/******/ (() => { // webpackBootstrap
/******/ var __webpack_modules__ = ({
/***/ 228:
/***/ ((module) => {
function _arrayLikeToArray(arr, len) {
if (len == null || len > arr.length) len = arr.length;
for (var i = 0, arr2 = new Array(len); i < len; i++) {
arr2[i] = arr[i];
}
return arr2;
}
module.exports = _arrayLikeToArray;
/***/ }),
/***/ 858:
/***/ ((module) => {
function _arrayWithHoles(arr) {
if (Array.isArray(arr)) return arr;
}
module.exports = _arrayWithHoles;
/***/ }),
/***/ 713:
/***/ ((module) => {
function _defineProperty(obj, key, value) {
if (key in obj) {
Object.defineProperty(obj, key, {
value: value,
enumerable: true,
configurable: true,
writable: true
});
} else {
obj[key] = value;
}
return obj;
}
module.exports = _defineProperty;
/***/ }),
/***/ 884:
/***/ ((module) => {
function _iterableToArrayLimit(arr, i) {
if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
var _arr = [];
var _n = true;
var _d = false;
var _e = undefined;
try {
for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
_arr.push(_s.value);
if (i && _arr.length === i) break;
}
} catch (err) {
_d = true;
_e = err;
} finally {
try {
if (!_n && _i["return"] != null) _i["return"]();
} finally {
if (_d) throw _e;
}
}
return _arr;
}
module.exports = _iterableToArrayLimit;
/***/ }),
/***/ 521:
/***/ ((module) => {
function _nonIterableRest() {
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
}
module.exports = _nonIterableRest;
/***/ }),
/***/ 38:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var arrayWithHoles = __webpack_require__(858);
var iterableToArrayLimit = __webpack_require__(884);
var unsupportedIterableToArray = __webpack_require__(379);
var nonIterableRest = __webpack_require__(521);
function _slicedToArray(arr, i) {
return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();
}
module.exports = _slicedToArray;
/***/ }),
/***/ 379:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var arrayLikeToArray = __webpack_require__(228);
function _unsupportedIterableToArray(o, minLen) {
if (!o) return;
if (typeof o === "string") return arrayLikeToArray(o, minLen);
var n = Object.prototype.toString.call(o).slice(8, -1);
if (n === "Object" && o.constructor) n = o.constructor.name;
if (n === "Map" || n === "Set") return Array.from(o);
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);
}
module.exports = _unsupportedIterableToArray;
/***/ }),
/***/ 804:
/***/ ((module) => {
/**
* SVG elements are case-sensitive.
*
* @see {@link https://developer.mozilla.org/docs/Web/SVG/Element#SVG_elements_A_to_Z}
*/
var CASE_SENSITIVE_TAG_NAMES = [
'animateMotion',
'animateTransform',
'clipPath',
'feBlend',
'feColorMatrix',
'feComponentTransfer',
'feComposite',
'feConvolveMatrix',
'feDiffuseLighting',
'feDisplacementMap',
'feDropShadow',
'feFlood',
'feFuncA',
'feFuncB',
'feFuncG',
'feFuncR',
'feGaussainBlur',
'feImage',
'feMerge',
'feMergeNode',
'feMorphology',
'feOffset',
'fePointLight',
'feSpecularLighting',
'feSpotLight',
'feTile',
'feTurbulence',
'foreignObject',
'linearGradient',
'radialGradient',
'textPath'
];
module.exports = {
CASE_SENSITIVE_TAG_NAMES: CASE_SENSITIVE_TAG_NAMES
};
/***/ }),
/***/ 982:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var utilities = __webpack_require__(412);
// constants
var HTML = 'html';
var HEAD = 'head';
var BODY = 'body';
var FIRST_TAG_REGEX = /<([a-zA-Z]+[0-9]?)/; // e.g.,
var HEAD_TAG_REGEX = //i;
var BODY_TAG_REGEX = //i;
// http://www.w3.org/TR/html/syntax.html#void-elements
var VOID_ELEMENTS_REGEX = /<(area|base|br|col|embed|hr|img|input|keygen|link|menuitem|meta|param|source|track|wbr)(.*?)\/?>/gi;
// detect IE browser
var isIE9 = utilities.isIE(9);
var isIE = isIE9 || utilities.isIE();
// falls back to `parseFromString` if `createHTMLDocument` cannot be used
var parseFromDocument = function () {
throw new Error(
'This browser does not support `document.implementation.createHTMLDocument`'
);
};
var parseFromString = function () {
throw new Error(
'This browser does not support `DOMParser.prototype.parseFromString`'
);
};
/**
* DOMParser (performance: slow).
*
* @see https://developer.mozilla.org/docs/Web/API/DOMParser#Parsing_an_SVG_or_HTML_document
*/
if (typeof window.DOMParser === 'function') {
var domParser = new window.DOMParser();
// IE9 does not support 'text/html' MIME type
// https://msdn.microsoft.com/en-us/library/ff975278(v=vs.85).aspx
var mimeType = isIE9 ? 'text/xml' : 'text/html';
/**
* Creates an HTML document using `DOMParser.parseFromString`.
*
* @param {string} html - The HTML string.
* @param {string} [tagName] - The element to render the HTML (with 'body' as fallback).
* @return {HTMLDocument}
*/
parseFromString = function (html, tagName) {
if (tagName) {
html = '<' + tagName + '>' + html + '' + tagName + '>';
}
// because IE9 only supports MIME type 'text/xml', void elements need to be self-closed
if (isIE9) {
html = html.replace(VOID_ELEMENTS_REGEX, '<$1$2$3/>');
}
return domParser.parseFromString(html, mimeType);
};
parseFromDocument = parseFromString;
}
/**
* DOMImplementation (performance: fair).
*
* @see https://developer.mozilla.org/docs/Web/API/DOMImplementation/createHTMLDocument
*/
if (document.implementation) {
// title parameter is required in IE
// https://msdn.microsoft.com/en-us/library/ff975457(v=vs.85).aspx
var doc = document.implementation.createHTMLDocument(
isIE ? 'html-dom-parser' : undefined
);
/**
* Use HTML document created by `document.implementation.createHTMLDocument`.
*
* @param {string} html - The HTML string.
* @param {string} [tagName] - The element to render the HTML (with 'body' as fallback).
* @return {HTMLDocument}
*/
parseFromDocument = function (html, tagName) {
if (tagName) {
doc.documentElement.getElementsByTagName(tagName)[0].innerHTML = html;
return doc;
}
try {
doc.documentElement.innerHTML = html;
return doc;
// fallback when certain elements in `documentElement` are read-only (IE9)
} catch (err) {
if (parseFromString) {
return parseFromString(html);
}
}
};
}
/**
* Template (performance: fast).
*
* @see https://developer.mozilla.org/docs/Web/HTML/Element/template
*/
var template = document.createElement('template');
var parseFromTemplate;
if (template.content) {
/**
* Uses a template element (content fragment) to parse HTML.
*
* @param {string} html - The HTML string.
* @return {NodeList}
*/
parseFromTemplate = function (html) {
template.innerHTML = html;
return template.content.childNodes;
};
}
/**
* Parses HTML string to DOM nodes.
*
* @param {string} html - The HTML string.
* @return {NodeList|Array}
*/
function domparser(html) {
var firstTagName;
var match = html.match(FIRST_TAG_REGEX);
if (match && match[1]) {
firstTagName = match[1].toLowerCase();
}
var doc;
var element;
var elements;
switch (firstTagName) {
case HTML:
doc = parseFromString(html);
// the created document may come with filler head/body elements,
// so make sure to remove them if they don't actually exist
if (!HEAD_TAG_REGEX.test(html)) {
element = doc.getElementsByTagName(HEAD)[0];
if (element) {
element.parentNode.removeChild(element);
}
}
if (!BODY_TAG_REGEX.test(html)) {
element = doc.getElementsByTagName(BODY)[0];
if (element) {
element.parentNode.removeChild(element);
}
}
return doc.getElementsByTagName(HTML);
case HEAD:
case BODY:
elements = parseFromDocument(html).getElementsByTagName(firstTagName);
// if there's a sibling element, then return both elements
if (BODY_TAG_REGEX.test(html) && HEAD_TAG_REGEX.test(html)) {
return elements[0].parentNode.childNodes;
}
return elements;
// low-level tag or text
default:
if (parseFromTemplate) {
return parseFromTemplate(html);
}
return parseFromDocument(html, BODY).getElementsByTagName(BODY)[0]
.childNodes;
}
}
module.exports = domparser;
/***/ }),
/***/ 57:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var domparser = __webpack_require__(982);
var utilities = __webpack_require__(412);
var formatDOM = utilities.formatDOM;
var isIE9 = utilities.isIE(9);
var DIRECTIVE_REGEX = /<(![a-zA-Z\s]+)>/; // e.g.,
/**
* Parses HTML and reformats DOM nodes output.
*
* @param {String} html - The HTML string.
* @return {Array} - The formatted DOM nodes.
*/
function parseDOM(html) {
if (typeof html !== 'string') {
throw new TypeError('First argument must be a string');
}
if (!html) {
return [];
}
// match directive
var match = html.match(DIRECTIVE_REGEX);
var directive;
if (match && match[1]) {
directive = match[1];
// remove directive in IE9 because DOMParser uses
// MIME type 'text/xml' instead of 'text/html'
if (isIE9) {
html = html.replace(match[0], '');
}
}
return formatDOM(domparser(html), null, directive);
}
module.exports = parseDOM;
/***/ }),
/***/ 412:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var CASE_SENSITIVE_TAG_NAMES = __webpack_require__(804).CASE_SENSITIVE_TAG_NAMES;
var caseSensitiveTagNamesMap = {};
var tagName;
for (var i = 0, len = CASE_SENSITIVE_TAG_NAMES.length; i < len; i++) {
tagName = CASE_SENSITIVE_TAG_NAMES[i];
caseSensitiveTagNamesMap[tagName.toLowerCase()] = tagName;
}
/**
* Gets case-sensitive tag name.
*
* @param {String} tagName - The lowercase tag name.
* @return {String|undefined}
*/
function getCaseSensitiveTagName(tagName) {
return caseSensitiveTagNamesMap[tagName];
}
/**
* Formats DOM attributes to a hash map.
*
* @param {NamedNodeMap} attributes - The list of attributes.
* @return {Object} - A map of attribute name to value.
*/
function formatAttributes(attributes) {
var result = {};
var attribute;
// `NamedNodeMap` is array-like
for (var i = 0, len = attributes.length; i < len; i++) {
attribute = attributes[i];
result[attribute.name] = attribute.value;
}
return result;
}
/**
* Corrects the tag name if it is case-sensitive (SVG).
* Otherwise, returns the lowercase tag name (HTML).
*
* @param {String} tagName - The lowercase tag name.
* @return {String} - The formatted tag name.
*/
function formatTagName(tagName) {
tagName = tagName.toLowerCase();
var caseSensitiveTagName = getCaseSensitiveTagName(tagName);
if (caseSensitiveTagName) {
return caseSensitiveTagName;
}
return tagName;
}
/**
* Formats the browser DOM nodes to mimic the output of `htmlparser2.parseDOM()`.
*
* @param {NodeList} nodes - The DOM nodes.
* @param {Object} [parentObj] - The formatted parent node.
* @param {String} [directive] - The directive.
* @return {Object[]} - The formatted DOM object.
*/
function formatDOM(nodes, parentObj, directive) {
parentObj = parentObj || null;
var result = [];
var node;
var prevNode;
var nodeObj;
// `NodeList` is array-like
for (var i = 0, len = nodes.length; i < len; i++) {
node = nodes[i];
// reset
nodeObj = {
next: null,
prev: result[i - 1] || null,
parent: parentObj
};
// set the next node for the previous node (if applicable)
prevNode = result[i - 1];
if (prevNode) {
prevNode.next = nodeObj;
}
// set the node name if it's not "#text" or "#comment"
// e.g., "div"
if (node.nodeName[0] !== '#') {
nodeObj.name = formatTagName(node.nodeName);
// also, nodes of type "tag" have "attribs"
nodeObj.attribs = {}; // default
if (node.attributes && node.attributes.length) {
nodeObj.attribs = formatAttributes(node.attributes);
}
}
// set the node type
// e.g., "tag"
switch (node.nodeType) {
// 1 = element
case 1:
if (nodeObj.name === 'script' || nodeObj.name === 'style') {
nodeObj.type = nodeObj.name;
} else {
nodeObj.type = 'tag';
}
// recursively format the children
nodeObj.children = formatDOM(node.childNodes, nodeObj);
break;
// 2 = attribute
// 3 = text
case 3:
nodeObj.type = 'text';
nodeObj.data = node.nodeValue;
break;
// 8 = comment
case 8:
nodeObj.type = 'comment';
nodeObj.data = node.nodeValue;
break;
}
result.push(nodeObj);
}
if (directive) {
result.unshift({
name: directive.substring(0, directive.indexOf(' ')).toLowerCase(),
data: directive,
type: 'directive',
next: result[0] ? result[0] : null,
prev: null,
parent: parentObj
});
if (result[1]) {
result[1].prev = result[0];
}
}
return result;
}
/**
* Detects IE with or without version.
*
* @param {Number} [version] - The IE version to detect.
* @return {Boolean} - Whether IE or the version has been detected.
*/
function isIE(version) {
if (version) {
return document.documentMode === version;
}
return /(MSIE |Trident\/|Edge\/)/.test(navigator.userAgent);
}
module.exports = {
formatAttributes: formatAttributes,
formatDOM: formatDOM,
isIE: isIE
};
/***/ }),
/***/ 488:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var domToReact = __webpack_require__(670);
var htmlToDOM = __webpack_require__(57);
// decode HTML entities by default for `htmlparser2`
var domParserOptions = { decodeEntities: true, lowerCaseAttributeNames: false };
/**
* Converts HTML string to React elements.
*
* @param {String} html - HTML string.
* @param {Object} [options] - Parser options.
* @param {Object} [options.htmlparser2] - htmlparser2 options.
* @param {Object} [options.library] - Library for React, Preact, etc.
* @param {Function} [options.replace] - Replace method.
* @return {JSX.Element|JSX.Element[]|String} - React element(s), empty array, or string.
*/
function HTMLReactParser(html, options) {
if (typeof html !== 'string') {
throw new TypeError('First argument must be a string');
}
if (html === '') {
return [];
}
options = options || {};
return domToReact(
htmlToDOM(html, options.htmlparser2 || domParserOptions),
options
);
}
HTMLReactParser.domToReact = domToReact;
HTMLReactParser.htmlToDOM = htmlToDOM;
// support CommonJS and ES Modules
module.exports = HTMLReactParser;
module.exports.default = HTMLReactParser;
/***/ }),
/***/ 484:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var reactProperty = __webpack_require__(686);
var styleToObject = __webpack_require__(848);
var utilities = __webpack_require__(606);
var camelCase = utilities.camelCase;
var htmlProperties = reactProperty.html;
var svgProperties = reactProperty.svg;
var isCustomAttribute = reactProperty.isCustomAttribute;
var hasOwnProperty = Object.prototype.hasOwnProperty;
/**
* Converts HTML/SVG DOM attributes to React props.
*
* @param {Object} [attributes={}] - The HTML/SVG DOM attributes.
* @return {Object} - The React props.
*/
function attributesToProps(attributes) {
attributes = attributes || {};
var attributeName;
var attributeNameLowerCased;
var attributeValue;
var property;
var props = {};
for (attributeName in attributes) {
attributeValue = attributes[attributeName];
// ARIA (aria-*) or custom data (data-*) attribute
if (isCustomAttribute(attributeName)) {
props[attributeName] = attributeValue;
continue;
}
// convert HTML attribute to React prop
attributeNameLowerCased = attributeName.toLowerCase();
if (hasOwnProperty.call(htmlProperties, attributeNameLowerCased)) {
property = htmlProperties[attributeNameLowerCased];
props[property.propertyName] =
property.hasBooleanValue ||
(property.hasOverloadedBooleanValue && !attributeValue)
? true
: attributeValue;
continue;
}
// convert SVG attribute to React prop
if (hasOwnProperty.call(svgProperties, attributeName)) {
property = svgProperties[attributeName];
props[property.propertyName] = attributeValue;
continue;
}
// preserve custom attribute if React >=16
if (utilities.PRESERVE_CUSTOM_ATTRIBUTES) {
props[attributeName] = attributeValue;
}
}
// convert inline style to object
if (attributes.style != null) {
props.style = cssToJs(attributes.style);
}
return props;
}
/**
* Converts inline CSS style to POJO (Plain Old JavaScript Object).
*
* @param {String} style - The inline CSS style.
* @return {Object} - The style object.
*/
function cssToJs(style) {
var styleObject = {};
if (style) {
styleToObject(style, function (property, value) {
// skip CSS comment
if (property && value) {
styleObject[camelCase(property)] = value;
}
});
}
return styleObject;
}
module.exports = attributesToProps;
/***/ }),
/***/ 670:
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
var attributesToProps = __webpack_require__(484);
var utilities = __webpack_require__(606);
/**
* Converts DOM nodes to React elements.
*
* @param {DomElement[]} nodes - The DOM nodes.
* @param {Object} [options={}] - The additional options.
* @param {Function} [options.replace] - The replacer.
* @param {Object} [options.library] - The library (React, Preact, etc.).
* @return {String|ReactElement|ReactElement[]}
*/
function domToReact(nodes, options) {
options = options || {};
var React = options.library || __webpack_require__(815);
var cloneElement = React.cloneElement;
var createElement = React.createElement;
var isValidElement = React.isValidElement;
var result = [];
var node;
var hasReplace = typeof options.replace === 'function';
var replaceElement;
var props;
var children;
var data;
var trim = options.trim;
for (var i = 0, len = nodes.length; i < len; i++) {
node = nodes[i];
// replace with custom React element (if present)
if (hasReplace) {
replaceElement = options.replace(node);
if (isValidElement(replaceElement)) {
// set "key" prop for sibling elements
// https://fb.me/react-warning-keys
if (len > 1) {
replaceElement = cloneElement(replaceElement, {
key: replaceElement.key || i
});
}
result.push(replaceElement);
continue;
}
}
if (node.type === 'text') {
// if trim option is enabled, skip whitespace text nodes
if (trim) {
data = node.data.trim();
if (data) {
result.push(node.data);
}
} else {
result.push(node.data);
}
continue;
}
props = node.attribs;
if (!shouldPassAttributesUnaltered(node)) {
props = attributesToProps(node.attribs);
}
children = null;
switch (node.type) {
case 'script':
case 'style':
// prevent text in