jiuyiUniapp/jiuyi/node_modules/rtc-ai-denoiser/rtc-ai-denoiser.js

2 lines
76 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("trtc-js-sdk")):"function"==typeof define&&define.amd?define(["trtc-js-sdk"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).RTCAIDenoiser=e(t.TRTC)}(this,(function(t){function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var r=e(t);function n(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function o(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?n(Object(r),!0).forEach((function(e){l(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function i(){i=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n="function"==typeof Symbol?Symbol:{},o=n.iterator||"@@iterator",a=n.asyncIterator||"@@asyncIterator",u=n.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(S){c=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var o=e&&e.prototype instanceof p?e:p,i=Object.create(o.prototype),a=new x(n||[]);return i._invoke=function(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return k()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var u=A(a,r);if(u){if(u===l)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var c=f(t,e,r);if("normal"===c.type){if(n=r.done?"completed":"suspendedYield",c.arg===l)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(n="completed",r.method="throw",r.arg=c.arg)}}}(t,r,a),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(S){return{type:"throw",arg:S}}}t.wrap=s;var l={};function p(){}function h(){}function d(){}var v={};c(v,o,(function(){return this}));var y=Object.getPrototypeOf,g=y&&y(y(O([])));g&&g!==e&&r.call(g,o)&&(v=g);var m=d.prototype=p.prototype=Object.create(v);function b(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function w(t,e){function n(o,i,a,u){var c=f(t[o],t,i);if("throw"!==c.type){var s=c.arg,l=s.value;return l&&"object"==typeof l&&r.call(l,"__await")?e.resolve(l.__await).then((function(t){n("next",t,a,u)}),(function(t){n("throw",t,a,u)})):e.resolve(l).then((function(t){s.value=t,a(s)}),(function(t){return n("throw",t,a,u)}))}u(c.arg)}var o;this._invoke=function(t,r){function i(){return new e((function(e,o){n(t,r,e,o)}))}return o=o?o.then(i,i):i()}}function A(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,A(t,e),"throw"===e.method))return l;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return l}var n=f(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,l;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,l):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,l)}function _(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function x(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function O(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:k}}function k(){return{value:void 0,done:!0}}return h.prototype=d,c(m,"constructor",d),c(d,"constructor",h),h.displayName=c(d,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,c(t,u,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},b(w.prototype),c(w.prototype,a,(function(){return this})),t.AsyncIterator=w,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new w(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(m),c(m,u,"Generator"),c(m,o,(function(){return this})),c(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){for(;e.length;){var n=e.pop();if(n in t)return r.value=n,r.done=!1,r}return r.done=!0,r}},t.values=O,x.prototype={constructor:x,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(T),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var u=r.call(i,"catchLoc"),c=r.call(i,"finallyLoc");if(u&&c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,l):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),l},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),T(r),l}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;T(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:O(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),l}},t}function a(t,e,r,n,o,i,a){try{var u=t[i](a),c=u.value}catch(s){return void r(s)}u.done?e(c):Promise.resolve(c).then(n,o)}function u(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function u(t){a(i,n,o,u,c,"next",t)}function c(t){a(i,n,o,u,c,"throw",t)}u(void 0)}))}}function c(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function f(t,e,r){return e&&s(t.prototype,e),r&&s(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}function l(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var p="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},h=function(t){try{return!!t()}catch(e){return!0}},d=!h((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})),v=d,y=Function.prototype,g=y.call,m=v&&y.bind.bind(g,g),b=function(t){return v?m(t):function(){return g.apply(t,arguments)}},w=b,A=w({}.toString),_=w("".slice),T=function(t){return _(A(t),8,-1)},x=T,O=b,k=function(t){if("Function"===x(t))return O(t)},S=h,E=T,I=Object,C=k("".split),j=S((function(){return!I("z").propertyIsEnumerable(0)}))?function(t){return"String"==E(t)?C(t,""):I(t)}:I,P=function(t){return null==t},M=P,L=TypeError,R=function(t){if(M(t))throw L("Can't call method on "+t);return t},D=j,N=R,F=function(t){return D(N(t))},U=function(t){return t&&t.Math==Math&&t},B=U("object"==typeof globalThis&&globalThis)||U("object"==typeof window&&window)||U("object"==typeof self&&self)||U("object"==typeof p&&p)||function(){return this}()||Function("return this")(),V={exports:{}},G=B,W=Object.defineProperty,Y=function(t,e){try{W(G,t,{value:e,configurable:!0,writable:!0})}catch(r){G[t]=e}return e},z=Y,H="__core-js_shared__",K=B[H]||z(H,{}),q=K;(V.exports=function(t,e){return q[t]||(q[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.25.5",mode:"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.25.5/LICENSE",source:"https://github.com/zloirock/core-js"});var X,$,J=R,Q=Object,Z=function(t){return Q(J(t))},tt=Z,et=k({}.hasOwnProperty),rt=Object.hasOwn||function(t,e){return et(tt(t),e)},nt=k,ot=0,it=Math.random(),at=nt(1..toString),ut=function(t){return"Symbol("+(void 0===t?"":t)+")_"+at(++ot+it,36)},ct="object"==typeof document&&document.all,st={all:ct,IS_HTMLDDA:void 0===ct&&void 0!==ct},ft=st.all,lt=st.IS_HTMLDDA?function(t){return"function"==typeof t||t===ft}:function(t){return"function"==typeof t},pt=B,ht=lt,dt=function(t){return ht(t)?t:void 0},vt=function(t,e){return arguments.length<2?dt(pt[t]):pt[t]&&pt[t][e]},yt=vt("navigator","userAgent")||"",gt=B,mt=yt,bt=gt.process,wt=gt.Deno,At=bt&&bt.versions||wt&&wt.version,_t=At&&At.v8;_t&&($=(X=_t.split("."))[0]>0&&X[0]<4?1:+(X[0]+X[1])),!$&&mt&&(!(X=mt.match(/Edge\/(\d+)/))||X[1]>=74)&&(X=mt.match(/Chrome\/(\d+)/))&&($=+X[1]);var Tt=$,xt=Tt,Ot=h,kt=!!Object.getOwnPropertySymbols&&!Ot((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&xt&&xt<41})),St=kt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,Et=B,It=V.exports,Ct=rt,jt=ut,Pt=kt,Mt=St,Lt=It("wks"),Rt=Et.Symbol,Dt=Rt&&Rt.for,Nt=Mt?Rt:Rt&&Rt.withoutSetter||jt,Ft=function(t){if(!Ct(Lt,t)||!Pt&&"string"!=typeof Lt[t]){var e="Symbol."+t;Pt&&Ct(Rt,t)?Lt[t]=Rt[t]:Lt[t]=Mt&&Dt?Dt(e):Nt(e)}return Lt[t]},Ut=lt,Bt=st.all,Vt=st.IS_HTMLDDA?function(t){return"object"==typeof t?null!==t:Ut(t)||t===Bt}:function(t){return"object"==typeof t?null!==t:Ut(t)},Gt=Vt,Wt=String,Yt=TypeError,zt=function(t){if(Gt(t))return t;throw Yt(Wt(t)+" is not an object")},Ht={},Kt=!h((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),qt=Kt&&h((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),Xt={},$t=Vt,Jt=B.document,Qt=$t(Jt)&&$t(Jt.createElement),Zt=function(t){return Qt?Jt.createElement(t):{}},te=Zt,ee=!Kt&&!h((function(){return 7!=Object.defineProperty(te("div"),"a",{get:function(){return 7}}).a})),re=d,ne=Function.prototype.call,oe=re?ne.bind(ne):function(){return ne.apply(ne,arguments)},ie=k({}.isPrototypeOf),ae=vt,ue=lt,ce=ie,se=Object,fe=St?function(t){return"symbol"==typeof t}:function(t){var e=ae("Symbol");return ue(e)&&ce(e.prototype,se(t))},le=String,pe=function(t){try{return le(t)}catch(e){return"Object"}},he=lt,de=pe,ve=TypeError,ye=function(t){if(he(t))return t;throw ve(de(t)+" is not a function")},ge=ye,me=P,be=function(t,e){var r=t[e];return me(r)?void 0:ge(r)},we=oe,Ae=lt,_e=Vt,Te=TypeError,xe=oe,Oe=Vt,ke=fe,Se=be,Ee=function(t,e){var r,n;if("string"===e&&Ae(r=t.toString)&&!_e(n=we(r,t)))return n;if(Ae(r=t.valueOf)&&!_e(n=we(r,t)))return n;if("string"!==e&&Ae(r=t.toString)&&!_e(n=we(r,t)))return n;throw Te("Can't convert object to primitive value")},Ie=TypeError,Ce=Ft("toPrimitive"),je=function(t,e){if(!Oe(t)||ke(t))return t;var r,n=Se(t,Ce);if(n){if(void 0===e&&(e="default"),r=xe(n,t,e),!Oe(r)||ke(r))return r;throw Ie("Can't convert object to primitive value")}return void 0===e&&(e="number"),Ee(t,e)},Pe=je,Me=fe,Le=function(t){var e=Pe(t,"string");return Me(e)?e:e+""},Re=Kt,De=ee,Ne=qt,Fe=zt,Ue=Le,Be=TypeError,Ve=Object.defineProperty,Ge=Object.getOwnPropertyDescriptor,We="enumerable",Ye="configurable",ze="writable";Xt.f=Re?Ne?function(t,e,r){if(Fe(t),e=Ue(e),Fe(r),"function"==typeof t&&"prototype"===e&&"value"in r&&ze in r&&!r.writable){var n=Ge(t,e);n&&n.writable&&(t[e]=r.value,r={configurable:Ye in r?r.configurable:n.configurable,enumerable:We in r?r.enumerable:n.enumerable,writable:!1})}return Ve(t,e,r)}:Ve:function(t,e,r){if(Fe(t),e=Ue(e),Fe(r),De)try{return Ve(t,e,r)}catch(n){}if("get"in r||"set"in r)throw Be("Accessors not supported");return"value"in r&&(t[e]=r.value),t};var He=Math.ceil,Ke=Math.floor,qe=Math.trunc||function(t){var e=+t;return(e>0?Ke:He)(e)},Xe=function(t){var e=+t;return e!=e||0===e?0:qe(e)},$e=Xe,Je=Math.max,Qe=Math.min,Ze=function(t,e){var r=$e(t);return r<0?Je(r+e,0):Qe(r,e)},tr=Xe,er=Math.min,rr=function(t){return t>0?er(tr(t),9007199254740991):0},nr=rr,or=function(t){return nr(t.length)},ir=F,ar=Ze,ur=or,cr=function(t){return function(e,r,n){var o,i=ir(e),a=ur(i),u=ar(n,a);if(t&&r!=r){for(;a>u;)if((o=i[u++])!=o)return!0}else for(;a>u;u++)if((t||u in i)&&i[u]===r)return t||u||0;return!t&&-1}},sr={includes:cr(!0),indexOf:cr(!1)},fr={},lr=rt,pr=F,hr=sr.indexOf,dr=fr,vr=k([].push),yr=function(t,e){var r,n=pr(t),o=0,i=[];for(r in n)!lr(dr,r)&&lr(n,r)&&vr(i,r);for(;e.length>o;)lr(n,r=e[o++])&&(~hr(i,r)||vr(i,r));return i},gr=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],mr=yr,br=gr,wr=Object.keys||function(t){return mr(t,br)},Ar=Kt,_r=qt,Tr=Xt,xr=zt,Or=F,kr=wr;Ht.f=Ar&&!_r?Object.defineProperties:function(t,e){xr(t);for(var r,n=Or(e),o=kr(e),i=o.length,a=0;i>a;)Tr.f(t,r=o[a++],n[r]);return t};var Sr,Er=vt("document","documentElement"),Ir=V.exports,Cr=ut,jr=Ir("keys"),Pr=function(t){return jr[t]||(jr[t]=Cr(t))},Mr=zt,Lr=Ht,Rr=gr,Dr=fr,Nr=Er,Fr=Zt,Ur=Pr("IE_PROTO"),Br=function(){},Vr=function(t){return"<script>"+t+"</"+"script>"},Gr=function(t){t.write(Vr("")),t.close();var e=t.parentWindow.Object;return t=null,e},Wr=function(){try{Sr=new ActiveXObject("htmlfile")}catch(n){}var t,e;Wr="undefined"!=typeof document?document.domain&&Sr?Gr(Sr):((e=Fr("iframe")).style.display="none",Nr.appendChild(e),e.src=String("javascript:"),(t=e.contentWindow.document).open(),t.write(Vr("document.F=Object")),t.close(),t.F):Gr(Sr);for(var r=Rr.length;r--;)delete Wr.prototype[Rr[r]];return Wr()};Dr[Ur]=!0;var Yr=Object.create||function(t,e){var r;return null!==t?(Br.prototype=Mr(t),r=new Br,Br.prototype=null,r[Ur]=t):r=Wr(),void 0===e?r:Lr.f(r,e)},zr=Ft,Hr=Yr,Kr=Xt.f,qr=zr("unscopables"),Xr=Array.prototype;null==Xr[qr]&&Kr(Xr,qr,{configurable:!0,value:Hr(null)});var $r,Jr,Qr,Zr={},tn=lt,en=B.WeakMap,rn=tn(en)&&/native code/.test(String(en)),nn=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},on=Xt,an=nn,un=Kt?function(t,e,r){return on.f(t,e,an(1,r))}:function(t,e,r){return t[e]=r,t},cn=rn,sn=B,fn=Vt,ln=un,pn=rt,hn=K,dn=Pr,vn=fr,yn="Object already initialized",gn=sn.TypeError,mn=sn.WeakMap;if(cn||hn.state){var bn=hn.state||(hn.state=new mn);bn.get=bn.get,bn.has=bn.has,bn.set=bn.set,$r=function(t,e){if(bn.has(t))throw gn(yn);return e.facade=t,bn.set(t,e),e},Jr=function(t){return bn.get(t)||{}},Qr=function(t){return bn.has(t)}}else{var wn=dn("state");vn[wn]=!0,$r=function(t,e){if(pn(t,wn))throw gn(yn);return e.facade=t,ln(t,wn,e),e},Jr=function(t){return pn(t,wn)?t[wn]:{}},Qr=function(t){return pn(t,wn)}}var An={set:$r,get:Jr,has:Qr,enforce:function(t){return Qr(t)?Jr(t):$r(t,{})},getterFor:function(t){return function(e){var r;if(!fn(e)||(r=Jr(e)).type!==t)throw gn("Incompatible receiver, "+t+" required");return r}}},_n={},Tn={},xn={}.propertyIsEnumerable,On=Object.getOwnPropertyDescriptor,kn=On&&!xn.call({1:2},1);Tn.f=kn?function(t){var e=On(this,t);return!!e&&e.enumerable}:xn;var Sn=Kt,En=oe,In=Tn,Cn=nn,jn=F,Pn=Le,Mn=rt,Ln=ee,Rn=Object.getOwnPropertyDescriptor;_n.f=Sn?Rn:function(t,e){if(t=jn(t),e=Pn(e),Ln)try{return Rn(t,e)}catch(r){}if(Mn(t,e))return Cn(!En(In.f,t,e),t[e])};var Dn={exports:{}},Nn=Kt,Fn=rt,Un=Function.prototype,Bn=Nn&&Object.getOwnPropertyDescriptor,Vn=Fn(Un,"name"),Gn={EXISTS:Vn,PROPER:Vn&&"something"===function(){}.name,CONFIGURABLE:Vn&&(!Nn||Nn&&Bn(Un,"name").configurable)},Wn=lt,Yn=K,zn=k(Function.toString);Wn(Yn.inspectSource)||(Yn.inspectSource=function(t){return zn(t)});var Hn=Yn.inspectSource,Kn=h,qn=lt,Xn=rt,$n=Kt,Jn=Gn.CONFIGURABLE,Qn=Hn,Zn=An.enforce,to=An.get,eo=Object.defineProperty,ro=$n&&!Kn((function(){return 8!==eo((function(){}),"length",{value:8}).length})),no=String(String).split("String"),oo=Dn.exports=function(t,e,r){"Symbol("===String(e).slice(0,7)&&(e="["+String(e).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),r&&r.getter&&(e="get "+e),r&&r.setter&&(e="set "+e),(!Xn(t,"name")||Jn&&t.name!==e)&&($n?eo(t,"name",{value:e,configurable:!0}):t.name=e),ro&&r&&Xn(r,"arity")&&t.length!==r.arity&&eo(t,"length",{value:r.arity});try{r&&Xn(r,"constructor")&&r.constructor?$n&&eo(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(o){}var n=Zn(t);return Xn(n,"source")||(n.source=no.join("string"==typeof e?e:"")),t};Function.prototype.toString=oo((function(){return qn(this)&&to(this).source||Qn(this)}),"toString");var io=lt,ao=Xt,uo=Dn.exports,co=Y,so=function(t,e,r,n){n||(n={});var o=n.enumerable,i=void 0!==n.name?n.name:e;if(io(r)&&uo(r,i,n),n.global)o?t[e]=r:co(e,r);else{try{n.unsafe?t[e]&&(o=!0):delete t[e]}catch(a){}o?t[e]=r:ao.f(t,e,{value:r,enumerable:!1,configurable:!n.nonConfigurable,writable:!n.nonWritable})}return t},fo={},lo=yr,po=gr.concat("length","prototype");fo.f=Object.getOwnPropertyNames||function(t){return lo(t,po)};var ho={};ho.f=Object.getOwnPropertySymbols;var vo,yo,go,mo=vt,bo=fo,wo=ho,Ao=zt,_o=k([].concat),To=mo("Reflect","ownKeys")||function(t){var e=bo.f(Ao(t)),r=wo.f;return r?_o(e,r(t)):e},xo=rt,Oo=To,ko=_n,So=Xt,Eo=h,Io=lt,Co=/#|\.prototype\./,jo=function(t,e){var r=Mo[Po(t)];return r==Ro||r!=Lo&&(Io(e)?Eo(e):!!e)},Po=jo.normalize=function(t){return String(t).replace(Co,".").toLowerCase()},Mo=jo.data={},Lo=jo.NATIVE="N",Ro=jo.POLYFILL="P",Do=jo,No=B,Fo=_n.f,Uo=un,Bo=so,Vo=Y,Go=function(t,e,r){for(var n=Oo(e),o=So.f,i=ko.f,a=0;a<n.length;a++){var u=n[a];xo(t,u)||r&&xo(r,u)||o(t,u,i(e,u))}},Wo=Do,Yo=function(t,e){var r,n,o,i,a,u=t.target,c=t.global,s=t.stat;if(r=c?No:s?No[u]||Vo(u,{}):(No[u]||{}).prototype)for(n in e){if(i=e[n],o=t.dontCallGetSet?(a=Fo(r,n))&&a.value:r[n],!Wo(c?n:u+(s?".":"#")+n,t.forced)&&void 0!==o){if(typeof i==typeof o)continue;Go(i,o)}(t.sham||o&&o.sham)&&Uo(i,"sham",!0),Bo(r,n,i,t)}},zo=!h((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),Ho=rt,Ko=lt,qo=Z,Xo=zo,$o=Pr("IE_PROTO"),Jo=Object,Qo=Jo.prototype,Zo=Xo?Jo.getPrototypeOf:function(t){var e=qo(t);if(Ho(e,$o))return e[$o];var r=e.constructor;return Ko(r)&&e instanceof r?r.prototype:e instanceof Jo?Qo:null},ti=h,ei=lt,ri=Vt,ni=Zo,oi=so,ii=Ft("iterator"),ai=!1;[].keys&&("next"in(go=[].keys())?(yo=ni(ni(go)))!==Object.prototype&&(vo=yo):ai=!0);var ui=!ri(vo)||ti((function(){var t={};return vo[ii].call(t)!==t}));ui&&(vo={}),ei(vo[ii])||oi(vo,ii,(function(){return this}));var ci={IteratorPrototype:vo,BUGGY_SAFARI_ITERATORS:ai},si=Xt.f,fi=rt,li=Ft("toStringTag"),pi=function(t,e,r){t&&!r&&(t=t.prototype),t&&!fi(t,li)&&si(t,li,{configurable:!0,value:e})},hi=ci.IteratorPrototype,di=Yr,vi=nn,yi=pi,gi=Zr,mi=function(){return this},bi=lt,wi=String,Ai=TypeError,_i=k,Ti=zt,xi=function(t){if("object"==typeof t||bi(t))return t;throw Ai("Can't set "+wi(t)+" as a prototype")},Oi=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,r={};try{(t=_i(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(r,[]),e=r instanceof Array}catch(n){}return function(r,n){return Ti(r),xi(n),e?t(r,n):r.__proto__=n,r}}():void 0),ki=Yo,Si=oe,Ei=lt,Ii=function(t,e,r,n){var o=e+" Iterator";return t.prototype=di(hi,{next:vi(+!n,r)}),yi(t,o,!1),gi[o]=mi,t},Ci=Zo,ji=Oi,Pi=pi,Mi=un,Li=so,Ri=Zr,Di=Gn.PROPER,Ni=Gn.CONFIGURABLE,Fi=ci.IteratorPrototype,Ui=ci.BUGGY_SAFARI_ITERATORS,Bi=Ft("iterator"),Vi="keys",Gi="values",Wi="entries",Yi=function(){return this},zi=function(t,e,r,n,o,i,a){Ii(r,e,n);var u,c,s,f=function(t){if(t===o&&v)return v;if(!Ui&&t in h)return h[t];switch(t){case Vi:case Gi:case Wi:return function(){return new r(this,t)}}return function(){return new r(this)}},l=e+" Iterator",p=!1,h=t.prototype,d=h[Bi]||h["@@iterator"]||o&&h[o],v=!Ui&&d||f(o),y="Array"==e&&h.entries||d;if(y&&(u=Ci(y.call(new t)))!==Object.prototype&&u.next&&(Ci(u)!==Fi&&(ji?ji(u,Fi):Ei(u[Bi])||Li(u,Bi,Yi)),Pi(u,l,!0)),Di&&o==Gi&&d&&d.name!==Gi&&(Ni?Mi(h,"name",Gi):(p=!0,v=function(){return Si(d,this)})),o)if(c={values:f(Gi),keys:i?v:f(Vi),entries:f(Wi)},a)for(s in c)(Ui||p||!(s in h))&&Li(h,s,c[s]);else ki({target:e,proto:!0,forced:Ui||p},c);return h[Bi]!==v&&Li(h,Bi,v,{name:o}),Ri[e]=v,c},Hi=function(t,e){return{value:t,done:e}},Ki=F,qi=function(t){Xr[qr][t]=!0},Xi=Zr,$i=An,Ji=Xt.f,Qi=zi,Zi=Hi,ta=Kt,ea="Array Iterator",ra=$i.set,na=$i.getterFor(ea),oa=Qi(Array,"Array",(function(t,e){ra(this,{type:ea,target:Ki(t),index:0,kind:e})}),(function(){var t=na(this),e=t.target,r=t.kind,n=t.index++;return!e||n>=e.length?(t.target=void 0,Zi(void 0,!0)):Zi("keys"==r?n:"values"==r?e[n]:[n,e[n]],!1)}),"values"),ia=Xi.Arguments=Xi.Array;if(qi("keys"),qi("values"),qi("entries"),ta&&"values"!==ia.name)try{Ji(ia,"name",{value:"values"})}catch(WA){}var aa={exports:{}},ua={},ca=Le,sa=Xt,fa=nn,la=function(t,e,r){var n=ca(e);n in t?sa.f(t,n,fa(0,r)):t[n]=r},pa=Ze,ha=or,da=la,va=Array,ya=Math.max,ga=function(t,e,r){for(var n=ha(t),o=pa(e,n),i=pa(void 0===r?n:r,n),a=va(ya(i-o,0)),u=0;o<i;o++,u++)da(a,u,t[o]);return a.length=u,a},ma=T,ba=F,wa=fo.f,Aa=ga,_a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];ua.f=function(t){return _a&&"Window"==ma(t)?function(t){try{return wa(t)}catch(WA){return Aa(_a)}}(t):wa(ba(t))};var Ta=h((function(){if("function"==typeof ArrayBuffer){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}})),xa=h,Oa=Vt,ka=T,Sa=Ta,Ea=Object.isExtensible,Ia=xa((function(){Ea(1)}))||Sa?function(t){return!!Oa(t)&&((!Sa||"ArrayBuffer"!=ka(t))&&(!Ea||Ea(t)))}:Ea,Ca=!h((function(){return Object.isExtensible(Object.preventExtensions({}))})),ja=Yo,Pa=k,Ma=fr,La=Vt,Ra=rt,Da=Xt.f,Na=fo,Fa=ua,Ua=Ia,Ba=Ca,Va=!1,Ga=ut("meta"),Wa=0,Ya=function(t){Da(t,Ga,{value:{objectID:"O"+Wa++,weakData:{}}})},za=aa.exports={enable:function(){za.enable=function(){},Va=!0;var t=Na.f,e=Pa([].splice),r={};r[Ga]=1,t(r).length&&(Na.f=function(r){for(var n=t(r),o=0,i=n.length;o<i;o++)if(n[o]===Ga){e(n,o,1);break}return n},ja({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:Fa.f}))},fastKey:function(t,e){if(!La(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!Ra(t,Ga)){if(!Ua(t))return"F";if(!e)return"E";Ya(t)}return t[Ga].objectID},getWeakData:function(t,e){if(!Ra(t,Ga)){if(!Ua(t))return!0;if(!e)return!1;Ya(t)}return t[Ga].weakData},onFreeze:function(t){return Ba&&Va&&Ua(t)&&!Ra(t,Ga)&&Ya(t),t}};Ma[Ga]=!0;var Ha=ye,Ka=d,qa=k(k.bind),Xa=function(t,e){return Ha(t),void 0===e?t:Ka?qa(t,e):function(){return t.apply(e,arguments)}},$a=Zr,Ja=Ft("iterator"),Qa=Array.prototype,Za=function(t){return void 0!==t&&($a.Array===t||Qa[Ja]===t)},tu={};tu[Ft("toStringTag")]="z";var eu="[object z]"===String(tu),ru=eu,nu=lt,ou=T,iu=Ft("toStringTag"),au=Object,uu="Arguments"==ou(function(){return arguments}()),cu=ru?ou:function(t){var e,r,n;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(r=function(t,e){try{return t[e]}catch(WA){}}(e=au(t),iu))?r:uu?ou(e):"Object"==(n=ou(e))&&nu(e.callee)?"Arguments":n},su=cu,fu=be,lu=P,pu=Zr,hu=Ft("iterator"),du=function(t){if(!lu(t))return fu(t,hu)||fu(t,"@@iterator")||pu[su(t)]},vu=oe,yu=ye,gu=zt,mu=pe,bu=du,wu=TypeError,Au=function(t,e){var r=arguments.length<2?bu(t):e;if(yu(r))return gu(vu(r,t));throw wu(mu(t)+" is not iterable")},_u=oe,Tu=zt,xu=be,Ou=Xa,ku=oe,Su=zt,Eu=pe,Iu=Za,Cu=or,ju=ie,Pu=Au,Mu=du,Lu=function(t,e,r){var n,o;Tu(t);try{if(!(n=xu(t,"return"))){if("throw"===e)throw r;return r}n=_u(n,t)}catch(WA){o=!0,n=WA}if("throw"===e)throw r;if(o)throw n;return Tu(n),r},Ru=TypeError,Du=function(t,e){this.stopped=t,this.result=e},Nu=Du.prototype,Fu=function(t,e,r){var n,o,i,a,u,c,s,f=r&&r.that,l=!(!r||!r.AS_ENTRIES),p=!(!r||!r.IS_RECORD),h=!(!r||!r.IS_ITERATOR),d=!(!r||!r.INTERRUPTED),v=Ou(e,f),y=function(t){return n&&Lu(n,"normal",t),new Du(!0,t)},g=function(t){return l?(Su(t),d?v(t[0],t[1],y):v(t[0],t[1])):d?v(t,y):v(t)};if(p)n=t.iterator;else if(h)n=t;else{if(!(o=Mu(t)))throw Ru(Eu(t)+" is not iterable");if(Iu(o)){for(i=0,a=Cu(t);a>i;i++)if((u=g(t[i]))&&ju(Nu,u))return u;return new Du(!1)}n=Pu(t,o)}for(c=p?t.next:n.next;!(s=ku(c,n)).done;){try{u=g(s.value)}catch(WA){Lu(n,"throw",WA)}if("object"==typeof u&&u&&ju(Nu,u))return u}return new Du(!1)},Uu=ie,Bu=TypeError,Vu=function(t,e){if(Uu(e,t))return t;throw Bu("Incorrect invocation")},Gu=Ft("iterator"),Wu=!1;try{var Yu=0,zu={next:function(){return{done:!!Yu++}},return:function(){Wu=!0}};zu[Gu]=function(){return this},Array.from(zu,(function(){throw 2}))}catch(WA){}var Hu=function(t,e){if(!e&&!Wu)return!1;var r=!1;try{var n={};n[Gu]=function(){return{next:function(){return{done:r=!0}}}},t(n)}catch(WA){}return r},Ku=lt,qu=Vt,Xu=Oi,$u=function(t,e,r){var n,o;return Xu&&Ku(n=e.constructor)&&n!==r&&qu(o=n.prototype)&&o!==r.prototype&&Xu(t,o),t},Ju=Yo,Qu=B,Zu=k,tc=Do,ec=so,rc=aa.exports,nc=Fu,oc=Vu,ic=lt,ac=P,uc=Vt,cc=h,sc=Hu,fc=pi,lc=$u,pc=so,hc=function(t,e,r){for(var n in e)pc(t,n,e[n],r);return t},dc=vt,vc=Xt,yc=Kt,gc=Ft("species"),mc=function(t){var e=dc(t),r=vc.f;yc&&e&&!e[gc]&&r(e,gc,{configurable:!0,get:function(){return this}})},bc=Xt.f,wc=Yr,Ac=hc,_c=Xa,Tc=Vu,xc=P,Oc=Fu,kc=zi,Sc=Hi,Ec=mc,Ic=Kt,Cc=aa.exports.fastKey,jc=An.set,Pc=An.getterFor,Mc={getConstructor:function(t,e,r,n){var o=t((function(t,o){Tc(t,i),jc(t,{type:e,index:wc(null),first:void 0,last:void 0,size:0}),Ic||(t.size=0),xc(o)||Oc(o,t[n],{that:t,AS_ENTRIES:r})})),i=o.prototype,a=Pc(e),u=function(t,e,r){var n,o,i=a(t),u=c(t,e);return u?u.value=r:(i.last=u={index:o=Cc(e,!0),key:e,value:r,previous:n=i.last,next:void 0,removed:!1},i.first||(i.first=u),n&&(n.next=u),Ic?i.size++:t.size++,"F"!==o&&(i.index[o]=u)),t},c=function(t,e){var r,n=a(t),o=Cc(e);if("F"!==o)return n.index[o];for(r=n.first;r;r=r.next)if(r.key==e)return r};return Ac(i,{clear:function(){for(var t=a(this),e=t.index,r=t.first;r;)r.removed=!0,r.previous&&(r.previous=r.previous.next=void 0),delete e[r.index],r=r.next;t.first=t.last=void 0,Ic?t.size=0:this.size=0},delete:function(t){var e=this,r=a(e),n=c(e,t);if(n){var o=n.next,i=n.previous;delete r.index[n.index],n.removed=!0,i&&(i.next=o),o&&(o.previous=i),r.first==n&&(r.first=o),r.last==n&&(r.last=i),Ic?r.size--:e.size--}return!!n},forEach:function(t){for(var e,r=a(this),n=_c(t,arguments.length>1?arguments[1]:void 0);e=e?e.next:r.first;)for(n(e.value,e.key,this);e&&e.removed;)e=e.previous},has:function(t){return!!c(this,t)}}),Ac(i,r?{get:function(t){var e=c(this,t);return e&&e.value},set:function(t,e){return u(this,0===t?0:t,e)}}:{add:function(t){return u(this,t=0===t?0:t,t)}}),Ic&&bc(i,"size",{get:function(){return a(this).size}}),o},setStrong:function(t,e,r){var n=e+" Iterator",o=Pc(e),i=Pc(n);kc(t,e,(function(t,e){jc(this,{type:n,target:t,state:o(t),kind:e,last:void 0})}),(function(){for(var t=i(this),e=t.kind,r=t.last;r&&r.removed;)r=r.previous;return t.target&&(t.last=r=r?r.next:t.state.first)?Sc("keys"==e?r.key:"values"==e?r.value:[r.key,r.value],!1):(t.target=void 0,Sc(void 0,!0))}),r?"entries":"values",!r,!0),Ec(e)}},Lc=function(t,e,r){var n=-1!==t.indexOf("Map"),o=-1!==t.indexOf("Weak"),i=n?"set":"add",a=Qu[t],u=a&&a.prototype,c=a,s={},f=function(t){var e=Zu(u[t]);ec(u,t,"add"==t?function(t){return e(this,0===t?0:t),this}:"delete"==t?function(t){return!(o&&!uc(t))&&e(this,0===t?0:t)}:"get"==t?function(t){return o&&!uc(t)?void 0:e(this,0===t?0:t)}:"has"==t?function(t){return!(o&&!uc(t))&&e(this,0===t?0:t)}:function(t,r){return e(this,0===t?0:t,r),this})};if(tc(t,!ic(a)||!(o||u.forEach&&!cc((function(){(new a).entries().next()})))))c=r.getConstructor(e,t,n,i),rc.enable();else if(tc(t,!0)){var l=new c,p=l[i](o?{}:-0,1)!=l,h=cc((function(){l.has(1)})),d=sc((function(t){new a(t)})),v=!o&&cc((function(){for(var t=new a,e=5;e--;)t[i](e,e);return!t.has(-0)}));d||((c=e((function(t,e){oc(t,u);var r=lc(new a,t,c);return ac(e)||nc(e,r[i],{that:r,AS_ENTRIES:n}),r}))).prototype=u,u.constructor=c),(h||v)&&(f("delete"),f("has"),n&&f("get")),(v||p)&&f(i),o&&u.clear&&delete u.clear}return s[t]=c,Ju({global:!0,constructor:!0,forced:c!=a},s),fc(c,t),o||r.setStrong(c,t,n),c};Lc("Map",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),Mc);var Rc=cu,Dc=eu?{}.toString:function(){return"[object "+Rc(this)+"]"};eu||so(Object.prototype,"toString",Dc,{unsafe:!0});var Nc=cu,Fc=String,Uc=function(t){if("Symbol"===Nc(t))throw TypeError("Cannot convert a Symbol value to a string");return Fc(t)},Bc=k,Vc=Xe,Gc=Uc,Wc=R,Yc=Bc("".charAt),zc=Bc("".charCodeAt),Hc=Bc("".slice),Kc=function(t){return function(e,r){var n,o,i=Gc(Wc(e)),a=Vc(r),u=i.length;return a<0||a>=u?t?"":void 0:(n=zc(i,a))<55296||n>56319||a+1===u||(o=zc(i,a+1))<56320||o>57343?t?Yc(i,a):n:t?Hc(i,a,a+2):o-56320+(n-55296<<10)+65536}},qc={codeAt:Kc(!1),charAt:Kc(!0)}.charAt,Xc=Uc,$c=An,Jc=zi,Qc=Hi,Zc="String Iterator",ts=$c.set,es=$c.getterFor(Zc);Jc(String,"String",(function(t){ts(this,{type:Zc,string:Xc(t),index:0})}),(function(){var t,e=es(this),r=e.string,n=e.index;return n>=r.length?Qc(void 0,!0):(t=qc(r,n),e.index+=t.length,Qc(t,!1))}));var rs=Zt("span").classList,ns=rs&&rs.constructor&&rs.constructor.prototype,os=ns===Object.prototype?void 0:ns,is=B,as={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},us=os,cs=oa,ss=un,fs=Ft,ls=fs("iterator"),ps=fs("toStringTag"),hs=cs.values,ds=function(t,e){if(t){if(t[ls]!==hs)try{ss(t,ls,hs)}catch(WA){t[ls]=hs}if(t[ps]||ss(t,ps,e),as[e])for(var r in cs)if(t[r]!==cs[r])try{ss(t,r,cs[r])}catch(WA){t[r]=cs[r]}}};for(var vs in as)ds(is[vs]&&is[vs].prototype,vs);ds(us,"DOMTokenList");var ys=T,gs=Array.isArray||function(t){return"Array"==ys(t)},ms=k,bs=h,ws=lt,As=cu,_s=Hn,Ts=function(){},xs=[],Os=vt("Reflect","construct"),ks=/^\s*(?:class|function)\b/,Ss=ms(ks.exec),Es=!ks.exec(Ts),Is=function(t){if(!ws(t))return!1;try{return Os(Ts,xs,t),!0}catch(WA){return!1}},Cs=function(t){if(!ws(t))return!1;switch(As(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return Es||!!Ss(ks,_s(t))}catch(WA){return!0}};Cs.sham=!0;var js=!Os||bs((function(){var t;return Is(Is.call)||!Is(Object)||!Is((function(){t=!0}))||t}))?Cs:Is,Ps=h,Ms=Tt,Ls=Ft("species"),Rs=function(t){return Ms>=51||!Ps((function(){var e=[];return(e.constructor={})[Ls]=function(){return{foo:1}},1!==e[t](Boolean).foo}))},Ds=k([].slice),Ns=Yo,Fs=gs,Us=js,Bs=Vt,Vs=Ze,Gs=or,Ws=F,Ys=la,zs=Ft,Hs=Ds,Ks=Rs("slice"),qs=zs("species"),Xs=Array,$s=Math.max;Ns({target:"Array",proto:!0,forced:!Ks},{slice:function(t,e){var r,n,o,i=Ws(this),a=Gs(i),u=Vs(t,a),c=Vs(void 0===e?a:e,a);if(Fs(i)&&(r=i.constructor,(Us(r)&&(r===Xs||Fs(r.prototype))||Bs(r)&&null===(r=r[qs]))&&(r=void 0),r===Xs||void 0===r))return Hs(i,u,c);for(n=new(void 0===r?Xs:r)($s(c-u,0)),o=0;u<c;u++,o++)u in i&&Ys(n,o,i[u]);return n.length=o,n}});var Js=Yo,Qs=Date,Zs=k(Qs.prototype.getTime);Js({target:"Date",stat:!0},{now:function(){return Zs(new Qs)}});var tf=k,ef=so,rf=Date.prototype,nf="Invalid Date",of="toString",af=tf(rf.toString),uf=tf(rf.getTime);String(new Date(NaN))!=nf&&ef(rf,of,(function(){var t=uf(this);return t==t?af(this):nf}));var cf=TypeError,sf=gs,ff=js,lf=Vt,pf=Ft("species"),hf=Array,df=function(t){var e;return sf(t)&&(e=t.constructor,(ff(e)&&(e===hf||sf(e.prototype))||lf(e)&&null===(e=e[pf]))&&(e=void 0)),void 0===e?hf:e},vf=function(t,e){return new(df(t))(0===e?0:e)},yf=Yo,gf=h,mf=gs,bf=Vt,wf=Z,Af=or,_f=function(t){if(t>9007199254740991)throw cf("Maximum allowed index exceeded");return t},Tf=la,xf=vf,Of=Rs,kf=Tt,Sf=Ft("isConcatSpreadable"),Ef=kf>=51||!gf((function(){var t=[];return t[Sf]=!1,t.concat()[0]!==t})),If=Of("concat"),Cf=function(t){if(!bf(t))return!1;var e=t[Sf];return void 0!==e?!!e:mf(t)};yf({target:"Array",proto:!0,arity:1,forced:!Ef||!If},{concat:function(t){var e,r,n,o,i,a=wf(this),u=xf(a,0),c=0;for(e=-1,n=arguments.length;e<n;e++)if(Cf(i=-1===e?a:arguments[e]))for(o=Af(i),_f(c+o),r=0;r<o;r++,c++)r in i&&Tf(u,c,i[r]);else _f(c+1),Tf(u,c++,i);return u.length=c,u}});var jf=k(1..valueOf),Pf=R,Mf=Uc,Lf=k("".replace),Rf="[\t\n\v\f\r    \u2028\u2029\ufeff]",Df=RegExp("^"+Rf+Rf+"*"),Nf=RegExp(Rf+Rf+"*$"),Ff=function(t){return function(e){var r=Mf(Pf(e));return 1&t&&(r=Lf(r,Df,"")),2&t&&(r=Lf(r,Nf,"")),r}},Uf={start:Ff(1),end:Ff(2),trim:Ff(3)},Bf=Kt,Vf=B,Gf=k,Wf=Do,Yf=so,zf=rt,Hf=$u,Kf=ie,qf=fe,Xf=je,$f=h,Jf=fo.f,Qf=_n.f,Zf=Xt.f,tl=jf,el=Uf.trim,rl="Number",nl=Vf.Number,ol=nl.prototype,il=Vf.TypeError,al=Gf("".slice),ul=Gf("".charCodeAt),cl=function(t){var e=Xf(t,"number");return"bigint"==typeof e?e:sl(e)},sl=function(t){var e,r,n,o,i,a,u,c,s=Xf(t,"number");if(qf(s))throw il("Cannot convert a Symbol value to a number");if("string"==typeof s&&s.length>2)if(s=el(s),43===(e=ul(s,0))||45===e){if(88===(r=ul(s,2))||120===r)return NaN}else if(48===e){switch(ul(s,1)){case 66:case 98:n=2,o=49;break;case 79:case 111:n=8,o=55;break;default:return+s}for(a=(i=al(s,2)).length,u=0;u<a;u++)if((c=ul(i,u))<48||c>o)return NaN;return parseInt(i,n)}return+s};if(Wf(rl,!nl(" 0o1")||!nl("0b1")||nl("+0x1"))){for(var fl,ll=function(t){var e=arguments.length<1?0:nl(cl(t)),r=this;return Kf(ol,r)&&$f((function(){tl(r)}))?Hf(Object(e),r,ll):e},pl=Bf?Jf(nl):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),hl=0;pl.length>hl;hl++)zf(nl,fl=pl[hl])&&!zf(ll,fl)&&Zf(ll,fl,Qf(nl,fl));ll.prototype=ol,ol.constructor=ll,Yf(Vf,rl,ll,{constructor:!0})}var dl,vl,yl,gl,ml="process"==T(B.process),bl=js,wl=pe,Al=TypeError,_l=function(t){if(bl(t))return t;throw Al(wl(t)+" is not a constructor")},Tl=zt,xl=_l,Ol=P,kl=Ft("species"),Sl=function(t,e){var r,n=Tl(t).constructor;return void 0===n||Ol(r=Tl(n)[kl])?e:xl(r)},El=d,Il=Function.prototype,Cl=Il.apply,jl=Il.call,Pl="object"==typeof Reflect&&Reflect.apply||(El?jl.bind(Cl):function(){return jl.apply(Cl,arguments)}),Ml=TypeError,Ll=/(?:ipad|iphone|ipod).*applewebkit/i.test(yt),Rl=B,Dl=Pl,Nl=Xa,Fl=lt,Ul=rt,Bl=h,Vl=Er,Gl=Ds,Wl=Zt,Yl=function(t,e){if(t<e)throw Ml("Not enough arguments");return t},zl=Ll,Hl=ml,Kl=Rl.setImmediate,ql=Rl.clearImmediate,Xl=Rl.process,$l=Rl.Dispatch,Jl=Rl.Function,Ql=Rl.MessageChannel,Zl=Rl.String,tp=0,ep={},rp="onreadystatechange";try{dl=Rl.location}catch(WA){}var np=function(t){if(Ul(ep,t)){var e=ep[t];delete ep[t],e()}},op=function(t){return function(){np(t)}},ip=function(t){np(t.data)},ap=function(t){Rl.postMessage(Zl(t),dl.protocol+"//"+dl.host)};Kl&&ql||(Kl=function(t){Yl(arguments.length,1);var e=Fl(t)?t:Jl(t),r=Gl(arguments,1);return ep[++tp]=function(){Dl(e,void 0,r)},vl(tp),tp},ql=function(t){delete ep[t]},Hl?vl=function(t){Xl.nextTick(op(t))}:$l&&$l.now?vl=function(t){$l.now(op(t))}:Ql&&!zl?(gl=(yl=new Ql).port2,yl.port1.onmessage=ip,vl=Nl(gl.postMessage,gl)):Rl.addEventListener&&Fl(Rl.postMessage)&&!Rl.importScripts&&dl&&"file:"!==dl.protocol&&!Bl(ap)?(vl=ap,Rl.addEventListener("message",ip,!1)):vl=rp in Wl("script")?function(t){Vl.appendChild(Wl("script")).onreadystatechange=function(){Vl.removeChild(this),np(t)}}:function(t){setTimeout(op(t),0)});var up,cp,sp,fp,lp,pp,hp,dp,vp={set:Kl,clear:ql},yp=B,gp=/ipad|iphone|ipod/i.test(yt)&&void 0!==yp.Pebble,mp=/web0s(?!.*chrome)/i.test(yt),bp=B,wp=Xa,Ap=_n.f,_p=vp.set,Tp=Ll,xp=gp,Op=mp,kp=ml,Sp=bp.MutationObserver||bp.WebKitMutationObserver,Ep=bp.document,Ip=bp.process,Cp=bp.Promise,jp=Ap(bp,"queueMicrotask"),Pp=jp&&jp.value;Pp||(up=function(){var t,e;for(kp&&(t=Ip.domain)&&t.exit();cp;){e=cp.fn,cp=cp.next;try{e()}catch(WA){throw cp?fp():sp=void 0,WA}}sp=void 0,t&&t.enter()},Tp||kp||Op||!Sp||!Ep?!xp&&Cp&&Cp.resolve?((hp=Cp.resolve(void 0)).constructor=Cp,dp=wp(hp.then,hp),fp=function(){dp(up)}):kp?fp=function(){Ip.nextTick(up)}:(_p=wp(_p,bp),fp=function(){_p(up)}):(lp=!0,pp=Ep.createTextNode(""),new Sp(up).observe(pp,{characterData:!0}),fp=function(){pp.data=lp=!lp}));var Mp=Pp||function(t){var e={fn:t,next:void 0};sp&&(sp.next=e),cp||(cp=e,fp()),sp=e},Lp=B,Rp=function(t){try{return{error:!1,value:t()}}catch(WA){return{error:!0,value:WA}}},Dp=function(){this.head=null,this.tail=null};Dp.prototype={add:function(t){var e={item:t,next:null};this.head?this.tail.next=e:this.head=e,this.tail=e},get:function(){var t=this.head;if(t)return this.head=t.next,this.tail===t&&(this.tail=null),t.item}};var Np=Dp,Fp=B.Promise,Up="object"==typeof Deno&&Deno&&"object"==typeof Deno.version,Bp=!Up&&!ml&&"object"==typeof window&&"object"==typeof document,Vp=B,Gp=Fp,Wp=lt,Yp=Do,zp=Hn,Hp=Ft,Kp=Bp,qp=Up,Xp=Tt;Gp&&Gp.prototype;var $p=Hp("species"),Jp=!1,Qp=Wp(Vp.PromiseRejectionEvent),Zp=Yp("Promise",(function(){var t=zp(Gp),e=t!==String(Gp);if(!e&&66===Xp)return!0;if(!Xp||Xp<51||!/native code/.test(t)){var r=new Gp((function(t){t(1)})),n=function(t){t((function(){}),(function(){}))};if((r.constructor={})[$p]=n,!(Jp=r.then((function(){}))instanceof n))return!0}return!e&&(Kp||qp)&&!Qp})),th={CONSTRUCTOR:Zp,REJECTION_EVENT:Qp,SUBCLASSING:Jp},eh={},rh=ye,nh=TypeError,oh=function(t){var e,r;this.promise=new t((function(t,n){if(void 0!==e||void 0!==r)throw nh("Bad Promise constructor");e=t,r=n})),this.resolve=rh(e),this.reject=rh(r)};eh.f=function(t){return new oh(t)};var ih,ah,uh,ch=Yo,sh=ml,fh=B,lh=oe,ph=so,hh=Oi,dh=pi,vh=mc,yh=ye,gh=lt,mh=Vt,bh=Vu,wh=Sl,Ah=vp.set,_h=Mp,Th=function(t,e){var r=Lp.console;r&&r.error&&(1==arguments.length?r.error(t):r.error(t,e))},xh=Rp,Oh=Np,kh=An,Sh=Fp,Eh=eh,Ih="Promise",Ch=th.CONSTRUCTOR,jh=th.REJECTION_EVENT,Ph=th.SUBCLASSING,Mh=kh.getterFor(Ih),Lh=kh.set,Rh=Sh&&Sh.prototype,Dh=Sh,Nh=Rh,Fh=fh.TypeError,Uh=fh.document,Bh=fh.process,Vh=Eh.f,Gh=Vh,Wh=!!(Uh&&Uh.createEvent&&fh.dispatchEvent),Yh="unhandledrejection",zh=function(t){var e;return!(!mh(t)||!gh(e=t.then))&&e},Hh=function(t,e){var r,n,o,i=e.value,a=1==e.state,u=a?t.ok:t.fail,c=t.resolve,s=t.reject,f=t.domain;try{u?(a||(2===e.rejection&&Jh(e),e.rejection=1),!0===u?r=i:(f&&f.enter(),r=u(i),f&&(f.exit(),o=!0)),r===t.promise?s(Fh("Promise-chain cycle")):(n=zh(r))?lh(n,r,c,s):c(r)):s(i)}catch(WA){f&&!o&&f.exit(),s(WA)}},Kh=function(t,e){t.notified||(t.notified=!0,_h((function(){for(var r,n=t.reactions;r=n.get();)Hh(r,t);t.notified=!1,e&&!t.rejection&&Xh(t)})))},qh=function(t,e,r){var n,o;Wh?((n=Uh.createEvent("Event")).promise=e,n.reason=r,n.initEvent(t,!1,!0),fh.dispatchEvent(n)):n={promise:e,reason:r},!jh&&(o=fh["on"+t])?o(n):t===Yh&&Th("Unhandled promise rejection",r)},Xh=function(t){lh(Ah,fh,(function(){var e,r=t.facade,n=t.value;if($h(t)&&(e=xh((function(){sh?Bh.emit("unhandledRejection",n,r):qh(Yh,r,n)})),t.rejection=sh||$h(t)?2:1,e.error))throw e.value}))},$h=function(t){return 1!==t.rejection&&!t.parent},Jh=function(t){lh(Ah,fh,(function(){var e=t.facade;sh?Bh.emit("rejectionHandled",e):qh("rejectionhandled",e,t.value)}))},Qh=function(t,e,r){return function(n){t(e,n,r)}},Zh=function(t,e,r){t.done||(t.done=!0,r&&(t=r),t.value=e,t.state=2,Kh(t,!0))},td=function(t,e,r){if(!t.done){t.done=!0,r&&(t=r);try{if(t.facade===e)throw Fh("Promise can't be resolved itself");var n=zh(e);n?_h((function(){var r={done:!1};try{lh(n,e,Qh(td,r,t),Qh(Zh,r,t))}catch(WA){Zh(r,WA,t)}})):(t.value=e,t.state=1,Kh(t,!1))}catch(WA){Zh({done:!1},WA,t)}}};if(Ch&&(Nh=(Dh=function(t){bh(this,Nh),yh(t),lh(ih,this);var e=Mh(this);try{t(Qh(td,e),Qh(Zh,e))}catch(WA){Zh(e,WA)}}).prototype,(ih=function(t){Lh(this,{type:Ih,done:!1,notified:!1,parent:!1,reactions:new Oh,rejection:!1,state:0,value:void 0})}).prototype=ph(Nh,"then",(function(t,e){var r=Mh(this),n=Vh(wh(this,Dh));return r.parent=!0,n.ok=!gh(t)||t,n.fail=gh(e)&&e,n.domain=sh?Bh.domain:void 0,0==r.state?r.reactions.add(n):_h((function(){Hh(n,r)})),n.promise})),ah=function(){var t=new ih,e=Mh(t);this.promise=t,this.resolve=Qh(td,e),this.reject=Qh(Zh,e)},Eh.f=Vh=function(t){return t===Dh||undefined===t?new ah(t):Gh(t)},gh(Sh)&&Rh!==Object.prototype)){uh=Rh.then,Ph||ph(Rh,"then",(function(t,e){var r=this;return new Dh((function(t,e){lh(uh,r,t,e)})).then(t,e)}),{unsafe:!0});try{delete Rh.constructor}catch(WA){}hh&&hh(Rh,Nh)}ch({global:!0,constructor:!0,wrap:!0,forced:Ch},{Promise:Dh}),dh(Dh,Ih,!1),vh(Ih);var ed=Fp,rd=th.CONSTRUCTOR||!Hu((function(t){ed.all(t).then(void 0,(function(){}))})),nd=oe,od=ye,id=eh,ad=Rp,ud=Fu;Yo({target:"Promise",stat:!0,forced:rd},{all:function(t){var e=this,r=id.f(e),n=r.resolve,o=r.reject,i=ad((function(){var r=od(e.resolve),i=[],a=0,u=1;ud(t,(function(t){var c=a++,s=!1;u++,nd(r,e,t).then((function(t){s||(s=!0,i[c]=t,--u||n(i))}),o)})),--u||n(i)}));return i.error&&o(i.value),r.promise}});var cd=Yo,sd=th.CONSTRUCTOR,fd=Fp,ld=vt,pd=lt,hd=so,dd=fd&&fd.prototype;if(cd({target:"Promise",proto:!0,forced:sd,real:!0},{catch:function(t){return this.then(void 0,t)}}),pd(fd)){var vd=ld("Promise").prototype.catch;dd.catch!==vd&&hd(dd,"catch",vd,{unsafe:!0})}var yd=oe,gd=ye,md=eh,bd=Rp,wd=Fu;Yo({target:"Promise",stat:!0,forced:rd},{race:function(t){var e=this,r=md.f(e),n=r.reject,o=bd((function(){var o=gd(e.resolve);wd(t,(function(t){yd(o,e,t).then(r.resolve,n)}))}));return o.error&&n(o.value),r.promise}});var Ad=oe,_d=eh;Yo({target:"Promise",stat:!0,forced:th.CONSTRUCTOR},{reject:function(t){var e=_d.f(this);return Ad(e.reject,void 0,t),e.promise}});var Td=zt,xd=Vt,Od=eh,kd=Yo,Sd=th.CONSTRUCTOR,Ed=function(t,e){if(Td(t),xd(e)&&e.constructor===t)return e;var r=Od.f(t);return(0,r.resolve)(e),r.promise};vt("Promise"),kd({target:"Promise",stat:!0,forced:Sd},{resolve:function(t){return Ed(this,t)}}),window.AudioContext=window.AudioContext||window.webkitAudioContext||window.mozAudioContext;var Id,Cd=function(){if(Id)return Id;Id=new window.AudioContext({sampleRate:48e3});var t=function t(){"suspended"===Id.state?(Id.resume(),document.removeEventListener("click",t)):"interrupted"===Id.state?Id.resume():document.removeEventListener("click",t)};return document.addEventListener("click",t),Id.onstatechange=function(){t()},Id},jd="input",Pd="output",Md="schedule.cloud-rtc.com",Ld="schedule.rtc.tencentcloud.com";function Rd(t){return Dd(t)?Ld:Md}var Dd=function(t){return(t=Number(t))>0&&t<14e8};function Nd(t){return Fd.apply(this,arguments)}function Fd(){return(Fd=u(i().mark((function t(e){var r,n,o,a,u,c,s,f,l,p,h,d,v,y,g;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.sdkAppId,n=e.userId,o=e.userSig,a=e.timestamp,u=Rd(r),c="https://".concat(u,"/api/v1/audioAiAuth?sdkAppId=").concat(r,"&userId=").concat(n,"&userSig=").concat(o,"&timestamp=").concat(a),t.next=5,fetch(c);case 5:return s=t.sent,t.next=8,s.json();case 8:if(f=t.sent,l=f.data,p=l.errCode,h=l.errMsg,d=l.sign,"1"!==(v=l.status)){t.next=16;break}return t.abrupt("return",{auth:!0,sign:d,status:v,message:h});case 16:y="Init RTCAIDenoiser failed.",g="",t.t0=p,t.next=1===t.t0?21:2===t.t0?23:3===t.t0?25:4===t.t0?27:5===t.t0?29:6===t.t0?31:33;break;case 21:return g="Please check your params.",t.abrupt("break",33);case 23:return g="You need to buy packages. Refer to: https://cloud.tencent.com/document/product/647/44247",t.abrupt("break",33);case 25:return g="Server is invalid. Please contact our engineer. ",t.abrupt("break",33);case 27:return g="Your packages is not active. Refer to: https://cloud.tencent.com/document/product/647/44247",t.abrupt("break",33);case 29:return g="Your packages is expired. Refer to: https://cloud.tencent.com/document/product/647/44247",t.abrupt("break",33);case 31:return g="Your version is not supported.",t.abrupt("break",33);case 33:return t.abrupt("return",{auth:!1,status:v,message:h?"".concat(y," Reason: ").concat(h,". ").concat(g):"".concat(y,", ").concat(g)});case 34:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var Ud={exports:{}};!function(t){var e=Object.prototype.hasOwnProperty,r="~";function n(){}function o(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function i(t,e,n,i,a){if("function"!=typeof n)throw new TypeError("The listener must be a function");var u=new o(n,i||t,a),c=r?r+e:e;return t._events[c]?t._events[c].fn?t._events[c]=[t._events[c],u]:t._events[c].push(u):(t._events[c]=u,t._eventsCount++),t}function a(t,e){0==--t._eventsCount?t._events=new n:delete t._events[e]}function u(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(r=!1)),u.prototype.eventNames=function(){var t,n,o=[];if(0===this._eventsCount)return o;for(n in t=this._events)e.call(t,n)&&o.push(r?n.slice(1):n);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(t)):o},u.prototype.listeners=function(t){var e=r?r+t:t,n=this._events[e];if(!n)return[];if(n.fn)return[n.fn];for(var o=0,i=n.length,a=new Array(i);o<i;o++)a[o]=n[o].fn;return a},u.prototype.listenerCount=function(t){var e=r?r+t:t,n=this._events[e];return n?n.fn?1:n.length:0},u.prototype.emit=function(t,e,n,o,i,a){var u=r?r+t:t;if(!this._events[u])return!1;var c,s,f=this._events[u],l=arguments.length;if(f.fn){switch(f.once&&this.removeListener(t,f.fn,void 0,!0),l){case 1:return f.fn.call(f.context),!0;case 2:return f.fn.call(f.context,e),!0;case 3:return f.fn.call(f.context,e,n),!0;case 4:return f.fn.call(f.context,e,n,o),!0;case 5:return f.fn.call(f.context,e,n,o,i),!0;case 6:return f.fn.call(f.context,e,n,o,i,a),!0}for(s=1,c=new Array(l-1);s<l;s++)c[s-1]=arguments[s];f.fn.apply(f.context,c)}else{var p,h=f.length;for(s=0;s<h;s++)switch(f[s].once&&this.removeListener(t,f[s].fn,void 0,!0),l){case 1:f[s].fn.call(f[s].context);break;case 2:f[s].fn.call(f[s].context,e);break;case 3:f[s].fn.call(f[s].context,e,n);break;case 4:f[s].fn.call(f[s].context,e,n,o);break;default:if(!c)for(p=1,c=new Array(l-1);p<l;p++)c[p-1]=arguments[p];f[s].fn.apply(f[s].context,c)}}return!0},u.prototype.on=function(t,e,r){return i(this,t,e,r,!1)},u.prototype.once=function(t,e,r){return i(this,t,e,r,!0)},u.prototype.removeListener=function(t,e,n,o){var i=r?r+t:t;if(!this._events[i])return this;if(!e)return a(this,i),this;var u=this._events[i];if(u.fn)u.fn!==e||o&&!u.once||n&&u.context!==n||a(this,i);else{for(var c=0,s=[],f=u.length;c<f;c++)(u[c].fn!==e||o&&!u[c].once||n&&u[c].context!==n)&&s.push(u[c]);s.length?this._events[i]=1===s.length?s[0]:s:a(this,i)}return this},u.prototype.removeAllListeners=function(t){var e;return t?(e=r?r+t:t,this._events[e]&&a(this,e)):(this._events=new n,this._eventsCount=0),this},u.prototype.off=u.prototype.removeListener,u.prototype.addListener=u.prototype.on,u.prefixed=r,u.EventEmitter=u,t.exports=u}(Ud);var Bd=Ud.exports,Vd="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView,Gd=Xe,Wd=rr,Yd=RangeError,zd=function(t){if(void 0===t)return 0;var e=Gd(t),r=Wd(e);if(e!==r)throw Yd("Wrong length or index");return r},Hd=Array,Kd=Math.abs,qd=Math.pow,Xd=Math.floor,$d=Math.log,Jd=Math.LN2,Qd=Z,Zd=Ze,tv=or,ev=function(t){for(var e=Qd(this),r=tv(e),n=arguments.length,o=Zd(n>1?arguments[1]:void 0,r),i=n>2?arguments[2]:void 0,a=void 0===i?r:Zd(i,r);a>o;)e[o++]=t;return e},rv=B,nv=k,ov=Kt,iv=Vd,av=Gn,uv=un,cv=hc,sv=h,fv=Vu,lv=Xe,pv=rr,hv=zd,dv={pack:function(t,e,r){var n,o,i,a=Hd(r),u=8*r-e-1,c=(1<<u)-1,s=c>>1,f=23===e?qd(2,-24)-qd(2,-77):0,l=t<0||0===t&&1/t<0?1:0,p=0;for((t=Kd(t))!=t||Infinity===t?(o=t!=t?1:0,n=c):(n=Xd($d(t)/Jd),t*(i=qd(2,-n))<1&&(n--,i*=2),(t+=n+s>=1?f/i:f*qd(2,1-s))*i>=2&&(n++,i/=2),n+s>=c?(o=0,n=c):n+s>=1?(o=(t*i-1)*qd(2,e),n+=s):(o=t*qd(2,s-1)*qd(2,e),n=0));e>=8;)a[p++]=255&o,o/=256,e-=8;for(n=n<<e|o,u+=e;u>0;)a[p++]=255&n,n/=256,u-=8;return a[--p]|=128*l,a},unpack:function(t,e){var r,n=t.length,o=8*n-e-1,i=(1<<o)-1,a=i>>1,u=o-7,c=n-1,s=t[c--],f=127&s;for(s>>=7;u>0;)f=256*f+t[c--],u-=8;for(r=f&(1<<-u)-1,f>>=-u,u+=e;u>0;)r=256*r+t[c--],u-=8;if(0===f)f=1-a;else{if(f===i)return r?NaN:s?-Infinity:Infinity;r+=qd(2,e),f-=a}return(s?-1:1)*r*qd(2,f-e)}},vv=Zo,yv=Oi,gv=fo.f,mv=Xt.f,bv=ev,wv=ga,Av=pi,_v=av.PROPER,Tv=av.CONFIGURABLE,xv=An.get,Ov=An.set,kv="ArrayBuffer",Sv="DataView",Ev="Wrong index",Iv=rv.ArrayBuffer,Cv=Iv,jv=Cv&&Cv.prototype,Pv=rv.DataView,Mv=Pv&&Pv.prototype,Lv=Object.prototype,Rv=rv.Array,Dv=rv.RangeError,Nv=nv(bv),Fv=nv([].reverse),Uv=dv.pack,Bv=dv.unpack,Vv=function(t){return[255&t]},Gv=function(t){return[255&t,t>>8&255]},Wv=function(t){return[255&t,t>>8&255,t>>16&255,t>>24&255]},Yv=function(t){return t[3]<<24|t[2]<<16|t[1]<<8|t[0]},zv=function(t){return Uv(t,23,4)},Hv=function(t){return Uv(t,52,8)},Kv=function(t,e){mv(t.prototype,e,{get:function(){return xv(this)[e]}})},qv=function(t,e,r,n){var o=hv(r),i=xv(t);if(o+e>i.byteLength)throw Dv(Ev);var a=xv(i.buffer).bytes,u=o+i.byteOffset,c=wv(a,u,u+e);return n?c:Fv(c)},Xv=function(t,e,r,n,o,i){var a=hv(r),u=xv(t);if(a+e>u.byteLength)throw Dv(Ev);for(var c=xv(u.buffer).bytes,s=a+u.byteOffset,f=n(+o),l=0;l<e;l++)c[s+l]=f[i?l:e-l-1]};if(iv){var $v=_v&&Iv.name!==kv;if(sv((function(){Iv(1)}))&&sv((function(){new Iv(-1)}))&&!sv((function(){return new Iv,new Iv(1.5),new Iv(NaN),1!=Iv.length||$v&&!Tv})))$v&&Tv&&uv(Iv,"name",kv);else{(Cv=function(t){return fv(this,jv),new Iv(hv(t))}).prototype=jv;for(var Jv,Qv=gv(Iv),Zv=0;Qv.length>Zv;)(Jv=Qv[Zv++])in Cv||uv(Cv,Jv,Iv[Jv]);jv.constructor=Cv}yv&&vv(Mv)!==Lv&&yv(Mv,Lv);var ty=new Pv(new Cv(2)),ey=nv(Mv.setInt8);ty.setInt8(0,2147483648),ty.setInt8(1,2147483649),!ty.getInt8(0)&&ty.getInt8(1)||cv(Mv,{setInt8:function(t,e){ey(this,t,e<<24>>24)},setUint8:function(t,e){ey(this,t,e<<24>>24)}},{unsafe:!0})}else jv=(Cv=function(t){fv(this,jv);var e=hv(t);Ov(this,{bytes:Nv(Rv(e),0),byteLength:e}),ov||(this.byteLength=e)}).prototype,Mv=(Pv=function(t,e,r){fv(this,Mv),fv(t,jv);var n=xv(t).byteLength,o=lv(e);if(o<0||o>n)throw Dv("Wrong offset");if(o+(r=void 0===r?n-o:pv(r))>n)throw Dv("Wrong length");Ov(this,{buffer:t,byteLength:r,byteOffset:o}),ov||(this.buffer=t,this.byteLength=r,this.byteOffset=o)}).prototype,ov&&(Kv(Cv,"byteLength"),Kv(Pv,"buffer"),Kv(Pv,"byteLength"),Kv(Pv,"byteOffset")),cv(Mv,{getInt8:function(t){return qv(this,1,t)[0]<<24>>24},getUint8:function(t){return qv(this,1,t)[0]},getInt16:function(t){var e=qv(this,2,t,arguments.length>1?arguments[1]:void 0);return(e[1]<<8|e[0])<<16>>16},getUint16:function(t){var e=qv(this,2,t,arguments.length>1?arguments[1]:void 0);return e[1]<<8|e[0]},getInt32:function(t){return Yv(qv(this,4,t,arguments.length>1?arguments[1]:void 0))},getUint32:function(t){return Yv(qv(this,4,t,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(t){return Bv(qv(this,4,t,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(t){return Bv(qv(this,8,t,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(t,e){Xv(this,1,t,Vv,e)},setUint8:function(t,e){Xv(this,1,t,Vv,e)},setInt16:function(t,e){Xv(this,2,t,Gv,e,arguments.length>2?arguments[2]:void 0)},setUint16:function(t,e){Xv(this,2,t,Gv,e,arguments.length>2?arguments[2]:void 0)},setInt32:function(t,e){Xv(this,4,t,Wv,e,arguments.length>2?arguments[2]:void 0)},setUint32:function(t,e){Xv(this,4,t,Wv,e,arguments.length>2?arguments[2]:void 0)},setFloat32:function(t,e){Xv(this,4,t,zv,e,arguments.length>2?arguments[2]:void 0)},setFloat64:function(t,e){Xv(this,8,t,Hv,e,arguments.length>2?arguments[2]:void 0)}});Av(Cv,kv),Av(Pv,Sv);var ry={ArrayBuffer:Cv,DataView:Pv},ny=Yo,oy=k,iy=h,ay=zt,uy=Ze,cy=rr,sy=Sl,fy=ry.ArrayBuffer,ly=ry.DataView,py=ly.prototype,hy=oy(fy.prototype.slice),dy=oy(py.getUint8),vy=oy(py.setUint8);ny({target:"ArrayBuffer",proto:!0,unsafe:!0,forced:iy((function(){return!new fy(2).slice(1,void 0).byteLength}))},{slice:function(t,e){if(hy&&void 0===e)return hy(ay(this),t);for(var r=ay(this).byteLength,n=uy(t,r),o=uy(void 0===e?r:e,r),i=new(sy(this,fy))(cy(o-n)),a=new ly(this),u=new ly(i),c=0;n<o;)vy(u,c++,dy(a,n++));return i}});var yy,gy,my,by={exports:{}},wy=Vd,Ay=Kt,_y=B,Ty=lt,xy=Vt,Oy=rt,ky=cu,Sy=pe,Ey=un,Iy=so,Cy=Xt.f,jy=ie,Py=Zo,My=Oi,Ly=Ft,Ry=ut,Dy=An.enforce,Ny=An.get,Fy=_y.Int8Array,Uy=Fy&&Fy.prototype,By=_y.Uint8ClampedArray,Vy=By&&By.prototype,Gy=Fy&&Py(Fy),Wy=Uy&&Py(Uy),Yy=Object.prototype,zy=_y.TypeError,Hy=Ly("toStringTag"),Ky=Ry("TYPED_ARRAY_TAG"),qy="TypedArrayConstructor",Xy=wy&&!!My&&"Opera"!==ky(_y.opera),$y=!1,Jy={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},Qy={BigInt64Array:8,BigUint64Array:8},Zy=function(t){var e=Py(t);if(xy(e)){var r=Ny(e);return r&&Oy(r,qy)?r.TypedArrayConstructor:Zy(e)}},tg=function(t){if(!xy(t))return!1;var e=ky(t);return Oy(Jy,e)||Oy(Qy,e)};for(yy in Jy)(my=(gy=_y[yy])&&gy.prototype)?Dy(my).TypedArrayConstructor=gy:Xy=!1;for(yy in Qy)(my=(gy=_y[yy])&&gy.prototype)&&(Dy(my).TypedArrayConstructor=gy);if((!Xy||!Ty(Gy)||Gy===Function.prototype)&&(Gy=function(){throw zy("Incorrect invocation")},Xy))for(yy in Jy)_y[yy]&&My(_y[yy],Gy);if((!Xy||!Wy||Wy===Yy)&&(Wy=Gy.prototype,Xy))for(yy in Jy)_y[yy]&&My(_y[yy].prototype,Wy);if(Xy&&Py(Vy)!==Wy&&My(Vy,Wy),Ay&&!Oy(Wy,Hy))for(yy in $y=!0,Cy(Wy,Hy,{get:function(){return xy(this)?this[Ky]:void 0}}),Jy)_y[yy]&&Ey(_y[yy],Ky,yy);var eg={NATIVE_ARRAY_BUFFER_VIEWS:Xy,TYPED_ARRAY_TAG:$y&&Ky,aTypedArray:function(t){if(tg(t))return t;throw zy("Target is not a typed array")},aTypedArrayConstructor:function(t){if(Ty(t)&&(!My||jy(Gy,t)))return t;throw zy(Sy(t)+" is not a typed array constructor")},exportTypedArrayMethod:function(t,e,r,n){if(Ay){if(r)for(var o in Jy){var i=_y[o];if(i&&Oy(i.prototype,t))try{delete i.prototype[t]}catch(WA){try{i.prototype[t]=e}catch(a){}}}Wy[t]&&!r||Iy(Wy,t,r?e:Xy&&Uy[t]||e,n)}},exportTypedArrayStaticMethod:function(t,e,r){var n,o;if(Ay){if(My){if(r)for(n in Jy)if((o=_y[n])&&Oy(o,t))try{delete o[t]}catch(WA){}if(Gy[t]&&!r)return;try{return Iy(Gy,t,r?e:Xy&&Gy[t]||e)}catch(WA){}}for(n in Jy)!(o=_y[n])||o[t]&&!r||Iy(o,t,e)}},getTypedArrayConstructor:Zy,isView:function(t){if(!xy(t))return!1;var e=ky(t);return"DataView"===e||Oy(Jy,e)||Oy(Qy,e)},isTypedArray:tg,TypedArray:Gy,TypedArrayPrototype:Wy},rg=B,ng=h,og=Hu,ig=eg.NATIVE_ARRAY_BUFFER_VIEWS,ag=rg.ArrayBuffer,ug=rg.Int8Array,cg=!ig||!ng((function(){ug(1)}))||!ng((function(){new ug(-1)}))||!og((function(t){new ug,new ug(null),new ug(1.5),new ug(t)}),!0)||ng((function(){return 1!==new ug(new ag(2),1,void 0).length})),sg=Vt,fg=Math.floor,lg=Number.isInteger||function(t){return!sg(t)&&isFinite(t)&&fg(t)===t},pg=Xe,hg=RangeError,dg=function(t){var e=pg(t);if(e<0)throw hg("The argument can't be less than 0");return e},vg=RangeError,yg=function(t,e){var r=dg(t);if(r%e)throw vg("Wrong offset");return r},gg=cu,mg=k("".slice),bg=je,wg=TypeError,Ag=function(t){var e=bg(t,"number");if("number"==typeof e)throw wg("Can't convert number to bigint");return BigInt(e)},_g=Xa,Tg=oe,xg=_l,Og=Z,kg=or,Sg=Au,Eg=du,Ig=Za,Cg=function(t){return"Big"===mg(gg(t),0,3)},jg=eg.aTypedArrayConstructor,Pg=Ag,Mg=Xa,Lg=j,Rg=Z,Dg=or,Ng=vf,Fg=k([].push),Ug=function(t){var e=1==t,r=2==t,n=3==t,o=4==t,i=6==t,a=7==t,u=5==t||i;return function(c,s,f,l){for(var p,h,d=Rg(c),v=Lg(d),y=Mg(s,f),g=Dg(v),m=0,b=l||Ng,w=e?b(c,g):r||a?b(c,0):void 0;g>m;m++)if((u||m in v)&&(h=y(p=v[m],m,d),t))if(e)w[m]=h;else if(h)switch(t){case 3:return!0;case 5:return p;case 6:return m;case 2:Fg(w,p)}else switch(t){case 4:return!1;case 7:Fg(w,p)}return i?-1:n||o?o:w}},Bg={forEach:Ug(0),map:Ug(1),filter:Ug(2),some:Ug(3),every:Ug(4),find:Ug(5),findIndex:Ug(6),filterReject:Ug(7)},Vg=Yo,Gg=B,Wg=oe,Yg=Kt,zg=cg,Hg=eg,Kg=ry,qg=Vu,Xg=nn,$g=un,Jg=lg,Qg=rr,Zg=zd,tm=yg,em=Le,rm=rt,nm=cu,om=Vt,im=fe,am=Yr,um=ie,cm=Oi,sm=fo.f,fm=function(t){var e,r,n,o,i,a,u,c,s=xg(this),f=Og(t),l=arguments.length,p=l>1?arguments[1]:void 0,h=void 0!==p,d=Eg(f);if(d&&!Ig(d))for(c=(u=Sg(f,d)).next,f=[];!(a=Tg(c,u)).done;)f.push(a.value);for(h&&l>2&&(p=_g(p,arguments[2])),r=kg(f),n=new(jg(s))(r),o=Cg(n),e=0;r>e;e++)i=h?p(f[e],e):f[e],n[e]=o?Pg(i):+i;return n},lm=Bg.forEach,pm=mc,hm=Xt,dm=_n,vm=$u,ym=An.get,gm=An.set,mm=An.enforce,bm=hm.f,wm=dm.f,Am=Math.round,_m=Gg.RangeError,Tm=Kg.ArrayBuffer,xm=Tm.prototype,Om=Kg.DataView,km=Hg.NATIVE_ARRAY_BUFFER_VIEWS,Sm=Hg.TYPED_ARRAY_TAG,Em=Hg.TypedArray,Im=Hg.TypedArrayPrototype,Cm=Hg.aTypedArrayConstructor,jm=Hg.isTypedArray,Pm="BYTES_PER_ELEMENT",Mm="Wrong length",Lm=function(t,e){Cm(t);for(var r=0,n=e.length,o=new t(n);n>r;)o[r]=e[r++];return o},Rm=function(t,e){bm(t,e,{get:function(){return ym(this)[e]}})},Dm=function(t){var e;return um(xm,t)||"ArrayBuffer"==(e=nm(t))||"SharedArrayBuffer"==e},Nm=function(t,e){return jm(t)&&!im(e)&&e in t&&Jg(+e)&&e>=0},Fm=function(t,e){return e=em(e),Nm(t,e)?Xg(2,t[e]):wm(t,e)},Um=function(t,e,r){return e=em(e),!(Nm(t,e)&&om(r)&&rm(r,"value"))||rm(r,"get")||rm(r,"set")||r.configurable||rm(r,"writable")&&!r.writable||rm(r,"enumerable")&&!r.enumerable?bm(t,e,r):(t[e]=r.value,t)};Yg?(km||(dm.f=Fm,hm.f=Um,Rm(Im,"buffer"),Rm(Im,"byteOffset"),Rm(Im,"byteLength"),Rm(Im,"length")),Vg({target:"Object",stat:!0,forced:!km},{getOwnPropertyDescriptor:Fm,defineProperty:Um}),by.exports=function(t,e,r){var n=t.match(/\d+$/)[0]/8,o=t+(r?"Clamped":"")+"Array",i="get"+t,a="set"+t,u=Gg[o],c=u,s=c&&c.prototype,f={},l=function(t,e){bm(t,e,{get:function(){return function(t,e){var r=ym(t);return r.view[i](e*n+r.byteOffset,!0)}(this,e)},set:function(t){return function(t,e,o){var i=ym(t);r&&(o=(o=Am(o))<0?0:o>255?255:255&o),i.view[a](e*n+i.byteOffset,o,!0)}(this,e,t)},enumerable:!0})};km?zg&&(c=e((function(t,e,r,o){return qg(t,s),vm(om(e)?Dm(e)?void 0!==o?new u(e,tm(r,n),o):void 0!==r?new u(e,tm(r,n)):new u(e):jm(e)?Lm(c,e):Wg(fm,c,e):new u(Zg(e)),t,c)})),cm&&cm(c,Em),lm(sm(u),(function(t){t in c||$g(c,t,u[t])})),c.prototype=s):(c=e((function(t,e,r,o){qg(t,s);var i,a,u,f=0,p=0;if(om(e)){if(!Dm(e))return jm(e)?Lm(c,e):Wg(fm,c,e);i=e,p=tm(r,n);var h=e.byteLength;if(void 0===o){if(h%n)throw _m(Mm);if((a=h-p)<0)throw _m(Mm)}else if((a=Qg(o)*n)+p>h)throw _m(Mm);u=a/n}else u=Zg(e),i=new Tm(a=u*n);for(gm(t,{buffer:i,byteOffset:p,byteLength:a,length:u,view:new Om(i)});f<u;)l(t,f++)})),cm&&cm(c,Em),s=c.prototype=am(Im)),s.constructor!==c&&$g(s,"constructor",c),mm(s).TypedArrayConstructor=c,Sm&&$g(s,Sm,o);var p=c!=u;f[o]=c,Vg({global:!0,constructor:!0,forced:p,sham:!km},f),Pm in c||$g(c,Pm,n),Pm in s||$g(s,Pm,n),pm(o)}):by.exports=function(){},(0,by.exports)("Float32",(function(t){return function(e,r,n){return t(this,e,r,n)}}));var Bm=pe,Vm=TypeError,Gm=Z,Wm=Ze,Ym=or,zm=function(t,e){if(!delete t[e])throw Vm("Cannot delete property "+Bm(e)+" of "+Bm(t))},Hm=Math.min,Km=[].copyWithin||function(t,e){var r=Gm(this),n=Ym(r),o=Wm(t,n),i=Wm(e,n),a=arguments.length>2?arguments[2]:void 0,u=Hm((void 0===a?n:Wm(a,n))-i,n-o),c=1;for(i<o&&o<i+u&&(c=-1,i+=u-1,o+=u-1);u-- >0;)i in r?r[o]=r[i]:zm(r,o),o+=c,i+=c;return r},qm=eg,Xm=k(Km),$m=qm.aTypedArray;(0,qm.exportTypedArrayMethod)("copyWithin",(function(t,e){return Xm($m(this),t,e,arguments.length>2?arguments[2]:void 0)}));var Jm=Bg.every,Qm=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("every",(function(t){return Jm(Qm(this),t,arguments.length>1?arguments[1]:void 0)}));var Zm=ev,tb=Ag,eb=cu,rb=oe,nb=h,ob=eg.aTypedArray,ib=eg.exportTypedArrayMethod,ab=k("".slice);ib("fill",(function(t){var e=arguments.length;ob(this);var r="Big"===ab(eb(this),0,3)?tb(t):+t;return rb(Zm,this,r,e>1?arguments[1]:void 0,e>2?arguments[2]:void 0)}),nb((function(){var t=0;return new Int8Array(2).fill({valueOf:function(){return t++}}),1!==t})));var ub=or,cb=Sl,sb=eg.aTypedArrayConstructor,fb=eg.getTypedArrayConstructor,lb=function(t){return sb(cb(t,fb(t)))},pb=function(t,e){for(var r=0,n=ub(e),o=new t(n);n>r;)o[r]=e[r++];return o},hb=lb,db=Bg.filter,vb=function(t,e){return pb(hb(t),e)},yb=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("filter",(function(t){var e=db(yb(this),t,arguments.length>1?arguments[1]:void 0);return vb(this,e)}));var gb=Bg.find,mb=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("find",(function(t){return gb(mb(this),t,arguments.length>1?arguments[1]:void 0)}));var bb=Bg.findIndex,wb=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("findIndex",(function(t){return bb(wb(this),t,arguments.length>1?arguments[1]:void 0)}));var Ab=Bg.forEach,_b=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("forEach",(function(t){Ab(_b(this),t,arguments.length>1?arguments[1]:void 0)}));var Tb=sr.includes,xb=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("includes",(function(t){return Tb(xb(this),t,arguments.length>1?arguments[1]:void 0)}));var Ob=sr.indexOf,kb=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("indexOf",(function(t){return Ob(kb(this),t,arguments.length>1?arguments[1]:void 0)}));var Sb=B,Eb=h,Ib=k,Cb=eg,jb=oa,Pb=Ft("iterator"),Mb=Sb.Uint8Array,Lb=Ib(jb.values),Rb=Ib(jb.keys),Db=Ib(jb.entries),Nb=Cb.aTypedArray,Fb=Cb.exportTypedArrayMethod,Ub=Mb&&Mb.prototype,Bb=!Eb((function(){Ub[Pb].call([1])})),Vb=!!Ub&&Ub.values&&Ub[Pb]===Ub.values&&"values"===Ub.values.name,Gb=function(){return Lb(Nb(this))};Fb("entries",(function(){return Db(Nb(this))}),Bb),Fb("keys",(function(){return Rb(Nb(this))}),Bb),Fb("values",Gb,Bb||!Vb,{name:"values"}),Fb(Pb,Gb,Bb||!Vb,{name:"values"});var Wb=eg.aTypedArray,Yb=eg.exportTypedArrayMethod,zb=k([].join);Yb("join",(function(t){return zb(Wb(this),t)}));var Hb=h,Kb=Pl,qb=F,Xb=Xe,$b=or,Jb=function(t,e){var r=[][t];return!!r&&Hb((function(){r.call(null,e||function(){return 1},1)}))},Qb=Math.min,Zb=[].lastIndexOf,tw=!!Zb&&1/[1].lastIndexOf(1,-0)<0,ew=Jb("lastIndexOf"),rw=tw||!ew?function(t){if(tw)return Kb(Zb,this,arguments)||0;var e=qb(this),r=$b(e),n=r-1;for(arguments.length>1&&(n=Qb(n,Xb(arguments[1]))),n<0&&(n=r+n);n>=0;n--)if(n in e&&e[n]===t)return n||0;return-1}:Zb,nw=Pl,ow=rw,iw=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("lastIndexOf",(function(t){var e=arguments.length;return nw(ow,iw(this),e>1?[t,arguments[1]]:[t])}));var aw=Bg.map,uw=lb,cw=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("map",(function(t){return aw(cw(this),t,arguments.length>1?arguments[1]:void 0,(function(t,e){return new(uw(t))(e)}))}));var sw=ye,fw=Z,lw=j,pw=or,hw=TypeError,dw=function(t){return function(e,r,n,o){sw(r);var i=fw(e),a=lw(i),u=pw(i),c=t?u-1:0,s=t?-1:1;if(n<2)for(;;){if(c in a){o=a[c],c+=s;break}if(c+=s,t?c<0:u<=c)throw hw("Reduce of empty array with no initial value")}for(;t?c>=0:u>c;c+=s)c in a&&(o=r(o,a[c],c,i));return o}},vw={left:dw(!1),right:dw(!0)},yw=vw.left,gw=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("reduce",(function(t){var e=arguments.length;return yw(gw(this),t,e,e>1?arguments[1]:void 0)}));var mw=vw.right,bw=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("reduceRight",(function(t){var e=arguments.length;return mw(bw(this),t,e,e>1?arguments[1]:void 0)}));var ww=eg.aTypedArray,Aw=eg.exportTypedArrayMethod,_w=Math.floor;Aw("reverse",(function(){for(var t,e=this,r=ww(e).length,n=_w(r/2),o=0;o<n;)t=e[o],e[o++]=e[--r],e[r]=t;return e}));var Tw=B,xw=oe,Ow=eg,kw=or,Sw=yg,Ew=Z,Iw=h,Cw=Tw.RangeError,jw=Tw.Int8Array,Pw=jw&&jw.prototype,Mw=Pw&&Pw.set,Lw=Ow.aTypedArray,Rw=Ow.exportTypedArrayMethod,Dw=!Iw((function(){var t=new Uint8ClampedArray(2);return xw(Mw,t,{length:1,0:3},1),3!==t[1]})),Nw=Dw&&Ow.NATIVE_ARRAY_BUFFER_VIEWS&&Iw((function(){var t=new jw(2);return t.set(1),t.set("2",1),0!==t[0]||2!==t[1]}));Rw("set",(function(t){Lw(this);var e=Sw(arguments.length>1?arguments[1]:void 0,1),r=Ew(t);if(Dw)return xw(Mw,this,r,e);var n=this.length,o=kw(r),i=0;if(o+e>n)throw Cw("Wrong length");for(;i<o;)this[e+i]=r[i++]}),!Dw||Nw);var Fw=lb,Uw=Ds,Bw=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("slice",(function(t,e){for(var r=Uw(Bw(this),t,e),n=Fw(this),o=0,i=r.length,a=new n(i);i>o;)a[o]=r[o++];return a}),h((function(){new Int8Array(1).slice()})));var Vw=Bg.some,Gw=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("some",(function(t){return Vw(Gw(this),t,arguments.length>1?arguments[1]:void 0)}));var Ww=ga,Yw=Math.floor,zw=function(t,e){var r=t.length,n=Yw(r/2);return r<8?Hw(t,e):Kw(t,zw(Ww(t,0,n),e),zw(Ww(t,n),e),e)},Hw=function(t,e){for(var r,n,o=t.length,i=1;i<o;){for(n=i,r=t[i];n&&e(t[n-1],r)>0;)t[n]=t[--n];n!==i++&&(t[n]=r)}return t},Kw=function(t,e,r,n){for(var o=e.length,i=r.length,a=0,u=0;a<o||u<i;)t[a+u]=a<o&&u<i?n(e[a],r[u])<=0?e[a++]:r[u++]:a<o?e[a++]:r[u++];return t},qw=zw,Xw=yt.match(/firefox\/(\d+)/i),$w=!!Xw&&+Xw[1],Jw=/MSIE|Trident/.test(yt),Qw=yt.match(/AppleWebKit\/(\d+)\./),Zw=!!Qw&&+Qw[1],tA=k,eA=h,rA=ye,nA=qw,oA=$w,iA=Jw,aA=Tt,uA=Zw,cA=eg.aTypedArray,sA=eg.exportTypedArrayMethod,fA=B.Uint16Array,lA=fA&&tA(fA.prototype.sort),pA=!(!lA||eA((function(){lA(new fA(2),null)}))&&eA((function(){lA(new fA(2),{})}))),hA=!!lA&&!eA((function(){if(aA)return aA<74;if(oA)return oA<67;if(iA)return!0;if(uA)return uA<602;var t,e,r=new fA(516),n=Array(516);for(t=0;t<516;t++)e=t%4,r[t]=515-t,n[t]=t-2*e+3;for(lA(r,(function(t,e){return(t/4|0)-(e/4|0)})),t=0;t<516;t++)if(r[t]!==n[t])return!0}));sA("sort",(function(t){return void 0!==t&&rA(t),hA?lA(this,t):nA(cA(this),function(t){return function(e,r){return void 0!==t?+t(e,r)||0:r!=r?-1:e!=e?1:0===e&&0===r?1/e>0&&1/r<0?1:-1:e>r}}(t))}),!hA||pA);var dA=rr,vA=Ze,yA=lb,gA=eg.aTypedArray;(0,eg.exportTypedArrayMethod)("subarray",(function(t,e){var r=gA(this),n=r.length,o=vA(t,n);return new(yA(r))(r.buffer,r.byteOffset+o*r.BYTES_PER_ELEMENT,dA((void 0===e?n:vA(e,n))-o))}));var mA=Pl,bA=eg,wA=h,AA=Ds,_A=B.Int8Array,TA=bA.aTypedArray,xA=bA.exportTypedArrayMethod,OA=[].toLocaleString,kA=!!_A&&wA((function(){OA.call(new _A(1))}));xA("toLocaleString",(function(){return mA(OA,kA?AA(TA(this)):TA(this),AA(arguments))}),wA((function(){return[1,2].toLocaleString()!=new _A([1,2]).toLocaleString()}))||!wA((function(){_A.prototype.toLocaleString.call([1,2])})));var SA=eg.exportTypedArrayMethod,EA=h,IA=k,CA=B.Uint8Array,jA=CA&&CA.prototype||{},PA=[].toString,MA=IA([].join);EA((function(){PA.call({})}))&&(PA=function(){return MA(this)});var LA=jA.toString!=PA;SA("toString",PA,LA),Yo({global:!0,constructor:!0,forced:!Vd},{DataView:ry.DataView});var RA=mc,DA="ArrayBuffer",NA=ry.ArrayBuffer;function FA(t,e){e=e||{};var r=t.numberOfChannels,n=t.sampleRate,o=e.float32?3:1,i=3===o?32:16;return function(t,e,r,n,o){var i=o/8,a=n*i,u=new ArrayBuffer(44+t.length*i),c=new DataView(u);UA(c,0,"RIFF"),c.setUint32(4,36+t.length*i,!0),UA(c,8,"WAVE"),UA(c,12,"fmt "),c.setUint32(16,16,!0),c.setUint16(20,e,!0),c.setUint16(22,n,!0),c.setUint32(24,r,!0),c.setUint32(28,r*a,!0),c.setUint16(32,a,!0),c.setUint16(34,o,!0),UA(c,36,"data"),c.setUint32(40,t.length*i,!0),1===e?function(t,e,r){for(var n=0;n<r.length;n++,e+=2){var o=Math.max(-1,Math.min(1,r[n]));t.setInt16(e,o<0?32768*o:32767*o,!0)}}(c,44,t):function(t,e,r){for(var n=0;n<r.length;n++,e+=4)t.setFloat32(e,r[n],!0)}(c,44,t);return u}(2===r?function(t,e){var r=t.length+e.length,n=new Float32Array(r),o=0,i=0;for(;o<r;)n[o++]=t[i],n[o++]=e[i],i++;return n}(t.getChannelData(0),t.getChannelData(1)):t.getChannelData(0),o,n,r,i)}function UA(t,e,r){for(var n=0;n<r.length;n++)t.setUint8(e+n,r.charCodeAt(n))}Yo({global:!0,constructor:!0,forced:B.ArrayBuffer!==NA},{ArrayBuffer:NA}),RA(DA);var BA=function(){function t(e){c(this,t),this.audioContext_=e,this.inputPCM_=new Float32Array,this.outputPCM_=new Float32Array}return f(t,[{key:"onDump",value:function(t,e){if(e===jd){var r=this.inputPCM_.length,n=new Float32Array(r+t[0].length);n.set(this.inputPCM_),n.set(t[0],r),this.inputPCM_=n}if(e===Pd){var o=this.outputPCM_.length,i=new Float32Array(o+t[0].length);i.set(this.outputPCM_),i.set(t[0],o),this.outputPCM_=i}}},{key:"getBlob",value:function(t){var e=t===jd?this.inputPCM_:this.outputPCM_,r=this.audioContext_.createBuffer(2,e.length,48e3);r.copyToChannel(e,0,0),r.copyToChannel(e,1,0);var n=FA(r);return r=null,new window.Blob([new DataView(n)],{type:"audio/wav"})}},{key:"reset",value:function(){this.inputPCM_=new Float32Array,this.outputPCM_=new Float32Array}},{key:"destroy",value:function(){this.inputPCM_=null,this.outputPCM_=null}}]),t}(),VA=function(){function t(e){var r=this,n=e.sdkAppId,o=e.userId,i=e.audioContext,a=e.sign,u=e.status,s=e.worklet,f=e.timestamp,l=e.logger;c(this,t),this.audioContext_=i,this.destination_=this.audioContext_.createMediaStreamDestination(),this.gainNode_=this.audioContext_.createGain(),this.gainNode_.gain.value=1.1,this.log_=l,this.workletNode_=s,this.workletNode_.connect(this.gainNode_).connect(this.destination_),this.workletNode_.port.postMessage({type:"init",data:{sdkAppId:String(n),userId:o,timestamp:f,sign:a,status:u}}),this.workletNode_.port.onmessage=function(t){var e=t.data,n=e.type,o=e.data;if("ondump"===n&&r.isDumping_){var i=o.inputPCM,a=o.outputPCM;r.dump_.onDump(i,jd),r.dump_.onDump(a,Pd)}"dumped"===n&&r.dumped()},this.trackConstraint_={},this.localStream_=null,this.audioTrack_=null,this.source_=null,this.denoiserTrack_=null,this.enableDenoise_=!0,this.emitter_=new Bd,this.dump_=new BA(this.audioContext_)}var e,n,o,a;return f(t,[{key:"dumped",value:function(){this.isDumping_=!1;var t=this.dump_.getBlob(jd),e=this.dump_.getBlob(Pd);this.emitter_.emit("ondumpend",{blob:t,name:jd}),this.emitter_.emit("ondumpend",{blob:e,name:Pd}),this.dump_.reset()}},{key:"process",value:(a=u(i().mark((function t(e){var r,n,o;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.localStream_=e,this.log_.info("RTCAIDenoiser: denoiser process stream ID: ".concat(e.getId(),".")),this.audioTrack_=null==e?void 0:e.getAudioTrack(),this.audioTrack_){t.next=5;break}throw new Error("RTCAIDenoiser: cannot process localStream without audioTrack.");case 5:return t.next=7,this.audioTrack_.getSettings();case 7:return r=t.sent,this.destination_.channelCount=(null==r?void 0:r.channelCount)||1,(n=new MediaStream).addTrack(this.audioTrack_),this.source_=this.audioContext_.createMediaStreamSource(n),t.next=14,this.source_.connect(this.workletNode_);case 14:return this.trackConstraint_=this.audioTrack_.getConstraints(),this.trackConstraint_.noiseSuppression=!1,t.next=18,this.audioTrack_.applyConstraints(this.trackConstraint_);case 18:return o=this.destination_.stream,this.denoiserTrack_=o.getAudioTracks()[0],t.next=22,this.localStream_.replaceTrack(this.denoiserTrack_);case 22:this.localStream_&&this.localStream_.setIsAIDenoiser&&this.localStream_.setIsAIDenoiser(!0);case 23:case"end":return t.stop()}}),t,this)}))),function(t){return a.apply(this,arguments)})},{key:"updateTrack",value:(o=u(i().mark((function t(e){var r,n;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=new MediaStream,t.next=3,r.addTrack(e);case 3:n=this.audioContext_.createMediaStreamSource(r),this.source_.disconnect(),n.connect(this.workletNode_),this.audioTrack_.stop(),this.audioTrack_=e,this.source_=n,this.log_.info("RTCAIDenoiser: ".concat(this.localStream_.getUserId()," updateTrack success."));case 10:case"end":return t.stop()}}),t,this)}))),function(t){return o.apply(this,arguments)})},{key:"disable",value:(n=u(i().mark((function t(){var e;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.enableDenoise_=!1,null===(e=this.workletNode_)||void 0===e||e.port.postMessage({type:"disable"}),this.trackConstraint_.noiseSuppression=!0,t.next=5,this.audioTrack_.applyConstraints(this.trackConstraint_);case 5:return this.log_.info("RTCAIDenoiser: disable ai denoiser."),t.abrupt("return",this.enableDenoise_);case 7:case"end":return t.stop()}}),t,this)}))),function(){return n.apply(this,arguments)})},{key:"enable",value:(e=u(i().mark((function t(){var e;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.enableDenoise_=!0,null===(e=this.workletNode_)||void 0===e||e.port.postMessage({type:"enable"}),this.trackConstraint_.noiseSuppression=!1,t.next=5,this.audioTrack_.applyConstraints(this.trackConstraint_);case 5:return this.log_.info("RTCAIDenoiser: enable ai denoiser."),t.abrupt("return",this.enableDenoise_);case 7:case"end":return t.stop()}}),t,this)}))),function(){return e.apply(this,arguments)})},{key:"startDump",value:function(){return this.isDumping_?(this.log_.info("RTCAIDenoiser: data is currently being dumped."),!1):(this.workletNode_.port.postMessage({type:"startDump"}),this.dump_?this.dump_.reset():this.dump_=new BA(this.audioContext_),this.isDumping_=!0,this.log_.info("RTCAIDenoiser: start dump data."),!0)}},{key:"stopDump",value:function(){this.isDumping_&&(this.workletNode_.port.postMessage({type:"stopDump"}),this.isDumping_=!1,this.log_.info("RTCAIDenoiser: stop dump data."))}},{key:"getAudioTrack",value:function(){return this.audioTrack_}},{key:"getDenoiserTrack",value:function(){return this.denoiserTrack_}},{key:"enabled",get:function(){return this.enableDenoise_}},{key:"destroy",value:function(){var t,e,r,n,o,i,a;this.log_.info("RTCAIDenoiser: ".concat(this.localStream_.getUserId()," destroy processor.")),null===(t=this.localStream_)||void 0===t||t.stop(),null===(e=this.audioTrack_)||void 0===e||e.stop(),null===(r=this.workletNode_)||void 0===r||r.port.postMessage({type:"destroy"}),this.workletNode_.port.onmessage=null,null===(n=this.source_)||void 0===n||n.disconnect(),null===(o=this.destination_)||void 0===o||o.disconnect(),null===(i=this.workletNode_)||void 0===i||i.disconnect(),null===(a=this.dump_)||void 0===a||a.destroy(),this.emitter_.removeAllListeners()}},{key:"on",value:function(t,e,r){this.emitter_.on(t,e,r)}},{key:"off",value:function(t,e,r){"*"===t?this.emitter_.removeAllListeners():this.emitter_.off(t,e,r)}},{key:"resetDenoiser",value:function(t){if(r.default){var e=r.default.DenoiserMap;null!=e&&e.has(t.getUserId())&&e.delete(t.getUserId())}}}]),t}();r.default&&(r.default.addDenoiserProcessor=function(t){var e=t.processor,n=t.userId;if(r.default.DenoiserMap)r.default.DenoiserMap.set(n,e);else{var o=new Map;o.set(n,e),r.default.DenoiserMap=o}});var GA=function(){function t(e){var r=e.assetsPath;c(this,t),this.audioContext_=Cd(),this.assetsPath_=r,this.isLoaded_=!1}var e,n,a;return f(t,[{key:"createProcessor",value:(a=u(i().mark((function t(e){var n,a,u,c,s,f,l,p,h;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=r.default?r.default.Logger.loggerManager.createLogger({id:e.userId,userId:e.userId,sdkAppId:e.sdkAppId}):{info:console.log},a=String(Date.now()).slice(0,-3),t.next=4,Nd(o(o({},e),{},{timestamp:a}));case 4:if(u=t.sent,c=u.auth,s=u.sign,f=u.status,l=u.message,c){t.next=12;break}throw n.info("RTCAIDenoiser: ".concat(e.userId," auth result: ").concat(c,". Message: ").concat(l)),new Error(l);case 12:return t.next=14,this.load();case 14:return t.next=16,this.initWorklet();case 16:return p=t.sent,h=new VA(o(o({},e),{},{audioContext:this.audioContext_,timestamp:a,sign:s,status:f,worklet:p,logger:n})),n.info("RTCAIDenoiser: ".concat(e.userId," create denoiser processor success.")),r.default&&r.default.addDenoiserProcessor({processor:h,userId:e.userId}),t.abrupt("return",h);case 21:case"end":return t.stop()}}),t,this)}))),function(t){return a.apply(this,arguments)})},{key:"load",value:(n=u(i().mark((function t(){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.isLoaded_){t.next=10;break}return t.prev=1,t.next=4,this.audioContext_.audioWorklet.addModule("".concat(this.assetsPath_,"/denoiser-wasm.js"));case 4:this.isLoaded_=!0,t.next=10;break;case 7:t.prev=7,t.t0=t.catch(1),console.error("Init assets from ".concat(this.assetsPath_," failed! Reason: ").concat(t.t0));case 10:case"end":return t.stop()}}),t,this,[[1,7]])}))),function(){return n.apply(this,arguments)})},{key:"initWorklet",value:(e=u(i().mark((function t(){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.abrupt("return",new AudioWorkletNode(this.audioContext_,"trtc-denoiser-processor",{numberOfInputs:1,numberOfOutputs:1}));case 4:return t.prev=4,t.t0=t.catch(0),t.next=8,this.load();case 8:return t.abrupt("return",new AudioWorkletNode(this.audioContext_,"trtc-denoiser-processor",{numberOfInputs:1,numberOfOutputs:1}));case 9:case"end":return t.stop()}}),t,this,[[0,4]])}))),function(){return e.apply(this,arguments)})},{key:"destroy",value:function(){var t;null===(t=this.audioContext_)||void 0===t||t.close()}},{key:"isSupported",value:function(){return"AudioWorklet"in window&&"WebAssembly"in window}}]),t}();return GA}));