xgplayer-mp4-loader 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,72 @@
1
+ # MP4Loader
2
+
3
+ MP4Loader 可以自定义加载单个 MP4 文件。
4
+
5
+ ## API
6
+
7
+ ### 参数
8
+
9
+ ```js
10
+ {
11
+ vid: '', // 视频 id,默认为 视频 url
12
+ moovEnd: 8000, // moov 盒子结束
13
+ segmentDuration: 5, // 期望的一个视频分片时长,实际会在该时长附近
14
+ maxDownloadInfoSize: 30, // 最大下载信息数组记录大小
15
+ cache: null, // 自定义 cache 对象
16
+ loaderType: LoaderType.FETCH, // loader 类型,默认 fetch,不支持时会自动降级为 xhr
17
+ retry: 0, // 重试次数
18
+ retryDelay: 0, // ms,每次重试间隔
19
+ timeout: 0, // 请求超时时间,默认不设置
20
+ request: null, // 请求 Request 对象
21
+ onTimeout: undefined, // 超时回调钩子
22
+ onRetryError: undefined, // 单次重试回调钩子
23
+ transformRequest: undefined, // 请求前会调用,可用来修改请求参数
24
+ transformResponse: undefined, // 响应后会调用,可以修改响应对象
25
+ url: '', // mp4 地址
26
+ params: undefined, // url 查询参数,为普通对象
27
+ method: 'GET', // 请求方法
28
+ headers: {}, // 自定义 header
29
+ body: undefined, // post 请求体
30
+ mode: undefined, // 同 fetch
31
+ credentials: undefined, // 同 fetch
32
+ cache: undefined, // 同 fetch
33
+ redirect: undefined, // 同 fetch
34
+ referrer: undefined, // 同 fetch
35
+ referrerPolicy: undefined, // 同 fetch
36
+ integrity: undefined, // 同 fetch
37
+ }
38
+ ```
39
+
40
+ ### 属性
41
+
42
+ ```js
43
+ const loader = new Loader()
44
+
45
+ loader.vid // 视频 vid,用于缓存 key
46
+ loader.meta // 视频元数据
47
+ // {
48
+ // videoCodec, // 视频编码字符串
49
+ // audioCodec, // 音频编码字符串
50
+ // width, // 宽度
51
+ // height, // 高度
52
+ // audioChannelCount, // 音频通道数
53
+ // audioSampleRate, // 音频采样率
54
+ // duration, // 视频时长
55
+ // moov // MP4Parser moov 对象
56
+ // }
57
+ loader.downloadInfo // 网络下载信息数组
58
+ // {
59
+ // startTime, // 开始下载时间戳
60
+ // endTime, // 结束下载时间戳
61
+ // size, // 下载数据大小
62
+ // range // range 范围 [start, end]
63
+ // }
64
+ loader.cache // loader 当前的 cache 对象
65
+ ```
66
+
67
+ ### 方法
68
+
69
+ #### loadMeta
70
+
71
+
72
+
@@ -0,0 +1,2 @@
1
+ !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).MP4Loader=e()}(this,(function(){"use strict";function t(t,e,r,n,o,i,a){try{var u=t[i](a),c=u.value}catch(t){return void r(t)}u.done?e(c):Promise.resolve(c).then(n,o)}function e(e){return function(){var r=this,n=arguments;return new Promise((function(o,i){var a=e.apply(r,n);function u(e){t(a,o,i,u,c,"next",e)}function c(e){t(a,o,i,u,c,"throw",e)}u(void 0)}))}}function r(t,e){if(null==t)return{};var r,n,o=function(t,e){if(null==t)return{};var r,n,o={},i=Object.keys(t);for(n=0;n<i.length;n++)r=i[n],e.indexOf(r)>=0||(o[r]=t[r]);return o}(t,e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(n=0;n<i.length;n++)r=i[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(o[r]=t[r])}return o}function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(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 i(t,e,r){return e&&o(t.prototype,e),r&&o(t,r),t}function a(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var u="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},c=function(t){return t&&t.Math==Math&&t},s=c("object"==typeof globalThis&&globalThis)||c("object"==typeof window&&window)||c("object"==typeof self&&self)||c("object"==typeof u&&u)||function(){return this}()||Function("return this")(),f={},l=function(t){try{return!!t()}catch(t){return!0}},d=!l((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),h={},p={}.propertyIsEnumerable,v=Object.getOwnPropertyDescriptor,y=v&&!p.call({1:2},1);h.f=y?function(t){var e=v(this,t);return!!e&&e.enumerable}:p;var g,m,b=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},w={}.toString,x=function(t){return w.call(t).slice(8,-1)},T=x,S="".split,k=l((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==T(t)?S.call(t,""):Object(t)}:Object,O=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},A=k,_=O,E=function(t){return A(_(t))},j=function(t){return"object"==typeof t?null!==t:"function"==typeof t},R=s,I=function(t){return"function"==typeof t?t:void 0},C=function(t,e){return arguments.length<2?I(R[t]):R[t]&&R[t][e]},P=C("navigator","userAgent")||"",L=s,M=P,D=L.process,B=L.Deno,F=D&&D.versions||B&&B.version,z=F&&F.v8;z?m=(g=z.split("."))[0]<4?1:g[0]+g[1]:M&&(!(g=M.match(/Edge\/(\d+)/))||g[1]>=74)&&(g=M.match(/Chrome\/(\d+)/))&&(m=g[1]);var U=m&&+m,N=U,Y=l,V=!!Object.getOwnPropertySymbols&&!Y((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&N&&N<41})),G=V&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,q=C,$=G?function(t){return"symbol"==typeof t}:function(t){var e=q("Symbol");return"function"==typeof e&&Object(t)instanceof e},W=j,H={exports:{}},K=s,Q=function(t,e){try{Object.defineProperty(K,t,{value:e,configurable:!0,writable:!0})}catch(r){K[t]=e}return e},J=Q,X="__core-js_shared__",Z=s[X]||J(X,{}),tt=Z;(H.exports=function(t,e){return tt[t]||(tt[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.16.2",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"});var et=O,rt=function(t){return Object(et(t))},nt=rt,ot={}.hasOwnProperty,it=Object.hasOwn||function(t,e){return ot.call(nt(t),e)},at=0,ut=Math.random(),ct=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++at+ut).toString(36)},st=s,ft=H.exports,lt=it,dt=ct,ht=V,pt=G,vt=ft("wks"),yt=st.Symbol,gt=pt?yt:yt&&yt.withoutSetter||dt,mt=function(t){return lt(vt,t)&&(ht||"string"==typeof vt[t])||(ht&&lt(yt,t)?vt[t]=yt[t]:vt[t]=gt("Symbol."+t)),vt[t]},bt=j,wt=$,xt=function(t,e){var r,n;if("string"===e&&"function"==typeof(r=t.toString)&&!W(n=r.call(t)))return n;if("function"==typeof(r=t.valueOf)&&!W(n=r.call(t)))return n;if("string"!==e&&"function"==typeof(r=t.toString)&&!W(n=r.call(t)))return n;throw TypeError("Can't convert object to primitive value")},Tt=mt("toPrimitive"),St=function(t,e){if(!bt(t)||wt(t))return t;var r,n=t[Tt];if(void 0!==n){if(void 0===e&&(e="default"),r=n.call(t,e),!bt(r)||wt(r))return r;throw TypeError("Can't convert object to primitive value")}return void 0===e&&(e="number"),xt(t,e)},kt=$,Ot=function(t){var e=St(t,"string");return kt(e)?e:String(e)},At=j,_t=s.document,Et=At(_t)&&At(_t.createElement),jt=function(t){return Et?_t.createElement(t):{}},Rt=jt,It=!d&&!l((function(){return 7!=Object.defineProperty(Rt("div"),"a",{get:function(){return 7}}).a})),Ct=d,Pt=h,Lt=b,Mt=E,Dt=Ot,Bt=it,Ft=It,zt=Object.getOwnPropertyDescriptor;f.f=Ct?zt:function(t,e){if(t=Mt(t),e=Dt(e),Ft)try{return zt(t,e)}catch(t){}if(Bt(t,e))return Lt(!Pt.f.call(t,e),t[e])};var Ut={},Nt=j,Yt=function(t){if(!Nt(t))throw TypeError(String(t)+" is not an object");return t},Vt=d,Gt=It,qt=Yt,$t=Ot,Wt=Object.defineProperty;Ut.f=Vt?Wt:function(t,e,r){if(qt(t),e=$t(e),qt(r),Gt)try{return Wt(t,e,r)}catch(t){}if("get"in r||"set"in r)throw TypeError("Accessors not supported");return"value"in r&&(t[e]=r.value),t};var Ht=Ut,Kt=b,Qt=d?function(t,e,r){return Ht.f(t,e,Kt(1,r))}:function(t,e,r){return t[e]=r,t},Jt={exports:{}},Xt=Z,Zt=Function.toString;"function"!=typeof Xt.inspectSource&&(Xt.inspectSource=function(t){return Zt.call(t)});var te,ee,re,ne=Xt.inspectSource,oe=ne,ie=s.WeakMap,ae="function"==typeof ie&&/native code/.test(oe(ie)),ue=H.exports,ce=ct,se=ue("keys"),fe=function(t){return se[t]||(se[t]=ce(t))},le={},de=ae,he=j,pe=Qt,ve=it,ye=Z,ge=fe,me=le,be="Object already initialized",we=s.WeakMap;if(de||ye.state){var xe=ye.state||(ye.state=new we),Te=xe.get,Se=xe.has,ke=xe.set;te=function(t,e){if(Se.call(xe,t))throw new TypeError(be);return e.facade=t,ke.call(xe,t,e),e},ee=function(t){return Te.call(xe,t)||{}},re=function(t){return Se.call(xe,t)}}else{var Oe=ge("state");me[Oe]=!0,te=function(t,e){if(ve(t,Oe))throw new TypeError(be);return e.facade=t,pe(t,Oe,e),e},ee=function(t){return ve(t,Oe)?t[Oe]:{}},re=function(t){return ve(t,Oe)}}var Ae={set:te,get:ee,has:re,enforce:function(t){return re(t)?ee(t):te(t,{})},getterFor:function(t){return function(e){var r;if(!he(e)||(r=ee(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return r}}},_e=s,Ee=Qt,je=it,Re=Q,Ie=ne,Ce=Ae.get,Pe=Ae.enforce,Le=String(String).split("String");(Jt.exports=function(t,e,r,n){var o,i=!!n&&!!n.unsafe,a=!!n&&!!n.enumerable,u=!!n&&!!n.noTargetGet;"function"==typeof r&&("string"!=typeof e||je(r,"name")||Ee(r,"name",e),(o=Pe(r)).source||(o.source=Le.join("string"==typeof e?e:""))),t!==_e?(i?!u&&t[e]&&(a=!0):delete t[e],a?t[e]=r:Ee(t,e,r)):a?t[e]=r:Re(e,r)})(Function.prototype,"toString",(function(){return"function"==typeof this&&Ce(this).source||Ie(this)}));var Me={},De=Math.ceil,Be=Math.floor,Fe=function(t){return isNaN(t=+t)?0:(t>0?Be:De)(t)},ze=Fe,Ue=Math.min,Ne=function(t){return t>0?Ue(ze(t),9007199254740991):0},Ye=Fe,Ve=Math.max,Ge=Math.min,qe=function(t,e){var r=Ye(t);return r<0?Ve(r+e,0):Ge(r,e)},$e=E,We=Ne,He=qe,Ke=function(t){return function(e,r,n){var o,i=$e(e),a=We(i.length),u=He(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}},Qe={includes:Ke(!0),indexOf:Ke(!1)},Je=it,Xe=E,Ze=Qe.indexOf,tr=le,er=function(t,e){var r,n=Xe(t),o=0,i=[];for(r in n)!Je(tr,r)&&Je(n,r)&&i.push(r);for(;e.length>o;)Je(n,r=e[o++])&&(~Ze(i,r)||i.push(r));return i},rr=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],nr=er,or=rr.concat("length","prototype");Me.f=Object.getOwnPropertyNames||function(t){return nr(t,or)};var ir={};ir.f=Object.getOwnPropertySymbols;var ar,ur=Me,cr=ir,sr=Yt,fr=C("Reflect","ownKeys")||function(t){var e=ur.f(sr(t)),r=cr.f;return r?e.concat(r(t)):e},lr=it,dr=fr,hr=f,pr=Ut,vr=function(t,e){for(var r=dr(e),n=pr.f,o=hr.f,i=0;i<r.length;i++){var a=r[i];lr(t,a)||n(t,a,o(e,a))}},yr=l,gr=/#|\.prototype\./,mr=function(t,e){var r=wr[br(t)];return r==Tr||r!=xr&&("function"==typeof e?yr(e):!!e)},br=mr.normalize=function(t){return String(t).replace(gr,".").toLowerCase()},wr=mr.data={},xr=mr.NATIVE="N",Tr=mr.POLYFILL="P",Sr=mr,kr=s,Or=f.f,Ar=Qt,_r=Jt.exports,Er=Q,jr=vr,Rr=Sr,Ir=function(t,e){var r,n,o,i,a,u=t.target,c=t.global,s=t.stat;if(r=c?kr:s?kr[u]||Er(u,{}):(kr[u]||{}).prototype)for(n in e){if(i=e[n],o=t.noTargetGet?(a=Or(r,n))&&a.value:r[n],!Rr(c?n:u+(s?".":"#")+n,t.forced)&&void 0!==o){if(typeof i==typeof o)continue;jr(i,o)}(t.sham||o&&o.sham)&&Ar(i,"sham",!0),_r(r,n,i,t)}},Cr=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t},Pr=Cr,Lr=function(t,e,r){if(Pr(t),void 0===e)return t;switch(r){case 0:return function(){return t.call(e)};case 1:return function(r){return t.call(e,r)};case 2:return function(r,n){return t.call(e,r,n)};case 3:return function(r,n,o){return t.call(e,r,n,o)}}return function(){return t.apply(e,arguments)}},Mr=x,Dr=Array.isArray||function(t){return"Array"==Mr(t)},Br=j,Fr=Dr,zr=mt("species"),Ur=function(t){var e;return Fr(t)&&("function"!=typeof(e=t.constructor)||e!==Array&&!Fr(e.prototype)?Br(e)&&null===(e=e[zr])&&(e=void 0):e=void 0),void 0===e?Array:e},Nr=function(t,e){return new(Ur(t))(0===e?0:e)},Yr=Lr,Vr=k,Gr=rt,qr=Ne,$r=Nr,Wr=[].push,Hr=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 d,h,p=Gr(c),v=Vr(p),y=Yr(s,f,3),g=qr(v.length),m=0,b=l||$r,w=e?b(c,g):r||a?b(c,0):void 0;g>m;m++)if((u||m in v)&&(h=y(d=v[m],m,p),t))if(e)w[m]=h;else if(h)switch(t){case 3:return!0;case 5:return d;case 6:return m;case 2:Wr.call(w,d)}else switch(t){case 4:return!1;case 7:Wr.call(w,d)}return i?-1:n||o?o:w}},Kr={forEach:Hr(0),map:Hr(1),filter:Hr(2),some:Hr(3),every:Hr(4),find:Hr(5),findIndex:Hr(6),filterReject:Hr(7)},Qr=er,Jr=rr,Xr=Object.keys||function(t){return Qr(t,Jr)},Zr=Ut,tn=Yt,en=Xr,rn=d?Object.defineProperties:function(t,e){tn(t);for(var r,n=en(e),o=n.length,i=0;o>i;)Zr.f(t,r=n[i++],e[r]);return t},nn=C("document","documentElement"),on=Yt,an=rn,un=rr,cn=le,sn=nn,fn=jt,ln=fe("IE_PROTO"),dn=function(){},hn=function(t){return"<script>"+t+"</"+"script>"},pn=function(t){t.write(hn("")),t.close();var e=t.parentWindow.Object;return t=null,e},vn=function(){try{ar=new ActiveXObject("htmlfile")}catch(t){}var t,e;vn="undefined"!=typeof document?document.domain&&ar?pn(ar):((e=fn("iframe")).style.display="none",sn.appendChild(e),e.src=String("javascript:"),(t=e.contentWindow.document).open(),t.write(hn("document.F=Object")),t.close(),t.F):pn(ar);for(var r=un.length;r--;)delete vn.prototype[un[r]];return vn()};cn[ln]=!0;var yn=Object.create||function(t,e){var r;return null!==t?(dn.prototype=on(t),r=new dn,dn.prototype=null,r[ln]=t):r=vn(),void 0===e?r:an(r,e)},gn=yn,mn=Ut,bn=mt("unscopables"),wn=Array.prototype;null==wn[bn]&&mn.f(wn,bn,{configurable:!0,value:gn(null)});var xn=function(t){wn[bn][t]=!0},Tn=Ir,Sn=Kr.find,kn=xn,On="find",An=!0;On in[]&&Array(1).find((function(){An=!1})),Tn({target:"Array",proto:!0,forced:An},{find:function(t){return Sn(this,t,arguments.length>1?arguments[1]:void 0)}}),kn(On);var _n=Ot,En=Ut,jn=b,Rn=function(t,e,r){var n=_n(e);n in t?En.f(t,n,jn(0,r)):t[n]=r},In=l,Cn=U,Pn=mt("species"),Ln=function(t){return Cn>=51||!In((function(){var e=[];return(e.constructor={})[Pn]=function(){return{foo:1}},1!==e[t](Boolean).foo}))},Mn=Ir,Dn=j,Bn=Dr,Fn=qe,zn=Ne,Un=E,Nn=Rn,Yn=mt,Vn=Ln("slice"),Gn=Yn("species"),qn=[].slice,$n=Math.max;Mn({target:"Array",proto:!0,forced:!Vn},{slice:function(t,e){var r,n,o,i=Un(this),a=zn(i.length),u=Fn(t,a),c=Fn(void 0===e?a:e,a);if(Bn(i)&&("function"!=typeof(r=i.constructor)||r!==Array&&!Bn(r.prototype)?Dn(r)&&null===(r=r[Gn])&&(r=void 0):r=void 0,r===Array||void 0===r))return qn.call(i,u,c);for(n=new(void 0===r?Array:r)($n(c-u,0)),o=0;u<c;u++,o++)u in i&&Nn(n,o,i[u]);return n.length=o,n}});var Wn={exports:{}};!function(t){var e=function(t){var e,r=Object.prototype,n=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",u=o.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(t){c=function(t,e,r){return t[e]=r}}function s(t,e,r,n){var o=e&&e.prototype instanceof y?e:y,i=Object.create(o.prototype),a=new E(n||[]);return i._invoke=function(t,e,r){var n=l;return function(o,i){if(n===h)throw new Error("Generator is already running");if(n===p){if("throw"===o)throw i;return R()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var u=O(a,r);if(u){if(u===v)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=p,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=h;var c=f(t,e,r);if("normal"===c.type){if(n=r.done?p:d,c.arg===v)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(n=p,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(t){return{type:"throw",arg:t}}}t.wrap=s;var l="suspendedStart",d="suspendedYield",h="executing",p="completed",v={};function y(){}function g(){}function m(){}var b={};b[i]=function(){return this};var w=Object.getPrototypeOf,x=w&&w(w(j([])));x&&x!==r&&n.call(x,i)&&(b=x);var T=m.prototype=y.prototype=Object.create(b);function S(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function k(t,e){function r(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&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(l).then((function(t){s.value=t,a(s)}),(function(t){return r("throw",t,a,u)}))}u(c.arg)}var o;this._invoke=function(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}}function O(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator.return&&(r.method="return",r.arg=e,O(t,r),"throw"===r.method))return v;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var o=f(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,v;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,v):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function A(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){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function j(t){if(t){var r=t[i];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return a.next=a}}return{next:R}}function R(){return{value:e,done:!0}}return g.prototype=T.constructor=m,m.constructor=g,g.displayName=c(m,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,c(t,u,"GeneratorFunction")),t.prototype=Object.create(T),t},t.awrap=function(t){return{__await:t}},S(k.prototype),k.prototype[a]=function(){return this},t.AsyncIterator=k,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new k(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},S(T),c(T,u,"Generator"),T[i]=function(){return this},T.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=j,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(_),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},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 r=this;function o(n,o){return u.type="throw",u.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var c=n.call(a,"catchLoc"),s=n.call(a,"finallyLoc");if(c&&s){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.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,v):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),v},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),_(r),v}},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;_(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:j(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),v}},t}(t.exports);try{regeneratorRuntime=e}catch(t){Function("r","regeneratorRuntime = r")(e)}}(Wn);var Hn=Wn.exports,Kn=Cr,Qn=j,Jn=[].slice,Xn={},Zn=function(t,e,r){if(!(e in Xn)){for(var n=[],o=0;o<e;o++)n[o]="a["+o+"]";Xn[e]=Function("C,a","return new C("+n.join(",")+")")}return Xn[e](t,r)},to=Function.bind||function(t){var e=Kn(this),r=Jn.call(arguments,1),n=function(){var o=r.concat(Jn.call(arguments));return this instanceof n?Zn(e,o.length,o):e.apply(t,o)};return Qn(e.prototype)&&(n.prototype=e.prototype),n},eo=Ir,ro=Cr,no=Yt,oo=j,io=yn,ao=to,uo=l,co=C("Reflect","construct"),so=uo((function(){function t(){}return!(co((function(){}),[],t)instanceof t)})),fo=!uo((function(){co((function(){}))})),lo=so||fo;function ho(t,e){return(ho=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function po(t){return(po="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function vo(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function yo(t,e){if(e&&("object"===po(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return vo(t)}function go(t){return(go=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function mo(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function bo(t,e,r){return(bo=mo()?Reflect.construct:function(t,e,r){var n=[null];n.push.apply(n,e);var o=new(Function.bind.apply(t,n));return r&&ho(o,r.prototype),o}).apply(null,arguments)}function wo(t){var e="function"==typeof Map?new Map:void 0;return(wo=function(t){if(null===t||(r=t,-1===Function.toString.call(r).indexOf("[native code]")))return t;var r;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,n)}function n(){return bo(t,arguments,go(this).constructor)}return n.prototype=Object.create(t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),ho(n,t)})(t)}eo({target:"Reflect",stat:!0,forced:lo,sham:lo},{construct:function(t,e){ro(t),no(e);var r=arguments.length<3?t:ro(arguments[2]);if(fo&&!so)return co(t,e,r);if(t==r){switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3])}var n=[null];return n.push.apply(n,e),new(ao.apply(t,n))}var o=r.prototype,i=io(oo(o)?o:Object.prototype),a=Function.apply.call(t,i,e);return oo(a)?a:i}});var xo,To,So,ko={},Oo=!l((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),Ao=it,_o=rt,Eo=Oo,jo=fe("IE_PROTO"),Ro=Object.prototype,Io=Eo?Object.getPrototypeOf:function(t){return t=_o(t),Ao(t,jo)?t[jo]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?Ro:null},Co=l,Po=Io,Lo=Qt,Mo=it,Do=mt("iterator"),Bo=!1;[].keys&&("next"in(So=[].keys())?(To=Po(Po(So)))!==Object.prototype&&(xo=To):Bo=!0),(null==xo||Co((function(){var t={};return xo[Do].call(t)!==t})))&&(xo={}),Mo(xo,Do)||Lo(xo,Do,(function(){return this}));var Fo={IteratorPrototype:xo,BUGGY_SAFARI_ITERATORS:Bo},zo=Ut.f,Uo=it,No=mt("toStringTag"),Yo=function(t,e,r){t&&!Uo(t=r?t:t.prototype,No)&&zo(t,No,{configurable:!0,value:e})},Vo=Fo.IteratorPrototype,Go=yn,qo=b,$o=Yo,Wo=ko,Ho=function(){return this},Ko=j,Qo=Yt,Jo=function(t){if(!Ko(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype");return t},Xo=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,r={};try{(t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(r,[]),e=r instanceof Array}catch(t){}return function(r,n){return Qo(r),Jo(n),e?t.call(r,n):r.__proto__=n,r}}():void 0),Zo=Ir,ti=function(t,e,r){var n=e+" Iterator";return t.prototype=Go(Vo,{next:qo(1,r)}),$o(t,n,!1),Wo[n]=Ho,t},ei=Io,ri=Xo,ni=Yo,oi=Qt,ii=Jt.exports,ai=ko,ui=Fo.IteratorPrototype,ci=Fo.BUGGY_SAFARI_ITERATORS,si=mt("iterator"),fi="keys",li="values",di="entries",hi=function(){return this},pi=function(t,e,r,n,o,i,a){ti(r,e,n);var u,c,s,f=function(t){if(t===o&&v)return v;if(!ci&&t in h)return h[t];switch(t){case fi:case li:case di:return function(){return new r(this,t)}}return function(){return new r(this)}},l=e+" Iterator",d=!1,h=t.prototype,p=h[si]||h["@@iterator"]||o&&h[o],v=!ci&&p||f(o),y="Array"==e&&h.entries||p;if(y&&(u=ei(y.call(new t)),ui!==Object.prototype&&u.next&&(ei(u)!==ui&&(ri?ri(u,ui):"function"!=typeof u[si]&&oi(u,si,hi)),ni(u,l,!0))),o==li&&p&&p.name!==li&&(d=!0,v=function(){return p.call(this)}),h[si]!==v&&oi(h,si,v),ai[e]=v,o)if(c={values:f(li),keys:i?v:f(fi),entries:f(di)},a)for(s in c)(ci||d||!(s in h))&&ii(h,s,c[s]);else Zo({target:e,proto:!0,forced:ci||d},c);return c},vi=E,yi=xn,gi=ko,mi=Ae,bi=pi,wi="Array Iterator",xi=mi.set,Ti=mi.getterFor(wi),Si=bi(Array,"Array",(function(t,e){xi(this,{type:wi,target:vi(t),index:0,kind:e})}),(function(){var t=Ti(this),e=t.target,r=t.kind,n=t.index++;return!e||n>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==r?{value:n,done:!1}:"values"==r?{value:e[n],done:!1}:{value:[n,e[n]],done:!1}}),"values");gi.Arguments=gi.Array,yi("keys"),yi("values"),yi("entries");var ki={};ki[mt("toStringTag")]="z";var Oi="[object z]"===String(ki),Ai=Oi,_i=x,Ei=mt("toStringTag"),ji="Arguments"==_i(function(){return arguments}()),Ri=Ai?_i: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(t){}}(e=Object(t),Ei))?r:ji?_i(e):"Object"==(n=_i(e))&&"function"==typeof e.callee?"Arguments":n},Ii=Ri,Ci=Oi?{}.toString:function(){return"[object "+Ii(this)+"]"},Pi=Oi,Li=Jt.exports,Mi=Ci;Pi||Li(Object.prototype,"toString",Mi,{unsafe:!0});var Di=$,Bi=function(t){if(Di(t))throw TypeError("Cannot convert a Symbol value to a string");return String(t)},Fi=Fe,zi=Bi,Ui=O,Ni=function(t){return function(e,r){var n,o,i=zi(Ui(e)),a=Fi(r),u=i.length;return a<0||a>=u?t?"":void 0:(n=i.charCodeAt(a))<55296||n>56319||a+1===u||(o=i.charCodeAt(a+1))<56320||o>57343?t?i.charAt(a):n:t?i.slice(a,a+2):o-56320+(n-55296<<10)+65536}},Yi={codeAt:Ni(!1),charAt:Ni(!0)},Vi=Yi.charAt,Gi=Bi,qi=Ae,$i=pi,Wi="String Iterator",Hi=qi.set,Ki=qi.getterFor(Wi);$i(String,"String",(function(t){Hi(this,{type:Wi,string:Gi(t),index:0})}),(function(){var t,e=Ki(this),r=e.string,n=e.index;return n>=r.length?{value:void 0,done:!0}:(t=Vi(r,n),e.index+=t.length,{value:t,done:!1})}));var Qi={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},Ji=s,Xi=Qi,Zi=Si,ta=Qt,ea=mt,ra=ea("iterator"),na=ea("toStringTag"),oa=Zi.values;for(var ia in Xi){var aa=Ji[ia],ua=aa&&aa.prototype;if(ua){if(ua[ra]!==oa)try{ta(ua,ra,oa)}catch(t){ua[ra]=oa}if(ua[na]||ta(ua,na,ia),Xi[ia])for(var ca in Zi)if(ua[ca]!==Zi[ca])try{ta(ua,ca,Zi[ca])}catch(t){ua[ca]=Zi[ca]}}}var sa=function(t,e,r){if(!(t instanceof e))throw TypeError("Incorrect "+(r?r+" ":"")+"invocation");return t},fa=d,la=l,da=Xr,ha=ir,pa=h,va=rt,ya=k,ga=Object.assign,ma=Object.defineProperty,ba=!ga||la((function(){if(fa&&1!==ga({b:1},ga(ma({},"a",{enumerable:!0,get:function(){ma(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var t={},e={},r=Symbol(),n="abcdefghijklmnopqrst";return t[r]=7,n.split("").forEach((function(t){e[t]=t})),7!=ga({},t)[r]||da(ga({},e)).join("")!=n}))?function(t,e){for(var r=va(t),n=arguments.length,o=1,i=ha.f,a=pa.f;n>o;)for(var u,c=ya(arguments[o++]),s=i?da(c).concat(i(c)):da(c),f=s.length,l=0;f>l;)u=s[l++],fa&&!a.call(c,u)||(r[u]=c[u]);return r}:ga,wa=Yt,xa=function(t){var e=t.return;if(void 0!==e)return wa(e.call(t)).value},Ta=Yt,Sa=xa,ka=ko,Oa=mt("iterator"),Aa=Array.prototype,_a=function(t){return void 0!==t&&(ka.Array===t||Aa[Oa]===t)},Ea=Ri,ja=ko,Ra=mt("iterator"),Ia=function(t){if(null!=t)return t[Ra]||t["@@iterator"]||ja[Ea(t)]},Ca=Lr,Pa=rt,La=function(t,e,r,n){try{return n?e(Ta(r)[0],r[1]):e(r)}catch(e){throw Sa(t),e}},Ma=_a,Da=Ne,Ba=Rn,Fa=Ia,za=Jt.exports,Ua=function(t,e,r){for(var n in e)za(t,n,e[n],r);return t},Na=l,Ya=function(t,e){var r=[][t];return!!r&&Na((function(){r.call(null,e||function(){throw 1},1)}))},Va=Kr.forEach,Ga=s,qa=Qi,$a=Ya("forEach")?[].forEach:function(t){return Va(this,t,arguments.length>1?arguments[1]:void 0)},Wa=Qt;for(var Ha in qa){var Ka=Ga[Ha],Qa=Ka&&Ka.prototype;if(Qa&&Qa.forEach!==$a)try{Wa(Qa,"forEach",$a)}catch(t){Qa.forEach=$a}}var Ja=rt,Xa=Xr;Ir({target:"Object",stat:!0,forced:l((function(){Xa(1)}))},{keys:function(t){return Xa(Ja(t))}});var Za=s.Promise,tu=C,eu=Ut,ru=d,nu=mt("species"),ou=function(t){var e=tu(t),r=eu.f;ru&&e&&!e[nu]&&r(e,nu,{configurable:!0,get:function(){return this}})},iu=Yt,au=_a,uu=Ne,cu=Lr,su=Ia,fu=xa,lu=function(t,e){this.stopped=t,this.result=e},du=mt("iterator"),hu=!1;try{var pu=0,vu={next:function(){return{done:!!pu++}},return:function(){hu=!0}};vu[du]=function(){return this},Array.from(vu,(function(){throw 2}))}catch(t){}var yu,gu,mu,bu,wu=function(t,e){if(!e&&!hu)return!1;var r=!1;try{var n={};n[du]=function(){return{next:function(){return{done:r=!0}}}},t(n)}catch(t){}return r},xu=Yt,Tu=Cr,Su=mt("species"),ku=function(t,e){var r,n=xu(t).constructor;return void 0===n||null==(r=xu(n)[Su])?e:Tu(r)},Ou=/(?:ipad|iphone|ipod).*applewebkit/i.test(P),Au="process"==x(s.process),_u=s,Eu=l,ju=Lr,Ru=nn,Iu=jt,Cu=Ou,Pu=Au,Lu=_u.setImmediate,Mu=_u.clearImmediate,Du=_u.process,Bu=_u.MessageChannel,Fu=_u.Dispatch,zu=0,Uu={},Nu="onreadystatechange";try{yu=_u.location}catch(t){}var Yu=function(t){if(Uu.hasOwnProperty(t)){var e=Uu[t];delete Uu[t],e()}},Vu=function(t){return function(){Yu(t)}},Gu=function(t){Yu(t.data)},qu=function(t){_u.postMessage(String(t),yu.protocol+"//"+yu.host)};Lu&&Mu||(Lu=function(t){for(var e=[],r=arguments.length,n=1;r>n;)e.push(arguments[n++]);return Uu[++zu]=function(){("function"==typeof t?t:Function(t)).apply(void 0,e)},gu(zu),zu},Mu=function(t){delete Uu[t]},Pu?gu=function(t){Du.nextTick(Vu(t))}:Fu&&Fu.now?gu=function(t){Fu.now(Vu(t))}:Bu&&!Cu?(bu=(mu=new Bu).port2,mu.port1.onmessage=Gu,gu=ju(bu.postMessage,bu,1)):_u.addEventListener&&"function"==typeof postMessage&&!_u.importScripts&&yu&&"file:"!==yu.protocol&&!Eu(qu)?(gu=qu,_u.addEventListener("message",Gu,!1)):gu=Nu in Iu("script")?function(t){Ru.appendChild(Iu("script")).onreadystatechange=function(){Ru.removeChild(this),Yu(t)}}:function(t){setTimeout(Vu(t),0)});var $u,Wu,Hu,Ku,Qu,Ju,Xu,Zu,tc={set:Lu,clear:Mu},ec=s,rc=/ipad|iphone|ipod/i.test(P)&&void 0!==ec.Pebble,nc=/web0s(?!.*chrome)/i.test(P),oc=s,ic=f.f,ac=tc.set,uc=Ou,cc=rc,sc=nc,fc=Au,lc=oc.MutationObserver||oc.WebKitMutationObserver,dc=oc.document,hc=oc.process,pc=oc.Promise,vc=ic(oc,"queueMicrotask"),yc=vc&&vc.value;yc||($u=function(){var t,e;for(fc&&(t=hc.domain)&&t.exit();Wu;){e=Wu.fn,Wu=Wu.next;try{e()}catch(t){throw Wu?Ku():Hu=void 0,t}}Hu=void 0,t&&t.enter()},uc||fc||sc||!lc||!dc?!cc&&pc&&pc.resolve?((Xu=pc.resolve(void 0)).constructor=pc,Zu=Xu.then,Ku=function(){Zu.call(Xu,$u)}):Ku=fc?function(){hc.nextTick($u)}:function(){ac.call(oc,$u)}:(Qu=!0,Ju=dc.createTextNode(""),new lc($u).observe(Ju,{characterData:!0}),Ku=function(){Ju.data=Qu=!Qu}));var gc=yc||function(t){var e={fn:t,next:void 0};Hu&&(Hu.next=e),Wu||(Wu=e,Ku()),Hu=e},mc={},bc=Cr,wc=function(t){var e,r;this.promise=new t((function(t,n){if(void 0!==e||void 0!==r)throw TypeError("Bad Promise constructor");e=t,r=n})),this.resolve=bc(e),this.reject=bc(r)};mc.f=function(t){return new wc(t)};var xc,Tc,Sc,kc,Oc=Yt,Ac=j,_c=mc,Ec=function(t,e){if(Oc(t),Ac(e)&&e.constructor===t)return e;var r=_c.f(t);return(0,r.resolve)(e),r.promise},jc=s,Rc="object"==typeof window,Ic=Ir,Cc=s,Pc=C,Lc=Za,Mc=Jt.exports,Dc=Ua,Bc=Xo,Fc=Yo,zc=ou,Uc=j,Nc=Cr,Yc=sa,Vc=ne,Gc=function(t,e,r){var n,o,i,a,u,c,s,f=r&&r.that,l=!(!r||!r.AS_ENTRIES),d=!(!r||!r.IS_ITERATOR),h=!(!r||!r.INTERRUPTED),p=cu(e,f,1+l+h),v=function(t){return n&&fu(n),new lu(!0,t)},y=function(t){return l?(iu(t),h?p(t[0],t[1],v):p(t[0],t[1])):h?p(t,v):p(t)};if(d)n=t;else{if("function"!=typeof(o=su(t)))throw TypeError("Target is not iterable");if(au(o)){for(i=0,a=uu(t.length);a>i;i++)if((u=y(t[i]))&&u instanceof lu)return u;return new lu(!1)}n=o.call(t)}for(c=n.next;!(s=c.call(n)).done;){try{u=y(s.value)}catch(t){throw fu(n),t}if("object"==typeof u&&u&&u instanceof lu)return u}return new lu(!1)},qc=wu,$c=ku,Wc=tc.set,Hc=gc,Kc=Ec,Qc=function(t,e){var r=jc.console;r&&r.error&&(1===arguments.length?r.error(t):r.error(t,e))},Jc=mc,Xc=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}},Zc=Ae,ts=Sr,es=Rc,rs=Au,ns=U,os=mt("species"),is="Promise",as=Zc.get,us=Zc.set,cs=Zc.getterFor(is),ss=Lc&&Lc.prototype,fs=Lc,ls=ss,ds=Cc.TypeError,hs=Cc.document,ps=Cc.process,vs=Jc.f,ys=vs,gs=!!(hs&&hs.createEvent&&Cc.dispatchEvent),ms="function"==typeof PromiseRejectionEvent,bs="unhandledrejection",ws=!1,xs=ts(is,(function(){var t=Vc(fs),e=t!==String(fs);if(!e&&66===ns)return!0;if(ns>=51&&/native code/.test(t))return!1;var r=new fs((function(t){t(1)})),n=function(t){t((function(){}),(function(){}))};return(r.constructor={})[os]=n,!(ws=r.then((function(){}))instanceof n)||!e&&es&&!ms})),Ts=xs||!qc((function(t){fs.all(t).catch((function(){}))})),Ss=function(t){var e;return!(!Uc(t)||"function"!=typeof(e=t.then))&&e},ks=function(t,e){if(!t.notified){t.notified=!0;var r=t.reactions;Hc((function(){for(var n=t.value,o=1==t.state,i=0;r.length>i;){var a,u,c,s=r[i++],f=o?s.ok:s.fail,l=s.resolve,d=s.reject,h=s.domain;try{f?(o||(2===t.rejection&&Es(t),t.rejection=1),!0===f?a=n:(h&&h.enter(),a=f(n),h&&(h.exit(),c=!0)),a===s.promise?d(ds("Promise-chain cycle")):(u=Ss(a))?u.call(a,l,d):l(a)):d(n)}catch(t){h&&!c&&h.exit(),d(t)}}t.reactions=[],t.notified=!1,e&&!t.rejection&&As(t)}))}},Os=function(t,e,r){var n,o;gs?((n=hs.createEvent("Event")).promise=e,n.reason=r,n.initEvent(t,!1,!0),Cc.dispatchEvent(n)):n={promise:e,reason:r},!ms&&(o=Cc["on"+t])?o(n):t===bs&&Qc("Unhandled promise rejection",r)},As=function(t){Wc.call(Cc,(function(){var e,r=t.facade,n=t.value;if(_s(t)&&(e=Xc((function(){rs?ps.emit("unhandledRejection",n,r):Os(bs,r,n)})),t.rejection=rs||_s(t)?2:1,e.error))throw e.value}))},_s=function(t){return 1!==t.rejection&&!t.parent},Es=function(t){Wc.call(Cc,(function(){var e=t.facade;rs?ps.emit("rejectionHandled",e):Os("rejectionhandled",e,t.value)}))},js=function(t,e,r){return function(n){t(e,n,r)}},Rs=function(t,e,r){t.done||(t.done=!0,r&&(t=r),t.value=e,t.state=2,ks(t,!0))},Is=function(t,e,r){if(!t.done){t.done=!0,r&&(t=r);try{if(t.facade===e)throw ds("Promise can't be resolved itself");var n=Ss(e);n?Hc((function(){var r={done:!1};try{n.call(e,js(Is,r,t),js(Rs,r,t))}catch(e){Rs(r,e,t)}})):(t.value=e,t.state=1,ks(t,!1))}catch(e){Rs({done:!1},e,t)}}};if(xs&&(ls=(fs=function(t){Yc(this,fs,is),Nc(t),xc.call(this);var e=as(this);try{t(js(Is,e),js(Rs,e))}catch(t){Rs(e,t)}}).prototype,(xc=function(t){us(this,{type:is,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=Dc(ls,{then:function(t,e){var r=cs(this),n=vs($c(this,fs));return n.ok="function"!=typeof t||t,n.fail="function"==typeof e&&e,n.domain=rs?ps.domain:void 0,r.parent=!0,r.reactions.push(n),0!=r.state&&ks(r,!1),n.promise},catch:function(t){return this.then(void 0,t)}}),Tc=function(){var t=new xc,e=as(t);this.promise=t,this.resolve=js(Is,e),this.reject=js(Rs,e)},Jc.f=vs=function(t){return t===fs||t===Sc?new Tc(t):ys(t)},"function"==typeof Lc&&ss!==Object.prototype)){kc=ss.then,ws||(Mc(ss,"then",(function(t,e){var r=this;return new fs((function(t,e){kc.call(r,t,e)})).then(t,e)}),{unsafe:!0}),Mc(ss,"catch",ls.catch,{unsafe:!0}));try{delete ss.constructor}catch(t){}Bc&&Bc(ss,ls)}Ic({global:!0,wrap:!0,forced:xs},{Promise:fs}),Fc(fs,is,!1),zc(is),Sc=Pc(is),Ic({target:is,stat:!0,forced:xs},{reject:function(t){var e=vs(this);return e.reject.call(void 0,t),e.promise}}),Ic({target:is,stat:!0,forced:xs},{resolve:function(t){return Kc(this,t)}}),Ic({target:is,stat:!0,forced:Ts},{all:function(t){var e=this,r=vs(e),n=r.resolve,o=r.reject,i=Xc((function(){var r=Nc(e.resolve),i=[],a=0,u=1;Gc(t,(function(t){var c=a++,s=!1;i.push(void 0),u++,r.call(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},race:function(t){var e=this,r=vs(e),n=r.reject,o=Xc((function(){var o=Nc(e.resolve);Gc(t,(function(t){o.call(e,t).then(r.resolve,n)}))}));return o.error&&n(o.value),r.promise}});var Cs=Yt,Ps=function(){var t=Cs(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e},Ls={},Ms=l,Ds=s.RegExp;Ls.UNSUPPORTED_Y=Ms((function(){var t=Ds("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),Ls.BROKEN_CARET=Ms((function(){var t=Ds("^r","gy");return t.lastIndex=2,null!=t.exec("str")}));var Bs,Fs,zs=l,Us=s.RegExp,Ns=zs((function(){var t=Us(".","s");return!(t.dotAll&&t.exec("\n")&&"s"===t.flags)})),Ys=l,Vs=s.RegExp,Gs=Ys((function(){var t=Vs("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})),qs=Bi,$s=Ps,Ws=Ls,Hs=H.exports,Ks=yn,Qs=Ae.get,Js=Ns,Xs=Gs,Zs=RegExp.prototype.exec,tf=Hs("native-string-replace",String.prototype.replace),ef=Zs,rf=(Bs=/a/,Fs=/b*/g,Zs.call(Bs,"a"),Zs.call(Fs,"a"),0!==Bs.lastIndex||0!==Fs.lastIndex),nf=Ws.UNSUPPORTED_Y||Ws.BROKEN_CARET,of=void 0!==/()??/.exec("")[1];(rf||of||nf||Js||Xs)&&(ef=function(t){var e,r,n,o,i,a,u,c=this,s=Qs(c),f=qs(t),l=s.raw;if(l)return l.lastIndex=c.lastIndex,e=ef.call(l,f),c.lastIndex=l.lastIndex,e;var d=s.groups,h=nf&&c.sticky,p=$s.call(c),v=c.source,y=0,g=f;if(h&&(-1===(p=p.replace("y","")).indexOf("g")&&(p+="g"),g=f.slice(c.lastIndex),c.lastIndex>0&&(!c.multiline||c.multiline&&"\n"!==f.charAt(c.lastIndex-1))&&(v="(?: "+v+")",g=" "+g,y++),r=new RegExp("^(?:"+v+")",p)),of&&(r=new RegExp("^"+v+"$(?!\\s)",p)),rf&&(n=c.lastIndex),o=Zs.call(h?r:c,g),h?o?(o.input=o.input.slice(y),o[0]=o[0].slice(y),o.index=c.lastIndex,c.lastIndex+=o[0].length):c.lastIndex=0:rf&&o&&(c.lastIndex=c.global?o.index+o[0].length:n),of&&o&&o.length>1&&tf.call(o[0],r,(function(){for(i=1;i<arguments.length-2;i++)void 0===arguments[i]&&(o[i]=void 0)})),o&&d)for(o.groups=a=Ks(null),i=0;i<d.length;i++)a[(u=d[i])[0]]=o[u[1]];return o});var af=ef;Ir({target:"RegExp",proto:!0,forced:/./.exec!==af},{exec:af});var uf=ba;Ir({target:"Object",stat:!0,forced:Object.assign!==uf},{assign:uf});var cf=Ir,sf=l,ff=Dr,lf=j,df=rt,hf=Ne,pf=Rn,vf=Nr,yf=Ln,gf=U,mf=mt("isConcatSpreadable"),bf=9007199254740991,wf="Maximum allowed index exceeded",xf=gf>=51||!sf((function(){var t=[];return t[mf]=!1,t.concat()[0]!==t})),Tf=yf("concat"),Sf=function(t){if(!lf(t))return!1;var e=t[mf];return void 0!==e?!!e:ff(t)};cf({target:"Array",proto:!0,forced:!xf||!Tf},{concat:function(t){var e,r,n,o,i,a=df(this),u=vf(a,0),c=0;for(e=-1,n=arguments.length;e<n;e++)if(Sf(i=-1===e?a:arguments[e])){if(c+(o=hf(i.length))>bf)throw TypeError(wf);for(r=0;r<o;r++,c++)r in i&&pf(u,c,i[r])}else{if(c>=bf)throw TypeError(wf);pf(u,c++,i)}return u.length=c,u}});var kf=Kr.map;Ir({target:"Array",proto:!0,forced:!Ln("map")},{map:function(t){return kf(this,t,arguments.length>1?arguments[1]:void 0)}});var Of=Ir,Af=Za,_f=l,Ef=C,jf=ku,Rf=Ec,If=Jt.exports;if(Of({target:"Promise",proto:!0,real:!0,forced:!!Af&&_f((function(){Af.prototype.finally.call({then:function(){}},(function(){}))}))},{finally:function(t){var e=jf(this,Ef("Promise")),r="function"==typeof t;return this.then(r?function(r){return Rf(e,t()).then((function(){return r}))}:t,r?function(r){return Rf(e,t()).then((function(){throw r}))}:t)}}),"function"==typeof Af){var Cf=Ef("Promise").prototype.finally;Af.prototype.finally!==Cf&&If(Af.prototype,"finally",Cf,{unsafe:!0})}var Pf,Lf,Mf,Df={exports:{}},Bf="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView,Ff=Bf,zf=d,Uf=s,Nf=j,Yf=it,Vf=Ri,Gf=Qt,qf=Jt.exports,$f=Ut.f,Wf=Io,Hf=Xo,Kf=mt,Qf=ct,Jf=Uf.Int8Array,Xf=Jf&&Jf.prototype,Zf=Uf.Uint8ClampedArray,tl=Zf&&Zf.prototype,el=Jf&&Wf(Jf),rl=Xf&&Wf(Xf),nl=Object.prototype,ol=nl.isPrototypeOf,il=Kf("toStringTag"),al=Qf("TYPED_ARRAY_TAG"),ul=Qf("TYPED_ARRAY_CONSTRUCTOR"),cl=Ff&&!!Hf&&"Opera"!==Vf(Uf.opera),sl=!1,fl={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},ll={BigInt64Array:8,BigUint64Array:8},dl=function(t){if(!Nf(t))return!1;var e=Vf(t);return Yf(fl,e)||Yf(ll,e)};for(Pf in fl)(Mf=(Lf=Uf[Pf])&&Lf.prototype)?Gf(Mf,ul,Lf):cl=!1;for(Pf in ll)(Mf=(Lf=Uf[Pf])&&Lf.prototype)&&Gf(Mf,ul,Lf);if((!cl||"function"!=typeof el||el===Function.prototype)&&(el=function(){throw TypeError("Incorrect invocation")},cl))for(Pf in fl)Uf[Pf]&&Hf(Uf[Pf],el);if((!cl||!rl||rl===nl)&&(rl=el.prototype,cl))for(Pf in fl)Uf[Pf]&&Hf(Uf[Pf].prototype,rl);if(cl&&Wf(tl)!==rl&&Hf(tl,rl),zf&&!Yf(rl,il))for(Pf in sl=!0,$f(rl,il,{get:function(){return Nf(this)?this[al]:void 0}}),fl)Uf[Pf]&&Gf(Uf[Pf],al,Pf);var hl={NATIVE_ARRAY_BUFFER_VIEWS:cl,TYPED_ARRAY_CONSTRUCTOR:ul,TYPED_ARRAY_TAG:sl&&al,aTypedArray:function(t){if(dl(t))return t;throw TypeError("Target is not a typed array")},aTypedArrayConstructor:function(t){if(Hf&&!ol.call(el,t))throw TypeError("Target is not a typed array constructor");return t},exportTypedArrayMethod:function(t,e,r){if(zf){if(r)for(var n in fl){var o=Uf[n];if(o&&Yf(o.prototype,t))try{delete o.prototype[t]}catch(t){}}rl[t]&&!r||qf(rl,t,r?e:cl&&Xf[t]||e)}},exportTypedArrayStaticMethod:function(t,e,r){var n,o;if(zf){if(Hf){if(r)for(n in fl)if((o=Uf[n])&&Yf(o,t))try{delete o[t]}catch(t){}if(el[t]&&!r)return;try{return qf(el,t,r?e:cl&&el[t]||e)}catch(t){}}for(n in fl)!(o=Uf[n])||o[t]&&!r||qf(o,t,e)}},isView:function(t){if(!Nf(t))return!1;var e=Vf(t);return"DataView"===e||Yf(fl,e)||Yf(ll,e)},isTypedArray:dl,TypedArray:el,TypedArrayPrototype:rl},pl=s,vl=l,yl=wu,gl=hl.NATIVE_ARRAY_BUFFER_VIEWS,ml=pl.ArrayBuffer,bl=pl.Int8Array,wl=!gl||!vl((function(){bl(1)}))||!vl((function(){new bl(-1)}))||!yl((function(t){new bl,new bl(null),new bl(1.5),new bl(t)}),!0)||vl((function(){return 1!==new bl(new ml(2),1,void 0).length})),xl=Fe,Tl=Ne,Sl=function(t){if(void 0===t)return 0;var e=xl(t),r=Tl(e);if(e!==r)throw RangeError("Wrong length or index");return r},kl=Math.abs,Ol=Math.pow,Al=Math.floor,_l=Math.log,El=Math.LN2,jl=rt,Rl=qe,Il=Ne,Cl=function(t){for(var e=jl(this),r=Il(e.length),n=arguments.length,o=Rl(n>1?arguments[1]:void 0,r),i=n>2?arguments[2]:void 0,a=void 0===i?r:Rl(i,r);a>o;)e[o++]=t;return e},Pl=s,Ll=d,Ml=Bf,Dl=Qt,Bl=Ua,Fl=l,zl=sa,Ul=Fe,Nl=Ne,Yl=Sl,Vl={pack:function(t,e,r){var n,o,i,a=new Array(r),u=8*r-e-1,c=(1<<u)-1,s=c>>1,f=23===e?Ol(2,-24)-Ol(2,-77):0,l=t<0||0===t&&1/t<0?1:0,d=0;for((t=kl(t))!=t||t===1/0?(o=t!=t?1:0,n=c):(n=Al(_l(t)/El),t*(i=Ol(2,-n))<1&&(n--,i*=2),(t+=n+s>=1?f/i:f*Ol(2,1-s))*i>=2&&(n++,i/=2),n+s>=c?(o=0,n=c):n+s>=1?(o=(t*i-1)*Ol(2,e),n+=s):(o=t*Ol(2,s-1)*Ol(2,e),n=0));e>=8;a[d++]=255&o,o/=256,e-=8);for(n=n<<e|o,u+=e;u>0;a[d++]=255&n,n/=256,u-=8);return a[--d]|=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],c--,u-=8);for(r=f&(1<<-u)-1,f>>=-u,u+=e;u>0;r=256*r+t[c],c--,u-=8);if(0===f)f=1-a;else{if(f===i)return r?NaN:s?-1/0:1/0;r+=Ol(2,e),f-=a}return(s?-1:1)*r*Ol(2,f-e)}},Gl=Io,ql=Xo,$l=Me.f,Wl=Ut.f,Hl=Cl,Kl=Yo,Ql=Ae.get,Jl=Ae.set,Xl="ArrayBuffer",Zl="DataView",td="Wrong index",ed=Pl.ArrayBuffer,rd=ed,nd=Pl.DataView,od=nd&&nd.prototype,id=Object.prototype,ad=Pl.RangeError,ud=Vl.pack,cd=Vl.unpack,sd=function(t){return[255&t]},fd=function(t){return[255&t,t>>8&255]},ld=function(t){return[255&t,t>>8&255,t>>16&255,t>>24&255]},dd=function(t){return t[3]<<24|t[2]<<16|t[1]<<8|t[0]},hd=function(t){return ud(t,23,4)},pd=function(t){return ud(t,52,8)},vd=function(t,e){Wl(t.prototype,e,{get:function(){return Ql(this)[e]}})},yd=function(t,e,r,n){var o=Yl(r),i=Ql(t);if(o+e>i.byteLength)throw ad(td);var a=Ql(i.buffer).bytes,u=o+i.byteOffset,c=a.slice(u,u+e);return n?c:c.reverse()},gd=function(t,e,r,n,o,i){var a=Yl(r),u=Ql(t);if(a+e>u.byteLength)throw ad(td);for(var c=Ql(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(Ml){if(!Fl((function(){ed(1)}))||!Fl((function(){new ed(-1)}))||Fl((function(){return new ed,new ed(1.5),new ed(NaN),ed.name!=Xl}))){for(var md,bd=(rd=function(t){return zl(this,rd),new ed(Yl(t))}).prototype=ed.prototype,wd=$l(ed),xd=0;wd.length>xd;)(md=wd[xd++])in rd||Dl(rd,md,ed[md]);bd.constructor=rd}ql&&Gl(od)!==id&&ql(od,id);var Td=new nd(new rd(2)),Sd=od.setInt8;Td.setInt8(0,2147483648),Td.setInt8(1,2147483649),!Td.getInt8(0)&&Td.getInt8(1)||Bl(od,{setInt8:function(t,e){Sd.call(this,t,e<<24>>24)},setUint8:function(t,e){Sd.call(this,t,e<<24>>24)}},{unsafe:!0})}else rd=function(t){zl(this,rd,Xl);var e=Yl(t);Jl(this,{bytes:Hl.call(new Array(e),0),byteLength:e}),Ll||(this.byteLength=e)},nd=function(t,e,r){zl(this,nd,Zl),zl(t,rd,Zl);var n=Ql(t).byteLength,o=Ul(e);if(o<0||o>n)throw ad("Wrong offset");if(o+(r=void 0===r?n-o:Nl(r))>n)throw ad("Wrong length");Jl(this,{buffer:t,byteLength:r,byteOffset:o}),Ll||(this.buffer=t,this.byteLength=r,this.byteOffset=o)},Ll&&(vd(rd,"byteLength"),vd(nd,"buffer"),vd(nd,"byteLength"),vd(nd,"byteOffset")),Bl(nd.prototype,{getInt8:function(t){return yd(this,1,t)[0]<<24>>24},getUint8:function(t){return yd(this,1,t)[0]},getInt16:function(t){var e=yd(this,2,t,arguments.length>1?arguments[1]:void 0);return(e[1]<<8|e[0])<<16>>16},getUint16:function(t){var e=yd(this,2,t,arguments.length>1?arguments[1]:void 0);return e[1]<<8|e[0]},getInt32:function(t){return dd(yd(this,4,t,arguments.length>1?arguments[1]:void 0))},getUint32:function(t){return dd(yd(this,4,t,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(t){return cd(yd(this,4,t,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(t){return cd(yd(this,8,t,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(t,e){gd(this,1,t,sd,e)},setUint8:function(t,e){gd(this,1,t,sd,e)},setInt16:function(t,e){gd(this,2,t,fd,e,arguments.length>2?arguments[2]:void 0)},setUint16:function(t,e){gd(this,2,t,fd,e,arguments.length>2?arguments[2]:void 0)},setInt32:function(t,e){gd(this,4,t,ld,e,arguments.length>2?arguments[2]:void 0)},setUint32:function(t,e){gd(this,4,t,ld,e,arguments.length>2?arguments[2]:void 0)},setFloat32:function(t,e){gd(this,4,t,hd,e,arguments.length>2?arguments[2]:void 0)},setFloat64:function(t,e){gd(this,8,t,pd,e,arguments.length>2?arguments[2]:void 0)}});Kl(rd,Xl),Kl(nd,Zl);var kd={ArrayBuffer:rd,DataView:nd},Od=j,Ad=Math.floor,_d=Fe,Ed=function(t){var e=_d(t);if(e<0)throw RangeError("The argument can't be less than 0");return e},jd=function(t,e){var r=Ed(t);if(r%e)throw RangeError("Wrong offset");return r},Rd=rt,Id=Ne,Cd=Ia,Pd=_a,Ld=Lr,Md=hl.aTypedArrayConstructor,Dd=j,Bd=Xo,Fd=Ir,zd=s,Ud=d,Nd=wl,Yd=hl,Vd=kd,Gd=sa,qd=b,$d=Qt,Wd=function(t){return!Od(t)&&isFinite(t)&&Ad(t)===t},Hd=Ne,Kd=Sl,Qd=jd,Jd=Ot,Xd=it,Zd=Ri,th=j,eh=$,rh=yn,nh=Xo,oh=Me.f,ih=function(t){var e,r,n,o,i,a,u=Rd(t),c=arguments.length,s=c>1?arguments[1]:void 0,f=void 0!==s,l=Cd(u);if(null!=l&&!Pd(l))for(a=(i=l.call(u)).next,u=[];!(o=a.call(i)).done;)u.push(o.value);for(f&&c>2&&(s=Ld(s,arguments[2],2)),r=Id(u.length),n=new(Md(this))(r),e=0;r>e;e++)n[e]=f?s(u[e],e):u[e];return n},ah=Kr.forEach,uh=ou,ch=Ut,sh=f,fh=function(t,e,r){var n,o;return Bd&&"function"==typeof(n=e.constructor)&&n!==r&&Dd(o=n.prototype)&&o!==r.prototype&&Bd(t,o),t},lh=Ae.get,dh=Ae.set,hh=ch.f,ph=sh.f,vh=Math.round,yh=zd.RangeError,gh=Vd.ArrayBuffer,mh=Vd.DataView,bh=Yd.NATIVE_ARRAY_BUFFER_VIEWS,wh=Yd.TYPED_ARRAY_CONSTRUCTOR,xh=Yd.TYPED_ARRAY_TAG,Th=Yd.TypedArray,Sh=Yd.TypedArrayPrototype,kh=Yd.aTypedArrayConstructor,Oh=Yd.isTypedArray,Ah="BYTES_PER_ELEMENT",_h="Wrong length",Eh=function(t,e){for(var r=0,n=e.length,o=new(kh(t))(n);n>r;)o[r]=e[r++];return o},jh=function(t,e){hh(t,e,{get:function(){return lh(this)[e]}})},Rh=function(t){var e;return t instanceof gh||"ArrayBuffer"==(e=Zd(t))||"SharedArrayBuffer"==e},Ih=function(t,e){return Oh(t)&&!eh(e)&&e in t&&Wd(+e)&&e>=0},Ch=function(t,e){return e=Jd(e),Ih(t,e)?qd(2,t[e]):ph(t,e)},Ph=function(t,e,r){return e=Jd(e),!(Ih(t,e)&&th(r)&&Xd(r,"value"))||Xd(r,"get")||Xd(r,"set")||r.configurable||Xd(r,"writable")&&!r.writable||Xd(r,"enumerable")&&!r.enumerable?hh(t,e,r):(t[e]=r.value,t)};Ud?(bh||(sh.f=Ch,ch.f=Ph,jh(Sh,"buffer"),jh(Sh,"byteOffset"),jh(Sh,"byteLength"),jh(Sh,"length")),Fd({target:"Object",stat:!0,forced:!bh},{getOwnPropertyDescriptor:Ch,defineProperty:Ph}),Df.exports=function(t,e,r){var n=t.match(/\d+$/)[0]/8,o=t+(r?"Clamped":"")+"Array",i="get"+t,a="set"+t,u=zd[o],c=u,s=c&&c.prototype,f={},l=function(t,e){hh(t,e,{get:function(){return function(t,e){var r=lh(t);return r.view[i](e*n+r.byteOffset,!0)}(this,e)},set:function(t){return function(t,e,o){var i=lh(t);r&&(o=(o=vh(o))<0?0:o>255?255:255&o),i.view[a](e*n+i.byteOffset,o,!0)}(this,e,t)},enumerable:!0})};bh?Nd&&(c=e((function(t,e,r,i){return Gd(t,c,o),fh(th(e)?Rh(e)?void 0!==i?new u(e,Qd(r,n),i):void 0!==r?new u(e,Qd(r,n)):new u(e):Oh(e)?Eh(c,e):ih.call(c,e):new u(Kd(e)),t,c)})),nh&&nh(c,Th),ah(oh(u),(function(t){t in c||$d(c,t,u[t])})),c.prototype=s):(c=e((function(t,e,r,i){Gd(t,c,o);var a,u,s,f=0,d=0;if(th(e)){if(!Rh(e))return Oh(e)?Eh(c,e):ih.call(c,e);a=e,d=Qd(r,n);var h=e.byteLength;if(void 0===i){if(h%n)throw yh(_h);if((u=h-d)<0)throw yh(_h)}else if((u=Hd(i)*n)+d>h)throw yh(_h);s=u/n}else s=Kd(e),a=new gh(u=s*n);for(dh(t,{buffer:a,byteOffset:d,byteLength:u,length:s,view:new mh(a)});f<s;)l(t,f++)})),nh&&nh(c,Th),s=c.prototype=rh(Sh)),s.constructor!==c&&$d(s,"constructor",c),$d(s,wh,c),xh&&$d(s,xh,o),f[o]=c,Fd({global:!0,forced:c!=u,sham:!bh},f),Ah in c||$d(c,Ah,n),Ah in s||$d(s,Ah,n),uh(o)}):Df.exports=function(){},(0,Df.exports)("Uint8",(function(t){return function(e,r,n){return t(this,e,r,n)}}));var Lh=rt,Mh=qe,Dh=Ne,Bh=Math.min,Fh=[].copyWithin||function(t,e){var r=Lh(this),n=Dh(r.length),o=Mh(t,n),i=Mh(e,n),a=arguments.length>2?arguments[2]:void 0,u=Bh((void 0===a?n:Mh(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]:delete r[o],o+=c,i+=c;return r},zh=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("copyWithin",(function(t,e){return Fh.call(zh(this),t,e,arguments.length>2?arguments[2]:void 0)}));var Uh=Kr.every,Nh=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("every",(function(t){return Uh(Nh(this),t,arguments.length>1?arguments[1]:void 0)}));var Yh=Cl,Vh=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("fill",(function(t){return Yh.apply(Vh(this),arguments)}));var Gh=ku,qh=hl.TYPED_ARRAY_CONSTRUCTOR,$h=hl.aTypedArrayConstructor,Wh=function(t){return $h(Gh(t,t[qh]))},Hh=function(t,e){for(var r=0,n=e.length,o=new t(n);n>r;)o[r]=e[r++];return o},Kh=Wh,Qh=Kr.filter,Jh=function(t,e){return Hh(Kh(t),e)},Xh=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("filter",(function(t){var e=Qh(Xh(this),t,arguments.length>1?arguments[1]:void 0);return Jh(this,e)}));var Zh=Kr.find,tp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("find",(function(t){return Zh(tp(this),t,arguments.length>1?arguments[1]:void 0)}));var ep=Kr.findIndex,rp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("findIndex",(function(t){return ep(rp(this),t,arguments.length>1?arguments[1]:void 0)}));var np=Kr.forEach,op=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("forEach",(function(t){np(op(this),t,arguments.length>1?arguments[1]:void 0)}));var ip=Qe.includes,ap=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("includes",(function(t){return ip(ap(this),t,arguments.length>1?arguments[1]:void 0)}));var up=Qe.indexOf,cp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("indexOf",(function(t){return up(cp(this),t,arguments.length>1?arguments[1]:void 0)}));var sp=s,fp=hl,lp=Si,dp=mt("iterator"),hp=sp.Uint8Array,pp=lp.values,vp=lp.keys,yp=lp.entries,gp=fp.aTypedArray,mp=fp.exportTypedArrayMethod,bp=hp&&hp.prototype[dp],wp=!!bp&&("values"==bp.name||null==bp.name),xp=function(){return pp.call(gp(this))};mp("entries",(function(){return yp.call(gp(this))})),mp("keys",(function(){return vp.call(gp(this))})),mp("values",xp,!wp),mp(dp,xp,!wp);var Tp=hl.aTypedArray,Sp=[].join;(0,hl.exportTypedArrayMethod)("join",(function(t){return Sp.apply(Tp(this),arguments)}));var kp=E,Op=Fe,Ap=Ne,_p=Ya,Ep=Math.min,jp=[].lastIndexOf,Rp=!!jp&&1/[1].lastIndexOf(1,-0)<0,Ip=_p("lastIndexOf"),Cp=Rp||!Ip?function(t){if(Rp)return jp.apply(this,arguments)||0;var e=kp(this),r=Ap(e.length),n=r-1;for(arguments.length>1&&(n=Ep(n,Op(arguments[1]))),n<0&&(n=r+n);n>=0;n--)if(n in e&&e[n]===t)return n||0;return-1}:jp,Pp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("lastIndexOf",(function(t){return Cp.apply(Pp(this),arguments)}));var Lp=Kr.map,Mp=Wh,Dp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("map",(function(t){return Lp(Dp(this),t,arguments.length>1?arguments[1]:void 0,(function(t,e){return new(Mp(t))(e)}))}));var Bp=Cr,Fp=rt,zp=k,Up=Ne,Np=function(t){return function(e,r,n,o){Bp(r);var i=Fp(e),a=zp(i),u=Up(i.length),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 TypeError("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}},Yp={left:Np(!1),right:Np(!0)},Vp=Yp.left,Gp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("reduce",(function(t){return Vp(Gp(this),t,arguments.length,arguments.length>1?arguments[1]:void 0)}));var qp=Yp.right,$p=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("reduceRight",(function(t){return qp($p(this),t,arguments.length,arguments.length>1?arguments[1]:void 0)}));var Wp=hl.aTypedArray,Hp=hl.exportTypedArrayMethod,Kp=Math.floor;Hp("reverse",(function(){for(var t,e=this,r=Wp(e).length,n=Kp(r/2),o=0;o<n;)t=e[o],e[o++]=e[--r],e[r]=t;return e}));var Qp=Ne,Jp=jd,Xp=rt,Zp=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("set",(function(t){Zp(this);var e=Jp(arguments.length>1?arguments[1]:void 0,1),r=this.length,n=Xp(t),o=Qp(n.length),i=0;if(o+e>r)throw RangeError("Wrong length");for(;i<o;)this[e+i]=n[i++]}),l((function(){new Int8Array(1).set({})})));var tv=Wh,ev=hl.aTypedArray,rv=[].slice;(0,hl.exportTypedArrayMethod)("slice",(function(t,e){for(var r=rv.call(ev(this),t,e),n=tv(this),o=0,i=r.length,a=new n(i);i>o;)a[o]=r[o++];return a}),l((function(){new Int8Array(1).slice()})));var nv=Kr.some,ov=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("some",(function(t){return nv(ov(this),t,arguments.length>1?arguments[1]:void 0)}));var iv=Math.floor,av=function(t,e){var r=t.length,n=iv(r/2);return r<8?uv(t,e):cv(av(t.slice(0,n),e),av(t.slice(n),e),e)},uv=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},cv=function(t,e,r){for(var n=t.length,o=e.length,i=0,a=0,u=[];i<n||a<o;)i<n&&a<o?u.push(r(t[i],e[a])<=0?t[i++]:e[a++]):u.push(i<n?t[i++]:e[a++]);return u},sv=av,fv=P.match(/firefox\/(\d+)/i),lv=!!fv&&+fv[1],dv=/MSIE|Trident/.test(P),hv=P.match(/AppleWebKit\/(\d+)\./),pv=!!hv&&+hv[1],vv=l,yv=Cr,gv=Ne,mv=sv,bv=lv,wv=dv,xv=U,Tv=pv,Sv=hl.aTypedArray,kv=hl.exportTypedArrayMethod,Ov=s.Uint16Array,Av=Ov&&Ov.prototype.sort,_v=!!Av&&!vv((function(){var t=new Ov(2);t.sort(null),t.sort({})})),Ev=!!Av&&!vv((function(){if(xv)return xv<74;if(bv)return bv<67;if(wv)return!0;if(Tv)return Tv<602;var t,e,r=new Ov(516),n=Array(516);for(t=0;t<516;t++)e=t%4,r[t]=515-t,n[t]=t-2*e+3;for(r.sort((function(t,e){return(t/4|0)-(e/4|0)})),t=0;t<516;t++)if(r[t]!==n[t])return!0}));kv("sort",(function(t){var e=this;if(void 0!==t&&yv(t),Ev)return Av.call(e,t);Sv(e);var r,n=gv(e.length),o=Array(n);for(r=0;r<n;r++)o[r]=e[r];for(o=mv(e,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)),r=0;r<n;r++)e[r]=o[r];return e}),!Ev||_v);var jv=Ne,Rv=qe,Iv=Wh,Cv=hl.aTypedArray;(0,hl.exportTypedArrayMethod)("subarray",(function(t,e){var r=Cv(this),n=r.length,o=Rv(t,n);return new(Iv(r))(r.buffer,r.byteOffset+o*r.BYTES_PER_ELEMENT,jv((void 0===e?n:Rv(e,n))-o))}));var Pv=hl,Lv=l,Mv=s.Int8Array,Dv=Pv.aTypedArray,Bv=Pv.exportTypedArrayMethod,Fv=[].toLocaleString,zv=[].slice,Uv=!!Mv&&Lv((function(){Fv.call(new Mv(1))}));Bv("toLocaleString",(function(){return Fv.apply(Uv?zv.call(Dv(this)):Dv(this),arguments)}),Lv((function(){return[1,2].toLocaleString()!=new Mv([1,2]).toLocaleString()}))||!Lv((function(){Mv.prototype.toLocaleString.call([1,2])})));var Nv=hl.exportTypedArrayMethod,Yv=l,Vv=s.Uint8Array,Gv=Vv&&Vv.prototype||{},qv=[].toString,$v=[].join;Yv((function(){qv.call({})}))&&(qv=function(){return $v.call(this)});var Wv=Gv.toString!=qv;Nv("toString",qv,Wv);var Hv="fetch",Kv="xhr",Qv="arraybuffer",Jv="text",Xv="json";function Zv(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function(){var r,n=go(t);if(e){var o=go(this).constructor;r=Reflect.construct(n,arguments,o)}else r=n.apply(this,arguments);return yo(this,r)}}var ty=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ho(t,e)}(r,t);var e=Zv(r);function r(t,o,i,u){var c;return n(this,r),a(vo(c=e.call(this,u)),"retryCount",0),a(vo(c),"isTimeout",!1),a(vo(c),"loaderType",Hv),a(vo(c),"startTime",0),a(vo(c),"endTime",0),c.url=t,c.request=o,c.response=i,c}return r}(wo(Error)),ey=Jt.exports,ry=af,ny=l,oy=mt,iy=Qt,ay=oy("species"),uy=RegExp.prototype,cy=function(t,e,r,n){var o=oy(t),i=!ny((function(){var e={};return e[o]=function(){return 7},7!=""[t](e)})),a=i&&!ny((function(){var e=!1,r=/a/;return"split"===t&&((r={}).constructor={},r.constructor[ay]=function(){return r},r.flags="",r[o]=/./[o]),r.exec=function(){return e=!0,null},r[o](""),!e}));if(!i||!a||r){var u=/./[o],c=e(o,""[t],(function(t,e,r,n,o){var a=e.exec;return a===ry||a===uy.exec?i&&!o?{done:!0,value:u.call(e,r,n)}:{done:!0,value:t.call(r,e,n)}:{done:!1}}));ey(String.prototype,t,c[0]),ey(uy,o,c[1])}n&&iy(uy[o],"sham",!0)},sy=Yi.charAt,fy=function(t,e,r){return e+(r?sy(t,e).length:1)},ly=rt,dy=Math.floor,hy="".replace,py=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,vy=/\$([$&'`]|\d{1,2})/g,yy=x,gy=af,my=function(t,e){var r=t.exec;if("function"==typeof r){var n=r.call(t,e);if("object"!=typeof n)throw TypeError("RegExp exec method returned something other than an Object or null");return n}if("RegExp"!==yy(t))throw TypeError("RegExp#exec called on incompatible receiver");return gy.call(t,e)},by=cy,wy=l,xy=Yt,Ty=Fe,Sy=Ne,ky=Bi,Oy=O,Ay=fy,_y=function(t,e,r,n,o,i){var a=r+t.length,u=n.length,c=vy;return void 0!==o&&(o=ly(o),c=py),hy.call(i,c,(function(i,c){var s;switch(c.charAt(0)){case"$":return"$";case"&":return t;case"`":return e.slice(0,r);case"'":return e.slice(a);case"<":s=o[c.slice(1,-1)];break;default:var f=+c;if(0===f)return i;if(f>u){var l=dy(f/10);return 0===l?i:l<=u?void 0===n[l-1]?c.charAt(1):n[l-1]+c.charAt(1):i}s=n[f-1]}return void 0===s?"":s}))},Ey=my,jy=mt("replace"),Ry=Math.max,Iy=Math.min,Cy="$0"==="a".replace(/./,"$0"),Py=!!/./[jy]&&""===/./[jy]("a","$0");by("replace",(function(t,e,r){var n=Py?"$":"$0";return[function(t,r){var n=Oy(this),o=null==t?void 0:t[jy];return void 0!==o?o.call(t,n,r):e.call(ky(n),t,r)},function(t,o){var i=xy(this),a=ky(t);if("string"==typeof o&&-1===o.indexOf(n)&&-1===o.indexOf("$<")){var u=r(e,i,a,o);if(u.done)return u.value}var c="function"==typeof o;c||(o=ky(o));var s=i.global;if(s){var f=i.unicode;i.lastIndex=0}for(var l=[];;){var d=Ey(i,a);if(null===d)break;if(l.push(d),!s)break;""===ky(d[0])&&(i.lastIndex=Ay(a,Sy(i.lastIndex),f))}for(var h,p="",v=0,y=0;y<l.length;y++){d=l[y];for(var g=ky(d[0]),m=Ry(Iy(Ty(d.index),a.length),0),b=[],w=1;w<d.length;w++)b.push(void 0===(h=d[w])?h:String(h));var x=d.groups;if(c){var T=[g].concat(b,m,a);void 0!==x&&T.push(x);var S=ky(o.apply(void 0,T))}else S=_y(g,a,m,b,x,o);m>=v&&(p+=a.slice(v,m)+S,v=m+g.length)}return p+a.slice(v)}]}),!!wy((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")}))||!Cy||Py);var Ly=Ir,My=E,Dy=[].join,By=k!=Object,Fy=Ya("join",",");Ly({target:"Array",proto:!0,forced:By||!Fy},{join:function(t){return Dy.call(My(this),void 0===t?",":t)}});var zy=Kr.filter;Ir({target:"Array",proto:!0,forced:!Ln("filter")},{filter:function(t){return zy(this,t,arguments.length>1?arguments[1]:void 0)}});var Uy=rt,Ny=Io,Yy=Oo;Ir({target:"Object",stat:!0,forced:l((function(){Ny(1)})),sham:!Yy},{getPrototypeOf:function(t){return Ny(Uy(t))}});var Vy=Object.prototype.toString;function Gy(t){if("[object Object]"!==Vy.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function qy(t){if(t&&null!=t[0]&&(0!==t[0]||null!=t[1])){var e="bytes="+t[0]+"-";return t[1]&&(e+=t[1]),e}}function $y(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Wy(t,e){if(t){if(!e)return t;var r,n=Object.keys(e).map((function(t){if(null!=(r=e[t]))return Array.isArray(r)?t+="[]":r=[r],r.map((function(e){var r;return r=e,"[object Date]"===Vy.call(r)?e=e.toISOString():function(t){return null!==t&&"object"===po(t)}(e)&&(e=JSON.stringify(e)),"".concat($y(t),"=").concat($y(e))})).join("&")})).filter(Boolean).join("&");if(n){var o=t.indexOf("#");-1!==o&&(t=t.slice(0,o)),t+=(-1===t.indexOf("?")?"?":"&")+n}return t}}function Hy(t,e,r,n,o,i){return n=null!=n?parseFloat(n):null,r=parseInt(r||"0",10),isNaN(r)&&(r=0),{data:t,response:e,contentLength:r,age:n,startTime:o,firstByteTime:i,endTime:Date.now()}}var Ky=function(){function t(){n(this,t),a(this,"_abortController",null),a(this,"_timeoutTimer",null),a(this,"_reader",null),a(this,"_response",null),a(this,"_aborted",!1)}var r;return i(t,[{key:"load",value:function(t){var r=this,n=t.url,o=t.timeout,i=t.responseType,a=t.onProgress,u=t.onTimeout,c=t.range,s=t.transformResponse,f=t.request,l=t.params,d=t.method,h=t.headers,p=t.body,v=t.mode,y=t.credentials,g=t.cache,m=t.redirect,b=t.referrer,w=t.referrerPolicy,x=t.integrity;this._aborted=!1,this._abortController=new AbortController;var T={method:d,headers:h,body:p,mode:v,credentials:y,cache:g,redirect:m,referrer:b,referrerPolicy:w,integrity:x,signal:this._abortController.signal},S=!1;clearTimeout(this._timeoutTimer),n=Wy(n,l);var k=qy(c);k&&((h=f?f.headers:T.headers=T.headers||new Headers)instanceof Headers?h.append("Range",k):h.Range=k),o&&(this._timeoutTimer=setTimeout((function(){if(S=!0,r.cancel(),u){var t=new ty(n,T);t.isTimeout=!0,u(t)}}),o));var O=Date.now();return fetch(f||n,f?void 0:T).then(function(){var t=e(Hn.mark((function t(e){var o,u;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(clearTimeout(r._timeoutTimer),r._response=e,!r._aborted){t.next=4;break}return t.abrupt("return");case 4:if(s&&(e=s(e,n)||e),e.ok){t.next=7;break}throw new ty(n,T,e,"bad network response");case 7:if(o=Date.now(),i!==Jv){t.next=14;break}return t.next=11,e.text();case 11:u=t.sent,t.next=28;break;case 14:if(i!==Xv){t.next=20;break}return t.next=17,e.json();case 17:u=t.sent,t.next=28;break;case 20:if(!a){t.next=24;break}r._loadChunk(e,a),t.next=28;break;case 24:return t.next=26,e.arrayBuffer();case 26:u=t.sent,u=new Uint8Array(u);case 28:return t.abrupt("return",Hy(u,e,e.headers.get("Content-Length"),e.headers.get("age"),O,o));case 29:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){if(clearTimeout(r._timeoutTimer),!r._aborted||S)throw(t=t instanceof ty?t:new ty(n,T)).startTime=O,t.endTime=Date.now(),t.isTimeout=S,t}))}},{key:"cancel",value:(r=e(Hn.mark((function t(){return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!this._aborted){t.next=2;break}return t.abrupt("return");case 2:if(this._aborted=!0,!this._response){t.next=15;break}return t.prev=4,t.next=7,this._response.body.cancel();case 7:if(!this._reader){t.next=10;break}return t.next=10,this._reader.cancel();case 10:t.next=14;break;case 12:t.prev=12,t.t0=t.catch(4);case 14:this._response=this._reader=null;case 15:if(this._abortController){try{this._abortController.abort()}catch(t){}this._abortController=null}case 16:case"end":return t.stop()}}),t,this,[[4,12]])}))),function(){return r.apply(this,arguments)})},{key:"_loadChunk",value:function(t,r){var n,o,i,a=this,u=this._reader=t.body.getReader(),c=function(){var s=e(Hn.mark((function e(){return Hn.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=Date.now(),e.prev=1,e.next=4,u.read();case 4:n=e.sent,i=Date.now(),e.next=13;break;case 8:return e.prev=8,e.t0=e.catch(1),i=Date.now(),r(void 0,!0,{startTime:o,endTime:i},t),e.abrupt("return");case 13:if(!a._aborted){e.next=16;break}return r(void 0,!0,{startTime:o,endTime:i},t),e.abrupt("return");case 16:r(n.value,n.done,{startTime:o,endTime:i},t),n.done||c();case 18:case"end":return e.stop()}}),e,null,[[1,8]])})));return function(){return s.apply(this,arguments)}}();c()}}],[{key:"isSupported",value:function(){if("undefined"==typeof ReadableStream)return!1;try{new ReadableStream({})}catch(t){return!1}return!("undefined"==typeof fetch||"undefined"==typeof AbortController)}}]),t}(),Qy={},Jy=E,Xy=Me.f,Zy={}.toString,tg="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];Qy.f=function(t){return tg&&"[object Window]"==Zy.call(t)?function(t){try{return Xy(t)}catch(t){return tg.slice()}}(t):Xy(Jy(t))};var eg={},rg=mt;eg.f=rg;var ng=s,og=it,ig=eg,ag=Ut.f,ug=function(t){var e=ng.Symbol||(ng.Symbol={});og(e,t)||ag(e,t,{value:ig.f(t)})},cg=Ir,sg=s,fg=C,lg=d,dg=V,hg=l,pg=it,vg=Dr,yg=j,gg=$,mg=Yt,bg=rt,wg=E,xg=Ot,Tg=Bi,Sg=b,kg=yn,Og=Xr,Ag=Me,_g=Qy,Eg=ir,jg=f,Rg=Ut,Ig=h,Cg=Qt,Pg=Jt.exports,Lg=H.exports,Mg=le,Dg=ct,Bg=mt,Fg=eg,zg=ug,Ug=Yo,Ng=Ae,Yg=Kr.forEach,Vg=fe("hidden"),Gg="Symbol",qg=Bg("toPrimitive"),$g=Ng.set,Wg=Ng.getterFor(Gg),Hg=Object.prototype,Kg=sg.Symbol,Qg=fg("JSON","stringify"),Jg=jg.f,Xg=Rg.f,Zg=_g.f,tm=Ig.f,em=Lg("symbols"),rm=Lg("op-symbols"),nm=Lg("string-to-symbol-registry"),om=Lg("symbol-to-string-registry"),im=Lg("wks"),am=sg.QObject,um=!am||!am.prototype||!am.prototype.findChild,cm=lg&&hg((function(){return 7!=kg(Xg({},"a",{get:function(){return Xg(this,"a",{value:7}).a}})).a}))?function(t,e,r){var n=Jg(Hg,e);n&&delete Hg[e],Xg(t,e,r),n&&t!==Hg&&Xg(Hg,e,n)}:Xg,sm=function(t,e){var r=em[t]=kg(Kg.prototype);return $g(r,{type:Gg,tag:t,description:e}),lg||(r.description=e),r},fm=function(t,e,r){t===Hg&&fm(rm,e,r),mg(t);var n=xg(e);return mg(r),pg(em,n)?(r.enumerable?(pg(t,Vg)&&t[Vg][n]&&(t[Vg][n]=!1),r=kg(r,{enumerable:Sg(0,!1)})):(pg(t,Vg)||Xg(t,Vg,Sg(1,{})),t[Vg][n]=!0),cm(t,n,r)):Xg(t,n,r)},lm=function(t,e){mg(t);var r=wg(e),n=Og(r).concat(vm(r));return Yg(n,(function(e){lg&&!dm.call(r,e)||fm(t,e,r[e])})),t},dm=function(t){var e=xg(t),r=tm.call(this,e);return!(this===Hg&&pg(em,e)&&!pg(rm,e))&&(!(r||!pg(this,e)||!pg(em,e)||pg(this,Vg)&&this[Vg][e])||r)},hm=function(t,e){var r=wg(t),n=xg(e);if(r!==Hg||!pg(em,n)||pg(rm,n)){var o=Jg(r,n);return!o||!pg(em,n)||pg(r,Vg)&&r[Vg][n]||(o.enumerable=!0),o}},pm=function(t){var e=Zg(wg(t)),r=[];return Yg(e,(function(t){pg(em,t)||pg(Mg,t)||r.push(t)})),r},vm=function(t){var e=t===Hg,r=Zg(e?rm:wg(t)),n=[];return Yg(r,(function(t){!pg(em,t)||e&&!pg(Hg,t)||n.push(em[t])})),n};(dg||(Pg((Kg=function(){if(this instanceof Kg)throw TypeError("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?Tg(arguments[0]):void 0,e=Dg(t),r=function(t){this===Hg&&r.call(rm,t),pg(this,Vg)&&pg(this[Vg],e)&&(this[Vg][e]=!1),cm(this,e,Sg(1,t))};return lg&&um&&cm(Hg,e,{configurable:!0,set:r}),sm(e,t)}).prototype,"toString",(function(){return Wg(this).tag})),Pg(Kg,"withoutSetter",(function(t){return sm(Dg(t),t)})),Ig.f=dm,Rg.f=fm,jg.f=hm,Ag.f=_g.f=pm,Eg.f=vm,Fg.f=function(t){return sm(Bg(t),t)},lg&&(Xg(Kg.prototype,"description",{configurable:!0,get:function(){return Wg(this).description}}),Pg(Hg,"propertyIsEnumerable",dm,{unsafe:!0}))),cg({global:!0,wrap:!0,forced:!dg,sham:!dg},{Symbol:Kg}),Yg(Og(im),(function(t){zg(t)})),cg({target:Gg,stat:!0,forced:!dg},{for:function(t){var e=Tg(t);if(pg(nm,e))return nm[e];var r=Kg(e);return nm[e]=r,om[r]=e,r},keyFor:function(t){if(!gg(t))throw TypeError(t+" is not a symbol");if(pg(om,t))return om[t]},useSetter:function(){um=!0},useSimple:function(){um=!1}}),cg({target:"Object",stat:!0,forced:!dg,sham:!lg},{create:function(t,e){return void 0===e?kg(t):lm(kg(t),e)},defineProperty:fm,defineProperties:lm,getOwnPropertyDescriptor:hm}),cg({target:"Object",stat:!0,forced:!dg},{getOwnPropertyNames:pm,getOwnPropertySymbols:vm}),cg({target:"Object",stat:!0,forced:hg((function(){Eg.f(1)}))},{getOwnPropertySymbols:function(t){return Eg.f(bg(t))}}),Qg)&&cg({target:"JSON",stat:!0,forced:!dg||hg((function(){var t=Kg();return"[null]"!=Qg([t])||"{}"!=Qg({a:t})||"{}"!=Qg(Object(t))}))},{stringify:function(t,e,r){for(var n,o=[t],i=1;arguments.length>i;)o.push(arguments[i++]);if(n=e,(yg(e)||void 0!==t)&&!gg(t))return vg(e)||(e=function(t,e){if("function"==typeof n&&(e=n.call(this,t,e)),!gg(e))return e}),o[1]=e,Qg.apply(null,o)}});Kg.prototype[qg]||Cg(Kg.prototype,qg,Kg.prototype.valueOf),Ug(Kg,Gg),Mg[Vg]=!0;var ym=Ir,gm=l,mm=E,bm=f.f,wm=d,xm=gm((function(){bm(1)}));ym({target:"Object",stat:!0,forced:!wm||xm,sham:!wm},{getOwnPropertyDescriptor:function(t,e){return bm(mm(t),e)}});var Tm=fr,Sm=E,km=f,Om=Rn;function Am(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 _m(t){return function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Am(Object(r),!0).forEach((function(e){a(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Am(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}({loaderType:Hv,retry:0,retryDelay:0,timeout:0,request:null,onTimeout:void 0,onProgress:void 0,onRetryError:void 0,transformRequest:void 0,transformResponse:void 0,transformError:void 0,responseType:Jv,range:void 0,url:"",params:void 0,method:"GET",headers:{},body:void 0,mode:void 0,credentials:void 0,cache:void 0,redirect:void 0,referrer:void 0,referrerPolicy:void 0,integrity:void 0},t)}Ir({target:"Object",stat:!0,sham:!d},{getOwnPropertyDescriptors:function(t){for(var e,r,n=Sm(t),o=km.f,i=Tm(n),a={},u=0;i.length>u;)void 0!==(r=o(n,e=i[u++]))&&Om(a,e,r);return a}});var Em=d,jm=Ut.f,Rm=Function.prototype,Im=Rm.toString,Cm=/^\s*function ([^ (]*)/,Pm="name";Em&&!(Pm in Rm)&&jm(Rm,Pm,{configurable:!0,get:function(){try{return Im.call(this).match(Cm)[1]}catch(t){return""}}});var Lm=function(t){var e,r,n,o,i,a,u=Pa(t),c="function"==typeof this?this:Array,s=arguments.length,f=s>1?arguments[1]:void 0,l=void 0!==f,d=Fa(u),h=0;if(l&&(f=Ca(f,s>2?arguments[2]:void 0,2)),null==d||c==Array&&Ma(d))for(r=new c(e=Da(u.length));e>h;h++)a=l?f(u[h],h):u[h],Ba(r,h,a);else for(i=(o=d.call(u)).next,r=new c;!(n=i.call(o)).done;h++)a=l?La(o,f,[n.value,h],!0):n.value,Ba(r,h,a);return r.length=h,r};Ir({target:"Array",stat:!0,forced:!wu((function(t){Array.from(t)}))},{from:Lm});var Mm=Ir,Dm=d,Bm=s,Fm=it,zm=j,Um=Ut.f,Nm=vr,Ym=Bm.Symbol;if(Dm&&"function"==typeof Ym&&(!("description"in Ym.prototype)||void 0!==Ym().description)){var Vm={},Gm=function(){var t=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),e=this instanceof Gm?new Ym(t):void 0===t?Ym():Ym(t);return""===t&&(Vm[e]=!0),e};Nm(Gm,Ym);var qm=Gm.prototype=Ym.prototype;qm.constructor=Gm;var $m=qm.toString,Wm="Symbol(test)"==String(Ym("test")),Hm=/^Symbol\((.*)\)[^)]+$/;Um(qm,"description",{configurable:!0,get:function(){var t=zm(this)?this.valueOf():this,e=$m.call(t);if(Fm(Vm,t))return"";var r=Wm?e.slice(7,-1):e.replace(Hm,"$1");return""===r?void 0:r}}),Mm({global:!0,forced:!0},{Symbol:Gm})}ug("iterator");var Km=j,Qm=x,Jm=mt("match"),Xm=function(t){var e;return Km(t)&&(void 0!==(e=t[Jm])?!!e:"RegExp"==Qm(t))},Zm=cy,tb=Xm,eb=Yt,rb=O,nb=ku,ob=fy,ib=Ne,ab=Bi,ub=my,cb=af,sb=l,fb=Ls.UNSUPPORTED_Y,lb=[].push,db=Math.min,hb=4294967295;Zm("split",(function(t,e,r){var n;return n="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,r){var n=ab(rb(this)),o=void 0===r?hb:r>>>0;if(0===o)return[];if(void 0===t)return[n];if(!tb(t))return e.call(n,t,o);for(var i,a,u,c=[],s=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),f=0,l=new RegExp(t.source,s+"g");(i=cb.call(l,n))&&!((a=l.lastIndex)>f&&(c.push(n.slice(f,i.index)),i.length>1&&i.index<n.length&&lb.apply(c,i.slice(1)),u=i[0].length,f=a,c.length>=o));)l.lastIndex===i.index&&l.lastIndex++;return f===n.length?!u&&l.test("")||c.push(""):c.push(n.slice(f)),c.length>o?c.slice(0,o):c}:"0".split(void 0,0).length?function(t,r){return void 0===t&&0===r?[]:e.call(this,t,r)}:e,[function(e,r){var o=rb(this),i=null==e?void 0:e[t];return void 0!==i?i.call(e,o,r):n.call(ab(o),e,r)},function(t,o){var i=eb(this),a=ab(t),u=r(n,i,a,o,n!==e);if(u.done)return u.value;var c=nb(i,RegExp),s=i.unicode,f=(i.ignoreCase?"i":"")+(i.multiline?"m":"")+(i.unicode?"u":"")+(fb?"g":"y"),l=new c(fb?"^(?:"+i.source+")":i,f),d=void 0===o?hb:o>>>0;if(0===d)return[];if(0===a.length)return null===ub(l,a)?[a]:[];for(var h=0,p=0,v=[];p<a.length;){l.lastIndex=fb?0:p;var y,g=ub(l,fb?a.slice(p):a);if(null===g||(y=db(ib(l.lastIndex+(fb?p:0)),a.length))===h)p=ob(a,p,s);else{if(v.push(a.slice(h,p)),v.length===d)return v;for(var m=1;m<=g.length-1;m++)if(v.push(g[m]),v.length===d)return v;p=h=y}}return v.push(a.slice(h)),v}]}),!!sb((function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var r="ab".split(t);return 2!==r.length||"a"!==r[0]||"b"!==r[1]})),fb);var pb="\t\n\v\f\r                 \u2028\u2029\ufeff",vb=O,yb=Bi,gb="[\t\n\v\f\r                 \u2028\u2029\ufeff]",mb=RegExp("^"+gb+gb+"*"),bb=RegExp(gb+gb+"*$"),wb=function(t){return function(e){var r=yb(vb(e));return 1&t&&(r=r.replace(mb,"")),2&t&&(r=r.replace(bb,"")),r}},xb={start:wb(1),end:wb(2),trim:wb(3)},Tb=l,Sb=pb,kb=xb.trim;function Ob(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return Ab(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ab(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){u=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw i}}}}function Ab(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}Ir({target:"String",proto:!0,forced:function(t){return Tb((function(){return!!Sb[t]()||"​…᠎"!="​…᠎"[t]()||Sb[t].name!==t}))}("trim")},{trim:function(){return kb(this)}});var _b=function(){function t(){n(this,t),a(this,"_xhr",null),a(this,"_aborted",!1),a(this,"_timeoutTimer",null)}return i(t,[{key:"load",value:function(t){var e=this;clearTimeout(this._timeoutTimer);var r=t.url,n=t.params,o=t.timeout,i=t.responseType,a=t.onTimeout,u=t.transformResponse,c=t.onProgress,s=t.method,f=t.credentials,l=t.body,d=t.headers,h=t.range,p=t.request,v=!1;r=Wy(r,n);var y=Date.now();return new Promise((function(t,n){var g=e._xhr=new XMLHttpRequest;g.open(s||"GET",r,!0),g.responseType=i,g.withCredentials="include"===f||"same-origin"===f;var m=qy(h);m&&((d=d||{}).Range=m),d&&Object.keys(d).forEach((function(t){g.setRequestHeader(t,d[t])})),o&&(e._timeoutTimer=setTimeout((function(){if(v=!0,e.cancel(),a){var t=new ty(r,p);t.isTimeout=!0,a(t)}}),o)),g.onerror=function(t){return n(t)},g.onreadystatechange=function(){if(g.readyState>=2){clearTimeout(e._timeoutTimer);var o=Date.now();if(4===g.readyState){if(g.onreadystatechange=null,e._aborted)return;var i=g.status,a={ok:i>=200&&i<300,status:i,statusText:g.statusText,url:g.responseURL,headers:e._getHeaders(g),body:g.response};if(u&&(a=u(a,r)||a),!a.ok)return n(new ty(r,p,a,"bad network response"));var s=g.responseType===Qv,f=s?new Uint8Array(g.response):g.response;c&&c(s?f:void 0,!0,{startTime:y,endTime:Date.now()},a),t(Hy(f,a,a.headers["content-length"],a.headers.age,y,o))}}},g.send(l)})).catch((function(t){if(clearTimeout(e._timeoutTimer),!e._aborted||v)throw(t=t instanceof ty?t:new ty(r,p)).startTime=y,t.endTime=Date.now(),t.isTimeout=v,t}))}},{key:"cancel",value:function(){if(!this._aborted)return this._aborted=!0,this._xhr?this._xhr.cancel():void 0}},{key:"_getHeaders",value:function(t){var e,r={},n=Ob(t.getAllResponseHeaders().trim().split("\r\n"));try{for(n.s();!(e=n.n()).done;){var o=e.value.split(": ");r[o[0].toLowerCase()]=o.slice(1).join(": ")}}catch(t){n.e(t)}finally{n.f()}return r}}],[{key:"isSupported",value:function(){return"undefined"!=typeof XMLHttpRequest}}]),t}(),Eb=["retry","retryDelay","onRetryError","transformError"],jb=function(){function t(e,r){n(this,t),this.promise=function(){var t,e,r=new Promise((function(r,n){t=r,e=n}));return r.used=!1,r.resolve=function(){return r.used=!0,t.apply(void 0,arguments)},r.reject=function(){return r.used=!0,e.apply(void 0,arguments)},r}(),this.alive=!!r.onProgress,this._loaderType=e,this._loader=e===Hv?new Ky:new _b,this._config=r,this._retryCount=0,this._retryTimer=null,this._canceled=!1}var o;return i(t,[{key:"exec",value:function(){var t=this,n=this._config,o=n.retry,i=n.retryDelay,a=n.onRetryError,u=n.transformError,c=r(n,Eb),s=function(){var r=e(Hn.mark((function e(){var r,n;return Hn.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,t._loader.load(c);case 3:r=e.sent,t.promise.resolve(r),e.next=22;break;case 7:if(e.prev=7,e.t0=e.catch(0),!t._canceled){e.next=11;break}return e.abrupt("return");case 11:if(e.t0.loaderType=t._loaderType,e.t0.retryCount=t._retryCount,n=e.t0,u&&(n=u(n)||n),a&&t._retryCount>0&&a(n,t._retryCount,o),t._retryCount++,!(t._retryCount<=o)){e.next=21;break}return clearTimeout(t._retryTimer),t._retryTimer=setTimeout(s,i),e.abrupt("return");case 21:t.promise.reject(n);case 22:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(){return r.apply(this,arguments)}}();return s(),this.promise}},{key:"cancel",value:(o=e(Hn.mark((function t(){return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return clearTimeout(this._retryTimer),this._canceled=!0,t.abrupt("return",this._loader.cancel());case 3:case"end":return t.stop()}}),t,this)}))),function(){return o.apply(this,arguments)})}]),t}(),Rb=function(){function t(e){n(this,t),a(this,"type",Hv),a(this,"_queue",[]),a(this,"_alive",[]),a(this,"_currentTask",null),this._config=_m(e),this._config.loaderType!==Kv&&Ky.isSupported()||(this.type=Kv)}return i(t,[{key:"isFetch",value:function(){return this.type===Hv}},{key:"load",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};"string"!=typeof t&&t?e=t:e.url=t||e.url||this._config.url,(e=Object.assign({},this._config,e)).params&&(e.params=Object.assign({},e.params)),e.headers&&Gy(e.headers)&&(e.headers=Object.assign({},e.headers)),e.body&&Gy(e.body)&&(e.body=Object.assign({},e.body)),e.transformRequest&&(e=e.transformRequest(e)||e);var r=new jb(this.type,e);return this._queue.push(r),1===this._queue.length&&this._processTask(),r.promise}},{key:"cancel",value:function(){var t=this._queue.map((function(t){return t.cancel()})).concat(this._alive.map((function(t){return t.cancel()})));return this._currentTask&&t.push(this._currentTask.cancel()),this._queue=[],this._alive=[],Promise.all(t)}},{key:"_processTask",value:function(){var t=this;this._currentTask=this._queue.shift(),this._currentTask&&(this._currentTask.alive&&this._alive.push(this._currentTask),this._currentTask.exec().finally((function(){t._processTask()})))}}],[{key:"isFetchSupport",value:function(){return Ky.isSupported()}}]),t}();function Ib(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];e=e.filter(Boolean);var n=new Uint8Array(e.reduce((function(t,e){return t+e.byteLength}),0)),o=0;return e.forEach((function(t){n.set(t,o),o+=t.byteLength})),n}var Cb=Qe.includes,Pb=xn;Ir({target:"Array",proto:!0},{includes:function(t){return Cb(this,t,arguments.length>1?arguments[1]:void 0)}}),Pb("includes");var Lb=Xm,Mb=mt("match"),Db=function(t){if(Lb(t))throw TypeError("The method doesn't accept regular expressions");return t},Bb=O,Fb=Bi;Ir({target:"String",proto:!0,forced:!function(t){var e=/./;try{"/./"[t](e)}catch(r){try{return e[Mb]=!1,"/./"[t](e)}catch(t){}}return!1}("includes")},{includes:function(t){return!!~Fb(Bb(this)).indexOf(Fb(Db(t)),arguments.length>1?arguments[1]:void 0)}});var zb="hevc",Ub=Jt.exports,Nb=Yt,Yb=Bi,Vb=l,Gb=Ps,qb="toString",$b=RegExp.prototype,Wb=$b.toString,Hb=Vb((function(){return"/a/b"!=Wb.call({source:"a",flags:"b"})})),Kb=Wb.name!=qb;(Hb||Kb)&&Ub(RegExp.prototype,qb,(function(){var t=Nb(this),e=Yb(t.source),r=t.flags;return"/"+e+"/"+Yb(void 0===r&&t instanceof RegExp&&!("flags"in $b)?Gb.call(t):r)}),{unsafe:!0});var Qb="undefined"!=typeof window,Jb=Qb&&navigator.userAgent.toLocaleLowerCase();Qb&&/^((?!chrome|android).)*safari/.test(Jb);var Xb=Qb&&Jb.includes("firefox"),Zb=Qb&&Jb.includes("android"),tw=Math.pow(2,32);function ew(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(t[e]<<8)+(t[e+1]||0)}function rw(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(t[e]<<24>>>0)+(t[e+1]<<16)+(t[e+2]<<8)+(t[e+3]||0)}function nw(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return rw(t,e)*tw+rw(t,e+4)}var ow=function(){function t(){n(this,t)}return i(t,null,[{key:"getRateIndexByRate",value:function(e){return t.FREQ.indexOf(e)}},{key:"parseADTS",value:function(e,r){for(var n=e.length,o=0;o+2<n&&(255!==e[o]||240!=(246&e[o+1]));)o++;if(!(o>=n)){var i=o,a=[],u=(60&e[o+2])>>>2,c=t.FREQ[u];if(!c)throw new Error("Invalid sampling index: ".concat(u));for(var s,f,l=1+((192&e[o+2])>>>6),d=(1&e[o+2])<<2|(192&e[o+3])>>>6,h=t._getConfig(u,d,l),p=h.config,v=h.codec,y=0,g=t.getFrameDuration(c);o+7<n;)if(255===e[o]&&240==(246&e[o+1])){if(n-o<(f=(3&e[o+3])<<11|e[o+4]<<3|(224&e[o+5])>>5))break;s=2*(1&~e[o+1]),a.push({pts:r+y*g,data:e.subarray(o+7+s,o+f)}),y++,o+=f}else o++;return{skip:i,remaining:o>=n?void 0:e.subarray(o),frames:a,samplingFrequencyIndex:u,sampleRate:c,objectType:l,channelCount:d,codec:v,config:p,originCodec:"mp4a.40.".concat(l)}}}},{key:"parseAudioSpecificConfig",value:function(e){if(e.length){var r=e[0]>>>3,n=(7&e[0])<<1|e[1]>>>7,o=(120&e[1])>>>3,i=t.FREQ[n];if(!i)throw new Error("Invalid sampling index: ".concat(n));var a=t._getConfig(n,o,r);return{samplingFrequencyIndex:n,sampleRate:i,objectType:r,channelCount:o,config:a.config,codec:a.codec,originCodec:"mp4a.40.".concat(r)}}}},{key:"getFrameDuration",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:9e4;return 1024*e/t}},{key:"_getConfig",value:function(t,e,r){var n,o,i=[];return Xb?t>=6?(n=5,o=t-3):(n=2,o=t):Zb?(n=2,o=t):(n=r,o=t,t>=6?o=t-3:1===e&&(n=2,o=t)),i[0]=n<<3,i[0]|=(14&t)>>1,i[1]=(1&t)<<7,i[1]|=e<<3,5===n&&(i[1]|=(14&o)>>1,i[2]=(1&o)<<7,i[2]|=8,i[3]=0),{config:i,codec:"mp4a.40.".concat(n)}}},{key:"getSilentFrame",value:function(t,e){switch(t){case"mp4a.40.2":if(1===e)return new Uint8Array([0,200,0,128,35,128]);if(2===e)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===e)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224]);break;default:if(1===e)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===e)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(3===e)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}}}]),t}();function iw(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function aw(t){return function(t){if(Array.isArray(t))return iw(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return iw(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?iw(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}a(ow,"FREQ",[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350]);var uw=Fe,cw=Bi,sw=O,fw=Ne,lw=Bi,dw=function(t){var e=cw(sw(this)),r="",n=uw(t);if(n<0||n==1/0)throw RangeError("Wrong number of repetitions");for(;n>0;(n>>>=1)&&(e+=e))1&n&&(r+=e);return r},hw=O,pw=Math.ceil,vw=function(t){return function(e,r,n){var o,i,a=lw(hw(e)),u=a.length,c=void 0===n?" ":lw(n),s=fw(r);return s<=u||""==c?a:(o=s-u,(i=dw.call(c,pw(o/c.length))).length>o&&(i=i.slice(0,o)),t?a+i:i+a)}},yw={start:vw(!1),end:vw(!0)},gw=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(P),mw=yw.start;Ir({target:"String",proto:!0,forced:gw},{padStart:function(t){return mw(this,t,arguments.length>1?arguments[1]:void 0)}});var bw=Ut,ww=Ps;d&&l((function(){return"sy"!==Object.getOwnPropertyDescriptor(RegExp.prototype,"flags").get.call({dotAll:!0,sticky:!0})}))&&bw.f(RegExp.prototype,"flags",{configurable:!0,get:ww});var xw=function(){function t(){n(this,t)}return i(t,null,[{key:"findBox",value:function(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,o=[];if(!e)return o;for(var i=0,a="",u=0;e.length>7;){if(i=rw(e),a=String.fromCharCode.apply(null,e.subarray(4,8)),u=8,1===i?(i=nw(e,8),u+=8):i||(i=e.length),!r[0]||a===r[0]){var c=e.subarray(0,i);if(!(r.length<2))return t.findBox(c.subarray(u),r.slice(1),n+u);o.push({start:n,size:i,headerSize:u,type:a,data:c})}n+=i,e=e.subarray(i)}return o}},{key:"moov",value:function(e){return kw(e,!1,(function(e,r,n){e.mvhd=t.mvhd(t.findBox(r,["mvhd"],n)[0]),e.trak=t.findBox(r,["trak"],n).map((function(e){return t.trak(e)}))}))}},{key:"mvhd",value:function(t){return kw(t,!0,(function(t,e){var r=0;1===t.version?(t.timescale=rw(e,16),t.duration=nw(e,20),r+=28):(t.timescale=rw(e,8),t.duration=rw(e,12),r+=16),t.nextTrackId=rw(e,r+76)}))}},{key:"trak",value:function(e){return kw(e,!1,(function(e,r,n){e.tkhd=t.tkhd(t.findBox(r,["tkhd"],n)[0]),e.mdia=t.mdia(t.findBox(r,["mdia"],n)[0])}))}},{key:"tkhd",value:function(t){return kw(t,!0,(function(t,e){var r=0;1===t.version?(t.trackId=rw(e,16),t.duration=nw(e,24),r+=32):(t.trackId=rw(e,8),t.duration=rw(e,16),r+=20),t.width=rw(e,r+52),t.height=rw(e,r+56)}))}},{key:"mdia",value:function(e){return kw(e,!1,(function(e,r,n){e.mdhd=t.mdhd(t.findBox(r,["mdhd"],n)[0]),e.hdlr=t.hdlr(t.findBox(r,["hdlr"],n)[0]),e.minf=t.minf(t.findBox(r,["minf"],n)[0])}))}},{key:"mdhd",value:function(t){return kw(t,!0,(function(t,e){var r=0;1===t.version?(t.timescale=rw(e,16),t.duration=nw(e,20),r+=28):(t.timescale=rw(e,8),t.duration=rw(e,12),r+=16);var n=ew(e,r);t.language=String.fromCharCode(96+(n>>10&31),96+(n>>5&31),96+(31&n))}))}},{key:"hdlr",value:function(t){return kw(t,!0,(function(t,e){0===t.version&&(t.handlerType=String.fromCharCode.apply(null,e.subarray(4,8)))}))}},{key:"minf",value:function(e){return kw(e,!1,(function(e,r,n){e.vmhd=t.vmhd(t.findBox(r,["vmhd"],n)[0]),e.smhd=t.smhd(t.findBox(r,["smhd"],n)[0]),e.stbl=t.stbl(t.findBox(r,["stbl"],n)[0])}))}},{key:"vmhd",value:function(t){return kw(t,!0,(function(t,e){t.graphicsmode=ew(e),t.opcolor=[ew(e,2),ew(e,4),ew(e,6)]}))}},{key:"smhd",value:function(t){return kw(t,!0,(function(t,e){t.balance=ew(e)}))}},{key:"stbl",value:function(e){return kw(e,!1,(function(e,r,n){e.stsd=t.stsd(t.findBox(r,["stsd"],n)[0]),e.stts=t.stts(t.findBox(r,["stts"],n)[0]),e.ctts=t.ctts(t.findBox(r,["ctts"],n)[0]),e.stsc=t.stsc(t.findBox(r,["stsc"],n)[0]),e.stsz=t.stsz(t.findBox(r,["stsz"],n)[0]),e.stco=t.stco(t.findBox(r,["stco"],n)[0]),e.stss=t.stss(t.findBox(r,["stss"],n)[0])}))}},{key:"stsd",value:function(e){return kw(e,!0,(function(e,r,n){e.entryCount=rw(r),e.entries=t.findBox(r.subarray(4),[],n+4).map((function(e){switch(e.type){case"avc1":case"avc2":case"avc3":case"avc4":return t.avc1(e);case"hvc1":case"hev1":return t.hvc1(e);case"mp4a":return t.mp4a(e)}})).filter(Boolean)}))}},{key:"avc1",value:function(e){return kw(e,!1,(function(e,r,n){var o=Sw(e,r),i=r.subarray(o);n+=o,e.avcC=t.avcC(t.findBox(i,["avcC"],n)[0]),e.pasp=t.pasp(t.findBox(i,["pasp"],n)[0])}))}},{key:"avcC",value:function(t){return kw(t,!1,(function(t,e){t.configurationVersion=e[0],t.AVCProfileIndication=e[1],t.profileCompatibility=e[2],t.AVCLevelIndication=e[3],t.codec=function(t){for(var e,r="avc1.",n=0;n<3;n++)(e=t[n].toString(16)).length<2&&(e="0".concat(e)),r+=e;return r}([e[1],e[2],e[3]]),t.lengthSizeMinusOne=3&e[4],t.spsLength=31&e[5],t.sps=[];for(var r=6,n=0;n<t.spsLength;n++){var o=ew(e,r);r+=2,t.sps.push(e.subarray(r,r+o)),r+=o}t.ppsLength=e[r],r+=1,t.pps=[];for(var i=0;i<t.ppsLength;i++){var a=ew(e,r);r+=2,t.pps.push(e.subarray(r,r+=a)),r+=a}}))}},{key:"hvc1",value:function(e){return kw(e,!1,(function(e,r,n){var o=Sw(e,r),i=r.subarray(o);n+=o,e.hvcC=t.hvcC(t.findBox(i,["hvcC"],n)[0]),e.pasp=t.pasp(t.findBox(i,["pasp"],n)[0])}))}},{key:"hvcC",value:function(t){return kw(t,!1,(function(e,r){e.data=t.data,e.codec="hev1.1.6.L93.B0",e.configurationVersion=r[0];var n=r[1];e.generalProfileSpace=n>>6,e.generalTierFlag=(32&n)>>5,e.generalProfileIdc=31&n,e.generalProfileCompatibility=rw(r,2),e.generalConstraintIndicatorFlags=r.subarray(6,12),e.generalLevelIdc=r[12],e.avgFrameRate=ew(r,19),e.numOfArrays=r[22],e.vps=[],e.sps=[],e.pps=[];for(var o=23,i=0,a=0,u=0,c=0;c<e.numOfArrays;c++){i=63&r[o],a=ew(r,o+1),o+=3;for(var s,f=[],l=0;l<a;l++)u=ew(r,o),o+=2,f.push(r.subarray(o,o+u)),o+=u;if(32===i)(s=e.vps).push.apply(s,f);else if(33===i){var d;(d=e.sps).push.apply(d,f)}else if(34===i){var h;(h=e.pps).push.apply(h,f)}}}))}},{key:"pasp",value:function(t){return kw(t,!1,(function(t,e){t.hSpacing=rw(e),t.vSpacing=rw(e,4)}))}},{key:"mp4a",value:function(e){return kw(e,!1,(function(e,r,n){var o=function(t,e){return t.dataReferenceIndex=ew(e,6),t.channelCount=ew(e,16),t.sampleSize=ew(e,18),t.sampleRate=rw(e,24)/65536,28}(e,r);e.esds=t.esds(t.findBox(r.subarray(o),["esds"],n+o)[0])}))}},{key:"esds",value:function(t){return kw(t,!0,(function(t,e){t.codec="mp4a.";for(var r=0,n=0,o=0,i=0;e.length;){for(i=e[r=0],n=e[r+1],r+=2;128&n;)o=(127&n)<<7,n=e[r],r+=1;if(o+=127&n,3===i)e=e.subarray(r+3);else{if(4!==i){if(5===i){var a=t.config=e.subarray(r,r+o),u=(248&a[0])>>3;return 31===u&&a.length>=2&&(u=32+((7&a[0])<<3)+((224&a[1])>>5)),t.objectType=u,void(t.codec+=u.toString(16))}return}t.codec+=(e[r].toString(16)+".").padStart(3,"0"),e=e.subarray(r+13)}}}))}},{key:"stts",value:function(t){return kw(t,!0,(function(t,e){for(var r=rw(e),n=[],o=4,i=0;i<r;i++)n.push({count:rw(e,o),delta:rw(e,o+4)}),o+=8;t.entryCount=r,t.entries=n}))}},{key:"ctts",value:function(t){return kw(t,!0,(function(t,e){var r=rw(e),n=[],o=4;if(1===t.version)for(var i=0;i<r;i++)n.push({count:rw(e,o),offset:rw(e,o+4)}),o+=8;else for(var a=0;a<r;a++)n.push({count:rw(e,o),offset:-(1+~rw(e,o+4))}),o+=8;t.entryCount=r,t.entries=n}))}},{key:"stsc",value:function(t){return kw(t,!0,(function(t,e){for(var r=rw(e),n=[],o=4,i=0;i<r;i++)n.push({firstChunk:rw(e,o),samplesPerChunk:rw(e,o+4),sampleDescriptionIndex:rw(e,o+8)}),o+=12;t.entryCount=r,t.entries=n}))}},{key:"stsz",value:function(t){return kw(t,!0,(function(t,e){var r=rw(e),n=rw(e,4),o=[];if(!r)for(var i=8,a=0;a<n;a++)o.push(rw(e,i)),i+=4;t.sampleSize=r,t.sampleCount=n,t.entrySizes=o}))}},{key:"stco",value:function(t){return kw(t,!0,(function(t,e){for(var r=rw(e),n=[],o=4,i=0;i<r;i++)n.push(rw(e,o)),o+=4;t.entryCount=r,t.entries=n}))}},{key:"stss",value:function(t){return kw(t,!0,(function(t,e){for(var r=rw(e),n=[],o=4,i=0;i<r;i++)n.push(rw(e,o)),o+=4;t.entryCount=r,t.entries=n}))}},{key:"moovToTrack",value:function(t,e,r){var n=t.trak;if(n&&n.length){var o=n.find((function(t){var e,r;return"vide"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)})),i=n.find((function(t){var e,r;return"soun"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)}));if(o&&e){var a=e;a.timescale=a.formatTimescale=o.mdia.mdhd.timescale,a.duration=o.mdia.mdhd.duration;var u=o.mdia.minf.stbl.stsd.entries[0];if(a.width=u.width,a.height=u.height,u.pasp&&(a.sarRatio=[u.pasp.hSpacing,u.pasp.vSpacing]),u.hvcC)a.codecType=zb,a.codec=u.hvcC.codec,a.vps=u.hvcC.vps,a.sps=u.hvcC.sps,a.pps=u.hvcC.pps,a.hvcC=u.hvcC.data;else{if(!u.avcC)throw new Error("unknown video stsd entry");a.codec=u.avcC.codec,a.sps=u.avcC.sps,a.pps=u.avcC.pps}a.present=!0}if(i&&r){var c,s,f=r;f.timescale=f.formatTimescale=i.mdia.mdhd.timescale,f.duration=i.mdia.mdhd.duration;var l=i.mdia.minf.stbl.stsd.entries[0];f.sampleSize=l.sampleSize,f.sampleRate=l.sampleRate,f.channelCount=l.channelCount,f.sampleDuration=ow.getFrameDuration(f.sampleRate,f.timescale),f.objectType=(null===(c=l.esds)||void 0===c?void 0:c.objectType)||2,l.esds&&(f.config=Array.from(l.esds.config)),f.codec=(null===(s=l.esds)||void 0===s?void 0:s.codec)||"mp4a.40.2",f.sampleRateIndex=ow.getRateIndexByRate(f.sampleRate),f.present=!0}return{videoTrack:e,audioTrack:r}}}},{key:"moovToSamples",value:function(t){var e=t.trak;if(e&&e.length){var r=e.find((function(t){var e,r;return"vide"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)})),n=e.find((function(t){var e,r;return"soun"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)}));if(r||n){var o,i;if(r){var a,u,c=null===(a=r.mdia)||void 0===a||null===(u=a.minf)||void 0===u?void 0:u.stbl;if(!c)return;var s=c.stts,f=c.stsc,l=c.stsz,d=c.stco,h=c.stss,p=c.ctts;if(!(s&&f&&l&&d&&h))return;o=Tw(s,f,l,d,p,h)}if(n){var v,y,g,m=null===(v=n.mdia)||void 0===v||null===(y=v.minf)||void 0===y?void 0:y.stbl;if(!m)return;var b=null===(g=n.mdia.mdhd)||void 0===g?void 0:g.timescale,w=m.stts,x=m.stsc,T=m.stsz,S=m.stco;if(!(b&&w&&x&&T&&S))return;i=Tw(w,x,T,S)}return{videoSamples:o,audioSamples:i}}}}}]),t}();function Tw(t,e,r,n,o,i){var a,u,c,s=[],f=null==o?void 0:o.entries,l=e.entries,d=n.entries,h=r.entrySizes,p=null==i?void 0:i.entries;p&&(a={},p.forEach((function(t){a[t-1]=!0}))),f&&(u=[],f.forEach((function(t){for(var e=t.count,r=t.offset,n=0;n<e;n++)u.push(r)})));var v=-1,y=0,g=0,m=0,b=0,w=0,x=l[0].samplesPerChunk,T=l[1]?l[1].firstChunk-1:1/0;return t.entries.forEach((function(t){for(var e=t.count,n=t.delta,o=0;o<e;o++)c={dts:y,duration:n,size:h[g]||r.sampleSize,offset:d[m]+w,index:g},p&&(c.keyframe=a[g],c.keyframe&&v++,c.gopId=v),u&&u[g]&&(c.pts=c.dts+u[g]),s.push(c),y+=n,++g<x?w+=c.size:(m++,w=0,m>=T&&(b++,T=l[b+1]?l[b+1].firstChunk-1:1/0),x+=l[b].samplesPerChunk)})),s}function Sw(t,e){return t.dataReferenceIndex=ew(e,6),t.width=ew(e,24),t.height=ew(e,26),t.horizresolution=rw(e,28),t.vertresolution=rw(e,32),t.frameCount=ew(e,40),t.depth=ew(e,74),78}function kw(t,e,r){if(t){if(t.size!==t.data.length)throw new Error("box ".concat(t.type," size !== data.length"));var n={start:t.start,size:t.size,headerSize:t.headerSize,type:t.type};return e&&(n.version=t.data[t.headerSize],n.flags=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(t[e]<<16)+(t[e+1]<<8)+(t[e+2]||0)}(t.data,t.headerSize+1),n.headerSize+=4),r(n,t.data.subarray(n.headerSize),n.start+n.headerSize),n}}function Ow(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 Aw(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Ow(Object(r),!0).forEach((function(e){a(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Ow(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var _w=function t(e,r){n(this,t),this.type="file",this.message=e,this.data=r},Ew=function(){function t(){n(this,t),a(this,"_data",Object.create(null))}return i(t,[{key:"set",value:function(t,e){this._data[t]=e}},{key:"get",value:function(t){return this._data[t]}},{key:"clear",value:function(){this._data=Object.create(null)}}]),t}();function jw(t,e){var r=t.trak;if(r&&r.length){var n=r.find((function(t){var e,r;return"vide"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)})),o=r.find((function(t){var e,r;return"soun"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)}));if(n||o){var i,a=[],u=[];if(n){var c,s,f,l=null===(c=n.mdia)||void 0===c||null===(s=c.minf)||void 0===s?void 0:s.stbl;if(!l)return;var d=null===(f=n.mdia.mdhd)||void 0===f?void 0:f.timescale,h=l.stts,p=l.stsc,v=l.stsz,y=l.stco,g=l.stss;if(!(d&&h&&p&&v&&y&&g))return;i=(a=Rw(e,d,h,p,v,y,g)).map((function(t){return t.endTime-t.startTime}))}if(o){var m,b,w,x=null===(m=o.mdia)||void 0===m||null===(b=m.minf)||void 0===b?void 0:b.stbl;if(!x)return;var T=null===(w=o.mdia.mdhd)||void 0===w?void 0:w.timescale,S=x.stts,k=x.stsc,O=x.stsz,A=x.stco;if(!(T&&S&&k&&O&&A))return;u=Rw(e,T,S,k,O,A,null,i)}return{videoSegments:a,audioSegments:u}}}}function Rw(t,e,r,n,o,i,a,u){var c,s,f,l=[],d=[],h=[],p=n.entries,v=i.entries,y=o.entrySizes,g=null==a?void 0:a.entries;g&&(c={},g.forEach((function(t){c[t-1]=!0})));var m=0,b=0,w=0,x=0,T=0,S=p[0].samplesPerChunk,k=p[1]?p[1].firstChunk-1:1/0;r.entries.forEach((function(t){var r=t.count,n=t.delta;f=n/e;for(var i=0;i<r;i++)s={startTime:m,duration:f,size:y[b]||o.sampleSize,offset:v[w]+T,index:b},g&&(s.keyframe=c[b],s.keyframe?(d.push([s]),h.push(s.duration)):(d[d.length-1].push(s),h[d.length-1]+=s.duration)),l.push(s),m+=f,++b<S?T+=s.size:(w++,T=0,w>=k&&(x++,k=p[x+1]?p[x+1].firstChunk-1:1/0),S+=p[x].samplesPerChunk)}));var O=l.length;if(O&&(!a||l[0].keyframe)){var A,_=[],E=[],j=0,R=function(){var t;A=E[E.length-1],_.push({index:_.length,startTime:(null===(t=_[_.length-1])||void 0===t?void 0:t.endTime)||E[0].startTime,endTime:A.startTime+A.duration,range:[E[0].offset,A.offset+A.size],frames:E}),j=0,E=[]};if(a)for(var I=0,C=0,P=d.length;C<P;C++){var L,M;if(j+=h[C],(L=E).push.apply(L,aw(d[C])),C+1<P){if((I=j+h[C+1])>=t)if(I-t<Math.abs(t-j))(M=E).push.apply(M,aw(d[C+1])),R(),C++;else R()}else R()}else for(var D=(u=u||[])[0]||t,B=0;B<O;B++)E.push(l[B]),j+=l[B].duration,(B+1>=O||j>=D)&&(R(),D=u[_.length]||t);return _}}function Iw(t){var e="",r="",n=0,o=0,i=0,a=0,u=0;t.mvhd&&(u=t.mvhd.duration/t.mvhd.timescale);var c=t.trak;if(c){var s,f,l,d,h,p,v,y,g,m=c.find((function(t){var e,r;return"vide"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)})),b=c.find((function(t){var e,r;return"soun"===(null===(e=t.mdia)||void 0===e||null===(r=e.hdlr)||void 0===r?void 0:r.handlerType)}));if(m)if(s=null===(f=m.mdia)||void 0===f||null===(l=f.minf)||void 0===l||null===(d=l.stbl)||void 0===d?void 0:d.stsd.entries[0])n=s.width,o=s.height,e=null===(h=s.avcC||s.hvcC)||void 0===h?void 0:h.codec;if(b)if(s=null===(p=b.mdia)||void 0===p||null===(v=p.minf)||void 0===v||null===(y=v.stbl)||void 0===y?void 0:y.stsd.entries[0])i=s.channelCount,a=s.sampleRate,r=null===(g=s.esds)||void 0===g?void 0:g.codec}return{videoCodec:e,audioCodec:r,width:n,height:o,audioChannelCount:i,audioSampleRate:a,duration:u,moov:t}}function Cw(t){return"number"==typeof t&&!isNaN(t)}var Pw=["vid","moovEnd","segmentDuration","cache","maxDownloadInfoSize"];return function(){function t(e){n(this,t),a(this,"vid",""),a(this,"url",""),a(this,"meta",{}),a(this,"downloadInfo",[]),a(this,"videoSegments",[]),a(this,"audioSegments",[]),a(this,"cache",null),a(this,"_currentSegmentIndex",-1),a(this,"_currentLoadingSegmentIndex",-1),a(this,"_transformError",(function(t){return t.type="network",t})),this._config=Aw(Aw({vid:"",moovEnd:8e3,segmentDuration:5,maxDownloadInfoSize:30,cache:null},e),{},{responseType:"arraybuffer"});var o=this._config,i=o.vid;o.moovEnd,o.segmentDuration;var u=o.cache;o.maxDownloadInfoSize;var c=r(o,Pw);this.cache=u||new Ew,this.vid=i||c.url,this.url=c.url,c.transformError=this._transformError,this._loader=new Rb(c)}var o,u,c,s,f,l,d,h,p,v;return i(t,[{key:"isMetaLoaded",get:function(){return this.videoSegments.length||this.audioSegments.length}},{key:"setCurrentSegment",value:function(t){Cw(t)&&(this._currentSegmentIndex=t)}},{key:"isLastSegment",value:function(t){var e,r;return!!Cw(t)&&t===((null===(e=this.videoSegments[this.videoSegments.length-1])||void 0===e?void 0:e.index)||(null===(r=this.audioSegments[this.audioSegments.length-1])||void 0===r?void 0:r.index)||0)}},{key:"isSegmentLoading",value:function(t){return t===this._currentLoadingSegmentIndex}},{key:"changeUrl",value:(v=e(Hn.mark((function t(e){var r,n,o=arguments;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=o.length>1&&void 0!==o[1]?o[1]:e,n=o.length>2?o[2]:void 0,t.next=4,this.reset();case 4:e&&(this.url=e),r&&(this.vid=r),n&&(this._config.moovEnd=n);case 7:case"end":return t.stop()}}),t,this)}))),function(t){return v.apply(this,arguments)})},{key:"getOrLoadMeta",value:(p=e(Hn.mark((function t(e){return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.isMetaLoaded){t.next=3;break}return t.next=3,this.loadMeta(e);case 3:return t.abrupt("return",this.meta);case 4:case"end":return t.stop()}}),t,this)}))),function(t){return p.apply(this,arguments)})},{key:"loadMeta",value:(h=e(Hn.mark((function t(e,r){var n,o,i,a,u,c,s,f,l;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=[],t.next=3,this._loadData([0,r||this._config.moovEnd],e);case 3:if(o=t.sent){t.next=6;break}return t.abrupt("return");case 6:if(n.push(o),i=xw.findBox(o.data,["moov"])[0]){t.next=22;break}if(a=xw.findBox(o.data,["mdat"])[0]){t.next=12;break}throw new _w("cannot find moov or mdat box",o.data);case 12:return u=a.start+a.size,t.next=15,this._loadData([u],e);case 15:if(o=t.sent){t.next=18;break}return t.abrupt("return");case 18:if(n.push(o),i=xw.findBox(o.data,["moov"],u)[0]){t.next=22;break}throw new _w("cannot find moov box",o.data);case 22:if(!(i.size>i.data.length)){t.next=30;break}return t.next=25,this._loadData([o.data.length,i.start+i.size-1],e);case 25:if(o=t.sent){t.next=28;break}return t.abrupt("return");case 28:n.push(o),i.data=Ib(i.data,o.data);case 30:if(c=xw.moov(i)){t.next=33;break}throw new _w("cannot parse moov box",i.data);case 33:if(s=jw(c,this._config.segmentDuration)){t.next=36;break}throw new _w("cannot parse segments",i.data);case 36:return this.meta=Iw(c),f=s.videoSegments,l=s.audioSegments,this.videoSegments=f,this.audioSegments=l,t.abrupt("return",{meta:this.meta,videoSegments:f,audioSegments:l,responses:n});case 41:case"end":return t.stop()}}),t,this)}))),function(t,e){return h.apply(this,arguments)})},{key:"getSegmentByTime",value:function(t){var e,r;return this.videoSegments.length?(e=this.videoSegments.find((function(e){return e.startTime<=t&&e.endTime>t})))&&(r=this.audioSegments[e.index]):r=this.audioSegments.find((function(e){return e.startTime<=t&&e.endTime>t})),{video:e,audio:r}}},{key:"loadSegmentByTime",value:(d=e(Hn.mark((function t(e,r){var n,o,i,a,u=arguments;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=!(u.length>2&&void 0!==u[2])||u[2],this.isMetaLoaded){t.next=4;break}return t.next=4,this.loadMeta(r);case 4:return o=this.getSegmentByTime(e),i=o.video,a=o.audio,t.abrupt("return",this._loadSegment(i,a,r,n));case 6:case"end":return t.stop()}}),t,this)}))),function(t,e){return d.apply(this,arguments)})},{key:"loadNextSegment",value:(l=e(Hn.mark((function t(e){var r,n,o,i=arguments;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=!(i.length>1&&void 0!==i[1])||i[1],this.isMetaLoaded){t.next=4;break}return t.next=4,this.loadMeta();case 4:return n=this.videoSegments[this._currentSegmentIndex+1],o=this.audioSegments[this._currentSegmentIndex+1],t.abrupt("return",this._loadSegment(n,o,e,r));case 7:case"end":return t.stop()}}),t,this)}))),function(t){return l.apply(this,arguments)})},{key:"preload",value:(f=e(Hn.mark((function t(r){var n,o,i,a,u,c,s,f=this;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.isMetaLoaded){t.next=3;break}return t.next=3,this.loadMeta(!0);case 3:if(r&&!(r<0)){t.next=5;break}return t.abrupt("return");case 5:if(n=this.getSegmentByTime(r),o=n.video,i=n.audio,a=Math.max((null==o?void 0:o.index)||0,(null==i?void 0:i.index)||0)){t.next=9;break}return t.abrupt("return");case 9:return u=this.videoSegments.slice(0,a),c=this.audioSegments.slice(0,a),s=function(){var t=e(Hn.mark((function t(e){return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e>a)){t.next=2;break}return t.abrupt("return");case 2:return t.next=4,f._loadSegment(u[e],c[e],!0,!1);case 4:return t.next=6,s(e+1);case 6:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),t.next=14,s(0);case 14:case"end":return t.stop()}}),t,this)}))),function(t){return f.apply(this,arguments)})},{key:"cancel",value:function(){return this._loader.cancel()}},{key:"reset",value:(s=e(Hn.mark((function t(){return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this._loader.cancel();case 2:this.vid=this.url="",this.meta={},this.downloadInfo=[],this.videoSegments=[],this.audioSegments=[],this._currentSegmentIndex=-1,this._currentLoadingSegmentIndex=-1;case 9:case"end":return t.stop()}}),t,this)}))),function(){return s.apply(this,arguments)})},{key:"destroy",value:(c=e(Hn.mark((function t(){return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.cancel();case 2:this.cache.clear();case 3:case"end":return t.stop()}}),t,this)}))),function(){return c.apply(this,arguments)})},{key:"_loadSegment",value:(u=e(Hn.mark((function t(e,r,n,o){var i,a;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(e||r){t.next=2;break}return t.abrupt("return");case 2:return i=(null==e?void 0:e.index)||(null==r?void 0:r.index)||0,this._currentLoadingSegmentIndex=i,t.prev=4,t.next=7,this._loadData([Math.min((null==e?void 0:e.range[0])||1/0,(null==r?void 0:r.range[0])||1/0),Math.max((null==e?void 0:e.range[1])||0,(null==r?void 0:r.range[1])||0)],n);case 7:a=t.sent;case 8:return t.prev=8,this._currentLoadingSegmentIndex=-1,t.finish(8);case 11:if(a){t.next=13;break}return t.abrupt("return");case 13:return o&&(this._currentSegmentIndex=i),a.video=e,a.audio=r,t.abrupt("return",a);case 17:case"end":return t.stop()}}),t,this,[[4,,8,11]])}))),function(t,e,r,n){return u.apply(this,arguments)})},{key:"_loadData",value:(o=e(Hn.mark((function t(e,r){var n,o,i;return Hn.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=this._getCacheKey(e),t.next=3,this.cache.get(n);case 3:if(o=t.sent){t.next=10;break}return t.next=7,this._loader.load(this.url,{range:e});case 7:i=t.sent,t.next=11;break;case 10:i={data:o,fromCache:!0};case 11:if(i){t.next=13;break}return t.abrupt("return");case 13:return o||(this.downloadInfo.push({startTime:i.startTime,endTime:i.endTime,size:i.data.byteLength,range:e}),this._addDownloadInfo>this._config.maxDownloadInfoSize&&(this._downloadInfos=this.downloadInfo.slice(-this._config.maxDownloadInfoSize))),!o&&r&&this.cache.set(n,i.data),i.range=e,t.abrupt("return",i);case 17:case"end":return t.stop()}}),t,this)}))),function(t,e){return o.apply(this,arguments)})},{key:"_getCacheKey",value:function(t){return(this.vid||this.url)+":"+t}}]),t}()}));
2
+ //# sourceMappingURL=index.min.js.map