From d76529a654a2fab02e6c92b6b8f241ce8953f645 Mon Sep 17 00:00:00 2001 From: Vitaly Puzrin Date: Thu, 5 Mar 2015 16:24:46 +0300 Subject: [PATCH] Browser files rebuild --- dist/markdown-it.js | 3102 ++++++++++++--------------------------- dist/markdown-it.min.js | 8 +- 2 files changed, 931 insertions(+), 2179 deletions(-) diff --git a/dist/markdown-it.js b/dist/markdown-it.js index 166cae1..ba9f347 100644 --- a/dist/markdown-it.js +++ b/dist/markdown-it.js @@ -1,4 +1,4 @@ -/*! markdown-it 3.0.7 https://github.com//markdown-it/markdown-it @license MIT */!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.markdownit=e()}}(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?@[\\\]^_`{|}~])/g; - -function unescapeMd(str) { - if (str.indexOf('\\') < 0) { return str; } - return str.replace(UNESCAPE_MD_RE, '$1'); -} - -//////////////////////////////////////////////////////////////////////////////// - function isValidEntityCode(c) { /*eslint no-bitwise:0*/ // broken sequence @@ -2482,8 +2473,13 @@ function fromCodePoint(c) { return String.fromCharCode(c); } -var NAMED_ENTITY_RE = /&([a-z#][a-z0-9]{1,31});/gi; + +var UNESCAPE_MD_RE = /\\([!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~])/g; +var ENTITY_RE = /&([a-z#][a-z0-9]{1,31});/gi; +var UNESCAPE_ALL_RE = new RegExp(UNESCAPE_MD_RE.source + '|' + ENTITY_RE.source, 'gi'); + var DIGITAL_ENTITY_TEST_RE = /^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i; + var entities = require('./entities'); function replaceEntityPattern(match, name) { @@ -2506,7 +2502,21 @@ function replaceEntityPattern(match, name) { function replaceEntities(str) { if (str.indexOf('&') < 0) { return str; } - return str.replace(NAMED_ENTITY_RE, replaceEntityPattern); + return str.replace(ENTITY_RE, replaceEntityPattern); +} + +function unescapeMd(str) { + if (str.indexOf('\\') < 0) { return str; } + return str.replace(UNESCAPE_MD_RE, '$1'); +} + +function unescapeAll(str) { + if (str.indexOf('\\') < 0 && str.indexOf('&') < 0) { return str; } + + return str.replace(UNESCAPE_ALL_RE, function(match, escaped, entity) { + if (escaped) { return escaped; } + return replaceEntityPattern(match, entity); + }); } //////////////////////////////////////////////////////////////////////////////// @@ -2533,36 +2543,7 @@ function escapeHtml(str) { //////////////////////////////////////////////////////////////////////////////// -var SURRORATE_TEST_RE = /[\uD800-\uDFFF]/; -var SURRORATE_SEARCH_RE = /[\uD800-\uDFFF]/g; - -function replaceBadSurrogate(ch, pos, orig) { - var code = ch.charCodeAt(0); - - if (code >= 0xD800 && code <= 0xDBFF) { - // high surrogate - if (pos >= orig.length - 1) { return '\uFFFD'; } - code = orig.charCodeAt(pos + 1); - if (code < 0xDC00 || code > 0xDFFF) { return '\uFFFD'; } - - return ch; - } - - // low surrogate - if (pos === 0) { return '\uFFFD'; } - code = orig.charCodeAt(pos - 1); - if (code < 0xD800 || code > 0xDBFF) { return '\uFFFD'; } - return ch; -} - -function fixBrokenSurrogates(str) { - if (!SURRORATE_TEST_RE.test(str)) { return str; } - - return str.replace(SURRORATE_SEARCH_RE, replaceBadSurrogate); -} - -//////////////////////////////////////////////////////////////////////////////// - +var encode = require('mdurl/encode'); // Incoming link can be partially encoded. Convert possible combinations to // unified form. @@ -2574,24 +2555,7 @@ function fixBrokenSurrogates(str) { // - (?) punicode for domain mame (but encodeURI seems to work in real world) // function normalizeLink(url) { - var normalized = replaceEntities(url); - - // We don't care much about result of mailformed URIs, - // but shoud not throw exception. - try { - normalized = decodeURI(normalized); - } catch (__) {} - - // Encoder throws exception on broken surrogate pairs. - // Fix those first. - - try { - return encodeURI(fixBrokenSurrogates(normalized)); - } catch (__) { - // This should never happen and left for safety only. - /*istanbul ignore next*/ - return ''; - } + return encode(url); } //////////////////////////////////////////////////////////////////////////////// @@ -2697,6 +2661,7 @@ exports.assign = assign; exports.isString = isString; exports.has = has; exports.unescapeMd = unescapeMd; +exports.unescapeAll = unescapeAll; exports.isValidEntityCode = isValidEntityCode; exports.fromCodePoint = fromCodePoint; exports.replaceEntities = replaceEntities; @@ -2709,10 +2674,7 @@ exports.isPunctChar = isPunctChar; exports.escapeRE = escapeRE; exports.normalizeReference = normalizeReference; -// for testing only -exports.fixBrokenSurrogates = fixBrokenSurrogates; - -},{"./entities":1,"uc.micro/categories/P/regex":51}],6:[function(require,module,exports){ +},{"./entities":1,"mdurl/encode":52,"uc.micro/categories/P/regex":55}],6:[function(require,module,exports){ // Just a shortcut for bulk export 'use strict'; @@ -2728,7 +2690,7 @@ exports.parseLinkTitle = require('./parse_link_title'); var normalizeLink = require('../common/utils').normalizeLink; -var unescapeMd = require('../common/utils').unescapeMd; +var unescapeAll = require('../common/utils').unescapeAll; module.exports = function parseLinkDestination(str, pos, max) { @@ -2749,7 +2711,7 @@ module.exports = function parseLinkDestination(str, pos, max) { if (code === 0x0A /* \n */) { return result; } if (code === 0x3E /* > */) { result.pos = pos + 1; - result.str = normalizeLink(unescapeMd(str.slice(start + 1, pos))); + result.str = normalizeLink(unescapeAll(str.slice(start + 1, pos))); result.ok = true; return result; } @@ -2796,7 +2758,7 @@ module.exports = function parseLinkDestination(str, pos, max) { if (start === pos) { return result; } - result.str = normalizeLink(unescapeMd(str.slice(start, pos))); + result.str = normalizeLink(unescapeAll(str.slice(start, pos))); result.lines = lines; result.pos = pos; result.ok = true; @@ -2859,7 +2821,7 @@ module.exports = function parseLinkLabel(state, start, disableNested) { 'use strict'; -var unescapeMd = require('../common/utils').unescapeMd; +var unescapeAll = require('../common/utils').unescapeAll; module.exports = function parseLinkTitle(str, pos, max) { @@ -2890,7 +2852,7 @@ module.exports = function parseLinkTitle(str, pos, max) { if (code === marker) { result.pos = pos + 1; result.lines = lines; - result.str = unescapeMd(str.slice(start + 1, pos)); + result.str = unescapeAll(str.slice(start + 1, pos)); result.ok = true; return result; } else if (code === 0x0A) { @@ -2920,6 +2882,7 @@ var Renderer = require('./renderer'); var ParserCore = require('./parser_core'); var ParserBlock = require('./parser_block'); var ParserInline = require('./parser_inline'); +var LinkifyIt = require('linkify-it'); var config = { 'default': require('./presets/default'), @@ -3103,6 +3066,15 @@ function MarkdownIt(presetName, options) { **/ this.renderer = new Renderer(); + /** + * MarkdownIt#linkify -> LinkifyIt + * + * [linkify-it](https://github.com/markdown-it/linkify-it) instance. + * Used by [linkify](https://github.com/markdown-it/markdown-it/blob/master/lib/rules_core/linkify.js) + * rule. + **/ + this.linkify = new LinkifyIt(); + // Expose utils & helpers for easy acces from plugins /** @@ -3282,10 +3254,10 @@ MarkdownIt.prototype.use = function (plugin /*, params, ... */) { * method directly, until you write custom renderer (for example, to produce * AST). * - * `env` is used to pass data between "distributed" rules (`{}` by default). - * For example, references are parsed in different chains, and need sandbox - * to store intermediate results. Can be used to inject data in specific cases. - * You will not need it with high probability. + * `env` is used to pass data between "distributed" rules and return additional + * metadata like reference info, needed for for renderer. It also can be used to + * inject data in specific cases. Usually, you will be ok to pass `{}`, + * and then pass updated object to renderer. **/ MarkdownIt.prototype.parse = function (src, env) { var state = new this.core.State(src, this, env); @@ -3320,8 +3292,8 @@ MarkdownIt.prototype.render = function (src, env) { * - env (Object): environment sandbox * * The same as [[MarkdownIt.parse]] but skip all block rules. It returns the - * block tokens list with th single `inline` element, containing parsed inline - * tokens in `children` property. + * block tokens list with the single `inline` element, containing parsed inline + * tokens in `children` property. Also updates `env` object. **/ MarkdownIt.prototype.parseInline = function (src, env) { var state = new this.core.State(src, this, env); @@ -3350,7 +3322,7 @@ MarkdownIt.prototype.renderInline = function (src, env) { module.exports = MarkdownIt; -},{"./common/utils":5,"./helpers":6,"./parser_block":11,"./parser_core":12,"./parser_inline":13,"./presets/commonmark":14,"./presets/default":15,"./presets/zero":16,"./renderer":17}],11:[function(require,module,exports){ +},{"./common/utils":5,"./helpers":6,"./parser_block":11,"./parser_core":12,"./parser_inline":13,"./presets/commonmark":14,"./presets/default":15,"./presets/zero":16,"./renderer":17,"linkify-it":50}],11:[function(require,module,exports){ /** internal * class ParserBlock * @@ -3879,8 +3851,7 @@ module.exports = { var assign = require('./common/utils').assign; -var unescapeMd = require('./common/utils').unescapeMd; -var replaceEntities = require('./common/utils').replaceEntities; +var unescapeAll = require('./common/utils').unescapeAll; var escapeHtml = require('./common/utils').escapeHtml; @@ -3909,7 +3880,7 @@ rules.fence = function (tokens, idx, options /*, env, self*/) { var highlighted; if (token.params) { - langName = escapeHtml(replaceEntities(unescapeMd(token.params.split(/\s+/g)[0]))); + langName = escapeHtml(unescapeAll(token.params.split(/\s+/g)[0])); langClass = ' class="' + langPrefix + langName + '"'; } @@ -3971,7 +3942,7 @@ rules.paragraph_close = function (tokens, idx /*, options, env */) { rules.link_open = function (tokens, idx /*, options, env */) { - var title = tokens[idx].title ? (' title="' + escapeHtml(replaceEntities(tokens[idx].title)) + '"') : ''; + var title = tokens[idx].title ? (' title="' + escapeHtml(tokens[idx].title) + '"') : ''; var target = tokens[idx].target ? (' target="' + escapeHtml(tokens[idx].target) + '"') : ''; return ''; }; @@ -3982,7 +3953,7 @@ rules.link_close = function (/* tokens, idx, options, env */) { rules.image = function (tokens, idx, options, env, self) { var src = ' src="' + escapeHtml(tokens[idx].src) + '"'; - var title = tokens[idx].title ? (' title="' + escapeHtml(replaceEntities(tokens[idx].title)) + '"') : ''; + var title = tokens[idx].title ? (' title="' + escapeHtml(tokens[idx].title) + '"') : ''; var alt = ' alt="' + self.renderInlineAsText(tokens[idx].tokens, options, env) + '"'; var suffix = options.xhtmlOut ? ' /' : ''; return ''; @@ -5476,6 +5447,8 @@ module.exports = function reference(state, startLine, _endLine, silent) { return false; } + // Reference can not terminate anything. This check is for safety only. + /*istanbul ignore if*/ if (silent) { return true; } label = normalizeReference(str.slice(1, labelEnd)); @@ -5857,11 +5830,8 @@ module.exports = function inline(state) { 'use strict'; -var Autolinker = require('autolinker'); var arrayReplaceAt = require('../common/utils').arrayReplaceAt; - - -var LINK_SCAN_RE = /www|@|\:\/\//; +var normalizeLink = require('../common/utils').normalizeLink; function isLinkOpen(str) { @@ -5871,54 +5841,17 @@ function isLinkClose(str) { return /^<\/a\s*>/i.test(str); } -// Stupid fabric to avoid singletons, for thread safety. -// Required for engines like Nashorn. -// -function createLinkifier() { - var links = []; - var autolinker = new Autolinker({ - stripPrefix: false, - url: true, - email: true, - twitter: false, - replaceFn: function (__, match) { - // Only collect matched strings but don't change anything. - switch (match.getType()) { - /*eslint default-case:0*/ - case 'url': - links.push({ - text: match.matchedText, - url: match.getUrl() - }); - break; - case 'email': - links.push({ - text: match.matchedText, - // normalize email protocol - url: 'mailto:' + match.getEmail().replace(/^mailto:/i, '') - }); - break; - } - return false; - } - }); - - return { - links: links, - autolinker: autolinker - }; -} - module.exports = function linkify(state) { - var i, j, l, tokens, token, text, nodes, ln, pos, level, htmlLinkLevel, + var i, j, l, tokens, token, nodes, ln, text, pos, lastPos, level, htmlLinkLevel, blockTokens = state.tokens, - linkifier = null, links, autolinker; + links; if (!state.md.options.linkify) { return; } for (j = 0, l = blockTokens.length; j < l; j++) { if (blockTokens[j].type !== 'inline') { continue; } + tokens = blockTokens[j].children; htmlLinkLevel = 0; @@ -5948,42 +5881,33 @@ module.exports = function linkify(state) { } if (htmlLinkLevel > 0) { continue; } - if (token.type === 'text' && LINK_SCAN_RE.test(token.content)) { - - // Init linkifier in lazy manner, only if required. - if (!linkifier) { - linkifier = createLinkifier(); - links = linkifier.links; - autolinker = linkifier.autolinker; - } + if (token.type === 'text' && state.md.linkify.test(token.content)) { text = token.content; - links.length = 0; - autolinker.link(text); - - if (!links.length) { continue; } + links = state.md.linkify.match(text); // Now split string to nodes nodes = []; level = token.level; + lastPos = 0; for (ln = 0; ln < links.length; ln++) { if (!state.md.inline.validateLink(links[ln].url)) { continue; } - pos = text.indexOf(links[ln].text); + pos = links[ln].index; - if (pos) { + if (pos > lastPos) { level = level; nodes.push({ type: 'text', - content: text.slice(0, pos), + content: text.slice(lastPos, pos), level: level }); } nodes.push({ type: 'link_open', - href: links[ln].url, + href: normalizeLink(links[ln].url), target: '', title: '', level: level++ @@ -5997,12 +5921,12 @@ module.exports = function linkify(state) { type: 'link_close', level: --level }); - text = text.slice(pos + links[ln].text.length); + lastPos = links[ln].lastIndex; } - if (text.length) { + if (lastPos < text.length) { nodes.push({ type: 'text', - content: text, + content: text.slice(lastPos), level: level }); } @@ -6014,7 +5938,7 @@ module.exports = function linkify(state) { } }; -},{"../common/utils":5,"autolinker":50}],34:[function(require,module,exports){ +},{"../common/utils":5}],34:[function(require,module,exports){ // Normalize input string 'use strict'; @@ -6137,18 +6061,14 @@ module.exports = function replace(state) { 'use strict'; +var isWhiteSpace = require('../common/utils').isWhiteSpace; +var isPunctChar = require('../common/utils').isPunctChar; +var isMdAsciiPunct = require('../common/utils').isMdAsciiPunct; + var QUOTE_TEST_RE = /['"]/; var QUOTE_RE = /['"]/g; -var PUNCT_RE = /[-\s()\[\]]/; var APOSTROPHE = '\u2019'; /* ’ */ -// This function returns true if the character at `pos` -// could be inside a word. -function isLetter(str, pos) { - if (pos < 0 || pos >= str.length) { return false; } - return !PUNCT_RE.test(str[pos]); -} - function replaceAt(str, index, ch) { return str.substr(0, index) + ch + str.substr(index + 1); @@ -6157,9 +6077,9 @@ function replaceAt(str, index, ch) { module.exports = function smartquotes(state) { /*eslint max-depth:0*/ - var i, token, text, t, pos, max, thisLevel, lastSpace, nextSpace, item, - canOpen, canClose, j, isSingle, blkIdx, tokens, - stack; + var i, token, text, t, pos, max, thisLevel, item, lastChar, nextChar, + isLastPunctChar, isNextPunctChar, isLastWhiteSpace, isNextWhiteSpace, + canOpen, canClose, j, isSingle, blkIdx, tokens, stack; if (!state.md.options.typographer) { return; } @@ -6195,12 +6115,51 @@ module.exports = function smartquotes(state) { t = QUOTE_RE.exec(text); if (!t) { break; } - lastSpace = !isLetter(text, t.index - 1); + canOpen = canClose = true; pos = t.index + 1; isSingle = (t[0] === "'"); - nextSpace = !isLetter(text, pos); - if (!nextSpace && !lastSpace) { + lastChar = t.index - 1 >= 0 ? text.charCodeAt(t.index - 1) : -1; + nextChar = pos < max ? text.charCodeAt(pos) : -1; + + isLastPunctChar = lastChar >= 0 && + (isMdAsciiPunct(lastChar) || isPunctChar(String.fromCharCode(lastChar))); + isNextPunctChar = nextChar >= 0 && + (isMdAsciiPunct(nextChar) || isPunctChar(String.fromCharCode(nextChar))); + + // begin/end of the line counts as a whitespace too + isLastWhiteSpace = lastChar < 0 || isWhiteSpace(lastChar); + isNextWhiteSpace = nextChar < 0 || isWhiteSpace(nextChar); + + if (isNextWhiteSpace) { + canOpen = false; + } else if (isNextPunctChar) { + if (!(isLastWhiteSpace || isLastPunctChar)) { + canOpen = false; + } + } + + if (isLastWhiteSpace) { + canClose = false; + } else if (isLastPunctChar) { + if (!(isNextWhiteSpace || isNextPunctChar)) { + canClose = false; + } + } + + if (nextChar === 0x22 /* " */ && t[0] === '"') { + if (lastChar >= 0x30 /* 0 */ && lastChar <= 0x39 /* 9 */) { + // special case: 1"" - count first quote as an inch + canClose = canOpen = false; + } + } + + if (canOpen && canClose) { + // treat this as the middle of the word + canOpen = canClose = false; + } + + if (!canOpen && !canClose) { // middle of word if (isSingle) { token.content = replaceAt(token.content, t.index, APOSTROPHE); @@ -6208,9 +6167,6 @@ module.exports = function smartquotes(state) { continue; } - canOpen = !nextSpace; - canClose = !lastSpace; - if (canClose) { // this could be a closing quote, rewind the stack to get a match for (j = stack.length - 1; j >= 0; j--) { @@ -6249,7 +6205,7 @@ module.exports = function smartquotes(state) { } }; -},{}],37:[function(require,module,exports){ +},{"../common/utils":5}],37:[function(require,module,exports){ // Core state object // 'use strict'; @@ -6402,12 +6358,6 @@ var isPunctChar = require('../common/utils').isPunctChar; var isMdAsciiPunct = require('../common/utils').isMdAsciiPunct; -function isAlphaNum(code) { - return (code >= 0x30 /* 0 */ && code <= 0x39 /* 9 */) || - (code >= 0x41 /* A */ && code <= 0x5A /* Z */) || - (code >= 0x61 /* a */ && code <= 0x7A /* z */); -} - // parse sequence of emphasis markers, // "start" should point at a valid marker function scanDelims(state, start) { @@ -6431,13 +6381,15 @@ function scanDelims(state, start) { (isMdAsciiPunct(lastChar) || isPunctChar(String.fromCharCode(lastChar))); isNextPunctChar = nextChar >= 0 && (isMdAsciiPunct(nextChar) || isPunctChar(String.fromCharCode(nextChar))); - isLastWhiteSpace = lastChar >= 0 && isWhiteSpace(lastChar); - isNextWhiteSpace = nextChar >= 0 && isWhiteSpace(nextChar); + + // begin/end of the line counts as a whitespace too + isLastWhiteSpace = lastChar < 0 || isWhiteSpace(lastChar); + isNextWhiteSpace = nextChar < 0 || isWhiteSpace(nextChar); if (isNextWhiteSpace) { can_open = false; } else if (isNextPunctChar) { - if (!(isLastWhiteSpace || isLastPunctChar || lastChar === -1)) { + if (!(isLastWhiteSpace || isLastPunctChar)) { can_open = false; } } @@ -6445,15 +6397,16 @@ function scanDelims(state, start) { if (isLastWhiteSpace) { can_close = false; } else if (isLastPunctChar) { - if (!(isNextWhiteSpace || isNextPunctChar || nextChar === -1)) { + if (!(isNextWhiteSpace || isNextPunctChar)) { can_close = false; } } if (marker === 0x5F /* _ */) { - // check if we aren't inside the word - if (isAlphaNum(lastChar)) { can_open = false; } - if (isAlphaNum(nextChar)) { can_close = false; } + if (can_open && can_close) { + // "_" inside a word can neither open nor close an emphasis + can_open = can_close = false; + } } return { @@ -7336,2009 +7289,808 @@ module.exports = function text(state, silent) { }; },{}],50:[function(require,module,exports){ -(function (root, factory) { - if (typeof define === 'function' && define.amd) { - // AMD. Register as an anonymous module. - define([], function () { - return (root.returnExportsGlobal = factory()); - }); - } else if (typeof exports === 'object') { - // Node. Does not work with strict CommonJS, but - // only CommonJS-like enviroments that support module.exports, - // like Node. - module.exports = factory(); - } else { - root['Autolinker'] = factory(); - } -}(this, function () { - - /*! - * Autolinker.js - * 0.15.2 - * - * Copyright(c) 2015 Gregory Jacobs - * MIT Licensed. http://www.opensource.org/licenses/mit-license.php - * - * https://github.com/gregjacobs/Autolinker.js - */ - /** - * @class Autolinker - * @extends Object - * - * Utility class used to process a given string of text, and wrap the URLs, email addresses, and Twitter handles in - * the appropriate anchor (<a>) tags to turn them into links. - * - * Any of the configuration options may be provided in an Object (map) provided to the Autolinker constructor, which - * will configure how the {@link #link link()} method will process the links. - * - * For example: - * - * var autolinker = new Autolinker( { - * newWindow : false, - * truncate : 30 - * } ); - * - * var html = autolinker.link( "Joe went to www.yahoo.com" ); - * // produces: 'Joe went to yahoo.com' - * - * - * The {@link #static-link static link()} method may also be used to inline options into a single call, which may - * be more convenient for one-off uses. For example: - * - * var html = Autolinker.link( "Joe went to www.yahoo.com", { - * newWindow : false, - * truncate : 30 - * } ); - * // produces: 'Joe went to yahoo.com' - * - * - * ## Custom Replacements of Links - * - * If the configuration options do not provide enough flexibility, a {@link #replaceFn} may be provided to fully customize - * the output of Autolinker. This function is called once for each URL/Email/Twitter handle match that is encountered. - * - * For example: - * - * var input = "..."; // string with URLs, Email Addresses, and Twitter Handles - * - * var linkedText = Autolinker.link( input, { - * replaceFn : function( autolinker, match ) { - * console.log( "href = ", match.getAnchorHref() ); - * console.log( "text = ", match.getAnchorText() ); - * - * switch( match.getType() ) { - * case 'url' : - * console.log( "url: ", match.getUrl() ); - * - * if( match.getUrl().indexOf( 'mysite.com' ) === -1 ) { - * var tag = autolinker.getTagBuilder().build( match ); // returns an `Autolinker.HtmlTag` instance, which provides mutator methods for easy changes - * tag.setAttr( 'rel', 'nofollow' ); - * tag.addClass( 'external-link' ); - * - * return tag; - * - * } else { - * return true; // let Autolinker perform its normal anchor tag replacement - * } - * - * case 'email' : - * var email = match.getEmail(); - * console.log( "email: ", email ); - * - * if( email === "my@own.address" ) { - * return false; // don't auto-link this particular email address; leave as-is - * } else { - * return; // no return value will have Autolinker perform its normal anchor tag replacement (same as returning `true`) - * } - * - * case 'twitter' : - * var twitterHandle = match.getTwitterHandle(); - * console.log( twitterHandle ); - * - * return '' + twitterHandle + ''; - * } - * } - * } ); - * - * - * The function may return the following values: - * - * - `true` (Boolean): Allow Autolinker to replace the match as it normally would. - * - `false` (Boolean): Do not replace the current match at all - leave as-is. - * - Any String: If a string is returned from the function, the string will be used directly as the replacement HTML for - * the match. - * - An {@link Autolinker.HtmlTag} instance, which can be used to build/modify an HTML tag before writing out its HTML text. - * - * @constructor - * @param {Object} [config] The configuration options for the Autolinker instance, specified in an Object (map). - */ - var Autolinker = function( cfg ) { - Autolinker.Util.assign( this, cfg ); // assign the properties of `cfg` onto the Autolinker instance. Prototype properties will be used for missing configs. - - this.matchValidator = new Autolinker.MatchValidator(); - }; - - - Autolinker.prototype = { - constructor : Autolinker, // fix constructor property - - /** - * @cfg {Boolean} urls - * - * `true` if miscellaneous URLs should be automatically linked, `false` if they should not be. - */ - urls : true, - - /** - * @cfg {Boolean} email - * - * `true` if email addresses should be automatically linked, `false` if they should not be. - */ - email : true, - - /** - * @cfg {Boolean} twitter - * - * `true` if Twitter handles ("@example") should be automatically linked, `false` if they should not be. - */ - twitter : true, - - /** - * @cfg {Boolean} newWindow - * - * `true` if the links should open in a new window, `false` otherwise. - */ - newWindow : true, - - /** - * @cfg {Boolean} stripPrefix - * - * `true` if 'http://' or 'https://' and/or the 'www.' should be stripped from the beginning of URL links' text, - * `false` otherwise. - */ - stripPrefix : true, - - /** - * @cfg {Number} truncate - * - * A number for how many characters long URLs/emails/twitter handles should be truncated to inside the text of - * a link. If the URL/email/twitter is over this number of characters, it will be truncated to this length by - * adding a two period ellipsis ('..') to the end of the string. - * - * For example: A url like 'http://www.yahoo.com/some/long/path/to/a/file' truncated to 25 characters might look - * something like this: 'yahoo.com/some/long/pat..' - */ - - /** - * @cfg {String} className - * - * A CSS class name to add to the generated links. This class will be added to all links, as well as this class - * plus url/email/twitter suffixes for styling url/email/twitter links differently. - * - * For example, if this config is provided as "myLink", then: - * - * - URL links will have the CSS classes: "myLink myLink-url" - * - Email links will have the CSS classes: "myLink myLink-email", and - * - Twitter links will have the CSS classes: "myLink myLink-twitter" - */ - className : "", - - /** - * @cfg {Function} replaceFn - * - * A function to individually process each URL/Email/Twitter match found in the input string. - * - * See the class's description for usage. - * - * This function is called with the following parameters: - * - * @cfg {Autolinker} replaceFn.autolinker The Autolinker instance, which may be used to retrieve child objects from (such - * as the instance's {@link #getTagBuilder tag builder}). - * @cfg {Autolinker.match.Match} replaceFn.match The Match instance which can be used to retrieve information about the - * {@link Autolinker.match.Url URL}/{@link Autolinker.match.Email email}/{@link Autolinker.match.Twitter Twitter} - * match that the `replaceFn` is currently processing. - */ - - - /** - * @private - * @property {RegExp} htmlCharacterEntitiesRegex - * - * The regular expression that matches common HTML character entities. - * - * Ignoring & as it could be part of a query string -- handling it separately. - */ - htmlCharacterEntitiesRegex: /( | |<|<|>|>|"|"|')/gi, - - /** - * @private - * @property {RegExp} matcherRegex - * - * The regular expression that matches URLs, email addresses, and Twitter handles. - * - * This regular expression has the following capturing groups: - * - * 1. Group that is used to determine if there is a Twitter handle match (i.e. \@someTwitterUser). Simply check for its - * existence to determine if there is a Twitter handle match. The next couple of capturing groups give information - * about the Twitter handle match. - * 2. The whitespace character before the \@sign in a Twitter handle. This is needed because there are no lookbehinds in - * JS regular expressions, and can be used to reconstruct the original string in a replace(). - * 3. The Twitter handle itself in a Twitter match. If the match is '@someTwitterUser', the handle is 'someTwitterUser'. - * 4. Group that matches an email address. Used to determine if the match is an email address, as well as holding the full - * address. Ex: 'me@my.com' - * 5. Group that matches a URL in the input text. Ex: 'http://google.com', 'www.google.com', or just 'google.com'. - * This also includes a path, url parameters, or hash anchors. Ex: google.com/path/to/file?q1=1&q2=2#myAnchor - * 6. Group that matches a protocol URL (i.e. 'http://google.com'). This is used to match protocol URLs with just a single - * word, like 'http://localhost', where we won't double check that the domain name has at least one '.' in it. - * 7. A protocol-relative ('//') match for the case of a 'www.' prefixed URL. Will be an empty string if it is not a - * protocol-relative match. We need to know the character before the '//' in order to determine if it is a valid match - * or the // was in a string we don't want to auto-link. - * 8. A protocol-relative ('//') match for the case of a known TLD prefixed URL. Will be an empty string if it is not a - * protocol-relative match. See #6 for more info. - */ - matcherRegex : (function() { - var twitterRegex = /(^|[^\w])@(\w{1,15})/, // For matching a twitter handle. Ex: @gregory_jacobs - - emailRegex = /(?:[\-;:&=\+\$,\w\.]+@)/, // something@ for email addresses (a.k.a. local-part) - - protocolRegex = /(?:[A-Za-z][-.+A-Za-z0-9]+:(?![A-Za-z][-.+A-Za-z0-9]+:\/\/)(?!\d+\/?)(?:\/\/)?)/, // match protocol, allow in format "http://" or "mailto:". However, do not match the first part of something like 'link:http://www.google.com' (i.e. don't match "link:"). Also, make sure we don't interpret 'google.com:8000' as if 'google.com' was a protocol here (i.e. ignore a trailing port number in this regex) - wwwRegex = /(?:www\.)/, // starting with 'www.' - domainNameRegex = /[A-Za-z0-9\.\-]*[A-Za-z0-9\-]/, // anything looking at all like a domain, non-unicode domains, not ending in a period - tldRegex = /\.(?:international|construction|contractors|enterprises|photography|productions|foundation|immobilien|industries|management|properties|technology|christmas|community|directory|education|equipment|institute|marketing|solutions|vacations|bargains|boutique|builders|catering|cleaning|clothing|computer|democrat|diamonds|graphics|holdings|lighting|partners|plumbing|supplies|training|ventures|academy|careers|company|cruises|domains|exposed|flights|florist|gallery|guitars|holiday|kitchen|neustar|okinawa|recipes|rentals|reviews|shiksha|singles|support|systems|agency|berlin|camera|center|coffee|condos|dating|estate|events|expert|futbol|kaufen|luxury|maison|monash|museum|nagoya|photos|repair|report|social|supply|tattoo|tienda|travel|viajes|villas|vision|voting|voyage|actor|build|cards|cheap|codes|dance|email|glass|house|mango|ninja|parts|photo|shoes|solar|today|tokyo|tools|watch|works|aero|arpa|asia|best|bike|blue|buzz|camp|club|cool|coop|farm|fish|gift|guru|info|jobs|kiwi|kred|land|limo|link|menu|mobi|moda|name|pics|pink|post|qpon|rich|ruhr|sexy|tips|vote|voto|wang|wien|wiki|zone|bar|bid|biz|cab|cat|ceo|com|edu|gov|int|kim|mil|net|onl|org|pro|pub|red|tel|uno|wed|xxx|xyz|ac|ad|ae|af|ag|ai|al|am|an|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cu|cv|cw|cx|cy|cz|de|dj|dk|dm|do|dz|ec|ee|eg|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|sj|sk|sl|sm|sn|so|sr|st|su|sv|sx|sy|sz|tc|td|tf|tg|th|tj|tk|tl|tm|tn|to|tp|tr|tt|tv|tw|tz|ua|ug|uk|us|uy|uz|va|vc|ve|vg|vi|vn|vu|wf|ws|ye|yt|za|zm|zw)\b/, // match our known top level domains (TLDs) - - // Allow optional path, query string, and hash anchor, not ending in the following characters: "?!:,.;" - // http://blog.codinghorror.com/the-problem-with-urls/ - urlSuffixRegex = /[\-A-Za-z0-9+&@#\/%=~_()|'$*\[\]?!:,.;]*[\-A-Za-z0-9+&@#\/%=~_()|'$*\[\]]/; - - return new RegExp( [ - '(', // *** Capturing group $1, which can be used to check for a twitter handle match. Use group $3 for the actual twitter handle though. $2 may be used to reconstruct the original string in a replace() - // *** Capturing group $2, which matches the whitespace character before the '@' sign (needed because of no lookbehinds), and - // *** Capturing group $3, which matches the actual twitter handle - twitterRegex.source, - ')', - - '|', - - '(', // *** Capturing group $4, which is used to determine an email match - emailRegex.source, - domainNameRegex.source, - tldRegex.source, - ')', - - '|', - - '(', // *** Capturing group $5, which is used to match a URL - '(?:', // parens to cover match for protocol (optional), and domain - '(', // *** Capturing group $6, for a protocol-prefixed url (ex: http://google.com) - protocolRegex.source, - domainNameRegex.source, - ')', - - '|', - - '(?:', // non-capturing paren for a 'www.' prefixed url (ex: www.google.com) - '(.?//)?', // *** Capturing group $7 for an optional protocol-relative URL. Must be at the beginning of the string or start with a non-word character - wwwRegex.source, - domainNameRegex.source, - ')', - - '|', - - '(?:', // non-capturing paren for known a TLD url (ex: google.com) - '(.?//)?', // *** Capturing group $8 for an optional protocol-relative URL. Must be at the beginning of the string or start with a non-word character - domainNameRegex.source, - tldRegex.source, - ')', - ')', - - '(?:' + urlSuffixRegex.source + ')?', // match for path, query string, and/or hash anchor - optional - ')' - ].join( "" ), 'gi' ); - } )(), - - /** - * @private - * @property {RegExp} charBeforeProtocolRelMatchRegex - * - * The regular expression used to retrieve the character before a protocol-relative URL match. - * - * This is used in conjunction with the {@link #matcherRegex}, which needs to grab the character before a protocol-relative - * '//' due to the lack of a negative look-behind in JavaScript regular expressions. The character before the match is stripped - * from the URL. - */ - charBeforeProtocolRelMatchRegex : /^(.)?\/\//, - - /** - * @private - * @property {Autolinker.MatchValidator} matchValidator - * - * The MatchValidator object, used to filter out any false positives from the {@link #matcherRegex}. See - * {@link Autolinker.MatchValidator} for details. - */ - - /** - * @private - * @property {Autolinker.HtmlParser} htmlParser - * - * The HtmlParser instance used to skip over HTML tags, while finding text nodes to process. This is lazily instantiated - * in the {@link #getHtmlParser} method. - */ - - /** - * @private - * @property {Autolinker.AnchorTagBuilder} tagBuilder - * - * The AnchorTagBuilder instance used to build the URL/email/Twitter replacement anchor tags. This is lazily instantiated - * in the {@link #getTagBuilder} method. - */ - - - /** - * Automatically links URLs, email addresses, and Twitter handles found in the given chunk of HTML. - * Does not link URLs found within HTML tags. - * - * For instance, if given the text: `You should go to http://www.yahoo.com`, then the result - * will be `You should go to <a href="http://www.yahoo.com">http://www.yahoo.com</a>` - * - * This method finds the text around any HTML elements in the input `textOrHtml`, which will be the text that is processed. - * Any original HTML elements will be left as-is, as well as the text that is already wrapped in anchor (<a>) tags. - * - * @param {String} textOrHtml The HTML or text to link URLs, email addresses, and Twitter handles within (depending on if - * the {@link #urls}, {@link #email}, and {@link #twitter} options are enabled). - * @return {String} The HTML, with URLs/emails/Twitter handles automatically linked. - */ - link : function( textOrHtml ) { - var me = this, // for closure - htmlParser = this.getHtmlParser(), - htmlCharacterEntitiesRegex = this.htmlCharacterEntitiesRegex, - anchorTagStackCount = 0, // used to only process text around anchor tags, and any inner text/html they may have - resultHtml = []; - - htmlParser.parse( textOrHtml, { - // Process HTML nodes in the input `textOrHtml` - processHtmlNode : function( tagText, tagName, isClosingTag ) { - if( tagName === 'a' ) { - if( !isClosingTag ) { // it's the start tag - anchorTagStackCount++; - } else { // it's the end tag - anchorTagStackCount = Math.max( anchorTagStackCount - 1, 0 ); // attempt to handle extraneous tags by making sure the stack count never goes below 0 - } - } - resultHtml.push( tagText ); // now add the text of the tag itself verbatim - }, - - // Process text nodes in the input `textOrHtml` - processTextNode : function( text ) { - if( anchorTagStackCount === 0 ) { - // If we're not within an tag, process the text node - var unescapedText = Autolinker.Util.splitAndCapture( text, htmlCharacterEntitiesRegex ); // split at HTML entities, but include the HTML entities in the results array - - for ( var i = 0, len = unescapedText.length; i < len; i++ ) { - var textToProcess = unescapedText[ i ], - processedTextNode = me.processTextNode( textToProcess ); - - resultHtml.push( processedTextNode ); - } - - } else { - // `text` is within an tag, simply append the text - we do not want to autolink anything - // already within an ... tag - resultHtml.push( text ); - } - } - } ); - - return resultHtml.join( "" ); - }, - - - /** - * Lazily instantiates and returns the {@link #htmlParser} instance for this Autolinker instance. - * - * @protected - * @return {Autolinker.HtmlParser} - */ - getHtmlParser : function() { - var htmlParser = this.htmlParser; - - if( !htmlParser ) { - htmlParser = this.htmlParser = new Autolinker.HtmlParser(); - } - - return htmlParser; - }, - - - /** - * Returns the {@link #tagBuilder} instance for this Autolinker instance, lazily instantiating it - * if it does not yet exist. - * - * This method may be used in a {@link #replaceFn} to generate the {@link Autolinker.HtmlTag HtmlTag} instance that - * Autolinker would normally generate, and then allow for modifications before returning it. For example: - * - * var html = Autolinker.link( "Test google.com", { - * replaceFn : function( autolinker, match ) { - * var tag = autolinker.getTagBuilder().build( match ); // returns an {@link Autolinker.HtmlTag} instance - * tag.setAttr( 'rel', 'nofollow' ); - * - * return tag; - * } - * } ); - * - * // generated html: - * // Test google.com - * - * @return {Autolinker.AnchorTagBuilder} - */ - getTagBuilder : function() { - var tagBuilder = this.tagBuilder; - - if( !tagBuilder ) { - tagBuilder = this.tagBuilder = new Autolinker.AnchorTagBuilder( { - newWindow : this.newWindow, - truncate : this.truncate, - className : this.className - } ); - } - - return tagBuilder; - }, - - - /** - * Process the text that lies inbetween HTML tags. This method does the actual wrapping of URLs with - * anchor tags. - * - * @private - * @param {String} text The text to auto-link. - * @return {String} The text with anchor tags auto-filled. - */ - processTextNode : function( text ) { - var me = this; // for closure - - return text.replace( this.matcherRegex, function( matchStr, $1, $2, $3, $4, $5, $6, $7, $8 ) { - var matchDescObj = me.processCandidateMatch( matchStr, $1, $2, $3, $4, $5, $6, $7, $8 ); // match description object - - // Return out with no changes for match types that are disabled (url, email, twitter), or for matches that are - // invalid (false positives from the matcherRegex, which can't use look-behinds since they are unavailable in JS). - if( !matchDescObj ) { - return matchStr; - - } else { - // Generate the replacement text for the match - var matchReturnVal = me.createMatchReturnVal( matchDescObj.match, matchDescObj.matchStr ); - return matchDescObj.prefixStr + matchReturnVal + matchDescObj.suffixStr; - } - } ); - }, - - - /** - * Processes a candidate match from the {@link #matcherRegex}. - * - * Not all matches found by the regex are actual URL/email/Twitter matches, as determined by the {@link #matchValidator}. In - * this case, the method returns `null`. Otherwise, a valid Object with `prefixStr`, `match`, and `suffixStr` is returned. - * - * @private - * @param {String} matchStr The full match that was found by the {@link #matcherRegex}. - * @param {String} twitterMatch The matched text of a Twitter handle, if the match is a Twitter match. - * @param {String} twitterHandlePrefixWhitespaceChar The whitespace char before the @ sign in a Twitter handle match. This - * is needed because of no lookbehinds in JS regexes, and is need to re-include the character for the anchor tag replacement. - * @param {String} twitterHandle The actual Twitter user (i.e the word after the @ sign in a Twitter match). - * @param {String} emailAddressMatch The matched email address for an email address match. - * @param {String} urlMatch The matched URL string for a URL match. - * @param {String} protocolUrlMatch The match URL string for a protocol match. Ex: 'http://yahoo.com'. This is used to match - * something like 'http://localhost', where we won't double check that the domain name has at least one '.' in it. - * @param {String} wwwProtocolRelativeMatch The '//' for a protocol-relative match from a 'www' url, with the character that - * comes before the '//'. - * @param {String} tldProtocolRelativeMatch The '//' for a protocol-relative match from a TLD (top level domain) match, with - * the character that comes before the '//'. - * - * @return {Object} A "match description object". This will be `null` if the match was invalid, or if a match type is disabled. - * Otherwise, this will be an Object (map) with the following properties: - * @return {String} return.prefixStr The char(s) that should be prepended to the replacement string. These are char(s) that - * were needed to be included from the regex match that were ignored by processing code, and should be re-inserted into - * the replacement stream. - * @return {String} return.suffixStr The char(s) that should be appended to the replacement string. These are char(s) that - * were needed to be included from the regex match that were ignored by processing code, and should be re-inserted into - * the replacement stream. - * @return {String} return.matchStr The `matchStr`, fixed up to remove characters that are no longer needed (which have been - * added to `prefixStr` and `suffixStr`). - * @return {Autolinker.match.Match} return.match The Match object that represents the match that was found. - */ - processCandidateMatch : function( - matchStr, twitterMatch, twitterHandlePrefixWhitespaceChar, twitterHandle, - emailAddressMatch, urlMatch, protocolUrlMatch, wwwProtocolRelativeMatch, tldProtocolRelativeMatch - ) { - var protocolRelativeMatch = wwwProtocolRelativeMatch || tldProtocolRelativeMatch, - match, // Will be an Autolinker.match.Match object - - prefixStr = "", // A string to use to prefix the anchor tag that is created. This is needed for the Twitter handle match - suffixStr = ""; // A string to suffix the anchor tag that is created. This is used if there is a trailing parenthesis that should not be auto-linked. - - - // Return out with `null` for match types that are disabled (url, email, twitter), or for matches that are - // invalid (false positives from the matcherRegex, which can't use look-behinds since they are unavailable in JS). - if( - ( twitterMatch && !this.twitter ) || ( emailAddressMatch && !this.email ) || ( urlMatch && !this.urls ) || - !this.matchValidator.isValidMatch( urlMatch, protocolUrlMatch, protocolRelativeMatch ) - ) { - return null; - } - - // Handle a closing parenthesis at the end of the match, and exclude it if there is not a matching open parenthesis - // in the match itself. - if( this.matchHasUnbalancedClosingParen( matchStr ) ) { - matchStr = matchStr.substr( 0, matchStr.length - 1 ); // remove the trailing ")" - suffixStr = ")"; // this will be added after the generated tag - } - - - if( emailAddressMatch ) { - match = new Autolinker.match.Email( { matchedText: matchStr, email: emailAddressMatch } ); - - } else if( twitterMatch ) { - // fix up the `matchStr` if there was a preceding whitespace char, which was needed to determine the match - // itself (since there are no look-behinds in JS regexes) - if( twitterHandlePrefixWhitespaceChar ) { - prefixStr = twitterHandlePrefixWhitespaceChar; - matchStr = matchStr.slice( 1 ); // remove the prefixed whitespace char from the match - } - match = new Autolinker.match.Twitter( { matchedText: matchStr, twitterHandle: twitterHandle } ); - - } else { // url match - // If it's a protocol-relative '//' match, remove the character before the '//' (which the matcherRegex needed - // to match due to the lack of a negative look-behind in JavaScript regular expressions) - if( protocolRelativeMatch ) { - var charBeforeMatch = protocolRelativeMatch.match( this.charBeforeProtocolRelMatchRegex )[ 1 ] || ""; - - if( charBeforeMatch ) { // fix up the `matchStr` if there was a preceding char before a protocol-relative match, which was needed to determine the match itself (since there are no look-behinds in JS regexes) - prefixStr = charBeforeMatch; - matchStr = matchStr.slice( 1 ); // remove the prefixed char from the match - } - } - - match = new Autolinker.match.Url( { - matchedText : matchStr, - url : matchStr, - protocolUrlMatch : !!protocolUrlMatch, - protocolRelativeMatch : !!protocolRelativeMatch, - stripPrefix : this.stripPrefix - } ); - } - - return { - prefixStr : prefixStr, - suffixStr : suffixStr, - matchStr : matchStr, - match : match - }; - }, - - - /** - * Determines if a match found has an unmatched closing parenthesis. If so, this parenthesis will be removed - * from the match itself, and appended after the generated anchor tag in {@link #processTextNode}. - * - * A match may have an extra closing parenthesis at the end of the match because the regular expression must include parenthesis - * for URLs such as "wikipedia.com/something_(disambiguation)", which should be auto-linked. - * - * However, an extra parenthesis *will* be included when the URL itself is wrapped in parenthesis, such as in the case of - * "(wikipedia.com/something_(disambiguation))". In this case, the last closing parenthesis should *not* be part of the URL - * itself, and this method will return `true`. - * - * @private - * @param {String} matchStr The full match string from the {@link #matcherRegex}. - * @return {Boolean} `true` if there is an unbalanced closing parenthesis at the end of the `matchStr`, `false` otherwise. - */ - matchHasUnbalancedClosingParen : function( matchStr ) { - var lastChar = matchStr.charAt( matchStr.length - 1 ); - - if( lastChar === ')' ) { - var openParensMatch = matchStr.match( /\(/g ), - closeParensMatch = matchStr.match( /\)/g ), - numOpenParens = ( openParensMatch && openParensMatch.length ) || 0, - numCloseParens = ( closeParensMatch && closeParensMatch.length ) || 0; - - if( numOpenParens < numCloseParens ) { - return true; - } - } - - return false; - }, - - - /** - * Creates the return string value for a given match in the input string, for the {@link #processTextNode} method. - * - * This method handles the {@link #replaceFn}, if one was provided. - * - * @private - * @param {Autolinker.match.Match} match The Match object that represents the match. - * @param {String} matchStr The original match string, after having been preprocessed to fix match edge cases (see - * the `prefixStr` and `suffixStr` vars in {@link #processTextNode}. - * @return {String} The string that the `match` should be replaced with. This is usually the anchor tag string, but - * may be the `matchStr` itself if the match is not to be replaced. - */ - createMatchReturnVal : function( match, matchStr ) { - // Handle a custom `replaceFn` being provided - var replaceFnResult; - if( this.replaceFn ) { - replaceFnResult = this.replaceFn.call( this, this, match ); // Autolinker instance is the context, and the first arg - } - - if( typeof replaceFnResult === 'string' ) { - return replaceFnResult; // `replaceFn` returned a string, use that - - } else if( replaceFnResult === false ) { - return matchStr; // no replacement for the match - - } else if( replaceFnResult instanceof Autolinker.HtmlTag ) { - return replaceFnResult.toString(); - - } else { // replaceFnResult === true, or no/unknown return value from function - // Perform Autolinker's default anchor tag generation - var tagBuilder = this.getTagBuilder(), - anchorTag = tagBuilder.build( match ); // returns an Autolinker.HtmlTag instance - - return anchorTag.toString(); - } - } - - }; - - - /** - * Automatically links URLs, email addresses, and Twitter handles found in the given chunk of HTML. - * Does not link URLs found within HTML tags. - * - * For instance, if given the text: `You should go to http://www.yahoo.com`, then the result - * will be `You should go to <a href="http://www.yahoo.com">http://www.yahoo.com</a>` - * - * Example: - * - * var linkedText = Autolinker.link( "Go to google.com", { newWindow: false } ); - * // Produces: "Go to google.com" - * - * @static - * @param {String} textOrHtml The HTML or text to find URLs, email addresses, and Twitter handles within (depending on if - * the {@link #urls}, {@link #email}, and {@link #twitter} options are enabled). - * @param {Object} [options] Any of the configuration options for the Autolinker class, specified in an Object (map). - * See the class description for an example call. - * @return {String} The HTML text, with URLs automatically linked - */ - Autolinker.link = function( textOrHtml, options ) { - var autolinker = new Autolinker( options ); - return autolinker.link( textOrHtml ); - }; - - - // Namespace for `match` classes - Autolinker.match = {}; - /*global Autolinker */ - /*jshint eqnull:true, boss:true */ - /** - * @class Autolinker.Util - * @singleton - * - * A few utility methods for Autolinker. - */ - Autolinker.Util = { - - /** - * @property {Function} abstractMethod - * - * A function object which represents an abstract method. - */ - abstractMethod : function() { throw "abstract"; }, - - - /** - * Assigns (shallow copies) the properties of `src` onto `dest`. - * - * @param {Object} dest The destination object. - * @param {Object} src The source object. - * @return {Object} The destination object (`dest`) - */ - assign : function( dest, src ) { - for( var prop in src ) { - if( src.hasOwnProperty( prop ) ) { - dest[ prop ] = src[ prop ]; - } - } - - return dest; - }, - - - /** - * Extends `superclass` to create a new subclass, adding the `protoProps` to the new subclass's prototype. - * - * @param {Function} superclass The constructor function for the superclass. - * @param {Object} protoProps The methods/properties to add to the subclass's prototype. This may contain the - * special property `constructor`, which will be used as the new subclass's constructor function. - * @return {Function} The new subclass function. - */ - extend : function( superclass, protoProps ) { - var superclassProto = superclass.prototype; - - var F = function() {}; - F.prototype = superclassProto; - - var subclass; - if( protoProps.hasOwnProperty( 'constructor' ) ) { - subclass = protoProps.constructor; - } else { - subclass = function() { superclassProto.constructor.apply( this, arguments ); }; - } - - var subclassProto = subclass.prototype = new F(); // set up prototype chain - subclassProto.constructor = subclass; // fix constructor property - subclassProto.superclass = superclassProto; - - delete protoProps.constructor; // don't re-assign constructor property to the prototype, since a new function may have been created (`subclass`), which is now already there - Autolinker.Util.assign( subclassProto, protoProps ); - - return subclass; - }, - - - /** - * Truncates the `str` at `len - ellipsisChars.length`, and adds the `ellipsisChars` to the - * end of the string (by default, two periods: '..'). If the `str` length does not exceed - * `len`, the string will be returned unchanged. - * - * @param {String} str The string to truncate and add an ellipsis to. - * @param {Number} truncateLen The length to truncate the string at. - * @param {String} [ellipsisChars=..] The ellipsis character(s) to add to the end of `str` - * when truncated. Defaults to '..' - */ - ellipsis : function( str, truncateLen, ellipsisChars ) { - if( str.length > truncateLen ) { - ellipsisChars = ( ellipsisChars == null ) ? '..' : ellipsisChars; - str = str.substring( 0, truncateLen - ellipsisChars.length ) + ellipsisChars; - } - return str; - }, - - - /** - * Supports `Array.prototype.indexOf()` functionality for old IE (IE8 and below). - * - * @param {Array} arr The array to find an element of. - * @param {*} element The element to find in the array, and return the index of. - * @return {Number} The index of the `element`, or -1 if it was not found. - */ - indexOf : function( arr, element ) { - if( Array.prototype.indexOf ) { - return arr.indexOf( element ); - - } else { - for( var i = 0, len = arr.length; i < len; i++ ) { - if( arr[ i ] === element ) return i; - } - return -1; - } - }, - - - - /** - * Performs the functionality of what modern browsers do when `String.prototype.split()` is called - * with a regular expression that contains capturing parenthesis. - * - * For example: - * - * // Modern browsers: - * "a,b,c".split( /(,)/ ); // --> [ 'a', ',', 'b', ',', 'c' ] - * - * // Old IE (including IE8): - * "a,b,c".split( /(,)/ ); // --> [ 'a', 'b', 'c' ] - * - * This method emulates the functionality of modern browsers for the old IE case. - * - * @param {String} str The string to split. - * @param {RegExp} splitRegex The regular expression to split the input `str` on. The splitting - * character(s) will be spliced into the array, as in the "modern browsers" example in the - * description of this method. - * Note #1: the supplied regular expression **must** have the 'g' flag specified. - * Note #2: for simplicity's sake, the regular expression does not need - * to contain capturing parenthesis - it will be assumed that any match has them. - * @return {String[]} The split array of strings, with the splitting character(s) included. - */ - splitAndCapture : function( str, splitRegex ) { - if( !splitRegex.global ) throw new Error( "`splitRegex` must have the 'g' flag set" ); - - var result = [], - lastIdx = 0, - match; - - while( match = splitRegex.exec( str ) ) { - result.push( str.substring( lastIdx, match.index ) ); - result.push( match[ 0 ] ); // push the splitting char(s) - - lastIdx = match.index + match[ 0 ].length; - } - result.push( str.substring( lastIdx ) ); - - return result; - } - - }; - /*global Autolinker */ - /** - * @private - * @class Autolinker.HtmlParser - * @extends Object - * - * An HTML parser implementation which simply walks an HTML string and calls the provided visitor functions to process - * HTML and text nodes. - * - * Autolinker uses this to only link URLs/emails/Twitter handles within text nodes, basically ignoring HTML tags. - */ - Autolinker.HtmlParser = Autolinker.Util.extend( Object, { - - /** - * @private - * @property {RegExp} htmlRegex - * - * The regular expression used to pull out HTML tags from a string. Handles namespaced HTML tags and - * attribute names, as specified by http://www.w3.org/TR/html-markup/syntax.html. - * - * Capturing groups: - * - * 1. The "!DOCTYPE" tag name, if a tag is a <!DOCTYPE> tag. - * 2. If it is an end tag, this group will have the '/'. - * 3. The tag name for all tags (other than the <!DOCTYPE> tag) - */ - htmlRegex : (function() { - var tagNameRegex = /[0-9a-zA-Z][0-9a-zA-Z:]*/, - attrNameRegex = /[^\s\0"'>\/=\x01-\x1F\x7F]+/, // the unicode range accounts for excluding control chars, and the delete char - attrValueRegex = /(?:"[^"]*?"|'[^']*?'|[^'"=<>`\s]+)/, // double quoted, single quoted, or unquoted attribute values - nameEqualsValueRegex = attrNameRegex.source + '(?:\\s*=\\s*' + attrValueRegex.source + ')?'; // optional '=[value]' - - return new RegExp( [ - // for tag. Ex: ) - '(?:', - '<(!DOCTYPE)', // *** Capturing Group 1 - If it's a doctype tag - - // Zero or more attributes following the tag name - '(?:', - '\\s+', // one or more whitespace chars before an attribute - - // Either: - // A. attr="value", or - // B. "value" alone (To cover example doctype tag: ) - '(?:', nameEqualsValueRegex, '|', attrValueRegex.source + ')', - ')*', - '>', - ')', - - '|', - - // All other HTML tags (i.e. tags that are not ) - '(?:', - '<(/)?', // Beginning of a tag. Either '<' for a start tag, or '' - '>', - ')' - ].join( "" ), 'gi' ); - } )(), - - - /** - * Walks an HTML string, calling the `options.processHtmlNode` function for each HTML tag that is encountered, and calling - * the `options.processTextNode` function when each text around HTML tags is encountered. - * - * @param {String} html The HTML to parse. - * @param {Object} [options] An Object (map) which may contain the following properties: - * - * @param {Function} [options.processHtmlNode] A visitor function which allows processing of an encountered HTML node. - * This function is called with the following arguments: - * @param {String} [options.processHtmlNode.tagText] The HTML tag text that was found. - * @param {String} [options.processHtmlNode.tagName] The tag name for the HTML tag that was found. Ex: 'a' for an anchor tag. - * @param {String} [options.processHtmlNode.isClosingTag] `true` if the tag is a closing tag (ex: </a>), `false` otherwise. - * - * @param {Function} [options.processTextNode] A visitor function which allows processing of an encountered text node. - * This function is called with the following arguments: - * @param {String} [options.processTextNode.text] The text node that was matched. - */ - parse : function( html, options ) { - options = options || {}; - - var processHtmlNodeVisitor = options.processHtmlNode || function() {}, - processTextNodeVisitor = options.processTextNode || function() {}, - htmlRegex = this.htmlRegex, - currentResult, - lastIndex = 0; - - // Loop over the HTML string, ignoring HTML tags, and processing the text that lies between them, - // wrapping the URLs in anchor tags - while( ( currentResult = htmlRegex.exec( html ) ) !== null ) { - var tagText = currentResult[ 0 ], - tagName = currentResult[ 1 ] || currentResult[ 3 ], // The tag (ex: "!DOCTYPE"), or another tag (ex: "a") - isClosingTag = !!currentResult[ 2 ], - inBetweenTagsText = html.substring( lastIndex, currentResult.index ); - - if( inBetweenTagsText ) { - processTextNodeVisitor( inBetweenTagsText ); - } - - processHtmlNodeVisitor( tagText, tagName.toLowerCase(), isClosingTag ); - - lastIndex = currentResult.index + tagText.length; - } - - // Process any remaining text after the last HTML element. Will process all of the text if there were no HTML elements. - if( lastIndex < html.length ) { - var text = html.substring( lastIndex ); - - if( text ) { - processTextNodeVisitor( text ); - } - } - } - - } ); - /*global Autolinker */ - /*jshint boss:true */ - /** - * @class Autolinker.HtmlTag - * @extends Object - * - * Represents an HTML tag, which can be used to easily build/modify HTML tags programmatically. - * - * Autolinker uses this abstraction to create HTML tags, and then write them out as strings. You may also use - * this class in your code, especially within a {@link Autolinker#replaceFn replaceFn}. - * - * ## Examples - * - * Example instantiation: - * - * var tag = new Autolinker.HtmlTag( { - * tagName : 'a', - * attrs : { 'href': 'http://google.com', 'class': 'external-link' }, - * innerHtml : 'Google' - * } ); - * - * tag.toString(); // Google - * - * // Individual accessor methods - * tag.getTagName(); // 'a' - * tag.getAttr( 'href' ); // 'http://google.com' - * tag.hasClass( 'external-link' ); // true - * - * - * Using mutator methods (which may be used in combination with instantiation config properties): - * - * var tag = new Autolinker.HtmlTag(); - * tag.setTagName( 'a' ); - * tag.setAttr( 'href', 'http://google.com' ); - * tag.addClass( 'external-link' ); - * tag.setInnerHtml( 'Google' ); - * - * tag.getTagName(); // 'a' - * tag.getAttr( 'href' ); // 'http://google.com' - * tag.hasClass( 'external-link' ); // true - * - * tag.toString(); // Google - * - * - * ## Example use within a {@link Autolinker#replaceFn replaceFn} - * - * var html = Autolinker.link( "Test google.com", { - * replaceFn : function( autolinker, match ) { - * var tag = autolinker.getTagBuilder().build( match ); // returns an {@link Autolinker.HtmlTag} instance, configured with the Match's href and anchor text - * tag.setAttr( 'rel', 'nofollow' ); - * - * return tag; - * } - * } ); - * - * // generated html: - * // Test google.com - * - * - * ## Example use with a new tag for the replacement - * - * var html = Autolinker.link( "Test google.com", { - * replaceFn : function( autolinker, match ) { - * var tag = new Autolinker.HtmlTag( { - * tagName : 'button', - * attrs : { 'title': 'Load URL: ' + match.getAnchorHref() }, - * innerHtml : 'Load URL: ' + match.getAnchorText() - * } ); - * - * return tag; - * } - * } ); - * - * // generated html: - * // Test - */ - Autolinker.HtmlTag = Autolinker.Util.extend( Object, { - - /** - * @cfg {String} tagName - * - * The tag name. Ex: 'a', 'button', etc. - * - * Not required at instantiation time, but should be set using {@link #setTagName} before {@link #toString} - * is executed. - */ - - /** - * @cfg {Object.} attrs - * - * An key/value Object (map) of attributes to create the tag with. The keys are the attribute names, and the - * values are the attribute values. - */ - - /** - * @cfg {String} innerHtml - * - * The inner HTML for the tag. - * - * Note the camel case name on `innerHtml`. Acronyms are camelCased in this utility (such as not to run into the acronym - * naming inconsistency that the DOM developers created with `XMLHttpRequest`). You may alternatively use {@link #innerHTML} - * if you prefer, but this one is recommended. - */ - - /** - * @cfg {String} innerHTML - * - * Alias of {@link #innerHtml}, accepted for consistency with the browser DOM api, but prefer the camelCased version - * for acronym names. - */ - - - /** - * @protected - * @property {RegExp} whitespaceRegex - * - * Regular expression used to match whitespace in a string of CSS classes. - */ - whitespaceRegex : /\s+/, - - - /** - * @constructor - * @param {Object} [cfg] The configuration properties for this class, in an Object (map) - */ - constructor : function( cfg ) { - Autolinker.Util.assign( this, cfg ); - - this.innerHtml = this.innerHtml || this.innerHTML; // accept either the camelCased form or the fully capitalized acronym - }, - - - /** - * Sets the tag name that will be used to generate the tag with. - * - * @param {String} tagName - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - setTagName : function( tagName ) { - this.tagName = tagName; - return this; - }, - - - /** - * Retrieves the tag name. - * - * @return {String} - */ - getTagName : function() { - return this.tagName || ""; - }, - - - /** - * Sets an attribute on the HtmlTag. - * - * @param {String} attrName The attribute name to set. - * @param {String} attrValue The attribute value to set. - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - setAttr : function( attrName, attrValue ) { - var tagAttrs = this.getAttrs(); - tagAttrs[ attrName ] = attrValue; - - return this; - }, - - - /** - * Retrieves an attribute from the HtmlTag. If the attribute does not exist, returns `undefined`. - * - * @param {String} name The attribute name to retrieve. - * @return {String} The attribute's value, or `undefined` if it does not exist on the HtmlTag. - */ - getAttr : function( attrName ) { - return this.getAttrs()[ attrName ]; - }, - - - /** - * Sets one or more attributes on the HtmlTag. - * - * @param {Object.} attrs A key/value Object (map) of the attributes to set. - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - setAttrs : function( attrs ) { - var tagAttrs = this.getAttrs(); - Autolinker.Util.assign( tagAttrs, attrs ); - - return this; - }, - - - /** - * Retrieves the attributes Object (map) for the HtmlTag. - * - * @return {Object.} A key/value object of the attributes for the HtmlTag. - */ - getAttrs : function() { - return this.attrs || ( this.attrs = {} ); - }, - - - /** - * Sets the provided `cssClass`, overwriting any current CSS classes on the HtmlTag. - * - * @param {String} cssClass One or more space-separated CSS classes to set (overwrite). - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - setClass : function( cssClass ) { - return this.setAttr( 'class', cssClass ); - }, - - - /** - * Convenience method to add one or more CSS classes to the HtmlTag. Will not add duplicate CSS classes. - * - * @param {String} cssClass One or more space-separated CSS classes to add. - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - addClass : function( cssClass ) { - var classAttr = this.getClass(), - whitespaceRegex = this.whitespaceRegex, - indexOf = Autolinker.Util.indexOf, // to support IE8 and below - classes = ( !classAttr ) ? [] : classAttr.split( whitespaceRegex ), - newClasses = cssClass.split( whitespaceRegex ), - newClass; - - while( newClass = newClasses.shift() ) { - if( indexOf( classes, newClass ) === -1 ) { - classes.push( newClass ); - } - } - - this.getAttrs()[ 'class' ] = classes.join( " " ); - return this; - }, - - - /** - * Convenience method to remove one or more CSS classes from the HtmlTag. - * - * @param {String} cssClass One or more space-separated CSS classes to remove. - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - removeClass : function( cssClass ) { - var classAttr = this.getClass(), - whitespaceRegex = this.whitespaceRegex, - indexOf = Autolinker.Util.indexOf, // to support IE8 and below - classes = ( !classAttr ) ? [] : classAttr.split( whitespaceRegex ), - removeClasses = cssClass.split( whitespaceRegex ), - removeClass; - - while( classes.length && ( removeClass = removeClasses.shift() ) ) { - var idx = indexOf( classes, removeClass ); - if( idx !== -1 ) { - classes.splice( idx, 1 ); - } - } - - this.getAttrs()[ 'class' ] = classes.join( " " ); - return this; - }, - - - /** - * Convenience method to retrieve the CSS class(es) for the HtmlTag, which will each be separated by spaces when - * there are multiple. - * - * @return {String} - */ - getClass : function() { - return this.getAttrs()[ 'class' ] || ""; - }, - - - /** - * Convenience method to check if the tag has a CSS class or not. - * - * @param {String} cssClass The CSS class to check for. - * @return {Boolean} `true` if the HtmlTag has the CSS class, `false` otherwise. - */ - hasClass : function( cssClass ) { - return ( ' ' + this.getClass() + ' ' ).indexOf( ' ' + cssClass + ' ' ) !== -1; - }, - - - /** - * Sets the inner HTML for the tag. - * - * @param {String} html The inner HTML to set. - * @return {Autolinker.HtmlTag} This HtmlTag instance, so that method calls may be chained. - */ - setInnerHtml : function( html ) { - this.innerHtml = html; - - return this; - }, - - - /** - * Retrieves the inner HTML for the tag. - * - * @return {String} - */ - getInnerHtml : function() { - return this.innerHtml || ""; - }, - - - /** - * Override of superclass method used to generate the HTML string for the tag. - * - * @return {String} - */ - toString : function() { - var tagName = this.getTagName(), - attrsStr = this.buildAttrsStr(); - - attrsStr = ( attrsStr ) ? ' ' + attrsStr : ''; // prepend a space if there are actually attributes - - return [ '<', tagName, attrsStr, '>', this.getInnerHtml(), '' ].join( "" ); - }, - - - /** - * Support method for {@link #toString}, returns the string space-separated key="value" pairs, used to populate - * the stringified HtmlTag. - * - * @protected - * @return {String} Example return: `attr1="value1" attr2="value2"` - */ - buildAttrsStr : function() { - if( !this.attrs ) return ""; // no `attrs` Object (map) has been set, return empty string - - var attrs = this.getAttrs(), - attrsArr = []; - - for( var prop in attrs ) { - if( attrs.hasOwnProperty( prop ) ) { - attrsArr.push( prop + '="' + attrs[ prop ] + '"' ); - } - } - return attrsArr.join( " " ); - } - - } ); - /*global Autolinker */ - /*jshint scripturl:true */ - /** - * @private - * @class Autolinker.MatchValidator - * @extends Object - * - * Used by Autolinker to filter out false positives from the {@link Autolinker#matcherRegex}. - * - * Due to the limitations of regular expressions (including the missing feature of look-behinds in JS regular expressions), - * we cannot always determine the validity of a given match. This class applies a bit of additional logic to filter out any - * false positives that have been matched by the {@link Autolinker#matcherRegex}. - */ - Autolinker.MatchValidator = Autolinker.Util.extend( Object, { - - /** - * @private - * @property {RegExp} invalidProtocolRelMatchRegex - * - * The regular expression used to check a potential protocol-relative URL match, coming from the - * {@link Autolinker#matcherRegex}. A protocol-relative URL is, for example, "//yahoo.com" - * - * This regular expression checks to see if there is a word character before the '//' match in order to determine if - * we should actually autolink a protocol-relative URL. This is needed because there is no negative look-behind in - * JavaScript regular expressions. - * - * For instance, we want to autolink something like "Go to: //google.com", but we don't want to autolink something - * like "abc//google.com" - */ - invalidProtocolRelMatchRegex : /^[\w]\/\//, - - /** - * Regex to test for a full protocol, with the two trailing slashes. Ex: 'http://' - * - * @private - * @property {RegExp} hasFullProtocolRegex - */ - hasFullProtocolRegex : /^[A-Za-z][-.+A-Za-z0-9]+:\/\//, - - /** - * Regex to find the URI scheme, such as 'mailto:'. - * - * This is used to filter out 'javascript:' and 'vbscript:' schemes. - * - * @private - * @property {RegExp} uriSchemeRegex - */ - uriSchemeRegex : /^[A-Za-z][-.+A-Za-z0-9]+:/, - - /** - * Regex to determine if at least one word char exists after the protocol (i.e. after the ':') - * - * @private - * @property {RegExp} hasWordCharAfterProtocolRegex - */ - hasWordCharAfterProtocolRegex : /:[^\s]*?[A-Za-z]/, - - - /** - * Determines if a given match found by {@link Autolinker#processTextNode} is valid. Will return `false` for: - * - * 1) URL matches which do not have at least have one period ('.') in the domain name (effectively skipping over - * matches like "abc:def"). However, URL matches with a protocol will be allowed (ex: 'http://localhost') - * 2) URL matches which do not have at least one word character in the domain name (effectively skipping over - * matches like "git:1.0"). - * 3) A protocol-relative url match (a URL beginning with '//') whose previous character is a word character - * (effectively skipping over strings like "abc//google.com") - * - * Otherwise, returns `true`. - * - * @param {String} urlMatch The matched URL, if there was one. Will be an empty string if the match is not a URL match. - * @param {String} protocolUrlMatch The match URL string for a protocol match. Ex: 'http://yahoo.com'. This is used to match - * something like 'http://localhost', where we won't double check that the domain name has at least one '.' in it. - * @param {String} protocolRelativeMatch The protocol-relative string for a URL match (i.e. '//'), possibly with a preceding - * character (ex, a space, such as: ' //', or a letter, such as: 'a//'). The match is invalid if there is a word character - * preceding the '//'. - * @return {Boolean} `true` if the match given is valid and should be processed, or `false` if the match is invalid and/or - * should just not be processed. - */ - isValidMatch : function( urlMatch, protocolUrlMatch, protocolRelativeMatch ) { - if( - ( protocolUrlMatch && !this.isValidUriScheme( protocolUrlMatch ) ) || - this.urlMatchDoesNotHaveProtocolOrDot( urlMatch, protocolUrlMatch ) || // At least one period ('.') must exist in the URL match for us to consider it an actual URL, *unless* it was a full protocol match (like 'http://localhost') - this.urlMatchDoesNotHaveAtLeastOneWordChar( urlMatch, protocolUrlMatch ) || // At least one letter character must exist in the domain name after a protocol match. Ex: skip over something like "git:1.0" - this.isInvalidProtocolRelativeMatch( protocolRelativeMatch ) // A protocol-relative match which has a word character in front of it (so we can skip something like "abc//google.com") - ) { - return false; - } - - return true; - }, - - - /** - * Determines if the URI scheme is a valid scheme to be autolinked. Returns `false` if the scheme is - * 'javascript:' or 'vbscript:' - * - * @private - * @param {String} uriSchemeMatch The match URL string for a full URI scheme match. Ex: 'http://yahoo.com' - * or 'mailto:a@a.com'. - * @return {Boolean} `true` if the scheme is a valid one, `false` otherwise. - */ - isValidUriScheme : function( uriSchemeMatch ) { - var uriScheme = uriSchemeMatch.match( this.uriSchemeRegex )[ 0 ]; - - return ( uriScheme !== 'javascript:' && uriScheme !== 'vbscript:' ); - }, - - - /** - * Determines if a URL match does not have either: - * - * a) a full protocol (i.e. 'http://'), or - * b) at least one dot ('.') in the domain name (for a non-full-protocol match). - * - * Either situation is considered an invalid URL (ex: 'git:d' does not have either the '://' part, or at least one dot - * in the domain name. If the match was 'git:abc.com', we would consider this valid.) - * - * @private - * @param {String} urlMatch The matched URL, if there was one. Will be an empty string if the match is not a URL match. - * @param {String} protocolUrlMatch The match URL string for a protocol match. Ex: 'http://yahoo.com'. This is used to match - * something like 'http://localhost', where we won't double check that the domain name has at least one '.' in it. - * @return {Boolean} `true` if the URL match does not have a full protocol, or at least one dot ('.') in a non-full-protocol - * match. - */ - urlMatchDoesNotHaveProtocolOrDot : function( urlMatch, protocolUrlMatch ) { - return ( !!urlMatch && ( !protocolUrlMatch || !this.hasFullProtocolRegex.test( protocolUrlMatch ) ) && urlMatch.indexOf( '.' ) === -1 ); - }, - - - /** - * Determines if a URL match does not have at least one word character after the protocol (i.e. in the domain name). - * - * At least one letter character must exist in the domain name after a protocol match. Ex: skip over something - * like "git:1.0" - * - * @private - * @param {String} urlMatch The matched URL, if there was one. Will be an empty string if the match is not a URL match. - * @param {String} protocolUrlMatch The match URL string for a protocol match. Ex: 'http://yahoo.com'. This is used to - * know whether or not we have a protocol in the URL string, in order to check for a word character after the protocol - * separator (':'). - * @return {Boolean} `true` if the URL match does not have at least one word character in it after the protocol, `false` - * otherwise. - */ - urlMatchDoesNotHaveAtLeastOneWordChar : function( urlMatch, protocolUrlMatch ) { - if( urlMatch && protocolUrlMatch ) { - return !this.hasWordCharAfterProtocolRegex.test( urlMatch ); - } else { - return false; - } - }, - - - /** - * Determines if a protocol-relative match is an invalid one. This method returns `true` if there is a `protocolRelativeMatch`, - * and that match contains a word character before the '//' (i.e. it must contain whitespace or nothing before the '//' in - * order to be considered valid). - * - * @private - * @param {String} protocolRelativeMatch The protocol-relative string for a URL match (i.e. '//'), possibly with a preceding - * character (ex, a space, such as: ' //', or a letter, such as: 'a//'). The match is invalid if there is a word character - * preceding the '//'. - * @return {Boolean} `true` if it is an invalid protocol-relative match, `false` otherwise. - */ - isInvalidProtocolRelativeMatch : function( protocolRelativeMatch ) { - return ( !!protocolRelativeMatch && this.invalidProtocolRelMatchRegex.test( protocolRelativeMatch ) ); - } - - } ); - /*global Autolinker */ - /*jshint sub:true */ - /** - * @protected - * @class Autolinker.AnchorTagBuilder - * @extends Object - * - * Builds anchor (<a>) tags for the Autolinker utility when a match is found. - * - * Normally this class is instantiated, configured, and used internally by an {@link Autolinker} instance, but may - * actually be retrieved in a {@link Autolinker#replaceFn replaceFn} to create {@link Autolinker.HtmlTag HtmlTag} instances - * which may be modified before returning from the {@link Autolinker#replaceFn replaceFn}. For example: - * - * var html = Autolinker.link( "Test google.com", { - * replaceFn : function( autolinker, match ) { - * var tag = autolinker.getTagBuilder().build( match ); // returns an {@link Autolinker.HtmlTag} instance - * tag.setAttr( 'rel', 'nofollow' ); - * - * return tag; - * } - * } ); - * - * // generated html: - * // Test google.com - */ - Autolinker.AnchorTagBuilder = Autolinker.Util.extend( Object, { - - /** - * @cfg {Boolean} newWindow - * @inheritdoc Autolinker#newWindow - */ - - /** - * @cfg {Number} truncate - * @inheritdoc Autolinker#truncate - */ - - /** - * @cfg {String} className - * @inheritdoc Autolinker#className - */ - - - /** - * @constructor - * @param {Object} [cfg] The configuration options for the AnchorTagBuilder instance, specified in an Object (map). - */ - constructor : function( cfg ) { - Autolinker.Util.assign( this, cfg ); - }, - - - /** - * Generates the actual anchor (<a>) tag to use in place of the matched URL/email/Twitter text, - * via its `match` object. - * - * @param {Autolinker.match.Match} match The Match instance to generate an anchor tag from. - * @return {Autolinker.HtmlTag} The HtmlTag instance for the anchor tag. - */ - build : function( match ) { - var tag = new Autolinker.HtmlTag( { - tagName : 'a', - attrs : this.createAttrs( match.getType(), match.getAnchorHref() ), - innerHtml : this.processAnchorText( match.getAnchorText() ) - } ); - - return tag; - }, - - - /** - * Creates the Object (map) of the HTML attributes for the anchor (<a>) tag being generated. - * - * @protected - * @param {"url"/"email"/"twitter"} matchType The type of match that an anchor tag is being generated for. - * @param {String} href The href for the anchor tag. - * @return {Object} A key/value Object (map) of the anchor tag's attributes. - */ - createAttrs : function( matchType, anchorHref ) { - var attrs = { - 'href' : anchorHref // we'll always have the `href` attribute - }; - - var cssClass = this.createCssClass( matchType ); - if( cssClass ) { - attrs[ 'class' ] = cssClass; - } - if( this.newWindow ) { - attrs[ 'target' ] = "_blank"; - } - - return attrs; - }, - - - /** - * Creates the CSS class that will be used for a given anchor tag, based on the `matchType` and the {@link #className} - * config. - * - * @private - * @param {"url"/"email"/"twitter"} matchType The type of match that an anchor tag is being generated for. - * @return {String} The CSS class string for the link. Example return: "myLink myLink-url". If no {@link #className} - * was configured, returns an empty string. - */ - createCssClass : function( matchType ) { - var className = this.className; - - if( !className ) - return ""; - else - return className + " " + className + "-" + matchType; // ex: "myLink myLink-url", "myLink myLink-email", or "myLink myLink-twitter" - }, - - - /** - * Processes the `anchorText` by truncating the text according to the {@link #truncate} config. - * - * @private - * @param {String} anchorText The anchor tag's text (i.e. what will be displayed). - * @return {String} The processed `anchorText`. - */ - processAnchorText : function( anchorText ) { - anchorText = this.doTruncate( anchorText ); - - return anchorText; - }, - - - /** - * Performs the truncation of the `anchorText`, if the `anchorText` is longer than the {@link #truncate} option. - * Truncates the text to 2 characters fewer than the {@link #truncate} option, and adds ".." to the end. - * - * @private - * @param {String} text The anchor tag's text (i.e. what will be displayed). - * @return {String} The truncated anchor text. - */ - doTruncate : function( anchorText ) { - return Autolinker.Util.ellipsis( anchorText, this.truncate || Number.POSITIVE_INFINITY ); - } - - } ); - /*global Autolinker */ - /** - * @abstract - * @class Autolinker.match.Match - * - * Represents a match found in an input string which should be Autolinked. A Match object is what is provided in a - * {@link Autolinker#replaceFn replaceFn}, and may be used to query for details about the match. - * - * For example: - * - * var input = "..."; // string with URLs, Email Addresses, and Twitter Handles - * - * var linkedText = Autolinker.link( input, { - * replaceFn : function( autolinker, match ) { - * console.log( "href = ", match.getAnchorHref() ); - * console.log( "text = ", match.getAnchorText() ); - * - * switch( match.getType() ) { - * case 'url' : - * console.log( "url: ", match.getUrl() ); - * - * case 'email' : - * console.log( "email: ", match.getEmail() ); - * - * case 'twitter' : - * console.log( "twitter: ", match.getTwitterHandle() ); - * } - * } - * } ); - * - * See the {@link Autolinker} class for more details on using the {@link Autolinker#replaceFn replaceFn}. - */ - Autolinker.match.Match = Autolinker.Util.extend( Object, { - - /** - * @cfg {String} matchedText (required) - * - * The original text that was matched. - */ - - - /** - * @constructor - * @param {Object} cfg The configuration properties for the Match instance, specified in an Object (map). - */ - constructor : function( cfg ) { - Autolinker.Util.assign( this, cfg ); - }, - - - /** - * Returns a string name for the type of match that this class represents. - * - * @abstract - * @return {String} - */ - getType : Autolinker.Util.abstractMethod, - - - /** - * Returns the original text that was matched. - * - * @return {String} - */ - getMatchedText : function() { - return this.matchedText; - }, - - - /** - * Returns the anchor href that should be generated for the match. - * - * @abstract - * @return {String} - */ - getAnchorHref : Autolinker.Util.abstractMethod, - - - /** - * Returns the anchor text that should be generated for the match. - * - * @abstract - * @return {String} - */ - getAnchorText : Autolinker.Util.abstractMethod - - } ); - /*global Autolinker */ - /** - * @class Autolinker.match.Email - * @extends Autolinker.match.Match - * - * Represents a Email match found in an input string which should be Autolinked. - * - * See this class's superclass ({@link Autolinker.match.Match}) for more details. - */ - Autolinker.match.Email = Autolinker.Util.extend( Autolinker.match.Match, { - - /** - * @cfg {String} email (required) - * - * The email address that was matched. - */ - - - /** - * Returns a string name for the type of match that this class represents. - * - * @return {String} - */ - getType : function() { - return 'email'; - }, - - - /** - * Returns the email address that was matched. - * - * @return {String} - */ - getEmail : function() { - return this.email; - }, - - - /** - * Returns the anchor href that should be generated for the match. - * - * @return {String} - */ - getAnchorHref : function() { - return 'mailto:' + this.email; - }, - - - /** - * Returns the anchor text that should be generated for the match. - * - * @return {String} - */ - getAnchorText : function() { - return this.email; - } - - } ); - /*global Autolinker */ - /** - * @class Autolinker.match.Twitter - * @extends Autolinker.match.Match - * - * Represents a Twitter match found in an input string which should be Autolinked. - * - * See this class's superclass ({@link Autolinker.match.Match}) for more details. - */ - Autolinker.match.Twitter = Autolinker.Util.extend( Autolinker.match.Match, { - - /** - * @cfg {String} twitterHandle (required) - * - * The Twitter handle that was matched. - */ - - - /** - * Returns the type of match that this class represents. - * - * @return {String} - */ - getType : function() { - return 'twitter'; - }, - - - /** - * Returns a string name for the type of match that this class represents. - * - * @return {String} - */ - getTwitterHandle : function() { - return this.twitterHandle; - }, - - - /** - * Returns the anchor href that should be generated for the match. - * - * @return {String} - */ - getAnchorHref : function() { - return 'https://twitter.com/' + this.twitterHandle; - }, - - - /** - * Returns the anchor text that should be generated for the match. - * - * @return {String} - */ - getAnchorText : function() { - return '@' + this.twitterHandle; - } - - } ); - /*global Autolinker */ - /** - * @class Autolinker.match.Url - * @extends Autolinker.match.Match - * - * Represents a Url match found in an input string which should be Autolinked. - * - * See this class's superclass ({@link Autolinker.match.Match}) for more details. - */ - Autolinker.match.Url = Autolinker.Util.extend( Autolinker.match.Match, { - - /** - * @cfg {String} url (required) - * - * The url that was matched. - */ - - /** - * @cfg {Boolean} protocolUrlMatch (required) - * - * `true` if the URL is a match which already has a protocol (i.e. 'http://'), `false` if the match was from a 'www' or - * known TLD match. - */ - - /** - * @cfg {Boolean} protocolRelativeMatch (required) - * - * `true` if the URL is a protocol-relative match. A protocol-relative match is a URL that starts with '//', - * and will be either http:// or https:// based on the protocol that the site is loaded under. - */ - - /** - * @cfg {Boolean} stripPrefix (required) - * @inheritdoc Autolinker#stripPrefix - */ - - - /** - * @private - * @property {RegExp} urlPrefixRegex - * - * A regular expression used to remove the 'http://' or 'https://' and/or the 'www.' from URLs. - */ - urlPrefixRegex: /^(https?:\/\/)?(www\.)?/i, - - /** - * @private - * @property {RegExp} protocolRelativeRegex - * - * The regular expression used to remove the protocol-relative '//' from the {@link #url} string, for purposes - * of {@link #getAnchorText}. A protocol-relative URL is, for example, "//yahoo.com" - */ - protocolRelativeRegex : /^\/\//, - - /** - * @private - * @property {Boolean} protocolPrepended - * - * Will be set to `true` if the 'http://' protocol has been prepended to the {@link #url} (because the - * {@link #url} did not have a protocol) - */ - protocolPrepended : false, - - - /** - * Returns a string name for the type of match that this class represents. - * - * @return {String} - */ - getType : function() { - return 'url'; - }, - - - /** - * Returns the url that was matched, assuming the protocol to be 'http://' if the original - * match was missing a protocol. - * - * @return {String} - */ - getUrl : function() { - var url = this.url; - - // if the url string doesn't begin with a protocol, assume 'http://' - if( !this.protocolRelativeMatch && !this.protocolUrlMatch && !this.protocolPrepended ) { - url = this.url = 'http://' + url; - - this.protocolPrepended = true; - } - - return url; - }, - - - /** - * Returns the anchor href that should be generated for the match. - * - * @return {String} - */ - getAnchorHref : function() { - var url = this.getUrl(); - - return url.replace( /&/g, '&' ); // any &'s in the URL should be converted back to '&' if they were displayed as & in the source html - }, - - - /** - * Returns the anchor text that should be generated for the match. - * - * @return {String} - */ - getAnchorText : function() { - var anchorText = this.getUrl(); - - if( this.protocolRelativeMatch ) { - // Strip off any protocol-relative '//' from the anchor text - anchorText = this.stripProtocolRelativePrefix( anchorText ); - } - if( this.stripPrefix ) { - anchorText = this.stripUrlPrefix( anchorText ); - } - anchorText = this.removeTrailingSlash( anchorText ); // remove trailing slash, if there is one - - return anchorText; - }, - - - // --------------------------------------- - - // Utility Functionality - - /** - * Strips the URL prefix (such as "http://" or "https://") from the given text. - * - * @private - * @param {String} text The text of the anchor that is being generated, for which to strip off the - * url prefix (such as stripping off "http://") - * @return {String} The `anchorText`, with the prefix stripped. - */ - stripUrlPrefix : function( text ) { - return text.replace( this.urlPrefixRegex, '' ); - }, - - - /** - * Strips any protocol-relative '//' from the anchor text. - * - * @private - * @param {String} text The text of the anchor that is being generated, for which to strip off the - * protocol-relative prefix (such as stripping off "//") - * @return {String} The `anchorText`, with the protocol-relative prefix stripped. - */ - stripProtocolRelativePrefix : function( text ) { - return text.replace( this.protocolRelativeRegex, '' ); - }, - - - /** - * Removes any trailing slash from the given `anchorText`, in preparation for the text to be displayed. - * - * @private - * @param {String} anchorText The text of the anchor that is being generated, for which to remove any trailing - * slash ('/') that may exist. - * @return {String} The `anchorText`, with the trailing slash removed. - */ - removeTrailingSlash : function( anchorText ) { - if( anchorText.charAt( anchorText.length - 1 ) === '/' ) { - anchorText = anchorText.slice( 0, -1 ); - } - return anchorText; - } - - } ); - - return Autolinker; - - -})); - -},{}],51:[function(require,module,exports){ +'use strict'; + + +//////////////////////////////////////////////////////////////////////////////// +// Helpers + +// Merge objects +// +function assign(obj /*from1, from2, from3, ...*/) { + var sources = Array.prototype.slice.call(arguments, 1); + + sources.forEach(function (source) { + if (!source) { return; } + + Object.keys(source).forEach(function (key) { + obj[key] = source[key]; + }); + }); + + return obj; +} + +function _class(obj) { return Object.prototype.toString.call(obj); } +function isString(obj) { return _class(obj) === '[object String]'; } +function isObject(obj) { return _class(obj) === '[object Object]'; } +function isRegExp(obj) { return _class(obj) === '[object RegExp]'; } +function isFunction(obj) { return _class(obj) === '[object Function]'; } + + +function escapeRE (str) { return str.replace(/[.?*+^$[\]\\(){}|-]/g, '\\$&'); } + +//////////////////////////////////////////////////////////////////////////////// + + +var defaultSchemas = { + 'http:': { + validate: function (text, pos, self) { + var tail = text.slice(pos); + + if (!self.re.http) { + // compile lazily, because "host"-containing variables can change on tlds update. + self.re.http = new RegExp( + '^\\/\\/' + self.re.src_auth + self.re.src_host_port_strict + self.re.src_path, 'i' + ); + } + if (self.re.http.test(tail)) { + return tail.match(self.re.http)[0].length; + } + return 0; + } + }, + 'https:': 'http:', + 'ftp:': 'http:', + '//': { + validate: function (text, pos, self) { + var tail = text.slice(pos); + + if (!self.re.no_http) { + // compile lazily, becayse "host"-containing variables can change on tlds update. + self.re.no_http = new RegExp( + '^' + self.re.src_auth + self.re.src_host_port_strict + self.re.src_path, 'i' + ); + } + + if (self.re.no_http.test(tail)) { + // should not be `://`, that protects from errors in protocol name + if (pos >= 3 && text[pos - 3] === ':') { return 0; } + return tail.match(self.re.no_http)[0].length; + } + return 0; + } + }, + 'mailto:': { + validate: function (text, pos, self) { + var tail = text.slice(pos); + + if (!self.re.mailto) { + self.re.mailto = new RegExp( + '^' + self.re.src_email_name + '@' + self.re.src_host_strict, 'i' + ); + } + if (self.re.mailto.test(tail)) { + return tail.match(self.re.mailto)[0].length; + } + return 0; + } + } +}; + +// DON'T try to make PRs with changes. Extend TLDs with LinkifyIt.tlds() instead +var tlds_default = 'biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф'.split('|'); + +//////////////////////////////////////////////////////////////////////////////// + +function resetScanCache(self) { + self.__index__ = -1; + self.__text_cache__ = ''; +} + +function createValidator(re) { + return function (text, pos) { + var tail = text.slice(pos); + + if (re.test(tail)) { + return tail.match(re)[0].length; + } + return 0; + }; +} + +function createNormalizer() { + return function (match, self) { + self.normalize(match); + }; +} + +// Schemas compiler. Build regexps. +// +function compile(self) { + + // Load & clone RE patterns. + var re = self.re = assign({}, require('./lib/re')); + + // Define dynamic patterns + var tlds = self.__tlds__.slice(); + + if (!self.__tlds_replaced__) { + tlds.push('[a-z]{2}'); + } + tlds.push(re.src_xn); + + re.src_tlds = tlds.join('|'); + + function untpl(tpl) { return tpl.replace('%TLDS%', re.src_tlds); } + + re.email_fuzzy = RegExp(untpl(re.tpl_email_fuzzy), 'i'); + re.link_fuzzy = RegExp(untpl(re.tpl_link_fuzzy), 'i'); + re.host_fuzzy_test = RegExp(untpl(re.tpl_host_fuzzy_test), 'i'); + + // + // Compile each schema + // + + var aliases = []; + + self.__compiled__ = {}; // Reset compiled data + + function schemaError(name, val) { + throw new Error('(LinkifyIt) Invalid schema "' + name + '": ' + val); + } + + Object.keys(self.__schemas__).forEach(function (name) { + var val = self.__schemas__[name]; + + // skip disabled methods + if (val === null) { return; } + + var compiled = { validate: null, link: null }; + + self.__compiled__[name] = compiled; + + if (isObject(val)) { + if (isRegExp(val.validate)) { + compiled.validate = createValidator(val.validate); + } else if (isFunction(val.validate)) { + compiled.validate = val.validate; + } else { + schemaError(name, val); + } + + if (isFunction(val.normalize)) { + compiled.normalize = val.normalize; + } else if (!val.normalize) { + compiled.normalize = createNormalizer(); + } else { + schemaError(name, val); + } + + return; + } + + if (isString(val)) { + aliases.push(name); + return; + } + + schemaError(name, val); + }); + + // + // Compile postponed aliases + // + + aliases.forEach(function (alias) { + if (!self.__compiled__[self.__schemas__[alias]]) { + // Silently fail on missed schemas to avoid errons on disable. + // schemaError(alias, self.__schemas__[alias]); + return; + } + + self.__compiled__[alias].validate = + self.__compiled__[self.__schemas__[alias]].validate; + self.__compiled__[alias].normalize = + self.__compiled__[self.__schemas__[alias]].normalize; + }); + + // + // Fake record for guessed links + // + self.__compiled__[''] = { validate: null, normalize: createNormalizer() }; + + // + // Build schema condition + // + var slist = Object.keys(self.__compiled__) + .filter(function(name) { + // Filter disabled & fake schemas + return name.length > 0 && self.__compiled__[name]; + }) + .map(escapeRE) + .join('|'); + // (?!_) cause 1.5x slowdown + self.re.schema_test = RegExp('(^|(?!_)(?:>|' + re.src_ZPCcCf + '))(' + slist + ')', 'i'); + self.re.schema_search = RegExp('(^|(?!_)(?:>|' + re.src_ZPCcCf + '))(' + slist + ')', 'ig'); + + // + // Cleanup + // + + resetScanCache(self); +} + +/** + * class Match + * + * Match result. Single element of array, returned by [[LinkifyIt#match]] + **/ +function Match(self, shift) { + var start = self.__index__, + end = self.__last_index__, + text = self.__text_cache__.slice(start, end); + + /** + * Match#schema -> String + * + * Prefix (protocol) for matched string. + **/ + this.schema = self.__schema__.toLowerCase(); + /** + * Match#index -> Number + * + * First position of matched string. + **/ + this.index = start + shift; + /** + * Match#lastIndex -> Number + * + * Next position after matched string. + **/ + this.lastIndex = end + shift; + /** + * Match#raw -> String + * + * Matched string. + **/ + this.raw = text; + /** + * Match#text -> String + * + * Notmalized text of matched string. + **/ + this.text = text; + /** + * Match#url -> String + * + * Normalized url of matched string. + **/ + this.url = text; +} + +function createMatch(self, shift) { + var match = new Match(self, shift); + + self.__compiled__[match.schema].normalize(match, self); + + return match; +} + + +/** + * class LinkifyIt + **/ + +/** + * new LinkifyIt(schemas) + * - schemas (Object): Optional. Additional schemas to validate (prefix/validator) + * + * Creates new linkifier instance with optional additional schemas. + * Can be called without `new` keyword for convenience. + * + * By default understands: + * + * - `http(s)://...` , `ftp://...`, `mailto:...` & `//...` links + * - "fuzzy" links and emails (example.com, foo@bar.com). + * + * `schemas` is an object, where each key/value describes protocol/rule: + * + * - __key__ - link prefix (usually, protocol name with `:` at the end, `skype:` + * for example). `linkify-it` makes shure that prefix is not preceeded with + * alphanumeric char and symbols. Only whitespaces and punctuation allowed. + * - __value__ - rule to check tail after link prefix + * - _String_ - just alias to existing rule + * - _Object_ + * - _validate_ - validator function (should return matched length on success), + * or `RegExp`. + * - _normalize_ - optional function to normalize text & url of matched result + * (for example, for @twitter mentions). + **/ +function LinkifyIt(schemas) { + if (!(this instanceof LinkifyIt)) { + return new LinkifyIt(schemas); + } + + // Cache last tested result. Used to skip repeating steps on next `match` call. + this.__index__ = -1; + this.__last_index__ = -1; // Next scan position + this.__schema__ = ''; + this.__text_cache__ = ''; + + this.__schemas__ = assign({}, defaultSchemas, schemas); + this.__compiled__ = {}; + + this.__tlds__ = tlds_default; + this.__tlds_replaced__ = false; + + this.re = {}; + + compile(this); +} + + +/** chainable + * LinkifyIt#add(schema, definition) + * - schema (String): rule name (fixed pattern prefix) + * - definition (String|RegExp|Object): schema definition + * + * Add new rule definition. See constructor description for details. + **/ +LinkifyIt.prototype.add = function add(schema, definition) { + this.__schemas__[schema] = definition; + compile(this); + return this; +}; + + +/** + * LinkifyIt#test(text) -> Boolean + * + * Searches linkifiable pattern and returns `true` on success or `false` on fail. + **/ +LinkifyIt.prototype.test = function test(text) { + // Reset scan cache + this.__text_cache__ = text; + this.__index__ = -1; + + if (!text.length) { return false; } + + var m, ml, me, len, shift, next, re, tld_pos, at_pos; + + // try to scan for link with schema - that's the most simple rule + if (this.re.schema_test.test(text)) { + re = this.re.schema_search; + re.lastIndex = 0; + while ((m = re.exec(text)) !== null) { + len = this.testSchemaAt(text, m[2], re.lastIndex); + if (len) { + this.__schema__ = m[2]; + this.__index__ = m.index + m[1].length; + this.__last_index__ = m.index + m[0].length + len; + break; + } + } + } + + if (this.__compiled__['http:']) { + // guess schemaless links + tld_pos = text.search(this.re.host_fuzzy_test); + if (tld_pos >= 0) { + // if tld is located after found link - no need to check fuzzy pattern + if (this.__index__ < 0 || tld_pos < this.__index__) { + if ((ml = text.match(this.re.link_fuzzy)) !== null) { + + shift = ml.index + ml[1].length; + + if (this.__index__ < 0 || shift < this.__index__) { + this.__schema__ = ''; + this.__index__ = shift; + this.__last_index__ = ml.index + ml[0].length; + } + } + } + } + } + + if (this.__compiled__['mailto:']) { + // guess schemaless emails + at_pos = text.indexOf('@'); + if (at_pos >= 0) { + // We can't skip this check, because this cases are possible: + // 192.168.1.1@gmail.com, my.in@example.com + if ((me = text.match(this.re.email_fuzzy)) !== null) { + + shift = me.index + me[1].length; + next = me.index + me[0].length; + + if (this.__index__ < 0 || shift < this.__index__ || + (shift === this.__index__ && next > this.__last_index__)) { + this.__schema__ = 'mailto:'; + this.__index__ = shift; + this.__last_index__ = next; + } + } + } + } + + return this.__index__ >= 0; +}; + + +/** + * LinkifyIt#testSchemaAt(text, name, position) -> Number + * - text (String): text to scan + * - name (String): rule (schema) name + * - position (Number): text offset to check from + * + * Similar to [[LinkifyIt#test]] but checks only specific protocol tail exactly + * at given position. Returns length of found pattern (0 on fail). + **/ +LinkifyIt.prototype.testSchemaAt = function testSchemaAt(text, schema, pos) { + // If not supported schema check requested - terminate + if (!this.__compiled__[schema.toLowerCase()]) { + return 0; + } + return this.__compiled__[schema.toLowerCase()].validate(text, pos, this); +}; + + +/** + * LinkifyIt#match(text) -> Array|null + * + * Returns array of found link descriptions or `null` on fail. We strongly + * to use [[LinkifyIt#test]] first, for best speed. + * + * ##### Result match description + * + * - __schema__ - link schema, can be empty for fuzzy links, or `//` for + * protocol-neutral links. + * - __index__ - offset of matched text + * - __lastIndex__ - index of next char after mathch end + * - __raw__ - matched text + * - __text__ - normalized text + * - __url__ - link, generated from matched text + **/ +LinkifyIt.prototype.match = function match(text) { + var shift = 0, result = []; + + // Try to take previous element from cache, if .test() called before + if (this.__index__ >= 0 && this.__text_cache__ === text) { + result.push(createMatch(this, shift)); + shift = this.__last_index__; + } + + // Cut head if cache was used + var tail = shift ? text.slice(shift) : text; + + // Scan string until end reached + while (this.test(tail)) { + result.push(createMatch(this, shift)); + + tail = tail.slice(this.__last_index__); + shift += this.__last_index__; + } + + if (result.length) { + return result; + } + + return null; +}; + + +/** chainable + * LinkifyIt#tlds(list [, keepOld]) -> this + * - list (Array): list of tlds + * - keepOld (Boolean): merge with current list if `true` (`false` by default) + * + * Load (or merge) new tlds list. Those are user for fuzzy links (without prefix) + * to avoid false positives. By default this algorythm used: + * + * - hostname with any 2-letter root zones are ok. + * - biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф + * are ok. + * - encoded (`xn--...`) root zones are ok. + * + * If list is replaced, then exact match for 2-chars root zones will be checked. + **/ +LinkifyIt.prototype.tlds = function tlds(list, keepOld) { + list = Array.isArray(list) ? list : [ list ]; + + if (!keepOld) { + this.__tlds__ = list.slice(); + this.__tlds_replaced__ = true; + compile(this); + return this; + } + + this.__tlds__ = this.__tlds__.concat(list) + .sort() + .filter(function(el, idx, arr) { + return el !== arr[idx - 1]; + }) + .reverse(); + + compile(this); + return this; +}; + +/** + * LinkifyIt#normalize(match) + * + * Default normalizer (if schema does not define it's own). + **/ +LinkifyIt.prototype.normalize = function normalize(match) { + + // Do minimal possible changes by default. Need to collect feedback prior + // to move forward https://github.com/markdown-it/linkify-it/issues/1 + + if (!match.schema) { match.url = 'http://' + match.url; } + + if (match.schema === 'mailto:' && !/^mailto:/i.test(match.url)) { + match.url = 'mailto:' + match.url; + } +}; + + +module.exports = LinkifyIt; + +},{"./lib/re":51}],51:[function(require,module,exports){ +'use strict'; + +// Use direct extract instead of `regenerate` to reduse browserified size +var src_Any = exports.src_Any = require('uc.micro/properties/Any/regex').source; +var src_Cc = exports.src_Cc = require('uc.micro/categories/Cc/regex').source; +var src_Cf = exports.src_Cf = require('uc.micro/categories/Cf/regex').source; +var src_Z = exports.src_Z = require('uc.micro/categories/Z/regex').source; +var src_P = exports.src_P = require('uc.micro/categories/P/regex').source; + +// \p{\Z\P\Cc\CF} (white spaces + control + format + punctuation) +var src_ZPCcCf = exports.src_ZPCcCf = [ src_Z, src_P, src_Cc, src_Cf ].join('|'); + +// All possible word characters (everything without punctuation, spaces & controls) +// Defined via punctuation & spaces to save space +// Should be something like \p{\L\N\S\M} (\w but without `_`) +var src_pseudo_letter = '(?:(?!' + src_ZPCcCf + ')' + src_Any + ')'; +// The same as abothe but without [0-9] +var src_pseudo_letter_non_d = '(?:(?![0-9]|' + src_ZPCcCf + ')' + src_Any + ')'; + +//////////////////////////////////////////////////////////////////////////////// + +var src_ip4 = exports.src_ip4 = + + '(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)'; + +exports.src_auth = '(?:(?:(?!' + src_Z + ').)+@)?'; + +var src_port = exports.src_port = + + '(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?'; + +var src_host_terminator = exports.src_host_terminator = + + '(?=$|' + src_ZPCcCf + ')(?!-|_|:\\d|\\.-|\\.(?!$|' + src_ZPCcCf + '))'; + +var src_path = exports.src_path = + + '(?:' + + '[/?#]' + + '(?:' + + '(?!' + src_Z + '|[()[\\]{}.,"\'?!\\-]).|' + + '\\[(?:(?!' + src_Z + '|\\]).)*\\]|' + + '\\((?:(?!' + src_Z + '|[)]).)*\\)|' + + '\\{(?:(?!' + src_Z + '|[}]).)*\\}|' + + '\\"(?:(?!' + src_Z + '|["]).)+\\"|' + + "\\'(?:(?!" + src_Z + "|[']).)+\\'|" + + "\\'(?=" + src_pseudo_letter + ').|' + // allow `I'm_king` if no pair found + '\\.(?!' + src_Z + '|[.]).|' + + '\\-(?!' + src_Z + '|--(?:[^-]|$))(?:[-]+|.)|' + // `---` => long dash, terminate + '\\,(?!' + src_Z + ').|' + // allow `,,,` in paths + '\\!(?!' + src_Z + '|[!]).|' + + '\\?(?!' + src_Z + '|[?]).' + + ')+' + + '|\\/' + + ')?'; + +var src_email_name = exports.src_email_name = + + '[\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]+'; + +var src_xn = exports.src_xn = + + 'xn--[a-z0-9\\-]{1,59}'; + +// More to read about domain names +// http://serverfault.com/questions/638260/ + +var src_domain_root = exports.src_domain_root = + + // Can't have digits and dashes + '(?:' + + src_xn + + '|' + + src_pseudo_letter_non_d + '{1,63}' + + ')'; + +var src_domain = exports.src_domain = + + '(?:' + + src_xn + + '|' + + '(?:' + src_pseudo_letter + ')' + + '|' + + // don't allow `--` in domain names, because: + // - that can conflict with markdown — / – + // - nobody use those anyway + '(?:' + src_pseudo_letter + '(?:-(?!-)|' + src_pseudo_letter + '){0,61}' + src_pseudo_letter + ')' + + ')'; + +var src_host = exports.src_host = + + '(?:' + + src_ip4 + + '|' + + '(?:(?:(?:' + src_domain + ')\\.)*' + src_domain_root + ')' + + ')'; + +var tpl_host_fuzzy = exports.tpl_host_fuzzy = + + '(?:' + + src_ip4 + + '|' + + '(?:(?:(?:' + src_domain + ')\\.)+(?:%TLDS%))' + + ')'; + +exports.src_host_strict = + + src_host + src_host_terminator; + +var tpl_host_fuzzy_strict = exports.tpl_host_fuzzy_strict = + + tpl_host_fuzzy + src_host_terminator; + +exports.src_host_port_strict = + + src_host + src_port + src_host_terminator; + +var tpl_host_port_fuzzy_strict = exports.tpl_host_port_fuzzy_strict = + + tpl_host_fuzzy + src_port + src_host_terminator; + +//////////////////////////////////////////////////////////////////////////////// +// Main rules + +// Rude test fuzzy links by host, for quick deny +exports.tpl_host_fuzzy_test = + + 'localhost|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:' + src_ZPCcCf + '|$))'; + +exports.tpl_email_fuzzy = + + '(^|>|' + src_Z + ')(' + src_email_name + '@' + tpl_host_fuzzy_strict + ')'; + +exports.tpl_link_fuzzy = + // Fuzzy link can't be prepended with .:/\- and non punctuation. + // but can start with > (markdown blockquote) + '(^|(?![.:/\\-_@])(?:[$+<=>^`|]|' + src_ZPCcCf + '))' + + '((?![$+<=>^`|])' + tpl_host_port_fuzzy_strict + src_path + ')'; + +},{"uc.micro/categories/Cc/regex":53,"uc.micro/categories/Cf/regex":54,"uc.micro/categories/P/regex":55,"uc.micro/categories/Z/regex":56,"uc.micro/properties/Any/regex":57}],52:[function(require,module,exports){ + +'use strict'; + + +var encodeCache = {}; + + +// Create a lookup array where anything but characters in `chars` string +// and alphanumeric chars is percent-encoded. +// +function getEncodeCache(exclude) { + var i, ch, cache = encodeCache[exclude]; + if (cache) { return cache; } + + cache = encodeCache[exclude] = []; + + for (i = 0; i < 128; i++) { + ch = String.fromCharCode(i); + + if (/^[0-9a-z]$/i.test(ch)) { + // always allow unencoded alphanumeric characters + cache.push(ch); + } else { + cache.push('%' + ('0' + i.toString(16).toUpperCase()).slice(-2)); + } + } + + for (i = 0; i < exclude.length; i++) { + cache[exclude.charCodeAt(i)] = exclude[i]; + } + + return cache; +} + + +// Encode unsafe characters with percent-encoding, skipping already +// encoded sequences. +// +// - string - string to encode +// - exclude - list of characters to ignore (in addition to a-zA-Z0-9) +// - keepEscaped - don't encode '%' in a correct escape sequence (default: true) +// +function encode(string, exclude, keepEscaped) { + var i, l, code, nextCode, cache, + result = ''; + + if (typeof exclude !== 'string') { + // encode(string, keepEscaped) + keepEscaped = exclude; + exclude = encode.defaultChars; + } + + if (typeof keepEscaped === 'undefined') { + keepEscaped = true; + } + + cache = getEncodeCache(exclude); + + for (i = 0, l = string.length; i < l; i++) { + code = string.charCodeAt(i); + + if (keepEscaped && code === 0x25 /* % */ && i + 2 < l) { + if (/^[0-9a-f]{2}$/i.test(string.slice(i + 1, i + 3))) { + result += string.slice(i, i + 3); + i += 2; + continue; + } + } + + if (code < 128) { + result += cache[code]; + continue; + } + + if (code >= 0xD800 && code <= 0xDFFF) { + if (code >= 0xD800 && code <= 0xDBFF && i + 1 < l) { + nextCode = string.charCodeAt(i + 1); + if (nextCode >= 0xDC00 && nextCode <= 0xDFFF) { + result += encodeURIComponent(string[i] + string[i + 1]); + i++; + continue; + } + } + result += '%EF%BF%BD'; + continue; + } + + result += encodeURIComponent(string[i]); + } + + return result; +} + +encode.defaultChars = ";/?:@&=+$,-_.!~*'()#"; +encode.componentChars = "-_.!~*'()"; + + +module.exports = encode; + +},{}],53:[function(require,module,exports){ +module.exports=/[\0-\x1F\x7F-\x9F]/ +},{}],54:[function(require,module,exports){ +module.exports=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804\uDCBD|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/ +},{}],55:[function(require,module,exports){ module.exports=/[!-#%-\*,-/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDE38-\uDE3D]|\uD805[\uDCC6\uDDC1-\uDDC9\uDE41-\uDE43]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F/ -},{}],52:[function(require,module,exports){ +},{}],56:[function(require,module,exports){ +module.exports=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/ +},{}],57:[function(require,module,exports){ +module.exports=/[\0-\uD7FF\uDC00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF]/ +},{}],58:[function(require,module,exports){ 'use strict'; module.exports = require('./lib/'); -},{"./lib/":10}]},{},[52])(52) +},{"./lib/":10}]},{},[58])(58) }); \ No newline at end of file diff --git a/dist/markdown-it.min.js b/dist/markdown-it.min.js index 573476d..e274405 100644 --- a/dist/markdown-it.min.js +++ b/dist/markdown-it.min.js @@ -1,4 +1,4 @@ -/*! markdown-it 3.0.7 https://github.com//markdown-it/markdown-it @license MIT */ -!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var r;"undefined"!=typeof window?r=window:"undefined"!=typeof global?r=global:"undefined"!=typeof self&&(r=self),r.markdownit=e()}}(function(){var e;return function r(e,t,n){function s(o,a){if(!t[o]){if(!e[o]){var l="function"==typeof require&&require;if(!a&&l)return l(o,!0);if(i)return i(o,!0);var c=new Error("Cannot find module '"+o+"'");throw c.code="MODULE_NOT_FOUND",c}var u=t[o]={exports:{}};e[o][0].call(u.exports,function(r){var t=e[o][1][r];return s(t?t:r)},u,u.exports,r,e,t,n)}return t[o].exports}for(var i="function"==typeof require&&require,o=0;o",Gt:"\u226b",gt:">",gtcc:"\u2aa7",gtcir:"\u2a7a",gtdot:"\u22d7",gtlPar:"\u2995",gtquest:"\u2a7c",gtrapprox:"\u2a86",gtrarr:"\u2978",gtrdot:"\u22d7",gtreqless:"\u22db",gtreqqless:"\u2a8c",gtrless:"\u2277",gtrsim:"\u2273",gvertneqq:"\u2269\ufe00",gvnE:"\u2269\ufe00",Hacek:"\u02c7",hairsp:"\u200a",half:"\xbd",hamilt:"\u210b",HARDcy:"\u042a",hardcy:"\u044a",hArr:"\u21d4",harr:"\u2194",harrcir:"\u2948",harrw:"\u21ad",Hat:"^",hbar:"\u210f",Hcirc:"\u0124",hcirc:"\u0125",hearts:"\u2665",heartsuit:"\u2665",hellip:"\u2026",hercon:"\u22b9",Hfr:"\u210c",hfr:"\ud835\udd25",HilbertSpace:"\u210b",hksearow:"\u2925",hkswarow:"\u2926",hoarr:"\u21ff",homtht:"\u223b",hookleftarrow:"\u21a9",hookrightarrow:"\u21aa",Hopf:"\u210d",hopf:"\ud835\udd59",horbar:"\u2015",HorizontalLine:"\u2500",Hscr:"\u210b",hscr:"\ud835\udcbd",hslash:"\u210f",Hstrok:"\u0126",hstrok:"\u0127",HumpDownHump:"\u224e",HumpEqual:"\u224f",hybull:"\u2043",hyphen:"\u2010",Iacute:"\xcd",iacute:"\xed",ic:"\u2063",Icirc:"\xce",icirc:"\xee",Icy:"\u0418",icy:"\u0438",Idot:"\u0130",IEcy:"\u0415",iecy:"\u0435",iexcl:"\xa1",iff:"\u21d4",Ifr:"\u2111",ifr:"\ud835\udd26",Igrave:"\xcc",igrave:"\xec",ii:"\u2148",iiiint:"\u2a0c",iiint:"\u222d",iinfin:"\u29dc",iiota:"\u2129",IJlig:"\u0132",ijlig:"\u0133",Im:"\u2111",Imacr:"\u012a",imacr:"\u012b",image:"\u2111",ImaginaryI:"\u2148",imagline:"\u2110",imagpart:"\u2111",imath:"\u0131",imof:"\u22b7",imped:"\u01b5",Implies:"\u21d2","in":"\u2208",incare:"\u2105",infin:"\u221e",infintie:"\u29dd",inodot:"\u0131",Int:"\u222c","int":"\u222b",intcal:"\u22ba",integers:"\u2124",Integral:"\u222b",intercal:"\u22ba",Intersection:"\u22c2",intlarhk:"\u2a17",intprod:"\u2a3c",InvisibleComma:"\u2063",InvisibleTimes:"\u2062",IOcy:"\u0401",iocy:"\u0451",Iogon:"\u012e",iogon:"\u012f",Iopf:"\ud835\udd40",iopf:"\ud835\udd5a",Iota:"\u0399",iota:"\u03b9",iprod:"\u2a3c",iquest:"\xbf",Iscr:"\u2110",iscr:"\ud835\udcbe",isin:"\u2208",isindot:"\u22f5",isinE:"\u22f9",isins:"\u22f4",isinsv:"\u22f3",isinv:"\u2208",it:"\u2062",Itilde:"\u0128",itilde:"\u0129",Iukcy:"\u0406",iukcy:"\u0456",Iuml:"\xcf",iuml:"\xef",Jcirc:"\u0134",jcirc:"\u0135",Jcy:"\u0419",jcy:"\u0439",Jfr:"\ud835\udd0d",jfr:"\ud835\udd27",jmath:"\u0237",Jopf:"\ud835\udd41",jopf:"\ud835\udd5b",Jscr:"\ud835\udca5",jscr:"\ud835\udcbf",Jsercy:"\u0408",jsercy:"\u0458",Jukcy:"\u0404",jukcy:"\u0454",Kappa:"\u039a",kappa:"\u03ba",kappav:"\u03f0",Kcedil:"\u0136",kcedil:"\u0137",Kcy:"\u041a",kcy:"\u043a",Kfr:"\ud835\udd0e",kfr:"\ud835\udd28",kgreen:"\u0138",KHcy:"\u0425",khcy:"\u0445",KJcy:"\u040c",kjcy:"\u045c",Kopf:"\ud835\udd42",kopf:"\ud835\udd5c",Kscr:"\ud835\udca6",kscr:"\ud835\udcc0",lAarr:"\u21da",Lacute:"\u0139",lacute:"\u013a",laemptyv:"\u29b4",lagran:"\u2112",Lambda:"\u039b",lambda:"\u03bb",Lang:"\u27ea",lang:"\u27e8",langd:"\u2991",langle:"\u27e8",lap:"\u2a85",Laplacetrf:"\u2112",laquo:"\xab",Larr:"\u219e",lArr:"\u21d0",larr:"\u2190",larrb:"\u21e4",larrbfs:"\u291f",larrfs:"\u291d",larrhk:"\u21a9",larrlp:"\u21ab",larrpl:"\u2939",larrsim:"\u2973",larrtl:"\u21a2",lat:"\u2aab",lAtail:"\u291b",latail:"\u2919",late:"\u2aad",lates:"\u2aad\ufe00",lBarr:"\u290e",lbarr:"\u290c",lbbrk:"\u2772",lbrace:"{",lbrack:"[",lbrke:"\u298b",lbrksld:"\u298f",lbrkslu:"\u298d",Lcaron:"\u013d",lcaron:"\u013e",Lcedil:"\u013b",lcedil:"\u013c",lceil:"\u2308",lcub:"{",Lcy:"\u041b",lcy:"\u043b",ldca:"\u2936",ldquo:"\u201c",ldquor:"\u201e",ldrdhar:"\u2967",ldrushar:"\u294b",ldsh:"\u21b2",lE:"\u2266",le:"\u2264",LeftAngleBracket:"\u27e8",LeftArrow:"\u2190",Leftarrow:"\u21d0",leftarrow:"\u2190",LeftArrowBar:"\u21e4",LeftArrowRightArrow:"\u21c6",leftarrowtail:"\u21a2",LeftCeiling:"\u2308",LeftDoubleBracket:"\u27e6",LeftDownTeeVector:"\u2961",LeftDownVector:"\u21c3",LeftDownVectorBar:"\u2959",LeftFloor:"\u230a",leftharpoondown:"\u21bd",leftharpoonup:"\u21bc",leftleftarrows:"\u21c7",LeftRightArrow:"\u2194",Leftrightarrow:"\u21d4",leftrightarrow:"\u2194",leftrightarrows:"\u21c6",leftrightharpoons:"\u21cb",leftrightsquigarrow:"\u21ad",LeftRightVector:"\u294e",LeftTee:"\u22a3",LeftTeeArrow:"\u21a4",LeftTeeVector:"\u295a",leftthreetimes:"\u22cb",LeftTriangle:"\u22b2",LeftTriangleBar:"\u29cf",LeftTriangleEqual:"\u22b4",LeftUpDownVector:"\u2951",LeftUpTeeVector:"\u2960",LeftUpVector:"\u21bf",LeftUpVectorBar:"\u2958",LeftVector:"\u21bc",LeftVectorBar:"\u2952",lEg:"\u2a8b",leg:"\u22da",leq:"\u2264",leqq:"\u2266",leqslant:"\u2a7d",les:"\u2a7d",lescc:"\u2aa8",lesdot:"\u2a7f",lesdoto:"\u2a81",lesdotor:"\u2a83",lesg:"\u22da\ufe00",lesges:"\u2a93",lessapprox:"\u2a85",lessdot:"\u22d6",lesseqgtr:"\u22da",lesseqqgtr:"\u2a8b",LessEqualGreater:"\u22da",LessFullEqual:"\u2266",LessGreater:"\u2276",lessgtr:"\u2276",LessLess:"\u2aa1",lesssim:"\u2272",LessSlantEqual:"\u2a7d",LessTilde:"\u2272",lfisht:"\u297c",lfloor:"\u230a",Lfr:"\ud835\udd0f",lfr:"\ud835\udd29",lg:"\u2276",lgE:"\u2a91",lHar:"\u2962",lhard:"\u21bd",lharu:"\u21bc",lharul:"\u296a",lhblk:"\u2584",LJcy:"\u0409",ljcy:"\u0459",Ll:"\u22d8",ll:"\u226a",llarr:"\u21c7",llcorner:"\u231e",Lleftarrow:"\u21da",llhard:"\u296b",lltri:"\u25fa",Lmidot:"\u013f",lmidot:"\u0140",lmoust:"\u23b0",lmoustache:"\u23b0",lnap:"\u2a89",lnapprox:"\u2a89",lnE:"\u2268",lne:"\u2a87",lneq:"\u2a87",lneqq:"\u2268",lnsim:"\u22e6",loang:"\u27ec",loarr:"\u21fd",lobrk:"\u27e6",LongLeftArrow:"\u27f5",Longleftarrow:"\u27f8",longleftarrow:"\u27f5",LongLeftRightArrow:"\u27f7",Longleftrightarrow:"\u27fa",longleftrightarrow:"\u27f7",longmapsto:"\u27fc",LongRightArrow:"\u27f6",Longrightarrow:"\u27f9",longrightarrow:"\u27f6",looparrowleft:"\u21ab",looparrowright:"\u21ac",lopar:"\u2985",Lopf:"\ud835\udd43",lopf:"\ud835\udd5d",loplus:"\u2a2d",lotimes:"\u2a34",lowast:"\u2217",lowbar:"_",LowerLeftArrow:"\u2199",LowerRightArrow:"\u2198",loz:"\u25ca",lozenge:"\u25ca",lozf:"\u29eb",lpar:"(",lparlt:"\u2993",lrarr:"\u21c6",lrcorner:"\u231f",lrhar:"\u21cb",lrhard:"\u296d",lrm:"\u200e",lrtri:"\u22bf",lsaquo:"\u2039",Lscr:"\u2112",lscr:"\ud835\udcc1",Lsh:"\u21b0",lsh:"\u21b0",lsim:"\u2272",lsime:"\u2a8d",lsimg:"\u2a8f",lsqb:"[",lsquo:"\u2018",lsquor:"\u201a",Lstrok:"\u0141",lstrok:"\u0142",LT:"<",Lt:"\u226a",lt:"<",ltcc:"\u2aa6",ltcir:"\u2a79",ltdot:"\u22d6",lthree:"\u22cb",ltimes:"\u22c9",ltlarr:"\u2976",ltquest:"\u2a7b",ltri:"\u25c3",ltrie:"\u22b4",ltrif:"\u25c2",ltrPar:"\u2996",lurdshar:"\u294a",luruhar:"\u2966",lvertneqq:"\u2268\ufe00",lvnE:"\u2268\ufe00",macr:"\xaf",male:"\u2642",malt:"\u2720",maltese:"\u2720",Map:"\u2905",map:"\u21a6",mapsto:"\u21a6",mapstodown:"\u21a7",mapstoleft:"\u21a4",mapstoup:"\u21a5",marker:"\u25ae",mcomma:"\u2a29",Mcy:"\u041c",mcy:"\u043c",mdash:"\u2014",mDDot:"\u223a",measuredangle:"\u2221",MediumSpace:"\u205f",Mellintrf:"\u2133",Mfr:"\ud835\udd10",mfr:"\ud835\udd2a",mho:"\u2127",micro:"\xb5",mid:"\u2223",midast:"*",midcir:"\u2af0",middot:"\xb7",minus:"\u2212",minusb:"\u229f",minusd:"\u2238",minusdu:"\u2a2a",MinusPlus:"\u2213",mlcp:"\u2adb",mldr:"\u2026",mnplus:"\u2213",models:"\u22a7",Mopf:"\ud835\udd44",mopf:"\ud835\udd5e",mp:"\u2213",Mscr:"\u2133",mscr:"\ud835\udcc2",mstpos:"\u223e",Mu:"\u039c",mu:"\u03bc",multimap:"\u22b8",mumap:"\u22b8",nabla:"\u2207",Nacute:"\u0143",nacute:"\u0144",nang:"\u2220\u20d2",nap:"\u2249",napE:"\u2a70\u0338",napid:"\u224b\u0338",napos:"\u0149",napprox:"\u2249",natur:"\u266e",natural:"\u266e",naturals:"\u2115",nbsp:"\xa0",nbump:"\u224e\u0338",nbumpe:"\u224f\u0338",ncap:"\u2a43",Ncaron:"\u0147",ncaron:"\u0148",Ncedil:"\u0145",ncedil:"\u0146",ncong:"\u2247",ncongdot:"\u2a6d\u0338",ncup:"\u2a42",Ncy:"\u041d",ncy:"\u043d",ndash:"\u2013",ne:"\u2260",nearhk:"\u2924",neArr:"\u21d7",nearr:"\u2197",nearrow:"\u2197",nedot:"\u2250\u0338",NegativeMediumSpace:"\u200b",NegativeThickSpace:"\u200b",NegativeThinSpace:"\u200b",NegativeVeryThinSpace:"\u200b",nequiv:"\u2262",nesear:"\u2928",nesim:"\u2242\u0338",NestedGreaterGreater:"\u226b",NestedLessLess:"\u226a",NewLine:"\n",nexist:"\u2204",nexists:"\u2204",Nfr:"\ud835\udd11",nfr:"\ud835\udd2b",ngE:"\u2267\u0338",nge:"\u2271",ngeq:"\u2271",ngeqq:"\u2267\u0338",ngeqslant:"\u2a7e\u0338",nges:"\u2a7e\u0338",nGg:"\u22d9\u0338",ngsim:"\u2275",nGt:"\u226b\u20d2",ngt:"\u226f",ngtr:"\u226f",nGtv:"\u226b\u0338",nhArr:"\u21ce",nharr:"\u21ae",nhpar:"\u2af2",ni:"\u220b",nis:"\u22fc",nisd:"\u22fa",niv:"\u220b",NJcy:"\u040a",njcy:"\u045a",nlArr:"\u21cd",nlarr:"\u219a",nldr:"\u2025",nlE:"\u2266\u0338",nle:"\u2270",nLeftarrow:"\u21cd",nleftarrow:"\u219a",nLeftrightarrow:"\u21ce",nleftrightarrow:"\u21ae",nleq:"\u2270",nleqq:"\u2266\u0338",nleqslant:"\u2a7d\u0338",nles:"\u2a7d\u0338",nless:"\u226e",nLl:"\u22d8\u0338",nlsim:"\u2274",nLt:"\u226a\u20d2",nlt:"\u226e",nltri:"\u22ea",nltrie:"\u22ec",nLtv:"\u226a\u0338",nmid:"\u2224",NoBreak:"\u2060",NonBreakingSpace:"\xa0",Nopf:"\u2115",nopf:"\ud835\udd5f",Not:"\u2aec",not:"\xac",NotCongruent:"\u2262",NotCupCap:"\u226d",NotDoubleVerticalBar:"\u2226",NotElement:"\u2209",NotEqual:"\u2260",NotEqualTilde:"\u2242\u0338",NotExists:"\u2204",NotGreater:"\u226f",NotGreaterEqual:"\u2271",NotGreaterFullEqual:"\u2267\u0338",NotGreaterGreater:"\u226b\u0338",NotGreaterLess:"\u2279",NotGreaterSlantEqual:"\u2a7e\u0338",NotGreaterTilde:"\u2275",NotHumpDownHump:"\u224e\u0338",NotHumpEqual:"\u224f\u0338",notin:"\u2209",notindot:"\u22f5\u0338",notinE:"\u22f9\u0338",notinva:"\u2209",notinvb:"\u22f7",notinvc:"\u22f6",NotLeftTriangle:"\u22ea",NotLeftTriangleBar:"\u29cf\u0338",NotLeftTriangleEqual:"\u22ec",NotLess:"\u226e",NotLessEqual:"\u2270",NotLessGreater:"\u2278",NotLessLess:"\u226a\u0338",NotLessSlantEqual:"\u2a7d\u0338",NotLessTilde:"\u2274",NotNestedGreaterGreater:"\u2aa2\u0338",NotNestedLessLess:"\u2aa1\u0338",notni:"\u220c",notniva:"\u220c",notnivb:"\u22fe",notnivc:"\u22fd",NotPrecedes:"\u2280",NotPrecedesEqual:"\u2aaf\u0338",NotPrecedesSlantEqual:"\u22e0",NotReverseElement:"\u220c",NotRightTriangle:"\u22eb",NotRightTriangleBar:"\u29d0\u0338",NotRightTriangleEqual:"\u22ed",NotSquareSubset:"\u228f\u0338",NotSquareSubsetEqual:"\u22e2",NotSquareSuperset:"\u2290\u0338",NotSquareSupersetEqual:"\u22e3",NotSubset:"\u2282\u20d2",NotSubsetEqual:"\u2288",NotSucceeds:"\u2281",NotSucceedsEqual:"\u2ab0\u0338",NotSucceedsSlantEqual:"\u22e1",NotSucceedsTilde:"\u227f\u0338",NotSuperset:"\u2283\u20d2",NotSupersetEqual:"\u2289",NotTilde:"\u2241",NotTildeEqual:"\u2244",NotTildeFullEqual:"\u2247",NotTildeTilde:"\u2249",NotVerticalBar:"\u2224",npar:"\u2226",nparallel:"\u2226",nparsl:"\u2afd\u20e5",npart:"\u2202\u0338",npolint:"\u2a14",npr:"\u2280",nprcue:"\u22e0",npre:"\u2aaf\u0338",nprec:"\u2280",npreceq:"\u2aaf\u0338",nrArr:"\u21cf",nrarr:"\u219b",nrarrc:"\u2933\u0338",nrarrw:"\u219d\u0338",nRightarrow:"\u21cf",nrightarrow:"\u219b",nrtri:"\u22eb",nrtrie:"\u22ed",nsc:"\u2281",nsccue:"\u22e1",nsce:"\u2ab0\u0338",Nscr:"\ud835\udca9",nscr:"\ud835\udcc3",nshortmid:"\u2224",nshortparallel:"\u2226",nsim:"\u2241",nsime:"\u2244",nsimeq:"\u2244",nsmid:"\u2224",nspar:"\u2226",nsqsube:"\u22e2",nsqsupe:"\u22e3",nsub:"\u2284",nsubE:"\u2ac5\u0338",nsube:"\u2288",nsubset:"\u2282\u20d2",nsubseteq:"\u2288",nsubseteqq:"\u2ac5\u0338",nsucc:"\u2281",nsucceq:"\u2ab0\u0338",nsup:"\u2285",nsupE:"\u2ac6\u0338",nsupe:"\u2289",nsupset:"\u2283\u20d2",nsupseteq:"\u2289",nsupseteqq:"\u2ac6\u0338",ntgl:"\u2279",Ntilde:"\xd1",ntilde:"\xf1",ntlg:"\u2278",ntriangleleft:"\u22ea",ntrianglelefteq:"\u22ec",ntriangleright:"\u22eb",ntrianglerighteq:"\u22ed",Nu:"\u039d",nu:"\u03bd",num:"#",numero:"\u2116",numsp:"\u2007",nvap:"\u224d\u20d2",nVDash:"\u22af",nVdash:"\u22ae",nvDash:"\u22ad",nvdash:"\u22ac",nvge:"\u2265\u20d2",nvgt:">\u20d2",nvHarr:"\u2904",nvinfin:"\u29de",nvlArr:"\u2902",nvle:"\u2264\u20d2",nvlt:"<\u20d2",nvltrie:"\u22b4\u20d2",nvrArr:"\u2903",nvrtrie:"\u22b5\u20d2",nvsim:"\u223c\u20d2",nwarhk:"\u2923",nwArr:"\u21d6",nwarr:"\u2196",nwarrow:"\u2196",nwnear:"\u2927",Oacute:"\xd3",oacute:"\xf3",oast:"\u229b",ocir:"\u229a",Ocirc:"\xd4",ocirc:"\xf4",Ocy:"\u041e",ocy:"\u043e",odash:"\u229d",Odblac:"\u0150",odblac:"\u0151",odiv:"\u2a38",odot:"\u2299",odsold:"\u29bc",OElig:"\u0152",oelig:"\u0153",ofcir:"\u29bf",Ofr:"\ud835\udd12",ofr:"\ud835\udd2c",ogon:"\u02db",Ograve:"\xd2",ograve:"\xf2",ogt:"\u29c1",ohbar:"\u29b5",ohm:"\u03a9",oint:"\u222e",olarr:"\u21ba",olcir:"\u29be",olcross:"\u29bb",oline:"\u203e",olt:"\u29c0",Omacr:"\u014c",omacr:"\u014d",Omega:"\u03a9",omega:"\u03c9",Omicron:"\u039f",omicron:"\u03bf",omid:"\u29b6",ominus:"\u2296",Oopf:"\ud835\udd46",oopf:"\ud835\udd60",opar:"\u29b7",OpenCurlyDoubleQuote:"\u201c",OpenCurlyQuote:"\u2018",operp:"\u29b9",oplus:"\u2295",Or:"\u2a54",or:"\u2228",orarr:"\u21bb",ord:"\u2a5d",order:"\u2134",orderof:"\u2134",ordf:"\xaa",ordm:"\xba",origof:"\u22b6",oror:"\u2a56",orslope:"\u2a57",orv:"\u2a5b",oS:"\u24c8",Oscr:"\ud835\udcaa",oscr:"\u2134",Oslash:"\xd8",oslash:"\xf8",osol:"\u2298",Otilde:"\xd5",otilde:"\xf5",Otimes:"\u2a37",otimes:"\u2297",otimesas:"\u2a36",Ouml:"\xd6",ouml:"\xf6",ovbar:"\u233d",OverBar:"\u203e",OverBrace:"\u23de",OverBracket:"\u23b4",OverParenthesis:"\u23dc",par:"\u2225",para:"\xb6",parallel:"\u2225",parsim:"\u2af3",parsl:"\u2afd",part:"\u2202",PartialD:"\u2202",Pcy:"\u041f",pcy:"\u043f",percnt:"%",period:".",permil:"\u2030",perp:"\u22a5",pertenk:"\u2031",Pfr:"\ud835\udd13",pfr:"\ud835\udd2d",Phi:"\u03a6",phi:"\u03c6",phiv:"\u03d5",phmmat:"\u2133",phone:"\u260e",Pi:"\u03a0",pi:"\u03c0",pitchfork:"\u22d4",piv:"\u03d6",planck:"\u210f",planckh:"\u210e",plankv:"\u210f",plus:"+",plusacir:"\u2a23",plusb:"\u229e",pluscir:"\u2a22",plusdo:"\u2214",plusdu:"\u2a25",pluse:"\u2a72",PlusMinus:"\xb1",plusmn:"\xb1",plussim:"\u2a26",plustwo:"\u2a27",pm:"\xb1",Poincareplane:"\u210c",pointint:"\u2a15",Popf:"\u2119",popf:"\ud835\udd61",pound:"\xa3",Pr:"\u2abb",pr:"\u227a",prap:"\u2ab7",prcue:"\u227c",prE:"\u2ab3",pre:"\u2aaf",prec:"\u227a",precapprox:"\u2ab7",preccurlyeq:"\u227c",Precedes:"\u227a",PrecedesEqual:"\u2aaf",PrecedesSlantEqual:"\u227c",PrecedesTilde:"\u227e",preceq:"\u2aaf",precnapprox:"\u2ab9",precneqq:"\u2ab5",precnsim:"\u22e8",precsim:"\u227e",Prime:"\u2033",prime:"\u2032",primes:"\u2119",prnap:"\u2ab9",prnE:"\u2ab5",prnsim:"\u22e8",prod:"\u220f",Product:"\u220f",profalar:"\u232e",profline:"\u2312",profsurf:"\u2313",prop:"\u221d",Proportion:"\u2237",Proportional:"\u221d",propto:"\u221d",prsim:"\u227e",prurel:"\u22b0",Pscr:"\ud835\udcab",pscr:"\ud835\udcc5",Psi:"\u03a8",psi:"\u03c8",puncsp:"\u2008",Qfr:"\ud835\udd14",qfr:"\ud835\udd2e",qint:"\u2a0c",Qopf:"\u211a",qopf:"\ud835\udd62",qprime:"\u2057",Qscr:"\ud835\udcac",qscr:"\ud835\udcc6",quaternions:"\u210d",quatint:"\u2a16",quest:"?",questeq:"\u225f",QUOT:'"',quot:'"',rAarr:"\u21db",race:"\u223d\u0331",Racute:"\u0154",racute:"\u0155",radic:"\u221a",raemptyv:"\u29b3",Rang:"\u27eb",rang:"\u27e9",rangd:"\u2992",range:"\u29a5",rangle:"\u27e9",raquo:"\xbb",Rarr:"\u21a0",rArr:"\u21d2",rarr:"\u2192",rarrap:"\u2975",rarrb:"\u21e5",rarrbfs:"\u2920",rarrc:"\u2933",rarrfs:"\u291e",rarrhk:"\u21aa",rarrlp:"\u21ac",rarrpl:"\u2945",rarrsim:"\u2974",Rarrtl:"\u2916",rarrtl:"\u21a3",rarrw:"\u219d",rAtail:"\u291c",ratail:"\u291a",ratio:"\u2236",rationals:"\u211a",RBarr:"\u2910",rBarr:"\u290f",rbarr:"\u290d",rbbrk:"\u2773",rbrace:"}",rbrack:"]",rbrke:"\u298c",rbrksld:"\u298e",rbrkslu:"\u2990",Rcaron:"\u0158",rcaron:"\u0159",Rcedil:"\u0156",rcedil:"\u0157",rceil:"\u2309",rcub:"}",Rcy:"\u0420",rcy:"\u0440",rdca:"\u2937",rdldhar:"\u2969",rdquo:"\u201d",rdquor:"\u201d",rdsh:"\u21b3",Re:"\u211c",real:"\u211c",realine:"\u211b",realpart:"\u211c",reals:"\u211d",rect:"\u25ad",REG:"\xae",reg:"\xae",ReverseElement:"\u220b",ReverseEquilibrium:"\u21cb",ReverseUpEquilibrium:"\u296f",rfisht:"\u297d",rfloor:"\u230b",Rfr:"\u211c",rfr:"\ud835\udd2f",rHar:"\u2964",rhard:"\u21c1",rharu:"\u21c0",rharul:"\u296c",Rho:"\u03a1",rho:"\u03c1",rhov:"\u03f1",RightAngleBracket:"\u27e9",RightArrow:"\u2192",Rightarrow:"\u21d2",rightarrow:"\u2192",RightArrowBar:"\u21e5",RightArrowLeftArrow:"\u21c4",rightarrowtail:"\u21a3",RightCeiling:"\u2309",RightDoubleBracket:"\u27e7",RightDownTeeVector:"\u295d",RightDownVector:"\u21c2",RightDownVectorBar:"\u2955",RightFloor:"\u230b",rightharpoondown:"\u21c1",rightharpoonup:"\u21c0",rightleftarrows:"\u21c4",rightleftharpoons:"\u21cc",rightrightarrows:"\u21c9",rightsquigarrow:"\u219d",RightTee:"\u22a2",RightTeeArrow:"\u21a6",RightTeeVector:"\u295b",rightthreetimes:"\u22cc",RightTriangle:"\u22b3",RightTriangleBar:"\u29d0",RightTriangleEqual:"\u22b5",RightUpDownVector:"\u294f",RightUpTeeVector:"\u295c",RightUpVector:"\u21be",RightUpVectorBar:"\u2954",RightVector:"\u21c0",RightVectorBar:"\u2953",ring:"\u02da",risingdotseq:"\u2253",rlarr:"\u21c4",rlhar:"\u21cc",rlm:"\u200f",rmoust:"\u23b1",rmoustache:"\u23b1",rnmid:"\u2aee",roang:"\u27ed",roarr:"\u21fe",robrk:"\u27e7",ropar:"\u2986",Ropf:"\u211d",ropf:"\ud835\udd63",roplus:"\u2a2e",rotimes:"\u2a35",RoundImplies:"\u2970",rpar:")",rpargt:"\u2994",rppolint:"\u2a12",rrarr:"\u21c9",Rrightarrow:"\u21db",rsaquo:"\u203a",Rscr:"\u211b",rscr:"\ud835\udcc7",Rsh:"\u21b1",rsh:"\u21b1",rsqb:"]",rsquo:"\u2019",rsquor:"\u2019",rthree:"\u22cc",rtimes:"\u22ca",rtri:"\u25b9",rtrie:"\u22b5",rtrif:"\u25b8",rtriltri:"\u29ce",RuleDelayed:"\u29f4",ruluhar:"\u2968",rx:"\u211e",Sacute:"\u015a",sacute:"\u015b",sbquo:"\u201a",Sc:"\u2abc",sc:"\u227b",scap:"\u2ab8",Scaron:"\u0160",scaron:"\u0161",sccue:"\u227d",scE:"\u2ab4",sce:"\u2ab0",Scedil:"\u015e",scedil:"\u015f",Scirc:"\u015c",scirc:"\u015d",scnap:"\u2aba",scnE:"\u2ab6",scnsim:"\u22e9",scpolint:"\u2a13",scsim:"\u227f",Scy:"\u0421",scy:"\u0441",sdot:"\u22c5",sdotb:"\u22a1",sdote:"\u2a66",searhk:"\u2925",seArr:"\u21d8",searr:"\u2198",searrow:"\u2198",sect:"\xa7",semi:";",seswar:"\u2929",setminus:"\u2216",setmn:"\u2216",sext:"\u2736",Sfr:"\ud835\udd16",sfr:"\ud835\udd30",sfrown:"\u2322",sharp:"\u266f",SHCHcy:"\u0429",shchcy:"\u0449",SHcy:"\u0428",shcy:"\u0448",ShortDownArrow:"\u2193",ShortLeftArrow:"\u2190",shortmid:"\u2223",shortparallel:"\u2225",ShortRightArrow:"\u2192",ShortUpArrow:"\u2191",shy:"\xad",Sigma:"\u03a3",sigma:"\u03c3",sigmaf:"\u03c2",sigmav:"\u03c2",sim:"\u223c",simdot:"\u2a6a",sime:"\u2243",simeq:"\u2243",simg:"\u2a9e",simgE:"\u2aa0",siml:"\u2a9d",simlE:"\u2a9f",simne:"\u2246",simplus:"\u2a24",simrarr:"\u2972",slarr:"\u2190",SmallCircle:"\u2218",smallsetminus:"\u2216",smashp:"\u2a33",smeparsl:"\u29e4",smid:"\u2223",smile:"\u2323",smt:"\u2aaa",smte:"\u2aac",smtes:"\u2aac\ufe00",SOFTcy:"\u042c",softcy:"\u044c",sol:"/",solb:"\u29c4",solbar:"\u233f",Sopf:"\ud835\udd4a",sopf:"\ud835\udd64",spades:"\u2660",spadesuit:"\u2660",spar:"\u2225",sqcap:"\u2293",sqcaps:"\u2293\ufe00",sqcup:"\u2294",sqcups:"\u2294\ufe00",Sqrt:"\u221a",sqsub:"\u228f",sqsube:"\u2291",sqsubset:"\u228f",sqsubseteq:"\u2291",sqsup:"\u2290",sqsupe:"\u2292",sqsupset:"\u2290",sqsupseteq:"\u2292",squ:"\u25a1",Square:"\u25a1",square:"\u25a1",SquareIntersection:"\u2293",SquareSubset:"\u228f",SquareSubsetEqual:"\u2291",SquareSuperset:"\u2290",SquareSupersetEqual:"\u2292",SquareUnion:"\u2294",squarf:"\u25aa",squf:"\u25aa",srarr:"\u2192",Sscr:"\ud835\udcae",sscr:"\ud835\udcc8",ssetmn:"\u2216",ssmile:"\u2323",sstarf:"\u22c6",Star:"\u22c6",star:"\u2606",starf:"\u2605",straightepsilon:"\u03f5",straightphi:"\u03d5",strns:"\xaf",Sub:"\u22d0",sub:"\u2282",subdot:"\u2abd",subE:"\u2ac5",sube:"\u2286",subedot:"\u2ac3",submult:"\u2ac1",subnE:"\u2acb",subne:"\u228a",subplus:"\u2abf",subrarr:"\u2979",Subset:"\u22d0",subset:"\u2282",subseteq:"\u2286",subseteqq:"\u2ac5",SubsetEqual:"\u2286",subsetneq:"\u228a",subsetneqq:"\u2acb",subsim:"\u2ac7",subsub:"\u2ad5",subsup:"\u2ad3",succ:"\u227b",succapprox:"\u2ab8",succcurlyeq:"\u227d",Succeeds:"\u227b",SucceedsEqual:"\u2ab0",SucceedsSlantEqual:"\u227d",SucceedsTilde:"\u227f",succeq:"\u2ab0",succnapprox:"\u2aba",succneqq:"\u2ab6",succnsim:"\u22e9",succsim:"\u227f",SuchThat:"\u220b",Sum:"\u2211",sum:"\u2211",sung:"\u266a",Sup:"\u22d1",sup:"\u2283",sup1:"\xb9",sup2:"\xb2",sup3:"\xb3",supdot:"\u2abe",supdsub:"\u2ad8",supE:"\u2ac6",supe:"\u2287",supedot:"\u2ac4",Superset:"\u2283",SupersetEqual:"\u2287",suphsol:"\u27c9",suphsub:"\u2ad7",suplarr:"\u297b",supmult:"\u2ac2",supnE:"\u2acc",supne:"\u228b",supplus:"\u2ac0",Supset:"\u22d1",supset:"\u2283",supseteq:"\u2287",supseteqq:"\u2ac6",supsetneq:"\u228b",supsetneqq:"\u2acc",supsim:"\u2ac8",supsub:"\u2ad4",supsup:"\u2ad6",swarhk:"\u2926",swArr:"\u21d9",swarr:"\u2199",swarrow:"\u2199",swnwar:"\u292a",szlig:"\xdf",Tab:" ",target:"\u2316",Tau:"\u03a4",tau:"\u03c4",tbrk:"\u23b4",Tcaron:"\u0164",tcaron:"\u0165",Tcedil:"\u0162",tcedil:"\u0163",Tcy:"\u0422",tcy:"\u0442",tdot:"\u20db",telrec:"\u2315",Tfr:"\ud835\udd17",tfr:"\ud835\udd31",there4:"\u2234",Therefore:"\u2234",therefore:"\u2234",Theta:"\u0398",theta:"\u03b8",thetasym:"\u03d1",thetav:"\u03d1",thickapprox:"\u2248",thicksim:"\u223c",ThickSpace:"\u205f\u200a",thinsp:"\u2009",ThinSpace:"\u2009",thkap:"\u2248",thksim:"\u223c",THORN:"\xde",thorn:"\xfe",Tilde:"\u223c",tilde:"\u02dc",TildeEqual:"\u2243",TildeFullEqual:"\u2245",TildeTilde:"\u2248",times:"\xd7",timesb:"\u22a0",timesbar:"\u2a31",timesd:"\u2a30",tint:"\u222d",toea:"\u2928",top:"\u22a4",topbot:"\u2336",topcir:"\u2af1",Topf:"\ud835\udd4b",topf:"\ud835\udd65",topfork:"\u2ada",tosa:"\u2929",tprime:"\u2034",TRADE:"\u2122",trade:"\u2122",triangle:"\u25b5",triangledown:"\u25bf",triangleleft:"\u25c3",trianglelefteq:"\u22b4",triangleq:"\u225c",triangleright:"\u25b9",trianglerighteq:"\u22b5",tridot:"\u25ec",trie:"\u225c",triminus:"\u2a3a",TripleDot:"\u20db",triplus:"\u2a39",trisb:"\u29cd",tritime:"\u2a3b",trpezium:"\u23e2",Tscr:"\ud835\udcaf",tscr:"\ud835\udcc9",TScy:"\u0426",tscy:"\u0446",TSHcy:"\u040b",tshcy:"\u045b",Tstrok:"\u0166",tstrok:"\u0167",twixt:"\u226c",twoheadleftarrow:"\u219e",twoheadrightarrow:"\u21a0",Uacute:"\xda",uacute:"\xfa",Uarr:"\u219f",uArr:"\u21d1",uarr:"\u2191",Uarrocir:"\u2949",Ubrcy:"\u040e",ubrcy:"\u045e",Ubreve:"\u016c",ubreve:"\u016d",Ucirc:"\xdb",ucirc:"\xfb",Ucy:"\u0423",ucy:"\u0443",udarr:"\u21c5",Udblac:"\u0170",udblac:"\u0171",udhar:"\u296e",ufisht:"\u297e",Ufr:"\ud835\udd18",ufr:"\ud835\udd32",Ugrave:"\xd9",ugrave:"\xf9",uHar:"\u2963",uharl:"\u21bf",uharr:"\u21be",uhblk:"\u2580",ulcorn:"\u231c",ulcorner:"\u231c",ulcrop:"\u230f",ultri:"\u25f8",Umacr:"\u016a",umacr:"\u016b",uml:"\xa8",UnderBar:"_",UnderBrace:"\u23df",UnderBracket:"\u23b5",UnderParenthesis:"\u23dd",Union:"\u22c3",UnionPlus:"\u228e",Uogon:"\u0172",uogon:"\u0173",Uopf:"\ud835\udd4c",uopf:"\ud835\udd66",UpArrow:"\u2191",Uparrow:"\u21d1",uparrow:"\u2191",UpArrowBar:"\u2912",UpArrowDownArrow:"\u21c5",UpDownArrow:"\u2195",Updownarrow:"\u21d5",updownarrow:"\u2195",UpEquilibrium:"\u296e",upharpoonleft:"\u21bf",upharpoonright:"\u21be",uplus:"\u228e",UpperLeftArrow:"\u2196",UpperRightArrow:"\u2197",Upsi:"\u03d2",upsi:"\u03c5",upsih:"\u03d2",Upsilon:"\u03a5",upsilon:"\u03c5",UpTee:"\u22a5",UpTeeArrow:"\u21a5",upuparrows:"\u21c8",urcorn:"\u231d",urcorner:"\u231d",urcrop:"\u230e",Uring:"\u016e",uring:"\u016f",urtri:"\u25f9",Uscr:"\ud835\udcb0",uscr:"\ud835\udcca",utdot:"\u22f0",Utilde:"\u0168",utilde:"\u0169",utri:"\u25b5",utrif:"\u25b4",uuarr:"\u21c8",Uuml:"\xdc",uuml:"\xfc",uwangle:"\u29a7",vangrt:"\u299c",varepsilon:"\u03f5",varkappa:"\u03f0",varnothing:"\u2205",varphi:"\u03d5",varpi:"\u03d6",varpropto:"\u221d",vArr:"\u21d5",varr:"\u2195",varrho:"\u03f1",varsigma:"\u03c2",varsubsetneq:"\u228a\ufe00",varsubsetneqq:"\u2acb\ufe00",varsupsetneq:"\u228b\ufe00",varsupsetneqq:"\u2acc\ufe00",vartheta:"\u03d1",vartriangleleft:"\u22b2",vartriangleright:"\u22b3",Vbar:"\u2aeb",vBar:"\u2ae8",vBarv:"\u2ae9",Vcy:"\u0412",vcy:"\u0432",VDash:"\u22ab",Vdash:"\u22a9",vDash:"\u22a8",vdash:"\u22a2",Vdashl:"\u2ae6",Vee:"\u22c1",vee:"\u2228",veebar:"\u22bb",veeeq:"\u225a",vellip:"\u22ee",Verbar:"\u2016",verbar:"|",Vert:"\u2016",vert:"|",VerticalBar:"\u2223",VerticalLine:"|",VerticalSeparator:"\u2758",VerticalTilde:"\u2240",VeryThinSpace:"\u200a",Vfr:"\ud835\udd19",vfr:"\ud835\udd33",vltri:"\u22b2",vnsub:"\u2282\u20d2",vnsup:"\u2283\u20d2",Vopf:"\ud835\udd4d",vopf:"\ud835\udd67",vprop:"\u221d",vrtri:"\u22b3",Vscr:"\ud835\udcb1",vscr:"\ud835\udccb",vsubnE:"\u2acb\ufe00",vsubne:"\u228a\ufe00",vsupnE:"\u2acc\ufe00",vsupne:"\u228b\ufe00",Vvdash:"\u22aa",vzigzag:"\u299a",Wcirc:"\u0174",wcirc:"\u0175",wedbar:"\u2a5f",Wedge:"\u22c0",wedge:"\u2227",wedgeq:"\u2259",weierp:"\u2118",Wfr:"\ud835\udd1a",wfr:"\ud835\udd34",Wopf:"\ud835\udd4e",wopf:"\ud835\udd68",wp:"\u2118",wr:"\u2240",wreath:"\u2240",Wscr:"\ud835\udcb2",wscr:"\ud835\udccc",xcap:"\u22c2",xcirc:"\u25ef",xcup:"\u22c3",xdtri:"\u25bd",Xfr:"\ud835\udd1b",xfr:"\ud835\udd35",xhArr:"\u27fa",xharr:"\u27f7",Xi:"\u039e",xi:"\u03be",xlArr:"\u27f8",xlarr:"\u27f5",xmap:"\u27fc",xnis:"\u22fb",xodot:"\u2a00",Xopf:"\ud835\udd4f",xopf:"\ud835\udd69",xoplus:"\u2a01",xotime:"\u2a02",xrArr:"\u27f9",xrarr:"\u27f6",Xscr:"\ud835\udcb3",xscr:"\ud835\udccd",xsqcup:"\u2a06",xuplus:"\u2a04",xutri:"\u25b3",xvee:"\u22c1",xwedge:"\u22c0",Yacute:"\xdd",yacute:"\xfd",YAcy:"\u042f",yacy:"\u044f",Ycirc:"\u0176",ycirc:"\u0177",Ycy:"\u042b",ycy:"\u044b",yen:"\xa5",Yfr:"\ud835\udd1c",yfr:"\ud835\udd36",YIcy:"\u0407",yicy:"\u0457",Yopf:"\ud835\udd50",yopf:"\ud835\udd6a",Yscr:"\ud835\udcb4",yscr:"\ud835\udcce",YUcy:"\u042e",yucy:"\u044e",Yuml:"\u0178",yuml:"\xff",Zacute:"\u0179",zacute:"\u017a",Zcaron:"\u017d",zcaron:"\u017e",Zcy:"\u0417",zcy:"\u0437",Zdot:"\u017b",zdot:"\u017c",zeetrf:"\u2128",ZeroWidthSpace:"\u200b",Zeta:"\u0396",zeta:"\u03b6",Zfr:"\u2128",zfr:"\ud835\udd37",ZHcy:"\u0416",zhcy:"\u0436",zigrarr:"\u21dd",Zopf:"\u2124",zopf:"\ud835\udd6b",Zscr:"\ud835\udcb5",zscr:"\ud835\udccf",zwj:"\u200d",zwnj:"\u200c"} -},{}],2:[function(e,r){"use strict";var t={};["article","aside","button","blockquote","body","canvas","caption","col","colgroup","dd","div","dl","dt","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","iframe","li","map","object","ol","output","p","pre","progress","script","section","style","table","tbody","td","textarea","tfoot","th","tr","thead","ul","video"].forEach(function(e){t[e]=!0}),r.exports=t},{}],3:[function(e,r){"use strict";var t="[a-zA-Z_:][a-zA-Z0-9:._-]*",n="[^\"'=<>`\\x00-\\x20]+",s="'[^']*'",i='"[^"]*"',o="(?:"+n+"|"+s+"|"+i+")",a="(?:\\s+"+t+"(?:\\s*=\\s*"+o+")?)",l="<[A-Za-z][A-Za-z0-9\\-]*"+a+"*\\s*\\/?>",c="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",u="|",p="<[?].*?[?]>",h="]*>",f="",d=new RegExp("^(?:"+l+"|"+c+"|"+u+"|"+p+"|"+h+"|"+f+")");r.exports.HTML_TAG_RE=d},{}],4:[function(e,r){"use strict";r.exports=["coap","doi","javascript","aaa","aaas","about","acap","cap","cid","crid","data","dav","dict","dns","file","ftp","geo","go","gopher","h323","http","https","iax","icap","im","imap","info","ipp","iris","iris.beep","iris.xpc","iris.xpcs","iris.lwz","ldap","mailto","mid","msrp","msrps","mtqp","mupdate","news","nfs","ni","nih","nntp","opaquelocktoken","pop","pres","rtsp","service","session","shttp","sieve","sip","sips","sms","snmp","soap.beep","soap.beeps","tag","tel","telnet","tftp","thismessage","tn3270","tip","tv","urn","vemmi","ws","wss","xcon","xcon-userid","xmlrpc.beep","xmlrpc.beeps","xmpp","z39.50r","z39.50s","adiumxtra","afp","afs","aim","apt","attachment","aw","beshare","bitcoin","bolo","callto","chrome","chrome-extension","com-eventbrite-attendee","content","cvs","dlna-playsingle","dlna-playcontainer","dtn","dvb","ed2k","facetime","feed","finger","fish","gg","git","gizmoproject","gtalk","hcp","icon","ipn","irc","irc6","ircs","itms","jar","jms","keyparc","lastfm","ldaps","magnet","maps","market","message","mms","ms-help","msnim","mumble","mvn","notes","oid","palm","paparazzi","platform","proxy","psyc","query","res","resource","rmi","rsync","rtmp","secondlife","sftp","sgn","skype","smb","soldat","spotify","ssh","steam","svn","teamspeak","things","udp","unreal","ut2004","ventrilo","view-source","webcal","wtai","wyciwyg","xfire","xri","ymsgr"]},{}],5:[function(e,r,t){"use strict";function n(e){return Object.prototype.toString.call(e)}function s(e){return"[object String]"===n(e)}function i(e,r){return A.call(e,r)}function o(e){var r=Array.prototype.slice.call(arguments,1);return r.forEach(function(r){if(r){if("object"!=typeof r)throw new TypeError(r+"must be object");Object.keys(r).forEach(function(t){e[t]=r[t]})}}),e}function a(e,r,t){return[].concat(e.slice(0,r),t,e.slice(r+1))}function l(e){return e.indexOf("\\")<0?e:e.replace(w,"$1")}function c(e){return e>=55296&&57343>=e?!1:e>=64976&&65007>=e?!1:65535===(65535&e)||65534===(65535&e)?!1:e>=0&&8>=e?!1:11===e?!1:e>=14&&31>=e?!1:e>=127&&159>=e?!1:e>1114111?!1:!0}function u(e){if(e>65535){e-=65536;var r=55296+(e>>10),t=56320+(1023&e);return String.fromCharCode(r,t)}return String.fromCharCode(e)}function p(e,r){var t=0;return i(D,r)?D[r]:35===r.charCodeAt(0)&&C.test(r)&&(t="x"===r[1].toLowerCase()?parseInt(r.slice(2),16):parseInt(r.slice(1),10),c(t))?u(t):e}function h(e){return e.indexOf("&")<0?e:e.replace(q,p)}function f(e){return F[e]}function d(e){return E.test(e)?e.replace(S,f):e}function g(e,r,t){var n=e.charCodeAt(0);return n>=55296&&56319>=n?r>=t.length-1?"\ufffd":(n=t.charCodeAt(r+1),56320>n||n>57343?"\ufffd":e):0===r?"\ufffd":(n=t.charCodeAt(r-1),55296>n||n>56319?"\ufffd":e)}function m(e){return M.test(e)?e.replace(L,g):e}function b(e){var r=h(e);try{r=decodeURI(r)}catch(t){}try{return encodeURI(m(r))}catch(t){return""}}function v(e){return e.replace(T,"\\$&")}function k(e){if(e>=8192&&8202>=e)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function y(e){return R.test(e)}function _(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function x(e){return e.trim().replace(/\s+/g," ").toUpperCase()}var A=Object.prototype.hasOwnProperty,w=/\\([!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~])/g,q=/&([a-z#][a-z0-9]{1,31});/gi,C=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i,D=e("./entities"),E=/[&<>"]/,S=/[&<>"]/g,F={"&":"&","<":"<",">":">",'"':"""},M=/[\uD800-\uDFFF]/,L=/[\uD800-\uDFFF]/g,T=/[.?*+^$[\]\\(){}|-]/g,R=e("uc.micro/categories/P/regex");t.assign=o,t.isString=s,t.has=i,t.unescapeMd=l,t.isValidEntityCode=c,t.fromCodePoint=u,t.replaceEntities=h,t.escapeHtml=d,t.arrayReplaceAt=a,t.normalizeLink=b,t.isWhiteSpace=k,t.isMdAsciiPunct=_,t.isPunctChar=y,t.escapeRE=v,t.normalizeReference=x,t.fixBrokenSurrogates=m},{"./entities":1,"uc.micro/categories/P/regex":51}],6:[function(e,r,t){"use strict";t.parseLinkLabel=e("./parse_link_label"),t.parseLinkDestination=e("./parse_link_destination"),t.parseLinkTitle=e("./parse_link_title")},{"./parse_link_destination":7,"./parse_link_label":8,"./parse_link_title":9}],7:[function(e,r){"use strict";var t=e("../common/utils").normalizeLink,n=e("../common/utils").unescapeMd;r.exports=function(e,r,s){var i,o,a=0,l=r,c={ok:!1,pos:0,lines:0,str:""};if(60===e.charCodeAt(r)){for(r++;s>r;){if(i=e.charCodeAt(r),10===i)return c;if(62===i)return c.pos=r+1,c.str=t(n(e.slice(l+1,r))),c.ok=!0,c;92===i&&s>r+1?r+=2:r++}return c}for(o=0;s>r&&(i=e.charCodeAt(r),32!==i)&&!(32>i||127===i);)if(92===i&&s>r+1)r+=2;else{if(40===i&&(o++,o>1))break;if(41===i&&(o--,0>o))break;r++}return l===r?c:(c.str=t(n(e.slice(l,r))),c.lines=a,c.pos=r,c.ok=!0,c)}},{"../common/utils":5}],8:[function(e,r){"use strict";r.exports=function(e,r,t){var n,s,i,o,a=-1,l=e.posMax,c=e.pos;for(e.pos=r+1,n=1;e.pos=n)return l;if(i=e.charCodeAt(r),34!==i&&39!==i&&40!==i)return l;for(r++,40===i&&(i=41);n>r;){if(s=e.charCodeAt(r),s===i)return l.pos=r+1,l.lines=o,l.str=t(e.slice(a+1,r)),l.ok=!0,l;10===s?o++:92===s&&n>r+1&&(r++,10===e.charCodeAt(r)&&o++),r++}return l}},{"../common/utils":5}],10:[function(e,r){"use strict";function t(e,r){return this instanceof t?(r||n.isString(e)||(r=e||{},e="default"),this.inline=new l,this.block=new a,this.core=new o,this.renderer=new i,this.utils=n,this.helpers=s,this.options={},this.configure(e),void(r&&this.set(r))):new t(e,r)}var n=e("./common/utils"),s=e("./helpers"),i=e("./renderer"),o=e("./parser_core"),a=e("./parser_block"),l=e("./parser_inline"),c={"default":e("./presets/default"),zero:e("./presets/zero"),commonmark:e("./presets/commonmark")};t.prototype.set=function(e){return n.assign(this.options,e),this},t.prototype.configure=function(e){var r,t=this;if(n.isString(e)&&(r=e,e=c[r],!e))throw new Error('Wrong `markdown-it` preset "'+r+'", check name');if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach(function(r){e.components[r].rules&&t[r].ruler.enableOnly(e.components[r].rules)}),this},t.prototype.enable=function(e,r){var t=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(r){t=t.concat(this[r].ruler.enable(e,!0))},this);var n=e.filter(function(e){return t.indexOf(e)<0});if(n.length&&!r)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+n);return this},t.prototype.disable=function(e,r){var t=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(r){t=t.concat(this[r].ruler.disable(e,!0))},this);var n=e.filter(function(e){return t.indexOf(e)<0});if(n.length&&!r)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+n);return this},t.prototype.use=function(e){var r=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,r),this},t.prototype.parse=function(e,r){var t=new this.core.State(e,this,r);return this.core.process(t),t.tokens},t.prototype.render=function(e,r){return r=r||{},this.renderer.render(this.parse(e,r),this.options,r)},t.prototype.parseInline=function(e,r){var t=new this.core.State(e,this,r);return t.inlineMode=!0,this.core.process(t),t.tokens},t.prototype.renderInline=function(e,r){return r=r||{},this.renderer.render(this.parseInline(e,r),this.options,r)},r.exports=t},{"./common/utils":5,"./helpers":6,"./parser_block":11,"./parser_core":12,"./parser_inline":13,"./presets/commonmark":14,"./presets/default":15,"./presets/zero":16,"./renderer":17}],11:[function(e,r){"use strict";function t(){this.ruler=new n;for(var e=0;ea&&(e.line=a=e.skipEmptyLines(a),!(a>=t))&&!(e.tShift[a]=c){e.line=t;break}for(s=0;o>s&&!(n=i[s](e,a,t,!1));s++);if(e.tight=!l,e.isEmpty(e.line-1)&&(l=!0),a=e.line,t>a&&e.isEmpty(a)){if(l=!0,a++,t>a&&"list"===e.parentType&&e.isEmpty(a))break;e.line=a}}},t.prototype.parse=function(e,r,t,n){var s;return e?(s=new this.State(e,r,t,n),void this.tokenize(s,s.line,s.lineMax)):[]},t.prototype.State=e("./rules_block/state_block"),r.exports=t},{"./ruler":18,"./rules_block/blockquote":19,"./rules_block/code":20,"./rules_block/fence":21,"./rules_block/heading":22,"./rules_block/hr":23,"./rules_block/html_block":24,"./rules_block/lheading":25,"./rules_block/list":26,"./rules_block/paragraph":27,"./rules_block/reference":28,"./rules_block/state_block":29,"./rules_block/table":30}],12:[function(e,r){"use strict";function t(){this.ruler=new n;for(var e=0;er;r++)n[r](e)},t.prototype.State=e("./rules_core/state_core"),r.exports=t},{"./ruler":18,"./rules_core/block":31,"./rules_core/inline":32,"./rules_core/linkify":33,"./rules_core/normalize":34,"./rules_core/replacements":35,"./rules_core/smartquotes":36,"./rules_core/state_core":37}],13:[function(e,r){"use strict";function t(e){var r=i(e);return r=r.trim().toLowerCase(),r.indexOf(":")>=0&&a.indexOf(r.split(":")[0])>=0?!1:!0}function n(){this.validateLink=t,this.ruler=new s;for(var e=0;e0)return void(e.pos=t);if(e.levelr;r++)if(s[r](e,!0))return void e.cacheSet(n,e.pos);e.pos++,e.cacheSet(n,e.pos)},n.prototype.tokenize=function(e){for(var r,t,n=this.ruler.getRules(""),s=n.length,i=e.posMax,o=e.md.options.maxNesting;e.post&&!(r=n[t](e,!1));t++);if(r){if(e.pos>=i)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},n.prototype.parse=function(e,r,t,n){var s=new this.State(e,r,t,n);this.tokenize(s)},n.prototype.State=e("./rules_inline/state_inline"),r.exports=n},{"./common/utils":5,"./ruler":18,"./rules_inline/autolink":38,"./rules_inline/backticks":39,"./rules_inline/emphasis":40,"./rules_inline/entity":41,"./rules_inline/escape":42,"./rules_inline/html_inline":43,"./rules_inline/image":44,"./rules_inline/link":45,"./rules_inline/newline":46,"./rules_inline/state_inline":47,"./rules_inline/strikethrough":48,"./rules_inline/text":49}],14:[function(e,r){"use strict";r.exports={options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"]}}}},{}],15:[function(e,r){"use strict";r.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{},block:{},inline:{}}}},{}],16:[function(e,r){"use strict";r.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["paragraph"]},inline:{rules:["text"]}}}},{}],17:[function(e,r){"use strict";function t(){this.rules=n({},a)}var n=e("./common/utils").assign,s=e("./common/utils").unescapeMd,i=e("./common/utils").replaceEntities,o=e("./common/utils").escapeHtml,a={};a.blockquote_open=function(){return"
\n"},a.blockquote_close=function(){return"
\n"},a.code_block=function(e,r){return"
"+o(e[r].content)+"
\n"},a.code_inline=function(e,r){return""+o(e[r].content)+""},a.fence=function(e,r,t){var n,a=e[r],l="",c=t.langPrefix,u="";return a.params&&(u=o(i(s(a.params.split(/\s+/g)[0]))),l=' class="'+c+u+'"'),n=t.highlight?t.highlight(a.content,u)||o(a.content):o(a.content),"
"+n+"
\n"},a.heading_open=function(e,r){return""},a.heading_close=function(e,r){return"\n"},a.hr=function(e,r,t){return t.xhtmlOut?"
\n":"
\n"},a.bullet_list_open=function(){return"
    \n"},a.bullet_list_close=function(){return"
\n"},a.list_item_open=function(e,r){var t=e[r+1];return"list_item_close"===t.type||"paragraph_open"===t.type&&t.tight?"
  • ":"
  • \n"},a.list_item_close=function(){return"
  • \n"},a.ordered_list_open=function(e,r){return e[r].order>1?'
      \n':"
        \n"},a.ordered_list_close=function(){return"
      \n"},a.paragraph_open=function(e,r){return e[r].tight?"":"

      "},a.paragraph_close=function(e,r){return e[r].tight===!0?"close"===e[r+1].type.slice(-5)?"":"\n":"

      \n"},a.link_open=function(e,r){var t=e[r].title?' title="'+o(i(e[r].title))+'"':"",n=e[r].target?' target="'+o(e[r].target)+'"':"";return'"},a.link_close=function(){return""},a.image=function(e,r,t,n,s){var a=' src="'+o(e[r].src)+'"',l=e[r].title?' title="'+o(i(e[r].title))+'"':"",c=' alt="'+s.renderInlineAsText(e[r].tokens,t,n)+'"',u=t.xhtmlOut?" /":"";return""},a.table_open=function(){return"\n"},a.table_close=function(){return"
      \n"},a.thead_open=function(){return"\n"},a.thead_close=function(){return"\n"},a.tbody_open=function(){return"\n"},a.tbody_close=function(){return"\n"},a.tr_open=function(){return""},a.tr_close=function(){return"\n"},a.th_open=function(e,r){return e[r].align?'':""},a.th_close=function(){return""},a.td_open=function(e,r){return e[r].align?'':""},a.td_close=function(){return""},a.strong_open=function(){return""},a.strong_close=function(){return""},a.em_open=function(){return""},a.em_close=function(){return""},a.s_open=function(){return""},a.s_close=function(){return""},a.hardbreak=function(e,r,t){return t.xhtmlOut?"
      \n":"
      \n"},a.softbreak=function(e,r,t){return t.breaks?t.xhtmlOut?"
      \n":"
      \n":"\n"},a.text=function(e,r){return o(e[r].content)},a.html_block=function(e,r){return e[r].content},a.html_inline=function(e,r){return e[r].content},t.prototype.renderInline=function(e,r,t){for(var n="",s=this.rules,i=0,o=e.length;o>i;i++)n+=s[e[i].type](e,i,r,t,this);return n},t.prototype.renderInlineAsText=function(e,r,t){for(var n="",s=this.rules,i=0,o=e.length;o>i;i++)"text"===e[i].type?n+=s.text(e,i,r,t,this):"image"===e[i].type&&(n+=this.renderInlineAsText(e[i].tokens,r,t));return n},t.prototype.render=function(e,r,t){var n,s,i="",o=this.rules;for(n=0,s=e.length;s>n;n++)i+="inline"===e[n].type?this.renderInline(e[n].children,r,t):o[e[n].type](e,n,r,t,this);return i},r.exports=t},{"./common/utils":5}],18:[function(e,r){"use strict";function t(){this.__rules__=[],this.__cache__=null}t.prototype.__find__=function(e){for(var r=0;rn){if(r)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[n].enabled=!0,t.push(e)},this),this.__cache__=null,t},t.prototype.enableOnly=function(e,r){Array.isArray(e)||(e=[e]),this.__rules__.forEach(function(e){e.enabled=!1}),this.enable(e,r)},t.prototype.disable=function(e,r){Array.isArray(e)||(e=[e]);var t=[];return e.forEach(function(e){var n=this.__find__(e);if(0>n){if(r)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[n].enabled=!1,t.push(e)},this),this.__cache__=null,t},t.prototype.getRules=function(e){return null===this.__cache__&&this.__compile__(),this.__cache__[e]||[]},r.exports=t},{}],19:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,a,l,c,u,p,h,f,d,g=e.bMarks[r]+e.tShift[r],m=e.eMarks[r];if(62!==e.src.charCodeAt(g++))return!1;if(n)return!0;for(32===e.src.charCodeAt(g)&&g++,l=e.blkIndent,e.blkIndent=0,a=[e.bMarks[r]],e.bMarks[r]=g,g=m>g?e.skipSpaces(g):g,i=g>=m,o=[e.tShift[r]],e.tShift[r]=g-e.bMarks[r],p=e.md.block.ruler.getRules("blockquote"),s=r+1;t>s&&(g=e.bMarks[s]+e.tShift[s],m=e.eMarks[s],!(g>=m));s++)if(62!==e.src.charCodeAt(g++)){if(i)break;for(d=!1,h=0,f=p.length;f>h;h++)if(p[h](e,s,t,!0)){d=!0;break}if(d)break;a.push(e.bMarks[s]),o.push(e.tShift[s]),e.tShift[s]=-1337}else 32===e.src.charCodeAt(g)&&g++,a.push(e.bMarks[s]),e.bMarks[s]=g,g=m>g?e.skipSpaces(g):g,i=g>=m,o.push(e.tShift[s]),e.tShift[s]=g-e.bMarks[s];for(c=e.parentType,e.parentType="blockquote",e.tokens.push({type:"blockquote_open",lines:u=[r,0],level:e.level++}),e.md.block.tokenize(e,r,s),e.tokens.push({type:"blockquote_close",level:--e.level}),e.parentType=c,u[1]=e.line,h=0;hn;)if(e.isEmpty(n))n++;else{if(!(e.tShift[n]-e.blkIndent>=4))break;n++,s=n}return e.line=n,e.tokens.push({type:"code_block",content:e.getLines(r,s,4+e.blkIndent,!0),lines:[r,e.line],level:e.level}),!0}},{}],21:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,a,l,c=!1,u=e.bMarks[r]+e.tShift[r],p=e.eMarks[r];if(u+3>p)return!1;if(s=e.src.charCodeAt(u),126!==s&&96!==s)return!1;if(l=u,u=e.skipChars(u,s),i=u-l,3>i)return!1;if(o=e.src.slice(u,p).trim(),o.indexOf("`")>=0)return!1;if(n)return!0;for(a=r;(a++,!(a>=t))&&(u=l=e.bMarks[a]+e.tShift[a],p=e.eMarks[a],!(p>u&&e.tShift[a]=4||(u=e.skipChars(u,s),i>u-l||(u=e.skipSpaces(u),p>u)))){c=!0;break}return i=e.tShift[r],e.line=a+(c?1:0),e.tokens.push({type:"fence",params:o,content:e.getLines(r+1,a,i,!0),lines:[r,e.line],level:e.level}),!0}},{}],22:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,a=e.bMarks[r]+e.tShift[r],l=e.eMarks[r];if(s=e.src.charCodeAt(a),35!==s||a>=l)return!1;for(i=1,s=e.src.charCodeAt(++a);35===s&&l>a&&6>=i;)i++,s=e.src.charCodeAt(++a);return i>6||l>a&&32!==s?!1:n?!0:(l=e.skipCharsBack(l,32,a),o=e.skipCharsBack(l,35,a),o>a&&32===e.src.charCodeAt(o-1)&&(l=o),e.line=r+1,e.tokens.push({type:"heading_open",hLevel:i,lines:[r,e.line],level:e.level}),l>a&&e.tokens.push({type:"inline",content:e.src.slice(a,l).trim(),level:e.level+1,lines:[r,e.line],children:[]}),e.tokens.push({type:"heading_close",hLevel:i,level:e.level}),!0)}},{}],23:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,a=e.bMarks[r]+e.tShift[r],l=e.eMarks[r];if(s=e.src.charCodeAt(a++),42!==s&&45!==s&&95!==s)return!1;for(i=1;l>a;){if(o=e.src.charCodeAt(a++),o!==s&&32!==o)return!1;o===s&&i++}return 3>i?!1:n?!0:(e.line=r+1,e.tokens.push({type:"hr",lines:[r,e.line],level:e.level}),!0)}},{}],24:[function(e,r){"use strict";function t(e){var r=32|e;return r>=97&&122>=r}var n=e("../common/html_blocks"),s=/^<([a-zA-Z]{1,15})[\s\/>]/,i=/^<\/([a-zA-Z]{1,15})[\s>]/;r.exports=function(e,r,o,a){var l,c,u,p=e.bMarks[r],h=e.eMarks[r],f=e.tShift[r];if(p+=f,!e.md.options.html)return!1;if(f>3||p+2>=h)return!1;if(60!==e.src.charCodeAt(p))return!1;if(l=e.src.charCodeAt(p+1),33===l||63===l){if(a)return!0}else{if(47!==l&&!t(l))return!1;if(47===l){if(c=e.src.slice(p,h).match(i),!c)return!1}else if(c=e.src.slice(p,h).match(s),!c)return!1;if(n[c[1].toLowerCase()]!==!0)return!1;if(a)return!0}for(u=r+1;u=t?!1:e.tShift[o]3?!1:(s=e.bMarks[o]+e.tShift[o],i=e.eMarks[o],s>=i?!1:(n=e.src.charCodeAt(s),45!==n&&61!==n?!1:(s=e.skipChars(s,n),s=e.skipSpaces(s),i>s?!1:(s=e.bMarks[r]+e.tShift[r],e.line=o+1,e.tokens.push({type:"heading_open",hLevel:61===n?1:2,lines:[r,e.line],level:e.level}),e.tokens.push({type:"inline",content:e.src.slice(s,e.eMarks[r]).trim(),level:e.level+1,lines:[r,e.line-1],children:[]}),e.tokens.push({type:"heading_close",hLevel:61===n?1:2,level:e.level}),!0))))}},{}],26:[function(e,r){"use strict";function t(e,r){var t,n,s;return n=e.bMarks[r]+e.tShift[r],s=e.eMarks[r],t=e.src.charCodeAt(n++),42!==t&&45!==t&&43!==t?-1:s>n&&32!==e.src.charCodeAt(n)?-1:n}function n(e,r){var t,n=e.bMarks[r]+e.tShift[r],s=e.eMarks[r];if(n+1>=s)return-1;if(t=e.src.charCodeAt(n++),48>t||t>57)return-1;for(;;){if(n>=s)return-1;if(t=e.src.charCodeAt(n++),!(t>=48&&57>=t)){if(41===t||46===t)break;return-1}}return s>n&&32!==e.src.charCodeAt(n)?-1:n}function s(e,r){var t,n,s=e.level+2;for(t=r+2,n=e.tokens.length-2;n>t;t++)e.tokens[t].level===s&&"paragraph_open"===e.tokens[t].type&&(e.tokens[t+2].tight=!0,e.tokens[t].tight=!0,t+=2)}r.exports=function(e,r,i,o){var a,l,c,u,p,h,f,d,g,m,b,v,k,y,_,x,A,w,q,C,D,E,S=!0;if((d=n(e,r))>=0)k=!0;else{if(!((d=t(e,r))>=0))return!1;k=!1}if(v=e.src.charCodeAt(d-1),o)return!0;for(_=e.tokens.length,k?(f=e.bMarks[r]+e.tShift[r],b=Number(e.src.substr(f,d-f-1)),e.tokens.push({type:"ordered_list_open",order:b,lines:A=[r,0],level:e.level++})):e.tokens.push({type:"bullet_list_open",lines:A=[r,0],level:e.level++}),a=r,x=!1,q=e.md.block.ruler.getRules("list");!(!(i>a)||(y=e.skipSpaces(d),g=e.eMarks[a],m=y>=g?1:y-d,m>4&&(m=1),l=d-e.bMarks[a]+m,e.tokens.push({type:"list_item_open",lines:w=[r,0],level:e.level++}),u=e.blkIndent,p=e.tight,c=e.tShift[r],h=e.parentType,e.tShift[r]=y-e.bMarks[r],e.blkIndent=l,e.tight=!0,e.parentType="list",e.md.block.tokenize(e,r,i,!0),(!e.tight||x)&&(S=!1),x=e.line-r>1&&e.isEmpty(e.line-1),e.blkIndent=u,e.tShift[r]=c,e.tight=p,e.parentType=h,e.tokens.push({type:"list_item_close",level:--e.level}),a=r=e.line,w[1]=a,y=e.bMarks[r],a>=i)||e.isEmpty(a)||e.tShift[a]C;C++)if(q[C](e,a,i,!0)){E=!0;break}if(E)break;if(k){if(d=n(e,a),0>d)break}else if(d=t(e,a),0>d)break;if(v!==e.src.charCodeAt(d-1))break}return e.tokens.push({type:k?"ordered_list_close":"bullet_list_close",level:--e.level}),A[1]=a,e.line=a,S&&s(e,_),!0}},{}],27:[function(e,r){"use strict";r.exports=function(e,r){var t,n,s,i,o,a,l=r+1;if(t=e.lineMax,t>l&&!e.isEmpty(l))for(a=e.md.block.ruler.getRules("paragraph");t>l&&!e.isEmpty(l);l++)if(!(e.tShift[l]-e.blkIndent>3)){for(s=!1,i=0,o=a.length;o>i;i++)if(a[i](e,l,t,!0)){s=!0;break}if(s)break}return n=e.getLines(r,l,e.blkIndent,!1).trim(),e.line=l,e.tokens.push({type:"paragraph_open",tight:!1,lines:[r,e.line],level:e.level}),e.tokens.push({type:"inline",content:n,level:e.level+1,lines:[r,e.line],children:[]}),e.tokens.push({type:"paragraph_close",tight:!1,level:e.level}),!0}},{}],28:[function(e,r){"use strict";var t=e("../helpers/parse_link_destination"),n=e("../helpers/parse_link_title"),s=e("../common/utils").normalizeReference;r.exports=function(e,r,i,o){var a,l,c,u,p,h,f,d,g,m,b,v,k,y,_,x=0,A=e.bMarks[r]+e.tShift[r],w=e.eMarks[r],q=r+1;if(91!==e.src.charCodeAt(A))return!1;for(;++Aq&&!e.isEmpty(q))for(y=e.md.block.ruler.getRules("reference");u>q&&!e.isEmpty(q);q++)if(!(e.tShift[q]-e.blkIndent>3)){for(k=!1,h=0,f=y.length;f>h;h++)if(y[h](e,q,u,!0)){k=!0;break}if(k)break}for(v=e.getLines(r,q,e.blkIndent,!1).trim(),w=v.length,A=1;w>A;A++){if(a=v.charCodeAt(A),91===a)return!1;if(93===a){g=A;break}10===a?x++:92===a&&(A++,w>A&&10===v.charCodeAt(A)&&x++)}if(0>g||58!==v.charCodeAt(g+1))return!1;for(A=g+2;w>A;A++)if(a=v.charCodeAt(A),10===a)x++;else if(32!==a)break;if(m=t(v,A,w),!m.ok)return!1;if(!e.md.inline.validateLink(m.str))return!1;for(p=m.str,A=m.pos,x+=m.lines,l=A,c=x,b=A;w>A;A++)if(a=v.charCodeAt(A),10===a)x++;else if(32!==a)break;for(m=n(v,A,w),w>A&&b!==A&&m.ok?(_=m.str,A=m.pos,x+=m.lines):(_="",A=l,x=c);w>A&&32===v.charCodeAt(A);)A++;return w>A&&10!==v.charCodeAt(A)?!1:o?!0:(d=s(v.slice(1,g)),"undefined"==typeof e.env.references&&(e.env.references={}),"undefined"==typeof e.env.references[d]&&(e.env.references[d]={title:_,href:p}),e.line=r+x+1,!0)}},{"../common/utils":5,"../helpers/parse_link_destination":7,"../helpers/parse_link_title":9}],29:[function(e,r){"use strict";function t(e,r,t,n){var s,i,o,a,l,c,u;for(this.src=e,this.md=r,this.env=t,this.tokens=n,this.bMarks=[],this.eMarks=[],this.tShift=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.parentType="root",this.ddIndent=-1,this.level=0,this.result="",i=this.src,c=0,u=!1,o=a=c=0,l=i.length;l>a;a++){if(s=i.charCodeAt(a),!u){if(32===s){c++;continue}u=!0}(10===s||a===l-1)&&(10!==s&&a++,this.bMarks.push(o),this.eMarks.push(a),this.tShift.push(c),u=!1,c=0,o=a+1)}this.bMarks.push(i.length),this.eMarks.push(i.length),this.tShift.push(0),this.lineMax=this.bMarks.length-1}t.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},t.prototype.skipEmptyLines=function(e){for(var r=this.lineMax;r>e&&!(this.bMarks[e]+this.tShift[e]e&&32===this.src.charCodeAt(e);e++);return e},t.prototype.skipChars=function(e,r){for(var t=this.src.length;t>e&&this.src.charCodeAt(e)===r;e++);return e},t.prototype.skipCharsBack=function(e,r,t){if(t>=e)return e;for(;e>t;)if(r!==this.src.charCodeAt(--e))return e+1;return e},t.prototype.getLines=function(e,r,t,n){var s,i,o,a,l,c=e;if(e>=r)return"";if(c+1===r)return i=this.bMarks[c]+Math.min(this.tShift[c],t),o=n?this.bMarks[r]:this.eMarks[r-1],this.src.slice(i,o);for(a=new Array(r-e),s=0;r>c;c++,s++)l=this.tShift[c],l>t&&(l=t),0>l&&(l=0),i=this.bMarks[c]+l,o=r>c+1||n?this.eMarks[c]+1:this.eMarks[c],a[s]=this.src.slice(i,o);return a.join("")},r.exports=t},{}],30:[function(e,r){"use strict";function t(e,r){var t=e.bMarks[r]+e.blkIndent,n=e.eMarks[r];return e.src.substr(t,n-t)}function n(e){var r,t=[],n=0,s=e.length,i=0,o=0;for(r=e.charCodeAt(n);s>n;)124===r&&i%2===0?(t.push(e.substring(o,n)),o=n+1):92===r?i++:i=0,r=e.charCodeAt(++n);return t.push(e.substring(o)),t}r.exports=function(e,r,s,i){var o,a,l,c,u,p,h,f,d,g;if(r+2>s)return!1;if(u=r+1,e.tShift[u]=e.eMarks[u])return!1;if(o=e.src.charCodeAt(l),124!==o&&45!==o&&58!==o)return!1;if(a=t(e,r+1),!/^[-:| ]+$/.test(a))return!1;if(p=a.split("|"),p.length<2)return!1;for(h=[],c=0;cu&&!(e.tShift[u]t;t++)r=s[t],"inline"===r.type&&e.md.inline.parse(r.content,e.md,e.env,r.children)}},{}],33:[function(e,r){"use strict";function t(e){return/^\s]/i.test(e)}function n(e){return/^<\/a\s*>/i.test(e)}function s(){var e=[],r=new i({stripPrefix:!1,url:!0,email:!0,twitter:!1,replaceFn:function(r,t){switch(t.getType()){case"url":e.push({text:t.matchedText,url:t.getUrl()});break;case"email":e.push({text:t.matchedText,url:"mailto:"+t.getEmail().replace(/^mailto:/i,"")})}return!1}});return{links:e,autolinker:r}}var i=e("autolinker"),o=e("../common/utils").arrayReplaceAt,a=/www|@|\:\/\//;r.exports=function(e){var r,i,l,c,u,p,h,f,d,g,m,b,v,k=e.tokens,y=null;if(e.md.options.linkify)for(i=0,l=k.length;l>i;i++)if("inline"===k[i].type)for(c=k[i].children,m=0,r=c.length-1;r>=0;r--)if(u=c[r],"link_close"!==u.type){if("html_inline"===u.type&&(t(u.content)&&m>0&&m--,n(u.content)&&m++),!(m>0)&&"text"===u.type&&a.test(u.content)){if(y||(y=s(),b=y.links,v=y.autolinker),p=u.content,b.length=0,v.link(p),!b.length)continue;for(h=[],g=u.level,f=0;f=0&&(i=0,o=0,r=r.replace(t,function(e,t){var n;return 10===r.charCodeAt(t)?(i=t+1,o=0,e):(n=" ".slice((t-i-o)%4),o=t-i+1,n)})),e.src=r}},{}],35:[function(e,r){"use strict";function t(e){return e.indexOf("(")<0?e:e.replace(s,function(e,r){return i[r.toLowerCase()]})}var n=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,s=/\((c|tm|r|p)\)/gi,i={c:"\xa9",r:"\xae",p:"\xa7",tm:"\u2122"};r.exports=function(e){var r,s,i,o,a;if(e.md.options.typographer)for(a=e.tokens.length-1;a>=0;a--)if("inline"===e.tokens[a].type)for(o=e.tokens[a].children,r=o.length-1;r>=0;r--)s=o[r],"text"===s.type&&(i=s.content,i=t(i),n.test(i)&&(i=i.replace(/\+-/g,"\xb1").replace(/\.{2,}/g,"\u2026").replace(/([?!])\u2026/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---([^-]|$)/gm,"$1\u2014$2").replace(/(^|\s)--(\s|$)/gm,"$1\u2013$2").replace(/(^|[^-\s])--([^-\s]|$)/gm,"$1\u2013$2")),s.content=i)}},{}],36:[function(e,r){"use strict";function t(e,r){return 0>r||r>=e.length?!1:!o.test(e[r])}function n(e,r,t){return e.substr(0,r)+t+e.substr(r+1)}var s=/['"]/,i=/['"]/g,o=/[-\s()\[\]]/,a="\u2019";r.exports=function(e){var r,o,l,c,u,p,h,f,d,g,m,b,v,k,y,_,x;if(e.md.options.typographer)for(x=[],y=e.tokens.length-1;y>=0;y--)if("inline"===e.tokens[y].type)for(_=e.tokens[y].children,x.length=0,r=0;r<_.length;r++)if(o=_[r],"text"===o.type&&!s.test(o.text)){for(h=_[r].level,v=x.length-1;v>=0&&!(x[v].level<=h);v--);x.length=v+1,l=o.content,u=0,p=l.length;e:for(;p>u&&(i.lastIndex=u,c=i.exec(l));)if(f=!t(l,c.index-1),u=c.index+1,k="'"===c[0],d=!t(l,u),d||f){if(m=!d,b=!f)for(v=x.length-1;v>=0&&(g=x[v],!(x[v].level/,i=/^<([a-zA-Z.\-]{1,25}):([^<>\x00-\x20]*)>/;r.exports=function(e,r){var o,a,l,c,u,p=e.pos;return 60!==e.src.charCodeAt(p)?!1:(o=e.src.slice(p),o.indexOf(">")<0?!1:(a=o.match(i))?t.indexOf(a[1].toLowerCase())<0?!1:(c=a[0].slice(1,-1),u=n(c),e.md.inline.validateLink(c)?(r||(e.push({type:"link_open",href:u,target:"",level:e.level}),e.push({type:"text",content:c,level:e.level+1}),e.push({type:"link_close",level:e.level})),e.pos+=a[0].length,!0):!1):(l=o.match(s),l?(c=l[0].slice(1,-1),u=n("mailto:"+c),e.md.inline.validateLink(u)?(r||(e.push({type:"link_open",href:u,target:"",level:e.level}),e.push({type:"text",content:c,level:e.level+1}),e.push({type:"link_close",level:e.level})),e.pos+=l[0].length,!0):!1):!1))}},{"../common/url_schemas":4,"../common/utils":5}],39:[function(e,r){"use strict";r.exports=function(e,r){var t,n,s,i,o,a=e.pos,l=e.src.charCodeAt(a);if(96!==l)return!1;for(t=a,a++,n=e.posMax;n>a&&96===e.src.charCodeAt(a);)a++;for(s=e.src.slice(t,a),i=o=a;-1!==(i=e.src.indexOf("`",o));){for(o=i+1;n>o&&96===e.src.charCodeAt(o);)o++;if(o-i===s.length)return r||e.push({type:"code_inline",content:e.src.slice(a,i).replace(/[ \n]+/g," ").trim(),level:e.level}),e.pos=o,!0}return r||(e.pending+=s),e.pos+=s.length,!0}},{}],40:[function(e,r){"use strict";function t(e){return e>=48&&57>=e||e>=65&&90>=e||e>=97&&122>=e}function n(e,r){var n,a,l,c,u,p,h,f=r,d=!0,g=!0,m=e.posMax,b=e.src.charCodeAt(r);for(n=r>0?e.src.charCodeAt(r-1):-1;m>f&&e.src.charCodeAt(f)===b;)f++;return f>=m&&(d=!1),l=f-r,a=m>f?e.src.charCodeAt(f):-1,u=n>=0&&(o(n)||i(String.fromCharCode(n))),h=a>=0&&(o(a)||i(String.fromCharCode(a))),c=n>=0&&s(n),p=a>=0&&s(a),p?d=!1:h&&(c||u||-1===n||(d=!1)),c?g=!1:u&&(p||h||-1===a||(g=!1)),95===b&&(t(n)&&(d=!1),t(a)&&(g=!1)),{can_open:d,can_close:g,delims:l}}var s=e("../common/utils").isWhiteSpace,i=e("../common/utils").isPunctChar,o=e("../common/utils").isMdAsciiPunct;r.exports=function(e,r){var t,s,i,o,a,l,c,u=e.posMax,p=e.pos,h=e.src.charCodeAt(p);if(95!==h&&42!==h)return!1;if(r)return!1;if(c=n(e,p),t=c.delims,!c.can_open)return e.pos+=t,e.pending+=e.src.slice(p,e.pos),!0;for(e.pos=p+t,l=[t];e.posa){l.push(o-a);break}if(a-=o,0===l.length)break;e.pos+=o,o=l.pop()}if(0===l.length){t=o,i=!0;break}e.pos+=s;continue}c.can_open&&l.push(s),e.pos+=s}if(!i)return e.pos=p,!1;for(e.posMax=e.pos,e.pos=p+t,s=t;s>1;s-=2)e.push({type:"strong_open",level:e.level++});for(s%2&&e.push({type:"em_open",level:e.level++}),e.md.inline.tokenize(e),s%2&&e.push({type:"em_close",level:--e.level}),s=t;s>1;s-=2)e.push({type:"strong_close",level:--e.level});return e.pos=e.posMax+t,e.posMax=u,!0}},{"../common/utils":5}],41:[function(e,r){"use strict";var t=e("../common/entities"),n=e("../common/utils").has,s=e("../common/utils").isValidEntityCode,i=e("../common/utils").fromCodePoint,o=/^&#((?:x[a-f0-9]{1,8}|[0-9]{1,8}));/i,a=/^&([a-z][a-z0-9]{1,31});/i;r.exports=function(e,r){var l,c,u,p=e.pos,h=e.posMax;if(38!==e.src.charCodeAt(p))return!1;if(h>p+1)if(l=e.src.charCodeAt(p+1),35===l){if(u=e.src.slice(p).match(o))return r||(c="x"===u[1][0].toLowerCase()?parseInt(u[1].slice(1),16):parseInt(u[1],10),e.pending+=i(s(c)?c:65533)),e.pos+=u[0].length,!0}else if(u=e.src.slice(p).match(a),u&&n(t,u[1]))return r||(e.pending+=t[u[1]]),e.pos+=u[0].length,!0;return r||(e.pending+="&"),e.pos++,!0}},{"../common/entities":1,"../common/utils":5}],42:[function(e,r){"use strict";for(var t=[],n=0;256>n;n++)t.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){t[e.charCodeAt(0)]=1}),r.exports=function(e,r){var n,s=e.pos,i=e.posMax;if(92!==e.src.charCodeAt(s))return!1;if(s++,i>s){if(n=e.src.charCodeAt(s),256>n&&0!==t[n])return r||(e.pending+=e.src[s]),e.pos+=2,!0;if(10===n){for(r||e.push({type:"hardbreak",level:e.level}),s++;i>s&&32===e.src.charCodeAt(s);)s++;return e.pos=s,!0}}return r||(e.pending+="\\"),e.pos++,!0}},{}],43:[function(e,r){"use strict";function t(e){var r=32|e;return r>=97&&122>=r}var n=e("../common/html_re").HTML_TAG_RE;r.exports=function(e,r){var s,i,o,a=e.pos;return e.md.options.html?(o=e.posMax,60!==e.src.charCodeAt(a)||a+2>=o?!1:(s=e.src.charCodeAt(a+1),(33===s||63===s||47===s||t(s))&&(i=e.src.slice(a).match(n))?(r||e.push({type:"html_inline",content:e.src.slice(a,a+i[0].length),level:e.level}),e.pos+=i[0].length,!0):!1)):!1}},{"../common/html_re":3}],44:[function(e,r){"use strict";var t=e("../helpers/parse_link_label"),n=e("../helpers/parse_link_destination"),s=e("../helpers/parse_link_title"),i=e("../common/utils").normalizeReference;r.exports=function(e,r){var o,a,l,c,u,p,h,f,d,g,m,b=e.pos,v=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;if(u=e.pos+2,c=t(e,e.pos+1,!1),0>c)return!1;if(p=c+1,v>p&&40===e.src.charCodeAt(p)){for(p++;v>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(p>=v)return!1;for(m=p,f=n(e.src,p,e.posMax),f.ok&&e.md.inline.validateLink(f.str)?(a=f.str,p=f.pos):a="",m=p;v>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(f=s(e.src,p,e.posMax),v>p&&m!==p&&f.ok)for(d=f.str,p=f.pos;v>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);else d="";if(p>=v||41!==e.src.charCodeAt(p))return e.pos=b,!1;p++}else{if("undefined"==typeof e.env.references)return!1;for(;v>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(v>p&&91===e.src.charCodeAt(p)?(m=p+1,p=t(e,p),p>=0?l=e.src.slice(m,p++):p=c+1):p=c+1,l||(l=e.src.slice(u,c)),h=e.env.references[i(l)],!h)return e.pos=b,!1;a=h.href,d=h.title}if(!r){e.pos=u,e.posMax=c;var k=new e.md.inline.State(e.src.slice(u,c),e.md,e.env,g=[]);k.md.inline.tokenize(k),e.push({type:"image",src:a,title:d,tokens:g,level:e.level})}return e.pos=p,e.posMax=v,!0}},{"../common/utils":5,"../helpers/parse_link_destination":7,"../helpers/parse_link_label":8,"../helpers/parse_link_title":9}],45:[function(e,r){"use strict";var t=e("../helpers/parse_link_label"),n=e("../helpers/parse_link_destination"),s=e("../helpers/parse_link_title"),i=e("../common/utils").normalizeReference;r.exports=function(e,r){var o,a,l,c,u,p,h,f,d,g=e.pos,m=e.posMax,b=e.pos;if(91!==e.src.charCodeAt(e.pos))return!1;if(u=e.pos+1,c=t(e,e.pos,!0),0>c)return!1;if(p=c+1,m>p&&40===e.src.charCodeAt(p)){for(p++;m>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(p>=m)return!1;for(b=p,h=n(e.src,p,e.posMax),h.ok&&e.md.inline.validateLink(h.str)?(a=h.str,p=h.pos):a="",b=p;m>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(h=s(e.src,p,e.posMax),m>p&&b!==p&&h.ok)for(d=h.str,p=h.pos;m>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);else d="";if(p>=m||41!==e.src.charCodeAt(p))return e.pos=g,!1;p++}else{if("undefined"==typeof e.env.references)return!1;for(;m>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(m>p&&91===e.src.charCodeAt(p)?(b=p+1,p=t(e,p),p>=0?l=e.src.slice(b,p++):p=c+1):p=c+1,l||(l=e.src.slice(u,c)),f=e.env.references[i(l)],!f)return e.pos=g,!1;a=f.href,d=f.title}return r||(e.pos=u,e.posMax=c,e.push({type:"link_open",href:a,target:"",title:d,level:e.level++}),e.md.inline.tokenize(e),e.push({type:"link_close",level:--e.level})),e.pos=p,e.posMax=m,!0}},{"../common/utils":5,"../helpers/parse_link_destination":7,"../helpers/parse_link_label":8,"../helpers/parse_link_title":9}],46:[function(e,r){"use strict";r.exports=function(e,r){var t,n,s=e.pos;if(10!==e.src.charCodeAt(s))return!1;for(t=e.pending.length-1,n=e.posMax,r||(t>=0&&32===e.pending.charCodeAt(t)?t>=1&&32===e.pending.charCodeAt(t-1)?(e.pending=e.pending.replace(/ +$/,""),e.push({type:"hardbreak",level:e.level})):(e.pending=e.pending.slice(0,-1),e.push({type:"softbreak",level:e.level})):e.push({type:"softbreak",level:e.level})),s++;n>s&&32===e.src.charCodeAt(s);)s++;return e.pos=s,!0}},{}],47:[function(e,r){"use strict";function t(e,r,t,n){this.src=e,this.env=t,this.md=r,this.tokens=n,this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache=[]}t.prototype.pushPending=function(){this.tokens.push({type:"text",content:this.pending,level:this.pendingLevel}),this.pending=""},t.prototype.push=function(e){this.pending&&this.pushPending(),this.tokens.push(e),this.pendingLevel=this.level},t.prototype.cacheSet=function(e,r){for(var t=this.cache.length;e>=t;t++)this.cache.push(0);this.cache[e]=r},t.prototype.cacheGet=function(e){return e0?e.src.charCodeAt(r-1):-1;g>h&&e.src.charCodeAt(h)===m;)h++;return h>=g&&(f=!1),a=h-r,o=g>h?e.src.charCodeAt(h):-1,c=t>=0&&(i(t)||s(String.fromCharCode(t))),p=o>=0&&(i(o)||s(String.fromCharCode(o))),l=t>=0&&n(t),u=o>=0&&n(o),u?f=!1:p&&(l||c||-1===t||(f=!1)),l?d=!1:c&&(u||p||-1===o||(d=!1)),{can_open:f,can_close:d,delims:a}}var n=e("../common/utils").isWhiteSpace,s=e("../common/utils").isPunctChar,i=e("../common/utils").isMdAsciiPunct;r.exports=function(e,r){var n,s,i,o,a,l,c=e.posMax,u=e.pos,p=e.src.charCodeAt(u);if(126!==p)return!1;if(r)return!1;if(l=t(e,u),n=l.delims,!l.can_open)return e.pos+=n,e.pending+=e.src.slice(u,e.pos),!0;if(a=Math.floor(n/2),0>=a)return!1;for(e.pos=u+n;e.pos=a){e.pos+=s-2,o=!0;break}a-=i,e.pos+=s;continue}l.can_open&&(a+=i),e.pos+=s}return o?(e.posMax=e.pos,e.pos=u+2,e.push({type:"s_open",level:e.level++}),e.md.inline.tokenize(e),e.push({type:"s_close",level:--e.level}),e.pos=e.posMax+2,e.posMax=c,!0):(e.pos=u,!1)}},{"../common/utils":5}],49:[function(e,r){"use strict";function t(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}r.exports=function(e,r){for(var n=e.pos;na;a++){var c=n[a],u=t.processTextNode(c);o.push(u)}else o.push(r)}}),o.join("")},getHtmlParser:function(){var r=this.htmlParser;return r||(r=this.htmlParser=new e.HtmlParser),r},getTagBuilder:function(){var r=this.tagBuilder;return r||(r=this.tagBuilder=new e.AnchorTagBuilder({newWindow:this.newWindow,truncate:this.truncate,className:this.className})),r},processTextNode:function(e){var r=this;return e.replace(this.matcherRegex,function(e,t,n,s,i,o,a,l,c){var u=r.processCandidateMatch(e,t,n,s,i,o,a,l,c);if(u){var p=r.createMatchReturnVal(u.match,u.matchStr);return u.prefixStr+p+u.suffixStr}return e})},processCandidateMatch:function(r,t,n,s,i,o,a,l,c){var u,p=l||c,h="",f="";if(t&&!this.twitter||i&&!this.email||o&&!this.urls||!this.matchValidator.isValidMatch(o,a,p))return null;if(this.matchHasUnbalancedClosingParen(r)&&(r=r.substr(0,r.length-1),f=")"),i)u=new e.match.Email({matchedText:r,email:i});else if(t)n&&(h=n,r=r.slice(1)),u=new e.match.Twitter({matchedText:r,twitterHandle:s});else{if(p){var d=p.match(this.charBeforeProtocolRelMatchRegex)[1]||"";d&&(h=d,r=r.slice(1))}u=new e.match.Url({matchedText:r,url:r,protocolUrlMatch:!!a,protocolRelativeMatch:!!p,stripPrefix:this.stripPrefix})}return{prefixStr:h,suffixStr:f,matchStr:r,match:u}},matchHasUnbalancedClosingParen:function(e){var r=e.charAt(e.length-1);if(")"===r){var t=e.match(/\(/g),n=e.match(/\)/g),s=t&&t.length||0,i=n&&n.length||0;if(i>s)return!0}return!1},createMatchReturnVal:function(r,t){var n;if(this.replaceFn&&(n=this.replaceFn.call(this,this,r)),"string"==typeof n)return n;if(n===!1)return t;if(n instanceof e.HtmlTag)return n.toString();var s=this.getTagBuilder(),i=s.build(r);return i.toString()}},e.link=function(r,t){var n=new e(t);return n.link(r)},e.match={},e.Util={abstractMethod:function(){throw"abstract"},assign:function(e,r){for(var t in r)r.hasOwnProperty(t)&&(e[t]=r[t]);return e},extend:function(r,t){var n=r.prototype,s=function(){};s.prototype=n;var i;i=t.hasOwnProperty("constructor")?t.constructor:function(){n.constructor.apply(this,arguments)};var o=i.prototype=new s;return o.constructor=i,o.superclass=n,delete t.constructor,e.Util.assign(o,t),i},ellipsis:function(e,r,t){return e.length>r&&(t=null==t?"..":t,e=e.substring(0,r-t.length)+t),e},indexOf:function(e,r){if(Array.prototype.indexOf)return e.indexOf(r);for(var t=0,n=e.length;n>t;t++)if(e[t]===r)return t;return-1},splitAndCapture:function(e,r){if(!r.global)throw new Error("`splitRegex` must have the 'g' flag set");for(var t,n=[],s=0;t=r.exec(e);)n.push(e.substring(s,t.index)),n.push(t[0]),s=t.index+t[0].length;return n.push(e.substring(s)),n}},e.HtmlParser=e.Util.extend(Object,{htmlRegex:function(){var e=/[0-9a-zA-Z][0-9a-zA-Z:]*/,r=/[^\s\0"'>\/=\x01-\x1F\x7F]+/,t=/(?:"[^"]*?"|'[^']*?'|[^'"=<>`\s]+)/,n=r.source+"(?:\\s*=\\s*"+t.source+")?";return new RegExp(["(?:","<(!DOCTYPE)","(?:","\\s+","(?:",n,"|",t.source+")",")*",">",")","|","(?:","<(/)?","("+e.source+")","(?:","\\s+",n,")*","\\s*/?",">",")"].join(""),"gi")}(),parse:function(e,r){r=r||{};for(var t,n=r.processHtmlNode||function(){},s=r.processTextNode||function(){},i=this.htmlRegex,o=0;null!==(t=i.exec(e));){var a=t[0],l=t[1]||t[3],c=!!t[2],u=e.substring(o,t.index);u&&s(u),n(a,l.toLowerCase(),c),o=t.index+a.length}if(o",this.getInnerHtml(),""].join("")},buildAttrsStr:function(){if(!this.attrs)return"";var e=this.getAttrs(),r=[];for(var t in e)e.hasOwnProperty(t)&&r.push(t+'="'+e[t]+'"');return r.join(" ")}}),e.MatchValidator=e.Util.extend(Object,{invalidProtocolRelMatchRegex:/^[\w]\/\//,hasFullProtocolRegex:/^[A-Za-z][-.+A-Za-z0-9]+:\/\//,uriSchemeRegex:/^[A-Za-z][-.+A-Za-z0-9]+:/,hasWordCharAfterProtocolRegex:/:[^\s]*?[A-Za-z]/,isValidMatch:function(e,r,t){return r&&!this.isValidUriScheme(r)||this.urlMatchDoesNotHaveProtocolOrDot(e,r)||this.urlMatchDoesNotHaveAtLeastOneWordChar(e,r)||this.isInvalidProtocolRelativeMatch(t)?!1:!0},isValidUriScheme:function(e){var r=e.match(this.uriSchemeRegex)[0];return"javascript:"!==r&&"vbscript:"!==r},urlMatchDoesNotHaveProtocolOrDot:function(e,r){return!(!e||r&&this.hasFullProtocolRegex.test(r)||-1!==e.indexOf("."))},urlMatchDoesNotHaveAtLeastOneWordChar:function(e,r){return e&&r?!this.hasWordCharAfterProtocolRegex.test(e):!1},isInvalidProtocolRelativeMatch:function(e){return!!e&&this.invalidProtocolRelMatchRegex.test(e)}}),e.AnchorTagBuilder=e.Util.extend(Object,{constructor:function(r){e.Util.assign(this,r)},build:function(r){var t=new e.HtmlTag({tagName:"a",attrs:this.createAttrs(r.getType(),r.getAnchorHref()),innerHtml:this.processAnchorText(r.getAnchorText())});return t},createAttrs:function(e,r){var t={href:r},n=this.createCssClass(e);return n&&(t["class"]=n),this.newWindow&&(t.target="_blank"),t},createCssClass:function(e){var r=this.className;return r?r+" "+r+"-"+e:""},processAnchorText:function(e){return e=this.doTruncate(e)},doTruncate:function(r){return e.Util.ellipsis(r,this.truncate||Number.POSITIVE_INFINITY)}}),e.match.Match=e.Util.extend(Object,{constructor:function(r){e.Util.assign(this,r)},getType:e.Util.abstractMethod,getMatchedText:function(){return this.matchedText},getAnchorHref:e.Util.abstractMethod,getAnchorText:e.Util.abstractMethod}),e.match.Email=e.Util.extend(e.match.Match,{getType:function(){return"email"},getEmail:function(){return this.email},getAnchorHref:function(){return"mailto:"+this.email},getAnchorText:function(){return this.email}}),e.match.Twitter=e.Util.extend(e.match.Match,{getType:function(){return"twitter"},getTwitterHandle:function(){return this.twitterHandle},getAnchorHref:function(){return"https://twitter.com/"+this.twitterHandle},getAnchorText:function(){return"@"+this.twitterHandle}}),e.match.Url=e.Util.extend(e.match.Match,{urlPrefixRegex:/^(https?:\/\/)?(www\.)?/i,protocolRelativeRegex:/^\/\//,protocolPrepended:!1,getType:function(){return"url"},getUrl:function(){var e=this.url;return this.protocolRelativeMatch||this.protocolUrlMatch||this.protocolPrepended||(e=this.url="http://"+e,this.protocolPrepended=!0),e},getAnchorHref:function(){var e=this.getUrl();return e.replace(/&/g,"&")},getAnchorText:function(){var e=this.getUrl();return this.protocolRelativeMatch&&(e=this.stripProtocolRelativePrefix(e)),this.stripPrefix&&(e=this.stripUrlPrefix(e)),e=this.removeTrailingSlash(e)},stripUrlPrefix:function(e){return e.replace(this.urlPrefixRegex,"")},stripProtocolRelativePrefix:function(e){return e.replace(this.protocolRelativeRegex,"")},removeTrailingSlash:function(e){return"/"===e.charAt(e.length-1)&&(e=e.slice(0,-1)),e}}),e})},{}],51:[function(e,r){r.exports=/[!-#%-\*,-/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDE38-\uDE3D]|\uD805[\uDCC6\uDDC1-\uDDC9\uDE41-\uDE43]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F/},{}],52:[function(e,r){"use strict";r.exports=e("./lib/")},{"./lib/":10}]},{},[52])(52)}); \ No newline at end of file +/*! markdown-it 3.1.0 https://github.com//markdown-it/markdown-it @license MIT */ +!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var r;r="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,r.markdownit=e()}}(function(){return function e(r,t,n){function s(o,l){if(!t[o]){if(!r[o]){var a="function"==typeof require&&require;if(!l&&a)return a(o,!0);if(i)return i(o,!0);var c=new Error("Cannot find module '"+o+"'");throw c.code="MODULE_NOT_FOUND",c}var u=t[o]={exports:{}};r[o][0].call(u.exports,function(e){var t=r[o][1][e];return s(t?t:e)},u,u.exports,e,r,t,n)}return t[o].exports}for(var i="function"==typeof require&&require,o=0;o",Gt:"\u226b",gt:">",gtcc:"\u2aa7",gtcir:"\u2a7a",gtdot:"\u22d7",gtlPar:"\u2995",gtquest:"\u2a7c",gtrapprox:"\u2a86",gtrarr:"\u2978",gtrdot:"\u22d7",gtreqless:"\u22db",gtreqqless:"\u2a8c",gtrless:"\u2277",gtrsim:"\u2273",gvertneqq:"\u2269\ufe00",gvnE:"\u2269\ufe00",Hacek:"\u02c7",hairsp:"\u200a",half:"\xbd",hamilt:"\u210b",HARDcy:"\u042a",hardcy:"\u044a",hArr:"\u21d4",harr:"\u2194",harrcir:"\u2948",harrw:"\u21ad",Hat:"^",hbar:"\u210f",Hcirc:"\u0124",hcirc:"\u0125",hearts:"\u2665",heartsuit:"\u2665",hellip:"\u2026",hercon:"\u22b9",Hfr:"\u210c",hfr:"\ud835\udd25",HilbertSpace:"\u210b",hksearow:"\u2925",hkswarow:"\u2926",hoarr:"\u21ff",homtht:"\u223b",hookleftarrow:"\u21a9",hookrightarrow:"\u21aa",Hopf:"\u210d",hopf:"\ud835\udd59",horbar:"\u2015",HorizontalLine:"\u2500",Hscr:"\u210b",hscr:"\ud835\udcbd",hslash:"\u210f",Hstrok:"\u0126",hstrok:"\u0127",HumpDownHump:"\u224e",HumpEqual:"\u224f",hybull:"\u2043",hyphen:"\u2010",Iacute:"\xcd",iacute:"\xed",ic:"\u2063",Icirc:"\xce",icirc:"\xee",Icy:"\u0418",icy:"\u0438",Idot:"\u0130",IEcy:"\u0415",iecy:"\u0435",iexcl:"\xa1",iff:"\u21d4",Ifr:"\u2111",ifr:"\ud835\udd26",Igrave:"\xcc",igrave:"\xec",ii:"\u2148",iiiint:"\u2a0c",iiint:"\u222d",iinfin:"\u29dc",iiota:"\u2129",IJlig:"\u0132",ijlig:"\u0133",Im:"\u2111",Imacr:"\u012a",imacr:"\u012b",image:"\u2111",ImaginaryI:"\u2148",imagline:"\u2110",imagpart:"\u2111",imath:"\u0131",imof:"\u22b7",imped:"\u01b5",Implies:"\u21d2","in":"\u2208",incare:"\u2105",infin:"\u221e",infintie:"\u29dd",inodot:"\u0131",Int:"\u222c","int":"\u222b",intcal:"\u22ba",integers:"\u2124",Integral:"\u222b",intercal:"\u22ba",Intersection:"\u22c2",intlarhk:"\u2a17",intprod:"\u2a3c",InvisibleComma:"\u2063",InvisibleTimes:"\u2062",IOcy:"\u0401",iocy:"\u0451",Iogon:"\u012e",iogon:"\u012f",Iopf:"\ud835\udd40",iopf:"\ud835\udd5a",Iota:"\u0399",iota:"\u03b9",iprod:"\u2a3c",iquest:"\xbf",Iscr:"\u2110",iscr:"\ud835\udcbe",isin:"\u2208",isindot:"\u22f5",isinE:"\u22f9",isins:"\u22f4",isinsv:"\u22f3",isinv:"\u2208",it:"\u2062",Itilde:"\u0128",itilde:"\u0129",Iukcy:"\u0406",iukcy:"\u0456",Iuml:"\xcf",iuml:"\xef",Jcirc:"\u0134",jcirc:"\u0135",Jcy:"\u0419",jcy:"\u0439",Jfr:"\ud835\udd0d",jfr:"\ud835\udd27",jmath:"\u0237",Jopf:"\ud835\udd41",jopf:"\ud835\udd5b",Jscr:"\ud835\udca5",jscr:"\ud835\udcbf",Jsercy:"\u0408",jsercy:"\u0458",Jukcy:"\u0404",jukcy:"\u0454",Kappa:"\u039a",kappa:"\u03ba",kappav:"\u03f0",Kcedil:"\u0136",kcedil:"\u0137",Kcy:"\u041a",kcy:"\u043a",Kfr:"\ud835\udd0e",kfr:"\ud835\udd28",kgreen:"\u0138",KHcy:"\u0425",khcy:"\u0445",KJcy:"\u040c",kjcy:"\u045c",Kopf:"\ud835\udd42",kopf:"\ud835\udd5c",Kscr:"\ud835\udca6",kscr:"\ud835\udcc0",lAarr:"\u21da",Lacute:"\u0139",lacute:"\u013a",laemptyv:"\u29b4",lagran:"\u2112",Lambda:"\u039b",lambda:"\u03bb",Lang:"\u27ea",lang:"\u27e8",langd:"\u2991",langle:"\u27e8",lap:"\u2a85",Laplacetrf:"\u2112",laquo:"\xab",Larr:"\u219e",lArr:"\u21d0",larr:"\u2190",larrb:"\u21e4",larrbfs:"\u291f",larrfs:"\u291d",larrhk:"\u21a9",larrlp:"\u21ab",larrpl:"\u2939",larrsim:"\u2973",larrtl:"\u21a2",lat:"\u2aab",lAtail:"\u291b",latail:"\u2919",late:"\u2aad",lates:"\u2aad\ufe00",lBarr:"\u290e",lbarr:"\u290c",lbbrk:"\u2772",lbrace:"{",lbrack:"[",lbrke:"\u298b",lbrksld:"\u298f",lbrkslu:"\u298d",Lcaron:"\u013d",lcaron:"\u013e",Lcedil:"\u013b",lcedil:"\u013c",lceil:"\u2308",lcub:"{",Lcy:"\u041b",lcy:"\u043b",ldca:"\u2936",ldquo:"\u201c",ldquor:"\u201e",ldrdhar:"\u2967",ldrushar:"\u294b",ldsh:"\u21b2",lE:"\u2266",le:"\u2264",LeftAngleBracket:"\u27e8",LeftArrow:"\u2190",Leftarrow:"\u21d0",leftarrow:"\u2190",LeftArrowBar:"\u21e4",LeftArrowRightArrow:"\u21c6",leftarrowtail:"\u21a2",LeftCeiling:"\u2308",LeftDoubleBracket:"\u27e6",LeftDownTeeVector:"\u2961",LeftDownVector:"\u21c3",LeftDownVectorBar:"\u2959",LeftFloor:"\u230a",leftharpoondown:"\u21bd",leftharpoonup:"\u21bc",leftleftarrows:"\u21c7",LeftRightArrow:"\u2194",Leftrightarrow:"\u21d4",leftrightarrow:"\u2194",leftrightarrows:"\u21c6",leftrightharpoons:"\u21cb",leftrightsquigarrow:"\u21ad",LeftRightVector:"\u294e",LeftTee:"\u22a3",LeftTeeArrow:"\u21a4",LeftTeeVector:"\u295a",leftthreetimes:"\u22cb",LeftTriangle:"\u22b2",LeftTriangleBar:"\u29cf",LeftTriangleEqual:"\u22b4",LeftUpDownVector:"\u2951",LeftUpTeeVector:"\u2960",LeftUpVector:"\u21bf",LeftUpVectorBar:"\u2958",LeftVector:"\u21bc",LeftVectorBar:"\u2952",lEg:"\u2a8b",leg:"\u22da",leq:"\u2264",leqq:"\u2266",leqslant:"\u2a7d",les:"\u2a7d",lescc:"\u2aa8",lesdot:"\u2a7f",lesdoto:"\u2a81",lesdotor:"\u2a83",lesg:"\u22da\ufe00",lesges:"\u2a93",lessapprox:"\u2a85",lessdot:"\u22d6",lesseqgtr:"\u22da",lesseqqgtr:"\u2a8b",LessEqualGreater:"\u22da",LessFullEqual:"\u2266",LessGreater:"\u2276",lessgtr:"\u2276",LessLess:"\u2aa1",lesssim:"\u2272",LessSlantEqual:"\u2a7d",LessTilde:"\u2272",lfisht:"\u297c",lfloor:"\u230a",Lfr:"\ud835\udd0f",lfr:"\ud835\udd29",lg:"\u2276",lgE:"\u2a91",lHar:"\u2962",lhard:"\u21bd",lharu:"\u21bc",lharul:"\u296a",lhblk:"\u2584",LJcy:"\u0409",ljcy:"\u0459",Ll:"\u22d8",ll:"\u226a",llarr:"\u21c7",llcorner:"\u231e",Lleftarrow:"\u21da",llhard:"\u296b",lltri:"\u25fa",Lmidot:"\u013f",lmidot:"\u0140",lmoust:"\u23b0",lmoustache:"\u23b0",lnap:"\u2a89",lnapprox:"\u2a89",lnE:"\u2268",lne:"\u2a87",lneq:"\u2a87",lneqq:"\u2268",lnsim:"\u22e6",loang:"\u27ec",loarr:"\u21fd",lobrk:"\u27e6",LongLeftArrow:"\u27f5",Longleftarrow:"\u27f8",longleftarrow:"\u27f5",LongLeftRightArrow:"\u27f7",Longleftrightarrow:"\u27fa",longleftrightarrow:"\u27f7",longmapsto:"\u27fc",LongRightArrow:"\u27f6",Longrightarrow:"\u27f9",longrightarrow:"\u27f6",looparrowleft:"\u21ab",looparrowright:"\u21ac",lopar:"\u2985",Lopf:"\ud835\udd43",lopf:"\ud835\udd5d",loplus:"\u2a2d",lotimes:"\u2a34",lowast:"\u2217",lowbar:"_",LowerLeftArrow:"\u2199",LowerRightArrow:"\u2198",loz:"\u25ca",lozenge:"\u25ca",lozf:"\u29eb",lpar:"(",lparlt:"\u2993",lrarr:"\u21c6",lrcorner:"\u231f",lrhar:"\u21cb",lrhard:"\u296d",lrm:"\u200e",lrtri:"\u22bf",lsaquo:"\u2039",Lscr:"\u2112",lscr:"\ud835\udcc1",Lsh:"\u21b0",lsh:"\u21b0",lsim:"\u2272",lsime:"\u2a8d",lsimg:"\u2a8f",lsqb:"[",lsquo:"\u2018",lsquor:"\u201a",Lstrok:"\u0141",lstrok:"\u0142",LT:"<",Lt:"\u226a",lt:"<",ltcc:"\u2aa6",ltcir:"\u2a79",ltdot:"\u22d6",lthree:"\u22cb",ltimes:"\u22c9",ltlarr:"\u2976",ltquest:"\u2a7b",ltri:"\u25c3",ltrie:"\u22b4",ltrif:"\u25c2",ltrPar:"\u2996",lurdshar:"\u294a",luruhar:"\u2966",lvertneqq:"\u2268\ufe00",lvnE:"\u2268\ufe00",macr:"\xaf",male:"\u2642",malt:"\u2720",maltese:"\u2720",Map:"\u2905",map:"\u21a6",mapsto:"\u21a6",mapstodown:"\u21a7",mapstoleft:"\u21a4",mapstoup:"\u21a5",marker:"\u25ae",mcomma:"\u2a29",Mcy:"\u041c",mcy:"\u043c",mdash:"\u2014",mDDot:"\u223a",measuredangle:"\u2221",MediumSpace:"\u205f",Mellintrf:"\u2133",Mfr:"\ud835\udd10",mfr:"\ud835\udd2a",mho:"\u2127",micro:"\xb5",mid:"\u2223",midast:"*",midcir:"\u2af0",middot:"\xb7",minus:"\u2212",minusb:"\u229f",minusd:"\u2238",minusdu:"\u2a2a",MinusPlus:"\u2213",mlcp:"\u2adb",mldr:"\u2026",mnplus:"\u2213",models:"\u22a7",Mopf:"\ud835\udd44",mopf:"\ud835\udd5e",mp:"\u2213",Mscr:"\u2133",mscr:"\ud835\udcc2",mstpos:"\u223e",Mu:"\u039c",mu:"\u03bc",multimap:"\u22b8",mumap:"\u22b8",nabla:"\u2207",Nacute:"\u0143",nacute:"\u0144",nang:"\u2220\u20d2",nap:"\u2249",napE:"\u2a70\u0338",napid:"\u224b\u0338",napos:"\u0149",napprox:"\u2249",natur:"\u266e",natural:"\u266e",naturals:"\u2115",nbsp:"\xa0",nbump:"\u224e\u0338",nbumpe:"\u224f\u0338",ncap:"\u2a43",Ncaron:"\u0147",ncaron:"\u0148",Ncedil:"\u0145",ncedil:"\u0146",ncong:"\u2247",ncongdot:"\u2a6d\u0338",ncup:"\u2a42",Ncy:"\u041d",ncy:"\u043d",ndash:"\u2013",ne:"\u2260",nearhk:"\u2924",neArr:"\u21d7",nearr:"\u2197",nearrow:"\u2197",nedot:"\u2250\u0338",NegativeMediumSpace:"\u200b",NegativeThickSpace:"\u200b",NegativeThinSpace:"\u200b",NegativeVeryThinSpace:"\u200b",nequiv:"\u2262",nesear:"\u2928",nesim:"\u2242\u0338",NestedGreaterGreater:"\u226b",NestedLessLess:"\u226a",NewLine:"\n",nexist:"\u2204",nexists:"\u2204",Nfr:"\ud835\udd11",nfr:"\ud835\udd2b",ngE:"\u2267\u0338",nge:"\u2271",ngeq:"\u2271",ngeqq:"\u2267\u0338",ngeqslant:"\u2a7e\u0338",nges:"\u2a7e\u0338",nGg:"\u22d9\u0338",ngsim:"\u2275",nGt:"\u226b\u20d2",ngt:"\u226f",ngtr:"\u226f",nGtv:"\u226b\u0338",nhArr:"\u21ce",nharr:"\u21ae",nhpar:"\u2af2",ni:"\u220b",nis:"\u22fc",nisd:"\u22fa",niv:"\u220b",NJcy:"\u040a",njcy:"\u045a",nlArr:"\u21cd",nlarr:"\u219a",nldr:"\u2025",nlE:"\u2266\u0338",nle:"\u2270",nLeftarrow:"\u21cd",nleftarrow:"\u219a",nLeftrightarrow:"\u21ce",nleftrightarrow:"\u21ae",nleq:"\u2270",nleqq:"\u2266\u0338",nleqslant:"\u2a7d\u0338",nles:"\u2a7d\u0338",nless:"\u226e",nLl:"\u22d8\u0338",nlsim:"\u2274",nLt:"\u226a\u20d2",nlt:"\u226e",nltri:"\u22ea",nltrie:"\u22ec",nLtv:"\u226a\u0338",nmid:"\u2224",NoBreak:"\u2060",NonBreakingSpace:"\xa0",Nopf:"\u2115",nopf:"\ud835\udd5f",Not:"\u2aec",not:"\xac",NotCongruent:"\u2262",NotCupCap:"\u226d",NotDoubleVerticalBar:"\u2226",NotElement:"\u2209",NotEqual:"\u2260",NotEqualTilde:"\u2242\u0338",NotExists:"\u2204",NotGreater:"\u226f",NotGreaterEqual:"\u2271",NotGreaterFullEqual:"\u2267\u0338",NotGreaterGreater:"\u226b\u0338",NotGreaterLess:"\u2279",NotGreaterSlantEqual:"\u2a7e\u0338",NotGreaterTilde:"\u2275",NotHumpDownHump:"\u224e\u0338",NotHumpEqual:"\u224f\u0338",notin:"\u2209",notindot:"\u22f5\u0338",notinE:"\u22f9\u0338",notinva:"\u2209",notinvb:"\u22f7",notinvc:"\u22f6",NotLeftTriangle:"\u22ea",NotLeftTriangleBar:"\u29cf\u0338",NotLeftTriangleEqual:"\u22ec",NotLess:"\u226e",NotLessEqual:"\u2270",NotLessGreater:"\u2278",NotLessLess:"\u226a\u0338",NotLessSlantEqual:"\u2a7d\u0338",NotLessTilde:"\u2274",NotNestedGreaterGreater:"\u2aa2\u0338",NotNestedLessLess:"\u2aa1\u0338",notni:"\u220c",notniva:"\u220c",notnivb:"\u22fe",notnivc:"\u22fd",NotPrecedes:"\u2280",NotPrecedesEqual:"\u2aaf\u0338",NotPrecedesSlantEqual:"\u22e0",NotReverseElement:"\u220c",NotRightTriangle:"\u22eb",NotRightTriangleBar:"\u29d0\u0338",NotRightTriangleEqual:"\u22ed",NotSquareSubset:"\u228f\u0338",NotSquareSubsetEqual:"\u22e2",NotSquareSuperset:"\u2290\u0338",NotSquareSupersetEqual:"\u22e3",NotSubset:"\u2282\u20d2",NotSubsetEqual:"\u2288",NotSucceeds:"\u2281",NotSucceedsEqual:"\u2ab0\u0338",NotSucceedsSlantEqual:"\u22e1",NotSucceedsTilde:"\u227f\u0338",NotSuperset:"\u2283\u20d2",NotSupersetEqual:"\u2289",NotTilde:"\u2241",NotTildeEqual:"\u2244",NotTildeFullEqual:"\u2247",NotTildeTilde:"\u2249",NotVerticalBar:"\u2224",npar:"\u2226",nparallel:"\u2226",nparsl:"\u2afd\u20e5",npart:"\u2202\u0338",npolint:"\u2a14",npr:"\u2280",nprcue:"\u22e0",npre:"\u2aaf\u0338",nprec:"\u2280",npreceq:"\u2aaf\u0338",nrArr:"\u21cf",nrarr:"\u219b",nrarrc:"\u2933\u0338",nrarrw:"\u219d\u0338",nRightarrow:"\u21cf",nrightarrow:"\u219b",nrtri:"\u22eb",nrtrie:"\u22ed",nsc:"\u2281",nsccue:"\u22e1",nsce:"\u2ab0\u0338",Nscr:"\ud835\udca9",nscr:"\ud835\udcc3",nshortmid:"\u2224",nshortparallel:"\u2226",nsim:"\u2241",nsime:"\u2244",nsimeq:"\u2244",nsmid:"\u2224",nspar:"\u2226",nsqsube:"\u22e2",nsqsupe:"\u22e3",nsub:"\u2284",nsubE:"\u2ac5\u0338",nsube:"\u2288",nsubset:"\u2282\u20d2",nsubseteq:"\u2288",nsubseteqq:"\u2ac5\u0338",nsucc:"\u2281",nsucceq:"\u2ab0\u0338",nsup:"\u2285",nsupE:"\u2ac6\u0338",nsupe:"\u2289",nsupset:"\u2283\u20d2",nsupseteq:"\u2289",nsupseteqq:"\u2ac6\u0338",ntgl:"\u2279",Ntilde:"\xd1",ntilde:"\xf1",ntlg:"\u2278",ntriangleleft:"\u22ea",ntrianglelefteq:"\u22ec",ntriangleright:"\u22eb",ntrianglerighteq:"\u22ed",Nu:"\u039d",nu:"\u03bd",num:"#",numero:"\u2116",numsp:"\u2007",nvap:"\u224d\u20d2",nVDash:"\u22af",nVdash:"\u22ae",nvDash:"\u22ad",nvdash:"\u22ac",nvge:"\u2265\u20d2",nvgt:">\u20d2",nvHarr:"\u2904",nvinfin:"\u29de",nvlArr:"\u2902",nvle:"\u2264\u20d2",nvlt:"<\u20d2",nvltrie:"\u22b4\u20d2",nvrArr:"\u2903",nvrtrie:"\u22b5\u20d2",nvsim:"\u223c\u20d2",nwarhk:"\u2923",nwArr:"\u21d6",nwarr:"\u2196",nwarrow:"\u2196",nwnear:"\u2927",Oacute:"\xd3",oacute:"\xf3",oast:"\u229b",ocir:"\u229a",Ocirc:"\xd4",ocirc:"\xf4",Ocy:"\u041e",ocy:"\u043e",odash:"\u229d",Odblac:"\u0150",odblac:"\u0151",odiv:"\u2a38",odot:"\u2299",odsold:"\u29bc",OElig:"\u0152",oelig:"\u0153",ofcir:"\u29bf",Ofr:"\ud835\udd12",ofr:"\ud835\udd2c",ogon:"\u02db",Ograve:"\xd2",ograve:"\xf2",ogt:"\u29c1",ohbar:"\u29b5",ohm:"\u03a9",oint:"\u222e",olarr:"\u21ba",olcir:"\u29be",olcross:"\u29bb",oline:"\u203e",olt:"\u29c0",Omacr:"\u014c",omacr:"\u014d",Omega:"\u03a9",omega:"\u03c9",Omicron:"\u039f",omicron:"\u03bf",omid:"\u29b6",ominus:"\u2296",Oopf:"\ud835\udd46",oopf:"\ud835\udd60",opar:"\u29b7",OpenCurlyDoubleQuote:"\u201c",OpenCurlyQuote:"\u2018",operp:"\u29b9",oplus:"\u2295",Or:"\u2a54",or:"\u2228",orarr:"\u21bb",ord:"\u2a5d",order:"\u2134",orderof:"\u2134",ordf:"\xaa",ordm:"\xba",origof:"\u22b6",oror:"\u2a56",orslope:"\u2a57",orv:"\u2a5b",oS:"\u24c8",Oscr:"\ud835\udcaa",oscr:"\u2134",Oslash:"\xd8",oslash:"\xf8",osol:"\u2298",Otilde:"\xd5",otilde:"\xf5",Otimes:"\u2a37",otimes:"\u2297",otimesas:"\u2a36",Ouml:"\xd6",ouml:"\xf6",ovbar:"\u233d",OverBar:"\u203e",OverBrace:"\u23de",OverBracket:"\u23b4",OverParenthesis:"\u23dc",par:"\u2225",para:"\xb6",parallel:"\u2225",parsim:"\u2af3",parsl:"\u2afd",part:"\u2202",PartialD:"\u2202",Pcy:"\u041f",pcy:"\u043f",percnt:"%",period:".",permil:"\u2030",perp:"\u22a5",pertenk:"\u2031",Pfr:"\ud835\udd13",pfr:"\ud835\udd2d",Phi:"\u03a6",phi:"\u03c6",phiv:"\u03d5",phmmat:"\u2133",phone:"\u260e",Pi:"\u03a0",pi:"\u03c0",pitchfork:"\u22d4",piv:"\u03d6",planck:"\u210f",planckh:"\u210e",plankv:"\u210f",plus:"+",plusacir:"\u2a23",plusb:"\u229e",pluscir:"\u2a22",plusdo:"\u2214",plusdu:"\u2a25",pluse:"\u2a72",PlusMinus:"\xb1",plusmn:"\xb1",plussim:"\u2a26",plustwo:"\u2a27",pm:"\xb1",Poincareplane:"\u210c",pointint:"\u2a15",Popf:"\u2119",popf:"\ud835\udd61",pound:"\xa3",Pr:"\u2abb",pr:"\u227a",prap:"\u2ab7",prcue:"\u227c",prE:"\u2ab3",pre:"\u2aaf",prec:"\u227a",precapprox:"\u2ab7",preccurlyeq:"\u227c",Precedes:"\u227a",PrecedesEqual:"\u2aaf",PrecedesSlantEqual:"\u227c",PrecedesTilde:"\u227e",preceq:"\u2aaf",precnapprox:"\u2ab9",precneqq:"\u2ab5",precnsim:"\u22e8",precsim:"\u227e",Prime:"\u2033",prime:"\u2032",primes:"\u2119",prnap:"\u2ab9",prnE:"\u2ab5",prnsim:"\u22e8",prod:"\u220f",Product:"\u220f",profalar:"\u232e",profline:"\u2312",profsurf:"\u2313",prop:"\u221d",Proportion:"\u2237",Proportional:"\u221d",propto:"\u221d",prsim:"\u227e",prurel:"\u22b0",Pscr:"\ud835\udcab",pscr:"\ud835\udcc5",Psi:"\u03a8",psi:"\u03c8",puncsp:"\u2008",Qfr:"\ud835\udd14",qfr:"\ud835\udd2e",qint:"\u2a0c",Qopf:"\u211a",qopf:"\ud835\udd62",qprime:"\u2057",Qscr:"\ud835\udcac",qscr:"\ud835\udcc6",quaternions:"\u210d",quatint:"\u2a16",quest:"?",questeq:"\u225f",QUOT:'"',quot:'"',rAarr:"\u21db",race:"\u223d\u0331",Racute:"\u0154",racute:"\u0155",radic:"\u221a",raemptyv:"\u29b3",Rang:"\u27eb",rang:"\u27e9",rangd:"\u2992",range:"\u29a5",rangle:"\u27e9",raquo:"\xbb",Rarr:"\u21a0",rArr:"\u21d2",rarr:"\u2192",rarrap:"\u2975",rarrb:"\u21e5",rarrbfs:"\u2920",rarrc:"\u2933",rarrfs:"\u291e",rarrhk:"\u21aa",rarrlp:"\u21ac",rarrpl:"\u2945",rarrsim:"\u2974",Rarrtl:"\u2916",rarrtl:"\u21a3",rarrw:"\u219d",rAtail:"\u291c",ratail:"\u291a",ratio:"\u2236",rationals:"\u211a",RBarr:"\u2910",rBarr:"\u290f",rbarr:"\u290d",rbbrk:"\u2773",rbrace:"}",rbrack:"]",rbrke:"\u298c",rbrksld:"\u298e",rbrkslu:"\u2990",Rcaron:"\u0158",rcaron:"\u0159",Rcedil:"\u0156",rcedil:"\u0157",rceil:"\u2309",rcub:"}",Rcy:"\u0420",rcy:"\u0440",rdca:"\u2937",rdldhar:"\u2969",rdquo:"\u201d",rdquor:"\u201d",rdsh:"\u21b3",Re:"\u211c",real:"\u211c",realine:"\u211b",realpart:"\u211c",reals:"\u211d",rect:"\u25ad",REG:"\xae",reg:"\xae",ReverseElement:"\u220b",ReverseEquilibrium:"\u21cb",ReverseUpEquilibrium:"\u296f",rfisht:"\u297d",rfloor:"\u230b",Rfr:"\u211c",rfr:"\ud835\udd2f",rHar:"\u2964",rhard:"\u21c1",rharu:"\u21c0",rharul:"\u296c",Rho:"\u03a1",rho:"\u03c1",rhov:"\u03f1",RightAngleBracket:"\u27e9",RightArrow:"\u2192",Rightarrow:"\u21d2",rightarrow:"\u2192",RightArrowBar:"\u21e5",RightArrowLeftArrow:"\u21c4",rightarrowtail:"\u21a3",RightCeiling:"\u2309",RightDoubleBracket:"\u27e7",RightDownTeeVector:"\u295d",RightDownVector:"\u21c2",RightDownVectorBar:"\u2955",RightFloor:"\u230b",rightharpoondown:"\u21c1",rightharpoonup:"\u21c0",rightleftarrows:"\u21c4",rightleftharpoons:"\u21cc",rightrightarrows:"\u21c9",rightsquigarrow:"\u219d",RightTee:"\u22a2",RightTeeArrow:"\u21a6",RightTeeVector:"\u295b",rightthreetimes:"\u22cc",RightTriangle:"\u22b3",RightTriangleBar:"\u29d0",RightTriangleEqual:"\u22b5",RightUpDownVector:"\u294f",RightUpTeeVector:"\u295c",RightUpVector:"\u21be",RightUpVectorBar:"\u2954",RightVector:"\u21c0",RightVectorBar:"\u2953",ring:"\u02da",risingdotseq:"\u2253",rlarr:"\u21c4",rlhar:"\u21cc",rlm:"\u200f",rmoust:"\u23b1",rmoustache:"\u23b1",rnmid:"\u2aee",roang:"\u27ed",roarr:"\u21fe",robrk:"\u27e7",ropar:"\u2986",Ropf:"\u211d",ropf:"\ud835\udd63",roplus:"\u2a2e",rotimes:"\u2a35",RoundImplies:"\u2970",rpar:")",rpargt:"\u2994",rppolint:"\u2a12",rrarr:"\u21c9",Rrightarrow:"\u21db",rsaquo:"\u203a",Rscr:"\u211b",rscr:"\ud835\udcc7",Rsh:"\u21b1",rsh:"\u21b1",rsqb:"]",rsquo:"\u2019",rsquor:"\u2019",rthree:"\u22cc",rtimes:"\u22ca",rtri:"\u25b9",rtrie:"\u22b5",rtrif:"\u25b8",rtriltri:"\u29ce",RuleDelayed:"\u29f4",ruluhar:"\u2968",rx:"\u211e",Sacute:"\u015a",sacute:"\u015b",sbquo:"\u201a",Sc:"\u2abc",sc:"\u227b",scap:"\u2ab8",Scaron:"\u0160",scaron:"\u0161",sccue:"\u227d",scE:"\u2ab4",sce:"\u2ab0",Scedil:"\u015e",scedil:"\u015f",Scirc:"\u015c",scirc:"\u015d",scnap:"\u2aba",scnE:"\u2ab6",scnsim:"\u22e9",scpolint:"\u2a13",scsim:"\u227f",Scy:"\u0421",scy:"\u0441",sdot:"\u22c5",sdotb:"\u22a1",sdote:"\u2a66",searhk:"\u2925",seArr:"\u21d8",searr:"\u2198",searrow:"\u2198",sect:"\xa7",semi:";",seswar:"\u2929",setminus:"\u2216",setmn:"\u2216",sext:"\u2736",Sfr:"\ud835\udd16",sfr:"\ud835\udd30",sfrown:"\u2322",sharp:"\u266f",SHCHcy:"\u0429",shchcy:"\u0449",SHcy:"\u0428",shcy:"\u0448",ShortDownArrow:"\u2193",ShortLeftArrow:"\u2190",shortmid:"\u2223",shortparallel:"\u2225",ShortRightArrow:"\u2192",ShortUpArrow:"\u2191",shy:"\xad",Sigma:"\u03a3",sigma:"\u03c3",sigmaf:"\u03c2",sigmav:"\u03c2",sim:"\u223c",simdot:"\u2a6a",sime:"\u2243",simeq:"\u2243",simg:"\u2a9e",simgE:"\u2aa0",siml:"\u2a9d",simlE:"\u2a9f",simne:"\u2246",simplus:"\u2a24",simrarr:"\u2972",slarr:"\u2190",SmallCircle:"\u2218",smallsetminus:"\u2216",smashp:"\u2a33",smeparsl:"\u29e4",smid:"\u2223",smile:"\u2323",smt:"\u2aaa",smte:"\u2aac",smtes:"\u2aac\ufe00",SOFTcy:"\u042c",softcy:"\u044c",sol:"/",solb:"\u29c4",solbar:"\u233f",Sopf:"\ud835\udd4a",sopf:"\ud835\udd64",spades:"\u2660",spadesuit:"\u2660",spar:"\u2225",sqcap:"\u2293",sqcaps:"\u2293\ufe00",sqcup:"\u2294",sqcups:"\u2294\ufe00",Sqrt:"\u221a",sqsub:"\u228f",sqsube:"\u2291",sqsubset:"\u228f",sqsubseteq:"\u2291",sqsup:"\u2290",sqsupe:"\u2292",sqsupset:"\u2290",sqsupseteq:"\u2292",squ:"\u25a1",Square:"\u25a1",square:"\u25a1",SquareIntersection:"\u2293",SquareSubset:"\u228f",SquareSubsetEqual:"\u2291",SquareSuperset:"\u2290",SquareSupersetEqual:"\u2292",SquareUnion:"\u2294",squarf:"\u25aa",squf:"\u25aa",srarr:"\u2192",Sscr:"\ud835\udcae",sscr:"\ud835\udcc8",ssetmn:"\u2216",ssmile:"\u2323",sstarf:"\u22c6",Star:"\u22c6",star:"\u2606",starf:"\u2605",straightepsilon:"\u03f5",straightphi:"\u03d5",strns:"\xaf",Sub:"\u22d0",sub:"\u2282",subdot:"\u2abd",subE:"\u2ac5",sube:"\u2286",subedot:"\u2ac3",submult:"\u2ac1",subnE:"\u2acb",subne:"\u228a",subplus:"\u2abf",subrarr:"\u2979",Subset:"\u22d0",subset:"\u2282",subseteq:"\u2286",subseteqq:"\u2ac5",SubsetEqual:"\u2286",subsetneq:"\u228a",subsetneqq:"\u2acb",subsim:"\u2ac7",subsub:"\u2ad5",subsup:"\u2ad3",succ:"\u227b",succapprox:"\u2ab8",succcurlyeq:"\u227d",Succeeds:"\u227b",SucceedsEqual:"\u2ab0",SucceedsSlantEqual:"\u227d",SucceedsTilde:"\u227f",succeq:"\u2ab0",succnapprox:"\u2aba",succneqq:"\u2ab6",succnsim:"\u22e9",succsim:"\u227f",SuchThat:"\u220b",Sum:"\u2211",sum:"\u2211",sung:"\u266a",Sup:"\u22d1",sup:"\u2283",sup1:"\xb9",sup2:"\xb2",sup3:"\xb3",supdot:"\u2abe",supdsub:"\u2ad8",supE:"\u2ac6",supe:"\u2287",supedot:"\u2ac4",Superset:"\u2283",SupersetEqual:"\u2287",suphsol:"\u27c9",suphsub:"\u2ad7",suplarr:"\u297b",supmult:"\u2ac2",supnE:"\u2acc",supne:"\u228b",supplus:"\u2ac0",Supset:"\u22d1",supset:"\u2283",supseteq:"\u2287",supseteqq:"\u2ac6",supsetneq:"\u228b",supsetneqq:"\u2acc",supsim:"\u2ac8",supsub:"\u2ad4",supsup:"\u2ad6",swarhk:"\u2926",swArr:"\u21d9",swarr:"\u2199",swarrow:"\u2199",swnwar:"\u292a",szlig:"\xdf",Tab:" ",target:"\u2316",Tau:"\u03a4",tau:"\u03c4",tbrk:"\u23b4",Tcaron:"\u0164",tcaron:"\u0165",Tcedil:"\u0162",tcedil:"\u0163",Tcy:"\u0422",tcy:"\u0442",tdot:"\u20db",telrec:"\u2315",Tfr:"\ud835\udd17",tfr:"\ud835\udd31",there4:"\u2234",Therefore:"\u2234",therefore:"\u2234",Theta:"\u0398",theta:"\u03b8",thetasym:"\u03d1",thetav:"\u03d1",thickapprox:"\u2248",thicksim:"\u223c",ThickSpace:"\u205f\u200a",thinsp:"\u2009",ThinSpace:"\u2009",thkap:"\u2248",thksim:"\u223c",THORN:"\xde",thorn:"\xfe",Tilde:"\u223c",tilde:"\u02dc",TildeEqual:"\u2243",TildeFullEqual:"\u2245",TildeTilde:"\u2248",times:"\xd7",timesb:"\u22a0",timesbar:"\u2a31",timesd:"\u2a30",tint:"\u222d",toea:"\u2928",top:"\u22a4",topbot:"\u2336",topcir:"\u2af1",Topf:"\ud835\udd4b",topf:"\ud835\udd65",topfork:"\u2ada",tosa:"\u2929",tprime:"\u2034",TRADE:"\u2122",trade:"\u2122",triangle:"\u25b5",triangledown:"\u25bf",triangleleft:"\u25c3",trianglelefteq:"\u22b4",triangleq:"\u225c",triangleright:"\u25b9",trianglerighteq:"\u22b5",tridot:"\u25ec",trie:"\u225c",triminus:"\u2a3a",TripleDot:"\u20db",triplus:"\u2a39",trisb:"\u29cd",tritime:"\u2a3b",trpezium:"\u23e2",Tscr:"\ud835\udcaf",tscr:"\ud835\udcc9",TScy:"\u0426",tscy:"\u0446",TSHcy:"\u040b",tshcy:"\u045b",Tstrok:"\u0166",tstrok:"\u0167",twixt:"\u226c",twoheadleftarrow:"\u219e",twoheadrightarrow:"\u21a0",Uacute:"\xda",uacute:"\xfa",Uarr:"\u219f",uArr:"\u21d1",uarr:"\u2191",Uarrocir:"\u2949",Ubrcy:"\u040e",ubrcy:"\u045e",Ubreve:"\u016c",ubreve:"\u016d",Ucirc:"\xdb",ucirc:"\xfb",Ucy:"\u0423",ucy:"\u0443",udarr:"\u21c5",Udblac:"\u0170",udblac:"\u0171",udhar:"\u296e",ufisht:"\u297e",Ufr:"\ud835\udd18",ufr:"\ud835\udd32",Ugrave:"\xd9",ugrave:"\xf9",uHar:"\u2963",uharl:"\u21bf",uharr:"\u21be",uhblk:"\u2580",ulcorn:"\u231c",ulcorner:"\u231c",ulcrop:"\u230f",ultri:"\u25f8",Umacr:"\u016a",umacr:"\u016b",uml:"\xa8",UnderBar:"_",UnderBrace:"\u23df",UnderBracket:"\u23b5",UnderParenthesis:"\u23dd",Union:"\u22c3",UnionPlus:"\u228e",Uogon:"\u0172",uogon:"\u0173",Uopf:"\ud835\udd4c",uopf:"\ud835\udd66",UpArrow:"\u2191",Uparrow:"\u21d1",uparrow:"\u2191",UpArrowBar:"\u2912",UpArrowDownArrow:"\u21c5",UpDownArrow:"\u2195",Updownarrow:"\u21d5",updownarrow:"\u2195",UpEquilibrium:"\u296e",upharpoonleft:"\u21bf",upharpoonright:"\u21be",uplus:"\u228e",UpperLeftArrow:"\u2196",UpperRightArrow:"\u2197",Upsi:"\u03d2",upsi:"\u03c5",upsih:"\u03d2",Upsilon:"\u03a5",upsilon:"\u03c5",UpTee:"\u22a5",UpTeeArrow:"\u21a5",upuparrows:"\u21c8",urcorn:"\u231d",urcorner:"\u231d",urcrop:"\u230e",Uring:"\u016e",uring:"\u016f",urtri:"\u25f9",Uscr:"\ud835\udcb0",uscr:"\ud835\udcca",utdot:"\u22f0",Utilde:"\u0168",utilde:"\u0169",utri:"\u25b5",utrif:"\u25b4",uuarr:"\u21c8",Uuml:"\xdc",uuml:"\xfc",uwangle:"\u29a7",vangrt:"\u299c",varepsilon:"\u03f5",varkappa:"\u03f0",varnothing:"\u2205",varphi:"\u03d5",varpi:"\u03d6",varpropto:"\u221d",vArr:"\u21d5",varr:"\u2195",varrho:"\u03f1",varsigma:"\u03c2",varsubsetneq:"\u228a\ufe00",varsubsetneqq:"\u2acb\ufe00",varsupsetneq:"\u228b\ufe00",varsupsetneqq:"\u2acc\ufe00",vartheta:"\u03d1",vartriangleleft:"\u22b2",vartriangleright:"\u22b3",Vbar:"\u2aeb",vBar:"\u2ae8",vBarv:"\u2ae9",Vcy:"\u0412",vcy:"\u0432",VDash:"\u22ab",Vdash:"\u22a9",vDash:"\u22a8",vdash:"\u22a2",Vdashl:"\u2ae6",Vee:"\u22c1",vee:"\u2228",veebar:"\u22bb",veeeq:"\u225a",vellip:"\u22ee",Verbar:"\u2016",verbar:"|",Vert:"\u2016",vert:"|",VerticalBar:"\u2223",VerticalLine:"|",VerticalSeparator:"\u2758",VerticalTilde:"\u2240",VeryThinSpace:"\u200a",Vfr:"\ud835\udd19",vfr:"\ud835\udd33",vltri:"\u22b2",vnsub:"\u2282\u20d2",vnsup:"\u2283\u20d2",Vopf:"\ud835\udd4d",vopf:"\ud835\udd67",vprop:"\u221d",vrtri:"\u22b3",Vscr:"\ud835\udcb1",vscr:"\ud835\udccb",vsubnE:"\u2acb\ufe00",vsubne:"\u228a\ufe00",vsupnE:"\u2acc\ufe00",vsupne:"\u228b\ufe00",Vvdash:"\u22aa",vzigzag:"\u299a",Wcirc:"\u0174",wcirc:"\u0175",wedbar:"\u2a5f",Wedge:"\u22c0",wedge:"\u2227",wedgeq:"\u2259",weierp:"\u2118",Wfr:"\ud835\udd1a",wfr:"\ud835\udd34",Wopf:"\ud835\udd4e",wopf:"\ud835\udd68",wp:"\u2118",wr:"\u2240",wreath:"\u2240",Wscr:"\ud835\udcb2",wscr:"\ud835\udccc",xcap:"\u22c2",xcirc:"\u25ef",xcup:"\u22c3",xdtri:"\u25bd",Xfr:"\ud835\udd1b",xfr:"\ud835\udd35",xhArr:"\u27fa",xharr:"\u27f7",Xi:"\u039e",xi:"\u03be",xlArr:"\u27f8",xlarr:"\u27f5",xmap:"\u27fc",xnis:"\u22fb",xodot:"\u2a00",Xopf:"\ud835\udd4f",xopf:"\ud835\udd69",xoplus:"\u2a01",xotime:"\u2a02",xrArr:"\u27f9",xrarr:"\u27f6",Xscr:"\ud835\udcb3",xscr:"\ud835\udccd",xsqcup:"\u2a06",xuplus:"\u2a04",xutri:"\u25b3",xvee:"\u22c1",xwedge:"\u22c0",Yacute:"\xdd",yacute:"\xfd",YAcy:"\u042f",yacy:"\u044f",Ycirc:"\u0176",ycirc:"\u0177",Ycy:"\u042b",ycy:"\u044b",yen:"\xa5",Yfr:"\ud835\udd1c",yfr:"\ud835\udd36",YIcy:"\u0407",yicy:"\u0457",Yopf:"\ud835\udd50",yopf:"\ud835\udd6a",Yscr:"\ud835\udcb4",yscr:"\ud835\udcce",YUcy:"\u042e",yucy:"\u044e",Yuml:"\u0178",yuml:"\xff",Zacute:"\u0179",zacute:"\u017a",Zcaron:"\u017d",zcaron:"\u017e",Zcy:"\u0417",zcy:"\u0437",Zdot:"\u017b",zdot:"\u017c",zeetrf:"\u2128",ZeroWidthSpace:"\u200b",Zeta:"\u0396",zeta:"\u03b6",Zfr:"\u2128",zfr:"\ud835\udd37",ZHcy:"\u0416",zhcy:"\u0436",zigrarr:"\u21dd",Zopf:"\u2124",zopf:"\ud835\udd6b",Zscr:"\ud835\udcb5",zscr:"\ud835\udccf",zwj:"\u200d",zwnj:"\u200c"} +},{}],2:[function(e,r){"use strict";var t={};["article","aside","button","blockquote","body","canvas","caption","col","colgroup","dd","div","dl","dt","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","hr","iframe","li","map","object","ol","output","p","pre","progress","script","section","style","table","tbody","td","textarea","tfoot","th","tr","thead","ul","video"].forEach(function(e){t[e]=!0}),r.exports=t},{}],3:[function(e,r){"use strict";var t="[a-zA-Z_:][a-zA-Z0-9:._-]*",n="[^\"'=<>`\\x00-\\x20]+",s="'[^']*'",i='"[^"]*"',o="(?:"+n+"|"+s+"|"+i+")",l="(?:\\s+"+t+"(?:\\s*=\\s*"+o+")?)",a="<[A-Za-z][A-Za-z0-9\\-]*"+l+"*\\s*\\/?>",c="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",u="|",p="<[?].*?[?]>",h="]*>",f="",d=new RegExp("^(?:"+a+"|"+c+"|"+u+"|"+p+"|"+h+"|"+f+")");r.exports.HTML_TAG_RE=d},{}],4:[function(e,r){"use strict";r.exports=["coap","doi","javascript","aaa","aaas","about","acap","cap","cid","crid","data","dav","dict","dns","file","ftp","geo","go","gopher","h323","http","https","iax","icap","im","imap","info","ipp","iris","iris.beep","iris.xpc","iris.xpcs","iris.lwz","ldap","mailto","mid","msrp","msrps","mtqp","mupdate","news","nfs","ni","nih","nntp","opaquelocktoken","pop","pres","rtsp","service","session","shttp","sieve","sip","sips","sms","snmp","soap.beep","soap.beeps","tag","tel","telnet","tftp","thismessage","tn3270","tip","tv","urn","vemmi","ws","wss","xcon","xcon-userid","xmlrpc.beep","xmlrpc.beeps","xmpp","z39.50r","z39.50s","adiumxtra","afp","afs","aim","apt","attachment","aw","beshare","bitcoin","bolo","callto","chrome","chrome-extension","com-eventbrite-attendee","content","cvs","dlna-playsingle","dlna-playcontainer","dtn","dvb","ed2k","facetime","feed","finger","fish","gg","git","gizmoproject","gtalk","hcp","icon","ipn","irc","irc6","ircs","itms","jar","jms","keyparc","lastfm","ldaps","magnet","maps","market","message","mms","ms-help","msnim","mumble","mvn","notes","oid","palm","paparazzi","platform","proxy","psyc","query","res","resource","rmi","rsync","rtmp","secondlife","sftp","sgn","skype","smb","soldat","spotify","ssh","steam","svn","teamspeak","things","udp","unreal","ut2004","ventrilo","view-source","webcal","wtai","wyciwyg","xfire","xri","ymsgr"]},{}],5:[function(e,r,t){"use strict";function n(e){return Object.prototype.toString.call(e)}function s(e){return"[object String]"===n(e)}function i(e,r){return x.call(e,r)}function o(e){var r=Array.prototype.slice.call(arguments,1);return r.forEach(function(r){if(r){if("object"!=typeof r)throw new TypeError(r+"must be object");Object.keys(r).forEach(function(t){e[t]=r[t]})}}),e}function l(e,r,t){return[].concat(e.slice(0,r),t,e.slice(r+1))}function a(e){return e>=55296&&57343>=e?!1:e>=64976&&65007>=e?!1:65535===(65535&e)||65534===(65535&e)?!1:e>=0&&8>=e?!1:11===e?!1:e>=14&&31>=e?!1:e>=127&&159>=e?!1:e>1114111?!1:!0}function c(e){if(e>65535){e-=65536;var r=55296+(e>>10),t=56320+(1023&e);return String.fromCharCode(r,t)}return String.fromCharCode(e)}function u(e,r){var t=0;return i(D,r)?D[r]:35===r.charCodeAt(0)&&q.test(r)&&(t="x"===r[1].toLowerCase()?parseInt(r.slice(2),16):parseInt(r.slice(1),10),a(t))?c(t):e}function p(e){return e.indexOf("&")<0?e:e.replace(w,u)}function h(e){return e.indexOf("\\")<0?e:e.replace(A,"$1")}function f(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(C,function(e,r,t){return r?r:u(e,t)})}function d(e){return S[e]}function m(e){return E.test(e)?e.replace(F,d):e}function _(e){return L(e)}function g(e){return e.replace(z,"\\$&")}function b(e){if(e>=8192&&8202>=e)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1}function k(e){return M.test(e)}function v(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}}function y(e){return e.trim().replace(/\s+/g," ").toUpperCase()}var x=Object.prototype.hasOwnProperty,A=/\\([!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~])/g,w=/&([a-z#][a-z0-9]{1,31});/gi,C=new RegExp(A.source+"|"+w.source,"gi"),q=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i,D=e("./entities"),E=/[&<>"]/,F=/[&<>"]/g,S={"&":"&","<":"<",">":">",'"':"""},L=e("mdurl/encode"),z=/[.?*+^$[\]\\(){}|-]/g,M=e("uc.micro/categories/P/regex");t.assign=o,t.isString=s,t.has=i,t.unescapeMd=h,t.unescapeAll=f,t.isValidEntityCode=a,t.fromCodePoint=c,t.replaceEntities=p,t.escapeHtml=m,t.arrayReplaceAt=l,t.normalizeLink=_,t.isWhiteSpace=b,t.isMdAsciiPunct=v,t.isPunctChar=k,t.escapeRE=g,t.normalizeReference=y},{"./entities":1,"mdurl/encode":52,"uc.micro/categories/P/regex":55}],6:[function(e,r,t){"use strict";t.parseLinkLabel=e("./parse_link_label"),t.parseLinkDestination=e("./parse_link_destination"),t.parseLinkTitle=e("./parse_link_title")},{"./parse_link_destination":7,"./parse_link_label":8,"./parse_link_title":9}],7:[function(e,r){"use strict";var t=e("../common/utils").normalizeLink,n=e("../common/utils").unescapeAll;r.exports=function(e,r,s){var i,o,l=0,a=r,c={ok:!1,pos:0,lines:0,str:""};if(60===e.charCodeAt(r)){for(r++;s>r;){if(i=e.charCodeAt(r),10===i)return c;if(62===i)return c.pos=r+1,c.str=t(n(e.slice(a+1,r))),c.ok=!0,c;92===i&&s>r+1?r+=2:r++}return c}for(o=0;s>r&&(i=e.charCodeAt(r),32!==i)&&!(32>i||127===i);)if(92===i&&s>r+1)r+=2;else{if(40===i&&(o++,o>1))break;if(41===i&&(o--,0>o))break;r++}return a===r?c:(c.str=t(n(e.slice(a,r))),c.lines=l,c.pos=r,c.ok=!0,c)}},{"../common/utils":5}],8:[function(e,r){"use strict";r.exports=function(e,r,t){var n,s,i,o,l=-1,a=e.posMax,c=e.pos;for(e.pos=r+1,n=1;e.pos=n)return a;if(i=e.charCodeAt(r),34!==i&&39!==i&&40!==i)return a;for(r++,40===i&&(i=41);n>r;){if(s=e.charCodeAt(r),s===i)return a.pos=r+1,a.lines=o,a.str=t(e.slice(l+1,r)),a.ok=!0,a;10===s?o++:92===s&&n>r+1&&(r++,10===e.charCodeAt(r)&&o++),r++}return a}},{"../common/utils":5}],10:[function(e,r){"use strict";function t(e,r){return this instanceof t?(r||n.isString(e)||(r=e||{},e="default"),this.inline=new a,this.block=new l,this.core=new o,this.renderer=new i,this.linkify=new c,this.utils=n,this.helpers=s,this.options={},this.configure(e),void(r&&this.set(r))):new t(e,r)}var n=e("./common/utils"),s=e("./helpers"),i=e("./renderer"),o=e("./parser_core"),l=e("./parser_block"),a=e("./parser_inline"),c=e("linkify-it"),u={"default":e("./presets/default"),zero:e("./presets/zero"),commonmark:e("./presets/commonmark")};t.prototype.set=function(e){return n.assign(this.options,e),this},t.prototype.configure=function(e){var r,t=this;if(n.isString(e)&&(r=e,e=u[r],!e))throw new Error('Wrong `markdown-it` preset "'+r+'", check name');if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&t.set(e.options),e.components&&Object.keys(e.components).forEach(function(r){e.components[r].rules&&t[r].ruler.enableOnly(e.components[r].rules)}),this},t.prototype.enable=function(e,r){var t=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(r){t=t.concat(this[r].ruler.enable(e,!0))},this);var n=e.filter(function(e){return t.indexOf(e)<0});if(n.length&&!r)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+n);return this},t.prototype.disable=function(e,r){var t=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(r){t=t.concat(this[r].ruler.disable(e,!0))},this);var n=e.filter(function(e){return t.indexOf(e)<0});if(n.length&&!r)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+n);return this},t.prototype.use=function(e){var r=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,r),this},t.prototype.parse=function(e,r){var t=new this.core.State(e,this,r);return this.core.process(t),t.tokens},t.prototype.render=function(e,r){return r=r||{},this.renderer.render(this.parse(e,r),this.options,r)},t.prototype.parseInline=function(e,r){var t=new this.core.State(e,this,r);return t.inlineMode=!0,this.core.process(t),t.tokens},t.prototype.renderInline=function(e,r){return r=r||{},this.renderer.render(this.parseInline(e,r),this.options,r)},r.exports=t},{"./common/utils":5,"./helpers":6,"./parser_block":11,"./parser_core":12,"./parser_inline":13,"./presets/commonmark":14,"./presets/default":15,"./presets/zero":16,"./renderer":17,"linkify-it":50}],11:[function(e,r){"use strict";function t(){this.ruler=new n;for(var e=0;el&&(e.line=l=e.skipEmptyLines(l),!(l>=t))&&!(e.tShift[l]=c){e.line=t;break}for(s=0;o>s&&!(n=i[s](e,l,t,!1));s++);if(e.tight=!a,e.isEmpty(e.line-1)&&(a=!0),l=e.line,t>l&&e.isEmpty(l)){if(a=!0,l++,t>l&&"list"===e.parentType&&e.isEmpty(l))break;e.line=l}}},t.prototype.parse=function(e,r,t,n){var s;return e?(s=new this.State(e,r,t,n),void this.tokenize(s,s.line,s.lineMax)):[]},t.prototype.State=e("./rules_block/state_block"),r.exports=t},{"./ruler":18,"./rules_block/blockquote":19,"./rules_block/code":20,"./rules_block/fence":21,"./rules_block/heading":22,"./rules_block/hr":23,"./rules_block/html_block":24,"./rules_block/lheading":25,"./rules_block/list":26,"./rules_block/paragraph":27,"./rules_block/reference":28,"./rules_block/state_block":29,"./rules_block/table":30}],12:[function(e,r){"use strict";function t(){this.ruler=new n;for(var e=0;er;r++)n[r](e)},t.prototype.State=e("./rules_core/state_core"),r.exports=t},{"./ruler":18,"./rules_core/block":31,"./rules_core/inline":32,"./rules_core/linkify":33,"./rules_core/normalize":34,"./rules_core/replacements":35,"./rules_core/smartquotes":36,"./rules_core/state_core":37}],13:[function(e,r){"use strict";function t(e){var r=i(e);return r=r.trim().toLowerCase(),r.indexOf(":")>=0&&l.indexOf(r.split(":")[0])>=0?!1:!0}function n(){this.validateLink=t,this.ruler=new s;for(var e=0;e0)return void(e.pos=t);if(e.levelr;r++)if(s[r](e,!0))return void e.cacheSet(n,e.pos);e.pos++,e.cacheSet(n,e.pos)},n.prototype.tokenize=function(e){for(var r,t,n=this.ruler.getRules(""),s=n.length,i=e.posMax,o=e.md.options.maxNesting;e.post&&!(r=n[t](e,!1));t++);if(r){if(e.pos>=i)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},n.prototype.parse=function(e,r,t,n){var s=new this.State(e,r,t,n);this.tokenize(s)},n.prototype.State=e("./rules_inline/state_inline"),r.exports=n},{"./common/utils":5,"./ruler":18,"./rules_inline/autolink":38,"./rules_inline/backticks":39,"./rules_inline/emphasis":40,"./rules_inline/entity":41,"./rules_inline/escape":42,"./rules_inline/html_inline":43,"./rules_inline/image":44,"./rules_inline/link":45,"./rules_inline/newline":46,"./rules_inline/state_inline":47,"./rules_inline/strikethrough":48,"./rules_inline/text":49}],14:[function(e,r){"use strict";r.exports={options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"]}}}},{}],15:[function(e,r){"use strict";r.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{},block:{},inline:{}}}},{}],16:[function(e,r){"use strict";r.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"\u201c\u201d\u2018\u2019",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["paragraph"]},inline:{rules:["text"]}}}},{}],17:[function(e,r){"use strict";function t(){this.rules=n({},o)}var n=e("./common/utils").assign,s=e("./common/utils").unescapeAll,i=e("./common/utils").escapeHtml,o={};o.blockquote_open=function(){return"
      \n"},o.blockquote_close=function(){return"
      \n"},o.code_block=function(e,r){return"
      "+i(e[r].content)+"
      \n"},o.code_inline=function(e,r){return""+i(e[r].content)+""},o.fence=function(e,r,t){var n,o=e[r],l="",a=t.langPrefix,c="";return o.params&&(c=i(s(o.params.split(/\s+/g)[0])),l=' class="'+a+c+'"'),n=t.highlight?t.highlight(o.content,c)||i(o.content):i(o.content),"
      "+n+"
      \n"},o.heading_open=function(e,r){return""},o.heading_close=function(e,r){return"\n"},o.hr=function(e,r,t){return t.xhtmlOut?"
      \n":"
      \n"},o.bullet_list_open=function(){return"
        \n"},o.bullet_list_close=function(){return"
      \n"},o.list_item_open=function(e,r){var t=e[r+1];return"list_item_close"===t.type||"paragraph_open"===t.type&&t.tight?"
    1. ":"
    2. \n"},o.list_item_close=function(){return"
    3. \n"},o.ordered_list_open=function(e,r){return e[r].order>1?'
        \n':"
          \n"},o.ordered_list_close=function(){return"
        \n"},o.paragraph_open=function(e,r){return e[r].tight?"":"

        "},o.paragraph_close=function(e,r){return e[r].tight===!0?"close"===e[r+1].type.slice(-5)?"":"\n":"

        \n"},o.link_open=function(e,r){var t=e[r].title?' title="'+i(e[r].title)+'"':"",n=e[r].target?' target="'+i(e[r].target)+'"':"";return'"},o.link_close=function(){return""},o.image=function(e,r,t,n,s){var o=' src="'+i(e[r].src)+'"',l=e[r].title?' title="'+i(e[r].title)+'"':"",a=' alt="'+s.renderInlineAsText(e[r].tokens,t,n)+'"',c=t.xhtmlOut?" /":"";return""},o.table_open=function(){return"\n"},o.table_close=function(){return"
        \n"},o.thead_open=function(){return"\n"},o.thead_close=function(){return"\n"},o.tbody_open=function(){return"\n"},o.tbody_close=function(){return"\n"},o.tr_open=function(){return""},o.tr_close=function(){return"\n"},o.th_open=function(e,r){return e[r].align?'':""},o.th_close=function(){return""},o.td_open=function(e,r){return e[r].align?'':""},o.td_close=function(){return""},o.strong_open=function(){return""},o.strong_close=function(){return""},o.em_open=function(){return""},o.em_close=function(){return""},o.s_open=function(){return""},o.s_close=function(){return""},o.hardbreak=function(e,r,t){return t.xhtmlOut?"
        \n":"
        \n"},o.softbreak=function(e,r,t){return t.breaks?t.xhtmlOut?"
        \n":"
        \n":"\n"},o.text=function(e,r){return i(e[r].content)},o.html_block=function(e,r){return e[r].content},o.html_inline=function(e,r){return e[r].content},t.prototype.renderInline=function(e,r,t){for(var n="",s=this.rules,i=0,o=e.length;o>i;i++)n+=s[e[i].type](e,i,r,t,this);return n},t.prototype.renderInlineAsText=function(e,r,t){for(var n="",s=this.rules,i=0,o=e.length;o>i;i++)"text"===e[i].type?n+=s.text(e,i,r,t,this):"image"===e[i].type&&(n+=this.renderInlineAsText(e[i].tokens,r,t));return n},t.prototype.render=function(e,r,t){var n,s,i="",o=this.rules;for(n=0,s=e.length;s>n;n++)i+="inline"===e[n].type?this.renderInline(e[n].children,r,t):o[e[n].type](e,n,r,t,this);return i},r.exports=t},{"./common/utils":5}],18:[function(e,r){"use strict";function t(){this.__rules__=[],this.__cache__=null}t.prototype.__find__=function(e){for(var r=0;rn){if(r)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[n].enabled=!0,t.push(e)},this),this.__cache__=null,t},t.prototype.enableOnly=function(e,r){Array.isArray(e)||(e=[e]),this.__rules__.forEach(function(e){e.enabled=!1}),this.enable(e,r)},t.prototype.disable=function(e,r){Array.isArray(e)||(e=[e]);var t=[];return e.forEach(function(e){var n=this.__find__(e);if(0>n){if(r)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[n].enabled=!1,t.push(e)},this),this.__cache__=null,t},t.prototype.getRules=function(e){return null===this.__cache__&&this.__compile__(),this.__cache__[e]||[]},r.exports=t},{}],19:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,l,a,c,u,p,h,f,d,m=e.bMarks[r]+e.tShift[r],_=e.eMarks[r];if(62!==e.src.charCodeAt(m++))return!1;if(n)return!0;for(32===e.src.charCodeAt(m)&&m++,a=e.blkIndent,e.blkIndent=0,l=[e.bMarks[r]],e.bMarks[r]=m,m=_>m?e.skipSpaces(m):m,i=m>=_,o=[e.tShift[r]],e.tShift[r]=m-e.bMarks[r],p=e.md.block.ruler.getRules("blockquote"),s=r+1;t>s&&(m=e.bMarks[s]+e.tShift[s],_=e.eMarks[s],!(m>=_));s++)if(62!==e.src.charCodeAt(m++)){if(i)break;for(d=!1,h=0,f=p.length;f>h;h++)if(p[h](e,s,t,!0)){d=!0;break}if(d)break;l.push(e.bMarks[s]),o.push(e.tShift[s]),e.tShift[s]=-1337}else 32===e.src.charCodeAt(m)&&m++,l.push(e.bMarks[s]),e.bMarks[s]=m,m=_>m?e.skipSpaces(m):m,i=m>=_,o.push(e.tShift[s]),e.tShift[s]=m-e.bMarks[s];for(c=e.parentType,e.parentType="blockquote",e.tokens.push({type:"blockquote_open",lines:u=[r,0],level:e.level++}),e.md.block.tokenize(e,r,s),e.tokens.push({type:"blockquote_close",level:--e.level}),e.parentType=c,u[1]=e.line,h=0;hn;)if(e.isEmpty(n))n++;else{if(!(e.tShift[n]-e.blkIndent>=4))break;n++,s=n}return e.line=n,e.tokens.push({type:"code_block",content:e.getLines(r,s,4+e.blkIndent,!0),lines:[r,e.line],level:e.level}),!0}},{}],21:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,l,a,c=!1,u=e.bMarks[r]+e.tShift[r],p=e.eMarks[r];if(u+3>p)return!1;if(s=e.src.charCodeAt(u),126!==s&&96!==s)return!1;if(a=u,u=e.skipChars(u,s),i=u-a,3>i)return!1;if(o=e.src.slice(u,p).trim(),o.indexOf("`")>=0)return!1;if(n)return!0;for(l=r;(l++,!(l>=t))&&(u=a=e.bMarks[l]+e.tShift[l],p=e.eMarks[l],!(p>u&&e.tShift[l]=4||(u=e.skipChars(u,s),i>u-a||(u=e.skipSpaces(u),p>u)))){c=!0;break}return i=e.tShift[r],e.line=l+(c?1:0),e.tokens.push({type:"fence",params:o,content:e.getLines(r+1,l,i,!0),lines:[r,e.line],level:e.level}),!0}},{}],22:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,l=e.bMarks[r]+e.tShift[r],a=e.eMarks[r];if(s=e.src.charCodeAt(l),35!==s||l>=a)return!1;for(i=1,s=e.src.charCodeAt(++l);35===s&&a>l&&6>=i;)i++,s=e.src.charCodeAt(++l);return i>6||a>l&&32!==s?!1:n?!0:(a=e.skipCharsBack(a,32,l),o=e.skipCharsBack(a,35,l),o>l&&32===e.src.charCodeAt(o-1)&&(a=o),e.line=r+1,e.tokens.push({type:"heading_open",hLevel:i,lines:[r,e.line],level:e.level}),a>l&&e.tokens.push({type:"inline",content:e.src.slice(l,a).trim(),level:e.level+1,lines:[r,e.line],children:[]}),e.tokens.push({type:"heading_close",hLevel:i,level:e.level}),!0)}},{}],23:[function(e,r){"use strict";r.exports=function(e,r,t,n){var s,i,o,l=e.bMarks[r]+e.tShift[r],a=e.eMarks[r];if(s=e.src.charCodeAt(l++),42!==s&&45!==s&&95!==s)return!1;for(i=1;a>l;){if(o=e.src.charCodeAt(l++),o!==s&&32!==o)return!1;o===s&&i++}return 3>i?!1:n?!0:(e.line=r+1,e.tokens.push({type:"hr",lines:[r,e.line],level:e.level}),!0)}},{}],24:[function(e,r){"use strict";function t(e){var r=32|e;return r>=97&&122>=r}var n=e("../common/html_blocks"),s=/^<([a-zA-Z]{1,15})[\s\/>]/,i=/^<\/([a-zA-Z]{1,15})[\s>]/;r.exports=function(e,r,o,l){var a,c,u,p=e.bMarks[r],h=e.eMarks[r],f=e.tShift[r];if(p+=f,!e.md.options.html)return!1;if(f>3||p+2>=h)return!1;if(60!==e.src.charCodeAt(p))return!1;if(a=e.src.charCodeAt(p+1),33===a||63===a){if(l)return!0}else{if(47!==a&&!t(a))return!1;if(47===a){if(c=e.src.slice(p,h).match(i),!c)return!1}else if(c=e.src.slice(p,h).match(s),!c)return!1;if(n[c[1].toLowerCase()]!==!0)return!1;if(l)return!0}for(u=r+1;u=t?!1:e.tShift[o]3?!1:(s=e.bMarks[o]+e.tShift[o],i=e.eMarks[o],s>=i?!1:(n=e.src.charCodeAt(s),45!==n&&61!==n?!1:(s=e.skipChars(s,n),s=e.skipSpaces(s),i>s?!1:(s=e.bMarks[r]+e.tShift[r],e.line=o+1,e.tokens.push({type:"heading_open",hLevel:61===n?1:2,lines:[r,e.line],level:e.level}),e.tokens.push({type:"inline",content:e.src.slice(s,e.eMarks[r]).trim(),level:e.level+1,lines:[r,e.line-1],children:[]}),e.tokens.push({type:"heading_close",hLevel:61===n?1:2,level:e.level}),!0))))}},{}],26:[function(e,r){"use strict";function t(e,r){var t,n,s;return n=e.bMarks[r]+e.tShift[r],s=e.eMarks[r],t=e.src.charCodeAt(n++),42!==t&&45!==t&&43!==t?-1:s>n&&32!==e.src.charCodeAt(n)?-1:n}function n(e,r){var t,n=e.bMarks[r]+e.tShift[r],s=e.eMarks[r];if(n+1>=s)return-1;if(t=e.src.charCodeAt(n++),48>t||t>57)return-1;for(;;){if(n>=s)return-1;if(t=e.src.charCodeAt(n++),!(t>=48&&57>=t)){if(41===t||46===t)break;return-1}}return s>n&&32!==e.src.charCodeAt(n)?-1:n}function s(e,r){var t,n,s=e.level+2;for(t=r+2,n=e.tokens.length-2;n>t;t++)e.tokens[t].level===s&&"paragraph_open"===e.tokens[t].type&&(e.tokens[t+2].tight=!0,e.tokens[t].tight=!0,t+=2)}r.exports=function(e,r,i,o){var l,a,c,u,p,h,f,d,m,_,g,b,k,v,y,x,A,w,C,q,D,E,F=!0;if((d=n(e,r))>=0)k=!0;else{if(!((d=t(e,r))>=0))return!1;k=!1}if(b=e.src.charCodeAt(d-1),o)return!0;for(y=e.tokens.length,k?(f=e.bMarks[r]+e.tShift[r],g=Number(e.src.substr(f,d-f-1)),e.tokens.push({type:"ordered_list_open",order:g,lines:A=[r,0],level:e.level++})):e.tokens.push({type:"bullet_list_open",lines:A=[r,0],level:e.level++}),l=r,x=!1,C=e.md.block.ruler.getRules("list");!(!(i>l)||(v=e.skipSpaces(d),m=e.eMarks[l],_=v>=m?1:v-d,_>4&&(_=1),a=d-e.bMarks[l]+_,e.tokens.push({type:"list_item_open",lines:w=[r,0],level:e.level++}),u=e.blkIndent,p=e.tight,c=e.tShift[r],h=e.parentType,e.tShift[r]=v-e.bMarks[r],e.blkIndent=a,e.tight=!0,e.parentType="list",e.md.block.tokenize(e,r,i,!0),(!e.tight||x)&&(F=!1),x=e.line-r>1&&e.isEmpty(e.line-1),e.blkIndent=u,e.tShift[r]=c,e.tight=p,e.parentType=h,e.tokens.push({type:"list_item_close",level:--e.level}),l=r=e.line,w[1]=l,v=e.bMarks[r],l>=i)||e.isEmpty(l)||e.tShift[l]q;q++)if(C[q](e,l,i,!0)){E=!0;break}if(E)break;if(k){if(d=n(e,l),0>d)break}else if(d=t(e,l),0>d)break;if(b!==e.src.charCodeAt(d-1))break}return e.tokens.push({type:k?"ordered_list_close":"bullet_list_close",level:--e.level}),A[1]=l,e.line=l,F&&s(e,y),!0}},{}],27:[function(e,r){"use strict";r.exports=function(e,r){var t,n,s,i,o,l,a=r+1;if(t=e.lineMax,t>a&&!e.isEmpty(a))for(l=e.md.block.ruler.getRules("paragraph");t>a&&!e.isEmpty(a);a++)if(!(e.tShift[a]-e.blkIndent>3)){for(s=!1,i=0,o=l.length;o>i;i++)if(l[i](e,a,t,!0)){s=!0;break}if(s)break}return n=e.getLines(r,a,e.blkIndent,!1).trim(),e.line=a,e.tokens.push({type:"paragraph_open",tight:!1,lines:[r,e.line],level:e.level}),e.tokens.push({type:"inline",content:n,level:e.level+1,lines:[r,e.line],children:[]}),e.tokens.push({type:"paragraph_close",tight:!1,level:e.level}),!0}},{}],28:[function(e,r){"use strict";var t=e("../helpers/parse_link_destination"),n=e("../helpers/parse_link_title"),s=e("../common/utils").normalizeReference;r.exports=function(e,r,i,o){var l,a,c,u,p,h,f,d,m,_,g,b,k,v,y,x=0,A=e.bMarks[r]+e.tShift[r],w=e.eMarks[r],C=r+1;if(91!==e.src.charCodeAt(A))return!1;for(;++AC&&!e.isEmpty(C))for(v=e.md.block.ruler.getRules("reference");u>C&&!e.isEmpty(C);C++)if(!(e.tShift[C]-e.blkIndent>3)){for(k=!1,h=0,f=v.length;f>h;h++)if(v[h](e,C,u,!0)){k=!0;break}if(k)break}for(b=e.getLines(r,C,e.blkIndent,!1).trim(),w=b.length,A=1;w>A;A++){if(l=b.charCodeAt(A),91===l)return!1;if(93===l){m=A;break}10===l?x++:92===l&&(A++,w>A&&10===b.charCodeAt(A)&&x++)}if(0>m||58!==b.charCodeAt(m+1))return!1;for(A=m+2;w>A;A++)if(l=b.charCodeAt(A),10===l)x++;else if(32!==l)break;if(_=t(b,A,w),!_.ok)return!1;if(!e.md.inline.validateLink(_.str))return!1;for(p=_.str,A=_.pos,x+=_.lines,a=A,c=x,g=A;w>A;A++)if(l=b.charCodeAt(A),10===l)x++;else if(32!==l)break;for(_=n(b,A,w),w>A&&g!==A&&_.ok?(y=_.str,A=_.pos,x+=_.lines):(y="",A=a,x=c);w>A&&32===b.charCodeAt(A);)A++;return w>A&&10!==b.charCodeAt(A)?!1:o?!0:(d=s(b.slice(1,m)),"undefined"==typeof e.env.references&&(e.env.references={}),"undefined"==typeof e.env.references[d]&&(e.env.references[d]={title:y,href:p}),e.line=r+x+1,!0)}},{"../common/utils":5,"../helpers/parse_link_destination":7,"../helpers/parse_link_title":9}],29:[function(e,r){"use strict";function t(e,r,t,n){var s,i,o,l,a,c,u;for(this.src=e,this.md=r,this.env=t,this.tokens=n,this.bMarks=[],this.eMarks=[],this.tShift=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.parentType="root",this.ddIndent=-1,this.level=0,this.result="",i=this.src,c=0,u=!1,o=l=c=0,a=i.length;a>l;l++){if(s=i.charCodeAt(l),!u){if(32===s){c++;continue}u=!0}(10===s||l===a-1)&&(10!==s&&l++,this.bMarks.push(o),this.eMarks.push(l),this.tShift.push(c),u=!1,c=0,o=l+1)}this.bMarks.push(i.length),this.eMarks.push(i.length),this.tShift.push(0),this.lineMax=this.bMarks.length-1}t.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},t.prototype.skipEmptyLines=function(e){for(var r=this.lineMax;r>e&&!(this.bMarks[e]+this.tShift[e]e&&32===this.src.charCodeAt(e);e++);return e},t.prototype.skipChars=function(e,r){for(var t=this.src.length;t>e&&this.src.charCodeAt(e)===r;e++);return e},t.prototype.skipCharsBack=function(e,r,t){if(t>=e)return e;for(;e>t;)if(r!==this.src.charCodeAt(--e))return e+1;return e},t.prototype.getLines=function(e,r,t,n){var s,i,o,l,a,c=e;if(e>=r)return"";if(c+1===r)return i=this.bMarks[c]+Math.min(this.tShift[c],t),o=n?this.bMarks[r]:this.eMarks[r-1],this.src.slice(i,o);for(l=new Array(r-e),s=0;r>c;c++,s++)a=this.tShift[c],a>t&&(a=t),0>a&&(a=0),i=this.bMarks[c]+a,o=r>c+1||n?this.eMarks[c]+1:this.eMarks[c],l[s]=this.src.slice(i,o);return l.join("")},r.exports=t},{}],30:[function(e,r){"use strict";function t(e,r){var t=e.bMarks[r]+e.blkIndent,n=e.eMarks[r];return e.src.substr(t,n-t)}function n(e){var r,t=[],n=0,s=e.length,i=0,o=0;for(r=e.charCodeAt(n);s>n;)124===r&&i%2===0?(t.push(e.substring(o,n)),o=n+1):92===r?i++:i=0,r=e.charCodeAt(++n);return t.push(e.substring(o)),t}r.exports=function(e,r,s,i){var o,l,a,c,u,p,h,f,d,m;if(r+2>s)return!1;if(u=r+1,e.tShift[u]=e.eMarks[u])return!1;if(o=e.src.charCodeAt(a),124!==o&&45!==o&&58!==o)return!1;if(l=t(e,r+1),!/^[-:| ]+$/.test(l))return!1;if(p=l.split("|"),p.length<2)return!1;for(h=[],c=0;cu&&!(e.tShift[u]t;t++)r=s[t],"inline"===r.type&&e.md.inline.parse(r.content,e.md,e.env,r.children)}},{}],33:[function(e,r){"use strict";function t(e){return/^\s]/i.test(e)}function n(e){return/^<\/a\s*>/i.test(e)}var s=e("../common/utils").arrayReplaceAt,i=e("../common/utils").normalizeLink;r.exports=function(e){var r,o,l,a,c,u,p,h,f,d,m,_,g,b=e.tokens;if(e.md.options.linkify)for(o=0,l=b.length;l>o;o++)if("inline"===b[o].type)for(a=b[o].children,_=0,r=a.length-1;r>=0;r--)if(c=a[r],"link_close"!==c.type){if("html_inline"===c.type&&(t(c.content)&&_>0&&_--,n(c.content)&&_++),!(_>0)&&"text"===c.type&&e.md.linkify.test(c.content)){for(h=c.content,g=e.md.linkify.match(h),u=[],m=c.level,d=0,p=0;pd&&(m=m,u.push({type:"text",content:h.slice(d,f),level:m})),u.push({type:"link_open",href:i(g[p].url),target:"",title:"",level:m++}),u.push({type:"text",content:g[p].text,level:m}),u.push({type:"link_close",level:--m}),d=g[p].lastIndex);d=0&&(i=0,o=0,r=r.replace(t,function(e,t){var n;return 10===r.charCodeAt(t)?(i=t+1,o=0,e):(n=" ".slice((t-i-o)%4),o=t-i+1,n)})),e.src=r}},{}],35:[function(e,r){"use strict";function t(e){return e.indexOf("(")<0?e:e.replace(s,function(e,r){return i[r.toLowerCase()]})}var n=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,s=/\((c|tm|r|p)\)/gi,i={c:"\xa9",r:"\xae",p:"\xa7",tm:"\u2122"};r.exports=function(e){var r,s,i,o,l;if(e.md.options.typographer)for(l=e.tokens.length-1;l>=0;l--)if("inline"===e.tokens[l].type)for(o=e.tokens[l].children,r=o.length-1;r>=0;r--)s=o[r],"text"===s.type&&(i=s.content,i=t(i),n.test(i)&&(i=i.replace(/\+-/g,"\xb1").replace(/\.{2,}/g,"\u2026").replace(/([?!])\u2026/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---([^-]|$)/gm,"$1\u2014$2").replace(/(^|\s)--(\s|$)/gm,"$1\u2013$2").replace(/(^|[^-\s])--([^-\s]|$)/gm,"$1\u2013$2")),s.content=i)}},{}],36:[function(e,r){"use strict";function t(e,r,t){return e.substr(0,r)+t+e.substr(r+1)}var n=e("../common/utils").isWhiteSpace,s=e("../common/utils").isPunctChar,i=e("../common/utils").isMdAsciiPunct,o=/['"]/,l=/['"]/g,a="\u2019";r.exports=function(e){var r,c,u,p,h,f,d,m,_,g,b,k,v,y,x,A,w,C,q,D,E;if(e.md.options.typographer)for(E=[],q=e.tokens.length-1;q>=0;q--)if("inline"===e.tokens[q].type)for(D=e.tokens[q].children,E.length=0,r=0;r=0&&!(E[w].level<=d);w--);E.length=w+1,u=c.content,h=0,f=u.length;e:for(;f>h&&(l.lastIndex=h,p=l.exec(u));)if(x=A=!0,h=p.index+1,C="'"===p[0],_=p.index-1>=0?u.charCodeAt(p.index-1):-1,g=f>h?u.charCodeAt(h):-1,b=_>=0&&(i(_)||s(String.fromCharCode(_))),k=g>=0&&(i(g)||s(String.fromCharCode(g))),v=0>_||n(_),y=0>g||n(g),y?x=!1:k&&(v||b||(x=!1)),v?A=!1:b&&(y||k||(A=!1)),34===g&&'"'===p[0]&&_>=48&&57>=_&&(A=x=!1),x&&A&&(x=A=!1),x||A){if(A)for(w=E.length-1;w>=0&&(m=E[w],!(E[w].level/,i=/^<([a-zA-Z.\-]{1,25}):([^<>\x00-\x20]*)>/;r.exports=function(e,r){var o,l,a,c,u,p=e.pos;return 60!==e.src.charCodeAt(p)?!1:(o=e.src.slice(p),o.indexOf(">")<0?!1:(l=o.match(i))?t.indexOf(l[1].toLowerCase())<0?!1:(c=l[0].slice(1,-1),u=n(c),e.md.inline.validateLink(c)?(r||(e.push({type:"link_open",href:u,target:"",level:e.level}),e.push({type:"text",content:c,level:e.level+1}),e.push({type:"link_close",level:e.level})),e.pos+=l[0].length,!0):!1):(a=o.match(s),a?(c=a[0].slice(1,-1),u=n("mailto:"+c),e.md.inline.validateLink(u)?(r||(e.push({type:"link_open",href:u,target:"",level:e.level}),e.push({type:"text",content:c,level:e.level+1}),e.push({type:"link_close",level:e.level})),e.pos+=a[0].length,!0):!1):!1))}},{"../common/url_schemas":4,"../common/utils":5}],39:[function(e,r){"use strict";r.exports=function(e,r){var t,n,s,i,o,l=e.pos,a=e.src.charCodeAt(l);if(96!==a)return!1;for(t=l,l++,n=e.posMax;n>l&&96===e.src.charCodeAt(l);)l++;for(s=e.src.slice(t,l),i=o=l;-1!==(i=e.src.indexOf("`",o));){for(o=i+1;n>o&&96===e.src.charCodeAt(o);)o++;if(o-i===s.length)return r||e.push({type:"code_inline",content:e.src.slice(l,i).replace(/[ \n]+/g," ").trim(),level:e.level}),e.pos=o,!0}return r||(e.pending+=s),e.pos+=s.length,!0}},{}],40:[function(e,r){"use strict";function t(e,r){var t,o,l,a,c,u,p,h=r,f=!0,d=!0,m=e.posMax,_=e.src.charCodeAt(r);for(t=r>0?e.src.charCodeAt(r-1):-1;m>h&&e.src.charCodeAt(h)===_;)h++;return h>=m&&(f=!1),l=h-r,o=m>h?e.src.charCodeAt(h):-1,c=t>=0&&(i(t)||s(String.fromCharCode(t))),p=o>=0&&(i(o)||s(String.fromCharCode(o))),a=0>t||n(t),u=0>o||n(o),u?f=!1:p&&(a||c||(f=!1)),a?d=!1:c&&(u||p||(d=!1)),95===_&&f&&d&&(f=d=!1),{can_open:f,can_close:d,delims:l}}var n=e("../common/utils").isWhiteSpace,s=e("../common/utils").isPunctChar,i=e("../common/utils").isMdAsciiPunct;r.exports=function(e,r){var n,s,i,o,l,a,c,u=e.posMax,p=e.pos,h=e.src.charCodeAt(p);if(95!==h&&42!==h)return!1;if(r)return!1;if(c=t(e,p),n=c.delims,!c.can_open)return e.pos+=n,e.pending+=e.src.slice(p,e.pos),!0;for(e.pos=p+n,a=[n];e.posl){a.push(o-l);break}if(l-=o,0===a.length)break;e.pos+=o,o=a.pop()}if(0===a.length){n=o,i=!0;break}e.pos+=s;continue}c.can_open&&a.push(s),e.pos+=s}if(!i)return e.pos=p,!1;for(e.posMax=e.pos,e.pos=p+n,s=n;s>1;s-=2)e.push({type:"strong_open",level:e.level++});for(s%2&&e.push({type:"em_open",level:e.level++}),e.md.inline.tokenize(e),s%2&&e.push({type:"em_close",level:--e.level}),s=n;s>1;s-=2)e.push({type:"strong_close",level:--e.level});return e.pos=e.posMax+n,e.posMax=u,!0}},{"../common/utils":5}],41:[function(e,r){"use strict";var t=e("../common/entities"),n=e("../common/utils").has,s=e("../common/utils").isValidEntityCode,i=e("../common/utils").fromCodePoint,o=/^&#((?:x[a-f0-9]{1,8}|[0-9]{1,8}));/i,l=/^&([a-z][a-z0-9]{1,31});/i;r.exports=function(e,r){var a,c,u,p=e.pos,h=e.posMax;if(38!==e.src.charCodeAt(p))return!1;if(h>p+1)if(a=e.src.charCodeAt(p+1),35===a){if(u=e.src.slice(p).match(o))return r||(c="x"===u[1][0].toLowerCase()?parseInt(u[1].slice(1),16):parseInt(u[1],10),e.pending+=i(s(c)?c:65533)),e.pos+=u[0].length,!0}else if(u=e.src.slice(p).match(l),u&&n(t,u[1]))return r||(e.pending+=t[u[1]]),e.pos+=u[0].length,!0;return r||(e.pending+="&"),e.pos++,!0}},{"../common/entities":1,"../common/utils":5}],42:[function(e,r){"use strict";for(var t=[],n=0;256>n;n++)t.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(e){t[e.charCodeAt(0)]=1}),r.exports=function(e,r){var n,s=e.pos,i=e.posMax;if(92!==e.src.charCodeAt(s))return!1;if(s++,i>s){if(n=e.src.charCodeAt(s),256>n&&0!==t[n])return r||(e.pending+=e.src[s]),e.pos+=2,!0;if(10===n){for(r||e.push({type:"hardbreak",level:e.level}),s++;i>s&&32===e.src.charCodeAt(s);)s++;return e.pos=s,!0}}return r||(e.pending+="\\"),e.pos++,!0}},{}],43:[function(e,r){"use strict";function t(e){var r=32|e;return r>=97&&122>=r}var n=e("../common/html_re").HTML_TAG_RE;r.exports=function(e,r){var s,i,o,l=e.pos;return e.md.options.html?(o=e.posMax,60!==e.src.charCodeAt(l)||l+2>=o?!1:(s=e.src.charCodeAt(l+1),(33===s||63===s||47===s||t(s))&&(i=e.src.slice(l).match(n))?(r||e.push({type:"html_inline",content:e.src.slice(l,l+i[0].length),level:e.level}),e.pos+=i[0].length,!0):!1)):!1}},{"../common/html_re":3}],44:[function(e,r){"use strict";var t=e("../helpers/parse_link_label"),n=e("../helpers/parse_link_destination"),s=e("../helpers/parse_link_title"),i=e("../common/utils").normalizeReference;r.exports=function(e,r){var o,l,a,c,u,p,h,f,d,m,_,g=e.pos,b=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;if(u=e.pos+2,c=t(e,e.pos+1,!1),0>c)return!1;if(p=c+1,b>p&&40===e.src.charCodeAt(p)){for(p++;b>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(p>=b)return!1;for(_=p,f=n(e.src,p,e.posMax),f.ok&&e.md.inline.validateLink(f.str)?(l=f.str,p=f.pos):l="",_=p;b>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(f=s(e.src,p,e.posMax),b>p&&_!==p&&f.ok)for(d=f.str,p=f.pos;b>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);else d="";if(p>=b||41!==e.src.charCodeAt(p))return e.pos=g,!1;p++}else{if("undefined"==typeof e.env.references)return!1;for(;b>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(b>p&&91===e.src.charCodeAt(p)?(_=p+1,p=t(e,p),p>=0?a=e.src.slice(_,p++):p=c+1):p=c+1,a||(a=e.src.slice(u,c)),h=e.env.references[i(a)],!h)return e.pos=g,!1;l=h.href,d=h.title}if(!r){e.pos=u,e.posMax=c;var k=new e.md.inline.State(e.src.slice(u,c),e.md,e.env,m=[]);k.md.inline.tokenize(k),e.push({type:"image",src:l,title:d,tokens:m,level:e.level})}return e.pos=p,e.posMax=b,!0}},{"../common/utils":5,"../helpers/parse_link_destination":7,"../helpers/parse_link_label":8,"../helpers/parse_link_title":9}],45:[function(e,r){"use strict";var t=e("../helpers/parse_link_label"),n=e("../helpers/parse_link_destination"),s=e("../helpers/parse_link_title"),i=e("../common/utils").normalizeReference;r.exports=function(e,r){var o,l,a,c,u,p,h,f,d,m=e.pos,_=e.posMax,g=e.pos;if(91!==e.src.charCodeAt(e.pos))return!1;if(u=e.pos+1,c=t(e,e.pos,!0),0>c)return!1;if(p=c+1,_>p&&40===e.src.charCodeAt(p)){for(p++;_>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(p>=_)return!1;for(g=p,h=n(e.src,p,e.posMax),h.ok&&e.md.inline.validateLink(h.str)?(l=h.str,p=h.pos):l="",g=p;_>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(h=s(e.src,p,e.posMax),_>p&&g!==p&&h.ok)for(d=h.str,p=h.pos;_>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);else d="";if(p>=_||41!==e.src.charCodeAt(p))return e.pos=m,!1;p++}else{if("undefined"==typeof e.env.references)return!1;for(;_>p&&(o=e.src.charCodeAt(p),32===o||10===o);p++);if(_>p&&91===e.src.charCodeAt(p)?(g=p+1,p=t(e,p),p>=0?a=e.src.slice(g,p++):p=c+1):p=c+1,a||(a=e.src.slice(u,c)),f=e.env.references[i(a)],!f)return e.pos=m,!1;l=f.href,d=f.title}return r||(e.pos=u,e.posMax=c,e.push({type:"link_open",href:l,target:"",title:d,level:e.level++}),e.md.inline.tokenize(e),e.push({type:"link_close",level:--e.level})),e.pos=p,e.posMax=_,!0}},{"../common/utils":5,"../helpers/parse_link_destination":7,"../helpers/parse_link_label":8,"../helpers/parse_link_title":9}],46:[function(e,r){"use strict";r.exports=function(e,r){var t,n,s=e.pos;if(10!==e.src.charCodeAt(s))return!1;for(t=e.pending.length-1,n=e.posMax,r||(t>=0&&32===e.pending.charCodeAt(t)?t>=1&&32===e.pending.charCodeAt(t-1)?(e.pending=e.pending.replace(/ +$/,""),e.push({type:"hardbreak",level:e.level})):(e.pending=e.pending.slice(0,-1),e.push({type:"softbreak",level:e.level})):e.push({type:"softbreak",level:e.level})),s++;n>s&&32===e.src.charCodeAt(s);)s++;return e.pos=s,!0}},{}],47:[function(e,r){"use strict";function t(e,r,t,n){this.src=e,this.env=t,this.md=r,this.tokens=n,this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache=[]}t.prototype.pushPending=function(){this.tokens.push({type:"text",content:this.pending,level:this.pendingLevel}),this.pending=""},t.prototype.push=function(e){this.pending&&this.pushPending(),this.tokens.push(e),this.pendingLevel=this.level},t.prototype.cacheSet=function(e,r){for(var t=this.cache.length;e>=t;t++)this.cache.push(0);this.cache[e]=r},t.prototype.cacheGet=function(e){return e0?e.src.charCodeAt(r-1):-1;m>h&&e.src.charCodeAt(h)===_;)h++;return h>=m&&(f=!1),l=h-r,o=m>h?e.src.charCodeAt(h):-1,c=t>=0&&(i(t)||s(String.fromCharCode(t))),p=o>=0&&(i(o)||s(String.fromCharCode(o))),a=t>=0&&n(t),u=o>=0&&n(o),u?f=!1:p&&(a||c||-1===t||(f=!1)),a?d=!1:c&&(u||p||-1===o||(d=!1)),{can_open:f,can_close:d,delims:l}}var n=e("../common/utils").isWhiteSpace,s=e("../common/utils").isPunctChar,i=e("../common/utils").isMdAsciiPunct;r.exports=function(e,r){var n,s,i,o,l,a,c=e.posMax,u=e.pos,p=e.src.charCodeAt(u);if(126!==p)return!1;if(r)return!1;if(a=t(e,u),n=a.delims,!a.can_open)return e.pos+=n,e.pending+=e.src.slice(u,e.pos),!0;if(l=Math.floor(n/2),0>=l)return!1;for(e.pos=u+n;e.pos=l){e.pos+=s-2,o=!0;break}l-=i,e.pos+=s;continue}a.can_open&&(l+=i),e.pos+=s}return o?(e.posMax=e.pos,e.pos=u+2,e.push({type:"s_open",level:e.level++}),e.md.inline.tokenize(e),e.push({type:"s_close",level:--e.level}),e.pos=e.posMax+2,e.posMax=c,!0):(e.pos=u,!1)}},{"../common/utils":5}],49:[function(e,r){"use strict";function t(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}r.exports=function(e,r){for(var n=e.pos;n0&&r.__compiled__[e]}).map(a).join("|");r.re.schema_test=RegExp("(^|(?!_)(?:>|"+f.src_ZPCcCf+"))("+_+")","i"),r.re.schema_search=RegExp("(^|(?!_)(?:>|"+f.src_ZPCcCf+"))("+_+")","ig"),c(r)}function f(e,r){var t=e.__index__,n=e.__last_index__,s=e.__text_cache__.slice(t,n);this.schema=e.__schema__.toLowerCase(),this.index=t+r,this.lastIndex=n+r,this.raw=s,this.text=s,this.url=s}function d(e,r){var t=new f(e,r);return e.__compiled__[t.schema].normalize(t,e),t}function m(e){return this instanceof m?(this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=t({},_,e),this.__compiled__={},this.__tlds__=g,this.__tlds_replaced__=!1,this.re={},void h(this)):new m(e)}var _={"http:":{validate:function(e,r,t){var n=e.slice(r);return t.re.http||(t.re.http=new RegExp("^\\/\\/"+t.re.src_auth+t.re.src_host_port_strict+t.re.src_path,"i")),t.re.http.test(n)?n.match(t.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,r,t){var n=e.slice(r);return t.re.no_http||(t.re.no_http=new RegExp("^"+t.re.src_auth+t.re.src_host_port_strict+t.re.src_path,"i")),t.re.no_http.test(n)?r>=3&&":"===e[r-3]?0:n.match(t.re.no_http)[0].length:0}},"mailto:":{validate:function(e,r,t){var n=e.slice(r);return t.re.mailto||(t.re.mailto=new RegExp("^"+t.re.src_email_name+"@"+t.re.src_host_strict,"i")),t.re.mailto.test(n)?n.match(t.re.mailto)[0].length:0}}},g="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|\u0440\u0444".split("|");m.prototype.add=function(e,r){return this.__schemas__[e]=r,h(this),this},m.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;var r,t,n,s,i,o,l,a,c;if(this.re.schema_test.test(e))for(l=this.re.schema_search,l.lastIndex=0;null!==(r=l.exec(e));)if(s=this.testSchemaAt(e,r[2],l.lastIndex)){this.__schema__=r[2],this.__index__=r.index+r[1].length,this.__last_index__=r.index+r[0].length+s;break}return this.__compiled__["http:"]&&(a=e.search(this.re.host_fuzzy_test),a>=0&&(this.__index__<0||a=0&&null!==(n=e.match(this.re.email_fuzzy))&&(i=n.index+n[1].length,o=n.index+n[0].length,(this.__index__<0||ithis.__last_index__)&&(this.__schema__="mailto:",this.__index__=i,this.__last_index__=o))),this.__index__>=0},m.prototype.testSchemaAt=function(e,r,t){return this.__compiled__[r.toLowerCase()]?this.__compiled__[r.toLowerCase()].validate(e,t,this):0},m.prototype.match=function(e){var r=0,t=[];this.__index__>=0&&this.__text_cache__===e&&(t.push(d(this,r)),r=this.__last_index__);for(var n=r?e.slice(r):e;this.test(n);)t.push(d(this,r)),n=n.slice(this.__last_index__),r+=this.__last_index__;return t.length?t:null},m.prototype.tlds=function(e,r){return e=Array.isArray(e)?e:[e],r?(this.__tlds__=this.__tlds__.concat(e).sort().filter(function(e,r,t){return e!==t[r-1]}).reverse(),h(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,h(this),this)},m.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},r.exports=m},{"./lib/re":51}],51:[function(e,r,t){"use strict";var n=t.src_Any=e("uc.micro/properties/Any/regex").source,s=t.src_Cc=e("uc.micro/categories/Cc/regex").source,i=t.src_Cf=e("uc.micro/categories/Cf/regex").source,o=t.src_Z=e("uc.micro/categories/Z/regex").source,l=t.src_P=e("uc.micro/categories/P/regex").source,a=t.src_ZPCcCf=[o,l,s,i].join("|"),c="(?:(?!"+a+")"+n+")",u="(?:(?![0-9]|"+a+")"+n+")",p=t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)";t.src_auth="(?:(?:(?!"+o+").)+@)?";var h=t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",f=t.src_host_terminator="(?=$|"+a+")(?!-|_|:\\d|\\.-|\\.(?!$|"+a+"))",d=t.src_path="(?:[/?#](?:(?!"+o+"|[()[\\]{}.,\"'?!\\-]).|\\[(?:(?!"+o+"|\\]).)*\\]|\\((?:(?!"+o+"|[)]).)*\\)|\\{(?:(?!"+o+'|[}]).)*\\}|\\"(?:(?!'+o+'|["]).)+\\"|\\\'(?:(?!'+o+"|[']).)+\\'|\\'(?="+c+").|\\.(?!"+o+"|[.]).|\\-(?!"+o+"|--(?:[^-]|$))(?:[-]+|.)|\\,(?!"+o+").|\\!(?!"+o+"|[!]).|\\?(?!"+o+"|[?]).)+|\\/)?",m=t.src_email_name='[\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]+',_=t.src_xn="xn--[a-z0-9\\-]{1,59}",g=t.src_domain_root="(?:"+_+"|"+u+"{1,63})",b=t.src_domain="(?:"+_+"|(?:"+c+")|(?:"+c+"(?:-(?!-)|"+c+"){0,61}"+c+"))",k=t.src_host="(?:"+p+"|(?:(?:(?:"+b+")\\.)*"+g+"))",v=t.tpl_host_fuzzy="(?:"+p+"|(?:(?:(?:"+b+")\\.)+(?:%TLDS%)))";t.src_host_strict=k+f;var y=t.tpl_host_fuzzy_strict=v+f;t.src_host_port_strict=k+h+f;var x=t.tpl_host_port_fuzzy_strict=v+h+f;t.tpl_host_fuzzy_test="localhost|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+a+"|$))",t.tpl_email_fuzzy="(^|>|"+o+")("+m+"@"+y+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|]|"+a+"))((?![$+<=>^`|])"+x+d+")"},{"uc.micro/categories/Cc/regex":53,"uc.micro/categories/Cf/regex":54,"uc.micro/categories/P/regex":55,"uc.micro/categories/Z/regex":56,"uc.micro/properties/Any/regex":57}],52:[function(e,r){"use strict";function t(e){var r,t,n=s[e];if(n)return n;for(n=s[e]=[],r=0;128>r;r++)t=String.fromCharCode(r),n.push(/^[0-9a-z]$/i.test(t)?t:"%"+("0"+r.toString(16).toUpperCase()).slice(-2));for(r=0;ri;i++)if(l=e.charCodeAt(i),s&&37===l&&o>i+2&&/^[0-9a-f]{2}$/i.test(e.slice(i+1,i+3)))u+=e.slice(i,i+3),i+=2;else if(128>l)u+=c[l];else if(l>=55296&&57343>=l){if(l>=55296&&56319>=l&&o>i+1&&(a=e.charCodeAt(i+1),a>=56320&&57343>=a)){u+=encodeURIComponent(e[i]+e[i+1]),i++;continue}u+="%EF%BF%BD"}else u+=encodeURIComponent(e[i]);return u}var s={};n.defaultChars=";/?:@&=+$,-_.!~*'()#",n.componentChars="-_.!~*'()",r.exports=n},{}],53:[function(e,r){r.exports=/[\0-\x1F\x7F-\x9F]/},{}],54:[function(e,r){r.exports=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804\uDCBD|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/},{}],55:[function(e,r){r.exports=/[!-#%-\*,-/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDE38-\uDE3D]|\uD805[\uDCC6\uDDC1-\uDDC9\uDE41-\uDE43]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F/},{}],56:[function(e,r){r.exports=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/},{}],57:[function(e,r){r.exports=/[\0-\uD7FF\uDC00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF]/},{}],58:[function(e,r){"use strict";r.exports=e("./lib/")},{"./lib/":10}]},{},[58])(58)}); \ No newline at end of file