UNPKG

metapatcher

Version:

HTML document head management library with convenient api. Manage social media tags, icons, device specific tags and event structured data with html meta tags and JSONLD documents.

1 lines 51.2 kB
var Metapatcher=function(t){"use strict";var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function r(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var n,i,o,u,s,a,c,f,l,d,h,p,m,v,y,g,b={},O={};function w(){if(i)return n;i=1;var t=function(t){return t&&t.Math===Math&&t};return n=t("object"==typeof globalThis&&globalThis)||t("object"==typeof window&&window)||t("object"==typeof self&&self)||t("object"==typeof e&&e)||t("object"==typeof n&&n)||function(){return this}()||Function("return this")()}function S(){return u?o:(u=1,o=function(t){try{return!!t()}catch(t){return!0}})}function P(){return a?s:(a=1,s=!S()((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})))}function j(){if(f)return c;f=1;var t=P(),e=Function.prototype,r=e.apply,n=e.call;return c="object"==typeof Reflect&&Reflect.apply||(t?n.bind(r):function(){return n.apply(r,arguments)}),c}function x(){if(d)return l;d=1;var t=P(),e=Function.prototype,r=e.call,n=t&&e.bind.bind(r,r);return l=t?n:function(t){return function(){return r.apply(t,arguments)}},l}function T(){if(p)return h;p=1;var t=x(),e=t({}.toString),r=t("".slice);return h=function(t){return r(e(t),8,-1)}}function A(){if(v)return m;v=1;var t=T(),e=x();return m=function(r){if("Function"===t(r))return e(r)}}function E(){if(g)return y;g=1;var t="object"==typeof document&&document.all;return y=void 0===t&&void 0!==t?function(e){return"function"==typeof e||e===t}:function(t){return"function"==typeof t}}var L,k,M,C,D={};function I(){return k?L:(k=1,L=!S()((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})))}function F(){if(C)return M;C=1;var t=P(),e=Function.prototype.call;return M=t?e.bind(e):function(){return e.apply(e,arguments)},M}var N,R,_,B,G,z,V,J,U,W,q,K,H,Y,X,$,Q,Z,tt,et,rt,nt,it,ot,ut,st,at,ct,ft,lt,dt,ht,pt,mt,vt,yt,gt,bt={};function Ot(){if(N)return bt;N=1;var t={}.propertyIsEnumerable,e=Object.getOwnPropertyDescriptor,r=e&&!t.call({1:2},1);return bt.f=r?function(t){var r=e(this,t);return!!r&&r.enumerable}:t,bt}function wt(){return _?R:(_=1,R=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}})}function St(){if(G)return B;G=1;var t=x(),e=S(),r=T(),n=Object,i=t("".split);return B=e((function(){return!n("z").propertyIsEnumerable(0)}))?function(t){return"String"===r(t)?i(t,""):n(t)}:n}function Pt(){return V?z:(V=1,z=function(t){return null==t})}function jt(){if(U)return J;U=1;var t=Pt(),e=TypeError;return J=function(r){if(t(r))throw new e("Can't call method on "+r);return r}}function xt(){if(q)return W;q=1;var t=St(),e=jt();return W=function(r){return t(e(r))}}function Tt(){if(H)return K;H=1;var t=E();return K=function(e){return"object"==typeof e?null!==e:t(e)}}function At(){return X?Y:(X=1,Y={})}function Et(){if(Q)return $;Q=1;var t=At(),e=w(),r=E(),n=function(t){return r(t)?t:void 0};return $=function(r,i){return arguments.length<2?n(t[r])||n(e[r]):t[r]&&t[r][i]||e[r]&&e[r][i]},$}function Lt(){return tt?Z:(tt=1,Z=x()({}.isPrototypeOf))}function kt(){if(rt)return et;rt=1;var t=w().navigator,e=t&&t.userAgent;return et=e?String(e):""}function Mt(){if(it)return nt;it=1;var t,e,r=w(),n=kt(),i=r.process,o=r.Deno,u=i&&i.versions||o&&o.version,s=u&&u.v8;return s&&(e=(t=s.split("."))[0]>0&&t[0]<4?1:+(t[0]+t[1])),!e&&n&&(!(t=n.match(/Edge\/(\d+)/))||t[1]>=74)&&(t=n.match(/Chrome\/(\d+)/))&&(e=+t[1]),nt=e}function Ct(){if(ut)return ot;ut=1;var t=Mt(),e=S(),r=w().String;return ot=!!Object.getOwnPropertySymbols&&!e((function(){var e=Symbol("symbol detection");return!r(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&t&&t<41})),ot}function Dt(){return at?st:(at=1,st=Ct()&&!Symbol.sham&&"symbol"==typeof Symbol.iterator)}function It(){if(ft)return ct;ft=1;var t=Et(),e=E(),r=Lt(),n=Object;return ct=Dt()?function(t){return"symbol"==typeof t}:function(i){var o=t("Symbol");return e(o)&&r(o.prototype,n(i))}}function Ft(){if(dt)return lt;dt=1;var t=String;return lt=function(e){try{return t(e)}catch(t){return"Object"}}}function Nt(){if(pt)return ht;pt=1;var t=E(),e=Ft(),r=TypeError;return ht=function(n){if(t(n))return n;throw new r(e(n)+" is not a function")}}function Rt(){if(vt)return mt;vt=1;var t=Nt(),e=Pt();return mt=function(r,n){var i=r[n];return e(i)?void 0:t(i)}}function _t(){if(gt)return yt;gt=1;var t=F(),e=E(),r=Tt(),n=TypeError;return yt=function(i,o){var u,s;if("string"===o&&e(u=i.toString)&&!r(s=t(u,i)))return s;if(e(u=i.valueOf)&&!r(s=t(u,i)))return s;if("string"!==o&&e(u=i.toString)&&!r(s=t(u,i)))return s;throw new n("Can't convert object to primitive value")}}var Bt,Gt,zt,Vt,Jt,Ut,Wt,qt,Kt,Ht,Yt,Xt,$t,Qt,Zt,te,ee,re,ne,ie,oe,ue,se,ae,ce,fe,le,de,he={exports:{}};function pe(){return Gt?Bt:(Gt=1,Bt=!0)}function me(){if(Vt)return zt;Vt=1;var t=w(),e=Object.defineProperty;return zt=function(r,n){try{e(t,r,{value:n,configurable:!0,writable:!0})}catch(e){t[r]=n}return n}}function ve(){if(Jt)return he.exports;Jt=1;var t=pe(),e=w(),r=me(),n="__core-js_shared__",i=he.exports=e[n]||r(n,{});return(i.versions||(i.versions=[])).push({version:"3.40.0",mode:t?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.40.0/LICENSE",source:"https://github.com/zloirock/core-js"}),he.exports}function ye(){if(Wt)return Ut;Wt=1;var t=ve();return Ut=function(e,r){return t[e]||(t[e]=r||{})}}function ge(){if(Kt)return qt;Kt=1;var t=jt(),e=Object;return qt=function(r){return e(t(r))}}function be(){if(Yt)return Ht;Yt=1;var t=x(),e=ge(),r=t({}.hasOwnProperty);return Ht=Object.hasOwn||function(t,n){return r(e(t),n)}}function Oe(){if($t)return Xt;$t=1;var t=x(),e=0,r=Math.random(),n=t(1..toString);return Xt=function(t){return"Symbol("+(void 0===t?"":t)+")_"+n(++e+r,36)}}function we(){if(Zt)return Qt;Zt=1;var t=w(),e=ye(),r=be(),n=Oe(),i=Ct(),o=Dt(),u=t.Symbol,s=e("wks"),a=o?u.for||u:u&&u.withoutSetter||n;return Qt=function(t){return r(s,t)||(s[t]=i&&r(u,t)?u[t]:a("Symbol."+t)),s[t]}}function Se(){if(ee)return te;ee=1;var t=F(),e=Tt(),r=It(),n=Rt(),i=_t(),o=TypeError,u=we()("toPrimitive");return te=function(s,a){if(!e(s)||r(s))return s;var c,f=n(s,u);if(f){if(void 0===a&&(a="default"),c=t(f,s,a),!e(c)||r(c))return c;throw new o("Can't convert object to primitive value")}return void 0===a&&(a="number"),i(s,a)}}function Pe(){if(ne)return re;ne=1;var t=Se(),e=It();return re=function(r){var n=t(r,"string");return e(n)?n:n+""}}function je(){if(oe)return ie;oe=1;var t=w(),e=Tt(),r=t.document,n=e(r)&&e(r.createElement);return ie=function(t){return n?r.createElement(t):{}}}function xe(){if(se)return ue;se=1;var t=I(),e=S(),r=je();return ue=!t&&!e((function(){return 7!==Object.defineProperty(r("div"),"a",{get:function(){return 7}}).a}))}function Te(){if(ae)return D;ae=1;var t=I(),e=F(),r=Ot(),n=wt(),i=xt(),o=Pe(),u=be(),s=xe(),a=Object.getOwnPropertyDescriptor;return D.f=t?a:function(t,c){if(t=i(t),c=o(c),s)try{return a(t,c)}catch(t){}if(u(t,c))return n(!e(r.f,t,c),t[c])},D}function Ae(){if(fe)return ce;fe=1;var t=S(),e=E(),r=/#|\.prototype\./,n=function(r,n){var a=o[i(r)];return a===s||a!==u&&(e(n)?t(n):!!n)},i=n.normalize=function(t){return String(t).replace(r,".").toLowerCase()},o=n.data={},u=n.NATIVE="N",s=n.POLYFILL="P";return ce=n}function Ee(){if(de)return le;de=1;var t=A(),e=Nt(),r=P(),n=t(t.bind);return le=function(t,i){return e(t),void 0===i?t:r?n(t,i):function(){return t.apply(i,arguments)}},le}var Le,ke,Me,Ce,De,Ie,Fe,Ne,Re,_e,Be,Ge,ze,Ve,Je,Ue={};function We(){return ke?Le:(ke=1,Le=I()&&S()((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})))}function qe(){if(Ce)return Me;Ce=1;var t=Tt(),e=String,r=TypeError;return Me=function(n){if(t(n))return n;throw new r(e(n)+" is not an object")}}function Ke(){if(De)return Ue;De=1;var t=I(),e=xe(),r=We(),n=qe(),i=Pe(),o=TypeError,u=Object.defineProperty,s=Object.getOwnPropertyDescriptor,a="enumerable",c="configurable",f="writable";return Ue.f=t?r?function(t,e,r){if(n(t),e=i(e),n(r),"function"==typeof t&&"prototype"===e&&"value"in r&&f in r&&!r[f]){var o=s(t,e);o&&o[f]&&(t[e]=r.value,r={configurable:c in r?r[c]:o[c],enumerable:a in r?r[a]:o[a],writable:!1})}return u(t,e,r)}:u:function(t,r,s){if(n(t),r=i(r),n(s),e)try{return u(t,r,s)}catch(t){}if("get"in s||"set"in s)throw new o("Accessors not supported");return"value"in s&&(t[r]=s.value),t},Ue}function He(){if(Fe)return Ie;Fe=1;var t=I(),e=Ke(),r=wt();return Ie=t?function(t,n,i){return e.f(t,n,r(1,i))}:function(t,e,r){return t[e]=r,t}}function Ye(){if(Re)return Ne;Re=1;var t=w(),e=j(),r=A(),n=E(),i=Te().f,o=Ae(),u=At(),s=Ee(),a=He(),c=be(),f=function(t){var r=function(n,i,o){if(this instanceof r){switch(arguments.length){case 0:return new t;case 1:return new t(n);case 2:return new t(n,i)}return new t(n,i,o)}return e(t,this,arguments)};return r.prototype=t.prototype,r};return Ne=function(e,l){var d,h,p,m,v,y,g,b,O,w=e.target,S=e.global,P=e.stat,j=e.proto,x=S?t:P?t[w]:t[w]&&t[w].prototype,T=S?u:u[w]||a(u,w,{})[w],A=T.prototype;for(m in l)h=!(d=o(S?m:w+(P?".":"#")+m,e.forced))&&x&&c(x,m),y=T[m],h&&(g=e.dontCallGetSet?(O=i(x,m))&&O.value:x[m]),v=h&&g?g:l[m],(d||j||typeof y!=typeof v)&&(b=e.bind&&h?s(v,t):e.wrap&&h?f(v):j&&n(v)?r(v):v,(e.sham||v&&v.sham||y&&y.sham)&&a(b,"sham",!0),a(T,m,b),j&&(c(u,p=w+"Prototype")||a(u,p,{}),a(u[p],m,v),e.real&&A&&(d||!A[m])&&a(A,m,v)))}}function Xe(){if(Be)return _e;Be=1;var t={};return t[we()("toStringTag")]="z",_e="[object z]"===String(t)}function $e(){if(ze)return Ge;ze=1;var t=Xe(),e=E(),r=T(),n=we()("toStringTag"),i=Object,o="Arguments"===r(function(){return arguments}());return Ge=t?r:function(t){var u,s,a;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(s=function(t,e){try{return t[e]}catch(t){}}(u=i(t),n))?s:o?r(u):"Object"===(a=r(u))&&e(u.callee)?"Arguments":a}}function Qe(){if(Je)return Ve;Je=1;var t=$e(),e=String;return Ve=function(r){if("Symbol"===t(r))throw new TypeError("Cannot convert a Symbol value to a string");return e(r)}}var Ze,tr,er,rr,nr,ir,or,ur,sr,ar,cr,fr,lr,dr,hr,pr,mr,vr,yr,gr,br,Or,wr,Sr,Pr,jr,xr,Tr={};function Ar(){if(tr)return Ze;tr=1;var t=Math.ceil,e=Math.floor;return Ze=Math.trunc||function(r){var n=+r;return(n>0?e:t)(n)}}function Er(){if(rr)return er;rr=1;var t=Ar();return er=function(e){var r=+e;return r!=r||0===r?0:t(r)}}function Lr(){if(ir)return nr;ir=1;var t=Er(),e=Math.max,r=Math.min;return nr=function(n,i){var o=t(n);return o<0?e(o+i,0):r(o,i)}}function kr(){if(ur)return or;ur=1;var t=Er(),e=Math.min;return or=function(r){var n=t(r);return n>0?e(n,9007199254740991):0}}function Mr(){if(ar)return sr;ar=1;var t=kr();return sr=function(e){return t(e.length)}}function Cr(){if(fr)return cr;fr=1;var t=xt(),e=Lr(),r=Mr(),n=function(n){return function(i,o,u){var s=t(i),a=r(s);if(0===a)return!n&&-1;var c,f=e(u,a);if(n&&o!=o){for(;a>f;)if((c=s[f++])!=c)return!0}else for(;a>f;f++)if((n||f in s)&&s[f]===o)return n||f||0;return!n&&-1}};return cr={includes:n(!0),indexOf:n(!1)}}function Dr(){return dr?lr:(dr=1,lr={})}function Ir(){if(pr)return hr;pr=1;var t=x(),e=be(),r=xt(),n=Cr().indexOf,i=Dr(),o=t([].push);return hr=function(t,u){var s,a=r(t),c=0,f=[];for(s in a)!e(i,s)&&e(a,s)&&o(f,s);for(;u.length>c;)e(a,s=u[c++])&&(~n(f,s)||o(f,s));return f}}function Fr(){return vr?mr:(vr=1,mr=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}function Nr(){if(gr)return yr;gr=1;var t=Ir(),e=Fr();return yr=Object.keys||function(r){return t(r,e)}}function Rr(){if(br)return Tr;br=1;var t=I(),e=We(),r=Ke(),n=qe(),i=xt(),o=Nr();return Tr.f=t&&!e?Object.defineProperties:function(t,e){n(t);for(var u,s=i(e),a=o(e),c=a.length,f=0;c>f;)r.f(t,u=a[f++],s[u]);return t},Tr}function _r(){return wr?Or:(wr=1,Or=Et()("document","documentElement"))}function Br(){if(Pr)return Sr;Pr=1;var t=ye(),e=Oe(),r=t("keys");return Sr=function(t){return r[t]||(r[t]=e(t))}}function Gr(){if(xr)return jr;xr=1;var t,e=qe(),r=Rr(),n=Fr(),i=Dr(),o=_r(),u=je(),s="prototype",a="script",c=Br()("IE_PROTO"),f=function(){},l=function(t){return"<"+a+">"+t+"</"+a+">"},d=function(t){t.write(l("")),t.close();var e=t.parentWindow.Object;return t=null,e},h=function(){try{t=new ActiveXObject("htmlfile")}catch(t){}var e,r,i;h="undefined"!=typeof document?document.domain&&t?d(t):(r=u("iframe"),i="java"+a+":",r.style.display="none",o.appendChild(r),r.src=String(i),(e=r.contentWindow.document).open(),e.write(l("document.F=Object")),e.close(),e.F):d(t);for(var c=n.length;c--;)delete h[s][n[c]];return h()};return i[c]=!0,jr=Object.create||function(t,n){var i;return null!==t?(f[s]=e(t),i=new f,f[s]=null,i[c]=t):i=h(),void 0===n?i:r.f(i,n)}}var zr,Vr={};function Jr(){if(zr)return Vr;zr=1;var t=Ir(),e=Fr().concat("length","prototype");return Vr.f=Object.getOwnPropertyNames||function(r){return t(r,e)},Vr}var Ur,Wr,qr,Kr={};function Hr(){return Wr?Ur:(Wr=1,Ur=x()([].slice))}function Yr(){if(qr)return Kr;qr=1;var t=T(),e=xt(),r=Jr().f,n=Hr(),i="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];return Kr.f=function(o){return i&&"Window"===t(o)?function(t){try{return r(t)}catch(t){return n(i)}}(o):r(e(o))},Kr}var Xr,$r,Qr,Zr,tn,en={};function rn(){return Xr||(Xr=1,en.f=Object.getOwnPropertySymbols),en}function nn(){if(Qr)return $r;Qr=1;var t=He();return $r=function(e,r,n,i){return i&&i.enumerable?e[r]=n:t(e,r,n),e}}function on(){if(tn)return Zr;tn=1;var t=Ke();return Zr=function(e,r,n){return t.f(e,r,n)}}var un,sn,an,cn,fn,ln,dn,hn,pn,mn,vn,yn,gn,bn,On,wn,Sn,Pn,jn,xn,Tn,An,En,Ln,kn,Mn,Cn={};function Dn(){if(un)return Cn;un=1;var t=we();return Cn.f=t,Cn}function In(){if(an)return sn;an=1;var t=At(),e=be(),r=Dn(),n=Ke().f;return sn=function(i){var o=t.Symbol||(t.Symbol={});e(o,i)||n(o,i,{value:r.f(i)})}}function Fn(){if(fn)return cn;fn=1;var t=F(),e=Et(),r=we(),n=nn();return cn=function(){var i=e("Symbol"),o=i&&i.prototype,u=o&&o.valueOf,s=r("toPrimitive");o&&!o[s]&&n(o,s,(function(e){return t(u,this)}),{arity:1})}}function Nn(){if(dn)return ln;dn=1;var t=Xe(),e=$e();return ln=t?{}.toString:function(){return"[object "+e(this)+"]"}}function Rn(){if(pn)return hn;pn=1;var t=Xe(),e=Ke().f,r=He(),n=be(),i=Nn(),o=we()("toStringTag");return hn=function(u,s,a,c){var f=a?u:u&&u.prototype;f&&(n(f,o)||e(f,o,{configurable:!0,value:s}),c&&!t&&r(f,"toString",i))}}function _n(){if(vn)return mn;vn=1;var t=w(),e=E(),r=t.WeakMap;return mn=e(r)&&/native code/.test(String(r))}function Bn(){if(gn)return yn;gn=1;var t,e,r,n=_n(),i=w(),o=Tt(),u=He(),s=be(),a=ve(),c=Br(),f=Dr(),l="Object already initialized",d=i.TypeError,h=i.WeakMap;if(n||a.state){var p=a.state||(a.state=new h);p.get=p.get,p.has=p.has,p.set=p.set,t=function(t,e){if(p.has(t))throw new d(l);return e.facade=t,p.set(t,e),e},e=function(t){return p.get(t)||{}},r=function(t){return p.has(t)}}else{var m=c("state");f[m]=!0,t=function(t,e){if(s(t,m))throw new d(l);return e.facade=t,u(t,m,e),e},e=function(t){return s(t,m)?t[m]:{}},r=function(t){return s(t,m)}}return yn={set:t,get:e,has:r,enforce:function(n){return r(n)?e(n):t(n,{})},getterFor:function(t){return function(r){var n;if(!o(r)||(n=e(r)).type!==t)throw new d("Incompatible receiver, "+t+" required");return n}}}}function Gn(){if(On)return bn;On=1;var t=T();return bn=Array.isArray||function(e){return"Array"===t(e)}}function zn(){if(Sn)return wn;Sn=1;var t=x(),e=E(),r=ve(),n=t(Function.toString);return e(r.inspectSource)||(r.inspectSource=function(t){return n(t)}),wn=r.inspectSource}function Vn(){if(jn)return Pn;jn=1;var t=x(),e=S(),r=E(),n=$e(),i=Et(),o=zn(),u=function(){},s=i("Reflect","construct"),a=/^\s*(?:class|function)\b/,c=t(a.exec),f=!a.test(u),l=function(t){if(!r(t))return!1;try{return s(u,[],t),!0}catch(t){return!1}},d=function(t){if(!r(t))return!1;switch(n(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return f||!!c(a,o(t))}catch(t){return!0}};return d.sham=!0,Pn=!s||e((function(){var t;return l(l.call)||!l(Object)||!l((function(){t=!0}))||t}))?d:l}function Jn(){if(Tn)return xn;Tn=1;var t=Gn(),e=Vn(),r=Tt(),n=we()("species"),i=Array;return xn=function(o){var u;return t(o)&&(u=o.constructor,(e(u)&&(u===i||t(u.prototype))||r(u)&&null===(u=u[n]))&&(u=void 0)),void 0===u?i:u}}function Un(){if(En)return An;En=1;var t=Jn();return An=function(e,r){return new(t(e))(0===r?0:r)}}function Wn(){if(kn)return Ln;kn=1;var t=Ee(),e=x(),r=St(),n=ge(),i=Mr(),o=Un(),u=e([].push),s=function(e){var s=1===e,a=2===e,c=3===e,f=4===e,l=6===e,d=7===e,h=5===e||l;return function(p,m,v,y){for(var g,b,O=n(p),w=r(O),S=i(w),P=t(m,v),j=0,x=y||o,T=s?x(p,S):a||d?x(p,0):void 0;S>j;j++)if((h||j in w)&&(b=P(g=w[j],j,O),e))if(s)T[j]=b;else if(b)switch(e){case 3:return!0;case 5:return g;case 6:return j;case 2:u(T,g)}else switch(e){case 4:return!1;case 7:u(T,g)}return l?-1:c||f?f:T}};return Ln={forEach:s(0),map:s(1),filter:s(2),some:s(3),every:s(4),find:s(5),findIndex:s(6),filterReject:s(7)}}var qn,Kn,Hn,Yn={};function Xn(){return Kn?qn:(Kn=1,qn=Ct()&&!!Symbol.for&&!!Symbol.keyFor)}var $n,Qn={};var Zn,ti,ei,ri={};function ni(){if(ti)return Zn;ti=1;var t=x(),e=Gn(),r=E(),n=T(),i=Qe(),o=t([].push);return Zn=function(t){if(r(t))return t;if(e(t)){for(var u=t.length,s=[],a=0;a<u;a++){var c=t[a];"string"==typeof c?o(s,c):"number"!=typeof c&&"Number"!==n(c)&&"String"!==n(c)||o(s,i(c))}var f=s.length,l=!0;return function(t,r){if(l)return l=!1,r;if(e(this))return r;for(var n=0;n<f;n++)if(s[n]===t)return r}}}}var ii,oi,ui,si,ai,ci,fi,li,di,hi,pi,mi,vi={};function yi(){return oi||(oi=1,function(){if(Mn)return O;Mn=1;var t=Ye(),e=w(),r=F(),n=x(),i=pe(),o=I(),u=Ct(),s=S(),a=be(),c=Lt(),f=qe(),l=xt(),d=Pe(),h=Qe(),p=wt(),m=Gr(),v=Nr(),y=Jr(),g=Yr(),b=rn(),P=Te(),j=Ke(),T=Rr(),A=Ot(),E=nn(),L=on(),k=ye(),M=Br(),C=Dr(),D=Oe(),N=we(),R=Dn(),_=In(),B=Fn(),G=Rn(),z=Bn(),V=Wn().forEach,J=M("hidden"),U="Symbol",W="prototype",q=z.set,K=z.getterFor(U),H=Object[W],Y=e.Symbol,X=Y&&Y[W],$=e.RangeError,Q=e.TypeError,Z=e.QObject,tt=P.f,et=j.f,rt=g.f,nt=A.f,it=n([].push),ot=k("symbols"),ut=k("op-symbols"),st=k("wks"),at=!Z||!Z[W]||!Z[W].findChild,ct=function(t,e,r){var n=tt(H,e);n&&delete H[e],et(t,e,r),n&&t!==H&&et(H,e,n)},ft=o&&s((function(){return 7!==m(et({},"a",{get:function(){return et(this,"a",{value:7}).a}})).a}))?ct:et,lt=function(t,e){var r=ot[t]=m(X);return q(r,{type:U,tag:t,description:e}),o||(r.description=e),r},dt=function(t,e,r){t===H&&dt(ut,e,r),f(t);var n=d(e);return f(r),a(ot,n)?(r.enumerable?(a(t,J)&&t[J][n]&&(t[J][n]=!1),r=m(r,{enumerable:p(0,!1)})):(a(t,J)||et(t,J,p(1,m(null))),t[J][n]=!0),ft(t,n,r)):et(t,n,r)},ht=function(t,e){f(t);var n=l(e),i=v(n).concat(yt(n));return V(i,(function(e){o&&!r(pt,n,e)||dt(t,e,n[e])})),t},pt=function(t){var e=d(t),n=r(nt,this,e);return!(this===H&&a(ot,e)&&!a(ut,e))&&(!(n||!a(this,e)||!a(ot,e)||a(this,J)&&this[J][e])||n)},mt=function(t,e){var r=l(t),n=d(e);if(r!==H||!a(ot,n)||a(ut,n)){var i=tt(r,n);return!i||!a(ot,n)||a(r,J)&&r[J][n]||(i.enumerable=!0),i}},vt=function(t){var e=rt(l(t)),r=[];return V(e,(function(t){a(ot,t)||a(C,t)||it(r,t)})),r},yt=function(t){var e=t===H,r=rt(e?ut:l(t)),n=[];return V(r,(function(t){!a(ot,t)||e&&!a(H,t)||it(n,ot[t])})),n};u||(Y=function(){if(c(X,this))throw new Q("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?h(arguments[0]):void 0,n=D(t),i=function(t){var o=void 0===this?e:this;o===H&&r(i,ut,t),a(o,J)&&a(o[J],n)&&(o[J][n]=!1);var u=p(1,t);try{ft(o,n,u)}catch(t){if(!(t instanceof $))throw t;ct(o,n,u)}};return o&&at&&ft(H,n,{configurable:!0,set:i}),lt(n,t)},E(X=Y[W],"toString",(function(){return K(this).tag})),E(Y,"withoutSetter",(function(t){return lt(D(t),t)})),A.f=pt,j.f=dt,T.f=ht,P.f=mt,y.f=g.f=vt,b.f=yt,R.f=function(t){return lt(N(t),t)},o&&(L(X,"description",{configurable:!0,get:function(){return K(this).description}}),i||E(H,"propertyIsEnumerable",pt,{unsafe:!0}))),t({global:!0,constructor:!0,wrap:!0,forced:!u,sham:!u},{Symbol:Y}),V(v(st),(function(t){_(t)})),t({target:U,stat:!0,forced:!u},{useSetter:function(){at=!0},useSimple:function(){at=!1}}),t({target:"Object",stat:!0,forced:!u,sham:!o},{create:function(t,e){return void 0===e?m(t):ht(m(t),e)},defineProperty:dt,defineProperties:ht,getOwnPropertyDescriptor:mt}),t({target:"Object",stat:!0,forced:!u},{getOwnPropertyNames:vt}),B(),G(Y,U),C[J]=!0}(),function(){if(Hn)return Yn;Hn=1;var t=Ye(),e=Et(),r=be(),n=Qe(),i=ye(),o=Xn(),u=i("string-to-symbol-registry"),s=i("symbol-to-string-registry");t({target:"Symbol",stat:!0,forced:!o},{for:function(t){var i=n(t);if(r(u,i))return u[i];var o=e("Symbol")(i);return u[i]=o,s[o]=i,o}})}(),function(){if($n)return Qn;$n=1;var t=Ye(),e=be(),r=It(),n=Ft(),i=ye(),o=Xn(),u=i("symbol-to-string-registry");t({target:"Symbol",stat:!0,forced:!o},{keyFor:function(t){if(!r(t))throw new TypeError(n(t)+" is not a symbol");if(e(u,t))return u[t]}})}(),function(){if(ei)return ri;ei=1;var t=Ye(),e=Et(),r=j(),n=F(),i=x(),o=S(),u=E(),s=It(),a=Hr(),c=ni(),f=Ct(),l=String,d=e("JSON","stringify"),h=i(/./.exec),p=i("".charAt),m=i("".charCodeAt),v=i("".replace),y=i(1..toString),g=/[\uD800-\uDFFF]/g,b=/^[\uD800-\uDBFF]$/,O=/^[\uDC00-\uDFFF]$/,w=!f||o((function(){var t=e("Symbol")("stringify detection");return"[null]"!==d([t])||"{}"!==d({a:t})||"{}"!==d(Object(t))})),P=o((function(){return'"\\udf06\\ud834"'!==d("\udf06\ud834")||'"\\udead"'!==d("\udead")})),T=function(t,e){var i=a(arguments),o=c(e);if(u(o)||void 0!==t&&!s(t))return i[1]=function(t,e){if(u(o)&&(e=n(o,this,l(t),e)),!s(e))return e},r(d,null,i)},A=function(t,e,r){var n=p(r,e-1),i=p(r,e+1);return h(b,t)&&!h(O,i)||h(O,t)&&!h(b,n)?"\\u"+y(m(t,0),16):t};d&&t({target:"JSON",stat:!0,arity:3,forced:w||P},{stringify:function(t,e,n){var i=a(arguments),o=r(w?T:d,null,i);return P&&"string"==typeof o?v(o,g,A):o}})}(),function(){if(ii)return vi;ii=1;var t=Ye(),e=Ct(),r=S(),n=rn(),i=ge();t({target:"Object",stat:!0,forced:!e||r((function(){n.f(1)}))},{getOwnPropertySymbols:function(t){var e=n.f;return e?e(i(t)):[]}})}()),b}function gi(){return si?ui:(si=1,yi(),ui=At().Object.getOwnPropertySymbols)}function bi(){return ci?ai:(ci=1,ai=gi())}function Oi(){return li?fi:(li=1,fi=bi())}function wi(){return hi?di:(hi=1,di=Oi())}function Si(){return mi?pi:(mi=1,pi=wi())}var Pi,ji,xi,Ti,Ai,Ei,Li,ki=r(Si()),Mi={};function Ci(){return ji?Pi:(ji=1,Pi=function(){})}function Di(){if(Ai)return Ti;Ai=1;var t=w(),e=At();return Ti=function(r,n){var i=e[r+"Prototype"],o=i&&i[n];if(o)return o;var u=t[r],s=u&&u.prototype;return s&&s[n]}}function Ii(){return Li?Ei:(Li=1,function(){if(xi)return Mi;xi=1;var t=Ye(),e=Cr().includes,r=S(),n=Ci();t({target:"Array",proto:!0,forced:r((function(){return!Array(1).includes()}))},{includes:function(t){return e(this,t,arguments.length>1?arguments[1]:void 0)}}),n("includes")}(),Ei=Di()("Array","includes"))}var Fi,Ni,Ri,_i,Bi,Gi,zi,Vi,Ji,Ui,Wi,qi,Ki,Hi,Yi,Xi,$i,Qi,Zi,to={};function eo(){if(Ni)return Fi;Ni=1;var t=Tt(),e=T(),r=we()("match");return Fi=function(n){var i;return t(n)&&(void 0!==(i=n[r])?!!i:"RegExp"===e(n))}}function ro(){if(_i)return Ri;_i=1;var t=eo(),e=TypeError;return Ri=function(r){if(t(r))throw new e("The method doesn't accept regular expressions");return r}}function no(){if(Gi)return Bi;Gi=1;var t=we()("match");return Bi=function(e){var r=/./;try{"/./"[e](r)}catch(n){try{return r[t]=!1,"/./"[e](r)}catch(t){}}return!1}}function io(){return Ji?Vi:(Ji=1,function(){if(zi)return to;zi=1;var t=Ye(),e=x(),r=ro(),n=jt(),i=Qe(),o=no(),u=e("".indexOf);t({target:"String",proto:!0,forced:!o("includes")},{includes:function(t){return!!~u(i(n(this)),i(r(t)),arguments.length>1?arguments[1]:void 0)}})}(),Vi=Di()("String","includes"))}function oo(){if(Wi)return Ui;Wi=1;var t=Lt(),e=Ii(),r=io(),n=Array.prototype,i=String.prototype;return Ui=function(o){var u=o.includes;return o===n||t(n,o)&&u===n.includes?e:"string"==typeof o||o===i||t(i,o)&&u===i.includes?r:u}}function uo(){return Ki?qi:(Ki=1,qi=oo())}function so(){return Yi?Hi:(Yi=1,Hi=uo())}function ao(){return $i?Xi:($i=1,Xi=so())}function co(){return Zi?Qi:(Zi=1,Qi=ao())}var fo=r(co());function lo(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r={};for(var n in t)if({}.hasOwnProperty.call(t,n)){if(fo(e).call(e,n))continue;r[n]=t[n]}return r}(t,e);if(ki){var o=ki(t);for(n=0;n<o.length;n++)r=o[n],fo(e).call(e,r)||{}.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}var ho,po,mo,vo,yo,go,bo,Oo,wo,So,Po={exports:{}},jo={};function xo(){if(ho)return jo;ho=1;var t=Ye(),e=I(),r=Ke().f;return t({target:"Object",stat:!0,forced:Object.defineProperty!==r,sham:!e},{defineProperty:r}),jo}function To(){if(po)return Po.exports;po=1,xo();var t=At().Object,e=Po.exports=function(e,r,n){return t.defineProperty(e,r,n)};return t.defineProperty.sham&&(e.sham=!0),Po.exports}function Ao(){return vo?mo:(vo=1,mo=To())}function Eo(){return go?yo:(go=1,yo=Ao())}function Lo(){return Oo?bo:(Oo=1,bo=Eo())}function ko(){return So?wo:(So=1,wo=Lo())}var Mo,Co,Do,Io,Fo,No,Ro,_o=r(ko()),Bo={};function Go(){if(Co)return Mo;Co=1;var t=TypeError;return Mo=function(e){if(e>9007199254740991)throw t("Maximum allowed index exceeded");return e}}function zo(){if(Io)return Do;Io=1;var t=I(),e=Ke(),r=wt();return Do=function(n,i,o){t?e.f(n,i,r(0,o)):n[i]=o}}function Vo(){if(No)return Fo;No=1;var t=S(),e=we(),r=Mt(),n=e("species");return Fo=function(e){return r>=51||!t((function(){var t=[];return(t.constructor={})[n]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}}var Jo;var Uo;var Wo;var qo,Ko={};function Ho(){return qo||(qo=1,In()("iterator")),Ko}var Yo;var Xo;var $o;var Qo;var Zo;var tu;var eu,ru={};function nu(){if(eu)return ru;eu=1;var t=In(),e=Fn();return t("toPrimitive"),e(),ru}var iu,ou={};var uu;var su,au,cu,fu={};function lu(){return cu?au:(cu=1,function(){if(Ro)return Bo;Ro=1;var t=Ye(),e=S(),r=Gn(),n=Tt(),i=ge(),o=Mr(),u=Go(),s=zo(),a=Un(),c=Vo(),f=we(),l=Mt(),d=f("isConcatSpreadable"),h=l>=51||!e((function(){var t=[];return t[d]=!1,t.concat()[0]!==t})),p=function(t){if(!n(t))return!1;var e=t[d];return void 0!==e?!!e:r(t)};t({target:"Array",proto:!0,arity:1,forced:!h||!c("concat")},{concat:function(t){var e,r,n,c,f,l=i(this),d=a(l,0),h=0;for(e=-1,n=arguments.length;e<n;e++)if(p(f=-1===e?l:arguments[e]))for(c=o(f),u(h+c),r=0;r<c;r++,h++)r in f&&s(d,h,f[r]);else u(h+1),s(d,h++,f);return d.length=h,d}})}(),yi(),Jo||(Jo=1,In()("asyncIterator")),Uo||(Uo=1,In()("hasInstance")),Wo||(Wo=1,In()("isConcatSpreadable")),Ho(),Yo||(Yo=1,In()("match")),Xo||(Xo=1,In()("matchAll")),$o||($o=1,In()("replace")),Qo||(Qo=1,In()("search")),Zo||(Zo=1,In()("species")),tu||(tu=1,In()("split")),nu(),function(){if(iu)return ou;iu=1;var t=Et(),e=In(),r=Rn();e("toStringTag"),r(t("Symbol"),"Symbol")}(),uu||(uu=1,In()("unscopables")),function(){if(su)return fu;su=1;var t=w();Rn()(t.JSON,"JSON",!0)}(),au=At().Symbol)}var du,hu,pu,mu,vu,yu,gu,bu,Ou,wu,Su,Pu,ju,xu,Tu,Au,Eu,Lu,ku,Mu,Cu,Du,Iu,Fu,Nu,Ru,_u,Bu,Gu,zu,Vu,Ju={};function Uu(){return hu?du:(hu=1,du={})}function Wu(){if(mu)return pu;mu=1;var t=I(),e=be(),r=Function.prototype,n=t&&Object.getOwnPropertyDescriptor,i=e(r,"name"),o=i&&"something"===function(){}.name,u=i&&(!t||t&&n(r,"name").configurable);return pu={EXISTS:i,PROPER:o,CONFIGURABLE:u}}function qu(){return yu?vu:(yu=1,vu=!S()((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})))}function Ku(){if(bu)return gu;bu=1;var t=be(),e=E(),r=ge(),n=Br(),i=qu(),o=n("IE_PROTO"),u=Object,s=u.prototype;return gu=i?u.getPrototypeOf:function(n){var i=r(n);if(t(i,o))return i[o];var a=i.constructor;return e(a)&&i instanceof a?a.prototype:i instanceof u?s:null}}function Hu(){if(wu)return Ou;wu=1;var t,e,r,n=S(),i=E(),o=Tt(),u=Gr(),s=Ku(),a=nn(),c=we(),f=pe(),l=c("iterator"),d=!1;return[].keys&&("next"in(r=[].keys())?(e=s(s(r)))!==Object.prototype&&(t=e):d=!0),!o(t)||n((function(){var e={};return t[l].call(e)!==e}))?t={}:f&&(t=u(t)),i(t[l])||a(t,l,(function(){return this})),Ou={IteratorPrototype:t,BUGGY_SAFARI_ITERATORS:d}}function Yu(){if(Pu)return Su;Pu=1;var t=Hu().IteratorPrototype,e=Gr(),r=wt(),n=Rn(),i=Uu(),o=function(){return this};return Su=function(u,s,a,c){var f=s+" Iterator";return u.prototype=e(t,{next:r(+!c,a)}),n(u,f,!1,!0),i[f]=o,u}}function Xu(){if(xu)return ju;xu=1;var t=x(),e=Nt();return ju=function(r,n,i){try{return t(e(Object.getOwnPropertyDescriptor(r,n)[i]))}catch(t){}}}function $u(){if(Au)return Tu;Au=1;var t=Tt();return Tu=function(e){return t(e)||null===e}}function Qu(){if(Lu)return Eu;Lu=1;var t=$u(),e=String,r=TypeError;return Eu=function(n){if(t(n))return n;throw new r("Can't set "+e(n)+" as a prototype")}}function Zu(){if(Mu)return ku;Mu=1;var t=Xu(),e=Tt(),r=jt(),n=Qu();return ku=Object.setPrototypeOf||("__proto__"in{}?function(){var i,o=!1,u={};try{(i=t(Object.prototype,"__proto__","set"))(u,[]),o=u instanceof Array}catch(t){}return function(t,u){return r(t),n(u),e(t)?(o?i(t,u):t.__proto__=u,t):t}}():void 0)}function ts(){if(Du)return Cu;Du=1;var t=Ye(),e=F(),r=pe(),n=Wu(),i=E(),o=Yu(),u=Ku(),s=Zu(),a=Rn(),c=He(),f=nn(),l=we(),d=Uu(),h=Hu(),p=n.PROPER,m=n.CONFIGURABLE,v=h.IteratorPrototype,y=h.BUGGY_SAFARI_ITERATORS,g=l("iterator"),b="keys",O="values",w="entries",S=function(){return this};return Cu=function(n,l,h,P,j,x,T){o(h,l,P);var A,E,L,k=function(t){if(t===j&&F)return F;if(!y&&t&&t in D)return D[t];switch(t){case b:case O:case w:return function(){return new h(this,t)}}return function(){return new h(this)}},M=l+" Iterator",C=!1,D=n.prototype,I=D[g]||D["@@iterator"]||j&&D[j],F=!y&&I||k(j),N="Array"===l&&D.entries||I;if(N&&(A=u(N.call(new n)))!==Object.prototype&&A.next&&(r||u(A)===v||(s?s(A,v):i(A[g])||f(A,g,S)),a(A,M,!0,!0),r&&(d[M]=S)),p&&j===O&&I&&I.name!==O&&(!r&&m?c(D,"name",O):(C=!0,F=function(){return e(I,this)})),j)if(E={values:k(O),keys:x?F:k(b),entries:k(w)},T)for(L in E)(y||C||!(L in D))&&f(D,L,E[L]);else t({target:l,proto:!0,forced:y||C},E);return r&&!T||D[g]===F||f(D,g,F,{name:j}),d[l]=F,E}}function es(){return Fu?Iu:(Fu=1,Iu=function(t,e){return{value:t,done:e}})}function rs(){if(Ru)return Nu;Ru=1;var t=xt(),e=Ci(),r=Uu(),n=Bn(),i=Ke().f,o=ts(),u=es(),s=pe(),a=I(),c="Array Iterator",f=n.set,l=n.getterFor(c);Nu=o(Array,"Array",(function(e,r){f(this,{type:c,target:t(e),index:0,kind:r})}),(function(){var t=l(this),e=t.target,r=t.index++;if(!e||r>=e.length)return t.target=null,u(void 0,!0);switch(t.kind){case"keys":return u(r,!1);case"values":return u(e[r],!1)}return u([r,e[r]],!1)}),"values");var d=r.Arguments=r.Array;if(e("keys"),e("values"),e("entries"),!s&&a&&"values"!==d.name)try{i(d,"name",{value:"values"})}catch(t){}return Nu}function ns(){return Bu?_u:(Bu=1,_u={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0})}function is(){if(Gu)return Ju;Gu=1,rs();var t=ns(),e=w(),r=Rn(),n=Uu();for(var i in t)r(e[i],i),n[i]=n.Array;return Ju}function os(){if(Vu)return zu;Vu=1;var t=lu();return is(),zu=t}var us,ss={};var as;var cs;var fs,ls,ds;function hs(){if(ds)return ls;ds=1;var t=os();return function(){if(us)return ss;us=1;var t=we(),e=Ke().f,r=t("metadata"),n=Function.prototype;void 0===n[r]&&e(n,r,{value:null})}(),as||(as=1,In()("asyncDispose")),cs||(cs=1,In()("dispose")),fs||(fs=1,In()("metadata")),ls=t}var ps,ms,vs;function ys(){if(ms)return ps;ms=1;var t=Et(),e=x(),r=t("Symbol"),n=r.keyFor,i=e(r.prototype.valueOf);return ps=r.isRegisteredSymbol||function(t){try{return void 0!==n(i(t))}catch(t){return!1}}}var gs,bs,Os;function ws(){if(bs)return gs;bs=1;for(var t=ye(),e=Et(),r=x(),n=It(),i=we(),o=e("Symbol"),u=o.isWellKnownSymbol,s=e("Object","getOwnPropertyNames"),a=r(o.prototype.valueOf),c=t("wks"),f=0,l=s(o),d=l.length;f<d;f++)try{var h=l[f];n(o[h])&&i(h)}catch(t){}return gs=function(t){if(u&&u(t))return!0;try{for(var e=a(t),r=0,n=s(c),i=n.length;r<i;r++)if(c[n[r]]==e)return!0}catch(t){}return!1},gs}var Ss;var Ps;var js;var xs;var Ts;var As;var Es;var Ls,ks,Ms,Cs,Ds;function Is(){if(Ms)return ks;Ms=1;var t=hs();return vs||(vs=1,Ye()({target:"Symbol",stat:!0},{isRegisteredSymbol:ys()})),Os||(Os=1,Ye()({target:"Symbol",stat:!0,forced:!0},{isWellKnownSymbol:ws()})),Ss||(Ss=1,In()("customMatcher")),Ps||(Ps=1,In()("observable")),js||(js=1,Ye()({target:"Symbol",stat:!0,name:"isRegisteredSymbol"},{isRegistered:ys()})),xs||(xs=1,Ye()({target:"Symbol",stat:!0,name:"isWellKnownSymbol",forced:!0},{isWellKnown:ws()})),Ts||(Ts=1,In()("matcher")),As||(As=1,In()("metadataKey")),Es||(Es=1,In()("patternMatch")),Ls||(Ls=1,In()("replaceAll")),ks=t}function Fs(){return Ds?Cs:(Ds=1,Cs=Is())}var Ns,Rs,_s,Bs,Gs,zs,Vs,Js,Us,Ws,qs,Ks,Hs,Ys=r(Fs()),Xs={};function $s(){if(Rs)return Ns;Rs=1;var t=x(),e=Er(),r=Qe(),n=jt(),i=t("".charAt),o=t("".charCodeAt),u=t("".slice),s=function(t){return function(s,a){var c,f,l=r(n(s)),d=e(a),h=l.length;return d<0||d>=h?t?"":void 0:(c=o(l,d))<55296||c>56319||d+1===h||(f=o(l,d+1))<56320||f>57343?t?i(l,d):c:t?u(l,d,d+2):f-56320+(c-55296<<10)+65536}};return Ns={codeAt:s(!1),charAt:s(!0)}}function Qs(){return Gs?Bs:(Gs=1,rs(),function(){if(_s)return Xs;_s=1;var t=$s().charAt,e=Qe(),r=Bn(),n=ts(),i=es(),o="String Iterator",u=r.set,s=r.getterFor(o);n(String,"String",(function(t){u(this,{type:o,string:e(t),index:0})}),(function(){var e,r=s(this),n=r.string,o=r.index;return o>=n.length?i(void 0,!0):(e=t(n,o),r.index+=e.length,i(e,!1))}))}(),Ho(),Bs=Dn().f("iterator"))}function Zs(){if(Vs)return zs;Vs=1;var t=Qs();return is(),zs=t}function ta(){return Us?Js:(Us=1,Js=Zs())}function ea(){return qs?Ws:(qs=1,Ws=ta())}function ra(){return Hs?Ks:(Hs=1,Ks=ea())}var na,ia,oa,ua,sa,aa,ca,fa,la,da,ha=r(ra());function pa(t){return pa="function"==typeof Ys&&"symbol"==typeof ha?function(t){return typeof t}:function(t){return t&&"function"==typeof Ys&&t.constructor===Ys&&t!==Ys.prototype?"symbol":typeof t},pa(t)}function ma(){return ia?na:(ia=1,nu(),na=Dn().f("toPrimitive"))}function va(){return ua?oa:(ua=1,oa=ma())}function ya(){return aa?sa:(aa=1,sa=va())}function ga(){return fa?ca:(fa=1,ca=ya())}function ba(){return da?la:(da=1,la=ga())}var Oa=r(ba());function wa(t){var e=function(t,e){if("object"!=pa(t)||!t)return t;var r=t[Oa];if(void 0!==r){var n=r.call(t,e||"default");if("object"!=pa(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==pa(e)?e:e+""}function Sa(t,e,r){return(e=wa(e))in t?_o(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}const Pa=["src"],ja=["href"];class xa{constructor(){Sa(this,"features",[]),Sa(this,"idPrefix","metapatcher"),Sa(this,"idCounters",{preload:0,prefetch:0,preconnect:0,dnsPrefetch:0}),Sa(this,"isDomAvailable","undefined"!=typeof document),Sa(this,"memory",[]),Sa(this,"htmlVoidElements",["base","link","meta"]),Sa(this,"mimeTypesByExtension",{svg:"image/svg+xml",png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",ico:"image/x-icon",gif:"image/gif",webp:"image/webp",bmp:"image/bmp"}),Sa(this,"reImageSizeFromStr",/[0-9]{2,3}x[0-9]{2,3}/g),Sa(this,"appleTouchIconSizes",["120x120","180x180","152x152","167x167","1024x1024"]),Sa(this,"webAppManifestIconSizes",["72x72","96x96","128x128","144x144","152x152","192x192","384x384","512x512"]),Sa(this,"msTilesNamingMap",{"70x70":"msapplication-square70x70logo","150x150":"msapplication-square150x150logo","310x310":"msapplication-square310x310logo","310x150":"msapplication-wide310x150logo"}),this.features=["structuredData","msTags","appleTags","openGraphTags","twitterTags","webAppManifest"],this.setMsApplicationConfig("none")}configure(t,e){if(null!=e&&e.idPrefix&&(this.idPrefix=e.idPrefix),t&&(this.features=t),this.features.includes("appleTags")){const t=this.idPrefix+"-apple-mobile-web-app-capable";this.set("meta",{id:t,name:"apple-mobile-web-app-capable",content:"yes"})}if(this.features.includes("twitterTags")){const t=this.idPrefix+"-twitter-card";this.set("meta",{id:t,name:"twitter:card",content:"summary"})}}setIcons(t){const e=Object.keys(this.msTilesNamingMap);for(const r of t){const t=this.findMimeType(r),n=r.match(this.reImageSizeFromStr),i=n&&n.length>0?n[0]:void 0;if(i&&t){if(this.features.includes("webAppManifest")&&this.webAppManifestIconSizes.includes(i)){const e=this.idPrefix+"-icon-"+i+"-wam";this.removeOne("link",{id:e}),this.set("link",{id:e,rel:"icon",href:r,sizes:i,type:t})}if(this.features.includes("appleTags")&&this.appleTouchIconSizes.includes(i)){const t=this.idPrefix+"-icon-"+i+"-apple";this.removeOne("link",{id:t}),this.set("link",{id:t,rel:"apple-touch-icon",href:r,sizes:i})}if(this.features.includes("msTags")&&e.includes(i)){const t=this.idPrefix+"-icon-"+i+"-ms";this.removeOne("meta",{id:t}),this.set("meta",{id:t,name:this.msTilesNamingMap[i],content:r})}}}return this}setPageDetails(t){var e;return t.title&&this.setPageTitle(t.title),t.description&&this.setPageDescription(t.description),t.path&&this.setPageUrl(t.path),t.image&&this.setPageImage(t.image),t.robots&&this.setRobots(t.robots),t.locale&&this.setPageLocale(t.locale),t.canonical&&this.setCanonical(t.canonical),t.localVersions&&this.setLocalVersions(t.localVersions,null!==(e=t.locale)&&void 0!==e?e:""),t.breadcrumb&&this.setBreadcrumb(t.breadcrumb),this}setPageTitle(t){if(this.setDocumentTitle(t),this.features.includes("openGraphTags")){const e=this.idPrefix+"og-title";this.removeOne("meta",{id:e}),this.set("meta",{id:e,property:"og:title",content:t})}if(this.features.includes("twitterTags")){const e=this.idPrefix+"tw-title";this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"twitter:title",content:t})}return this}setPageDescription(t){const e=this.idPrefix+"-description";if(this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"description",content:t}),this.features.includes("openGraphTags")){const e=this.idPrefix+"-description-og";this.removeOne("meta",{id:e}),this.set("meta",{id:e,property:"og:description",content:t})}if(this.features.includes("twitterTags")){const e=this.idPrefix+"-description-tw";this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"twitter:description",content:t})}return this}setPageUrl(t){if(this.features.includes("openGraphTags")){const e=this.idPrefix+"-url-og";this.removeOne("meta",{id:e}),this.set("meta",{id:e,property:"og:url",content:t})}return this}setPageImage(t){const e="string"==typeof t?{path:t}:t;if(this.features.includes("openGraphTags")){const t=this.idPrefix+"-image-og";this.removeOne("meta",{id:t}),this.set("meta",{id:t,property:"og:image",content:e.path});const r=this.idPrefix+"-image-w-og";this.removeOne("meta",{id:r}),e.width&&this.set("meta",{id:r,property:"og:image:width",content:e.width.toString()});const n=this.idPrefix+"-image-h-og";this.removeOne("meta",{id:n}),e.height&&this.set("meta",{id:n,property:"og:image:height",content:e.height.toString()})}if(this.features.includes("twitterTags")){const t=this.idPrefix+"-image-tw";this.removeOne("meta",{id:t}),this.set("meta",{id:t,property:"twitter:image",content:e.path})}return this}setPageLocale(t){if(t=t.replace("_","-"),this.isDomAvailable&&document.documentElement.setAttribute("lang",t),this.features.includes("openGraphTags")){const e=this.idPrefix+"-locale-og";this.removeOne("meta",{id:e}),this.set("meta",{id:e,property:"og:locale",content:t})}}setProjectDetails(t){if(t.favicon&&this.setFavicon(t.favicon),t.name&&this.setProjectName(t.name),t.url&&this.setProjectUrl(t.url),t.robots&&this.setRobots(t.robots),t.themeColor&&this.setThemeColor(t.themeColor),t.twitterSite&&this.setTwitterSite(t.twitterSite),t.safariPinnedTab&&this.setSafariPinnedTab(t.safariPinnedTab),t.icons&&this.setIcons(t.icons),this.features.includes("structuredData")){const e=this.idPrefix+"-project-org",r={"@context":"https://schema.org","@type":"Organization"};t.logo&&(r.logo=t.logo),t.url&&(r.url=t.url),t.name&&(r.name=t.name),t.email&&(r.email=t.email),t.phone&&(r.telephone=t.phone),t.description&&(r.description=t.description),t.image&&(r.image=t.image),t.legalName&&(r.legalName=t.legalName),t.address&&(r.address={"@type":"PostalAddress"},t.address.country&&(r.address.addressCountry=t.address.country),t.address.region&&(r.address.addressRegion=t.address.region),t.address.city&&(r.address.addressLocality=t.address.city),t.address.postalCode&&(r.address.postalCode=t.address.postalCode),t.address.street&&(r.address.streetAddress=t.address.street));const n=JSON.stringify(r);this.removeOne("script",{id:e}),this.isDomAvailable?this.setJsonLdDom(e,n):this.setJsonLdMemory(e,n)}return this}setProjectName(t){const e=this.idPrefix+"-project-name";if(this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"application-name",content:t}),this.features.includes("openGraphTags")){const e=this.idPrefix+"-project-name-og";this.removeOne("meta",{id:e}),this.set("meta",{id:e,property:"og:site_name",content:t})}else if(this.features.includes("appleTags")){const e=this.idPrefix+"-project-name-apple";this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"apple-mobile-web-app-title",content:t})}return this}setProjectUrl(t){if(this.features.includes("msTags")){const e=this.idPrefix+"-project-url";this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"msapplication-starturl",content:t})}return this}setThemeColor(t){const e=this.idPrefix+"-theme-color";if(this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"theme-color",content:t}),this.features.includes("msTags")){const e=this.idPrefix+"-theme-color-ms";this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"msapplication-TileColor",content:t})}return this}setTwitterSite(t){const e=this.idPrefix+"-twitter-site";return this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"twitter:site",content:t}),this}addDnsPrefetch(t){const e=this.idPrefix+"-dns-prefetch-"+this.idCounters.dnsPrefetch.toString();this.idCounters.dnsPrefetch+=1;const r="string"==typeof t?{id:e,rel:"dns-prefetch",href:t}:Object.assign({},t,{id:e,rel:"dns-prefetch"});return this.removeOne("link",{rel:"dns-prefetch",href:r.href}),this.set("link",r),this}addPreconnect(t){const e=this.idPrefix+"-preconnect-"+this.idCounters.preconnect.toString();this.idCounters.preconnect+=1;const r="string"==typeof t?{id:e,rel:"preconnect",href:t}:Object.assign({},t,{id:e,rel:"preconnect"});return this.removeOne("link",{rel:"preconnect",href:r.href}),this.set("link",r),this}addPrefetch(t){const e=this.idPrefix+"-prefetch-"+this.idCounters.prefetch.toString();this.idCounters.prefetch+=1;const r="string"==typeof t?{id:e,rel:"prefetch",href:t}:Object.assign({},t,{id:e,rel:"prefetch"});return this.removeOne("link",{rel:"prefetch",href:r.href}),this.set("link",r),this}addPreload(t){const e=this.idPrefix+"-preload-"+this.idCounters.preload.toString();this.idCounters.preload+=1;const r="string"==typeof t?{id:e,rel:"preload",href:t}:Object.assign({},t,{id:e,rel:"preload"});return this.removeOne("link",{rel:"preload",href:r.href}),this.set("link",r),this}setRobots(t){const e=this.idPrefix+"-robots",r="string"==typeof t?{id:e,name:"robots",content:t}:Object.assign({},t,{id:e,name:"robots"});return this.removeOne("meta",{id:e}),this.set("meta",r),this}setDocumentTitle(t){if(this.isDomAvailable)document.title=t;else{const e=t=>t.includes("<title>")&&t.includes("</title>");this.memory.some(e)?this.memory=this.memory.map((r=>e(r)?"<title>".concat(t,"</title>"):r)):this.memory.push("<title>".concat(t,"</title>"))}return this}setFavicon(t){if(!this.findMimeType("string"==typeof t?t:t.href))return this;const e=this.idPrefix+"-favicon",r="string"==typeof t?{id:e,rel:"shortcut icon",href:t}:Object.assign({},t,{id:e,rel:"shortcut icon"});return this.removeOne("link",{id:e}),this.set("link",r),this}setMsApplicationConfig(t){const e=this.idPrefix+"-msapplication-config",r="string"==typeof t?{id:e,name:"msapplication-config",content:t}:Object.assign({},t,{id:e,name:"msapplication-config"});return this.removeOne("meta",{id:e}),this.set("meta",r),this}setSafariPinnedTab(t){const e=this.idPrefix+"-safari-pinned-tab",r=Object.assign({},t,{id:e,rel:"mask-icon"});return this.removeOne("link",{id:e}),this.set("link",r),this}setAppleStatusBarStyle(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";const e=this.idPrefix+"-apple-status-bar-style";return this.removeOne("meta",{id:e}),this.set("meta",{id:e,name:"apple-mobile-web-app-status-bar-style",content:t}),this}setBreadcrumb(t){if(!this.features.includes("structuredData"))return"";const e=this.idPrefix+"-breadcrumb",r={"@context":"https://schema.org","@type":"BreadcrumbList",itemListElement:t.map(((t,e)=>{let{title:r,url:n}=t;return{"@type":"ListItem",position:e+1,name:r,item:n}}))},n=JSON.stringify(r);return this.removeOne("script",{id:e}),this.isDomAvailable?this.setJsonLdDom(e,n):this.setJsonLdMemory(e,n)}setJsonLdDom(t,e){const r=document.createElement("script");return r.id=t,r.type="application/ld+json",r.text=e,document.head.insertBefore(r,null),r}setJsonLdMemory(t,e){const r='<script id="'.concat(t,'" type="application/ld+json">').concat(e,"<\/script>");return this.memory.push(r),r}setCanonical(t){const e=this.idPrefix+"-canonical",r="string"==typeof t?{id:e,rel:"canonical",href:t}:Object.assign({},t,{id:e,rel:"canonical"});return this.removeOne("link",{id:e}),this.set("link",r),this}setMeta(t,e){return this.removeOne("meta",{name:t}),this.set("meta",{name:t,content:e}),this}setMobileVariant(t){const e=this.idPrefix+"-mobile-variant",r="string"==typeof t?{id:e,rel:"alternate",href:t,media:"only screen and (max-width: 640px)"}:Object.assign({},t,{id:e,rel:"alternate"});return this.removeOne("link",{id:e}),this.set("link",r),this}setLocalVersions(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";this.removeMany("link",{rel:"alternate",hreflang:!0}),this.features.includes("openGraphTags")&&(e=e.replace("_","-"),this.removeMany("meta",{property:"og:locale:alternate"}),this.removeOne("meta",{property:"og:locale"}));for(const r of t){const t=this.idPrefix+"-local-version-"+r.hreflang;r.hreflang=r.hreflang.replace("_","-");const n=Object.assign({},r,{id:t,rel:"alternate"});if(this.set("link",n),this.features.includes("openGraphTags")){const t={id:this.idPrefix+"-local-version-og-"+r.hreflang,property:"og:locale"+(e===r.hreflang?"":":alternate"),content:r.hreflang.replace("-","_")};this.set("meta",t)}}return this}setJsonLd(t,e){const r=JSON.stringify(e);return this.removeOne("script",{id:t}),this.isDomAvailable?this.setJsonLdDom(t,r):this.setJsonLdMemory(t,r)}removeOne(t,e){if(!this.isDomAvailable){const r=["<".concat(t)].concat(Object.keys(e).map((t=>"".concat(t,'="').concat(e[t],'"'))));return this.memory=this.memory.filter((t=>!r.every((e=>t.includes(e))))),this}const r=Object.keys(e).reduce(((t,r)=>t+="[".concat(r,'="').concat(e[r],'"]')),""),n="".concat(t).concat(r),i=document.head.querySelector(n);return i&&i.parentNode.removeChild(i),this}removeMany(t,e){if(!this.isDomAvailable){const r=["<".concat(t)].concat(Object.keys(e).map((t=>"boolean"==typeof e[t]?"".concat(t):"".concat(t,'="').concat(e[t],'"'))));return this.memory=this.memory.filter((t=>!r.every((e=>t.includes(e))))),this}const r=Object.keys(e).reduce(((t,r)=>t+="boolean"==typeof e[r]?"[".concat(r,"]"):"[".concat(r,'="').concat(e[r],'"]')),""),n="".concat(t).concat(r),i=document.head.querySelectorAll(n);return i&&i.length>0&&i.forEach((t=>{t.parentNode.removeChild(t)})),this}dump(){return this.isDomAvailable?"":this.memory.join("\n")}flushMemory(){return this.memory=[],this}set(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0;t=t.toLowerCase();const n=r&&Object.hasOwn(r,"void")?r.void:this.htmlVoidElements.includes(t);return this.isDomAvailable?this.setDom(t,e,{void:n}):this.setMemory(t,e,{void:n})}setDom(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=document.createElement(t);return this.setElementAttrs(r,e),document.head.insertBefore(r,null),r}setMemory(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=(arguments.length>2?arguments[2]:void 0).void?" />":"></".concat(t,">"),n="<".concat(t).concat(this.serializeAttrs(e)).concat(r);return this.memory.push(n),n}setElementAttrs(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(const r of Object.keys(e)){const n=e[r];"string"==typeof n?t.setAttribute(r,n):!0===n&&t.setAttribute(r,"")}}async setScript(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t=Object.assign({},{type:"text/javascript"},t),e=Object.assign({},{location:"headEnd",waitForLoad:"",timeout:1e4},e),new Promise(((r,n)=>{if(!this.isDomAvailable)return r(this.setMemory("script",t,{void:this.htmlVoidElements.includes("script")}));const i=setTimeout((()=>{n(new Error("Timeout."))}),e.timeout),o=document.createElement("script"),{src:u}=t,s=lo(t,Pa);this.setElementAttrs(o,s),o.addEventListener("load",(function(){if(clearTimeout(i),0===e.waitForLoad.length)return r(o);{const t=setInterval((()=>{if(Object.hasOwn(window,e.waitForLoad))return clearInterval(t),r(o)}),100)}})),o.addEventListener("error",(function(t){clearTimeout(i),n(new Error("Error loading resource"))})),o.src=u,"headEnd"===e.location?document.head.insertBefore(o,null):"bodyEnd"===e.location?document.body.insertBefore(o,null):"bodyStart"===e.location?document.body.insertBefore(o,document.body.firstChild):document.body.insertBefore(o,null)}))}async setStylesheet(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return t=Object.assign({},{rel:"stylesheet"},t),e=Object.assign({},{location:"headEnd",timeout:1e4},e),new Promise(((r,n)=>{if(!this.