agent-device
Version:
Open source device layer for AI coding agents: a CLI, MCP server, and typed Node.js API to control mobile, web, TV, and desktop apps on devices and simulators, locally or in the cloud.
9 lines • 150 kB
JavaScript
import{t as e}from"./rolldown-runtime.js";var t=e((e=>{function t(e,t,n){if(n===void 0&&(n=Array.prototype),e&&typeof n.find==`function`)return n.find.call(e,t);for(var i=0;i<e.length;i++)if(r(e,i)){var a=e[i];if(t.call(void 0,a,i,e))return a}}function n(e,t){return t===void 0&&(t=Object),t&&typeof t.getOwnPropertyDescriptors==`function`&&(e=t.create(null,t.getOwnPropertyDescriptors(e))),t&&typeof t.freeze==`function`?t.freeze(e):e}function r(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function i(e,t){if(typeof e!=`object`||!e)throw TypeError(`target is not an object`);for(var n in t)r(t,n)&&(e[n]=t[n]);return e}var a=n({allowfullscreen:!0,async:!0,autofocus:!0,autoplay:!0,checked:!0,controls:!0,default:!0,defer:!0,disabled:!0,formnovalidate:!0,hidden:!0,ismap:!0,itemscope:!0,loop:!0,multiple:!0,muted:!0,nomodule:!0,novalidate:!0,open:!0,playsinline:!0,readonly:!0,required:!0,reversed:!0,selected:!0});function o(e){return r(a,e.toLowerCase())}var s=n({area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function c(e){return r(s,e.toLowerCase())}var l=n({script:!1,style:!1,textarea:!0,title:!0});function u(e){var t=e.toLowerCase();return r(l,t)&&!l[t]}function d(e){var t=e.toLowerCase();return r(l,t)&&l[t]}function f(e){return e===m.HTML}function p(e){return f(e)||e===m.XML_XHTML_APPLICATION}var m=n({HTML:`text/html`,XML_APPLICATION:`application/xml`,XML_TEXT:`text/xml`,XML_XHTML_APPLICATION:`application/xhtml+xml`,XML_SVG_IMAGE:`image/svg+xml`}),h=Object.keys(m).map(function(e){return m[e]});function g(e){return h.indexOf(e)>-1}var _=n({HTML:`http://www.w3.org/1999/xhtml`,SVG:`http://www.w3.org/2000/svg`,XML:`http://www.w3.org/XML/1998/namespace`,XMLNS:`http://www.w3.org/2000/xmlns/`});e.assign=i,e.find=t,e.freeze=n,e.HTML_BOOLEAN_ATTRIBUTES=a,e.HTML_RAW_TEXT_ELEMENTS=l,e.HTML_VOID_ELEMENTS=s,e.hasDefaultHTMLNamespace=p,e.hasOwn=r,e.isHTMLBooleanAttribute=o,e.isHTMLRawTextElement=u,e.isHTMLEscapableRawTextElement=d,e.isHTMLMimeType=f,e.isHTMLVoidElement=c,e.isValidMimeType=g,e.MIME_TYPE=m,e.NAMESPACE=_})),n=e((e=>{var n=t();function r(e,t){e.prototype=Object.create(Error.prototype,{constructor:{value:e},name:{value:e.name,enumerable:!0,writable:t}})}var i=n.freeze({Error:`Error`,IndexSizeError:`IndexSizeError`,DomstringSizeError:`DomstringSizeError`,HierarchyRequestError:`HierarchyRequestError`,WrongDocumentError:`WrongDocumentError`,InvalidCharacterError:`InvalidCharacterError`,NoDataAllowedError:`NoDataAllowedError`,NoModificationAllowedError:`NoModificationAllowedError`,NotFoundError:`NotFoundError`,NotSupportedError:`NotSupportedError`,InUseAttributeError:`InUseAttributeError`,InvalidStateError:`InvalidStateError`,SyntaxError:`SyntaxError`,InvalidModificationError:`InvalidModificationError`,NamespaceError:`NamespaceError`,InvalidAccessError:`InvalidAccessError`,ValidationError:`ValidationError`,TypeMismatchError:`TypeMismatchError`,SecurityError:`SecurityError`,NetworkError:`NetworkError`,AbortError:`AbortError`,URLMismatchError:`URLMismatchError`,QuotaExceededError:`QuotaExceededError`,TimeoutError:`TimeoutError`,InvalidNodeTypeError:`InvalidNodeTypeError`,DataCloneError:`DataCloneError`,EncodingError:`EncodingError`,NotReadableError:`NotReadableError`,UnknownError:`UnknownError`,ConstraintError:`ConstraintError`,DataError:`DataError`,TransactionInactiveError:`TransactionInactiveError`,ReadOnlyError:`ReadOnlyError`,VersionError:`VersionError`,OperationError:`OperationError`,NotAllowedError:`NotAllowedError`,OptOutError:`OptOutError`}),a=Object.keys(i);function o(e){return typeof e==`number`&&e>=1&&e<=25}function s(e){return typeof e==`string`&&e.substring(e.length-i.Error.length)===i.Error}function c(e,t){o(e)?(this.name=a[e],this.message=t||``):(this.message=e,this.name=s(t)?t:i.Error),Error.captureStackTrace&&Error.captureStackTrace(this,c)}r(c,!0),Object.defineProperties(c.prototype,{code:{enumerable:!0,get:function(){var e=a.indexOf(this.name);return o(e)?e:0}}});for(var l={INDEX_SIZE_ERR:1,DOMSTRING_SIZE_ERR:2,HIERARCHY_REQUEST_ERR:3,WRONG_DOCUMENT_ERR:4,INVALID_CHARACTER_ERR:5,NO_DATA_ALLOWED_ERR:6,NO_MODIFICATION_ALLOWED_ERR:7,NOT_FOUND_ERR:8,NOT_SUPPORTED_ERR:9,INUSE_ATTRIBUTE_ERR:10,INVALID_STATE_ERR:11,SYNTAX_ERR:12,INVALID_MODIFICATION_ERR:13,NAMESPACE_ERR:14,INVALID_ACCESS_ERR:15,VALIDATION_ERR:16,TYPE_MISMATCH_ERR:17,SECURITY_ERR:18,NETWORK_ERR:19,ABORT_ERR:20,URL_MISMATCH_ERR:21,QUOTA_EXCEEDED_ERR:22,TIMEOUT_ERR:23,INVALID_NODE_TYPE_ERR:24,DATA_CLONE_ERR:25},u=Object.entries(l),d=0;d<u.length;d++){var f=u[d][0];c[f]=u[d][1]}function p(e,t,n){this.message=e,this.locator=t,this.cause=n,Error.captureStackTrace&&Error.captureStackTrace(this,p)}r(p),e.DOMException=c,e.DOMExceptionName=i,e.ExceptionCode=l,e.ParseError=p})),r=e((e=>{function t(e){try{typeof e!=`function`&&(e=RegExp);var t=new e(`𝌆`,`u`).exec(`𝌆`);return!!t&&t[0].length===2}catch{}return!1}var n=t();function r(e){if(e.source[0]!==`[`)throw Error(e+` can not be used with chars`);return e.source.slice(1,e.source.lastIndexOf(`]`))}function i(e,t){if(e.source[0]!==`[`)throw Error(`/`+e.source+`/ can not be used with chars_without`);if(!t||typeof t!=`string`)throw Error(JSON.stringify(t)+` is not a valid search`);if(e.source.indexOf(t)===-1)throw Error(`"`+t+`" is not is /`+e.source+`/`);if(t===`-`&&e.source.indexOf(t)!==1)throw Error(`"`+t+`" is not at the first postion of /`+e.source+`/`);return new RegExp(e.source.replace(t,``),n?`u`:``)}function a(e){var t=this;return new RegExp(Array.prototype.slice.call(arguments).map(function(e){var n=typeof e==`string`;if(n&&t===void 0&&e===`|`)throw Error("use regg instead of reg to wrap expressions with `|`!");return n?e:e.source}).join(``),n?`u`:``)}function o(e){if(arguments.length===0)throw Error(`no parameters provided`);return a.apply(o,[`(?:`].concat(Array.prototype.slice.call(arguments),[`)`]))}var s=`�`,c=/[-\x09\x0A\x0D\x20-\x2C\x2E-\uD7FF\uE000-\uFFFD]/;n&&(c=a(`[`,r(c),`\\u{10000}-\\u{10FFFF}`,`]`));var l=RegExp(`[^`+r(c)+`]`,n?`u`:``),u=/[\x20\x09\x0D\x0A]/,d=r(u),f=a(u,`+`),p=a(u,`*`),m=/[:_a-zA-Z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/;n&&(m=a(`[`,r(m),`\\u{10000}-\\u{10FFFF}`,`]`));var h=a(`[`,r(m),r(/[-.0-9\xB7]/),r(/[\u0300-\u036F\u203F-\u2040]/),`]`),g=a(m,h,`*`),_=a(`^`,g,`$`),v=a(h,`+`),y=o(a(`&`,g,`;`),`|`,o(/&#[0-9]+;|&#x[0-9a-fA-F]+;/)),b=a(`%`,g,`;`),x=o(a(`"`,o(/[^%&"]/,`|`,b,`|`,y),`*`,`"`),`|`,a(`'`,o(/[^%&']/,`|`,b,`|`,y),`*`,`'`)),S=o(`"`,o(/[^<&"]/,`|`,y),`*`,`"`,`|`,`'`,o(/[^<&']/,`|`,y),`*`,`'`),C=a(i(m,`:`),i(h,`:`),`*`),w=a(`^`,C,`$`),T=a(C,o(`:`,C),`?`),E=a(`^`,T,`$`),D=a(`(`,T,`)`),O=o(/"[^"]*"|'[^']*'/),k=a(/^<\?/,`(`,g,`)`,o(f,`(?!`,u,`)(`,c,`*?)`),`?`,/\?>/),A=/[\x20\x0D\x0Aa-zA-Z0-9-'()+,./:=?;!*#@$_%]/,j=o(`"`,A,`*"`,`|`,`'`,i(A,`'`),`*'`),M=`<!--`,N=`-->`,P=a(M,o(i(c,`-`),`|`,a(`-`,i(c,`-`))),`*`,N),F=`#PCDATA`,I=o(`EMPTY`,`|`,`ANY`,`|`,o(a(/\(/,p,F,o(p,/\|/,p,T),`*`,p,/\)\*/),`|`,a(/\(/,p,F,p,/\)/)),`|`,a(/\([^>]+\)/,/[?*+]?/)),L=a(`<!ELEMENT`,f,o(T,`|`,b),f,o(I,`|`,b),p,`>`),R=a(`<!ATTLIST`,f,g,o(f,g,f,o(/CDATA|ID|IDREF|IDREFS|ENTITY|ENTITIES|NMTOKEN|NMTOKENS/,`|`,o(a(`NOTATION`,f,/\(/,p,g,o(p,/\|/,p,g),`*`,p,/\)/),`|`,a(/\(/,p,v,o(p,/\|/,p,v),`*`,p,/\)/))),f,o(/#REQUIRED|#IMPLIED/,`|`,o(o(`#FIXED`,f),`?`,S))),`*`,p,`>`),z=`about:legacy-compat`,B=o(`"`+z+`"`,`|`,`'`+z+`'`),V=`SYSTEM`,H=`PUBLIC`,U=o(o(V,f,O),`|`,o(H,f,j,f,O)),W=a(`^`,o(o(V,f,`(?<SystemLiteralOnly>`,O,`)`),`|`,o(H,f,`(?<PubidLiteral>`,j,`)`,f,`(?<SystemLiteral>`,O,`)`))),G=a(`^`,j,`$`),K=a(`^`,O,`$`),q=o(x,`|`,o(U,o(f,`NDATA`,f,g),`?`)),ee=`<!ENTITY`,J=o(a(ee,f,g,f,q,p,`>`),`|`,a(ee,f,`%`,f,g,f,o(x,`|`,U),p,`>`)),te=a(`<!NOTATION`,f,g,f,o(U,`|`,a(H,f,j)),p,`>`),ne=a(p,`=`,p),re=/1[.]\d+/,ie=a(f,`version`,ne,o(`'`,re,`'`,`|`,`"`,re,`"`)),ae=/[A-Za-z][-A-Za-z0-9._]*/,oe=a(/^<\?xml/,ie,o(f,`encoding`,ne,o(`"`,ae,`"`,`|`,`'`,ae,`'`)),`?`,o(f,`standalone`,ne,o(`'`,o(`yes`,`|`,`no`),`'`,`|`,`"`,o(`yes`,`|`,`no`),`"`)),`?`,p,/\?>/),Y=`<!DOCTYPE`,se=`<![CDATA[`,ce=`]]>`,X=a(/<!\[CDATA\[/,a(c,`*?`,/\]\]>/));e.chars=r,e.chars_without=i,e.detectUnicodeSupport=t,e.reg=a,e.regg=o,e.ABOUT_LEGACY_COMPAT=z,e.ABOUT_LEGACY_COMPAT_SystemLiteral=B,e.AttlistDecl=R,e.CDATA_START=se,e.CDATA_END=ce,e.CDSect=X,e.Char=c,e.Comment=P,e.COMMENT_START=M,e.COMMENT_END=N,e.DOCTYPE_DECL_START=Y,e.elementdecl=L,e.EntityDecl=J,e.EntityValue=x,e.ExternalID=U,e.ExternalID_match=W,e.Name=g,e.Name_exact=_,e.NCName_exact=w,e.NotationDecl=te,e.Reference=y,e.PEReference=b,e.PI=k,e.PUBLIC=H,e.PubidLiteral=j,e.PubidLiteral_match=G,e.QName=T,e.QName_exact=E,e.QName_group=D,e.S=f,e.SChar_s=d,e.S_OPT=p,e.SYSTEM=V,e.SystemLiteral=O,e.SystemLiteral_match=K,e.InvalidChar=l,e.UNICODE_REPLACEMENT_CHARACTER=s,e.UNICODE_SUPPORT=n,e.XMLDecl=oe})),i=e((e=>{var i=t(),a=i.find,o=i.hasDefaultHTMLNamespace,s=i.hasOwn,c=i.isHTMLMimeType,l=i.isHTMLRawTextElement,u=i.isHTMLVoidElement,d=i.MIME_TYPE,f=i.NAMESPACE,p=Symbol(),m=n(),h=m.DOMException,g=m.DOMExceptionName,_=r();function v(e){if(e!==p)throw TypeError(`Illegal constructor`)}function y(e){return e!==``}function b(e){return e?e.split(/[\t\n\f\r ]+/).filter(y):[]}function x(e,t){return s(e,t)||(e[t]=!0),e}function S(e){if(!e)return[];var t=b(e);return Object.keys(t.reduce(x,{}))}function C(e){return function(t){return e&&e.indexOf(t)!==-1}}function w(e){if(!_.QName_exact.test(e))throw new h(h.INVALID_CHARACTER_ERR,`invalid character in qualified name "`+e+`"`)}function T(e,t){w(t),e||=null;var n=null,r=t;if(t.indexOf(`:`)>=0){var a=t.split(`:`);n=a[0],r=a[1]}if(n!==null&&e===null)throw new h(h.NAMESPACE_ERR,`prefix is non-null and namespace is null`);if(n===`xml`&&e!==i.NAMESPACE.XML)throw new h(h.NAMESPACE_ERR,`prefix is "xml" and namespace is not the XML namespace`);if((n===`xmlns`||t===`xmlns`)&&e!==i.NAMESPACE.XMLNS)throw new h(h.NAMESPACE_ERR,`either qualifiedName or prefix is "xmlns" and namespace is not the XMLNS namespace`);if(e===i.NAMESPACE.XMLNS&&n!==`xmlns`&&t!==`xmlns`)throw new h(h.NAMESPACE_ERR,`namespace is the XMLNS namespace and neither qualifiedName nor prefix is "xmlns"`);return[e,n,r]}function E(e,t){for(var n in e)s(e,n)&&(t[n]=e[n])}function D(e,t){var n=e.prototype;if(!(n instanceof t)){function r(){}r.prototype=t.prototype,r=new r,E(n,r),e.prototype=n=r}n.constructor!=e&&(typeof e!=`function`&&console.error(`unknown Class:`+e),n.constructor=e)}var O={},k=O.ELEMENT_NODE=1,A=O.ATTRIBUTE_NODE=2,j=O.TEXT_NODE=3,M=O.CDATA_SECTION_NODE=4,N=O.ENTITY_REFERENCE_NODE=5,P=O.ENTITY_NODE=6,F=O.PROCESSING_INSTRUCTION_NODE=7,I=O.COMMENT_NODE=8,L=O.DOCUMENT_NODE=9,R=O.DOCUMENT_TYPE_NODE=10,z=O.DOCUMENT_FRAGMENT_NODE=11,B=O.NOTATION_NODE=12,V=i.freeze({DOCUMENT_POSITION_DISCONNECTED:1,DOCUMENT_POSITION_PRECEDING:2,DOCUMENT_POSITION_FOLLOWING:4,DOCUMENT_POSITION_CONTAINS:8,DOCUMENT_POSITION_CONTAINED_BY:16,DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:32});function H(e,t){if(t.length<e.length)return H(t,e);var n=null;for(var r in e){if(e[r]!==t[r])return n;n=e[r]}return n}function U(e){return e.guid||=Math.random(),e.guid}function W(){}W.prototype={length:0,item:function(e){return e>=0&&e<this.length?this[e]:null},toString:function(e){for(var t=typeof e==`function`?{requireWellFormed:!1,splitCDATASections:!0,nodeFilter:e}:e?{requireWellFormed:!!e.requireWellFormed,splitCDATASections:e.splitCDATASections!==!1,nodeFilter:e.nodeFilter||null}:{requireWellFormed:!1,splitCDATASections:!0,nodeFilter:null},n=[],r=0;r<this.length;r++)Re(this[r],n,null,t);return n.join(``)},filter:function(e){return Array.prototype.filter.call(this,e)},indexOf:function(e){return Array.prototype.indexOf.call(this,e)}},W.prototype[Symbol.iterator]=function(){var e=this,t=0;return{next:function(){return t<e.length?{value:e[t++],done:!1}:{done:!0}},return:function(){return{done:!0}}}};function G(e,t){this._node=e,this._refresh=t,K(this)}function K(e){var t=e._node._inc||e._node.ownerDocument._inc;if(e._inc!==t){var n=e._refresh(e._node);if(Ve(e,`length`,n.length),!e.$$length||n.length<e.$$length)for(var r=n.length;r in e;r++)s(e,r)&&delete e[r];E(n,e),e._inc=t}}G.prototype.item=function(e){return K(this),this[e]||null},D(G,W);function q(){this._nsIndex=Object.create(null),this._noNsIndex=Object.create(null)}function ee(e,t){for(var n=0;n<e.length;){if(e[n]===t)return n;n++}}function J(e,t,n){if(!t)return e._noNsIndex;var r=e._nsIndex[t];return!r&&n&&(r=e._nsIndex[t]=Object.create(null)),r}function te(e,t,n){var r=J(e,t,!1);return r&&r[n]||null}function ne(e,t){J(e,t.namespaceURI,!0)[t.localName]=t}function re(e,t){var n=J(e,t.namespaceURI,!1);n&&delete n[t.localName]}function ie(e,t,n,r){if(r?t[ee(t,r)]=n:(t[t.length]=n,t.length++),ne(t,n),e){n.ownerElement=e;var i=e.ownerDocument;i&&(r&&ue(i,e,r),le(i,e,n))}}function ae(e,t,n){var r=ee(t,n);if(r>=0){for(var i=t.length-1;r<=i;)t[r]=t[++r];if(t.length=i,re(t,n),e){var a=e.ownerDocument;a&&ue(a,e,n),n.ownerElement=null}}}q.prototype={length:0,item:W.prototype.item,getNamedItem:function(e){this._ownerElement&&this._ownerElement._isInHTMLDocumentAndNamespace()&&(e=e.toLowerCase());for(var t=0;t<this.length;){var n=this[t];if(n.nodeName===e)return n;t++}return null},setNamedItem:function(e){var t=e.ownerElement;if(t&&t!==this._ownerElement)throw new h(h.INUSE_ATTRIBUTE_ERR);var n=te(this,e.namespaceURI,e.localName);return n===e?e:(ie(this._ownerElement,this,e,n),n)},setNamedItemNS:function(e){return this.setNamedItem(e)},removeNamedItem:function(e){var t=this.getNamedItem(e);if(!t)throw new h(h.NOT_FOUND_ERR,e);return ae(this._ownerElement,this,t),t},removeNamedItemNS:function(e,t){var n=this.getNamedItemNS(e,t);if(!n)throw new h(h.NOT_FOUND_ERR,e?e+` : `+t:t);return ae(this._ownerElement,this,n),n},getNamedItemNS:function(e,t){e||=null;for(var n=0;n<this.length;){var r=this[n];if(r.localName===t&&r.namespaceURI===e)return r;n++}return null}},q.prototype[Symbol.iterator]=function(){var e=this,t=0;return{next:function(){return t<e.length?{value:e[t++],done:!1}:{done:!0}},return:function(){return{done:!0}}}};function oe(){}oe.prototype={hasFeature:function(e,t){return!0},createDocument:function(e,t,n){var r=d.XML_APPLICATION;e===f.HTML?r=d.XML_XHTML_APPLICATION:e===f.SVG&&(r=d.XML_SVG_IMAGE);var i=new Z(p,{contentType:r});if(i.implementation=this,i.childNodes=new W,i.doctype=n||null,n&&i.appendChild(n),t){var a=i.createElementNS(e,t);i.appendChild(a)}return i},createDocumentType:function(e,t,n,r){w(e);var i=new Oe(p);return i.name=e,i.nodeName=e,i.publicId=t||``,i.systemId=n||``,i.internalSubset=r||``,i.childNodes=new W,i},createHTMLDocument:function(e){var t=new Z(p,{contentType:d.HTML});if(t.implementation=this,t.childNodes=new W,e!==!1){t.doctype=this.createDocumentType(`html`),t.doctype.ownerDocument=t,t.appendChild(t.doctype);var n=t.createElement(`html`);t.appendChild(n);var r=t.createElement(`head`);if(n.appendChild(r),typeof e==`string`){var i=t.createElement(`title`);i.appendChild(t.createTextNode(e)),r.appendChild(i)}n.appendChild(t.createElement(`body`))}return t}};function Y(e){v(e)}Y.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,parentNode:null,get parentElement(){return this.parentNode&&this.parentNode.nodeType===this.ELEMENT_NODE?this.parentNode:null},childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,baseURI:`about:blank`,get isConnected(){var e=this.getRootNode();return e&&e.nodeType===e.DOCUMENT_NODE},contains:function(e){if(!e)return!1;var t=e;do{if(this===t)return!0;t=t.parentNode}while(t);return!1},getRootNode:function(e){var t=this;do{if(!t.parentNode)return t;t=t.parentNode}while(t)},isEqualNode:function(e){if(!e)return!1;for(var t=[{node:this,other:e}];t.length>0;){var n=t.pop(),r=n.node,i=n.other;if(r.nodeType!==i.nodeType)return!1;switch(r.nodeType){case r.DOCUMENT_TYPE_NODE:if(r.name!==i.name||r.publicId!==i.publicId||r.systemId!==i.systemId)return!1;break;case r.ELEMENT_NODE:if(r.namespaceURI!==i.namespaceURI||r.prefix!==i.prefix||r.localName!==i.localName||r.attributes.length!==i.attributes.length)return!1;for(var a=0;a<r.attributes.length;a++){var o=r.attributes.item(a),s=i.getAttributeNodeNS(o.namespaceURI,o.localName);if(!s)return!1;t.push({node:o,other:s})}break;case r.ATTRIBUTE_NODE:if(r.namespaceURI!==i.namespaceURI||r.localName!==i.localName||r.value!==i.value)return!1;break;case r.PROCESSING_INSTRUCTION_NODE:if(r.target!==i.target||r.data!==i.data)return!1;break;case r.TEXT_NODE:case r.CDATA_SECTION_NODE:case r.COMMENT_NODE:if(r.data!==i.data)return!1}if(r.childNodes.length!==i.childNodes.length)return!1;for(var a=r.childNodes.length-1;a>=0;a--)t.push({node:r.childNodes[a],other:i.childNodes[a]})}return!0},isSameNode:function(e){return this===e},insertBefore:function(e,t){return Se(this,e,t)},replaceChild:function(e,t){Se(this,e,t,xe),t&&this.removeChild(t)},removeChild:function(e){return fe(this,e)},appendChild:function(e){return this.insertBefore(e,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(e){return Be(this.ownerDocument||this,this,e)},normalize:function(){X(this,null,{enter:function(e){for(var t=e.firstChild;t;){var n=t.nextSibling;if(n!==null&&n.nodeType===j&&t.nodeType===j){for(var r=[],i=n;i!==null&&i.nodeType===j;)r.push(i.data),i=i.nextSibling;for(var a=t.nextSibling;a!==i;){var o=a.nextSibling;a.parentNode=null,a.previousSibling=null,a.nextSibling=null,a=o}t.nextSibling=i,i===null?e.lastChild=t:i.previousSibling=t,t.appendData(r.join(``)),de(e.ownerDocument,e),t=i}else t=n}return!0}})},isSupported:function(e,t){return this.ownerDocument.implementation.hasFeature(e,t)},lookupPrefix:function(e){for(var t=this;t;){var n=t._nsMap;if(n){for(var r in n)if(s(n,r)&&n[r]===e)return r}t=t.nodeType==A?t.ownerDocument:t.parentNode}return null},lookupNamespaceURI:function(e){for(var t=this;t;){var n=t._nsMap;if(n&&s(n,e))return n[e];t=t.nodeType==A?t.ownerDocument:t.parentNode}return null},isDefaultNamespace:function(e){return this.lookupPrefix(e)==null},compareDocumentPosition:function(e){if(this===e)return 0;var t=e,n=this,r=null,i=null;if(t instanceof Ce&&(r=t,t=r.ownerElement),n instanceof Ce&&(i=n,n=i.ownerElement,r&&t&&n===t))for(var a=0,o;o=n.attributes[a];a++){if(o===r)return V.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC+V.DOCUMENT_POSITION_PRECEDING;if(o===i)return V.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC+V.DOCUMENT_POSITION_FOLLOWING}if(!t||!n||n.ownerDocument!==t.ownerDocument)return V.DOCUMENT_POSITION_DISCONNECTED+V.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC+(U(n.ownerDocument)>U(t.ownerDocument)?V.DOCUMENT_POSITION_FOLLOWING:V.DOCUMENT_POSITION_PRECEDING);if(i&&t===n)return V.DOCUMENT_POSITION_CONTAINS+V.DOCUMENT_POSITION_PRECEDING;if(r&&t===n)return V.DOCUMENT_POSITION_CONTAINED_BY+V.DOCUMENT_POSITION_FOLLOWING;for(var s=[],c=t.parentNode;c;){if(!i&&c===n)return V.DOCUMENT_POSITION_CONTAINED_BY+V.DOCUMENT_POSITION_FOLLOWING;s.push(c),c=c.parentNode}s.reverse();for(var l=[],u=n.parentNode;u;){if(!r&&u===t)return V.DOCUMENT_POSITION_CONTAINS+V.DOCUMENT_POSITION_PRECEDING;l.push(u),u=u.parentNode}l.reverse();var d=H(s,l);for(var f in d.childNodes){var p=d.childNodes[f];if(p===n)return V.DOCUMENT_POSITION_FOLLOWING;if(p===t)return V.DOCUMENT_POSITION_PRECEDING;if(l.indexOf(p)>=0)return V.DOCUMENT_POSITION_FOLLOWING;if(s.indexOf(p)>=0)return V.DOCUMENT_POSITION_PRECEDING}return 0}};function se(e){return e==`<`&&`<`||e==`>`&&`>`||e==`&`&&`&`||e==`"`&&`"`||`&#`+e.charCodeAt()+`;`}E(O,Y),E(O,Y.prototype),E(V,Y),E(V,Y.prototype);function ce(e,t){X(e,null,{enter:function(e){return!t(e)||X.STOP}})}function X(e,t,n){for(var r=[{node:e,context:t,phase:X.ENTER}];r.length>0;){var i=r.pop();if(i.phase===X.ENTER){var a=n.enter(i.node,i.context);if(a===X.STOP)return X.STOP;if(r.push({node:i.node,context:a,phase:X.EXIT}),a==null)continue;for(var o=i.node.lastChild;o;)r.push({node:o,context:a,phase:X.ENTER}),o=o.previousSibling}else n.exit&&n.exit(i.node,i.context)}}X.STOP=Symbol(`walkDOM.STOP`),X.ENTER=0,X.EXIT=1;function Z(e,t){v(e);var n=t||{};this.ownerDocument=this,this.contentType=n.contentType||d.XML_APPLICATION,this.type=c(this.contentType)?`html`:`xml`}function le(e,t,n){e&&e._inc++,n.namespaceURI===f.XMLNS&&(t._nsMap[n.prefix?n.localName:``]=n.value)}function ue(e,t,n,r){e&&e._inc++,n.namespaceURI===f.XMLNS&&delete t._nsMap[n.prefix?n.localName:``]}function de(e,t,n){if(e&&e._inc){e._inc++;var r=t.childNodes;if(n&&!n.nextSibling)r[r.length++]=n;else{for(var i=t.firstChild,a=0;i;)r[a++]=i,i=i.nextSibling;r.length=a,delete r[r.length]}}}function fe(e,t){if(e!==t.parentNode)throw new h(h.NOT_FOUND_ERR,`child's parent is not parent`);var n=t.previousSibling,r=t.nextSibling;return n?n.nextSibling=r:e.firstChild=r,r?r.previousSibling=n:e.lastChild=n,de(e.ownerDocument,e),t.parentNode=null,t.previousSibling=null,t.nextSibling=null,t}function pe(e){return e&&(e.nodeType===Y.DOCUMENT_NODE||e.nodeType===Y.DOCUMENT_FRAGMENT_NODE||e.nodeType===Y.ELEMENT_NODE)}function me(e){return e&&(e.nodeType===Y.CDATA_SECTION_NODE||e.nodeType===Y.COMMENT_NODE||e.nodeType===Y.DOCUMENT_FRAGMENT_NODE||e.nodeType===Y.DOCUMENT_TYPE_NODE||e.nodeType===Y.ELEMENT_NODE||e.nodeType===Y.PROCESSING_INSTRUCTION_NODE||e.nodeType===Y.TEXT_NODE)}function he(e){return e&&e.nodeType===Y.DOCUMENT_TYPE_NODE}function Q(e){return e&&e.nodeType===Y.ELEMENT_NODE}function ge(e){return e&&e.nodeType===Y.TEXT_NODE}function _e(e,t){var n=e.childNodes||[];if(a(n,Q)||he(t))return!1;var r=a(n,he);return!(t&&r&&n.indexOf(r)>n.indexOf(t))}function ve(e,t){var n=e.childNodes||[];function r(e){return Q(e)&&e!==t}if(a(n,r))return!1;var i=a(n,he);return!(t&&i&&n.indexOf(i)>n.indexOf(t))}function ye(e,t,n){if(!pe(e))throw new h(h.HIERARCHY_REQUEST_ERR,`Unexpected parent node type `+e.nodeType);if(n&&n.parentNode!==e)throw new h(h.NOT_FOUND_ERR,`child not in parent`);if(!me(t)||he(t)&&e.nodeType!==Y.DOCUMENT_NODE)throw new h(h.HIERARCHY_REQUEST_ERR,`Unexpected node type `+t.nodeType+` for parent node type `+e.nodeType)}function be(e,t,n){var r=e.childNodes||[],i=t.childNodes||[];if(t.nodeType===Y.DOCUMENT_FRAGMENT_NODE){var o=i.filter(Q);if(o.length>1||a(i,ge))throw new h(h.HIERARCHY_REQUEST_ERR,`More than one element or text in fragment`);if(o.length===1&&!_e(e,n))throw new h(h.HIERARCHY_REQUEST_ERR,`Element in fragment can not be inserted before doctype`)}if(Q(t)&&!_e(e,n))throw new h(h.HIERARCHY_REQUEST_ERR,`Only one element can be added and only after doctype`);if(he(t)){if(a(r,he))throw new h(h.HIERARCHY_REQUEST_ERR,`Only one doctype is allowed`);var s=a(r,Q);if(n&&r.indexOf(s)<r.indexOf(n))throw new h(h.HIERARCHY_REQUEST_ERR,`Doctype can only be inserted before an element`);if(!n&&s)throw new h(h.HIERARCHY_REQUEST_ERR,`Doctype can not be appended since element is present`)}}function xe(e,t,n){var r=e.childNodes||[],i=t.childNodes||[];if(t.nodeType===Y.DOCUMENT_FRAGMENT_NODE){var o=i.filter(Q);if(o.length>1||a(i,ge))throw new h(h.HIERARCHY_REQUEST_ERR,`More than one element or text in fragment`);if(o.length===1&&!ve(e,n))throw new h(h.HIERARCHY_REQUEST_ERR,`Element in fragment can not be inserted before doctype`)}if(Q(t)&&!ve(e,n))throw new h(h.HIERARCHY_REQUEST_ERR,`Only one element can be added and only after doctype`);if(he(t)){function e(e){return he(e)&&e!==n}if(a(r,e))throw new h(h.HIERARCHY_REQUEST_ERR,`Only one doctype is allowed`);var s=a(r,Q);if(n&&r.indexOf(s)<r.indexOf(n))throw new h(h.HIERARCHY_REQUEST_ERR,`Doctype can only be inserted before an element`)}}function Se(e,t,n,r){ye(e,t,n),e.nodeType===Y.DOCUMENT_NODE&&(r||be)(e,t,n);var i=t.parentNode;if(i&&i.removeChild(t),t.nodeType===z){var a=t.firstChild;if(a==null)return t;var o=t.lastChild}else a=o=t;var s=n?n.previousSibling:e.lastChild;a.previousSibling=s,o.nextSibling=n,s?s.nextSibling=a:e.firstChild=a,n==null?e.lastChild=o:n.previousSibling=o;do a.parentNode=e;while(a!==o&&(a=a.nextSibling));return de(e.ownerDocument||e,e,t),t.nodeType==z&&(t.firstChild=t.lastChild=null),t}Z.prototype={implementation:null,nodeName:`#document`,nodeType:L,doctype:null,documentElement:null,_inc:1,insertBefore:function(e,t){if(e.nodeType===z){for(var n=e.firstChild;n;){var r=n.nextSibling;this.insertBefore(n,t),n=r}return e}return Se(this,e,t),e.ownerDocument=this,this.documentElement===null&&e.nodeType===k&&(this.documentElement=e),e},removeChild:function(e){var t=fe(this,e);return t===this.documentElement&&(this.documentElement=null),t},replaceChild:function(e,t){Se(this,e,t,xe),e.ownerDocument=this,t&&this.removeChild(t),Q(e)&&(this.documentElement=e)},importNode:function(e,t){return ze(this,e,t)},getElementById:function(e){var t=null;return ce(this.documentElement,function(n){if(n.nodeType==k&&n.getAttribute(`id`)==e)return t=n,!0}),t},createElement:function(e){var t=new $(p);t.ownerDocument=this,this.type===`html`&&(e=e.toLowerCase()),o(this.contentType)&&(t.namespaceURI=f.HTML),t.nodeName=e,t.tagName=e,t.localName=e,t.childNodes=new W;var n=t.attributes=new q;return n._ownerElement=t,t},createDocumentFragment:function(){var e=new Me(p);return e.ownerDocument=this,e.childNodes=new W,e},createTextNode:function(e){var t=new Te(p);return t.ownerDocument=this,t.childNodes=new W,t.appendData(e),t},createComment:function(e){var t=new Ee(p);return t.ownerDocument=this,t.childNodes=new W,t.appendData(e),t},createCDATASection:function(e){if(e.indexOf(`]]>`)!==-1)throw new h(h.INVALID_CHARACTER_ERR,`data contains "]]>"`);var t=new De(p);return t.ownerDocument=this,t.childNodes=new W,t.appendData(e),t},createProcessingInstruction:function(e,t){var n=new Ne(p);return n.ownerDocument=this,n.childNodes=new W,n.nodeName=n.target=e,n.nodeValue=n.data=t,n},createAttribute:function(e){if(!_.QName_exact.test(e))throw new h(h.INVALID_CHARACTER_ERR,`invalid character in name "`+e+`"`);return this.type===`html`&&(e=e.toLowerCase()),this._createAttribute(e)},_createAttribute:function(e){var t=new Ce(p);return t.ownerDocument=this,t.childNodes=new W,t.name=e,t.nodeName=e,t.localName=e,t.specified=!0,t},createEntityReference:function(e){if(!_.Name_exact.test(e))throw new h(h.INVALID_CHARACTER_ERR,`not a valid xml name "`+e+`"`);if(this.type===`html`)throw new h(`document is an html document`,g.NotSupportedError);var t=new je(p);return t.ownerDocument=this,t.childNodes=new W,t.nodeName=e,t},createElementNS:function(e,t){var n=T(e,t),r=new $(p),i=r.attributes=new q;return r.childNodes=new W,r.ownerDocument=this,r.nodeName=t,r.tagName=t,r.namespaceURI=n[0],r.prefix=n[1],r.localName=n[2],i._ownerElement=r,r},createAttributeNS:function(e,t){var n=T(e,t),r=new Ce(p);return r.ownerDocument=this,r.childNodes=new W,r.nodeName=t,r.name=t,r.specified=!0,r.namespaceURI=n[0],r.prefix=n[1],r.localName=n[2],r}},D(Z,Y);function $(e){v(e),this._nsMap=Object.create(null)}$.prototype={nodeType:k,attributes:null,getQualifiedName:function(){return this.prefix?this.prefix+`:`+this.localName:this.localName},_isInHTMLDocumentAndNamespace:function(){return this.ownerDocument.type===`html`&&this.namespaceURI===f.HTML},hasAttributes:function(){return!!(this.attributes&&this.attributes.length)},hasAttribute:function(e){return!!this.getAttributeNode(e)},getAttribute:function(e){var t=this.getAttributeNode(e);return t?t.value:null},getAttributeNode:function(e){return this._isInHTMLDocumentAndNamespace()&&(e=e.toLowerCase()),this.attributes.getNamedItem(e)},setAttribute:function(e,t){this._isInHTMLDocumentAndNamespace()&&(e=e.toLowerCase());var n=this.getAttributeNode(e);n?n.value=n.nodeValue=``+t:(n=this.ownerDocument._createAttribute(e),n.value=n.nodeValue=``+t,this.setAttributeNode(n))},removeAttribute:function(e){var t=this.getAttributeNode(e);t&&this.removeAttributeNode(t)},setAttributeNode:function(e){return this.attributes.setNamedItem(e)},setAttributeNodeNS:function(e){return this.attributes.setNamedItemNS(e)},removeAttributeNode:function(e){return this.attributes.removeNamedItem(e.nodeName)},removeAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);n&&this.removeAttributeNode(n)},hasAttributeNS:function(e,t){return this.getAttributeNodeNS(e,t)!=null},getAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);return n?n.value:null},setAttributeNS:function(e,t,n){var r=T(e,t)[2],i=this.getAttributeNodeNS(e,r);i?i.value=i.nodeValue=``+n:(i=this.ownerDocument.createAttributeNS(e,t),i.value=i.nodeValue=``+n,this.setAttributeNode(i))},getAttributeNodeNS:function(e,t){return this.attributes.getNamedItemNS(e,t)},getElementsByClassName:function(e){var t=S(e);return new G(this,function(n){var r=[];return t.length>0&&ce(n,function(i){if(i!==n&&i.nodeType===k){var a=i.getAttribute(`class`);if(a){var o=e===a;if(!o){var s=S(a);o=t.every(C(s))}o&&r.push(i)}}}),r})},getElementsByTagName:function(e){var t=(this.nodeType===L?this:this.ownerDocument).type===`html`,n=e.toLowerCase();return new G(this,function(r){var i=[];return ce(r,function(a){a!==r&&a.nodeType===k&&(e===`*`||a.getQualifiedName()===(t&&a.namespaceURI===f.HTML?n:e))&&i.push(a)}),i})},getElementsByTagNameNS:function(e,t){return new G(this,function(n){var r=[];return ce(n,function(i){i!==n&&i.nodeType===k&&(e===`*`||i.namespaceURI===e)&&(t===`*`||i.localName==t)&&r.push(i)}),r})}},Z.prototype.getElementsByClassName=$.prototype.getElementsByClassName,Z.prototype.getElementsByTagName=$.prototype.getElementsByTagName,Z.prototype.getElementsByTagNameNS=$.prototype.getElementsByTagNameNS,D($,Y);function Ce(e){v(e),this.namespaceURI=null,this.prefix=null,this.ownerElement=null}Ce.prototype.nodeType=A,D(Ce,Y);function we(e){v(e)}we.prototype={data:``,substringData:function(e,t){return this.data.substring(e,e+t)},appendData:function(e){e=this.data+e,this.nodeValue=this.data=e,this.length=e.length},insertData:function(e,t){this.replaceData(e,0,t)},deleteData:function(e,t){this.replaceData(e,t,``)},replaceData:function(e,t,n){var r=this.data.substring(0,e),i=this.data.substring(e+t);n=r+n+i,this.nodeValue=this.data=n,this.length=n.length}},D(we,Y);function Te(e){v(e)}Te.prototype={nodeName:`#text`,nodeType:j,splitText:function(e){var t=this.data,n=t.substring(e);t=t.substring(0,e),this.data=this.nodeValue=t,this.length=t.length;var r=this.ownerDocument.createTextNode(n);return this.parentNode&&this.parentNode.insertBefore(r,this.nextSibling),r}},D(Te,we);function Ee(e){v(e)}Ee.prototype={nodeName:`#comment`,nodeType:I},D(Ee,we);function De(e){v(e)}De.prototype={nodeName:`#cdata-section`,nodeType:M},D(De,Te);function Oe(e){v(e)}Oe.prototype.nodeType=R,D(Oe,Y);function ke(e){v(e)}ke.prototype.nodeType=B,D(ke,Y);function Ae(e){v(e)}Ae.prototype.nodeType=P,D(Ae,Y);function je(e){v(e)}je.prototype.nodeType=N,D(je,Y);function Me(e){v(e)}Me.prototype.nodeName=`#document-fragment`,Me.prototype.nodeType=z,D(Me,Y);function Ne(e){v(e)}Ne.prototype.nodeType=F,D(Ne,we);function Pe(){}Pe.prototype.serializeToString=function(e,t){return Fe.call(e,t)},Y.prototype.toString=Fe;function Fe(e){var t=typeof e==`function`?{requireWellFormed:!1,splitCDATASections:!0,nodeFilter:e}:e==null?{requireWellFormed:!1,splitCDATASections:!0,nodeFilter:null}:{requireWellFormed:!!e.requireWellFormed,splitCDATASections:e.splitCDATASections!==!1,nodeFilter:e.nodeFilter||null},n=[],r=this.nodeType===L&&this.documentElement||this,i=r.prefix,a=r.namespaceURI;if(a&&i==null){var i=r.lookupPrefix(a);if(i==null)var o=[{namespace:a,prefix:null}]}return Re(this,n,o,t),n.join(``)}function Ie(e,t,n){var r=e.prefix||``,i=e.namespaceURI;if(!i||r===`xml`&&i===f.XML||i===f.XMLNS)return!1;for(var a=n.length;a--;){var o=n[a];if(o.prefix===r)return o.namespace!==i}return!0}function Le(e,t,n,r){if(r&&!_.QName_exact.test(t))throw new h(`The attribute name "`+t+`" is not a valid XML QName`,g.InvalidStateError);e.push(` `,t,`="`,n.replace(/[<>&"\t\n\r]/g,se),`"`)}function Re(e,t,n,r){n||=[];var i=r.nodeFilter,a=r.requireWellFormed,o=r.splitCDATASections,s=(e.nodeType===L?e:e.ownerDocument).type===`html`;X(e,{ns:n},{enter:function(e,n){var c=n.ns;if(i){if(e=i(e),e){if(typeof e==`string`)return t.push(e),null}else return null}switch(e.nodeType){case k:var d=e.attributes,p=d.length,m=e.tagName,v=m;if(!s&&!e.prefix&&e.namespaceURI){for(var y,b=0;b<d.length;b++)if(d.item(b).name===`xmlns`){y=d.item(b).value;break}if(!y)for(var x=c.length-1;x>=0;x--){var S=c[x];if(S.prefix===``&&S.namespace===e.namespaceURI){y=S.namespace;break}}if(y!==e.namespaceURI)for(var x=c.length-1;x>=0;x--){var S=c[x];if(S.namespace===e.namespaceURI){S.prefix&&(v=S.prefix+`:`+m);break}}}if(a&&!_.QName_exact.test(v))throw new h(`The element name "`+v+`" is not a valid XML QName`,g.InvalidStateError);t.push(`<`,v);for(var C=c.slice(),w=0;w<p;w++){var T=d.item(w);T.prefix==`xmlns`?C.push({prefix:T.localName,namespace:T.value}):T.nodeName==`xmlns`&&C.push({prefix:``,namespace:T.value})}for(var w=0;w<p;w++){var T=d.item(w);if(Ie(T,s,C)){var E=T.prefix||``,D=T.namespaceURI;Le(t,E?`xmlns:`+E:`xmlns`,D,a),C.push({prefix:E,namespace:D})}var O=i?i(T):T;O&&(typeof O==`string`?t.push(O):Le(t,O.name,O.value,a))}if(m===v&&Ie(e,s,C)){var P=e.prefix||``,D=e.namespaceURI;Le(t,P?`xmlns:`+P:`xmlns`,D,a),C.push({prefix:P,namespace:D})}var B=!e.firstChild;if(B&&(s||e.namespaceURI===f.HTML)&&(B=u(m)),B)return t.push(`/>`),null;if(t.push(`>`),s&&l(m)){for(var V=e.firstChild;V;)V.data?t.push(V.data):Re(V,t,C.slice(),r),V=V.nextSibling;return t.push(`</`,v,`>`),null}return{ns:C,tag:v};case L:case z:if(a&&e.nodeType===L&&e.documentElement==null)throw new h(`The Document has no documentElement`,g.InvalidStateError);return{ns:c};case A:return Le(t,e.name,e.value,a),null;case j:if(a&&_.InvalidChar.test(e.data))throw new h(`The Text node data contains characters outside the XML Char production`,g.InvalidStateError);return t.push(e.data.replace(/[<&>]/g,se)),null;case M:if(a&&e.data.indexOf(`]]>`)!==-1)throw new h(`The CDATASection data contains "]]>"`,g.InvalidStateError);return o?t.push(_.CDATA_START,e.data.replace(/]]>/g,`]]]]><![CDATA[>`),_.CDATA_END):t.push(_.CDATA_START,e.data,_.CDATA_END),null;case I:if(a){if(_.InvalidChar.test(e.data))throw new h(`The comment node data contains characters outside the XML Char production`,g.InvalidStateError);if(e.data.indexOf(`--`)!==-1||e.data[e.data.length-1]===`-`)throw new h(`The comment node data contains "--" or ends with "-"`,g.InvalidStateError)}return t.push(_.COMMENT_START,e.data,_.COMMENT_END),null;case R:var H=e.publicId,U=e.systemId;if(a){if(!_.Name_exact.test(e.name))throw new h(`The doctype name "`+e.name+`" is not a valid XML Name`,g.InvalidStateError);if(H&&!_.PubidLiteral_match.test(H))throw new h(`DocumentType publicId is not a valid PubidLiteral`,g.InvalidStateError);if(U&&U!==`.`&&!_.SystemLiteral_match.test(U))throw new h(`DocumentType systemId is not a valid SystemLiteral`,g.InvalidStateError);if(e.internalSubset&&e.internalSubset.indexOf(`]>`)!==-1)throw new h(`DocumentType internalSubset contains "]>"`,g.InvalidStateError)}return t.push(_.DOCTYPE_DECL_START,` `,e.name),H?(t.push(` `,_.PUBLIC,` `,H),U&&U!==`.`&&t.push(` `,U)):U&&U!==`.`&&t.push(` `,_.SYSTEM,` `,U),e.internalSubset&&t.push(` [`,e.internalSubset,`]`),t.push(`>`),null;case F:if(a){if(!_.NCName_exact.test(e.target)||e.target.toLowerCase()===`xml`)throw new h(`The processing instruction target "`+e.target+`" is not a valid XML NCName or is reserved`,g.InvalidStateError);if(_.InvalidChar.test(e.data))throw new h(`The ProcessingInstruction data contains characters outside the XML Char production`,g.InvalidStateError);if(e.data.indexOf(`?>`)!==-1)throw new h(`The ProcessingInstruction data contains "?>"`,g.InvalidStateError)}return t.push(`<?`,e.target,` `,e.data,`?>`),null;case N:if(a&&!_.Name_exact.test(e.nodeName))throw new h(`The entity reference name "`+e.nodeName+`" is not a valid XML Name`,g.InvalidStateError);return t.push(`&`,e.nodeName,`;`),null;default:return t.push(`??`,e.nodeName),null}},exit:function(e,n){n&&n.tag&&t.push(`</`,n.tag,`>`)}})}function ze(e,t,n){var r;return X(t,null,{enter:function(t,i){var a=t.cloneNode(!1);return a.ownerDocument=e,a.parentNode=null,i===null?r=a:i.appendChild(a),t.nodeType===A||n?a:null}}),r}function Be(e,t,n){var r;return X(t,null,{enter:function(t,i){var a=new t.constructor(p);for(var o in t)if(s(t,o)){var c=t[o];typeof c!=`object`&&c!=a[o]&&(a[o]=c)}t.childNodes&&(a.childNodes=new W),a.ownerDocument=e;var l=n;switch(a.nodeType){case k:var u=t.attributes,d=a.attributes=new q,f=u.length;d._ownerElement=a;for(var m=0;m<f;m++)a.setAttributeNode(Be(e,u.item(m),!0));break;case A:l=!0}return i===null?r=a:i.appendChild(a),l?a:null}}),r}function Ve(e,t,n){e[t]=n}function He(e){for(var t=[],n=e.firstChild;n;)n.nodeType===k&&t.push(n),n=n.nextSibling;return t}try{Object.defineProperty&&(Object.defineProperty(G.prototype,"length",{get:function(){return K(this),this.$$length}}),Object.defineProperty(Y.prototype,"textContent",{get:function(){if(this.nodeType===k||this.nodeType===z){var e=[];return X(this,null,{enter:function(t){if(t.nodeType===k||t.nodeType===z)return!0;if(t.nodeType===F||t.nodeType===I)return null;e.push(t.nodeValue)}}),e.join(``)}return this.nodeValue},set:function(e){switch(this.nodeType){case k:case z:for(;this.firstChild;)this.removeChild(this.firstChild);(e||String(e))&&this.appendChild(this.ownerDocument.createTextNode(e));break;default:this.data=e,this.value=e,this.nodeValue=e}}}),Object.defineProperty(we.prototype,"data",{get:function(){return this._data==null?``:this._data},set:function(e){this._data=e,this.length=typeof e==`string`?e.length:0}}),Object.defineProperty(we.prototype,"nodeValue",{get:function(){return this.data},set:function(e){this.data=e},enumerable:!0,configurable:!0}),Object.defineProperty($.prototype,"children",{get:function(){return new G(this,He)}}),Object.defineProperty(Z.prototype,"children",{get:function(){return new G(this,He)}}),Object.defineProperty(Me.prototype,"children",{get:function(){return new G(this,He)}}),Ve=function(e,t,n){e[`$$`+t]=n})}catch{}e._updateLiveList=K,e.Attr=Ce,e.CDATASection=De,e.CharacterData=we,e.Comment=Ee,e.Document=Z,e.DocumentFragment=Me,e.DocumentType=Oe,e.DOMImplementation=oe,e.Element=$,e.Entity=Ae,e.EntityReference=je,e.LiveNodeList=G,e.NamedNodeMap=q,e.Node=Y,e.NodeList=W,e.Notation=ke,e.Text=Te,e.ProcessingInstruction=Ne,e.walkDOM=X,e.XMLSerializer=Pe})),a=e((e=>{var n=t().freeze;e.XML_ENTITIES=n({amp:`&`,apos:`'`,gt:`>`,lt:`<`,quot:`"`}),e.HTML_ENTITIES=n({Aacute:`Á`,aacute:`á`,Abreve:`Ă`,abreve:`ă`,ac:`∾`,acd:`∿`,acE:`∾̳`,Acirc:`Â`,acirc:`â`,acute:`´`,Acy:`А`,acy:`а`,AElig:`Æ`,aelig:`æ`,af:``,Afr:`𝔄`,afr:`𝔞`,Agrave:`À`,agrave:`à`,alefsym:`ℵ`,aleph:`ℵ`,Alpha:`Α`,alpha:`α`,Amacr:`Ā`,amacr:`ā`,amalg:`⨿`,AMP:`&`,amp:`&`,And:`⩓`,and:`∧`,andand:`⩕`,andd:`⩜`,andslope:`⩘`,andv:`⩚`,ang:`∠`,ange:`⦤`,angle:`∠`,angmsd:`∡`,angmsdaa:`⦨`,angmsdab:`⦩`,angmsdac:`⦪`,angmsdad:`⦫`,angmsdae:`⦬`,angmsdaf:`⦭`,angmsdag:`⦮`,angmsdah:`⦯`,angrt:`∟`,angrtvb:`⊾`,angrtvbd:`⦝`,angsph:`∢`,angst:`Å`,angzarr:`⍼`,Aogon:`Ą`,aogon:`ą`,Aopf:`𝔸`,aopf:`𝕒`,ap:`≈`,apacir:`⩯`,apE:`⩰`,ape:`≊`,apid:`≋`,apos:`'`,ApplyFunction:``,approx:`≈`,approxeq:`≊`,Aring:`Å`,aring:`å`,Ascr:`𝒜`,ascr:`𝒶`,Assign:`≔`,ast:`*`,asymp:`≈`,asympeq:`≍`,Atilde:`Ã`,atilde:`ã`,Auml:`Ä`,auml:`ä`,awconint:`∳`,awint:`⨑`,backcong:`≌`,backepsilon:`϶`,backprime:`‵`,backsim:`∽`,backsimeq:`⋍`,Backslash:`∖`,Barv:`⫧`,barvee:`⊽`,Barwed:`⌆`,barwed:`⌅`,barwedge:`⌅`,bbrk:`⎵`,bbrktbrk:`⎶`,bcong:`≌`,Bcy:`Б`,bcy:`б`,bdquo:`„`,becaus:`∵`,Because:`∵`,because:`∵`,bemptyv:`⦰`,bepsi:`϶`,bernou:`ℬ`,Bernoullis:`ℬ`,Beta:`Β`,beta:`β`,beth:`ℶ`,between:`≬`,Bfr:`𝔅`,bfr:`𝔟`,bigcap:`⋂`,bigcirc:`◯`,bigcup:`⋃`,bigodot:`⨀`,bigoplus:`⨁`,bigotimes:`⨂`,bigsqcup:`⨆`,bigstar:`★`,bigtriangledown:`▽`,bigtriangleup:`△`,biguplus:`⨄`,bigvee:`⋁`,bigwedge:`⋀`,bkarow:`⤍`,blacklozenge:`⧫`,blacksquare:`▪`,blacktriangle:`▴`,blacktriangledown:`▾`,blacktriangleleft:`◂`,blacktriangleright:`▸`,blank:`␣`,blk12:`▒`,blk14:`░`,blk34:`▓`,block:`█`,bne:`=⃥`,bnequiv:`≡⃥`,bNot:`⫭`,bnot:`⌐`,Bopf:`𝔹`,bopf:`𝕓`,bot:`⊥`,bottom:`⊥`,bowtie:`⋈`,boxbox:`⧉`,boxDL:`╗`,boxDl:`╖`,boxdL:`╕`,boxdl:`┐`,boxDR:`╔`,boxDr:`╓`,boxdR:`╒`,boxdr:`┌`,boxH:`═`,boxh:`─`,boxHD:`╦`,boxHd:`╤`,boxhD:`╥`,boxhd:`┬`,boxHU:`╩`,boxHu:`╧`,boxhU:`╨`,boxhu:`┴`,boxminus:`⊟`,boxplus:`⊞`,boxtimes:`⊠`,boxUL:`╝`,boxUl:`╜`,boxuL:`╛`,boxul:`┘`,boxUR:`╚`,boxUr:`╙`,boxuR:`╘`,boxur:`└`,boxV:`║`,boxv:`│`,boxVH:`╬`,boxVh:`╫`,boxvH:`╪`,boxvh:`┼`,boxVL:`╣`,boxVl:`╢`,boxvL:`╡`,boxvl:`┤`,boxVR:`╠`,boxVr:`╟`,boxvR:`╞`,boxvr:`├`,bprime:`‵`,Breve:`˘`,breve:`˘`,brvbar:`¦`,Bscr:`ℬ`,bscr:`𝒷`,bsemi:`⁏`,bsim:`∽`,bsime:`⋍`,bsol:`\\`,bsolb:`⧅`,bsolhsub:`⟈`,bull:`•`,bullet:`•`,bump:`≎`,bumpE:`⪮`,bumpe:`≏`,Bumpeq:`≎`,bumpeq:`≏`,Cacute:`Ć`,cacute:`ć`,Cap:`⋒`,cap:`∩`,capand:`⩄`,capbrcup:`⩉`,capcap:`⩋`,capcup:`⩇`,capdot:`⩀`,CapitalDifferentialD:`ⅅ`,caps:`∩︀`,caret:`⁁`,caron:`ˇ`,Cayleys:`ℭ`,ccaps:`⩍`,Ccaron:`Č`,ccaron:`č`,Ccedil:`Ç`,ccedil:`ç`,Ccirc:`Ĉ`,ccirc:`ĉ`,Cconint:`∰`,ccups:`⩌`,ccupssm:`⩐`,Cdot:`Ċ`,cdot:`ċ`,cedil:`¸`,Cedilla:`¸`,cemptyv:`⦲`,cent:`¢`,CenterDot:`·`,centerdot:`·`,Cfr:`ℭ`,cfr:`𝔠`,CHcy:`Ч`,chcy:`ч`,check:`✓`,checkmark:`✓`,Chi:`Χ`,chi:`χ`,cir:`○`,circ:`ˆ`,circeq:`≗`,circlearrowleft:`↺`,circlearrowright:`↻`,circledast:`⊛`,circledcirc:`⊚`,circleddash:`⊝`,CircleDot:`⊙`,circledR:`®`,circledS:`Ⓢ`,CircleMinus:`⊖`,CirclePlus:`⊕`,CircleTimes:`⊗`,cirE:`⧃`,cire:`≗`,cirfnint:`⨐`,cirmid:`⫯`,cirscir:`⧂`,ClockwiseContourIntegral:`∲`,CloseCurlyDoubleQuote:`”`,CloseCurlyQuote:`’`,clubs:`♣`,clubsuit:`♣`,Colon:`∷`,colon:`:`,Colone:`⩴`,colone:`≔`,coloneq:`≔`,comma:`,`,commat:`@`,comp:`∁`,compfn:`∘`,complement:`∁`,complexes:`ℂ`,cong:`≅`,congdot:`⩭`,Congruent:`≡`,Conint:`∯`,conint:`∮`,ContourIntegral:`∮`,Copf:`ℂ`,copf:`𝕔`,coprod:`∐`,Coproduct:`∐`,COPY:`©`,copy:`©`,copysr:`℗`,CounterClockwiseContourIntegral:`∳`,crarr:`↵`,Cross:`⨯`,cross:`✗`,Cscr:`𝒞`,cscr:`𝒸`,csub:`⫏`,csube:`⫑`,csup:`⫐`,csupe:`⫒`,ctdot:`⋯`,cudarrl:`⤸`,cudarrr:`⤵`,cuepr:`⋞`,cuesc:`⋟`,cularr:`↶`,cularrp:`⤽`,Cup:`⋓`,cup:`∪`,cupbrcap:`⩈`,CupCap:`≍`,cupcap:`⩆`,cupcup:`⩊`,cupdot:`⊍`,cupor:`⩅`,cups:`∪︀`,curarr:`↷`,curarrm:`⤼`,curlyeqprec:`⋞`,curlyeqsucc:`⋟`,curlyvee:`⋎`,curlywedge:`⋏`,curren:`¤`,curvearrowleft:`↶`,curvearrowright:`↷`,cuvee:`⋎`,cuwed:`⋏`,cwconint:`∲`,cwint:`∱`,cylcty:`⌭`,Dagger:`‡`,dagger:`†`,daleth:`ℸ`,Darr:`↡`,dArr:`⇓`,darr:`↓`,dash:`‐`,Dashv:`⫤`,dashv:`⊣`,dbkarow:`⤏`,dblac:`˝`,Dcaron:`Ď`,dcaron:`ď`,Dcy:`Д`,dcy:`д`,DD:`ⅅ`,dd:`ⅆ`,ddagger:`‡`,ddarr:`⇊`,DDotrahd:`⤑`,ddotseq:`⩷`,deg:`°`,Del:`∇`,Delta:`Δ`,delta:`δ`,demptyv:`⦱`,dfisht:`⥿`,Dfr:`𝔇`,dfr:`𝔡`,dHar:`⥥`,dharl:`⇃`,dharr:`⇂`,DiacriticalAcute:`´`,DiacriticalDot:`˙`,DiacriticalDoubleAcute:`˝`,DiacriticalGrave:"`",DiacriticalTilde:`˜`,diam:`⋄`,Diamond:`⋄`,diamond:`⋄`,diamondsuit:`♦`,diams:`♦`,die:`¨`,DifferentialD:`ⅆ`,digamma:`ϝ`,disin:`⋲`,div:`÷`,divide:`÷`,divideontimes:`⋇`,divonx:`⋇`,DJcy:`Ђ`,djcy:`ђ`,dlcorn:`⌞`,dlcrop:`⌍`,dollar:`$`,Dopf:`𝔻`,dopf:`𝕕`,Dot:`¨`,dot:`˙`,DotDot:`⃜`,doteq:`≐`,doteqdot:`≑`,DotEqual:`≐`,dotminus:`∸`,dotplus:`∔`,dotsquare:`⊡`,doublebarwedge:`⌆`,DoubleContourIntegral:`∯`,DoubleDot:`¨`,DoubleDownArrow:`⇓`,DoubleLeftArrow:`⇐`,DoubleLeftRightArrow:`⇔`,DoubleLeftTee:`⫤`,DoubleLongLeftArrow:`⟸`,DoubleLongLeftRightArrow:`⟺`,DoubleLongRightArrow:`⟹`,DoubleRightArrow:`⇒`,DoubleRightTee:`⊨`,DoubleUpArrow:`⇑`,DoubleUpDownArrow:`⇕`,DoubleVerticalBar:`∥`,DownArrow:`↓`,Downarrow:`⇓`,downarrow:`↓`,DownArrowBar:`⤓`,DownArrowUpArrow:`⇵`,DownBreve:`̑`,downdownarrows:`⇊`,downharpoonleft:`⇃`,downharpoonright:`⇂`,DownLeftRightVector:`⥐`,DownLeftTeeVector:`⥞`,DownLeftVector:`↽`,DownLeftVectorBar:`⥖`,DownRightTeeVector:`⥟`,DownRightVector:`⇁`,DownRightVectorBar:`⥗`,DownTee:`⊤`,DownTeeArrow:`↧`,drbkarow:`⤐`,drcorn:`⌟`,drcrop:`⌌`,Dscr:`𝒟`,dscr:`𝒹`,DScy:`Ѕ`,dscy:`ѕ`,dsol:`⧶`,Dstrok:`Đ`,dstrok:`đ`,dtdot:`⋱`,dtri:`▿`,dtrif:`▾`,duarr:`⇵`,duhar:`⥯`,dwangle:`⦦`,DZcy:`Џ`,dzcy:`џ`,dzigrarr:`⟿`,Eacute:`É`,eacute:`é`,easter:`⩮`,Ecaron:`Ě`,ecaron:`ě`,ecir:`≖`,Ecirc:`Ê`,ecirc:`ê`,ecolon:`≕`,Ecy:`Э`,ecy:`э`,eDDot:`⩷`,Edot:`Ė`,eDot:`≑`,edot:`ė`,ee:`ⅇ`,efDot:`≒`,Efr:`𝔈`,efr:`𝔢`,eg:`⪚`,Egrave:`È`,egrave:`è`,egs:`⪖`,egsdot:`⪘`,el:`⪙`,Element:`∈`,elinters:`⏧`,ell:`ℓ`,els:`⪕`,elsdot:`⪗`,Emacr:`Ē`,emacr:`ē`,empty:`∅`,emptyset:`∅`,EmptySmallSquare:`◻`,emptyv:`∅`,EmptyVerySmallSquare:`▫`,emsp:` `,emsp13:` `,emsp14:` `,ENG:`Ŋ`,eng:`ŋ`,ensp:` `,Eogon:`Ę`,eogon:`ę`,Eopf:`𝔼`,eopf:`𝕖`,epar:`⋕`,eparsl:`⧣`,eplus:`⩱`,epsi:`ε`,Epsilon:`Ε`,epsilon:`ε`,epsiv:`ϵ`,eqcirc:`≖`,eqcolon:`≕`,eqsim:`≂`,eqslantgtr:`⪖`,eqslantless:`⪕`,Equal:`⩵`,equals:`=`,EqualTilde:`≂`,equest:`≟`,Equilibrium:`⇌`,equiv:`≡`,equivDD:`⩸`,eqvparsl:`⧥`,erarr:`⥱`,erDot:`≓`,Escr:`ℰ`,escr:`ℯ`,esdot:`≐`,Esim:`⩳`,esim:`≂`,Eta:`Η`,eta:`η`,ETH:`Ð`,eth:`ð`,Euml:`Ë`,euml:`ë`,euro:`€`,excl:`!`,exist:`∃`,Exists:`∃`,expectation:`ℰ`,ExponentialE:`ⅇ`,exponentiale:`ⅇ`,fallingdotseq:`≒`,Fcy:`Ф`,fcy:`ф`,female:`♀`,ffilig:`ffi`,fflig:`ff`,ffllig:`ffl`,Ffr:`𝔉`,ffr:`𝔣`,filig:`fi`,FilledSmallSquare:`◼`,FilledVerySmallSquare:`▪`,fjlig:`fj`,flat:`♭`,fllig:`fl`,fltns:`▱`,fnof:`ƒ`,Fopf:`𝔽`,fopf:`𝕗`,ForAll:`∀`,forall:`∀`,fork:`⋔`,forkv:`⫙`,Fouriertrf:`ℱ`,fpartint:`⨍`,frac12:`½`,frac13:`⅓`,frac14:`¼`,frac15:`⅕`,frac16:`⅙`,frac18:`⅛`,frac23:`⅔`,frac25:`⅖`,frac34:`¾`,frac35:`⅗`,frac38:`⅜`,frac45:`⅘`,frac56:`⅚`,frac58:`⅝`,frac78:`⅞`,frasl:`⁄`,frown:`⌢`,Fscr:`ℱ`,fscr:`𝒻`,gacute:`ǵ`,Gamma:`Γ`,gamma:`γ`,Gammad:`Ϝ`,gammad:`ϝ`,gap:`⪆`,Gbreve:`Ğ`,gbreve:`ğ`,Gcedil:`Ģ`,Gcirc:`Ĝ`,gcirc:`ĝ`,Gcy:`Г`,gcy:`г`,Gdot:`Ġ`,gdot:`ġ`,gE:`≧`,ge:`≥`,gEl:`⪌`,gel:`⋛`,geq:`≥`,geqq:`≧`,geqslant:`⩾`,ges:`⩾`,gescc:`⪩`,gesdot:`⪀`,gesdoto:`⪂`,gesdotol:`⪄`,gesl:`⋛︀`,gesles:`⪔`,Gfr:`𝔊`,gfr:`𝔤`,Gg:`⋙`,gg:`≫`,ggg:`⋙`,gimel:`ℷ`,GJcy:`Ѓ`,gjcy:`ѓ`,gl:`≷`,gla:`⪥`,glE:`⪒`,glj:`⪤`,gnap:`⪊`,gnapprox:`⪊`,gnE:`≩`,gne:`⪈`,gneq:`⪈`,gneqq:`≩`,gnsim:`⋧`,Gopf:`𝔾`,gopf:`𝕘`,grave:"`",GreaterEqual:`≥`,GreaterEqualLess:`⋛`,GreaterFullEqual:`≧`,GreaterGreater:`⪢`,GreaterLess:`≷`,GreaterSlantEqual:`⩾`,GreaterTilde:`≳`,Gscr:`𝒢`,gscr:`ℊ`,gsim:`≳`,gsime:`⪎`,gsiml:`⪐`,Gt:`≫`,GT:`>`,gt:`>`,gtcc:`⪧`,gtcir:`⩺`,gtdot:`⋗`,gtlPar:`⦕`,gtquest:`⩼`,gtrapprox:`⪆`,gtrarr:`⥸`,gtrdot:`⋗`,gtreqless:`⋛`,gtreqqless:`⪌`,gtrless:`≷`,gtrsim:`≳`,gvertneqq:`≩︀`,gvnE:`≩︀`,Hacek:`ˇ`,hairsp:` `,half:`½`,hamilt:`ℋ`,HARDcy:`Ъ`,hardcy:`ъ`,hArr:`⇔`,harr:`↔`,harrcir:`⥈`,harrw:`↭`,Hat:`^`,hbar:`ℏ`,Hcirc:`Ĥ`,hcirc:`ĥ`,hearts:`♥`,heartsuit:`♥`,hellip:`…`,hercon:`⊹`,Hfr:`ℌ`,hfr:`𝔥`,HilbertSpace:`ℋ`,hksearow:`⤥`,hkswarow:`⤦`,hoarr:`⇿`,homtht:`∻`,hookleftarrow:`↩`,hookrightarrow:`↪`,Hopf:`ℍ`,hopf:`𝕙`,horbar:`―`,HorizontalLine:`─`,Hscr:`ℋ`,hscr:`𝒽`,hslash:`ℏ`,Hstrok:`Ħ`,hstrok:`ħ`,HumpDownHump:`≎`,HumpEqual:`≏`,hybull:`⁃`,hyphen:`‐`,Iacute:`Í`,iacute:`í`,ic:``,Icirc:`Î`,icirc:`î`,Icy:`И`,icy:`и`,Idot:`İ`,IEcy:`Е`,iecy:`е`,iexcl:`¡`,iff:`⇔`,Ifr:`ℑ`,ifr:`𝔦`,Igrave:`Ì`,igrave:`ì`,ii:`ⅈ`,iiiint:`⨌`,iiint:`∭`,iinfin:`⧜`,iiota:`℩`,IJlig:`IJ`,ijlig:`ij`,Im:`ℑ`,Imacr:`Ī`,imacr:`ī`,image:`ℑ`,ImaginaryI:`ⅈ`,imagline:`ℐ`,imagpart:`ℑ`,imath:`ı`,imof:`⊷`,imped:`Ƶ`,Implies:`⇒`,in:`∈`,incare:`℅`,infin:`∞`,infintie:`⧝`,inodot:`ı`,Int:`∬`,int:`∫`,intcal:`⊺`,integers:`ℤ`,Integral:`∫`,intercal:`⊺`,Intersection:`⋂`,intlarhk:`⨗`,intprod:`⨼`,InvisibleComma:``,InvisibleTimes:``,IOcy:`Ё`,iocy:`ё`,Iogon:`Į`,iogon:`į`,Iopf:`𝕀`,iopf:`𝕚`,Iota:`Ι`,iota:`ι`,iprod:`⨼`,iquest:`¿`,Iscr:`ℐ`,iscr:`𝒾`,isin:`∈`,isindot:`⋵`,isinE:`⋹`,isins:`⋴`,isinsv:`⋳`,isinv:`∈`,it:``,Itilde:`Ĩ`,itilde:`ĩ`,Iukcy:`І`,iukcy:`і`,Iuml:`Ï`,iuml:`ï`,Jcirc:`Ĵ`,jcirc:`ĵ`,Jcy:`Й`,jcy:`й`,Jfr:`𝔍`,jfr:`𝔧`,jmath:`ȷ`,Jopf:`𝕁`,jopf:`𝕛`,Jscr:`𝒥`,jscr:`𝒿`,Jsercy:`Ј`,jsercy:`ј`,Jukcy:`Є`,jukcy:`є`,Kappa:`Κ`,kappa:`κ`,kappav:`ϰ`,Kcedil:`Ķ`,kcedil:`ķ`,Kcy:`К`,kcy:`к`,Kfr:`𝔎`,kfr:`𝔨`,kgreen:`ĸ`,KHcy:`Х`,khcy:`х`,KJcy:`Ќ`,kjcy:`ќ`,Kopf:`𝕂`,kopf:`𝕜`,Kscr:`𝒦`,kscr:`𝓀`,lAarr:`⇚`,Lacute:`Ĺ`,lacute:`ĺ`,laemptyv:`⦴`,lagran:`ℒ`,Lambda:`Λ`,lambda:`λ`,Lang:`⟪`,lang:`⟨`,langd:`⦑`,langle:`⟨`,lap:`⪅`,Laplacetrf:`ℒ`,laquo:`«`,Larr:`↞`,lArr:`⇐`,larr:`←`,larrb:`⇤`,larrbfs:`⤟`,larrfs:`⤝`,larrhk:`↩`,larrlp:`↫`,larrpl:`⤹`,larrsim:`⥳`,larrtl:`↢`,lat:`⪫`,lAtail:`⤛`,latail:`⤙`,late:`⪭`,lates:`⪭︀`,lBarr:`⤎`,lbarr:`⤌`,lbbrk:`❲`,lbrace:`{`,lbrack:`[`,lbrke:`⦋`,lbrksld:`⦏`,lbrkslu:`⦍`,Lcaron:`Ľ`,lcaron:`ľ`,Lcedil:`Ļ`,lcedil:`ļ`,lceil:`⌈`,lcub:`{`,Lcy:`Л`,lcy:`л`,ldca:`⤶`,ldquo:`“`,ldquor:`„`,ldrdhar:`⥧`,ldrushar:`⥋`,ldsh:`↲`,lE:`≦`,le:`≤`,LeftAngleBracket:`⟨`,LeftArrow:`←`,Leftarrow:`⇐`,leftarrow:`←`,LeftArrowBar:`⇤`,LeftArrowRightArrow:`⇆`,leftarrowtail:`↢`,LeftCeiling:`⌈`,LeftDoubleBracket:`⟦`,LeftDownTeeVector:`⥡`,LeftDownVector:`⇃`,LeftDownVectorBar:`⥙`,LeftFloor:`⌊`,leftharpoondown:`↽`,leftharpoonup:`↼`,leftleftarrows:`⇇`,LeftRightArrow:`↔`,Leftrightarrow:`⇔`,leftrightarrow:`↔`,leftrightarrows:`⇆`,leftrightharpoons:`⇋`,leftrightsquigarrow:`↭`,LeftRightVector:`⥎`,LeftTee:`⊣`,LeftTeeArrow:`↤`,LeftTeeVector:`⥚`,leftthreetimes:`⋋`,LeftTriangle:`⊲`,LeftTriangleBar:`⧏`,LeftTriangleEqual:`⊴`,LeftUpDownVector:`⥑`,LeftUpTeeVector:`⥠`,LeftUpVector:`↿`,LeftUpVectorBar:`⥘`,LeftVector:`↼`,LeftVectorBar:`⥒`,lEg:`⪋`,leg:`⋚`,leq:`≤`,leqq:`≦`,leqslant:`⩽`,les:`⩽`,lescc:`⪨`,lesdot:`⩿`,lesdoto:`⪁`,lesdotor:`⪃`,lesg:`⋚︀`,lesges:`⪓`,lessapprox:`⪅`,lessdot:`⋖`,lesseqgtr:`⋚`,lesseqqgtr:`⪋`,LessEqualGreater:`⋚`,LessFullEqual:`≦`,LessGreater:`≶`,lessgtr:`≶`,LessLess:`⪡`,lesssim:`≲`,LessSlantEqual:`⩽`,LessTilde:`≲`,lfisht:`⥼`,lfloor:`⌊`,Lfr:`𝔏`,lfr:`𝔩`,lg:`≶`,lgE:`⪑`,lHar:`⥢`,lhard:`↽`,lharu:`↼`,lharul:`⥪`,lhblk:`▄`,LJcy:`Љ`,ljcy:`љ`,Ll:`⋘`,ll:`≪`,llarr:`⇇`,llcorner:`⌞`,Lleftarrow:`⇚`,llhard:`⥫`,lltri:`◺`,Lmidot:`Ŀ`,lmidot:`ŀ`,lmoust:`⎰`,lmoustache:`⎰`,lnap:`⪉`,lnapprox:`⪉`,lnE:`≨`,lne:`⪇`,lneq:`⪇`,lneqq:`≨`,lnsim:`⋦`,loang:`⟬`,loarr:`⇽`,lobrk:`⟦`,LongLeftArrow:`⟵`,Longleftarrow:`⟸`,longleftarrow:`⟵`,LongLeftRightArrow:`⟷`,Longleftrightarrow:`⟺`,longleftrightarrow:`⟷`,longmapsto:`⟼`,LongRightArrow:`⟶`,Longrightarrow:`⟹`,longrightarrow:`⟶`,looparrowleft:`↫`,looparrowright:`↬`,lopar:`⦅`,Lopf:`𝕃`,lopf:`𝕝`,loplus:`⨭`,lotimes:`⨴`,lowast:`∗`,lowbar:`_`,LowerLeftArrow:`↙`,LowerRightArrow:`↘`,loz:`◊`,lozenge:`◊`,lozf:`⧫`,lpar:`(`,lparlt:`⦓`,lrarr:`⇆`,lrcorner:`⌟`,lrhar:`⇋`,lrhard:`⥭`,lrm:``,lrtri:`⊿`,lsaquo:`‹`,Lscr:`ℒ`,lscr:`𝓁`,Lsh:`↰`,lsh:`↰`,lsim:`≲`,lsime:`⪍`,lsimg:`⪏`,lsqb:`[`,lsquo:`‘`,lsquor:`‚`,Lstrok:`Ł`,lstrok:`ł`,Lt:`≪`,LT:`<`,lt:`<`,ltcc:`⪦`,ltcir:`⩹`,ltdot:`⋖`,lthree:`⋋`,ltimes:`⋉`,ltlarr:`⥶`,ltquest:`⩻`,ltri:`◃`,ltrie:`⊴`,ltrif:`◂`,ltrPar:`⦖`,lurdshar:`⥊`,luruhar:`⥦`,lvertneqq:`≨︀`,lvnE:`≨︀`,macr:`¯`,male:`♂`,malt:`✠`,maltese:`✠`,Map:`⤅`,map:`↦`,mapsto:`↦`,mapstodown:`↧`,mapstoleft:`↤`,mapstoup:`↥`,marker:`▮`,mcomma:`⨩`,Mcy:`М`,mcy:`м`,mdash:`—`,mDDot:`∺`,measuredangle:`∡`,MediumSpace:` `,Mellintrf:`ℳ`,Mfr:`𝔐`,mfr:`𝔪`,mho:`℧`,micro:`µ`,mid:`∣`,midast:`*`,midcir:`⫰`,middot:`·`,minus:`−`,minusb:`⊟`,minusd:`∸`,minusdu:`⨪`,MinusPlus:`∓`,mlcp:`⫛`,mldr:`…`,mnplus:`∓`,models:`⊧`,Mopf:`𝕄`,mopf:`𝕞`,mp:`∓`,Mscr:`ℳ`,mscr:`𝓂`,mstpos:`∾`,Mu:`Μ`,mu:`μ`,multimap:`⊸`,mumap:`⊸`,nabla:`∇`,Nacute:`Ń`,nacute:`ń`,nang:`∠⃒`,nap:`≉`,napE:`⩰̸`,napid:`≋̸`,napos:`ʼn`,napprox:`≉`,natur:`♮`,natural:`♮`,naturals:`ℕ`,nbsp:`\xA0`,nbump:`≎̸`,nbumpe:`≏̸`,ncap:`⩃`,Ncaron:`Ň`,ncaron:`ň`,Ncedil:`Ņ`,ncedil:`ņ`,ncong:`≇`,ncongdot:`⩭̸`,ncup:`⩂`,Ncy:`Н`,ncy:`н`,ndash:`–`,ne:`≠`,nearhk:`⤤`,neArr:`⇗`,nearr:`↗`,nearrow:`↗`,nedot:`≐̸`,NegativeMediumSpace:``,NegativeThickSpace:``,NegativeThinSpace:``,NegativeVeryThinSpace:``,nequiv:`≢`,nesear:`⤨`,nesim:`≂̸`,NestedGreaterGreater:`≫`,NestedLessLess:`≪`,NewLine:`
`,nexist:`∄`,nexists:`∄`,Nfr:`𝔑`,nfr:`𝔫`,ngE:`≧̸`,nge:`≱`,ngeq:`≱`,ngeqq:`≧̸`,ngeqslant:`⩾̸`,nges:`⩾̸`,nGg:`⋙̸`,ngsim:`≵`,nGt:`≫⃒`,ngt:`≯`,ngtr:`≯`,nGtv:`≫̸`,nhArr:`⇎`,nharr:`↮`,nhpar:`⫲`,ni:`∋`,nis:`⋼`,nisd:`⋺`,niv:`∋`,NJcy:`Њ`,njcy:`њ`,nlArr:`⇍`,nlarr:`↚`,nldr:`‥`,nlE:`≦̸`,nle:`≰`,nLeftarrow:`⇍`,nleftarrow:`↚`,nLeftrightarrow:`⇎`,nleftrightarrow:`↮`,nleq:`≰`,nleqq:`≦̸`,nleqslant:`⩽̸`,nles:`⩽̸`,nless:`≮`,nLl:`⋘̸`,nlsim:`≴`,nLt:`≪⃒`,nlt:`≮`,nltri:`⋪`,nltrie:`⋬`,nLtv:`≪̸`,nmid:`∤`,NoBreak:``,NonBreakingSpace:`\xA0`,Nopf:`ℕ`,nopf:`𝕟`,Not:`⫬`,not:`¬`,NotCongruent:`≢`,NotCupCap:`≭`,NotDoubleVerticalBar:`∦`,NotElement:`∉`,NotEqual:`≠`,NotEqualTilde:`≂̸`,NotExists:`∄`,NotGreater:`≯`,NotGreaterEqual:`≱`,NotGreaterFullEqual:`≧̸`,NotGreaterGreater:`≫̸`,NotGreaterLess:`≹`,NotGreaterSlantEqual:`⩾̸`,NotGreaterTilde:`≵`,NotHumpDownHump:`≎̸`,NotHumpEqual:`≏̸`,notin:`∉`,notindot:`⋵̸`,notinE:`⋹̸`,notinva:`∉`,notinvb:`⋷`,notinvc:`⋶`,NotLeftTriangle:`⋪`,NotLeftTriangleBar:`⧏̸`,NotLeftTriangleEqual:`⋬`,NotLess:`≮`,NotLessEqual:`≰`,NotLessGreater:`≸`,NotLessLess:`≪̸`,NotLessSlantEqual:`⩽̸`,NotLessTilde:`≴`,NotNestedGreaterGreater:`⪢̸`,NotNestedLessLess:`⪡̸`,notni:`∌`,notniva:`∌`,notnivb:`⋾`,notnivc:`⋽`,NotPrecedes:`⊀`,NotPrecedesEqual:`⪯̸`,NotPrecedesSlantEqual:`⋠`,NotReverseElement:`∌`,NotRightTriangle:`⋫`,NotRightTriangleBar:`⧐̸`,NotRightTriangleEqual:`⋭`,NotSquareSubset:`⊏̸`,NotSquareSubsetEqual:`⋢`,NotSquareSuperset:`⊐̸`,NotSquareSupersetEqual:`⋣`,NotSubset:`⊂⃒`,NotSubsetEqual:`⊈`,NotSucceeds:`⊁`,NotSucceedsEqual:`⪰̸`,NotSucceedsSlantEqual:`⋡`,NotSucceedsTilde:`≿̸`,NotSuperset:`⊃⃒`,NotSupersetEqual:`⊉`,NotTilde:`≁`,NotTildeEqual:`≄`,NotTildeFullEqual:`≇`,NotTildeTilde:`≉`,NotVerticalBar:`∤`,npar:`∦`,nparallel:`∦`,nparsl:`⫽⃥`,npart:`∂̸`,npolint:`⨔`,npr:`⊀`,nprcue:`⋠`,npre:`⪯̸`,nprec:`⊀`,npreceq:`⪯̸`,nrArr:`⇏`,nrarr:`↛`,nrarrc:`⤳̸`,nrarrw:`↝̸`,nRightarrow:`⇏`,nrightarrow:`↛`,nrtri:`⋫`,nrtrie:`⋭`,nsc:`⊁`,nsccue:`⋡`,nsce:`⪰̸`,Nscr:`𝒩`,nscr:`𝓃`,nshortmid:`∤`,nshortparallel:`∦`,nsim:`≁`,nsime:`≄`,nsimeq:`≄`,nsmid:`∤`,nspar:`∦`,nsqsube:`⋢`,nsqsupe:`⋣`,nsub:`⊄`,nsubE:`⫅̸`,nsube:`⊈`,nsubset:`⊂⃒`,nsubseteq:`⊈`,nsubseteqq:`⫅̸`,nsucc:`⊁`,nsucceq:`⪰̸`,nsup:`⊅`,nsupE:`⫆̸`,nsupe:`⊉`,nsupset:`⊃⃒`,nsupseteq:`⊉`,nsupseteqq:`⫆̸`,ntgl:`≹`,Ntilde:`Ñ`,ntilde:`ñ`,ntlg:`≸`,ntriangleleft:`⋪`,ntrianglelefteq:`⋬`,ntriangleright:`⋫`,ntrianglerighteq:`⋭`,Nu:`Ν`,nu:`ν`,num:`#`,numero:`№`,numsp:` `,nvap:`≍⃒`,nVDash:`⊯`,nVdash:`⊮`,nvDash:`⊭`,nvdash:`⊬`,nvge:`≥⃒`,nvgt:`>⃒`,nvHarr:`⤄`,nvinfin:`⧞`,nvlArr:`⤂`,nvle:`≤⃒`,nvlt:`<⃒`,nvltrie:`⊴⃒`,nvrArr:`⤃`,nvrtrie:`⊵⃒`,nvsim:`∼⃒`,nwarhk:`⤣`,nwArr:`⇖`,nwarr:`↖`,nwarrow:`↖`,nwnear:`⤧`,Oacute:`Ó`,oacute:`ó`,oast:`⊛`,ocir:`⊚`,Ocirc:`Ô`,ocirc:`ô`,Ocy:`О`,ocy:`о`,odash:`⊝`,Odblac:`Ő`,odblac:`ő`,odiv:`⨸`,odot:`⊙`,odsold:`⦼`,OElig:`Œ`,oelig:`œ`,ofcir:`⦿`,Ofr:`𝔒`,ofr:`𝔬`,ogon:`˛`,Ograve:`Ò`,ograve:`ò`,ogt:`⧁`,ohbar:`⦵`,ohm:`Ω`,oint:`∮`,olarr:`↺`,olcir:`⦾`,olcross:`⦻`,oline:`‾`,olt:`⧀`,Omacr:`Ō`,omacr:`ō`,Omega:`Ω`,omega:`ω`,Omicron:`Ο`,omicron:`ο`,omid:`⦶`,ominus:`⊖`,Oopf:`𝕆`,oopf:`𝕠`,opar:`⦷`,OpenCurlyDoubleQuote:`“`,OpenCurlyQuote:`‘`,operp:`⦹`,oplus:`⊕`,Or:`⩔`,or:`∨`,orarr:`↻`,ord:`⩝`,order:`ℴ`,orderof:`ℴ`,ordf:`ª`,ordm:`º`,origof:`⊶`,oror:`⩖`,orslope:`⩗`,orv:`⩛`,oS:`Ⓢ`,Oscr:`𝒪`,oscr:`ℴ`,Oslash:`Ø`,oslash:`ø`,osol:`⊘`,Otilde:`Õ`,otilde:`õ`,Otimes:`⨷`,otimes:`⊗`,otimesas:`⨶`,Ouml:`Ö`,ouml:`ö`,ovbar:`⌽`,OverBar:`‾`,OverBrace:`⏞`,OverBracket:`⎴`,OverParenthesis:`⏜`,par:`∥`,para:`¶`,parallel:`∥`,parsim:`⫳`,parsl:`⫽`,part:`∂`,PartialD:`∂`,Pcy:`П`,pcy:`п`,percnt:`%`,period:`.`,permil:`‰`,perp:`⊥`,pertenk:`‱`,Pfr:`𝔓`,pfr:`𝔭`,Phi:`Φ`,phi:`φ`,phiv:`ϕ`,phmmat:`ℳ`,phone:`☎`,Pi:`Π`,pi:`π`,pitchfork:`⋔`,piv:`ϖ`,planck:`ℏ`,planckh:`ℎ`,plankv:`ℏ`,plus:`+`,plusacir:`⨣`,plusb:`⊞`,pluscir:`⨢`,plusdo:`∔`,plusdu:`⨥`,pluse:`⩲`,PlusMinus:`±`,plusmn:`±`,plussim:`⨦`,plustwo:`⨧`,pm:`±`,Poincareplane:`ℌ`,pointint:`⨕`,Popf:`ℙ`,popf:`𝕡`,pound:`£`,Pr:`⪻`,pr:`≺`,prap:`⪷`,prcue:`≼`,prE:`⪳`,pre:`⪯`,prec:`≺`,precapprox:`⪷`,preccurlyeq:`≼`,Precedes:`≺`,PrecedesEqual:`⪯`,PrecedesSlantEqual:`≼`,PrecedesTilde:`≾`,preceq:`⪯`,precnapprox:`⪹`,precneqq:`⪵`,precnsim:`⋨`,precsim:`≾`,Prime:`″`,prime:`′`,primes:`ℙ`,prnap:`⪹`,prnE:`⪵`,prnsim:`⋨`,prod:`∏`,Product:`∏`,profalar:`⌮`,profline:`⌒`,profsurf:`⌓`,prop:`∝`,Proportion:`∷`,Proportional:`∝`,propto:`∝`,prsim:`≾`,prurel:`⊰`,Pscr:`𝒫`,pscr:`𝓅`,Psi:`Ψ`,psi:`ψ`,puncsp:` `,Qfr:`𝔔`,qfr:`𝔮`,qint:`⨌`,Qopf:`ℚ`,qopf:`𝕢`,qprime:`⁗`,Qscr:`𝒬`,qscr:`𝓆`,quaternions:`ℍ`,quatint:`⨖`,quest:`?`,questeq:`≟`,QUOT:`"`,quot:`"`,rAarr:`⇛`,race:`∽̱`,Racute:`Ŕ`,racute:`ŕ`,radic:`√`,raemptyv:`⦳`,Rang:`⟫`,rang:`⟩`,rangd:`⦒`,range:`⦥`,rangle:`⟩`,raquo:`»`,Rarr:`↠`,rArr:`⇒`,rarr:`→`,rarrap:`⥵`,rarrb:`⇥`,rarrbfs:`⤠`,rarrc:`⤳`,rarrfs:`⤞`,rarrhk:`↪`,rarrlp:`↬`,rarrpl:`⥅`,rarrsim:`⥴`,Rarrtl:`⤖`,rarrtl:`↣`,rarrw:`↝`,rAtail:`⤜`,ratail:`⤚`,ratio:`∶`,rationals:`ℚ`,RBarr:`⤐`,rBarr:`⤏`,rbarr:`⤍`,rbbrk:`❳`,rbrace:`}`,rbrack:`]`,rbrke:`⦌`,rbrksld:`⦎`,rbrkslu:`⦐`,Rcaron:`Ř`,rcaron:`ř`,Rcedil:`Ŗ`,rcedil:`ŗ`,rceil:`⌉`,rcub:`}`,Rcy:`Р`,rcy:`р`,rdca:`⤷`,rdldhar:`⥩`,rdquo:`”`,rdquor:`”`,rdsh:`↳`,Re:`ℜ`,real:`ℜ`,realine:`ℛ`,realpart:`ℜ`,reals:`ℝ`,rect:`▭`,REG:`®`,reg:`®`,ReverseElement:`∋`,ReverseEquilibrium:`⇋`,ReverseUpEquilibrium:`⥯`,rfisht:`⥽`,rfloor:`⌋`,Rfr:`ℜ`,rfr:`𝔯`,rHar:`⥤`,rhard:`⇁`,rharu:`⇀`,rharul:`⥬`,Rho:`Ρ`,rho:`ρ`,rhov:`ϱ`,RightAngleBracket:`⟩`,RightArrow:`→`,Rightarrow:`⇒`,rightarrow:`→`,RightArrowBar:`⇥`,RightArrowLeftArrow:`⇄`,rightarrowtail:`↣`,RightCeiling:`⌉`,RightDoubleBracket:`⟧`,RightDownTeeVector:`⥝`,RightDownVector:`⇂`,RightDownVectorBar:`⥕`,RightFloor:`⌋`,rightharpoondown:`⇁`,rightharpoonup:`⇀`,rightleftarrows:`⇄`,rightleftharpoons:`⇌`,rightrightarrows:`⇉`,rightsquigarrow:`↝`,RightTee:`⊢`,RightTeeArrow:`↦`,RightTeeVector:`⥛`,rightthreetimes:`⋌`,RightTriangle:`⊳`,RightTriangleBar:`⧐`,RightTriangleEqual:`⊵`,RightUpDownVector:`⥏`,RightUpTeeVector:`⥜`,RightUpVector:`↾`,RightUpVectorBar:`⥔`,RightVector:`⇀`,RightVectorBar:`⥓`,ring:`˚`,risingdotseq:`≓`,rlarr:`⇄`,rlhar:`⇌`,rlm:``,rmoust:`⎱`,rmoustache:`⎱`,rnmid:`⫮`,roang:`⟭`,roarr:`⇾`,robrk:`⟧`,ropar:`⦆`,Ropf:`ℝ`,ropf:`𝕣`,roplus:`⨮`,rotimes:`⨵`,RoundImplies:`⥰`,rpar:`)`,rpargt:`⦔`,rppolint:`⨒`,rrarr:`⇉`,Rrightarrow:`⇛`,rsaquo:`›`,Rscr:`ℛ`,rscr:`𝓇`,Rsh:`↱`,rsh:`↱`,rsqb:`]`,rsquo:`’`,rsquor:`’`,rthree:`⋌`,rtimes:`⋊`,rtri:`▹`,rtrie:`⊵`,rtrif:`▸`,rtriltri:`⧎`,RuleDelayed:`⧴`,ruluhar:`⥨`,rx:`℞`,Sacute:`Ś`,sacute:`ś`,sbquo:`‚`,Sc:`⪼`,sc:`≻`,scap:`⪸`,Scaron:`Š`,scaron:`š`,sccue:`≽`,scE:`⪴`,sce:`⪰`,Scedil:`Ş`,scedil:`ş`,Scirc:`Ŝ`,scirc:`ŝ`,scnap:`⪺`,scnE:`⪶`,scnsim:`⋩`,scpolint:`⨓`,scsim:`≿`,Scy:`С`,scy:`с`,sdot:`⋅`,sdotb:`⊡`,sdote:`⩦`,searhk:`⤥`,seArr:`⇘`,searr:`↘`,searrow:`↘`,sect:`§`,semi:`;`,seswar:`⤩`,setminus:`∖`,setmn:`∖`,sext:`✶`,Sfr:`𝔖`,sfr:`𝔰`,sfrown:`⌢`,sharp:`♯`,SHCHcy:`Щ`,shchcy:`щ`,SHcy:`Ш`,shcy:`ш`,ShortDownArrow:`↓`,ShortLeftArrow:`←`,shortmid:`∣`,shortparallel:`∥`,ShortRightArrow:`→`,ShortUpArrow:`↑`,shy:``,Sigma:`Σ`,sigma:`σ`,sigmaf:`ς`,sigmav:`ς`,sim:`∼`,simdot:`⩪`,sime:`≃`,simeq:`≃`,simg:`⪞`,simgE:`⪠`,siml:`⪝`,simlE:`⪟`,simne:`≆`,simplus:`⨤`,simrarr:`⥲`,slarr:`←`,SmallCircle:`∘`,smallsetminus:`∖`,smashp:`⨳`,smeparsl:`⧤`,smid:`∣`,smile:`⌣`,smt:`⪪`,smte:`⪬`,smtes:`⪬︀`,SOFTcy:`Ь`,softcy:`ь`,sol:`/`,solb:`⧄`,solbar:`⌿`,Sopf:`𝕊`,sopf:`𝕤`,spades:`♠`,spadesuit:`♠`,spar:`∥`,sqcap:`⊓`,sqcaps:`⊓︀`,sqcup:`⊔`,sqcups:`⊔︀`,Sqrt:`√`,sqsub:`⊏`,sqsube:`⊑`,sqsubset:`⊏`,sqsubseteq:`⊑`,sqsup:`⊐`,sqsupe:`⊒`,sqsupset:`⊐`,sqsupseteq:`⊒`,squ:`□`,Square:`□`,square:`□`,SquareIntersection:`⊓`,SquareSubset:`⊏`,SquareSubsetEqual:`⊑`,SquareSuperset:`⊐`,SquareSupersetEqual:`⊒`,SquareUnion:`⊔`,squarf:`▪`,squf:`▪`,srarr:`→`,Sscr:`𝒮`,sscr:`𝓈`,ssetmn:`∖`,ssmile:`⌣`,sstarf:`⋆`,Star:`⋆`,star:`☆`,starf:`★`,straightepsilon:`ϵ`,straightphi:`ϕ`,strns:`¯`,Sub:`⋐`,sub:`⊂`,subdot:`⪽`,subE:`⫅`,sube:`⊆`,subedot:`⫃`,submult:`⫁`,subnE:`⫋`,subne:`⊊`,subplus:`⪿`,subrarr:`⥹`,Subset:`⋐`,subset:`⊂`,subseteq:`⊆`,subseteqq:`⫅`,SubsetEqual:`⊆`,subsetneq:`⊊`,subsetneqq:`⫋`,subsim:`⫇`,subsub:`⫕`,subsup:`⫓`,succ:`≻`,succapprox:`⪸`,succcurlyeq:`≽`,Succeeds:`≻`,SucceedsEqual:`⪰`,SucceedsSlantEqual:`≽`,SucceedsTilde:`≿`,succeq:`⪰`,succnapprox:`⪺`,succneqq:`⪶`,succnsim:`⋩`,succsim:`≿`,SuchThat:`∋`,Sum:`∑`,sum:`∑`,sung:`♪`,Sup:`⋑`,sup:`⊃`,sup1:`¹`,sup2:`²`,sup3:`³`,supdot:`⪾`,supdsub:`⫘`,supE:`⫆`,supe:`⊇`,supedot:`⫄`,Superset:`⊃`,SupersetEqual:`⊇`,suphsol:`⟉`,suphsub:`⫗`,suplarr:`⥻`,supmult:`⫂`,supnE:`⫌`,supne:`⊋`,supplus:`⫀`,Supset:`⋑`,supset:`⊃`,supseteq:`⊇`,supseteqq:`⫆`,supsetneq:`⊋`,supsetneqq:`⫌`,supsim:`⫈`,supsub:`⫔`,supsup:`⫖`,swarhk:`⤦`,swArr:`⇙`,swarr:`↙`,swarrow:`↙`,swnwar:`⤪`,szlig:`ß`,Tab:` `,target:`⌖`,Tau:`Τ`,tau:`τ`,tbrk:`⎴`,Tcaron:`Ť`,tcaron:`ť`,Tcedil:`Ţ`,tcedil:`ţ`,Tcy:`Т`,tcy:`т`,tdot:`⃛`,telrec:`⌕`,Tfr:`𝔗`,tfr:`𝔱`,there4:`∴`,Therefore:`∴`,therefore:`∴`,Theta:`Θ`,theta:`θ`,thetasym:`ϑ`,thetav:`ϑ`,thickapprox:`≈`,thicksim:`∼`,ThickSpace:` `,thinsp:` `,ThinSpace:` `,thkap:`≈`,thksim:`∼`,THORN:`Þ`,thorn:`þ`,Tilde:`∼`,tilde:`˜`,TildeEqual:`≃`,TildeFullEqual:`≅`,TildeTilde:`≈`,times:`×`,timesb:`⊠`,timesbar:`⨱`,timesd:`⨰`,tint:`∭`,toea:`⤨`,top:`⊤`,topbot:`⌶`,topcir:`⫱`,Topf:`𝕋`,topf:`𝕥`,topfork:`⫚`,tosa:`⤩`,tprime:`‴`,TRADE:`™`,trade:`™`,triangle:`▵`,triangledown:`▿`,triangleleft:`◃`,trianglelefteq:`⊴`,triangleq:`≜`,triangleright:`▹`,trianglerighteq:`⊵`,tridot:`◬`,trie:`≜`,triminus:`⨺`,TripleDot:`⃛`,triplus:`⨹`,trisb:`⧍`,tritime:`⨻`,trpezium:`⏢`,Tscr:`𝒯`,tscr:`𝓉`,TScy:`Ц`,tscy:`ц`,TSHcy:`Ћ`,tshcy:`ћ`,Tstrok:`Ŧ`,tstrok:`ŧ`,twixt:`≬`,twoheadleftarrow:`↞`,twoheadrightarrow:`↠`,Uacute:`Ú`,uacute:`ú`,Uarr:`↟`,uArr:`⇑`,uarr:`↑`,Uarrocir:`⥉`,Ubrcy:`Ў`,ubrcy:`ў`,Ubreve:`Ŭ`,ubreve:`ŭ`,Ucirc:`Û`,ucirc:`û`,Ucy:`У`,ucy:`у`,udarr:`⇅`,Udblac:`Ű`,udblac:`ű`,udhar:`⥮`,ufisht:`⥾`,Ufr:`𝔘`,ufr:`𝔲`,Ugrave:`Ù`,ugrave:`ù`,uHar:`⥣`,uharl:`↿`,uharr:`↾`,uhblk:`▀`,ulcorn:`⌜`,ulcorner:`⌜`,ulcrop:`⌏`,ultri:`◸`,Umacr:`Ū`,umacr:`ū`,uml:`¨`,UnderBar:`_`,UnderBrace:`⏟`,UnderBracket:`⎵`,UnderParenthesis:`⏝`,Union:`⋃`,UnionPlus:`⊎`,Uogon:`Ų`,uogon:`ų`,Uopf:`𝕌`,uopf:`𝕦`,UpArrow:`↑`,Uparrow:`⇑`,uparrow:`↑`,UpArrowBar:`⤒`,UpArrowDownArrow:`⇅`,UpDownArrow:`↕`,Updownarrow:`⇕`,updownarrow:`↕`,UpEquilibrium:`⥮`,upharpoonleft:`↿`,upharpoonright:`↾`,uplus:`⊎`,UpperLeftArrow:`↖`,UpperRightArrow:`↗`,Upsi:`ϒ`,upsi:`υ`,upsih:`ϒ`,Upsilon:`Υ`,upsilon:`υ`,UpTee:`⊥`,UpTeeArrow:`↥`,upuparrows:`⇈`,urcorn:`⌝`,urcorner:`⌝`,urcrop:`⌎`,Uring:`Ů`,uring:`ů`,urtri:`◹`,Uscr:`𝒰`,uscr:`𝓊`,utdot:`⋰`,Utilde:`Ũ`,utilde:`ũ`,utri:`▵`,utrif:`▴`,uuarr:`⇈`,Uuml:`Ü`,uuml:`ü`,uwangle:`⦧`,vangrt:`⦜`,varepsilon:`ϵ`,varkappa:`ϰ`,varnothing:`∅`,varphi:`ϕ`,varpi:`ϖ`,varpropto:`∝`,vArr:`⇕`,varr:`↕`,varrho:`ϱ`,varsigma:`ς`,varsubsetneq:`⊊︀`,varsubsetneqq:`⫋︀`,varsupsetneq:`⊋︀`,varsupsetneqq:`⫌︀`,vartheta:`ϑ`,vartriangleleft:`⊲`,vartriangleright:`⊳`,Vbar:`⫫`,vBar:`⫨`,vBarv:`⫩`,Vcy:`В`,vcy:`в`,VDash:`⊫`,Vdash:`⊩`,vDash:`⊨`,vdash:`⊢`,Vdashl:`⫦`,Vee:`⋁`,vee:`∨`,veebar:`⊻`,veeeq:`≚`,vellip:`⋮`,Verbar:`‖`,verbar:`|`,Vert:`‖`,vert:`|`,VerticalBar:`∣`,VerticalLine:`|`,VerticalSeparator:`❘`,VerticalTilde:`≀`,VeryThinSpace:` `,Vfr:`𝔙`,vfr:`𝔳`,vltri:`⊲`,vnsub:`⊂⃒`,vnsup:`⊃⃒`,Vopf:`𝕍`,vopf:`𝕧`,vprop:`∝`,vrtri:`⊳`,Vscr:`𝒱`,vscr:`𝓋`,vsubnE:`⫋︀`,vsubne:`⊊︀`,vsupnE:`⫌︀`,vsupne:`⊋︀`,Vvdash:`⊪`,vzigzag:`⦚`,Wcirc:`Ŵ`,wcirc:`ŵ`,wedbar:`⩟`,Wedge:`⋀`,wedge:`∧`,wedgeq:`≙`,weierp:`℘`,Wfr:`𝔚`,wfr:`𝔴`,Wopf:`𝕎`,wopf:`𝕨`,wp:`℘`,wr:`≀`,wreath:`≀`,Wscr:`𝒲`,wscr:`𝓌`,xcap:`⋂`,xcirc:`◯`,xcup:`⋃`,xdtri:`▽`,Xfr:`𝔛`,xfr:`𝔵`,xhArr:`⟺`,xharr:`⟷`,Xi:`Ξ`,xi:`ξ`,xlArr:`⟸`,xlarr:`⟵`,xmap:`⟼`,xnis:`⋻`,xodot:`⨀`,Xopf:`𝕏`,xopf:`𝕩`,xoplus:`⨁`,xotime:`⨂`,xrArr:`⟹`,xrarr:`⟶`,Xscr:`𝒳`,xscr:`𝓍`,xsqcup:`⨆`,xuplus:`⨄`,xutri:`△`,xvee:`⋁`,xwedge:`⋀`,Yacute:`Ý`,yacute:`ý`,YAcy:`Я`,yacy:`я`,Ycirc:`Ŷ`,ycirc:`ŷ`,Ycy:`Ы`,ycy:`ы`,yen:`¥`,Yfr:`𝔜`,yfr:`𝔶`,YIcy:`Ї`,yicy:`ї`,Yopf:`𝕐`,yopf:`𝕪`,Yscr:`𝒴`,yscr:`𝓎`,YUcy:`Ю`,yucy:`ю`,Yuml:`Ÿ`,yuml:`ÿ`,Zacute:`Ź`,zacute:`ź`,Zcaron:`Ž`,zcaron:`ž`,Zcy:`З`,zcy:`з`,Zdot:`Ż`,zdot:`ż`,zeetrf:`ℨ`,ZeroWidthSpace:``,Zeta:`Ζ`,zeta:`ζ`,Zfr:`ℨ`,zfr:`𝔷`,ZHcy:`Ж`,zhcy:`ж`,zigrarr:`⇝`,Zopf:`ℤ`,zopf:`𝕫`,Zscr:`𝒵`,zscr:`𝓏`,zwj:``,zwnj:``}),e.entityMap=e.HTML_ENTITIES})),o=e((e=>{var i=t(),a=r(),o=n(),s=i.isHTMLEscapableRawTextElement,c=i.isHTMLMimeType,l=i.isHTMLRawTextElement,u=i.hasOwn,d=i.NAMESPACE,f=o.ParseError,p=o.DOMException,m=0,h=1,g=2,_=3,v=4,y=5,b=6,x=7;function S(){}S.prototype={parse:function(e,t,n){var r=this.domBuilder;r.startDocument(),k(t,t=Object.create(null)),w(e,t,n,r,this.errorHandler),r.endDocument()}};var C=/&#?\w+;?/g;function w(e,t,n,r,o){var s=c(r.mimeType);e.indexOf(a.UNICODE_REPLACEMENT_CHARACTER)>=0&&o.warning(`Unicode replacement character detected, source encoding issues?`);function l(e){if(e>65535){e-=65536;var t=55296+(e>>10),n=56320+(e&1023);return String.fromCharCode(t,n)}return String.fromCharCode(e)}function d(e){var t=e[e.length-1]===`;`?e:e+`;`;if(!s&&t!==e)return o.error(`EntityRef: expecting ;`),e;var r=a.Reference.exec(t);if(!r||r[0].length!==t.length)return o.error(`entity not matching Reference production: `+e),e;var i=t.slice(1,-1);return u(n,i)?n[i]:i.charAt(0)===`#`?l(parseInt(i.substring(1).replace(`x`,`0x`))):(o.error(`entity not found:`+e),e)}function m(t){if(t>S){var n=e.substring(S,t).replace(C,d);v&&y(S),r.characters(n,0,t-S),S=t}}var h=0,g=0,_=/\r\n?|\n|$/g,v=r.locator;function y(t,n){for(;t>=g&&(n=_.exec(e));)h=g,g=n.index+n[0].length,v.lineNumber++;v.columnNumber=t-h+1}for(var b=[{currentNSMap:t}],x=[],S=0;;){try{var w=e.indexOf(`<`,S);if(w<0){if(!s&&x.length>0)return o.fatalError(`unclosed xml tag(s): `+x.join(`, `));if(!e.substring(S).match(/^\s*$/)){var k=r.doc,A=k.createTextNode(e.substring(S));if(k.documentElement)return o.error(`Extra content at the end of the document`);k.appendChild(A),r.currentElement=A}return}if(w>S){var j=e.substring(S,w);!s&&x.length===0&&(j=j.replace(new RegExp(a.S_OPT.source,`g`),``),j&&o.error(`Unexpected content outside root element: '`+j+`'`)),m(w)}switch(e.charAt(w+1)){case`/`:var F=e.indexOf(`>`,w+2),I=e.substring(w+2,F>0?F:void 0);if(!I)return o.fatalError(`end tag name missing`);var L=a.reg(`^`,a.QName_group,a.S_OPT,`$`),R=F>0&&L.exec(I);if(!R){var z=F>0&&a.reg(`^`,a.QName_group).exec(I);if(s&&z)o.warning(`end tag name contains invalid trailing characters: "`+I+`"`),R=z;else if(z&&new RegExp(L.source,L.flags+`m`).test(I))o.error(`end tag name is followed by a line break and trailing content: "`+I+`"`),R=z;else return o.fatalError(`end tag name contains invalid characters: "`+I+`"`)}if(!r.currentElement&&!r.doc.documentElement)return;var B=x[x.length-1]||r.currentElement.tagName||r.doc.documentElement.tagName||``;if(B!==R[1]){var V=R[1].toLowerCase();if(!s||B.toLowerCase()!==V)return o.fatalError(`Opening and ending tag mismatch: "`+B+`" != "`+I+`"`)}var H=b.pop();x.pop();var U=H.localNSMap;if(r.endElement(H.uri,H.localName,B),U)for(var W in U)u(U,W)&&r.endPrefixMapping(W);F++;break;case`?`:v&&y(w),F=N(e,w,r,o);break;case`!`:v&&y(w),F=M(e,w,r,o,s);break;default:v&&y(w);var G=new P,K=b[b.length-1].currentNSMap,F=E(e,w,G,K,d,o,s),q=G.length;if(G.closed||(s&&i.isHTMLVoidElement(G.tagName)?G.closed=!0:x.push(G.tagName)),v&&q){for(var ee=T(v,{}),J=0;J<q;J++){var te=G[J];y(te.offset),te.locator=T(v,{})}r.locator=ee,D(G,r,K)&&b.push(G),r.locator=v}else D(G,r,K)&&b.push(G);s&&!G.closed?F=O(e,F,G.tagName,d,r):F++}}catch(e){if(e instanceof f)throw e;if(e instanceof p)return o.fatalError(`Error constructing the DOM: `+e.name+`: `+e.message,e);o.error(`element parse error: `+e),F=-1}F>S?S=F:m(Math.max(w,S)+1)}}function T(e,t){return t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber,t}function E(e,t,n,r,i,a,o){function s(e,t,r){if(u(n.attributeNames,e))return a.fatalError(`Attribute `+e+` redefined`);if(!o&&t.indexOf(`<`)>=0)return a.fatalError(`Unescaped '<' not allowed in attributes values`);n.addValue(e,t.replace(/[\t\n\r]/g,` `).replace(C,i),r)}for(var c,l,d=++t,f=m;;){var p=e.charAt(d);if(f===m&&p===`<`)throw Error(`unexpected < in tag name: `+e.slice(t,d));switch(p){case`=`:if(f===h)c=e.slice(t,d),f=_;else if(f===g)f=_;else throw Error(`attribute equal must after attrName`);break;case`'`:case`"`:if(f===_||f===h){if(f===h&&(a.warning(`attribute value must after "="`),c=e.slice(t,d)),t=d+1,d=e.indexOf(p,t),d>0)l=e.slice(t,d),s(c,l,t-1),f=y;else throw Error(`attribute value no end '`+p+`' match`)}else if(f==v)l=e.slice(t,d),s(c,l,t),a.warning(`attribute "`+c+`" missed start quot(`+p+`)!!`),t=d+1,f=y;else throw Error(`attribute value must after "="`);break;case`/`:switch(f){case m:n.setTagName(e.slice(t,d));case y:case b:case x:f=x,n.closed=!0;case v:case h:break;case g:n.closed=!0;break;default:throw Error(`attribute invalid close char('/')`)}break;case``:return a.error(`unexpected end of input`),f==m&&n.setTagName(e.slice(t,d)),d;case`>`:switch(f){case m:n.setTagName(e.slice(t,d));case y:case b:case x:break;case v:case h:l=e.slice(t,d),l.slice(-1)===`/`&&(n.closed=!0,l=l.slice(0,-1));case g:f===g&&(l=c),f==v?(a.warning(`attribute "`+l+`" missed quot(")!`),s(c,l,t)):(o||a.warning(`attribute "`+l+`" missed value!! "`+l+`" instead!!`),s(l,l,t));break;case _:if(!o)return a.fatalError(`AttValue: ' or " expected`)}return d;case``:p=` `;default:if(p<=` `)switch(f){case m:n.setTagName(e.slice(t,d)),f=b;break;case h:c=e.slice(t,d),f=g;break;case v:var l=e.slice(t,d);a.warning(`attribute "`+l+`" missed quot(")!!`),s(c,l,t);case y:f=b}else switch(f){case g:o||a.warning(`attribute "`+c+`" missed value!! "`+c+`" instead2!!`),s(c,c,t),t=d,f=h;break;case y:a.warning(`attribute space is required"`+c+`"!!`);case b:f=h,t=d;break;case _:f=v,t=d;break;case x:throw Error(`elements closed character '/' and '>' must be connected to`)}}d++}}function D(e,t,n){for(var r=e.tagName,i=null,a=e.length;a--;){var o=e[a],s=o.qName,c=o.value,l=s.indexOf(`:`);if(l>0)var f=o.prefix=s.slice(0,l),p=s.slice(l+1),m=f===`xmlns`&&p;else p=s,f=null,m=s===`xmlns`&&``;o.localName=p,m!==!1&&(i??(i=Object.create(null),n=Object.create(n)),n[m]=i[m]=c,o.uri=d.XMLNS,t.startPrefixMapping(m,c))}for(var a=e.length;a--;)o=e[a],o.prefix&&(o.prefix===`xml`&&(o.uri=d.XML),o.prefix!==`xmlns`&&(o.uri=n[o.prefix]));var l=r.indexOf(`:`);l>0?(f=e.prefix=r.slice(0,l),p=e.localName=r.slice(l+1)):(f=null,p=e.localName=r);var h=e.uri=n[f||``];if(t.startElement(h,p,r,e),e.closed){if(t.endElement(h,p,r),i)for(f in i)u(i,f)&&t.endPrefixMapping(f)}else return e.currentNSMap=n,e.localNSMap=i,!0}function O(e,t,n,r,i){var a=s(n);if(a||l(n)){var o=RegExp(`</`+n.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)+`>`,`ig`);o.lastIndex=t;var c=o.exec(e),u=c?c.index:-1;if(u<0)return t+1;var d=e.substring(t+1,u);return a&&(d=d.replace(C,r)),i.characters(d,0,d.length),u}return t+1}function k(e,t){for(var n in e)u(e,n)&&(t[n]=e[n])}function A(e,t){var n=t;function r(t){return t||=0,e.charAt(n+t)}function i(e){e||=1,n+=e}function o(){for(var t=0;n<e.length;){var a=r();if(a!==` `&&a!==`
`&&a!==` `&&a!==`\r`)return t;t++,i()}return-1}function s(){return e.substring(n)}function c(t){return e.substring(n,n+t.length)===t}function l(t){return e.substring(n,n+t.length).toUpperCase()===t.toUpperCase()}function u(e){var t=a.reg(`^`,e).exec(s());return t?(i(t[0].length),t[0]):null}return{char:r,getIndex:function(){return n},getMatch:u,getSource:function(){return e},skip:i,skipBlanks:o,substringFromIndex:s,substringStartsWith:c,substringStartsWithCaseInsensitive:l}}function j(e,t){function n(e,t){var n=a.PI.exec(e.substringFromIndex());return n?n[1].toLowerCase()===`xml`?t.fatalError(`xml declaration is only allowed at the start of the document, but found at position `+e.getIndex()):(e.skip(n[0].length),n[0]):t.fatalError(`processing instruction is not well-formed at position `+e.getIndex())}var r=e.getSource();if(e.char()===`[`){e.skip(1);for(var i=e.getIndex();e.getIndex()<r.length;){if(e.skipBlanks(),e.char()===`]`){var o=r.substring(i,e.getIndex());return e.skip(1),o}var s=null;if(e.char()===`<`&&e.char(1)===`!`)switch(e.char(2)){case`E`:e.char(3)===`L`?s=e.getMatch(a.elementdecl):e.char(3)===`N`&&(s=e.getMatch(a.EntityDecl));break;case`A`:s=e.getMatch(a.AttlistDecl);break;case`N`:s=e.getMatch(a.NotationDecl);break;case`-`:s=e.getMatch(a.Comment)}else if(e.char()===`<`&&e.char(1)===`?`)s=n(e,t);else if(e.char()===`%`)s=e.getMatch(a.PEReference);else return t.fatalError(`Error detected in Markup declaration`);if(!s)return t.fatalError(`Error in internal subset at position `+e.getIndex())}return t.fatalError(`doctype internal subset is not well-formed, missing ]`)}}function M(e,t,n,r,i){var o=A(e,t);switch(i?o.char(2).toUpperCase():o.char(2)){case`-`:var s=o.getMatch(a.Comment);return s?(n.comment(s,a.COMMENT_START.length,s.length-a.COMMENT_START.length-a.COMMENT_END.length),o.getIndex()):r.fatalError(`comment is not well-formed at position `+o.getIndex());case`[`:var c=o.getMatch(a.CDSect);return c?!i&&!n.currentElement?r.fatalError(`CDATA outside of element`):(n.startCDATA(),n.characters(c,a.CDATA_START.length,c.length-a.CDATA_START.length-a.CDATA_END.length),n.endCDATA(),o.getIndex()):r.fatalError(`Invalid CDATA starting at position `+t);case`D`:if(n.doc&&n.doc.documentElement)return r.fatalError(`Doctype not allowed inside or after documentElement at position `+o.getIndex());if(i?!o.substringStartsWithCaseInsensitive(a.DOCTYPE_DECL_START):!o.substringStartsWith(a.DOCTYPE_DECL_START))return r.fatalError(`Expected `+a.DOCTYPE_DECL_START+` at position `+o.getIndex());if(o.skip(a.DOCTYPE_DECL_START.length),o.skipBlanks()<1)return r.fatalError(`Expected whitespace after `+a.DOCTYPE_DECL_START+` at position `+o.getIndex());var l={name:void 0,publicId:void 0,systemId:void 0,internalSubset:void 0};if(l.name=o.getMatch(a.Name),!l.name)return r.fatalError(`doctype name missing or contains unexpected characters at position `+o.getIndex());if(i&&l.name.toLowerCase()!==`html`&&r.warning(`Unexpected DOCTYPE in HTML document at position `+o.getIndex()),o.skipBlanks(),o.substringStartsWith(a.PUBLIC)||o.substringStartsWith(a.SYSTEM)){var u=a.ExternalID_match.exec(o.substringFromIndex());if(!u)return r.fatalError(`doctype external id is not well-formed at position `+o.getIndex());u.groups.SystemLiteralOnly===void 0?(l.systemId=u.groups.SystemLiteral,l.publicId=u.groups.PubidLiteral):l.systemId=u.groups.SystemLiteralOnly,o.skip(u[0].length)}else if(i&&o.substringStartsWithCaseInsensitive(a.SYSTEM)){if(o.skip(a.SYSTEM.length),o.skipBlanks()<1)return r.fatalError(`Expected whitespace after `+a.SYSTEM+` at position `+o.getIndex());if(l.systemId=o.getMatch(a.ABOUT_LEGACY_COMPAT_SystemLiteral),!l.systemId)return r.fatalError(`Expected `+a.ABOUT_LEGACY_COMPAT+` in single or double quotes after `+a.SYSTEM+` at position `+o.getIndex())}return i&&l.systemId&&!a.ABOUT_LEGACY_COMPAT_SystemLiteral.test(l.systemId)&&r.warning(`Unexpected doctype.systemId in HTML document at position `+o.getIndex()),i||(o.skipBlanks(),l.internalSubset=j(o,r)),o.skipBlanks(),o.char()===`>`?(o.skip(1),n.startDTD(l.name,l.publicId,l.systemId,l.internalSubset),n.endDTD(),o.getIndex()):r.fatalError(`doctype not terminated with > at position `+o.getIndex());default:return r.fatalError(`Not well-formed XML starting with "<!" at position `+t)}}function N(e,t,n,r){var i=e.substring(t).match(a.PI);if(!i)return r.fatalError(`Invalid processing instruction starting at position `+t);if(i[1].toLowerCase()===`xml`){if(t>0)return r.fatalError(`processing instruction at position `+t+` is an xml declaration which is only at the start of the document`);if(!a.XMLDecl.test(e.substring(t)))return r.fatalError(`xml declaration is not well-formed`)}return n.processingInstruction(i[1],i[2]),t+i[0].length}function P(){this.attributeNames=Object.create(null)}P.prototype={setTagName:function(e){if(!a.QName_exact.test(e))throw Error(`invalid tagName:`+e);this.tagName=e},addValue:function(e,t,n){if(!a.QName_exact.test(e))throw Error(`invalid attribute:`+e);this.attributeNames[e]=this.length,this[this.length++]={qName:e,value:t,offset:n}},length:0,getLocalName:function(e){return this[e].localName},getLocator:function(e){return this[e].locator},getQName:function(e){return this[e].qName},getURI:function(e){return this[e].uri},getValue:function(e){return this[e].value}},e.XMLReader=S,e.parseUtils=A,e.parseDoctypeCommentOrCData=M})),s=e((e=>{var r=t(),s=i(),c=n(),l=a(),u=o(),d=s.DOMImplementation,f=r.hasDefaultHTMLNamespace,p=r.isHTMLMimeType,m=r.isValidMimeType,h=r.MIME_TYPE,g=r.NAMESPACE,_=c.ParseError,v=u.XMLReader;function y(e){return e.replace(/\r[\n\u0085]/g,`
`).replace(/[\r\u0085\u2028\u2029]/g,`
`)}function b(e){if(e||={},e.locator===void 0&&(e.locator=!0),this.assign=e.assign||r.assign,this.domHandler=e.domHandler||x,this.onError=e.onError||e.errorHandler,e.errorHandler&&typeof e.errorHandler!=`function`)throw TypeError(`errorHandler object is no longer supported, switch to onError!`);e.errorHandler&&e.errorHandler(`warning`,"The `errorHandler` option has been deprecated, use `onError` instead!",this),this.normalizeLineEndings=e.normalizeLineEndings||y,this.locator=!!e.locator,this.xmlns=this.assign(Object.create(null),e.xmlns)}b.prototype.parseFromString=function(e,t){if(!m(t))throw TypeError(`DOMParser.parseFromString: the provided mimeType "`+t+`" is not valid.`);var n=this.assign(Object.create(null),this.xmlns),i=l.XML_ENTITIES,a=n[``]||null;f(t)?(i=l.HTML_ENTITIES,a=g.HTML):t===h.XML_SVG_IMAGE&&(a=g.SVG),n[``]=a,n.xml=n.xml||g.XML;var o=new this.domHandler({mimeType:t,defaultNamespace:a,onError:this.onError}),s=this.locator?{}:void 0;this.locator&&o.setDocumentLocator(s);var c=new v;return c.errorHandler=o,c.domBuilder=o,!r.isHTMLMimeType(t)&&typeof e!=`string`&&c.errorHandler.fatalError(`source is not a string`),c.parse(this.normalizeLineEndings(String(e)),n,i),o.doc.documentElement||c.errorHandler.fatalError(`missing root element`),o.doc};function x(e){var t=e||{};this.mimeType=t.mimeType||h.XML_APPLICATION,this.defaultNamespace=t.defaultNamespace||null,this.cdata=!1,this.currentElement=void 0,this.doc=void 0,this.locator=void 0,this.onError=t.onError}function S(e,t){t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber}x.prototype={startDocument:function(){var e=new d;this.doc=p(this.mimeType)?e.createHTMLDocument(!1):e.createDocument(this.defaultNamespace,``)},startElement:function(e,t,n,r){var i=this.doc,a=i.createElementNS(e,n||t),o=r.length;T(this,a),this.currentElement=a,this.locator&&S(this.locator,a);for(var s=0;s<o;s++){var e=r.getURI(s),c=r.getValue(s),n=r.getQName(s),l=i.createAttributeNS(e,n);this.locator&&S(r.getLocator(s),l),l.value=l.nodeValue=c,a.setAttributeNode(l)}},endElement:function(e,t,n){this.currentElement=this.currentElement.parentNode},startPrefixMapping:function(e,t){},endPrefixMapping:function(e){},processingInstruction:function(e,t){var n=this.doc.createProcessingInstruction(e,t);this.locator&&S(this.locator,n),T(this,n)},ignorableWhitespace:function(e,t,n){},characters:function(e,t,n){if(e=w.apply(this,arguments),e){if(this.cdata)var r=this.doc.createCDATASection(e);else var r=this.doc.createTextNode(e);this.currentElement?this.currentElement.appendChild(r):/^\s*$/.test(e)&&this.doc.appendChild(r),this.locator&&S(this.locator,r)}},skippedEntity:function(e){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(e){e&&(e.lineNumber=0),this.locator=e},comment:function(e,t,n){e=w.apply(this,arguments);var r=this.doc.createComment(e);this.locator&&S(this.locator,r),T(this,r)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(e,t,n,r){var i=this.doc.implementation;if(i&&i.createDocumentType){var a=i.createDocumentType(e,t,n,r);this.locator&&S(this.locator,a),T(this,a),this.doc.doctype=a}},reportError:function(e,t){if(typeof this.onError==`function`)try{this.onError(e,t,this)}catch(n){throw new _(`Reporting `+e+` "`+t+`" caused `+n,this.locator)}else console.error(`[xmldom `+e+`] `+t,C(this.locator))},warning:function(e){this.reportError(`warning`,e)},error:function(e){this.reportError(`error`,e)},fatalError:function(e,t){throw this.reportError(`fatalError`,e),new _(e,this.locator,t)}};function C(e){if(e)return`
@#[line:`+e.lineNumber+`,col:`+e.columnNumber+`]`}function w(e,t,n){return typeof e==`string`?e.substr(t,n):e.length>=t+n||t?new java.lang.String(e,t,n)+``:e}`endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl`.replace(/\w+/g,function(e){x.prototype[e]=function(){return null}});function T(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}function E(e){if(e===`error`)throw`onErrorStopParsing`}function D(){throw`onWarningStopParsing`}e.__DOMHandler=x,e.DOMParser=b,e.normalizeLineEndings=y,e.onErrorStopParsing=E,e.onWarningStopParsing=D})),c=e((e=>{var r=t();e.assign=r.assign,e.hasDefaultHTMLNamespace=r.hasDefaultHTMLNamespace,e.isHTMLMimeType=r.isHTMLMimeType,e.isValidMimeType=r.isValidMimeType,e.MIME_TYPE=r.MIME_TYPE,e.NAMESPACE=r.NAMESPACE;var a=n();e.DOMException=a.DOMException,e.DOMExceptionName=a.DOMExceptionName,e.ExceptionCode=a.ExceptionCode,e.ParseError=a.ParseError;var o=i();e.Attr=o.Attr,e.CDATASection=o.CDATASection,e.CharacterData=o.CharacterData,e.Comment=o.Comment,e.Document=o.Document,e.DocumentFragment=o.DocumentFragment,e.DocumentType=o.DocumentType,e.DOMImplementation=o.DOMImplementation,e.Element=o.Element,e.Entity=o.Entity,e.EntityReference=o.EntityReference,e.LiveNodeList=o.LiveNodeList,e.NamedNodeMap=o.NamedNodeMap,e.Node=o.Node,e.NodeList=o.NodeList,e.Notation=o.Notation,e.ProcessingInstruction=o.ProcessingInstruction,e.Text=o.Text,e.XMLSerializer=o.XMLSerializer;var c=s();e.DOMParser=c.DOMParser,e.normalizeLineEndings=c.normalizeLineEndings,e.onErrorStopParsing=c.onErrorStopParsing,e.onWarningStopParsing=c.onWarningStopParsing}))();function l(e,t,n){switch(n){case 1:return e.getUint8(t);case 2:return e.getUint16(t);case 4:return e.getUint32(t);case 8:{let n=e.getUint32(t),r=e.getUint32(t+4);return n*4294967296+r}default:throw Error(`Unsupported int size: ${n}`)}}function u(e){let t=new DataView(e.buffer,e.byteOffset,e.byteLength),n=e.byteLength;if(String.fromCharCode(...e.subarray(0,8))!==`bplist00`)throw Error(`Invalid binary plist: bad magic`);let r=n-32,i=t.getUint8(r+6),a=t.getUint8(r+7),o=l(t,r+8,8),s=l(t,r+16,8),c=l(t,r+24,8),u=[];for(let e=0;e<o;e++)u.push(l(t,c+e*i,i));function d(n){let r=u[n],i=t.getUint8(r),o=i>>4,s=i&15;if(r++,o!==0&&o!==8&&s===15){let e=t.getUint8(r);r++;let n=1<<(e&15);s=l(t,r,n),r+=n}switch(o){case 0:if(i===0)return null;if(i===8)return!1;if(i===9)return!0;throw Error(`Unknown singleton: 0x${i.toString(16)}`);case 1:{let e=1<<s;if(e<=4)return l(t,r,e);let n=t.getInt32(r),i=t.getUint32(r+4);return n*4294967296+i}case 2:{let e=1<<s;if(e===4)return t.getFloat32(r);if(e===8)return t.getFloat64(r);throw Error(`Unsupported real size: ${e}`)}case 3:{let e=t.getFloat64(r);return new Date(e*1e3+9783072e5)}case 4:return new Uint8Array(e.buffer,e.byteOffset+r,s);case 5:{let e=``;for(let n=0;n<s;n++)e+=String.fromCharCode(t.getUint8(r+n));return e}case 6:{let e=``;for(let n=0;n<s;n++)e+=String.fromCharCode(t.getUint16(r+n*2));return e}case 8:{let e=s+1;return{UID:l(t,r,e)}}case 10:{let e=[];for(let n=0;n<s;n++){let i=l(t,r+n*a,a);e.push(d(i))}return e}case 13:{let e={};for(let n=0;n<s;n++){let i=l(t,r+n*a,a),o=l(t,r+(s+n)*a,a),c=d(i);e[c]=d(o)}return e}default:throw Error(`Unknown object type: 0x${o.toString(16)}`)}}return d(s)}var d=class{input;pos;constructor(e){this.input=e,this.pos=0}skipWhitespaceAndComments(){for(;this.pos<this.input.length;){let e=this.input[this.pos];if(/\s/.test(e)){this.pos++;continue}if(e===`/`&&this.pos+1<this.input.length&&this.input[this.pos+1]===`*`){this.pos+=2;let e=this.input.indexOf(`*/`,this.pos);if(e===-1)throw Error(`Unterminated block comment`);this.pos=e+2;continue}if(e===`/`&&this.pos+1<this.input.length&&this.input[this.pos+1]===`/`){this.pos+=2;let e=this.input.indexOf(`
`,this.pos);this.pos=e===-1?this.input.length:e+1;continue}break}}parseValue(){if(this.skipWhitespaceAndComments(),this.pos>=this.input.length)throw Error(`Unexpected end of input`);let e=this.input[this.pos];return e===`{`?this.parseDict():e===`(`?this.parseArray():e===`<`?this.parseData():e===`"`?this.parseQuotedString():this.parseUnquotedString()}parseDict(){this.pos++;let e={};for(;;){if(this.skipWhitespaceAndComments(),this.pos>=this.input.length)throw Error(`Unterminated dictionary`);if(this.input[this.pos]===`}`)return this.pos++,e;let t=this.parseValue();if(this.skipWhitespaceAndComments(),this.pos>=this.input.length||this.input[this.pos]!==`=`)throw Error(`Expected '=' after key "${t}" at position ${this.pos}`);this.pos++,e[t]=this.parseValue(),this.skipWhitespaceAndComments(),this.pos<this.input.length&&this.input[this.pos]===`;`&&this.pos++}}parseArray(){this.pos++;let e=[];if(this.skipWhitespaceAndComments(),this.pos<this.input.length&&this.input[this.pos]===`)`)return this.pos++,e;for(;;){if(e.push(this.parseValue()),this.skipWhitespaceAndComments(),this.pos>=this.input.length)throw Error(`Unterminated array`);if(this.input[this.pos]===`)`)return this.pos++,e;if(this.input[this.pos]===`,`){if(this.pos++,this.skipWhitespaceAndComments(),this.pos<this.input.length&&this.input[this.pos]===`)`)return this.pos++,e}else throw Error(`Expected ',' or ')' in array at position ${this.pos}`)}}parseData(){this.pos++;let e=``;for(;this.pos<this.input.length;){let t=this.input[this.pos];if(t===`>`){this.pos++;let t=e.replace(/\s+/g,``),n=new Uint8Array(t.length/2);for(let e=0;e<t.length;e+=2)n[e/2]=parseInt(t.substring(e,e+2),16);return n}e+=t,this.pos++}throw Error(`Unterminated data`)}parseQuotedString(){this.pos++;let e=``;for(;this.pos<this.input.length;){let t=this.input[this.pos];if(t===`\\`){if(this.pos++,this.pos>=this.input.length)throw Error(`Unterminated string escape`);let t=this.input[this.pos];switch(t){case`"`:e+=`"`;break;case`\\`:e+=`\\`;break;case`n`:e+=`
`;break;case`t`:e+=` `;break;case`r`:e+=`\r`;break;case`0`:e+=`\0`;break;default:e+=t}this.pos++;continue}if(t===`"`)return this.pos++,e;e+=t,this.pos++}throw Error(`Unterminated string`)}parseUnquotedString(){let e=this.pos;for(;this.pos<this.input.length;){let e=this.input[this.pos];if(/[a-zA-Z0-9._\/$:-]/.test(e))this.pos++;else break}if(this.pos===e)throw Error(`Unexpected character '${this.input[this.pos]}' at position ${this.pos}`);return this.input.substring(e,this.pos)}};function f(e){return new d(e).parseValue()}function p(e){let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}function m(e){return e.nodeType===3||e.nodeType===8||e.nodeType===4}function h(e){return!e.childNodes||e.childNodes.length===0}function g(e,t){if(!e)throw Error(t)}function _(e){if(e instanceof ArrayBuffer)return u(new Uint8Array(e));if(e instanceof Uint8Array)return u(e);if(typeof e==`string`&&e.startsWith(`bplist`))return u(new TextEncoder().encode(e));if(typeof e==`string`){let t=e.trimStart();if((t[0]===`{`||t[0]===`(`)&&!t.startsWith(`<?xml`)&&!t.startsWith(`<!DOCTYPE`)&&!t.startsWith(`<plist`))return f(e)}let t=new c.DOMParser().parseFromString(e,`text/xml`).documentElement;g(t!==null&&t.nodeName===`plist`,`malformed document. First element should be <plist>`);let n=v(t);return Array.isArray(n)&&n.length==1&&(n=n[0]),n}function v(e){if(!e)return null;if(e.nodeName===`plist`){let t=[];if(h(e))return t;for(let n=0;n<e.childNodes.length;n++)m(e.childNodes[n])||t.push(v(e.childNodes[n]));return t}if(e.nodeName===`dict`){let t={},n=null,r=0;if(h(e))return t;for(let i=0;i<e.childNodes.length;i++)m(e.childNodes[i])||(r%2==0?(g(e.childNodes[i].nodeName===`key`,`Missing key while parsing <dict/>.`),n=v(e.childNodes[i])):(g(e.childNodes[i].nodeName!==`key`,`Unexpected <key> while parsing <dict/>. Keys and values must alternate.`),t[n]=v(e.childNodes[i])),r+=1);return r%2==1&&(t[n]=``),t}if(e.nodeName===`array`){let t=[];if(h(e))return t;for(let n=0;n<e.childNodes.length;n++)if(!m(e.childNodes[n])){let r=v(e.childNodes[n]);r!=null&&t.push(r)}return t}if(e.nodeName!==`#text`){if(e.nodeName===`key`)return h(e)?``:(g(e.childNodes[0].nodeValue!==`__proto__`,`__proto__ keys can lead to prototype pollution. More details on CVE-2022-22912`),e.childNodes[0].nodeValue);if(e.nodeName===`string`){let t=``;if(h(e))return t;for(let n=0;n<e.childNodes.length;n++){let r=e.childNodes[n].nodeType;(r===3||r===4)&&(t+=e.childNodes[n].nodeValue)}return t}if(e.nodeName===`integer`)return g(!h(e),`Cannot parse "" as integer.`),parseInt(e.childNodes[0].nodeValue,10);if(e.nodeName===`real`){g(!h(e),`Cannot parse "" as real.`);let t=``;for(let n=0;n<e.childNodes.length;n++)e.childNodes[n].nodeType===3&&(t+=e.childNodes[n].nodeValue);return parseFloat(t)}if(e.nodeName===`data`){let t=``;if(h(e))return p(t);for(let n=0;n<e.childNodes.length;n++)e.childNodes[n].nodeType===3&&(t+=e.childNodes[n].nodeValue.replace(/\s+/g,``));return p(t)}if(e.nodeName===`date`)return g(!h(e),`Cannot parse "" as Date.`),new Date(e.childNodes[0].nodeValue);if(e.nodeName===`null`)return null;if(e.nodeName===`true`)return!0;if(e.nodeName===`false`)return!1;throw Error(`Invalid PLIST tag `+e.nodeName)}return null}var y=e(((e,t)=>{(function(){var e,n,r,i,a,o,s,c={}.hasOwnProperty;e=function(e,...t){var n,r,i,o;if(a(Object.assign))Object.assign.apply(null,arguments);else for(n=0,i=t.length;n<i;n++)if(o=t[n],o!=null)for(r in o)c.call(o,r)&&(e[r]=o[r]);return e},a=function(e){return!!e&&Object.prototype.toString.call(e)===`[object Function]`},o=function(e){var t;return!!e&&((t=typeof e)==`function`||t===`object`)},r=function(e){return a(Array.isArray)?Array.isArray(e):Object.prototype.toString.call(e)===`[object Array]`},i=function(e){var t;if(r(e))return!e.length;for(t in e)if(c.call(e,t))return!1;return!0},s=function(e){var t,n;return o(e)&&(n=Object.getPrototypeOf(e))&&(t=n.constructor)&&typeof t==`function`&&t instanceof t&&Function.prototype.toString.call(t)===Function.prototype.toString.call(Object)},n=function(e){return a(e.valueOf)?e.valueOf():e},t.exports.assign=e,t.exports.isFunction=a,t.exports.isObject=o,t.exports.isArray=r,t.exports.isEmpty=i,t.exports.isPlainObject=s,t.exports.getValue=n}).call(e)})),b=e(((e,t)=>{(function(){t.exports=class{hasFeature(e,t){return!0}createDocumentType(e,t,n){throw Error(`This DOM method is not implemented.`)}createDocument(e,t,n){throw Error(`This DOM method is not implemented.`)}createHTMLDocument(e){throw Error(`This DOM method is not implemented.`)}getFeature(e,t){throw Error(`This DOM method is not implemented.`)}}}).call(e)})),x=e(((e,t)=>{(function(){t.exports=class{constructor(){}handleError(e){throw Error(e)}}}).call(e)})),S=e(((e,t)=>{(function(){t.exports=(function(){class e{constructor(e){this.arr=e||[]}item(e){return this.arr[e]||null}contains(e){return this.arr.indexOf(e)!==-1}}return Object.defineProperty(e.prototype,"length",{get:function(){return this.arr.length}}),e}).call(this)}).call(e)})),C=e(((e,t)=>{(function(){var e=x(),n=S();t.exports=(function(){class t{constructor(){this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new e,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":``,"schema-type":``,"split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=Object.create(this.defaultParams)}getParameter(e){return this.params.hasOwnProperty(e)?this.params[e]:null}canSetParameter(e,t){return!0}setParameter(e,t){return t==null?delete this.params[e]:this.params[e]=t}}return Object.defineProperty(t.prototype,"parameterNames",{get:function(){return new n(Object.keys(this.defaultParams))}}),t}).call(this)}).call(e)})),w=e(((e,t)=>{(function(){t.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(e)})),T=e(((e,t)=>{(function(){var e=w();U(),t.exports=(function(){class t{constructor(t,n,r){if(this.parent=t,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),n==null)throw Error(`Missing attribute name. `+this.debugInfo(n));this.name=this.stringify.name(n),this.value=this.stringify.attValue(r),this.type=e.Attribute,this.isId=!1,this.schemaTypeInfo=null}clone(){return Object.create(this)}toString(e){return this.options.writer.attribute(this,this.options.writer.filterOptions(e))}debugInfo(e){return e||=this.name,e==null?`parent: <`+this.parent.name+`>`:`attribute: {`+e+`}, parent: <`+this.parent.name+`>`}isEqualNode(e){return e.namespaceURI===this.namespaceURI&&e.prefix===this.prefix&&e.localName===this.localName&&e.value===this.value}}return Object.defineProperty(t.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(t.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(t.prototype,"textContent",{get:function(){return this.value},set:function(e){return this.value=e||``}}),Object.defineProperty(t.prototype,"namespaceURI",{get:function(){return``}}),Object.defineProperty(t.prototype,"prefix",{get:function(){return``}}),Object.defineProperty(t.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"specified",{get:function(){return!0}}),t}).call(this)}).call(e)})),E=e(((e,t)=>{(function(){t.exports=(function(){class e{constructor(e){this.nodes=e}clone(){return this.nodes=null}getNamedItem(e){return this.nodes[e]}setNamedItem(e){var t=this.nodes[e.nodeName];return this.nodes[e.nodeName]=e,t||null}removeNamedItem(e){var t=this.nodes[e];return delete this.nodes[e],t||null}item(e){return this.nodes[Object.keys(this.nodes)[e]]||null}getNamedItemNS(e,t){throw Error(`This DOM method is not implemented.`)}setNamedItemNS(e){throw Error(`This DOM method is not implemented.`)}removeNamedItemNS(e,t){throw Error(`This DOM method is not implemented.`)}}return Object.defineProperty(e.prototype,"length",{get:function(){return Object.keys(this.nodes).length||0}}),e}).call(this)}).call(e)})),D=e(((e,t)=>{(function(){var e,n,r,i,a,o,s,c={}.hasOwnProperty;({isObject:s,isFunction:o,getValue:a}=y()),i=U(),e=w(),n=T(),r=E(),t.exports=(function(){class t extends i{constructor(t,n,r){var i,a,o,s;if(super(t),n==null)throw Error(`Missing element name. `+this.debugInfo());if(this.name=this.stringify.name(n),this.type=e.Element,this.attribs={},this.schemaTypeInfo=null,r!=null&&this.attribute(r),t.type===e.Document&&(this.isRoot=!0,this.documentObject=t,t.rootObject=this,t.children)){for(s=t.children,a=0,o=s.length;a<o;a++)if(i=s[a],i.type===e.DocType){i.name=this.name;break}}}clone(){var e,t,n=Object.create(this),r;for(t in n.isRoot&&(n.documentObject=null),n.attribs={},r=this.attribs,r)c.call(r,t)&&(e=r[t],n.attribs[t]=e.clone());return n.children=[],this.children.forEach(function(e){var t=e.clone();return t.parent=n,n.children.push(t)}),n}attribute(e,t){var r,i;if(e!=null&&(e=a(e)),s(e))for(r in e)c.call(e,r)&&(i=e[r],this.attribute(r,i));else o(t)&&(t=t.apply()),this.options.keepNullAttributes&&t==null?this.attribs[e]=new n(this,e,``):t!=null&&(this.attribs[e]=new n(this,e,t));return this}removeAttribute(e){var t,n,r;if(e==null)throw Error(`Missing attribute name. `+this.debugInfo());if(e=a(e),Array.isArray(e))for(n=0,r=e.length;n<r;n++)t=e[n],delete this.attribs[t];else delete this.attribs[e];return this}toString(e){return this.options.writer.element(this,this.options.writer.filterOptions(e))}att(e,t){return this.attribute(e,t)}a(e,t){return this.attribute(e,t)}getAttribute(e){return this.attribs.hasOwnProperty(e)?this.attribs[e].value:null}setAttribute(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getAttributeNode(e){return this.attribs.hasOwnProperty(e)?this.attribs[e]:null}setAttributeNode(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}removeAttributeNode(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByTagName(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getAttributeNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}setAttributeNS(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}removeAttributeNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getAttributeNodeNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}setAttributeNodeNS(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByTagNameNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}hasAttribute(e){return this.attribs.hasOwnProperty(e)}hasAttributeNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}setIdAttribute(e,t){return this.attribs.hasOwnProperty(e)?this.attribs[e].isId:t}setIdAttributeNS(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}setIdAttributeNode(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByTagName(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByTagNameNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByClassName(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}isEqualNode(e){var t,n,r;if(!super.isEqualNode(e)||e.namespaceURI!==this.namespaceURI||e.prefix!==this.prefix||e.localName!==this.localName||e.attribs.length!==this.attribs.length)return!1;for(t=n=0,r=this.attribs.length-1;0<=r?n<=r:n>=r;t=0<=r?++n:--n)if(!this.attribs[t].isEqualNode(e.attribs[t]))return!1;return!0}}return Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"namespaceURI",{get:function(){return``}}),Object.defineProperty(t.prototype,"prefix",{get:function(){return``}}),Object.defineProperty(t.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"id",{get:function(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}),Object.defineProperty(t.prototype,"className",{get:function(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}),Object.defineProperty(t.prototype,"classList",{get:function(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}),Object.defineProperty(t.prototype,"attributes",{get:function(){return(!this.attributeMap||!this.attributeMap.nodes)&&(this.attributeMap=new r(this.attribs)),this.attributeMap}}),t}).call(this)}).call(e)})),O=e(((e,t)=>{(function(){var e=U();t.exports=(function(){class t extends e{constructor(e){super(e),this.value=``}clone(){return Object.create(this)}substringData(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}appendData(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}insertData(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}deleteData(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}replaceData(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}isEqualNode(e){return!(!super.isEqualNode(e)||e.data!==this.data)}}return Object.defineProperty(t.prototype,"data",{get:function(){return this.value},set:function(e){return this.value=e||``}}),Object.defineProperty(t.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(t.prototype,"textContent",{get:function(){return this.value},set:function(e){return this.value=e||``}}),t}).call(this)}).call(e)})),k=e(((e,t)=>{(function(){var e=w(),n=O();t.exports=class extends n{constructor(t,n){if(super(t),n==null)throw Error(`Missing CDATA text. `+this.debugInfo());this.name=`#cdata-section`,this.type=e.CData,this.value=this.stringify.cdata(n)}clone(){return Object.create(this)}toString(e){return this.options.writer.cdata(this,this.options.writer.filterOptions(e))}}}).call(e)})),A=e(((e,t)=>{(function(){var e=w(),n=O();t.exports=class extends n{constructor(t,n){if(super(t),n==null)throw Error(`Missing comment text. `+this.debugInfo());this.name=`#comment`,this.type=e.Comment,this.value=this.stringify.comment(n)}clone(){return Object.create(this)}toString(e){return this.options.writer.comment(this,this.options.writer.filterOptions(e))}}}).call(e)})),j=e(((e,t)=>{(function(){var e,n,r;({isObject:r}=y()),n=U(),e=w(),t.exports=class extends n{constructor(t,n,i,a){super(t),r(n)&&({version:n,encoding:i,standalone:a}=n),n||=`1.0`,this.type=e.Declaration,this.version=this.stringify.xmlVersion(n),i!=null&&(this.encoding=this.stringify.xmlEncoding(i)),a!=null&&(this.standalone=this.stringify.xmlStandalone(a))}toString(e){return this.options.writer.declaration(this,this.options.writer.filterOptions(e))}}}).call(e)})),M=e(((e,t)=>{(function(){var e,n=U();e=w(),t.exports=class extends n{constructor(t,n,r,i,a,o){if(super(t),n==null)throw Error(`Missing DTD element name. `+this.debugInfo());if(r==null)throw Error(`Missing DTD attribute name. `+this.debugInfo(n));if(!i)throw Error(`Missing DTD attribute type. `+this.debugInfo(n));if(!a)throw Error(`Missing DTD attribute default. `+this.debugInfo(n));if(a.indexOf(`#`)!==0&&(a=`#`+a),!a.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw Error(`Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. `+this.debugInfo(n));if(o&&!a.match(/^(#FIXED|#DEFAULT)$/))throw Error(`Default value only applies to #FIXED or #DEFAULT. `+this.debugInfo(n));this.elementName=this.stringify.name(n),this.type=e.AttributeDeclaration,this.attributeName=this.stringify.name(r),this.attributeType=this.stringify.dtdAttType(i),o&&(this.defaultValue=this.stringify.dtdAttDefault(o)),this.defaultValueType=a}toString(e){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(e))}}}).call(e)})),N=e(((e,t)=>{(function(){var e,n,r;({isObject:r}=y()),n=U(),e=w(),t.exports=(function(){class t extends n{constructor(t,n,i,a){if(super(t),i==null)throw Error(`Missing DTD entity name. `+this.debugInfo(i));if(a==null)throw Error(`Missing DTD entity value. `+this.debugInfo(i));if(this.pe=!!n,this.name=this.stringify.name(i),this.type=e.EntityDeclaration,!r(a))this.value=this.stringify.dtdEntityValue(a),this.internal=!0;else{if(!a.pubID&&!a.sysID)throw Error(`Public and/or system identifiers are required for an external entity. `+this.debugInfo(i));if(a.pubID&&!a.sysID)throw Error(`System identifier is required for a public external entity. `+this.debugInfo(i));if(this.internal=!1,a.pubID!=null&&(this.pubID=this.stringify.dtdPubID(a.pubID)),a.sysID!=null&&(this.sysID=this.stringify.dtdSysID(a.sysID)),a.nData!=null&&(this.nData=this.stringify.dtdNData(a.nData)),this.pe&&this.nData)throw Error(`Notation declaration is not allowed in a parameter entity. `+this.debugInfo(i))}}toString(e){return this.options.writer.dtdEntity(this,this.options.writer.filterOptions(e))}}return Object.defineProperty(t.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(t.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(t.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(t.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(t.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(t.prototype,"xmlVersion",{get:function(){return null}}),t}).call(this)}).call(e)})),P=e(((e,t)=>{(function(){var e,n=U();e=w(),t.exports=class extends n{constructor(t,n,r){if(super(t),n==null)throw Error(`Missing DTD element name. `+this.debugInfo());r||=`(#PCDATA)`,Array.isArray(r)&&(r=`(`+r.join(`,`)+`)`),this.name=this.stringify.name(n),this.type=e.ElementDeclaration,this.value=this.stringify.dtdElementValue(r)}toString(e){return this.options.writer.dtdElement(this,this.options.writer.filterOptions(e))}}}).call(e)})),F=e(((e,t)=>{(function(){var e,n=U();e=w(),t.exports=(function(){class t extends n{constructor(t,n,r){if(super(t),n==null)throw Error(`Missing DTD notation name. `+this.debugInfo(n));if(!r.pubID&&!r.sysID)throw Error(`Public or system identifiers are required for an external entity. `+this.debugInfo(n));this.name=this.stringify.name(n),this.type=e.NotationDeclaration,r.pubID!=null&&(this.pubID=this.stringify.dtdPubID(r.pubID)),r.sysID!=null&&(this.sysID=this.stringify.dtdSysID(r.sysID))}toString(e){return this.options.writer.dtdNotation(this,this.options.writer.filterOptions(e))}}return Object.defineProperty(t.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(t.prototype,"systemId",{get:function(){return this.sysID}}),t}).call(this)}).call(e)})),I=e(((e,t)=>{(function(){var e,n,r,i,a,o,s,c;({isObject:c}=y()),s=U(),e=w(),n=M(),i=N(),r=P(),a=F(),o=E(),t.exports=(function(){class t extends s{constructor(t,n,r){var i,a,o,s;if(super(t),this.type=e.DocType,t.children){for(s=t.children,a=0,o=s.length;a<o;a++)if(i=s[a],i.type===e.Element){this.name=i.name;break}}this.documentObject=t,c(n)&&({pubID:n,sysID:r}=n),r??([r,n]=[n,r]),n!=null&&(this.pubID=this.stringify.dtdPubID(n)),r!=null&&(this.sysID=this.stringify.dtdSysID(r))}element(e,t){var n=new r(this,e,t);return this.children.push(n),this}attList(e,t,r,i,a){var o=new n(this,e,t,r,i,a);return this.children.push(o),this}entity(e,t){var n=new i(this,!1,e,t);return this.children.push(n),this}pEntity(e,t){var n=new i(this,!0,e,t);return this.children.push(n),this}notation(e,t){var n=new a(this,e,t);return this.children.push(n),this}toString(e){return this.options.writer.docType(this,this.options.writer.filterOptions(e))}ele(e,t){return this.element(e,t)}att(e,t,n,r,i){return this.attList(e,t,n,r,i)}ent(e,t){return this.entity(e,t)}pent(e,t){return this.pEntity(e,t)}not(e,t){return this.notation(e,t)}up(){return this.root()||this.documentObject}isEqualNode(e){return!(!super.isEqualNode(e)||e.name!==this.name||e.publicId!==this.publicId||e.systemId!==this.systemId)}}return Object.defineProperty(t.prototype,"entities",{get:function(){var t,n,r,i={},a=this.children;for(n=0,r=a.length;n<r;n++)t=a[n],t.type===e.EntityDeclaration&&!t.pe&&(i[t.name]=t);return new o(i)}}),Object.defineProperty(t.prototype,"notations",{get:function(){var t,n,r,i={},a=this.children;for(n=0,r=a.length;n<r;n++)t=a[n],t.type===e.NotationDeclaration&&(i[t.name]=t);return new o(i)}}),Object.defineProperty(t.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(t.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(t.prototype,"internalSubset",{get:function(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}),t}).call(this)}).call(e)})),L=e(((e,t)=>{(function(){var e=w(),n=U();t.exports=class extends n{constructor(t,n){if(super(t),n==null)throw Error(`Missing raw text. `+this.debugInfo());this.type=e.Raw,this.value=this.stringify.raw(n)}clone(){return Object.create(this)}toString(e){return this.options.writer.raw(this,this.options.writer.filterOptions(e))}}}).call(e)})),R=e(((e,t)=>{(function(){var e=w(),n=O();t.exports=(function(){class t extends n{constructor(t,n){if(super(t),n==null)throw Error(`Missing element text. `+this.debugInfo());this.name=`#text`,this.type=e.Text,this.value=this.stringify.text(n)}clone(){return Object.create(this)}toString(e){return this.options.writer.text(this,this.options.writer.filterOptions(e))}splitText(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}replaceWholeText(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}return Object.defineProperty(t.prototype,"isElementContentWhitespace",{get:function(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}),Object.defineProperty(t.prototype,"wholeText",{get:function(){var e,t,n=``;for(t=this.previousSibling;t;)n=t.data+n,t=t.previousSibling;for(n+=this.data,e=this.nextSibling;e;)n+=e.data,e=e.nextSibling;return n}}),t}).call(this)}).call(e)})),z=e(((e,t)=>{(function(){var e=w(),n=O();t.exports=class extends n{constructor(t,n,r){if(super(t),n==null)throw Error(`Missing instruction target. `+this.debugInfo());this.type=e.ProcessingInstruction,this.target=this.stringify.insTarget(n),this.name=this.target,r&&(this.value=this.stringify.insValue(r))}clone(){return Object.create(this)}toString(e){return this.options.writer.processingInstruction(this,this.options.writer.filterOptions(e))}isEqualNode(e){return!(!super.isEqualNode(e)||e.target!==this.target)}}}).call(e)})),B=e(((e,t)=>{(function(){var e,n=U();e=w(),t.exports=class extends n{constructor(t){super(t),this.type=e.Dummy}clone(){return Object.create(this)}toString(e){return``}}}).call(e)})),V=e(((e,t)=>{(function(){t.exports=(function(){class e{constructor(e){this.nodes=e}clone(){return this.nodes=null}item(e){return this.nodes[e]||null}}return Object.defineProperty(e.prototype,"length",{get:function(){return this.nodes.length||0}}),e}).call(this)}).call(e)})),H=e(((e,t)=>{(function(){t.exports={Disconnected:1,Preceding:2,Following:4,Contains:8,ContainedBy:16,ImplementationSpecific:32}}).call(e)})),U=e(((e,t)=>{(function(){var e,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_={}.hasOwnProperty,v=[].splice;({isObject:g,isFunction:h,isEmpty:m,getValue:p}=y()),c=null,r=null,i=null,a=null,o=null,d=null,f=null,u=null,s=null,n=null,l=null,e=null,t.exports=(function(){class t{constructor(t){this.parent=t,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.value=null,this.children=[],this.baseURI=null,c||(c=D(),r=k(),i=A(),a=j(),o=I(),d=L(),f=R(),u=z(),s=B(),n=w(),l=V(),E(),e=H())}setParent(e){var t,n,r,i,a;for(this.parent=e,e&&(this.options=e.options,this.stringify=e.stringify),i=this.children,a=[],n=0,r=i.length;n<r;n++)t=i[n],a.push(t.setParent(this));return a}element(e,t,n){var r,i,a,o,s,c=null,l,u,d;if(t===null&&n==null&&([t,n]=[{},null]),t??={},t=p(t),g(t)||([n,t]=[t,n]),e!=null&&(e=p(e)),Array.isArray(e))for(a=0,l=e.length;a<l;a++)i=e[a],c=this.element(i);else if(h(e))c=this.element(e.apply());else if(g(e)){for(s in e)if(_.call(e,s)){if(d=e[s],h(d)&&(d=d.apply()),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&s.indexOf(this.stringify.convertAttKey)===0)c=this.attribute(s.substr(this.stringify.convertAttKey.length),d);else if(!this.options.separateArrayItems&&Array.isArray(d)&&m(d))c=this.dummy();else if(g(d)&&m(d))c=this.element(s);else if(!this.options.keepNullNodes&&d==null)c=this.dummy();else if(!this.options.separateArrayItems&&Array.isArray(d))for(o=0,u=d.length;o<u;o++)i=d[o],r={},r[s]=i,c=this.element(r);else g(d)?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&s.indexOf(this.stringify.convertTextKey)===0?c=this.element(d):(c=this.element(s),c.element(d)):c=this.element(s,d)}}else c=!this.options.keepNullNodes&&n===null?this.dummy():!this.options.ignoreDecorators&&this.stringify.convertTextKey&&e.indexOf(this.stringify.convertTextKey)===0?this.text(n):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&e.indexOf(this.stringify.convertCDataKey)===0?this.cdata(n):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&e.indexOf(this.stringify.convertCommentKey)===0?this.comment(n):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&e.indexOf(this.stringify.convertRawKey)===0?this.raw(n):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&e.indexOf(this.stringify.convertPIKey)===0?this.instruction(e.substr(this.stringify.convertPIKey.length),n):this.node(e,t,n);if(c==null)throw Error(`Could not create any elements with: `+e+`. `+this.debugInfo());return c}insertBefore(e,t,n){var r,i,a,o,s;if(e?.type)return a=e,o=t,a.setParent(this),o?(i=children.indexOf(o),s=children.splice(i),children.push(a),Array.prototype.push.apply(children,s)):children.push(a),a;if(this.isRoot)throw Error(`Cannot insert elements at root level. `+this.debugInfo(e));return i=this.parent.children.indexOf(this),s=this.parent.children.splice(i),r=this.parent.element(e,t,n),Array.prototype.push.apply(this.parent.children,s),r}insertAfter(e,t,n){var r,i,a;if(this.isRoot)throw Error(`Cannot insert elements at root level. `+this.debugInfo(e));return i=this.parent.children.indexOf(this),a=this.parent.children.splice(i+1),r=this.parent.element(e,t,n),Array.prototype.push.apply(this.parent.children,a),r}remove(){var e;if(this.isRoot)throw Error(`Cannot remove the root element. `+this.debugInfo());return e=this.parent.children.indexOf(this),v.apply(this.parent.children,[e,e-e+1]),this.parent}node(e,t,n){var r;return e!=null&&(e=p(e)),t||={},t=p(t),g(t)||([n,t]=[t,n]),r=new c(this,e,t),n!=null&&r.text(n),this.children.push(r),r}text(e){var t;return g(e)&&this.element(e),t=new f(this,e),this.children.push(t),this}cdata(e){var t=new r(this,e);return this.children.push(t),this}comment(e){var t=new i(this,e);return this.children.push(t),this}commentBefore(e){var t=this.parent.children.indexOf(this),n=this.parent.children.splice(t);return this.parent.comment(e),Array.prototype.push.apply(this.parent.children,n),this}commentAfter(e){var t=this.parent.children.indexOf(this),n=this.parent.children.splice(t+1);return this.parent.comment(e),Array.prototype.push.apply(this.parent.children,n),this}raw(e){var t=new d(this,e);return this.children.push(t),this}dummy(){return new s(this)}instruction(e,t){var n,r,i,a,o;if(e!=null&&(e=p(e)),t!=null&&(t=p(t)),Array.isArray(e))for(a=0,o=e.length;a<o;a++)n=e[a],this.instruction(n);else if(g(e))for(n in e)_.call(e,n)&&(r=e[n],this.instruction(n,r));else h(t)&&(t=t.apply()),i=new u(this,e,t),this.children.push(i);return this}instructionBefore(e,t){var n=this.parent.children.indexOf(this),r=this.parent.children.splice(n);return this.parent.instruction(e,t),Array.prototype.push.apply(this.parent.children,r),this}instructionAfter(e,t){var n=this.parent.children.indexOf(this),r=this.parent.children.splice(n+1);return this.parent.instruction(e,t),Array.prototype.push.apply(this.parent.children,r),this}declaration(e,t,r){var i=this.document(),o=new a(i,e,t,r);return i.children.length===0?i.children.unshift(o):i.children[0].type===n.Declaration?i.children[0]=o:i.children.unshift(o),i.root()||i}dtd(e,t){var r,i=this.document(),a=new o(i,e,t),s,c,l,u,d,f=i.children,p;for(s=c=0,u=f.length;c<u;s=++c)if(r=f[s],r.type===n.DocType)return i.children[s]=a,a;for(p=i.children,s=l=0,d=p.length;l<d;s=++l)if(r=p[s],r.isRoot)return i.children.splice(s,0,a),a;return i.children.push(a),a}up(){if(this.isRoot)throw Error(`The root node has no parent. Use doc() if you need to get the document object.`);return this.parent}root(){for(var e=this;e;)if(e.type===n.Document)return e.rootObject;else if(e.isRoot)return e;else e=e.parent}document(){for(var e=this;e;)if(e.type===n.Document)return e;else e=e.parent}end(e){return this.document().end(e)}prev(){var e=this.parent.children.indexOf(this);if(e<1)throw Error(`Already at the first node. `+this.debugInfo());return this.parent.children[e-1]}next(){var e=this.parent.children.indexOf(this);if(e===-1||e===this.parent.children.length-1)throw Error(`Already at the last node. `+this.debugInfo());return this.parent.children[e+1]}importDocument(e){var t,r=e.root().clone(),i,a,o;if(r.parent=this,r.isRoot=!1,this.children.push(r),this.type===n.Document&&(r.isRoot=!0,r.documentObject=this,this.rootObject=r,this.children)){for(o=this.children,i=0,a=o.length;i<a;i++)if(t=o[i],t.type===n.DocType){t.name=r.name;break}}return this}debugInfo(e){return e||=this.name,e==null&&!this.parent?.name?``:e==null?`parent: <`+this.parent.name+`>`:this.parent?.name?`node: <`+e+`>, parent: <`+this.parent.name+`>`:`node: <`+e+`>`}ele(e,t,n){return this.element(e,t,n)}nod(e,t,n){return this.node(e,t,n)}txt(e){return this.text(e)}dat(e){return this.cdata(e)}com(e){return this.comment(e)}ins(e,t){return this.instruction(e,t)}doc(){return this.document()}dec(e,t,n){return this.declaration(e,t,n)}e(e,t,n){return this.element(e,t,n)}n(e,t,n){return this.node(e,t,n)}t(e){return this.text(e)}d(e){return this.cdata(e)}c(e){return this.comment(e)}r(e){return this.raw(e)}i(e,t){return this.instruction(e,t)}u(){return this.up()}importXMLBuilder(e){return this.importDocument(e)}attribute(e,t){throw Error(`attribute() applies to element nodes only.`)}att(e,t){return this.attribute(e,t)}a(e,t){return this.attribute(e,t)}removeAttribute(e){throw Error(`attribute() applies to element nodes only.`)}replaceChild(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}removeChild(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}appendChild(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}hasChildNodes(){return this.children.length!==0}cloneNode(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}normalize(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}isSupported(e,t){return!0}hasAttributes(){return this.attribs.length!==0}compareDocumentPosition(t){var n=this,r;return n===t?0:this.document()===t.document()?n.isAncestor(t)?e.Contains|e.Preceding:n.isDescendant(t)?e.Contains|e.Following:n.isPreceding(t)?e.Preceding:e.Following:(r=e.Disconnected|e.ImplementationSpecific,r|=Math.random()<.5?e.Preceding:e.Following,r)}isSameNode(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}lookupPrefix(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}isDefaultNamespace(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}lookupNamespaceURI(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}isEqualNode(e){var t,n,r;if(e.nodeType!==this.nodeType||e.children.length!==this.children.length)return!1;for(t=n=0,r=this.children.length-1;0<=r?n<=r:n>=r;t=0<=r?++n:--n)if(!this.children[t].isEqualNode(e.children[t]))return!1;return!0}getFeature(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}setUserData(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getUserData(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}contains(e){return e?e===this||this.isDescendant(e):!1}isDescendant(e){var t,n,r,i,a=this.children;for(r=0,i=a.length;r<i;r++)if(t=a[r],e===t||(n=t.isDescendant(e),n))return!0;return!1}isAncestor(e){return e.isDescendant(this)}isPreceding(e){var t=this.treePosition(e),n=this.treePosition(this);return t===-1||n===-1?!1:t<n}isFollowing(e){var t=this.treePosition(e),n=this.treePosition(this);return t===-1||n===-1?!1:t>n}treePosition(e){var t,n=0;return t=!1,this.foreachTreeNode(this.document(),function(r){if(n++,!t&&r===e)return t=!0}),t?n:-1}foreachTreeNode(e,t){var n,r,i,a,o;for(e||=this.document(),a=e.children,r=0,i=a.length;r<i;r++)if(n=a[r],(o=t(n))||(o=this.foreachTreeNode(n,t),o))return o}}return Object.defineProperty(t.prototype,"nodeName",{get:function(){return this.name}}),Object.defineProperty(t.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(t.prototype,"nodeValue",{get:function(){return this.value}}),Object.defineProperty(t.prototype,"parentNode",{get:function(){return this.parent}}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return(!this.childNodeList||!this.childNodeList.nodes)&&(this.childNodeList=new l(this.children)),this.childNodeList}}),Object.defineProperty(t.prototype,"firstChild",{get:function(){return this.children[0]||null}}),Object.defineProperty(t.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null}}),Object.defineProperty(t.prototype,"previousSibling",{get:function(){var e=this.parent.children.indexOf(this);return this.parent.children[e-1]||null}}),Object.defineProperty(t.prototype,"nextSibling",{get:function(){var e=this.parent.children.indexOf(this);return this.parent.children[e+1]||null}}),Object.defineProperty(t.prototype,"ownerDocument",{get:function(){return this.document()||null}}),Object.defineProperty(t.prototype,"textContent",{get:function(){var e,t,r,i,a;if(this.nodeType===n.Element||this.nodeType===n.DocumentFragment){for(a=``,i=this.children,t=0,r=i.length;t<r;t++)e=i[t],e.textContent&&(a+=e.textContent);return a}return null},set:function(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}),t}).call(this)}).call(e)})),W=e(((e,t)=>{(function(){var e={}.hasOwnProperty;t.exports=(function(){class t{constructor(t){var n,r,i;for(n in this.assertLegalChar=this.assertLegalChar.bind(this),this.assertLegalName=this.assertLegalName.bind(this),t||={},this.options=t,this.options.version||(this.options.version=`1.0`),r=t.stringify||{},r)e.call(r,n)&&(i=r[n],this[n]=i)}name(e){return this.options.noValidation?e:this.assertLegalName(``+e||``)}text(e){return this.options.noValidation?e:this.assertLegalChar(this.textEscape(``+e||``))}cdata(e){return this.options.noValidation?e:(e=``+e||``,e=e.replace(`]]>`,`]]]]><![CDATA[>`),this.assertLegalChar(e))}comment(e){if(this.options.noValidation)return e;if(e=``+e||``,e.match(/--/))throw Error(`Comment text cannot contain double-hypen: `+e);return this.assertLegalChar(e)}raw(e){return this.options.noValidation?e:``+e||``}attValue(e){return this.options.noValidation?e:this.assertLegalChar(this.attEscape(e=``+e||``))}insTarget(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}insValue(e){if(this.options.noValidation)return e;if(e=``+e||``,e.match(/\?>/))throw Error(`Invalid processing instruction value: `+e);return this.assertLegalChar(e)}xmlVersion(e){if(this.options.noValidation)return e;if(e=``+e||``,!e.match(/1\.[0-9]+/))throw Error(`Invalid version number: `+e);return e}xmlEncoding(e){if(this.options.noValidation)return e;if(e=``+e||``,!e.match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw Error(`Invalid encoding: `+e);return this.assertLegalChar(e)}xmlStandalone(e){return this.options.noValidation?e:e?`yes`:`no`}dtdPubID(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}dtdSysID(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}dtdElementValue(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}dtdAttType(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}dtdAttDefault(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}dtdEntityValue(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}dtdNData(e){return this.options.noValidation?e:this.assertLegalChar(``+e||``)}assertLegalChar(e){var t,n;if(this.options.noValidation)return e;if(this.options.version===`1.0`){if(t=/[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/g,this.options.invalidCharReplacement!==void 0)e=e.replace(t,this.options.invalidCharReplacement);else if(n=e.match(t))throw Error(`Invalid character in string: ${e} at index ${n.index}`)}else if(this.options.version===`1.1`){if(t=/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/g,this.options.invalidCharReplacement!==void 0)e=e.replace(t,this.options.invalidCharReplacement);else if(n=e.match(t))throw Error(`Invalid character in string: ${e} at index ${n.index}`)}return e}assertLegalName(e){var t;if(this.options.noValidation)return e;if(e=this.assertLegalChar(e),t=/^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/,!e.match(t))throw Error(`Invalid character in name: ${e}`);return e}textEscape(e){var t;return this.options.noValidation?e:(t=this.options.noDoubleEncoding?/(?!&(lt|gt|amp|apos|quot);)&/g:/&/g,e.replace(t,`&`).replace(/</g,`<`).replace(/>/g,`>`).replace(/\r/g,`
`))}attEscape(e){var t;return this.options.noValidation?e:(t=this.options.noDoubleEncoding?/(?!&(lt|gt|amp|apos|quot);)&/g:/&/g,e.replace(t,`&`).replace(/</g,`<`).replace(/"/g,`"`).replace(/\t/g,`	`).replace(/\n/g,`
`).replace(/\r/g,`
`))}}return t.prototype.convertAttKey=`@`,t.prototype.convertPIKey=`?`,t.prototype.convertTextKey=`#text`,t.prototype.convertCDataKey=`#cdata`,t.prototype.convertCommentKey=`#comment`,t.prototype.convertRawKey=`#raw`,t}).call(this)}).call(e)})),G=e(((e,t)=>{(function(){t.exports={None:0,OpenTag:1,InsideTag:2,CloseTag:3}}).call(e)})),K=e(((e,t)=>{(function(){var e,n,r,i={}.hasOwnProperty;({assign:r}=y()),e=w(),j(),I(),k(),A(),D(),L(),R(),z(),B(),M(),P(),N(),F(),n=G(),t.exports=class{constructor(e){var t,n,r;for(t in e||={},this.options=e,n=e.writer||{},n)i.call(n,t)&&(r=n[t],this[`_`+t]=this[t],this[t]=r)}filterOptions(e){var t;return e||={},e=r({},this.options,e),t={writer:this},t.pretty=e.pretty||!1,t.allowEmpty=e.allowEmpty||!1,t.indent=e.indent??` `,t.newline=e.newline??`
`,t.offset=e.offset??0,t.width=e.width??0,t.dontPrettyTextNodes=e.dontPrettyTextNodes??e.dontprettytextnodes??0,t.spaceBeforeSlash=e.spaceBeforeSlash??e.spacebeforeslash??``,t.spaceBeforeSlash===!0&&(t.spaceBeforeSlash=` `),t.suppressPrettyCount=0,t.user={},t.state=n.None,t}indent(e,t,n){var r;return!t.pretty||t.suppressPrettyCount?``:t.pretty&&(r=(n||0)+t.offset+1,r>0)?Array(r).join(t.indent):``}endline(e,t,n){return!t.pretty||t.suppressPrettyCount?``:t.newline}attribute(e,t,n){var r;return this.openAttribute(e,t,n),r=t.pretty&&t.width>0?e.name+`="`+e.value+`"`:` `+e.name+`="`+e.value+`"`,this.closeAttribute(e,t,n),r}cdata(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<![CDATA[`,t.state=n.InsideTag,i+=e.value,t.state=n.CloseTag,i+=`]]>`+this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}comment(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<!-- `,t.state=n.InsideTag,i+=e.value,t.state=n.CloseTag,i+=` -->`+this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}declaration(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<?xml`,t.state=n.InsideTag,i+=` version="`+e.version+`"`,e.encoding!=null&&(i+=` encoding="`+e.encoding+`"`),e.standalone!=null&&(i+=` standalone="`+e.standalone+`"`),t.state=n.CloseTag,i+=t.spaceBeforeSlash+`?>`,i+=this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}docType(e,t,r){var i,a,o,s,c;if(r||=0,this.openNode(e,t,r),t.state=n.OpenTag,s=this.indent(e,t,r),s+=`<!DOCTYPE `+e.root().name,e.pubID&&e.sysID?s+=` PUBLIC "`+e.pubID+`" "`+e.sysID+`"`:e.sysID&&(s+=` SYSTEM "`+e.sysID+`"`),e.children.length>0){for(s+=` [`,s+=this.endline(e,t,r),t.state=n.InsideTag,c=e.children,a=0,o=c.length;a<o;a++)i=c[a],s+=this.writeChildNode(i,t,r+1);t.state=n.CloseTag,s+=`]`}return t.state=n.CloseTag,s+=t.spaceBeforeSlash+`>`,s+=this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),s}element(t,r,a){var o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,C,w;if(a||=0,_=!1,this.openNode(t,r,a),r.state=n.OpenTag,v=this.indent(t,r,a)+`<`+t.name,r.pretty&&r.width>0)for(g in p=v.length,b=t.attribs,b)i.call(b,g)&&(o=b[g],y=this.attribute(o,r,a),s=y.length,p+s>r.width?(w=this.indent(t,r,a+1)+y,v+=this.endline(t,r,a)+w,p=w.length):(w=` `+y,v+=w,p+=w.length));else for(g in x=t.attribs,x)i.call(x,g)&&(o=x[g],v+=this.attribute(o,r,a));if(l=t.children.length,u=l===0?null:t.children[0],l===0||t.children.every(function(t){return(t.type===e.Text||t.type===e.Raw||t.type===e.CData)&&t.value===``}))r.allowEmpty?(v+=`>`,r.state=n.CloseTag,v+=`</`+t.name+`>`+this.endline(t,r,a)):(r.state=n.CloseTag,v+=r.spaceBeforeSlash+`/>`+this.endline(t,r,a));else if(r.pretty&&l===1&&(u.type===e.Text||u.type===e.Raw||u.type===e.CData)&&u.value!=null)v+=`>`,r.state=n.InsideTag,r.suppressPrettyCount++,_=!0,v+=this.writeChildNode(u,r,a+1),r.suppressPrettyCount--,_=!1,r.state=n.CloseTag,v+=`</`+t.name+`>`+this.endline(t,r,a);else{if(r.dontPrettyTextNodes){for(S=t.children,d=0,m=S.length;d<m;d++)if(c=S[d],(c.type===e.Text||c.type===e.Raw||c.type===e.CData)&&c.value!=null){r.suppressPrettyCount++,_=!0;break}}for(v+=`>`+this.endline(t,r,a),r.state=n.InsideTag,C=t.children,f=0,h=C.length;f<h;f++)c=C[f],v+=this.writeChildNode(c,r,a+1);r.state=n.CloseTag,v+=this.indent(t,r,a)+`</`+t.name+`>`,_&&r.suppressPrettyCount--,v+=this.endline(t,r,a),r.state=n.None}return this.closeNode(t,r,a),v}writeChildNode(t,n,r){switch(t.type){case e.CData:return this.cdata(t,n,r);case e.Comment:return this.comment(t,n,r);case e.Element:return this.element(t,n,r);case e.Raw:return this.raw(t,n,r);case e.Text:return this.text(t,n,r);case e.ProcessingInstruction:return this.processingInstruction(t,n,r);case e.Dummy:return``;case e.Declaration:return this.declaration(t,n,r);case e.DocType:return this.docType(t,n,r);case e.AttributeDeclaration:return this.dtdAttList(t,n,r);case e.ElementDeclaration:return this.dtdElement(t,n,r);case e.EntityDeclaration:return this.dtdEntity(t,n,r);case e.NotationDeclaration:return this.dtdNotation(t,n,r);default:throw Error(`Unknown XML node type: `+t.constructor.name)}}processingInstruction(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<?`,t.state=n.InsideTag,i+=e.target,e.value&&(i+=` `+e.value),t.state=n.CloseTag,i+=t.spaceBeforeSlash+`?>`,i+=this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}raw(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r),t.state=n.InsideTag,i+=e.value,t.state=n.CloseTag,i+=this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}text(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r),t.state=n.InsideTag,i+=e.value,t.state=n.CloseTag,i+=this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}dtdAttList(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<!ATTLIST`,t.state=n.InsideTag,i+=` `+e.elementName+` `+e.attributeName+` `+e.attributeType,e.defaultValueType!==`#DEFAULT`&&(i+=` `+e.defaultValueType),e.defaultValue&&(i+=` "`+e.defaultValue+`"`),t.state=n.CloseTag,i+=t.spaceBeforeSlash+`>`+this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}dtdElement(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<!ELEMENT`,t.state=n.InsideTag,i+=` `+e.name+` `+e.value,t.state=n.CloseTag,i+=t.spaceBeforeSlash+`>`+this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}dtdEntity(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<!ENTITY`,t.state=n.InsideTag,e.pe&&(i+=` %`),i+=` `+e.name,e.value?i+=` "`+e.value+`"`:(e.pubID&&e.sysID?i+=` PUBLIC "`+e.pubID+`" "`+e.sysID+`"`:e.sysID&&(i+=` SYSTEM "`+e.sysID+`"`),e.nData&&(i+=` NDATA `+e.nData)),t.state=n.CloseTag,i+=t.spaceBeforeSlash+`>`+this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}dtdNotation(e,t,r){var i;return this.openNode(e,t,r),t.state=n.OpenTag,i=this.indent(e,t,r)+`<!NOTATION`,t.state=n.InsideTag,i+=` `+e.name,e.pubID&&e.sysID?i+=` PUBLIC "`+e.pubID+`" "`+e.sysID+`"`:e.pubID?i+=` PUBLIC "`+e.pubID+`"`:e.sysID&&(i+=` SYSTEM "`+e.sysID+`"`),t.state=n.CloseTag,i+=t.spaceBeforeSlash+`>`+this.endline(e,t,r),t.state=n.None,this.closeNode(e,t,r),i}openNode(e,t,n){}closeNode(e,t,n){}openAttribute(e,t,n){}closeAttribute(e,t,n){}}}).call(e)})),q=e(((e,t)=>{(function(){var e=K();t.exports=class extends e{constructor(e){super(e)}document(e,t){var n,r,i,a,o;for(t=this.filterOptions(t),a=``,o=e.children,r=0,i=o.length;r<i;r++)n=o[r],a+=this.writeChildNode(n,t,0);return t.pretty&&a.slice(-t.newline.length)===t.newline&&(a=a.slice(0,-t.newline.length)),a}}}).call(e)})),ee=e(((e,t)=>{(function(){var e,n,r,i,a,o,s;({isPlainObject:s}=y()),r=b(),n=C(),i=U(),e=w(),o=W(),a=q(),t.exports=(function(){class t extends i{constructor(t){super(null),this.name=`#document`,this.type=e.Document,this.documentURI=null,this.domConfig=new n,t||={},t.writer||(t.writer=new a),this.options=t,this.stringify=new o(t)}end(e){var t={};return e?s(e)&&(t=e,e=this.options.writer):e=this.options.writer,e.document(this,e.filterOptions(t))}toString(e){return this.options.writer.document(this,this.options.writer.filterOptions(e))}createElement(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createDocumentFragment(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createTextNode(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createComment(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createCDATASection(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createProcessingInstruction(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createAttribute(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createEntityReference(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByTagName(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}importNode(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createElementNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createAttributeNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByTagNameNS(e,t){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementById(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}adoptNode(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}normalizeDocument(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}renameNode(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}getElementsByClassName(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createEvent(e){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createRange(){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createNodeIterator(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}createTreeWalker(e,t,n){throw Error(`This DOM method is not implemented.`+this.debugInfo())}}return Object.defineProperty(t.prototype,"implementation",{value:new r}),Object.defineProperty(t.prototype,"doctype",{get:function(){var t,n,r,i=this.children;for(n=0,r=i.length;n<r;n++)if(t=i[n],t.type===e.DocType)return t;return null}}),Object.defineProperty(t.prototype,"documentElement",{get:function(){return this.rootObject||null}}),Object.defineProperty(t.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(t.prototype,"strictErrorChecking",{get:function(){return!1}}),Object.defineProperty(t.prototype,"xmlEncoding",{get:function(){return this.children.length!==0&&this.children[0].type===e.Declaration?this.children[0].encoding:null}}),Object.defineProperty(t.prototype,"xmlStandalone",{get:function(){return this.children.length!==0&&this.children[0].type===e.Declaration&&this.children[0].standalone===`yes`}}),Object.defineProperty(t.prototype,"xmlVersion",{get:function(){return this.children.length!==0&&this.children[0].type===e.Declaration?this.children[0].version:`1.0`}}),Object.defineProperty(t.prototype,"URL",{get:function(){return this.documentURI}}),Object.defineProperty(t.prototype,"origin",{get:function(){return null}}),Object.defineProperty(t.prototype,"compatMode",{get:function(){return null}}),Object.defineProperty(t.prototype,"characterSet",{get:function(){return null}}),Object.defineProperty(t.prototype,"contentType",{get:function(){return null}}),t}).call(this)}).call(e)})),J=e(((e,t)=>{(function(){var e,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,b,x,S,C,E={}.hasOwnProperty;({isObject:S,isFunction:x,isPlainObject:C,getValue:b}=y()),e=w(),f=ee(),p=D(),i=k(),a=A(),h=L(),v=R(),m=z(),u=j(),d=I(),o=M(),c=N(),s=P(),l=F(),r=T(),_=W(),g=q(),n=G(),t.exports=class{constructor(t,n,r){var i;this.name=`?xml`,this.type=e.Document,t||={},i={},t.writer?C(t.writer)&&(i=t.writer,t.writer=new g):t.writer=new g,this.options=t,this.writer=t.writer,this.writerOptions=this.writer.filterOptions(i),this.stringify=new _(t),this.onDataCallback=n||function(){},this.onEndCallback=r||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}createChildNode(t){var n,r,i,a,o,s,c,l;switch(t.type){case e.CData:this.cdata(t.value);break;case e.Comment:this.comment(t.value);break;case e.Element:for(r in i={},c=t.attribs,c)E.call(c,r)&&(n=c[r],i[r]=n.value);this.node(t.name,i);break;case e.Dummy:this.dummy();break;case e.Raw:this.raw(t.value);break;case e.Text:this.text(t.value);break;case e.ProcessingInstruction:this.instruction(t.target,t.value);break;default:throw Error(`This XML node type is not supported in a JS object: `+t.constructor.name)}for(l=t.children,o=0,s=l.length;o<s;o++)a=l[o],this.createChildNode(a),a.type===e.Element&&this.up();return this}dummy(){return this}node(e,t,n){if(e==null)throw Error(`Missing node name.`);if(this.root&&this.currentLevel===-1)throw Error(`Document can only have one root node. `+this.debugInfo(e));return this.openCurrent(),e=b(e),t??={},t=b(t),S(t)||([n,t]=[t,n]),this.currentNode=new p(this,e,t),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,n!=null&&this.text(n),this}element(t,n,r){var i,a,o,s,c,l;if(this.currentNode&&this.currentNode.type===e.DocType)this.dtdElement(...arguments);else if(Array.isArray(t)||S(t)||x(t))for(s=this.options.noValidation,this.options.noValidation=!0,l=new f(this.options).element(`TEMP_ROOT`),l.element(t),this.options.noValidation=s,c=l.children,a=0,o=c.length;a<o;a++)i=c[a],this.createChildNode(i),i.type===e.Element&&this.up();else this.node(t,n,r);return this}attribute(e,t){var n,i;if(!this.currentNode||this.currentNode.children)throw Error(`att() can only be used immediately after an ele() call in callback mode. `+this.debugInfo(e));if(e!=null&&(e=b(e)),S(e))for(n in e)E.call(e,n)&&(i=e[n],this.attribute(n,i));else x(t)&&(t=t.apply()),this.options.keepNullAttributes&&t==null?this.currentNode.attribs[e]=new r(this,e,``):t!=null&&(this.currentNode.attribs[e]=new r(this,e,t));return this}text(e){var t;return this.openCurrent(),t=new v(this,e),this.onData(this.writer.text(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}cdata(e){var t;return this.openCurrent(),t=new i(this,e),this.onData(this.writer.cdata(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}comment(e){var t;return this.openCurrent(),t=new a(this,e),this.onData(this.writer.comment(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}raw(e){var t;return this.openCurrent(),t=new h(this,e),this.onData(this.writer.raw(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}instruction(e,t){var n,r,i,a,o;if(this.openCurrent(),e!=null&&(e=b(e)),t!=null&&(t=b(t)),Array.isArray(e))for(n=0,a=e.length;n<a;n++)r=e[n],this.instruction(r);else if(S(e))for(r in e)E.call(e,r)&&(i=e[r],this.instruction(r,i));else x(t)&&(t=t.apply()),o=new m(this,e,t),this.onData(this.writer.processingInstruction(o,this.writerOptions,this.currentLevel+1),this.currentLevel+1);return this}declaration(e,t,n){var r;if(this.openCurrent(),this.documentStarted)throw Error(`declaration() must be the first node.`);return r=new u(this,e,t,n),this.onData(this.writer.declaration(r,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}doctype(e,t,n){if(this.openCurrent(),e==null)throw Error(`Missing root node name.`);if(this.root)throw Error(`dtd() must come before the root node.`);return this.currentNode=new d(this,t,n),this.currentNode.rootNodeName=e,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this}dtdElement(e,t){var n;return this.openCurrent(),n=new s(this,e,t),this.onData(this.writer.dtdElement(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}attList(e,t,n,r,i){var a;return this.openCurrent(),a=new o(this,e,t,n,r,i),this.onData(this.writer.dtdAttList(a,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}entity(e,t){var n;return this.openCurrent(),n=new c(this,!1,e,t),this.onData(this.writer.dtdEntity(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}pEntity(e,t){var n;return this.openCurrent(),n=new c(this,!0,e,t),this.onData(this.writer.dtdEntity(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}notation(e,t){var n;return this.openCurrent(),n=new l(this,e,t),this.onData(this.writer.dtdNotation(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this}up(){if(this.currentLevel<0)throw Error(`The document node has no parent.`);return this.currentNode?(this.currentNode.children?this.closeNode(this.currentNode):this.openNode(this.currentNode),this.currentNode=null):this.closeNode(this.openTags[this.currentLevel]),delete this.openTags[this.currentLevel],this.currentLevel--,this}end(){for(;this.currentLevel>=0;)this.up();return this.onEnd()}openCurrent(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)}openNode(t){var r,i,a,o;if(!t.isOpen){if(!this.root&&this.currentLevel===0&&t.type===e.Element&&(this.root=t),i=``,t.type===e.Element){for(a in this.writerOptions.state=n.OpenTag,i=this.writer.indent(t,this.writerOptions,this.currentLevel)+`<`+t.name,o=t.attribs,o)E.call(o,a)&&(r=o[a],i+=this.writer.attribute(r,this.writerOptions,this.currentLevel));i+=(t.children?`>`:`/>`)+this.writer.endline(t,this.writerOptions,this.currentLevel),this.writerOptions.state=n.InsideTag}else this.writerOptions.state=n.OpenTag,i=this.writer.indent(t,this.writerOptions,this.currentLevel)+`<!DOCTYPE `+t.rootNodeName,t.pubID&&t.sysID?i+=` PUBLIC "`+t.pubID+`" "`+t.sysID+`"`:t.sysID&&(i+=` SYSTEM "`+t.sysID+`"`),t.children?(i+=` [`,this.writerOptions.state=n.InsideTag):(this.writerOptions.state=n.CloseTag,i+=`>`),i+=this.writer.endline(t,this.writerOptions,this.currentLevel);return this.onData(i,this.currentLevel),t.isOpen=!0}}closeNode(t){var r;if(!t.isClosed)return r=``,this.writerOptions.state=n.CloseTag,r=t.type===e.Element?this.writer.indent(t,this.writerOptions,this.currentLevel)+`</`+t.name+`>`+this.writer.endline(t,this.writerOptions,this.currentLevel):this.writer.indent(t,this.writerOptions,this.currentLevel)+`]>`+this.writer.endline(t,this.writerOptions,this.currentLevel),this.writerOptions.state=n.None,this.onData(r,this.currentLevel),t.isClosed=!0}onData(e,t){return this.documentStarted=!0,this.onDataCallback(e,t+1)}onEnd(){return this.documentCompleted=!0,this.onEndCallback()}debugInfo(e){return e==null?``:`node: <`+e+`>`}ele(){return this.element(...arguments)}nod(e,t,n){return this.node(e,t,n)}txt(e){return this.text(e)}dat(e){return this.cdata(e)}com(e){return this.comment(e)}ins(e,t){return this.instruction(e,t)}dec(e,t,n){return this.declaration(e,t,n)}dtd(e,t,n){return this.doctype(e,t,n)}e(e,t,n){return this.element(e,t,n)}n(e,t,n){return this.node(e,t,n)}t(e){return this.text(e)}d(e){return this.cdata(e)}c(e){return this.comment(e)}r(e){return this.raw(e)}i(e,t){return this.instruction(e,t)}att(){return this.currentNode&&this.currentNode.type===e.DocType?this.attList(...arguments):this.attribute(...arguments)}a(){return this.currentNode&&this.currentNode.type===e.DocType?this.attList(...arguments):this.attribute(...arguments)}ent(e,t){return this.entity(e,t)}pent(e,t){return this.pEntity(e,t)}not(e,t){return this.notation(e,t)}}}).call(e)})),te=e(((e,t)=>{(function(){var e,n,r,i={}.hasOwnProperty;e=w(),r=K(),n=G(),t.exports=class extends r{constructor(e,t){super(t),this.stream=e}endline(e,t,r){return e.isLastRootNode&&t.state===n.CloseTag?``:super.endline(e,t,r)}document(e,t){var n,r,i,a,o,s,c=e.children,l,u;for(r=i=0,o=c.length;i<o;r=++i)n=c[r],n.isLastRootNode=r===e.children.length-1;for(t=this.filterOptions(t),l=e.children,u=[],a=0,s=l.length;a<s;a++)n=l[a],u.push(this.writeChildNode(n,t,0));return u}cdata(e,t,n){return this.stream.write(super.cdata(e,t,n))}comment(e,t,n){return this.stream.write(super.comment(e,t,n))}declaration(e,t,n){return this.stream.write(super.declaration(e,t,n))}docType(e,t,r){var i,a,o,s;if(r||=0,this.openNode(e,t,r),t.state=n.OpenTag,this.stream.write(this.indent(e,t,r)),this.stream.write(`<!DOCTYPE `+e.root().name),e.pubID&&e.sysID?this.stream.write(` PUBLIC "`+e.pubID+`" "`+e.sysID+`"`):e.sysID&&this.stream.write(` SYSTEM "`+e.sysID+`"`),e.children.length>0){for(this.stream.write(` [`),this.stream.write(this.endline(e,t,r)),t.state=n.InsideTag,s=e.children,a=0,o=s.length;a<o;a++)i=s[a],this.writeChildNode(i,t,r+1);t.state=n.CloseTag,this.stream.write(`]`)}return t.state=n.CloseTag,this.stream.write(t.spaceBeforeSlash+`>`),this.stream.write(this.endline(e,t,r)),t.state=n.None,this.closeNode(e,t,r)}element(t,r,a){var o,s,c,l,u,d,f,p,m,h,g,_,v,y,b;if(a||=0,this.openNode(t,r,a),r.state=n.OpenTag,h=this.indent(t,r,a)+`<`+t.name,r.pretty&&r.width>0)for(m in f=h.length,_=t.attribs,_)i.call(_,m)&&(o=_[m],g=this.attribute(o,r,a),s=g.length,f+s>r.width?(b=this.indent(t,r,a+1)+g,h+=this.endline(t,r,a)+b,f=b.length):(b=` `+g,h+=b,f+=b.length));else for(m in v=t.attribs,v)i.call(v,m)&&(o=v[m],h+=this.attribute(o,r,a));if(this.stream.write(h),l=t.children.length,u=l===0?null:t.children[0],l===0||t.children.every(function(t){return(t.type===e.Text||t.type===e.Raw||t.type===e.CData)&&t.value===``}))r.allowEmpty?(this.stream.write(`>`),r.state=n.CloseTag,this.stream.write(`</`+t.name+`>`)):(r.state=n.CloseTag,this.stream.write(r.spaceBeforeSlash+`/>`));else if(r.pretty&&l===1&&(u.type===e.Text||u.type===e.Raw||u.type===e.CData)&&u.value!=null)this.stream.write(`>`),r.state=n.InsideTag,r.suppressPrettyCount++,this.writeChildNode(u,r,a+1),r.suppressPrettyCount--,r.state=n.CloseTag,this.stream.write(`</`+t.name+`>`);else{for(this.stream.write(`>`+this.endline(t,r,a)),r.state=n.InsideTag,y=t.children,d=0,p=y.length;d<p;d++)c=y[d],this.writeChildNode(c,r,a+1);r.state=n.CloseTag,this.stream.write(this.indent(t,r,a)+`</`+t.name+`>`)}return this.stream.write(this.endline(t,r,a)),r.state=n.None,this.closeNode(t,r,a)}processingInstruction(e,t,n){return this.stream.write(super.processingInstruction(e,t,n))}raw(e,t,n){return this.stream.write(super.raw(e,t,n))}text(e,t,n){return this.stream.write(super.text(e,t,n))}dtdAttList(e,t,n){return this.stream.write(super.dtdAttList(e,t,n))}dtdElement(e,t,n){return this.stream.write(super.dtdElement(e,t,n))}dtdEntity(e,t,n){return this.stream.write(super.dtdEntity(e,t,n))}dtdNotation(e,t,n){return this.stream.write(super.dtdNotation(e,t,n))}}}).call(e)}));e(((e,t)=>{(function(){var e,n,r,i,a,o,s,c,l;({assign:c,isFunction:l}=y()),r=b(),i=ee(),a=J(),s=q(),o=te(),e=w(),n=G(),t.exports.create=function(e,t,n,r){var a,o;if(e==null)throw Error(`Root element needs a name.`);return r=c({},t,n,r),a=new i(r),o=a.element(e),r.headless||(a.declaration(r),(r.pubID!=null||r.sysID!=null)&&a.dtd(r)),o},t.exports.begin=function(e,t,n){return l(e)&&([t,n]=[e,t],e={}),t?new a(e,t,n):new i(e)},t.exports.stringWriter=function(e){return new s(e)},t.exports.streamWriter=function(e,t){return new o(e,t)},t.exports.implementation=new r,t.exports.nodeType=e,t.exports.writerState=n}).call(e)}))();export{_ as parse};