html-react-parser
Advanced tools
Comparing version 5.2.0 to 5.2.1
@@ -1,2 +0,2 @@ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("react")):"function"==typeof define&&define.amd?define(["react"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).HTMLReactParser=t(e.React)}(this,(function(e){"use strict";function t(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}function n(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var r,o={},i={},a={},l={},s={},c={};function u(){return r||(r=1,function(e){var t;Object.defineProperty(e,"__esModule",{value:!0}),e.Doctype=e.CDATA=e.Tag=e.Style=e.Script=e.Comment=e.Directive=e.Text=e.Root=e.isTag=e.ElementType=void 0,function(e){e.Root="root",e.Text="text",e.Directive="directive",e.Comment="comment",e.Script="script",e.Style="style",e.Tag="tag",e.CDATA="cdata",e.Doctype="doctype"}(t=e.ElementType||(e.ElementType={})),e.isTag=function(e){return e.type===t.Tag||e.type===t.Script||e.type===t.Style},e.Root=t.Root,e.Text=t.Text,e.Directive=t.Directive,e.Comment=t.Comment,e.Script=t.Script,e.Style=t.Style,e.Tag=t.Tag,e.CDATA=t.CDATA,e.Doctype=t.Doctype}(c)),c}var p,d,f={};function h(){if(p)return f;p=1;var e,t=f&&f.__extends||(e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)},function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}),n=f&&f.__assign||function(){return n=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},n.apply(this,arguments)};Object.defineProperty(f,"__esModule",{value:!0}),f.cloneNode=f.hasChildren=f.isDocument=f.isDirective=f.isComment=f.isText=f.isCDATA=f.isTag=f.Element=f.Document=f.CDATA=f.NodeWithChildren=f.ProcessingInstruction=f.Comment=f.Text=f.DataNode=f.Node=void 0;var r=u(),o=function(){function e(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent},set:function(e){this.parent=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return this.prev},set:function(e){this.prev=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return this.next},set:function(e){this.next=e},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(e){return void 0===e&&(e=!1),T(this,e)},e}();f.Node=o;var i=function(e){function n(t){var n=e.call(this)||this;return n.data=t,n}return t(n,e),Object.defineProperty(n.prototype,"nodeValue",{get:function(){return this.data},set:function(e){this.data=e},enumerable:!1,configurable:!0}),n}(o);f.DataNode=i;var a=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.Text,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),n}(i);f.Text=a;var l=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.Comment,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),n}(i);f.Comment=l;var s=function(e){function n(t,n){var o=e.call(this,n)||this;return o.name=t,o.type=r.ElementType.Directive,o}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),n}(i);f.ProcessingInstruction=s;var c=function(e){function n(t){var n=e.call(this)||this;return n.children=t,n}return t(n,e),Object.defineProperty(n.prototype,"firstChild",{get:function(){var e;return null!==(e=this.children[0])&&void 0!==e?e:null},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"childNodes",{get:function(){return this.children},set:function(e){this.children=e},enumerable:!1,configurable:!0}),n}(o);f.NodeWithChildren=c;var d=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.CDATA,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),n}(c);f.CDATA=d;var h=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.Root,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),n}(c);f.Document=h;var m=function(e){function n(t,n,o,i){void 0===o&&(o=[]),void 0===i&&(i="script"===t?r.ElementType.Script:"style"===t?r.ElementType.Style:r.ElementType.Tag);var a=e.call(this,o)||this;return a.name=t,a.attribs=n,a.type=i,a}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"tagName",{get:function(){return this.name},set:function(e){this.name=e},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"attributes",{get:function(){var e=this;return Object.keys(this.attribs).map((function(t){var n,r;return{name:t,value:e.attribs[t],namespace:null===(n=e["x-attribsNamespace"])||void 0===n?void 0:n[t],prefix:null===(r=e["x-attribsPrefix"])||void 0===r?void 0:r[t]}}))},enumerable:!1,configurable:!0}),n}(c);function y(e){return(0,r.isTag)(e)}function g(e){return e.type===r.ElementType.CDATA}function v(e){return e.type===r.ElementType.Text}function b(e){return e.type===r.ElementType.Comment}function x(e){return e.type===r.ElementType.Directive}function E(e){return e.type===r.ElementType.Root}function T(e,t){var r;if(void 0===t&&(t=!1),v(e))r=new a(e.data);else if(b(e))r=new l(e.data);else if(y(e)){var o=t?k(e.children):[],i=new m(e.name,n({},e.attribs),o);o.forEach((function(e){return e.parent=i})),null!=e.namespace&&(i.namespace=e.namespace),e["x-attribsNamespace"]&&(i["x-attribsNamespace"]=n({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(i["x-attribsPrefix"]=n({},e["x-attribsPrefix"])),r=i}else if(g(e)){o=t?k(e.children):[];var c=new d(o);o.forEach((function(e){return e.parent=c})),r=c}else if(E(e)){o=t?k(e.children):[];var u=new h(o);o.forEach((function(e){return e.parent=u})),e["x-mode"]&&(u["x-mode"]=e["x-mode"]),r=u}else{if(!x(e))throw new Error("Not implemented yet: ".concat(e.type));var p=new s(e.name,e.data);null!=e["x-name"]&&(p["x-name"]=e["x-name"],p["x-publicId"]=e["x-publicId"],p["x-systemId"]=e["x-systemId"]),r=p}return r.startIndex=e.startIndex,r.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(r.sourceCodeLocation=e.sourceCodeLocation),r}function k(e){for(var t=e.map((function(e){return T(e,!0)})),n=1;n<t.length;n++)t[n].prev=t[n-1],t[n-1].next=t[n];return t}return f.Element=m,f.isTag=y,f.isCDATA=g,f.isText=v,f.isComment=b,f.isDirective=x,f.isDocument=E,f.hasChildren=function(e){return Object.prototype.hasOwnProperty.call(e,"children")},f.cloneNode=T,f}function m(){return d||(d=1,function(e){var t=s&&s.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=s&&s.__exportStar||function(e,n){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(n,r)||t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.DomHandler=void 0;var r=u(),o=h();n(h(),e);var i={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},a=function(){function e(e,t,n){this.dom=[],this.root=new o.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,"function"==typeof t&&(n=t,t=i),"object"==typeof e&&(t=e,e=void 0),this.callback=null!=e?e:null,this.options=null!=t?t:i,this.elementCB=null!=n?n:null}return e.prototype.onparserinit=function(e){this.parser=e},e.prototype.onreset=function(){this.dom=[],this.root=new o.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},e.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},e.prototype.onerror=function(e){this.handleCallback(e)},e.prototype.onclosetag=function(){this.lastNode=null;var e=this.tagStack.pop();this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)},e.prototype.onopentag=function(e,t){var n=this.options.xmlMode?r.ElementType.Tag:void 0,i=new o.Element(e,t,void 0,n);this.addNode(i),this.tagStack.push(i)},e.prototype.ontext=function(e){var t=this.lastNode;if(t&&t.type===r.ElementType.Text)t.data+=e,this.options.withEndIndices&&(t.endIndex=this.parser.endIndex);else{var n=new o.Text(e);this.addNode(n),this.lastNode=n}},e.prototype.oncomment=function(e){if(this.lastNode&&this.lastNode.type===r.ElementType.Comment)this.lastNode.data+=e;else{var t=new o.Comment(e);this.addNode(t),this.lastNode=t}},e.prototype.oncommentend=function(){this.lastNode=null},e.prototype.oncdatastart=function(){var e=new o.Text(""),t=new o.CDATA([e]);this.addNode(t),e.parent=t,this.lastNode=e},e.prototype.oncdataend=function(){this.lastNode=null},e.prototype.onprocessinginstruction=function(e,t){var n=new o.ProcessingInstruction(e,t);this.addNode(n)},e.prototype.handleCallback=function(e){if("function"==typeof this.callback)this.callback(e,this.dom);else if(e)throw e},e.prototype.addNode=function(e){var t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null},e}();e.DomHandler=a,e.default=a}(s)),s}var y,g,v,b,x={};function E(){if(g)return l;g=1,Object.defineProperty(l,"__esModule",{value:!0}),l.formatAttributes=n,l.escapeSpecialCharacters=function(e){return e.replace(/\r/g,"\\r")},l.revertEscapedCharacters=o,l.formatDOM=function t(i,a,l){void 0===a&&(a=null);for(var s,c=[],u=0,p=i.length;u<p;u++){var d=i[u];switch(d.nodeType){case 1:var f=r(d.nodeName);(s=new e.Element(f,n(d.attributes))).children=t("template"===f?d.content.childNodes:d.childNodes,s);break;case 3:s=new e.Text(o(d.nodeValue));break;case 8:s=new e.Comment(d.nodeValue);break;default:continue}var h=c[u-1]||null;h&&(h.next=s),s.parent=a,s.prev=h,s.next=null,c.push(s)}l&&((s=new e.ProcessingInstruction(l.substring(0,l.indexOf(" ")).toLowerCase(),l)).next=c[0]||null,s.parent=a,c.unshift(s),c[1]&&(c[1].prev=c[0]));return c};var e=m(),t=(y||(y=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES=void 0,e.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"],e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES.reduce((function(e,t){return e[t.toLowerCase()]=t,e}),{})}(x)),x);function n(e){for(var t={},n=0,r=e.length;n<r;n++){var o=e[n];t[o.name]=o.value}return t}function r(e){var n=function(e){return t.CASE_SENSITIVE_TAG_NAMES_MAP[e]}(e=e.toLowerCase());return n||e}function o(e){return e.replace(/\\r/g,"\r")}return l}function T(){if(b)return i;b=1;var e=i&&i.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(i,"__esModule",{value:!0}),i.default=function(e){if("string"!=typeof e)throw new TypeError("First argument must be a string");if(!e)return[];var o=e.match(r),i=o?o[1]:void 0;return(0,n.formatDOM)((0,t.default)(e),null,i)};var t=e(function(){if(v)return a;v=1,Object.defineProperty(a,"__esModule",{value:!0}),a.default=function(a){var u,p,d=(a=(0,e.escapeSpecialCharacters)(a)).match(o),h=d&&d[1]?d[1].toLowerCase():"";switch(h){case t:var m=c(a);return i.test(a)||null===(u=null==(g=m.querySelector(n))?void 0:g.parentNode)||void 0===u||u.removeChild(g),l.test(a)||null===(p=null==(g=m.querySelector(r))?void 0:g.parentNode)||void 0===p||p.removeChild(g),m.querySelectorAll(t);case n:case r:var y=s(a).querySelectorAll(h);return l.test(a)&&i.test(a)?y[0].parentNode.childNodes:y;default:return f?f(a):(g=s(a,r).querySelector(r)).childNodes;var g}};var e=E(),t="html",n="head",r="body",o=/<([a-zA-Z]+[0-9]?)/,i=/<head[^]*>/i,l=/<body[^]*>/i,s=function(e,t){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},c=function(e,t){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},u="object"==typeof window&&window.DOMParser;if("function"==typeof u){var p=new u;s=c=function(e,t){return t&&(e="<".concat(t,">").concat(e,"</").concat(t,">")),p.parseFromString(e,"text/html")}}if("object"==typeof document&&document.implementation){var d=document.implementation.createHTMLDocument();s=function(e,t){if(t){var n=d.documentElement.querySelector(t);return n&&(n.innerHTML=e),d}return d.documentElement.innerHTML=e,d}}var f,h="object"==typeof document&&document.createElement("template");return h&&h.content&&(f=function(e){return h.innerHTML=e,h.content.childNodes}),a}()),n=E(),r=/<(![a-zA-Z\s]+)>/;return i}var k,w,S={},C={},_={};function O(){if(k)return _;k=1;_.SAME=0;return _.CAMELCASE=1,_.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1},_}var A,P,N,M={},I={};function D(){if(N)return I;N=1;var e=I&&I.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(I,"__esModule",{value:!0}),I.default=function(e,n){var r=null;if(!e||"string"!=typeof e)return r;var o=(0,t.default)(e),i="function"==typeof n;return o.forEach((function(e){if("declaration"===e.type){var t=e.property,o=e.value;i?n(t,o,e):o&&((r=r||{})[t]=o)}})),r};var t=e(function(){if(P)return A;P=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,i=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,l=/^\s+|\s+$/g,s="";function c(e){return e?e.replace(l,s):s}return A=function(l,u){if("string"!=typeof l)throw new TypeError("First argument must be a string");if(!l)return[];u=u||{};var p=1,d=1;function f(e){var n=e.match(t);n&&(p+=n.length);var r=e.lastIndexOf("\n");d=~r?e.length-r:d+e.length}function h(){var e={line:p,column:d};return function(t){return t.position=new m(e),v(),t}}function m(e){this.start=e,this.end={line:p,column:d},this.source=u.source}function y(e){var t=new Error(u.source+":"+p+":"+d+": "+e);if(t.reason=e,t.filename=u.source,t.line=p,t.column=d,t.source=l,!u.silent)throw t}function g(e){var t=e.exec(l);if(t){var n=t[0];return f(n),l=l.slice(n.length),t}}function v(){g(n)}function b(e){var t;for(e=e||[];t=x();)!1!==t&&e.push(t);return e}function x(){var e=h();if("/"==l.charAt(0)&&"*"==l.charAt(1)){for(var t=2;s!=l.charAt(t)&&("*"!=l.charAt(t)||"/"!=l.charAt(t+1));)++t;if(t+=2,s===l.charAt(t-1))return y("End of comment missing");var n=l.slice(2,t-2);return d+=2,f(n),l=l.slice(t),d+=2,e({type:"comment",comment:n})}}function E(){var t=h(),n=g(r);if(n){if(x(),!g(o))return y("property missing ':'");var l=g(i),u=t({type:"declaration",property:c(n[0].replace(e,s)),value:l?c(l[0].replace(e,s)):s});return g(a),u}}return m.prototype.content=l,v(),function(){var e,t=[];for(b(t);e=E();)!1!==e&&(t.push(e),b(t));return t}()},A}());return I}var R,j,L,F,H,z={};function B(){if(R)return z;R=1,Object.defineProperty(z,"__esModule",{value:!0}),z.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,i=function(e,t){return t.toUpperCase()},a=function(e,t){return"".concat(t,"-")};return z.camelCase=function(l,s){return void 0===s&&(s={}),function(t){return!t||n.test(t)||e.test(t)}(l)?l:(l=l.toLowerCase(),(l=s.reactCompat?l.replace(o,a):l.replace(r,a)).replace(t,i))},z}function V(){return F||(F=1,function(t){var n=M&&M.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.returnFirstArg=t.canTextBeChildOfNode=t.ELEMENTS_WITH_NO_TEXT_CHILDREN=t.PRESERVE_CUSTOM_ATTRIBUTES=void 0,t.isCustomComponent=function(e,t){if(!e.includes("-"))return Boolean(t&&"string"==typeof t.is);if(i.has(e))return!1;return!0},t.setStyleProp=function(e,t){if("string"!=typeof e)return;if(!e.trim())return void(t.style={});try{t.style=(0,o.default)(e,a)}catch(e){t.style={}}};var r=e,o=n(function(){if(L)return j;L=1;var e=(j&&j.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(D()),t=B();function n(n,r){var o={};return n&&"string"==typeof n?((0,e.default)(n,(function(e,n){e&&n&&(o[(0,t.camelCase)(e,r)]=n)})),o):o}return n.default=n,j=n}()),i=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);var a={reactCompat:!0};t.PRESERVE_CUSTOM_ATTRIBUTES=Number(r.version.split(".")[0])>=16,t.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);t.canTextBeChildOfNode=function(e){return!t.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(e.name)};t.returnFirstArg=function(e){return e}}(M)),M}function U(){if(H)return S;H=1,Object.defineProperty(S,"__esModule",{value:!0}),S.default=function(a,l){void 0===a&&(a={});var s={},c=Boolean(a.type&&o[a.type]);for(var u in a){var p=a[u];if((0,e.isCustomAttribute)(u))s[u]=p;else{var d=u.toLowerCase(),f=i(d);if(f){var h=(0,e.getPropertyInfo)(f);switch(n.includes(f)&&r.includes(l)&&!c&&(f=i("default"+d)),s[f]=p,h&&h.type){case e.BOOLEAN:s[f]=!0;break;case e.OVERLOADED_BOOLEAN:""===p&&(s[f]=!0)}}else t.PRESERVE_CUSTOM_ATTRIBUTES&&(s[u]=p)}}return(0,t.setStyleProp)(a.style,s),s};var e=function(){if(w)return C;function e(e,t,n,r,o,i,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=a}w=1;const t={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach((n=>{t[n]=new e(n,0,!1,n,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((([n,r])=>{t[n]=new e(n,1,!1,r,null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((n=>{t[n]=new e(n,2,!1,n.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((n=>{t[n]=new e(n,2,!1,n,null,!1,!1)})),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach((n=>{t[n]=new e(n,3,!1,n.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((n=>{t[n]=new e(n,3,!0,n,null,!1,!1)})),["capture","download"].forEach((n=>{t[n]=new e(n,4,!1,n,null,!1,!1)})),["cols","rows","size","span"].forEach((n=>{t[n]=new e(n,6,!1,n,null,!1,!1)})),["rowSpan","start"].forEach((n=>{t[n]=new e(n,5,!1,n.toLowerCase(),null,!1,!1)}));const n=/[\-\:]([a-z])/g,r=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach((o=>{const i=o.replace(n,r);t[i]=new e(i,1,!1,o,null,!1,!1)})),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach((o=>{const i=o.replace(n,r);t[i]=new e(i,1,!1,o,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((o=>{const i=o.replace(n,r);t[i]=new e(i,1,!1,o,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((n=>{t[n]=new e(n,1,!1,n.toLowerCase(),null,!1,!1)})),t.xlinkHref=new e("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((n=>{t[n]=new e(n,1,!1,n.toLowerCase(),null,!0,!0)}));const{CAMELCASE:o,SAME:i,possibleStandardNames:a}=O(),l=RegExp.prototype.test.bind(new RegExp("^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$")),s=Object.keys(a).reduce(((e,t)=>{const n=a[t];return n===i?e[t]=t:n===o?e[t.toLowerCase()]=t:e[t]=n,e}),{});return C.BOOLEAN=3,C.BOOLEANISH_STRING=2,C.NUMERIC=5,C.OVERLOADED_BOOLEAN=4,C.POSITIVE_NUMERIC=6,C.RESERVED=0,C.STRING=1,C.getPropertyInfo=function(e){return t.hasOwnProperty(e)?t[e]:null},C.isCustomAttribute=l,C.possibleStandardNames=s,C}(),t=V(),n=["checked","value"],r=["input","select","textarea"],o={reset:!0,submit:!0};function i(t){return e.possibleStandardNames[t]}return S}var q,W,X={};var G=(W||(W=1,function(t){var n=o&&o.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.htmlToDOM=t.domToReact=t.attributesToProps=t.Text=t.ProcessingInstruction=t.Element=t.Comment=void 0,t.default=function(e,t){if("string"!=typeof e)throw new TypeError("First argument must be a string");return e?(0,a.default)((0,r.default)(e,(null==t?void 0:t.htmlparser2)||s),t):[]};var r=n(T());t.htmlToDOM=r.default;var i=n(U());t.attributesToProps=i.default;var a=n(function(){if(q)return X;q=1;var t=X&&X.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(X,"__esModule",{value:!0}),X.default=function e(t,n){void 0===n&&(n={});for(var l=[],s="function"==typeof n.replace,c=n.transform||o.returnFirstArg,u=n.library||i,p=u.cloneElement,d=u.createElement,f=u.isValidElement,h=t.length,m=0;m<h;m++){var y=t[m];if(s){var g=n.replace(y,m);if(f(g)){h>1&&(g=p(g,{key:g.key||m})),l.push(c(g,y,m));continue}}if("text"!==y.type){var v=y,b={};a(v)?((0,o.setStyleProp)(v.attribs.style,v.attribs),b=v.attribs):v.attribs&&(b=(0,r.default)(v.attribs,v.name));var x=void 0;switch(y.type){case"script":case"style":y.children[0]&&(b.dangerouslySetInnerHTML={__html:y.children[0].data});break;case"tag":"textarea"===y.name&&y.children[0]?b.defaultValue=y.children[0].data:y.children&&y.children.length&&(x=e(y.children,n));break;default:continue}h>1&&(b.key=m),l.push(c(d(y.name,b,x),y,m))}else{var E=!y.data.trim().length;if(E&&y.parent&&!(0,o.canTextBeChildOfNode)(y.parent))continue;if(n.trim&&E)continue;l.push(c(y.data,y,m))}}return 1===l.length?l[0]:l};var n=e,r=t(U()),o=V(),i={cloneElement:n.cloneElement,createElement:n.createElement,isValidElement:n.isValidElement};function a(e){return o.PRESERVE_CUSTOM_ATTRIBUTES&&"tag"===e.type&&(0,o.isCustomComponent)(e.name,e.attribs)}return X}());t.domToReact=a.default;var l=m();Object.defineProperty(t,"Comment",{enumerable:!0,get:function(){return l.Comment}}),Object.defineProperty(t,"Element",{enumerable:!0,get:function(){return l.Element}}),Object.defineProperty(t,"ProcessingInstruction",{enumerable:!0,get:function(){return l.ProcessingInstruction}}),Object.defineProperty(t,"Text",{enumerable:!0,get:function(){return l.Text}});var s={lowerCaseAttributeNames:!1}}(o)),o),Y=n(G),Z=t({__proto__:null,default:Y},[G]);const $=Y;return Object.assign($,Z),$})); | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t(require("react")):"function"==typeof define&&define.amd?define(["react"],t):(e="undefined"!=typeof globalThis?globalThis:e||self).HTMLReactParser=t(e.React)}(this,(function(e){"use strict";function t(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}function n(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var r,o={},i={},a={},l={},s={},c={};function u(){return r||(r=1,function(e){var t;Object.defineProperty(e,"__esModule",{value:!0}),e.Doctype=e.CDATA=e.Tag=e.Style=e.Script=e.Comment=e.Directive=e.Text=e.Root=e.isTag=e.ElementType=void 0,function(e){e.Root="root",e.Text="text",e.Directive="directive",e.Comment="comment",e.Script="script",e.Style="style",e.Tag="tag",e.CDATA="cdata",e.Doctype="doctype"}(t=e.ElementType||(e.ElementType={})),e.isTag=function(e){return e.type===t.Tag||e.type===t.Script||e.type===t.Style},e.Root=t.Root,e.Text=t.Text,e.Directive=t.Directive,e.Comment=t.Comment,e.Script=t.Script,e.Style=t.Style,e.Tag=t.Tag,e.CDATA=t.CDATA,e.Doctype=t.Doctype}(c)),c}var p,d,f={};function h(){if(p)return f;p=1;var e,t=f&&f.__extends||(e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)},function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}),n=f&&f.__assign||function(){return n=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},n.apply(this,arguments)};Object.defineProperty(f,"__esModule",{value:!0}),f.cloneNode=f.hasChildren=f.isDocument=f.isDirective=f.isComment=f.isText=f.isCDATA=f.isTag=f.Element=f.Document=f.CDATA=f.NodeWithChildren=f.ProcessingInstruction=f.Comment=f.Text=f.DataNode=f.Node=void 0;var r=u(),o=function(){function e(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent},set:function(e){this.parent=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return this.prev},set:function(e){this.prev=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return this.next},set:function(e){this.next=e},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(e){return void 0===e&&(e=!1),T(this,e)},e}();f.Node=o;var i=function(e){function n(t){var n=e.call(this)||this;return n.data=t,n}return t(n,e),Object.defineProperty(n.prototype,"nodeValue",{get:function(){return this.data},set:function(e){this.data=e},enumerable:!1,configurable:!0}),n}(o);f.DataNode=i;var a=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.Text,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),n}(i);f.Text=a;var l=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.Comment,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),n}(i);f.Comment=l;var s=function(e){function n(t,n){var o=e.call(this,n)||this;return o.name=t,o.type=r.ElementType.Directive,o}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),n}(i);f.ProcessingInstruction=s;var c=function(e){function n(t){var n=e.call(this)||this;return n.children=t,n}return t(n,e),Object.defineProperty(n.prototype,"firstChild",{get:function(){var e;return null!==(e=this.children[0])&&void 0!==e?e:null},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"childNodes",{get:function(){return this.children},set:function(e){this.children=e},enumerable:!1,configurable:!0}),n}(o);f.NodeWithChildren=c;var d=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.CDATA,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),n}(c);f.CDATA=d;var h=function(e){function n(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=r.ElementType.Root,t}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),n}(c);f.Document=h;var m=function(e){function n(t,n,o,i){void 0===o&&(o=[]),void 0===i&&(i="script"===t?r.ElementType.Script:"style"===t?r.ElementType.Style:r.ElementType.Tag);var a=e.call(this,o)||this;return a.name=t,a.attribs=n,a.type=i,a}return t(n,e),Object.defineProperty(n.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"tagName",{get:function(){return this.name},set:function(e){this.name=e},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"attributes",{get:function(){var e=this;return Object.keys(this.attribs).map((function(t){var n,r;return{name:t,value:e.attribs[t],namespace:null===(n=e["x-attribsNamespace"])||void 0===n?void 0:n[t],prefix:null===(r=e["x-attribsPrefix"])||void 0===r?void 0:r[t]}}))},enumerable:!1,configurable:!0}),n}(c);function g(e){return(0,r.isTag)(e)}function y(e){return e.type===r.ElementType.CDATA}function v(e){return e.type===r.ElementType.Text}function E(e){return e.type===r.ElementType.Comment}function b(e){return e.type===r.ElementType.Directive}function x(e){return e.type===r.ElementType.Root}function T(e,t){var r;if(void 0===t&&(t=!1),v(e))r=new a(e.data);else if(E(e))r=new l(e.data);else if(g(e)){var o=t?_(e.children):[],i=new m(e.name,n({},e.attribs),o);o.forEach((function(e){return e.parent=i})),null!=e.namespace&&(i.namespace=e.namespace),e["x-attribsNamespace"]&&(i["x-attribsNamespace"]=n({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(i["x-attribsPrefix"]=n({},e["x-attribsPrefix"])),r=i}else if(y(e)){o=t?_(e.children):[];var c=new d(o);o.forEach((function(e){return e.parent=c})),r=c}else if(x(e)){o=t?_(e.children):[];var u=new h(o);o.forEach((function(e){return e.parent=u})),e["x-mode"]&&(u["x-mode"]=e["x-mode"]),r=u}else{if(!b(e))throw new Error("Not implemented yet: ".concat(e.type));var p=new s(e.name,e.data);null!=e["x-name"]&&(p["x-name"]=e["x-name"],p["x-publicId"]=e["x-publicId"],p["x-systemId"]=e["x-systemId"]),r=p}return r.startIndex=e.startIndex,r.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(r.sourceCodeLocation=e.sourceCodeLocation),r}function _(e){for(var t=e.map((function(e){return T(e,!0)})),n=1;n<t.length;n++)t[n].prev=t[n-1],t[n-1].next=t[n];return t}return f.Element=m,f.isTag=g,f.isCDATA=y,f.isText=v,f.isComment=E,f.isDirective=b,f.isDocument=x,f.hasChildren=function(e){return Object.prototype.hasOwnProperty.call(e,"children")},f.cloneNode=T,f}function m(){return d||(d=1,function(e){var t=s&&s.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=s&&s.__exportStar||function(e,n){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(n,r)||t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.DomHandler=void 0;var r=u(),o=h();n(h(),e);var i={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},a=function(){function e(e,t,n){this.dom=[],this.root=new o.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,"function"==typeof t&&(n=t,t=i),"object"==typeof e&&(t=e,e=void 0),this.callback=null!=e?e:null,this.options=null!=t?t:i,this.elementCB=null!=n?n:null}return e.prototype.onparserinit=function(e){this.parser=e},e.prototype.onreset=function(){this.dom=[],this.root=new o.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},e.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},e.prototype.onerror=function(e){this.handleCallback(e)},e.prototype.onclosetag=function(){this.lastNode=null;var e=this.tagStack.pop();this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)},e.prototype.onopentag=function(e,t){var n=this.options.xmlMode?r.ElementType.Tag:void 0,i=new o.Element(e,t,void 0,n);this.addNode(i),this.tagStack.push(i)},e.prototype.ontext=function(e){var t=this.lastNode;if(t&&t.type===r.ElementType.Text)t.data+=e,this.options.withEndIndices&&(t.endIndex=this.parser.endIndex);else{var n=new o.Text(e);this.addNode(n),this.lastNode=n}},e.prototype.oncomment=function(e){if(this.lastNode&&this.lastNode.type===r.ElementType.Comment)this.lastNode.data+=e;else{var t=new o.Comment(e);this.addNode(t),this.lastNode=t}},e.prototype.oncommentend=function(){this.lastNode=null},e.prototype.oncdatastart=function(){var e=new o.Text(""),t=new o.CDATA([e]);this.addNode(t),e.parent=t,this.lastNode=e},e.prototype.oncdataend=function(){this.lastNode=null},e.prototype.onprocessinginstruction=function(e,t){var n=new o.ProcessingInstruction(e,t);this.addNode(n)},e.prototype.handleCallback=function(e){if("function"==typeof this.callback)this.callback(e,this.dom);else if(e)throw e},e.prototype.addNode=function(e){var t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null},e}();e.DomHandler=a,e.default=a}(s)),s}var g,y,v,E,b={};function x(){if(y)return l;y=1,Object.defineProperty(l,"__esModule",{value:!0}),l.formatAttributes=n,l.escapeSpecialCharacters=function(e){return e.replace(t.CARRIAGE_RETURN_REGEX,t.CARRIAGE_RETURN_PLACEHOLDER)},l.revertEscapedCharacters=o,l.formatDOM=function t(i,a,l){void 0===a&&(a=null);for(var s,c=[],u=0,p=i.length;u<p;u++){var d=i[u];switch(d.nodeType){case 1:var f=r(d.nodeName);(s=new e.Element(f,n(d.attributes))).children=t("template"===f?d.content.childNodes:d.childNodes,s);break;case 3:s=new e.Text(o(d.nodeValue));break;case 8:s=new e.Comment(d.nodeValue);break;default:continue}var h=c[u-1]||null;h&&(h.next=s),s.parent=a,s.prev=h,s.next=null,c.push(s)}l&&((s=new e.ProcessingInstruction(l.substring(0,l.indexOf(" ")).toLowerCase(),l)).next=c[0]||null,s.parent=a,c.unshift(s),c[1]&&(c[1].prev=c[0]));return c};var e=m(),t=(g||(g=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CARRIAGE_RETURN_PLACEHOLDER_REGEX=e.CARRIAGE_RETURN_PLACEHOLDER=e.CARRIAGE_RETURN_REGEX=e.CARRIAGE_RETURN=e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES=void 0,e.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"],e.CASE_SENSITIVE_TAG_NAMES_MAP=e.CASE_SENSITIVE_TAG_NAMES.reduce((function(e,t){return e[t.toLowerCase()]=t,e}),{}),e.CARRIAGE_RETURN="\r",e.CARRIAGE_RETURN_REGEX=new RegExp(e.CARRIAGE_RETURN,"g"),e.CARRIAGE_RETURN_PLACEHOLDER="__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_".concat(Date.now(),"__"),e.CARRIAGE_RETURN_PLACEHOLDER_REGEX=new RegExp(e.CARRIAGE_RETURN_PLACEHOLDER,"g")}(b)),b);function n(e){for(var t={},n=0,r=e.length;n<r;n++){var o=e[n];t[o.name]=o.value}return t}function r(e){var n=function(e){return t.CASE_SENSITIVE_TAG_NAMES_MAP[e]}(e=e.toLowerCase());return n||e}function o(e){return e.replace(t.CARRIAGE_RETURN_PLACEHOLDER_REGEX,t.CARRIAGE_RETURN)}return l}function T(){if(E)return i;E=1;var e=i&&i.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(i,"__esModule",{value:!0}),i.default=function(e){if("string"!=typeof e)throw new TypeError("First argument must be a string");if(!e)return[];var o=e.match(r),i=o?o[1]:void 0;return(0,n.formatDOM)((0,t.default)(e),null,i)};var t=e(function(){if(v)return a;v=1,Object.defineProperty(a,"__esModule",{value:!0}),a.default=function(a){var u,p,d=(a=(0,e.escapeSpecialCharacters)(a)).match(o),h=d&&d[1]?d[1].toLowerCase():"";switch(h){case t:var m=c(a);return i.test(a)||null===(u=null==(y=m.querySelector(n))?void 0:y.parentNode)||void 0===u||u.removeChild(y),l.test(a)||null===(p=null==(y=m.querySelector(r))?void 0:y.parentNode)||void 0===p||p.removeChild(y),m.querySelectorAll(t);case n:case r:var g=s(a).querySelectorAll(h);return l.test(a)&&i.test(a)?g[0].parentNode.childNodes:g;default:return f?f(a):(y=s(a,r).querySelector(r)).childNodes;var y}};var e=x(),t="html",n="head",r="body",o=/<([a-zA-Z]+[0-9]?)/,i=/<head[^]*>/i,l=/<body[^]*>/i,s=function(e,t){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},c=function(e,t){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},u="object"==typeof window&&window.DOMParser;if("function"==typeof u){var p=new u;s=c=function(e,t){return t&&(e="<".concat(t,">").concat(e,"</").concat(t,">")),p.parseFromString(e,"text/html")}}if("object"==typeof document&&document.implementation){var d=document.implementation.createHTMLDocument();s=function(e,t){if(t){var n=d.documentElement.querySelector(t);return n&&(n.innerHTML=e),d}return d.documentElement.innerHTML=e,d}}var f,h="object"==typeof document&&document.createElement("template");return h&&h.content&&(f=function(e){return h.innerHTML=e,h.content.childNodes}),a}()),n=x(),r=/<(![a-zA-Z\s]+)>/;return i}var _,k,C={},A={},w={};function R(){if(_)return w;_=1;w.SAME=0;return w.CAMELCASE=1,w.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1},w}var S,O,P,N={},I={};function M(){if(P)return I;P=1;var e=I&&I.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(I,"__esModule",{value:!0}),I.default=function(e,n){var r=null;if(!e||"string"!=typeof e)return r;var o=(0,t.default)(e),i="function"==typeof n;return o.forEach((function(e){if("declaration"===e.type){var t=e.property,o=e.value;i?n(t,o,e):o&&((r=r||{})[t]=o)}})),r};var t=e(function(){if(O)return S;O=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,i=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,a=/^[;\s]*/,l=/^\s+|\s+$/g,s="";function c(e){return e?e.replace(l,s):s}return S=function(l,u){if("string"!=typeof l)throw new TypeError("First argument must be a string");if(!l)return[];u=u||{};var p=1,d=1;function f(e){var n=e.match(t);n&&(p+=n.length);var r=e.lastIndexOf("\n");d=~r?e.length-r:d+e.length}function h(){var e={line:p,column:d};return function(t){return t.position=new m(e),v(),t}}function m(e){this.start=e,this.end={line:p,column:d},this.source=u.source}function g(e){var t=new Error(u.source+":"+p+":"+d+": "+e);if(t.reason=e,t.filename=u.source,t.line=p,t.column=d,t.source=l,!u.silent)throw t}function y(e){var t=e.exec(l);if(t){var n=t[0];return f(n),l=l.slice(n.length),t}}function v(){y(n)}function E(e){var t;for(e=e||[];t=b();)!1!==t&&e.push(t);return e}function b(){var e=h();if("/"==l.charAt(0)&&"*"==l.charAt(1)){for(var t=2;s!=l.charAt(t)&&("*"!=l.charAt(t)||"/"!=l.charAt(t+1));)++t;if(t+=2,s===l.charAt(t-1))return g("End of comment missing");var n=l.slice(2,t-2);return d+=2,f(n),l=l.slice(t),d+=2,e({type:"comment",comment:n})}}function x(){var t=h(),n=y(r);if(n){if(b(),!y(o))return g("property missing ':'");var l=y(i),u=t({type:"declaration",property:c(n[0].replace(e,s)),value:l?c(l[0].replace(e,s)):s});return y(a),u}}return m.prototype.content=l,v(),function(){var e,t=[];for(E(t);e=x();)!1!==e&&(t.push(e),E(t));return t}()},S}());return I}var D,L,j,F,H,U={};function z(){if(D)return U;D=1,Object.defineProperty(U,"__esModule",{value:!0}),U.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,o=/^-(ms)-/,i=function(e,t){return t.toUpperCase()},a=function(e,t){return"".concat(t,"-")};return U.camelCase=function(l,s){return void 0===s&&(s={}),function(t){return!t||n.test(t)||e.test(t)}(l)?l:(l=l.toLowerCase(),(l=s.reactCompat?l.replace(o,a):l.replace(r,a)).replace(t,i))},U}function B(){return F||(F=1,function(t){var n=N&&N.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.returnFirstArg=t.canTextBeChildOfNode=t.ELEMENTS_WITH_NO_TEXT_CHILDREN=t.PRESERVE_CUSTOM_ATTRIBUTES=void 0,t.isCustomComponent=function(e,t){if(!e.includes("-"))return Boolean(t&&"string"==typeof t.is);if(i.has(e))return!1;return!0},t.setStyleProp=function(e,t){if("string"!=typeof e)return;if(!e.trim())return void(t.style={});try{t.style=(0,o.default)(e,a)}catch(e){t.style={}}};var r=e,o=n(function(){if(j)return L;j=1;var e=(L&&L.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(M()),t=z();function n(n,r){var o={};return n&&"string"==typeof n?((0,e.default)(n,(function(e,n){e&&n&&(o[(0,t.camelCase)(e,r)]=n)})),o):o}return n.default=n,L=n}()),i=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);var a={reactCompat:!0};t.PRESERVE_CUSTOM_ATTRIBUTES=Number(r.version.split(".")[0])>=16,t.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);t.canTextBeChildOfNode=function(e){return!t.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(e.name)};t.returnFirstArg=function(e){return e}}(N)),N}function G(){if(H)return C;H=1,Object.defineProperty(C,"__esModule",{value:!0}),C.default=function(a,l){void 0===a&&(a={});var s={},c=Boolean(a.type&&o[a.type]);for(var u in a){var p=a[u];if((0,e.isCustomAttribute)(u))s[u]=p;else{var d=u.toLowerCase(),f=i(d);if(f){var h=(0,e.getPropertyInfo)(f);switch(n.includes(f)&&r.includes(l)&&!c&&(f=i("default"+d)),s[f]=p,h&&h.type){case e.BOOLEAN:s[f]=!0;break;case e.OVERLOADED_BOOLEAN:""===p&&(s[f]=!0)}}else t.PRESERVE_CUSTOM_ATTRIBUTES&&(s[u]=p)}}return(0,t.setStyleProp)(a.style,s),s};var e=function(){if(k)return A;function e(e,t,n,r,o,i,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=a}k=1;const t={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach((n=>{t[n]=new e(n,0,!1,n,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((([n,r])=>{t[n]=new e(n,1,!1,r,null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((n=>{t[n]=new e(n,2,!1,n.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((n=>{t[n]=new e(n,2,!1,n,null,!1,!1)})),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach((n=>{t[n]=new e(n,3,!1,n.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((n=>{t[n]=new e(n,3,!0,n,null,!1,!1)})),["capture","download"].forEach((n=>{t[n]=new e(n,4,!1,n,null,!1,!1)})),["cols","rows","size","span"].forEach((n=>{t[n]=new e(n,6,!1,n,null,!1,!1)})),["rowSpan","start"].forEach((n=>{t[n]=new e(n,5,!1,n.toLowerCase(),null,!1,!1)}));const n=/[\-\:]([a-z])/g,r=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach((o=>{const i=o.replace(n,r);t[i]=new e(i,1,!1,o,null,!1,!1)})),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach((o=>{const i=o.replace(n,r);t[i]=new e(i,1,!1,o,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((o=>{const i=o.replace(n,r);t[i]=new e(i,1,!1,o,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((n=>{t[n]=new e(n,1,!1,n.toLowerCase(),null,!1,!1)})),t.xlinkHref=new e("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((n=>{t[n]=new e(n,1,!1,n.toLowerCase(),null,!0,!0)}));const{CAMELCASE:o,SAME:i,possibleStandardNames:a}=R(),l=RegExp.prototype.test.bind(new RegExp("^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$")),s=Object.keys(a).reduce(((e,t)=>{const n=a[t];return n===i?e[t]=t:n===o?e[t.toLowerCase()]=t:e[t]=n,e}),{});return A.BOOLEAN=3,A.BOOLEANISH_STRING=2,A.NUMERIC=5,A.OVERLOADED_BOOLEAN=4,A.POSITIVE_NUMERIC=6,A.RESERVED=0,A.STRING=1,A.getPropertyInfo=function(e){return t.hasOwnProperty(e)?t[e]:null},A.isCustomAttribute=l,A.possibleStandardNames=s,A}(),t=B(),n=["checked","value"],r=["input","select","textarea"],o={reset:!0,submit:!0};function i(t){return e.possibleStandardNames[t]}return C}var V,X,q={};var W=(X||(X=1,function(t){var n=o&&o.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.htmlToDOM=t.domToReact=t.attributesToProps=t.Text=t.ProcessingInstruction=t.Element=t.Comment=void 0,t.default=function(e,t){if("string"!=typeof e)throw new TypeError("First argument must be a string");return e?(0,a.default)((0,r.default)(e,(null==t?void 0:t.htmlparser2)||s),t):[]};var r=n(T());t.htmlToDOM=r.default;var i=n(G());t.attributesToProps=i.default;var a=n(function(){if(V)return q;V=1;var t=q&&q.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(q,"__esModule",{value:!0}),q.default=function e(t,n){void 0===n&&(n={});for(var l=[],s="function"==typeof n.replace,c=n.transform||o.returnFirstArg,u=n.library||i,p=u.cloneElement,d=u.createElement,f=u.isValidElement,h=t.length,m=0;m<h;m++){var g=t[m];if(s){var y=n.replace(g,m);if(f(y)){h>1&&(y=p(y,{key:y.key||m})),l.push(c(y,g,m));continue}}if("text"!==g.type){var v=g,E={};a(v)?((0,o.setStyleProp)(v.attribs.style,v.attribs),E=v.attribs):v.attribs&&(E=(0,r.default)(v.attribs,v.name));var b=void 0;switch(g.type){case"script":case"style":g.children[0]&&(E.dangerouslySetInnerHTML={__html:g.children[0].data});break;case"tag":"textarea"===g.name&&g.children[0]?E.defaultValue=g.children[0].data:g.children&&g.children.length&&(b=e(g.children,n));break;default:continue}h>1&&(E.key=m),l.push(c(d(g.name,E,b),g,m))}else{var x=!g.data.trim().length;if(x&&g.parent&&!(0,o.canTextBeChildOfNode)(g.parent))continue;if(n.trim&&x)continue;l.push(c(g.data,g,m))}}return 1===l.length?l[0]:l};var n=e,r=t(G()),o=B(),i={cloneElement:n.cloneElement,createElement:n.createElement,isValidElement:n.isValidElement};function a(e){return o.PRESERVE_CUSTOM_ATTRIBUTES&&"tag"===e.type&&(0,o.isCustomComponent)(e.name,e.attribs)}return q}());t.domToReact=a.default;var l=m();Object.defineProperty(t,"Comment",{enumerable:!0,get:function(){return l.Comment}}),Object.defineProperty(t,"Element",{enumerable:!0,get:function(){return l.Element}}),Object.defineProperty(t,"ProcessingInstruction",{enumerable:!0,get:function(){return l.ProcessingInstruction}}),Object.defineProperty(t,"Text",{enumerable:!0,get:function(){return l.Text}});var s={lowerCaseAttributeNames:!1}}(o)),o),Y=n(W),Z=t({__proto__:null,default:Y},[W]);const $=Y;return Object.assign($,Z),$})); | ||
//# sourceMappingURL=html-react-parser.min.js.map |
{ | ||
"name": "html-react-parser", | ||
"version": "5.2.0", | ||
"version": "5.2.1", | ||
"description": "HTML to React parser.", | ||
@@ -52,3 +52,3 @@ "author": "Mark <mark@remarkablemark.org> (https://remarkablemark.org)", | ||
"domhandler": "5.0.3", | ||
"html-dom-parser": "5.0.11", | ||
"html-dom-parser": "5.0.12", | ||
"react-property": "2.0.2", | ||
@@ -58,21 +58,21 @@ "style-to-js": "1.1.16" | ||
"devDependencies": { | ||
"@commitlint/cli": "19.6.0", | ||
"@commitlint/cli": "19.6.1", | ||
"@commitlint/config-conventional": "19.6.0", | ||
"@eslint/compat": "1.2.4", | ||
"@eslint/eslintrc": "3.2.0", | ||
"@eslint/js": "9.16.0", | ||
"@rollup/plugin-commonjs": "28.0.1", | ||
"@rollup/plugin-node-resolve": "15.3.0", | ||
"@eslint/js": "9.17.0", | ||
"@rollup/plugin-commonjs": "28.0.2", | ||
"@rollup/plugin-node-resolve": "16.0.0", | ||
"@rollup/plugin-terser": "0.4.4", | ||
"@rollup/plugin-typescript": "12.1.1", | ||
"@rollup/plugin-typescript": "12.1.2", | ||
"@size-limit/preset-big-lib": "11.1.6", | ||
"@types/benchmark": "2.1.5", | ||
"@types/jest": "29.5.14", | ||
"@types/node": "22.10.1", | ||
"@types/react": "19.0.0", | ||
"@types/react-dom": "19.0.0", | ||
"@typescript-eslint/eslint-plugin": "8.17.0", | ||
"@typescript-eslint/parser": "8.17.0", | ||
"@types/node": "22.10.2", | ||
"@types/react": "19.0.1", | ||
"@types/react-dom": "19.0.2", | ||
"@typescript-eslint/eslint-plugin": "8.18.0", | ||
"@typescript-eslint/parser": "8.18.0", | ||
"benchmark": "2.1.4", | ||
"eslint": "9.16.0", | ||
"eslint": "9.17.0", | ||
"eslint-plugin-prettier": "5.2.1", | ||
@@ -85,7 +85,7 @@ "eslint-plugin-simple-import-sort": "12.1.1", | ||
"jest-watch-typeahead": "2.2.2", | ||
"lint-staged": "15.2.10", | ||
"preact": "10.25.1", | ||
"lint-staged": "15.2.11", | ||
"preact": "10.25.2", | ||
"react": "18.3.1", | ||
"react-dom": "18.3.1", | ||
"rollup": "4.28.0", | ||
"rollup": "4.28.1", | ||
"size-limit": "11.1.6", | ||
@@ -92,0 +92,0 @@ "ts-jest": "29.2.5", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
468353
3801
147
3
3
1
23
+ Addedhtml-dom-parser@5.0.12(transitive)
- Removedhtml-dom-parser@5.0.11(transitive)
Updatedhtml-dom-parser@5.0.12