var commonjsGlobal=typeof globalThis!=="undefined"?globalThis:typeof window!=="undefined"?window:typeof global!=="undefined"?global:typeof self!=="undefined"?self:{};var svgo={};var config$1={};var plugins$1={};var plugins={};var xast={};var lib$8={};var lib$7={};var stringify$2={};var lib$6={};var lib$5={};(function(exports){Object.defineProperty(exports,"__esModule",{value:true});exports.Doctype=exports.CDATA=exports.Tag=exports.Style=exports.Script=exports.Comment=exports.Directive=exports.Text=exports.Root=exports.isTag=exports.ElementType=void 0;var ElementType;(function(ElementType){ElementType["Root"]="root";ElementType["Text"]="text";ElementType["Directive"]="directive";ElementType["Comment"]="comment";ElementType["Script"]="script";ElementType["Style"]="style";ElementType["Tag"]="tag";ElementType["CDATA"]="cdata";ElementType["Doctype"]="doctype"})(ElementType=exports.ElementType||(exports.ElementType={}));function isTag(elem){return elem.type===ElementType.Tag||elem.type===ElementType.Script||elem.type===ElementType.Style}exports.isTag=isTag;exports.Root=ElementType.Root;exports.Text=ElementType.Text;exports.Directive=ElementType.Directive;exports.Comment=ElementType.Comment;exports.Script=ElementType.Script;exports.Style=ElementType.Style;exports.Tag=ElementType.Tag;exports.CDATA=ElementType.CDATA;exports.Doctype=ElementType.Doctype})(lib$5);var node={};var __extends=commonjsGlobal&&commonjsGlobal.__extends||function(){var extendStatics=function(d,b){extendStatics=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,b){d.__proto__=b}||function(d,b){for(var p in b)if(Object.prototype.hasOwnProperty.call(b,p))d[p]=b[p]};return extendStatics(d,b)};return function(d,b){if(typeof b!=="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");extendStatics(d,b);function __(){this.constructor=d}d.prototype=b===null?Object.create(b):(__.prototype=b.prototype,new __)}}();var __assign$1=commonjsGlobal&&commonjsGlobal.__assign||function(){__assign$1=Object.assign||function(t){for(var s,i=1,n=arguments.length;i0?this.children[this.children.length-1]:null},enumerable:false,configurable:true});Object.defineProperty(NodeWithChildren.prototype,"childNodes",{get:function(){return this.children},set:function(children){this.children=children},enumerable:false,configurable:true});return NodeWithChildren}(Node);node.NodeWithChildren=NodeWithChildren;var Document=function(_super){__extends(Document,_super);function Document(children){return _super.call(this,domelementtype_1$1.ElementType.Root,children)||this}return Document}(NodeWithChildren);node.Document=Document;var Element$1=function(_super){__extends(Element,_super);function Element(name,attribs,children,type){if(children===void 0){children=[]}if(type===void 0){type=name==="script"?domelementtype_1$1.ElementType.Script:name==="style"?domelementtype_1$1.ElementType.Style:domelementtype_1$1.ElementType.Tag}var _this=_super.call(this,type,children)||this;_this.name=name;_this.attribs=attribs;return _this}Object.defineProperty(Element.prototype,"tagName",{get:function(){return this.name},set:function(name){this.name=name},enumerable:false,configurable:true});Object.defineProperty(Element.prototype,"attributes",{get:function(){var _this=this;return Object.keys(this.attribs).map((function(name){var _a,_b;return{name:name,value:_this.attribs[name],namespace:(_a=_this["x-attribsNamespace"])===null||_a===void 0?void 0:_a[name],prefix:(_b=_this["x-attribsPrefix"])===null||_b===void 0?void 0:_b[name]}}))},enumerable:false,configurable:true});return Element}(NodeWithChildren);node.Element=Element$1;function isTag$1(node){return(0,domelementtype_1$1.isTag)(node)}node.isTag=isTag$1;function isCDATA(node){return node.type===domelementtype_1$1.ElementType.CDATA}node.isCDATA=isCDATA;function isText(node){return node.type===domelementtype_1$1.ElementType.Text}node.isText=isText;function isComment(node){return node.type===domelementtype_1$1.ElementType.Comment}node.isComment=isComment;function isDirective(node){return node.type===domelementtype_1$1.ElementType.Directive}node.isDirective=isDirective;function isDocument(node){return node.type===domelementtype_1$1.ElementType.Root}node.isDocument=isDocument;function hasChildren(node){return Object.prototype.hasOwnProperty.call(node,"children")}node.hasChildren=hasChildren;function cloneNode(node,recursive){if(recursive===void 0){recursive=false}var result;if(isText(node)){result=new Text(node.data)}else if(isComment(node)){result=new Comment$1(node.data)}else if(isTag$1(node)){var children=recursive?cloneChildren(node.children):[];var clone_1=new Element$1(node.name,__assign$1({},node.attribs),children);children.forEach((function(child){return child.parent=clone_1}));if(node["x-attribsNamespace"]){clone_1["x-attribsNamespace"]=__assign$1({},node["x-attribsNamespace"])}if(node["x-attribsPrefix"]){clone_1["x-attribsPrefix"]=__assign$1({},node["x-attribsPrefix"])}result=clone_1}else if(isCDATA(node)){var children=recursive?cloneChildren(node.children):[];var clone_2=new NodeWithChildren(domelementtype_1$1.ElementType.CDATA,children);children.forEach((function(child){return child.parent=clone_2}));result=clone_2}else if(isDocument(node)){var children=recursive?cloneChildren(node.children):[];var clone_3=new Document(children);children.forEach((function(child){return child.parent=clone_3}));if(node["x-mode"]){clone_3["x-mode"]=node["x-mode"]}result=clone_3}else if(isDirective(node)){var instruction=new ProcessingInstruction(node.name,node.data);if(node["x-name"]!=null){instruction["x-name"]=node["x-name"];instruction["x-publicId"]=node["x-publicId"];instruction["x-systemId"]=node["x-systemId"]}result=instruction}else{throw new Error("Not implemented yet: "+node.type)}result.startIndex=node.startIndex;result.endIndex=node.endIndex;return result}node.cloneNode=cloneNode;function cloneChildren(childs){var children=childs.map((function(child){return cloneNode(child,true)}));for(var i=1;i65535){codePoint-=65536;output+=String.fromCharCode(codePoint>>>10&1023|55296);codePoint=56320|codePoint&1023}output+=String.fromCharCode(codePoint);return output};function decodeCodePoint(codePoint){if(codePoint>=55296&&codePoint<=57343||codePoint>1114111){return"�"}if(codePoint in decode_json_1.default){codePoint=decode_json_1.default[codePoint]}return fromCodePoint(codePoint)}decode_codepoint.default=decodeCodePoint;var __importDefault$3=commonjsGlobal&&commonjsGlobal.__importDefault||function(mod){return mod&&mod.__esModule?mod:{default:mod}};Object.defineProperty(decode,"__esModule",{value:true});decode.decodeHTML=decode.decodeHTMLStrict=decode.decodeXML=void 0;var entities_json_1$1=__importDefault$3(require$$1$1);var legacy_json_1=__importDefault$3(require$$1);var xml_json_1$1=__importDefault$3(require$$0$1);var decode_codepoint_1=__importDefault$3(decode_codepoint);var strictEntityRe=/&(?:[a-zA-Z0-9]+|#[xX][\da-fA-F]+|#\d+);/g;decode.decodeXML=getStrictDecoder(xml_json_1$1.default);decode.decodeHTMLStrict=getStrictDecoder(entities_json_1$1.default);function getStrictDecoder(map){var replace=getReplacer(map);return function(str){return String(str).replace(strictEntityRe,replace)}}var sorter=function(a,b){return a1?getCodePoint(c):c.charCodeAt(0)).toString(16).toUpperCase()+";"}function getInverse(inverse,re){return function(data){return data.replace(re,(function(name){return inverse[name]})).replace(reNonASCII,singleCharReplacer)}}var reEscapeChars=new RegExp(xmlReplacer.source+"|"+reNonASCII.source,"g");function escape(data){return data.replace(reEscapeChars,singleCharReplacer)}encode.escape=escape;function escapeUTF8(data){return data.replace(xmlReplacer,singleCharReplacer)}encode.escapeUTF8=escapeUTF8;function getASCIIEncoder(obj){return function(data){return data.replace(reEscapeChars,(function(c){return obj[c]||singleCharReplacer(c)}))}}(function(exports){Object.defineProperty(exports,"__esModule",{value:true});exports.decodeXMLStrict=exports.decodeHTML5Strict=exports.decodeHTML4Strict=exports.decodeHTML5=exports.decodeHTML4=exports.decodeHTMLStrict=exports.decodeHTML=exports.decodeXML=exports.encodeHTML5=exports.encodeHTML4=exports.escapeUTF8=exports.escape=exports.encodeNonAsciiHTML=exports.encodeHTML=exports.encodeXML=exports.encode=exports.decodeStrict=exports.decode=void 0;var decode_1=decode;var encode_1=encode;function decode$1(data,level){return(!level||level<=0?decode_1.decodeXML:decode_1.decodeHTML)(data)}exports.decode=decode$1;function decodeStrict(data,level){return(!level||level<=0?decode_1.decodeXML:decode_1.decodeHTMLStrict)(data)}exports.decodeStrict=decodeStrict;function encode$1(data,level){return(!level||level<=0?encode_1.encodeXML:encode_1.encodeHTML)(data)}exports.encode=encode$1;var encode_2=encode;Object.defineProperty(exports,"encodeXML",{enumerable:true,get:function(){return encode_2.encodeXML}});Object.defineProperty(exports,"encodeHTML",{enumerable:true,get:function(){return encode_2.encodeHTML}});Object.defineProperty(exports,"encodeNonAsciiHTML",{enumerable:true,get:function(){return encode_2.encodeNonAsciiHTML}});Object.defineProperty(exports,"escape",{enumerable:true,get:function(){return encode_2.escape}});Object.defineProperty(exports,"escapeUTF8",{enumerable:true,get:function(){return encode_2.escapeUTF8}});Object.defineProperty(exports,"encodeHTML4",{enumerable:true,get:function(){return encode_2.encodeHTML}});Object.defineProperty(exports,"encodeHTML5",{enumerable:true,get:function(){return encode_2.encodeHTML}});var decode_2=decode;Object.defineProperty(exports,"decodeXML",{enumerable:true,get:function(){return decode_2.decodeXML}});Object.defineProperty(exports,"decodeHTML",{enumerable:true,get:function(){return decode_2.decodeHTML}});Object.defineProperty(exports,"decodeHTMLStrict",{enumerable:true,get:function(){return decode_2.decodeHTMLStrict}});Object.defineProperty(exports,"decodeHTML4",{enumerable:true,get:function(){return decode_2.decodeHTML}});Object.defineProperty(exports,"decodeHTML5",{enumerable:true,get:function(){return decode_2.decodeHTML}});Object.defineProperty(exports,"decodeHTML4Strict",{enumerable:true,get:function(){return decode_2.decodeHTMLStrict}});Object.defineProperty(exports,"decodeHTML5Strict",{enumerable:true,get:function(){return decode_2.decodeHTMLStrict}});Object.defineProperty(exports,"decodeXMLStrict",{enumerable:true,get:function(){return decode_2.decodeXML}})})(lib$3);var foreignNames={};Object.defineProperty(foreignNames,"__esModule",{value:true});foreignNames.attributeNames=foreignNames.elementNames=void 0;foreignNames.elementNames=new Map([["altglyph","altGlyph"],["altglyphdef","altGlyphDef"],["altglyphitem","altGlyphItem"],["animatecolor","animateColor"],["animatemotion","animateMotion"],["animatetransform","animateTransform"],["clippath","clipPath"],["feblend","feBlend"],["fecolormatrix","feColorMatrix"],["fecomponenttransfer","feComponentTransfer"],["fecomposite","feComposite"],["feconvolvematrix","feConvolveMatrix"],["fediffuselighting","feDiffuseLighting"],["fedisplacementmap","feDisplacementMap"],["fedistantlight","feDistantLight"],["fedropshadow","feDropShadow"],["feflood","feFlood"],["fefunca","feFuncA"],["fefuncb","feFuncB"],["fefuncg","feFuncG"],["fefuncr","feFuncR"],["fegaussianblur","feGaussianBlur"],["feimage","feImage"],["femerge","feMerge"],["femergenode","feMergeNode"],["femorphology","feMorphology"],["feoffset","feOffset"],["fepointlight","fePointLight"],["fespecularlighting","feSpecularLighting"],["fespotlight","feSpotLight"],["fetile","feTile"],["feturbulence","feTurbulence"],["foreignobject","foreignObject"],["glyphref","glyphRef"],["lineargradient","linearGradient"],["radialgradient","radialGradient"],["textpath","textPath"]]);foreignNames.attributeNames=new Map([["definitionurl","definitionURL"],["attributename","attributeName"],["attributetype","attributeType"],["basefrequency","baseFrequency"],["baseprofile","baseProfile"],["calcmode","calcMode"],["clippathunits","clipPathUnits"],["diffuseconstant","diffuseConstant"],["edgemode","edgeMode"],["filterunits","filterUnits"],["glyphref","glyphRef"],["gradienttransform","gradientTransform"],["gradientunits","gradientUnits"],["kernelmatrix","kernelMatrix"],["kernelunitlength","kernelUnitLength"],["keypoints","keyPoints"],["keysplines","keySplines"],["keytimes","keyTimes"],["lengthadjust","lengthAdjust"],["limitingconeangle","limitingConeAngle"],["markerheight","markerHeight"],["markerunits","markerUnits"],["markerwidth","markerWidth"],["maskcontentunits","maskContentUnits"],["maskunits","maskUnits"],["numoctaves","numOctaves"],["pathlength","pathLength"],["patterncontentunits","patternContentUnits"],["patterntransform","patternTransform"],["patternunits","patternUnits"],["pointsatx","pointsAtX"],["pointsaty","pointsAtY"],["pointsatz","pointsAtZ"],["preservealpha","preserveAlpha"],["preserveaspectratio","preserveAspectRatio"],["primitiveunits","primitiveUnits"],["refx","refX"],["refy","refY"],["repeatcount","repeatCount"],["repeatdur","repeatDur"],["requiredextensions","requiredExtensions"],["requiredfeatures","requiredFeatures"],["specularconstant","specularConstant"],["specularexponent","specularExponent"],["spreadmethod","spreadMethod"],["startoffset","startOffset"],["stddeviation","stdDeviation"],["stitchtiles","stitchTiles"],["surfacescale","surfaceScale"],["systemlanguage","systemLanguage"],["tablevalues","tableValues"],["targetx","targetX"],["targety","targetY"],["textlength","textLength"],["viewbox","viewBox"],["viewtarget","viewTarget"],["xchannelselector","xChannelSelector"],["ychannelselector","yChannelSelector"],["zoomandpan","zoomAndPan"]]);var __assign=commonjsGlobal&&commonjsGlobal.__assign||function(){__assign=Object.assign||function(t){for(var s,i=1,n=arguments.length;i0){tag+=render(elem.children,opts)}if(opts.xmlMode||!singleTag.has(elem.name)){tag+=""}}return tag}function renderDirective(elem){return"<"+elem.data+">"}function renderText(elem,opts){var data=elem.data||"";if(opts.decodeEntities!==false&&!(!opts.xmlMode&&elem.parent&&unencodedElements.has(elem.parent.name))){data=entities_1.encodeXML(data)}return data}function renderCdata(elem){return""}function renderComment(elem){return"\x3c!--"+elem.data+"--\x3e"}var __importDefault$1=commonjsGlobal&&commonjsGlobal.__importDefault||function(mod){return mod&&mod.__esModule?mod:{default:mod}};Object.defineProperty(stringify$2,"__esModule",{value:true});stringify$2.innerText=stringify$2.textContent=stringify$2.getText=stringify$2.getInnerHTML=stringify$2.getOuterHTML=void 0;var domhandler_1$4=lib$6;var dom_serializer_1=__importDefault$1(lib$4);var domelementtype_1=lib$5;function getOuterHTML(node,options){return(0,dom_serializer_1.default)(node,options)}stringify$2.getOuterHTML=getOuterHTML;function getInnerHTML(node,options){return(0,domhandler_1$4.hasChildren)(node)?node.children.map((function(node){return getOuterHTML(node,options)})).join(""):""}stringify$2.getInnerHTML=getInnerHTML;function getText$1(node){if(Array.isArray(node))return node.map(getText$1).join("");if((0,domhandler_1$4.isTag)(node))return node.name==="br"?"\n":getText$1(node.children);if((0,domhandler_1$4.isCDATA)(node))return getText$1(node.children);if((0,domhandler_1$4.isText)(node))return node.data;return""}stringify$2.getText=getText$1;function textContent(node){if(Array.isArray(node))return node.map(textContent).join("");if((0,domhandler_1$4.hasChildren)(node)&&!(0,domhandler_1$4.isComment)(node)){return textContent(node.children)}if((0,domhandler_1$4.isText)(node))return node.data;return""}stringify$2.textContent=textContent;function innerText(node){if(Array.isArray(node))return node.map(innerText).join("");if((0,domhandler_1$4.hasChildren)(node)&&(node.type===domelementtype_1.ElementType.Tag||(0,domhandler_1$4.isCDATA)(node))){return innerText(node.children)}if((0,domhandler_1$4.isText)(node))return node.data;return""}stringify$2.innerText=innerText;var traversal={};Object.defineProperty(traversal,"__esModule",{value:true});traversal.prevElementSibling=traversal.nextElementSibling=traversal.getName=traversal.hasAttrib=traversal.getAttributeValue=traversal.getSiblings=traversal.getParent=traversal.getChildren=void 0;var domhandler_1$3=lib$6;var emptyArray=[];function getChildren$1(elem){var _a;return(_a=elem.children)!==null&&_a!==void 0?_a:emptyArray}traversal.getChildren=getChildren$1;function getParent$1(elem){return elem.parent||null}traversal.getParent=getParent$1;function getSiblings$1(elem){var _a,_b;var parent=getParent$1(elem);if(parent!=null)return getChildren$1(parent);var siblings=[elem];var prev=elem.prev,next=elem.next;while(prev!=null){siblings.unshift(prev);_a=prev,prev=_a.prev}while(next!=null){siblings.push(next);_b=next,next=_b.next}return siblings}traversal.getSiblings=getSiblings$1;function getAttributeValue$1(elem,name){var _a;return(_a=elem.attribs)===null||_a===void 0?void 0:_a[name]}traversal.getAttributeValue=getAttributeValue$1;function hasAttrib$1(elem,name){return elem.attribs!=null&&Object.prototype.hasOwnProperty.call(elem.attribs,name)&&elem.attribs[name]!=null}traversal.hasAttrib=hasAttrib$1;function getName$1(elem){return elem.name}traversal.getName=getName$1;function nextElementSibling(elem){var _a;var next=elem.next;while(next!==null&&!(0,domhandler_1$3.isTag)(next))_a=next,next=_a.next;return next}traversal.nextElementSibling=nextElementSibling;function prevElementSibling(elem){var _a;var prev=elem.prev;while(prev!==null&&!(0,domhandler_1$3.isTag)(prev))_a=prev,prev=_a.prev;return prev}traversal.prevElementSibling=prevElementSibling;var manipulation={};Object.defineProperty(manipulation,"__esModule",{value:true});manipulation.prepend=manipulation.prependChild=manipulation.append=manipulation.appendChild=manipulation.replaceElement=manipulation.removeElement=void 0;function removeElement(elem){if(elem.prev)elem.prev.next=elem.next;if(elem.next)elem.next.prev=elem.prev;if(elem.parent){var childs=elem.parent.children;childs.splice(childs.lastIndexOf(elem),1)}}manipulation.removeElement=removeElement;function replaceElement(elem,replacement){var prev=replacement.prev=elem.prev;if(prev){prev.next=replacement}var next=replacement.next=elem.next;if(next){next.prev=replacement}var parent=replacement.parent=elem.parent;if(parent){var childs=parent.children;childs[childs.lastIndexOf(elem)]=replacement}}manipulation.replaceElement=replaceElement;function appendChild(elem,child){removeElement(child);child.next=null;child.parent=elem;if(elem.children.push(child)>1){var sibling=elem.children[elem.children.length-2];sibling.next=child;child.prev=sibling}else{child.prev=null}}manipulation.appendChild=appendChild;function append(elem,next){removeElement(next);var parent=elem.parent;var currNext=elem.next;next.next=currNext;next.prev=elem;elem.next=next;next.parent=parent;if(currNext){currNext.prev=next;if(parent){var childs=parent.children;childs.splice(childs.lastIndexOf(currNext),0,next)}}else if(parent){parent.children.push(next)}}manipulation.append=append;function prependChild(elem,child){removeElement(child);child.parent=elem;child.prev=null;if(elem.children.unshift(child)!==1){var sibling=elem.children[1];sibling.prev=child;child.next=sibling}else{child.next=null}}manipulation.prependChild=prependChild;function prepend(elem,prev){removeElement(prev);var parent=elem.parent;if(parent){var childs=parent.children;childs.splice(childs.indexOf(elem),0,prev)}if(elem.prev){elem.prev.next=prev}prev.parent=parent;prev.prev=elem.prev;prev.next=elem;elem.prev=prev}manipulation.prepend=prepend;var querying={};Object.defineProperty(querying,"__esModule",{value:true});querying.findAll=querying.existsOne=querying.findOne=querying.findOneChild=querying.find=querying.filter=void 0;var domhandler_1$2=lib$6;function filter(test,node,recurse,limit){if(recurse===void 0){recurse=true}if(limit===void 0){limit=Infinity}if(!Array.isArray(node))node=[node];return find(test,node,recurse,limit)}querying.filter=filter;function find(test,nodes,recurse,limit){var result=[];for(var _i=0,nodes_1=nodes;_i0){var children=find(test,elem.children,recurse,limit);result.push.apply(result,children);limit-=children.length;if(limit<=0)break}}return result}querying.find=find;function findOneChild(test,nodes){return nodes.find(test)}querying.findOneChild=findOneChild;function findOne$1(test,nodes,recurse){if(recurse===void 0){recurse=true}var elem=null;for(var i=0;i0){elem=findOne$1(test,checked.children)}}return elem}querying.findOne=findOne$1;function existsOne$1(test,nodes){return nodes.some((function(checked){return(0,domhandler_1$2.isTag)(checked)&&(test(checked)||checked.children.length>0&&existsOne$1(test,checked.children))}))}querying.existsOne=existsOne$1;function findAll$1(test,nodes){var _a;var result=[];var stack=nodes.filter(domhandler_1$2.isTag);var elem;while(elem=stack.shift()){var children=(_a=elem.children)===null||_a===void 0?void 0:_a.filter(domhandler_1$2.isTag);if(children&&children.length>0){stack.unshift.apply(stack,children)}if(test(elem))result.push(elem)}return result}querying.findAll=findAll$1;var legacy={};Object.defineProperty(legacy,"__esModule",{value:true});legacy.getElementsByTagType=legacy.getElementsByTagName=legacy.getElementById=legacy.getElements=legacy.testElement=void 0;var domhandler_1$1=lib$6;var querying_1=querying;var Checks={tag_name:function(name){if(typeof name==="function"){return function(elem){return(0,domhandler_1$1.isTag)(elem)&&name(elem.name)}}else if(name==="*"){return domhandler_1$1.isTag}return function(elem){return(0,domhandler_1$1.isTag)(elem)&&elem.name===name}},tag_type:function(type){if(typeof type==="function"){return function(elem){return type(elem.type)}}return function(elem){return elem.type===type}},tag_contains:function(data){if(typeof data==="function"){return function(elem){return(0,domhandler_1$1.isText)(elem)&&data(elem.data)}}return function(elem){return(0,domhandler_1$1.isText)(elem)&&elem.data===data}}};function getAttribCheck(attrib,value){if(typeof value==="function"){return function(elem){return(0,domhandler_1$1.isTag)(elem)&&value(elem.attribs[attrib])}}return function(elem){return(0,domhandler_1$1.isTag)(elem)&&elem.attribs[attrib]===value}}function combineFuncs(a,b){return function(elem){return a(elem)||b(elem)}}function compileTest(options){var funcs=Object.keys(options).map((function(key){var value=options[key];return Object.prototype.hasOwnProperty.call(Checks,key)?Checks[key](value):getAttribCheck(key,value)}));return funcs.length===0?null:funcs.reduce(combineFuncs)}function testElement(options,node){var test=compileTest(options);return test?test(node):true}legacy.testElement=testElement;function getElements(options,nodes,recurse,limit){if(limit===void 0){limit=Infinity}var test=compileTest(options);return test?(0,querying_1.filter)(test,nodes,recurse,limit):[]}legacy.getElements=getElements;function getElementById(id,nodes,recurse){if(recurse===void 0){recurse=true}if(!Array.isArray(nodes))nodes=[nodes];return(0,querying_1.findOne)(getAttribCheck("id",id),nodes,recurse)}legacy.getElementById=getElementById;function getElementsByTagName(tagName,nodes,recurse,limit){if(recurse===void 0){recurse=true}if(limit===void 0){limit=Infinity}return(0,querying_1.filter)(Checks.tag_name(tagName),nodes,recurse,limit)}legacy.getElementsByTagName=getElementsByTagName;function getElementsByTagType(type,nodes,recurse,limit){if(recurse===void 0){recurse=true}if(limit===void 0){limit=Infinity}return(0,querying_1.filter)(Checks.tag_type(type),nodes,recurse,limit)}legacy.getElementsByTagType=getElementsByTagType;var helpers={};Object.defineProperty(helpers,"__esModule",{value:true});helpers.uniqueSort=helpers.compareDocumentPosition=helpers.removeSubsets=void 0;var domhandler_1=lib$6;function removeSubsets$1(nodes){var idx=nodes.length;while(--idx>=0){var node=nodes[idx];if(idx>0&&nodes.lastIndexOf(node,idx-1)>=0){nodes.splice(idx,1);continue}for(var ancestor=node.parent;ancestor;ancestor=ancestor.parent){if(nodes.includes(ancestor)){nodes.splice(idx,1);break}}}return nodes}helpers.removeSubsets=removeSubsets$1;function compareDocumentPosition(nodeA,nodeB){var aParents=[];var bParents=[];if(nodeA===nodeB){return 0}var current=(0,domhandler_1.hasChildren)(nodeA)?nodeA:nodeA.parent;while(current){aParents.unshift(current);current=current.parent}current=(0,domhandler_1.hasChildren)(nodeB)?nodeB:nodeB.parent;while(current){bParents.unshift(current);current=current.parent}var maxIdx=Math.min(aParents.length,bParents.length);var idx=0;while(idxsiblings.indexOf(bSibling)){if(sharedParent===nodeB){return 4|16}return 4}if(sharedParent===nodeA){return 2|8}return 2}helpers.compareDocumentPosition=compareDocumentPosition;function uniqueSort(nodes){nodes=nodes.filter((function(node,i,arr){return!arr.includes(node,i+1)}));nodes.sort((function(a,b){var relative=compareDocumentPosition(a,b);if(relative&2){return-1}else if(relative&4){return 1}return 0}));return nodes}helpers.uniqueSort=uniqueSort;var feeds={};Object.defineProperty(feeds,"__esModule",{value:true});feeds.getFeed=void 0;var stringify_1=stringify$2;var legacy_1=legacy;function getFeed(doc){var feedRoot=getOneElement(isValidFeed,doc);return!feedRoot?null:feedRoot.name==="feed"?getAtomFeed(feedRoot):getRssFeed(feedRoot)}feeds.getFeed=getFeed;function getAtomFeed(feedRoot){var _a;var childs=feedRoot.children;var feed={type:"atom",items:(0,legacy_1.getElementsByTagName)("entry",childs).map((function(item){var _a;var children=item.children;var entry={media:getMediaElements(children)};addConditionally(entry,"id","id",children);addConditionally(entry,"title","title",children);var href=(_a=getOneElement("link",children))===null||_a===void 0?void 0:_a.attribs.href;if(href){entry.link=href}var description=fetch("summary",children)||fetch("content",children);if(description){entry.description=description}var pubDate=fetch("updated",children);if(pubDate){entry.pubDate=new Date(pubDate)}return entry}))};addConditionally(feed,"id","id",childs);addConditionally(feed,"title","title",childs);var href=(_a=getOneElement("link",childs))===null||_a===void 0?void 0:_a.attribs.href;if(href){feed.link=href}addConditionally(feed,"description","subtitle",childs);var updated=fetch("updated",childs);if(updated){feed.updated=new Date(updated)}addConditionally(feed,"author","email",childs,true);return feed}function getRssFeed(feedRoot){var _a,_b;var childs=(_b=(_a=getOneElement("channel",feedRoot.children))===null||_a===void 0?void 0:_a.children)!==null&&_b!==void 0?_b:[];var feed={type:feedRoot.name.substr(0,3),id:"",items:(0,legacy_1.getElementsByTagName)("item",feedRoot.children).map((function(item){var children=item.children;var entry={media:getMediaElements(children)};addConditionally(entry,"id","guid",children);addConditionally(entry,"title","title",children);addConditionally(entry,"link","link",children);addConditionally(entry,"description","description",children);var pubDate=fetch("pubDate",children);if(pubDate)entry.pubDate=new Date(pubDate);return entry}))};addConditionally(feed,"title","title",childs);addConditionally(feed,"link","link",childs);addConditionally(feed,"description","description",childs);var updated=fetch("lastBuildDate",childs);if(updated){feed.updated=new Date(updated)}addConditionally(feed,"author","managingEditor",childs,true);return feed}var MEDIA_KEYS_STRING=["url","type","lang"];var MEDIA_KEYS_INT=["fileSize","bitrate","framerate","samplingrate","channels","duration","height","width"];function getMediaElements(where){return(0,legacy_1.getElementsByTagName)("media:content",where).map((function(elem){var attribs=elem.attribs;var media={medium:attribs.medium,isDefault:!!attribs.isDefault};for(var _i=0,MEDIA_KEYS_STRING_1=MEDIA_KEYS_STRING;_i":"child","<":"parent","~":"sibling","+":"adjacent"};var attribSelectors={"#":["id","equals"],".":["class","element"]};var unpackPseudos=new Set(["has","not","matches","is","host","host-context"]);var traversalNames=new Set(__spreadArray$1(["descendant"],Object.keys(Traversals).map((function(k){return Traversals[k]}))));var caseInsensitiveAttributes=new Set(["accept","accept-charset","align","alink","axis","bgcolor","charset","checked","clear","codetype","color","compact","declare","defer","dir","direction","disabled","enctype","face","frame","hreflang","http-equiv","lang","language","link","media","method","multiple","nohref","noresize","noshade","nowrap","readonly","rel","rev","rules","scope","scrolling","selected","shape","target","text","type","valign","valuetype","vlink"]);function isTraversal(selector){return traversalNames.has(selector.type)}parse$4.isTraversal=isTraversal;var stripQuotesFromPseudos=new Set(["contains","icontains"]);var quotes=new Set(['"',"'"]);function funescape(_,escaped,escapedWhitespace){var high=parseInt(escaped,16)-65536;return high!==high||escapedWhitespace?escaped:high<0?String.fromCharCode(high+65536):String.fromCharCode(high>>10|55296,high&1023|56320)}function unescapeCSS(str){return str.replace(reEscape,funescape)}function isWhitespace(c){return c===" "||c==="\n"||c==="\t"||c==="\f"||c==="\r"}function parse$3(selector,options){var subselects=[];var endIndex=parseSelector(subselects,""+selector,options,0);if(endIndex0&&isTraversal(tokens[tokens.length-1])){throw new Error("Did not expect successive traversals.")}}stripWhitespace(0);while(selector!==""){var firstChar=selector.charAt(selectorIndex);if(isWhitespace(firstChar)){sawWS=true;stripWhitespace(1)}else if(firstChar in Traversals){ensureNotTraversal();tokens.push({type:Traversals[firstChar]});sawWS=false;stripWhitespace(1)}else if(firstChar===","){if(tokens.length===0){throw new Error("Empty sub-selector")}subselects.push(tokens);tokens=[];sawWS=false;stripWhitespace(1)}else if(selector.startsWith("/*",selectorIndex)){var endIndex=selector.indexOf("*/",selectorIndex+2);if(endIndex<0){throw new Error("Comment was not terminated")}selectorIndex=endIndex+2}else{if(sawWS){ensureNotTraversal();tokens.push({type:"descendant"});sawWS=false}if(firstChar in attribSelectors){var _c=attribSelectors[firstChar],name_1=_c[0],action=_c[1];tokens.push({type:"attribute",name:name_1,action:action,value:getName(1),namespace:null,ignoreCase:options.xmlMode?null:false})}else if(firstChar==="["){stripWhitespace(1);var name_2=void 0;var namespace=null;if(selector.charAt(selectorIndex)==="|"){namespace="";selectorIndex+=1}if(selector.startsWith("*|",selectorIndex)){namespace="*";selectorIndex+=2}name_2=getName(0);if(namespace===null&&selector.charAt(selectorIndex)==="|"&&selector.charAt(selectorIndex+1)!=="="){namespace=name_2;name_2=getName(1)}if((_a=options.lowerCaseAttributeNames)!==null&&_a!==void 0?_a:!options.xmlMode){name_2=name_2.toLowerCase()}stripWhitespace(0);var action="exists";var possibleAction=actionTypes$1.get(selector.charAt(selectorIndex));if(possibleAction){action=possibleAction;if(selector.charAt(selectorIndex+1)!=="="){throw new Error("Expected `=`")}stripWhitespace(2)}else if(selector.charAt(selectorIndex)==="="){action="equals";stripWhitespace(1)}var value="";var ignoreCase=null;if(action!=="exists"){if(quotes.has(selector.charAt(selectorIndex))){var quote=selector.charAt(selectorIndex);var sectionEnd=selectorIndex+1;while(sectionEnd0&&selectorIndex0&&tokens.length===0){throw new Error("Empty sub-selector")}subselects.push(tokens)}var stringify$1={};var __spreadArray=commonjsGlobal&&commonjsGlobal.__spreadArray||function(to,from){for(var i=0,il=from.length,j=to.length;i ";case"parent":return" < ";case"sibling":return" ~ ";case"adjacent":return" + ";case"descendant":return" ";case"universal":return getNamespace(token.namespace)+"*";case"tag":return getNamespacedName(token);case"pseudo-element":return"::"+escapeName(token.name);case"pseudo":if(token.data===null)return":"+escapeName(token.name);if(typeof token.data==="string"){return":"+escapeName(token.name)+"("+escapeName(token.data)+")"}return":"+escapeName(token.name)+"("+stringify(token.data)+")";case"attribute":{if(token.name==="id"&&token.action==="equals"&&!token.ignoreCase&&!token.namespace){return"#"+escapeName(token.value)}if(token.name==="class"&&token.action==="element"&&!token.ignoreCase&&!token.namespace){return"."+escapeName(token.value)}var name_1=getNamespacedName(token);if(token.action==="exists"){return"["+name_1+"]"}return"["+name_1+actionTypes[token.action]+"='"+escapeName(token.value)+"'"+(token.ignoreCase?"i":token.ignoreCase===false?"s":"")+"]"}}}function getNamespacedName(token){return""+getNamespace(token.namespace)+escapeName(token.name)}function getNamespace(namespace){return namespace!==null?(namespace==="*"?"*":escapeName(namespace))+"|":""}function escapeName(str){return str.split("").map((function(c){return charsToEscape.has(c)?"\\"+c:c})).join("")}(function(exports){var __createBinding=commonjsGlobal&&commonjsGlobal.__createBinding||(Object.create?function(o,m,k,k2){if(k2===undefined)k2=k;Object.defineProperty(o,k2,{enumerable:true,get:function(){return m[k]}})}:function(o,m,k,k2){if(k2===undefined)k2=k;o[k2]=m[k]});var __exportStar=commonjsGlobal&&commonjsGlobal.__exportStar||function(m,exports){for(var p in m)if(p!=="default"&&!Object.prototype.hasOwnProperty.call(exports,p))__createBinding(exports,m,p)};var __importDefault=commonjsGlobal&&commonjsGlobal.__importDefault||function(mod){return mod&&mod.__esModule?mod:{default:mod}};Object.defineProperty(exports,"__esModule",{value:true});exports.stringify=exports.parse=void 0;__exportStar(parse$4,exports);var parse_1=parse$4;Object.defineProperty(exports,"parse",{enumerable:true,get:function(){return __importDefault(parse_1).default}});var stringify_1=stringify$1;Object.defineProperty(exports,"stringify",{enumerable:true,get:function(){return __importDefault(stringify_1).default}})})(lib$2);var sort={};var procedure={};(function(exports){Object.defineProperty(exports,"__esModule",{value:true});exports.isTraversal=exports.procedure=void 0;exports.procedure={universal:50,tag:30,attribute:1,pseudo:0,"pseudo-element":0,descendant:-1,child:-1,parent:-1,sibling:-1,adjacent:-1,_flexibleDescendant:-1};function isTraversal(t){return exports.procedure[t.type]<0}exports.isTraversal=isTraversal})(procedure);Object.defineProperty(sort,"__esModule",{value:true});var procedure_1$1=procedure;var attributes$1={exists:10,equals:8,not:7,start:6,end:6,any:5,hyphen:4,element:4};function sortByProcedure(arr){var procs=arr.map(getProcedure);for(var i=1;i=0&&procNew>=1}}else if(token.type==="pseudo"){if(!token.data){proc=3}else if(token.name==="has"||token.name==="contains"){proc=0}else if(Array.isArray(token.data)){proc=0;for(var i=0;iproc)proc=cur}if(token.data.length>1&&proc>0)proc-=1}else{proc=1}}return proc}var general={};var attributes={};Object.defineProperty(attributes,"__esModule",{value:true});attributes.attributeRules=void 0;var boolbase_1$2=boolbase;var reChars=/[-[\]{}()*+?.,\\^$|#\s]/g;function escapeRegex(value){return value.replace(reChars,"\\$&")}attributes.attributeRules={equals:function(next,data,_a){var adapter=_a.adapter;var name=data.name;var value=data.value;if(data.ignoreCase){value=value.toLowerCase();return function(elem){var attr=adapter.getAttributeValue(elem,name);return attr!=null&&attr.length===value.length&&attr.toLowerCase()===value&&next(elem)}}return function(elem){return adapter.getAttributeValue(elem,name)===value&&next(elem)}},hyphen:function(next,data,_a){var adapter=_a.adapter;var name=data.name;var value=data.value;var len=value.length;if(data.ignoreCase){value=value.toLowerCase();return function hyphenIC(elem){var attr=adapter.getAttributeValue(elem,name);return attr!=null&&(attr.length===len||attr.charAt(len)==="-")&&attr.substr(0,len).toLowerCase()===value&&next(elem)}}return function hyphen(elem){var attr=adapter.getAttributeValue(elem,name);return attr!=null&&(attr.length===len||attr.charAt(len)==="-")&&attr.substr(0,len)===value&&next(elem)}},element:function(next,_a,_b){var name=_a.name,value=_a.value,ignoreCase=_a.ignoreCase;var adapter=_b.adapter;if(/\s/.test(value)){return boolbase_1$2.falseFunc}var regex=new RegExp("(?:^|\\s)"+escapeRegex(value)+"(?:$|\\s)",ignoreCase?"i":"");return function element(elem){var attr=adapter.getAttributeValue(elem,name);return attr!=null&&attr.length>=value.length&®ex.test(attr)&&next(elem)}},exists:function(next,_a,_b){var name=_a.name;var adapter=_b.adapter;return function(elem){return adapter.hasAttrib(elem,name)&&next(elem)}},start:function(next,data,_a){var adapter=_a.adapter;var name=data.name;var value=data.value;var len=value.length;if(len===0){return boolbase_1$2.falseFunc}if(data.ignoreCase){value=value.toLowerCase();return function(elem){var attr=adapter.getAttributeValue(elem,name);return attr!=null&&attr.length>=len&&attr.substr(0,len).toLowerCase()===value&&next(elem)}}return function(elem){var _a;return!!((_a=adapter.getAttributeValue(elem,name))===null||_a===void 0?void 0:_a.startsWith(value))&&next(elem)}},end:function(next,data,_a){var adapter=_a.adapter;var name=data.name;var value=data.value;var len=-value.length;if(len===0){return boolbase_1$2.falseFunc}if(data.ignoreCase){value=value.toLowerCase();return function(elem){var _a;return((_a=adapter.getAttributeValue(elem,name))===null||_a===void 0?void 0:_a.substr(len).toLowerCase())===value&&next(elem)}}return function(elem){var _a;return!!((_a=adapter.getAttributeValue(elem,name))===null||_a===void 0?void 0:_a.endsWith(value))&&next(elem)}},any:function(next,data,_a){var adapter=_a.adapter;var name=data.name,value=data.value;if(value===""){return boolbase_1$2.falseFunc}if(data.ignoreCase){var regex_1=new RegExp(escapeRegex(value),"i");return function anyIC(elem){var attr=adapter.getAttributeValue(elem,name);return attr!=null&&attr.length>=value.length&®ex_1.test(attr)&&next(elem)}}return function(elem){var _a;return!!((_a=adapter.getAttributeValue(elem,name))===null||_a===void 0?void 0:_a.includes(value))&&next(elem)}},not:function(next,data,_a){var adapter=_a.adapter;var name=data.name;var value=data.value;if(value===""){return function(elem){return!!adapter.getAttributeValue(elem,name)&&next(elem)}}else if(data.ignoreCase){value=value.toLowerCase();return function(elem){var attr=adapter.getAttributeValue(elem,name);return(attr==null||attr.length!==value.length||attr.toLowerCase()!==value)&&next(elem)}}return function(elem){return adapter.getAttributeValue(elem,name)!==value&&next(elem)}}};var pseudoSelectors={};var filters$1={};var lib$1={};var parse$2={};Object.defineProperty(parse$2,"__esModule",{value:true});parse$2.parse=void 0;var RE_NTH_ELEMENT=/^([+-]?\d*n)?\s*(?:([+-]?)\s*(\d+))?$/;function parse$1(formula){formula=formula.trim().toLowerCase();if(formula==="even"){return[2,0]}else if(formula==="odd"){return[2,1]}var parsed=formula.match(RE_NTH_ELEMENT);if(!parsed){throw new Error("n-th rule couldn't be parsed ('"+formula+"')")}var a;if(parsed[1]){a=parseInt(parsed[1],10);if(isNaN(a)){a=parsed[1].startsWith("-")?-1:1}}else a=0;var b=(parsed[2]==="-"?-1:1)*(parsed[3]?parseInt(parsed[3],10):0);return[a,b]}parse$2.parse=parse$1;var compile$2={};Object.defineProperty(compile$2,"__esModule",{value:true});compile$2.compile=void 0;var boolbase_1$1=boolbase;function compile$1(parsed){var a=parsed[0];var b=parsed[1]-1;if(b<0&&a<=0)return boolbase_1$1.falseFunc;if(a===-1)return function(index){return index<=b};if(a===0)return function(index){return index===b};if(a===1)return b<0?boolbase_1$1.trueFunc:function(index){return index>=b};var absA=Math.abs(a);var bMod=(b%absA+absA)%absA;return a>1?function(index){return index>=b&&index%absA===bMod}:function(index){return index<=b&&index%absA===bMod}}compile$2.compile=compile$1;(function(exports){Object.defineProperty(exports,"__esModule",{value:true});exports.compile=exports.parse=void 0;var parse_1=parse$2;Object.defineProperty(exports,"parse",{enumerable:true,get:function(){return parse_1.parse}});var compile_1=compile$2;Object.defineProperty(exports,"compile",{enumerable:true,get:function(){return compile_1.compile}});function nthCheck(formula){return compile_1.compile(parse_1.parse(formula))}exports.default=nthCheck})(lib$1);(function(exports){var __importDefault=commonjsGlobal&&commonjsGlobal.__importDefault||function(mod){return mod&&mod.__esModule?mod:{default:mod}};Object.defineProperty(exports,"__esModule",{value:true});exports.filters=void 0;var nth_check_1=__importDefault(lib$1);var boolbase_1=boolbase;function getChildFunc(next,adapter){return function(elem){var parent=adapter.getParent(elem);return parent!=null&&adapter.isTag(parent)&&next(elem)}}exports.filters={contains:function(next,text,_a){var adapter=_a.adapter;return function contains(elem){return next(elem)&&adapter.getText(elem).includes(text)}},icontains:function(next,text,_a){var adapter=_a.adapter;var itext=text.toLowerCase();return function icontains(elem){return next(elem)&&adapter.getText(elem).toLowerCase().includes(itext)}},"nth-child":function(next,rule,_a){var adapter=_a.adapter,equals=_a.equals;var func=nth_check_1.default(rule);if(func===boolbase_1.falseFunc)return boolbase_1.falseFunc;if(func===boolbase_1.trueFunc)return getChildFunc(next,adapter);return function nthChild(elem){var siblings=adapter.getSiblings(elem);var pos=0;for(var i=0;i=0;i--){if(equals(elem,siblings[i]))break;if(adapter.isTag(siblings[i])){pos++}}return func(pos)&&next(elem)}},"nth-of-type":function(next,rule,_a){var adapter=_a.adapter,equals=_a.equals;var func=nth_check_1.default(rule);if(func===boolbase_1.falseFunc)return boolbase_1.falseFunc;if(func===boolbase_1.trueFunc)return getChildFunc(next,adapter);return function nthOfType(elem){var siblings=adapter.getSiblings(elem);var pos=0;for(var i=0;i=0;i--){var currentSibling=siblings[i];if(equals(elem,currentSibling))break;if(adapter.isTag(currentSibling)&&adapter.getName(currentSibling)===adapter.getName(elem)){pos++}}return func(pos)&&next(elem)}},root:function(next,_rule,_a){var adapter=_a.adapter;return function(elem){var parent=adapter.getParent(elem);return(parent==null||!adapter.isTag(parent))&&next(elem)}},scope:function(next,rule,options,context){var equals=options.equals;if(!context||context.length===0){return exports.filters.root(next,rule,options)}if(context.length===1){return function(elem){return equals(context[0],elem)&&next(elem)}}return function(elem){return context.includes(elem)&&next(elem)}},hover:dynamicStatePseudo("isHovered"),visited:dynamicStatePseudo("isVisited"),active:dynamicStatePseudo("isActive")};function dynamicStatePseudo(name){return function dynamicPseudo(next,_rule,_a){var adapter=_a.adapter;var func=adapter[name];if(typeof func!=="function"){return boolbase_1.falseFunc}return function active(elem){return func(elem)&&next(elem)}}}})(filters$1);var pseudos={};Object.defineProperty(pseudos,"__esModule",{value:true});pseudos.verifyPseudoArgs=pseudos.pseudos=void 0;pseudos.pseudos={empty:function(elem,_a){var adapter=_a.adapter;return!adapter.getChildren(elem).some((function(elem){return adapter.isTag(elem)||adapter.getText(elem)!==""}))},"first-child":function(elem,_a){var adapter=_a.adapter,equals=_a.equals;var firstChild=adapter.getSiblings(elem).find((function(elem){return adapter.isTag(elem)}));return firstChild!=null&&equals(elem,firstChild)},"last-child":function(elem,_a){var adapter=_a.adapter,equals=_a.equals;var siblings=adapter.getSiblings(elem);for(var i=siblings.length-1;i>=0;i--){if(equals(elem,siblings[i]))return true;if(adapter.isTag(siblings[i]))break}return false},"first-of-type":function(elem,_a){var adapter=_a.adapter,equals=_a.equals;var siblings=adapter.getSiblings(elem);var elemName=adapter.getName(elem);for(var i=0;i=0;i--){var currentSibling=siblings[i];if(equals(elem,currentSibling))return true;if(adapter.isTag(currentSibling)&&adapter.getName(currentSibling)===elemName){break}}return false},"only-of-type":function(elem,_a){var adapter=_a.adapter,equals=_a.equals;var elemName=adapter.getName(elem);return adapter.getSiblings(elem).every((function(sibling){return equals(elem,sibling)||!adapter.isTag(sibling)||adapter.getName(sibling)!==elemName}))},"only-child":function(elem,_a){var adapter=_a.adapter,equals=_a.equals;return adapter.getSiblings(elem).every((function(sibling){return equals(elem,sibling)||!adapter.isTag(sibling)}))}};function verifyPseudoArgs(func,name,subselect){if(subselect===null){if(func.length>2){throw new Error("pseudo-selector :"+name+" requires an argument")}}else if(func.length===2){throw new Error("pseudo-selector :"+name+" doesn't have any arguments")}}pseudos.verifyPseudoArgs=verifyPseudoArgs;var aliases={};Object.defineProperty(aliases,"__esModule",{value:true});aliases.aliases=void 0;aliases.aliases={"any-link":":is(a, area, link)[href]",link:":any-link:not(:visited)",disabled:":is(\n :is(button, input, select, textarea, optgroup, option)[disabled],\n optgroup[disabled] > option,\n fieldset[disabled]:not(fieldset[disabled] legend:first-of-type *)\n )",enabled:":not(:disabled)",checked:":is(:is(input[type=radio], input[type=checkbox])[checked], option:selected)",required:":is(input, select, textarea)[required]",optional:":is(input, select, textarea):not([required])",selected:"option:is([selected], select:not([multiple]):not(:has(> option[selected])) > :first-of-type)",checkbox:"[type=checkbox]",file:"[type=file]",password:"[type=password]",radio:"[type=radio]",reset:"[type=reset]",image:"[type=image]",submit:"[type=submit]",parent:":not(:empty)",header:":is(h1, h2, h3, h4, h5, h6)",button:":is(button, input[type=button])",input:":is(input, textarea, select, button)",text:"input:is(:not([type!='']), [type=text])"};var subselects={};(function(exports){var __spreadArray=commonjsGlobal&&commonjsGlobal.__spreadArray||function(to,from){for(var i=0,il=from.length,j=to.length;i0&&procedure_1.isTraversal(t[0])&&t[0].type!=="descendant");else if(hasContext&&!t.some(includesScopePseudo)){t.unshift(DESCENDANT_TOKEN)}else{continue}t.unshift(SCOPE_TOKEN)}}function compileToken(token,options,context){var _a;token=token.filter((function(t){return t.length>0}));token.forEach(sort_1.default);context=(_a=options.context)!==null&&_a!==void 0?_a:context;var isArrayContext=Array.isArray(context);var finalContext=context&&(Array.isArray(context)?context:[context]);absolutize(token,options,finalContext);var shouldTestNextSiblings=false;var query=token.map((function(rules){if(rules.length>=2){var first=rules[0],second=rules[1];if(first.type!=="pseudo"||first.name!=="scope");else if(isArrayContext&&second.type==="descendant"){rules[1]=FLEXIBLE_DESCENDANT_TOKEN}else if(second.type==="adjacent"||second.type==="sibling"){shouldTestNextSiblings=true}}return compileRules(rules,options,finalContext)})).reduce(reduceRules,boolbase_1.falseFunc);query.shouldTestNextSiblings=shouldTestNextSiblings;return query}compile$3.compileToken=compileToken;function compileRules(rules,options,context){var _a;return rules.reduce((function(previous,rule){return previous===boolbase_1.falseFunc?boolbase_1.falseFunc:general_1.compileGeneralSelector(previous,rule,options,context,compileToken)}),(_a=options.rootFunc)!==null&&_a!==void 0?_a:boolbase_1.trueFunc)}function reduceRules(a,b){if(b===boolbase_1.falseFunc||a===boolbase_1.trueFunc){return a}if(a===boolbase_1.falseFunc||b===boolbase_1.trueFunc){return b}return function combine(elem){return a(elem)||b(elem)}}(function(exports){var __createBinding=commonjsGlobal&&commonjsGlobal.__createBinding||(Object.create?function(o,m,k,k2){if(k2===undefined)k2=k;Object.defineProperty(o,k2,{enumerable:true,get:function(){return m[k]}})}:function(o,m,k,k2){if(k2===undefined)k2=k;o[k2]=m[k]});var __setModuleDefault=commonjsGlobal&&commonjsGlobal.__setModuleDefault||(Object.create?function(o,v){Object.defineProperty(o,"default",{enumerable:true,value:v})}:function(o,v){o["default"]=v});var __importStar=commonjsGlobal&&commonjsGlobal.__importStar||function(mod){if(mod&&mod.__esModule)return mod;var result={};if(mod!=null)for(var k in mod)if(k!=="default"&&Object.prototype.hasOwnProperty.call(mod,k))__createBinding(result,mod,k);__setModuleDefault(result,mod);return result};Object.defineProperty(exports,"__esModule",{value:true});exports.aliases=exports.pseudos=exports.filters=exports.is=exports.selectOne=exports.selectAll=exports.prepareContext=exports._compileToken=exports._compileUnsafe=exports.compile=void 0;var DomUtils=__importStar(lib$7);var boolbase_1=boolbase;var compile_1=compile$3;var subselects_1=subselects;var defaultEquals=function(a,b){return a===b};var defaultOptions={adapter:DomUtils,equals:defaultEquals};function convertOptionFormats(options){var _a,_b,_c,_d;var opts=options!==null&&options!==void 0?options:defaultOptions;(_a=opts.adapter)!==null&&_a!==void 0?_a:opts.adapter=DomUtils;(_b=opts.equals)!==null&&_b!==void 0?_b:opts.equals=(_d=(_c=opts.adapter)===null||_c===void 0?void 0:_c.equals)!==null&&_d!==void 0?_d:defaultEquals;return opts}function wrapCompile(func){return function addAdapter(selector,options,context){var opts=convertOptionFormats(options);return func(selector,opts,context)}}exports.compile=wrapCompile(compile_1.compile);exports._compileUnsafe=wrapCompile(compile_1.compileUnsafe);exports._compileToken=wrapCompile(compile_1.compileToken);function getSelectorFunc(searchFunc){return function select(query,elements,options){var opts=convertOptionFormats(options);if(typeof query!=="function"){query=compile_1.compileUnsafe(query,opts,elements)}var filteredElements=prepareContext(elements,opts.adapter,query.shouldTestNextSiblings);return searchFunc(query,filteredElements,opts)}}function prepareContext(elems,adapter,shouldTestNextSiblings){if(shouldTestNextSiblings===void 0){shouldTestNextSiblings=false}if(shouldTestNextSiblings){elems=appendNextSiblings(elems,adapter)}return Array.isArray(elems)?adapter.removeSubsets(elems):adapter.getChildren(elems)}exports.prepareContext=prepareContext;function appendNextSiblings(elem,adapter){var elems=Array.isArray(elem)?elem.slice(0):[elem];for(var i=0;inode.type==="element";const existsOne=(test,elems)=>elems.some((elem=>{if(isTag(elem)){return test(elem)||existsOne(test,getChildren(elem))}else{return false}}));const getAttributeValue=(elem,name)=>elem.attributes[name];const getChildren=node=>node.children||[];const getName=elemAst=>elemAst.name;const getParent=node=>node.parentNode||null;const getSiblings=elem=>{var parent=getParent(elem);return parent?getChildren(parent):[]};const getText=node=>{if(node.children[0].type==="text"&&node.children[0].type==="cdata"){return node.children[0].value}return""};const hasAttrib=(elem,name)=>elem.attributes[name]!==undefined;const removeSubsets=nodes=>{let idx=nodes.length;let node;let ancestor;let replace;while(--idx>-1){node=ancestor=nodes[idx];nodes[idx]=null;replace=true;while(ancestor){if(nodes.includes(ancestor)){replace=false;nodes.splice(idx,1);break}ancestor=getParent(ancestor)}if(replace){nodes[idx]=node}}return nodes};const findAll=(test,elems)=>{const result=[];for(const elem of elems){if(isTag(elem)){if(test(elem)){result.push(elem)}result.push(...findAll(test,getChildren(elem)))}}return result};const findOne=(test,elems)=>{for(const elem of elems){if(isTag(elem)){if(test(elem)){return elem}const result=findOne(test,getChildren(elem));if(result){return result}}}return null};const svgoCssSelectAdapter$1={isTag:isTag,existsOne:existsOne,getAttributeValue:getAttributeValue,getChildren:getChildren,getName:getName,getParent:getParent,getSiblings:getSiblings,getText:getText,hasAttrib:hasAttrib,removeSubsets:removeSubsets,findAll:findAll,findOne:findOne};var cssSelectAdapter=svgoCssSelectAdapter$1;const{selectAll:selectAll$1,selectOne:selectOne$1,is:is$1}=lib$8;const xastAdaptor=cssSelectAdapter;const cssSelectOptions={xmlMode:true,adapter:xastAdaptor};const querySelectorAll$2=(node,selector)=>selectAll$1(selector,node,cssSelectOptions);xast.querySelectorAll=querySelectorAll$2;const querySelector$1=(node,selector)=>selectOne$1(selector,node,cssSelectOptions);xast.querySelector=querySelector$1;const matches$1=(node,selector)=>is$1(node,selector,cssSelectOptions);xast.matches=matches$1;const closestByName$2=(node,name)=>{let currentNode=node;while(currentNode){if(currentNode.type==="element"&¤tNode.name===name){return currentNode}currentNode=currentNode.parentNode}return null};xast.closestByName=closestByName$2;const visitSkip$5=Symbol();xast.visitSkip=visitSkip$5;const visit$5=(node,visitor,parentNode)=>{const callbacks=visitor[node.type];if(callbacks&&callbacks.enter){const symbol=callbacks.enter(node,parentNode);if(symbol===visitSkip$5){return}}if(node.type==="root"){for(const child of node.children){visit$5(child,visitor,node)}}if(node.type==="element"){if(parentNode.children.includes(node)){for(const child of node.children){visit$5(child,visitor,node)}}}if(callbacks&&callbacks.exit){callbacks.exit(node,parentNode)}};xast.visit=visit$5;const detachNodeFromParent$l=(node,parentNode)=>{parentNode.children=parentNode.children.filter((child=>child!==node))};xast.detachNodeFromParent=detachNodeFromParent$l;const{visit:visit$4}=xast;const invokePlugins$1=(ast,info,plugins,overrides,globalOverrides)=>{for(const plugin of plugins){const override=overrides==null?null:overrides[plugin.name];if(override===false){continue}const params={...plugin.params,...globalOverrides,...override};if(plugin.type==="perItem"){ast=perItem(ast,info,plugin,params)}if(plugin.type==="perItemReverse"){ast=perItem(ast,info,plugin,params,true)}if(plugin.type==="full"){if(plugin.active){ast=plugin.fn(ast,params,info)}}if(plugin.type==="visitor"){if(plugin.active){const visitor=plugin.fn(ast,params,info);if(visitor!=null){visit$4(ast,visitor)}}}}return ast};plugins.invokePlugins=invokePlugins$1;function perItem(data,info,plugin,params,reverse){function monkeys(items){items.children=items.children.filter((function(item){if(reverse&&item.children){monkeys(item)}let kept=true;if(plugin.active){kept=plugin.fn(item,params,info)!==false}if(!reverse&&item.children){monkeys(item)}return kept}));return items}return monkeys(data)}const createPreset$1=({name:name,plugins:plugins})=>({name:name,type:"full",fn:(ast,params,info)=>{const{floatPrecision:floatPrecision,overrides:overrides}=params;const globalOverrides={};if(floatPrecision!=null){globalOverrides.floatPrecision=floatPrecision}return invokePlugins$1(ast,info,plugins,overrides,globalOverrides)}});plugins.createPreset=createPreset$1;var removeDoctype$1={};const{detachNodeFromParent:detachNodeFromParent$k}=xast;removeDoctype$1.name="removeDoctype";removeDoctype$1.type="visitor";removeDoctype$1.active=true;removeDoctype$1.description="removes doctype declaration";removeDoctype$1.fn=()=>({doctype:{enter:(node,parentNode)=>{detachNodeFromParent$k(node,parentNode)}}});var removeXMLProcInst$1={};const{detachNodeFromParent:detachNodeFromParent$j}=xast;removeXMLProcInst$1.name="removeXMLProcInst";removeXMLProcInst$1.type="visitor";removeXMLProcInst$1.active=true;removeXMLProcInst$1.description="removes XML processing instructions";removeXMLProcInst$1.fn=()=>({instruction:{enter:(node,parentNode)=>{if(node.name==="xml"){detachNodeFromParent$j(node,parentNode)}}}});var removeComments$1={};const{detachNodeFromParent:detachNodeFromParent$i}=xast;removeComments$1.name="removeComments";removeComments$1.type="visitor";removeComments$1.active=true;removeComments$1.description="removes comments";removeComments$1.fn=()=>({comment:{enter:(node,parentNode)=>{if(node.value.charAt(0)!=="!"){detachNodeFromParent$i(node,parentNode)}}}});var removeMetadata$1={};const{detachNodeFromParent:detachNodeFromParent$h}=xast;removeMetadata$1.name="removeMetadata";removeMetadata$1.type="visitor";removeMetadata$1.active=true;removeMetadata$1.description="removes ";removeMetadata$1.fn=()=>({element:{enter:(node,parentNode)=>{if(node.name==="metadata"){detachNodeFromParent$h(node,parentNode)}}}});var removeEditorsNSData$1={};var _collections={};(function(exports){exports.elemsGroups={animation:["animate","animateColor","animateMotion","animateTransform","set"],descriptive:["desc","metadata","title"],shape:["circle","ellipse","line","path","polygon","polyline","rect"],structural:["defs","g","svg","symbol","use"],paintServer:["solidColor","linearGradient","radialGradient","meshGradient","pattern","hatch"],nonRendering:["linearGradient","radialGradient","pattern","clipPath","mask","marker","symbol","filter","solidColor"],container:["a","defs","g","marker","mask","missing-glyph","pattern","svg","switch","symbol","foreignObject"],textContent:["altGlyph","altGlyphDef","altGlyphItem","glyph","glyphRef","textPath","text","tref","tspan"],textContentChild:["altGlyph","textPath","tref","tspan"],lightSource:["feDiffuseLighting","feSpecularLighting","feDistantLight","fePointLight","feSpotLight"],filterPrimitive:["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","feSpecularLighting","feTile","feTurbulence"]};exports.textElems=exports.elemsGroups.textContent.concat("title");exports.pathElems=["path","glyph","missing-glyph"];exports.attrsGroups={animationAddition:["additive","accumulate"],animationAttributeTarget:["attributeType","attributeName"],animationEvent:["onbegin","onend","onrepeat","onload"],animationTiming:["begin","dur","end","min","max","restart","repeatCount","repeatDur","fill"],animationValue:["calcMode","values","keyTimes","keySplines","from","to","by"],conditionalProcessing:["requiredFeatures","requiredExtensions","systemLanguage"],core:["id","tabindex","xml:base","xml:lang","xml:space"],graphicalEvent:["onfocusin","onfocusout","onactivate","onclick","onmousedown","onmouseup","onmouseover","onmousemove","onmouseout","onload"],presentation:["alignment-baseline","baseline-shift","clip","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cursor","direction","display","dominant-baseline","enable-background","fill","fill-opacity","fill-rule","filter","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-orientation-horizontal","glyph-orientation-vertical","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","mask","opacity","overflow","paint-order","pointer-events","shape-rendering","stop-color","stop-opacity","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-overflow","text-rendering","transform","transform-origin","unicode-bidi","vector-effect","visibility","word-spacing","writing-mode"],xlink:["xlink:href","xlink:show","xlink:actuate","xlink:type","xlink:role","xlink:arcrole","xlink:title"],documentEvent:["onunload","onabort","onerror","onresize","onscroll","onzoom"],filterPrimitive:["x","y","width","height","result"],transferFunction:["type","tableValues","slope","intercept","amplitude","exponent","offset"]};exports.attrsGroupsDefaults={core:{"xml:space":"default"},presentation:{clip:"auto","clip-path":"none","clip-rule":"nonzero",mask:"none",opacity:"1","stop-color":"#000","stop-opacity":"1","fill-opacity":"1","fill-rule":"nonzero",fill:"#000",stroke:"none","stroke-width":"1","stroke-linecap":"butt","stroke-linejoin":"miter","stroke-miterlimit":"4","stroke-dasharray":"none","stroke-dashoffset":"0","stroke-opacity":"1","paint-order":"normal","vector-effect":"none",display:"inline",visibility:"visible","marker-start":"none","marker-mid":"none","marker-end":"none","color-interpolation":"sRGB","color-interpolation-filters":"linearRGB","color-rendering":"auto","shape-rendering":"auto","text-rendering":"auto","image-rendering":"auto","font-style":"normal","font-variant":"normal","font-weight":"normal","font-stretch":"normal","font-size":"medium","font-size-adjust":"none",kerning:"auto","letter-spacing":"normal","word-spacing":"normal","text-decoration":"none","text-anchor":"start","text-overflow":"clip","writing-mode":"lr-tb","glyph-orientation-vertical":"auto","glyph-orientation-horizontal":"0deg",direction:"ltr","unicode-bidi":"normal","dominant-baseline":"auto","alignment-baseline":"baseline","baseline-shift":"baseline"},transferFunction:{slope:"1",intercept:"0",amplitude:"1",exponent:"1",offset:"0"}};exports.elems={a:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation","xlink"],attrs:["class","style","externalResourcesRequired","transform","target"],defaults:{target:"_self"},contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view","tspan"]},altGlyph:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation","xlink"],attrs:["class","style","externalResourcesRequired","x","y","dx","dy","glyphRef","format","rotate"]},altGlyphDef:{attrsGroups:["core"],content:["glyphRef"]},altGlyphItem:{attrsGroups:["core"],content:["glyphRef","altGlyphItem"]},animate:{attrsGroups:["conditionalProcessing","core","animationAddition","animationAttributeTarget","animationEvent","animationTiming","animationValue","presentation","xlink"],attrs:["externalResourcesRequired"],contentGroups:["descriptive"]},animateColor:{attrsGroups:["conditionalProcessing","core","animationEvent","xlink","animationAttributeTarget","animationTiming","animationValue","animationAddition","presentation"],attrs:["externalResourcesRequired"],contentGroups:["descriptive"]},animateMotion:{attrsGroups:["conditionalProcessing","core","animationEvent","xlink","animationTiming","animationValue","animationAddition"],attrs:["externalResourcesRequired","path","keyPoints","rotate","origin"],defaults:{rotate:"0"},contentGroups:["descriptive"],content:["mpath"]},animateTransform:{attrsGroups:["conditionalProcessing","core","animationEvent","xlink","animationAttributeTarget","animationTiming","animationValue","animationAddition"],attrs:["externalResourcesRequired","type"],contentGroups:["descriptive"]},circle:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","cx","cy","r"],defaults:{cx:"0",cy:"0"},contentGroups:["animation","descriptive"]},clipPath:{attrsGroups:["conditionalProcessing","core","presentation"],attrs:["class","style","externalResourcesRequired","transform","clipPathUnits"],defaults:{clipPathUnits:"userSpaceOnUse"},contentGroups:["animation","descriptive","shape"],content:["text","use"]},"color-profile":{attrsGroups:["core","xlink"],attrs:["local","name","rendering-intent"],defaults:{name:"sRGB","rendering-intent":"auto"},contentGroups:["descriptive"]},cursor:{attrsGroups:["core","conditionalProcessing","xlink"],attrs:["externalResourcesRequired","x","y"],defaults:{x:"0",y:"0"},contentGroups:["descriptive"]},defs:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform"],contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},desc:{attrsGroups:["core"],attrs:["class","style"]},ellipse:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","cx","cy","rx","ry"],defaults:{cx:"0",cy:"0"},contentGroups:["animation","descriptive"]},feBlend:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","in2","mode"],defaults:{mode:"normal"},content:["animate","set"]},feColorMatrix:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","type","values"],defaults:{type:"matrix"},content:["animate","set"]},feComponentTransfer:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in"],content:["feFuncA","feFuncB","feFuncG","feFuncR"]},feComposite:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","in2","operator","k1","k2","k3","k4"],defaults:{operator:"over",k1:"0",k2:"0",k3:"0",k4:"0"},content:["animate","set"]},feConvolveMatrix:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","order","kernelMatrix","divisor","bias","targetX","targetY","edgeMode","kernelUnitLength","preserveAlpha"],defaults:{order:"3",bias:"0",edgeMode:"duplicate",preserveAlpha:"false"},content:["animate","set"]},feDiffuseLighting:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","surfaceScale","diffuseConstant","kernelUnitLength"],defaults:{surfaceScale:"1",diffuseConstant:"1"},contentGroups:["descriptive"],content:["feDistantLight","fePointLight","feSpotLight"]},feDisplacementMap:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","in2","scale","xChannelSelector","yChannelSelector"],defaults:{scale:"0",xChannelSelector:"A",yChannelSelector:"A"},content:["animate","set"]},feDistantLight:{attrsGroups:["core"],attrs:["azimuth","elevation"],defaults:{azimuth:"0",elevation:"0"},content:["animate","set"]},feFlood:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style"],content:["animate","animateColor","set"]},feFuncA:{attrsGroups:["core","transferFunction"],content:["set","animate"]},feFuncB:{attrsGroups:["core","transferFunction"],content:["set","animate"]},feFuncG:{attrsGroups:["core","transferFunction"],content:["set","animate"]},feFuncR:{attrsGroups:["core","transferFunction"],content:["set","animate"]},feGaussianBlur:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","stdDeviation"],defaults:{stdDeviation:"0"},content:["set","animate"]},feImage:{attrsGroups:["core","presentation","filterPrimitive","xlink"],attrs:["class","style","externalResourcesRequired","preserveAspectRatio","href","xlink:href"],defaults:{preserveAspectRatio:"xMidYMid meet"},content:["animate","animateTransform","set"]},feMerge:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style"],content:["feMergeNode"]},feMergeNode:{attrsGroups:["core"],attrs:["in"],content:["animate","set"]},feMorphology:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","operator","radius"],defaults:{operator:"erode",radius:"0"},content:["animate","set"]},feOffset:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","dx","dy"],defaults:{dx:"0",dy:"0"},content:["animate","set"]},fePointLight:{attrsGroups:["core"],attrs:["x","y","z"],defaults:{x:"0",y:"0",z:"0"},content:["animate","set"]},feSpecularLighting:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in","surfaceScale","specularConstant","specularExponent","kernelUnitLength"],defaults:{surfaceScale:"1",specularConstant:"1",specularExponent:"1"},contentGroups:["descriptive","lightSource"]},feSpotLight:{attrsGroups:["core"],attrs:["x","y","z","pointsAtX","pointsAtY","pointsAtZ","specularExponent","limitingConeAngle"],defaults:{x:"0",y:"0",z:"0",pointsAtX:"0",pointsAtY:"0",pointsAtZ:"0",specularExponent:"1"},content:["animate","set"]},feTile:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","in"],content:["animate","set"]},feTurbulence:{attrsGroups:["core","presentation","filterPrimitive"],attrs:["class","style","baseFrequency","numOctaves","seed","stitchTiles","type"],defaults:{baseFrequency:"0",numOctaves:"1",seed:"0",stitchTiles:"noStitch",type:"turbulence"},content:["animate","set"]},filter:{attrsGroups:["core","presentation","xlink"],attrs:["class","style","externalResourcesRequired","x","y","width","height","filterRes","filterUnits","primitiveUnits","href","xlink:href"],defaults:{primitiveUnits:"userSpaceOnUse",x:"-10%",y:"-10%",width:"120%",height:"120%"},contentGroups:["descriptive","filterPrimitive"],content:["animate","set"]},font:{attrsGroups:["core","presentation"],attrs:["class","style","externalResourcesRequired","horiz-origin-x","horiz-origin-y","horiz-adv-x","vert-origin-x","vert-origin-y","vert-adv-y"],defaults:{"horiz-origin-x":"0","horiz-origin-y":"0"},contentGroups:["descriptive"],content:["font-face","glyph","hkern","missing-glyph","vkern"]},"font-face":{attrsGroups:["core"],attrs:["font-family","font-style","font-variant","font-weight","font-stretch","font-size","unicode-range","units-per-em","panose-1","stemv","stemh","slope","cap-height","x-height","accent-height","ascent","descent","widths","bbox","ideographic","alphabetic","mathematical","hanging","v-ideographic","v-alphabetic","v-mathematical","v-hanging","underline-position","underline-thickness","strikethrough-position","strikethrough-thickness","overline-position","overline-thickness"],defaults:{"font-style":"all","font-variant":"normal","font-weight":"all","font-stretch":"normal","unicode-range":"U+0-10FFFF","units-per-em":"1000","panose-1":"0 0 0 0 0 0 0 0 0 0",slope:"0"},contentGroups:["descriptive"],content:["font-face-src"]},"font-face-format":{attrsGroups:["core"],attrs:["string"]},"font-face-name":{attrsGroups:["core"],attrs:["name"]},"font-face-src":{attrsGroups:["core"],content:["font-face-name","font-face-uri"]},"font-face-uri":{attrsGroups:["core","xlink"],attrs:["href","xlink:href"],content:["font-face-format"]},foreignObject:{attrsGroups:["core","conditionalProcessing","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","x","y","width","height"],defaults:{x:"0",y:"0"}},g:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform"],contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},glyph:{attrsGroups:["core","presentation"],attrs:["class","style","d","horiz-adv-x","vert-origin-x","vert-origin-y","vert-adv-y","unicode","glyph-name","orientation","arabic-form","lang"],defaults:{"arabic-form":"initial"},contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},glyphRef:{attrsGroups:["core","presentation"],attrs:["class","style","d","horiz-adv-x","vert-origin-x","vert-origin-y","vert-adv-y"],contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},hatch:{attrsGroups:["core","presentation","xlink"],attrs:["class","style","x","y","pitch","rotate","hatchUnits","hatchContentUnits","transform"],defaults:{hatchUnits:"objectBoundingBox",hatchContentUnits:"userSpaceOnUse",x:"0",y:"0",pitch:"0",rotate:"0"},contentGroups:["animation","descriptive"],content:["hatchPath"]},hatchPath:{attrsGroups:["core","presentation","xlink"],attrs:["class","style","d","offset"],defaults:{offset:"0"},contentGroups:["animation","descriptive"]},hkern:{attrsGroups:["core"],attrs:["u1","g1","u2","g2","k"]},image:{attrsGroups:["core","conditionalProcessing","graphicalEvent","xlink","presentation"],attrs:["class","style","externalResourcesRequired","preserveAspectRatio","transform","x","y","width","height","href","xlink:href"],defaults:{x:"0",y:"0",preserveAspectRatio:"xMidYMid meet"},contentGroups:["animation","descriptive"]},line:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","x1","y1","x2","y2"],defaults:{x1:"0",y1:"0",x2:"0",y2:"0"},contentGroups:["animation","descriptive"]},linearGradient:{attrsGroups:["core","presentation","xlink"],attrs:["class","style","externalResourcesRequired","x1","y1","x2","y2","gradientUnits","gradientTransform","spreadMethod","href","xlink:href"],defaults:{x1:"0",y1:"0",x2:"100%",y2:"0",spreadMethod:"pad"},contentGroups:["descriptive"],content:["animate","animateTransform","set","stop"]},marker:{attrsGroups:["core","presentation"],attrs:["class","style","externalResourcesRequired","viewBox","preserveAspectRatio","refX","refY","markerUnits","markerWidth","markerHeight","orient"],defaults:{markerUnits:"strokeWidth",refX:"0",refY:"0",markerWidth:"3",markerHeight:"3"},contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},mask:{attrsGroups:["conditionalProcessing","core","presentation"],attrs:["class","style","externalResourcesRequired","x","y","width","height","mask-type","maskUnits","maskContentUnits"],defaults:{maskUnits:"objectBoundingBox",maskContentUnits:"userSpaceOnUse",x:"-10%",y:"-10%",width:"120%",height:"120%"},contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},metadata:{attrsGroups:["core"]},"missing-glyph":{attrsGroups:["core","presentation"],attrs:["class","style","d","horiz-adv-x","vert-origin-x","vert-origin-y","vert-adv-y"],contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},mpath:{attrsGroups:["core","xlink"],attrs:["externalResourcesRequired","href","xlink:href"],contentGroups:["descriptive"]},path:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","d","pathLength"],contentGroups:["animation","descriptive"]},pattern:{attrsGroups:["conditionalProcessing","core","presentation","xlink"],attrs:["class","style","externalResourcesRequired","viewBox","preserveAspectRatio","x","y","width","height","patternUnits","patternContentUnits","patternTransform","href","xlink:href"],defaults:{patternUnits:"objectBoundingBox",patternContentUnits:"userSpaceOnUse",x:"0",y:"0",width:"0",height:"0",preserveAspectRatio:"xMidYMid meet"},contentGroups:["animation","descriptive","paintServer","shape","structural"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},polygon:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","points"],contentGroups:["animation","descriptive"]},polyline:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","points"],contentGroups:["animation","descriptive"]},radialGradient:{attrsGroups:["core","presentation","xlink"],attrs:["class","style","externalResourcesRequired","cx","cy","r","fx","fy","fr","gradientUnits","gradientTransform","spreadMethod","href","xlink:href"],defaults:{gradientUnits:"objectBoundingBox",cx:"50%",cy:"50%",r:"50%"},contentGroups:["descriptive"],content:["animate","animateTransform","set","stop"]},meshGradient:{attrsGroups:["core","presentation","xlink"],attrs:["class","style","x","y","gradientUnits","transform"],contentGroups:["descriptive","paintServer","animation"],content:["meshRow"]},meshRow:{attrsGroups:["core","presentation"],attrs:["class","style"],contentGroups:["descriptive"],content:["meshPatch"]},meshPatch:{attrsGroups:["core","presentation"],attrs:["class","style"],contentGroups:["descriptive"],content:["stop"]},rect:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","x","y","width","height","rx","ry"],defaults:{x:"0",y:"0"},contentGroups:["animation","descriptive"]},script:{attrsGroups:["core","xlink"],attrs:["externalResourcesRequired","type","href","xlink:href"]},set:{attrsGroups:["conditionalProcessing","core","animation","xlink","animationAttributeTarget","animationTiming"],attrs:["externalResourcesRequired","to"],contentGroups:["descriptive"]},solidColor:{attrsGroups:["core","presentation"],attrs:["class","style"],contentGroups:["paintServer"]},stop:{attrsGroups:["core","presentation"],attrs:["class","style","offset","path"],content:["animate","animateColor","set"]},style:{attrsGroups:["core"],attrs:["type","media","title"],defaults:{type:"text/css"}},svg:{attrsGroups:["conditionalProcessing","core","documentEvent","graphicalEvent","presentation"],attrs:["class","style","x","y","width","height","viewBox","preserveAspectRatio","zoomAndPan","version","baseProfile","contentScriptType","contentStyleType"],defaults:{x:"0",y:"0",width:"100%",height:"100%",preserveAspectRatio:"xMidYMid meet",zoomAndPan:"magnify",version:"1.1",baseProfile:"none",contentScriptType:"application/ecmascript",contentStyleType:"text/css"},contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},switch:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform"],contentGroups:["animation","descriptive","shape"],content:["a","foreignObject","g","image","svg","switch","text","use"]},symbol:{attrsGroups:["core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","preserveAspectRatio","viewBox","refX","refY"],defaults:{refX:"0",refY:"0"},contentGroups:["animation","descriptive","shape","structural","paintServer"],content:["a","altGlyphDef","clipPath","color-profile","cursor","filter","font","font-face","foreignObject","image","marker","mask","pattern","script","style","switch","text","view"]},text:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","transform","lengthAdjust","x","y","dx","dy","rotate","textLength"],defaults:{x:"0",y:"0",lengthAdjust:"spacing"},contentGroups:["animation","descriptive","textContentChild"],content:["a"]},textPath:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation","xlink"],attrs:["class","style","externalResourcesRequired","href","xlink:href","startOffset","method","spacing","d"],defaults:{startOffset:"0",method:"align",spacing:"exact"},contentGroups:["descriptive"],content:["a","altGlyph","animate","animateColor","set","tref","tspan"]},title:{attrsGroups:["core"],attrs:["class","style"]},tref:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation","xlink"],attrs:["class","style","externalResourcesRequired","href","xlink:href"],contentGroups:["descriptive"],content:["animate","animateColor","set"]},tspan:{attrsGroups:["conditionalProcessing","core","graphicalEvent","presentation"],attrs:["class","style","externalResourcesRequired","x","y","dx","dy","rotate","textLength","lengthAdjust"],contentGroups:["descriptive"],content:["a","altGlyph","animate","animateColor","set","tref","tspan"]},use:{attrsGroups:["core","conditionalProcessing","graphicalEvent","presentation","xlink"],attrs:["class","style","externalResourcesRequired","transform","x","y","width","height","href","xlink:href"],defaults:{x:"0",y:"0"},contentGroups:["animation","descriptive"]},view:{attrsGroups:["core"],attrs:["externalResourcesRequired","viewBox","preserveAspectRatio","zoomAndPan","viewTarget"],contentGroups:["descriptive"]},vkern:{attrsGroups:["core"],attrs:["u1","g1","u2","g2","k"]}};exports.editorNamespaces=["http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd","http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd","http://www.inkscape.org/namespaces/inkscape","http://www.bohemiancoding.com/sketch/ns","http://ns.adobe.com/AdobeIllustrator/10.0/","http://ns.adobe.com/Graphs/1.0/","http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/","http://ns.adobe.com/Variables/1.0/","http://ns.adobe.com/SaveForWeb/1.0/","http://ns.adobe.com/Extensibility/1.0/","http://ns.adobe.com/Flows/1.0/","http://ns.adobe.com/ImageReplacement/1.0/","http://ns.adobe.com/GenericCustomNamespace/1.0/","http://ns.adobe.com/XPath/1.0/","http://schemas.microsoft.com/visio/2003/SVGExtensions/","http://taptrix.com/vectorillustrator/svg_extensions","http://www.figma.com/figma/ns","http://purl.org/dc/elements/1.1/","http://creativecommons.org/ns#","http://www.w3.org/1999/02/22-rdf-syntax-ns#","http://www.serif.com/","http://www.vector.evaxdesign.sk"];exports.referencesProps=["clip-path","color-profile","fill","filter","marker-start","marker-mid","marker-end","mask","stroke","style"];exports.inheritableAttrs=["clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cursor","direction","dominant-baseline","fill","fill-opacity","fill-rule","font","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-orientation-horizontal","glyph-orientation-vertical","image-rendering","letter-spacing","marker","marker-end","marker-mid","marker-start","paint-order","pointer-events","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-rendering","transform","visibility","word-spacing","writing-mode"];exports.presentationNonInheritableGroupAttrs=["display","clip-path","filter","mask","opacity","text-decoration","transform","unicode-bidi"];exports.colorsNames={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#0ff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000",blanchedalmond:"#ffebcd",blue:"#00f",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#0ff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#f0f",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#789",lightslategrey:"#789",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#0f0",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#f0f",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#639",red:"#f00",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#fff",whitesmoke:"#f5f5f5",yellow:"#ff0",yellowgreen:"#9acd32"};exports.colorsShortNames={"#f0ffff":"azure","#f5f5dc":"beige","#ffe4c4":"bisque","#a52a2a":"brown","#ff7f50":"coral","#ffd700":"gold","#808080":"gray","#008000":"green","#4b0082":"indigo","#fffff0":"ivory","#f0e68c":"khaki","#faf0e6":"linen","#800000":"maroon","#000080":"navy","#808000":"olive","#ffa500":"orange","#da70d6":"orchid","#cd853f":"peru","#ffc0cb":"pink","#dda0dd":"plum","#800080":"purple","#f00":"red","#ff0000":"red","#fa8072":"salmon","#a0522d":"sienna","#c0c0c0":"silver","#fffafa":"snow","#d2b48c":"tan","#008080":"teal","#ff6347":"tomato","#ee82ee":"violet","#f5deb3":"wheat"};exports.colorsProps=["color","fill","stroke","stop-color","flood-color","lighting-color"]})(_collections);const{detachNodeFromParent:detachNodeFromParent$g}=xast;const{editorNamespaces:editorNamespaces}=_collections;removeEditorsNSData$1.type="visitor";removeEditorsNSData$1.name="removeEditorsNSData";removeEditorsNSData$1.active=true;removeEditorsNSData$1.description="removes editors namespaces, elements and attributes";removeEditorsNSData$1.fn=(_root,params)=>{let namespaces=editorNamespaces;if(Array.isArray(params.additionalNamespaces)){namespaces=[...editorNamespaces,...params.additionalNamespaces]}const prefixes=[];return{element:{enter:(node,parentNode)=>{if(node.name==="svg"){for(const[name,value]of Object.entries(node.attributes)){if(name.startsWith("xmlns:")&&namespaces.includes(value)){prefixes.push(name.slice("xmlns:".length));delete node.attributes[name]}}}for(const name of Object.keys(node.attributes)){if(name.includes(":")){const[prefix]=name.split(":");if(prefixes.includes(prefix)){delete node.attributes[name]}}}if(node.name.includes(":")){const[prefix]=node.name.split(":");if(prefixes.includes(prefix)){detachNodeFromParent$g(node,parentNode)}}}}}};var cleanupAttrs$1={};cleanupAttrs$1.name="cleanupAttrs";cleanupAttrs$1.type="visitor";cleanupAttrs$1.active=true;cleanupAttrs$1.description="cleanups attributes from newlines, trailing and repeating spaces";const regNewlinesNeedSpace=/(\S)\r?\n(\S)/g;const regNewlines=/\r?\n/g;const regSpaces=/\s{2,}/g;cleanupAttrs$1.fn=(root,params)=>{const{newlines:newlines=true,trim:trim=true,spaces:spaces=true}=params;return{element:{enter:node=>{for(const name of Object.keys(node.attributes)){if(newlines){node.attributes[name]=node.attributes[name].replace(regNewlinesNeedSpace,((match,p1,p2)=>p1+" "+p2));node.attributes[name]=node.attributes[name].replace(regNewlines,"")}if(trim){node.attributes[name]=node.attributes[name].trim()}if(spaces){node.attributes[name]=node.attributes[name].replace(regSpaces," ")}}}}}};var mergeStyles$1={};var CSSClassList$1=function(node){this.parentNode=node;this.classNames=new Set;const value=node.attributes.class;if(value!=null){this.addClassValueHandler();this.setClassValue(value)}};CSSClassList$1.prototype.addClassValueHandler=function(){Object.defineProperty(this.parentNode.attributes,"class",{get:this.getClassValue.bind(this),set:this.setClassValue.bind(this),enumerable:true,configurable:true})};CSSClassList$1.prototype.getClassValue=function(){var arrClassNames=Array.from(this.classNames);return arrClassNames.join(" ")};CSSClassList$1.prototype.setClassValue=function(newValue){if(typeof newValue==="undefined"){this.classNames.clear();return}var arrClassNames=newValue.split(" ");this.classNames=new Set(arrClassNames)};CSSClassList$1.prototype.add=function(){this.addClassValueHandler();Object.values(arguments).forEach(this._addSingle.bind(this))};CSSClassList$1.prototype._addSingle=function(className){this.classNames.add(className)};CSSClassList$1.prototype.remove=function(){this.addClassValueHandler();Object.values(arguments).forEach(this._removeSingle.bind(this))};CSSClassList$1.prototype._removeSingle=function(className){this.classNames.delete(className)};CSSClassList$1.prototype.item=function(index){var arrClassNames=Array.from(this.classNames);return arrClassNames[index]};CSSClassList$1.prototype.toggle=function(className,force){if(this.contains(className)||force===false){this.classNames.delete(className)}this.classNames.add(className)};CSSClassList$1.prototype.contains=function(className){return this.classNames.has(className)};var cssClassList=CSSClassList$1;var csstree_min={exports:{}};(function(module,exports){!function(e,t){module.exports=t()}(commonjsGlobal,(function(){function e(e){return{prev:null,next:null,data:e}}function t(e,t,n){var i;return null!==r?(i=r,r=r.cursor,i.prev=t,i.next=n,i.cursor=e.cursor):i={prev:t,next:n,cursor:e.cursor},e.cursor=i,i}function n(e){var t=e.cursor;e.cursor=t.cursor,t.prev=null,t.next=null,t.cursor=r,r=t}var r=null,i=function(){this.cursor=null,this.head=null,this.tail=null};i.createItem=e,i.prototype.createItem=e,i.prototype.updateCursors=function(e,t,n,r){for(var i=this.cursor;null!==i;)i.prev===e&&(i.prev=t),i.next===n&&(i.next=r),i=i.cursor},i.prototype.getSize=function(){for(var e=0,t=this.head;t;)e++,t=t.next;return e},i.prototype.fromArray=function(t){var n=null;this.head=null;for(var r=0;r100&&(c=a-60+3,a=58);for(var u=o;u<=s;u++)u>=0&&u0&&r[u].length>c?"…":"")+r[u].substr(c,98)+(r[u].length>c+100-1?"…":""));return[n(o,i),new Array(a+l+2).join("-")+"^",n(i,s)].filter(Boolean).join("\n")}var l=function(e,t,n,r,i){var a=o("SyntaxError",e);return a.source=t,a.offset=n,a.line=r,a.column=i,a.sourceFragment=function(e){return s(a,isNaN(e)?0:e)},Object.defineProperty(a,"formattedMessage",{get:function(){return"Parse error: "+a.message+"\n"+s(a,2)}}),a.parseError={offset:n,line:r,column:i},a},c={EOF:0,Ident:1,Function:2,AtKeyword:3,Hash:4,String:5,BadString:6,Url:7,BadUrl:8,Delim:9,Number:10,Percentage:11,Dimension:12,WhiteSpace:13,CDO:14,CDC:15,Colon:16,Semicolon:17,Comma:18,LeftSquareBracket:19,RightSquareBracket:20,LeftParenthesis:21,RightParenthesis:22,LeftCurlyBracket:23,RightCurlyBracket:24,Comment:25},u=Object.keys(c).reduce((function(e,t){return e[c[t]]=t,e}),{}),h={TYPE:c,NAME:u};function p(e){return e>=48&&e<=57}function d(e){return e>=65&&e<=90}function m(e){return e>=97&&e<=122}function g(e){return d(e)||m(e)}function f(e){return e>=128}function b(e){return g(e)||f(e)||95===e}function y(e){return e>=0&&e<=8||11===e||e>=14&&e<=31||127===e}function k(e){return 10===e||13===e||12===e}function v(e){return k(e)||32===e||9===e}function x(e,t){return 92===e&&(!k(t)&&0!==t)}var w=new Array(128);C.Eof=128,C.WhiteSpace=130,C.Digit=131,C.NameStart=132,C.NonPrintable=133;for(var S=0;S=65&&e<=70||e>=97&&e<=102},isUppercaseLetter:d,isLowercaseLetter:m,isLetter:g,isNonAscii:f,isNameStart:b,isName:function(e){return b(e)||p(e)||45===e},isNonPrintable:y,isNewline:k,isWhiteSpace:v,isValidEscape:x,isIdentifierStart:function(e,t,n){return 45===e?b(t)||45===t||x(t,n):!!b(e)||92===e&&x(e,t)},isNumberStart:function(e,t,n){return 43===e||45===e?p(t)?2:46===t&&p(n)?3:0:46===e?p(t)?2:0:p(e)?1:0},isBOM:function(e){return 65279===e||65534===e?1:0},charCodeCategory:C},A=z.isDigit,P=z.isHexDigit,T=z.isUppercaseLetter,L=z.isName,E=z.isWhiteSpace,D=z.isValidEscape;function O(e,t){return te.length)return!1;for(var i=t;i=0&&E(e.charCodeAt(t));t--);return t+1},findWhiteSpaceEnd:function(e,t){for(;t>24:W},lookupOffset:function(e){return(e+=this.tokenIndex)0?e>24,this.source,i)){case 1:break e;case 2:r++;break e;default:this.balance[n]===r&&(r=n),i=16777215&this.offsetAndType[r]}return r-this.tokenIndex},isBalanceEdge:function(e){return this.balance[this.tokenIndex]>24===q;e++,t++);t>0&&this.skip(t)},skipSC:function(){for(;this.tokenType===q||this.tokenType===Y;)this.next()},skip:function(e){var t=this.tokenIndex+e;t>24,this.tokenEnd=16777215&t):(this.tokenIndex=this.tokenCount,this.next())},next:function(){var e=this.tokenIndex+1;e>24,this.tokenEnd=16777215&e):(this.tokenIndex=this.tokenCount,this.eof=!0,this.tokenType=W,this.tokenStart=this.tokenEnd=this.source.length)},forEachToken(e){for(var t=0,n=this.firstCharOffset;t>24,r,a,t)}},dump(){var e=new Array(this.tokenCount);return this.forEachToken(((t,n,r,i)=>{e[i]={idx:i,type:_[t],chunk:this.source.substring(n,r),balance:this.balance[i]}})),e}};var H=U;function V(e){return e}function K(e,t,n,r){var i,a;switch(e.type){case"Group":i=function(e,t,n,r){var i=" "===e.combinator||r?e.combinator:" "+e.combinator+" ",a=e.terms.map((function(e){return K(e,t,n,r)})).join(i);return(e.explicit||n)&&(a=(r||","===a[0]?"[":"[ ")+a+(r?"]":" ]")),a}(e,t,n,r)+(e.disallowEmpty?"!":"");break;case"Multiplier":return K(e.term,t,n,r)+t(0===(a=e).min&&0===a.max?"*":0===a.min&&1===a.max?"?":1===a.min&&0===a.max?a.comma?"#":"+":1===a.min&&1===a.max?"":(a.comma?"#":"")+(a.min===a.max?"{"+a.min+"}":"{"+a.min+","+(0!==a.max?a.max:"")+"}"),e);case"Type":i="<"+e.name+(e.opts?t(function(e){switch(e.type){case"Range":return" ["+(null===e.min?"-∞":e.min)+","+(null===e.max?"∞":e.max)+"]";default:throw new Error("Unknown node type `"+e.type+"`")}}(e.opts),e.opts):"")+">";break;case"Property":i="<'"+e.name+"'>";break;case"Keyword":i=e.name;break;case"AtKeyword":i="@"+e.name;break;case"Function":i=e.name+"(";break;case"String":case"Token":i=e.value;break;case"Comma":i=",";break;default:throw new Error("Unknown node type `"+e.type+"`")}return t(i,e)}var G=function(e,t){var n=V,r=!1,i=!1;return"function"==typeof t?n=t:t&&(r=Boolean(t.forceBraces),i=Boolean(t.compact),"function"==typeof t.decorate&&(n=t.decorate)),K(e,n,r,i)};const Q={offset:0,line:1,column:1};function X(e,t){const n=e&&e.loc&&e.loc[t];return n?"line"in n?Z(n):n:null}function Z({offset:e,line:t,column:n},r){const i={offset:e,line:t,column:n};if(r){const e=r.split(/\n|\r\n?|\f/);i.offset+=r.length,i.line+=e.length-1,i.column=1===e.length?i.column+r.length:e.pop().length+1}return i}var $=function(e,t){const n=o("SyntaxReferenceError",e+(t?" `"+t+"`":""));return n.reference=t,n},J=function(e,t,n,r){const i=o("SyntaxMatchError",e),{css:a,mismatchOffset:s,mismatchLength:l,start:c,end:u}=function(e,t){const n=e.tokens,r=e.longestMatch,i=r1?(o=X(a||t,"end")||Z(Q,h),s=Z(o)):(o=X(a,"start")||Z(X(t,"start")||Q,h.slice(0,l)),s=X(a,"end")||Z(o,h.substr(l,c))),{css:h,mismatchOffset:l,mismatchLength:c,start:o,end:s}}(r,n);return i.rawMessage=e,i.syntax=t?G(t):"",i.css=a,i.mismatchOffset=s,i.mismatchLength=l,i.message=e+"\n syntax: "+i.syntax+"\n value: "+(a||"")+"\n --------"+new Array(i.mismatchOffset+1).join("-")+"^",Object.assign(i,c),i.loc={source:n&&n.loc&&n.loc.source||"",start:c,end:u},i},ee=Object.prototype.hasOwnProperty,te=Object.create(null),ne=Object.create(null);function re(e,t){return t=t||0,e.length-t>=2&&45===e.charCodeAt(t)&&45===e.charCodeAt(t+1)}function ie(e,t){if(t=t||0,e.length-t>=3&&45===e.charCodeAt(t)&&45!==e.charCodeAt(t+1)){var n=e.indexOf("-",t+2);if(-1!==n)return e.substring(t,n+1)}return""}var ae={keyword:function(e){if(ee.call(te,e))return te[e];var t=e.toLowerCase();if(ee.call(te,t))return te[e]=te[t];var n=re(t,0),r=n?"":ie(t,0);return te[e]=Object.freeze({basename:t.substr(r.length),name:t,vendor:r,prefix:r,custom:n})},property:function(e){if(ee.call(ne,e))return ne[e];var t=e,n=e[0];"/"===n?n="/"===e[1]?"//":"/":"_"!==n&&"*"!==n&&"$"!==n&&"#"!==n&&"+"!==n&&"&"!==n&&(n="");var r=re(t,n.length);if(!r&&(t=t.toLowerCase(),ee.call(ne,t)))return ne[e]=ne[t];var i=r?"":ie(t,n.length),a=t.substr(0,n.length+i.length);return ne[e]=Object.freeze({basename:t.substr(a.length),name:t.substr(n.length),hack:n,vendor:i,prefix:a,custom:r})},isCustomProperty:re,vendorPrefix:ie},oe="undefined"!=typeof Uint32Array?Uint32Array:Array,se=function(e,t){return null===e||e.length=e.length?void(h>24,l[c]=m,l[m++]=c;m0?6:0;if(!je(a))return 0;if(++i>6)return 0}return i}function Ge(e,t,n){if(!e)return 0;for(;He(n(t),63);){if(++e>6)return 0;t++}return t}var Qe=Ce.isIdentifierStart,Xe=Ce.isHexDigit,Ze=Ce.isDigit,$e=Ce.cmpStr,Je=Ce.consumeNumber,et=Ce.TYPE,tt=["unset","initial","inherit"],nt=["calc(","-moz-calc(","-webkit-calc("];function rt(e,t){return te.max)return!0}return!1}function lt(e,t){var n=e.index,r=0;do{if(r++,e.balance<=n)break}while(e=t(r));return r}function ct(e){return function(t,n,r){return null===t?0:t.type===et.Function&&at(t.value,nt)?lt(t,n):e(t,n,r)}}function ut(e){return function(t){return null===t||t.type!==e?0:1}}function ht(e){return function(t,n,r){if(null===t||t.type!==et.Dimension)return 0;var i=Je(t.value,0);if(null!==e){var a=t.value.indexOf("\\",i),o=-1!==a&&ot(t.value,a)?t.value.substring(i,a):t.value.substr(i);if(!1===e.hasOwnProperty(o.toLowerCase()))return 0}return st(r,t.value,i)?0:1}}function pt(e){return"function"!=typeof e&&(e=function(){return 0}),function(t,n,r){return null!==t&&t.type===et.Number&&0===Number(t.value)?1:e(t,n,r)}}var dt,mt={"ident-token":ut(et.Ident),"function-token":ut(et.Function),"at-keyword-token":ut(et.AtKeyword),"hash-token":ut(et.Hash),"string-token":ut(et.String),"bad-string-token":ut(et.BadString),"url-token":ut(et.Url),"bad-url-token":ut(et.BadUrl),"delim-token":ut(et.Delim),"number-token":ut(et.Number),"percentage-token":ut(et.Percentage),"dimension-token":ut(et.Dimension),"whitespace-token":ut(et.WhiteSpace),"CDO-token":ut(et.CDO),"CDC-token":ut(et.CDC),"colon-token":ut(et.Colon),"semicolon-token":ut(et.Semicolon),"comma-token":ut(et.Comma),"[-token":ut(et.LeftSquareBracket),"]-token":ut(et.RightSquareBracket),"(-token":ut(et.LeftParenthesis),")-token":ut(et.RightParenthesis),"{-token":ut(et.LeftCurlyBracket),"}-token":ut(et.RightCurlyBracket),string:ut(et.String),ident:ut(et.Ident),"custom-ident":function(e){if(null===e||e.type!==et.Ident)return 0;var t=e.value.toLowerCase();return at(t,tt)||it(t,"default")?0:1},"custom-property-name":function(e){return null===e||e.type!==et.Ident||45!==rt(e.value,0)||45!==rt(e.value,1)?0:1},"hex-color":function(e){if(null===e||e.type!==et.Hash)return 0;var t=e.value.length;if(4!==t&&5!==t&&7!==t&&9!==t)return 0;for(var n=1;ne.index||e.balancee.index||e.balance=128||0===yt[n])break}return e.pos===t&&e.error("Expect a keyword"),e.substringToPos(t)}function wt(e){for(var t=e.pos;t57)break}return e.pos===t&&e.error("Expect a number"),e.substringToPos(t)}function St(e){var t=e.str.indexOf("'",e.pos+1);return-1===t&&(e.pos=e.str.length,e.error("Expect an apostrophe")),e.substringToPos(t+1)}function Ct(e){var t,n=null;return e.eat(123),t=wt(e),44===e.charCode()?(e.pos++,125!==e.charCode()&&(n=wt(e))):n=t,e.eat(125),{min:Number(t),max:n?Number(n):0}}function zt(e,t){var n=function(e){var t=null,n=!1;switch(e.charCode()){case 42:e.pos++,t={min:0,max:0};break;case 43:e.pos++,t={min:1,max:0};break;case 63:e.pos++,t={min:0,max:1};break;case 35:e.pos++,n=!0,t=123===e.charCode()?Ct(e):{min:1,max:0};break;case 123:t=Ct(e);break;default:return null}return{type:"Multiplier",comma:n,min:t.min,max:t.max,term:null}}(e);return null!==n?(n.term=t,n):t}function At(e){var t=e.peek();return""===t?null:{type:"Token",value:t}}function Pt(e){var t,n=null;return e.eat(60),t=xt(e),40===e.charCode()&&41===e.nextCharCode()&&(e.pos+=2,t+="()"),91===e.charCodeAt(e.findWsEnd(e.pos))&&(vt(e),n=function(e){var t=null,n=null,r=1;return e.eat(91),45===e.charCode()&&(e.peek(),r=-1),-1==r&&8734===e.charCode()?e.peek():t=r*Number(wt(e)),vt(e),e.eat(44),vt(e),8734===e.charCode()?e.peek():(r=1,45===e.charCode()&&(e.peek(),r=-1),n=r*Number(wt(e))),e.eat(93),null===t&&null===n?null:{type:"Range",min:t,max:n}}(e)),e.eat(62),zt(e,{type:"Type",name:t,opts:n})}function Tt(e,t){function n(e,t){return{type:"Group",terms:e,combinator:t,disallowEmpty:!1,explicit:!1}}for(t=Object.keys(t).sort((function(e,t){return kt[e]-kt[t]}));t.length>0;){for(var r=t.shift(),i=0,a=0;i1&&(e.splice(a,i-a,n(e.slice(a,i),r)),i=a+1),a=-1))}-1!==a&&t.length&&e.splice(a,i-a,n(e.slice(a,i),r))}return r}function Lt(e){for(var t,n=[],r={},i=null,a=e.pos;t=Et(e);)"Spaces"!==t.type&&("Combinator"===t.type?(null!==i&&"Combinator"!==i.type||(e.pos=a,e.error("Unexpected combinator")),r[t.value]=!0):null!==i&&"Combinator"!==i.type&&(r[" "]=!0,n.push({type:"Combinator",value:" "})),n.push(t),i=t,a=e.pos);return null!==i&&"Combinator"===i.type&&(e.pos-=a,e.error("Unexpected combinator")),{type:"Group",terms:n,combinator:Tt(n,r)||" ",disallowEmpty:!1,explicit:!1}}function Et(e){var t=e.charCode();if(t<128&&1===yt[t])return function(e){var t;return t=xt(e),40===e.charCode()?(e.pos++,{type:"Function",name:t}):zt(e,{type:"Keyword",name:t})}(e);switch(t){case 93:break;case 91:return zt(e,function(e){var t;return e.eat(91),t=Lt(e),e.eat(93),t.explicit=!0,33===e.charCode()&&(e.pos++,t.disallowEmpty=!0),t}(e));case 60:return 39===e.nextCharCode()?function(e){var t;return e.eat(60),e.eat(39),t=xt(e),e.eat(39),e.eat(62),zt(e,{type:"Property",name:t})}(e):Pt(e);case 124:return{type:"Combinator",value:e.substringToPos(124===e.nextCharCode()?e.pos+2:e.pos+1)};case 38:return e.pos++,e.eat(38),{type:"Combinator",value:"&&"};case 44:return e.pos++,{type:"Comma"};case 39:return zt(e,{type:"String",value:St(e)});case 32:case 9:case 10:case 13:case 12:return{type:"Spaces",value:vt(e)};case 64:return(t=e.nextCharCode())<128&&1===yt[t]?(e.pos++,{type:"AtKeyword",name:xt(e)}):At(e);case 42:case 43:case 63:case 35:case 33:break;case 123:if((t=e.nextCharCode())<48||t>57)return At(e);break;default:return At(e)}}function Dt(e){var t=new bt(e),n=Lt(t);return t.pos!==e.length&&t.error("Unexpected input"),1===n.terms.length&&"Group"===n.terms[0].type&&(n=n.terms[0]),n}Dt("[a&&#|<'c'>*||e() f{2} /,(% g#{1,2} h{2,})]!");var Ot=Dt,Bt=function(){};function It(e){return"function"==typeof e?e:Bt}var Nt=function(e,t,n){var r=Bt,i=Bt;if("function"==typeof t?r=t:t&&(r=It(t.enter),i=It(t.leave)),r===Bt&&i===Bt)throw new Error("Neither `enter` nor `leave` walker handler is set or both aren't a function");!function e(t){switch(r.call(n,t),t.type){case"Group":t.terms.forEach(e);break;case"Multiplier":e(t.term);break;case"Type":case"Property":case"Keyword":case"AtKeyword":case"Function":case"String":case"Token":case"Comma":break;default:throw new Error("Unknown type: "+t.type)}i.call(n,t)}(e)},Rt=new H,Mt={decorator:function(e){var t=null,n={len:0,node:null},r=[n],i="";return{children:e.children,node:function(n){var r=t;t=n,e.node.call(this,n),t=r},chunk:function(e){i+=e,n.node!==t?r.push({len:e.length,node:t}):n.len+=e.length},result:function(){return jt(i,r)}}}};function jt(e,t){var n=[],r=0,i=0,a=t?t[i].node:null;for(Ce(e,Rt);!Rt.eof;){if(t)for(;i2&&40===e.charCodeAt(e.length-2)&&41===e.charCodeAt(e.length-1)}function Ut(e){return"Keyword"===e.type||"AtKeyword"===e.type||"Function"===e.type||"Type"===e.type&&Yt(e.name)}function Ht(e){if("function"==typeof e)return{type:"Generic",fn:e};switch(e.type){case"Group":var t=function e(t,n,r){switch(t){case" ":for(var i=_t,a=n.length-1;a>=0;a--){i=qt(l=n[a],i,Ft)}return i;case"|":i=Ft;var o=null;for(a=n.length-1;a>=0;a--){if(Ut(l=n[a])&&(null===o&&a>0&&Ut(n[a-1])&&(i=qt({type:"Enum",map:o=Object.create(null)},_t,i)),null!==o)){var s=(Yt(l.name)?l.name.slice(0,-1):l.name).toLowerCase();if(s in o==!1){o[s]=l;continue}}o=null,i=qt(l,_t,i)}return i;case"&&":if(n.length>5)return{type:"MatchOnce",terms:n,all:!0};for(i=Ft,a=n.length-1;a>=0;a--){var l=n[a];c=n.length>1?e(t,n.filter((function(e){return e!==l})),!1):_t,i=qt(l,c,i)}return i;case"||":if(n.length>5)return{type:"MatchOnce",terms:n,all:!1};for(i=r?_t:Ft,a=n.length-1;a>=0;a--){var c;l=n[a];c=n.length>1?e(t,n.filter((function(e){return e!==l})),!0):_t,i=qt(l,c,i)}return i}}(e.combinator,e.terms.map(Ht),!1);return e.disallowEmpty&&(t=qt(t,Wt,Ft)),t;case"Multiplier":return function(e){var t=_t,n=Ht(e.term);if(0===e.max)n=qt(n,Wt,Ft),(t=qt(n,null,Ft)).then=qt(_t,_t,t),e.comma&&(t.then.else=qt({type:"Comma",syntax:e},t,Ft));else for(var r=e.min||1;r<=e.max;r++)e.comma&&t!==_t&&(t=qt({type:"Comma",syntax:e},t,Ft)),t=qt(n,qt(_t,_t,t),Ft);if(0===e.min)t=qt(_t,_t,t);else for(r=0;r=65&&r<=90&&(r|=32),r!==t.charCodeAt(n))return!1}return!0}function rn(e){return null===e||(e.type===en.Comma||e.type===en.Function||e.type===en.LeftParenthesis||e.type===en.LeftSquareBracket||e.type===en.LeftCurlyBracket||function(e){return e.type===en.Delim&&"?"!==e.value}(e))}function an(e){return null===e||(e.type===en.RightParenthesis||e.type===en.RightSquareBracket||e.type===en.RightCurlyBracket||e.type===en.Delim)}function on(e,t,n){function r(){do{b++,f=by&&(y=b)}function c(){k=2===k.type?k.prev:{type:3,syntax:u.syntax,token:k.token,prev:k},u=u.prev}var u=null,h=null,p=null,d=null,m=0,g=null,f=null,b=-1,y=0,k={type:0,syntax:null,token:null,prev:null};for(r();null===g&&++m<15e3;)switch(t.type){case"Match":if(null===h){if(null!==f&&(b!==e.length-1||"\\0"!==f.value&&"\\9"!==f.value)){t=$t;break}g="Match";break}if((t=h.nextState)===Jt){if(h.matchStack===k){t=$t;break}t=Zt}for(;h.syntaxStack!==u;)c();h=h.prev;break;case"Mismatch":if(null!==d&&!1!==d)(null===p||b>p.tokenIndex)&&(p=d,d=!1);else if(null===p){g="Mismatch";break}t=p.nextState,h=p.thenStack,u=p.syntaxStack,k=p.matchStack,b=p.tokenIndex,f=bb){for(;b":"<'"+t.name+"'>"));if(!1!==d&&null!==f&&"Type"===t.type)if("custom-ident"===t.name&&f.type===en.Ident||"length"===t.name&&"0"===f.value){null===d&&(d=a(t,p)),t=$t;break}u={syntax:t.syntax,opts:t.syntax.opts||null!==u&&u.opts||null,prev:u},k={type:2,syntax:t.syntax,token:k.token,prev:k},t=z.match;break;case"Keyword":var A=t.name;if(null!==f){var P=f.value;if(-1!==P.indexOf("\\")&&(P=P.replace(/\\[09].*$/,"")),nn(P,A)){l(),t=Zt;break}}t=$t;break;case"AtKeyword":case"Function":if(null!==f&&nn(f.value,t.name)){l(),t=Zt;break}t=$t;break;case"Token":if(null!==f&&f.value===t.value){l(),t=Zt;break}t=$t;break;case"Comma":null!==f&&f.type===en.Comma?rn(k.token)?t=$t:(l(),t=an(f)?$t:Zt):t=rn(k.token)||an(f)?Zt:$t;break;case"String":var T="";for(S=b;S=0}function mn(e){return Boolean(e)&&dn(e.offset)&&dn(e.line)&&dn(e.column)}function gn(e,t){return function(n,r){if(!n||n.constructor!==Object)return r(n,"Type of node should be an Object");for(var i in n){var o=!0;if(!1!==pn.call(n,i)){if("type"===i)n.type!==e&&r(n,"Wrong node type `"+n.type+"`, expected `"+e+"`");else if("loc"===i){if(null===n.loc)continue;if(n.loc&&n.loc.constructor===Object)if("string"!=typeof n.loc.source)i+=".source";else if(mn(n.loc.start)){if(mn(n.loc.end))continue;i+=".end"}else i+=".start";o=!1}else if(t.hasOwnProperty(i)){var s=0;for(o=!1;!o&&s");else{if(!Array.isArray(c))throw new Error("Wrong value `"+c+"` in `"+e+"."+a+"` structure definition");o.push("List")}}i[a]=o.join(" | ")}return{docs:i,check:gn(e,r)}}var bn=$,yn=J,kn=Qt,vn=sn,xn=function(e){var t={};if(e.node)for(var n in e.node)if(pn.call(e.node,n)){var r=e.node[n];if(!r.structure)throw new Error("Missed `structure` field in `"+n+"` node type definition");t[n]=fn(n,r)}return t},wn=kn("inherit | initial | unset"),Sn=kn("inherit | initial | unset | <-ms-legacy-expression>");function Cn(e,t,n){var r={};for(var i in e)e[i].syntax&&(r[i]=n?e[i].syntax:G(e[i].syntax,{compact:t}));return r}function zn(e,t,n){const r={};for(const[i,a]of Object.entries(e))r[i]={prelude:a.prelude&&(n?a.prelude.syntax:G(a.prelude.syntax,{compact:t})),descriptors:a.descriptors&&Cn(a.descriptors,t,n)};return r}function An(e,t,n){return{matched:e,iterations:n,error:t,getTrace:un.getTrace,isType:un.isType,isProperty:un.isProperty,isKeyword:un.isKeyword}}function Pn(e,t,n,r){var i,a=function(e,t){return"string"==typeof e?jt(e,null):t.generate(e,Mt)}(n,e.syntax);return function(e){for(var t=0;t(n[r]=this.createDescriptor(t.descriptors[r],"AtruleDescriptor",r,e),n)),{}):null})},addProperty_:function(e,t){t&&(this.properties[e]=this.createDescriptor(t,"Property",e))},addType_:function(e,t){t&&(this.types[e]=this.createDescriptor(t,"Type",e),t===mt["-ms-legacy-expression"]&&(this.valueCommonSyntax=Sn))},checkAtruleName:function(e){if(!this.getAtrule(e))return new bn("Unknown at-rule","@"+e)},checkAtrulePrelude:function(e,t){let n=this.checkAtruleName(e);if(n)return n;var r=this.getAtrule(e);return!r.prelude&&t?new SyntaxError("At-rule `@"+e+"` should not contain a prelude"):r.prelude&&!t?new SyntaxError("At-rule `@"+e+"` should contain a prelude"):void 0},checkAtruleDescriptorName:function(e,t){let n=this.checkAtruleName(e);if(n)return n;var r=this.getAtrule(e),i=ae.keyword(t);return r.descriptors?r.descriptors[i.name]||r.descriptors[i.basename]?void 0:new bn("Unknown at-rule descriptor",t):new SyntaxError("At-rule `@"+e+"` has no known descriptors")},checkPropertyName:function(e){return ae.property(e).custom?new Error("Lexer matching doesn't applicable for custom properties"):this.getProperty(e)?void 0:new bn("Unknown property",e)},matchAtrulePrelude:function(e,t){var n=this.checkAtrulePrelude(e,t);return n?An(null,n):t?Pn(this,this.getAtrule(e).prelude,t,!1):An(null,null)},matchAtruleDescriptor:function(e,t,n){var r=this.checkAtruleDescriptorName(e,t);if(r)return An(null,r);var i=this.getAtrule(e),a=ae.keyword(t);return Pn(this,i.descriptors[a.name]||i.descriptors[a.basename],n,!1)},matchDeclaration:function(e){return"Declaration"!==e.type?An(null,new Error("Not a Declaration node")):this.matchProperty(e.property,e.value)},matchProperty:function(e,t){var n=this.checkPropertyName(e);return n?An(null,n):Pn(this,this.getProperty(e),t,!0)},matchType:function(e,t){var n=this.getType(e);return n?Pn(this,n,t,!1):An(null,new bn("Unknown type",e))},match:function(e,t){return"string"==typeof e||e&&e.type?("string"!=typeof e&&e.match||(e=this.createDescriptor(e,"Type","anonymous")),Pn(this,e,t,!1)):An(null,new bn("Bad syntax"))},findValueFragments:function(e,t,n,r){return hn.matchFragments(this,t,this.matchProperty(e,t),n,r)},findDeclarationValueFragments:function(e,t,n){return hn.matchFragments(this,e.value,this.matchDeclaration(e),t,n)},findAllFragments:function(e,t,n){var r=[];return this.syntax.walk(e,{visit:"Declaration",enter:function(e){r.push.apply(r,this.findDeclarationValueFragments(e,t,n))}.bind(this)}),r},getAtrule:function(e,t=!0){var n=ae.keyword(e);return(n.vendor&&t?this.atrules[n.name]||this.atrules[n.basename]:this.atrules[n.name])||null},getAtrulePrelude:function(e,t=!0){const n=this.getAtrule(e,t);return n&&n.prelude||null},getAtruleDescriptor:function(e,t){return this.atrules.hasOwnProperty(e)&&this.atrules.declarators&&this.atrules[e].declarators[t]||null},getProperty:function(e,t=!0){var n=ae.property(e);return(n.vendor&&t?this.properties[n.name]||this.properties[n.basename]:this.properties[n.name])||null},getType:function(e){return this.types.hasOwnProperty(e)?this.types[e]:null},validate:function(){function e(r,i,a,o){if(a.hasOwnProperty(i))return a[i];a[i]=!1,null!==o.syntax&&Nt(o.syntax,(function(o){if("Type"===o.type||"Property"===o.type){var s="Type"===o.type?r.types:r.properties,l="Type"===o.type?t:n;s.hasOwnProperty(o.name)&&!e(r,o.name,l,s[o.name])||(a[i]=!0)}}),this)}var t={},n={};for(var r in this.types)e(this,r,t,this.types[r]);for(var r in this.properties)e(this,r,n,this.properties[r]);return t=Object.keys(t).filter((function(e){return t[e]})),n=Object.keys(n).filter((function(e){return n[e]})),t.length||n.length?{types:t,properties:n}:null},dump:function(e,t){return{generic:this.generic,types:Cn(this.types,!t,e),properties:Cn(this.properties,!t,e),atrules:zn(this.atrules,!t,e)}},toString:function(){return JSON.stringify(this.dump())}};var Ln=Tn,En={SyntaxError:gt,parse:Ot,generate:G,walk:Nt},Dn=Ce.isBOM;var On=function(){this.lines=null,this.columns=null,this.linesAndColumnsComputed=!1};On.prototype={setSource:function(e,t,n,r){this.source=e,this.startOffset=void 0===t?0:t,this.startLine=void 0===n?1:n,this.startColumn=void 0===r?1:r,this.linesAndColumnsComputed=!1},ensureLinesAndColumnsComputed:function(){this.linesAndColumnsComputed||(!function(e,t){for(var n=t.length,r=se(e.lines,n),i=e.startLine,a=se(e.columns,n),o=e.startColumn,s=t.length>0?Dn(t.charCodeAt(0)):0;s",needPositions:!1,onParseError:Fn,onParseErrorThrow:!1,parseAtrulePrelude:!0,parseRulePrelude:!0,parseValue:!0,parseCustomProperty:!1,readSequence:Mn,createList:function(){return new a},createSingleNodeList:function(e){return(new a).appendData(e)},getFirstListNode:function(e){return e&&e.first()},getLastListNode:function(e){return e.last()},parseWithFallback:function(e,t){var n=this.scanner.tokenIndex;try{return e.call(this)}catch(e){if(this.onParseErrorThrow)throw e;var r=t.call(this,n);return this.onParseErrorThrow=!0,this.onParseError(e,r),this.onParseErrorThrow=!1,r}},lookupNonWSType:function(e){do{var t=this.scanner.lookupType(e++);if(t!==Yn)return t}while(0!==t);return 0},eat:function(e){if(this.scanner.tokenType!==e){var t=this.scanner.tokenStart,n=qn[e]+" is expected";switch(e){case Hn:this.scanner.tokenType===Vn||this.scanner.tokenType===Kn?(t=this.scanner.tokenEnd-1,n="Identifier is expected but function found"):n="Identifier is expected";break;case Gn:this.scanner.isDelim(35)&&(this.scanner.next(),t++,n="Name is expected");break;case Qn:this.scanner.tokenType===Xn&&(t=this.scanner.tokenEnd,n="Percent sign is expected");break;default:this.scanner.source.charCodeAt(this.scanner.tokenStart)===e&&(t+=1)}this.error(n,t)}this.scanner.next()},consume:function(e){var t=this.scanner.getTokenValue();return this.eat(e),t},consumeFunctionName:function(){var e=this.scanner.source.substring(this.scanner.tokenStart,this.scanner.tokenEnd-1);return this.eat(Vn),e},getLocation:function(e,t){return this.needPositions?this.locationMap.getLocationRange(e,t,this.filename):null},getLocationFromList:function(e){if(this.needPositions){var t=this.getFirstListNode(e),n=this.getLastListNode(e);return this.locationMap.getLocationRange(null!==t?t.loc.start.offset-this.locationMap.startOffset:this.scanner.tokenStart,null!==n?n.loc.end.offset-this.locationMap.startOffset:this.scanner.tokenStart,this.filename)}return null},error:function(e,t){var n=void 0!==t&&t",t.needPositions=Boolean(n.positions),t.onParseError="function"==typeof n.onParseError?n.onParseError:Fn,t.onParseErrorThrow=!1,t.parseAtrulePrelude=!("parseAtrulePrelude"in n)||Boolean(n.parseAtrulePrelude),t.parseRulePrelude=!("parseRulePrelude"in n)||Boolean(n.parseRulePrelude),t.parseValue=!("parseValue"in n)||Boolean(n.parseValue),t.parseCustomProperty="parseCustomProperty"in n&&Boolean(n.parseCustomProperty),!t.context.hasOwnProperty(i))throw new Error("Unknown context `"+i+"`");return"function"==typeof a&&t.scanner.forEachToken(((n,r,i)=>{if(n===Un){const n=t.getLocation(r,i),o=_n(e,i-2,i,"*/")?e.slice(r+2,i-2):e.slice(r+2,i);a(o,n)}})),r=t.context[i].call(t,n),t.scanner.eof||t.error(),r}},Jn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),er=function(e){if(0<=e&&e>>=5)>0&&(t|=32),n+=er(t)}while(r>0);return n};var nr=function(e,t){return e(t={exports:{}},t.exports),t.exports}((function(e,t){t.getArg=function(e,t,n){if(t in e)return e[t];if(3===arguments.length)return n;throw new Error('"'+t+'" is a required argument.')};var n=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,r=/^data:.+\,.+$/;function i(e){var t=e.match(n);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}function a(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}function o(e){var n=e,r=i(e);if(r){if(!r.path)return e;n=r.path}for(var o,s=t.isAbsolute(n),l=n.split(/\/+/),c=0,u=l.length-1;u>=0;u--)"."===(o=l[u])?l.splice(u,1):".."===o?c++:c>0&&(""===o?(l.splice(u+1,c),c=0):(l.splice(u,2),c--));return""===(n=l.join("/"))&&(n=s?"/":"."),r?(r.path=n,a(r)):n}function s(e,t){""===e&&(e="."),""===t&&(t=".");var n=i(t),s=i(e);if(s&&(e=s.path||"/"),n&&!n.scheme)return s&&(n.scheme=s.scheme),a(n);if(n||t.match(r))return t;if(s&&!s.host&&!s.path)return s.host=t,a(s);var l="/"===t.charAt(0)?t:o(e.replace(/\/+$/,"")+"/"+t);return s?(s.path=l,a(s)):l}t.urlParse=i,t.urlGenerate=a,t.normalize=o,t.join=s,t.isAbsolute=function(e){return"/"===e.charAt(0)||n.test(e)},t.relative=function(e,t){""===e&&(e="."),e=e.replace(/\/$/,"");for(var n=0;0!==t.indexOf(e+"/");){var r=e.lastIndexOf("/");if(r<0)return t;if((e=e.slice(0,r)).match(/^([^\/]+:\/)?\/*$/))return t;++n}return Array(n+1).join("../")+t.substr(e.length+1)};var l=!("__proto__"in Object.create(null));function c(e){return e}function u(e){if(!e)return!1;var t=e.length;if(t<9)return!1;if(95!==e.charCodeAt(t-1)||95!==e.charCodeAt(t-2)||111!==e.charCodeAt(t-3)||116!==e.charCodeAt(t-4)||111!==e.charCodeAt(t-5)||114!==e.charCodeAt(t-6)||112!==e.charCodeAt(t-7)||95!==e.charCodeAt(t-8)||95!==e.charCodeAt(t-9))return!1;for(var n=t-10;n>=0;n--)if(36!==e.charCodeAt(n))return!1;return!0}function h(e,t){return e===t?0:null===e?1:null===t?-1:e>t?1:-1}t.toSetString=l?c:function(e){return u(e)?"$"+e:e},t.fromSetString=l?c:function(e){return u(e)?e.slice(1):e},t.compareByOriginalPositions=function(e,t,n){var r=h(e.source,t.source);return 0!==r||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)||n||0!==(r=e.generatedColumn-t.generatedColumn)||0!==(r=e.generatedLine-t.generatedLine)?r:h(e.name,t.name)},t.compareByGeneratedPositionsDeflated=function(e,t,n){var r=e.generatedLine-t.generatedLine;return 0!==r||0!==(r=e.generatedColumn-t.generatedColumn)||n||0!==(r=h(e.source,t.source))||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)?r:h(e.name,t.name)},t.compareByGeneratedPositionsInflated=function(e,t){var n=e.generatedLine-t.generatedLine;return 0!==n||0!==(n=e.generatedColumn-t.generatedColumn)||0!==(n=h(e.source,t.source))||0!==(n=e.originalLine-t.originalLine)||0!==(n=e.originalColumn-t.originalColumn)?n:h(e.name,t.name)},t.parseSourceMapInput=function(e){return JSON.parse(e.replace(/^\)]}'[^\n]*\n/,""))},t.computeSourceURL=function(e,t,n){if(t=t||"",e&&("/"!==e[e.length-1]&&"/"!==t[0]&&(e+="/"),t=e+t),n){var r=i(n);if(!r)throw new Error("sourceMapURL could not be parsed");if(r.path){var l=r.path.lastIndexOf("/");l>=0&&(r.path=r.path.substring(0,l+1))}t=s(a(r),t)}return o(t)}})),rr=(nr.getArg,nr.urlParse,nr.urlGenerate,nr.normalize,nr.join,nr.isAbsolute,nr.relative,nr.toSetString,nr.fromSetString,nr.compareByOriginalPositions,nr.compareByGeneratedPositionsDeflated,nr.compareByGeneratedPositionsInflated,nr.parseSourceMapInput,nr.computeSourceURL,Object.prototype.hasOwnProperty),ir="undefined"!=typeof Map;function ar(){this._array=[],this._set=ir?new Map:Object.create(null)}ar.fromArray=function(e,t){for(var n=new ar,r=0,i=e.length;r=0)return t}else{var n=nr.toSetString(e);if(rr.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')},ar.prototype.at=function(e){if(e>=0&&er||i==r&&o>=a||nr.compareByGeneratedPositionsInflated(t,n)<=0?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))},sr.prototype.toArray=function(){return this._sorted||(this._array.sort(nr.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};var lr=or.ArraySet,cr={MappingList:sr}.MappingList;function ur(e){e||(e={}),this._file=nr.getArg(e,"file",null),this._sourceRoot=nr.getArg(e,"sourceRoot",null),this._skipValidation=nr.getArg(e,"skipValidation",!1),this._sources=new lr,this._names=new lr,this._mappings=new cr,this._sourcesContents=null}ur.prototype._version=3,ur.fromSourceMap=function(e){var t=e.sourceRoot,n=new ur({file:e.file,sourceRoot:t});return e.eachMapping((function(e){var r={generated:{line:e.generatedLine,column:e.generatedColumn}};null!=e.source&&(r.source=e.source,null!=t&&(r.source=nr.relative(t,r.source)),r.original={line:e.originalLine,column:e.originalColumn},null!=e.name&&(r.name=e.name)),n.addMapping(r)})),e.sources.forEach((function(r){var i=r;null!==t&&(i=nr.relative(t,r)),n._sources.has(i)||n._sources.add(i);var a=e.sourceContentFor(r);null!=a&&n.setSourceContent(r,a)})),n},ur.prototype.addMapping=function(e){var t=nr.getArg(e,"generated"),n=nr.getArg(e,"original",null),r=nr.getArg(e,"source",null),i=nr.getArg(e,"name",null);this._skipValidation||this._validateMapping(t,n,r,i),null!=r&&(r=String(r),this._sources.has(r)||this._sources.add(r)),null!=i&&(i=String(i),this._names.has(i)||this._names.add(i)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:null!=n&&n.line,originalColumn:null!=n&&n.column,source:r,name:i})},ur.prototype.setSourceContent=function(e,t){var n=e;null!=this._sourceRoot&&(n=nr.relative(this._sourceRoot,n)),null!=t?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[nr.toSetString(n)]=t):this._sourcesContents&&(delete this._sourcesContents[nr.toSetString(n)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},ur.prototype.applySourceMap=function(e,t,n){var r=t;if(null==t){if(null==e.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');r=e.file}var i=this._sourceRoot;null!=i&&(r=nr.relative(i,r));var a=new lr,o=new lr;this._mappings.unsortedForEach((function(t){if(t.source===r&&null!=t.originalLine){var s=e.originalPositionFor({line:t.originalLine,column:t.originalColumn});null!=s.source&&(t.source=s.source,null!=n&&(t.source=nr.join(n,t.source)),null!=i&&(t.source=nr.relative(i,t.source)),t.originalLine=s.line,t.originalColumn=s.column,null!=s.name&&(t.name=s.name))}var l=t.source;null==l||a.has(l)||a.add(l);var c=t.name;null==c||o.has(c)||o.add(c)}),this),this._sources=a,this._names=o,e.sources.forEach((function(t){var r=e.sourceContentFor(t);null!=r&&(null!=n&&(t=nr.join(n,t)),null!=i&&(t=nr.relative(i,t)),this.setSourceContent(t,r))}),this)},ur.prototype._validateMapping=function(e,t,n,r){if(t&&"number"!=typeof t.line&&"number"!=typeof t.column)throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if((!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0)||t||n||r)&&!(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&n))throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:t,name:r}))},ur.prototype._serializeMappings=function(){for(var e,t,n,r,i=0,a=1,o=0,s=0,l=0,c=0,u="",h=this._mappings.toArray(),p=0,d=h.length;p0){if(!nr.compareByGeneratedPositionsInflated(t,h[p-1]))continue;e+=","}e+=tr(t.generatedColumn-i),i=t.generatedColumn,null!=t.source&&(r=this._sources.indexOf(t.source),e+=tr(r-c),c=r,e+=tr(t.originalLine-1-s),s=t.originalLine-1,e+=tr(t.originalColumn-o),o=t.originalColumn,null!=t.name&&(n=this._names.indexOf(t.name),e+=tr(n-l),l=n)),u+=e}return u},ur.prototype._generateSourcesContent=function(e,t){return e.map((function(e){if(!this._sourcesContents)return null;null!=t&&(e=nr.relative(t,e));var n=nr.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null}),this)},ur.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},ur.prototype.toString=function(){return JSON.stringify(this.toJSON())};var hr={SourceMapGenerator:ur}.SourceMapGenerator,pr={Atrule:!0,Selector:!0,Declaration:!0},dr=Object.prototype.hasOwnProperty;function mr(e,t){var n=e.children,r=null;"function"!=typeof t?n.forEach(this.node,this):n.forEach((function(e){null!==r&&t.call(this,r),this.node(e),r=e}),this)}var gr=function(e){function t(e){if(!dr.call(n,e.type))throw new Error("Unknown node type: "+e.type);n[e.type].call(this,e)}var n={};if(e.node)for(var r in e.node)n[r]=e.node[r].generate;return function(e,n){var r="",i={children:mr,node:t,chunk:function(e){r+=e},result:function(){return r}};return n&&("function"==typeof n.decorator&&(i=n.decorator(i)),n.sourceMap&&(i=function(e){var t=new hr,n=1,r=0,i={line:1,column:0},a={line:0,column:0},o=!1,s={line:1,column:0},l={generated:s},c=e.node;e.node=function(e){if(e.loc&&e.loc.start&&pr.hasOwnProperty(e.type)){var u=e.loc.start.line,h=e.loc.start.column-1;a.line===u&&a.column===h||(a.line=u,a.column=h,i.line=n,i.column=r,o&&(o=!1,i.line===s.line&&i.column===s.column||t.addMapping(l)),o=!0,t.addMapping({source:e.loc.source,original:a,generated:i}))}c.call(this,e),o&&pr.hasOwnProperty(e.type)&&(s.line=n,s.column=r)};var u=e.chunk;e.chunk=function(e){for(var t=0;te||c(t,n,r),h=br,p=br,d=n,m={break:i,skip:a,root:e,stylesheet:null,atrule:null,atrulePrelude:null,rule:null,selector:null,block:null,declaration:null,function:null};if("function"==typeof o)h=o;else if(o&&(h=yr(o.enter),p=yr(o.leave),o.reverse&&(d=r),o.visit)){if(s.hasOwnProperty(o.visit))d=o.reverse?l[o.visit]:s[o.visit];else if(!t.hasOwnProperty(o.visit))throw new Error("Bad value `"+o.visit+"` for `visit` option (should be: "+Object.keys(t).join(", ")+")");h=kr(h,o.visit),p=kr(p,o.visit)}if(h===br&&p===br)throw new Error("Neither `enter` nor `leave` walker handler is set or both aren't a function");c(e)};return c.break=i,c.skip=a,c.find=function(e,t){var n=null;return c(e,(function(e,r,a){if(t.call(this,e,r,a))return n=e,i})),n},c.findLast=function(e,t){var n=null;return c(e,{reverse:!0,enter:function(e,r,a){if(t.call(this,e,r,a))return n=e,i}}),n},c.findAll=function(e,t){var n=[];return c(e,(function(e,r,i){t.call(this,e,r,i)&&n.push(e)})),n},c},Cr=function e(t){var n={};for(var r in t){var i=t[r];i&&(Array.isArray(i)||i instanceof a?i=i.map(e):i.constructor===Object&&(i=e(i))),n[r]=i}return n};const zr=Object.prototype.hasOwnProperty,Ar={generic:!0,types:Er,atrules:{prelude:Dr,descriptors:Dr},properties:Er,parseContext:function(e,t){return Object.assign(e,t)},scope:function e(t,n){for(const r in n)zr.call(n,r)&&(Pr(t[r])?e(t[r],Tr(n[r])):t[r]=Tr(n[r]));return t},atrule:["parse"],pseudo:["parse"],node:["name","structure","parse","generate","walkContext"]};function Pr(e){return e&&e.constructor===Object}function Tr(e){return Pr(e)?Object.assign({},e):e}function Lr(e,t){return"string"==typeof t&&/^\s*\|/.test(t)?"string"==typeof e?e+t:t.replace(/^\s*\|\s*/,""):t||null}function Er(e,t){if("string"==typeof t)return Lr(e,t);const n=Object.assign({},e);for(let r in t)zr.call(t,r)&&(n[r]=Lr(zr.call(e,r)?e[r]:void 0,t[r]));return n}function Dr(e,t){const n=Er(e,t);return!Pr(n)||Object.keys(n).length?n:null}var Or=(e,t)=>function e(t,n,r){for(const i in r)if(!1!==zr.call(r,i))if(!0===r[i])i in n&&zr.call(n,i)&&(t[i]=Tr(n[i]));else if(r[i])if("function"==typeof r[i]){const e=r[i];t[i]=e({},t[i]),t[i]=e(t[i]||{},n[i])}else if(Pr(r[i])){const a={};for(let n in t[i])a[n]=e({},t[i][n],r[i]);for(let t in n[i])a[t]=e(a[t]||{},n[i][t],r[i]);t[i]=a}else if(Array.isArray(r[i])){const a={},o=r[i].reduce((function(e,t){return e[t]=!0,e}),{});for(const[n,r]of Object.entries(t[i]||{}))a[n]={},r&&e(a[n],r,o);for(const t in n[i])zr.call(n[i],t)&&(a[t]||(a[t]={}),n[i]&&n[i][t]&&e(a[t],n[i][t],o));t[i]=a}return t}(e,t,Ar);function Br(e){var t=$n(e),n=Sr(e),r=gr(e),i=function(e){return{fromPlainObject:function(t){return e(t,{enter:function(e){e.children&&e.children instanceof a==!1&&(e.children=(new a).fromArray(e.children))}}),t},toPlainObject:function(t){return e(t,{leave:function(e){e.children&&e.children instanceof a&&(e.children=e.children.toArray())}}),t}}}(n),o={List:a,SyntaxError:l,TokenStream:H,Lexer:Ln,vendorPrefix:ae.vendorPrefix,keyword:ae.keyword,property:ae.property,isCustomProperty:ae.isCustomProperty,definitionSyntax:En,lexer:null,createLexer:function(e){return new Ln(e,o,o.lexer.structure)},tokenize:Ce,parse:t,walk:n,generate:r,find:n.find,findLast:n.findLast,findAll:n.findAll,clone:Cr,fromPlainObject:i.fromPlainObject,toPlainObject:i.toPlainObject,createSyntax:function(e){return Br(Or({},e))},fork:function(t){var n=Or({},e);return Br("function"==typeof t?t(n,Object.assign):Or(n,t))}};return o.lexer=new Ln({generic:!0,types:e.types,atrules:e.atrules,properties:e.properties,node:e.node},o),o}var Ir=function(e){return Br(Or({},e))},Nr={generic:!0,types:{"absolute-size":"xx-small|x-small|small|medium|large|x-large|xx-large|xxx-large","alpha-value":"|","angle-percentage":"|","angular-color-hint":"","angular-color-stop":"&&?","angular-color-stop-list":"[ [, ]?]# , ","animateable-feature":"scroll-position|contents|",attachment:"scroll|fixed|local","attr()":"attr( ? [, ]? )","attr-matcher":"['~'|'|'|'^'|'$'|'*']? '='","attr-modifier":"i|s","attribute-selector":"'[' ']'|'[' [|] ? ']'","auto-repeat":"repeat( [auto-fill|auto-fit] , [? ]+ ? )","auto-track-list":"[? [|]]* ? [? [|]]* ?","baseline-position":"[first|last]? baseline","basic-shape":"||||","bg-image":"none|","bg-layer":"|| [/ ]?||||||||","bg-position":"[[left|center|right|top|bottom|]|[left|center|right|] [top|center|bottom|]|[center|[left|right] ?]&&[center|[top|bottom] ?]]","bg-size":"[|auto]{1,2}|cover|contain","blur()":"blur( )","blend-mode":"normal|multiply|screen|overlay|darken|lighten|color-dodge|color-burn|hard-light|soft-light|difference|exclusion|hue|saturation|color|luminosity",box:"border-box|padding-box|content-box","brightness()":"brightness( )","calc()":"calc( )","calc-sum":" [['+'|'-'] ]*","calc-product":" ['*' |'/' ]*","calc-value":"|||( )","cf-final-image":"|","cf-mixing-image":"?&&","circle()":"circle( []? [at ]? )","clamp()":"clamp( #{3} )","class-selector":"'.' ","clip-source":"",color:"||||||currentcolor|","color-stop":"|","color-stop-angle":"{1,2}","color-stop-length":"{1,2}","color-stop-list":"[ [, ]?]# , ",combinator:"'>'|'+'|'~'|['||']","common-lig-values":"[common-ligatures|no-common-ligatures]","compat-auto":"searchfield|textarea|push-button|slider-horizontal|checkbox|radio|square-button|menulist|listbox|meter|progress-bar|button","composite-style":"clear|copy|source-over|source-in|source-out|source-atop|destination-over|destination-in|destination-out|destination-atop|xor","compositing-operator":"add|subtract|intersect|exclude","compound-selector":"[? * [ *]*]!","compound-selector-list":"#","complex-selector":" [? ]*","complex-selector-list":"#","conic-gradient()":"conic-gradient( [from ]? [at ]? , )","contextual-alt-values":"[contextual|no-contextual]","content-distribution":"space-between|space-around|space-evenly|stretch","content-list":"[|contents||||||counter( , <'list-style-type'>? )]+","content-position":"center|start|end|flex-start|flex-end","content-replacement":"","contrast()":"contrast( [] )","counter()":"counter( , ? )","counter-style":"|symbols( )","counter-style-name":"","counters()":"counters( , , ? )","cross-fade()":"cross-fade( , ? )","cubic-bezier-timing-function":"ease|ease-in|ease-out|ease-in-out|cubic-bezier( , , , )","deprecated-system-color":"ActiveBorder|ActiveCaption|AppWorkspace|Background|ButtonFace|ButtonHighlight|ButtonShadow|ButtonText|CaptionText|GrayText|Highlight|HighlightText|InactiveBorder|InactiveCaption|InactiveCaptionText|InfoBackground|InfoText|Menu|MenuText|Scrollbar|ThreeDDarkShadow|ThreeDFace|ThreeDHighlight|ThreeDLightShadow|ThreeDShadow|Window|WindowFrame|WindowText","discretionary-lig-values":"[discretionary-ligatures|no-discretionary-ligatures]","display-box":"contents|none","display-inside":"flow|flow-root|table|flex|grid|ruby","display-internal":"table-row-group|table-header-group|table-footer-group|table-row|table-cell|table-column-group|table-column|table-caption|ruby-base|ruby-text|ruby-base-container|ruby-text-container","display-legacy":"inline-block|inline-list-item|inline-table|inline-flex|inline-grid","display-listitem":"?&&[flow|flow-root]?&&list-item","display-outside":"block|inline|run-in","drop-shadow()":"drop-shadow( {2,3} ? )","east-asian-variant-values":"[jis78|jis83|jis90|jis04|simplified|traditional]","east-asian-width-values":"[full-width|proportional-width]","element()":"element( , [first|start|last|first-except]? )|element( )","ellipse()":"ellipse( [{2}]? [at ]? )","ending-shape":"circle|ellipse","env()":"env( , ? )","explicit-track-list":"[? ]+ ?","family-name":"|+","feature-tag-value":" [|on|off]?","feature-type":"@stylistic|@historical-forms|@styleset|@character-variant|@swash|@ornaments|@annotation","feature-value-block":" '{' '}'","feature-value-block-list":"+","feature-value-declaration":" : + ;","feature-value-declaration-list":"","feature-value-name":"","fill-rule":"nonzero|evenodd","filter-function":"|||||||||","filter-function-list":"[|]+","final-bg-layer":"<'background-color'>|||| [/ ]?||||||||","fit-content()":"fit-content( [|] )","fixed-breadth":"","fixed-repeat":"repeat( [] , [? ]+ ? )","fixed-size":"|minmax( , )|minmax( , )","font-stretch-absolute":"normal|ultra-condensed|extra-condensed|condensed|semi-condensed|semi-expanded|expanded|extra-expanded|ultra-expanded|","font-variant-css21":"[normal|small-caps]","font-weight-absolute":"normal|bold|","frequency-percentage":"|","general-enclosed":"[ )]|( )","generic-family":"serif|sans-serif|cursive|fantasy|monospace|-apple-system","generic-name":"serif|sans-serif|cursive|fantasy|monospace","geometry-box":"|fill-box|stroke-box|view-box",gradient:"|||||<-legacy-gradient>","grayscale()":"grayscale( )","grid-line":"auto||[&&?]|[span&&[||]]","historical-lig-values":"[historical-ligatures|no-historical-ligatures]","hsl()":"hsl( [/ ]? )|hsl( , , , ? )","hsla()":"hsla( [/ ]? )|hsla( , , , ? )",hue:"|","hue-rotate()":"hue-rotate( )",image:"||||||","image()":"image( ? [? , ?]! )","image-set()":"image-set( # )","image-set-option":"[|] ","image-src":"|","image-tags":"ltr|rtl","inflexible-breadth":"||min-content|max-content|auto","inset()":"inset( {1,4} [round <'border-radius'>]? )","invert()":"invert( )","keyframes-name":"|","keyframe-block":"# { }","keyframe-block-list":"+","keyframe-selector":"from|to|","leader()":"leader( )","leader-type":"dotted|solid|space|","length-percentage":"|","line-names":"'[' * ']'","line-name-list":"[|]+","line-style":"none|hidden|dotted|dashed|solid|double|groove|ridge|inset|outset","line-width":"|thin|medium|thick","linear-color-hint":"","linear-color-stop":" ?","linear-gradient()":"linear-gradient( [|to ]? , )","mask-layer":"|| [/ ]?||||||[|no-clip]||||","mask-position":"[|left|center|right] [|top|center|bottom]?","mask-reference":"none||","mask-source":"","masking-mode":"alpha|luminance|match-source","matrix()":"matrix( #{6} )","matrix3d()":"matrix3d( #{16} )","max()":"max( # )","media-and":" [and ]+","media-condition":"|||","media-condition-without-or":"||","media-feature":"( [||] )","media-in-parens":"( )||","media-not":"not ","media-or":" [or ]+","media-query":"|[not|only]? [and ]?","media-query-list":"#","media-type":"","mf-boolean":"","mf-name":"","mf-plain":" : ","mf-range":" ['<'|'>']? '='? | ['<'|'>']? '='? | '<' '='? '<' '='? | '>' '='? '>' '='? ","mf-value":"|||","min()":"min( # )","minmax()":"minmax( [||min-content|max-content|auto] , [|||min-content|max-content|auto] )","named-color":"transparent|aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen|<-non-standard-color>","namespace-prefix":"","ns-prefix":"[|'*']? '|'","number-percentage":"|","numeric-figure-values":"[lining-nums|oldstyle-nums]","numeric-fraction-values":"[diagonal-fractions|stacked-fractions]","numeric-spacing-values":"[proportional-nums|tabular-nums]",nth:"|even|odd","opacity()":"opacity( [] )","overflow-position":"unsafe|safe","outline-radius":"|","page-body":"? [; ]?| ","page-margin-box":" '{' '}'","page-margin-box-type":"@top-left-corner|@top-left|@top-center|@top-right|@top-right-corner|@bottom-left-corner|@bottom-left|@bottom-center|@bottom-right|@bottom-right-corner|@left-top|@left-middle|@left-bottom|@right-top|@right-middle|@right-bottom","page-selector-list":"[#]?","page-selector":"+| *","path()":"path( [ ,]? )","paint()":"paint( , ? )","perspective()":"perspective( )","polygon()":"polygon( ? , [ ]# )",position:"[[left|center|right]||[top|center|bottom]|[left|center|right|] [top|center|bottom|]?|[[left|right] ]&&[[top|bottom] ]]","pseudo-class-selector":"':' |':' ')'","pseudo-element-selector":"':' ","pseudo-page":": [left|right|first|blank]",quote:"open-quote|close-quote|no-open-quote|no-close-quote","radial-gradient()":"radial-gradient( [||]? [at ]? , )","relative-selector":"? ","relative-selector-list":"#","relative-size":"larger|smaller","repeat-style":"repeat-x|repeat-y|[repeat|space|round|no-repeat]{1,2}","repeating-linear-gradient()":"repeating-linear-gradient( [|to ]? , )","repeating-radial-gradient()":"repeating-radial-gradient( [||]? [at ]? , )","rgb()":"rgb( {3} [/ ]? )|rgb( {3} [/ ]? )|rgb( #{3} , ? )|rgb( #{3} , ? )","rgba()":"rgba( {3} [/ ]? )|rgba( {3} [/ ]? )|rgba( #{3} , ? )|rgba( #{3} , ? )","rotate()":"rotate( [|] )","rotate3d()":"rotate3d( , , , [|] )","rotateX()":"rotateX( [|] )","rotateY()":"rotateY( [|] )","rotateZ()":"rotateZ( [|] )","saturate()":"saturate( )","scale()":"scale( , ? )","scale3d()":"scale3d( , , )","scaleX()":"scaleX( )","scaleY()":"scaleY( )","scaleZ()":"scaleZ( )","self-position":"center|start|end|self-start|self-end|flex-start|flex-end","shape-radius":"|closest-side|farthest-side","skew()":"skew( [|] , [|]? )","skewX()":"skewX( [|] )","skewY()":"skewY( [|] )","sepia()":"sepia( )",shadow:"inset?&&{2,4}&&?","shadow-t":"[{2,3}&&?]",shape:"rect( , , , )|rect( )","shape-box":"|margin-box","side-or-corner":"[left|right]||[top|bottom]","single-animation":"