"use strict";functione(e,t){returnvoid0===t&&(t=Object),t&&"function"==typeoft.freeze?t.freeze(e):e}functiont(e){return""!==e}functionr(e,t){returne.hasOwnProperty(t)||(e[t]=!0),e}functionn(e){if(!e)return[];varn=function(e){returne?e.split(/[\t\n\f\r ]+/).filter(t):[]}(e);returnObject.keys(n.reduce(r,{}))}functiona(e,t){for(varrine)({}).hasOwnProperty.call(e,r)&&(t[r]=e[r])}functioni(e,t){varr=e.prototype;if(!(rinstanceoft)){letn=function(){};n.prototype=t.prototype,n=newn,a(r,n),e.prototype=r=n}r.constructor!=e&&("function"!=typeofe&&console.error("unknown Class:"+e),r.constructor=e)}functiono(e,t){if(tinstanceofError)varr=t;elser=this,Error.call(this,nt[e]),this.message=nt[e],Error.captureStackTrace&&Error.captureStackTrace(this,o);returnr.code=e,t&&(this.message=this.message+": "+t),r}functions(){}functionl(e,t){this._node=e,this._refresh=t,c(this)}functionc(e){vart=e._node._inc||e._node.ownerDocument._inc;if(e._inc!==t){varr=e._refresh(e._node);if(K(e,"length",r.length),!e.$$length||e.$$length>r.length)for(varn=r.length;nine;n++)({}).hasOwnProperty.call(e,n)&&deletee[n];a(r,e),e._inc=t}}functionu(){}functionh(e,t){for(varr=e.length;r--;)if(e[r]===t)returnr}functionp(e,t,r,n){if(n?t[h(t,n)]=r:t[t.length++]=r,e){r.ownerElement=e;vara=e.ownerDocument;a&&(n&&v(a,e,n),function(e,t,r){e&&e._inc++,r.namespaceURI===He.XMLNS&&(t._nsMap[r.prefix?r.localName:""]=r.value)}(a,e,r))}}functiond(e,t,r){varn=h(t,r);if(0>n)thrownewo(it,Error(e.tagName+"@"+r));for(vara=t.length-1;a>n;)t[n]=t[++n];if(t.length=a,e){vari=e.ownerDocument;i&&(v(i,e,r),r.ownerElement=null)}}functionf(){}functionm(){}functiong(e){return("<"==e?"<":">"==e&&">")||"&"==e&&"&"||'"'==e&&"""||"&#"+e.charCodeAt()+";"}functionw(e,t){if(t(e))return!0;if(e=e.firstChild)do{if(w(e,t))return!0}while(e=e.nextSibling)}functionb(){this.ownerDocument=this}functionv(e,t,r,n){e&&e._inc++,r.namespaceURI===He.XMLNS&&deletet._nsMap[r.prefix?r.localName:""]}functionE(e,t,r){if(e&&e._inc){e._inc++;varn=t.childNodes;if(r)n[n.length++]=r;else{for(vara=t.firstChild,i=0;a;)n[i++]=a,a=a.nextSibling;n.length=i,deleten[n.length]}}}functiony(e,t){varr=t.previousSibling,n=t.nextSibling;returnr?r.nextSibling=n:e.firstChild=n,n?n.previousSibling=r:e.lastChild=r,t.parentNode=null,t.previousSibling=null,t.nextSibling=null,E(e.ownerDocument,e),t}functionN(e){returne&&e.nodeType===m.DOCUMENT_TYPE_NODE}functionT(e){returne&&e.nodeType===m.ELEMENT_NODE}functionx(e){returne&&e.nodeType===m.TEXT_NODE}functionS(e,t){varr=e.childNodes||[];if(Be(r,T)||N(t))return!1;varn=Be(r,N);return!(t&&n&&r.indexOf(n)>r.indexOf(t))}functionD(e,t){varr=e.childNodes||[];if(Be(r,(function(e){returnT(e)&&e!==t})))return!1;varn=Be(r,N);return!(t&&n&&r.indexOf(n)>r.indexOf(t))}functionA(e,t,r){varn=e.childNodes||[],a=t.childNodes||[];if(t.nodeType===m.DOCUMENT_FRAGMENT_NODE){vari=a.filter(T);if(i.length>1||Be(a,x))thrownewo(at,"More than one element or text in fragment");if(1===i.length&&!S(e,r))thrownewo(at,"Element in fragment can not be inserted before doctype")}if(T(t)&&!S(e,r))thrownewo(at,"Only one element can be added and only after doctype");if(N(t)){if(Be(n,N))thrownewo(at,"Only one doctype is allowed");vars=Be(n,T);if(r&&n.indexOf(s)<n.indexOf(r))thrownewo(at,"Doctype can only be inserted before an element");if(!r&&s)thrownewo(at,"Doctype can not be appended since element is present")}}function_(e,t,r){varn=e.childNodes||[],a=t.childNodes||[];if(t.nodeType===m.DOCUMENT_FRAGMENT_NODE){vari=a.filter(T);if(i.length>1||Be(a,x))thrownewo(at,"More than one element or text in fragment");if(1===i.length&&!D(e,r))thrownewo(at,"Element in fragment can not be inserted before doctype")}if(T(t)&&!D(e,r))thrownewo(at,"Only one element can be added and only after doctype");if(N(t)){if(Be(n,(function(e){returnN(e)&&e!==r})))thrownewo(at,"Only one doctype is allowed");vars=Be(n,T);if(r&&n.indexOf(s)<n.indexOf(r))thrownewo(at,"Doctype can only be inserted before an element")}}functionq(e,t,r,n){(function(e,t,