You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/p__Competitions__Detail.7c9...

293 lines
1.6 MiB

This file contains invisible Unicode characters!

This file contains invisible Unicode characters that may be processed differently from what appears below. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to reveal hidden characters.

(window.webpackJsonp=window.webpackJsonp||[]).push([[134,5,6,7,8,13,20],{"+NIl":function(F,Q,j){(function(N){N(j("VrN/"))})(function(N){"use strict";N.defineMode("stex",function(v,C){"use strict";function M(i,o){i.cmdState.push(o)}function m(i){return i.cmdState.length>0?i.cmdState[i.cmdState.length-1]:null}function y(i){var o=i.cmdState.pop();o&&o.closeBracket()}function w(i){for(var o=i.cmdState,u=o.length-1;u>=0;u--){var f=o[u];if(f.name=="DEFAULT")continue;return f}return{styleIdentifier:function(){return null}}}function b(i,o,u){return function(){this.name=i,this.bracketNo=0,this.style=o,this.styles=u,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var p={};p.importmodule=b("importmodule","tag",["string","builtin"]),p.documentclass=b("documentclass","tag",["","atom"]),p.usepackage=b("usepackage","tag",["atom"]),p.begin=b("begin","tag",["atom"]),p.end=b("end","tag",["atom"]),p.label=b("label","tag",["atom"]),p.ref=b("ref","tag",["atom"]),p.eqref=b("eqref","tag",["atom"]),p.cite=b("cite","tag",["atom"]),p.bibitem=b("bibitem","tag",["atom"]),p.Bibitem=b("Bibitem","tag",["atom"]),p.RBibitem=b("RBibitem","tag",["atom"]),p.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}};function d(i,o){i.f=o}function n(i,o){var u;if(i.match(/^\\[a-zA-Z@]+/)){var f=i.current().slice(1);return u=p.hasOwnProperty(f)?p[f]:p.DEFAULT,u=new u,M(o,u),d(o,r),u.style}if(i.match(/^\\[$&%#{}_]/))return"tag";if(i.match(/^\\[,;!\/\\]/))return"tag";if(i.match("\\["))return d(o,function(l,t){return c(l,t,"\\]")}),"keyword";if(i.match("\\("))return d(o,function(l,t){return c(l,t,"\\)")}),"keyword";if(i.match("$$"))return d(o,function(l,t){return c(l,t,"$$")}),"keyword";if(i.match("$"))return d(o,function(l,t){return c(l,t,"$")}),"keyword";var s=i.next();if(s=="%")return i.skipToEnd(),"comment";if(s=="}"||s=="]"){if(u=m(o),u)u.closeBracket(s),d(o,r);else return"error";return"bracket"}else return s=="{"||s=="["?(u=p.DEFAULT,u=new u,M(o,u),"bracket"):/\d/.test(s)?(i.eatWhile(/[\w.%]/),"atom"):(i.eatWhile(/[\w\-_]/),u=w(o),u.name=="begin"&&(u.argument=i.current()),u.styleIdentifier())}function c(i,o,u){if(i.eatSpace())return null;if(u&&i.match(u))return d(o,n),"keyword";if(i.match(/^\\[a-zA-Z@]+/))return"tag";if(i.match(/^[a-zA-Z]+/))return"variable-2";if(i.match(/^\\[$&%#{}_]/))return"tag";if(i.match(/^\\[,;!\/]/))return"tag";if(i.match(/^[\^_&]/))return"tag";if(i.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(i.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var f=i.next();return f=="{"||f=="}"||f=="["||f=="]"||f=="("||f==")"?"bracket":f=="%"?(i.skipToEnd(),"comment"):"error"}function r(i,o){var u=i.peek(),f;return u=="{"||u=="["?(f=m(o),f.openBracket(u),i.eat(u),d(o,n),"bracket"):/[ \t\r]/.test(u)?(i.eat(u),null):(d(o,n),y(o),n(i,o))}return{startState:function(){var i=C.inMathMode?function(o,u){return c(o,u)}:n;return{cmdState:[],f:i}},copyState:function(i){return{cmdState:i.cmdState.slice(),f:i.f}},token:function(i,o){return o.f(i,o)},blankLine:function(i){i.f=n,i.cmdState.length=0},lineComment:"%"}}),N.defineMIME("text/x-stex","stex"),N.defineMIME("text/x-latex","stex")})},"+ua5":function(F,Q,j){},"19Vz":function(F,Q,j){(function(N){N(j("VrN/"))})(function(N){N.defineOption("placeholder","",function(b,p,d){var n=d&&d!=N.Init;if(p&&!n)b.on("blur",m),b.on("change",y),b.on("swapDoc",y),N.on(b.getInputField(),"compositionupdate",b.state.placeholderCompose=function(){M(b)}),y(b);else if(!p&&n){b.off("blur",m),b.off("change",y),b.off("swapDoc",y),N.off(b.getInputField(),"compositionupdate",b.state.placeholderCompose),v(b);var c=b.getWrapperElement();c.className=c.className.replace(" CodeMirror-empty","")}p&&!b.hasFocus()&&m(b)});function v(b){b.state.placeholder&&(b.state.placeholder.parentNode.removeChild(b.state.placeholder),b.state.placeholder=null)}function C(b){v(b);var p=b.state.placeholder=document.createElement("pre");p.style.cssText="height: 0; overflow: visible",p.style.direction=b.getOption("direction"),p.className="CodeMirror-placeholder CodeMirror-line-like";var d=b.getOption("placeholder");typeof d=="string"&&(d=document.createTextNode(d)),p.appendChild(d),b.display.lineSpace.insertBefore(p,b.display.lineSpace.firstChild)}function M(b){setTimeout(function(){var p=!1,d=b.getInputField();d.nodeName=="TEXTAREA"?p=!d.value:b.lineCount()==1&&(p=!/[^\u200b]/.test(d.querySelector(".CodeMirror-line").textContent)),p?C(b):v(b)},20)}function m(b){w(b)&&C(b)}function y(b){var p=b.getWrapperElement(),d=w(b);p.className=p.className.replace(" CodeMirror-empty","")+(d?" CodeMirror-empty":""),d?C(b):v(b)}function w(b){return b.lineCount()===1&&b.getLine(0)===""}})},"1ZF9":function(F,Q,j){F.exports=j.p+"static/Authorize.cc9c212f.png"},"1eCo":function(F,Q,j){(function(N){N(j("VrN/"))})(function(N){"use strict";var v={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},C={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};N.defineMode("xml",function(M,m){var y=M.indentUnit,w={},b=m.htmlMode?v:C;for(var p in b)w[p]=b[p];for(var p in m)w[p]=m[p];var d,n;function c(T,L){function I(W){return L.tokenize=W,W(T,L)}var P=T.next();if(P=="<")return T.eat("!")?T.eat("[")?T.match("CDATA[")?I(o("atom","]]>")):null:T.match("--")?I(o("comment","-->")):T.match("DOCTYPE",!0,!0)?(T.eatWhile(/[\w\._\-]/),I(u(1))):null:T.eat("?")?(T.eatWhile(/[\w\._\-]/),L.tokenize=o("meta","?>"),"meta"):(d=T.eat("/")?"closeTag":"openTag",L.tokenize=r,"tag bracket");if(P=="&"){var G;return T.eat("#")?T.eat("x")?G=T.eatWhile(/[a-fA-F\d]/)&&T.eat(";"):G=T.eatWhile(/[\d]/)&&T.eat(";"):G=T.eatWhile(/[\w\.\-:]/)&&T.eat(";"),G?"atom":"error"}else return T.eatWhile(/[^&<]/),null}c.isInText=!0;function r(T,L){var I=T.next();if(I==">"||I=="/"&&T.eat(">"))return L.tokenize=c,d=I==">"?"endTag":"selfcloseTag","tag bracket";if(I=="=")return d="equals",null;if(I=="<"){L.tokenize=c,L.state=t,L.tagName=L.tagStart=null;var P=L.tokenize(T,L);return P?P+" tag error":"tag error"}else return/[\'\"]/.test(I)?(L.tokenize=i(I),L.stringStartCol=T.column(),L.tokenize(T,L)):(T.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function i(T){var L=function(I,P){for(;!I.eol();)if(I.next()==T){P.tokenize=r;break}return"string"};return L.isInAttribute=!0,L}function o(T,L){return function(I,P){for(;!I.eol();){if(I.match(L)){P.tokenize=c;break}I.next()}return T}}function u(T){return function(L,I){for(var P;(P=L.next())!=null;){if(P=="<")return I.tokenize=u(T+1),I.tokenize(L,I);if(P==">")if(T==1){I.tokenize=c;break}else return I.tokenize=u(T-1),I.tokenize(L,I)}return"meta"}}function f(T,L,I){this.prev=T.context,this.tagName=L,this.indent=T.indented,this.startOfLine=I,(w.doNotIndent.hasOwnProperty(L)||T.context&&T.context.noIndent)&&(this.noIndent=!0)}function s(T){T.context&&(T.context=T.context.prev)}function l(T,L){for(var I;;){if(!T.context)return;if(I=T.context.tagName,!w.contextGrabbers.hasOwnProperty(I)||!w.contextGrabbers[I].hasOwnProperty(L))return;s(T)}}function t(T,L,I){return T=="openTag"?(I.tagStart=L.column(),S):T=="closeTag"?x:t}function S(T,L,I){return T=="word"?(I.tagName=L.current(),n="tag",O):w.allowMissingTagName&&T=="endTag"?(n="tag bracket",O(T,L,I)):(n="error",S)}function x(T,L,I){if(T=="word"){var P=L.current();return I.context&&I.context.tagName!=P&&w.implicitlyClosed.hasOwnProperty(I.context.tagName)&&s(I),I.context&&I.context.tagName==P||w.matchClosing===!1?(n="tag",h):(n="tag error",R)}else return w.allowMissingTagName&&T=="endTag"?(n="tag bracket",h(T,L,I)):(n="error",R)}function h(T,L,I){return T!="endTag"?(n="error",h):(s(I),t)}function R(T,L,I){return n="error",h(T,L,I)}function O(T,L,I){if(T=="word")return n="attribute",g;if(T=="endTag"||T=="selfcloseTag"){var P=I.tagName,G=I.tagStart;return I.tagName=I.tagStart=null,T=="selfcloseTag"||w.autoSelfClosers.hasOwnProperty(P)?l(I,P):(l(I,P),I.context=new f(I,P,G==I.indented)),t}return n="error",O}function g(T,L,I){return T=="equals"?_:(w.allowMissing||(n="error"),O(T,L,I))}function _(T,L,I){return T=="string"?E:T=="word"&&w.allowUnquoted?(n="string",O):(n="error",O(T,L,I))}function E(T,L,I){return T=="string"?E:O(T,L,I)}return{startState:function(T){var L={tokenize:c,state:t,indented:T||0,tagName:null,tagStart:null,context:null};return T!=null&&(L.baseIndent=T),L},token:function(T,L){if(!L.tagName&&T.sol()&&(L.indented=T.indentation()),T.eatSpace())return null;d=null;var I=L.tokenize(T,L);return(I||d)&&I!="comment"&&(n=null,L.state=L.state(d||I,T,L),n&&(I=n=="error"?I+" error":n)),I},indent:function(T,L,I){var P=T.context;if(T.tokenize.isInAttribute)return T.tagStart==T.indented?T.stringStartCol+1:T.indented+y;if(P&&P.noIndent)return N.Pass;if(T.tokenize!=r&&T.tokenize!=c)return I?I.match(/^(\s*)/)[0].length:0;if(T.tagName)return w.multilineTagIndentPastTag!==!1?T.tagStart+T.tagName.length+2:T.tagStart+y*(w.multilineTagIndentFactor||1);if(w.alignCDATA&&/<!\[CDATA\[/.test(L))return 0;var G=L&&/^<(\/)?([\w_:\.-]*)/.exec(L);if(G&&G[1])for(;P;)if(P.tagName==G[2]){P=P.prev;break}else if(w.implicitlyClosed.hasOwnProperty(P.tagName))P=P.prev;else break;else if(G)for(;P;){var W=w.contextGrabbers[P.tagName];if(W&&W.hasOwnProperty(G[2]))P=P.prev;else break}for(;P&&P.prev&&!P.startOfLine;)P=P.prev;return P?P.indent+y:T.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"<!--",blockCommentEnd:"-->",configuration:w.htmlMode?"html":"xml",helperType:w.htmlMode?"html":"xml",skipAttribute:function(T){T.state==_&&(T.state=O)},xmlCurrentTag:function(T){return T.tagName?{name:T.tagName,close:T.type=="closeTag"}:null},xmlCurrentContext:function(T){for(var L=[],I=T.context;I;I=I.prev)I.tagName&&L.push(I.tagName);return L.reverse()}}}),N.defineMIME("text/xml","xml"),N.defineMIME("application/xml","xml"),N.mimeModes.hasOwnProperty("text/html")||N.defineMIME("text/html",{name:"xml",htmlMode:!0})})},"1uat":function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("MlIO"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.Hasher,m=v.x64,y=m.Word,w=m.WordArray,b=v.algo;function p(){return y.create.apply(y,arguments)}var d=[p(1116352408,3609767458),p(1899447441,602891725),p(3049323471,3964484399),p(3921009573,2173295548),p(961987163,4081628472),p(1508970993,3053834265),p(2453635748,2937671579),p(2870763221,3664609560),p(3624381080,2734883394),p(310598401,1164996542),p(607225278,1323610764),p(1426881987,3590304994),p(1925078388,4068182383),p(2162078206,991336113),p(2614888103,633803317),p(3248222580,3479774868),p(3835390401,2666613458),p(4022224774,944711139),p(264347078,2341262773),p(604807628,2007800933),p(770255983,1495990901),p(1249150122,1856431235),p(1555081692,3175218132),p(1996064986,2198950837),p(2554220882,3999719339),p(2821834349,766784016),p(2952996808,2566594879),p(3210313671,3203337956),p(3336571891,1034457026),p(3584528711,2466948901),p(113926993,3758326383),p(338241895,168717936),p(666307205,1188179964),p(773529912,1546045734),p(1294757372,1522805485),p(1396182291,2643833823),p(1695183700,2343527390),p(1986661051,1014477480),p(2177026350,1206759142),p(2456956037,344077627),p(2730485921,1290863460),p(2820302411,3158454273),p(3259730800,3505952657),p(3345764771,106217008),p(3516065817,3606008344),p(3600352804,1432725776),p(4094571909,1467031594),p(275423344,851169720),p(430227734,3100823752),p(506948616,1363258195),p(659060556,3750685593),p(883997877,3785050280),p(958139571,3318307427),p(1322822218,3812723403),p(1537002063,2003034995),p(1747873779,3602036899),p(1955562222,1575990012),p(2024104815,1125592928),p(2227730452,2716904306),p(2361852424,442776044),p(2428436474,593698344),p(2756734187,3733110249),p(3204031479,2999351573),p(3329325298,3815920427),p(3391569614,3928383900),p(3515267271,566280711),p(3940187606,3454069534),p(4118630271,4000239992),p(116418474,1914138554),p(174292421,2731055270),p(289380356,3203993006),p(460393269,320620315),p(685471733,587496836),p(852142971,1086792851),p(1017036298,365543100),p(1126000580,2618297676),p(1288033470,3409855158),p(1501505948,4234509866),p(1607167915,987167468),p(1816402316,1246189591)],n=[];(function(){for(var r=0;r<80;r++)n[r]=p()})();var c=b.SHA512=M.extend({_doReset:function(){this._hash=new w.init([new y.init(1779033703,4089235720),new y.init(3144134277,2227873595),new y.init(1013904242,4271175723),new y.init(2773480762,1595750129),new y.init(1359893119,2917565137),new y.init(2600822924,725511199),new y.init(528734635,4215389547),new y.init(1541459225,327033209)])},_doProcessBlock:function(r,i){for(var o=this._hash.words,u=o[0],f=o[1],s=o[2],l=o[3],t=o[4],S=o[5],x=o[6],h=o[7],R=u.high,O=u.low,g=f.high,_=f.low,E=s.high,T=s.low,L=l.high,I=l.low,P=t.high,G=t.low,W=S.high,H=S.low,z=x.high,B=x.low,k=h.high,K=h.low,Y=R,ne=O,oe=g,_e=_,xe=E,le=T,me=L,de=I,ae=P,ie=G,q=W,ue=H,Z=z,ee=B,Ee=k,te=K,J=0;J<80;J++){var X,$,ge=n[J];if(J<16)$=ge.high=r[i+J*2]|0,X=ge.low=r[i+J*2+1]|0;else{var fe=n[J-15],Te=fe.high,ze=fe.low,Xe=(Te>>>1|ze<<31)^(Te>>>8|ze<<24)^Te>>>7,Ye=(ze>>>1|Te<<31)^(ze>>>8|Te<<24)^(ze>>>7|Te<<25),rt=n[J-2],at=rt.high,ot=rt.low,Pe=(at>>>19|ot<<13)^(at<<3|ot>>>29)^at>>>6,Se=(ot>>>19|at<<13)^(ot<<3|at>>>29)^(ot>>>6|at<<26),Je=n[J-7],nt=Je.high,We=Je.low,et=n[J-16],Me=et.high,Ce=et.low;X=Ye+We,$=Xe+nt+(X>>>0<Ye>>>0?1:0),X=X+Se,$=$+Pe+(X>>>0<Se>>>0?1:0),X=X+Ce,$=$+Me+(X>>>0<Ce>>>0?1:0),ge.high=$,ge.low=X}var Re=ae&q^~ae&Z,pe=ie&ue^~ie&ee,ye=Y&oe^Y&xe^oe&xe,we=ne&_e^ne&le^_e&le,Ie=(Y>>>28|ne<<4)^(Y<<30|ne>>>2)^(Y<<25|ne>>>7),ke=(ne>>>28|Y<<4)^(ne<<30|Y>>>2)^(ne<<25|Y>>>7),Ve=(ae>>>14|ie<<18)^(ae>>>18|ie<<14)^(ae<<23|ie>>>9),ut=(ie>>>14|ae<<18)^(ie>>>18|ae<<14)^(ie<<23|ae>>>9),ct=d[J],Lt=ct.high,Dt=ct.low,Er=te+ut,rr=Ee+Ve+(Er>>>0<te>>>0?1:0),Er=Er+pe,rr=rr+Re+(Er>>>0<pe>>>0?1:0),Er=Er+Dt,rr=rr+Lt+(Er>>>0<Dt>>>0?1:0),Er=Er+X,rr=rr+$+(Er>>>0<X>>>0?1:0),xt=ke+we,kr=Ie+ye+(xt>>>0<ke>>>0?1:0);Ee=Z,te=ee,Z=q,ee=ue,q=ae,ue=ie,ie=de+Er|0,ae=me+rr+(ie>>>0<de>>>0?1:0)|0,me=xe,de=le,xe=oe,le=_e,oe=Y,_e=ne,ne=Er+xt|0,Y=rr+kr+(ne>>>0<Er>>>0?1:0)|0}O=u.low=O+ne,u.high=R+Y+(O>>>0<ne>>>0?1:0),_=f.low=_+_e,f.high=g+oe+(_>>>0<_e>>>0?1:0),T=s.low=T+le,s.high=E+xe+(T>>>0<le>>>0?1:0),I=l.low=I+de,l.high=L+me+(I>>>0<de>>>0?1:0),G=t.low=G+ie,t.high=P+ae+(G>>>0<ie>>>0?1:0),H=S.low=H+ue,S.high=W+q+(H>>>0<ue>>>0?1:0),B=x.low=B+ee,x.high=z+Z+(B>>>0<ee>>>0?1:0),K=h.low=K+te,h.high=k+Ee+(K>>>0<te>>>0?1:0)},_doFinalize:function(){var r=this._data,i=r.words,o=this._nDataBytes*8,u=r.sigBytes*8;i[u>>>5]|=128<<24-u%32,i[(u+128>>>10<<5)+30]=Math.floor(o/4294967296),i[(u+128>>>10<<5)+31]=o,r.sigBytes=i.length*4,this._process();var f=this._hash.toX32();return f},clone:function(){var r=M.clone.call(this);return r._hash=this._hash.clone(),r},blockSize:1024/32});v.SHA512=M._createHelper(c),v.HmacSHA512=M._createHmacHelper(c)}(),N.SHA512})},"3y9D":function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.WordArray,m=C.Hasher,y=v.algo,w=[],b=y.SHA1=m.extend({_doReset:function(){this._hash=new M.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(p,d){for(var n=this._hash.words,c=n[0],r=n[1],i=n[2],o=n[3],u=n[4],f=0;f<80;f++){if(f<16)w[f]=p[d+f]|0;else{var s=w[f-3]^w[f-8]^w[f-14]^w[f-16];w[f]=s<<1|s>>>31}var l=(c<<5|c>>>27)+u+w[f];f<20?l+=(r&i|~r&o)+1518500249:f<40?l+=(r^i^o)+1859775393:f<60?l+=(r&i|r&o|i&o)-1894007588:l+=(r^i^o)-899497514,u=o,o=i,i=r<<30|r>>>2,r=c,c=l}n[0]=n[0]+c|0,n[1]=n[1]+r|0,n[2]=n[2]+i|0,n[3]=n[3]+o|0,n[4]=n[4]+u|0},_doFinalize:function(){var p=this._data,d=p.words,n=this._nDataBytes*8,c=p.sigBytes*8;return d[c>>>5]|=128<<24-c%32,d[(c+64>>>9<<4)+14]=Math.floor(n/4294967296),d[(c+64>>>9<<4)+15]=n,p.sigBytes=d.length*4,this._process(),this._hash},clone:function(){var p=m.clone.call(this);return p._hash=this._hash.clone(),p}});v.SHA1=m._createHelper(b),v.HmacSHA1=m._createHmacHelper(b)}(),N.SHA1})},4:function(F,Q){},"55Ip":function(F,Q,j){"use strict";j.d(Q,"a",function(){return l});var N=j("Ty5D"),v=j("dI71"),C=j("cDcd"),M=j.n(C),m=j("YS25"),y=j("17x9"),w=j.n(y),b=j("wx14"),p=j("zLVn"),d=j("9R94"),n=function(_){Object(v.a)(E,_);function E(){for(var L,I=arguments.length,P=new Array(I),G=0;G<I;G++)P[G]=arguments[G];return L=_.call.apply(_,[this].concat(P))||this,L.history=Object(m.a)(L.props),L}var T=E.prototype;return T.render=function(){return M.a.createElement(N.c,{history:this.history,children:this.props.children})},E}(M.a.Component),c=function(_){Object(v.a)(E,_);function E(){for(var L,I=arguments.length,P=new Array(I),G=0;G<I;G++)P[G]=arguments[G];return L=_.call.apply(_,[this].concat(P))||this,L.history=Object(m.b)(L.props),L}var T=E.prototype;return T.render=function(){return M.a.createElement(N.c,{history:this.history,children:this.props.children})},E}(M.a.Component),r=function(E,T){return typeof E=="function"?E(T):E},i=function(E,T){return typeof E=="string"?Object(m.c)(E,null,null,T):E},o=function(E){return E},u=M.a.forwardRef;typeof u=="undefined"&&(u=o);function f(_){return!!(_.metaKey||_.altKey||_.ctrlKey||_.shiftKey)}var s=u(function(_,E){var T=_.innerRef,L=_.navigate,I=_.onClick,P=Object(p.a)(_,["innerRef","navigate","onClick"]),G=P.target,W=Object(b.a)({},P,{onClick:function(z){try{I&&I(z)}catch(B){throw z.preventDefault(),B}!z.defaultPrevented&&z.button===0&&(!G||G==="_self")&&!f(z)&&(z.preventDefault(),L())}});return o!==u?W.ref=E||T:W.ref=T,M.a.createElement("a",W)}),l=u(function(_,E){var T=_.component,L=T===void 0?s:T,I=_.replace,P=_.to,G=_.innerRef,W=Object(p.a)(_,["component","replace","to","innerRef"]);return M.a.createElement(N.e.Consumer,null,function(H){H||Object(d.a)(!1);var z=H.history,B=i(r(P,H.location),H.location),k=B?z.createHref(B):"",K=Object(b.a)({},W,{href:k,navigate:function(){var ne=r(P,H.location),oe=I?z.replace:z.push;oe(ne)}});return o!==u?K.ref=E||G:K.innerRef=G,M.a.createElement(L,K)})});if(!1)var t,S;var x=function(E){return E},h=M.a.forwardRef;typeof h=="undefined"&&(h=x);function R(){for(var _=arguments.length,E=new Array(_),T=0;T<_;T++)E[T]=arguments[T];return E.filter(function(L){return L}).join(" ")}var O=h(function(_,E){var T=_["aria-current"],L=T===void 0?"page":T,I=_.activeClassName,P=I===void 0?"active":I,G=_.activeStyle,W=_.className,H=_.exact,z=_.isActive,B=_.location,k=_.sensitive,K=_.strict,Y=_.style,ne=_.to,oe=_.innerRef,_e=Object(p.a)(_,["aria-current","activeClassName","activeStyle","className","exact","isActive","location","sensitive","strict","style","to","innerRef"]);return M.a.createElement(N.e.Consumer,null,function(xe){xe||Object(d.a)(!1);var le=B||xe.location,me=i(r(ne,le),le),de=me.pathname,ae=de&&de.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),ie=ae?Object(N.f)(le.pathname,{path:ae,exact:H,sensitive:k,strict:K}):null,q=!!(z?z(ie,le):ie),ue=q?R(W,P):W,Z=q?Object(b.a)({},Y,{},G):Y,ee=Object(b.a)({"aria-current":q&&L||null,className:ue,style:Z,to:me},_e);return x!==h?ee.ref=E||oe:ee.innerRef=oe,M.a.createElement(l,ee)})});if(!1)var g},"5VLF":function(F,Q,j){"use strict";var N,v;function C(M,m,y){var w=function(b,p){return M.js_beautify(b,p)};return w.js=M.js_beautify,w.css=m.css_beautify,w.html=y.html_beautify,w.js_beautify=M.js_beautify,w.css_beautify=m.css_beautify,w.html_beautify=y.html_beautify,w}!(N=[j("6UM0"),j("TXwP"),j("psGv")],v=function(M,m,y){return C(M,m,y)}.apply(Q,N),v!==void 0&&(F.exports=v))},"5hvy":function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("MlIO"))})(this,function(N){return function(v){var C=N,M=C.lib,m=M.WordArray,y=M.Hasher,w=C.x64,b=w.Word,p=C.algo,d=[],n=[],c=[];(function(){for(var o=1,u=0,f=0;f<24;f++){d[o+5*u]=(f+1)*(f+2)/2%64;var s=u%5,l=(2*o+3*u)%5;o=s,u=l}for(var o=0;o<5;o++)for(var u=0;u<5;u++)n[o+5*u]=u+(2*o+3*u)%5*5;for(var t=1,S=0;S<24;S++){for(var x=0,h=0,R=0;R<7;R++){if(t&1){var O=(1<<R)-1;O<32?h^=1<<O:x^=1<<O-32}t&128?t=t<<1^113:t<<=1}c[S]=b.create(x,h)}})();var r=[];(function(){for(var o=0;o<25;o++)r[o]=b.create()})();var i=p.SHA3=y.extend({cfg:y.cfg.extend({outputLength:512}),_doReset:function(){for(var o=this._state=[],u=0;u<25;u++)o[u]=new b.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(o,u){for(var f=this._state,s=this.blockSize/2,l=0;l<s;l++){var t=o[u+2*l],S=o[u+2*l+1];t=(t<<8|t>>>24)&16711935|(t<<24|t>>>8)&4278255360,S=(S<<8|S>>>24)&16711935|(S<<24|S>>>8)&4278255360;var x=f[l];x.high^=S,x.low^=t}for(var h=0;h<24;h++){for(var R=0;R<5;R++){for(var O=0,g=0,_=0;_<5;_++){var x=f[R+5*_];O^=x.high,g^=x.low}var E=r[R];E.high=O,E.low=g}for(var R=0;R<5;R++)for(var T=r[(R+4)%5],L=r[(R+1)%5],I=L.high,P=L.low,O=T.high^(I<<1|P>>>31),g=T.low^(P<<1|I>>>31),_=0;_<5;_++){var x=f[R+5*_];x.high^=O,x.low^=g}for(var G=1;G<25;G++){var O,g,x=f[G],W=x.high,H=x.low,z=d[G];z<32?(O=W<<z|H>>>32-z,g=H<<z|W>>>32-z):(O=H<<z-32|W>>>64-z,g=W<<z-32|H>>>64-z);var B=r[n[G]];B.high=O,B.low=g}var k=r[0],K=f[0];k.high=K.high,k.low=K.low;for(var R=0;R<5;R++)for(var _=0;_<5;_++){var G=R+5*_,x=f[G],Y=r[G],ne=r[(R+1)%5+5*_],oe=r[(R+2)%5+5*_];x.high=Y.high^~ne.high&oe.high,x.low=Y.low^~ne.low&oe.low}var x=f[0],_e=c[h];x.high^=_e.high,x.low^=_e.low}},_doFinalize:function(){var o=this._data,u=o.words,f=this._nDataBytes*8,s=o.sigBytes*8,l=this.blockSize*32;u[s>>>5]|=1<<24-s%32,u[(v.ceil((s+1)/l)*l>>>5)-1]|=128,o.sigBytes=u.length*4,this._process();for(var t=this._state,S=this.cfg.outputLength/8,x=S/8,h=[],R=0;R<x;R++){var O=t[R],g=O.high,_=O.low;g=(g<<8|g>>>24)&16711935|(g<<24|g>>>8)&4278255360,_=(_<<8|_>>>24)&16711935|(_<<24|_>>>8)&4278255360,h.push(_),h.push(g)}return new m.init(h,S)},clone:function(){for(var o=y.clone.call(this),u=o._state=this._state.slice(0),f=0;f<25;f++)u[f]=u[f].clone();return o}});C.SHA3=y._createHelper(i),C.HmacSHA3=y._createHmacHelper(i)}(Math),N.SHA3})},"6+eU":function(F,Q,j){"use strict";j.d(Q,"a",function(){return h});var N=j("wx14"),v=j("rePB"),C=j("VTBJ"),M=j("1OyB"),m=j("vuIU"),y=j("Ji7U"),w=j("LK+K"),b=j("cDcd"),p=j.n(b),d=j("TSYQ"),n=j.n(d),c=function(O){var g,_="".concat(O.rootPrefixCls,"-item"),E=n()(_,"".concat(_,"-").concat(O.page),(g={},Object(v.a)(g,"".concat(_,"-active"),O.active),Object(v.a)(g,O.className,!!O.className),Object(v.a)(g,"".concat(_,"-disabled"),!O.page),g)),T=function(){O.onClick(O.page)},L=function(P){O.onKeyPress(P,O.onClick,O.page)};return p.a.createElement("li",{title:O.showTitle?O.page:null,className:E,onClick:T,onKeyPress:L,tabIndex:"0"},O.itemRender(O.page,"page",p.a.createElement("a",{rel:"nofollow"},O.page)))},r=c,i={ZERO:48,NINE:57,NUMPAD_ZERO:96,NUMPAD_NINE:105,BACKSPACE:8,DELETE:46,ENTER:13,ARROW_UP:38,ARROW_DOWN:40},o=function(R){Object(y.a)(g,R);var O=Object(w.a)(g);function g(){var _;Object(M.a)(this,g);for(var E=arguments.length,T=new Array(E),L=0;L<E;L++)T[L]=arguments[L];return _=O.call.apply(O,[this].concat(T)),_.state={goInputText:""},_.buildOptionText=function(I){return"".concat(I," ").concat(_.props.locale.items_per_page)},_.changeSize=function(I){_.props.changeSize(Number(I))},_.handleChange=function(I){_.setState({goInputText:I.target.value})},_.handleBlur=function(I){var P=_.props,G=P.goButton,W=P.quickGo,H=P.rootPrefixCls,z=_.state.goInputText;if(G||z==="")return;if(I.relatedTarget&&(I.relatedTarget.className.indexOf("".concat(H,"-prev"))>=0||I.relatedTarget.className.indexOf("".concat(H,"-next"))>=0))return;_.setState({goInputText:""}),W(_.getValidValue())},_.go=function(I){var P=_.state.goInputText;if(P==="")return;(I.keyCode===i.ENTER||I.type==="click")&&(_.setState({goInputText:""}),_.props.quickGo(_.getValidValue()))},_}return Object(m.a)(g,[{key:"getValidValue",value:function(){var E=this.state,T=E.goInputText,L=E.current;return!T||isNaN(T)?L:Number(T)}},{key:"getPageSizeOptions",value:function(){var E=this.props,T=E.pageSize,L=E.pageSizeOptions;return L.some(function(I){return I.toString()===T.toString()})?L:L.concat([T.toString()]).sort(function(I,P){var G=isNaN(Number(I))?0:Number(I),W=isNaN(Number(P))?0:Number(P);return G-W})}},{key:"render",value:function(){var E=this,T=this.props,L=T.pageSize,I=T.locale,P=T.rootPrefixCls,G=T.changeSize,W=T.quickGo,H=T.goButton,z=T.selectComponentClass,B=T.buildOptionText,k=T.selectPrefixCls,K=T.disabled,Y=this.state.goInputText,ne="".concat(P,"-options"),oe=z,_e=null,xe=null,le=null;if(!G&&!W)return null;var me=this.getPageSizeOptions();if(G&&oe){var de=me.map(function(ae,ie){return p.a.createElement(oe.Option,{key:ie,value:ae.toString()},(B||E.buildOptionText)(ae))});_e=p.a.createElement(oe,{disabled:K,prefixCls:k,showSearch:!1,className:"".concat(ne,"-size-changer"),optionLabelProp:"children",dropdownMatchSelectWidth:!1,value:(L||me[0]).toString(),onChange:this.changeSize,getPopupContainer:function(ie){return ie.parentNode}},de)}return W&&(H&&(le=typeof H=="boolean"?p.a.createElement("button",{type:"button",onClick:this.go,onKeyUp:this.go,disabled:K,className:"".concat(ne,"-quick-jumper-button")},I.jump_to_confirm):p.a.createElement("span",{onClick:this.go,onKeyUp:this.go},H)),xe=p.a.createElement("div",{className:"".concat(ne,"-quick-jumper")},I.jump_to,p.a.createElement("input",{disabled:K,type:"text",value:Y,onChange:this.handleChange,onKeyUp:this.go,onBlur:this.handleBlur}),I.page,le)),p.a.createElement("li",{className:"".concat(ne)},_e,xe)}}]),g}(p.a.Component);o.defaultProps={pageSizeOptions:["10","20","50","100"]};var u=o,f=j("N2Kk");function s(){}function l(R){return typeof R=="number"&&isFinite(R)&&Math.floor(R)===R}function t(R,O,g){return g}function S(R,O,g){var _=typeof R=="undefined"?O.pageSize:R;return Math.floor((g.total-1)/_)+1}var x=function(R){Object(y.a)(g,R);var O=Object(w.a)(g);function g(_){var E;Object(M.a)(this,g),E=O.call(this,_),E.getJumpPrevPage=function(){return Math.max(1,E.state.current-(E.props.showLessItems?3:5))},E.getJumpNextPage=function(){return Math.min(S(void 0,E.state,E.props),E.state.current+(E.props.showLessItems?3:5))},E.getItemIcon=function(G,W){var H=E.props.prefixCls,z=G||p.a.createElement("button",{type:"button","aria-label":W,className:"".concat(H,"-item-link")});return typeof G=="function"&&(z=p.a.createElement(G,Object(C.a)({},E.props))),z},E.savePaginationNode=function(G){E.paginationNode=G},E.isValid=function(G){return l(G)&&G!==E.state.current},E.shouldDisplayQuickJumper=function(){var G=E.props,W=G.showQuickJumper,H=G.pageSize,z=G.total;return z<=H?!1:W},E.handleKeyDown=function(G){(G.keyCode===i.ARROW_UP||G.keyCode===i.ARROW_DOWN)&&G.preventDefault()},E.handleKeyUp=function(G){var W=E.getValidValue(G),H=E.state.currentInputValue;W!==H&&E.setState({currentInputValue:W}),G.keyCode===i.ENTER?E.handleChange(W):G.keyCode===i.ARROW_UP?E.handleChange(W-1):G.keyCode===i.ARROW_DOWN&&E.handleChange(W+1)},E.changePageSize=function(G){var W=E.state.current,H=S(G,E.state,E.props);W=W>H?H:W,H===0&&(W=E.state.current),typeof G=="number"&&("pageSize"in E.props||E.setState({pageSize:G}),"current"in E.props||E.setState({current:W,currentInputValue:W})),E.props.onShowSizeChange(W,G),"onChange"in E.props&&E.props.onChange&&E.props.onChange(W,G)},E.handleChange=function(G){var W=E.props.disabled,H=G;if(E.isValid(H)&&!W){var z=S(void 0,E.state,E.props);H>z?H=z:H<1&&(H=1),"current"in E.props||E.setState({current:H,currentInputValue:H});var B=E.state.pageSize;return E.props.onChange(H,B),H}return E.state.current},E.prev=function(){E.hasPrev()&&E.handleChange(E.state.current-1)},E.next=function(){E.hasNext()&&E.handleChange(E.state.current+1)},E.jumpPrev=function(){E.handleChange(E.getJumpPrevPage())},E.jumpNext=function(){E.handleChange(E.getJumpNextPage())},E.hasPrev=function(){return E.state.current>1},E.hasNext=function(){return E.state.current<S(void 0,E.state,E.props)},E.runIfEnter=function(G,W){if(G.key==="Enter"||G.charCode===13){for(var H=arguments.length,z=new Array(H>2?H-2:0),B=2;B<H;B++)z[B-2]=arguments[B];W.apply(void 0,z)}},E.runIfEnterPrev=function(G){E.runIfEnter(G,E.prev)},E.runIfEnterNext=function(G){E.runIfEnter(G,E.next)},E.runIfEnterJumpPrev=function(G){E.runIfEnter(G,E.jumpPrev)},E.runIfEnterJumpNext=function(G){E.runIfEnter(G,E.jumpNext)},E.handleGoTO=function(G){(G.keyCode===i.ENTER||G.type==="click")&&E.handleChange(E.state.currentInputValue)};var T=_.onChange!==s,L="current"in _;L&&!T&&console.warn("Warning: You provided a `current` prop to a Pagination component without an `onChange` handler. This will render a read-only component.");var I=_.defaultCurrent;"current"in _&&(I=_.current);var P=_.defaultPageSize;return"pageSize"in _&&(P=_.pageSize),I=Math.min(I,S(P,void 0,_)),E.state={current:I,currentInputValue:I,pageSize:P},E}return Object(m.a)(g,[{key:"componentDidUpdate",value:function(E,T){var L=this.props.prefixCls;if(T.current!==this.state.current&&this.paginationNode){var I=this.paginationNode.querySelector(".".concat(L,"-item-").concat(T.current));I&&document.activeElement===I&&I.blur()}}},{key:"getValidValue",value:function(E){var T=E.target.value,L=S(void 0,this.state,this.props),I=this.state.currentInputValue,P;return T===""?P=T:isNaN(Number(T))?P=I:T>=L?P=L:P=Number(T),P}},{key:"getShowSizeChanger",value:function(){var E=this.props,T=E.showSizeChanger,L=E.total,I=E.totalBoundaryShowSizeChanger;return typeof T!="undefined"?T:L>I}},{key:"renderPrev",value:function(E){var T=this.props,L=T.prevIcon,I=T.itemRender,P=I(E,"prev",this.getItemIcon(L,"prev page")),G=!this.hasPrev();return Object(b.isValidElement)(P)?Object(b.cloneElement)(P,{disabled:G}):P}},{key:"renderNext",value:function(E){var T=this.props,L=T.nextIcon,I=T.itemRender,P=I(E,"next",this.getItemIcon(L,"next page")),G=!this.hasNext();return Object(b.isValidElement)(P)?Object(b.cloneElement)(P,{disabled:G}):P}},{key:"render",value:function(){var E=this,T=this.props,L=T.prefixCls,I=T.className,P=T.style,G=T.disabled,W=T.hideOnSinglePage,H=T.total,z=T.locale,B=T.showQuickJumper,k=T.showLessItems,K=T.showTitle,Y=T.showTotal,ne=T.simple,oe=T.itemRender,_e=T.showPrevNextJumpers,xe=T.jumpPrevIcon,le=T.jumpNextIcon,me=T.selectComponentClass,de=T.selectPrefixCls,ae=T.pageSizeOptions,ie=this.state,q=ie.current,ue=ie.pageSize,Z=ie.currentInputValue;if(W===!0&&H<=ue)return null;var ee=S(void 0,this.state,this.props),Ee=[],te=null,J=null,X=null,$=null,ge=null,fe=B&&B.goButton,Te=k?1:2,ze=q-1>0?q-1:0,Xe=q+1<ee?q+1:ee,Ye=Object.keys(this.props).reduce(function(pe,ye){return(ye.substr(0,5)==="data-"||ye.substr(0,5)==="aria-"||ye==="role")&&(pe[ye]=E.props[ye]),pe},{});if(ne)return fe&&(typeof fe=="boolean"?ge=p.a.createElement("button",{type:"button",onClick:this.handleGoTO,onKeyUp:this.handleGoTO},z.jump_to_confirm):ge=p.a.createElement("span",{onClick:this.handleGoTO,onKeyUp:this.handleGoTO},fe),ge=p.a.createElement("li",{title:K?"".concat(z.jump_to).concat(q,"/").concat(ee):null,className:"".concat(L,"-simple-pager")},ge)),p.a.createElement("ul",Object(N.a)({className:n()(L,"".concat(L,"-simple"),Object(v.a)({},"".concat(L,"-disabled"),G),I),style:P,ref:this.savePaginationNode},Ye),p.a.createElement("li",{title:K?z.prev_page:null,onClick:this.prev,tabIndex:this.hasPrev()?0:null,onKeyPress:this.runIfEnterPrev,className:n()("".concat(L,"-prev"),Object(v.a)({},"".concat(L,"-disabled"),!this.hasPrev())),"aria-disabled":!this.hasPrev()},this.renderPrev(ze)),p.a.createElement("li",{title:K?"".concat(q,"/").concat(ee):null,className:"".concat(L,"-simple-pager")},p.a.createElement("input",{type:"text",value:Z,disabled:G,onKeyDown:this.handleKeyDown,onKeyUp:this.handleKeyUp,onChange:this.handleKeyUp,size:"3"}),p.a.createElement("span",{className:"".concat(L,"-slash")},"/"),ee),p.a.createElement("li",{title:K?z.next_page:null,onClick:this.next,tabIndex:this.hasPrev()?0:null,onKeyPress:this.runIfEnterNext,className:n()("".concat(L,"-next"),Object(v.a)({},"".concat(L,"-disabled"),!this.hasNext())),"aria-disabled":!this.hasNext()},this.renderNext(Xe)),ge);if(ee<=3+Te*2){var rt={locale:z,rootPrefixCls:L,onClick:this.handleChange,onKeyPress:this.runIfEnter,showTitle:K,itemRender:oe};ee||Ee.push(p.a.createElement(r,Object(N.a)({},rt,{key:"noPager",page:ee,className:"".concat(L,"-disabled")})));for(var at=1;at<=ee;at+=1){var ot=q===at;Ee.push(p.a.createElement(r,Object(N.a)({},rt,{key:at,page:at,active:ot})))}}else{var Pe=k?z.prev_3:z.prev_5,Se=k?z.next_3:z.next_5;_e&&(te=p.a.createElement("li",{title:K?Pe:null,key:"prev",onClick:this.jumpPrev,tabIndex:"0",onKeyPress:this.runIfEnterJumpPrev,className:n()("".concat(L,"-jump-prev"),Object(v.a)({},"".concat(L,"-jump-prev-custom-icon"),!!xe))},oe(this.getJumpPrevPage(),"jump-prev",this.getItemIcon(xe,"prev page"))),J=p.a.createElement("li",{title:K?Se:null,key:"next",tabIndex:"0",onClick:this.jumpNext,onKeyPress:this.runIfEnterJumpNext,className:n()("".concat(L,"-jump-next"),Object(v.a)({},"".concat(L,"-jump-next-custom-icon"),!!le))},oe(this.getJumpNextPage(),"jump-next",this.getItemIcon(le,"next page")))),$=p.a.createElement(r,{locale:z,last:!0,rootPrefixCls:L,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:ee,page:ee,active:!1,showTitle:K,itemRender:oe}),X=p.a.createElement(r,{locale:z,rootPrefixCls:L,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:1,page:1,active:!1,showTitle:K,itemRender:oe});var Je=Math.max(1,q-Te),nt=Math.min(q+Te,ee);q-1<=Te&&(nt=1+Te*2),ee-q<=Te&&(Je=ee-Te*2);for(var We=Je;We<=nt;We+=1){var et=q===We;Ee.push(p.a.createElement(r,{locale:z,rootPrefixCls:L,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:We,page:We,active:et,showTitle:K,itemRender:oe}))}q-1>=Te*2&&q!==1+2&&(Ee[0]=Object(b.cloneElement)(Ee[0],{className:"".concat(L,"-item-after-jump-prev")}),Ee.unshift(te)),ee-q>=Te*2&&q!==ee-2&&(Ee[Ee.length-1]=Object(b.cloneElement)(Ee[Ee.length-1],{className:"".concat(L,"-item-before-jump-next")}),Ee.push(J)),Je!==1&&Ee.unshift(X),nt!==ee&&Ee.push($)}var Me=null;Y&&(Me=p.a.createElement("li",{className:"".concat(L,"-total-text")},Y(H,[H===0?0:(q-1)*ue+1,q*ue>H?H:q*ue])));var Ce=!this.hasPrev()||!ee,Re=!this.hasNext()||!ee;return p.a.createElement("ul",Object(N.a)({className:n()(L,I,Object(v.a)({},"".concat(L,"-disabled"),G)),style:P,unselectable:"unselectable",ref:this.savePaginationNode},Ye),Me,p.a.createElement("li",{title:K?z.prev_page:null,onClick:this.prev,tabIndex:Ce?null:0,onKeyPress:this.runIfEnterPrev,className:n()("".concat(L,"-prev"),Object(v.a)({},"".concat(L,"-disabled"),Ce)),"aria-disabled":Ce},this.renderPrev(ze)),Ee,p.a.createElement("li",{title:K?z.next_page:null,onClick:this.next,tabIndex:Re?null:0,onKeyPress:this.runIfEnterNext,className:n()("".concat(L,"-next"),Object(v.a)({},"".concat(L,"-disabled"),Re)),"aria-disabled":Re},this.renderNext(Xe)),p.a.createElement(u,{disabled:G,locale:z,rootPrefixCls:L,selectComponentClass:me,selectPrefixCls:de,changeSize:this.getShowSizeChanger()?this.changePageSize:null,current:q,pageSize:ue,pageSizeOptions:ae,quickGo:this.shouldDisplayQuickJumper()?this.handleChange:null,goButton:fe}))}}],[{key:"getDerivedStateFromProps",value:function(E,T){var L={};if("current"in E&&(L.current=E.current,E.current!==T.current&&(L.currentInputValue=L.current)),"pageSize"in E&&E.pageSize!==T.pageSize){var I=T.current,P=S(E.pageSize,T,E);I=I>P?P:I,"current"in E||(L.current=I,L.currentInputValue=I),L.pageSize=E.pageSize}return L}}]),g}(p.a.Component);x.defaultProps={defaultCurrent:1,total:0,defaultPageSize:10,onChange:s,className:"",selectPrefixCls:"rc-select",prefixCls:"rc-pagination",selectComponentClass:null,hideOnSinglePage:!1,showPrevNextJumpers:!0,showQuickJumper:!1,showLessItems:!1,showTitle:!0,onShowSizeChange:s,locale:f.a,style:{},itemRender:t,totalBoundaryShowSizeChanger:50};var h=x},"6RRn":function(F,Q,j){"use strict";var N=j("wCXF"),v=j("n6Qo");j.d(Q,"b",function(){return v.a});var C=j("IBYe"),M=j("6eGT"),m=j("hW8S");j.d(Q,"a",function(){return m.a}),Q.c=N.b},"6UM0":function(F,Q,j){var N,v;(function(){var C;(function(){"use strict";var m=[function(p,d,n){var c=n(1).Beautifier,r=n(5).Options;function i(o,u){var f=new c(o,u);return f.beautify()}p.exports=i,p.exports.defaultOptions=function(){return new r}},function(p,d,n){var c=n(2).Output,r=n(3).Token,i=n(4),o=n(5).Options,u=n(7).Tokenizer,f=n(7).line_starters,s=n(7).positionable_operators,l=n(7).TOKEN;function t(k,K){return K.indexOf(k)!==-1}function S(k){return k.replace(/^\s+/g,"")}function x(k){for(var K={},Y=0;Y<k.length;Y++)K[k[Y].replace(/-/g,"_")]=k[Y];return K}function h(k,K){return k&&k.type===l.RESERVED&&k.text===K}function R(k,K){return k&&k.type===l.RESERVED&&t(k.text,K)}var O=["case","return","do","if","throw","else","await","break","continue","async"],g=["before-newline","after-newline","preserve-newline"],_=x(g),E=[_.before_newline,_.preserve_newline],T={BlockStatement:"BlockStatement",Statement:"Statement",ObjectLiteral:"ObjectLiteral",ArrayLiteral:"ArrayLiteral",ForInitializer:"ForInitializer",Conditional:"Conditional",Expression:"Expression"};function L(k,K){if(K.multiline_frame||K.mode===T.ForInitializer||K.mode===T.Conditional)return;k.remove_indent(K.start_line_index)}function I(k){k=k.replace(i.allLineBreaks,`
`);for(var K=[],Y=k.indexOf(`
`);Y!==-1;)K.push(k.substring(0,Y)),k=k.substring(Y+1),Y=k.indexOf(`
`);return k.length&&K.push(k),K}function P(k){return k===T.ArrayLiteral}function G(k){return t(k,[T.Expression,T.ForInitializer,T.Conditional])}function W(k,K){for(var Y=0;Y<k.length;Y++){var ne=k[Y].trim();if(ne.charAt(0)!==K)return!1}return!0}function H(k,K){for(var Y=0,ne=k.length,oe;Y<ne;Y++)if(oe=k[Y],oe&&oe.indexOf(K)!==0)return!1;return!0}function z(k,K){K=K||{},this._source_text=k||"",this._output=null,this._tokens=null,this._last_last_text=null,this._flags=null,this._previous_flags=null,this._flag_store=null,this._options=new o(K)}z.prototype.create_flags=function(k,K){var Y=0;k&&(Y=k.indentation_level,!this._output.just_added_newline()&&k.line_indent_level>Y&&(Y=k.line_indent_level));var ne={mode:K,parent:k,last_token:k?k.last_token:new r(l.START_BLOCK,""),last_word:k?k.last_word:"",declaration_statement:!1,declaration_assignment:!1,multiline_frame:!1,inline_frame:!1,if_block:!1,else_block:!1,class_start_block:!1,do_block:!1,do_while:!1,import_block:!1,in_case_statement:!1,in_case:!1,case_body:!1,case_block:!1,indentation_level:Y,alignment:0,line_indent_level:k?k.line_indent_level:Y,start_line_index:this._output.get_line_number(),ternary_depth:0};return ne},z.prototype._reset=function(k){var K=k.match(/^[\t ]*/)[0];this._last_last_text="",this._output=new c(this._options,K),this._output.raw=this._options.test_output_raw,this._flag_store=[],this.set_mode(T.BlockStatement);var Y=new u(k,this._options);return this._tokens=Y.tokenize(),k},z.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var k,K=this._reset(this._source_text),Y=this._options.eol;this._options.eol==="auto"&&(Y=`
`,K&&i.lineBreak.test(K||"")&&(Y=K.match(i.lineBreak)[0]));for(var ne=this._tokens.next();ne;)this.handle_token(ne),this._last_last_text=this._flags.last_token.text,this._flags.last_token=ne,ne=this._tokens.next();return k=this._output.get_code(Y),k},z.prototype.handle_token=function(k,K){k.type===l.START_EXPR?this.handle_start_expr(k):k.type===l.END_EXPR?this.handle_end_expr(k):k.type===l.START_BLOCK?this.handle_start_block(k):k.type===l.END_BLOCK?this.handle_end_block(k):k.type===l.WORD?this.handle_word(k):k.type===l.RESERVED?this.handle_word(k):k.type===l.SEMICOLON?this.handle_semicolon(k):k.type===l.STRING?this.handle_string(k):k.type===l.EQUALS?this.handle_equals(k):k.type===l.OPERATOR?this.handle_operator(k):k.type===l.COMMA?this.handle_comma(k):k.type===l.BLOCK_COMMENT?this.handle_block_comment(k,K):k.type===l.COMMENT?this.handle_comment(k,K):k.type===l.DOT?this.handle_dot(k):k.type===l.EOF?this.handle_eof(k):k.type===l.UNKNOWN?this.handle_unknown(k,K):this.handle_unknown(k,K)},z.prototype.handle_whitespace_and_comments=function(k,K){var Y=k.newlines,ne=this._options.keep_array_indentation&&P(this._flags.mode);if(k.comments_before)for(var oe=k.comments_before.next();oe;)this.handle_whitespace_and_comments(oe,K),this.handle_token(oe,K),oe=k.comments_before.next();if(ne)for(var _e=0;_e<Y;_e+=1)this.print_newline(_e>0,K);else if(this._options.max_preserve_newlines&&Y>this._options.max_preserve_newlines&&(Y=this._options.max_preserve_newlines),this._options.preserve_newlines&&Y>1){this.print_newline(!1,K);for(var xe=1;xe<Y;xe+=1)this.print_newline(!0,K)}};var B=["async","break","continue","return","throw","yield"];z.prototype.allow_wrap_or_preserved_newline=function(k,K){if(K=K===void 0?!1:K,this._output.just_added_newline())return;var Y=this._options.preserve_newlines&&k.newlines||K,ne=t(this._flags.last_token.text,s)||t(k.text,s);if(ne){var oe=t(this._flags.last_token.text,s)&&t(this._options.operator_position,E)||t(k.text,s);Y=Y&&oe}if(Y)this.print_newline(!1,!0);else if(this._options.wrap_line_length){if(R(this._flags.last_token,B))return;this._output.set_wrap_point()}},z.prototype.print_newline=function(k,K){if(!K&&(this._flags.last_token.text!==";"&&this._flags.last_token.text!==","&&this._flags.last_token.text!=="="&&(this._flags.last_token.type!==l.OPERATOR||this._flags.last_token.text==="--"||this._flags.last_token.text==="++")))for(var Y=this._tokens.peek();this._flags.mode===T.Statement&&!(this._flags.if_block&&h(Y,"else"))&&!this._flags.do_block;)this.restore_mode();this._output.add_new_line(k)&&(this._flags.multiline_frame=!0)},z.prototype.print_token_line_indentation=function(k){this._output.just_added_newline()&&(this._options.keep_array_indentation&&k.newlines&&(k.text==="["||P(this._flags.mode))?(this._output.current_line.set_indent(-1),this._output.current_line.push(k.whitespace_before),this._output.space_before_token=!1):this._output.set_indent(this._flags.indentation_level,this._flags.alignment)&&(this._flags.line_indent_level=this._flags.indentation_level))},z.prototype.print_token=function(k){if(this._output.raw){this._output.add_raw_token(k);return}if(this._options.comma_first&&k.previous&&k.previous.type===l.COMMA&&this._output.just_added_newline()&&this._output.previous_line.last()===","){var K=this._output.previous_line.pop();this._output.previous_line.is_empty()&&(this._output.previous_line.push(K),this._output.trim(!0),this._output.current_line.pop(),this._output.trim()),this.print_token_line_indentation(k),this._output.add_token(","),this._output.space_before_token=!0}this.print_token_line_indentation(k),this._output.non_breaking_space=!0,this._output.add_token(k.text),this._output.previous_token_wrapped&&(this._flags.multiline_frame=!0)},z.prototype.indent=function(){this._flags.indentation_level+=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment)},z.prototype.deindent=function(){this._flags.indentation_level>0&&(!this._flags.parent||this._flags.indentation_level>this._flags.parent.indentation_level)&&(this._flags.indentation_level-=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},z.prototype.set_mode=function(k){this._flags?(this._flag_store.push(this._flags),this._previous_flags=this._flags):this._previous_flags=this.create_flags(null,k),this._flags=this.create_flags(this._previous_flags,k),this._output.set_indent(this._flags.indentation_level,this._flags.alignment)},z.prototype.restore_mode=function(){this._flag_store.length>0&&(this._previous_flags=this._flags,this._flags=this._flag_store.pop(),this._previous_flags.mode===T.Statement&&L(this._output,this._previous_flags),this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},z.prototype.start_of_object_property=function(){return this._flags.parent.mode===T.ObjectLiteral&&this._flags.mode===T.Statement&&(this._flags.last_token.text===":"&&this._flags.ternary_depth===0||R(this._flags.last_token,["get","set"]))},z.prototype.start_of_statement=function(k){var K=!1;return K=K||R(this._flags.last_token,["var","let","const"])&&k.type===l.WORD,K=K||h(this._flags.last_token,"do"),K=K||!(this._flags.parent.mode===T.ObjectLiteral&&this._flags.mode===T.Statement)&&R(this._flags.last_token,B)&&!k.newlines,K=K||h(this._flags.last_token,"else")&&!(h(k,"if")&&!k.comments_before),K=K||this._flags.last_token.type===l.END_EXPR&&(this._previous_flags.mode===T.ForInitializer||this._previous_flags.mode===T.Conditional),K=K||this._flags.last_token.type===l.WORD&&this._flags.mode===T.BlockStatement&&!this._flags.in_case&&!(k.text==="--"||k.text==="++")&&this._last_last_text!=="function"&&k.type!==l.WORD&&k.type!==l.RESERVED,K=K||this._flags.mode===T.ObjectLiteral&&(this._flags.last_token.text===":"&&this._flags.ternary_depth===0||R(this._flags.last_token,["get","set"])),K?(this.set_mode(T.Statement),this.indent(),this.handle_whitespace_and_comments(k,!0),this.start_of_object_property()||this.allow_wrap_or_preserved_newline(k,R(k,["do","for","if","while"])),!0):!1},z.prototype.handle_start_expr=function(k){this.start_of_statement(k)||this.handle_whitespace_and_comments(k);var K=T.Expression;if(k.text==="["){if(this._flags.last_token.type===l.WORD||this._flags.last_token.text===")"){R(this._flags.last_token,f)&&(this._output.space_before_token=!0),this.print_token(k),this.set_mode(K),this.indent(),this._options.space_in_paren&&(this._output.space_before_token=!0);return}K=T.ArrayLiteral,P(this._flags.mode)&&((this._flags.last_token.text==="["||this._flags.last_token.text===","&&(this._last_last_text==="]"||this._last_last_text==="}"))&&(this._options.keep_array_indentation||this.print_newline())),t(this._flags.last_token.type,[l.START_EXPR,l.END_EXPR,l.WORD,l.OPERATOR,l.DOT])||(this._output.space_before_token=!0)}else{if(this._flags.last_token.type===l.RESERVED)this._flags.last_token.text==="for"?(this._output.space_before_token=this._options.space_before_conditional,K=T.ForInitializer):t(this._flags.last_token.text,["if","while","switch"])?(this._output.space_before_token=this._options.space_before_conditional,K=T.Conditional):t(this._flags.last_word,["await","async"])?this._output.space_before_token=!0:this._flags.last_token.text==="import"&&k.whitespace_before===""?this._output.space_before_token=!1:(t(this._flags.last_token.text,f)||this._flags.last_token.text==="catch")&&(this._output.space_before_token=!0);else if(this._flags.last_token.type===l.EQUALS||this._flags.last_token.type===l.OPERATOR)this.start_of_object_property()||this.allow_wrap_or_preserved_newline(k);else if(this._flags.last_token.type===l.WORD){this._output.space_before_token=!1;var Y=this._tokens.peek(-3);if(this._options.space_after_named_function&&Y){var ne=this._tokens.peek(-4);R(Y,["async","function"])||Y.text==="*"&&R(ne,["async","function"])?this._output.space_before_token=!0:this._flags.mode===T.ObjectLiteral?(Y.text==="{"||Y.text===","||Y.text==="*"&&(ne.text==="{"||ne.text===","))&&(this._output.space_before_token=!0):this._flags.parent&&this._flags.parent.class_start_block&&(this._output.space_before_token=!0)}}else this.allow_wrap_or_preserved_newline(k);(this._flags.last_token.type===l.RESERVED&&(this._flags.last_word==="function"||this._flags.last_word==="typeof")||this._flags.last_token.text==="*"&&(t(this._last_last_text,["function","yield"])||this._flags.mode===T.ObjectLiteral&&t(this._last_last_text,["{",","])))&&(this._output.space_before_token=this._options.space_after_anon_function)}this._flags.last_token.text===";"||this._flags.last_token.type===l.START_BLOCK?this.print_newline():(this._flags.last_token.type===l.END_EXPR||this._flags.last_token.type===l.START_EXPR||this._flags.last_token.type===l.END_BLOCK||this._flags.last_token.text==="."||this._flags.last_token.type===l.COMMA)&&this.allow_wrap_or_preserved_newline(k,k.newlines),this.print_token(k),this.set_mode(K),this._options.space_in_paren&&(this._output.space_before_token=!0),this.indent()},z.prototype.handle_end_expr=function(k){for(;this._flags.mode===T.Statement;)this.restore_mode();this.handle_whitespace_and_comments(k),this._flags.multiline_frame&&this.allow_wrap_or_preserved_newline(k,k.text==="]"&&P(this._flags.mode)&&!this._options.keep_array_indentation),this._options.space_in_paren&&(this._flags.last_token.type===l.START_EXPR&&!this._options.space_in_empty_paren?(this._output.trim(),this._output.space_before_token=!1):this._output.space_before_token=!0),this.deindent(),this.print_token(k),this.restore_mode(),L(this._output,this._previous_flags),this._flags.do_while&&this._previous_flags.mode===T.Conditional&&(this._previous_flags.mode=T.Expression,this._flags.do_block=!1,this._flags.do_while=!1)},z.prototype.handle_start_block=function(k){this.handle_whitespace_and_comments(k);var K=this._tokens.peek(),Y=this._tokens.peek(1);this._flags.last_word==="switch"&&this._flags.last_token.type===l.END_EXPR?(this.set_mode(T.BlockStatement),this._flags.in_case_statement=!0):this._flags.case_body?this.set_mode(T.BlockStatement):Y&&(t(Y.text,[":",","])&&t(K.type,[l.STRING,l.WORD,l.RESERVED])||t(K.text,["get","set","..."])&&t(Y.type,[l.WORD,l.RESERVED]))?t(this._last_last_text,["class","interface"])&&!t(Y.text,[":",","])?this.set_mode(T.BlockStatement):this.set_mode(T.ObjectLiteral):this._flags.last_token.type===l.OPERATOR&&this._flags.last_token.text==="=>"?this.set_mode(T.BlockStatement):t(this._flags.last_token.type,[l.EQUALS,l.START_EXPR,l.COMMA,l.OPERATOR])||R(this._flags.last_token,["return","throw","import","default"])?this.set_mode(T.ObjectLiteral):this.set_mode(T.BlockStatement),this._flags.last_token&&(R(this._flags.last_token.previous,["class","extends"])&&(this._flags.class_start_block=!0));var ne=!K.comments_before&&K.text==="}",oe=ne&&this._flags.last_word==="function"&&this._flags.last_token.type===l.END_EXPR;if(this._options.brace_preserve_inline){var _e=0,xe=null;this._flags.inline_frame=!0;do if(_e+=1,xe=this._tokens.peek(_e-1),xe.newlines){this._flags.inline_frame=!1;break}while(xe.type!==l.EOF&&!(xe.type===l.END_BLOCK&&xe.opened===k))}(this._options.brace_style==="expand"||this._options.brace_style==="none"&&k.newlines)&&!this._flags.inline_frame?this._flags.last_token.type!==l.OPERATOR&&(oe||this._flags.last_token.type===l.EQUALS||R(this._flags.last_token,O)&&this._flags.last_token.text!=="else")?this._output.space_before_token=!0:this.print_newline(!1,!0):(P(this._previous_flags.mode)&&(this._flags.last_token.type===l.START_EXPR||this._flags.last_token.type===l.COMMA)&&((this._flags.last_token.type===l.COMMA||this._options.space_in_paren)&&(this._output.space_before_token=!0),(this._flags.last_token.type===l.COMMA||this._flags.last_token.type===l.START_EXPR&&this._flags.inline_frame)&&(this.allow_wrap_or_preserved_newline(k),this._previous_flags.multiline_frame=this._previous_flags.multiline_frame||this._flags.multiline_frame,this._flags.multiline_frame=!1)),this._flags.last_token.type!==l.OPERATOR&&this._flags.last_token.type!==l.START_EXPR&&(this._flags.last_token.type===l.START_BLOCK&&!this._flags.inline_frame?this.print_newline():this._output.space_before_token=!0)),this.print_token(k),this.indent(),!ne&&!(this._options.brace_preserve_inline&&this._flags.inline_frame)&&this.print_newline()},z.prototype.handle_end_block=function(k){for(this.handle_whitespace_and_comments(k);this._flags.mode===T.Statement;)this.restore_mode();var K=this._flags.last_token.type===l.START_BLOCK;this._flags.inline_frame&&!K?this._output.space_before_token=!0:this._options.brace_style==="expand"?K||this.print_newline():K||(P(this._flags.mode)&&this._options.keep_array_indentation?(this._options.keep_array_indentation=!1,this.print_newline(),this._options.keep_array_indentation=!0):this.print_newline()),this.restore_mode(),this.print_token(k)},z.prototype.handle_word=function(k){if(k.type===l.RESERVED){if(t(k.text,["set","get"])&&this._flags.mode!==T.ObjectLiteral)k.type=l.WORD;else if(k.text==="import"&&t(this._tokens.peek().text,["(","."]))k.type=l.WORD;else if(t(k.text,["as","from"])&&!this._flags.import_block)k.type=l.WORD;else if(this._flags.mode===T.ObjectLiteral){var K=this._tokens.peek();K.text===":"&&(k.type=l.WORD)}}if(this.start_of_statement(k)?R(this._flags.last_token,["var","let","const"])&&k.type===l.WORD&&(this._flags.declaration_statement=!0):k.newlines&&!G(this._flags.mode)&&(this._flags.last_token.type!==l.OPERATOR||this._flags.last_token.text==="--"||this._flags.last_token.text==="++")&&this._flags.last_token.type!==l.EQUALS&&(this._options.preserve_newlines||!R(this._flags.last_token,["var","let","const","set","get"]))?(this.handle_whitespace_and_comments(k),this.print_newline()):this.handle_whitespace_and_comments(k),this._flags.do_block&&!this._flags.do_while)if(h(k,"while")){this._output.space_before_token=!0,this.print_token(k),this._output.space_before_token=!0,this._flags.do_while=!0;return}else this.print_newline(),this._flags.do_block=!1;if(this._flags.if_block)if(!this._flags.else_block&&h(k,"else"))this._flags.else_block=!0;else{for(;this._flags.mode===T.Statement;)this.restore_mode();this._flags.if_block=!1,this._flags.else_block=!1}if(this._flags.in_case_statement&&R(k,["case","default"])){this.print_newline(),!this._flags.case_block&&(this._flags.case_body||this._options.jslint_happy)&&this.deindent(),this._flags.case_body=!1,this.print_token(k),this._flags.in_case=!0;return}if((this._flags.last_token.type===l.COMMA||this._flags.last_token.type===l.START_EXPR||this._flags.last_token.type===l.EQUALS||this._flags.last_token.type===l.OPERATOR)&&(this.start_of_object_property()||this.allow_wrap_or_preserved_newline(k)),h(k,"function")){(t(this._flags.last_token.text,["}",";"])||this._output.just_added_newline()&&!(t(this._flags.last_token.text,["(","[","{",":","=",","])||this._flags.last_token.type===l.OPERATOR))&&(!this._output.just_added_blankline()&&!k.comments_before&&(this.print_newline(),this.print_newline(!0))),this._flags.last_token.type===l.RESERVED||this._flags.last_token.type===l.WORD?R(this._flags.last_token,["get","set","new","export"])||R(this._flags.last_token,B)?this._output.space_before_token=!0:h(this._flags.last_token,"default")&&this._last_last_text==="export"?this._output.space_before_token=!0:this._flags.last_token.text==="declare"?this._output.space_before_token=!0:this.print_newline():this._flags.last_token.type===l.OPERATOR||this._flags.last_token.text==="="?this._output.space_before_token=!0:!this._flags.multiline_frame&&(G(this._flags.mode)||P(this._flags.mode))||this.print_newline(),this.print_token(k),this._flags.last_word=k.text;return}var Y="NONE";if(this._flags.last_token.type===l.END_BLOCK?this._previous_flags.inline_frame?Y="SPACE":R(k,["else","catch","finally","from"])?this._options.brace_style==="expand"||this._options.brace_style==="end-expand"||this._options.brace_style==="none"&&k.newlines?Y="NEWLINE":(Y="SPACE",this._output.space_before_token=!0):Y="NEWLINE":this._flags.last_token.type===l.SEMICOLON&&this._flags.mode===T.BlockStatement?Y="NEWLINE":this._flags.last_token.type===l.SEMICOLON&&G(this._flags.mode)?Y="SPACE":this._flags.last_token.type===l.STRING?Y="NEWLINE":this._flags.last_token.type===l.RESERVED||this._flags.last_token.type===l.WORD||this._flags.last_token.text==="*"&&(t(this._last_last_text,["function","yield"])||this._flags.mode===T.ObjectLiteral&&t(this._last_last_text,["{",","]))?Y="SPACE":this._flags.last_token.type===l.START_BLOCK?this._flags.inline_frame?Y="SPACE":Y="NEWLINE":this._flags.last_token.type===l.END_EXPR&&(this._output.space_before_token=!0,Y="NEWLINE"),R(k,f)&&this._flags.last_token.text!==")"&&(this._flags.inline_frame||this._flags.last_token.text==="else"||this._flags.last_token.text==="export"?Y="SPACE":Y="NEWLINE"),R(k,["else","catch","finally"]))if((!(this._flags.last_token.type===l.END_BLOCK&&this._previous_flags.mode===T.BlockStatement)||this._options.brace_style==="expand"||this._options.brace_style==="end-expand"||this._options.brace_style==="none"&&k.newlines)&&!this._flags.inline_frame)this.print_newline();else{this._output.trim(!0);var ne=this._output.current_line;ne.last()!=="}"&&this.print_newline(),this._output.space_before_token=!0}else Y==="NEWLINE"?R(this._flags.last_token,O)?this._output.space_before_token=!0:this._flags.last_token.text==="declare"&&R(k,["var","let","const"])?this._output.space_before_token=!0:this._flags.last_token.type!==l.END_EXPR?(this._flags.last_token.type!==l.START_EXPR||!R(k,["var","let","const"]))&&this._flags.last_token.text!==":"&&(h(k,"if")&&h(k.previous,"else")?this._output.space_before_token=!0:this.print_newline()):R(k,f)&&this._flags.last_token.text!==")"&&this.print_newline():this._flags.multiline_frame&&P(this._flags.mode)&&this._flags.last_token.text===","&&this._last_last_text==="}"?this.print_newline():Y==="SPACE"&&(this._output.space_before_token=!0);k.previous&&(k.previous.type===l.WORD||k.previous.type===l.RESERVED)&&(this._output.space_before_token=!0),this.print_token(k),this._flags.last_word=k.text,k.type===l.RESERVED&&(k.text==="do"?this._flags.do_block=!0:k.text==="if"?this._flags.if_block=!0:k.text==="import"?this._flags.import_block=!0:this._flags.import_block&&h(k,"from")&&(this._flags.import_block=!1))},z.prototype.handle_semicolon=function(k){this.start_of_statement(k)?this._output.space_before_token=!1:this.handle_whitespace_and_comments(k);for(var K=this._tokens.peek();this._flags.mode===T.Statement&&!(this._flags.if_block&&h(K,"else"))&&!this._flags.do_block;)this.restore_mode();this._flags.import_block&&(this._flags.import_block=!1),this.print_token(k)},z.prototype.handle_string=function(k){k.text.startsWith("`")&&k.newlines===0&&k.whitespace_before===""&&(k.previous.text===")"||this._flags.last_token.type===l.WORD)||(this.start_of_statement(k)?this._output.space_before_token=!0:(this.handle_whitespace_and_comments(k),this._flags.last_token.type===l.RESERVED||this._flags.last_token.type===l.WORD||this._flags.inline_frame?this._output.space_before_token=!0:this._flags.last_token.type===l.COMMA||this._flags.last_token.type===l.START_EXPR||this._flags.last_token.type===l.EQUALS||this._flags.last_token.type===l.OPERATOR?this.start_of_object_property()||this.allow_wrap_or_preserved_newline(k):k.text.startsWith("`")&&this._flags.last_token.type===l.END_EXPR&&(k.previous.text==="]"||k.previous.text===")")&&k.newlines===0?this._output.space_before_token=!0:this.print_newline())),this.print_token(k)},z.prototype.handle_equals=function(k){this.start_of_statement(k)||this.handle_whitespace_and_comments(k),this._flags.declaration_statement&&(this._flags.declaration_assignment=!0),this._output.space_before_token=!0,this.print_token(k),this._output.space_before_token=!0},z.prototype.handle_comma=function(k){this.handle_whitespace_and_comments(k,!0),this.print_token(k),this._output.space_before_token=!0,this._flags.declaration_statement?(G(this._flags.parent.mode)&&(this._flags.declaration_assignment=!1),this._flags.declaration_assignment?(this._flags.declaration_assignment=!1,this.print_newline(!1,!0)):this._options.comma_first&&this.allow_wrap_or_preserved_newline(k)):this._flags.mode===T.ObjectLiteral||this._flags.mode===T.Statement&&this._flags.parent.mode===T.ObjectLiteral?(this._flags.mode===T.Statement&&this.restore_mode(),this._flags.inline_frame||this.print_newline()):this._options.comma_first&&this.allow_wrap_or_preserved_newline(k)},z.prototype.handle_operator=function(k){var K=k.text==="*"&&(R(this._flags.last_token,["function","yield"])||t(this._flags.last_token.type,[l.START_BLOCK,l.COMMA,l.END_BLOCK,l.SEMICOLON])),Y=t(k.text,["-","+"])&&(t(this._flags.last_token.type,[l.START_BLOCK,l.START_EXPR,l.EQUALS,l.OPERATOR])||t(this._flags.last_token.text,f)||this._flags.last_token.text===",");if(!this.start_of_statement(k)){var ne=!K;this.handle_whitespace_and_comments(k,ne)}if(k.text==="*"&&this._flags.last_token.type===l.DOT){this.print_token(k);return}if(k.text==="::"){this.print_token(k);return}if(this._flags.last_token.type===l.OPERATOR&&t(this._options.operator_position,E)&&this.allow_wrap_or_preserved_newline(k),k.text===":"&&this._flags.in_case){this.print_token(k),this._flags.in_case=!1,this._flags.case_body=!0,this._tokens.peek().type!==l.START_BLOCK?(this.indent(),this.print_newline(),this._flags.case_block=!1):(this._flags.case_block=!0,this._output.space_before_token=!0);return}var oe=!0,_e=!0,xe=!1;if(k.text===":"?this._flags.ternary_depth===0?oe=!1:(this._flags.ternary_depth-=1,xe=!0):k.text==="?"&&(this._flags.ternary_depth+=1),!Y&&!K&&this._options.preserve_newlines&&t(k.text,s)){var le=k.text===":",me=le&&xe,de=le&&!xe;switch(this._options.operator_position){case _.before_newline:this._output.space_before_token=!de,this.print_token(k),(!le||me)&&this.allow_wrap_or_preserved_newline(k),this._output.space_before_token=!0;return;case _.after_newline:this._output.space_before_token=!0,!le||me?this._tokens.peek().newlines?this.print_newline(!1,!0):this.allow_wrap_or_preserved_newline(k):this._output.space_before_token=!1,this.print_token(k),this._output.space_before_token=!0;return;case _.preserve_newline:de||this.allow_wrap_or_preserved_newline(k),oe=!(this._output.just_added_newline()||de),this._output.space_before_token=oe,this.print_token(k),this._output.space_before_token=!0;return}}if(K){this.allow_wrap_or_preserved_newline(k),oe=!1;var ae=this._tokens.peek();_e=ae&&t(ae.type,[l.WORD,l.RESERVED])}else if(k.text==="...")this.allow_wrap_or_preserved_newline(k),oe=this._flags.last_token.type===l.START_BLOCK,_e=!1;else if(t(k.text,["--","++","!","~"])||Y){if((this._flags.last_token.type===l.COMMA||this._flags.last_token.type===l.START_EXPR)&&this.allow_wrap_or_preserved_newline(k),oe=!1,_e=!1,k.newlines&&(k.text==="--"||k.text==="++"||k.text==="~")){var ie=R(this._flags.last_token,O)&&k.newlines;ie&&(this._previous_flags.if_block||this._previous_flags.else_block)&&this.restore_mode(),this.print_newline(ie,!0)}this._flags.last_token.text===";"&&G(this._flags.mode)&&(oe=!0),this._flags.last_token.type===l.RESERVED?oe=!0:this._flags.last_token.type===l.END_EXPR?oe=!(this._flags.last_token.text==="]"&&(k.text==="--"||k.text==="++")):this._flags.last_token.type===l.OPERATOR&&(oe=t(k.text,["--","-","++","+"])&&t(this._flags.last_token.text,["--","-","++","+"]),t(k.text,["+","-"])&&t(this._flags.last_token.text,["--","++"])&&(_e=!0)),(this._flags.mode===T.BlockStatement&&!this._flags.inline_frame||this._flags.mode===T.Statement)&&(this._flags.last_token.text==="{"||this._flags.last_token.text===";")&&this.print_newline()}this._output.space_before_token=this._output.space_before_token||oe,this.print_token(k),this._output.space_before_token=_e},z.prototype.handle_block_comment=function(k,K){if(this._output.raw){this._output.add_raw_token(k),k.directives&&k.directives.preserve==="end"&&(this._output.raw=this._options.test_output_raw);return}if(k.directives){this.print_newline(!1,K),this.print_token(k),k.directives.preserve==="start"&&(this._output.raw=!0),this.print_newline(!1,!0);return}if(!i.newline.test(k.text)&&!k.newlines){this._output.space_before_token=!0,this.print_token(k),this._output.space_before_token=!0;return}else this.print_block_commment(k,K)},z.prototype.print_block_commment=function(k,K){var Y=I(k.text),ne,oe=!1,_e=!1,xe=k.whitespace_before,le=xe.length;if(this.print_newline(!1,K),this.print_token_line_indentation(k),this._output.add_token(Y[0]),this.print_newline(!1,K),Y.length>1){for(Y=Y.slice(1),oe=W(Y,"*"),_e=H(Y,xe),oe&&(this._flags.alignment=1),ne=0;ne<Y.length;ne++)oe?(this.print_token_line_indentation(k),this._output.add_token(S(Y[ne]))):_e&&Y[ne]?(this.print_token_line_indentation(k),this._output.add_token(Y[ne].substring(le))):(this._output.current_line.set_indent(-1),this._output.add_token(Y[ne])),this.print_newline(!1,K);this._flags.alignment=0}},z.prototype.handle_comment=function(k,K){k.newlines?this.print_newline(!1,K):this._output.trim(!0),this._output.space_before_token=!0,this.print_token(k),this.print_newline(!1,K)},z.prototype.handle_dot=function(k){this.start_of_statement(k)||this.handle_whitespace_and_comments(k,!0),this._flags.last_token.text.match("^[0-9]+$")&&(this._output.space_before_token=!0),R(this._flags.last_token,O)?this._output.space_before_token=!1:this.allow_wrap_or_preserved_newline(k,this._flags.last_token.text===")"&&this._options.break_chained_methods),this._options.unindent_chained_methods&&this._output.just_added_newline()&&this.deindent(),this.print_token(k)},z.prototype.handle_unknown=function(k,K){this.print_token(k),k.text[k.text.length-1]===`
`&&this.print_newline(!1,K)},z.prototype.handle_eof=function(k){for(;this._flags.mode===T.Statement;)this.restore_mode();this.handle_whitespace_and_comments(k)},p.exports.Beautifier=z},function(p){function d(r){this.__parent=r,this.__character_count=0,this.__indent_count=-1,this.__alignment_count=0,this.__wrap_point_index=0,this.__wrap_point_character_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}d.prototype.clone_empty=function(){var r=new d(this.__parent);return r.set_indent(this.__indent_count,this.__alignment_count),r},d.prototype.item=function(r){return r<0?this.__items[this.__items.length+r]:this.__items[r]},d.prototype.has_match=function(r){for(var i=this.__items.length-1;i>=0;i--)if(this.__items[i].match(r))return!0;return!1},d.prototype.set_indent=function(r,i){this.is_empty()&&(this.__indent_count=r||0,this.__alignment_count=i||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},d.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},d.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},d.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var r=this.__parent.current_line;return r.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),r.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),r.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count,r.__items[0]===" "&&(r.__items.splice(0,1),r.__character_count-=1),!0}return!1},d.prototype.is_empty=function(){return this.__items.length===0},d.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},d.prototype.push=function(r){this.__items.push(r);var i=r.lastIndexOf(`
`);i!==-1?this.__character_count=r.length-i:this.__character_count+=r.length},d.prototype.pop=function(){var r=null;return this.is_empty()||(r=this.__items.pop(),this.__character_count-=r.length),r},d.prototype._remove_indent=function(){this.__indent_count>0&&(this.__indent_count-=1,this.__character_count-=this.__parent.indent_size)},d.prototype._remove_wrap_indent=function(){this.__wrap_point_indent_count>0&&(this.__wrap_point_indent_count-=1)},d.prototype.trim=function(){for(;this.last()===" ";)this.__items.pop(),this.__character_count-=1},d.prototype.toString=function(){var r="";return this.is_empty()?this.__parent.indent_empty_lines&&(r=this.__parent.get_indent_string(this.__indent_count)):(r=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),r+=this.__items.join("")),r};function n(r,i){this.__cache=[""],this.__indent_size=r.indent_size,this.__indent_string=r.indent_char,r.indent_with_tabs||(this.__indent_string=new Array(r.indent_size+1).join(r.indent_char)),i=i||"",r.indent_level>0&&(i=new Array(r.indent_level+1).join(this.__indent_string)),this.__base_string=i,this.__base_string_length=i.length}n.prototype.get_indent_size=function(r,i){var o=this.__base_string_length;return i=i||0,r<0&&(o=0),o+=r*this.__indent_size,o+=i,o},n.prototype.get_indent_string=function(r,i){var o=this.__base_string;return i=i||0,r<0&&(r=0,o=""),i+=r*this.__indent_size,this.__ensure_cache(i),o+=this.__cache[i],o},n.prototype.__ensure_cache=function(r){for(;r>=this.__cache.length;)this.__add_column()},n.prototype.__add_column=function(){var r=this.__cache.length,i=0,o="";this.__indent_size&&r>=this.__indent_size&&(i=Math.floor(r/this.__indent_size),r-=i*this.__indent_size,o=new Array(i+1).join(this.__indent_string)),r&&(o+=new Array(r+1).join(" ")),this.__cache.push(o)};function c(r,i){this.__indent_cache=new n(r,i),this.raw=!1,this._end_with_newline=r.end_with_newline,this.indent_size=r.indent_size,this.wrap_line_length=r.wrap_line_length,this.indent_empty_lines=r.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new d(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}c.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},c.prototype.get_line_number=function(){return this.__lines.length},c.prototype.get_indent_string=function(r,i){return this.__indent_cache.get_indent_string(r,i)},c.prototype.get_indent_size=function(r,i){return this.__indent_cache.get_indent_size(r,i)},c.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},c.prototype.add_new_line=function(r){return this.is_empty()||!r&&this.just_added_newline()?!1:(this.raw||this.__add_outputline(),!0)},c.prototype.get_code=function(r){this.trim(!0);var i=this.current_line.pop();i&&(i[i.length-1]===`
`&&(i=i.replace(/\n+$/g,"")),this.current_line.push(i)),this._end_with_newline&&this.__add_outputline();var o=this.__lines.join(`
`);return r!==`
`&&(o=o.replace(/[\n]/g,r)),o},c.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},c.prototype.set_indent=function(r,i){return r=r||0,i=i||0,this.next_line.set_indent(r,i),this.__lines.length>1?(this.current_line.set_indent(r,i),!0):(this.current_line.set_indent(),!1)},c.prototype.add_raw_token=function(r){for(var i=0;i<r.newlines;i++)this.__add_outputline();this.current_line.set_indent(-1),this.current_line.push(r.whitespace_before),this.current_line.push(r.text),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1},c.prototype.add_token=function(r){this.__add_space_before_token(),this.current_line.push(r),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=this.current_line._allow_wrap()},c.prototype.__add_space_before_token=function(){this.space_before_token&&!this.just_added_newline()&&(this.non_breaking_space||this.set_wrap_point(),this.current_line.push(" "))},c.prototype.remove_indent=function(r){for(var i=this.__lines.length;r<i;)this.__lines[r]._remove_indent(),r++;this.current_line._remove_wrap_indent()},c.prototype.trim=function(r){for(r=r===void 0?!1:r,this.current_line.trim();r&&this.__lines.length>1&&this.current_line.is_empty();)this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null},c.prototype.just_added_newline=function(){return this.current_line.is_empty()},c.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()},c.prototype.ensure_empty_line_above=function(r,i){for(var o=this.__lines.length-2;o>=0;){var u=this.__lines[o];if(u.is_empty())break;if(u.item(0).indexOf(r)!==0&&u.item(-1)!==i){this.__lines.splice(o+1,0,new d(this)),this.previous_line=this.__lines[this.__lines.length-2];break}o--}},p.exports.Output=c},function(p){function d(n,c,r,i){this.type=n,this.text=c,this.comments_before=null,this.newlines=r||0,this.whitespace_before=i||"",this.parent=null,this.next=null,this.previous=null,this.opened=null,this.closed=null,this.directives=null}p.exports.Token=d},function(p,d){var n="\\x23\\x24\\x40\\x41-\\x5a\\x5f\\x61-\\x7a",c="\\x24\\x30-\\x39\\x41-\\x5a\\x5f\\x61-\\x7a",r="\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05d0-\\u05ea\\u05f0-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u08a0\\u08a2-\\u08ac\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0977\\u0979-\\u097f\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c33\\u0c35-\\u0c39\\u0c3d\\u0c58\\u0c59\\u0c60\\u0c61\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d05-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d60\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e87\\u0e88\\u0e8a\\u0e8d\\u0e94-\\u0e97\\u0e99-\\u0e9f\\u0ea1-\\u0ea3\\u0ea5\\u0ea7\\u0eaa\\u0eab\\u0ead-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f4\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f0\\u1700-\\u170c\\u170e-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1877\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191c\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19c1-\\u19c7\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4b\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1ce9-\\u1cec\\u1cee-\\u1cf1\\u1cf5\\u1cf6\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2119-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u212d\\u212f-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2c2e\\u2c30-\\u2c5e\\u2c60-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u2e2f\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309d-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312d\\u3131-\\u318e\\u31a0-\\u31ba\\u31f0-\\u31ff\\u3400-\\u4db5\\u4e00-\\u9fcc\\ua000-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua697\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua78e\\ua790-\\ua793\\ua7a0-\\ua7aa\\ua7f8-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa80-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uabc0-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc",i="\\u0300-\\u036f\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u0620-\\u0649\\u0672-\\u06d3\\u06e7-\\u06e8\\u06fb-\\u06fc\\u0730-\\u074a\\u0800-\\u0814\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0840-\\u0857\\u08e4-\\u08fe\\u0900-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962-\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09d7\\u09df-\\u09e0\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2-\\u0ae3\\u0ae6-\\u0aef\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b56\\u0b57\\u0b5f-\\u0b60\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c01-\\u0c03\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62-\\u0c63\\u0c66-\\u0c6f\\u0c82\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2-\\u0ce3\\u0ce6-\\u0cef\\u0d02\\u0d03\\u0d46-\\u0d48\\u0d57\\u0d62-\\u0d63\\u0d66-\\u0d6f\\u0d82\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0df2\\u0df3\\u0e34-\\u0e3a\\u0e40-\\u0e45\\u0e50-\\u0e59\\u0eb4-\\u0eb9\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f41-\\u0f47\\u0f71-\\u0f84\\u0f86-\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u1000-\\u1029\\u1040-\\u1049\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u170e-\\u1710\\u1720-\\u1730\\u1740-\\u1750\\u1772\\u1773\\u1780-\\u17b2\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u1810-\\u1819\\u1920-\\u192b\\u1930-\\u193b\\u1951-\\u196d\\u19b0-\\u19c0\\u19c8-\\u19c9\\u19d0-\\u19d9\\u1a00-\\u1a15\\u1a20-\\u1a53\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1b46-\\u1b4b\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c00-\\u1c22\\u1c40-\\u1c49\\u1c5b-\\u1c7d\\u1cd0-\\u1cd2\\u1d00-\\u1dbe\\u1e01-\\u1f15\\u200c\\u200d\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2d81-\\u2d96\\u2de0-\\u2dff\\u3021-\\u3028\\u3099\\u309a\\ua640-\\ua66d\\ua674-\\ua67d\\ua69f\\ua6f0-\\ua6f1\\ua7f8-\\ua800\\ua806\\ua80b\\ua823-\\ua827\\ua880-\\ua881\\ua8b4-\\ua8c4\\ua8d0-\\ua8d9\\ua8f3-\\ua8f7\\ua900-\\ua909\\ua926-\\ua92d\\ua930-\\ua945\\ua980-\\ua983\\ua9b3-\\ua9c0\\uaa00-\\uaa27\\uaa40-\\uaa41\\uaa4c-\\uaa4d\\uaa50-\\uaa59\\uaa7b\\uaae0-\\uaae9\\uaaf2-\\uaaf3\\uabc0-\\uabe1\\uabec\\uabed\\uabf0-\\uabf9\\ufb20-\\ufb28\\ufe00-\\ufe0f\\ufe20-\\ufe26\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f",o="(?:\\\\u[0-9a-fA-F]{4}|["+n+r+"])",u="(?:\\\\u[0-9a-fA-F]{4}|["+c+r+i+"])*";d.identifier=new RegExp(o+u,"g"),d.identifierStart=new RegExp(o),d.identifierMatch=new RegExp("(?:\\\\u[0-9a-fA-F]{4}|["+c+r+i+"])+");var f=/[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/;d.newline=/[\n\r\u2028\u2029]/,d.lineBreak=new RegExp(`\r
|`+d.newline.source),d.allLineBreaks=new RegExp(d.lineBreak.source,"g")},function(p,d,n){var c=n(6).Options,r=["before-newline","after-newline","preserve-newline"];function i(o){c.call(this,o,"js");var u=this.raw_options.brace_style||null;u==="expand-strict"?this.raw_options.brace_style="expand":u==="collapse-preserve-inline"?this.raw_options.brace_style="collapse,preserve-inline":this.raw_options.braces_on_own_line!==void 0&&(this.raw_options.brace_style=this.raw_options.braces_on_own_line?"expand":"collapse");var f=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_preserve_inline=!1,this.brace_style="collapse";for(var s=0;s<f.length;s++)f[s]==="preserve-inline"?this.brace_preserve_inline=!0:this.brace_style=f[s];this.unindent_chained_methods=this._get_boolean("unindent_chained_methods"),this.break_chained_methods=this._get_boolean("break_chained_methods"),this.space_in_paren=this._get_boolean("space_in_paren"),this.space_in_empty_paren=this._get_boolean("space_in_empty_paren"),this.jslint_happy=this._get_boolean("jslint_happy"),this.space_after_anon_function=this._get_boolean("space_after_anon_function"),this.space_after_named_function=this._get_boolean("space_after_named_function"),this.keep_array_indentation=this._get_boolean("keep_array_indentation"),this.space_before_conditional=this._get_boolean("space_before_conditional",!0),this.unescape_strings=this._get_boolean("unescape_strings"),this.e4x=this._get_boolean("e4x"),this.comma_first=this._get_boolean("comma_first"),this.operator_position=this._get_selection("operator_position",r),this.test_output_raw=this._get_boolean("test_output_raw"),this.jslint_happy&&(this.space_after_anon_function=!0)}i.prototype=new c,p.exports.Options=i},function(p){function d(r,i){this.raw_options=n(r,i),this.disabled=this._get_boolean("disabled"),this.eol=this._get_characters("eol","auto"),this.end_with_newline=this._get_boolean("end_with_newline"),this.indent_size=this._get_number("indent_size",4),this.indent_char=this._get_characters("indent_char"," "),this.indent_level=this._get_number("indent_level"),this.preserve_newlines=this._get_boolean("preserve_newlines",!0),this.max_preserve_newlines=this._get_number("max_preserve_newlines",32786),this.preserve_newlines||(this.max_preserve_newlines=0),this.indent_with_tabs=this._get_boolean("indent_with_tabs",this.indent_char===" "),this.indent_with_tabs&&(this.indent_char=" ",this.indent_size===1&&(this.indent_size=4)),this.wrap_line_length=this._get_number("wrap_line_length",this._get_number("max_char")),this.indent_empty_lines=this._get_boolean("indent_empty_lines"),this.templating=this._get_selection_list("templating",["auto","none","django","erb","handlebars","php","smarty"],["auto"])}d.prototype._get_array=function(r,i){var o=this.raw_options[r],u=i||[];return typeof o=="object"?o!==null&&typeof o.concat=="function"&&(u=o.concat()):typeof o=="string"&&(u=o.split(/[^a-zA-Z0-9_\/\-]+/)),u},d.prototype._get_boolean=function(r,i){var o=this.raw_options[r],u=o===void 0?!!i:!!o;return u},d.prototype._get_characters=function(r,i){var o=this.raw_options[r],u=i||"";return typeof o=="string"&&(u=o.replace(/\\r/,"\r").replace(/\\n/,`
`).replace(/\\t/," ")),u},d.prototype._get_number=function(r,i){var o=this.raw_options[r];i=parseInt(i,10),isNaN(i)&&(i=0);var u=parseInt(o,10);return isNaN(u)&&(u=i),u},d.prototype._get_selection=function(r,i,o){var u=this._get_selection_list(r,i,o);if(u.length!==1)throw new Error("Invalid Option Value: The option '"+r+`' can only be one of the following values:
`+i+`
You passed in: '`+this.raw_options[r]+"'");return u[0]},d.prototype._get_selection_list=function(r,i,o){if(!i||i.length===0)throw new Error("Selection list cannot be empty.");if(o=o||[i[0]],!this._is_valid_selection(o,i))throw new Error("Invalid Default Value!");var u=this._get_array(r,o);if(!this._is_valid_selection(u,i))throw new Error("Invalid Option Value: The option '"+r+`' can contain only the following values:
`+i+`
You passed in: '`+this.raw_options[r]+"'");return u},d.prototype._is_valid_selection=function(r,i){return r.length&&i.length&&!r.some(function(o){return i.indexOf(o)===-1})};function n(r,i){var o={};r=c(r);var u;for(u in r)u!==i&&(o[u]=r[u]);if(i&&r[i])for(u in r[i])o[u]=r[i][u];return o}function c(r){var i={},o;for(o in r){var u=o.replace(/-/g,"_");i[u]=r[o]}return i}p.exports.Options=d,p.exports.normalizeOpts=c,p.exports.mergeOpts=n},function(p,d,n){var c=n(8).InputScanner,r=n(9).Tokenizer,i=n(9).TOKEN,o=n(13).Directives,u=n(4),f=n(12).Pattern,s=n(14).TemplatablePattern;function l(W,H){return H.indexOf(W)!==-1}var t={START_EXPR:"TK_START_EXPR",END_EXPR:"TK_END_EXPR",START_BLOCK:"TK_START_BLOCK",END_BLOCK:"TK_END_BLOCK",WORD:"TK_WORD",RESERVED:"TK_RESERVED",SEMICOLON:"TK_SEMICOLON",STRING:"TK_STRING",EQUALS:"TK_EQUALS",OPERATOR:"TK_OPERATOR",COMMA:"TK_COMMA",BLOCK_COMMENT:"TK_BLOCK_COMMENT",COMMENT:"TK_COMMENT",DOT:"TK_DOT",UNKNOWN:"TK_UNKNOWN",START:i.START,RAW:i.RAW,EOF:i.EOF},S=new o(/\/\*/,/\*\//),x=/0[xX][0123456789abcdefABCDEF_]*n?|0[oO][01234567_]*n?|0[bB][01_]*n?|\d[\d_]*n|(?:\.\d[\d_]*|\d[\d_]*\.?[\d_]*)(?:[eE][+-]?[\d_]+)?/,h=/[0-9]/,R=/[^\d\.]/,O=">>> === !== &&= ??= ||= << && >= ** != == <= >> || ?? |> < / - + > : & % ? ^ | *".split(" "),g=">>>= ... >>= <<= === >>> !== **= &&= ??= ||= => ^= :: /= << <= == && -= >= >> != -- += ** || ?? ++ %= &= *= |= |> = ! ? > < : / ^ - + * & % ~ |";g=g.replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&"),g="\\?\\.(?!\\d) "+g,g=g.replace(/ /g,"|");var _=new RegExp(g),E="continue,try,throw,return,var,let,const,if,switch,case,default,for,while,break,function,import,export".split(","),T=E.concat(["do","in","of","else","get","set","new","catch","finally","typeof","yield","async","await","from","as","class","extends"]),L=new RegExp("^(?:"+T.join("|")+")$"),I,P=function(W,H){r.call(this,W,H),this._patterns.whitespace=this._patterns.whitespace.matching(/\u00A0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff/.source,/\u2028\u2029/.source);var z=new f(this._input),B=new s(this._input).read_options(this._options);this.__patterns={template:B,identifier:B.starting_with(u.identifier).matching(u.identifierMatch),number:z.matching(x),punct:z.matching(_),comment:z.starting_with(/\/\//).until(/[\n\r\u2028\u2029]/),block_comment:z.starting_with(/\/\*/).until_after(/\*\//),html_comment_start:z.matching(/<!--/),html_comment_end:z.matching(/-->/),include:z.starting_with(/#include/).until_after(u.lineBreak),shebang:z.starting_with(/#!/).until_after(u.lineBreak),xml:z.matching(/[\s\S]*?<(\/?)([-a-zA-Z:0-9_.]+|{[^}]+?}|!\[CDATA\[[^\]]*?\]\]|)(\s*{[^}]+?}|\s+[-a-zA-Z:0-9_.]+|\s+[-a-zA-Z:0-9_.]+\s*=\s*('[^']*'|"[^"]*"|{([^{}]|{[^}]+?})+?}))*\s*(\/?)\s*>/),single_quote:B.until(/['\\\n\r\u2028\u2029]/),double_quote:B.until(/["\\\n\r\u2028\u2029]/),template_text:B.until(/[`\\$]/),template_expression:B.until(/[`}\\]/)}};P.prototype=new r,P.prototype._is_comment=function(W){return W.type===t.COMMENT||W.type===t.BLOCK_COMMENT||W.type===t.UNKNOWN},P.prototype._is_opening=function(W){return W.type===t.START_BLOCK||W.type===t.START_EXPR},P.prototype._is_closing=function(W,H){return(W.type===t.END_BLOCK||W.type===t.END_EXPR)&&H&&(W.text==="]"&&H.text==="["||W.text===")"&&H.text==="("||W.text==="}"&&H.text==="{")},P.prototype._reset=function(){I=!1},P.prototype._get_next_token=function(W,H){var z=null;this._readWhitespace();var B=this._input.peek();return B===null?this._create_token(t.EOF,""):(z=z||this._read_non_javascript(B),z=z||this._read_string(B),z=z||this._read_word(W),z=z||this._read_singles(B),z=z||this._read_comment(B),z=z||this._read_regexp(B,W),z=z||this._read_xml(B,W),z=z||this._read_punctuation(),z=z||this._create_token(t.UNKNOWN,this._input.next()),z)},P.prototype._read_word=function(W){var H;if(H=this.__patterns.identifier.read(),H!=="")return H=H.replace(u.allLineBreaks,`
`),!(W.type===t.DOT||W.type===t.RESERVED&&(W.text==="set"||W.text==="get"))&&L.test(H)?(H==="in"||H==="of")&&(W.type===t.WORD||W.type===t.STRING)?this._create_token(t.OPERATOR,H):this._create_token(t.RESERVED,H):this._create_token(t.WORD,H);if(H=this.__patterns.number.read(),H!=="")return this._create_token(t.WORD,H)},P.prototype._read_singles=function(W){var H=null;return W==="("||W==="["?H=this._create_token(t.START_EXPR,W):W===")"||W==="]"?H=this._create_token(t.END_EXPR,W):W==="{"?H=this._create_token(t.START_BLOCK,W):W==="}"?H=this._create_token(t.END_BLOCK,W):W===";"?H=this._create_token(t.SEMICOLON,W):W==="."&&R.test(this._input.peek(1))?H=this._create_token(t.DOT,W):W===","&&(H=this._create_token(t.COMMA,W)),H&&this._input.next(),H},P.prototype._read_punctuation=function(){var W=this.__patterns.punct.read();if(W!=="")return W==="="?this._create_token(t.EQUALS,W):W==="?."?this._create_token(t.DOT,W):this._create_token(t.OPERATOR,W)},P.prototype._read_non_javascript=function(W){var H="";if(W==="#"){if(this._is_first_token()&&(H=this.__patterns.shebang.read(),H))return this._create_token(t.UNKNOWN,H.trim()+`
`);if(H=this.__patterns.include.read(),H)return this._create_token(t.UNKNOWN,H.trim()+`
`);W=this._input.next();var z="#";if(this._input.hasNext()&&this._input.testChar(h)){do W=this._input.next(),z+=W;while(this._input.hasNext()&&W!=="#"&&W!=="=");return W==="#"||(this._input.peek()==="["&&this._input.peek(1)==="]"?(z+="[]",this._input.next(),this._input.next()):this._input.peek()==="{"&&this._input.peek(1)==="}"&&(z+="{}",this._input.next(),this._input.next())),this._create_token(t.WORD,z)}this._input.back()}else if(W==="<"&&this._is_first_token()){if(H=this.__patterns.html_comment_start.read(),H){for(;this._input.hasNext()&&!this._input.testChar(u.newline);)H+=this._input.next();return I=!0,this._create_token(t.COMMENT,H)}}else if(I&&W==="-"&&(H=this.__patterns.html_comment_end.read(),H))return I=!1,this._create_token(t.COMMENT,H);return null},P.prototype._read_comment=function(W){var H=null;if(W==="/"){var z="";if(this._input.peek(1)==="*"){z=this.__patterns.block_comment.read();var B=S.get_directives(z);B&&B.ignore==="start"&&(z+=S.readIgnored(this._input)),z=z.replace(u.allLineBreaks,`
`),H=this._create_token(t.BLOCK_COMMENT,z),H.directives=B}else this._input.peek(1)==="/"&&(z=this.__patterns.comment.read(),H=this._create_token(t.COMMENT,z))}return H},P.prototype._read_string=function(W){if(W==="`"||W==="'"||W==='"'){var H=this._input.next();return this.has_char_escapes=!1,W==="`"?H+=this._read_string_recursive("`",!0,"${"):H+=this._read_string_recursive(W),this.has_char_escapes&&this._options.unescape_strings&&(H=G(H)),this._input.peek()===W&&(H+=this._input.next()),H=H.replace(u.allLineBreaks,`
`),this._create_token(t.STRING,H)}return null},P.prototype._allow_regexp_or_xml=function(W){return W.type===t.RESERVED&&l(W.text,["return","case","throw","else","do","typeof","yield"])||W.type===t.END_EXPR&&W.text===")"&&W.opened.previous.type===t.RESERVED&&l(W.opened.previous.text,["if","while","for"])||l(W.type,[t.COMMENT,t.START_EXPR,t.START_BLOCK,t.START,t.END_BLOCK,t.OPERATOR,t.EQUALS,t.EOF,t.SEMICOLON,t.COMMA])},P.prototype._read_regexp=function(W,H){if(W==="/"&&this._allow_regexp_or_xml(H)){for(var z=this._input.next(),B=!1,k=!1;this._input.hasNext()&&(B||k||this._input.peek()!==W)&&!this._input.testChar(u.newline);)z+=this._input.peek(),B?B=!1:(B=this._input.peek()==="\\",this._input.peek()==="["?k=!0:this._input.peek()==="]"&&(k=!1)),this._input.next();return this._input.peek()===W&&(z+=this._input.next(),z+=this._input.read(u.identifier)),this._create_token(t.STRING,z)}return null},P.prototype._read_xml=function(W,H){if(this._options.e4x&&W==="<"&&this._allow_regexp_or_xml(H)){var z="",B=this.__patterns.xml.read_match();if(B){for(var k=B[2].replace(/^{\s+/,"{").replace(/\s+}$/,"}"),K=k.indexOf("{")===0,Y=0;B;){var ne=!!B[1],oe=B[2],_e=!!B[B.length-1]||oe.slice(0,8)==="![CDATA[";if(!_e&&(oe===k||K&&oe.replace(/^{\s+/,"{").replace(/\s+}$/,"}"))&&(ne?--Y:++Y),z+=B[0],Y<=0)break;B=this.__patterns.xml.read_match()}return B||(z+=this._input.match(/[\s\S]*/g)[0]),z=z.replace(u.allLineBreaks,`
`),this._create_token(t.STRING,z)}}return null};function G(W){for(var H="",z=0,B=new c(W),k=null;B.hasNext();)if(k=B.match(/([\s]|[^\\]|\\\\)+/g),k&&(H+=k[0]),B.peek()==="\\"){if(B.next(),B.peek()==="x")k=B.match(/x([0-9A-Fa-f]{2})/g);else if(B.peek()==="u")k=B.match(/u([0-9A-Fa-f]{4})/g);else{H+="\\",B.hasNext()&&(H+=B.next());continue}if(!k)return W;if(z=parseInt(k[1],16),z>126&&z<=255&&k[0].indexOf("x")===0)return W;if(z>=0&&z<32){H+="\\"+k[0];continue}else z===34||z===39||z===92?H+="\\"+String.fromCharCode(z):H+=String.fromCharCode(z)}return H}P.prototype._read_string_recursive=function(W,H,z){var B,k;W==="'"?k=this.__patterns.single_quote:W==='"'?k=this.__patterns.double_quote:W==="`"?k=this.__patterns.template_text:W==="}"&&(k=this.__patterns.template_expression);for(var K=k.read(),Y="";this._input.hasNext();){if(Y=this._input.next(),Y===W||!H&&u.newline.test(Y)){this._input.back();break}else Y==="\\"&&this._input.hasNext()?(B=this._input.peek(),B==="x"||B==="u"?this.has_char_escapes=!0:B==="\r"&&this._input.peek(1)===`
`&&this._input.next(),Y+=this._input.next()):z&&(z==="${"&&Y==="$"&&this._input.peek()==="{"&&(Y+=this._input.next()),z===Y&&(W==="`"?Y+=this._read_string_recursive("}",H,"`"):Y+=this._read_string_recursive("`",H,"${"),this._input.hasNext()&&(Y+=this._input.next())));Y+=k.read(),K+=Y}return K},p.exports.Tokenizer=P,p.exports.TOKEN=t,p.exports.positionable_operators=O.slice(),p.exports.line_starters=E.slice()},function(p){var d=RegExp.prototype.hasOwnProperty("sticky");function n(c){this.__input=c||"",this.__input_length=this.__input.length,this.__position=0}n.prototype.restart=function(){this.__position=0},n.prototype.back=function(){this.__position>0&&(this.__position-=1)},n.prototype.hasNext=function(){return this.__position<this.__input_length},n.prototype.next=function(){var c=null;return this.hasNext()&&(c=this.__input.charAt(this.__position),this.__position+=1),c},n.prototype.peek=function(c){var r=null;return c=c||0,c+=this.__position,c>=0&&c<this.__input_length&&(r=this.__input.charAt(c)),r},n.prototype.__match=function(c,r){c.lastIndex=r;var i=c.exec(this.__input);return i&&!(d&&c.sticky)&&(i.index!==r&&(i=null)),i},n.prototype.test=function(c,r){return r=r||0,r+=this.__position,r>=0&&r<this.__input_length?!!this.__match(c,r):!1},n.prototype.testChar=function(c,r){var i=this.peek(r);return c.lastIndex=0,i!==null&&c.test(i)},n.prototype.match=function(c){var r=this.__match(c,this.__position);return r?this.__position+=r[0].length:r=null,r},n.prototype.read=function(c,r,i){var o="",u;return c&&(u=this.match(c),u&&(o+=u[0])),r&&(u||!c)&&(o+=this.readUntil(r,i)),o},n.prototype.readUntil=function(c,r){var i="",o=this.__position;c.lastIndex=this.__position;var u=c.exec(this.__input);return u?(o=u.index,r&&(o+=u[0].length)):o=this.__input_length,i=this.__input.substring(this.__position,o),this.__position=o,i},n.prototype.readUntilAfter=function(c){return this.readUntil(c,!0)},n.prototype.get_regexp=function(c,r){var i=null,o="g";return r&&d&&(o="y"),typeof c=="string"&&c!==""?i=new RegExp(c,o):c&&(i=new RegExp(c.source,o)),i},n.prototype.get_literal_regexp=function(c){return RegExp(c.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))},n.prototype.peekUntilAfter=function(c){var r=this.__position,i=this.readUntilAfter(c);return this.__position=r,i},n.prototype.lookBack=function(c){var r=this.__position-1;return r>=c.length&&this.__input.substring(r-c.length,r).toLowerCase()===c},p.exports.InputScanner=n},function(p,d,n){var c=n(8).InputScanner,r=n(3).Token,i=n(10).TokenStream,o=n(11).WhitespacePattern,u={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"},f=function(s,l){this._input=new c(s),this._options=l||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new o(this._input)};f.prototype.tokenize=function(){this._input.restart(),this.__tokens=new i,this._reset();for(var s,l=new r(u.START,""),t=null,S=[],x=new i;l.type!==u.EOF;){for(s=this._get_next_token(l,t);this._is_comment(s);)x.add(s),s=this._get_next_token(l,t);x.isEmpty()||(s.comments_before=x,x=new i),s.parent=t,this._is_opening(s)?(S.push(t),t=s):t&&this._is_closing(s,t)&&(s.opened=t,t.closed=s,t=S.pop(),s.parent=t),s.previous=l,l.next=s,this.__tokens.add(s),l=s}return this.__tokens},f.prototype._is_first_token=function(){return this.__tokens.isEmpty()},f.prototype._reset=function(){},f.prototype._get_next_token=function(s,l){this._readWhitespace();var t=this._input.read(/.+/g);return t?this._create_token(u.RAW,t):this._create_token(u.EOF,"")},f.prototype._is_comment=function(s){return!1},f.prototype._is_opening=function(s){return!1},f.prototype._is_closing=function(s,l){return!1},f.prototype._create_token=function(s,l){var t=new r(s,l,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token);return t},f.prototype._readWhitespace=function(){return this._patterns.whitespace.read()},p.exports.Tokenizer=f,p.exports.TOKEN=u},function(p){function d(n){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=n}d.prototype.restart=function(){this.__position=0},d.prototype.isEmpty=function(){return this.__tokens_length===0},d.prototype.hasNext=function(){return this.__position<this.__tokens_length},d.prototype.next=function(){var n=null;return this.hasNext()&&(n=this.__tokens[this.__position],this.__position+=1),n},d.prototype.peek=function(n){var c=null;return n=n||0,n+=this.__position,n>=0&&n<this.__tokens_length&&(c=this.__tokens[n]),c},d.prototype.add=function(n){this.__parent_token&&(n.parent=this.__parent_token),this.__tokens.push(n),this.__tokens_length+=1},p.exports.TokenStream=d},function(p,d,n){var c=n(12).Pattern;function r(i,o){c.call(this,i,o),o?this._line_regexp=this._input.get_regexp(o._line_regexp):this.__set_whitespace_patterns("",""),this.newline_count=0,this.whitespace_before_token=""}r.prototype=new c,r.prototype.__set_whitespace_patterns=function(i,o){i+="\\t ",o+="\\n\\r",this._match_pattern=this._input.get_regexp("["+i+o+"]+",!0),this._newline_regexp=this._input.get_regexp("\\r\\n|["+o+"]")},r.prototype.read=function(){this.newline_count=0,this.whitespace_before_token="";var i=this._input.read(this._match_pattern);if(i===" ")this.whitespace_before_token=" ";else if(i){var o=this.__split(this._newline_regexp,i);this.newline_count=o.length-1,this.whitespace_before_token=o[this.newline_count]}return i},r.prototype.matching=function(i,o){var u=this._create();return u.__set_whitespace_patterns(i,o),u._update(),u},r.prototype._create=function(){return new r(this._input,this)},r.prototype.__split=function(i,o){i.lastIndex=0;for(var u=0,f=[],s=i.exec(o);s;)f.push(o.substring(u,s.index)),u=s.index+s[0].length,s=i.exec(o);return u<o.length?f.push(o.substring(u,o.length)):f.push(""),f},p.exports.WhitespacePattern=r},function(p){function d(n,c){this._input=n,this._starting_pattern=null,this._match_pattern=null,this._until_pattern=null,this._until_after=!1,c&&(this._starting_pattern=this._input.get_regexp(c._starting_pattern,!0),this._match_pattern=this._input.get_regexp(c._match_pattern,!0),this._until_pattern=this._input.get_regexp(c._until_pattern),this._until_after=c._until_after)}d.prototype.read=function(){var n=this._input.read(this._starting_pattern);return(!this._starting_pattern||n)&&(n+=this._input.read(this._match_pattern,this._until_pattern,this._until_after)),n},d.prototype.read_match=function(){return this._input.match(this._match_pattern)},d.prototype.until_after=function(n){var c=this._create();return c._until_after=!0,c._until_pattern=this._input.get_regexp(n),c._update(),c},d.prototype.until=function(n){var c=this._create();return c._until_after=!1,c._until_pattern=this._input.get_regexp(n),c._update(),c},d.prototype.starting_with=function(n){var c=this._create();return c._starting_pattern=this._input.get_regexp(n,!0),c._update(),c},d.prototype.matching=function(n){var c=this._create();return c._match_pattern=this._input.get_regexp(n,!0),c._update(),c},d.prototype._create=function(){return new d(this._input,this)},d.prototype._update=function(){},p.exports.Pattern=d},function(p){function d(n,c){n=typeof n=="string"?n:n.source,c=typeof c=="string"?c:c.source,this.__directives_block_pattern=new RegExp(n+/ beautify( \w+[:]\w+)+ /.source+c,"g"),this.__directive_pattern=/ (\w+)[:](\w+)/g,this.__directives_end_ignore_pattern=new RegExp(n+/\sbeautify\signore:end\s/.source+c,"g")}d.prototype.get_directives=function(n){if(!n.match(this.__directives_block_pattern))return null;var c={};this.__directive_pattern.lastIndex=0;for(var r=this.__directive_pattern.exec(n);r;)c[r[1]]=r[2],r=this.__directive_pattern.exec(n);return c},d.prototype.readIgnored=function(n){return n.readUntilAfter(this.__directives_end_ignore_pattern)},p.exports.Directives=d},function(p,d,n){var c=n(12).Pattern,r={django:!1,erb:!1,handlebars:!1,php:!1,smarty:!1};function i(o,u){c.call(this,o,u),this.__template_pattern=null,this._disabled=Object.assign({},r),this._excluded=Object.assign({},r),u&&(this.__template_pattern=this._input.get_regexp(u.__template_pattern),this._excluded=Object.assign(this._excluded,u._excluded),this._disabled=Object.assign(this._disabled,u._disabled));var f=new c(o);this.__patterns={handlebars_comment:f.starting_with(/{{!--/).until_after(/--}}/),handlebars_unescaped:f.starting_with(/{{{/).until_after(/}}}/),handlebars:f.starting_with(/{{/).until_after(/}}/),php:f.starting_with(/<\?(?:[= ]|php)/).until_after(/\?>/),erb:f.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:f.starting_with(/{%/).until_after(/%}/),django_value:f.starting_with(/{{/).until_after(/}}/),django_comment:f.starting_with(/{#/).until_after(/#}/),smarty:f.starting_with(/{(?=[^}{\s\n])/).until_after(/[^\s\n]}/),smarty_comment:f.starting_with(/{\*/).until_after(/\*}/),smarty_literal:f.starting_with(/{literal}/).until_after(/{\/literal}/)}}i.prototype=new c,i.prototype._create=function(){return new i(this._input,this)},i.prototype._update=function(){this.__set_templated_pattern()},i.prototype.disable=function(o){var u=this._create();return u._disabled[o]=!0,u._update(),u},i.prototype.read_options=function(o){var u=this._create();for(var f in r)u._disabled[f]=o.templating.indexOf(f)===-1;return u._update(),u},i.prototype.exclude=function(o){var u=this._create();return u._excluded[o]=!0,u._update(),u},i.prototype.read=function(){var o="";this._match_pattern?o=this._input.read(this._starting_pattern):o=this._input.read(this._starting_pattern,this.__template_pattern);for(var u=this._read_template();u;)this._match_pattern?u+=this._input.read(this._match_pattern):u+=this._input.readUntil(this.__template_pattern),o+=u,u=this._read_template();return this._until_after&&(o+=this._input.readUntilAfter(this._until_pattern)),o},i.prototype.__set_templated_pattern=function(){var o=[];this._disabled.php||o.push(this.__patterns.php._starting_pattern.source),this._disabled.handlebars||o.push(this.__patterns.handlebars._starting_pattern.source),this._disabled.erb||o.push(this.__patterns.erb._starting_pattern.source),this._disabled.django||(o.push(this.__patterns.django._starting_pattern.source),o.push(this.__patterns.django_value._starting_pattern.source),o.push(this.__patterns.django_comment._starting_pattern.source)),this._disabled.smarty||o.push(this.__patterns.smarty._starting_pattern.source),this._until_pattern&&o.push(this._until_pattern.source),this.__template_pattern=this._input.get_regexp("(?:"+o.join("|")+")")},i.prototype._read_template=function(){var o="",u=this._input.peek();if(u==="<"){var f=this._input.peek(1);!this._disabled.php&&!this._excluded.php&&f==="?"&&(o=o||this.__patterns.php.read()),!this._disabled.erb&&!this._excluded.erb&&f==="%"&&(o=o||this.__patterns.erb.read())}else u==="{"&&(!this._disabled.handlebars&&!this._excluded.handlebars&&(o=o||this.__patterns.handlebars_comment.read(),o=o||this.__patterns.handlebars_unescaped.read(),o=o||this.__patterns.handlebars.read()),this._disabled.django||(!this._excluded.django&&!this._excluded.handlebars&&(o=o||this.__patterns.django_value.read()),this._excluded.django||(o=o||this.__patterns.django_comment.read(),o=o||this.__patterns.django.read())),this._disabled.smarty||this._disabled.django&&this._disabled.handlebars&&(o=o||this.__patterns.smarty_comment.read(),o=o||this.__patterns.smarty_literal.read(),o=o||this.__patterns.smarty.read()));return o},p.exports.TemplatablePattern=i}],y={};function w(p){var d=y[p];if(d!==void 0)return d.exports;var n=y[p]={exports:{}};return m[p](n,n.exports,w),n.exports}var b=w(0);C=b})();var M=C;!(N=[],v=function(){return{js_beautify:M}}.apply(Q,N),v!==void 0&&(F.exports=v))})()},"6eGT":function(F,Q,j){"use strict";function N(v){return null}Q.a=N},"7Cbv":function(F,Q,j){"use strict";var N=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto!="undefined"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),v=new Uint8Array(16);function C(){if(!N)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return N(v)}var M=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function m(r){return typeof r=="string"&&M.test(r)}for(var y=m,w=[],b=0;b<256;++b)w.push((b+256).toString(16).substr(1));function p(r){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=(w[r[i+0]]+w[r[i+1]]+w[r[i+2]]+w[r[i+3]]+"-"+w[r[i+4]]+w[r[i+5]]+"-"+w[r[i+6]]+w[r[i+7]]+"-"+w[r[i+8]]+w[r[i+9]]+"-"+w[r[i+10]]+w[r[i+11]]+w[r[i+12]]+w[r[i+13]]+w[r[i+14]]+w[r[i+15]]).toLowerCase();if(!y(o))throw TypeError("Stringified UUID is invalid");return o}var d=p;function n(r,i,o){r=r||{};var u=r.random||(r.rng||C)();if(u[6]=u[6]&15|64,u[8]=u[8]&63|128,i){o=o||0;for(var f=0;f<16;++f)i[o+f]=u[f];return i}return d(u)}var c=Q.a=n},"7ahc":function(F,Q,j){"use strict";j.d(Q,"a",function(){return S});var N=j("k1fw"),v=j("0Owb"),C=j("+L6B"),M=j("2/Rp"),m=j("y8nQ"),y=j("Vl3Y"),w=j("tJVT"),b=j("OaEy"),p=j("2fM7"),d=j("cDcd"),n=j.n(d),c=j("VrN/"),r=j.n(c),i=j("p77/"),o=j.n(i),u=j("c5Ni"),f=j.n(u),s=p.a.Option,l={labelCol:{span:4},wrapperCol:{span:20}},t={asp:["ASP","vbscript"],actionscript:["ActionScript(3.0)/Flash/Flex","clike"],bash:["Bash/Bat","shell"],css:["CSS","css"],c:["C","clike"],cpp:["C++","clike"],csharp:["C#","clike"],coffeescript:["CoffeeScript","coffeescript"],d:["D","d"],dart:["Dart","dart"],delphi:["Delphi/Pascal","pascal"],erlang:["Erlang","erlang"],go:["Golang","go"],groovy:["Groovy","groovy"],html:["HTML","text/html"],java:["Java","clike"],json:["JSON","text/json"],javascript:["Javascript","javascript"],lua:["Lua","lua"],less:["LESS","css"],markdown:["Markdown","gfm"],"objective-c":["Objective-C","clike"],php:["PHP","php"],perl:["Perl","perl"],python:["Python","python"],r:["R","r"],rst:["reStructedText","rst"],ruby:["Ruby","ruby"],sql:["SQL","sql"],sass:["SASS/SCSS","sass"],shell:["Shell","shell"],scala:["Scala","clike"],swift:["Swift","clike"],vb:["VB/VBScript","vb"],xml:["XML","text/xml"],yaml:["YAML","yaml"]};Q.b=function(x){var h=x.callback,R=x.onCancel,O=Object(d.useState)("python"),g=Object(w.a)(O,2),_=g[0],E=g[1];function T(I){E(t[I][1])}function L(I){h(I)}return n.a.createElement(y.a,Object(v.a)({},l,{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:L}),n.a.createElement(y.a.Item,{label:"\u4EE3\u7801\u8BED\u8A00",name:"language"},n.a.createElement(p.a,{onChange:T},Object.keys(t).map(function(I){return n.a.createElement(s,{key:I,value:I},t[I][0])}))),n.a.createElement(y.a.Item,{label:"\u4EE3\u7801\u5185\u5BB9",name:"content",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u4EE3\u7801\u5185\u5BB9"}]},n.a.createElement(S,{mode:_})),n.a.createElement("div",{className:"flex-container flex-end"},n.a.createElement(M.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),n.a.createElement(M.a,{type:"ghost",onClick:R},"\u53D6\u6D88")))};function S(x){var h=x.value,R=x.onChange,O=x.mode,g=x.options,_=g===void 0?{}:g,E=Object(d.useRef)(),T=Object(d.useState)(),L=Object(w.a)(T,2),I=L[0],P=L[1];return Object(d.useEffect)(function(){if(I){function G(W){var H=W.getValue();R&&R(H)}return I.on("change",G),function(){I.off("change",G)}}},[I,R]),Object(d.useEffect)(function(){I&&I.setOption("mode",O)},[I,O]),Object(d.useEffect)(function(){I&&((h!==I.getValue()||h==="")&&setTimeout(function(){I.setValue(h||" ")},300))},[I,h]),Object(d.useEffect)(function(){if(E.current&&!I){var G=r.a.fromTextArea(E.current,Object(N.a)({mode:O,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},_));P(G)}},[E.current,I]),n.a.createElement("div",{className:"my-codemirror-container"},n.a.createElement("textarea",{ref:E}))}},"815F":function(F,Q,j){"use strict";j.d(Q,"e",function(){return w}),j.d(Q,"c",function(){return p}),j.d(Q,"d",function(){return d}),j.d(Q,"a",function(){return c}),j.d(Q,"f",function(){return r}),j.d(Q,"b",function(){return i});var N=j("KQm4"),v=j("VTBJ"),C=j("Ff2n"),M=j("Zm9Q"),m=j("Kwbf"),y=j("OZM5");function w(o,u){return o!=null?o:u}function b(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=new Map;function f(s){var l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";(s||[]).forEach(function(t){var S=t.key,x=t.children;Object(m.a)(S!=null,"Tree node must have a certain key: [".concat(l).concat(S,"]"));var h=String(S);Object(m.a)(!u.has(h)||S===null||S===void 0,"Same 'key' exist in the Tree: ".concat(h)),u.set(h,!0),f(x,"".concat(l).concat(h," > "))})}f(o)}function p(o){function u(f){var s=Object(M.a)(f);return s.map(function(l){if(!Object(y.i)(l))return Object(m.a)(!l,"Tree/TreeNode can only accept TreeNode as children."),null;var t=l.key,S=l.props,x=S.children,h=Object(C.a)(S,["children"]),R=Object(v.a)({key:t},h),O=u(x);return O.length&&(R.children=O),R}).filter(function(l){return l})}return u(o)}function d(){var o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],f=new Set(u===!0?[]:u),s=[];function l(t){var S=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;return t.map(function(x,h){var R=Object(y.h)(S?S.pos:"0",h),O=w(x.key,R),g=Object(v.a)(Object(v.a)({},x),{},{parent:S,pos:R,children:null,data:x,isStart:[].concat(Object(N.a)(S?S.isStart:[]),[h===0]),isEnd:[].concat(Object(N.a)(S?S.isEnd:[]),[h===t.length-1])});return s.push(g),u===!0||f.has(O)?g.children=l(x.children||[],g):g.children=[],g})}return l(o),s}function n(o,u,f){var s;f?typeof f=="string"?s=function(S){return S[f]}:typeof f=="function"&&(s=function(S){return f(S)}):s=function(S,x){return w(S.key,x)};function l(t,S,x){var h=t?t.children:o,R=t?Object(y.h)(x.pos,S):"0";if(t){var O=s(t,R),g={node:t,index:S,pos:R,key:O,parentPos:x.node?x.pos:null,level:x.level+1};u(g)}h&&h.forEach(function(_,E){l(_,E,{node:t,pos:R,level:x?x.level+1:-1})})}l(null)}function c(o){var u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},f=u.initWrapper,s=u.processEntity,l=u.onProcessFinished,t=arguments.length>2?arguments[2]:void 0,S={},x={},h={posEntities:S,keyEntities:x};return f&&(h=f(h)||h),n(o,function(R){var O=R.node,g=R.index,_=R.pos,E=R.key,T=R.parentPos,L=R.level,I={node:O,index:g,key:E,pos:_,level:L},P=w(E,_);S[_]=I,x[P]=I,I.parent=S[T],I.parent&&(I.parent.children=I.parent.children||[],I.parent.children.push(I)),s&&s(I,h)},t),l&&l(h),h}function r(o,u){var f=u.expandedKeys,s=u.selectedKeys,l=u.loadedKeys,t=u.loadingKeys,S=u.checkedKeys,x=u.halfCheckedKeys,h=u.dragOverNodeKey,R=u.dropPosition,O=u.keyEntities,g=O[o],_={eventKey:o,expanded:f.indexOf(o)!==-1,selected:s.indexOf(o)!==-1,loaded:l.indexOf(o)!==-1,loading:t.indexOf(o)!==-1,checked:S.indexOf(o)!==-1,halfChecked:x.indexOf(o)!==-1,pos:String(g?g.pos:""),dragOver:h===o&&R===0,dragOverGapTop:h===o&&R===-1,dragOverGapBottom:h===o&&R===1};return _}function i(o){var u=o.data,f=o.expanded,s=o.selected,l=o.checked,t=o.loaded,S=o.loading,x=o.halfChecked,h=o.dragOver,R=o.dragOverGapTop,O=o.dragOverGapBottom,g=o.pos,_=o.active,E=Object(v.a)(Object(v.a)({},u),{},{expanded:f,selected:s,checked:l,loaded:t,loading:S,halfChecked:x,dragOver:h,dragOverGapTop:R,dragOverGapBottom:O,pos:g,active:_});return"props"in E||Object.defineProperty(E,"props",{get:function(){return Object(m.a)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),o}}),E}},"8EBN":function(F,Q,j){(function(N){N(j("VrN/"))})(function(N){"use strict";N.modeInfo=[{name:"APL",mime:"text/apl",mode:"apl",ext:["dyalog","apl"]},{name:"PGP",mimes:["application/pgp","application/pgp-encrypted","application/pgp-keys","application/pgp-signature"],mode:"asciiarmor",ext:["asc","pgp","sig"]},{name:"ASN.1",mime:"text/x-ttcn-asn",mode:"asn.1",ext:["asn","asn1"]},{name:"Asterisk",mime:"text/x-asterisk",mode:"asterisk",file:/^extensions\.conf$/i},{name:"Brainfuck",mime:"text/x-brainfuck",mode:"brainfuck",ext:["b","bf"]},{name:"C",mime:"text/x-csrc",mode:"clike",ext:["c","h","ino"]},{name:"C++",mime:"text/x-c++src",mode:"clike",ext:["cpp","c++","cc","cxx","hpp","h++","hh","hxx"],alias:["cpp"]},{name:"Cobol",mime:"text/x-cobol",mode:"cobol",ext:["cob","cpy"]},{name:"C#",mime:"text/x-csharp",mode:"clike",ext:["cs"],alias:["csharp","cs"]},{name:"Clojure",mime:"text/x-clojure",mode:"clojure",ext:["clj","cljc","cljx"]},{name:"ClojureScript",mime:"text/x-clojurescript",mode:"clojure",ext:["cljs"]},{name:"Closure Stylesheets (GSS)",mime:"text/x-gss",mode:"css",ext:["gss"]},{name:"CMake",mime:"text/x-cmake",mode:"cmake",ext:["cmake","cmake.in"],file:/^CMakeLists\.txt$/},{name:"CoffeeScript",mimes:["application/vnd.coffeescript","text/coffeescript","text/x-coffeescript"],mode:"coffeescript",ext:["coffee"],alias:["coffee","coffee-script"]},{name:"Common Lisp",mime:"text/x-common-lisp",mode:"commonlisp",ext:["cl","lisp","el"],alias:["lisp"]},{name:"Cypher",mime:"application/x-cypher-query",mode:"cypher",ext:["cyp","cypher"]},{name:"Cython",mime:"text/x-cython",mode:"python",ext:["pyx","pxd","pxi"]},{name:"Crystal",mime:"text/x-crystal",mode:"crystal",ext:["cr"]},{name:"CSS",mime:"text/css",mode:"css",ext:["css"]},{name:"CQL",mime:"text/x-cassandra",mode:"sql",ext:["cql"]},{name:"D",mime:"text/x-d",mode:"d",ext:["d"]},{name:"Dart",mimes:["application/dart","text/x-dart"],mode:"dart",ext:["dart"]},{name:"diff",mime:"text/x-diff",mode:"diff",ext:["diff","patch"]},{name:"Django",mime:"text/x-django",mode:"django"},{name:"Dockerfile",mime:"text/x-dockerfile",mode:"dockerfile",file:/^Dockerfile$/},{name:"DTD",mime:"application/xml-dtd",mode:"dtd",ext:["dtd"]},{name:"Dylan",mime:"text/x-dylan",mode:"dylan",ext:["dylan","dyl","intr"]},{name:"EBNF",mime:"text/x-ebnf",mode:"ebnf"},{name:"ECL",mime:"text/x-ecl",mode:"ecl",ext:["ecl"]},{name:"edn",mime:"application/edn",mode:"clojure",ext:["edn"]},{name:"Eiffel",mime:"text/x-eiffel",mode:"eiffel",ext:["e"]},{name:"Elm",mime:"text/x-elm",mode:"elm",ext:["elm"]},{name:"Embedded Javascript",mime:"application/x-ejs",mode:"htmlembedded",ext:["ejs"]},{name:"Embedded Ruby",mime:"application/x-erb",mode:"htmlembedded",ext:["erb"]},{name:"Erlang",mime:"text/x-erlang",mode:"erlang",ext:["erl"]},{name:"Esper",mime:"text/x-esper",mode:"sql"},{name:"Factor",mime:"text/x-factor",mode:"factor",ext:["factor"]},{name:"FCL",mime:"text/x-fcl",mode:"fcl"},{name:"Forth",mime:"text/x-forth",mode:"forth",ext:["forth","fth","4th"]},{name:"Fortran",mime:"text/x-fortran",mode:"fortran",ext:["f","for","f77","f90","f95"]},{name:"F#",mime:"text/x-fsharp",mode:"mllike",ext:["fs"],alias:["fsharp"]},{name:"Gas",mime:"text/x-gas",mode:"gas",ext:["s"]},{name:"Gherkin",mime:"text/x-feature",mode:"gherkin",ext:["feature"]},{name:"GitHub Flavored Markdown",mime:"text/x-gfm",mode:"gfm",file:/^(readme|contributing|history)\.md$/i},{name:"Go",mime:"text/x-go",mode:"go",ext:["go"]},{name:"Groovy",mime:"text/x-groovy",mode:"groovy",ext:["groovy","gradle"],file:/^Jenkinsfile$/},{name:"HAML",mime:"text/x-haml",mode:"haml",ext:["haml"]},{name:"Haskell",mime:"text/x-haskell",mode:"haskell",ext:["hs"]},{name:"Haskell (Literate)",mime:"text/x-literate-haskell",mode:"haskell-literate",ext:["lhs"]},{name:"Haxe",mime:"text/x-haxe",mode:"haxe",ext:["hx"]},{name:"HXML",mime:"text/x-hxml",mode:"haxe",ext:["hxml"]},{name:"ASP.NET",mime:"application/x-aspx",mode:"htmlembedded",ext:["aspx"],alias:["asp","aspx"]},{name:"HTML",mime:"text/html",mode:"htmlmixed",ext:["html","htm","handlebars","hbs"],alias:["xhtml"]},{name:"HTTP",mime:"message/http",mode:"http"},{name:"IDL",mime:"text/x-idl",mode:"idl",ext:["pro"]},{name:"Pug",mime:"text/x-pug",mode:"pug",ext:["jade","pug"],alias:["jade"]},{name:"Java",mime:"text/x-java",mode:"clike",ext:["java"]},{name:"Java Server Pages",mime:"application/x-jsp",mode:"htmlembedded",ext:["jsp"],alias:["jsp"]},{name:"JavaScript",mimes:["text/javascript","text/ecmascript","application/javascript","application/x-javascript","application/ecmascript"],mode:"javascript",ext:["js"],alias:["ecmascript","js","node"]},{name:"JSON",mimes:["application/json","application/x-json"],mode:"javascript",ext:["json","map"],alias:["json5"]},{name:"JSON-LD",mime:"application/ld+json",mode:"javascript",ext:["jsonld"],alias:["jsonld"]},{name:"JSX",mime:"text/jsx",mode:"jsx",ext:["jsx"]},{name:"Jinja2",mime:"text/jinja2",mode:"jinja2",ext:["j2","jinja","jinja2"]},{name:"Julia",mime:"text/x-julia",mode:"julia",ext:["jl"]},{name:"Kotlin",mime:"text/x-kotlin",mode:"clike",ext:["kt"]},{name:"LESS",mime:"text/x-less",mode:"css",ext:["less"]},{name:"LiveScript",mime:"text/x-livescript",mode:"livescript",ext:["ls"],alias:["ls"]},{name:"Lua",mime:"text/x-lua",mode:"lua",ext:["lua"]},{name:"Markdown",mime:"text/x-markdown",mode:"markdown",ext:["markdown","md","mkd"]},{name:"mIRC",mime:"text/mirc",mode:"mirc"},{name:"MariaDB SQL",mime:"text/x-mariadb",mode:"sql"},{name:"Mathematica",mime:"text/x-mathematica",mode:"mathematica",ext:["m","nb","wl","wls"]},{name:"Modelica",mime:"text/x-modelica",mode:"modelica",ext:["mo"]},{name:"MUMPS",mime:"text/x-mumps",mode:"mumps",ext:["mps"]},{name:"MS SQL",mime:"text/x-mssql",mode:"sql"},{name:"mbox",mime:"application/mbox",mode:"mbox",ext:["mbox"]},{name:"MySQL",mime:"text/x-mysql",mode:"sql"},{name:"Nginx",mime:"text/x-nginx-conf",mode:"nginx",file:/nginx.*\.conf$/i},{name:"NSIS",mime:"text/x-nsis",mode:"nsis",ext:["nsh","nsi"]},{name:"NTriples",mimes:["application/n-triples","application/n-quads","text/n-triples"],mode:"ntriples",ext:["nt","nq"]},{name:"Objective-C",mime:"text/x-objectivec",mode:"clike",ext:["m"],alias:["objective-c","objc"]},{name:"Objective-C++",mime:"text/x-objectivec++",mode:"clike",ext:["mm"],alias:["objective-c++","objc++"]},{name:"OCaml",mime:"text/x-ocaml",mode:"mllike",ext:["ml","mli","mll","mly"]},{name:"Octave",mime:"text/x-octave",mode:"octave",ext:["m"]},{name:"Oz",mime:"text/x-oz",mode:"oz",ext:["oz"]},{name:"Pascal",mime:"text/x-pascal",mode:"pascal",ext:["p","pas"]},{name:"PEG.js",mime:"null",mode:"pegjs",ext:["jsonld"]},{name:"Perl",mime:"text/x-perl",mode:"perl",ext:["pl","pm"]},{name:"PHP",mimes:["text/x-php","application/x-httpd-php","application/x-httpd-php-open"],mode:"php",ext:["php","php3","php4","php5","php7","phtml"]},{name:"Pig",mime:"text/x-pig",mode:"pig",ext:["pig"]},{name:"Plain Text",mime:"text/plain",mode:"null",ext:["txt","text","conf","def","list","log"]},{name:"PLSQL",mime:"text/x-plsql",mode:"sql",ext:["pls"]},{name:"PostgreSQL",mime:"text/x-pgsql",mode:"sql"},{name:"PowerShell",mime:"application/x-powershell",mode:"powershell",ext:["ps1","psd1","psm1"]},{name:"Properties files",mime:"text/x-properties",mode:"properties",ext:["properties","ini","in"],alias:["ini","properties"]},{name:"ProtoBuf",mime:"text/x-protobuf",mode:"protobuf",ext:["proto"]},{name:"Python",mime:"text/x-python",mode:"python",ext:["BUILD","bzl","py","pyw"],file:/^(BUCK|BUILD)$/},{name:"Puppet",mime:"text/x-puppet",mode:"puppet",ext:["pp"]},{name:"Q",mime:"text/x-q",mode:"q",ext:["q"]},{name:"R",mime:"text/x-rsrc",mode:"r",ext:["r","R"],alias:["rscript"]},{name:"reStructuredText",mime:"text/x-rst",mode:"rst",ext:["rst"],alias:["rst"]},{name:"RPM Changes",mime:"text/x-rpm-changes",mode:"rpm"},{name:"RPM Spec",mime:"text/x-rpm-spec",mode:"rpm",ext:["spec"]},{name:"Ruby",mime:"text/x-ruby",mode:"ruby",ext:["rb"],alias:["jruby","macruby","rake","rb","rbx"]},{name:"Rust",mime:"text/x-rustsrc",mode:"rust",ext:["rs"]},{name:"SAS",mime:"text/x-sas",mode:"sas",ext:["sas"]},{name:"Sass",mime:"text/x-sass",mode:"sass",ext:["sass"]},{name:"Scala",mime:"text/x-scala",mode:"clike",ext:["scala"]},{name:"Scheme",mime:"text/x-scheme",mode:"scheme",ext:["scm","ss"]},{name:"SCSS",mime:"text/x-scss",mode:"css",ext:["scss"]},{name:"Shell",mimes:["text/x-sh","application/x-sh"],mode:"shell",ext:["sh","ksh","bash"],alias:["bash","sh","zsh"],file:/^PKGBUILD$/},{name:"Sieve",mime:"application/sieve",mode:"sieve",ext:["siv","sieve"]},{name:"Slim",mimes:["text/x-slim","application/x-slim"],mode:"slim",ext:["slim"]},{name:"Smalltalk",mime:"text/x-stsrc",mode:"smalltalk",ext:["st"]},{name:"Smarty",mime:"text/x-smarty",mode:"smarty",ext:["tpl"]},{name:"Solr",mime:"text/x-solr",mode:"solr"},{name:"SML",mime:"text/x-sml",mode:"mllike",ext:["sml","sig","fun","smackspec"]},{name:"Soy",mime:"text/x-soy",mode:"soy",ext:["soy"],alias:["closure template"]},{name:"SPARQL",mime:"application/sparql-query",mode:"sparql",ext:["rq","sparql"],alias:["sparul"]},{name:"Spreadsheet",mime:"text/x-spreadsheet",mode:"spreadsheet",alias:["excel","formula"]},{name:"SQL",mime:"text/x-sql",mode:"sql",ext:["sql"]},{name:"SQLite",mime:"text/x-sqlite",mode:"sql"},{name:"Squirrel",mime:"text/x-squirrel",mode:"clike",ext:["nut"]},{name:"Stylus",mime:"text/x-styl",mode:"stylus",ext:["styl"]},{name:"Swift",mime:"text/x-swift",mode:"swift",ext:["swift"]},{name:"sTeX",mime:"text/x-stex",mode:"stex"},{name:"LaTeX",mime:"text/x-latex",mode:"stex",ext:["text","ltx","tex"],alias:["tex"]},{name:"SystemVerilog",mime:"text/x-systemverilog",mode:"verilog",ext:["v","sv","svh"]},{name:"Tcl",mime:"text/x-tcl",mode:"tcl",ext:["tcl"]},{name:"Textile",mime:"text/x-textile",mode:"textile",ext:["textile"]},{name:"TiddlyWiki",mime:"text/x-tiddlywiki",mode:"tiddlywiki"},{name:"Tiki wiki",mime:"text/tiki",mode:"tiki"},{name:"TOML",mime:"text/x-toml",mode:"toml",ext:["toml"]},{name:"Tornado",mime:"text/x-tornado",mode:"tornado"},{name:"troff",mime:"text/troff",mode:"troff",ext:["1","2","3","4","5","6","7","8","9"]},{name:"TTCN",mime:"text/x-ttcn",mode:"ttcn",ext:["ttcn","ttcn3","ttcnpp"]},{name:"TTCN_CFG",mime:"text/x-ttcn-cfg",mode:"ttcn-cfg",ext:["cfg"]},{name:"Turtle",mime:"text/turtle",mode:"turtle",ext:["ttl"]},{name:"TypeScript",mime:"application/typescript",mode:"javascript",ext:["ts"],alias:["ts"]},{name:"TypeScript-JSX",mime:"text/typescript-jsx",mode:"jsx",ext:["tsx"],alias:["tsx"]},{name:"Twig",mime:"text/x-twig",mode:"twig"},{name:"Web IDL",mime:"text/x-webidl",mode:"webidl",ext:["webidl"]},{name:"VB.NET",mime:"text/x-vb",mode:"vb",ext:["vb"]},{name:"VBScript",mime:"text/vbscript",mode:"vbscript",ext:["vbs"]},{name:"Velocity",mime:"text/velocity",mode:"velocity",ext:["vtl"]},{name:"Verilog",mime:"text/x-verilog",mode:"verilog",ext:["v"]},{name:"VHDL",mime:"text/x-vhdl",mode:"vhdl",ext:["vhd","vhdl"]},{name:"Vue.js Component",mimes:["script/x-vue","text/x-vue"],mode:"vue",ext:["vue"]},{name:"XML",mimes:["application/xml","text/xml"],mode:"xml",ext:["xml","xsl","xsd","svg"],alias:["rss","wsdl","xsd"]},{name:"XQuery",mime:"application/xquery",mode:"xquery",ext:["xy","xquery"]},{name:"Yacas",mime:"text/x-yacas",mode:"yacas",ext:["ys"]},{name:"YAML",mimes:["text/x-yaml","text/yaml"],mode:"yaml",ext:["yaml","yml"],alias:["yml"]},{name:"Z80",mime:"text/x-z80",mode:"z80",ext:["z80"]},{name:"mscgen",mime:"text/x-mscgen",mode:"mscgen",ext:["mscgen","mscin","msc"]},{name:"xu",mime:"text/x-xu",mode:"mscgen",ext:["xu"]},{name:"msgenny",mime:"text/x-msgenny",mode:"mscgen",ext:["msgenny"]},{name:"WebAssembly",mime:"text/webassembly",mode:"wast",ext:["wat","wast"]}];for(var v=0;v<N.modeInfo.length;v++){var C=N.modeInfo[v];C.mimes&&(C.mime=C.mimes[0])}N.findModeByMIME=function(M){M=M.toLowerCase();for(var m=0;m<N.modeInfo.length;m++){var y=N.modeInfo[m];if(y.mime==M)return y;if(y.mimes){for(var w=0;w<y.mimes.length;w++)if(y.mimes[w]==M)return y}}if(/\+xml$/.test(M))return N.findModeByMIME("application/xml");if(/\+json$/.test(M))return N.findModeByMIME("application/json")},N.findModeByExtension=function(M){M=M.toLowerCase();for(var m=0;m<N.modeInfo.length;m++){var y=N.modeInfo[m];if(y.ext){for(var w=0;w<y.ext.length;w++)if(y.ext[w]==M)return y}}},N.findModeByFileName=function(M){for(var m=0;m<N.modeInfo.length;m++){var y=N.modeInfo[m];if(y.file&&y.file.test(M))return y}var w=M.lastIndexOf("."),b=w>-1&&M.substring(w+1,M.length);if(b)return N.findModeByExtension(b)},N.findModeByName=function(M){M=M.toLowerCase();for(var m=0;m<N.modeInfo.length;m++){var y=N.modeInfo[m];if(y.name.toLowerCase()==M)return y;if(y.alias){for(var w=0;w<y.alias.length;w++)if(y.alias[w].toLowerCase()==M)return y}}}})},"8hTe":function(F,Q,j){F.exports={button:"button___1wy9m"}},"9Bee":function(F,Q,j){"use strict";var N=j("DYRE"),v=j("zeV3"),C=j("+L6B"),M=j("2/Rp"),m=j("k1fw"),y=j("tJVT"),w=j("cDcd"),b=j.n(w),p=j("vg9a"),d=j("DlQD"),n=j.n(d),c=j("rUJ1");function r(le,me){var de=le.match(/^(\s+)(?:```)/);if(de===null)return me;var ae=de[1];return me.split(`
`).map(function(ie){var q=ie.match(/^\s+/);if(q===null)return ie;var ue=Object(y.a)(q,1),Z=ue[0];return Z.length>=ae.length?ie.slice(ae.length):ie}).join(`
`)}var i=[],o=["<ul>"],u=new n.a.Renderer,f=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function s(){i.length=0,o=["<ul>"]}var l={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function t(le,me,de,ae){if(me>=le.length||le[me].level<=de)return me;var ie=le[me];ae.push("<li><a href='#"+ie.anchor+"'>"+ie.text+"</a>"),me++;var q=[];return me=t(le,me,ie.level,q),q.length>0&&(ae.push("<ul>"),q.forEach(function(ue){ae.push(ue)}),ae.push("</ul>")),ae.push("</li>"),me=t(le,me,de,ae),me}function S(){return t(i,0,0,o),o.push("</ul>"),o.join("")}var x={heading:function(me){var de=f.exec(me);if(de)return{type:"heading",raw:de[0],depth:de[1].length,text:de[2]}},fences:function(me){var de=this.rules.block.fences.exec(me);if(de){var ae=de[0],ie=r(ae,de[3]||""),q=de[2]?de[2].trim():de[2];if(["latex","katex","math"].indexOf(q)>=0){var ue=O(),Z=ie;ie=ue,g[ue]={type:"block",expression:Z}}return{type:"code",raw:ae,lang:q,text:ie}}}},h=/(?:\${2})([^\n`]+?)(?:\${2})/gi,R=0,O=function(){return"__special_katext_id_".concat(R++,"__")},g={};function _(){return g}function E(){R=0,g={}}function T(le){return le=le.replace(h,function(me,de){var ae=O();return g[ae]={type:"inline",expression:de},ae}),le}var L=u.listitem;u.listitem=function(le){return L(T(le))};var I=u.paragraph;u.paragraph=function(le){return I(T(le))};var P=u.tablecell;u.tablecell=function(le,me){return P(T(le),me)},u.code=function(le,me,de){var ae=(me||"").match(/\S*/)[0];return ae?["latex","katex","math"].indexOf(ae)>=0?"<p class='editormd-tex'>".concat(le,"</p>"):'<pre class="prettyprint linenums"><code class="language-'.concat(me,'">').concat(de?le:Object(c.escape)(le,!0),`</code></pre>
`):'<pre class="prettyprint linenums"><code>'+(de?le:Object(c.escape)(le,!0))+"</code></pre>"},u.heading=function(le,me,de){var ae=this.options.headerPrefix+de.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return i.push({anchor:ae,level:me,text:le}),"<h"+me+' id="'+ae+'">'+le+"</h"+me+">"},n.a.setOptions({silent:!0,gfm:!0,pedantic:!1}),n.a.use({tokenizer:x,renderer:u});var G=n.a,W=j("SJMd"),H=j("ulZh"),z=j.n(H),B=j("m3rI"),k=j("Oy/b"),K=j("p5ED"),Y=j("8hTe"),ne=j.n(Y),oe=/<pre[^>]*>/g;function _e(le){var me=document.createElement("div");return me.innerHTML=le,me.childNodes.length===0?"":me.childNodes[0].nodeValue}var xe=Q.a=function(le){var me=le.value,de=me===void 0?"":me,ae=le.edit,ie=ae===void 0?!1:ae,q=le.className,ue=le.showTextOnly,Z=le.showLines,ee=le.replaces,Ee=le.zoomImg,te=le.hasMask,J=le.style,X=J===void 0?{}:J,$=le.stylesPrev,ge=$===void 0?{}:$,fe=String(de),Te=Object(w.useRef)(),ze=Object(w.useRef)(),Xe=Object(w.useState)(""),Ye=Object(y.a)(Xe,2),rt=Ye[0],at=Ye[1],ot=Object(w.useState)("office"),Pe=Object(y.a)(ot,2),Se=Pe[0],Je=Pe[1],nt=Object(w.useMemo)(function(){try{var Re=/\(\s+\/api\/attachments\/|\(\/api\/attachments\/|\(\/attachments\/download\//g,pe=/\"\/api\/attachments\/|\"\/attachments\/download\//g,ye=/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g;fe=fe.replace(Re,"("+B.a.API_SERVER+"/api/attachments/").replace(pe,'"'+B.a.API_SERVER+"/api/attachments/").replace(ye,'"'+B.a.API_SERVER+"/files/uploads/").replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,`
`)}catch(Ve){}var we=G(fe),Ie=_();if(fe.match(/\[TOC\]/)&&(we=we.replace("<p>[TOC]</p>",S()),s()),we=we.replace(/(__special_katext_id_\d+__)/g,function(Ve,ut){var ct=Ie[ut],Lt=ct.type,Dt=ct.expression;return Object(k.renderToString)(_e(Dt)||"",{displayMode:Lt==="block",throwOnError:!1,output:"html"})}),we=we.replace(/▁/g,"\u2581\u2581\u2581"),E(),ue){var ke=document.createElement("div");return ke.innerHTML=we,ke.innerText}return setTimeout(function(){return Me()},500),we},[fe]),We=Object(w.useRef)();l.WebkitLineClamp=Z,Z&&(X=Object(m.a)(Object(m.a)({},X),l));function et(Re){var pe=Re.target;if(pe.tagName.toUpperCase()==="IMG"){if(Ee){var ye=pe.getAttribute("src");at(ye),Je("image")}}else if(pe.tagName.toUpperCase()==="A"){var we=pe.getAttribute("href");if(we.indexOf("office")>-1)Re.preventDefault(),at(we),Je("office");else if(we.indexOf("application/pdf")>-1)Re.preventDefault(),at(we),Je("pdf");else if(we.indexOf("text/html")>-1)Re.preventDefault(),at(we),Je("html");else if(we.startsWith("#")){Re.preventDefault();var Ie=document.getElementById(we.replace("#",""));Ie&&Ie.scrollIntoView(!0)}}}var Me=function(){var pe,ye=(pe=We.current)===null||pe===void 0?void 0:pe.querySelectorAll("video");ye==null||ye.forEach(function(we){if(we.oncontextmenu=function(){return!1},we.src.indexOf(".m3u8")>-1&&!we.canPlayType("application/vnd.apple.mpegurl")){if(z.a.isSupported()){var Ie=new z.a;Ie.loadSource(we.src),Ie.attachMedia(we)}}})};Object(w.useEffect)(function(){if(We.current&&nt&&(nt.match(oe)&&window.PR.prettyPrint()),We.current)return We.current.addEventListener("click",et),function(){We.current.removeEventListener("click",et),E(),s()}},[nt,We.current,et]);var Ce=function(pe){if(!ie)return;pe.target.nodeName==="IMG"?(Te.current.style.display="flex",Te.current.style.width=pe.target.clientWidth+"px",Te.current.style.height=pe.target.clientHeight+"px",Te.current.style.top=pe.target.offsetTop+"px",Te.current.style.left=pe.target.offsetLeft+"px",ze.current.src=pe.target.getAttribute("src")):Te.current.style.display="none"};return b.a.createElement("div",{style:{position:"relative"}},b.a.createElement("div",{ref:We,style:Object(m.a)({},X),className:"".concat(q||""," markdown-body ").concat(ne.a.mdBody),onMouseOver:Ce,dangerouslySetInnerHTML:{__html:nt}}),b.a.createElement("div",{ref:Te,className:ne.a.button},b.a.createElement(v.a,null,b.a.createElement(M.a,{onClick:function(){return openCrop()}},"\u88C1\u526A"),b.a.createElement(M.a,{onClick:function(){return openEditor()}},"\u7F16\u8F91"))),b.a.createElement("img",{ref:ze,src:"",alt:"sample",crossOrigin:"anonymous",style:{maxWidth:"90%",opacity:0,position:"absolute",zIndex:-1,top:"-10000px"}}),b.a.createElement(K.a,{close:!0,data:rt,type:rt!=null&&rt.length?Se:"",style:Object(m.a)({},ge),onClose:function(){return at("")}}))}},"9OqN":function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.mode.CTR=function(){var v=N.lib.BlockCipherMode.extend(),C=v.Encryptor=v.extend({processBlock:function(M,m){var y=this._cipher,w=y.blockSize,b=this._iv,p=this._counter;b&&(p=this._counter=b.slice(0),this._iv=void 0);var d=p.slice(0);y.encryptBlock(d,0),p[w-1]=p[w-1]+1|0;for(var n=0;n<w;n++)M[m+n]^=d[n]}});return v.Decryptor=C,v}(),N.mode.CTR})},"9VGf":function(F,Q,j){"use strict";j.d(Q,"a",function(){return C});var N=j("cDcd"),v=j.n(N);function C(M,m){var y=Object(N.useRef)();Object(N.useEffect)(function(){y.current=M}),Object(N.useEffect)(function(){function w(){y.current()}if(m!==null){var b=setInterval(w,m);return function(){return clearInterval(b)}}},[m])}},ALsQ:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.mode.CFB=function(){var v=N.lib.BlockCipherMode.extend();v.Encryptor=v.extend({processBlock:function(M,m){var y=this._cipher,w=y.blockSize;C.call(this,M,m,w,y),this._prevBlock=M.slice(m,m+w)}}),v.Decryptor=v.extend({processBlock:function(M,m){var y=this._cipher,w=y.blockSize,b=M.slice(m,m+w);C.call(this,M,m,w,y),this._prevBlock=b}});function C(M,m,y,w){var b,p=this._iv;p?(b=p.slice(0),this._iv=void 0):b=this._prevBlock,w.encryptBlock(b,0);for(var d=0;d<y;d++)M[m+d]^=b[d]}return v}(),N.mode.CFB})},BJfS:function(F,Q){var j=function(N){return N.replace(/[A-Z]/g,function(v){return"-"+v.toLowerCase()}).toLowerCase()};F.exports=j},BU3w:function(F,Q,j){"use strict";j.d(Q,"a",function(){return y});var N=j("MNnm"),v="rc-util-key";function C(w){if(w.attachTo)return w.attachTo;var b=document.querySelector("head");return b||document.body}function M(w){var b,p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!Object(N.a)())return null;var d=document.createElement("style");if((b=p.csp)===null||b===void 0?void 0:b.nonce){var n;d.nonce=(n=p.csp)===null||n===void 0?void 0:n.nonce}d.innerHTML=w;var c=C(p),r=c.firstChild;return p.prepend&&c.prepend?c.prepend(d):p.prepend&&r?c.insertBefore(d,r):c.appendChild(d),d}var m=new Map;function y(w,b){var p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},d=C(p);if(!m.has(d)){var n=M("",p),c=n.parentNode;m.set(d,c),c.removeChild(n)}var r=Array.from(m.get(d).children).find(function(s){return s.tagName==="STYLE"&&s[v]===b});if(r){var i,o;if(((i=p.csp)===null||i===void 0?void 0:i.nonce)&&r.nonce!==((o=p.csp)===null||o===void 0?void 0:o.nonce)){var u;r.nonce=(u=p.csp)===null||u===void 0?void 0:u.nonce}return r.innerHTML!==w&&(r.innerHTML=w),r}var f=M(w,p);return f[v]=b,f}},Bd2K:function(F,Q,j){(function(N){N(j("VrN/"),j("osHv"))})(function(N){N.defineOption("autoCloseTags",!1,function(p,d,n){if(n!=N.Init&&n&&p.removeKeyMap("autoCloseTags"),!d)return;var c={name:"autoCloseTags"};(typeof d!="object"||d.whenClosing!==!1)&&(c["'/'"]=function(r){return y(r)}),(typeof d!="object"||d.whenOpening!==!1)&&(c["'>'"]=function(r){return M(r)}),p.addKeyMap(c)});var v=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],C=["applet","blockquote","body","button","div","dl","fieldset","form","frameset","h1","h2","h3","h4","h5","h6","head","html","iframe","layer","legend","object","ol","p","select","table","ul"];function M(p){if(p.getOption("disableInput"))return N.Pass;for(var d=p.listSelections(),n=[],c=p.getOption("autoCloseTags"),r=0;r<d.length;r++){if(!d[r].empty())return N.Pass;var i=d[r].head,o=p.getTokenAt(i),u=N.innerMode(p.getMode(),o.state),f=u.state,s=u.mode.xmlCurrentTag&&u.mode.xmlCurrentTag(f),l=s&&s.name;if(!l)return N.Pass;var t=u.mode.configuration=="html",S=typeof c=="object"&&c.dontCloseTags||t&&v,x=typeof c=="object"&&c.indentTags||t&&C;o.end>i.ch&&(l=l.slice(0,l.length-o.end+i.ch));var h=l.toLowerCase();if(!l||o.type=="string"&&(o.end!=i.ch||!/[\"\']/.test(o.string.charAt(o.string.length-1))||o.string.length==1)||o.type=="tag"&&s.close||o.string.indexOf("/")==i.ch-o.start-1||S&&w(S,h)>-1||b(p,u.mode.xmlCurrentContext&&u.mode.xmlCurrentContext(f)||[],l,i,!0))return N.Pass;var R=typeof c=="object"&&c.emptyTags;if(R&&w(R,l)>-1){n[r]={text:"/>",newPos:N.Pos(i.line,i.ch+2)};continue}var O=x&&w(x,h)>-1;n[r]={indent:O,text:">"+(O?`
`:"")+"</"+l+">",newPos:O?N.Pos(i.line+1,0):N.Pos(i.line,i.ch+1)}}for(var g=typeof c=="object"&&c.dontIndentOnAutoClose,r=d.length-1;r>=0;r--){var _=n[r];p.replaceRange(_.text,d[r].head,d[r].anchor,"+insert");var E=p.listSelections().slice(0);E[r]={head:_.newPos,anchor:_.newPos},p.setSelections(E),!g&&_.indent&&(p.indentLine(_.newPos.line,null,!0),p.indentLine(_.newPos.line+1,null,!0))}}function m(p,d){for(var n=p.listSelections(),c=[],r=d?"/":"</",i=p.getOption("autoCloseTags"),o=typeof i=="object"&&i.dontIndentOnSlash,u=0;u<n.length;u++){if(!n[u].empty())return N.Pass;var f=n[u].head,s=p.getTokenAt(f),l=N.innerMode(p.getMode(),s.state),t=l.state;if(d&&(s.type=="string"||s.string.charAt(0)!="<"||s.start!=f.ch-1))return N.Pass;var S,x=l.mode.name!="xml"&&p.getMode().name=="htmlmixed";if(x&&l.mode.name=="javascript")S=r+"script";else if(x&&l.mode.name=="css")S=r+"style";else{var h=l.mode.xmlCurrentContext&&l.mode.xmlCurrentContext(t);if(!h||h.length&&b(p,h,h[h.length-1],f))return N.Pass;S=r+h[h.length-1]}p.getLine(f.line).charAt(s.end)!=">"&&(S+=">"),c[u]=S}if(p.replaceSelections(c),n=p.listSelections(),!o)for(var u=0;u<n.length;u++)(u==n.length-1||n[u].head.line<n[u+1].head.line)&&p.indentLine(n[u].head.line)}function y(p){return p.getOption("disableInput")?N.Pass:m(p,!0)}N.commands.closeTag=function(p){return m(p)};function w(p,d){if(p.indexOf)return p.indexOf(d);for(var n=0,c=p.length;n<c;++n)if(p[n]==d)return n;return-1}function b(p,d,n,c,r){if(!N.scanForClosingTag)return!1;var i=Math.min(p.lastLine()+1,c.line+500),o=N.scanForClosingTag(p,c,null,i);if(!o||o.tag!=n)return!1;for(var u=r?1:0,f=d.length-1;f>=0&&d[f]==n;f--)++u;c=o.to;for(var f=1;f<u;f++){var s=N.scanForClosingTag(p,c,null,i);if(!s||s.tag!=n)return!1;c=s.to}return!0}})},BjJ7:function(F,Q,j){"use strict";j.d(Q,"d",function(){return v}),j.d(Q,"c",function(){return C}),j.d(Q,"e",function(){return M}),j.d(Q,"b",function(){return m}),j.d(Q,"a",function(){return w});var N=j("m3rI");function v(b){var p=!0;if(b.length>0){for(var d=0;d<b.length;d++)if(b[d].compile_success==0||!b[d].compile_success){p=!1;break}}else p=!1;return p}function C(b){for(var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",d=[],n=0;n<b.length;n++){var c=b[n],r=p?"".concat(p,"/").concat(c.name):"".concat(c.name);d.push({title:c.name,isLeaf:!(c.type==="tree"),key:r})}return d}function M(b,p,d){for(var n=0;n<b.length;n++){var c=b[n];if(c.key===p){c.children=d;break}c.children&&M(c.children,p,d)}return b}function m(b,p,d){var n;return function(){var c=this,r=arguments,i=function(){n=null,d||b.apply(c,r)},o=d&&!n;clearTimeout(n),n=setTimeout(i,p),o&&b.apply(c,r)}}var y=!0,w=N.a.API_SERVER},"C+DQ":function(F,Q,j){},Dgm7:function(F,Q,j){F.exports=j.p+"static/auth.ea067b42.png"},DlQD:function(F,Q,j){(function(N,v){F.exports=v()})(this,function(){"use strict";function N(Me,Ce){for(var Re=0;Re<Ce.length;Re++){var pe=Ce[Re];pe.enumerable=pe.enumerable||!1,pe.configurable=!0,"value"in pe&&(pe.writable=!0),Object.defineProperty(Me,pe.key,pe)}}function v(Me,Ce,Re){return Ce&&N(Me.prototype,Ce),Re&&N(Me,Re),Me}function C(Me,Ce){if(!Me)return;if(typeof Me=="string")return M(Me,Ce);var Re=Object.prototype.toString.call(Me).slice(8,-1);if(Re==="Object"&&Me.constructor&&(Re=Me.constructor.name),Re==="Map"||Re==="Set")return Array.from(Me);if(Re==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Re))return M(Me,Ce)}function M(Me,Ce){(Ce==null||Ce>Me.length)&&(Ce=Me.length);for(var Re=0,pe=new Array(Ce);Re<Ce;Re++)pe[Re]=Me[Re];return pe}function m(Me,Ce){var Re;if(typeof Symbol=="undefined"||Me[Symbol.iterator]==null){if(Array.isArray(Me)||(Re=C(Me))||Ce&&Me&&typeof Me.length=="number"){Re&&(Me=Re);var pe=0;return function(){return pe>=Me.length?{done:!0}:{done:!1,value:Me[pe++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}return Re=Me[Symbol.iterator](),Re.next.bind(Re)}function y(Me,Ce){return Ce={exports:{}},Me(Ce,Ce.exports),Ce.exports}var w=y(function(Me){function Ce(){return{baseUrl:null,breaks:!1,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartLists:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}}function Re(pe){Me.exports.defaults=pe}Me.exports={defaults:Ce(),getDefaults:Ce,changeDefaults:Re}}),b=w.defaults,p=w.getDefaults,d=w.changeDefaults,n=/[&<>"']/,c=/[&<>"']/g,r=/[<>"']|&(?!#?\w+;)/,i=/[<>"']|&(?!#?\w+;)/g,o={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},u=function(Ce){return o[Ce]};function f(Me,Ce){if(Ce){if(n.test(Me))return Me.replace(c,u)}else if(r.test(Me))return Me.replace(i,u);return Me}var s=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function l(Me){return Me.replace(s,function(Ce,Re){return Re=Re.toLowerCase(),Re==="colon"?":":Re.charAt(0)==="#"?Re.charAt(1)==="x"?String.fromCharCode(parseInt(Re.substring(2),16)):String.fromCharCode(+Re.substring(1)):""})}var t=/(^|[^\[])\^/g;function S(Me,Ce){Me=Me.source||Me,Ce=Ce||"";var Re={replace:function(ye,we){return we=we.source||we,we=we.replace(t,"$1"),Me=Me.replace(ye,we),Re},getRegex:function(){return new RegExp(Me,Ce)}};return Re}var x=/[^\w:]/g,h=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function R(Me,Ce,Re){if(Me){var pe;try{pe=decodeURIComponent(l(Re)).replace(x,"").toLowerCase()}catch(ye){return null}if(pe.indexOf("javascript:")===0||pe.indexOf("vbscript:")===0||pe.indexOf("data:")===0)return null}Ce&&!h.test(Re)&&(Re=T(Ce,Re));try{Re=encodeURI(Re).replace(/%25/g,"%")}catch(ye){return null}return Re}var O={},g=/^[^:]+:\/*[^/]*$/,_=/^([^:]+:)[\s\S]*$/,E=/^([^:]+:\/*[^/]*)[\s\S]*$/;function T(Me,Ce){O[" "+Me]||(g.test(Me)?O[" "+Me]=Me+"/":O[" "+Me]=G(Me,"/",!0)),Me=O[" "+Me];var Re=Me.indexOf(":")===-1;return Ce.substring(0,2)==="//"?Re?Ce:Me.replace(_,"$1")+Ce:Ce.charAt(0)==="/"?Re?Ce:Me.replace(E,"$1")+Ce:Me+Ce}var L={exec:function(){}};function I(Me){for(var Ce=1,Re,pe;Ce<arguments.length;Ce++){Re=arguments[Ce];for(pe in Re)Object.prototype.hasOwnProperty.call(Re,pe)&&(Me[pe]=Re[pe])}return Me}function P(Me,Ce){var Re=Me.replace(/\|/g,function(we,Ie,ke){for(var Ve=!1,ut=Ie;--ut>=0&&ke[ut]==="\\";)Ve=!Ve;return Ve?"|":" |"}),pe=Re.split(/ \|/),ye=0;if(pe.length>Ce)pe.splice(Ce);else for(;pe.length<Ce;)pe.push("");for(;ye<pe.length;ye++)pe[ye]=pe[ye].trim().replace(/\\\|/g,"|");return pe}function G(Me,Ce,Re){var pe=Me.length;if(pe===0)return"";for(var ye=0;ye<pe;){var we=Me.charAt(pe-ye-1);if(we===Ce&&!Re)ye++;else if(we!==Ce&&Re)ye++;else break}return Me.substr(0,pe-ye)}function W(Me,Ce){if(Me.indexOf(Ce[1])===-1)return-1;for(var Re=Me.length,pe=0,ye=0;ye<Re;ye++)if(Me[ye]==="\\")ye++;else if(Me[ye]===Ce[0])pe++;else if(Me[ye]===Ce[1]&&(pe--,pe<0))return ye;return-1}function H(Me){Me&&Me.sanitize&&!Me.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}var z={escape:f,unescape:l,edit:S,cleanUrl:R,resolveUrl:T,noopTest:L,merge:I,splitCells:P,rtrim:G,findClosingBracket:W,checkSanitizeDeprecation:H},B=w.defaults,k=z.rtrim,K=z.splitCells,Y=z.escape,ne=z.findClosingBracket;function oe(Me,Ce,Re){var pe=Ce.href,ye=Ce.title?Y(Ce.title):null,we=Me[1].replace(/\\([\[\]])/g,"$1");return Me[0].charAt(0)!=="!"?{type:"link",raw:Re,href:pe,title:ye,text:we}:{type:"image",raw:Re,href:pe,title:ye,text:Y(we)}}function _e(Me,Ce){var Re=Me.match(/^(\s+)(?:```)/);if(Re===null)return Ce;var pe=Re[1];return Ce.split(`
`).map(function(ye){var we=ye.match(/^\s+/);if(we===null)return ye;var Ie=we[0];return Ie.length>=pe.length?ye.slice(pe.length):ye}).join(`
`)}var xe=function(){function Me(Re){this.options=Re||B}var Ce=Me.prototype;return Ce.space=function(pe){var ye=this.rules.block.newline.exec(pe);if(ye)return ye[0].length>1?{type:"space",raw:ye[0]}:{raw:`
`}},Ce.code=function(pe,ye){var we=this.rules.block.code.exec(pe);if(we){var Ie=ye[ye.length-1];if(Ie&&Ie.type==="paragraph")return{raw:we[0],text:we[0].trimRight()};var ke=we[0].replace(/^ {4}/gm,"");return{type:"code",raw:we[0],codeBlockStyle:"indented",text:this.options.pedantic?ke:k(ke,`
`)}}},Ce.fences=function(pe){var ye=this.rules.block.fences.exec(pe);if(ye){var we=ye[0],Ie=_e(we,ye[3]||"");return{type:"code",raw:we,lang:ye[2]?ye[2].trim():ye[2],text:Ie}}},Ce.heading=function(pe){var ye=this.rules.block.heading.exec(pe);if(ye)return{type:"heading",raw:ye[0],depth:ye[1].length,text:ye[2]}},Ce.nptable=function(pe){var ye=this.rules.block.nptable.exec(pe);if(ye){var we={type:"table",header:K(ye[1].replace(/^ *| *\| *$/g,"")),align:ye[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:ye[3]?ye[3].replace(/\n$/,"").split(`
`):[],raw:ye[0]};if(we.header.length===we.align.length){var Ie=we.align.length,ke;for(ke=0;ke<Ie;ke++)/^ *-+: *$/.test(we.align[ke])?we.align[ke]="right":/^ *:-+: *$/.test(we.align[ke])?we.align[ke]="center":/^ *:-+ *$/.test(we.align[ke])?we.align[ke]="left":we.align[ke]=null;for(Ie=we.cells.length,ke=0;ke<Ie;ke++)we.cells[ke]=K(we.cells[ke],we.header.length);return we}}},Ce.hr=function(pe){var ye=this.rules.block.hr.exec(pe);if(ye)return{type:"hr",raw:ye[0]}},Ce.blockquote=function(pe){var ye=this.rules.block.blockquote.exec(pe);if(ye){var we=ye[0].replace(/^ *> ?/gm,"");return{type:"blockquote",raw:ye[0],text:we}}},Ce.list=function(pe){var ye=this.rules.block.list.exec(pe);if(ye){for(var we=ye[0],Ie=ye[2],ke=Ie.length>1,Ve=Ie[Ie.length-1]===")",ut={type:"list",raw:we,ordered:ke,start:ke?+Ie.slice(0,-1):"",loose:!1,items:[]},ct=ye[0].match(this.rules.block.item),Lt=!1,Dt,Er,rr,xt,kr,Mr,Ur,ln=ct.length,Sr=0;Sr<ln;Sr++)Dt=ct[Sr],we=Dt,Er=Dt.length,Dt=Dt.replace(/^ *([*+-]|\d+[.)]) */,""),~Dt.indexOf(`
`)&&(Er-=Dt.length,Dt=this.options.pedantic?Dt.replace(/^ {1,4}/gm,""):Dt.replace(new RegExp("^ {1,"+Er+"}","gm"),"")),Sr!==ln-1&&(rr=this.rules.block.bullet.exec(ct[Sr+1])[0],(ke?rr.length===1||!Ve&&rr[rr.length-1]===")":rr.length>1||this.options.smartLists&&rr!==Ie)&&(xt=ct.slice(Sr+1).join(`
`),ut.raw=ut.raw.substring(0,ut.raw.length-xt.length),Sr=ln-1)),kr=Lt||/\n\n(?!\s*$)/.test(Dt),Sr!==ln-1&&(Lt=Dt.charAt(Dt.length-1)===`
`,kr||(kr=Lt)),kr&&(ut.loose=!0),Mr=/^\[[ xX]\] /.test(Dt),Ur=void 0,Mr&&(Ur=Dt[1]!==" ",Dt=Dt.replace(/^\[[ xX]\] +/,"")),ut.items.push({type:"list_item",raw:we,task:Mr,checked:Ur,loose:kr,text:Dt});return ut}},Ce.html=function(pe){var ye=this.rules.block.html.exec(pe);if(ye)return{type:this.options.sanitize?"paragraph":"html",raw:ye[0],pre:!this.options.sanitizer&&(ye[1]==="pre"||ye[1]==="script"||ye[1]==="style"),text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(ye[0]):Y(ye[0]):ye[0]}},Ce.def=function(pe){var ye=this.rules.block.def.exec(pe);if(ye){ye[3]&&(ye[3]=ye[3].substring(1,ye[3].length-1));var we=ye[1].toLowerCase().replace(/\s+/g," ");return{tag:we,raw:ye[0],href:ye[2],title:ye[3]}}},Ce.table=function(pe){var ye=this.rules.block.table.exec(pe);if(ye){var we={type:"table",header:K(ye[1].replace(/^ *| *\| *$/g,"")),align:ye[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:ye[3]?ye[3].replace(/\n$/,"").split(`
`):[]};if(we.header.length===we.align.length){we.raw=ye[0];var Ie=we.align.length,ke;for(ke=0;ke<Ie;ke++)/^ *-+: *$/.test(we.align[ke])?we.align[ke]="right":/^ *:-+: *$/.test(we.align[ke])?we.align[ke]="center":/^ *:-+ *$/.test(we.align[ke])?we.align[ke]="left":we.align[ke]=null;for(Ie=we.cells.length,ke=0;ke<Ie;ke++)we.cells[ke]=K(we.cells[ke].replace(/^ *\| *| *\| *$/g,""),we.header.length);return we}}},Ce.lheading=function(pe){var ye=this.rules.block.lheading.exec(pe);if(ye)return{type:"heading",raw:ye[0],depth:ye[2].charAt(0)==="="?1:2,text:ye[1]}},Ce.paragraph=function(pe){var ye=this.rules.block.paragraph.exec(pe);if(ye)return{type:"paragraph",raw:ye[0],text:ye[1].charAt(ye[1].length-1)===`
`?ye[1].slice(0,-1):ye[1]}},Ce.text=function(pe,ye){var we=this.rules.block.text.exec(pe);if(we){var Ie=ye[ye.length-1];return Ie&&Ie.type==="text"?{raw:we[0],text:we[0]}:{type:"text",raw:we[0],text:we[0]}}},Ce.escape=function(pe){var ye=this.rules.inline.escape.exec(pe);if(ye)return{type:"escape",raw:ye[0],text:Y(ye[1])}},Ce.tag=function(pe,ye,we){var Ie=this.rules.inline.tag.exec(pe);if(Ie)return!ye&&/^<a /i.test(Ie[0])?ye=!0:ye&&/^<\/a>/i.test(Ie[0])&&(ye=!1),!we&&/^<(pre|code|kbd|script)(\s|>)/i.test(Ie[0])?we=!0:we&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(Ie[0])&&(we=!1),{type:this.options.sanitize?"text":"html",raw:Ie[0],inLink:ye,inRawBlock:we,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(Ie[0]):Y(Ie[0]):Ie[0]}},Ce.link=function(pe){var ye=this.rules.inline.link.exec(pe);if(ye){var we=ne(ye[2],"()");if(we>-1){var Ie=ye[0].indexOf("!")===0?5:4,ke=Ie+ye[1].length+we;ye[2]=ye[2].substring(0,we),ye[0]=ye[0].substring(0,ke).trim(),ye[3]=""}var Ve=ye[2],ut="";if(this.options.pedantic){var ct=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(Ve);ct?(Ve=ct[1],ut=ct[3]):ut=""}else ut=ye[3]?ye[3].slice(1,-1):"";Ve=Ve.trim().replace(/^<([\s\S]*)>$/,"$1");var Lt=oe(ye,{href:Ve&&Ve.replace(this.rules.inline._escapes,"$1"),title:ut&&ut.replace(this.rules.inline._escapes,"$1")},ye[0]);return Lt}},Ce.reflink=function(pe,ye){var we;if((we=this.rules.inline.reflink.exec(pe))||(we=this.rules.inline.nolink.exec(pe))){var Ie=(we[2]||we[1]).replace(/\s+/g," ");if(Ie=ye[Ie.toLowerCase()],!Ie||!Ie.href){var ke=we[0].charAt(0);return{type:"text",raw:ke,text:ke}}var Ve=oe(we,Ie,we[0]);return Ve}},Ce.strong=function(pe,ye,we){we===void 0&&(we="");var Ie=this.rules.inline.strong.start.exec(pe);if(Ie&&(!Ie[1]||Ie[1]&&(we===""||this.rules.inline.punctuation.exec(we)))){ye=ye.slice(-1*pe.length);var ke=Ie[0]==="**"?this.rules.inline.strong.endAst:this.rules.inline.strong.endUnd;ke.lastIndex=0;for(var Ve;(Ie=ke.exec(ye))!=null;)if(Ve=this.rules.inline.strong.middle.exec(ye.slice(0,Ie.index+3)),Ve)return{type:"strong",raw:pe.slice(0,Ve[0].length),text:pe.slice(2,Ve[0].length-2)}}},Ce.em=function(pe,ye,we){we===void 0&&(we="");var Ie=this.rules.inline.em.start.exec(pe);if(Ie&&(!Ie[1]||Ie[1]&&(we===""||this.rules.inline.punctuation.exec(we)))){ye=ye.slice(-1*pe.length);var ke=Ie[0]==="*"?this.rules.inline.em.endAst:this.rules.inline.em.endUnd;ke.lastIndex=0;for(var Ve;(Ie=ke.exec(ye))!=null;)if(Ve=this.rules.inline.em.middle.exec(ye.slice(0,Ie.index+2)),Ve)return{type:"em",raw:pe.slice(0,Ve[0].length),text:pe.slice(1,Ve[0].length-1)}}},Ce.codespan=function(pe){var ye=this.rules.inline.code.exec(pe);if(ye){var we=ye[2].replace(/\n/g," "),Ie=/[^ ]/.test(we),ke=we.startsWith(" ")&&we.endsWith(" ");return Ie&&ke&&(we=we.substring(1,we.length-1)),we=Y(we,!0),{type:"codespan",raw:ye[0],text:we}}},Ce.br=function(pe){var ye=this.rules.inline.br.exec(pe);if(ye)return{type:"br",raw:ye[0]}},Ce.del=function(pe){var ye=this.rules.inline.del.exec(pe);if(ye)return{type:"del",raw:ye[0],text:ye[1]}},Ce.autolink=function(pe,ye){var we=this.rules.inline.autolink.exec(pe);if(we){var Ie,ke;return we[2]==="@"?(Ie=Y(this.options.mangle?ye(we[1]):we[1]),ke="mailto:"+Ie):(Ie=Y(we[1]),ke=Ie),{type:"link",raw:we[0],text:Ie,href:ke,tokens:[{type:"text",raw:Ie,text:Ie}]}}},Ce.url=function(pe,ye){var we;if(we=this.rules.inline.url.exec(pe)){var Ie,ke;if(we[2]==="@")Ie=Y(this.options.mangle?ye(we[0]):we[0]),ke="mailto:"+Ie;else{var Ve;do Ve=we[0],we[0]=this.rules.inline._backpedal.exec(we[0])[0];while(Ve!==we[0]);Ie=Y(we[0]),we[1]==="www."?ke="http://"+Ie:ke=Ie}return{type:"link",raw:we[0],text:Ie,href:ke,tokens:[{type:"text",raw:Ie,text:Ie}]}}},Ce.inlineText=function(pe,ye,we){var Ie=this.rules.inline.text.exec(pe);if(Ie){var ke;return ye?ke=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(Ie[0]):Y(Ie[0]):Ie[0]:ke=Y(this.options.smartypants?we(Ie[0]):Ie[0]),{type:"text",raw:Ie[0],text:ke}}},Me}(),le=z.noopTest,me=z.edit,de=z.merge,ae={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?:\n+|$)|$)/,hr:/^ {0,3}((?:- *){3,}|(?:_ *){3,}|(?:\* *){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6}) +([^\n]*?)(?: +#+)? *(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3})(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:"^ {0,3}(?:<(script|pre|style)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?\\?>\\n*|<![A-Z][\\s\\S]*?>\\n*|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>\\n*|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:\\n{2,}|$)|<(?!script|pre|style)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$)|</(?!script|pre|style)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:\\n{2,}|$))",def:/^ {0,3}\[(label)\]: *\n? *<?([^\s>]+)>?(?:(?: +\n? *| *\n *)(title))? *(?:\n+|$)/,nptable:le,table:le,lheading:/^([^\n]+)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html)[^\n]+)*)/,text:/^[^\n]+/};ae._label=/(?!\s*\])(?:\\[\[\]]|[^\[\]])+/,ae._title=/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/,ae.def=me(ae.def).replace("label",ae._label).replace("title",ae._title).getRegex(),ae.bullet=/(?:[*+-]|\d{1,9}[.)])/,ae.item=/^( *)(bull) ?[^\n]*(?:\n(?!\1bull ?)[^\n]*)*/,ae.item=me(ae.item,"gm").replace(/bull/g,ae.bullet).getRegex(),ae.list=me(ae.list).replace(/bull/g,ae.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+ae.def.source+")").getRegex(),ae._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",ae._comment=/<!--(?!-?>)[\s\S]*?-->/,ae.html=me(ae.html,"i").replace("comment",ae._comment).replace("tag",ae._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),ae.paragraph=me(ae._paragraph).replace("hr",ae.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",ae._tag).getRegex(),ae.blockquote=me(ae.blockquote).replace("paragraph",ae.paragraph).getRegex(),ae.normal=de({},ae),ae.gfm=de({},ae.normal,{nptable:"^ *([^|\\n ].*\\|.*)\\n *([-:]+ *\\|[-| :]*)(?:\\n((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)",table:"^ *\\|(.+)\\n *\\|?( *[-:]+[-| :]*)(?:\\n *((?:(?!\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"}),ae.gfm.nptable=me(ae.gfm.nptable).replace("hr",ae.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",ae._tag).getRegex(),ae.gfm.table=me(ae.gfm.table).replace("hr",ae.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|!--)").replace("tag",ae._tag).getRegex(),ae.pedantic=de({},ae.normal,{html:me(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",ae._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/,fences:le,paragraph:me(ae.normal._paragraph).replace("hr",ae.hr).replace("heading",` *#{1,6} *[^
]`).replace("lheading",ae.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()});var ie={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:le,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/,nolink:/^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",strong:{start:/^(?:(\*\*(?=[*punctuation]))|\*\*)(?![\s])|__/,middle:/^\*\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*\*$|^__(?![\s])((?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?)__$/,endAst:/[^punctuation\s]\*\*(?!\*)|[punctuation]\*\*(?!\*)(?:(?=[punctuation\s]|$))/,endUnd:/[^\s]__(?!_)(?:(?=[punctuation\s])|$)/},em:{start:/^(?:(\*(?=[punctuation]))|\*)(?![*\s])|_/,middle:/^\*(?:(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)|\*(?:(?!overlapSkip)(?:[^*]|\\\*)|overlapSkip)*?\*)+?\*$|^_(?![_\s])(?:(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)|_(?:(?!overlapSkip)(?:[^_]|\\_)|overlapSkip)*?_)+?_$/,endAst:/[^punctuation\s]\*(?!\*)|[punctuation]\*(?!\*)(?:(?=[punctuation\s]|$))/,endUnd:/[^\s]_(?!_)(?:(?=[punctuation\s])|$)/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:le,text:/^(`+|[^`])(?:[\s\S]*?(?:(?=[\\<!\[`*]|\b_|$)|[^ ](?= {2,}\n))|(?= {2,}\n))/,punctuation:/^([\s*punctuation])/};ie._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",ie.punctuation=me(ie.punctuation).replace(/punctuation/g,ie._punctuation).getRegex(),ie._blockSkip="\\[[^\\]]*?\\]\\([^\\)]*?\\)|`[^`]*?`|<[^>]*?>",ie._overlapSkip="__[^_]*?__|\\*\\*\\[^\\*\\]*?\\*\\*",ie.em.start=me(ie.em.start).replace(/punctuation/g,ie._punctuation).getRegex(),ie.em.middle=me(ie.em.middle).replace(/punctuation/g,ie._punctuation).replace(/overlapSkip/g,ie._overlapSkip).getRegex(),ie.em.endAst=me(ie.em.endAst,"g").replace(/punctuation/g,ie._punctuation).getRegex(),ie.em.endUnd=me(ie.em.endUnd,"g").replace(/punctuation/g,ie._punctuation).getRegex(),ie.strong.start=me(ie.strong.start).replace(/punctuation/g,ie._punctuation).getRegex(),ie.strong.middle=me(ie.strong.middle).replace(/punctuation/g,ie._punctuation).replace(/blockSkip/g,ie._blockSkip).getRegex(),ie.strong.endAst=me(ie.strong.endAst,"g").replace(/punctuation/g,ie._punctuation).getRegex(),ie.strong.endUnd=me(ie.strong.endUnd,"g").replace(/punctuation/g,ie._punctuation).getRegex(),ie.blockSkip=me(ie._blockSkip,"g").getRegex(),ie.overlapSkip=me(ie._overlapSkip,"g").getRegex(),ie._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,ie._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,ie._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,ie.autolink=me(ie.autolink).replace("scheme",ie._scheme).replace("email",ie._email).getRegex(),ie._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,ie.tag=me(ie.tag).replace("comment",ae._comment).replace("attribute",ie._attribute).getRegex(),ie._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,ie._href=/<(?:\\[<>]?|[^\s<>\\])*>|[^\s\x00-\x1f]*/,ie._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,ie.link=me(ie.link).replace("label",ie._label).replace("href",ie._href).replace("title",ie._title).getRegex(),ie.reflink=me(ie.reflink).replace("label",ie._label).getRegex(),ie.reflinkSearch=me(ie.reflinkSearch,"g").replace("reflink",ie.reflink).replace("nolink",ie.nolink).getRegex(),ie.normal=de({},ie),ie.pedantic=de({},ie.normal,{strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:me(/^!?\[(label)\]\((.*?)\)/).replace("label",ie._label).getRegex(),reflink:me(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",ie._label).getRegex()}),ie.gfm=de({},ie.normal,{escape:me(ie.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_~)]+(?!$))+/,del:/^~+(?=\S)([\s\S]*?\S)~+/,text:/^(`+|[^`])(?:[\s\S]*?(?:(?=[\\<!\[`*~]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))|(?= {2,}\n|[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))/}),ie.gfm.url=me(ie.gfm.url,"i").replace("email",ie.gfm._extended_email).getRegex(),ie.breaks=de({},ie.gfm,{br:me(ie.br).replace("{2,}","*").getRegex(),text:me(ie.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()});var q={block:ae,inline:ie},ue=w.defaults,Z=q.block,ee=q.inline;function Ee(Me){return Me.replace(/---/g,"\u2014").replace(/--/g,"\u2013").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1\u2018").replace(/'/g,"\u2019").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1\u201C").replace(/"/g,"\u201D").replace(/\.{3}/g,"\u2026")}function te(Me){var Ce="",Re,pe,ye=Me.length;for(Re=0;Re<ye;Re++)pe=Me.charCodeAt(Re),Math.random()>.5&&(pe="x"+pe.toString(16)),Ce+="&#"+pe+";";return Ce}var J=function(){function Me(Re){this.tokens=[],this.tokens.links=Object.create(null),this.options=Re||ue,this.options.tokenizer=this.options.tokenizer||new xe,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options;var pe={block:Z.normal,inline:ee.normal};this.options.pedantic?(pe.block=Z.pedantic,pe.inline=ee.pedantic):this.options.gfm&&(pe.block=Z.gfm,this.options.breaks?pe.inline=ee.breaks:pe.inline=ee.gfm),this.tokenizer.rules=pe}Me.lex=function(pe,ye){var we=new Me(ye);return we.lex(pe)};var Ce=Me.prototype;return Ce.lex=function(pe){return pe=pe.replace(/\r\n|\r/g,`
`).replace(/\t/g," "),this.blockTokens(pe,this.tokens,!0),this.inline(this.tokens),this.tokens},Ce.blockTokens=function(pe,ye,we){ye===void 0&&(ye=[]),we===void 0&&(we=!0),pe=pe.replace(/^ +$/gm,"");for(var Ie,ke,Ve,ut;pe;){if(Ie=this.tokenizer.space(pe)){pe=pe.substring(Ie.raw.length),Ie.type&&ye.push(Ie);continue}if(Ie=this.tokenizer.code(pe,ye)){pe=pe.substring(Ie.raw.length),Ie.type?ye.push(Ie):(ut=ye[ye.length-1],ut.raw+=`
`+Ie.raw,ut.text+=`
`+Ie.text);continue}if(Ie=this.tokenizer.fences(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(Ie=this.tokenizer.heading(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(Ie=this.tokenizer.nptable(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(Ie=this.tokenizer.hr(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(Ie=this.tokenizer.blockquote(pe)){pe=pe.substring(Ie.raw.length),Ie.tokens=this.blockTokens(Ie.text,[],we),ye.push(Ie);continue}if(Ie=this.tokenizer.list(pe)){for(pe=pe.substring(Ie.raw.length),Ve=Ie.items.length,ke=0;ke<Ve;ke++)Ie.items[ke].tokens=this.blockTokens(Ie.items[ke].text,[],!1);ye.push(Ie);continue}if(Ie=this.tokenizer.html(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(we&&(Ie=this.tokenizer.def(pe))){pe=pe.substring(Ie.raw.length),this.tokens.links[Ie.tag]||(this.tokens.links[Ie.tag]={href:Ie.href,title:Ie.title});continue}if(Ie=this.tokenizer.table(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(Ie=this.tokenizer.lheading(pe)){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(we&&(Ie=this.tokenizer.paragraph(pe))){pe=pe.substring(Ie.raw.length),ye.push(Ie);continue}if(Ie=this.tokenizer.text(pe,ye)){pe=pe.substring(Ie.raw.length),Ie.type?ye.push(Ie):(ut=ye[ye.length-1],ut.raw+=`
`+Ie.raw,ut.text+=`
`+Ie.text);continue}if(pe){var ct="Infinite loop on byte: "+pe.charCodeAt(0);if(this.options.silent){console.error(ct);break}else throw new Error(ct)}}return ye},Ce.inline=function(pe){var ye,we,Ie,ke,Ve,ut,ct=pe.length;for(ye=0;ye<ct;ye++){ut=pe[ye];switch(ut.type){case"paragraph":case"text":case"heading":{ut.tokens=[],this.inlineTokens(ut.text,ut.tokens);break}case"table":{for(ut.tokens={header:[],cells:[]},ke=ut.header.length,we=0;we<ke;we++)ut.tokens.header[we]=[],this.inlineTokens(ut.header[we],ut.tokens.header[we]);for(ke=ut.cells.length,we=0;we<ke;we++)for(Ve=ut.cells[we],ut.tokens.cells[we]=[],Ie=0;Ie<Ve.length;Ie++)ut.tokens.cells[we][Ie]=[],this.inlineTokens(Ve[Ie],ut.tokens.cells[we][Ie]);break}case"blockquote":{this.inline(ut.tokens);break}case"list":{for(ke=ut.items.length,we=0;we<ke;we++)this.inline(ut.items[we].tokens);break}}}return pe},Ce.inlineTokens=function(pe,ye,we,Ie,ke){ye===void 0&&(ye=[]),we===void 0&&(we=!1),Ie===void 0&&(Ie=!1),ke===void 0&&(ke="");var Ve,ut=pe,ct;if(this.tokens.links){var Lt=Object.keys(this.tokens.links);if(Lt.length>0)for(;(ct=this.tokenizer.rules.inline.reflinkSearch.exec(ut))!=null;)Lt.includes(ct[0].slice(ct[0].lastIndexOf("[")+1,-1))&&(ut=ut.slice(0,ct.index)+"["+"a".repeat(ct[0].length-2)+"]"+ut.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(ct=this.tokenizer.rules.inline.blockSkip.exec(ut))!=null;)ut=ut.slice(0,ct.index)+"["+"a".repeat(ct[0].length-2)+"]"+ut.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;pe;){if(Ve=this.tokenizer.escape(pe)){pe=pe.substring(Ve.raw.length),ye.push(Ve);continue}if(Ve=this.tokenizer.tag(pe,we,Ie)){pe=pe.substring(Ve.raw.length),we=Ve.inLink,Ie=Ve.inRawBlock,ye.push(Ve);continue}if(Ve=this.tokenizer.link(pe)){pe=pe.substring(Ve.raw.length),Ve.type==="link"&&(Ve.tokens=this.inlineTokens(Ve.text,[],!0,Ie)),ye.push(Ve);continue}if(Ve=this.tokenizer.reflink(pe,this.tokens.links)){pe=pe.substring(Ve.raw.length),Ve.type==="link"&&(Ve.tokens=this.inlineTokens(Ve.text,[],!0,Ie)),ye.push(Ve);continue}if(Ve=this.tokenizer.strong(pe,ut,ke)){pe=pe.substring(Ve.raw.length),Ve.tokens=this.inlineTokens(Ve.text,[],we,Ie),ye.push(Ve);continue}if(Ve=this.tokenizer.em(pe,ut,ke)){pe=pe.substring(Ve.raw.length),Ve.tokens=this.inlineTokens(Ve.text,[],we,Ie),ye.push(Ve);continue}if(Ve=this.tokenizer.codespan(pe)){pe=pe.substring(Ve.raw.length),ye.push(Ve);continue}if(Ve=this.tokenizer.br(pe)){pe=pe.substring(Ve.raw.length),ye.push(Ve);continue}if(Ve=this.tokenizer.del(pe)){pe=pe.substring(Ve.raw.length),Ve.tokens=this.inlineTokens(Ve.text,[],we,Ie),ye.push(Ve);continue}if(Ve=this.tokenizer.autolink(pe,te)){pe=pe.substring(Ve.raw.length),ye.push(Ve);continue}if(!we&&(Ve=this.tokenizer.url(pe,te))){pe=pe.substring(Ve.raw.length),ye.push(Ve);continue}if(Ve=this.tokenizer.inlineText(pe,Ie,Ee)){pe=pe.substring(Ve.raw.length),ke=Ve.raw.slice(-1),ye.push(Ve);continue}if(pe){var Dt="Infinite loop on byte: "+pe.charCodeAt(0);if(this.options.silent){console.error(Dt);break}else throw new Error(Dt)}}return ye},v(Me,null,[{key:"rules",get:function(){return{block:Z,inline:ee}}}]),Me}(),X=w.defaults,$=z.cleanUrl,ge=z.escape,fe=function(){function Me(Re){this.options=Re||X}var Ce=Me.prototype;return Ce.code=function(pe,ye,we){var Ie=(ye||"").match(/\S*/)[0];if(this.options.highlight){var ke=this.options.highlight(pe,Ie);ke!=null&&ke!==pe&&(we=!0,pe=ke)}return Ie?'<pre><code class="'+this.options.langPrefix+ge(Ie,!0)+'">'+(we?pe:ge(pe,!0))+`</code></pre>
`:"<pre><code>"+(we?pe:ge(pe,!0))+`</code></pre>
`},Ce.blockquote=function(pe){return`<blockquote>
`+pe+`</blockquote>
`},Ce.html=function(pe){return pe},Ce.heading=function(pe,ye,we,Ie){return this.options.headerIds?"<h"+ye+' id="'+this.options.headerPrefix+Ie.slug(we)+'">'+pe+"</h"+ye+`>
`:"<h"+ye+">"+pe+"</h"+ye+`>
`},Ce.hr=function(){return this.options.xhtml?`<hr/>
`:`<hr>
`},Ce.list=function(pe,ye,we){var Ie=ye?"ol":"ul",ke=ye&&we!==1?' start="'+we+'"':"";return"<"+Ie+ke+`>
`+pe+"</"+Ie+`>
`},Ce.listitem=function(pe){return"<li>"+pe+`</li>
`},Ce.checkbox=function(pe){return"<input "+(pe?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "},Ce.paragraph=function(pe){return"<p>"+pe+`</p>
`},Ce.table=function(pe,ye){return ye&&(ye="<tbody>"+ye+"</tbody>"),`<table>
<thead>
`+pe+`</thead>
`+ye+`</table>
`},Ce.tablerow=function(pe){return`<tr>
`+pe+`</tr>
`},Ce.tablecell=function(pe,ye){var we=ye.header?"th":"td",Ie=ye.align?"<"+we+' align="'+ye.align+'">':"<"+we+">";return Ie+pe+"</"+we+`>
`},Ce.strong=function(pe){return"<strong>"+pe+"</strong>"},Ce.em=function(pe){return"<em>"+pe+"</em>"},Ce.codespan=function(pe){return"<code>"+pe+"</code>"},Ce.br=function(){return this.options.xhtml?"<br/>":"<br>"},Ce.del=function(pe){return"<del>"+pe+"</del>"},Ce.link=function(pe,ye,we){if(pe=$(this.options.sanitize,this.options.baseUrl,pe),pe===null)return we;var Ie='<a href="'+ge(pe)+'"';return ye&&(Ie+=' title="'+ye+'"'),Ie+=">"+we+"</a>",Ie},Ce.image=function(pe,ye,we){if(pe=$(this.options.sanitize,this.options.baseUrl,pe),pe===null)return we;var Ie='<img src="'+pe+'" alt="'+we+'"';return ye&&(Ie+=' title="'+ye+'"'),Ie+=this.options.xhtml?"/>":">",Ie},Ce.text=function(pe){return pe},Me}(),Te=function(){function Me(){}var Ce=Me.prototype;return Ce.strong=function(pe){return pe},Ce.em=function(pe){return pe},Ce.codespan=function(pe){return pe},Ce.del=function(pe){return pe},Ce.html=function(pe){return pe},Ce.text=function(pe){return pe},Ce.link=function(pe,ye,we){return""+we},Ce.image=function(pe,ye,we){return""+we},Ce.br=function(){return""},Me}(),ze=function(){function Me(){this.seen={}}var Ce=Me.prototype;return Ce.slug=function(pe){var ye=pe.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-");if(this.seen.hasOwnProperty(ye)){var we=ye;do this.seen[we]++,ye=we+"-"+this.seen[we];while(this.seen.hasOwnProperty(ye))}return this.seen[ye]=0,ye},Me}(),Xe=w.defaults,Ye=z.unescape,rt=function(){function Me(Re){this.options=Re||Xe,this.options.renderer=this.options.renderer||new fe,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new Te,this.slugger=new ze}Me.parse=function(pe,ye){var we=new Me(ye);return we.parse(pe)};var Ce=Me.prototype;return Ce.parse=function(pe,ye){ye===void 0&&(ye=!0);var we="",Ie,ke,Ve,ut,ct,Lt,Dt,Er,rr,xt,kr,Mr,Ur,ln,Sr,an,qr,Bt,ur=pe.length;for(Ie=0;Ie<ur;Ie++){xt=pe[Ie];switch(xt.type){case"space":continue;case"hr":{we+=this.renderer.hr();continue}case"heading":{we+=this.renderer.heading(this.parseInline(xt.tokens),xt.depth,Ye(this.parseInline(xt.tokens,this.textRenderer)),this.slugger);continue}case"code":{we+=this.renderer.code(xt.text,xt.lang,xt.escaped);continue}case"table":{for(Er="",Dt="",ut=xt.header.length,ke=0;ke<ut;ke++)Dt+=this.renderer.tablecell(this.parseInline(xt.tokens.header[ke]),{header:!0,align:xt.align[ke]});for(Er+=this.renderer.tablerow(Dt),rr="",ut=xt.cells.length,ke=0;ke<ut;ke++){for(Lt=xt.tokens.cells[ke],Dt="",ct=Lt.length,Ve=0;Ve<ct;Ve++)Dt+=this.renderer.tablecell(this.parseInline(Lt[Ve]),{header:!1,align:xt.align[Ve]});rr+=this.renderer.tablerow(Dt)}we+=this.renderer.table(Er,rr);continue}case"blockquote":{rr=this.parse(xt.tokens),we+=this.renderer.blockquote(rr);continue}case"list":{for(kr=xt.ordered,Mr=xt.start,Ur=xt.loose,ut=xt.items.length,rr="",ke=0;ke<ut;ke++)Sr=xt.items[ke],an=Sr.checked,qr=Sr.task,ln="",Sr.task&&(Bt=this.renderer.checkbox(an),Ur?Sr.tokens.length>0&&Sr.tokens[0].type==="text"?(Sr.tokens[0].text=Bt+" "+Sr.tokens[0].text,Sr.tokens[0].tokens&&Sr.tokens[0].tokens.length>0&&Sr.tokens[0].tokens[0].type==="text"&&(Sr.tokens[0].tokens[0].text=Bt+" "+Sr.tokens[0].tokens[0].text)):Sr.tokens.unshift({type:"text",text:Bt}):ln+=Bt),ln+=this.parse(Sr.tokens,Ur),rr+=this.renderer.listitem(ln,qr,an);we+=this.renderer.list(rr,kr,Mr);continue}case"html":{we+=this.renderer.html(xt.text);continue}case"paragraph":{we+=this.renderer.paragraph(this.parseInline(xt.tokens));continue}case"text":{for(rr=xt.tokens?this.parseInline(xt.tokens):xt.text;Ie+1<ur&&pe[Ie+1].type==="text";)xt=pe[++Ie],rr+=`
`+(xt.tokens?this.parseInline(xt.tokens):xt.text);we+=ye?this.renderer.paragraph(rr):rr;continue}default:{var jr='Token with "'+xt.type+'" type was not found.';if(this.options.silent){console.error(jr);return}else throw new Error(jr)}}}return we},Ce.parseInline=function(pe,ye){ye=ye||this.renderer;var we="",Ie,ke,Ve=pe.length;for(Ie=0;Ie<Ve;Ie++){ke=pe[Ie];switch(ke.type){case"escape":{we+=ye.text(ke.text);break}case"html":{we+=ye.html(ke.text);break}case"link":{we+=ye.link(ke.href,ke.title,this.parseInline(ke.tokens,ye));break}case"image":{we+=ye.image(ke.href,ke.title,ke.text);break}case"strong":{we+=ye.strong(this.parseInline(ke.tokens,ye));break}case"em":{we+=ye.em(this.parseInline(ke.tokens,ye));break}case"codespan":{we+=ye.codespan(ke.text);break}case"br":{we+=ye.br();break}case"del":{we+=ye.del(this.parseInline(ke.tokens,ye));break}case"text":{we+=ye.text(ke.text);break}default:{var ut='Token with "'+ke.type+'" type was not found.';if(this.options.silent){console.error(ut);return}else throw new Error(ut)}}}return we},Me}(),at=z.merge,ot=z.checkSanitizeDeprecation,Pe=z.escape,Se=w.getDefaults,Je=w.changeDefaults,nt=w.defaults;function We(Me,Ce,Re){if(typeof Me=="undefined"||Me===null)throw new Error("marked(): input parameter is undefined or null");if(typeof Me!="string")throw new Error("marked(): input parameter is of type "+Object.prototype.toString.call(Me)+", string expected");if(typeof Ce=="function"&&(Re=Ce,Ce=null),Ce=at({},We.defaults,Ce||{}),ot(Ce),Re){var pe=Ce.highlight,ye;try{ye=J.lex(Me,Ce)}catch(Ve){return Re(Ve)}var we=function(ut){var ct;if(!ut)try{ct=rt.parse(ye,Ce)}catch(Lt){ut=Lt}return Ce.highlight=pe,ut?Re(ut):Re(null,ct)};if(!pe||pe.length<3)return we();if(delete Ce.highlight,!ye.length)return we();var Ie=0;We.walkTokens(ye,function(Ve){Ve.type==="code"&&(Ie++,setTimeout(function(){pe(Ve.text,Ve.lang,function(ut,ct){if(ut)return we(ut);ct!=null&&ct!==Ve.text&&(Ve.text=ct,Ve.escaped=!0),Ie--,Ie===0&&we()})},0))}),Ie===0&&we();return}try{var ke=J.lex(Me,Ce);return Ce.walkTokens&&We.walkTokens(ke,Ce.walkTokens),rt.parse(ke,Ce)}catch(Ve){if(Ve.message+=`
Please report this to https://github.com/markedjs/marked.`,Ce.silent)return"<p>An error occurred:</p><pre>"+Pe(Ve.message+"",!0)+"</pre>";throw Ve}}We.options=We.setOptions=function(Me){return at(We.defaults,Me),Je(We.defaults),We},We.getDefaults=Se,We.defaults=nt,We.use=function(Me){var Ce=at({},Me);if(Me.renderer&&function(){var pe=We.defaults.renderer||new fe,ye=function(ke){var Ve=pe[ke];pe[ke]=function(){for(var ut=arguments.length,ct=new Array(ut),Lt=0;Lt<ut;Lt++)ct[Lt]=arguments[Lt];var Dt=Me.renderer[ke].apply(pe,ct);return Dt===!1&&(Dt=Ve.apply(pe,ct)),Dt}};for(var we in Me.renderer)ye(we);Ce.renderer=pe}(),Me.tokenizer&&function(){var pe=We.defaults.tokenizer||new xe,ye=function(ke){var Ve=pe[ke];pe[ke]=function(){for(var ut=arguments.length,ct=new Array(ut),Lt=0;Lt<ut;Lt++)ct[Lt]=arguments[Lt];var Dt=Me.tokenizer[ke].apply(pe,ct);return Dt===!1&&(Dt=Ve.apply(pe,ct)),Dt}};for(var we in Me.tokenizer)ye(we);Ce.tokenizer=pe}(),Me.walkTokens){var Re=We.defaults.walkTokens;Ce.walkTokens=function(pe){Me.walkTokens(pe),Re&&Re(pe)}}We.setOptions(Ce)},We.walkTokens=function(Me,Ce){for(var Re=m(Me),pe;!(pe=Re()).done;){var ye=pe.value;Ce(ye);switch(ye.type){case"table":{for(var we=m(ye.tokens.header),Ie;!(Ie=we()).done;){var ke=Ie.value;We.walkTokens(ke,Ce)}for(var Ve=m(ye.tokens.cells),ut;!(ut=Ve()).done;)for(var ct=ut.value,Lt=m(ct),Dt;!(Dt=Lt()).done;){var Er=Dt.value;We.walkTokens(Er,Ce)}break}case"list":{We.walkTokens(ye.items,Ce);break}default:ye.tokens&&We.walkTokens(ye.tokens,Ce)}}},We.Parser=rt,We.parser=rt.parse,We.Renderer=fe,We.TextRenderer=Te,We.Lexer=J,We.lexer=J.lex,We.Tokenizer=xe,We.Slugger=ze,We.parse=We;var et=We;return et})},E4JC:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("ETIr"),j("cv67"),j("K3mO"),j("OLod"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.StreamCipher,m=v.algo,y=[],w=[],b=[],p=m.Rabbit=M.extend({_doReset:function(){for(var n=this._key.words,c=this.cfg.iv,r=0;r<4;r++)n[r]=(n[r]<<8|n[r]>>>24)&16711935|(n[r]<<24|n[r]>>>8)&4278255360;var i=this._X=[n[0],n[3]<<16|n[2]>>>16,n[1],n[0]<<16|n[3]>>>16,n[2],n[1]<<16|n[0]>>>16,n[3],n[2]<<16|n[1]>>>16],o=this._C=[n[2]<<16|n[2]>>>16,n[0]&4294901760|n[1]&65535,n[3]<<16|n[3]>>>16,n[1]&4294901760|n[2]&65535,n[0]<<16|n[0]>>>16,n[2]&4294901760|n[3]&65535,n[1]<<16|n[1]>>>16,n[3]&4294901760|n[0]&65535];this._b=0;for(var r=0;r<4;r++)d.call(this);for(var r=0;r<8;r++)o[r]^=i[r+4&7];if(c){var u=c.words,f=u[0],s=u[1],l=(f<<8|f>>>24)&16711935|(f<<24|f>>>8)&4278255360,t=(s<<8|s>>>24)&16711935|(s<<24|s>>>8)&4278255360,S=l>>>16|t&4294901760,x=t<<16|l&65535;o[0]^=l,o[1]^=S,o[2]^=t,o[3]^=x,o[4]^=l,o[5]^=S,o[6]^=t,o[7]^=x;for(var r=0;r<4;r++)d.call(this)}},_doProcessBlock:function(n,c){var r=this._X;d.call(this),y[0]=r[0]^r[5]>>>16^r[3]<<16,y[1]=r[2]^r[7]>>>16^r[5]<<16,y[2]=r[4]^r[1]>>>16^r[7]<<16,y[3]=r[6]^r[3]>>>16^r[1]<<16;for(var i=0;i<4;i++)y[i]=(y[i]<<8|y[i]>>>24)&16711935|(y[i]<<24|y[i]>>>8)&4278255360,n[c+i]^=y[i]},blockSize:128/32,ivSize:64/32});function d(){for(var n=this._X,c=this._C,r=0;r<8;r++)w[r]=c[r];c[0]=c[0]+1295307597+this._b|0,c[1]=c[1]+3545052371+(c[0]>>>0<w[0]>>>0?1:0)|0,c[2]=c[2]+886263092+(c[1]>>>0<w[1]>>>0?1:0)|0,c[3]=c[3]+1295307597+(c[2]>>>0<w[2]>>>0?1:0)|0,c[4]=c[4]+3545052371+(c[3]>>>0<w[3]>>>0?1:0)|0,c[5]=c[5]+886263092+(c[4]>>>0<w[4]>>>0?1:0)|0,c[6]=c[6]+1295307597+(c[5]>>>0<w[5]>>>0?1:0)|0,c[7]=c[7]+3545052371+(c[6]>>>0<w[6]>>>0?1:0)|0,this._b=c[7]>>>0<w[7]>>>0?1:0;for(var r=0;r<8;r++){var i=n[r]+c[r],o=i&65535,u=i>>>16,f=((o*o>>>17)+o*u>>>15)+u*u,s=((i&4294901760)*i|0)+((i&65535)*i|0);b[r]=f^s}n[0]=b[0]+(b[7]<<16|b[7]>>>16)+(b[6]<<16|b[6]>>>16)|0,n[1]=b[1]+(b[0]<<8|b[0]>>>24)+b[7]|0,n[2]=b[2]+(b[1]<<16|b[1]>>>16)+(b[0]<<16|b[0]>>>16)|0,n[3]=b[3]+(b[2]<<8|b[2]>>>24)+b[1]|0,n[4]=b[4]+(b[3]<<16|b[3]>>>16)+(b[2]<<16|b[2]>>>16)|0,n[5]=b[5]+(b[4]<<8|b[4]>>>24)+b[3]|0,n[6]=b[6]+(b[5]<<16|b[5]>>>16)+(b[4]<<16|b[4]>>>16)|0,n[7]=b[7]+(b[6]<<8|b[6]>>>24)+b[5]|0}v.Rabbit=M._createHelper(p)}(),N.Rabbit})},ELLl:function(F,Q,j){(function(N){N(j("VrN/"))})(function(N){var v={pairs:`()[]{}''""`,closeBefore:`)]}'":;>`,triples:"",explode:"[]{}"},C=N.Pos;N.defineOption("autoCloseBrackets",!1,function(o,u,f){f&&f!=N.Init&&(o.removeKeyMap(m),o.state.closeBrackets=null),u&&(y(M(u,"pairs")),o.state.closeBrackets=u,o.addKeyMap(m))});function M(o,u){return u=="pairs"&&typeof o=="string"?o:typeof o=="object"&&o[u]!=null?o[u]:v[u]}var m={Backspace:p,Enter:d};function y(o){for(var u=0;u<o.length;u++){var f=o.charAt(u),s="'"+f+"'";m[s]||(m[s]=w(f))}}y(v.pairs+"`");function w(o){return function(u){return c(u,o)}}function b(o){var u=o.state.closeBrackets;if(!u||u.override)return u;var f=o.getModeAt(o.getCursor());return f.closeBrackets||u}function p(o){var u=b(o);if(!u||o.getOption("disableInput"))return N.Pass;for(var f=M(u,"pairs"),s=o.listSelections(),l=0;l<s.length;l++){if(!s[l].empty())return N.Pass;var t=r(o,s[l].head);if(!t||f.indexOf(t)%2!=0)return N.Pass}for(var l=s.length-1;l>=0;l--){var S=s[l].head;o.replaceRange("",C(S.line,S.ch-1),C(S.line,S.ch+1),"+delete")}}function d(o){var u=b(o),f=u&&M(u,"explode");if(!f||o.getOption("disableInput"))return N.Pass;for(var s=o.listSelections(),l=0;l<s.length;l++){if(!s[l].empty())return N.Pass;var t=r(o,s[l].head);if(!t||f.indexOf(t)%2!=0)return N.Pass}o.operation(function(){var S=o.lineSeparator()||`
`;o.replaceSelection(S+S,null),o.execCommand("goCharLeft"),s=o.listSelections();for(var x=0;x<s.length;x++){var h=s[x].head.line;o.indentLine(h,null,!0),o.indentLine(h+1,null,!0)}})}function n(o){var u=N.cmpPos(o.anchor,o.head)>0;return{anchor:new C(o.anchor.line,o.anchor.ch+(u?-1:1)),head:new C(o.head.line,o.head.ch+(u?1:-1))}}function c(o,u){var f=b(o);if(!f||o.getOption("disableInput"))return N.Pass;var s=M(f,"pairs"),l=s.indexOf(u);if(l==-1)return N.Pass;for(var t=M(f,"closeBefore"),S=M(f,"triples"),x=s.charAt(l+1)==u,h=o.listSelections(),R=l%2==0,O,g=0;g<h.length;g++){var _=h[g],E=_.head,T,L=o.getRange(E,C(E.line,E.ch+1));if(R&&!_.empty())T="surround";else if((x||!R)&&L==u)x&&i(o,E)?T="both":S.indexOf(u)>=0&&o.getRange(E,C(E.line,E.ch+3))==u+u+u?T="skipThree":T="skip";else if(x&&E.ch>1&&S.indexOf(u)>=0&&o.getRange(C(E.line,E.ch-2),E)==u+u){if(E.ch>2&&/\bstring/.test(o.getTokenTypeAt(C(E.line,E.ch-2))))return N.Pass;T="addFour"}else if(x){var I=E.ch==0?" ":o.getRange(C(E.line,E.ch-1),E);if(!N.isWordChar(L)&&I!=u&&!N.isWordChar(I))T="both";else return N.Pass}else if(R&&(L.length===0||/\s/.test(L)||t.indexOf(L)>-1))T="both";else return N.Pass;if(!O)O=T;else if(O!=T)return N.Pass}var P=l%2?s.charAt(l-1):u,G=l%2?u:s.charAt(l+1);o.operation(function(){if(O=="skip")o.execCommand("goCharRight");else if(O=="skipThree")for(var W=0;W<3;W++)o.execCommand("goCharRight");else if(O=="surround"){for(var H=o.getSelections(),W=0;W<H.length;W++)H[W]=P+H[W]+G;o.replaceSelections(H,"around"),H=o.listSelections().slice();for(var W=0;W<H.length;W++)H[W]=n(H[W]);o.setSelections(H)}else O=="both"?(o.replaceSelection(P+G,null),o.triggerElectric(P+G),o.execCommand("goCharLeft")):O=="addFour"&&(o.replaceSelection(P+P+P+P,"before"),o.execCommand("goCharRight"))})}function r(o,u){var f=o.getRange(C(u.line,u.ch-1),C(u.line,u.ch+1));return f.length==2?f:null}function i(o,u){var f=o.getTokenAt(C(u.line,u.ch+1));return/\bstring/.test(f.type)&&f.start==u.ch&&(u.ch==0||!/\bstring/.test(o.getTokenTypeAt(u)))}})},ELcG:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){/** @preserve
(c) 2012 by Cédric Mesnil. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/return function(v){var C=N,M=C.lib,m=M.WordArray,y=M.Hasher,w=C.algo,b=m.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),p=m.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),d=m.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),n=m.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),c=m.create([0,1518500249,1859775393,2400959708,2840853838]),r=m.create([1352829926,1548603684,1836072691,2053994217,0]),i=w.RIPEMD160=y.extend({_doReset:function(){this._hash=m.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(S,x){for(var h=0;h<16;h++){var R=x+h,O=S[R];S[R]=(O<<8|O>>>24)&16711935|(O<<24|O>>>8)&4278255360}var g=this._hash.words,_=c.words,E=r.words,T=b.words,L=p.words,I=d.words,P=n.words,G,W,H,z,B,k,K,Y,ne,oe;k=G=g[0],K=W=g[1],Y=H=g[2],ne=z=g[3],oe=B=g[4];for(var _e,h=0;h<80;h+=1)_e=G+S[x+T[h]]|0,h<16?_e+=o(W,H,z)+_[0]:h<32?_e+=u(W,H,z)+_[1]:h<48?_e+=f(W,H,z)+_[2]:h<64?_e+=s(W,H,z)+_[3]:_e+=l(W,H,z)+_[4],_e=_e|0,_e=t(_e,I[h]),_e=_e+B|0,G=B,B=z,z=t(H,10),H=W,W=_e,_e=k+S[x+L[h]]|0,h<16?_e+=l(K,Y,ne)+E[0]:h<32?_e+=s(K,Y,ne)+E[1]:h<48?_e+=f(K,Y,ne)+E[2]:h<64?_e+=u(K,Y,ne)+E[3]:_e+=o(K,Y,ne)+E[4],_e=_e|0,_e=t(_e,P[h]),_e=_e+oe|0,k=oe,oe=ne,ne=t(Y,10),Y=K,K=_e;_e=g[1]+H+ne|0,g[1]=g[2]+z+oe|0,g[2]=g[3]+B+k|0,g[3]=g[4]+G+K|0,g[4]=g[0]+W+Y|0,g[0]=_e},_doFinalize:function(){var S=this._data,x=S.words,h=this._nDataBytes*8,R=S.sigBytes*8;x[R>>>5]|=128<<24-R%32,x[(R+64>>>9<<4)+14]=(h<<8|h>>>24)&16711935|(h<<24|h>>>8)&4278255360,S.sigBytes=(x.length+1)*4,this._process();for(var O=this._hash,g=O.words,_=0;_<5;_++){var E=g[_];g[_]=(E<<8|E>>>24)&16711935|(E<<24|E>>>8)&4278255360}return O},clone:function(){var S=y.clone.call(this);return S._hash=this._hash.clone(),S}});function o(S,x,h){return S^x^h}function u(S,x,h){return S&x|~S&h}function f(S,x,h){return(S|~x)^h}function s(S,x,h){return S&h|x&~h}function l(S,x,h){return S^(x|~h)}function t(S,x){return S<<x|S>>>32-x}C.RIPEMD160=y._createHelper(i),C.HmacRIPEMD160=y._createHmacHelper(i)}(Math),N.RIPEMD160})},ETIr:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.WordArray,m=v.enc,y=m.Base64={stringify:function(b){var p=b.words,d=b.sigBytes,n=this._map;b.clamp();for(var c=[],r=0;r<d;r+=3)for(var i=p[r>>>2]>>>24-r%4*8&255,o=p[r+1>>>2]>>>24-(r+1)%4*8&255,u=p[r+2>>>2]>>>24-(r+2)%4*8&255,f=i<<16|o<<8|u,s=0;s<4&&r+s*.75<d;s++)c.push(n.charAt(f>>>6*(3-s)&63));var l=n.charAt(64);if(l)for(;c.length%4;)c.push(l);return c.join("")},parse:function(b){var p=b.length,d=this._map,n=this._reverseMap;if(!n){n=this._reverseMap=[];for(var c=0;c<d.length;c++)n[d.charCodeAt(c)]=c}var r=d.charAt(64);if(r){var i=b.indexOf(r);i!==-1&&(p=i)}return w(b,p,n)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function w(b,p,d){for(var n=[],c=0,r=0;r<p;r++)if(r%4){var i=d[b.charCodeAt(r-1)]<<r%4*2,o=d[b.charCodeAt(r)]>>>6-r%4*2,u=i|o;n[c>>>2]|=u<<24-c%4*8,c++}return M.create(n,c)}}(),N.enc.Base64})},"F+F2":function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(){if(typeof ArrayBuffer!="function")return;var v=N,C=v.lib,M=C.WordArray,m=M.init,y=M.init=function(w){if(w instanceof ArrayBuffer&&(w=new Uint8Array(w)),(w instanceof Int8Array||typeof Uint8ClampedArray!="undefined"&&w instanceof Uint8ClampedArray||w instanceof Int16Array||w instanceof Uint16Array||w instanceof Int32Array||w instanceof Uint32Array||w instanceof Float32Array||w instanceof Float64Array)&&(w=new Uint8Array(w.buffer,w.byteOffset,w.byteLength)),w instanceof Uint8Array){for(var b=w.byteLength,p=[],d=0;d<b;d++)p[d>>>2]|=w[d]<<24-d%4*8;m.call(this,p,b)}else m.apply(this,arguments)};y.prototype=M}(),N.lib.WordArray})},GRO8:function(F,Q,j){"use strict";j.r(Q);var N=j("k1fw"),v=j("2qtc"),C=j("kLXV"),M=j("lUTK"),m=j("BvKs"),y=j("+L6B"),w=j("2/Rp"),b=j("T2oS"),p=j("W9HT"),d=j("sPJy"),n=j("bE4q"),c=j("miYZ"),r=j("tsqr"),i=j("9og8"),o=j("tJVT"),u=j("PpiC"),f=j("WmNS"),s=j.n(f),l=j("cDcd"),t=j.n(l),S=j("Ty5D"),x=j("55Ip"),h=j("9kvl"),R=j("KeDT"),O=j.n(R),g=j("zrhs"),_=j("DZo9"),E=j("8z0m"),T=j("LtfV"),L=j("KhGG"),I=E.a.Dragger,P=function(qe){var pt=qe.user,_t=qe.dispatch,Ut=qe.classroomList,At=qe.shixunsDetail,Xt=qe.getResults,kt=Object(S.i)(),st=Object(l.useState)(),gt=Object(o.a)(st,2),bt=gt[0],tr=gt[1],Jt=Object(l.useState)([]),Wt=Object(o.a)(Jt,2),jt=Wt[0],Vt=Wt[1],Zt=Object(l.useState)(!1),Ze=Object(o.a)(Zt,2),vr=Ze[0],Or=Ze[1],nr={onRemove:function(){Vt([])},beforeUpload:function(yt){if(console.log(yt),(yt==null?void 0:yt.size)>1024*1024*500)return r.b.info("\u6587\u4EF6\u8D85\u8FC7500M\uFF0C\u4E0D\u7B26\u5408\u4E0A\u4F20\u8981\u6C42"),!1;var ht=[];return ht.push(yt),Vt([].concat(ht)),!1},fileList:jt};return t.a.createElement(C.a,{title:"\u63D0\u4EA4\u6587\u4EF6",visible:At.actionTabs.key==="md-tab",confirmLoading:vr,onOk:Object(i.a)(s.a.mark(function ft(){var yt,ht,wt;return s.a.wrap(function(ar){for(;;)switch(ar.prev=ar.next){case 0:if(!((jt==null?void 0:jt.length)<=0)){ar.next=3;break}return r.b.info("\u8BF7\u5148\u9009\u62E9\u6587\u4EF6"),ar.abrupt("return");case 3:return Or(!0),ar.next=6,Object(L.c)(jt[0],{login:(yt=pt.userInfo)===null||yt===void 0?void 0:yt.login,container_type:"Competition",container_id:At.actionTabs.params.id,stage_type:At.actionTabs.params.value,file_name:(ht=jt[0])===null||ht===void 0?void 0:ht.name});case 6:wt=ar.sent,(wt==null?void 0:wt.status)===0?(r.b.info("\u63D0\u4EA4\u6210\u529F"),_t({type:"shixunsDetail/setActionTabs",payload:{key:""}}),Or(!1),Vt([]),Xt(At.actionTabs.params.value)):(Or(!1),r.b.info("\u63D0\u4EA4\u5931\u8D25"));case 8:case"end":return ar.stop()}},ft)})),onCancel:function(){Vt([]),_t({type:"shixunsDetail/setActionTabs",payload:{key:""}})}},t.a.createElement(I,nr,t.a.createElement("p",{className:"ant-upload-drag-icon"},t.a.createElement(T.a,null)),t.a.createElement("p",{className:"ant-upload-hint"},"\u62D6\u62FD\u6587\u4EF6\u6216\u8005\u70B9\u51FB\u4E0A\u4F20")))},G=Object(h.a)(function(mt){var qe=mt.user,pt=mt.classroomList,_t=mt.shixunsDetail;return{user:qe,classroomList:pt,shixunsDetail:_t}})(P),W=j("14J3"),H=j("BMrR"),z=j("5NDa"),B=j("5rEg"),k=j("9Bee"),K=j("m3rI"),Y=j("ErOA"),ne=j("NLgs"),oe=j("fV52"),_e=j("3I+P"),xe=j("OaEy"),le=j("2fM7"),me=j("5bA4"),de=j("UESt"),ae=le.a.Option;function ie(mt){var qe=mt.rewarddata,pt=mt.getlistdatas,_t=mt.is_signed,Ut=mt.dispatch,At=mt.userlist,Xt=Object(l.useRef)(null),kt=Object(l.useState)(!1),st=Object(o.a)(kt,2),gt=st[0],bt=st[1],tr=Object(l.useState)(void 0),Jt=Object(o.a)(tr,2),Wt=Jt[0],jt=Jt[1],Vt=Object(l.useState)(""),Zt=Object(o.a)(Vt,2),Ze=Zt[0],vr=Zt[1],Or=Object(l.useState)(void 0),nr=Object(o.a)(Or,2),ft=nr[0],yt=nr[1],ht=Object(l.useState)(void 0),wt=Object(o.a)(ht,2),Kt=wt[0],ar=wt[1],zt=Object(l.useState)(void 0),gr=Object(o.a)(zt,2),Rr=gr[0],lr=gr[1];function Qe(ir){return Pt.apply(this,arguments)}function Pt(){return Pt=Object(i.a)(s.a.mark(function ir(br){var Tr;return s.a.wrap(function(Ht){for(;;)switch(Ht.prev=Ht.next){case 0:if(!br.user_received){Ht.next=3;break}return window.open(br.click_info),Ht.abrupt("return");case 3:if(Object(ne.f)(Ut)){Ht.next=5;break}return Ht.abrupt("return");case 5:if(!(_t===!1)){Ht.next=8;break}return r.b.info("\u60A8\u5C1A\u672A\u62A5\u540D\u53C2\u8D5B\uFF0C\u8BF7\u62A5\u540D\u53C2\u8D5B\u540E\u9886\u53D6"),Ht.abrupt("return");case 8:if(!(br.click_event==="Pop")){Ht.next=14;break}return vr(br.id),bt(!0),Ht.abrupt("return");case 14:jt(void 0);case 15:return Ht.next=17,Ut({type:"competitions/Reward",payload:{competition_module_setting_id:br.id}});case 17:Tr=Ht.sent,Tr&&Tr.status===0&&(pt(),br.click_event==="Link"?(r.b.info("\u9886\u53D6\u6210\u529F"),window.open(br.click_info)):r.b.info(br.click_info));case 19:case"end":return Ht.stop()}},ir)})),Pt.apply(this,arguments)}function Vr(){return Hr.apply(this,arguments)}function Hr(){return Hr=Object(i.a)(s.a.mark(function ir(){var br;return s.a.wrap(function(Ot){for(;;)switch(Ot.prev=Ot.next){case 0:if(!(At&&!At.real_name)){Ot.next=4;break}if(ft){Ot.next=4;break}return r.b.info("\u59D3\u540D\u4E0D\u80FD\u4E3A\u7A7A"),Ot.abrupt("return");case 4:if(!(At&&!At.email)){Ot.next=8;break}if(Kt){Ot.next=8;break}return r.b.info("\u90AE\u7BB1\u4E0D\u80FD\u4E3A\u7A7A"),Ot.abrupt("return");case 8:if(!(At&&!At.phone)){Ot.next=12;break}if(Rr){Ot.next=12;break}return r.b.info("\u624B\u673A\u53F7\u7801\u4E0D\u80FD\u4E3A\u7A7A"),Ot.abrupt("return");case 12:if(Wt){Ot.next=15;break}return r.b.info("\u8BF7\u9009\u62E9\u4F60\u7684\u5E74\u7EA7"),Ot.abrupt("return");case 15:return Ot.next=17,Ut({type:"competitions/Reward",payload:{competition_module_setting_id:Ze,className:Wt,name:ft,mail:Kt,phone:Rr}});case 17:br=Ot.sent,br&&br.status===0&&(bt(!1),pt(),r.b.info("HCIA\u8BA4\u8BC1\u8003\u8BD5\u4EE3\u91D1\u52B5\u5C06\u7531Educoder\u5E73\u53F0\u7EDF\u4E00\u53D1\u653E\uFF0C\u8BF7\u53CA\u65F6\u5173\u6CE8\u90AE\u7BB1\u6216\u7AD9\u5185\u77ED\u4FE1\u67E5\u6536"));case 19:case"end":return Ot.stop()}},ir)})),Hr.apply(this,arguments)}return t.a.createElement("div",null,t.a.createElement(C.a,{visible:gt,title:"\u5B8C\u5584\u4FE1\u606F",onCancel:function(){return bt(!1)},onOk:function(){Vr()}},t.a.createElement("p",null,"\u60A8\u7684\u59D3\u540D\uFF1A",t.a.createElement(B.a,{className:At&&At.real_name?"":O.a.bkfff,style:{width:"300px",marginLeft:"14px",background:At&&At.phone?"":"#ffffff!important"},value:At&&At.real_name||ft,disabled:At&&At.real_name||!1,onChange:function(br){return yt(br.target.value)}})),t.a.createElement("p",{style:{marginTop:"1em"}},"\u60A8\u7684\u90AE\u7BB1\uFF1A",t.a.createElement(B.a,{className:At&&At.email?"":"bkfff",style:{width:"300px",marginLeft:"14px",background:At&&At.phone?"":"#ffffff!important"},value:At&&At.email||Kt,disabled:At&&At.email||!1,onChange:function(br){return ar(br.target.value)}})),t.a.createElement("p",{style:{marginTop:"1em"}},"\u60A8\u7684\u624B\u673A\u53F7\uFF1A",t.a.createElement(B.a,{style:{width:"300px"},className:At&&At.phone?"":"bkfff",value:At&&At.phone||Rr,disabled:At&&At.phone||!1,onChange:function(br){return lr(br.target.value)}})),"\u60A8\u7684\u5E74\u7EA7\uFF1A",t.a.createElement(le.a,{style:{width:"300px",marginTop:"1em",marginLeft:"14px"},onChange:function(br){jt(br)}},t.a.createElement(ae,{value:"\u5927\u4E00"},"\u5927\u4E00"),t.a.createElement(ae,{value:"\u5927\u4E8C"},"\u5927\u4E8C"),t.a.createElement(ae,{value:"\u5927\u4E09"},"\u5927\u4E09"),t.a.createElement(ae,{value:"\u5927\u56DB"},"\u5927\u56DB"),t.a.createElement(ae,{value:"\u5927\u4E94"},"\u5927\u4E94"),t.a.createElement(ae,{value:"\u7855\u4E00"},"\u7855\u4E00"),t.a.createElement(ae,{value:"\u7855\u4E8C"},"\u7855\u4E8C"),t.a.createElement(ae,{value:"\u7855\u4E09"},"\u7855\u4E09"),t.a.createElement(ae,{value:"\u535A\u4E00"},"\u535A\u4E00"),t.a.createElement(ae,{value:"\u535A\u4E8C"},"\u535A\u4E8C"),t.a.createElement(ae,{value:"\u535A\u4E09"},"\u535A\u4E09"),t.a.createElement(ae,{value:"\u535A\u56DB"},"\u535A\u56DB"),t.a.createElement(ae,{value:"\u535A\u4E94"},"\u535A\u4E94")),t.a.createElement("p",{style:{marginTop:"1em"}},"\u63D0\u9192\uFF1A\u5982\u65E0\u534E\u4E3A\u4E91\u8D26\u53F7\uFF0C\u8BF7\u5C3D\u5FEB\u6CE8\u518C\u534E\u4E3A\u4E91\uFF01")),qe&&qe.length>3?t.a.createElement("div",{style:{position:"relative",marginBottom:"10px",marginTop:"10px"}},t.a.createElement("span",{className:O.a.spanprev,onClick:function(){Xt.current.prev()}},t.a.createElement(me.a,{style:{color:"#fff",fontSize:"20px",marginLeft:"15px"}})),t.a.createElement(_e.a,{ref:Xt,className:O.a.divwidth,slidesToShow:3,slidesToScroll:1},qe&&qe.map(function(ir,br){return t.a.createElement("div",{style:{textAlign:"center",position:"relative"}},t.a.createElement("img",{src:K.a.IMG_SERVER+"/".concat(ir.image_url)}),ir.user_received===!1||ir.click_event==="Link"?t.a.createElement("p",{className:O.a.receiveclick,onClick:function(){return Qe(ir)}},"\u70B9\u51FB\u9886\u53D6"):t.a.createElement("p",{className:O.a.receivealready},"\u5DF2\u7ECF\u9886\u53D6"))})),t.a.createElement("span",{className:O.a.spannext,onClick:function(){Xt.current.next()}},t.a.createElement(de.a,{style:{color:"#fff",fontSize:"20px",marginLeft:"5px"}}))):t.a.createElement("div",{className:O.a.divwidth,style:{justifyContent:"space-around",marginBottom:"10px",marginTop:"10px"}},qe&&qe.map(function(ir,br){return t.a.createElement("div",{style:{textAlign:"center",position:"relative"}},t.a.createElement("img",{src:K.a.IMG_SERVER+"/".concat(ir.image_url)}),ir.user_received===!1||ir.click_event==="Link"?t.a.createElement("p",{className:O.a.receiveclick,onClick:function(){return Qe(ir)}},"\u70B9\u51FB\u9886\u53D6"):t.a.createElement("p",{className:O.a.receivealready},"\u5DF2\u7ECF\u9886\u53D6"))})))}var q=ie,ue=function(qe,pt){var _t=qe.StaffDetail,Ut=qe.HeaderDetail,At=qe.ItemData,Xt=qe.setIssee,kt=qe.ModelType,st=qe.dispatch,gt=qe.userinfo,bt=qe.Editable,tr=Object(l.useState)(!1),Jt=Object(o.a)(tr,2),Wt=Jt[0],jt=Jt[1],Vt=Object(l.useState)([]),Zt=Object(o.a)(Vt,2),Ze=Zt[0],vr=Zt[1],Or=Object(l.useState)(""),nr=Object(o.a)(Or,2),ft=nr[0],yt=nr[1],ht=Object(l.useState)(""),wt=Object(o.a)(ht,2),Kt=wt[0],ar=wt[1],zt=Object(l.useState)(!1),gr=Object(o.a)(zt,2),Rr=gr[0],lr=gr[1],Qe=Object(S.i)(),Pt=Qe.identifier,Vr=Object(l.useRef)(null),Hr=Object(l.useRef)(null);Vr.current=_t==null?void 0:_t.enrolled,Object(l.useEffect)(function(){var Ot;return(Ot=Hr.current)===null||Ot===void 0||Ot.addEventListener("click",ir),function(){var Ht;(Ht=Hr.current)===null||Ht===void 0||Ht.removeEventListener("click",ir)}},[]);var ir=function(Ht){var or;if((Ht==null||((or=Ht.target)===null||or===void 0)?void 0:or.id)==="modal-upload"){if(!Object(ne.e)(st))return;if(!Vr.current){C.a.info({title:"\u63D0\u793A",centered:!0,okText:"\u6211\u77E5\u9053\u4E86",content:"\u8BF7\u5148\u62A5\u540D\uFF0C\u518D\u63D0\u4EA4\u4F5C\u54C1"});return}jt(!0)}};Object(l.useEffect)(function(){if(Ut!=null&&Ut.upload_file){var Ot,Ht,or;vr([{name:Ut==null||((Ot=Ut.upload_file)===null||Ot===void 0)?void 0:Ot.title,status:"done",uid:"123456789"}]),ar(Ut==null?void 0:Ut.upload_file_url),yt(Ut==null||((Ht=Ut.upload_file)===null||Ht===void 0||((or=Ht.url)===null||or===void 0))?void 0:or.split("/")[3])}},[Ut==null?void 0:Ut.upload_file]);var br={name:"file",multiple:!1,withCredentials:!0,action:K.a.API_SERVER+"/api/attachments.json",showUploadList:{showRemoveIcon:!1},fileList:Ze,onChange:function(Ht){var or=Ht.file.status,Gt=[Object(N.a)({},Ht.file)];if(vr(Gt),Ht.file.status==="uploading"&&lr(!0),or==="done"){var lt,dt;yt((lt=Gt[0])===null||lt===void 0||((dt=lt.response)===null||dt===void 0)?void 0:dt.id),lr(!1)}or==="error"&&(vr([]),lr(!1))},beforeUpload:function(Ht){var or=Ht.size/1024/1024<1e3;return or?Promise.resolve():(r.b.info("\u6587\u4EF6\u5927\u5C0F\u5FC5\u987B\u5C0F\u4E8E1000MB"),Promise.reject())}},Tr=function(){jt(!0)};return Object(l.useImperativeHandle)(pt,function(){return{handleVisible:Tr}}),t.a.createElement("div",{ref:Hr},kt==="reward"?t.a.createElement(q,{userlist:gt,dispatch:st,rewarddata:At.reward_setting,is_signed:At.is_signed}):null,t.a.createElement("div",{style:{textAlign:"right"}},((gt==null?void 0:gt.admin)||(gt==null?void 0:gt.business)||bt)&&t.a.createElement(w.a,{onClick:function(){return Xt(!1)}},"\u7F16\u8F91")),t.a.createElement(k.a,{value:At.md_content}),At&&At.attachments&&At.attachments.map(function(Ot,Ht){return t.a.createElement("div",null,t.a.createElement("a",{href:(K.a===null||K.a===void 0?void 0:K.a.API_SERVER)+Ot.url,target:"_self",download:Ot.title},t.a.createElement("i",{style:{color:"#29BD8B"},className:"font-14 color-green iconfont icon-fujian mr8"}),t.a.createElement("span",{style:{color:"#000000"}},Ot.title),t.a.createElement("span",{style:{color:"#000000",marginLeft:"10px"}},Ot.filesize)))}),t.a.createElement(C.a,{centered:!0,title:"\u4E0A\u4F20\u4F5C\u54C1",visible:Wt,okText:"\u63D0\u4EA4\u4F5C\u54C1",cancelText:"\u53D6\u6D88",confirmLoading:Rr,onCancel:function(){return jt(!1)},onOk:Object(i.a)(s.a.mark(function Ot(){var Ht;return s.a.wrap(function(Gt){for(;;)switch(Gt.prev=Gt.next){case 0:if(!(!ft&&!Kt)){Gt.next=3;break}return jt(!1),Gt.abrupt("return");case 3:return lr(!0),Gt.next=6,Object(Y.a)("/api/competitions/".concat(Pt,"/upload_file.json"),{method:"post",body:{attachment_id:ft,upload_file_url:Kt}});case 6:Ht=Gt.sent,Ht.status===0&&(jt(!1),lr(!1));case 8:case"end":return Gt.stop()}},Ot)}))},t.a.createElement("div",null,t.a.createElement(H.a,{align:"middle",className:"mb20"},t.a.createElement("span",null,"\u4F5C\u54C1\u94FE\u63A5\uFF1A"),t.a.createElement(B.a,{style:{width:416},value:Kt,onChange:function(Ht){var or;return ar((or=Ht.target)===null||or===void 0?void 0:or.value)}})),t.a.createElement(H.a,{align:"top"},t.a.createElement("span",{style:{lineHeight:"28px"}},"\u4F5C\u54C1\u6587\u4EF6\uFF1A"),t.a.createElement(E.a,br,t.a.createElement(w.a,{type:"primary",className:"mb10"},"\u4E0A\u4F20\u4F5C\u54C1"))))))},Z=Object(l.forwardRef)(ue),ee=j("Ot1p"),Ee=j("hJwl");function te(mt){var qe=mt.ItemData,pt=mt.setIssee,_t=mt.MenuItem,Ut=mt.dispatch,At=mt.identifier,Xt=mt.ModelType,kt=mt.userinfo,st=mt.getrightdatas,gt=Object(l.useState)([]),bt=Object(o.a)(gt,2),tr=bt[0],Jt=bt[1],Wt=Object(l.useState)(qe.md_content),jt=Object(o.a)(Wt,2),Vt=jt[0],Zt=jt[1];Object(l.useEffect)(function(){var yt,ht=[];qe==null||((yt=qe.attachments)===null||yt===void 0)||yt.map(function(wt){var Kt={uid:wt.id,name:wt.title,response:{id:wt.id}};ht.push(Kt)}),Jt(ht)},[qe==null?void 0:qe.attachments]);function Ze(){var yt,ht=[];return qe==null||((yt=qe.attachments)===null||yt===void 0)||yt.map(function(wt){var Kt={uid:wt==null?void 0:wt.id,name:wt.title,response:{id:wt.id}};ht.push(Kt)}),ht}var vr={name:"file",multiple:!0,withCredentials:!0,action:K.a.API_SERVER+"/api/attachments.json",defaultFileList:Ze(),onRemove:function(ht){Object(Ee.t)({id:ht.uid})},onChange:function(ht){var wt=ht.file.status;wt!=="uploading",wt==="removed"&&Jt(ht.fileList),wt==="done"?(Jt(ht.fileList),r.b.success("".concat(ht.file.name," \u6587\u4EF6\u4E0A\u4F20\u6210\u529F"))):wt==="error"&&r.b.error("".concat(ht.file.name," \u6587\u4EF6\u4E0A\u4F20\u5931\u8D25"))},beforeUpload:function(ht){var wt=ht.size/1024/1024<150;return wt||r.b.info("\u6587\u4EF6\u5927\u5C0F\u5FC5\u987B\u5C0F\u4E8E150MB"),wt}};console.log(vr);function Or(){return nr.apply(this,arguments)}function nr(){return nr=Object(i.a)(s.a.mark(function yt(){var ht;return s.a.wrap(function(Kt){for(;;)switch(Kt.prev=Kt.next){case 0:return Kt.next=2,Ut({type:"competitions/updateMdContent",payload:{attachment_ids:ft(tr),competition_module_id:qe.id,md_content_id:qe.md_id,content:Vt,identifier:At}});case 2:ht=Kt.sent,ht&&(r.b.info("\u63D0\u4EA4\u6210\u529F"),pt(!0),st(_t));case 4:case"end":return Kt.stop()}},yt)})),nr.apply(this,arguments)}function ft(yt){var ht=[];return yt&&yt.map(function(wt){ht.push(wt.response.id)}),ht}return t.a.createElement("div",null,Xt==="reward"?t.a.createElement(q,{userlist:kt,dispatch:Ut,rewarddata:qe.reward_setting,is_signed:qe.is_signed}):null,t.a.createElement(ee.a,{defaultValue:Vt,onChange:function(ht){return Zt(ht)}}),t.a.createElement(E.a,vr,t.a.createElement(w.a,{className:"uploadBtn"},"\u4E0A\u4F20\u9644\u4EF6"),"(\u5355\u4E2A\u6587\u4EF6150M\u4EE5\u5185)"),t.a.createElement("p",{style:{marginTop:"10px"}},t.a.createElement(w.a,{style:{width:"90px"},type:"primary",onClick:function(){return Or()}},"\u63D0\u4EA4"),t.a.createElement(w.a,{style:{marginLeft:"30px",width:"90px"},onClick:function(){return pt(!0)}},"\u53D6\u6D88")))}var J=te,X=j("g9YV"),$=j("wCAj"),ge=j("Znn+"),fe=j("ZTPi");function Te(){return t.a.createElement("div",null,t.a.createElement("p",{style:{fontSize:"24px",color:"#05101a"}},"\u603B\u6392\u884C"),t.a.createElement("div",{style:{textAlign:"center"}},t.a.createElement("img",{src:K.a.IMG_SERVER+"/images/educoder/competitions/trophy.png"}),t.a.createElement("p",null,"\u8981\u6293\u4F4F\u4E00\u5207\u673A\u4F1A\uFF0C\u5411\u6240\u6709\u4EBA\u8BC1\u660E\u81EA\u5DF1\uFF0C\u8BC1\u660E\u4F60\u80FD\u591F\u8FCE\u63A5\u8363\u8000")))}var ze=Te,Xe=j("5Dmo"),Ye=j("3S7+"),rt=j("jCWc"),at=j("kPKH"),ot=j("IzEo"),Pe=j("bx4M");function Se(mt){var qe=mt.oneItem,pt=mt.towItem,_t=mt.threeItem;return t.a.createElement("div",{style:{textAlign:"center"}},t.a.createElement(H.a,{gutter:16,style:{justifyContent:"center"}},t.a.createElement(at.a,{span:6,style:{marginTop:"30px",marginRight:"20px"}},t.a.createElement(Pe.a,{title:t.a.createElement("div",{className:O.a.towtop},t.a.createElement("img",{style:{marginTop:"20px"},src:K.a.IMG_SERVER+"/images/educoder/huangguan-two.png"}),t.a.createElement("p",{style:{marginTop:"10px"}},t.a.createElement(x.a,{to:"/users/".concat(pt==null?void 0:pt.user_login,"/classrooms")},t.a.createElement("img",{className:O.a.imgradius,src:K.a.IMG_SERVER+"/images/".concat(pt==null?void 0:pt.user_image)}),(pt==null?void 0:pt.competition_prize)&&t.a.createElement("p",{className:O.a.prize},pt==null?void 0:pt.competition_prize),t.a.createElement("p",{style:{color:"#05101a",fontSize:"16px",marginTop:"10px"}},pt==null?void 0:pt.record_user_name)))),className:O.a.towdiv,bordered:!1},t.a.createElement("p",{style:{fontSize:"14px"}},pt==null?void 0:pt.school_name),t.a.createElement("p",{style:{fontSize:"18px"}},pt==null?void 0:pt.spend_time),t.a.createElement("p",{style:{fontSize:"26px",color:"#a55b29"}},parseFloat(pt==null?void 0:pt.extra_score)+parseFloat(pt==null?void 0:pt.score),"\u5206"))),t.a.createElement(at.a,{span:6},t.a.createElement(Pe.a,{title:t.a.createElement("div",{className:O.a.onetop},t.a.createElement("img",{style:{marginTop:"20px"},src:K.a.IMG_SERVER+"/images/educoder/huangguan.png"}),t.a.createElement("p",{style:{marginTop:"10px"}},t.a.createElement(x.a,{to:"/users/".concat(qe==null?void 0:qe.user_login,"/classrooms")},t.a.createElement("img",{className:O.a.imgradius,src:K.a.IMG_SERVER+"/images/".concat(qe==null?void 0:qe.user_image)}),(qe==null?void 0:qe.competition_prize)&&t.a.createElement("p",{className:O.a.prize},qe==null?void 0:qe.competition_prize),t.a.createElement("p",{style:{color:"#05101a",fontSize:"16px",marginTop:"10px"}},qe==null?void 0:qe.record_user_name)))),className:O.a.onediv,bordered:!1},t.a.createElement("p",{style:{fontSize:"14px"}},qe==null?void 0:qe.school_name),t.a.createElement("p",{style:{fontSize:"18px"}},qe==null?void 0:qe.spend_time),t.a.createElement("p",{style:{fontSize:"26px",color:"#a55b29"}},parseFloat(qe==null?void 0:qe.extra_score)+parseFloat(qe==null?void 0:qe.score),"\u5206"))),t.a.createElement(at.a,{span:6,style:{marginTop:"40px",marginLeft:"20px"}},t.a.createElement(Pe.a,{title:t.a.createElement("div",{className:O.a.threetop},t.a.createElement("img",{style:{marginTop:"20px"},src:K.a.IMG_SERVER+"/images/educoder/huangguan-three.png"}),t.a.createElement("p",{style:{marginTop:"10px"}},t.a.createElement(x.a,{to:"/users/".concat(_t==null?void 0:_t.user_login,"/classrooms")},t.a.createElement("img",{className:O.a.imgradius,src:K.a.IMG_SERVER+"/images/".concat(_t==null?void 0:_t.user_image)}),(_t==null?void 0:_t.competition_prize)&&t.a.createElement("p",{className:O.a.prize},_t==null?void 0:_t.competition_prize),t.a.createElement("p",{style:{color:"#05101a",fontSize:"16px",marginTop:"10px"}},_t==null?void 0:_t.record_user_name)))),className:O.a.threediv,bordered:!1},t.a.createElement("p",{style:{fontSize:"14px"}},_t==null?void 0:_t.school_name),t.a.createElement("p",{style:{fontSize:"18px"}},_t==null?void 0:_t.spend_time),t.a.createElement("p",{style:{fontSize:"26px",color:"#a55b29"}},parseFloat(_t==null?void 0:_t.extra_score)+parseFloat(_t==null?void 0:_t.score),"\u5206")))))}var Je=Se;function nt(mt){var qe,pt,_t,Ut,At,Xt,kt,st,gt,bt,tr,Jt,Wt,jt,Vt,Zt,Ze,vr,Or,nr,ft,yt,ht,wt,Kt,ar,zt,gr,Rr,lr,Qe=mt.ItemData;return t.a.createElement("div",null,t.a.createElement("p",{style:{fontSize:"24px",color:"#05101a"}},"\u603B\u6392\u884C"),t.a.createElement(Je,{oneItem:Qe==null?void 0:Qe.teams[0],towItem:Qe==null?void 0:Qe.teams[1],threeItem:Qe==null?void 0:Qe.teams[2]}),(Qe==null||((qe=Qe.user_ranks)===null||qe===void 0)?void 0:qe.length)>0&&t.a.createElement("div",{className:O.a.myTeam},(Qe==null||((pt=Qe.user_ranks)===null||pt===void 0||((_t=pt[0])===null||_t===void 0))?void 0:_t.success)===!1?t.a.createElement("span",{style:{marginRight:"70px",padding:"10px"}},t.a.createElement("p",{style:{marginBottom:"0px"}}," \u662F\u5426\u664B\u7EA7\uFF1A",t.a.createElement("span",{style:{color:(Qe==null||((Ut=Qe.user_ranks)===null||Ut===void 0||((At=Ut[0])===null||At===void 0))?void 0:At.success)===!1?"red":"green"}},(Qe==null||((Xt=Qe.user_ranks)===null||Xt===void 0||((kt=Xt[0])===null||kt===void 0))?void 0:kt.success)===!1?"\u5426":Qe!=null&&(st=Qe.user_ranks)!==null&&st!==void 0&&(gt=st[0])!==null&&gt!==void 0&&gt.success?"\u662F":"")),(Qe==null||((bt=Qe.user_ranks)===null||bt===void 0||((tr=bt[0])===null||tr===void 0))?void 0:tr.awards)&&t.a.createElement("p",{style:{marginBottom:"0px"}}," \u662F\u5426\u83B7\u5956\uFF1A",t.a.createElement("span",null,(Qe==null||((Jt=Qe.user_ranks)===null||Jt===void 0||((Wt=Jt[0])===null||Wt===void 0))?void 0:Wt.awards)==="percent_20"?"\u4E8C\u7B49\u5956":(Qe==null||((jt=Qe.user_ranks)===null||jt===void 0||((Vt=jt[0])===null||Vt===void 0))?void 0:Vt.awards)==="percent_30"?"\u4E09\u7B49\u5956":"\u6CA1\u6709\u83B7\u5F97\u5956\u9879"))):t.a.createElement("span",{style:{marginRight:"70px"}},"\u6211\u7684\u6392\u540D\uFF1A",Qe==null||((Zt=Qe.user_ranks)===null||Zt===void 0||((Ze=Zt[0])===null||Ze===void 0))?void 0:Ze.rank),t.a.createElement("span",{style:{flex:1}},t.a.createElement(Ye.a,{title:"\u6218\u961F\u540D"},Qe==null||((vr=Qe.user_ranks)===null||vr===void 0||((Or=vr[0])===null||Or===void 0))?void 0:Or.team_name)),t.a.createElement("span",{style:{flex:1}},t.a.createElement(Ye.a,{title:"\u65F6\u95F4"},Qe==null||((nr=Qe.user_ranks)===null||nr===void 0||((ft=nr[0])===null||ft===void 0))?void 0:ft.cost_time)),t.a.createElement("span",{style:{flex:1,textAlign:"center"}},t.a.createElement(Ye.a,{title:"\u8D4B\u80FD\u8D5B\u52A0\u5206"},Qe==null||((yt=Qe.user_ranks)===null||yt===void 0||((ht=yt[0])===null||ht===void 0))?void 0:ht.extra_score)),t.a.createElement("span",{style:{flex:1}},t.a.createElement(Ye.a,{title:"\u6BD4\u8D5B\u6210\u7EE9"},Qe==null||((wt=Qe.user_ranks)===null||wt===void 0||((Kt=wt[0])===null||Kt===void 0))?void 0:Kt.score)),t.a.createElement("span",null,t.a.createElement(Ye.a,{title:"\u603B\u5206"},parseFloat(Qe==null||((ar=Qe.user_ranks)===null||ar===void 0||((zt=ar[0])===null||zt===void 0))?void 0:zt.extra_score)+parseFloat(Qe==null||((gr=Qe.user_ranks)===null||gr===void 0||((Rr=gr[0])===null||Rr===void 0))?void 0:Rr.score)||0))),Qe==null||((lr=Qe.teams)===null||lr===void 0)?void 0:lr.map(function(Pt,Vr){return t.a.createElement("div",{className:O.a.bottomItem},t.a.createElement("span",{style:{color:"#0152d9",marginRight:"20px"}},Vr+1),t.a.createElement(x.a,{to:"/users/".concat(Pt==null?void 0:Pt.user_login,"/classrooms"),style:{marginRight:"80px",position:"relative"}},t.a.createElement("img",{className:O.a.imgradius,src:K.a.IMG_SERVER+"/images/".concat(Pt==null?void 0:Pt.user_image)}),(Pt==null?void 0:Pt.competition_prize)&&t.a.createElement("span",{className:O.a.spanrightradius},Pt==null?void 0:Pt.competition_prize)),t.a.createElement("span",{style:{flex:1}},t.a.createElement(Ye.a,{title:"\u6218\u961F\u540D"},Pt==null?void 0:Pt.team_name)),t.a.createElement("span",{style:{flex:1}},t.a.createElement(Ye.a,{title:"\u5355\u4F4D/\u5B66\u6821\u540D"},Pt.school_name)),t.a.createElement("span",{style:{flex:1,textAlign:"center"}},t.a.createElement(Ye.a,{title:"\u8D4B\u80FD\u8D5B\u52A0\u5206"},Pt.extra_score)),t.a.createElement("span",{style:{flex:1}},t.a.createElement(Ye.a,{title:"\u6BD4\u8D5B\u6210\u7EE9"},Pt.score)),t.a.createElement("span",{style:{color:"#0152d9"}},t.a.createElement(Ye.a,{title:"\u603B\u5206"},parseFloat(Pt.extra_score)+parseFloat(Pt.score))))}))}var We=nt,et=fe.a.TabPane;function Me(mt){var qe,pt,_t,Ut,At,Xt,kt=mt.ChartRules,st=mt.ItemData,gt=mt.getCharts,bt=mt.Selectkey,tr=mt.getChartRules,Jt=mt.userinfo,Wt=mt.Editable,jt=mt.HeaderDetail,Vt=Object(l.useState)(!1),Zt=Object(o.a)(Vt,2),Ze=Zt[0],vr=Zt[1],Or=Object(l.useState)(""),nr=Object(o.a)(Or,2),ft=nr[0],yt=nr[1],ht=Object(l.useState)(!0),wt=Object(o.a)(ht,2),Kt=wt[0],ar=wt[1],zt=Object(l.useState)(),gr=Object(o.a)(zt,2),Rr=gr[0],lr=gr[1],Qe=Object(l.useState)(),Pt=Object(o.a)(Qe,2),Vr=Pt[0],Hr=Pt[1],ir=Object(S.i)(),br=ir.identifier;Object(l.useEffect)(function(){if(Kt){var or,Gt=kt==null||((or=kt.stages)===null||or===void 0)?void 0:or[0];if(lr(Gt),Gt!=null&&Gt.id){var lt,dt,Mt;((jt==null?void 0:jt.task)==="mAP"||(jt==null?void 0:jt.task)==="dog")&&gt(Gt==null?void 0:Gt.id),yt(((lt=kt.rule_contents)===null||lt===void 0||((dt=lt.filter(function(Yr){return parseInt(Yr.competition_stage_id)===parseInt(Gt==null?void 0:Gt.id)}))===null||dt===void 0||((Mt=dt[0])===null||Mt===void 0))?void 0:Mt.content)||"")}else{var Tt,yr,Gr;(jt==null?void 0:jt.task)==="mAP"||(jt==null?void 0:jt.task)==="dog",yt(((Tt=kt.rule_contents)===null||Tt===void 0||((yr=Tt.filter(function(Yr){return parseInt(Yr.competition_stage_id)===0}))===null||yr===void 0||((Gr=yr[0])===null||Gr===void 0))?void 0:Gr.content)||"")}}},[kt]);function Tr(){return Ot.apply(this,arguments)}function Ot(){return Ot=Object(i.a)(s.a.mark(function or(){var Gt,lt,dt,Mt,Tt,yr,Gr,Yr,mr;return s.a.wrap(function(Cr){for(;;)switch(Cr.prev=Cr.next){case 0:if(ft){Cr.next=3;break}return r.b.info("\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A"),Cr.abrupt("return");case 3:if(ar(!1),Gt=Rr==null?void 0:Rr.id,!Gt){Cr.next=12;break}return Cr.next=8,Object(Y.a)("/api/competitions/".concat(br,"/update_md_content.json"),{method:"post",body:{competition_module_id:bt,content:ft,md_content_id:(lt=kt.rule_contents)===null||lt===void 0||((dt=lt.filter(function(tn){return parseInt(tn.competition_stage_id)===parseInt(Gt)}))===null||dt===void 0||((Mt=dt[0])===null||Mt===void 0))?void 0:Mt.id,stage_id:Rr==null?void 0:Rr.id}});case 8:Tt=Cr.sent,Tt.status===0&&(r.b.info("\u66F4\u65B0\u6210\u529F"),vr(!1),tr()),Cr.next=16;break;case 12:return Cr.next=14,Object(Y.a)("/api/competitions/".concat(br,"/update_md_content.json"),{method:"post",body:{competition_module_id:bt,content:ft,md_content_id:(yr=kt.rule_contents)===null||yr===void 0||((Gr=yr.filter(function(tn){return parseInt(tn.competition_stage_id)===0}))===null||Gr===void 0||((Yr=Gr[0])===null||Yr===void 0))?void 0:Yr.id,stage_id:Rr==null?void 0:Rr.id}});case 14:mr=Cr.sent,mr.status===0&&(r.b.info("\u66F4\u65B0\u6210\u529F"),vr(!1),tr());case 16:case"end":return Cr.stop()}},or)})),Ot.apply(this,arguments)}var Ht=[{title:"\u6392\u540D",dataIndex:"name",align:"center",key:"name",render:function(Gt,lt,dt){return t.a.createElement("span",null,dt+1)}},{title:"\u5934\u50CF",dataIndex:"user_image",align:"center",key:"user_image",render:function(Gt){return t.a.createElement("img",{className:O.a.imgradius,src:K.a.IMG_SERVER+"/images/".concat(Gt)})}},{title:"\u6218\u961F\u540D\u79F0",dataIndex:"team_name",key:"team_name",render:function(Gt){return t.a.createElement("span",{title:Gt},Gt&&(Gt==null?void 0:Gt.length)>=15?(Gt==null?void 0:Gt.substr(0,15))+"...":Gt||"--")}},{title:"\u5355\u4F4D",dataIndex:"school_name",key:"school_name",align:"center",render:function(Gt){return t.a.createElement("span",null,Gt||"--")}},{title:(jt==null?void 0:jt.task)==="mAP"?"mAP\u6307\u6807":(jt==null?void 0:jt.task)==="Jittor-3"?"\u603B\u5206":"top1\u6307\u6807",dataIndex:"score",key:"score",render:function(Gt){return t.a.createElement("span",null,Gt||"--")}}];return t.a.createElement("div",null,(kt==null||((qe=kt.stages)===null||qe===void 0)?void 0:qe.length)>0?null:t.a.createElement(ze,null),(kt==null||((pt=kt.stages)===null||pt===void 0)?void 0:pt.length)>0&&t.a.createElement(fe.a,{animated:!0,tabBarExtraContent:((Jt==null?void 0:Jt.admin)||(Jt==null?void 0:Jt.business)||Wt)&&t.a.createElement(w.a,{onClick:function(){vr(!0)}},"\u7F16\u8F91"),onChange:function(Gt){var lt,dt,Mt,Tt,yr;vr(!1);var Gr=kt==null||((lt=kt.stages)===null||lt===void 0)?void 0:lt.filter(function(mr){return parseInt(Gt)===parseInt(mr==null?void 0:mr.id)})[0];lr(Gr);var Yr=Gr==null||((dt=Gr.children)===null||dt===void 0)?void 0:dt[0];Hr(Yr),yt(((Mt=kt.rule_contents)===null||Mt===void 0||((Tt=Mt.filter(function(mr){return parseInt(mr.competition_stage_id)===parseInt(Gr==null?void 0:Gr.id)}))===null||Tt===void 0||((yr=Tt[0])===null||yr===void 0))?void 0:yr.content)||""),gt((Yr==null?void 0:Yr.id)||Gt)}},kt&&kt.stages.map(function(or,Gt){return t.a.createElement(et,{tab:or.name,key:or.id===null?0:or.id},Ze===!1&&kt&&kt.rule_contents.map(function(lt,dt){if(or.id===lt.competition_stage_id)return t.a.createElement(k.a,{key:dt,value:lt.content===void 0||lt.content===null?"":lt.content});if(or.id===null&&lt.competition_stage_id===0)return t.a.createElement(k.a,{key:dt,value:lt.content===void 0||lt.content===null?"":lt.content})}))})),(Rr==null||((_t=Rr.children)===null||_t===void 0)?void 0:_t.length)>0&&t.a.createElement(fe.a,{activeKey:(Vr==null?void 0:Vr.id)+"",onChange:function(Gt){var lt,dt=Rr==null||((lt=Rr.children)===null||lt===void 0)?void 0:lt.filter(function(Mt){return parseInt(Gt)===parseInt(Mt==null?void 0:Mt.id)})[0];Hr(dt),gt(Gt)}},Rr==null||((Ut=Rr.children)===null||Ut===void 0)?void 0:Ut.map(function(or,Gt){return t.a.createElement(et,{tab:or.name,key:or.id===null?0:or.id})})),Ze&&t.a.createElement("div",null,t.a.createElement(ee.a,{defaultValue:ft,onChange:function(Gt){yt(Gt)}}),t.a.createElement("p",{style:{marginTop:"10px"}},t.a.createElement(w.a,{style:{width:"90px"},type:"primary",onClick:function(){return Tr()}},"\u63D0\u4EA4"),t.a.createElement(w.a,{style:{marginLeft:"30px",width:"90px"},onClick:function(){return vr(!1)}},"\u53D6\u6D88"))),(st==null||((At=st.teams)===null||At===void 0)?void 0:At.length)>0&&((jt==null?void 0:jt.task)==="mAP"||(jt==null?void 0:jt.task)==="dog"||(jt==null?void 0:jt.task)==="Jittor-3")?t.a.createElement($.a,{dataSource:st==null?void 0:st.teams,columns:Ht,pagination:!1}):(st==null||((Xt=st.teams)===null||Xt===void 0)?void 0:Xt.length)>0&&t.a.createElement(We,{ItemData:st}))}var Ce=Me,Re=j("/zsF"),pe=j("PArb");function ye(mt){var qe,pt,_t,Ut,At,Xt,kt,st=mt.Prize,gt=Object(S.i)(),bt=Object(l.useState)([{type:1,name:"\u56E2\u4F53\u5956\u8BC1\u4E66"},{type:2,name:"\u4E2A\u4EBA\u5956\u8BC1\u4E66"},{type:3,name:"\u4F18\u79C0\u6307\u5BFC\u6559\u5E08\u8BC1\u4E66"}]),tr=Object(o.a)(bt,2),Jt=tr[0],Wt=tr[1],jt=function(){var Vt=Object(i.a)(s.a.mark(function Zt(Ze){var vr;return s.a.wrap(function(nr){for(;;)switch(nr.prev=nr.next){case 0:return nr.next=2,Object(Ee.u)({type:Ze.type,id:gt.identifier});case 2:vr=nr.sent,(vr==null?void 0:vr.status)===0&&(location.href="/competitions/exports?id=".concat(gt.identifier,"&type=").concat(Ze.type));case 4:case"end":return nr.stop()}},Zt)}));return function(Ze){return Vt.apply(this,arguments)}}();return t.a.createElement("div",null,t.a.createElement("p",{className:O.a.downloadpdf},"\u6E29\u99A8\u63D0\u793A\uFF1A\u586B\u5199\u7684\u4E2A\u4EBA\u4FE1\u606F\u7ECF\u5BA1\u6279\u540E\uFF0C\u5C06\u63D0\u4F9B\u4E2A\u4EBA\u83B7\u5956\u8BC1\u4E66\u4E0B\u8F7D\uFF1B\u56E2\u961F\u961F\u5458\u4FE1\u606F\u5168\u90E8\u5BA1\u6279\u540E\uFF0C\u5C06\u63D0\u4F9B\u56E2\u961F\u83B7\u5956\u8BC1\u4E66\u4E0B\u8F7D\u3002"),t.a.createElement("p",{style:{marginTop:"30px",fontSize:"16px",color:"#000"}},"\u8BC1\u4E66\u60C5\u51B5"),(st==null||((qe=st.personal_certifications)===null||qe===void 0)?void 0:qe.length)>0?t.a.createElement("p",null,t.a.createElement("span",null,"\u4E2A\u4EBA\u8BC1\u4E66\uFF1A"),t.a.createElement("img",{src:K.a.IMG_SERVER+"/images/educoder/pdfs.png"}),t.a.createElement("a",{style:{marginLeft:"5px"},href:K.a.API_SERVER+"".concat(st==null||((pt=st.personal_certifications[0])===null||pt===void 0)?void 0:pt.url)},"\u7ACB\u5373\u4E0B\u8F7D")):t.a.createElement("p",null,t.a.createElement("span",null,"\u4E2A\u4EBA\u8BC1\u4E66\uFF1A")," ",t.a.createElement("span",{style:{color:"#000"}},"\u6682\u672A\u751F\u6210"),t.a.createElement("span",{style:{marginLeft:"20px"}},"\u539F\u56E0\uFF1A")," ",t.a.createElement("span",{style:{color:"#000"}},"\u7EC4\u59D4\u4F1A\u672A\u5B8C\u6210\u8BC1\u4E66\u5BA1\u6279\uFF0C\u8BF7\u7A0D\u540E")),(st==null||((_t=st.team_certifications)===null||_t===void 0)?void 0:_t.length)>0?t.a.createElement("p",null,t.a.createElement("span",null,"\u56E2\u961F\u8BC1\u4E66\uFF1A"),t.a.createElement("img",{src:K.a.IMG_SERVER+"/images/educoder/pdfs.png"}),t.a.createElement("a",{style:{marginLeft:"5px"},href:K.a.API_SERVER+"".concat(st==null||((Ut=st.team_certifications[0])===null||Ut===void 0)?void 0:Ut.url)},"\u7ACB\u5373\u4E0B\u8F7D")):t.a.createElement("p",null,t.a.createElement("span",null,"\u56E2\u961F\u8BC1\u4E66\uFF1A")," ",t.a.createElement("span",{style:{color:"#000"}},"\u6682\u672A\u751F\u6210")),t.a.createElement(pe.a,null),(st==null||((At=st.teams)===null||At===void 0)?void 0:At.length)>0?t.a.createElement("div",null,t.a.createElement("p",null,(st==null?void 0:st.teams)&&(st==null||((Xt=st.teams[0])===null||Xt===void 0)?void 0:Xt.name),"\u6218\u961F\u4FE1\u606F\u586B\u62A5\u6982\u51B5"),t.a.createElement("p",{style:{display:"flex",height:"50px",background:"#f5f5f5",alignItems:"center",justifyContent:"space-around"}},t.a.createElement("span",{style:{width:"5%"}},"\u89D2\u8272"),t.a.createElement("span",{style:{width:"5%"}},"\u59D3\u540D"),t.a.createElement("span",{style:{width:"10%"}},"\u5B9E\u540D\u8BA4\u8BC1"),t.a.createElement("span",{style:{width:"10%"}},"\u804C\u4E1A\u8BA4\u8BC1"),t.a.createElement("span",{style:{width:"10%"}},"\u624B\u673A\u7ED1\u5B9A"),t.a.createElement("span",{style:{width:"10%"}},"\u90AE\u7BB1\u7ED1\u5B9A"),t.a.createElement("span",{style:{width:"50%",textAlign:"center"}},"\u5F00\u6237\u884C\u53CA\u94F6\u884C\u5361\u53F7\u4FE1\u606F\uFF08\u961F\u957F\u586B\u5199\uFF09")),(st==null?void 0:st.teams)&&(st==null||((kt=st.teams[0])===null||kt===void 0)?void 0:kt.team_members.map(function(Vt,Zt){var Ze,vr,Or,nr,ft,yt;return t.a.createElement("p",{className:O.a.teamItem},t.a.createElement("span",{style:{width:"5%"}},Vt==null?void 0:Vt.role),t.a.createElement("span",{style:{width:"5%"}},Vt==null?void 0:Vt.name),t.a.createElement("span",{style:{width:"10%"}},(Vt==null?void 0:Vt.real_name_auth)==="authed"?"\u5DF2\u8BA4\u8BC1":(Vt==null?void 0:Vt.real_name_auth)==="authing"?"\u5F85\u5BA1\u6838":"\u672A\u8BA4\u8BC1"),t.a.createElement("span",{style:{width:"10%"}},(Vt==null?void 0:Vt.professional_auth)==="authed"?"\u5DF2\u8BA4\u8BC1":(Vt==null?void 0:Vt.professional_auth)==="authing"?"\u5F85\u5BA1\u6838":"\u672A\u8BA4\u8BC1"),t.a.createElement("span",{style:{width:"10%"}},Vt!=null&&Vt.phone_binded?"\u5DF2\u7ED1\u5B9A":"\u672A\u7ED1\u5B9A"),t.a.createElement("span",{style:{width:"10%"}},Vt!=null&&Vt.email_binded?"\u5DF2\u7ED1\u5B9A":"\u672A\u7ED1\u5B9A"),(Vt==null?void 0:Vt.role)==="\u961F\u957F"?t.a.createElement("span",{style:{width:"50%",textAlign:"center"}},(st==null?void 0:st.teams)&&(st==null||((Ze=st.teams[0])===null||Ze===void 0||((vr=Ze.bank_account)===null||vr===void 0))?void 0:vr.bank),(st==null?void 0:st.teams)&&(st==null||((Or=st.teams[0])===null||Or===void 0||((nr=Or.bank_account)===null||nr===void 0))?void 0:nr.second_bank),(st==null?void 0:st.teams)&&(st==null||((ft=st.teams[0])===null||ft===void 0||((yt=ft.bank_account)===null||yt===void 0))?void 0:yt.card_no)):t.a.createElement("span",{style:{width:"50%"}}))}))):null,t.a.createElement(H.a,{gutter:[20,20]},Jt.map(function(Vt,Zt){return t.a.createElement(at.a,{key:Zt},t.a.createElement(w.a,{type:"primary",onClick:function(){return jt(Vt)}},Vt.name))})))}var we=ye,Ie=j("0Owb"),ke=j("7Kak"),Ve=j("9yH6"),ut=j("y8nQ"),ct=j("Vl3Y"),Lt=j("1vsH"),Dt=j("Dgm7"),Er=j.n(Dt),rr=j("NnUe"),xt=j.n(rr),kr=E.a.Dragger,Mr=10,Ur=function(qe){var pt=qe.user,_t=qe.account,Ut=qe.globalSetting,At=qe.loading,Xt=qe.dispatch,kt=Object(u.a)(qe,["user","account","globalSetting","loading","dispatch"]),st=ct.a.useForm(),gt=Object(o.a)(st,1),bt=gt[0],tr=Object(l.useState)({}),Jt=Object(o.a)(tr,2),Wt=Jt[0],jt=Jt[1],Vt=Object(l.useState)(!0),Zt=Object(o.a)(Vt,2),Ze=Zt[0],vr=Zt[1],Or=Object(l.useState)(),nr=Object(o.a)(Or,2),ft=nr[0],yt=nr[1],ht=Object(l.useState)(),wt=Object(o.a)(ht,2),Kt=wt[0],ar=wt[1],zt=Object(l.useState)(),gr=Object(o.a)(zt,2),Rr=gr[0],lr=gr[1],Qe=Object(l.useState)(),Pt=Object(o.a)(Qe,2),Vr=Pt[0],Hr=Pt[1];Object(l.useEffect)(function(){if(!_t.basicInfo)return;var Gt=_t.basicInfo,lt={name:Gt.show_realname?Gt.name:Object(Lt.I)(Gt.name),gender:Gt.gender};yt(Gt.name),vr(Gt.show_realname),bt.setFieldsValue(lt),jt(lt)},[_t.basicInfo]);var ir=function(lt){if(lt.file.status==="uploading"){Hr(!0);return}if(lt.file.status==="done"){var dt;console.log(lt.file,lt.file.response),lr((dt=lt.file.response)===null||dt===void 0?void 0:dt.id),Object(Lt.E)(lt.file.originFileObj,function(Mt){ar(Mt),Hr(!1)})}},br=function(lt){jt(Object(N.a)({},bt.getFieldsValue())),"name"in lt&&yt(lt.name)},Tr=function(){var lt=!Ze;vr(lt);var dt=lt?ft:Object(Lt.I)(ft);bt.setFieldsValue({name:dt})},Ot=function(){var Gt=Object(i.a)(s.a.mark(function lt(dt){var Mt,Tt,yr,Gr,Yr,mr,Wr,Cr;return s.a.wrap(function(Lr){for(;;)switch(Lr.prev=Lr.next){case 0:if(yr=dt||{},Gr=yr.name,Yr=yr.gender,mr=yr.idNumber,Kt){Lr.next=4;break}return r.b.info("\u8BF7\u5148\u4E0A\u4F20\u7167\u7247\uFF01"),Lr.abrupt("return");case 4:return Lr.next=6,Xt({type:"account/applyRealNameAuth",payload:{id:((Mt=_t.basicInfo)===null||Mt===void 0?void 0:Mt.id)||((Tt=pt.userInfo)===null||Tt===void 0?void 0:Tt.login),name:Gr,gender:Yr,id_number:mr,show_realname:Ze,attachment_ids:[Rr]}});case 6:Wr=Lr.sent,Ht(),Wr&&(r.b.info("\u7533\u8BF7\u5DF2\u63D0\u4EA4\uFF0C\u8BF7\u7B49\u5F85\u5BA1\u6838!"),Xt({type:"account/getBasicInfo",payload:{login:(Cr=pt.userInfo)===null||Cr===void 0?void 0:Cr.login}}));case 9:case"end":return Lr.stop()}},lt)}));return function(dt){return Gt.apply(this,arguments)}}(),Ht=function(){Xt({type:"account/setActionTabs",payload:{}})},or={data:{type:"real_name"},multiple:!0,showUploadList:!1,action:"".concat(K.a.API_SERVER,"/api/attachments.json"),className:xt.a.uploader,onChange:ir,beforeUpload:function(lt){var dt=lt.type==="image/jpeg"||lt.type==="image/png"||lt.type==="image/jpg"||lt.type==="image/bmp";return dt||r.b.info("\u8BF7\u4E0A\u4F20\u6B63\u786E\u6587\u4EF6\u683C\u5F0F"),dt}};return t.a.createElement(C.a,{centered:!0,keyboard:!1,closable:!1,destroyOnClose:!0,visible:_t.actionTabs.key==="Account-RealNameAuth",title:"\u4FEE\u6539\u5B9E\u540D\u4FE1\u606F",width:"600px",footer:null},t.a.createElement(p.a,{spinning:!!Vr},t.a.createElement(ct.a,{className:xt.a.formWrap,form:bt,layout:"horizontal",onValuesChange:br,onFinish:Ot},t.a.createElement(ct.a.Item,{label:"\u59D3\u540D",name:"name",labelCol:{span:3},wrapperCol:{span:12},rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u771F\u5B9E\u59D3\u540D\uFF0C\u6700\u5927\u9650\u5236".concat(Mr,"\u4E2A\u5B57\u7B26")},{validator:Lt.L}],extra:t.a.createElement("span",null,Ze?"\uFF08\u663E\u793A\uFF1A\u5E73\u53F0\u5C06\u663E\u793A\u60A8\u7684\u771F\u5B9E\u59D3\u540D\uFF09":"\uFF08\u9690\u85CF\uFF1A\u5E73\u53F0\u5C06\u663E\u793A\u4F60\u7684\u6635\u79F0\uFF09")},t.a.createElement(B.a,{disabled:!Ze,placeholder:"\u8BF7\u8F93\u5165\u771F\u5B9E\u59D3\u540D\uFF0C\u6700\u5927\u9650\u5236".concat(Mr,"\u4E2A\u5B57\u7B26"),maxLength:Mr,addonAfter:t.a.createElement("i",{className:"iconfont ".concat(Ze?"icon-xianshi":"icon-yincang"," font18 ").concat(xt.a.color0152d9),onClick:Tr})})),t.a.createElement(ct.a.Item,{label:"\u6027\u522B\uFF1A",name:"gender",labelCol:{span:3},wrapperCol:{span:12},rules:[{required:!0,message:"\u8BF7\u9009\u62E9\u6027\u522B"}]},t.a.createElement(Ve.a.Group,null,t.a.createElement(Ve.a,{value:0},"\u7537"),t.a.createElement(Ve.a,{value:1},"\u5973"))),t.a.createElement(ct.a.Item,{label:"\u8BC1\u4EF6\u53F7\uFF1A",labelCol:{span:3},name:"idNumber",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u8BC1\u4EF6\u53F7"}]},t.a.createElement(B.a,{placeholder:"\u8BF7\u8F93\u5165\u8BC1\u4EF6\u53F7"})),t.a.createElement(ct.a.Item,{label:"\u8EAB\u4EFD\u8BC1\u4E0A\u4F20",labelCol:{span:3}},t.a.createElement("div",{className:xt.a.flexRow},t.a.createElement("div",{className:"".concat(xt.a.flexColumn," ").concat(xt.a.example)},t.a.createElement("span",{className:xt.a.exampleImg},t.a.createElement("img",{src:Er.a})),t.a.createElement("span",{className:"tc"},t.a.createElement("p",null,"\u793A\u4F8B\u56FE\u7247"),t.a.createElement("p",{className:"".concat(xt.a.colorOrange," font12")},"\uFF08png/jpg/bmp\u683C\u5F0F\uFF0C\u4E0D\u8D85\u8FC72MB\uFF09"))),t.a.createElement("div",{className:xt.a.flexColumn},t.a.createElement(kr,Object(Ie.a)({},or,{accept:".png,.jpg,.bmp,.jpeg"}),Kt?t.a.createElement("img",{src:Kt,className:xt.a.uploadImg}):t.a.createElement("div",{className:xt.a.imageTip},t.a.createElement("p",null,t.a.createElement("i",{className:"iconfont icon-cuban2shangchuanyunduan ".concat(xt.a.uploadTipIcon)})),t.a.createElement("p",{className:xt.a.uploadTip},t.a.createElement("a",{className:xt.a.color05101a},"\u70B9\u51FB\u6216\u62D6\u62FD\u4E0A\u4F20\u56FE\u7247")))),t.a.createElement("span",{className:"tc"},t.a.createElement("p",{className:xt.a.viewLargerImg},"\u67E5\u770B\u5927\u56FE"))))),t.a.createElement("div",{className:xt.a.footerWrap},t.a.createElement(ct.a.Item,null,t.a.createElement(w.a,{className:"mr5",size:"large",onClick:Ht},"\u53D6\u6D88"),t.a.createElement(w.a,{size:"large",type:"primary",htmlType:"submit",loading:At["account/applyRealNameAuth"]},"\u4FDD\u5B58"))),t.a.createElement("div",{className:xt.a.note},t.a.createElement("p",null,"\u8BA4\u8BC1\u987B\u77E5\uFF1A"),t.a.createElement("p",null,"1.\u4F60\u9700\u8981\u51C6\u5907\u6709\u6548\u7684\u8EAB\u4EFD\u8BC1\u6B63\u9762\uFF08\u4EBA\u50CF\u9762\uFF09\u7684\u8BC1\u4EF6\u7167\u7167\u7247\uFF0C\u8BF7\u786E\u4FDD\u8BC1\u4EF6\u7167\u7247\u6E05\u6670\u53EF\u89C1\uFF0C\u4E25\u7981PS\uFF1B"),t.a.createElement("p",null,"2.\u6211\u4EEC\u5C06\u5728\u4F60\u63D0\u4EA4\u8BA4\u8BC1\u4FE1\u606F\u540E\u768424\u5C0F\u65F6\uFF08\u4E0D\u5305\u542B\u8282\u5047\u65E5\uFF09\u5185\u5B8C\u6210\u5BA1\u6838\uFF0C\u5BA1\u6838\u7ED3\u679C\u5C06\u4F1A\u4EE5\u7CFB\u7EDF\u6D88\u606F\u7684\u5F62\u5F0F\u53D1\u9001\u7ED9\u4F60\uFF1B"),t.a.createElement("p",null,"3.\u5B9E\u540D\u8BA4\u8BC1\u5BA1\u6838\u5B8C\u6210\u540E\uFF0C\u65E0\u6CD5\u5220\u9664\uFF0C\u8BF7\u8C28\u614E\u586B\u5199\uFF1B"),t.a.createElement("p",null,"4.\u5B9E\u540D\u8BA4\u8BC1\u5BA1\u6838\u5B8C\u6210\u540E\uFF0C\u7CFB\u7EDF\u5C06\u81EA\u52A8\u53D1\u653E500\u4E2A\u91D1\u5E01\u4F5C\u4E3A\u5956\u52B1\uFF1B"),t.a.createElement("p",null,"5.\u6211\u4EEC\u4F1A\u786E\u4FDD\u4F60\u6240\u63D0\u4F9B\u7684\u4FE1\u606F\u5747\u5904\u4E8E\u4E25\u683C\u7684\u4FDD\u5BC6\u72B6\u6001\uFF0C\u4E0D\u4F1A\u6CC4\u9732\uFF1B"),t.a.createElement("p",null,"6.\u5982\u5B58\u5728\u6076\u610F\u4E71\u586B\u5199\u59D3\u540D\uFF0C\u8BC1\u4EF6\u53F7\uFF0C\u53CA\u4E0A\u4F20\u4E0E\u5B9E\u540D\u8BA4\u8BC1\u8BC1\u4EF6\u65E0\u5173\u56FE\u7247\u8005\uFF0C\u4E00\u7ECF\u53D1\u73B0\u5C06\u51BB\u7ED3EduCoder\u8D26\u53F7\u3002"),t.a.createElement("p",null,"7.\u63D0\u4EA4\u5B9E\u540D\u8BA4\u8BC1\u540E\u7CFB\u7EDF\u4F1A\u81EA\u52A8\u5C06\u72B6\u6001\u6539\u4E3A\u5DF2\u8BA4\u8BC1\uFF0C\u4F60\u5C06\u53EF\u4EE5\u4F53\u9A8C\u5E73\u53F0\u9700\u8981\u5B9E\u540D\u8BA4\u8BC1\u7684\u529F\u80FD\uFF1B\u5982\u679C\u5728\u8BA4\u8BC1\u540E\u7684\u4F7F\u7528\u8FC7\u7A0B\u4E2D\u672A\u901A\u8FC7\u5BA1\u6838\uFF0C\u4F60\u5C06\u4E0D\u80FD\u7EE7\u7EED\u4F53\u9A8C\u9700\u8981\u8BA4\u8BC1\u7684\u529F\u80FD\u3002")))))},ln=Object(h.a)(function(mt){var qe=mt.user,pt=mt.account,_t=mt.loading,Ut=mt.globalSetting;return{user:qe,account:pt,globalSetting:Ut,loading:_t.effects}})(Ur),Sr=j("O3gP"),an=j("lrIw"),qr=j("KXlV"),Bt=j.n(qr),ur=j("Sjjz"),jr=j.n(ur),en=B.a.TextArea,Jr=function(qe){var pt=qe.account,_t=qe.globalSetting,Ut=qe.loading,At=qe.dispatch,Xt=qe.schoolName,kt=qe.departmentName,st=qe.visible,gt=qe.onClose,bt=gt===void 0?function(){}:gt,tr=qe.onSuccess,Jt=tr===void 0?function(){}:tr,Wt=Object(u.a)(qe,["account","globalSetting","loading","dispatch","schoolName","departmentName","visible","onClose","onSuccess"]),jt=ct.a.useForm(),Vt=Object(o.a)(jt,1),Zt=Vt[0],Ze=Object(l.useRef)();Object(l.useEffect)(function(){Ze.current=Wt.schoolId},[Wt.schoolId]),Object(l.useEffect)(function(){Zt.setFieldsValue({department:kt})},[kt]);var vr=function(){var Or=Object(i.a)(s.a.mark(function nr(ft){var yt,ht,wt,Kt;return s.a.wrap(function(zt){for(;;)switch(zt.prev=zt.next){case 0:return yt=ft||{},ht=yt.department,wt=yt.remarks,zt.next=3,At({type:"account/appplyDepartment",payload:{school_id:Ze.current,name:ht,remarks:wt}});case 3:Kt=zt.sent,bt(),Kt&&(r.b.success("\u65B0\u589E\u9662\u7CFB/\u90E8\u95E8\u6210\u529F\uFF01"),Jt(ht));case 6:case"end":return zt.stop()}},nr)}));return function(ft){return Or.apply(this,arguments)}}();return t.a.createElement(C.a,{centered:!0,keyboard:!1,closable:!1,destroyOnClose:!0,visible:st,title:"\u7533\u8BF7\u6DFB\u52A0\u5B50\u5355\u4F4D\u540D\u79F0",width:"600px",footer:null},t.a.createElement(ct.a,{className:jr.a.formWrap,form:Zt,labelCol:{span:4},wrapperCol:{span:20},onFinish:vr},t.a.createElement(ct.a.Item,{label:"\u5355\u4F4D\u540D\u79F0\uFF1A"},Xt),t.a.createElement(ct.a.Item,{label:"\u90E8\u95E8\u540D\u79F0\uFF1A",name:"department",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u90E8\u95E8\u6216\u8005\u5B66\u9662\u540D\u79F0"}]},t.a.createElement(B.a,{placeholder:"\u8BF7\u8F93\u5165\u90E8\u95E8\u6216\u8005\u5B66\u9662\u540D\u79F0"})),t.a.createElement(ct.a.Item,{label:"\u8BF4\u660E\uFF1A",name:"remarks"},t.a.createElement(en,{placeholder:"\u518D\u6B21\u8BF4\u660E\u7279\u522B\u60C5\u51B5\uFF08\u9009\u586B\uFF09"})),t.a.createElement("div",{className:jr.a.footerWrap},t.a.createElement(ct.a.Item,null,t.a.createElement(w.a,{className:"mr5",size:"large",onClick:function(){bt()}},"\u53D6\u6D88"),t.a.createElement(w.a,{size:"large",type:"primary",htmlType:"submit",loading:Ut["account/appplyDepartment"]},"\u4FDD\u5B58")))))},_a=Object(h.a)(function(mt){var qe=mt.account,pt=mt.loading,_t=mt.globalSetting;return{account:qe,globalSetting:_t,loading:pt.effects}})(Jr),Wa=j("6UJt"),_n=j("DFOY"),er=j("jO45"),Xn=j("jN4g"),Ea=j("gJ3r"),Pn=j("jwmR"),Qr=j.n(Pn),Ln=function(qe,pt){return pt.some(function(_t){return _t.label.toLowerCase().indexOf(qe.toLowerCase())>-1})},la=B.a.TextArea,fa=function(qe){var pt=qe.account,_t=qe.globalSetting,Ut=qe.loading,At=qe.dispatch,Xt=qe.schoolName,kt=qe.visible,st=qe.onClose,gt=st===void 0?function(){}:st,bt=qe.onSuccess,tr=bt===void 0?function(){}:bt,Jt=Object(u.a)(qe,["account","globalSetting","loading","dispatch","schoolName","visible","onClose","onSuccess"]),Wt=ct.a.useForm(),jt=Object(o.a)(Wt,1),Vt=jt[0];Object(l.useEffect)(function(){Vt.setFieldsValue({name:Xt})},[Xt]);var Zt=function(){var Ze=Object(i.a)(s.a.mark(function vr(Or){var nr,ft,yt,ht,wt,Kt,ar;return s.a.wrap(function(gr){for(;;)switch(gr.prev=gr.next){case 0:return nr=Or||{},ft=nr.name,yt=nr.city,ht=yt===void 0?[]:yt,wt=nr.address,Kt=nr.remarks,gr.next=3,At({type:"account/appplySchool",payload:{name:ft,province:ht[0],city:ht[1],address:wt,remarks:Kt}});case 3:ar=gr.sent,gt(),ar&&(r.b.success("\u65B0\u589E\u5B66\u6821/\u5355\u4F4D\u6210\u529F\uFF01"),tr(ft));case 6:case"end":return gr.stop()}},vr)}));return function(Or){return Ze.apply(this,arguments)}}();return t.a.createElement(C.a,{centered:!0,keyboard:!1,closable:!1,destroyOnClose:!0,visible:kt,title:"\u7533\u8BF7\u6DFB\u52A0\u5355\u4F4D\u540D\u79F0",width:"600px",footer:null},t.a.createElement(ct.a,{className:Qr.a.formWrap,form:Vt,labelCol:{span:4},wrapperCol:{span:20},onFinish:Zt},t.a.createElement(ct.a.Item,{label:"\u5355\u4F4D\u5168\u79F0\uFF1A",name:"name",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5B66\u6821\u6216\u5DE5\u4F5C\u5355\u4F4D"}]},t.a.createElement(B.a,{placeholder:"\u5B66\u6821\u6216\u5DE5\u4F5C\u5355\u4F4D"})),t.a.createElement("div",{className:"".concat(Qr.a.flexRow," ").concat(Qr.a.example)},t.a.createElement("div",null,"\u793A\u4F8B\uFF1A"),t.a.createElement("div",{className:Qr.a.flexColumn},t.a.createElement("div",null,t.a.createElement(er.a,{style:{color:"rgb(82, 196, 26)"}}),t.a.createElement("span",{className:"font14 ml5"},"\u6B63\u786E\u793A\u4F8B\uFF1A\u6570\u636E\u7ED3\u6784")),t.a.createElement("div",null,t.a.createElement(Xn.a,{style:{color:"red"}}),t.a.createElement("span",{className:"font14 ml5"},"\u9519\u8BEF\u793A\u4F8B\uFF1A\u6570\u636E\u7ED3\u67842019\u6625")))),t.a.createElement(ct.a.Item,{label:"\u5730\u533A\uFF1A",name:"city"},t.a.createElement(_n.a,{allowClear:!0,size:"large",options:Ea.a,placeholder:"\u8BF7\u9009\u62E9\u6240\u5728\u5730",showSearch:{matchInputWidth:!0,filter:Ln}})),t.a.createElement(ct.a.Item,{label:"\u8BE6\u7EC6\u5730\u5740\uFF1A",name:"address"},t.a.createElement(B.a,{placeholder:"\u8BF7\u586B\u5199\u5B8C\u6574\u7684\u5730\u5740\u4FE1\u606F"})),t.a.createElement(ct.a.Item,{label:"\u8BF4\u660E\uFF1A",name:"remarks"},t.a.createElement(la,{placeholder:"\u518D\u6B21\u8BF4\u660E\u7279\u522B\u60C5\u51B5\uFF08\u9009\u586B\uFF09"})),t.a.createElement("div",{className:Qr.a.footerWrap},t.a.createElement(ct.a.Item,null,t.a.createElement(w.a,{className:"mr5",size:"large",onClick:function(){gt()}},"\u53D6\u6D88"),t.a.createElement(w.a,{size:"large",type:"primary",htmlType:"submit",loading:Ut["account/appplySchool"]},"\u4FDD\u5B58")))))},It=Object(h.a)(function(mt){var qe=mt.account,pt=mt.loading,_t=mt.globalSetting;return{account:qe,globalSetting:_t,loading:pt.effects}})(fa),dr=le.a.Option,ha=E.a.Dragger,xa=function(qe){var pt,_t,Ut=qe.user,At=qe.account,Xt=qe.globalSetting,kt=qe.loading,st=qe.dispatch,gt=qe.Scoid,bt=Object(u.a)(qe,["user","account","globalSetting","loading","dispatch","Scoid"]),tr=ct.a.useForm(),Jt=Object(o.a)(tr,1),Wt=Jt[0],jt=Object(l.useState)({}),Vt=Object(o.a)(jt,2),Zt=Vt[0],Ze=Vt[1],vr=Object(l.useState)([]),Or=Object(o.a)(vr,2),nr=Or[0],ft=Or[1],yt=Object(l.useState)([]),ht=Object(o.a)(yt,2),wt=ht[0],Kt=ht[1],ar=Object(l.useState)([]),zt=Object(o.a)(ar,2),gr=zt[0],Rr=zt[1],lr=Object(l.useState)([]),Qe=Object(o.a)(lr,2),Pt=Qe[0],Vr=Qe[1],Hr=Object(l.useState)(),ir=Object(o.a)(Hr,2),br=ir[0],Tr=ir[1],Ot=Object(l.useState)(),Ht=Object(o.a)(Ot,2),or=Ht[0],Gt=Ht[1],lt=Object(l.useState)(),dt=Object(o.a)(lt,2),Mt=dt[0],Tt=dt[1],yr=Object(l.useState)(),Gr=Object(o.a)(yr,2),Yr=Gr[0],mr=Gr[1],Wr=Object(l.useState)(),Cr=Object(o.a)(Wr,2),tn=Cr[0],Lr=Cr[1];Object(l.useEffect)(function(){rn()},[]),Object(l.useEffect)(function(){Object(i.a)(s.a.mark(function Be(){var je;return s.a.wrap(function(it){for(;;)switch(it.prev=it.next){case 0:if(gt){it.next=2;break}return it.abrupt("return");case 2:return it.next=4,Nn(gt);case 4:je=it.sent,Rr(je==null?void 0:je.departments);case 6:case"end":return it.stop()}},Be)}))()},[gt]);var rn=function(){var Be=Object(i.a)(s.a.mark(function je(){var Ge;return s.a.wrap(function(Et){for(;;)switch(Et.prev=Et.next){case 0:return Et.next=2,st({type:"account/getSchoolOption"});case 2:Ge=Et.sent,ft(Ge==null?void 0:Ge.schools);case 4:case"end":return Et.stop()}},je)}));return function(){return Be.apply(this,arguments)}}(),Nn=function(je){return st({type:"account/getDepartmentOption",payload:{id:je}})};Object(l.useEffect)(function(){if(!At.basicInfo)return;var Be=At.basicInfo,je={identity:Be.identity,school:Be.school_name,department:Be.department_name,studentNo:Be.student_id,jobTitle:Be.identity=="teacher"?Be.technical_title:"\u6559\u6388",manager:Be.identity=="professional"?Be.technical_title:"\u4F01\u4E1A\u7BA1\u7406\u8005"};Wt.setFieldsValue(je),Ze(je)},[At.basicInfo]);var Ae=function(){mr(!0)},Ue=function(){if(!nr.find(function(je){return je.name===Zt.school})){r.b.info("\u8BF7\u5148\u9009\u62E9\u6B63\u786E\u7684\u5355\u4F4D\u6216\u8005\u5B66\u6821\uFF01");return}Lr(!0)},Ke=function(je){if(Ze(Object(N.a)({},Wt.getFieldsValue())),"school"in je){Kt(nr.filter(function(it){return it.name.includes(je.school)}));var Ge=(nr.find(function(it){return it.name===je.school})||{}).id;Ge?Le(je.school):(Wt.setFieldsValue({department:""}),Ze(Object(N.a)(Object(N.a)({},Zt),{school:je.school,department:""})))}},Le=function(){var Be=Object(i.a)(s.a.mark(function je(Ge,it){var Et,St,Nt,_r,Nr,Pr;return s.a.wrap(function(Ir){for(;;)switch(Ir.prev=Ir.next){case 0:return _r=(Et=nr.find(function(Kr){return Kr.name===Ge}))===null||Et===void 0?void 0:Et.id,Ir.next=3,Nn(_r);case 3:if(Ir.t0=Ir.sent,Ir.t0){Ir.next=6;break}Ir.t0={};case 6:Nr=Ir.t0,Rr(Nr==null?void 0:Nr.departments),Pr=it||(Nr==null||((St=Nr.departments)===null||St===void 0||((Nt=St[0])===null||Nt===void 0))?void 0:Nt.name),Wt.setFieldsValue({department:Pr}),Ze(Object(N.a)(Object(N.a)({},Zt),{school:Ge,department:Pr}));case 11:case"end":return Ir.stop()}},je)}));return function(Ge,it){return Be.apply(this,arguments)}}(),he=function(){var Be=Object(i.a)(s.a.mark(function je(Ge){return s.a.wrap(function(Et){for(;;)switch(Et.prev=Et.next){case 0:return Et.next=2,rn();case 2:Wt.setFieldsValue({school:Ge,department:""}),Ze(Object(N.a)(Object(N.a)({},Zt),{school:Ge,department:""}));case 4:case"end":return Et.stop()}},je)}));return function(Ge){return Be.apply(this,arguments)}}(),Oe=function(je){if(je.file.status==="uploading"){Tt(!0);return}if(je.file.status==="done"){var Ge;console.log(je.file,je.file.response),Gt((Ge=je.file.response)===null||Ge===void 0?void 0:Ge.id),Object(Lt.E)(je.file.originFileObj,function(it){Tr(it),Tt(!1)})}},be=function(){var Be=Object(i.a)(s.a.mark(function je(Ge){var it,Et,St,Nt,_r,Nr,Pr,Br,Ir,Kr,zr,on,$r,gn,Zr,wr;return s.a.wrap(function(Xr){for(;;)switch(Xr.prev=Xr.next){case 0:if(_r=Ge||{},Nr=_r.school,Pr=_r.department,Br=_r.identity,Ir=_r.studentNo,Kr=_r.jobTitle,zr=_r.manager,br){Xr.next=4;break}return r.b.info("\u8BF7\u5148\u4E0A\u4F20\u7167\u7247\uFF01"),Xr.abrupt("return");case 4:return on=(it=nr.find(function(nn){return nn.name===Nr}))===null||it===void 0?void 0:it.id,$r=(Et=gr.find(function(nn){return nn.name===Pr}))===null||Et===void 0?void 0:Et.id,Br==="student"?gn=Ir:Br==="teacher"?gn=Kr:gn=zr,Xr.next=9,st({type:"account/applyProfessionalAuth",payload:{id:((St=At.basicInfo)===null||St===void 0?void 0:St.id)||((Nt=Ut.userInfo)===null||Nt===void 0?void 0:Nt.login),school_id:on,department_id:$r,identity:Br,extra:gn,attachment_ids:[or]}});case 9:Zr=Xr.sent,De(),Zr&&(r.b.info("\u7533\u8BF7\u5DF2\u63D0\u4EA4\uFF0C\u8BF7\u7B49\u5F85\u5BA1\u6838!"),st({type:"account/getBasicInfo",payload:{login:(wr=Ut.userInfo)===null||wr===void 0?void 0:wr.login}}));case 12:case"end":return Xr.stop()}},je)}));return function(Ge){return Be.apply(this,arguments)}}(),De=function(){st({type:"account/setActionTabs",payload:{}})},Fe={data:{type:"professional"},multiple:!0,showUploadList:!1,action:"".concat(K.a.API_SERVER,"/api/attachments.json"),className:xt.a.uploader,onChange:Oe,beforeUpload:function(je){var Ge=je.type==="image/jpeg"||je.type==="image/png"||je.type==="image/jpg"||je.type==="image/bmp";return Ge||r.b.info("\u8BF7\u4E0A\u4F20\u6B63\u786E\u6587\u4EF6\u683C\u5F0F"),Ge}};return t.a.createElement(C.a,{centered:!0,keyboard:!1,closable:!1,destroyOnClose:!0,className:xt.a.modal,visible:At.actionTabs.key==="Account-ProfessionalAuth",title:t.a.createElement("div",null,t.a.createElement("i",{className:"iconfont icon-zhiyerenzheng font18 mr5 ".concat(xt.a.colorBlue)}),"\u804C\u4E1A\u8BA4\u8BC1"),width:"660px",footer:null},t.a.createElement(p.a,{spinning:!!Mt},t.a.createElement(ct.a,{className:xt.a.formWrap,form:Wt,layout:"horizontal",onValuesChange:Ke,onFinish:be},t.a.createElement(H.a,{gutter:[10,0]},t.a.createElement(at.a,{flex:"300px"},t.a.createElement(ct.a.Item,{label:"\u804C\u4E1A",name:"identity",rules:[{required:!0,message:"\u8BF7\u5148\u9009\u62E9\u804C\u4E1A"}]},t.a.createElement(le.a,null,t.a.createElement(dr,{value:"teacher"},"\u6559\u5E08"),t.a.createElement(dr,{value:"student"},"\u5B66\u751F"),t.a.createElement(dr,{value:"professional"},"\u4E13\u4E1A\u4EBA\u58EB")))),Zt.identity==="student"&&t.a.createElement(at.a,{flex:"200px"},t.a.createElement(ct.a.Item,{initialValue:Zt.studentNo,name:"studentNo",rules:[{required:!0,message:"\u8BF7\u5148\u8F93\u5165\u5B66\u53F7"}]},t.a.createElement(B.a,{type:"text",placeholder:"\u8BF7\u8F93\u5165\u5B66\u53F7"}))),Zt.identity==="teacher"&&t.a.createElement(at.a,{flex:"200px"},t.a.createElement(ct.a.Item,{initialValue:Zt.jobTitle,name:"jobTitle",rules:[{required:!0,message:"\u8BF7\u5148\u9009\u62E9\u804C\u79F0"}]},t.a.createElement(le.a,null,t.a.createElement(dr,{value:"\u6559\u6388"},"\u6559\u6388"),t.a.createElement(dr,{value:"\u526F\u6559\u6388"},"\u526F\u6559\u6388"),t.a.createElement(dr,{value:"\u8BB2\u5E08"},"\u8BB2\u5E08"),t.a.createElement(dr,{value:"\u52A9\u6559"},"\u52A9\u6559")))),Zt.identity==="professional"&&t.a.createElement(at.a,{flex:"200px"},t.a.createElement(ct.a.Item,{initialValue:Zt.manager,name:"manager",rules:[{required:!0,message:"\u8BF7\u5148\u9009\u62E9\u804C\u79F0"}]},t.a.createElement(le.a,null,t.a.createElement(dr,{value:"\u4F01\u4E1A\u7BA1\u7406\u8005"},"\u4F01\u4E1A\u7BA1\u7406\u8005"),t.a.createElement(dr,{value:"\u90E8\u95E8\u7BA1\u7406\u8005"},"\u90E8\u95E8\u7BA1\u7406\u8005"),t.a.createElement(dr,{value:"\u9AD8\u7EA7\u5DE5\u7A0B\u5E08"},"\u9AD8\u7EA7\u5DE5\u7A0B\u5E08"),t.a.createElement(dr,{value:"\u5DE5\u7A0B\u5E08"},"\u5DE5\u7A0B\u5E08"),t.a.createElement(dr,{value:"\u52A9\u7406\u5DE5\u7A0B\u5E08"},"\u52A9\u7406\u5DE5\u7A0B\u5E08"))))),t.a.createElement(ct.a.Item,{label:"\u5B66\u6821/\u5355\u4F4D",name:"school",extra:Zt.school&&!(nr!=null&&nr.find(function(Be){return Be.name===Zt.school}))&&t.a.createElement("div",{className:xt.a.schoolHintWrap},t.a.createElement("span",{className:xt.a.colorCDCDCD},"\u672A\u627E\u5230\u5305\u542B\u201C",Zt.school,"\u201D\u7684\u9AD8\u6821\uFF0C"),t.a.createElement("span",{className:"".concat(xt.a.color0152d9," current"),onClick:Ae},"\u7533\u8BF7\u65B0\u589E")),rules:[{required:!0,message:"\u8BF7\u5148\u9009\u62E9\u5B66\u6821/\u5355\u4F4D"}]},t.a.createElement(an.a,{showSearch:!0,options:wt==null?void 0:wt.map(function(Be){return{value:Be.name}})})),t.a.createElement(ct.a.Item,{label:"\u9662\u7CFB/\u90E8\u95E8",name:"department",extra:Zt.department&&!(gr!=null&&gr.find(function(Be){return Be.name===Zt.department}))&&t.a.createElement("div",{className:xt.a.schoolHintWrap},t.a.createElement("span",{className:xt.a.colorCDCDCD},Zt.department?"\u672A\u627E\u5230\u5305\u542B\u201C".concat(Zt.department,"\u201D\u7684\u9AD8\u6821\uFF0C"):"\u672A\u627E\u5230\u9662\u7CFB\uFF0C"),t.a.createElement("span",{className:"".concat(xt.a.color0152d9," current"),onClick:Ue},"\u7533\u8BF7\u65B0\u589E")),rules:[{required:!0,message:"\u8BF7\u5148\u9009\u62E9\u9662\u7CFB/\u90E8\u95E8"}]},t.a.createElement(an.a,{showSearch:!0,onChange:function(je){return Vr(gr.filter(function(Ge){return Ge.name.includes(je)}))},options:Pt==null?void 0:Pt.map(function(Be){return{value:Be.name}})})),t.a.createElement(ct.a.Item,{label:"\u804C\u4E1A\u8BC1\u4E0A\u4F20"},t.a.createElement("div",{className:xt.a.flexRow},t.a.createElement("div",{className:"".concat(xt.a.flexColumn," ").concat(xt.a.example)},t.a.createElement("span",{className:xt.a.exampleImg},t.a.createElement("img",{src:Bt.a})),t.a.createElement("span",{className:"tc"},t.a.createElement("p",null,"\u793A\u4F8B\u56FE\u7247"),t.a.createElement("p",{className:"".concat(xt.a.colorOrange," font12")},"\uFF08png/jpg/bmp\u683C\u5F0F\uFF0C\u4E0D\u8D85\u8FC72MB\uFF09"))),t.a.createElement("div",{className:xt.a.flexColumn},t.a.createElement(ha,Object(Ie.a)({},Fe,{accept:".png,.jpg,.bmp,.jpeg"}),br?t.a.createElement("img",{src:br,className:xt.a.uploadImg}):t.a.createElement("div",{className:xt.a.imageTip},t.a.createElement("p",null,t.a.createElement("i",{className:"iconfont icon-cuban2shangchuanyunduan ".concat(xt.a.uploadTipIcon)})),t.a.createElement("p",{className:xt.a.uploadTip},t.a.createElement("a",{className:xt.a.color05101a},"\u70B9\u51FB\u6216\u62D6\u62FD\u4E0A\u4F20\u56FE\u7247")))),t.a.createElement("span",{className:"tc"},t.a.createElement("p",{className:xt.a.viewLargerImg},"\u67E5\u770B\u5927\u56FE"))))),t.a.createElement("div",{className:xt.a.footerWrap},t.a.createElement(ct.a.Item,null,t.a.createElement(w.a,{className:"mr5",size:"large",onClick:De},"\u53D6\u6D88"),t.a.createElement(w.a,{size:"large",type:"primary",htmlType:"submit",loading:kt["account/applyProfessionalAuth"]},"\u4FDD\u5B58"))),t.a.createElement("div",{className:xt.a.note},t.a.createElement("p",null,"\u8BA4\u8BC1\u987B\u77E5\uFF1A"),t.a.createElement("p",null,"1.\u6839\u636E\u804C\u4E1A\u4E0A\u4F20\u76F8\u5E94\u7684\u8BC1\u4EF6\u7167\uFF1A\u6559\u5E08\uFF08\u6559\u5E08\u8BC1\uFF09\uFF0C\u4E13\u4E1A\u4EBA\u58EB\uFF08\u5458\u5DE5\u8BC1\uFF09\u3001\u5B66\u751F\uFF08\u5B66\u751F\u8BC1\uFF09\uFF0C\u8BF7\u786E\u4FDD\u8BC1\u4EF6\u7167\u5185\u5BB9\u5B8C\u6574\u5E76\u4E14\u6E05\u6670\u53EF\u89C1\uFF0C\u4E25\u7981PS\uFF1B"),t.a.createElement("p",null,"2.\u6211\u4EEC\u5C06\u5728\u4F60\u63D0\u4EA4\u804C\u4E1A\u8BC1\u4FE1\u606F\u540E\u768424\u5C0F\u65F6\uFF08\u4E0D\u5305\u542B\u8282\u5047\u65E5\uFF09\u5185\u5B8C\u6210\u5BA1\u6838\uFF0C\u5BA1\u6838\u7ED3\u679C\u5C06\u4F1A\u4EE5\u7CFB\u7EDF\u6D88\u606F\u7684\u5F62\u5F0F\u53D1\u9001\u7ED9\u4F60\uFF1B"),t.a.createElement("p",null,"3.\u804C\u4E1A\u8BA4\u8BC1\u5BA1\u6838\u5B8C\u6210\u540E\uFF0C\u65E0\u6CD5\u5220\u9664\uFF0C\u8BF7\u8C28\u614E\u586B\u5199\uFF1B\u804C\u4E1A\u53D8\u66F4\u8BF7\u9009\u62E9\u91CD\u65B0\u8BA4\u8BC1\uFF1B"),t.a.createElement("p",null,"4.\u804C\u4E1A\u8BA4\u8BC1\u5BA1\u6838\u5B8C\u6210\u540E\uFF0C\u7CFB\u7EDF\u5C06\u81EA\u52A8\u53D1\u653E500\u4E2A\u91D1\u5E01\u4F5C\u4E3A\u5956\u52B1\uFF1B"),t.a.createElement("p",null,"5.\u6211\u4EEC\u4F1A\u786E\u4FDD\u4F60\u6240\u63D0\u4F9B\u7684\u4FE1\u606F\u5747\u5904\u4E8E\u4E25\u683C\u7684\u4FDD\u5BC6\u72B6\u6001\uFF0C\u4E0D\u4F1A\u6CC4\u9732\uFF1B"),t.a.createElement("p",null,"6.\u5982\u5B58\u5728\u6076\u610F\u4E71\u586B\u5199\u59D3\u540D\uFF0C\u5B66\u53F7\uFF0C\u53CA\u4E0A\u4F20\u4E0E\u804C\u4E1A\u8BC1\u4EF6\u65E0\u5173\u56FE\u7247\u8005\uFF0C\u4E00\u7ECF\u53D1\u73B0\u5C06\u51BB\u7ED3",!(Xt!=null&&(pt=Xt.setting)!==null&&pt!==void 0&&pt.is_local)&&"EduCoder","\u8D26\u53F7\u3002"),t.a.createElement("p",null,"7.\u975E\u8001\u5E08\u8EAB\u4EFD\u63D0\u4EA4\u804C\u4E1A\u8BA4\u8BC1\u540E\u7CFB\u7EDF\u4F1A\u81EA\u52A8\u5C06\u72B6\u6001\u6539\u4E3A\u5DF2\u8BA4\u8BC1\uFF0C\u4F60\u5C06\u53EF\u4EE5\u4F53\u9A8C\u5E73\u53F0\u9700\u8981\u804C\u4E1A\u8BA4\u8BC1\u7684\u529F\u80FD\uFF1B\u5982\u679C\u5728\u8BA4\u8BC1\u540E\u7684\u4F7F\u7528\u8FC7\u7A0B\u4E2D\u672A\u901A\u8FC7\u5BA1\u6838\uFF0C\u4F60\u5C06\u4E0D\u80FD\u7EE7\u7EED\u4F53\u9A8C\u9700\u8981\u8BA4\u8BC1\u7684\u529F\u80FD\u3002")))),t.a.createElement(It,{visible:Yr,onClose:function(){return mr(!1)},schoolName:Zt.school,onSuccess:he}),t.a.createElement(_a,{visible:tn,onClose:function(){return Lr(!1)},schoolId:(_t=nr.find(function(Be){return Be.name===Zt.school}))===null||_t===void 0?void 0:_t.id,schoolName:Zt.school,departmentName:Zt.department,onSuccess:function(je){return Le(Zt.school,je)}}))},Pa=Object(h.a)(function(mt){var qe=mt.user,pt=mt.account,_t=mt.loading,Ut=mt.globalSetting;return{user:qe,account:pt,globalSetting:Ut,loading:_t.effects}})(xa),pa=j("aCH8"),kn=j.n(pa);function xr(mt){var qe=mt.type,pt=mt.dispatch,_t=mt.userid,Ut=mt.isshow,At=mt.setPhoneshow,Xt=mt.setEmailshow,kt="79e33abd4b6588941ab7622aed1e67e8",st=Object(l.useState)(""),gt=Object(o.a)(st,2),bt=gt[0],tr=gt[1],Jt=Object(l.useState)("\u83B7\u53D6\u9A8C\u8BC1\u7801"),Wt=Object(o.a)(Jt,2),jt=Wt[0],Vt=Wt[1],Zt=Object(l.useState)(60),Ze=Object(o.a)(Zt,2),vr=Ze[0],Or=Ze[1],nr=Object(l.useState)(!1),ft=Object(o.a)(nr,2),yt=ft[0],ht=ft[1],wt=Object(l.useState)(""),Kt=Object(o.a)(wt,2),ar=Kt[0],zt=Kt[1];function gr(){return Rr.apply(this,arguments)}function Rr(){return Rr=Object(i.a)(s.a.mark(function ir(){var br;return s.a.wrap(function(Ot){for(;;)switch(Ot.prev=Ot.next){case 0:if(bt){Ot.next=3;break}return qe===3?r.b.info("\u624B\u673A\u53F7\u4E0D\u80FD\u4E3A\u7A7A"):r.b.info("\u90AE\u7BB1\u5730\u5740\u4E0D\u80FD\u4E3A\u7A7A"),Ot.abrupt("return");case 3:return Ot.next=5,pt({type:"competitions/getVerification",payload:{type:qe,login:bt,smscode:kn()(kt+bt)}});case 5:br=Ot.sent,br.status===1&&(r.b.info("\u83B7\u53D6\u9A8C\u8BC1\u7801\u6210\u529F"),lr(),ht(!0));case 7:case"end":return Ot.stop()}},ir)})),Rr.apply(this,arguments)}function lr(){Or(60);var ir=setInterval(function(){--vr,vr>-1?Or(vr):(clearInterval(ir),ht(!1))},1e3)}function Qe(){return Pt.apply(this,arguments)}function Pt(){return Pt=Object(i.a)(s.a.mark(function ir(){var br;return s.a.wrap(function(Ot){for(;;)switch(Ot.prev=Ot.next){case 0:return Ot.next=2,pt({type:"competitions/PhoneBind",payload:{userid:_t,code:ar,phone:bt}});case 2:br=Ot.sent,br.status===0&&(r.b.info("\u7ED1\u5B9A\u6210\u529F"),At("none"));case 4:case"end":return Ot.stop()}},ir)})),Pt.apply(this,arguments)}function Vr(){return Hr.apply(this,arguments)}function Hr(){return Hr=Object(i.a)(s.a.mark(function ir(){var br;return s.a.wrap(function(Ot){for(;;)switch(Ot.prev=Ot.next){case 0:return Ot.next=2,pt({type:"competitions/EmailBind",payload:{userid:_t,code:ar,email:bt}});case 2:br=Ot.sent,br.status===0&&(r.b.info("\u7ED1\u5B9A\u6210\u529F"),Xt("none"));case 4:case"end":return Ot.stop()}},ir)})),Hr.apply(this,arguments)}return t.a.createElement("div",{style:{display:Ut}},t.a.createElement("p",null,t.a.createElement(B.a,{value:bt,onChange:function(br){return tr(br.target.value)},placeholder:qe===3?"\u8BF7\u8F93\u5165\u624B\u673A\u53F7":"\u8BF7\u8F93\u5165\u90AE\u7BB1\u5730\u5740",style:{width:"370px"}})),t.a.createElement("span",null,t.a.createElement(B.a,{value:ar,onChange:function(br){return zt(br.target.value)},placeholder:qe===3?"\u8BF7\u8F93\u5165\u624B\u673A\u83B7\u53D6\u7684\u9A8C\u8BC1\u7801":"\u8BF7\u8F93\u5165\u90AE\u7BB1\u83B7\u53D6\u7684\u9A8C\u8BC1\u7801",style:{width:"250px"}}))," ",t.a.createElement(w.a,{disabled:yt,onClick:function(){return gr()},type:"primary",style:{marginLeft:"20px",width:"100px"}},yt?"\u91CD\u65B0\u53D1\u9001".concat(vr,"s"):jt),t.a.createElement("p",{style:{marginTop:"30px",width:"370px",textAlign:"center"}},t.a.createElement(w.a,{type:"primary",style:{marginRight:"15px"},onClick:function(){if(!ar){r.b.info("\u9A8C\u8BC1\u7801\u4E0D\u80FD\u4E3A\u7A7A");return}qe===3?Qe():Vr()}},"\u786E\u8BA4"),t.a.createElement(w.a,{style:{marginLeft:"20px"},onClick:function(){qe===3?At("none"):Xt("none")}},"\u53D6\u6D88")))}var ta=xr;function Ct(mt){var qe=mt.dispatch,pt=mt.userid,_t={wrapperCol:{offset:3,span:21}},Ut=ct.a.useForm(),At=Object(o.a)(Ut,1),Xt=At[0],kt=Object(S.i)(),st=kt.identifier;return t.a.createElement("div",{style:{width:"500px"}},t.a.createElement(ct.a,{form:Xt,name:"basic"},t.a.createElement(ct.a.Item,Object(Ie.a)({},_t,{label:t.a.createElement("div",{style:{width:"30px"}},"\u5F00\u6237\u884C"),name:"bank",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5F00\u6237\u884C"}]}),t.a.createElement(B.a,null)),t.a.createElement(ct.a.Item,Object(Ie.a)({},_t,{label:t.a.createElement("div",{style:{width:"30px"}},"\u652F\u884C"),name:"second_bank",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u652F\u884C"}]}),t.a.createElement(B.a,null)),t.a.createElement(ct.a.Item,Object(Ie.a)({},_t,{label:t.a.createElement("div",{style:{width:"30px"}},"\u8D26\u53F7"),name:"card_no",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u8D26\u53F7"}]}),t.a.createElement(B.a,null)),t.a.createElement(ct.a.Item,null,t.a.createElement(w.a,{type:"primary",htmlType:"submit",onClick:Object(i.a)(s.a.mark(function gt(){return s.a.wrap(function(tr){for(;;)switch(tr.prev=tr.next){case 0:Xt.validateFields().then(function(){var Jt=Object(i.a)(s.a.mark(function Wt(jt){var Vt;return s.a.wrap(function(Ze){for(;;)switch(Ze.prev=Ze.next){case 0:return Ze.next=2,qe({type:"competitions/setleader",payload:Object(N.a)({identifier:st,user_id:pt},jt)});case 2:Vt=Ze.sent,Vt.status===0&&r.b.info("\u63D0\u4EA4\u6210\u529F");case 4:case"end":return Ze.stop()}},Wt)}));return function(Wt){return Jt.apply(this,arguments)}}());case 1:case"end":return tr.stop()}},gt)}))},"\u63D0\u4EA4"))))}var Vn=Ct,Mn={teacher:"\u6559\u5E08",student:"\u5B66\u751F",professional:"\u4E13\u4E1A\u4EBA\u58EB"};function Ka(mt){var qe,pt,_t,Ut,At,Xt,kt,st,gt=mt.Prize,bt=mt.Accounts,tr=mt.dispatch,Jt=mt.userid,Wt=Object(l.useState)("none"),jt=Object(o.a)(Wt,2),Vt=jt[0],Zt=jt[1],Ze=Object(l.useState)("none"),vr=Object(o.a)(Ze,2),Or=vr[0],nr=vr[1];function ft(ht){return yt.apply(this,arguments)}function yt(){return yt=Object(i.a)(s.a.mark(function ht(wt){var Kt;return s.a.wrap(function(zt){for(;;)switch(zt.prev=zt.next){case 0:if(!(wt==="1")){zt.next=6;break}return zt.next=3,tr({type:"competitions/Authentication"});case 3:Kt=zt.sent,zt.next=9;break;case 6:return zt.next=8,tr({type:"competitions/Professional"});case 8:Kt=zt.sent;case 9:Kt.status===0&&r.b.info("\u64A4\u9500\u6210\u529F");case 10:case"end":return zt.stop()}},ht)})),yt.apply(this,arguments)}return t.a.createElement("div",null,t.a.createElement("p",null,t.a.createElement("span",{style:{color:"red"}},"*"),t.a.createElement("span",{style:{fontSize:"16px"}},"\u5B9E\u540D\u4FE1\u606F"),(bt==null?void 0:bt.authentication)==="uncertified"?t.a.createElement("span",{style:{fontSize:"14px",marginLeft:"20px"}},"\u901A\u8FC7\u5B9E\u540D\u8BA4\u8BC1\u540E\u624D\u80FD\u83B7\u5F97\u8BC1\u4E66"):null,(bt==null?void 0:bt.authentication)==="uncertified"?t.a.createElement("span",{style:{fontSize:"14px",marginLeft:"20px",color:"#0152d9",cursor:"pointer"},onClick:function(){tr({type:"account/setActionTabs",payload:{key:"Account-RealNameAuth"}})}},"\u7ACB\u5373\u8BA4\u8BC1"):null),t.a.createElement("div",{style:{padding:"20px"}},t.a.createElement("p",null,"\u59D3\u540D\uFF1A",t.a.createElement("span",null,bt==null?void 0:bt.name),(bt==null?void 0:bt.authentication)==="uncertified"?null:(bt==null?void 0:bt.authentication)==="applying"?t.a.createElement("span",null,t.a.createElement("span",null,"\u5F85\u5BA1\u6838"),t.a.createElement(w.a,{type:"primary",onClick:function(){return ft("1")},ghost:!0,style:{marginLeft:"20px"}},"\u64A4\u9500\u8BA4\u8BC1")):t.a.createElement("span",{style:{color:"#6ec76e"}},t.a.createElement("span",{className:"iconfont icon-wancheng font-14 ml20"})," \u5DF2\u8BA4\u8BC1")),t.a.createElement("p",null,"\u6027\u522B\uFF1A",t.a.createElement("span",null,(bt==null?void 0:bt.gender)===0?"\u7537":"\u5973"))),t.a.createElement("p",null,t.a.createElement("span",{style:{color:"red"}},"*"),t.a.createElement("span",{style:{fontSize:"16px"}},"\u804C\u4E1A\u4FE1\u606F"),(bt==null?void 0:bt.authentication)==="uncertified"?t.a.createElement("span",{style:{fontSize:"14px",marginLeft:"20px"}},"\u901A\u8FC7\u5B9E\u540D\u8BA4\u8BC1\u540E\u624D\u80FD\u83B7\u5F97\u8BC1\u4E66"):null,(bt==null?void 0:bt.authentication)==="uncertified"?t.a.createElement("span",{style:{fontSize:"14px",marginLeft:"20px",color:"#0152d9"},onClick:function(){tr({type:"account/setActionTabs",payload:{key:"Account-ProfessionalAuth"}})}},"\u7ACB\u5373\u8BA4\u8BC1"):null),t.a.createElement("div",{style:{padding:"20px"}},t.a.createElement("p",null,"\u804C\u4E1A\uFF1A",t.a.createElement("span",null,bt&&bt.identity&&Mn[bt.identity]),(bt==null?void 0:bt.authentication)==="uncertified"?null:(bt==null?void 0:bt.authentication)==="applying"?t.a.createElement("span",null,t.a.createElement("span",null,"\u5F85\u5BA1\u6838"),t.a.createElement(w.a,{type:"primary",onClick:function(){return ft("2")},ghost:!0,style:{marginLeft:"20px"}},"\u64A4\u9500\u8BA4\u8BC1")):t.a.createElement("span",{style:{color:"#6ec76e"}},t.a.createElement("span",{className:"iconfont icon-wancheng font-12 ml20"}),t.a.createElement("span",null,"\u5DF2\u8BA4\u8BC1"),t.a.createElement(w.a,{type:"primary",onClick:function(){tr({type:"account/setActionTabs",payload:{key:"Account-ProfessionalAuth"}})},ghost:!0,style:{marginLeft:"20px"}},"\u91CD\u65B0\u8BA4\u8BC1"))),t.a.createElement("p",null,"\u5B66\u53F7\uFF1A",t.a.createElement("span",null,(bt==null?void 0:bt.student_id)||"--")),t.a.createElement("p",null,"\u5B66\u6821\uFF1A",t.a.createElement("span",null,(bt==null?void 0:bt.school_name)||"--")),t.a.createElement("p",null,"\u9662\u7CFB\uFF1A",t.a.createElement("span",null,(bt==null?void 0:bt.department_name)||"--"))),t.a.createElement("p",null,t.a.createElement("span",{style:{color:"red"}},"*"),t.a.createElement("span",{style:{fontSize:"16px"}},"\u8054\u7CFB\u65B9\u5F0F")),t.a.createElement("div",{style:{padding:"20px"}},t.a.createElement("p",{style:{display:"flex"}},t.a.createElement("span",{style:{width:"60px",textAlign:"right"}},"\u624B\u673A\u53F7\uFF1A"),t.a.createElement("span",{style:{width:"150px"}},(bt==null?void 0:bt.phone)||"--"),Vt==="none"?t.a.createElement("span",{style:{color:"#0152d9",marginLeft:"20px",cursor:"pointer"},onClick:function(){Zt("block")}},"\u66F4\u6362"):null),t.a.createElement(ta,{type:3,dispatch:tr,userid:bt==null?void 0:bt.id,isshow:Vt,setPhoneshow:Zt,setEmailshow:nr}),t.a.createElement("p",{style:{display:"flex"}},t.a.createElement("span",{style:{width:"60px",textAlign:"right"}},"Email\uFF1A"),t.a.createElement("span",{style:{width:"150px"}},(bt==null?void 0:bt.mail)||"--"),Or==="none"?t.a.createElement("span",{style:{color:"#0152d9",marginLeft:"20px",cursor:"pointer"},onClick:function(){nr("block")}},"\u66F4\u6362"):null),t.a.createElement(ta,{type:4,dispatch:tr,userid:bt==null?void 0:bt.id,isshow:Or,setEmailshow:nr,setPhoneshow:Zt})),gt!=null&&gt.leader&&gt!==null&&gt!==void 0&&gt.teams&&gt!==null&&gt!==void 0&&(qe=gt.teams[0])!==null&&qe!==void 0&&(pt=qe.bank_account)!==null&&pt!==void 0&&pt.bank?t.a.createElement("p",null,t.a.createElement("span",{style:{fontSize:"16px"}},"\u7B7E/\u9886/\u5F00\u6237\u884C\u53CA\u94F6\u884C\u5361\u53F7"),t.a.createElement("span",{style:{fontSize:"12px",marginLeft:"20px"}},"\u4E3A\u4FDD\u969C\u5956\u91D1\u7684\u53CA\u65F6\u53D1\u653E\uFF0C\u8BF7\u961F\u957F\u5982\u5B9E\u586B\u5199\u4F60\u540D\u4E0B\u7684\u94F6\u884C\u5361\u4FE1\u606F")):t.a.createElement("div",null,t.a.createElement("p",null,t.a.createElement("span",{style:{fontSize:"16px"}},"\u7B7E/\u9886/\u5F00\u6237\u884C\u53CA\u94F6\u884C\u5361\u53F7"),t.a.createElement("span",{style:{fontSize:"12px",marginLeft:"20px"}},"\u4E3A\u4FDD\u969C\u5956\u91D1\u7684\u53CA\u65F6\u53D1\u653E\uFF0C\u8BF7\u961F\u957F\u5982\u5B9E\u586B\u5199\u4F60\u540D\u4E0B\u7684\u94F6\u884C\u5361\u4FE1\u606F")),t.a.createElement(Vn,{dispatch:tr,userid:Jt})),gt!=null&&gt.leader?t.a.createElement("div",{style:{padding:"20px"}},t.a.createElement("p",{style:{display:"flex"}},t.a.createElement("span",{style:{width:"60px",textAlign:"right"}},"\u5F00\u6237\u884C\uFF1A"),t.a.createElement("span",null,(gt==null?void 0:gt.teams)&&(gt==null||((_t=gt.teams[0])===null||_t===void 0||((Ut=_t.bank_account)===null||Ut===void 0))?void 0:Ut.bank)||"--")),t.a.createElement("p",{style:{display:"flex"}},t.a.createElement("span",{style:{width:"60px",textAlign:"right"}},"\u652F\u884C\uFF1A"),t.a.createElement("span",null,(gt==null?void 0:gt.teams)&&(gt==null||((At=gt.teams[0])===null||At===void 0||((Xt=At.bank_account)===null||Xt===void 0))?void 0:Xt.second_bank)||"--")),t.a.createElement("p",{style:{display:"flex"}},t.a.createElement("span",{style:{width:"60px",textAlign:"right"}},"\u8D26\u53F7\uFF1A"),t.a.createElement("span",null,(gt==null?void 0:gt.teams)&&(gt==null||((kt=gt.teams[0])===null||kt===void 0||((st=kt.bank_account)===null||st===void 0))?void 0:st.card_no)||"--"))):null,t.a.createElement(Pa,{Scoid:bt==null?void 0:bt.school_id}),t.a.createElement(ln,null))}var Ta=Ka,Qn=fe.a.TabPane;function Qa(mt){var qe=mt.Prize,pt=mt.Accounts,_t=mt.getAccounts,Ut=mt.dispatch,At=mt.userid;return t.a.createElement("div",{className:"fr"},t.a.createElement("div",{className:"mb100 "},t.a.createElement(fe.a,{defaultActiveKey:"1",onChange:function(kt){kt==="2"&&_t()}},t.a.createElement(Qn,{tab:"\u83B7\u5956\u8BC1\u4E66\u4E0B\u8F7D",key:"1"},t.a.createElement(we,{Prize:qe})),t.a.createElement(Qn,{tab:"\u5B8C\u5584\u4E2A\u4EBA\u4FE1\u606F",key:"2"},t.a.createElement(Ta,{userid:At,dispatch:Ut,Prize:qe,Accounts:pt})))))}var Za=Qa,ra=j("xKgJ"),wn=j("wd/R"),na=j.n(wn),ka=fe.a.TabPane;function ma(mt){var qe,pt,_t,Ut,At,Xt,kt=mt.ChartRules,st=mt.ItemData,gt=mt.getCharts,bt=mt.Selectkey,tr=mt.HeaderDetail,Jt=mt.getChartRules,Wt=mt.userinfo,jt=mt.Editable,Vt=mt.dispatch,Zt=mt.StaffDetail,Ze=Object(l.useState)(!1),vr=Object(o.a)(Ze,2),Or=vr[0],nr=vr[1],ft=Object(l.useState)(""),yt=Object(o.a)(ft,2),ht=yt[0],wt=yt[1],Kt=Object(l.useState)(!0),ar=Object(o.a)(Kt,2),zt=ar[0],gr=ar[1],Rr=Object(l.useState)(),lr=Object(o.a)(Rr,2),Qe=lr[0],Pt=lr[1],Vr=Object(l.useState)(),Hr=Object(o.a)(Vr,2),ir=Hr[0],br=Hr[1],Tr=Object(S.i)(),Ot=Tr.identifier;Object(l.useEffect)(function(){if(zt){var lt,dt,Mt,Tt,yr=kt==null||((lt=kt.stages)===null||lt===void 0)?void 0:lt[0];Pt(yr);var Gr=kt==null||((dt=kt.stages)===null||dt===void 0||((Mt=dt[0])===null||Mt===void 0||((Tt=Mt.children)===null||Tt===void 0)))?void 0:Tt[0];if(br(Gr),yr!=null&&yr.id){var Yr,mr,Wr;gt(yr==null?void 0:yr.id),wt(((Yr=kt.rule_contents)===null||Yr===void 0||((mr=Yr.filter(function(rn){return parseInt(rn.competition_stage_id)===parseInt(yr==null?void 0:yr.id)}))===null||mr===void 0||((Wr=mr[0])===null||Wr===void 0))?void 0:Wr.content)||"")}else{var Cr,tn,Lr;gt(0),wt(((Cr=kt.rule_contents)===null||Cr===void 0||((tn=Cr.filter(function(rn){return parseInt(rn.competition_stage_id)===0}))===null||tn===void 0||((Lr=tn[0])===null||Lr===void 0))?void 0:Lr.content)||"")}}},[kt]);function Ht(){return or.apply(this,arguments)}function or(){return or=Object(i.a)(s.a.mark(function lt(){var dt,Mt,Tt,yr,Gr,Yr,mr,Wr,Cr;return s.a.wrap(function(Lr){for(;;)switch(Lr.prev=Lr.next){case 0:if(ht){Lr.next=3;break}return r.b.info("\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A"),Lr.abrupt("return");case 3:if(gr(!1),dt=Qe==null?void 0:Qe.id,!dt){Lr.next=12;break}return Lr.next=8,Object(Y.a)("/api/competitions/".concat(Ot,"/update_md_content.json"),{method:"post",body:{competition_module_id:bt,content:ht,md_content_id:(Mt=kt.rule_contents)===null||Mt===void 0||((Tt=Mt.filter(function(rn){return parseInt(rn.competition_stage_id)===parseInt(dt)}))===null||Tt===void 0||((yr=Tt[0])===null||yr===void 0))?void 0:yr.id,stage_id:Qe==null?void 0:Qe.id}});case 8:Gr=Lr.sent,Gr.status===0&&(r.b.info("\u66F4\u65B0\u6210\u529F"),nr(!1),Jt()),Lr.next=16;break;case 12:return Lr.next=14,Object(Y.a)("/api/competitions/".concat(Ot,"/update_md_content.json"),{method:"post",body:{competition_module_id:bt,content:ht,md_content_id:(Yr=kt.rule_contents)===null||Yr===void 0||((mr=Yr.filter(function(rn){return parseInt(rn.competition_stage_id)===0}))===null||mr===void 0||((Wr=mr[0])===null||Wr===void 0))?void 0:Wr.id,stage_id:Qe==null?void 0:Qe.id}});case 14:Cr=Lr.sent,Cr.status===0&&(r.b.info("\u66F4\u65B0\u6210\u529F"),nr(!1),Jt());case 16:case"end":return Lr.stop()}},lt)})),or.apply(this,arguments)}var Gt=[{title:"request_id",dataIndex:"request_id",width:120,align:"center",key:"name",render:function(dt,Mt,Tt){return t.a.createElement("span",null,dt)}},{title:"\u9644\u4EF6",dataIndex:"file_name",align:"center",width:150,key:"file_name",render:function(dt){return t.a.createElement(Ye.a,{title:dt},t.a.createElement("span",{title:dt},dt&&(dt==null?void 0:dt.length)>=10?(dt==null?void 0:dt.substr(0,10))+"...":dt||"--"))}},{title:"\u63D0\u4EA4\u4EBA",dataIndex:"user_name",key:"user_name",width:100,render:function(dt){return t.a.createElement("span",{title:dt},dt&&(dt==null?void 0:dt.length)>=6?(dt==null?void 0:dt.substr(0,6))+"...":dt||"--")}},{title:"\u63D0\u4EA4\u65F6\u95F4",dataIndex:"created_at",key:"created_at",align:"center"},{title:"\u72B6\u6001",dataIndex:"status",key:"status",width:50,render:function(dt){return t.a.createElement("span",null,dt===1?"\u8BA1\u7B97\u4E2D":dt===2?"\u5B8C\u6210":dt===0?"\u5F85\u8BA1\u7B97":dt===3&&"\u9519\u8BEF")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name)==="\u8BA1\u56FE\u6311\u6218\u70ED\u8EAB\u8D5B"&&{title:"\u6570\u636E\u6307\u68071",dataIndex:"data_ranking",key:"data_ranking",align:"center",render:function(dt){return t.a.createElement("span",null,dt||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name)==="\u8BA1\u56FE\u6311\u6218\u70ED\u8EAB\u8D5B"&&{title:"\u6570\u636E\u6307\u68072",dataIndex:"data_other",key:"data_other",align:"left",render:function(dt){return(dt==null?void 0:dt.length)>0?dt==null?void 0:dt.map(function(Mt,Tt){return t.a.createElement("span",null,Mt==null?void 0:Mt.name,"\uFF1A",Mt==null?void 0:Mt.value," ",t.a.createElement("br",null))}):t.a.createElement("span",null,"--")}},(Qe==null?void 0:Qe.display_four_indicators)&&{title:"mask accuary",dataIndex:"data_ranking",key:"data_ranking",align:"left",render:function(dt){return t.a.createElement("span",null,dt||"--")}},(Qe==null?void 0:Qe.display_four_indicators)&&{title:"\u7F8E\u5B66\u8BC4\u5206",dataIndex:"data_other",key:"data_other",align:"left",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="score"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},(Qe==null?void 0:Qe.display_four_indicators)&&{title:"FID",dataIndex:"data_other",key:"data_other",align:"left",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="fid"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},(Qe==null?void 0:Qe.display_four_indicators)&&{title:"\u603B\u5206",dataIndex:"data_other",key:"data_other",align:"left",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="total_score"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name.includes("\u53EF\u5FAE\u6E32\u67D3\u65B0\u89C6\u89D2\u751F\u6210\u8D5B\u9898"))&&{title:"Car",dataIndex:"data_ranking",key:"data_ranking",align:"center",render:function(dt){return t.a.createElement("span",null,dt||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name.includes("\u53EF\u5FAE\u6E32\u67D3\u65B0\u89C6\u89D2\u751F\u6210\u8D5B\u9898"))&&{title:"Coffee",dataIndex:"data_other",key:"data_other",align:"center",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="Coffee"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name.includes("\u53EF\u5FAE\u6E32\u67D3\u65B0\u89C6\u89D2\u751F\u6210\u8D5B\u9898"))&&{title:"Easyship",dataIndex:"data_other",key:"data_other",align:"center",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="Easyship"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name.includes("\u53EF\u5FAE\u6E32\u67D3\u65B0\u89C6\u89D2\u751F\u6210\u8D5B\u9898"))&&{title:"Scar",dataIndex:"data_other",key:"data_other",align:"center",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="Scar"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name.includes("\u53EF\u5FAE\u6E32\u67D3\u65B0\u89C6\u89D2\u751F\u6210\u8D5B\u9898"))&&{title:"Scarf",dataIndex:"data_other",key:"data_other",align:"center",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="Scarf"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},!(Qe!=null&&Qe.display_four_indicators)&&(Qe==null?void 0:Qe.name.includes("\u53EF\u5FAE\u6E32\u67D3\u65B0\u89C6\u89D2\u751F\u6210\u8D5B\u9898"))&&{title:"\u603B\u5206",dataIndex:"data_other",key:"data_other",align:"center",render:function(dt){var Mt;return t.a.createElement("span",null,(dt==null||((Mt=dt.find(function(Tt){return(Tt==null?void 0:Tt.name)==="Total"}))===null||Mt===void 0)?void 0:Mt.value)||"--")}},{title:"\u64CD\u4F5C",dataIndex:"result_url",width:50,key:"result_url",render:function(dt){return t.a.createElement("a",{href:dt,target:"_blank",download:"\u9644\u4EF6"},"\u4E0B\u8F7D")}}].filter(function(lt){return!!lt});return t.a.createElement("div",null,(kt==null||((qe=kt.stages)===null||qe===void 0)?void 0:qe.length)>0?null:t.a.createElement(ze,null),(kt==null||((pt=kt.stages)===null||pt===void 0)?void 0:pt.length)>0&&t.a.createElement(fe.a,{animated:!0,tabBarExtraContent:Wt!=null&&Wt.admin||Wt!=null&&Wt.business||jt?t.a.createElement(w.a,{onClick:function(){nr(!0)}},"\u7F16\u8F91"):Zt.enrolled&&(Qe==null?void 0:Qe.start_time)&&(Qe==null?void 0:Qe.end_time)&&t.a.createElement("span",null,"\u63D0\u4EA4\u65F6\u95F4\uFF1A",na()(Qe==null?void 0:Qe.start_time).format("YYYY-MM-DD HH:mm:ss"),"\u81F3",na()(Qe==null?void 0:Qe.end_time).format("YYYY-MM-DD HH:mm:ss"),t.a.createElement(w.a,{style:{marginLeft:"20px"},disabled:na()(Qe==null?void 0:Qe.start_time).unix()>na()(na()().format("YYYY-MM-DD HH:mm:s")).unix()||na()(na()().format("YYYY-MM-DD HH:mm:s")).unix()>na()(Qe==null?void 0:Qe.end_time).unix(),onClick:function(){Vt({type:"shixunsDetail/setActionTabs",payload:{key:"md-tab",params:{value:(ir==null?void 0:ir.id)||(Qe==null?void 0:Qe.id),id:tr==null?void 0:tr.id}}})}},"\u63D0\u4EA4\u7ED3\u679C")),onChange:function(dt){var Mt,Tt,yr,Gr,Yr;nr(!1);var mr=kt==null||((Mt=kt.stages)===null||Mt===void 0)?void 0:Mt.filter(function(Cr){return parseInt(dt)===parseInt(Cr==null?void 0:Cr.id)})[0],Wr=mr==null||((Tt=mr.children)===null||Tt===void 0)?void 0:Tt[0];br(Wr),Pt(mr),wt(((yr=kt.rule_contents)===null||yr===void 0||((Gr=yr.filter(function(Cr){return parseInt(Cr.competition_stage_id)===parseInt(mr==null?void 0:mr.id)}))===null||Gr===void 0||((Yr=Gr[0])===null||Yr===void 0))?void 0:Yr.content)||""),gt((Wr==null?void 0:Wr.id)||dt)}},kt&&kt.stages.map(function(lt,dt){return t.a.createElement(ka,{tab:lt.name,key:lt.id===null?0:lt.id},Or===!1&&kt&&kt.rule_contents.map(function(Mt,Tt){if(lt.id===Mt.competition_stage_id)return t.a.createElement(k.a,{key:Tt,value:Mt.content===void 0||Mt.content===null?"":Mt.content});if(lt.id===null&&Mt.competition_stage_id===0)return t.a.createElement(k.a,{key:Tt,value:Mt.content===void 0||Mt.content===null?"":Mt.content})}))})),(Qe==null||((_t=Qe.children)===null||_t===void 0)?void 0:_t.length)>0&&t.a.createElement(fe.a,{activeKey:(ir==null?void 0:ir.id)+"",onChange:function(dt){var Mt,Tt=Qe==null||((Mt=Qe.children)===null||Mt===void 0)?void 0:Mt.filter(function(yr){return parseInt(dt)===parseInt(yr==null?void 0:yr.id)})[0];br(Tt),gt(dt)}},Qe==null||((Ut=Qe.children)===null||Ut===void 0)?void 0:Ut.map(function(lt,dt){return t.a.createElement(ka,{tab:lt.name,key:lt.id===null?0:lt.id})})),Or&&t.a.createElement("div",null,t.a.createElement(ee.a,{defaultValue:ht,onChange:function(dt){wt(dt)}}),t.a.createElement("p",{style:{marginTop:"10px"}},t.a.createElement(w.a,{style:{width:"90px"},type:"primary",onClick:function(){return Ht()}},"\u63D0\u4EA4"),t.a.createElement(w.a,{style:{marginLeft:"30px",width:"90px"},onClick:function(){return nr(!1)}},"\u53D6\u6D88"))),((At=tr.competition_modules.filter(function(lt){return lt.id===bt}))===null||At===void 0||((Xt=At[0])===null||Xt===void 0)?void 0:Xt.show_leaderboard)&&t.a.createElement($.a,{dataSource:st==null?void 0:st.results,columns:Gt}))}var va=ma,Di=j("DjyN"),Xa=j("NUBc"),jn=fe.a.TabPane;function za(mt){var qe,pt,_t,Ut,At,Xt,kt=mt.loading,st=mt.ChartRules,gt=mt.ItemData,bt=mt.getCharts,tr=mt.Selectkey,Jt=mt.HeaderDetail,Wt=mt.getChartRules,jt=mt.userinfo,Vt=mt.Editable,Zt=mt.dispatch,Ze=mt.StaffDetail,vr=Object(l.useState)(!1),Or=Object(o.a)(vr,2),nr=Or[0],ft=Or[1],yt=Object(l.useState)(""),ht=Object(o.a)(yt,2),wt=ht[0],Kt=ht[1],ar=Object(l.useState)(!0),zt=Object(o.a)(ar,2),gr=zt[0],Rr=zt[1],lr=Object(l.useState)(),Qe=Object(o.a)(lr,2),Pt=Qe[0],Vr=Qe[1],Hr=Object(l.useState)(),ir=Object(o.a)(Hr,2),br=ir[0],Tr=ir[1],Ot=Object(S.i)(),Ht=Ot.identifier,or=Object(l.useState)({page:1,limit:10,sort:"desc"}),Gt=Object(o.a)(or,2),lt=Gt[0],dt=Gt[1];Object(l.useEffect)(function(){var Tt;gr&&st!==null&&st!==void 0&&(Tt=st.stages)!==null&&Tt!==void 0&&Tt[0]&&Mt()},[st==null||((qe=st.stages)===null||qe===void 0)?void 0:qe[0]]);var Mt=function(){var Tt=Object(i.a)(s.a.mark(function yr(){var Gr,Yr,mr,Wr,Cr,tn;return s.a.wrap(function(rn){for(;;)switch(rn.prev=rn.next){case 0:return Cr=st==null||((Gr=st.stages)===null||Gr===void 0)?void 0:Gr[0],Vr(Cr),tn=st==null||((Yr=st.stages)===null||Yr===void 0||((mr=Yr[0])===null||mr===void 0||((Wr=mr.children)===null||Wr===void 0)))?void 0:Wr[0],Tr(tn),lt.id=(tn==null?void 0:tn.id)||(Cr==null?void 0:Cr.id),dt(Object(N.a)({},lt)),rn.next=7,bt(Object(N.a)(Object(N.a)({},lt),{},{stage_id:lt.id}));case 7:case"end":return rn.stop()}},yr)}));return function(){return Tt.apply(this,arguments)}}();return t.a.createElement("div",null,(st==null||((pt=st.stages)===null||pt===void 0)?void 0:pt.length)>0?null:t.a.createElement(ze,null),(st==null||((_t=st.stages)===null||_t===void 0)?void 0:_t.length)>0&&t.a.createElement(fe.a,{tabBarStyle:{height:65,marginLeft:35,marginRight:30},animated:!0,onChange:function(){var Tt=Object(i.a)(s.a.mark(function yr(Gr){var Yr,mr,Wr,Cr,tn,Lr,rn;return s.a.wrap(function(Ae){for(;;)switch(Ae.prev=Ae.next){case 0:return ft(!1),Lr=st==null||((Yr=st.stages)===null||Yr===void 0)?void 0:Yr.filter(function(Ue){return parseInt(Gr)===parseInt(Ue==null?void 0:Ue.id)})[0],rn=Lr==null||((mr=Lr.children)===null||mr===void 0)?void 0:mr[0],Tr(rn),Vr(Lr),Kt(((Wr=st.rule_contents)===null||Wr===void 0||((Cr=Wr.filter(function(Ue){return parseInt(Ue.competition_stage_id)===parseInt(Lr==null?void 0:Lr.id)}))===null||Cr===void 0||((tn=Cr[0])===null||tn===void 0))?void 0:tn.content)||""),lt.page=1,lt.limit=10,lt.id=(rn==null?void 0:rn.id)||Gr,dt(Object(N.a)({},lt)),Ae.next=9,bt(Object(N.a)({},lt));case 9:case"end":return Ae.stop()}},yr)}));return function(yr){return Tt.apply(this,arguments)}}()},st&&st.stages.map(function(Tt,yr){return t.a.createElement(jn,{tab:Tt.name,key:Tt.id===null?0:Tt.id})})),(Pt==null||((Ut=Pt.children)===null||Ut===void 0)?void 0:Ut.length)>0&&t.a.createElement(fe.a,{activeKey:(br==null?void 0:br.id)+"",onChange:function(){var Tt=Object(i.a)(s.a.mark(function yr(Gr){var Yr,mr;return s.a.wrap(function(Cr){for(;;)switch(Cr.prev=Cr.next){case 0:return mr=Pt==null||((Yr=Pt.children)===null||Yr===void 0)?void 0:Yr.filter(function(tn){return parseInt(Gr)===parseInt(tn==null?void 0:tn.id)})[0],Tr(mr),lt.page=1,lt.limit=10,lt.id=Gr,dt(Object(N.a)({},lt)),Cr.next=5,bt(Object(N.a)({},lt));case 5:case"end":return Cr.stop()}},yr)}));return function(yr){return Tt.apply(this,arguments)}}()},Pt==null||((At=Pt.children)===null||At===void 0)?void 0:At.map(function(Tt,yr){return t.a.createElement(jn,{tab:Tt.name,key:Tt.id===null?0:Tt.id})})),t.a.createElement("div",{style:{height:10,background:"#F5F5F5"}}),t.a.createElement("div",{style:{padding:"20px 30px"}},t.a.createElement("span",{style:{cursor:"pointer",marginRight:20},onClick:function(){lt.page=1,lt.sort=lt.sort==="desc"?"asc":"desc",dt(Object(N.a)({},lt)),bt(Object(N.a)({},lt))}},"\u6309\u63D0\u4EA4\u65F6\u95F4",lt.sort==="asc"?"\u6B63":"\u5012","\u5E8F\u6392\u5E8F ",t.a.createElement("i",{className:"iconfont font14 ".concat(lt.sort==="asc"?"icon-jiantou9":"icon-changyongtubiao-xianxingdaochu-zhuanqu-")}))," ",t.a.createElement(B.a.Search,{onSearch:function(yr){lt.page=1,lt.search=yr,dt(Object(N.a)({},lt)),bt(Object(N.a)({},lt))},style:{width:"82%"},placeholder:"\u8F93\u5165\u4EBA\u5458/\u6218\u961F\u540D\u79F0\u8FDB\u884C\u641C\u7D22"}),t.a.createElement(p.a,{spinning:kt},gt==null||((Xt=gt.results)===null||Xt===void 0)?void 0:Xt.map(function(Tt,yr){return t.a.createElement("div",{style:{border:"1px solid #E3EFFC",height:100,borderRadius:"2px 2px 0px 0px",marginTop:yr===0?14:30}},t.a.createElement("div",{style:{height:60,padding:10,display:"flex",alignItems:"center"}},t.a.createElement("img",{src:K.a.IMG_SERVER+"/images/"+(Tt==null?void 0:Tt.image_url),style:{width:40,height:40,borderRadius:"50%"}}),t.a.createElement("div",{style:{marginLeft:10}},t.a.createElement("span",{style:{color:"#333333",fontWeight:500,fontSize:"16px"}},Tt==null?void 0:Tt.user_name),t.a.createElement("span",{style:{color:"#999999",fontWeight:400,fontSize:"14px",marginLeft:60}},"\u6240\u5C5E\u6218\u961F",t.a.createElement("span",{style:{marginLeft:10,color:"#333"}},(Tt==null?void 0:Tt.team_name)||"- -")),t.a.createElement("span",{style:{color:"#333333",fontWeight:400,fontSize:"14px",marginLeft:40}},"\u5B66\u6821 ",t.a.createElement("span",{style:{marginLeft:10,color:"#333"}},(Tt==null?void 0:Tt.school_name)||"- -")))),t.a.createElement("div",{style:{background:"#EEF2F8",height:40,borderRadius:"0px 0px 2px 2px",paddingLeft:60,paddingRight:40,display:"flex",alignItems:"center",justifyContent:"space-between"}},t.a.createElement("div",null,t.a.createElement("span",{style:{color:"#666666",fontSize:"12px"}},"\u63D0\u4EA4\u65F6\u95F4\uFF1A",Tt==null?void 0:Tt.created_at),t.a.createElement("span",{style:{color:"#666666",fontSize:"12px",margin:"0px 40px"}},"\u6D88\u8017\u5185\u5B58\uFF1A",(Tt==null?void 0:Tt.ts_mem)||"- -","MB"),t.a.createElement("span",{style:{color:"#666666",fontSize:"12px"}},"\u4EE3\u7801\u6267\u884C\u65F6\u95F4\uFF1A",(Tt==null?void 0:Tt.ts_time)||"- -","\u79D2")),t.a.createElement("a",{style:{display:"flex",alignItems:"center"},href:"/tasks/".concat(Tt==null?void 0:Tt.game_identifier),target:"_blank"},t.a.createElement("i",{className:"iconfont icon-chakandaima",style:{marginRight:4}}),t.a.createElement("span",{style:{lineHeight:"14px"}},"\u67E5\u770B\u4EE3\u7801"))))})),t.a.createElement(Xa.a,{total:gt==null?void 0:gt.total_count,pageSize:10,hideOnSinglePage:!0,style:{marginTop:40,textAlign:"center"},showSizeChanger:!1,current:lt.page,onChange:function(yr,Gr){lt.page=yr,dt(Object(N.a)({},lt)),bt(Object(N.a)({},lt))}})))}var _i=za,Ma=function(qe){var pt=["\u96F6","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D","\u4E03","\u516B","\u4E5D"],_t=["","\u5341","\u767E","\u5343","\u4E07"];qe=parseInt(qe);var Ut=function(st){for(var gt=st.toString().split("").reverse(),bt="",tr=0;tr<gt.length;tr++)bt=(tr==0&&gt[tr]==0||tr>0&&gt[tr]==0&&gt[tr-1]==0?"":pt[gt[tr]]+(gt[tr]==0?_t[0]:_t[tr]))+bt;return bt},At=Math.floor(qe/1e4),Xt=qe%1e4;return Xt.toString().length<4&&(Xt="0"+Xt),At?Ut(At)+"\u4E07"+Ut(Xt):Ut(qe)};function aa(mt){var qe,pt=mt.item,_t=mt.index,Ut=mt.StaffDetail,At=Object(l.useState)(!0),Xt=Object(o.a)(At,2),kt=Xt[0],st=Xt[1],gt=Object(l.useState)(!0),bt=Object(o.a)(gt,2),tr=bt[0],Jt=bt[1],Wt=Object(l.useRef)();return t.a.createElement("div",{style:{border:"1px solid #E3EFFC",borderRadius:"2px",marginTop:20}},t.a.createElement("div",{style:{padding:10,display:"flex",position:"relative"}},t.a.createElement("img",{src:K.a.IMG_SERVER+"/"+(pt==null?void 0:pt.pic),style:{width:220,height:130,borderRadius:"4px"}}),t.a.createElement("div",{style:{marginLeft:20,width:"75%"}},t.a.createElement("div",{style:{display:"flex",justifyContent:"space-between"}},t.a.createElement("span",{style:{color:"#333333",fontWeight:500,fontSize:"16px"}},"\u4EFB\u52A1",Ma(_t+1),"\uFF1A",t.a.createElement("span",{style:{color:"#333",fontWeight:"400"}},pt==null?void 0:pt.name)),t.a.createElement("span",{style:{color:"#9096A3"}},"\u5173\u5361",t.a.createElement("span",{style:{color:"#333333",marginLeft:5}},pt==null?void 0:pt.challenges_count)," ")),t.a.createElement("div",{ref:Wt},t.a.createElement(k.a,{style:{maxHeight:kt&&100},value:pt==null?void 0:pt.description})),t.a.createElement("div",{style:{textAlign:"center",color:"#145DFF",cursor:"pointer"},onClick:function(){st(!kt)}},kt?"\u9605\u8BFB\u5168\u6587 ":"\u6536\u8D77\u5168\u6587 ",t.a.createElement("i",{className:"iconfont font14 ".concat(kt?"icon-jiantou9":"icon-changyongtubiao-xianxingdaochu-zhuanqu-")})),t.a.createElement("div",{style:{marginTop:14,maxHeight:tr&&58,overflow:"hidden"}},pt==null||((qe=pt.challenges)===null||qe===void 0)?void 0:qe.map(function(jt,Vt){return t.a.createElement("div",{style:{marginTop:Vt===0?0:12}},t.a.createElement("i",{className:"iconfont icon-shixunti2 c-light-primary font20"}),t.a.createElement("span",{style:{marginLeft:10}},"\u7B2C",Vt+1,"\u5173",jt==null?void 0:jt.name))})),t.a.createElement("div",{style:{position:"absolute",bottom:14,right:10,color:"#145DFF",cursor:"pointer"}},t.a.createElement("span",{onClick:function(){Jt(!tr)}},tr?"\u5C55\u5F00":"\u6536\u8D77"," ",t.a.createElement("i",{className:"iconfont font14 ".concat(tr?"icon-jiantou9":"icon-changyongtubiao-xianxingdaochu-zhuanqu-")}))," ",(Ut==null?void 0:Ut.enrolled)&&t.a.createElement(w.a,{onClick:function(){window.open("/shixuns/".concat(pt==null?void 0:pt.identifier,"/challenges"))},style:{marginLeft:30},type:"primary"},"\u5F00\u542F\u6311\u6218")))))}var oi=aa,pi=fe.a.TabPane;function si(mt){var qe,pt,_t,Ut,At,Xt,kt=mt.loading,st=mt.ChartRules,gt=mt.ItemData,bt=mt.getCharts,tr=mt.Selectkey,Jt=mt.HeaderDetail,Wt=mt.getChartRules,jt=mt.userinfo,Vt=mt.Editable,Zt=mt.dispatch,Ze=mt.StaffDetail,vr=Object(l.useState)(!1),Or=Object(o.a)(vr,2),nr=Or[0],ft=Or[1],yt=Object(l.useState)(""),ht=Object(o.a)(yt,2),wt=ht[0],Kt=ht[1],ar=Object(l.useState)(!0),zt=Object(o.a)(ar,2),gr=zt[0],Rr=zt[1],lr=Object(l.useState)(),Qe=Object(o.a)(lr,2),Pt=Qe[0],Vr=Qe[1],Hr=Object(l.useState)(),ir=Object(o.a)(Hr,2),br=ir[0],Tr=ir[1],Ot=Object(S.i)(),Ht=Ot.identifier,or=Object(l.useState)({page:1,limit:10}),Gt=Object(o.a)(or,2),lt=Gt[0],dt=Gt[1],Mt=Object(l.useState)(),Tt=Object(o.a)(Mt,2),yr=Tt[0],Gr=Tt[1];Object(l.useEffect)(function(){var mr;gr&&st!==null&&st!==void 0&&(mr=st.stages)!==null&&mr!==void 0&&mr[0]&&Yr()},[st==null||((qe=st.stages)===null||qe===void 0)?void 0:qe[0]]);var Yr=function(){var mr=Object(i.a)(s.a.mark(function Wr(){var Cr,tn,Lr,rn,Nn,Ae;return s.a.wrap(function(Ke){for(;;)switch(Ke.prev=Ke.next){case 0:return Nn=st==null||((Cr=st.stages)===null||Cr===void 0)?void 0:Cr[0],Vr(Nn),Ae=st==null||((tn=st.stages)===null||tn===void 0||((Lr=tn[0])===null||Lr===void 0||((rn=Lr.children)===null||rn===void 0)))?void 0:rn[0],Tr(Ae),lt.id=(Ae==null?void 0:Ae.id)||(Nn==null?void 0:Nn.id),dt(Object(N.a)({},lt)),Ke.next=7,bt(Object(N.a)(Object(N.a)({},lt),{},{stage_id:lt.id}));case 7:case"end":return Ke.stop()}},Wr)}));return function(){return mr.apply(this,arguments)}}();return t.a.createElement("div",null,(st==null||((pt=st.stages)===null||pt===void 0)?void 0:pt.length)>0?null:t.a.createElement(ze,null),(st==null||((_t=st.stages)===null||_t===void 0)?void 0:_t.length)>0&&t.a.createElement(fe.a,{tabBarStyle:{height:65,marginLeft:35,marginRight:30},animated:!0,onChange:function(){var mr=Object(i.a)(s.a.mark(function Wr(Cr){var tn,Lr,rn,Nn,Ae,Ue,Ke;return s.a.wrap(function(he){for(;;)switch(he.prev=he.next){case 0:return ft(!1),Ue=st==null||((tn=st.stages)===null||tn===void 0)?void 0:tn.filter(function(Oe){return parseInt(Cr)===parseInt(Oe==null?void 0:Oe.id)})[0],Ke=Ue==null||((Lr=Ue.children)===null||Lr===void 0)?void 0:Lr[0],Tr(Ke),Vr(Ue),Kt(((rn=st.rule_contents)===null||rn===void 0||((Nn=rn.filter(function(Oe){return parseInt(Oe.competition_stage_id)===parseInt(Ue==null?void 0:Ue.id)}))===null||Nn===void 0||((Ae=Nn[0])===null||Ae===void 0))?void 0:Ae.content)||""),lt.page=1,lt.limit=10,lt.id=(Ke==null?void 0:Ke.id)||Cr,dt(Object(N.a)({},lt)),he.next=9,bt(Object(N.a)({},lt));case 9:case"end":return he.stop()}},Wr)}));return function(Wr){return mr.apply(this,arguments)}}()},st&&st.stages.map(function(mr,Wr){return t.a.createElement(pi,{tab:mr.name,key:mr.id===null?0:mr.id})})),(Pt==null||((Ut=Pt.children)===null||Ut===void 0)?void 0:Ut.length)>0&&t.a.createElement(fe.a,{activeKey:(br==null?void 0:br.id)+"",tabBarStyle:{height:65,marginLeft:35,marginRight:30},onChange:function(){var mr=Object(i.a)(s.a.mark(function Wr(Cr){var tn,Lr;return s.a.wrap(function(Nn){for(;;)switch(Nn.prev=Nn.next){case 0:return Lr=Pt==null||((tn=Pt.children)===null||tn===void 0)?void 0:tn.filter(function(Ae){return parseInt(Cr)===parseInt(Ae==null?void 0:Ae.id)})[0],Tr(Lr),lt.page=1,lt.limit=10,lt.id=Cr,dt(Object(N.a)({},lt)),Nn.next=5,bt(Object(N.a)({},lt));case 5:case"end":return Nn.stop()}},Wr)}));return function(Wr){return mr.apply(this,arguments)}}()},Pt==null||((At=Pt.children)===null||At===void 0)?void 0:At.map(function(mr,Wr){return t.a.createElement(pi,{tab:mr.name,key:mr.id===null?0:mr.id})})),t.a.createElement("div",{style:{height:10,background:"#F5F5F5"}}),t.a.createElement("div",{style:{padding:"20px 30px"}},t.a.createElement("div",{style:{display:"flex",justifyContent:"space-between"}},t.a.createElement("span",{style:{color:"#9096A3"}},"\u4F5C\u54C1\u63D0\u4EA4\u65F6\u95F4",t.a.createElement("span",{style:{color:"#333333",marginLeft:5}},gt==null?void 0:gt.start_time,"~",gt==null?void 0:gt.end_time)),t.a.createElement("span",{style:{color:"#9096A3"}},"\u6210\u7EE9\u6765\u6E90",t.a.createElement("span",{style:{color:"#333333",marginLeft:5}},(gt==null?void 0:gt.score_source)===0?"\u7ECF\u9A8C\u503C":"\u9884\u6D4B\u51C6\u786E\u7387")," ")),t.a.createElement(p.a,{spinning:kt},gt==null||((Xt=gt.results)===null||Xt===void 0)?void 0:Xt.map(function(mr,Wr){return t.a.createElement(oi,{StaffDetail:Ze,item:mr,index:Wr})})),t.a.createElement(Xa.a,{total:gt==null?void 0:gt.total_count,pageSize:10,hideOnSinglePage:!0,style:{marginTop:40,textAlign:"center"},showSizeChanger:!1,current:lt.page,onChange:function(Wr,Cr){lt.page=Wr,dt(Object(N.a)({},lt)),bt(Object(N.a)({},lt))}})))}var mi=si,qa=j("UfjD"),wa=j("qHvr"),ei=function(qe){var pt,_t,Ut,At,Xt,kt,st,gt,bt=qe.globalSetting,tr=qe.loading,Jt=qe.dispatch,Wt=qe.user,jt=Object(u.a)(qe,["globalSetting","loading","dispatch","user"]),Vt=Object(l.useState)({avatar_url:""}),Zt=Object(o.a)(Vt,2),Ze=Zt[0],vr=Zt[1],Or=Object(l.useState)([]),nr=Object(o.a)(Or,2),ft=nr[0],yt=nr[1],ht=Object(S.i)(),wt=ht.identifier,Kt=Object(l.useState)([]),ar=Object(o.a)(Kt,2),zt=ar[0],gr=ar[1],Rr=Object(l.useState)(!0),lr=Object(o.a)(Rr,2),Qe=lr[0],Pt=lr[1],Vr=Object(l.useState)([]),Hr=Object(o.a)(Vr,2),ir=Hr[0],br=Hr[1],Tr=Object(l.useState)([]),Ot=Object(o.a)(Tr,2),Ht=Ot[0],or=Ot[1],Gt=Object(l.useState)(!1),lt=Object(o.a)(Gt,2),dt=lt[0],Mt=lt[1],Tt=Object(l.useState)(!1),yr=Object(o.a)(Tt,2),Gr=yr[0],Yr=yr[1],mr=Object(l.useState)(!1),Wr=Object(o.a)(mr,2),Cr=Wr[0],tn=Wr[1],Lr=Object(l.useState)([]),rn=Object(o.a)(Lr,2),Nn=rn[0],Ae=rn[1],Ue=Object(l.useState)([]),Ke=Object(o.a)(Ue,2),Le=Ke[0],he=Ke[1],Oe=Object(l.useState)([]),be=Object(o.a)(Oe,2),De=be[0],Fe=be[1],Be=Object(l.useState)(!1),je=Object(o.a)(Be,2),Ge=je[0],it=je[1],Et=Object(l.useState)([]),St=Object(o.a)(Et,2),Nt=St[0],_r=St[1],Nr=Object(l.useState)(),Pr=Object(o.a)(Nr,2),Br=Pr[0],Ir=Pr[1],Kr=Object(l.useState)(!0),zr=Object(o.a)(Kr,2),on=zr[0],$r=zr[1],gn=Object(l.useState)(!1),Zr=Object(o.a)(gn,2),wr=Zr[0],Ar=Zr[1],Xr=Object(l.useState)(!1),nn=Object(o.a)(Xr,2),fr=nn[0],un=nn[1],An=Object(l.useState)(!1),fn=Object(o.a)(An,2),En=fn[0],hn=fn[1],Fn=Object(l.useState)(!1),Kn=Object(o.a)(Fn,2),Rn=Kn[0],Zn=Kn[1],Na=Object(l.useState)(!1),ua=Object(o.a)(Na,2),zn=ua[0],xn=ua[1],Tn=Object(l.useState)(!0),In=Object(o.a)(Tn,2),Cn=In[0],Bn=In[1],ga=Object(S.h)(),Va=Object(l.useRef)(null);Object(l.useEffect)(function(){wt&&mn(),Object(Lt.Z)("\u7ADE\u8D5B")},[wt]);function mn(){return Ca.apply(this,arguments)}function Ca(){return Ca=Object(i.a)(s.a.mark(function cr(){var hr;return s.a.wrap(function(cn){for(;;)switch(cn.prev=cn.next){case 0:return cn.t0=yt,cn.next=3,Jt({type:"competitions/getStaff",payload:{identifier:wt}});case 3:return cn.t1=cn.sent,(0,cn.t0)(cn.t1),cn.next=7,Jt({type:"competitions/getHeader",payload:{identifier:wt}});case 7:hr=cn.sent,vr(hr),Object(Lt.Z)((hr==null?void 0:hr.name)||"\u7ADE\u8D5B");case 10:case"end":return cn.stop()}},cr)})),Ca.apply(this,arguments)}Object(l.useEffect)(function(){var cr;Ir(parseInt(ga==null||((cr=ga.query)===null||cr===void 0)?void 0:cr.type)===1)},[ga]),Object(l.useEffect)(function(){var cr;if((Ze==null||((cr=Ze.competition_modules)===null||cr===void 0)?void 0:cr.length)>0){var hr,Qt;if((ga==null||((hr=ga.query)===null||hr===void 0)?void 0:hr.active)==="\u8D5B\u9898\u53D1\u5E03"){var cn,qt=Ze==null||((cn=Ze.competition_modules)===null||cn===void 0)?void 0:cn.find(function(ui){return ui.name==="\u8D5B\u9898\u53D1\u5E03"});if(qt){Aa(qt);return}}Aa(Ze==null||((Qt=Ze.competition_modules)===null||Qt===void 0)?void 0:Qt[0])}},[Ze]);function Aa(cr){return bn.apply(this,arguments)}function bn(){return bn=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:if(Fe(hr.id),De=hr.id,br(hr),!(hr.module_type==="entrance")){qt.next=9;break}return qt.next=6,Jt({type:"competitions/getItem",payload:{url:hr.module_url,module_type:"entrance"}});case 6:Qt=qt.sent,qt.next=12;break;case 9:return qt.next=11,Jt({type:"competitions/getItem",payload:{url:hr.module_url}});case 11:Qt=qt.sent;case 12:Mt(!1),tn(!1),it(!1),gr(Qt),Ar(!1),un(!1),or(hr.module_type),hr.module_type==="chart"?(Mt(!0),Pt(!1),Bi()):hr.module_type==="certificate"?(tn(!0),Mt(!1),Pt(!1),vi()):hr.module_type==="md_tab"?(it(!0),Pt(!1),localStorage.setItem("issee","2"),Mt(!1),tn(!1),ni()):hr.module_type==="md_shixun"?(Ar(!0),Pt(!1),ni()):hr.module_type==="entrance"?(un(!0),Pt(!1),ni()):(Pt(!0),localStorage.setItem("issee","1"));case 20:case"end":return qt.stop()}},cr)})),bn.apply(this,arguments)}function pn(cr,hr,Qt){return Hn.apply(this,arguments)}function Hn(){return Hn=Object(i.a)(s.a.mark(function cr(hr,Qt,cn){var qt,ui;return s.a.wrap(function(Sn){for(;;)switch(Sn.prev=Sn.next){case 0:if(hr.stopPropagation(),Object(ne.e)(Jt)){Sn.next=3;break}return Sn.abrupt("return");case 3:if(!(Ze!=null&&Ze.is_authentication&&!(Wt!=null&&(qt=Wt.userInfo)!==null&&qt!==void 0&&qt.authentication))){Sn.next=6;break}return Jt({type:"shixunsDetail/setActionTabs",payload:{key:"Banner-Auth"}}),Sn.abrupt("return");case 6:if(!(Ze!=null&&Ze.enroll_url)){Sn.next=9;break}return Object(Lt.U)(Ze==null?void 0:Ze.enroll_url),Sn.abrupt("return");case 9:if(!(cn==="ismodel")){Sn.next=23;break}if(!(Qt.member_of_course===!0)){Sn.next=14;break}Object(Lt.U)("/classrooms/".concat(Qt.course_id)),Sn.next=21;break;case 14:if(Qt.invite_code){Sn.next=17;break}return r.b.info("\u672C\u7ADE\u8D5B\u53EA\u9762\u5411\u90E8\u5206\u5B66\u6821/\u5355\u4F4D\u5F00\u653E\uFF0C\u4F60\u6682\u65F6\u6CA1\u6709\u53C2\u8D5B\u8D44\u683C"),Sn.abrupt("return");case 17:return Sn.next=19,Jt({type:"competitions/addApplytojoincourse",payload:{invite_code:Qt.invite_code,student:1}});case 19:ui=Sn.sent,ui.status===0&&Object(Lt.U)("/classrooms/".concat(Qt.course_id));case 21:Sn.next=27;break;case 23:if(!(ft.enrolled===!0)){Sn.next=26;break}return Object(Lt.U)(cn),Sn.abrupt("return");case 26:hn(!0);case 27:case"end":return Sn.stop()}},cr)})),Hn.apply(this,arguments)}function Bi(){return xi.apply(this,arguments)}function xi(){return xi=Object(i.a)(s.a.mark(function cr(){return s.a.wrap(function(Qt){for(;;)switch(Qt.prev=Qt.next){case 0:return Qt.t0=Yr,Qt.next=3,Jt({type:"competitions/ChartRules",payload:{identifier:wt}});case 3:return Qt.t1=Qt.sent,Qt.next=6,(0,Qt.t0)(Qt.t1);case 6:case"end":return Qt.stop()}},cr)})),xi.apply(this,arguments)}function ti(cr){return ri.apply(this,arguments)}function ri(){return ri=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:return qt.next=2,Jt({type:"competitions/Charts",payload:{identifier:wt,stage_id:hr}});case 2:Qt=qt.sent,gr(Qt);case 4:case"end":return qt.stop()}},cr)})),ri.apply(this,arguments)}function Li(cr){return Ti.apply(this,arguments)}function Ti(){return Ti=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:return $r(!0),qt.next=3,Jt({type:"competitions/Results",payload:Object(N.a)({identifier:wt,stage_id:hr==null?void 0:hr.id},hr)});case 3:Qt=qt.sent,gr(Qt),$r(!1);case 6:case"end":return qt.stop()}},cr)})),Ti.apply(this,arguments)}function Pi(cr){return Hi.apply(this,arguments)}function Hi(){return Hi=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:return $r(!0),qt.next=3,Jt({type:"competitions/Results",payload:Object(N.a)({identifier:wt,stage_id:hr==null?void 0:hr.id,module_type:"entrance"},hr)});case 3:Qt=qt.sent,gr(Qt),$r(!1);case 6:case"end":return qt.stop()}},cr)})),Hi.apply(this,arguments)}function Vi(cr){return ki.apply(this,arguments)}function ki(){return ki=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:return qt.next=2,Jt({type:"competitions/Results",payload:{identifier:wt,stage_id:hr}});case 2:if(Qt=qt.sent,!(localStorage.getItem("issee")==="1")){qt.next=5;break}return qt.abrupt("return");case 5:gr(Qt);case 6:case"end":return qt.stop()}},cr)})),ki.apply(this,arguments)}function ni(){return wi.apply(this,arguments)}function wi(){return wi=Object(i.a)(s.a.mark(function cr(){return s.a.wrap(function(Qt){for(;;)switch(Qt.prev=Qt.next){case 0:return Qt.t0=_r,Qt.next=3,Jt({type:"competitions/TabResults",payload:{identifier:wt,competition_module_id:De}});case 3:Qt.t1=Qt.sent,(0,Qt.t0)(Qt.t1);case 5:case"end":return Qt.stop()}},cr)})),wi.apply(this,arguments)}function vi(){return ai.apply(this,arguments)}function ai(){return ai=Object(i.a)(s.a.mark(function cr(){var hr,Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:return qt.next=2,Jt({type:"competitions/Prize",payload:{identifier:wt,user_id:Wt==null||((hr=Wt.userInfo)===null||hr===void 0)?void 0:hr.user_id}});case 2:Qt=qt.sent,Ae(Qt);case 4:case"end":return qt.stop()}},cr)})),ai.apply(this,arguments)}function co(){return gi.apply(this,arguments)}function gi(){return gi=Object(i.a)(s.a.mark(function cr(){var hr,Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:return qt.next=2,Jt({type:"competitions/Accounts",payload:{id:Wt==null||((hr=Wt.userInfo)===null||hr===void 0)?void 0:hr.user_id}});case 2:Qt=qt.sent,he(Qt);case 4:case"end":return qt.stop()}},cr)})),gi.apply(this,arguments)}function Si(cr){return ii.apply(this,arguments)}function ii(){return ii=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:if(Cn){qt.next=2;break}return qt.abrupt("return");case 2:if(Bn(!1),!li()){qt.next=5;break}return qt.abrupt("return");case 5:return qt.next=7,Jt({type:"competitions/AddTeam",payload:{identifier:wt,name:hr}});case 7:Qt=qt.sent,Qt&&Qt.status===0?(r.b.info("\u521B\u5EFA\u6218\u961F\u6210\u529F"),mn(),Zn(!1)):Bn(!0);case 9:case"end":return qt.stop()}},cr)})),ii.apply(this,arguments)}function li(){var cr,hr;if(Wt!=null&&(cr=Wt.userInfo)!==null&&cr!==void 0&&cr.is_teacher){var Qt;if(ft!=null&&(Qt=ft.teacher_staff)!==null&&Qt!==void 0&&Qt.mutiple_limited&&(ft!=null&&ft.enrolled))return r.b.info("\u4F60\u5DF2\u7ECF\u62A5\u540D\uFF0C\u4E0D\u80FD\u91CD\u590D\u62A5\u540D"),Bn(!0),!0}else{var cn;if(ft!=null&&(cn=ft.member_staff)!==null&&cn!==void 0&&cn.mutiple_limited&&(ft!=null&&ft.enrolled))return r.b.info("\u4F60\u5DF2\u7ECF\u62A5\u540D\uFF0C\u4E0D\u80FD\u91CD\u590D\u62A5\u540D"),Bn(!0),!0}if(ft!=null&&ft.enroll_ended)return r.b.info("\u62A5\u540D\u5DF2\u622A\u6B62\uFF0C\u65E0\u9700\u62A5\u540D"),Bn(!0),!0;if(Wt!=null&&(hr=Wt.userInfo)!==null&&hr!==void 0&&hr.is_teacher){if(!ft.teacher_staff)return r.b.info("\u5DF2\u7981\u6B62\u8001\u5E08\u62A5\u540D"),Bn(!0),!0}else if(!(ft!=null&&ft.member_staff))return r.b.info("\u5DF2\u7981\u6B62\u5B66\u751F\u62A5\u540D"),Bn(!0),!0}function ja(cr){return Ya.apply(this,arguments)}function Ya(){return Ya=Object(i.a)(s.a.mark(function cr(hr){var Qt;return s.a.wrap(function(qt){for(;;)switch(qt.prev=qt.next){case 0:if(Cn){qt.next=2;break}return qt.abrupt("return");case 2:if(!li()){qt.next=4;break}return qt.abrupt("return");case 4:return Bn(!1),qt.next=7,Jt({type:"competitions/JoinTeam",payload:{identifier:wt,invite_code:hr}});case 7:Qt=qt.sent,Qt&&Qt.status===0?(r.b.info("\u52A0\u5165\u6218\u961F\u6210\u529F"),xn(!1),Bn(!0),mn()):Bn(!0);case 9:case"end":return qt.stop()}},cr)})),Ya.apply(this,arguments)}return t.a.createElement("div",{className:"edu-container minH500"},t.a.createElement(n.a,{className:"mt10",separator:">"},t.a.createElement(n.a.Item,null,t.a.createElement(x.a,{to:"/competitions/index"},"\u5728\u7EBF\u7ADE\u8D5B")),t.a.createElement(n.a.Item,null,Ze.name,Ze.sub_title?"-"+Ze.sub_title:null)),t.a.createElement("div",{className:"mt10",style:{display:"flex",background:"#fff",position:"relative",padding:"20px 12px"}},t.a.createElement(p.a,{spinning:tr.effects["competitions/getHeader"]},t.a.createElement("div",{style:{height:"355px",width:"800px"}},(Ze==null?void 0:Ze.avatar_url)&&(Ze==null?void 0:Ze.avatar_url)!==null&&t.a.createElement("img",{style:{height:"355px",width:"800px"},src:K.a.IMG_SERVER+"/"+(Ze==null?void 0:Ze.avatar_url)}),!(Ze!=null&&Ze.avatar_url)&&(Ze==null?void 0:Ze.avatar_url)==null&&t.a.createElement("img",{style:{height:"355px",width:"800px"},src:K.a.IMG_SERVER+"/images/educoder/competitions/mainbanner.jpg"}))),t.a.createElement("div",{style:{marginLeft:"20px",width:"400px"}},t.a.createElement("p",{className:"".concat(O.a.titlesize)},Ze.name,Ze.sub_title?"-"+Ze.sub_title:null),t.a.createElement("p",{style:{display:"flex",justifyContent:"space-between",marginRight:18}},t.a.createElement("span",{style:{display:"flex",flexDirection:"column",alignItems:"center"}},t.a.createElement("span",null,"\u5956\u91D1"),Ze!=null&&Ze.bonus?t.a.createElement("span",{style:{fontSize:"24px"}},"\xA5",parseInt(Ze&&Ze.bonus).toLocaleString()):t.a.createElement("span",{style:{fontSize:"24px"}},"\u6682\u65E0")),t.a.createElement("span",{style:{display:"flex",flexDirection:"column",alignItems:"center"}},t.a.createElement("span",null,"\u6D4F\u89C8"),t.a.createElement("span",{style:{fontSize:"24px"}},parseInt(Ze&&Ze.visits_count).toLocaleString())),t.a.createElement("span",{style:{display:"flex",flexDirection:"column",alignItems:"center"}},t.a.createElement("span",null,"\u62A5\u540D"),t.a.createElement("span",{style:{fontSize:"24px"}},parseInt(Ze&&Ze.member_count).toLocaleString()))),t.a.createElement("p",{className:O.a.timesize,style:{marginTop:30}},t.a.createElement("span",{style:{color:"#9b9b9b",marginTop:"30px"}},"\u7ADE\u8D5B\u65F6\u95F4\uFF1A"),Ze.start_time,"~",Ze.end_time),t.a.createElement("p",{className:O.a.timesize},t.a.createElement("span",{style:{color:"#9b9b9b"}},"\u62A5\u540D\u622A\u6B62\uFF1A"),Ze.enroll_end_time),Ze.competition_status==="ended"?t.a.createElement("p",{className:O.a.timesize},t.a.createElement("span",{style:{color:"#9b9b9b"}},"\u7ADE\u8D5B\u72B6\u6001\uFF1A"),"\u5DF2\u7ED3\u675F"):null,Ze.competition_status==="nearly_published"?t.a.createElement("p",{className:O.a.timesize},t.a.createElement("span",{style:{color:"#9b9b9b"}},"\u7ADE\u8D5B\u72B6\u6001\uFF1A"),"\u672A\u53D1\u5E03"):null,Ze.competition_status==="progressing"?t.a.createElement("p",{className:O.a.timesize},t.a.createElement("span",{style:{color:"#9b9b9b"}},"\u7ADE\u8D5B\u72B6\u6001\uFF1A"),"\u8FDB\u884C\u4E2D"):null,t.a.createElement("div",{style:{display:"flex",justifyContent:"center"}},(Ze==null?void 0:Ze.mode)<=2&&ft.enrolled&&t.a.createElement(w.a,{onClick:function(hr){if((Ze==null?void 0:Ze.mode)===1){var Qt;Aa((Qt=Ze.competition_modules)===null||Qt===void 0?void 0:Qt.find(function(cn){return cn.module_type==="entrance"}))}else pn(hr,Ze,"ismodel")},style:{background:"#07C160",color:"#fff",border:"1px solid #07C160",marginRight:20,display:(Ze==null?void 0:Ze.mode)===2||(Ze==null?void 0:Ze.mode)===1&&((pt=Ze.competition_modules)===null||pt===void 0||((_t=pt.filter(function(cr){return cr.module_type==="entrance"}))===null||_t===void 0)?void 0:_t.length)>0?"":"none"},className:O.a.buttonsize},(Ze==null?void 0:Ze.mode)===1&&"\u8D5B\u9898\u5165\u53E3",(Ze==null?void 0:Ze.mode)===2&&"\u8FDB\u5165\u8BFE\u5802"),Ze.competition_status==="ended"?t.a.createElement(w.a,{type:"primary",className:O.a.buttonsize,disabled:!0},"\u5DF2\u7ED3\u675F"):null,Ze.competition_status==="nearly_published"?t.a.createElement(w.a,{type:"primary",className:O.a.buttonsize,disabled:!0},"\u672A\u53D1\u5E03"):null,Ze.competition_status!=="nearly_published"&&Ze.enroll_end&&Ze.competition_status!=="ended"?t.a.createElement(w.a,{type:"primary",className:O.a.buttonsize,disabled:!0},"\u62A5\u540D\u622A\u6B62"):null,Ze.competition_status==="progressing"&&Ze.enroll_end!=!0?t.a.createElement(w.a,{type:"primary",disabled:ft.enrolled&&!Ze.need_attachment,className:O.a.buttonsize,onClick:function(hr){if(ft.enrolled&&Ze.need_attachment){var Qt;(Qt=Va.current)===null||Qt===void 0||Qt.handleVisible();return}pn(hr,Ze,Ze.mode===2?"ismodel":Ze.personal?"personal":"/competitions/index/".concat(Ze.identifier,"/enroll"))}},ft.enrolled?Ze.need_attachment?"\u4E0A\u4F20\u4F5C\u54C1":"\u5DF2\u62A5\u540D":Ze!=null&&Ze.enroll_url?"\u524D\u5F80\u5927\u8D5B\u5B98\u7F51\u62A5\u540D":"\u7ACB\u5373\u62A5\u540D"):null),Wt.userInfo.real_name!="\u6E38\u5BA2"&&!(Ze!=null&&Ze.enroll_url)&&t.a.createElement("span",{onClick:function(hr){return pn(hr,Ze,Ze.mode===2?"ismodel":Ze.personal?"personal":"/competitions/index/".concat(Ze.identifier,"/enroll"))},className:O.a.myteam},Object(ra.u)()?"\u53C2\u8D5B\u6218\u961F>>":"\u6211\u7684\u6218\u961F>>"))),t.a.createElement("div",{className:O.a.bootmdetail},t.a.createElement("div",{className:O.a.flex1},t.a.createElement(m.a,{selectedKeys:["".concat(De)]},Ze&&Ze.competition_modules&&Ze.competition_modules.map(function(cr,hr){if(cr.module_type!="enroll")return t.a.createElement(m.a.Item,{className:O.a.menuItem,onClick:function(){if(cr!=null&&cr.is_authentication){if(!Object(ne.e)(Jt))return;r.b.info("\u52A0\u5165\u6218\u961F\u624D\u80FD\u67E5\u770B");return}Aa(cr)},key:cr.id},cr.name)}))),t.a.createElement("div",{className:O.a.flex6,style:{padding:(wr||fr)&&0}},Cr?t.a.createElement(Za,{dispatch:Jt,userid:Wt==null||((Ut=Wt.userInfo)===null||Ut===void 0)?void 0:Ut.user_id,Prize:Nn,Accounts:Le,getAccounts:co}):null,dt?t.a.createElement(Ce,{HeaderDetail:Ze,userinfo:Wt.userInfo,Editable:Ze==null||((At=Ze.permission)===null||At===void 0)?void 0:At.editable,getCharts:ti,getChartRules:Bi,Selectkey:De,ChartRules:Gr,ItemData:zt}):null,Qe?t.a.createElement(Z,{ref:Va,StaffDetail:ft,HeaderDetail:Ze,userinfo:Wt.userInfo,Editable:Ze==null||((Xt=Ze.permission)===null||Xt===void 0)?void 0:Xt.editable,ItemData:zt,setIssee:Pt,ModelType:Ht,dispatch:Jt}):null,!Qe&&!wr&&!fr&&!dt&&!Cr&&!Ge?t.a.createElement(J,{userinfo:Wt.userInfo,ModelType:Ht,getrightdatas:Aa,dispatch:Jt,MenuItem:ir,setIssee:Pt,identifier:wt,ItemData:zt}):null,Ge&&t.a.createElement(va,{dispatch:Jt,StaffDetail:ft,userinfo:Wt.userInfo,HeaderDetail:Ze,Editable:Ze==null||((kt=Ze.permission)===null||kt===void 0)?void 0:kt.editable,getCharts:Vi,getChartRules:ni,Selectkey:De,ChartRules:Nt,ItemData:zt}),wr&&t.a.createElement(_i,{loading:on,dispatch:Jt,StaffDetail:ft,userinfo:Wt.userInfo,HeaderDetail:Ze,Editable:Ze==null||((st=Ze.permission)===null||st===void 0)?void 0:st.editable,getCharts:Li,getChartRules:ni,Selectkey:De,ChartRules:Nt,ItemData:zt}),fr&&t.a.createElement(mi,{loading:on,dispatch:Jt,StaffDetail:ft,userinfo:Wt.userInfo,HeaderDetail:Ze,Editable:Ze==null||((gt=Ze.permission)===null||gt===void 0)?void 0:gt.editable,getCharts:Pi,getChartRules:ni,Selectkey:De,ChartRules:Nt,ItemData:zt}))),t.a.createElement(g.a,null),t.a.createElement(G,{getResults:Vi}),t.a.createElement(C.a,{visible:Br,footer:null,width:720,title:"\u63D0\u793A",centered:!0,onCancel:function(){return Ir(!1)}},t.a.createElement("div",{className:O.a.modal},t.a.createElement("div",null,"\u534E\u4E3A\u6A21\u578B\u738B\u8005\u6311\u6218\u8D5B\u9EC4\u91D1\u8D5B\u6B63\u5F0F\u5F00\u542F\u5566"),t.a.createElement("div",null,"\u672C\u8D5B\u6BB5\u603B\u5956\u91D1\u9AD8\u8FBE",t.a.createElement("span",{style:{color:"#FF8C29"}},"300,000"),"\u5143"),t.a.createElement("div",null,"1\u3001\u7B26\u5408\u8D5B\u9898\u8981\u6C42\u7684\u961F\u4F0D\uFF08\u517125\u652F\uFF09\u53EF\u83B7\u5F97\u5956\u91D1\uFF1A12000RMB/\u961F \uFF1B"),t.a.createElement("div",null,"2\u3001\u53C2\u4E0E\u83B7\u5F97\u201C\u8363\u8000\u6BBF\u5802\u201D\u699C\u4E3B\u7684\u961F\u4F0D\uFF0C\u53EF\u83B7\u5F97\u7531\u4E2D\u56FD\u8F6F\u4EF6\u5F00\u6E90\u521B\u65B0\u5927\u8D5B\u7EC4\u59D4\u4F1A\u9881\u53D1\u7684\u9EC4\u91D1\u5B9D\u7BB1\uFF1B"),t.a.createElement("div",null,"3\u3001\u5404\u8D5B\u9898\u7CBE\u5EA6\u6700\u9AD8\u7684\u961F\u4F0D\uFF0C\u53EF\u83B7\u5F97\u7531\u4E2D\u56FD\u8F6F\u4EF6\u5F00\u6E90\u521B\u65B0\u5927\u8D5B\u7EC4\u59D4\u4F1A\u9881\u53D1\u7684\u9EC4\u91D1\u5B9D\u7BB1+\u8363\u8A89\u8BC1\u4E66\uFF1B"),t.a.createElement("div",null,"\u5FC3\u52A8\u5427\uFF0C\u90A3\u5C31\u5FEB\u70B9\u51FB\u4E0B\u65B9\u6309\u94AE\u62A5\u540D\u53C2\u8D5B"),t.a.createElement(w.a,{type:"primary",onClick:function(){return Object(Lt.U)("https://competition.huaweicloud.com/information/1000041485/introduction")}},"\u524D\u5F80\u62A5\u540D\u53C2\u8D5B"))),t.a.createElement(C.a,{title:"\u9009\u62E9\u53C2\u8D5B\u65B9\u5F0F",visible:En,onCancel:function(){hn(!1)},footer:!1},t.a.createElement("div",{style:{display:"flex",justifyContent:"space-around",height:100,alignItems:"center"}},t.a.createElement(w.a,{type:"primary",style:{height:40},onClick:function(){xn(!0),hn(!1)}},"\u52A0\u5165\u6218\u961F\u53C2\u8D5B"),t.a.createElement(w.a,{style:{height:40},onClick:function(){Zn(!0),hn(!1)}},"\u53BB\u521B\u5EFA\u6218\u961F\u53C2\u8D5B"))),zn?t.a.createElement(qa.a,{isjoin:zn,setJoin:xn,JoinTeams:ja}):null,Rn?t.a.createElement(wa.a,{isAddmodle:Rn,setIsAdd:Zn,createTeam:Si}):null)},Ei=Q.default=Object(h.a)(function(mt){var qe=mt.loading,pt=mt.globalSetting,_t=mt.user;return{globalSetting:pt,loading:qe,user:_t}})(ei)},GRuw:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("lPiR"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.WordArray,m=v.algo,y=m.SHA256,w=m.SHA224=y.extend({_doReset:function(){this._hash=new M.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var b=y._doFinalize.call(this);return b.sigBytes-=4,b}});v.SHA224=y._createHelper(w),v.HmacSHA224=y._createHmacHelper(w)}(),N.SHA224})},GfqC:function(F,Q,j){"use strict";var N=j("cDcd"),v=j.n(N),C=j("TSYQ"),M=j.n(C);function m(z,B){var k="cannot "+z.method+" "+z.action+" "+B.status+"'",K=new Error(k);return K.status=B.status,K.method=z.method,K.url=z.action,K}function y(z){var B=z.responseText||z.response;if(!B)return B;try{return JSON.parse(B)}catch(k){return B}}function w(z){var B=new XMLHttpRequest;z.onProgress&&B.upload&&(B.upload.onprogress=function(ne){ne.total>0&&(ne.percent=ne.loaded/ne.total*100),z.onProgress(ne)});var k=new FormData;z.data&&Object.keys(z.data).forEach(function(Y){var ne=z.data[Y];if(Array.isArray(ne)){ne.forEach(function(oe){k.append(Y+"[]",oe)});return}k.append(Y,z.data[Y])}),z.file instanceof Blob?k.append(z.filename,z.file,z.file.name):k.append(z.filename,z.file),B.onerror=function(ne){z.onError(ne)},B.onload=function(){return B.status<200||B.status>=300?z.onError(m(z,B),y(B)):z.onSuccess(y(B),B)},B.open(z.method,z.action,!0),z.withCredentials&&"withCredentials"in B&&(B.withCredentials=!0);var K=z.headers||{};return K["X-Requested-With"]!==null&&B.setRequestHeader("X-Requested-With","XMLHttpRequest"),Object.keys(K).forEach(function(Y){K[Y]!==null&&B.setRequestHeader(Y,K[Y])}),B.send(k),{abort:function(){B.abort()}}}var b=+new Date,p=0;function d(){return"rc-upload-"+b+"-"+ ++p}function n(z,B){return z.indexOf(B,z.length-B.length)!==-1}var c=function(z,B){if(z&&B){var k=Array.isArray(B)?B:B.split(","),K=z.name||"",Y=z.type||"",ne=Y.replace(/\/.*$/,"");return k.some(function(oe){var _e=oe.trim();return _e.charAt(0)==="."?n(K.toLowerCase(),_e.toLowerCase()):/\/\*$/.test(_e)?ne===_e.replace(/\/.*$/,""):Y===_e})}return!0};function r(z,B){var k=z.createReader(),K=[];function Y(){k.readEntries(function(ne){var oe=Array.prototype.slice.apply(ne);K=K.concat(oe);var _e=!oe.length;_e?B(K):Y()})}Y()}var i=function(B,k,K){var Y=function ne(oe,_e){_e=_e||"",oe.isFile?oe.file(function(xe){K(xe)&&(oe.fullPath&&!xe.webkitRelativePath&&(Object.defineProperties(xe,{webkitRelativePath:{writable:!0}}),xe.webkitRelativePath=oe.fullPath.replace(/^\//,""),Object.defineProperties(xe,{webkitRelativePath:{writable:!1}})),k([xe]))}):oe.isDirectory&&r(oe,function(xe){xe.forEach(function(le){ne(le,""+_e+oe.name+"/")})})};B.forEach(function(ne){Y(ne.webkitGetAsEntry())})},o=i,u=Object.assign||function(z){for(var B=1;B<arguments.length;B++){var k=arguments[B];for(var K in k)Object.prototype.hasOwnProperty.call(k,K)&&(z[K]=k[K])}return z},f=function(){function z(B,k){var K=[],Y=!0,ne=!1,oe=void 0;try{for(var _e=B[Symbol.iterator](),xe;!(Y=(xe=_e.next()).done)&&!(K.push(xe.value),k&&K.length===k);Y=!0);}catch(le){ne=!0,oe=le}finally{try{!Y&&_e.return&&_e.return()}finally{if(ne)throw oe}}return K}return function(B,k){if(Array.isArray(B))return B;if(Symbol.iterator in Object(B))return z(B,k);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(){function z(B,k){for(var K=0;K<k.length;K++){var Y=k[K];Y.enumerable=Y.enumerable||!1,Y.configurable=!0,"value"in Y&&(Y.writable=!0),Object.defineProperty(B,Y.key,Y)}}return function(B,k,K){return k&&z(B.prototype,k),K&&z(B,K),B}}();function l(z,B,k){return B in z?Object.defineProperty(z,B,{value:k,enumerable:!0,configurable:!0,writable:!0}):z[B]=k,z}function t(z,B){var k={};for(var K in z){if(B.indexOf(K)>=0)continue;if(!Object.prototype.hasOwnProperty.call(z,K))continue;k[K]=z[K]}return k}function S(z,B){if(!(z instanceof B))throw new TypeError("Cannot call a class as a function")}function x(z,B){if(!z)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return B&&(typeof B=="object"||typeof B=="function")?B:z}function h(z,B){if(typeof B!="function"&&B!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof B);z.prototype=Object.create(B&&B.prototype,{constructor:{value:z,enumerable:!1,writable:!0,configurable:!0}}),B&&(Object.setPrototypeOf?Object.setPrototypeOf(z,B):z.__proto__=B)}var R=function(B){return Object.keys(B).reduce(function(k,K){return(K.substr(0,5)==="data-"||K.substr(0,5)==="aria-"||K==="role")&&(k[K]=B[K]),k},{})},O=function(z){h(B,z);function B(){var k,K,Y,ne;S(this,B);for(var oe=arguments.length,_e=Array(oe),xe=0;xe<oe;xe++)_e[xe]=arguments[xe];return ne=(K=(Y=x(this,(k=B.__proto__||Object.getPrototypeOf(B)).call.apply(k,[this].concat(_e))),Y),Y.state={uid:d()},Y.reqs={},Y.onChange=function(le){var me=le.target.files;Y.uploadFiles(me),Y.reset()},Y.onClick=function(le){var me=Y.fileInput;if(!me)return;var de=Y.props,ae=de.children,ie=de.onClick;ae&&ae.type==="button"&&(me.parentNode.focus(),me.parentNode.querySelector("button").blur()),me.click(),ie&&ie(le)},Y.onKeyDown=function(le){le.key==="Enter"&&Y.onClick()},Y.onFileDrop=function(le){var me=Y.props.multiple;if(le.preventDefault(),le.type==="dragover")return;if(Y.props.directory)o(Array.prototype.slice.call(le.dataTransfer.items),Y.uploadFiles,function(ae){return c(ae,Y.props.accept)});else{var de=Array.prototype.slice.call(le.dataTransfer.files).filter(function(ae){return c(ae,Y.props.accept)});me===!1&&(de=de.slice(0,1)),Y.uploadFiles(de)}},Y.uploadFiles=function(le){var me=Array.prototype.slice.call(le);me.map(function(de){return de.uid=d(),de}).forEach(function(de){Y.upload(de,me)})},Y.saveFileInput=function(le){Y.fileInput=le},K),x(Y,ne)}return s(B,[{key:"componentDidMount",value:function(){this._isMounted=!0}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,this.abort()}},{key:"upload",value:function(K,Y){var ne=this,oe=this.props;if(!oe.beforeUpload)return setTimeout(function(){return ne.post(K)},0);var _e=oe.beforeUpload(K,Y);_e&&_e.then?_e.then(function(xe){var le=Object.prototype.toString.call(xe);return le==="[object File]"||le==="[object Blob]"?ne.post(xe):ne.post(K)}).catch(function(xe){console.log(xe)}):_e!==!1&&setTimeout(function(){return ne.post(K)},0);return}},{key:"post",value:function(K){var Y=this;if(!this._isMounted)return;var ne=this.props,oe=ne.onStart,_e=ne.onProgress,xe=ne.transformFile,le=xe===void 0?function(me){return me}:xe;new Promise(function(me){var de=ne.action;return typeof de=="function"&&(de=de(K)),me(de)}).then(function(me){var de=K.uid,ae=ne.customRequest||w,ie=Promise.resolve(le(K)).then(function(q){var ue=ne.data;return typeof ue=="function"&&(ue=ue(q)),Promise.all([q,ue])}).catch(function(q){console.error(q)});ie.then(function(q){var ue=f(q,2),Z=ue[0],ee=ue[1],Ee={action:me,filename:ne.name,data:ee,file:Z,headers:ne.headers,withCredentials:ne.withCredentials,method:ne.method||"post",onProgress:_e?function(te){_e(te,K)}:null,onSuccess:function(J,X){delete Y.reqs[de],ne.onSuccess(J,K,X)},onError:function(J,X){delete Y.reqs[de],ne.onError(J,X,K)}};oe(K),Y.reqs[de]=ae(Ee)})})}},{key:"reset",value:function(){this.setState({uid:d()})}},{key:"abort",value:function(K){var Y=this.reqs;if(K){var ne=K;K&&K.uid&&(ne=K.uid),Y[ne]&&Y[ne].abort&&Y[ne].abort(),delete Y[ne]}else Object.keys(Y).forEach(function(oe){Y[oe]&&Y[oe].abort&&Y[oe].abort(),delete Y[oe]})}},{key:"render",value:function(){var K,Y=this.props,ne=Y.component,oe=Y.prefixCls,_e=Y.className,xe=Y.disabled,le=Y.id,me=Y.style,de=Y.multiple,ae=Y.accept,ie=Y.children,q=Y.directory,ue=Y.openFileDialogOnClick,Z=Y.onMouseEnter,ee=Y.onMouseLeave,Ee=t(Y,["component","prefixCls","className","disabled","id","style","multiple","accept","children","directory","openFileDialogOnClick","onMouseEnter","onMouseLeave"]),te=M()((K={},l(K,oe,!0),l(K,oe+"-disabled",xe),l(K,_e,_e),K)),J=xe?{}:{onClick:ue?this.onClick:function(){},onKeyDown:ue?this.onKeyDown:function(){},onMouseEnter:Z,onMouseLeave:ee,onDrop:this.onFileDrop,onDragOver:this.onFileDrop,tabIndex:"0"};return v.a.createElement(ne,u({},J,{className:te,role:"button",style:me}),v.a.createElement("input",u({},R(Ee),{id:le,type:"file",ref:this.saveFileInput,onClick:function($){return $.stopPropagation()},key:this.state.uid,style:{display:"none"},accept:ae,directory:q?"directory":null,webkitdirectory:q?"webkitdirectory":null,multiple:de,onChange:this.onChange})),ie)}}]),B}(N.Component),g=O,_=Object.assign||function(z){for(var B=1;B<arguments.length;B++){var k=arguments[B];for(var K in k)Object.prototype.hasOwnProperty.call(k,K)&&(z[K]=k[K])}return z},E=function(){function z(B,k){for(var K=0;K<k.length;K++){var Y=k[K];Y.enumerable=Y.enumerable||!1,Y.configurable=!0,"value"in Y&&(Y.writable=!0),Object.defineProperty(B,Y.key,Y)}}return function(B,k,K){return k&&z(B.prototype,k),K&&z(B,K),B}}();function T(z,B){if(!(z instanceof B))throw new TypeError("Cannot call a class as a function")}function L(z,B){if(!z)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return B&&(typeof B=="object"||typeof B=="function")?B:z}function I(z,B){if(typeof B!="function"&&B!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof B);z.prototype=Object.create(B&&B.prototype,{constructor:{value:z,enumerable:!1,writable:!0,configurable:!0}}),B&&(Object.setPrototypeOf?Object.setPrototypeOf(z,B):z.__proto__=B)}function P(){}var G=function(z){I(B,z);function B(){var k,K,Y,ne;T(this,B);for(var oe=arguments.length,_e=Array(oe),xe=0;xe<oe;xe++)_e[xe]=arguments[xe];return ne=(K=(Y=L(this,(k=B.__proto__||Object.getPrototypeOf(B)).call.apply(k,[this].concat(_e))),Y),Y.saveUploader=function(le){Y.uploader=le},K),L(Y,ne)}return E(B,[{key:"abort",value:function(K){this.uploader.abort(K)}},{key:"render",value:function(){return v.a.createElement(g,_({},this.props,{ref:this.saveUploader}))}}]),B}(N.Component);G.defaultProps={component:"span",prefixCls:"rc-upload",data:{},headers:{},name:"file",multipart:!1,onStart:P,onError:P,onSuccess:P,multiple:!1,beforeUpload:null,customRequest:null,withCredentials:!1,openFileDialogOnClick:!0};var W=G,H=Q.a=W},HmJG:function(F,Q,j){},IBYe:function(F,Q,j){"use strict";function N(v){return null}Q.a=N},Ib8C:function(F,Q,j){(function(N){(function(v,C){F.exports=Q=C()})(this,function(){var v=v||function(C,M){var m;if(typeof window!="undefined"&&window.crypto&&(m=window.crypto),typeof self!="undefined"&&self.crypto&&(m=self.crypto),typeof globalThis!="undefined"&&globalThis.crypto&&(m=globalThis.crypto),!m&&typeof window!="undefined"&&window.msCrypto&&(m=window.msCrypto),!m&&typeof N!="undefined"&&N.crypto&&(m=N.crypto),!m&&!0)try{m=j(4)}catch(l){}var y=function(){if(m){if(typeof m.getRandomValues=="function")try{return m.getRandomValues(new Uint32Array(1))[0]}catch(l){}if(typeof m.randomBytes=="function")try{return m.randomBytes(4).readInt32LE()}catch(l){}}throw new Error("Native crypto module could not be used to get secure random number.")},w=Object.create||function(){function l(){}return function(t){var S;return l.prototype=t,S=new l,l.prototype=null,S}}(),b={},p=b.lib={},d=p.Base=function(){return{extend:function(l){var t=w(this);return l&&t.mixIn(l),(!t.hasOwnProperty("init")||this.init===t.init)&&(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var l=this.extend();return l.init.apply(l,arguments),l},init:function(){},mixIn:function(l){for(var t in l)l.hasOwnProperty(t)&&(this[t]=l[t]);l.hasOwnProperty("toString")&&(this.toString=l.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),n=p.WordArray=d.extend({init:function(l,t){l=this.words=l||[],t!=M?this.sigBytes=t:this.sigBytes=l.length*4},toString:function(l){return(l||r).stringify(this)},concat:function(l){var t=this.words,S=l.words,x=this.sigBytes,h=l.sigBytes;if(this.clamp(),x%4)for(var R=0;R<h;R++){var O=S[R>>>2]>>>24-R%4*8&255;t[x+R>>>2]|=O<<24-(x+R)%4*8}else for(var g=0;g<h;g+=4)t[x+g>>>2]=S[g>>>2];return this.sigBytes+=h,this},clamp:function(){var l=this.words,t=this.sigBytes;l[t>>>2]&=4294967295<<32-t%4*8,l.length=C.ceil(t/4)},clone:function(){var l=d.clone.call(this);return l.words=this.words.slice(0),l},random:function(l){for(var t=[],S=0;S<l;S+=4)t.push(y());return new n.init(t,l)}}),c=b.enc={},r=c.Hex={stringify:function(l){for(var t=l.words,S=l.sigBytes,x=[],h=0;h<S;h++){var R=t[h>>>2]>>>24-h%4*8&255;x.push((R>>>4).toString(16)),x.push((R&15).toString(16))}return x.join("")},parse:function(l){for(var t=l.length,S=[],x=0;x<t;x+=2)S[x>>>3]|=parseInt(l.substr(x,2),16)<<24-x%8*4;return new n.init(S,t/2)}},i=c.Latin1={stringify:function(l){for(var t=l.words,S=l.sigBytes,x=[],h=0;h<S;h++){var R=t[h>>>2]>>>24-h%4*8&255;x.push(String.fromCharCode(R))}return x.join("")},parse:function(l){for(var t=l.length,S=[],x=0;x<t;x++)S[x>>>2]|=(l.charCodeAt(x)&255)<<24-x%4*8;return new n.init(S,t)}},o=c.Utf8={stringify:function(l){try{return decodeURIComponent(escape(i.stringify(l)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(l){return i.parse(unescape(encodeURIComponent(l)))}},u=p.BufferedBlockAlgorithm=d.extend({reset:function(){this._data=new n.init,this._nDataBytes=0},_append:function(l){typeof l=="string"&&(l=o.parse(l)),this._data.concat(l),this._nDataBytes+=l.sigBytes},_process:function(l){var t,S=this._data,x=S.words,h=S.sigBytes,R=this.blockSize,O=R*4,g=h/O;l?g=C.ceil(g):g=C.max((g|0)-this._minBufferSize,0);var _=g*R,E=C.min(_*4,h);if(_){for(var T=0;T<_;T+=R)this._doProcessBlock(x,T);t=x.splice(0,_),S.sigBytes-=E}return new n.init(t,E)},clone:function(){var l=d.clone.call(this);return l._data=this._data.clone(),l},_minBufferSize:0}),f=p.Hasher=u.extend({cfg:d.extend(),init:function(l){this.cfg=this.cfg.extend(l),this.reset()},reset:function(){u.reset.call(this),this._doReset()},update:function(l){return this._append(l),this._process(),this},finalize:function(l){l&&this._append(l);var t=this._doFinalize();return t},blockSize:512/32,_createHelper:function(l){return function(t,S){return new l.init(S).finalize(t)}},_createHmacHelper:function(l){return function(t,S){return new s.HMAC.init(l,S).finalize(t)}}}),s=b.algo={};return b}(Math);return v})}).call(this,j("IyRk"))},K3mO:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("3y9D"),j("WYAk"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.Base,m=C.WordArray,y=v.algo,w=y.MD5,b=y.EvpKDF=M.extend({cfg:M.extend({keySize:128/32,hasher:w,iterations:1}),init:function(p){this.cfg=this.cfg.extend(p)},compute:function(p,d){for(var n,c=this.cfg,r=c.hasher.create(),i=m.create(),o=i.words,u=c.keySize,f=c.iterations;o.length<u;){n&&r.update(n),n=r.update(p).finalize(d),r.reset();for(var s=1;s<f;s++)n=r.finalize(n),r.reset();i.concat(n)}return i.sigBytes=u*4,i}});v.EvpKDF=function(p,d,n){return b.create(n).compute(p,d)}}(),N.EvpKDF})},KXlV:function(F,Q,j){F.exports=j.p+"static/job.65c6034f.png"},KeDT:function(F,Q,j){F.exports={flex_box_center:"flex_box_center___3otMp",flex_space_between:"flex_space_between___2nig-",flex_box_vertical_center:"flex_box_vertical_center___3opWF",flex_box_center_end:"flex_box_center_end___1u2JP",flex_box_column:"flex_box_column___1RMsI",wrp:"wrp___-Shy4",bg:"bg___3aDMI",commonimg:"commonimg___15xnD",titlesize:"titlesize___2x92E",timesize:"timesize___3GFem",flex1:"flex1___1D3Li",buttonsize:"buttonsize___3oghG",myteam:"myteam___v6SIK",bootmdetail:"bootmdetail___3hk9v",flex6:"flex6___2iMiQ",menuItem:"menuItem___20c2q",spanprev:"spanprev___1dQoJ",spannext:"spannext___3fFnS",divwidth:"divwidth___1Dk29",receiveclick:"receiveclick___3mYYR",receivealready:"receivealready___20cCL",bkfff:"bkfff___WkCDR","ant-input":"ant-input___Zl9Xd",onediv:"onediv___2hHLH",onetop:"onetop___73xTC",towdiv:"towdiv___nqi1b",towtop:"towtop___pPhtO",threediv:"threediv___2G0u0",threetop:"threetop___2DsrB",imgradius:"imgradius___2WlXC",prize:"prize___1al1u",spanrightradius:"spanrightradius___3VHYc",bottomItem:"bottomItem___1NfPd",myTeam:"myTeam___2A-RJ",downloadpdf:"downloadpdf___1BQ_n",teamItem:"teamItem___220Fc",dash:"dash___3pxuh",modal:"modal___27esx"}},KhGG:function(F,Q,j){"use strict";j.d(Q,"a",function(){return h}),j.d(Q,"c",function(){return g});var N=j("0Owb"),v=j("miYZ"),C=j("tsqr"),M=j("oBTY"),m=j("tJVT"),y=j("PpiC"),w=j("k1fw"),b=j("9og8"),p=j("DZo9"),d=j("8z0m"),n=j("WmNS"),c=j.n(n),r=j("cDcd"),i=j.n(r),o=j("ErOA"),u=j("NFKh"),f=j.n(u),s=j("7Cbv"),l=j("9kvl"),t=j("mxV5"),S=j.n(t),x=d.a.Dragger,h=function(T){var L="bf3c199c2470cb477d907b1e0917c17b",I="5183666c72eec9e4",P=f.a.enc.Utf8.parse(L),G=f.a.enc.Utf8.parse(I),W=f.a.AES.decrypt(T,P,{iv:G,mode:f.a.mode.CBC});return W.toString(f.a.enc.Utf8)},R,O=function(){var E=Object(b.a)(c.a.mark(function T(L){var I,P,G,W,H,z,B,k,K,Y,ne;return c.a.wrap(function(_e){for(;;)switch(_e.prev=_e.next){case 0:return B=L.identifier,k=L.oldFilename,K=L.newFilename,_e.next=3,Object(o.a)("/api/buckets/get_upload_token_for_big_files.json",{method:"get"});case 3:return Y=_e.sent,Y.data=JSON.parse(h(Y.data)),ne=new S.a({endpoint:Y==null||((I=Y.data)===null||I===void 0)?void 0:I.end_point,region:Y==null||((P=Y.data)===null||P===void 0)?void 0:P.region,accessKeyId:Y==null||((G=Y.data)===null||G===void 0)?void 0:G.access_key_id,accessKeySecret:Y==null||((W=Y.data)===null||W===void 0)?void 0:W.access_key_secret,bucket:Y==null||((H=Y.data)===null||H===void 0)?void 0:H.bucket,stsToken:Y==null||((z=Y.data)===null||z===void 0)?void 0:z.security_token}),_e.abrupt("return",new Promise(function(xe,le){console.log(11111,"".concat(B,"/").concat(k),"".concat(B,"/").concat(K),Y.data),ne.copy("/".concat(B,"/").concat(k),"/".concat(B,"/").concat(K)).then(function(me){console.log("\u62F7\u8D1D\u6210\u529F",me)}).catch(function(me){console.log(me);debugger})}));case 7:case"end":return _e.stop()}},T)}));return function(L){return E.apply(this,arguments)}}(),g=function(){var E=Object(b.a)(c.a.mark(function T(L,I,P){var G,W,H,z,B,k,K,Y,ne,oe;return c.a.wrap(function(xe){for(;;)switch(xe.prev=xe.next){case 0:return I.file_name=L.name,xe.next=3,Object(o.a)("/api/buckets/get_upload_token.json",{method:"get"});case 3:return K=xe.sent,console.log("decrypt(res.data):",h(K.data)),K.data=JSON.parse(h(K.data)),Y=L.name.split("."),Y.pop(),ne=I.realFileName?Y:Object(s.a)(),oe=new S.a({endpoint:K==null||((G=K.data)===null||G===void 0)?void 0:G.end_point,region:K==null||((W=K.data)===null||W===void 0)?void 0:W.region,accessKeyId:K==null||((H=K.data)===null||H===void 0)?void 0:H.access_key_id,accessKeySecret:K==null||((z=K.data)===null||z===void 0)?void 0:z.access_key_secret,bucket:K==null||((B=K.data)===null||B===void 0)?void 0:B.bucket,stsToken:K==null||((k=K.data)===null||k===void 0)?void 0:k.security_token}),xe.abrupt("return",new Promise(function(le,me){var de;oe.multipartUpload("".concat(ne),new Blob([L],{type:L.type}),Object(w.a)(Object(w.a)({timeout:200*1e3,partSize:102400},P),{},{callback:{url:K==null||((de=K.data)===null||de===void 0)?void 0:de.callback_url,host:K==null?void 0:K.data.bucket_host,body:"bucket=${bucket}&object=${object}&etag=${etag}&size=${size}&mimeType=${mimeType}&my_var=${x:my_var}&"+Object(o.e)(I)}})).then(function(ae){var ie;L.response=(ie=ae.data)===null||ie===void 0?void 0:ie.data,le(ae==null?void 0:ae.data)}).catch(function(ae){me(ae),console.log("err:",ae)})}));case 11:case"end":return xe.stop()}},T)}));return function(L,I,P){return E.apply(this,arguments)}}(),_=function(T){var L=T.user,I=T.cancelUpload,P=Object(y.a)(T,["user","cancelUpload"]),G=Object(r.useState)([]),W=Object(m.a)(G,2),H=W[0],z=W[1],B=Object(r.useState)(),k=Object(m.a)(B,2),K=k[0],Y=k[1],ne={onRemove:function(xe){z(Object(M.a)(H.filter(function(le){return le.name!==xe.name}))),P.onChange(H.filter(function(le){return le.name!==xe.name}))},disabled:P.disabled,multiple:!0,fileList:H==null?void 0:H.map(function(_e){return _e.file}),customRequest:function(){},beforeUpload:function(){var _e=Object(b.a)(c.a.mark(function le(me){var de;return c.a.wrap(function(ie){for(;;)switch(ie.prev=ie.next){case 0:if(de=P.maxSize||1024*1024*1024*1,!H.filter(function(q){return q.name===me.name}).length){ie.next=4;break}return C.b.info("".concat(me.name,"\u5DF2\u5B58\u5728\uFF0C\u8BF7\u91CD\u65B0\u9009\u62E9")),ie.abrupt("return");case 4:if(!((me==null?void 0:me.size)>de)){ie.next=7;break}return C.b.info("\u6587\u4EF6\u8D85\u8FC7".concat(de/1024/1024/1024,"GB\uFF0C\u4E0D\u7B26\u5408\u4E0A\u4F20\u8981\u6C42")),ie.abrupt("return",!1);case 7:return H.push({name:me.name,file:me}),z(Object(M.a)(H)),P.onChange(H),ie.abrupt("return",!1);case 11:case"end":return ie.stop()}},le)}));function xe(le){return _e.apply(this,arguments)}return xe}()},oe=function(){var _e=Object(b.a)(c.a.mark(function xe(le,me){var de,ae,ie,q,ue,Z,ee,Ee,te,J;return c.a.wrap(function($){for(;;)switch($.prev=$.next){case 0:return me.file_name=le.name,ee=le.name,$.next=4,Object(o.a)("/api/buckets/get_upload_token_for_big_files.json",{method:"get"});case 4:if(Ee=$.sent,Ee.data=JSON.parse(h(Ee.data)),!((Ee==null?void 0:Ee.status)!==0)){$.next=12;break}return H[H.findIndex(function(ge){return ge.name===ee})].status="error",H[H.findIndex(function(ge){return ge.name===ee})].file.status="error",P.onChange(H),C.b.warn("\u4E0A\u4F20\u5931\u8D25\uFF0C\u8BF7\u91CD\u65B0\u5C1D\u8BD5"),$.abrupt("return");case 12:return K=new S.a({endpoint:Ee==null||((de=Ee.data)===null||de===void 0)?void 0:de.end_point,region:Ee==null||((ae=Ee.data)===null||ae===void 0)?void 0:ae.region,accessKeyId:Ee==null||((ie=Ee.data)===null||ie===void 0)?void 0:ie.access_key_id,accessKeySecret:Ee==null||((q=Ee.data)===null||q===void 0)?void 0:q.access_key_secret,bucket:Ee==null||((ue=Ee.data)===null||ue===void 0)?void 0:ue.bucket,stsToken:Ee==null||((Z=Ee.data)===null||Z===void 0)?void 0:Z.security_token}),console.log(le,"file"),Y(K),te=le.name.split("."),te.pop(),J=me.realFileName?te:Object(s.a)(),$.abrupt("return",new Promise(function(ge,fe){try{var Te;K.multipartUpload("".concat(P.identifier,"/").concat(J).concat(ee.indexOf(".")>-1?"."+ee.split(".").pop():""),new Blob([le.file],{type:le.file.type}),{timeout:3600*1e3,partSize:1002400,progress:function(Xe,Ye,rt){try{console.log("\u8FDB\u5EA6",Xe,Ye,rt);var at=H.findIndex(function(ot){return ot.name===ee});H[at].file.percent=Xe*100,H[at].tempCheckpoint=Ye,z(Object(M.a)(H))}catch(ot){}},checkpoint:H[H.findIndex(function(ze){return ze.name===ee})].tempCheckpoint,callback:{customValue:{id:ee+""},url:Ee==null||((Te=Ee.data)===null||Te===void 0)?void 0:Te.callback_url,host:Ee==null?void 0:Ee.data.bucket_host,body:"bucket=${bucket}&object=${object}&etag=${etag}&size=${size}&mimeType=${mimeType}&my_var=${x:my_var}&"+Object(o.e)(me)}}).then(function(ze){var Xe,Ye=H.findIndex(function(Se){return Se.name===ee}),rt="done";if(((Xe=ze.data)===null||Xe===void 0?void 0:Xe.status)===0){var at;le.response=(at=ze.data)===null||at===void 0?void 0:at.data;var ot=H.findIndex(function(Se){return Se.name===ee});H[ot].status="done",H[ot].file.status="done"}else{var Pe;C.b.warn((Pe=ze.data)===null||Pe===void 0?void 0:Pe.message),rt="error"}H[Ye].status=rt,H[Ye].file.status=rt,P.onChange(H),ge(ze==null?void 0:ze.data)}).catch(function(ze){H[H.findIndex(function(Xe){return Xe.name===ee})].status="error",H[H.findIndex(function(Xe){return Xe.name===ee})].file.status="error",C.b.warn("\u4E0A\u4F20\u5931\u8D25\uFF0C\u8BF7\u91CD\u65B0\u5C1D\u8BD5"),z(Object(M.a)(H)),P.onChange(H),fe(ze),console.log("err:",ze)})}catch(ze){}}));case 19:case"end":return $.stop()}},xe)}));return function(le,me){return _e.apply(this,arguments)}}();return Object(r.useEffect)(function(){H.every(function(_e){return _e==="done"||_e==="error"})&&P.onComplete(H)},[H]),Object(r.useEffect)(function(){if(I){var _e;(_e=K)===null||_e===void 0||_e.cancel()}},[I]),Object(r.useEffect)(function(){P.uploading&&H.map(function(){var _e=Object(b.a)(c.a.mark(function xe(le){var me,de;return c.a.wrap(function(ie){for(;;)switch(ie.prev=ie.next){case 0:if(!((!le.status||le.status==="error")&&!I)){ie.next=6;break}return le.status="uploading",le.file.status="uploading",ie.next=5,oe(le,{login:L==null||((me=L.userInfo)===null||me===void 0)?void 0:me.login,container_type:P.container_type,container_id:P.container_id,description:P.description,realFileName:P.realFileName});case 5:de=ie.sent;case 6:case"end":return ie.stop()}},xe)}));return function(xe){return _e.apply(this,arguments)}}())},[P.uploading]),i.a.createElement(x,Object(N.a)({},ne,{height:P.height,className:P.className}),i.a.createElement("p",{className:"ant-upload-hint"},P.text||"\u62D6\u62FD\u6587\u4EF6\u6216\u8005\u70B9\u51FB\u4E0A\u4F20"))};Q.b=Object(l.a)(function(E){var T=E.loading,L=E.globalSetting,I=E.user;return{globalSetting:L,loading:T.models.competitions,user:I}})(_)},KmYQ:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.pad.ZeroPadding={pad:function(v,C){var M=C*4;v.clamp(),v.sigBytes+=M-(v.sigBytes%M||M)},unpad:function(v){for(var C=v.words,M=v.sigBytes-1,M=v.sigBytes-1;M>=0;M--)if(C[M>>>2]>>>24-M%4*8&255){v.sigBytes=M+1;break}}},N.pad.ZeroPadding})},LdHM:function(F,Q,j){"use strict";j.d(Q,"b",function(){return t}),j.d(Q,"a",function(){return x});var N=j("1OyB"),v=j("vuIU"),C=j("Ji7U"),M=j("LK+K"),m=j("cDcd"),y=j("rePB"),w=j("Ff2n"),b=j("ODXe"),p=j("4IlW"),d=j("bX4T"),n=j("YrtM"),c=j("TSYQ"),r=j.n(c),i=j("+nKL"),o=j("8OUc"),u=function(K,Y){var ne=K.prefixCls,oe=K.id,_e=K.flattenOptions,xe=K.childrenAsData,le=K.values,me=K.searchValue,de=K.multiple,ae=K.defaultActiveFirstOption,ie=K.height,q=K.itemHeight,ue=K.notFoundContent,Z=K.open,ee=K.menuItemSelectedIcon,Ee=K.virtual,te=K.onSelect,J=K.onToggleOpen,X=K.onActiveValue,$=K.onScroll,ge=K.onMouseEnter,fe="".concat(ne,"-item"),Te=Object(n.a)(function(){return _e},[Z,_e],function(et,Me){return Me[0]&&et[1]!==Me[1]}),ze=m.useRef(null),Xe=function(Me){Me.preventDefault()},Ye=function(Me){ze.current&&ze.current.scrollTo({index:Me})},rt=function(Me){for(var Ce=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,Re=Te.length,pe=0;pe<Re;pe+=1){var ye=(Me+pe*Ce+Re)%Re,we=Te[ye],Ie=we.group,ke=we.data;if(!Ie&&!ke.disabled)return ye}return-1},at=m.useState(function(){return rt(0)}),ot=Object(b.a)(at,2),Pe=ot[0],Se=ot[1],Je=function(Me){Se(Me);var Ce=Te[Me];if(!Ce){X(null,-1);return}X(Ce.data.value,Me)};m.useEffect(function(){Je(ae!==!1?rt(0):-1)},[Te.length,me]),m.useEffect(function(){var et=setTimeout(function(){if(!de&&Z&&le.size===1){var Me=Array.from(le)[0],Ce=Te.findIndex(function(Re){var pe=Re.data;return pe.value===Me});Je(Ce),Ye(Ce)}});return function(){return clearTimeout(et)}},[Z]);var nt=function(Me){Me!==void 0&&te(Me,{selected:!le.has(Me)}),de||J(!1)};if(m.useImperativeHandle(Y,function(){return{onKeyDown:function(Me){var Ce=Me.which;switch(Ce){case p.a.UP:case p.a.DOWN:{var Re=0;if(Ce===p.a.UP?Re=-1:Ce===p.a.DOWN&&(Re=1),Re!==0){var pe=rt(Pe+Re,Re);Ye(pe),Je(pe)}break}case p.a.ENTER:{var ye=Te[Pe];ye&&!ye.data.disabled?nt(ye.data.value):nt(void 0),Z&&Me.preventDefault();break}case p.a.ESC:J(!1)}},onKeyUp:function(){},scrollTo:function(Me){Ye(Me)}}}),Te.length===0)return m.createElement("div",{role:"listbox",id:"".concat(oe,"_list"),className:"".concat(fe,"-empty"),onMouseDown:Xe},ue);function We(et){var Me=Te[et];if(!Me)return null;var Ce=Me.data||{},Re=Ce.value,pe=Ce.label,ye=Ce.children,we=Object(d.a)(Ce,!0),Ie=xe?ye:pe;return Me?m.createElement("div",Object.assign({"aria-label":typeof Ie=="string"?Ie:null},we,{key:et,role:"option",id:"".concat(oe,"_list_").concat(et),"aria-selected":le.has(Re)}),Re):null}return m.createElement(m.Fragment,null,m.createElement("div",{role:"listbox",id:"".concat(oe,"_list"),style:{height:0,width:0,overflow:"hidden"}},We(Pe-1),We(Pe),We(Pe+1)),m.createElement(i.a,{itemKey:"key",ref:ze,data:Te,height:ie,itemHeight:q,fullHeight:!1,onMouseDown:Xe,onScroll:$,virtual:Ee,onMouseEnter:ge},function(et,Me){var Ce,Re=et.group,pe=et.groupOption,ye=et.data,we=ye.label,Ie=ye.key;if(Re)return m.createElement("div",{className:r()(fe,"".concat(fe,"-group"))},we!==void 0?we:Ie);var ke=ye.disabled,Ve=ye.value,ut=ye.title,ct=ye.children,Lt=ye.style,Dt=ye.className,Er=Object(w.a)(ye,["disabled","value","title","children","style","className"]),rr=le.has(Ve),xt="".concat(fe,"-option"),kr=r()(fe,xt,Dt,(Ce={},Object(y.a)(Ce,"".concat(xt,"-grouped"),pe),Object(y.a)(Ce,"".concat(xt,"-active"),Pe===Me&&!ke),Object(y.a)(Ce,"".concat(xt,"-disabled"),ke),Object(y.a)(Ce,"".concat(xt,"-selected"),rr),Ce)),Mr=xe?ct:we,Ur=!ee||typeof ee=="function"||rr;return m.createElement("div",Object.assign({},Er,{"aria-selected":rr,className:kr,title:ut,onMouseMove:function(){if(Pe===Me||ke)return;Je(Me)},onClick:function(){ke||nt(Ve)},style:Lt}),m.createElement("div",{className:"".concat(xt,"-content")},Mr||Ve),m.isValidElement(ee)||rr,Ur&&m.createElement(o.a,{className:"".concat(fe,"-option-state"),customizeIcon:ee,customizeIconProps:{isSelected:rr}},rr?"\u2713":null))}))},f=m.forwardRef(u);f.displayName="OptionList";var s=f,l=function(){return null};l.isSelectOption=!0;var t=l,S=function(){return null};S.isSelectOptGroup=!0;var x=S,h=j("VTBJ"),R=j("Zm9Q");function O(k){var K=k.key,Y=k.props,ne=Y.children,oe=Y.value,_e=Object(w.a)(Y,["children","value"]);return Object(h.a)({key:K,value:oe!==void 0?oe:K,children:ne},_e)}function g(k){var K=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return Object(R.a)(k).map(function(Y,ne){if(!m.isValidElement(Y)||!Y.type)return null;var oe=Y.type.isSelectOptGroup,_e=Y.key,xe=Y.props,le=xe.children,me=Object(w.a)(xe,["children"]);return K||!oe?O(Y):Object(h.a)(Object(h.a)({key:"__RC_SELECT_GRP__".concat(_e===null?ne:_e,"__"),label:_e},me),{},{options:g(le)})}).filter(function(Y){return Y})}var _=j("2Qr1"),E=j("qNPg"),T=j("U8pU"),L=j("Kwbf"),I=j("WKfj");function P(k){var K=k.mode,Y=k.options,ne=k.children,oe=k.backfill,_e=k.allowClear,xe=k.placeholder,le=k.getInputElement,me=k.showSearch,de=k.onSearch,ae=k.defaultOpen,ie=k.autoFocus,q=k.labelInValue,ue=k.value,Z=k.inputValue,ee=k.optionLabelProp,Ee=K==="multiple"||K==="tags",te=me!==void 0?me:Ee||K==="combobox",J=Y||g(ne);if(Object(L.a)(K!=="tags"||J.every(function(fe){return!fe.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),K==="tags"||K==="combobox"){var X=J.some(function(fe){return fe.options?fe.options.some(function(Te){return typeof("value"in Te?Te.value:Te.key)=="number"}):typeof("value"in fe?fe.value:fe.key)=="number"});Object(L.a)(!X,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(Object(L.a)(K!=="combobox"||!ee,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),Object(L.a)(K==="combobox"||!oe,"`backfill` only works with `combobox` mode."),Object(L.a)(K==="combobox"||!le,"`getInputElement` only work with `combobox` mode."),Object(L.b)(K!=="combobox"||!le||!_e||!xe,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),de&&!te&&K!=="combobox"&&K!=="tags"&&Object(L.a)(!1,"`onSearch` should work with `showSearch` instead of use alone."),Object(L.b)(!ae||ie,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),ue!=null){var $=Object(I.d)(ue);Object(L.a)(!q||$.every(function(fe){return Object(T.a)(fe)==="object"&&("key"in fe||"value"in fe)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),Object(L.a)(!Ee||Array.isArray(ue),"`value` should be array when `mode` is `multiple` or `tags`")}if(ne){var ge=null;Object(R.a)(ne).some(function(fe){if(!m.isValidElement(fe)||!fe.type)return!1;var Te=fe.type;if(Te.isSelectOption)return!1;if(Te.isSelectOptGroup){var ze=Object(R.a)(fe.props.children).every(function(Xe){return!m.isValidElement(Xe)||!fe.type||Xe.type.isSelectOption?!0:(ge=Xe.type,!1)});return!ze}return ge=Te,!0}),ge&&Object(L.a)(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(ge.displayName||ge.name||ge,"`.")),Object(L.a)(Z===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}var G=P,W=Object(E.a)({prefixCls:"rc-select",components:{optionList:s},convertChildrenToData:g,flattenOptions:_.d,getLabeledValue:_.e,filterOptions:_.b,isValueDisabled:_.g,findValueOption:_.c,warningProps:G,fillOptionsWithMissingValue:_.a}),H=function(k){Object(C.a)(Y,k);var K=Object(M.a)(Y);function Y(){var ne;return Object(N.a)(this,Y),ne=K.apply(this,arguments),ne.selectRef=m.createRef(),ne.focus=function(){ne.selectRef.current.focus()},ne.blur=function(){ne.selectRef.current.blur()},ne}return Object(v.a)(Y,[{key:"render",value:function(){return m.createElement(W,Object.assign({ref:this.selectRef},this.props))}}]),Y}(m.Component);H.Option=t,H.OptGroup=x;var z=H,B=Q.c=z},M8RZ:function(F,Q,j){"use strict";j.d(Q,"a",function(){return p});var N=j("fWQN"),v=j("mtLc"),C=j("yKVA"),M=j("879j"),m=j("cDcd"),y=j.n(m),w=j("faye"),b=j.n(w),p=function(d){Object(C.a)(c,d);var n=Object(M.a)(c);function c(r){var i;Object(N.a)(this,c),i=n.call(this,r);var o=window.document;return i.node=o.createElement("div"),o.body.appendChild(i.node),i}return Object(v.a)(c,[{key:"render",value:function(){var i=this.props.children;return Object(w.createPortal)(i,this.node)}},{key:"componentWillUnmount",value:function(){window.document.body.removeChild(this.node)}}]),c}(y.a.Component)},MlIO:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(v){var C=N,M=C.lib,m=M.Base,y=M.WordArray,w=C.x64={},b=w.Word=m.extend({init:function(d,n){this.high=d,this.low=n}}),p=w.WordArray=m.extend({init:function(d,n){d=this.words=d||[],n!=v?this.sigBytes=n:this.sigBytes=d.length*8},toX32:function(){for(var d=this.words,n=d.length,c=[],r=0;r<n;r++){var i=d[r];c.push(i.high),c.push(i.low)}return y.create(c,this.sigBytes)},clone:function(){for(var d=m.clone.call(this),n=d.words=this.words.slice(0),c=n.length,r=0;r<c;r++)n[r]=n[r].clone();return d}})}(),N})},NFKh:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("MlIO"),j("F+F2"),j("qM6L"),j("ETIr"),j("wbyO"),j("cv67"),j("3y9D"),j("lPiR"),j("GRuw"),j("1uat"),j("uGsb"),j("5hvy"),j("ELcG"),j("WYAk"),j("e7zE"),j("K3mO"),j("OLod"),j("ALsQ"),j("9OqN"),j("qu8F"),j("S6kV"),j("gb/T"),j("qBft"),j("oRuE"),j("jO9C"),j("KmYQ"),j("uGxW"),j("bQjk"),j("wZgz"),j("pA7S"),j("w7YG"),j("E4JC"),j("PVpz"))})(this,function(N){return N})},NLgs:function(F,Q,j){"use strict";j.d(Q,"e",function(){return t}),j.d(Q,"f",function(){return S}),j.d(Q,"d",function(){return h}),j.d(Q,"c",function(){return R}),j.d(Q,"a",function(){return O}),j.d(Q,"b",function(){return g});var N=j("miYZ"),v=j("tsqr"),C=j("9og8"),M=j("2qtc"),m=j("kLXV"),y=j("WmNS"),w=j.n(y),b=j("cDcd"),p=j.n(b),d=j("9kvl"),n=j("xKgJ"),c=j("1vsH"),r=j("RCxd"),i=j("mOS8"),o=j.n(i),u=j("1ZF9"),f=j.n(u),s=j("NoGO"),l=j.n(s),t=function(E){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return!!(S(E)&&x(T))},S=function(E){return Object(n.p)()?!0:(E({type:"user/showPopLogin",payload:{showPopLogin:!0,showClosable:!0}}),!1)},x=function(){var E,T=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,L=Object(d.c)()._store.getState(),I=L.user;return(E=I.userInfo)!==null&&E!==void 0&&E.profile_completed?!0:(m.a.confirm({title:"\u63D0\u793A",width:530,centered:!0,content:T?"\u6309\u7167\u6709\u5173\u653F\u7B56\u89C4\u5B9A\uFF0C\u7279\u6B8A\u5B9E\u9A8C\u9700\u8981\u5148\u7ED1\u5B9A\u624B\u673A\u53F7\u624D\u80FD\u4F7F\u7528\uFF0C\u8BF7\u5148\u7ED1\u5B9A\u624B\u673A\u53F7\u7801":"\u60A8\u9700\u8981\u53BB\u5B8C\u5584\u60A8\u7684\u4E2A\u4EBA\u8D44\u6599\uFF0C\u624D\u80FD\u4F7F\u7528\u6B64\u529F\u80FD",okText:"\u7ACB\u5373\u5B8C\u5584",cancelText:"\u7A0D\u540E\u5B8C\u5584",onOk:function(){d.d.push("/account/profile/edit")}}),!1)},h=function(){var E,T=Object(d.c)()._store.getState(),L=T.user;return(E=L.userInfo)!==null&&E!==void 0&&E.professional_certification?!0:(m.a.confirm({title:"\u63D0\u793A",centered:!0,content:p.a.createElement("div",{className:"tc"},"\u60A8\u9700\u8981\u53BB\u5B8C\u6210\u60A8\u7684\u804C\u4E1A\u8BA4\u8BC1\uFF0C\u624D\u80FD\u4F7F\u7528\u6B64\u529F\u80FD"),okText:"\u7ACB\u5373\u5B8C\u5584",cancelText:"\u7A0D\u540E\u5B8C\u5584",onOk:function(){Object(c.U)("/account/certification")}}),!1)},R=function(){return Object(n.a)()?!0:(m.a.warning({centered:!0,width:530,title:"\u63D0\u793A",content:p.a.createElement("div",{className:"tc",style:{marginLeft:-38}},p.a.createElement("p",null,"\u626B\u7801\u52A0\u5934\u6B4C\u52A9\u6559\uFF0C\u7533\u8BF7\u64CD\u4F5C\u6743\u9650"),p.a.createElement("img",{src:l.a,width:200})),okText:"\u6211\u77E5\u9053\u4E86",maskClosable:!0}),!1)},O=function(E,T){return E?!0:(m.a.confirm({centered:!0,zIndex:1e4,width:530,title:"\u63D0\u793A",content:p.a.createElement("div",null,p.a.createElement("p",null,T||"\u8BE5\u5B9E\u8DF5\u8D44\u6E90\u9700\u6388\u6743\u540E\u624D\u53EF\u4F7F\u7528\u3002 \u60A8\u53EF\u4EE5\u5728QQ\u670D\u52A1\u7FA4\u5411\u7BA1\u7406\u5458\u7533\u8BF7\uFF0C\u83B7\u5F97\u7EE7\u7EED\u64CD\u4F5C\u7684\u6743\u9650\u3002"),p.a.createElement("div",{style:{marginLeft:"110px"}},p.a.createElement("img",{src:f.a,width:200}),p.a.createElement("div",{style:{marginLeft:"35px"}},"\u7FA4\u53F7\uFF1A","714336072"))),okText:"\u7ACB\u5373\u8054\u7CFB",cancelText:"\u53D6\u6D88",onOk:function(){Object(c.U)("https://qm.qq.com/cgi-bin/qm/qr?k=tIyDPXUtE0yEk-MOJxhH55lTUJS-nYAM&jump_from=webapi")}}),!1)},g=function(E){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",L=Object(d.c)()._store.getState(),I=L.shixunsDetail.detail;return(I==null?void 0:I.public)===2||(I==null?void 0:I.public)===1||(I==null?void 0:I.shixun_status)===3?(m.a.info({centered:!0,icon:p.a.createElement(r.a,{style:{color:"#faad14"}}),width:460,title:"\u63D0\u793A",content:p.a.createElement("div",{className:"tc",style:{marginLeft:-38}},p.a.createElement("div",{style:{display:"flex",flexDirection:"column",alignItems:"flex-start",paddingLeft:38,margin:"12px 0"}},p.a.createElement("span",null,"\u8BE5\u5B9E\u8DF5\u9879\u76EE\u7684\u72B6\u6001\u4E3A",(I==null?void 0:I.public)===2?"\u5DF2\u516C\u5F00":(I==null?void 0:I.public)===1?"\u5F85\u5BA1\u6838":"\u5DF2\u5173\u95ED","\uFF0C",T,"\u3002"),p.a.createElement("p",null,"\u5982\u6709\u9700\u8981\uFF0C\u8BF7\u8054\u7CFB\u5E73\u53F0\u7BA1\u7406\u5458\u8FDB\u884C\u6280\u672F\u652F\u6301\u3002")),p.a.createElement("img",{style:{border:"4px solid #0152d9",borderRadius:"4px"},src:o.a,alt:"\u4E8C\u7EF4\u7801",width:160})),okText:"\u6211\u77E5\u9053\u4E86"}),!0):(I==null?void 0:I.shixun_status)===2?(m.a.confirm({centered:!0,icon:p.a.createElement(r.a,null),title:"\u63D0\u793A",content:p.a.createElement("div",null,p.a.createElement("span",null,"\u8BE5\u5B9E\u8DF5\u9879\u76EE\u5DF2\u53D1\u5E03\uFF0C",T,"\u3002"),p.a.createElement("br",null),p.a.createElement("span",null,"\u5982\u6709\u9700\u8981\uFF0C\u60A8\u53EF\u4EE5\u64A4\u9500\u53D1\u5E03\u540E\uFF0C\u518D\u8FDB\u884C\u64CD\u4F5C\u3002")),okText:"\u64A4\u9500\u53D1\u5E03",cancelText:"\u53D6\u6D88",onOk:function(){m.a.confirm({width:440,centered:!0,icon:p.a.createElement(r.a,{style:{color:"#faad14"}}),title:"\u63D0\u793A",content:"\u64A4\u9500\u53D1\u5E03\u540E\uFF0C\u5B66\u5458\u5C06\u65E0\u6CD5\u8FDB\u884C\u7EC3\u4E60\u3002\u662F\u5426\u786E\u8BA4\u64A4\u9500\u53D1\u5E03\uFF1F",okText:"\u786E\u5B9A\u64A4\u9500\u53D1\u5E03",cancelText:"\u53D6\u6D88",onOk:function(){var G=Object(C.a)(w.a.mark(function H(){var z;return w.a.wrap(function(k){for(;;)switch(k.prev=k.next){case 0:return k.next=2,E({type:"shixunsDetail/cancelRelease",payload:{id:I==null?void 0:I.identifier}});case 2:z=k.sent,z.status!==401&&(v.b.success("\u64A4\u9500\u53D1\u5E03\u6210\u529F\u3002\u5B9E\u8BAD\u56DE\u5230\u672A\u53D1\u5E03\u7684\u72B6\u6001\u3002"),E({type:"shixunsDetail/getShixunsDetail",payload:{id:I==null?void 0:I.identifier}}),E({type:"practiceSetting/getCommonData",payload:{id:I==null?void 0:I.identifier}}));case 4:case"end":return k.stop()}},H)}));function W(){return G.apply(this,arguments)}return W}()})}}),!0):!1}},NnUe:function(F,Q,j){F.exports={modal:"modal___sZeHv",colorBlue:"colorBlue___3FmfG",formWrap:"formWrap___3YEqH",flexRow:"flexRow___37Sa0",flexColumn:"flexColumn___1ykGy",example:"example___7mYRk",exampleImg:"exampleImg___UGH9Y",colorOrange:"colorOrange___1IJLa",uploader:"uploader___3f2Sm",uploadImg:"uploadImg___3WCoA",imageTip:"imageTip___FhklW",uploadTipIcon:"uploadTipIcon___2YZJx",uploadTip:"uploadTip___1eikX",color05101a:"color05101a___1Nuwt",viewLargerImg:"viewLargerImg___Ek8jW",footerWrap:"footerWrap___F9F0q",note:"note___1U6xc",schoolHintWrap:"schoolHintWrap___31S22",colorCDCDCD:"colorCDCDCD___1KqvR",color0152d9:"color0152d9___1YXxu"}},NoGO:function(F,Q,j){F.exports=j.p+"static/newqrcode.9bae6615.png"},NvD2:function(F,Q,j){"use strict";j.d(Q,"a",function(){return y});var N=j("Kwbf");function v(w,b){var p=new Set;return w.forEach(function(d){b.has(d)||p.add(d)}),p}function C(w){var b=w||{},p=b.disabled,d=b.disableCheckbox,n=b.checkable;return!!(p||d)||n===!1}function M(w,b,p,d){for(var n=new Set(w),c=new Set,r=0;r<=p;r+=1){var i=b.get(r)||new Set;i.forEach(function(s){var l=s.key,t=s.node,S=s.children,x=S===void 0?[]:S;n.has(l)&&!d(t)&&x.filter(function(h){return!d(h.node)}).forEach(function(h){n.add(h.key)})})}for(var o=new Set,u=p;u>=0;u-=1){var f=b.get(u)||new Set;f.forEach(function(s){var l=s.parent,t=s.node;if(d(t)||!s.parent||o.has(s.parent.key))return;if(d(s.parent.node)){o.add(l.key);return}var S=!0,x=!1;(l.children||[]).filter(function(h){return!d(h.node)}).forEach(function(h){var R=h.key,O=n.has(R);S&&!O&&(S=!1),!x&&(O||c.has(R))&&(x=!0)}),S&&n.add(l.key),x&&c.add(l.key),o.add(l.key)})}return{checkedKeys:Array.from(n),halfCheckedKeys:Array.from(v(c,n))}}function m(w,b,p,d,n){for(var c=new Set(w),r=new Set(b),i=0;i<=d;i+=1){var o=p.get(i)||new Set;o.forEach(function(l){var t=l.key,S=l.node,x=l.children,h=x===void 0?[]:x;!c.has(t)&&!r.has(t)&&!n(S)&&h.filter(function(R){return!n(R.node)}).forEach(function(R){c.delete(R.key)})})}r=new Set;for(var u=new Set,f=d;f>=0;f-=1){var s=p.get(f)||new Set;s.forEach(function(l){var t=l.parent,S=l.node;if(n(S)||!l.parent||u.has(l.parent.key))return;if(n(l.parent.node)){u.add(t.key);return}var x=!0,h=!1;(t.children||[]).filter(function(R){return!n(R.node)}).forEach(function(R){var O=R.key,g=c.has(O);x&&!g&&(x=!1),!h&&(g||r.has(O))&&(h=!0)}),x||c.delete(t.key),h&&r.add(t.key),u.add(t.key)})}return{checkedKeys:Array.from(c),halfCheckedKeys:Array.from(v(r,c))}}function y(w,b,p,d){var n=[],c;d?c=d:c=C;var r=new Set(w.filter(function(f){var s=!!p[f];return s||n.push(f),s})),i=new Map,o=0;Object.keys(p).forEach(function(f){var s=p[f],l=s.level,t=i.get(l);t||(t=new Set,i.set(l,t)),t.add(s),o=Math.max(o,l)}),Object(N.a)(!n.length,"Tree missing follow keys: ".concat(n.slice(0,100).map(function(f){return"'".concat(f,"'")}).join(", ")));var u;return b===!0?u=M(r,i,o,c):u=m(r,b.halfCheckedKeys,i,o,c),u}},OLod:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("K3mO"))})(this,function(N){N.lib.Cipher||function(v){var C=N,M=C.lib,m=M.Base,y=M.WordArray,w=M.BufferedBlockAlgorithm,b=C.enc,p=b.Utf8,d=b.Base64,n=C.algo,c=n.EvpKDF,r=M.Cipher=w.extend({cfg:m.extend(),createEncryptor:function(E,T){return this.create(this._ENC_XFORM_MODE,E,T)},createDecryptor:function(E,T){return this.create(this._DEC_XFORM_MODE,E,T)},init:function(E,T,L){this.cfg=this.cfg.extend(L),this._xformMode=E,this._key=T,this.reset()},reset:function(){w.reset.call(this),this._doReset()},process:function(E){return this._append(E),this._process()},finalize:function(E){E&&this._append(E);var T=this._doFinalize();return T},keySize:128/32,ivSize:128/32,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function E(T){return typeof T=="string"?_:R}return function(T){return{encrypt:function(L,I,P){return E(I).encrypt(T,L,I,P)},decrypt:function(L,I,P){return E(I).decrypt(T,L,I,P)}}}}()}),i=M.StreamCipher=r.extend({_doFinalize:function(){var E=this._process(!0);return E},blockSize:1}),o=C.mode={},u=M.BlockCipherMode=m.extend({createEncryptor:function(E,T){return this.Encryptor.create(E,T)},createDecryptor:function(E,T){return this.Decryptor.create(E,T)},init:function(E,T){this._cipher=E,this._iv=T}}),f=o.CBC=function(){var E=u.extend();E.Encryptor=E.extend({processBlock:function(L,I){var P=this._cipher,G=P.blockSize;T.call(this,L,I,G),P.encryptBlock(L,I),this._prevBlock=L.slice(I,I+G)}}),E.Decryptor=E.extend({processBlock:function(L,I){var P=this._cipher,G=P.blockSize,W=L.slice(I,I+G);P.decryptBlock(L,I),T.call(this,L,I,G),this._prevBlock=W}});function T(L,I,P){var G,W=this._iv;W?(G=W,this._iv=v):G=this._prevBlock;for(var H=0;H<P;H++)L[I+H]^=G[H]}return E}(),s=C.pad={},l=s.Pkcs7={pad:function(E,T){for(var L=T*4,I=L-E.sigBytes%L,P=I<<24|I<<16|I<<8|I,G=[],W=0;W<I;W+=4)G.push(P);var H=y.create(G,I);E.concat(H)},unpad:function(E){var T=E.words[E.sigBytes-1>>>2]&255;E.sigBytes-=T}},t=M.BlockCipher=r.extend({cfg:r.cfg.extend({mode:f,padding:l}),reset:function(){var E;r.reset.call(this);var T=this.cfg,L=T.iv,I=T.mode;this._xformMode==this._ENC_XFORM_MODE?E=I.createEncryptor:(E=I.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==E?this._mode.init(this,L&&L.words):(this._mode=E.call(I,this,L&&L.words),this._mode.__creator=E)},_doProcessBlock:function(E,T){this._mode.processBlock(E,T)},_doFinalize:function(){var E,T=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(T.pad(this._data,this.blockSize),E=this._process(!0)):(E=this._process(!0),T.unpad(E)),E},blockSize:128/32}),S=M.CipherParams=m.extend({init:function(E){this.mixIn(E)},toString:function(E){return(E||this.formatter).stringify(this)}}),x=C.format={},h=x.OpenSSL={stringify:function(E){var T,L=E.ciphertext,I=E.salt;return I?T=y.create([1398893684,1701076831]).concat(I).concat(L):T=L,T.toString(d)},parse:function(E){var T,L=d.parse(E),I=L.words;return I[0]==1398893684&&I[1]==1701076831&&(T=y.create(I.slice(2,4)),I.splice(0,4),L.sigBytes-=16),S.create({ciphertext:L,salt:T})}},R=M.SerializableCipher=m.extend({cfg:m.extend({format:h}),encrypt:function(E,T,L,I){I=this.cfg.extend(I);var P=E.createEncryptor(L,I),G=P.finalize(T),W=P.cfg;return S.create({ciphertext:G,key:L,iv:W.iv,algorithm:E,mode:W.mode,padding:W.padding,blockSize:E.blockSize,formatter:I.format})},decrypt:function(E,T,L,I){I=this.cfg.extend(I),T=this._parse(T,I.format);var P=E.createDecryptor(L,I).finalize(T.ciphertext);return P},_parse:function(E,T){return typeof E=="string"?T.parse(E,this):E}}),O=C.kdf={},g=O.OpenSSL={execute:function(E,T,L,I){I||(I=y.random(64/8));var P=c.create({keySize:T+L}).compute(E,I),G=y.create(P.words.slice(T),L*4);return P.sigBytes=T*4,S.create({key:P,iv:G,salt:I})}},_=M.PasswordBasedCipher=R.extend({cfg:R.cfg.extend({kdf:g}),encrypt:function(E,T,L,I){I=this.cfg.extend(I);var P=I.kdf.execute(L,E.keySize,E.ivSize);I.iv=P.iv;var G=R.encrypt.call(this,E,T,P.key,I);return G.mixIn(P),G},decrypt:function(E,T,L,I){I=this.cfg.extend(I),T=this._parse(T,I.format);var P=I.kdf.execute(L,E.keySize,E.ivSize,T.salt);I.iv=P.iv;var G=R.decrypt.call(this,E,T,P.key,I);return G}})}()})},OZM5:function(F,Q,j){"use strict";j.d(Q,"b",function(){return d}),j.d(Q,"a",function(){return n}),j.d(Q,"k",function(){return c}),j.d(Q,"h",function(){return r}),j.d(Q,"i",function(){return i}),j.d(Q,"g",function(){return o}),j.d(Q,"c",function(){return u}),j.d(Q,"d",function(){return f}),j.d(Q,"j",function(){return t}),j.d(Q,"e",function(){return S}),j.d(Q,"f",function(){return x});var N=j("KQm4"),v=j("U8pU"),C=j("Ff2n"),M=j("cDcd"),m=j.n(M),y=j("Kwbf"),w=j("WaYH"),b=.25,p=2;function d(h,R){var O=h.slice(),g=O.indexOf(R);return g>=0&&O.splice(g,1),O}function n(h,R){var O=h.slice();return O.indexOf(R)===-1&&O.push(R),O}function c(h){return h.split("-")}function r(h,R){return"".concat(h,"-").concat(R)}function i(h){return h&&h.type&&h.type.isTreeNode}function o(h,R){var O=[h],g=R[h];function _(){var E=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];E.forEach(function(T){var L=T.key,I=T.children;O.push(L),_(I)})}return _(g.children),O}function u(h,R){var O=h.clientY,g=R.selectHandle.getBoundingClientRect(),_=g.top,E=g.bottom,T=g.height,L=Math.max(T*b,p);return O<=_+L?-1:O>=E-L?1:0}function f(h,R){if(!h)return;var O=R.multiple;return O?h.slice():h.length?[h[0]]:h}var s=function(R){return R};function l(h,R){if(!h)return[];var O=R||{},g=O.processProps,_=g===void 0?s:g,E=Array.isArray(h)?h:[h];return E.map(function(T){var L=T.children,I=Object(C.a)(T,["children"]),P=l(L,R);return m.a.createElement(w.a,Object.assign({},_(I)),P)})}function t(h){if(!h)return null;var R;if(Array.isArray(h))R={checkedKeys:h,halfCheckedKeys:void 0};else if(Object(v.a)(h)==="object")R={checkedKeys:h.checked||void 0,halfCheckedKeys:h.halfChecked||void 0};else return Object(y.a)(!1,"`checkedKeys` is not an array or an object"),null;return R}function S(h,R){var O=new Set;function g(_){if(O.has(_))return;var E=R[_];if(!E)return;O.add(_);var T=E.parent,L=E.node;if(L.disabled)return;T&&g(T.key)}return(h||[]).forEach(function(_){g(_)}),Object(N.a)(O)}function x(h){var R={};return Object.keys(h).forEach(function(O){(O.startsWith("data-")||O.startsWith("aria-"))&&(R[O]=h[O])}),R}},Ot1p:function(F,Q,j){"use strict";var N=j("2qtc"),v=j("kLXV"),C=j("rAM+"),M=j("miYZ"),m=j("tsqr"),y=j("9og8"),w=j("tJVT"),b=j("jrin"),p=j("WmNS"),d=j.n(p),n=j("cDcd"),c=j.n(n),r=j("VrN/"),i=j.n(r),o=j("bdgK"),u=j("p77/"),f=j("Bd2K"),s=j("ELLl"),l=j("19Vz"),t=j("lZu9"),S=j("+NIl"),x=j("kSUc"),h=j("9Bee"),R=function(ke){var Ve=ke.value,ut=Ve===void 0?"":Ve,ct=ke.className,Lt=ke.showTextOnly,Dt=ke.showLines,Er=ke.style,rr=Er===void 0?{}:Er,xt=Object(n.useMemo)(function(){return""},[ut]);return c.a.createElement(c.a.Fragment,null,c.a.createElement("div",{dangerouslySetInnerHTML:{__html:xt}}))},O=j("0Owb"),g=j("dejd"),_=j("C+DQ"),E=j("1vsH"),T=j("m3rI"),L=[{title:"\u7C97\u4F53",icon:"icon-bold",actionName:"bold"},{title:"\u659C\u4F53",icon:"icon-italic",actionName:"italic"},"|",{title:"\u65E0\u5E8F\u5217\u8868",icon:"icon-unorder-list",actionName:"list-ul"},{title:"\u6709\u5E8F\u5217\u8868",icon:"icon-order-list",actionName:"list-ol"},"|",{title:"\u884C\u5185\u4EE3\u7801",icon:"icon-code",actionName:"code"},{title:"\u4EE3\u7801\u5757\uFF08\u591A\u8BED\u8A00\u98CE\u683C\uFF09",icon:"icon-file-code",actionName:"code-block"},{title:"\u94FE\u63A5",icon:"icon-link",actionName:"link"},"|",{title:"\u884C\u5185\u516C\u5F0F",icon:"icon-sum",actionName:"inline-latex"},{title:"\u591A\u884C\u516C\u5F0F",icon:"icon-formula",actionName:"latex"},"|",{title:"\u6DFB\u52A0\u56FE\u7247",icon:"icon-picture",actionName:"upload-image"},{title:"\u8868\u683C",icon:"icon-table",actionName:"add-table"},"|",{title:"\u6362\u884C",icon:"icon-minus",actionName:"line-break"},{title:"\u6E05\u7A7A",icon:"icon-eraser",actionName:"eraser"}];function I(ke){var Ve=ke.onActionCallback,ut=ke.title,ct=ke.icon,Lt=ke.actionName,Dt=ke.className,Er=Dt===void 0?"":Dt,rr=ke.children;function xt(){Ve(Lt)}return c.a.createElement("a",{title:ut,className:Er,onClick:xt},c.a.createElement("i",{className:"md-iconfont ".concat(ct)}),rr)}var P=function(ke){var Ve=ke.watch,ut=ke.showNullButton,ct=ke.onActionCallback,Lt=ke.fullScreen,Dt=ke.insertTemp,Er=ke.hidetoolBar,rr=ke.uuid,xt=ke.setOpenPhones;console.log("link:","".concat(location.origin,"/upload.html?_educoder_session_login=").concat(Object(E.G)("_educoder_session_login"),"&_educoder_session=").concat(Object(E.G)("_educoder_session"),"&key=").concat(rr,"&api=").concat(encodeURIComponent(T.a.PROXY_SERVER)));var kr=[].concat(L,[{title:"".concat(Ve?"\u5173\u95ED\u5B9E\u65F6\u9884\u89C8":"\u5F00\u542F\u5B9E\u65F6\u9884\u89C8"),icon:"".concat(Ve?"icon-eye-slash":"icon-eye"),actionName:"trigger-watch"}]);return c.a.createElement("ul",{className:"markdown-toolbar-container"},!Er&&kr.map(function(Mr,Ur){return c.a.createElement("li",{key:Ur},Mr.actionName?c.a.createElement(I,Object(O.a)({},Mr,{onActionCallback:ct})):c.a.createElement("span",{className:"v-line"}))}),ut?c.a.createElement("li",null,c.a.createElement(I,{icon:"icon-edit",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-null-ch",onActionCallback:ct},c.a.createElement("span",{className:"fill-tip"},"\u70B9\u51FB\u63D2\u5165\b\u586B\u7A7A\u9879"))):null,Dt&&c.a.createElement("li",null,c.a.createElement(I,{icon:"icon-edit",className:"btn-null",title:"\u63D2\u5165\u6A21\u677F",actionName:"inster-template-".concat(Dt),onActionCallback:ct},c.a.createElement("span",{className:"fill-tip"},"\u63D2\u5165\u6A21\u677F"))),c.a.createElement("li",{className:"btn-full-screen"},c.a.createElement(I,{icon:"".concat(Lt?"icon-shrink":"icon-enlarge"),title:Lt?"\u5173\u95ED\u5168\u5C4F":"\u5F00\u542F\u5168\u5C4F",actionName:"trigger-full-screen",onActionCallback:ct})))},G=j("M8RZ"),W=j("+L6B"),H=j("2/Rp"),z=j("y8nQ"),B=j("Vl3Y"),k=j("5NDa"),K=j("5rEg"),Y={labelCol:{span:4},wrapperCol:{span:20}},ne=function(ke){var Ve=ke.callback,ut=ke.onCancel;function ct(Lt){Ve(Lt)}return c.a.createElement(B.a,Object(O.a)({},Y,{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:ct}),c.a.createElement(B.a.Item,{label:"\u94FE\u63A5\u5730\u5740",name:"link",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740"}]},c.a.createElement(K.a,null)),c.a.createElement(B.a.Item,{label:"\u94FE\u63A5\u6807\u9898",name:"title",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u6807\u9898"}]},c.a.createElement(K.a,null)),c.a.createElement("div",{className:"flex-container flex-end"},c.a.createElement(H.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),c.a.createElement(H.a,{type:"ghost",onClick:ut},"\u53D6\u6D88")))},oe=j("7ahc"),_e=j("HmJG"),xe=j("BjJ7"),le=B.a.useForm,me={width:280,marginRight:10},de={labelCol:{span:5},wrapperCol:{span:19}},ae=function(ke){var Ve=ke.callback,ut=ke.onCancel,ct=le(),Lt=Object(w.a)(ct,1),Dt=Lt[0];function Er(kr){Ve(kr)}function rr(kr,Mr){if(kr.status===-1){m.b.error(kr.message);return}Dt.setFieldsValue({src:"/api/attachments/".concat(kr.id),type:Mr.type})}function xt(kr){var Mr=kr.target.files[0];q(Mr,rr)}return c.a.createElement(B.a,Object(O.a)({form:Dt},de,{className:"upload-image-panel",onFinish:Er}),c.a.createElement(B.a.Item,{label:"\u56FE\u7247\u5730\u5740",required:!0},c.a.createElement("div",{className:"flex-container"},c.a.createElement(B.a.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u56FE\u7247\u5730\u5740"}]},c.a.createElement(K.a,{style:me})),c.a.createElement(ie,{onFileChange:xt}))),c.a.createElement(B.a.Item,{label:"\u56FE\u7247\u63CF\u8FF0",name:"alt"},c.a.createElement(K.a,{style:{width:264}})),c.a.createElement(B.a.Item,{style:{textAlign:"right"}},c.a.createElement(H.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),c.a.createElement(H.a,{type:"ghost",onClick:ut},"\u53D6\u6D88")))};function ie(ke){var Ve=ke.onFileChange;return c.a.createElement("a",{className:"upload-button"},"\u672C\u5730\u4E0A\u4F20",c.a.createElement("input",{type:"file",onChange:Ve}))}function q(ke,Ve){if(!ke)throw new String("\u6CA1\u6709\u6587\u4EF6");var ut=new FormData;ut.append("editormd-image-file",ke),ut.append("file_param_name","editormd-image-file"),ut.append("byxhr","true");var ct=new window.XMLHttpRequest;ct.withCredentials=!0,ct.addEventListener("load",function(Lt){Ve(JSON.parse(Lt.target.responseText),ke)},!1),ct.addEventListener("error",function(Lt){console.error(Lt)},!1),ct.open("POST","".concat(xe.a,"/api/attachments.json")),ct.send(ut)}var ue=j("giR+"),Z=j("fyUT"),ee=j("7Kak"),Ee=j("9yH6"),te=Ee.a.Group,J={margin:"0 8px"},X=function(ke){var Ve=ke.callback,ut=ke.onCancel;function ct(Lt){Ve(Lt)}return c.a.createElement(B.a,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:ct},c.a.createElement("div",{className:"flex-container",style:{alignItems:"baseline"}},c.a.createElement("span",{style:J},"\u5355\u5143\u683C\u6570\uFF1A"),c.a.createElement("span",{style:J},"\u884C\u6570"),c.a.createElement(B.a.Item,{name:"row",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u884C\u6570"}]},c.a.createElement(Z.a,null)),c.a.createElement("span",{style:J},"\u5217\u6570"),c.a.createElement(B.a.Item,{name:"col",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5217\u6570"}]},c.a.createElement(Z.a,null))),c.a.createElement("div",{className:"flex-container",style:{marginTop:12,alignItems:"baseline"}},c.a.createElement("span",{style:J},"\u5BF9\u9F50\u65B9\u5F0F\uFF1A"),c.a.createElement(B.a.Item,{name:"align"},c.a.createElement(te,null,c.a.createElement(Ee.a,{value:"default"},c.a.createElement("i",{className:"fa fa-align-justify"})),c.a.createElement(Ee.a,{value:"left"},c.a.createElement("i",{className:"fa fa-align-left"})),c.a.createElement(Ee.a,{value:"center"},c.a.createElement("i",{className:"fa fa-align-center"})),c.a.createElement(Ee.a,{value:"right"},c.a.createElement("i",{className:"fa fa-align-right"}))))),c.a.createElement("div",{className:"flex-container flex-end"},c.a.createElement(H.a,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),c.a.createElement(H.a,{type:"ghost",onClick:ut},"\u53D6\u6D88")))},$=j("ErOA"),ge=j("7Cbv"),fe="link",Te="upload-image",ze="code-block",Xe="add-table",Ye="------------",rt={default:Ye,left:":".concat(Ye),center:":".concat(Ye,":"),right:"".concat(Ye,":")},at=j("9VGf"),ot,Pe;function Se(){}var Je=0,nt=1e4,We="\u2581",et=`
**\u6A21\u677F\u6807\u9898**
\u6A21\u677F\u6B63\u6587\u5185\u5BB9\uFF0C\u53EF\u8F93\u5165\u6587\u672C\u5185\u5BB9\u548C\u7C98\u8D34\u56FE\u7247\u7B49\u64CD\u4F5C`;function Me(ke){return/^\d+$/.test(ke)?"".concat(ke,"px"):ke}var Ce=navigator.platform.toUpperCase().indexOf("MAC")>=0,Re=Ce?"Cmd":"Ctrl",pe=["pptm","pptx","ppt","pot","pps","ppa","potx","ppsx","ppam","pptm","potm","ppsm","doc","docx","dot","dotx","docm","dotm","xls","xlsx","csv","xlt","xla","xltx","xlsm","xltm","xlam","xlsb"],ye=(ot={},Object(b.a)(ot,Re+"-B","bold"),Object(b.a)(ot,Re+"-I","italic"),ot),we=(Pe={},Object(b.a)(Pe,fe,"\u6DFB\u52A0\u94FE\u63A5"),Object(b.a)(Pe,ze,"\u6DFB\u52A0\u4EE3\u7801\u5757"),Object(b.a)(Pe,Te,"\u6DFB\u52A0\u6587\u4EF6"),Object(b.a)(Pe,Xe,"\u6DFB\u52A0\u8868\u683C"),Pe),Ie=Q.a=function(ke){var Ve=ke.defaultValue,ut=Ve===void 0?"":Ve,ct=ke.onChange,Lt=ke.width,Dt=Lt===void 0?"100%":Lt,Er=ke.height,rr=Er===void 0?400:Er,xt=ke.miniToolbar,kr=xt===void 0?!1:xt,Mr=ke.isFocus,Ur=Mr===void 0?!1:Mr,ln=ke.watch,Sr=ke.insertTemp,an=ke.mode,qr=an===void 0?"markdown":an,Bt=ke.id,ur=Bt===void 0?"markdown-editor-id":Bt,jr=ke.showResizeBar,en=jr===void 0?!1:jr,Jr=ke.noStorage,_a=Jr===void 0?!1:Jr,Wa=ke.showNullButton,_n=Wa===void 0?!1:Wa,er=ke.hidetoolBar,Xn=er===void 0?!1:er,Ea=ke.fullScreen,Pn=Ea===void 0?!1:Ea,Qr=ke.onBlur,Ln=ke.onCMBeforeChange,la=ke.onFullScreen,fa=ke.className,It=fa===void 0?"":fa,dr=ke.disablePaste,ha=dr===void 0?!1:dr,xa=ke.placeholder,Pa=xa===void 0?"":xa,pa=ke.values,kn=pa===void 0?"":pa,xr=Object(n.useState)(null),ta=Object(w.a)(xr,2),Ct=ta[0],Vn=ta[1],Mn=Object(n.useState)(ut),Ka=Object(w.a)(Mn,2),Ta=Ka[0],Qn=Ka[1],Qa=Object(n.useState)(ln),Za=Object(w.a)(Qa,2),ra=Za[0],wn=Za[1],na=Object(n.useState)(Pn),ka=Object(w.a)(na,2),ma=ka[0],va=ka[1],Di=Object(n.useState)(""),Xa=Object(w.a)(Di,2),jn=Xa[0],za=Xa[1],_i=Object(n.useState)(0),Ma=Object(w.a)(_i,2),aa=Ma[0],oi=Ma[1],pi=Object(n.useState)(rr),si=Object(w.a)(pi,2),mi=si[0],qa=si[1],wa=Object(n.useState)(!1),ei=Object(w.a)(wa,2),Ei=ei[0],mt=ei[1],qe=Object(n.useRef)(Object(ge.a)()),pt=Object(n.useRef)(!1),_t=Object(n.useRef)(),Ut=Object(n.useRef)(),At=Object(n.useRef)(),Xt=Object(n.useRef)(),kt=Object(n.useRef)(),st=function(){var ft=Object(y.a)(d.a.mark(function yt(){var ht,wt;return d.a.wrap(function(ar){for(;;)switch(ar.prev=ar.next){case 0:return ar.next=2,Object($.a)("/api/attachments/distinct_hash_val.json",{method:"post",body:{hash_val:qe.current}});case 2:wt=ar.sent,wt!=null&&(ht=wt.attachments)!==null&&ht!==void 0&&ht.length&&(console.log("cm:",Ct,Ut),wt.attachments.map(function(zt){zt.content_type.indexOf("image")>-1?Ct.replaceSelection("![,](/api/attachments/".concat(zt.id,"?type=").concat(zt.content_type,")")):zt.content_type.indexOf("video")>-1?Ct.replaceSelection('<video width="100%" controls src="'.concat(T.a.API_SERVER,"/api/attachments/").concat(data.id,'"></video>')):zt.content_type.indexOf("pdf")>-1?Ct.replaceSelection('<a href="'.concat(T.a.API_SERVER,"/api/attachments/").concat(zt.id,"?type=").concat(zt.content_type,'&disposition=inline" target="_blank">').concat(zt.name,"</a>")):Ct.replaceSelection("[".concat(zt.name,"](").concat(T.a.API_SERVER,"/api/attachments/").concat(zt.id,"?type=").concat(zt.content_type,")"))}));case 4:case"end":return ar.stop()}},yt)}));return function(){return ft.apply(this,arguments)}}();Object(n.useEffect)(function(){Qn(kn),Ct==null||Ct.setValue(kn)},[kn]),Object(n.useEffect)(function(){la==null||la(ma)},[ma]),Object(n.useEffect)(function(){if(Ut.current){var ft=i.a.fromTextArea(Ut.current,{mode:qr,lineNumbers:!kr,lineWrapping:!0,value:ut,autoCloseTags:!0,autoCloseBrackets:!0});Ur&&ft.focus();function yt(ht,wt){if(ha){wt.preventDefault();return}var Kt=wt.clipboardData;if(Kt){var ar=Kt.types.toString(),zt=Kt.items;if(ar==="Files"||Kt.types.indexOf("Files")>-1){if(wt.preventDefault(),qr=="stex")return;try{var gr,Rr=zt[1];((gr=zt[0])===null||gr===void 0?void 0:gr.kind)==="file"&&(Rr=zt[0]);var lr=Rr.getAsFile(),Qe=lr.name.split(".").pop();q(lr,function(Pt){if(Pt.id){var Vr,Hr,ir;(lr==null||((Vr=lr.type)===null||Vr===void 0)?void 0:Vr.indexOf("image"))>-1?ft.replaceSelection("![,](/api/attachments/".concat(Pt.id,"?type=").concat(Pt.content_type,")")):(lr==null||((Hr=lr.type)===null||Hr===void 0)?void 0:Hr.indexOf("video"))>-1?ft.replaceSelection('<video width="100%" controls src="'.concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,'"></video>')):(lr==null||((ir=lr.type)===null||ir===void 0)?void 0:ir.indexOf("pdf"))>-1?ft.replaceSelection('<a href="'.concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,"?type=").concat(lr.type,'&disposition=inline" target="_blank">').concat(lr.name,"</a>")):pe.includes(Qe)?ft.replaceSelection('<a href="'.concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,'?type=office&disposition=inline" target="_blank">').concat(lr.name,"</a>")):ft.replaceSelection("[".concat(lr.name,"](").concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,"?type=").concat(Pt.content_type,")"))}else(Pt==null?void 0:Pt.status)===401&&(document.location.href="/user/login")})}catch(Pt){m.b.warn("\u8BF7\u4F7F\u7528chrome\u6D4F\u89C8\u5668\u7C98\u8D34")}return!0}else return!0}return!0}return ft.on("paste",yt),ft.on("dragleave",function(ht,wt){At.current.classList.remove("mouse-hover-md")}),ft.on("dragover",function(ht,wt){At.current.classList.add("mouse-hover-md")}),ft.on("drop",function(ht,wt){At.current.classList.add("mouse-hover-md");var Kt;if(Kt=wt.dataTransfer.files,Kt.length>0){wt.preventDefault(),wt.stopPropagation();for(var ar=function(Rr){var lr=Kt[Rr],Qe=lr.name.split(".").pop();q(lr,function(Pt){if(Pt.id){var Vr,Hr,ir;(lr==null||((Vr=lr.type)===null||Vr===void 0)?void 0:Vr.indexOf("image"))>-1?ft.replaceSelection("![,](/api/attachments/".concat(Pt.id,"?type=").concat(Pt.content_type,")")):(lr==null||((Hr=lr.type)===null||Hr===void 0)?void 0:Hr.indexOf("video"))>-1?ft.replaceSelection('<video width="100%" controls src="'.concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,'"></video>')):(lr==null||((ir=lr.type)===null||ir===void 0)?void 0:ir.indexOf("pdf"))>-1?ft.replaceSelection('<a href="'.concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,"?type=").concat(lr.type,'&disposition=inline" target="_blank">').concat(lr.name,"</a>")):pe.includes(Qe)?ft.replaceSelection('<a href="'.concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,'?type=office&disposition=inline" target="_blank">').concat(lr.name,"</a>")):ft.replaceSelection("[".concat(lr.name,"](").concat(T.a.API_SERVER,"/api/attachments/").concat(Pt.id,"?type=").concat(Pt.content_type,")"))}else(Pt==null?void 0:Pt.status)===401&&(document.location.href="/user/login")})},zt=0;zt<Kt.length;zt++)ar(zt)}}),Vn(ft),function(){ft.off("paste",yt)}}},[]);var gt=Object(n.useCallback)(function(){if(At.current)try{}catch(ft){console.log(ft,"---- to set md editor body height")}},[mi,At,ma]);Object(n.useEffect)(function(){function ft(){var ht=new o.default(function(wt){var Kt=Object(C.a)(wt),ar;try{for(Kt.s();!(ar=Kt.n()).done;){var zt=ar.value;(zt.target.offsetHeight>0||zt.target.offsetWidth>0)&&(gt(),Ct.setSize("100%","100%"),Ct.refresh())}}catch(gr){Kt.e(gr)}finally{Kt.f()}});return ht.observe(Ut.current.parentElement),ht}if(Ct){var yt=ft();return function(){yt.unobserve(Ut.current.parentElement)}}},[Ct,gt]),Object(n.useEffect)(function(){if(Ct){for(var ft=[],yt=function(){var zt=wt[ht];Kt=Object(w.a)(zt,2);var gr=Kt[0],Rr=Kt[1],lr=Object(b.a)({},gr,function(){bt(Rr)});ft.push(lr),Ct.addKeyMap(lr)},ht=0,wt=Object.entries(ye);ht<wt.length;ht++){var Kt;yt()}return _t.current=setInterval(function(){pt.current&&st()},4e3),function(){clearInterval(_t.current);var ar=Object(C.a)(ft),zt;try{for(ar.s();!(zt=ar.n()).done;){var gr=zt.value;Ct.removeKeyMap(gr)}}catch(Rr){ar.e(Rr)}finally{ar.f()}}}},[Ct]),Object(n.useEffect)(function(){Pn!==ma&&va(Pn)},[Pn]),Object(at.a)(function(){if(!_a&&aa>0){var ft=new Date().getTime(),yt=window.sessionStorage.getItem(ur);ft>=aa+nt&&(!yt||yt!==Ta)&&(window.sessionStorage.setItem(ur,Ta),mt(!0))}},nt),Object(n.useEffect)(function(){wn(ln)},[Ct,ln]),Object(n.useEffect)(function(){Ct&&(Ur&&Ct.focus())},[Ct,Ur]),Object(n.useEffect)(function(){if(ra&&Ct){var ft=Ct.getScrollerElement();function yt(ht){var wt=ht.target;if(kt.current){var Kt=wt.scrollTop/wt.scrollHeight;kt.current.scrollTop=kt.current.scrollHeight*Kt}}return ft.addEventListener("scroll",yt),function(){ft.removeEventListener("scroll",yt)}}},[Ct,ra]),Object(n.useEffect)(function(){if(Ct&&Ln){function ft(yt,ht){Ln(yt,ht)}return Ct.on("beforeChange",ft),function(){Ct.off("beforeChange",ft)}}},[Ct,Ln]),Object(n.useEffect)(function(){if(Ct&&Qr){function ft(){Qr(Ct.getValue())}return Ct.on("blur",ft),function(){Ct.off("blur",ft)}}},[Ct,Qr]),Object(n.useEffect)(function(){if(Ct){function ft(yt){var ht=yt.getValue();Qn(ht),oi(new Date().getTime()),yt.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),ct&&ct(ht)}return Ct.on("change",ft),function(){Ct.off("change",ft)}}},[Ct,ct]),Object(n.useEffect)(function(){Ct&&(ut==null?(Ct.setValue(""),Qn("")):ut!==Ct.getValue()&&(Ct.setValue(ut),Qn(ut),Ct.setCursor(Ct.lineCount(),0)))},[Ct,ut]);var bt=Object(n.useCallback)(function(ft){var yt=Ct.getCursor(),ht=Ct.getSelection(),wt=ht.split(`
`);switch(ft){case"bold":return Ct.replaceSelection("**"+ht+"**"),ht===""&&Ct.setCursor(yt.line,yt.ch+2),Ct.focus();case"italic":return Ct.replaceSelection("*"+ht+"*"),ht===""&&Ct.setCursor(yt.line,yt.ch+1),Ct.focus();case"code":return Ct.replaceSelection("`"+ht+"`"),ht===""&&Ct.setCursor(yt.line,yt.ch+1),Ct.focus();case"inline-latex":return Ct.replaceSelection("`$$"+ht+"$$`"),ht===""&&Ct.setCursor(yt.line,yt.ch+3),Ct.focus();case"latex":return Ct.replaceSelection("```latex\n"+ht+"\n```"),Ct.setCursor(yt.line+1,ht.length+1),Ct.focus();case"line-break":return Ct.replaceSelection(`<br/>
`),Ct.focus();case"list-ul":return ht===""?Ct.replaceSelection("- "+ht):Ct.replaceSelection(wt.map(function(Kt){return Kt===""?"":"- ".concat(Kt)}).join(`
`)),Ct.focus();case"list-ol":return ht===""?Ct.replaceSelection("1. "+ht):Ct.replaceSelection(wt.map(function(Kt,ar){return Kt===""?"":"".concat(ar+1,". ").concat(Kt)}).join(`
`)),Ct.focus();case"add-null-ch":return ht===""&&Ct.setCursor(yt.line,yt.ch+1),Ct.replaceSelection(We),Ct.focus();case"inster-template-1":return ht===""&&Ct.setCursor(yt.line,yt.ch),Ct.replaceSelection(et),Ct.focus();case"eraser":return Ct.setValue(""),Ct.focus();case"trigger-watch":return wn(!ra),Ct.focus();case"trigger-full-screen":return va(!ma),Ct.focus();case fe:za(fe);return;case ze:za(ze);return;case Te:za(Te);return;case Xe:za(Xe);return;default:throw new Error}},[Ct,ra,ma]),tr=Object(n.useCallback)(function(ft){za("");switch(jn){case fe:var yt=ft.title,ht=ft.link;return Ct.replaceSelection("[".concat(yt,"](").concat(ht,")")),Ct.focus();case ze:var wt=ft.language,Kt=ft.content;return Ct.replaceSelection(["```"+wt,Kt,"```"].join(`
`)),Ct.focus();case Te:var ar=ft.src,zt=ft.alt;return zt?Ct.replaceSelection("![ ".concat(zt," ]( ").concat(ar,' "').concat(zt,'" )')):Ct.replaceSelection("![,](".concat(ar,")")),Ct.focus();case Xe:for(var gr=ft.row,Rr=ft.col,lr=ft.align,Qe=`
`,Pt=0;Pt<gr;Pt++){for(var Vr=[],Hr=[],ir=0;ir<Rr;ir++)Pt===1&&Hr.push(rt[lr]),Vr.push(" ");Pt===1&&(Qe+="| ".concat(Hr.join(" | "),` |
`)),Qe+="| ".concat(Vr.join(Rr===1?"":" | "),` |
`)}return Ct.replaceSelection(Qe+`
`),Ct.focus();default:throw new Error}},[Ct,jn]),Jt=Object(n.useMemo)(function(){switch(jn){case fe:return c.a.createElement(ne,{callback:tr,onCancel:Wt});case ze:return c.a.createElement(oe.b,{callback:tr,onCancel:Wt});case Te:return c.a.createElement(ae,{callback:tr,onCancel:Wt});case Xe:return c.a.createElement(X,{callback:tr,onCancel:Wt});default:return null}},[jn]);function Wt(){za("")}Object(n.useEffect)(function(){if(Xt.current){var ft=Xt.current,yt=!1,ht=0;function wt(zt){yt=!0,ht=zt.pageY}function Kt(){yt=!1}function ar(zt){if(yt){var gr=zt.pageY-ht;gr<0&&(gr=0),gr>300&&(gr=300);var Rr=rr+gr+"px";qa(Rr)}}return ft.addEventListener("mousedown",wt),document.addEventListener("mousemove",ar),document.addEventListener("mouseup",Kt),function(){ft.removeEventListener("mousedown",wt),document.removeEventListener("mousemove",ar),document.removeEventListener("mouseup",Kt)}}},[Ct,Xt]),Object(n.useEffect)(function(){qa(rr)},[rr]);var jt=Me(Dt),Vt=Me(mi),Zt={width:jt,height:Vt},Ze=Object(n.useMemo)(function(){if(aa){var ft=new Date(aa),yt=ft.getHours(),ht=ft.getMinutes(),wt=ft.getSeconds();return yt=yt<10?"0"+yt:yt,ht=ht<10?"0"+ht:ht,wt=wt<10?"0"+wt:wt,"".concat(yt,":").concat(ht,":").concat(wt)}return 0},[aa]);function vr(){window.sessionStorage.removeItem(ur),mt(!1),oi(0)}function Or(){mt(!1),oi(0),Ct.setValue(window.sessionStorage.getItem(ur))}function nr(ft,yt){var ht=Ct.getValue();ht=ht.replace(ft,yt),Qn(ht),Ct==null||Ct.setValue(ht)}return c.a.createElement(n.Fragment,null,c.a.createElement("div",{className:"markdown-editor-wrapper",ref:At},c.a.createElement("div",{className:"markdown-editor-container ".concat(It," ").concat(ra?"on-preview":""," ").concat(kr?"mini":""," ").concat(ma?"full-screen":""),style:Zt},c.a.createElement(P,{insertTemp:Sr,watch:ra,fullScreen:ma,showNullButton:_n,onActionCallback:bt,hidetoolBar:Xn,uuid:qe.current,setOpenPhones:function(){pt.current=!0}}),c.a.createElement("div",{className:"markdown-editor-body"},c.a.createElement("div",{className:"codemirror-container"},c.a.createElement("textarea",{ref:Ut,placeholder:Pa})),ra?c.a.createElement("div",{ref:kt,className:"preview-container"},qr==="stex"&&c.a.createElement(R,{value:Ta}),qr!=="stex"&&c.a.createElement(h.a,{edit:!0,value:Ta,replaces:nr})):null))),en?c.a.createElement("a",{ref:Xt,className:"editor-resize"}):null,c.a.createElement(G.a,null,we[jn]?c.a.createElement(v.a,{centered:!0,title:we[jn],visible:!0,onCancel:Wt,footer:null,className:"markdown-popup-form"},Jt):null))}},PVpz:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("ETIr"),j("cv67"),j("K3mO"),j("OLod"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.StreamCipher,m=v.algo,y=[],w=[],b=[],p=m.RabbitLegacy=M.extend({_doReset:function(){var n=this._key.words,c=this.cfg.iv,r=this._X=[n[0],n[3]<<16|n[2]>>>16,n[1],n[0]<<16|n[3]>>>16,n[2],n[1]<<16|n[0]>>>16,n[3],n[2]<<16|n[1]>>>16],i=this._C=[n[2]<<16|n[2]>>>16,n[0]&4294901760|n[1]&65535,n[3]<<16|n[3]>>>16,n[1]&4294901760|n[2]&65535,n[0]<<16|n[0]>>>16,n[2]&4294901760|n[3]&65535,n[1]<<16|n[1]>>>16,n[3]&4294901760|n[0]&65535];this._b=0;for(var o=0;o<4;o++)d.call(this);for(var o=0;o<8;o++)i[o]^=r[o+4&7];if(c){var u=c.words,f=u[0],s=u[1],l=(f<<8|f>>>24)&16711935|(f<<24|f>>>8)&4278255360,t=(s<<8|s>>>24)&16711935|(s<<24|s>>>8)&4278255360,S=l>>>16|t&4294901760,x=t<<16|l&65535;i[0]^=l,i[1]^=S,i[2]^=t,i[3]^=x,i[4]^=l,i[5]^=S,i[6]^=t,i[7]^=x;for(var o=0;o<4;o++)d.call(this)}},_doProcessBlock:function(n,c){var r=this._X;d.call(this),y[0]=r[0]^r[5]>>>16^r[3]<<16,y[1]=r[2]^r[7]>>>16^r[5]<<16,y[2]=r[4]^r[1]>>>16^r[7]<<16,y[3]=r[6]^r[3]>>>16^r[1]<<16;for(var i=0;i<4;i++)y[i]=(y[i]<<8|y[i]>>>24)&16711935|(y[i]<<24|y[i]>>>8)&4278255360,n[c+i]^=y[i]},blockSize:128/32,ivSize:64/32});function d(){for(var n=this._X,c=this._C,r=0;r<8;r++)w[r]=c[r];c[0]=c[0]+1295307597+this._b|0,c[1]=c[1]+3545052371+(c[0]>>>0<w[0]>>>0?1:0)|0,c[2]=c[2]+886263092+(c[1]>>>0<w[1]>>>0?1:0)|0,c[3]=c[3]+1295307597+(c[2]>>>0<w[2]>>>0?1:0)|0,c[4]=c[4]+3545052371+(c[3]>>>0<w[3]>>>0?1:0)|0,c[5]=c[5]+886263092+(c[4]>>>0<w[4]>>>0?1:0)|0,c[6]=c[6]+1295307597+(c[5]>>>0<w[5]>>>0?1:0)|0,c[7]=c[7]+3545052371+(c[6]>>>0<w[6]>>>0?1:0)|0,this._b=c[7]>>>0<w[7]>>>0?1:0;for(var r=0;r<8;r++){var i=n[r]+c[r],o=i&65535,u=i>>>16,f=((o*o>>>17)+o*u>>>15)+u*u,s=((i&4294901760)*i|0)+((i&65535)*i|0);b[r]=f^s}n[0]=b[0]+(b[7]<<16|b[7]>>>16)+(b[6]<<16|b[6]>>>16)|0,n[1]=b[1]+(b[0]<<8|b[0]>>>24)+b[7]|0,n[2]=b[2]+(b[1]<<16|b[1]>>>16)+(b[0]<<16|b[0]>>>16)|0,n[3]=b[3]+(b[2]<<8|b[2]>>>24)+b[1]|0,n[4]=b[4]+(b[3]<<16|b[3]>>>16)+(b[2]<<16|b[2]>>>16)|0,n[5]=b[5]+(b[4]<<8|b[4]>>>24)+b[3]|0,n[6]=b[6]+(b[5]<<16|b[5]>>>16)+(b[4]<<16|b[4]>>>16)|0,n[7]=b[7]+(b[6]<<8|b[6]>>>24)+b[5]|0}v.RabbitLegacy=M._createHelper(p)}(),N.RabbitLegacy})},RxwV:function(F,Q,j){"use strict";var N=j("cDcd"),v=j("uciX"),C=j("2W6z"),M=j.n(C),m=j("4IlW"),y=j("uK0f"),w=j.n(y);function b(me,de){if(me===de)return!0;if(!me||!de)return!1;var ae=me.length;if(de.length!==ae)return!1;for(var ie=0;ie<ae;ie++)if(me[ie]!==de[ie])return!1;return!0}function p(me){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?p=function(ae){return typeof ae}:p=function(ae){return ae&&typeof Symbol=="function"&&ae.constructor===Symbol&&ae!==Symbol.prototype?"symbol":typeof ae},p(me)}function d(me,de){if(!(me instanceof de))throw new TypeError("Cannot call a class as a function")}function n(me,de){for(var ae=0;ae<de.length;ae++){var ie=de[ae];ie.enumerable=ie.enumerable||!1,ie.configurable=!0,"value"in ie&&(ie.writable=!0),Object.defineProperty(me,ie.key,ie)}}function c(me,de,ae){return de&&n(me.prototype,de),ae&&n(me,ae),me}function r(me,de){if(typeof de!="function"&&de!==null)throw new TypeError("Super expression must either be null or a function");me.prototype=Object.create(de&&de.prototype,{constructor:{value:me,writable:!0,configurable:!0}}),de&&i(me,de)}function i(me,de){return i=Object.setPrototypeOf||function(ie,q){return ie.__proto__=q,ie},i(me,de)}function o(me){var de=s();return function(){var ae=l(me),ie;if(de){var q=l(this).constructor;ie=Reflect.construct(ae,arguments,q)}else ie=ae.apply(this,arguments);return u(this,ie)}}function u(me,de){return de&&(p(de)==="object"||typeof de=="function")?de:f(me)}function f(me){if(me===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return me}function s(){if(typeof Reflect=="undefined"||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(me){return!1}}function l(me){return l=Object.setPrototypeOf?Object.getPrototypeOf:function(ae){return ae.__proto__||Object.getPrototypeOf(ae)},l(me)}var t=function(){var me=function(de){r(ie,de);var ae=o(ie);function ie(){var q;return d(this,ie),q=ae.apply(this,arguments),q.menuItems={},q.saveMenuItem=function(ue){return function(Z){q.menuItems[ue]=Z}},q}return c(ie,[{key:"componentDidMount",value:function(){this.scrollActiveItemToView()}},{key:"componentDidUpdate",value:function(ue){!ue.visible&&this.props.visible&&this.scrollActiveItemToView()}},{key:"getFieldName",value:function(ue){var Z=this.props,ee=Z.fieldNames,Ee=Z.defaultFieldNames;return ee[ue]||Ee[ue]}},{key:"getOption",value:function(ue,Z){var ee=this.props,Ee=ee.prefixCls,te=ee.expandTrigger,J=ee.expandIcon,X=ee.loadingIcon,$=this.props.onSelect.bind(this,ue,Z),ge=this.props.onItemDoubleClick.bind(this,ue,Z),fe={onClick:$,onDoubleClick:ge},Te="".concat(Ee,"-menu-item"),ze=null,Xe=ue[this.getFieldName("children")]&&ue[this.getFieldName("children")].length>0;(Xe||ue.isLeaf===!1)&&(Te+=" ".concat(Ee,"-menu-item-expand"),ue.loading||(ze=N.createElement("span",{className:"".concat(Ee,"-menu-item-expand-icon")},J))),te==="hover"&&(Xe||ue.isLeaf===!1)&&(fe={onMouseEnter:this.delayOnSelect.bind(this,$),onMouseLeave:this.delayOnSelect.bind(this),onClick:$}),this.isActiveOption(ue,Z)&&(Te+=" ".concat(Ee,"-menu-item-active"),fe.ref=this.saveMenuItem(Z)),ue.disabled&&(Te+=" ".concat(Ee,"-menu-item-disabled"));var Ye=null;ue.loading&&(Te+=" ".concat(Ee,"-menu-item-loading"),Ye=X||null);var rt="";return"title"in ue?rt=ue.title:typeof ue[this.getFieldName("label")]=="string"&&(rt=ue[this.getFieldName("label")]),N.createElement("li",Object.assign({key:ue[this.getFieldName("value")],className:Te,title:rt},fe,{role:"menuitem",onMouseDown:function(ot){return ot.preventDefault()}}),ue[this.getFieldName("label")],ze,Ye)}},{key:"getActiveOptions",value:function(ue){var Z=this,ee=this.props.options,Ee=ue||this.props.activeValue;return w()(ee,function(te,J){return te[Z.getFieldName("value")]===Ee[J]},{childrenKeyName:this.getFieldName("children")})}},{key:"getShowOptions",value:function(){var ue=this,Z=this.props.options,ee=this.getActiveOptions().map(function(Ee){return Ee[ue.getFieldName("children")]}).filter(function(Ee){return!!Ee});return ee.unshift(Z),ee}},{key:"delayOnSelect",value:function(ue){for(var Z=this,ee=arguments.length,Ee=new Array(ee>1?ee-1:0),te=1;te<ee;te++)Ee[te-1]=arguments[te];this.delayTimer&&(clearTimeout(this.delayTimer),this.delayTimer=null),typeof ue=="function"&&(this.delayTimer=window.setTimeout(function(){ue(Ee),Z.delayTimer=null},150))}},{key:"scrollActiveItemToView",value:function(){for(var ue=this.getShowOptions().length,Z=0;Z<ue;Z++){var ee=this.menuItems[Z];ee&&ee.parentElement&&(ee.parentElement.scrollTop=ee.offsetTop)}}},{key:"isActiveOption",value:function(ue,Z){var ee=this.props.activeValue,Ee=ee===void 0?[]:ee;return Ee[Z]===ue[this.getFieldName("value")]}},{key:"render",value:function(){var ue=this,Z=this.props,ee=Z.prefixCls,Ee=Z.dropdownMenuColumnStyle;return N.createElement("div",null,this.getShowOptions().map(function(te,J){return N.createElement("ul",{className:"".concat(ee,"-menu"),key:J,style:Ee},te.map(function(X){return ue.getOption(X,J)}))}))}}]),ie}(N.Component);return me.defaultProps={options:[],value:[],activeValue:[],onSelect:function(){},prefixCls:"rc-cascader-menus",visible:!1,expandTrigger:"click"},me}(),S=t,x={bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:1,adjustY:1}},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:1,adjustY:1}},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:1,adjustY:1}},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:1,adjustY:1}}},h=x;function R(me){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?R=function(ae){return typeof ae}:R=function(ae){return ae&&typeof Symbol=="function"&&ae.constructor===Symbol&&ae!==Symbol.prototype?"symbol":typeof ae},R(me)}function O(me,de){if(me==null)return{};var ae=g(me,de),ie,q;if(Object.getOwnPropertySymbols){var ue=Object.getOwnPropertySymbols(me);for(q=0;q<ue.length;q++){if(ie=ue[q],de.indexOf(ie)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(me,ie))continue;ae[ie]=me[ie]}}return ae}function g(me,de){if(me==null)return{};var ae={},ie=Object.keys(me),q,ue;for(ue=0;ue<ie.length;ue++){if(q=ie[ue],de.indexOf(q)>=0)continue;ae[q]=me[q]}return ae}function _(me){return I(me)||L(me)||T(me)||E()}function E(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function T(me,de){if(!me)return;if(typeof me=="string")return P(me,de);var ae=Object.prototype.toString.call(me).slice(8,-1);if(ae==="Object"&&me.constructor&&(ae=me.constructor.name),ae==="Map"||ae==="Set")return Array.from(me);if(ae==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ae))return P(me,de)}function L(me){if(typeof Symbol!="undefined"&&Symbol.iterator in Object(me))return Array.from(me)}function I(me){if(Array.isArray(me))return P(me)}function P(me,de){(de==null||de>me.length)&&(de=me.length);for(var ae=0,ie=new Array(de);ae<de;ae++)ie[ae]=me[ae];return ie}function G(me,de){if(!(me instanceof de))throw new TypeError("Cannot call a class as a function")}function W(me,de){for(var ae=0;ae<de.length;ae++){var ie=de[ae];ie.enumerable=ie.enumerable||!1,ie.configurable=!0,"value"in ie&&(ie.writable=!0),Object.defineProperty(me,ie.key,ie)}}function H(me,de,ae){return de&&W(me.prototype,de),ae&&W(me,ae),me}function z(me,de){if(typeof de!="function"&&de!==null)throw new TypeError("Super expression must either be null or a function");me.prototype=Object.create(de&&de.prototype,{constructor:{value:me,writable:!0,configurable:!0}}),de&&B(me,de)}function B(me,de){return B=Object.setPrototypeOf||function(ie,q){return ie.__proto__=q,ie},B(me,de)}function k(me){var de=ne();return function(){var ae=oe(me),ie;if(de){var q=oe(this).constructor;ie=Reflect.construct(ae,arguments,q)}else ie=ae.apply(this,arguments);return K(this,ie)}}function K(me,de){return de&&(R(de)==="object"||typeof de=="function")?de:Y(me)}function Y(me){if(me===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return me}function ne(){if(typeof Reflect=="undefined"||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(me){return!1}}function oe(me){return oe=Object.setPrototypeOf?Object.getPrototypeOf:function(ae){return ae.__proto__||Object.getPrototypeOf(ae)},oe(me)}var _e=function(){var me=function(de){z(ie,de);var ae=k(ie);function ie(q){var ue;G(this,ie),ue=ae.call(this,q),ue.setPopupVisible=function(ee){var Ee=ue.state.value;"popupVisible"in ue.props||ue.setState({popupVisible:ee}),ee&&!ue.state.popupVisible&&ue.setState({activeValue:Ee}),ue.props.onPopupVisibleChange(ee)},ue.handleChange=function(ee,Ee,te){var J=Ee.visible;(te.type!=="keydown"||te.keyCode===m.a.ENTER)&&(ue.props.onChange(ee.map(function(X){return X[ue.getFieldName("value")]}),ee),ue.setPopupVisible(J))},ue.handlePopupVisibleChange=function(ee){ue.setPopupVisible(ee)},ue.handleMenuSelect=function(ee,Ee,te){var J=ue.trigger.getRootDomNode();J&&J.focus&&J.focus();var X=ue.props,$=X.changeOnSelect,ge=X.loadData,fe=X.expandTrigger;if(!ee||ee.disabled)return;var Te=ue.state.activeValue;Te=Te.slice(0,Ee+1),Te[Ee]=ee[ue.getFieldName("value")];var ze=ue.getActiveOptions(Te);if(ee.isLeaf===!1&&!ee[ue.getFieldName("children")]&&ge){$&&ue.handleChange(ze,{visible:!0},te),ue.setState({activeValue:Te}),ge(ze);return}var Xe={};!ee[ue.getFieldName("children")]||!ee[ue.getFieldName("children")].length?(ue.handleChange(ze,{visible:!1},te),Xe.value=Te):$&&(te.type==="click"||te.type==="keydown")&&(fe==="hover"?ue.handleChange(ze,{visible:!1},te):ue.handleChange(ze,{visible:!0},te),Xe.value=Te),Xe.activeValue=Te,("value"in ue.props||te.type==="keydown"&&te.keyCode!==m.a.ENTER)&&delete Xe.value,ue.setState(Xe)},ue.handleItemDoubleClick=function(){var ee=ue.props.changeOnSelect;ee&&ue.setPopupVisible(!1)},ue.handleKeyDown=function(ee){var Ee=ue.props.children;if(Ee&&Ee.props.onKeyDown){Ee.props.onKeyDown(ee);return}var te=_(ue.state.activeValue),J=te.length-1<0?0:te.length-1,X=ue.getCurrentLevelOptions(),$=X.map(function(ze){return ze[ue.getFieldName("value")]}).indexOf(te[J]);if(ee.keyCode!==m.a.DOWN&&ee.keyCode!==m.a.UP&&ee.keyCode!==m.a.LEFT&&ee.keyCode!==m.a.RIGHT&&ee.keyCode!==m.a.ENTER&&ee.keyCode!==m.a.SPACE&&ee.keyCode!==m.a.BACKSPACE&&ee.keyCode!==m.a.ESC&&ee.keyCode!==m.a.TAB)return;if(!ue.state.popupVisible&&ee.keyCode!==m.a.BACKSPACE&&ee.keyCode!==m.a.LEFT&&ee.keyCode!==m.a.RIGHT&&ee.keyCode!==m.a.ESC&&ee.keyCode!==m.a.TAB){ue.setPopupVisible(!0);return}if(ee.keyCode===m.a.DOWN||ee.keyCode===m.a.UP){ee.preventDefault();var ge=$;ge!==-1?ee.keyCode===m.a.DOWN?(ge+=1,ge=ge>=X.length?0:ge):(ge-=1,ge=ge<0?X.length-1:ge):ge=0,te[J]=X[ge][ue.getFieldName("value")]}else if(ee.keyCode===m.a.LEFT||ee.keyCode===m.a.BACKSPACE)ee.preventDefault(),te.splice(te.length-1,1);else if(ee.keyCode===m.a.RIGHT)ee.preventDefault(),X[$]&&X[$][ue.getFieldName("children")]&&te.push(X[$][ue.getFieldName("children")][0][ue.getFieldName("value")]);else if(ee.keyCode===m.a.ESC||ee.keyCode===m.a.TAB){ue.setPopupVisible(!1);return}(!te||te.length===0)&&ue.setPopupVisible(!1);var fe=ue.getActiveOptions(te),Te=fe[fe.length-1];ue.handleMenuSelect(Te,fe.length-1,ee),ue.props.onKeyDown&&ue.props.onKeyDown(ee)},ue.saveTrigger=function(ee){ue.trigger=ee};var Z=[];return"value"in q?Z=q.value||[]:"defaultValue"in q&&(Z=q.defaultValue||[]),M()(!("filedNames"in q),"`filedNames` of Cascader is a typo usage and deprecated, please use `fieldNames` instead."),ue.state={popupVisible:q.popupVisible,activeValue:Z,value:Z,prevProps:q},ue.defaultFieldNames={label:"label",value:"value",children:"children"},ue}return H(ie,[{key:"getPopupDOMNode",value:function(){return this.trigger.getPopupDomNode()}},{key:"getFieldName",value:function(ue){var Z=this.defaultFieldNames,ee=this.props,Ee=ee.fieldNames,te=ee.filedNames;return"filedNames"in this.props?te[ue]||Z[ue]:Ee[ue]||Z[ue]}},{key:"getFieldNames",value:function(){var ue=this.props,Z=ue.fieldNames,ee=ue.filedNames;return"filedNames"in this.props?ee:Z}},{key:"getCurrentLevelOptions",value:function(){var ue=this,Z=this.props.options,ee=Z===void 0?[]:Z,Ee=this.state.activeValue,te=Ee===void 0?[]:Ee,J=w()(ee,function(X,$){return X[ue.getFieldName("value")]===te[$]},{childrenKeyName:this.getFieldName("children")});return J[J.length-2]?J[J.length-2][this.getFieldName("children")]:_(ee).filter(function(X){return!X.disabled})}},{key:"getActiveOptions",value:function(ue){var Z=this;return w()(this.props.options||[],function(ee,Ee){return ee[Z.getFieldName("value")]===ue[Ee]},{childrenKeyName:this.getFieldName("children")})}},{key:"render",value:function(){var ue=this.props,Z=ue.prefixCls,ee=ue.transitionName,Ee=ue.popupClassName,te=ue.options,J=te===void 0?[]:te,X=ue.disabled,$=ue.builtinPlacements,ge=ue.popupPlacement,fe=ue.children,Te=ue.dropdownRender,ze=O(ue,["prefixCls","transitionName","popupClassName","options","disabled","builtinPlacements","popupPlacement","children","dropdownRender"]),Xe=N.createElement("div",null),Ye="";J&&J.length>0?Xe=N.createElement(S,Object.assign({},this.props,{fieldNames:this.getFieldNames(),defaultFieldNames:this.defaultFieldNames,activeValue:this.state.activeValue,onSelect:this.handleMenuSelect,onItemDoubleClick:this.handleItemDoubleClick,visible:this.state.popupVisible})):Ye=" ".concat(Z,"-menus-empty");var rt=Xe;return Te&&(rt=Te(Xe)),N.createElement(v.a,Object.assign({ref:this.saveTrigger},ze,{popupPlacement:ge,builtinPlacements:$,popupTransitionName:ee,action:X?[]:["click"],popupVisible:X?!1:this.state.popupVisible,onPopupVisibleChange:this.handlePopupVisibleChange,prefixCls:"".concat(Z,"-menus"),popupClassName:Ee+Ye,popup:rt}),N.cloneElement(fe,{onKeyDown:this.handleKeyDown,tabIndex:X?void 0:0}))}}],[{key:"getDerivedStateFromProps",value:function(ue,Z){var ee=Z.prevProps,Ee=ee===void 0?{}:ee,te={prevProps:ue};return"value"in ue&&!b(Ee.value,ue.value)&&(te.value=ue.value||[],"loadData"in ue||(te.activeValue=ue.value||[])),"popupVisible"in ue&&(te.popupVisible=ue.popupVisible),te}}]),ie}(N.Component);return me.defaultProps={onChange:function(){},onPopupVisibleChange:function(){},disabled:!1,transitionName:"",prefixCls:"rc-cascader",popupClassName:"",popupPlacement:"bottomLeft",builtinPlacements:h,expandTrigger:"click",fieldNames:{label:"label",value:"value",children:"children"},expandIcon:">"},me}(),xe=_e,le=Q.a=xe},S6kV:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.mode.OFB=function(){var v=N.lib.BlockCipherMode.extend(),C=v.Encryptor=v.extend({processBlock:function(M,m){var y=this._cipher,w=y.blockSize,b=this._iv,p=this._keystream;b&&(p=this._keystream=b.slice(0),this._iv=void 0),y.encryptBlock(p,0);for(var d=0;d<w;d++)M[m+d]^=p[d]}});return v.Decryptor=C,v}(),N.mode.OFB})},"SA+Z":function(F,Q,j){var N=j("wTVA"),v=j("EbDI"),C=j("ZhPi"),M=j("wkBT");function m(y){return N(y)||v(y)||C(y)||M()}F.exports=m,F.exports.__esModule=!0,F.exports.default=F.exports},SJMd:function(F,Q){/**
* @license
* Copyright (C) 2006 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/var j,N,v,C=!1,M,m;window.PR_SHOULD_USE_CONTINUATION=!0;var y,w;(function(){var b=window,p=["break,continue,do,else,for,if,return,while"],d=[p,"auto,case,char,const,default,double,enum,extern,float,goto,inline,int,long,register,restrict,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"],n=[d,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"],c=[n,"alignas,alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,delegate,dynamic_cast,explicit,export,friend,generic,late_check,mutable,namespace,noexcept,noreturn,nullptr,property,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"],r=[n,"abstract,assert,boolean,byte,extends,finally,final,implements,import,instanceof,interface,null,native,package,strictfp,super,synchronized,throws,transient"],i=[n,"abstract,add,alias,as,ascending,async,await,base,bool,by,byte,checked,decimal,delegate,descending,dynamic,event,finally,fixed,foreach,from,get,global,group,implicit,in,interface,internal,into,is,join,let,lock,null,object,out,override,orderby,params,partial,readonly,ref,remove,sbyte,sealed,select,set,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,value,var,virtual,where,yield"],o="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,throw,true,try,unless,until,when,while,yes",u=[n,"abstract,async,await,constructor,debugger,enum,eval,export,function,get,implements,instanceof,interface,let,null,set,undefined,var,with,yield,Infinity,NaN"],f="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END",s=[p,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"],l=[p,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"],t=[p,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"],S=[c,i,r,u,f,s,l,t],x=/^(DIR|FILE|array|vector|(de|priority_)?queue|(forward_)?list|stack|(const_)?(reverse_)?iterator|(unordered_)?(multi)?(set|map)|bitset|u?(int|float)\d*)\b/,h="str",R="kwd",O="com",g="typ",_="lit",E="pun",T="pln",L="tag",I="dec",P="src",G="atn",W="atv",H="nocode",z="(?:^^\\.?|[+-]|[!=]=?=?|\\#|%=?|&&?=?|\\(|\\*=?|[+\\-]=|->|\\/=?|::?|<<?=?|>>?>?=?|,|;|\\?|@|\\[|~|{|\\^\\^?=?|\\|\\|?=?|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function B(te){for(var J=0,X=!1,$=!1,ge=0,fe=te.length;ge<fe;++ge){var Te=te[ge];if(Te.ignoreCase)$=!0;else if(/[a-z]/i.test(Te.source.replace(/\\u[0-9a-f]{4}|\\x[0-9a-f]{2}|\\[^ux]/gi,""))){X=!0,$=!1;break}}var ze={b:8,t:9,n:10,v:11,f:12,r:13};function Xe(Pe){var Se=Pe.charCodeAt(0);if(Se!==92)return Se;var Je=Pe.charAt(1);return Se=ze[Je],Se||("0"<=Je&&Je<="7"?parseInt(Pe.substring(1),8):Je==="u"||Je==="x"?parseInt(Pe.substring(2),16):Pe.charCodeAt(1))}function Ye(Pe){if(Pe<32)return(Pe<16?"\\x0":"\\x")+Pe.toString(16);var Se=String.fromCharCode(Pe);return Se==="\\"||Se==="-"||Se==="]"||Se==="^"?"\\"+Se:Se}function rt(Pe){var Se=Pe.substring(1,Pe.length-1).match(new RegExp("\\\\u[0-9A-Fa-f]{4}|\\\\x[0-9A-Fa-f]{2}|\\\\[0-3][0-7]{0,2}|\\\\[0-7]{1,2}|\\\\[\\s\\S]|-|[^-\\\\]","g")),Je=[],nt=Se[0]==="^",We=["["];nt&&We.push("^");for(var et=nt?1:0,Me=Se.length;et<Me;++et){var Ce=Se[et];if(/\\[bdsw]/i.test(Ce))We.push(Ce);else{var Re=Xe(Ce),pe;et+2<Me&&Se[et+1]==="-"?(pe=Xe(Se[et+2]),et+=2):pe=Re,Je.push([Re,pe]),pe<65||Re>122||(pe<65||Re>90||Je.push([Math.max(65,Re)|32,Math.min(pe,90)|32]),pe<97||Re>122||Je.push([Math.max(97,Re)&~32,Math.min(pe,122)&~32]))}}Je.sort(function(ke,Ve){return ke[0]-Ve[0]||Ve[1]-ke[1]});for(var ye=[],we=[],et=0;et<Je.length;++et){var Ie=Je[et];Ie[0]<=we[1]+1?we[1]=Math.max(we[1],Ie[1]):ye.push(we=Ie)}for(var et=0;et<ye.length;++et){var Ie=ye[et];We.push(Ye(Ie[0])),Ie[1]>Ie[0]&&(Ie[1]+1>Ie[0]&&We.push("-"),We.push(Ye(Ie[1])))}return We.push("]"),We.join("")}function at(Pe){for(var Se=Pe.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g")),Je=Se.length,nt=[],We=0,et=0;We<Je;++We){var Me=Se[We];if(Me==="(")++et;else if(Me.charAt(0)==="\\"){var Ce=+Me.substring(1);Ce&&(Ce<=et?nt[Ce]=-1:Se[We]=Ye(Ce))}}for(var We=1;We<nt.length;++We)nt[We]===-1&&(nt[We]=++J);for(var We=0,et=0;We<Je;++We){var Me=Se[We];if(Me==="(")++et,nt[et]||(Se[We]="(?:");else if(Me.charAt(0)==="\\"){var Ce=+Me.substring(1);Ce&&Ce<=et&&(Se[We]="\\"+nt[Ce])}}for(var We=0;We<Je;++We)Se[We]==="^"&&Se[We+1]!=="^"&&(Se[We]="");if(Pe.ignoreCase&&X)for(var We=0;We<Je;++We){var Me=Se[We],Re=Me.charAt(0);Me.length>=2&&Re==="["?Se[We]=rt(Me):Re!=="\\"&&(Se[We]=Me.replace(/[a-zA-Z]/g,function(we){var Ie=we.charCodeAt(0);return"["+String.fromCharCode(Ie&~32,Ie|32)+"]"}))}return Se.join("")}for(var ot=[],ge=0,fe=te.length;ge<fe;++ge){var Te=te[ge];if(Te.global||Te.multiline)throw new Error(""+Te);ot.push("(?:"+at(Te)+")")}return new RegExp(ot.join("|"),$?"gi":"g")}function k(te,J){var X=/(?:^|\s)nocode(?:\s|$)/,$=[],ge=0,fe=[],Te=0;function ze(Xe){var Ye=Xe.nodeType;if(Ye==1){if(X.test(Xe.className))return;for(var rt=Xe.firstChild;rt;rt=rt.nextSibling)ze(rt);var at=Xe.nodeName.toLowerCase();(at==="br"||at==="li")&&($[Te]=`
`,fe[Te<<1]=ge++,fe[Te++<<1|1]=Xe)}else if(Ye==3||Ye==4){var ot=Xe.nodeValue;ot.length&&(J?ot=ot.replace(/\r\n?/g,`
`):ot=ot.replace(/[ \t\r\n]+/g," "),$[Te]=ot,fe[Te<<1]=ge,ge+=ot.length,fe[Te++<<1|1]=Xe)}}return ze(te),{sourceCode:$.join("").replace(/\n$/,""),spans:fe}}function K(te,J,X,$,ge){if(!X)return;var fe={sourceNode:te,pre:1,langExtension:null,numberLines:null,sourceCode:X,spans:null,basePos:J,decorations:null};$(fe),ge.push.apply(ge,fe.decorations)}var Y=/\S/;function ne(te){for(var J=void 0,X=te.firstChild;X;X=X.nextSibling){var $=X.nodeType;J=$===1?J?te:X:$===3&&Y.test(X.nodeValue)?te:J}return J===te?void 0:J}function oe(te,J){var X={},$;(function(){for(var Te=te.concat(J),ze=[],Xe={},Ye=0,rt=Te.length;Ye<rt;++Ye){var at=Te[Ye],ot=at[3];if(ot)for(var Pe=ot.length;--Pe>=0;)X[ot.charAt(Pe)]=at;var Se=at[1],Je=""+Se;Xe.hasOwnProperty(Je)||(ze.push(Se),Xe[Je]=null)}ze.push(/[\0-\uffff]/),$=B(ze)})();var ge=J.length,fe=function(Te){for(var ze=Te.sourceCode,Xe=Te.basePos,Ye=Te.sourceNode,rt=[Xe,T],at=0,ot=ze.match($)||[],Pe={},Se=0,Je=ot.length;Se<Je;++Se){var nt=ot[Se],We=Pe[nt],et=void 0,Me;if(typeof We=="string")Me=!1;else{var Ce=X[nt.charAt(0)];if(Ce)et=nt.match(Ce[1]),We=Ce[0];else{for(var Re=0;Re<ge;++Re)if(Ce=J[Re],et=nt.match(Ce[1]),et){We=Ce[0];break}et||(We=T)}Me=We.length>=5&&We.substring(0,5)==="lang-",Me&&!(et&&typeof et[1]=="string")&&(Me=!1,We=P),Me||(Pe[nt]=We)}var pe=at;if(at+=nt.length,!Me)rt.push(Xe+pe,We);else{var ye=et[1],we=nt.indexOf(ye),Ie=we+ye.length;et[2]&&(Ie=nt.length-et[2].length,we=Ie-ye.length);var ke=We.substring(5);K(Ye,Xe+pe,nt.substring(0,we),fe,rt),K(Ye,Xe+pe+we,ye,ie(ke,ye),rt),K(Ye,Xe+pe+Ie,nt.substring(Ie),fe,rt)}}Te.decorations=rt};return fe}function _e(te){var J=[],X=[];te.tripleQuotedStrings?J.push([h,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,`'"`]):te.multiLineStrings?J.push([h,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"]):J.push([h,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,`"'`]),te.verbatimStrings&&X.push([h,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null]);var $=te.hashComments;$&&(te.cStyleComments?($>1?J.push([O,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"]):J.push([O,/^#(?:(?:define|e(?:l|nd)if|else|error|ifn?def|include|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"]),X.push([h,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h(?:h|pp|\+\+)?|[a-z]\w*)>/,null])):J.push([O,/^#[^\r\n]*/,null,"#"])),te.cStyleComments&&(X.push([O,/^\/\/[^\r\n]*/,null]),X.push([O,/^\/\*[\s\S]*?(?:\*\/|$)/,null]));var ge=te.regexLiterals;if(ge){var fe=ge>1?"":`
\r`,Te=fe?".":"[\\S\\s]",ze="/(?=[^/*"+fe+"])(?:[^/\\x5B\\x5C"+fe+"]|\\x5C"+Te+"|\\x5B(?:[^\\x5C\\x5D"+fe+"]|\\x5C"+Te+")*(?:\\x5D|$))+/";X.push(["lang-regex",RegExp("^"+z+"("+ze+")")])}var Xe=te.types;Xe&&X.push([g,Xe]);var Ye=(""+te.keywords).replace(/^ | $/g,"");Ye.length&&X.push([R,new RegExp("^(?:"+Ye.replace(/[\s,]+/g,"|")+")\\b"),null]),J.push([T,/^\s+/,null,` \r
\xA0`]);var rt="^.[^\\s\\w.$@'\"`/\\\\]*";return te.regexLiterals&&(rt+="(?!s*/)"),X.push([_,/^@[a-z_$][a-z_$@0-9]*/i,null],[g,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[T,/^[a-z_$][a-z_$@0-9]*/i,null],[_,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[T,/^\\[\s\S]?/,null],[E,new RegExp(rt),null]),oe(J,X)}var xe=_e({keywords:S,hashComments:!0,cStyleComments:!0,multiLineStrings:!0,regexLiterals:!0});function le(te,J,X){for(var $=/(?:^|\s)nocode(?:\s|$)/,ge=/\r\n?|\n/,fe=te.ownerDocument,Te=fe.createElement("li");te.firstChild;)Te.appendChild(te.firstChild);var ze=[Te];function Xe(Se){var Je=Se.nodeType;if(Je==1&&!$.test(Se.className))if(Se.nodeName==="br")Ye(Se),Se.parentNode&&Se.parentNode.removeChild(Se);else for(var nt=Se.firstChild;nt;nt=nt.nextSibling)Xe(nt);else if((Je==3||Je==4)&&X){var We=Se.nodeValue,et=We.match(ge);if(et){var Me=We.substring(0,et.index);Se.nodeValue=Me;var Ce=We.substring(et.index+et[0].length);if(Ce){var Re=Se.parentNode;Re.insertBefore(fe.createTextNode(Ce),Se.nextSibling)}Ye(Se),Me||Se.parentNode.removeChild(Se)}}}function Ye(Se){for(;!Se.nextSibling;)if(Se=Se.parentNode,!Se)return;function Je(et,Me){var Ce=Me?et.cloneNode(!1):et,Re=et.parentNode;if(Re){var pe=Je(Re,1),ye=et.nextSibling;pe.appendChild(Ce);for(var we=ye;we;we=ye)ye=we.nextSibling,pe.appendChild(we)}return Ce}for(var nt=Je(Se.nextSibling,0),We;(We=nt.parentNode)&&We.nodeType===1;)nt=We;ze.push(nt)}for(var rt=0;rt<ze.length;++rt)Xe(ze[rt]);J===(J|0)&&ze[0].setAttribute("value",J);var at=fe.createElement("ol");at.className="linenums";for(var ot=Math.max(0,J-1|0)||0,rt=0,Pe=ze.length;rt<Pe;++rt)Te=ze[rt],Te.className="L"+(rt+ot)%10,Te.firstChild||Te.appendChild(fe.createTextNode("\xA0")),at.appendChild(Te);te.appendChild(at)}function me(te){var J=/\bMSIE\s(\d+)/.exec(navigator.userAgent);J=J&&+J[1]<=8;var X=/\n/g,$=te.sourceCode,ge=$.length,fe=0,Te=te.spans,ze=Te.length,Xe=0,Ye=te.decorations,rt=Ye.length,at=0;Ye[rt]=ge;var ot,Pe;for(Pe=ot=0;Pe<rt;)Ye[Pe]!==Ye[Pe+2]?(Ye[ot++]=Ye[Pe++],Ye[ot++]=Ye[Pe++]):Pe+=2;for(rt=ot,Pe=ot=0;Pe<rt;){for(var Se=Ye[Pe],Je=Ye[Pe+1],nt=Pe+2;nt+2<=rt&&Ye[nt+1]===Je;)nt+=2;Ye[ot++]=Se,Ye[ot++]=Je,Pe=nt}rt=Ye.length=ot;var We=te.sourceNode,et="";We&&(et=We.style.display,We.style.display="none");try{for(var Me=null;Xe<ze;){var Ce=Te[Xe],Re=Te[Xe+2]||ge,pe=Ye[at+2]||ge,nt=Math.min(Re,pe),ye=Te[Xe+1],we;if(ye.nodeType!==1&&(we=$.substring(fe,nt))){J&&(we=we.replace(X,"\r")),ye.nodeValue=we;var Ie=ye.ownerDocument,ke=Ie.createElement("span");ke.className=Ye[at+1];var Ve=ye.parentNode;Ve.replaceChild(ke,ye),ke.appendChild(ye),fe<Re&&(Te[Xe+1]=ye=Ie.createTextNode($.substring(nt,Re)),Ve.insertBefore(ye,ke.nextSibling))}fe=nt,fe>=Re&&(Xe+=2),fe>=pe&&(at+=2)}}finally{We&&(We.style.display=et)}}var de={};function ae(te,J){for(var X=J.length;--X>=0;){var $=J[X];de.hasOwnProperty($)?b.console&&console.warn("cannot override language handler %s",$):de[$]=te}}function ie(te,J){return te&&de.hasOwnProperty(te)||(te=/^\s*</.test(J)?"default-markup":"default-code"),de[te]}ae(xe,["default-code"]),ae(oe([],[[T,/^[^<?]+/],[I,/^<!\w[^>]*(?:>|$)/],[O,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[E,/^(?:<[%?]|[%?]>)/],["lang-",/^<xmp\b[^>]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^<script\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^<style\b[^>]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]),ae(oe([[T,/^[\s]+/,null,` \r
`],[W,/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,`"'`]],[[L,/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],[G,/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],[E,/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]),ae(oe([],[[W,/^[\s\S]+/]]),["uq.val"]),ae(_e({keywords:c,hashComments:!0,cStyleComments:!0,types:x}),["c","cc","cpp","cxx","cyc","m"]),ae(_e({keywords:"null,true,false"}),["json"]),ae(_e({keywords:i,hashComments:!0,cStyleComments:!0,verbatimStrings:!0,types:x}),["cs"]),ae(_e({keywords:r,cStyleComments:!0}),["java"]),ae(_e({keywords:t,hashComments:!0,multiLineStrings:!0}),["bash","bsh","csh","sh"]),ae(_e({keywords:s,hashComments:!0,multiLineStrings:!0,tripleQuotedStrings:!0}),["cv","py","python"]),ae(_e({keywords:f,hashComments:!0,multiLineStrings:!0,regexLiterals:2}),["perl","pl","pm"]),ae(_e({keywords:l,hashComments:!0,multiLineStrings:!0,regexLiterals:!0}),["rb","ruby"]),ae(_e({keywords:u,cStyleComments:!0,regexLiterals:!0}),["javascript","js","ts","typescript"]),ae(_e({keywords:o,hashComments:3,cStyleComments:!0,multilineStrings:!0,tripleQuotedStrings:!0,regexLiterals:!0}),["coffee"]),ae(oe([],[[h,/^[\s\S]+/]]),["regex"]);function q(te){var J=te.langExtension;try{var X=k(te.sourceNode,te.pre),$=X.sourceCode;te.sourceCode=$,te.spans=X.spans,te.basePos=0,ie(J,$)(te),me(te)}catch(ge){b.console&&console.log(ge&&ge.stack||ge)}}function ue(te,J,X){var $=X||!1,ge=J||null,fe=document.createElement("div");fe.innerHTML="<pre>"+te+"</pre>",fe=fe.firstChild,$&&le(fe,$,!0);var Te={langExtension:ge,numberLines:$,sourceNode:fe,pre:1,sourceCode:null,basePos:null,spans:null,decorations:null};return q(Te),fe.innerHTML}function Z(te,J){var X=J||document.body,$=X.ownerDocument||document;function ge(Ce){return X.getElementsByTagName(Ce)}for(var fe=[ge("pre"),ge("code"),ge("xmp")],Te=[],ze=0;ze<fe.length;++ze)for(var Xe=0,Ye=fe[ze].length;Xe<Ye;++Xe)Te.push(fe[ze][Xe]);fe=null;var rt=Date;rt.now||(rt={now:function(){return+new Date}});var at=0,ot=/\blang(?:uage)?-([\w.]+)(?!\S)/,Pe=/\bprettyprint\b/,Se=/\bprettyprinted\b/,Je=/pre|xmp/i,nt=/^code$/i,We=/^(?:pre|code|xmp)$/i,et={};function Me(){for(var Ce=b.PR_SHOULD_USE_CONTINUATION?rt.now()+250:Infinity;at<Te.length&&rt.now()<Ce;at++){for(var Re=Te[at],pe=et,ye=Re;ye=ye.previousSibling;){var we=ye.nodeType,Ie=(we===7||we===8)&&ye.nodeValue;if(Ie?!/^\??prettify\b/.test(Ie):we!==3||/\S/.test(ye.nodeValue))break;if(Ie){pe={},Ie.replace(/\b(\w+)=([\w:.%+-]+)/g,function(ln,Sr,an){pe[Sr]=an});break}}var ke=Re.className;if((pe!==et||Pe.test(ke))&&!Se.test(ke)){for(var Ve=!1,ut=Re.parentNode;ut;ut=ut.parentNode){var ct=ut.tagName;if(We.test(ct)&&ut.className&&Pe.test(ut.className)){Ve=!0;break}}if(!Ve){Re.className+=" prettyprinted";var Lt=pe.lang;if(!Lt){Lt=ke.match(ot);var Dt;!Lt&&(Dt=ne(Re))&&nt.test(Dt.tagName)&&(Lt=Dt.className.match(ot)),Lt&&(Lt=Lt[1])}var Er;if(Je.test(Re.tagName))Er=1;else{var rr=Re.currentStyle,xt=$.defaultView,kr=rr?rr.whiteSpace:xt&&xt.getComputedStyle?xt.getComputedStyle(Re,null).getPropertyValue("white-space"):0;Er=kr&&kr.substring(0,3)==="pre"}var Mr=pe.linenums;(Mr=Mr==="true"||+Mr)||(Mr=ke.match(/\blinenums\b(?::(\d+))?/),Mr=Mr?Mr[1]&&Mr[1].length?+Mr[1]:!0:!1),Mr&&le(Re,Mr,Er);var Ur={langExtension:Lt,sourceNode:Re,numberLines:Mr,pre:Er,sourceCode:null,basePos:null,spans:null,decorations:null};q(Ur)}}}at<Te.length?b.setTimeout(Me,250):typeof te=="function"&&te()}Me()}var ee=b.PR={createSimpleLexer:oe,registerLangHandler:ae,sourceDecorator:_e,PR_ATTRIB_NAME:G,PR_ATTRIB_VALUE:W,PR_COMMENT:O,PR_DECLARATION:I,PR_KEYWORD:R,PR_LITERAL:_,PR_NOCODE:H,PR_PLAIN:T,PR_PUNCTUATION:E,PR_SOURCE:P,PR_STRING:h,PR_TAG:L,PR_TYPE:g,prettyPrintOne:C?b.prettyPrintOne=ue:y=ue,prettyPrint:w=C?b.prettyPrint=Z:w=Z},Ee=b.define;typeof Ee=="function"&&Ee.amd&&Ee("google-code-prettify",[],function(){return ee})})()},Sjjz:function(F,Q,j){F.exports={flexRow:"flexRow___1u_bL",flexColumn:"flexColumn___1kaUk",formWrap:"formWrap___31wys",example:"example___Cqoob",footerWrap:"footerWrap___2syNI"}},TXwP:function(F,Q,j){var N,v;(function(){var C;(function(){"use strict";var m=[,,function(p){function d(r){this.__parent=r,this.__character_count=0,this.__indent_count=-1,this.__alignment_count=0,this.__wrap_point_index=0,this.__wrap_point_character_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}d.prototype.clone_empty=function(){var r=new d(this.__parent);return r.set_indent(this.__indent_count,this.__alignment_count),r},d.prototype.item=function(r){return r<0?this.__items[this.__items.length+r]:this.__items[r]},d.prototype.has_match=function(r){for(var i=this.__items.length-1;i>=0;i--)if(this.__items[i].match(r))return!0;return!1},d.prototype.set_indent=function(r,i){this.is_empty()&&(this.__indent_count=r||0,this.__alignment_count=i||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},d.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},d.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},d.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var r=this.__parent.current_line;return r.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),r.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),r.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count,r.__items[0]===" "&&(r.__items.splice(0,1),r.__character_count-=1),!0}return!1},d.prototype.is_empty=function(){return this.__items.length===0},d.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},d.prototype.push=function(r){this.__items.push(r);var i=r.lastIndexOf(`
`);i!==-1?this.__character_count=r.length-i:this.__character_count+=r.length},d.prototype.pop=function(){var r=null;return this.is_empty()||(r=this.__items.pop(),this.__character_count-=r.length),r},d.prototype._remove_indent=function(){this.__indent_count>0&&(this.__indent_count-=1,this.__character_count-=this.__parent.indent_size)},d.prototype._remove_wrap_indent=function(){this.__wrap_point_indent_count>0&&(this.__wrap_point_indent_count-=1)},d.prototype.trim=function(){for(;this.last()===" ";)this.__items.pop(),this.__character_count-=1},d.prototype.toString=function(){var r="";return this.is_empty()?this.__parent.indent_empty_lines&&(r=this.__parent.get_indent_string(this.__indent_count)):(r=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),r+=this.__items.join("")),r};function n(r,i){this.__cache=[""],this.__indent_size=r.indent_size,this.__indent_string=r.indent_char,r.indent_with_tabs||(this.__indent_string=new Array(r.indent_size+1).join(r.indent_char)),i=i||"",r.indent_level>0&&(i=new Array(r.indent_level+1).join(this.__indent_string)),this.__base_string=i,this.__base_string_length=i.length}n.prototype.get_indent_size=function(r,i){var o=this.__base_string_length;return i=i||0,r<0&&(o=0),o+=r*this.__indent_size,o+=i,o},n.prototype.get_indent_string=function(r,i){var o=this.__base_string;return i=i||0,r<0&&(r=0,o=""),i+=r*this.__indent_size,this.__ensure_cache(i),o+=this.__cache[i],o},n.prototype.__ensure_cache=function(r){for(;r>=this.__cache.length;)this.__add_column()},n.prototype.__add_column=function(){var r=this.__cache.length,i=0,o="";this.__indent_size&&r>=this.__indent_size&&(i=Math.floor(r/this.__indent_size),r-=i*this.__indent_size,o=new Array(i+1).join(this.__indent_string)),r&&(o+=new Array(r+1).join(" ")),this.__cache.push(o)};function c(r,i){this.__indent_cache=new n(r,i),this.raw=!1,this._end_with_newline=r.end_with_newline,this.indent_size=r.indent_size,this.wrap_line_length=r.wrap_line_length,this.indent_empty_lines=r.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new d(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}c.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},c.prototype.get_line_number=function(){return this.__lines.length},c.prototype.get_indent_string=function(r,i){return this.__indent_cache.get_indent_string(r,i)},c.prototype.get_indent_size=function(r,i){return this.__indent_cache.get_indent_size(r,i)},c.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},c.prototype.add_new_line=function(r){return this.is_empty()||!r&&this.just_added_newline()?!1:(this.raw||this.__add_outputline(),!0)},c.prototype.get_code=function(r){this.trim(!0);var i=this.current_line.pop();i&&(i[i.length-1]===`
`&&(i=i.replace(/\n+$/g,"")),this.current_line.push(i)),this._end_with_newline&&this.__add_outputline();var o=this.__lines.join(`
`);return r!==`
`&&(o=o.replace(/[\n]/g,r)),o},c.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},c.prototype.set_indent=function(r,i){return r=r||0,i=i||0,this.next_line.set_indent(r,i),this.__lines.length>1?(this.current_line.set_indent(r,i),!0):(this.current_line.set_indent(),!1)},c.prototype.add_raw_token=function(r){for(var i=0;i<r.newlines;i++)this.__add_outputline();this.current_line.set_indent(-1),this.current_line.push(r.whitespace_before),this.current_line.push(r.text),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1},c.prototype.add_token=function(r){this.__add_space_before_token(),this.current_line.push(r),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=this.current_line._allow_wrap()},c.prototype.__add_space_before_token=function(){this.space_before_token&&!this.just_added_newline()&&(this.non_breaking_space||this.set_wrap_point(),this.current_line.push(" "))},c.prototype.remove_indent=function(r){for(var i=this.__lines.length;r<i;)this.__lines[r]._remove_indent(),r++;this.current_line._remove_wrap_indent()},c.prototype.trim=function(r){for(r=r===void 0?!1:r,this.current_line.trim();r&&this.__lines.length>1&&this.current_line.is_empty();)this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null},c.prototype.just_added_newline=function(){return this.current_line.is_empty()},c.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()},c.prototype.ensure_empty_line_above=function(r,i){for(var o=this.__lines.length-2;o>=0;){var u=this.__lines[o];if(u.is_empty())break;if(u.item(0).indexOf(r)!==0&&u.item(-1)!==i){this.__lines.splice(o+1,0,new d(this)),this.previous_line=this.__lines[this.__lines.length-2];break}o--}},p.exports.Output=c},,,,function(p){function d(r,i){this.raw_options=n(r,i),this.disabled=this._get_boolean("disabled"),this.eol=this._get_characters("eol","auto"),this.end_with_newline=this._get_boolean("end_with_newline"),this.indent_size=this._get_number("indent_size",4),this.indent_char=this._get_characters("indent_char"," "),this.indent_level=this._get_number("indent_level"),this.preserve_newlines=this._get_boolean("preserve_newlines",!0),this.max_preserve_newlines=this._get_number("max_preserve_newlines",32786),this.preserve_newlines||(this.max_preserve_newlines=0),this.indent_with_tabs=this._get_boolean("indent_with_tabs",this.indent_char===" "),this.indent_with_tabs&&(this.indent_char=" ",this.indent_size===1&&(this.indent_size=4)),this.wrap_line_length=this._get_number("wrap_line_length",this._get_number("max_char")),this.indent_empty_lines=this._get_boolean("indent_empty_lines"),this.templating=this._get_selection_list("templating",["auto","none","django","erb","handlebars","php","smarty"],["auto"])}d.prototype._get_array=function(r,i){var o=this.raw_options[r],u=i||[];return typeof o=="object"?o!==null&&typeof o.concat=="function"&&(u=o.concat()):typeof o=="string"&&(u=o.split(/[^a-zA-Z0-9_\/\-]+/)),u},d.prototype._get_boolean=function(r,i){var o=this.raw_options[r],u=o===void 0?!!i:!!o;return u},d.prototype._get_characters=function(r,i){var o=this.raw_options[r],u=i||"";return typeof o=="string"&&(u=o.replace(/\\r/,"\r").replace(/\\n/,`
`).replace(/\\t/," ")),u},d.prototype._get_number=function(r,i){var o=this.raw_options[r];i=parseInt(i,10),isNaN(i)&&(i=0);var u=parseInt(o,10);return isNaN(u)&&(u=i),u},d.prototype._get_selection=function(r,i,o){var u=this._get_selection_list(r,i,o);if(u.length!==1)throw new Error("Invalid Option Value: The option '"+r+`' can only be one of the following values:
`+i+`
You passed in: '`+this.raw_options[r]+"'");return u[0]},d.prototype._get_selection_list=function(r,i,o){if(!i||i.length===0)throw new Error("Selection list cannot be empty.");if(o=o||[i[0]],!this._is_valid_selection(o,i))throw new Error("Invalid Default Value!");var u=this._get_array(r,o);if(!this._is_valid_selection(u,i))throw new Error("Invalid Option Value: The option '"+r+`' can contain only the following values:
`+i+`
You passed in: '`+this.raw_options[r]+"'");return u},d.prototype._is_valid_selection=function(r,i){return r.length&&i.length&&!r.some(function(o){return i.indexOf(o)===-1})};function n(r,i){var o={};r=c(r);var u;for(u in r)u!==i&&(o[u]=r[u]);if(i&&r[i])for(u in r[i])o[u]=r[i][u];return o}function c(r){var i={},o;for(o in r){var u=o.replace(/-/g,"_");i[u]=r[o]}return i}p.exports.Options=d,p.exports.normalizeOpts=c,p.exports.mergeOpts=n},,function(p){var d=RegExp.prototype.hasOwnProperty("sticky");function n(c){this.__input=c||"",this.__input_length=this.__input.length,this.__position=0}n.prototype.restart=function(){this.__position=0},n.prototype.back=function(){this.__position>0&&(this.__position-=1)},n.prototype.hasNext=function(){return this.__position<this.__input_length},n.prototype.next=function(){var c=null;return this.hasNext()&&(c=this.__input.charAt(this.__position),this.__position+=1),c},n.prototype.peek=function(c){var r=null;return c=c||0,c+=this.__position,c>=0&&c<this.__input_length&&(r=this.__input.charAt(c)),r},n.prototype.__match=function(c,r){c.lastIndex=r;var i=c.exec(this.__input);return i&&!(d&&c.sticky)&&(i.index!==r&&(i=null)),i},n.prototype.test=function(c,r){return r=r||0,r+=this.__position,r>=0&&r<this.__input_length?!!this.__match(c,r):!1},n.prototype.testChar=function(c,r){var i=this.peek(r);return c.lastIndex=0,i!==null&&c.test(i)},n.prototype.match=function(c){var r=this.__match(c,this.__position);return r?this.__position+=r[0].length:r=null,r},n.prototype.read=function(c,r,i){var o="",u;return c&&(u=this.match(c),u&&(o+=u[0])),r&&(u||!c)&&(o+=this.readUntil(r,i)),o},n.prototype.readUntil=function(c,r){var i="",o=this.__position;c.lastIndex=this.__position;var u=c.exec(this.__input);return u?(o=u.index,r&&(o+=u[0].length)):o=this.__input_length,i=this.__input.substring(this.__position,o),this.__position=o,i},n.prototype.readUntilAfter=function(c){return this.readUntil(c,!0)},n.prototype.get_regexp=function(c,r){var i=null,o="g";return r&&d&&(o="y"),typeof c=="string"&&c!==""?i=new RegExp(c,o):c&&(i=new RegExp(c.source,o)),i},n.prototype.get_literal_regexp=function(c){return RegExp(c.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))},n.prototype.peekUntilAfter=function(c){var r=this.__position,i=this.readUntilAfter(c);return this.__position=r,i},n.prototype.lookBack=function(c){var r=this.__position-1;return r>=c.length&&this.__input.substring(r-c.length,r).toLowerCase()===c},p.exports.InputScanner=n},,,,,function(p){function d(n,c){n=typeof n=="string"?n:n.source,c=typeof c=="string"?c:c.source,this.__directives_block_pattern=new RegExp(n+/ beautify( \w+[:]\w+)+ /.source+c,"g"),this.__directive_pattern=/ (\w+)[:](\w+)/g,this.__directives_end_ignore_pattern=new RegExp(n+/\sbeautify\signore:end\s/.source+c,"g")}d.prototype.get_directives=function(n){if(!n.match(this.__directives_block_pattern))return null;var c={};this.__directive_pattern.lastIndex=0;for(var r=this.__directive_pattern.exec(n);r;)c[r[1]]=r[2],r=this.__directive_pattern.exec(n);return c},d.prototype.readIgnored=function(n){return n.readUntilAfter(this.__directives_end_ignore_pattern)},p.exports.Directives=d},,function(p,d,n){var c=n(16).Beautifier,r=n(17).Options;function i(o,u){var f=new c(o,u);return f.beautify()}p.exports=i,p.exports.defaultOptions=function(){return new r}},function(p,d,n){var c=n(17).Options,r=n(2).Output,i=n(8).InputScanner,o=n(13).Directives,u=new o(/\/\*/,/\*\//),f=/\r\n|[\r\n]/,s=/\r\n|[\r\n]/g,l=/\s/,t=/(?:\s|\n)+/g,S=/\/\*(?:[\s\S]*?)((?:\*\/)|$)/g,x=/\/\/(?:[^\n\r\u2028\u2029]*)/g;function h(R,O){this._source_text=R||"",this._options=new c(O),this._ch=null,this._input=null,this.NESTED_AT_RULE={"@page":!0,"@font-face":!0,"@keyframes":!0,"@media":!0,"@supports":!0,"@document":!0},this.CONDITIONAL_GROUP_RULE={"@media":!0,"@supports":!0,"@document":!0},this.NON_SEMICOLON_NEWLINE_PROPERTY=["grid-template-areas","grid-template"]}h.prototype.eatString=function(R){var O="";for(this._ch=this._input.next();this._ch;){if(O+=this._ch,this._ch==="\\")O+=this._input.next();else if(R.indexOf(this._ch)!==-1||this._ch===`
`)break;this._ch=this._input.next()}return O},h.prototype.eatWhitespace=function(R){for(var O=l.test(this._input.peek()),g=0;l.test(this._input.peek());)this._ch=this._input.next(),R&&this._ch===`
`&&((g===0||g<this._options.max_preserve_newlines)&&(g++,this._output.add_new_line(!0)));return O},h.prototype.foundNestedPseudoClass=function(){for(var R=0,O=1,g=this._input.peek(O);g;){if(g==="{")return!0;if(g==="(")R+=1;else if(g===")"){if(R===0)return!1;R-=1}else if(g===";"||g==="}")return!1;O++,g=this._input.peek(O)}return!1},h.prototype.print_string=function(R){this._output.set_indent(this._indentLevel),this._output.non_breaking_space=!0,this._output.add_token(R)},h.prototype.preserveSingleSpace=function(R){R&&(this._output.space_before_token=!0)},h.prototype.indent=function(){this._indentLevel++},h.prototype.outdent=function(){this._indentLevel>0&&this._indentLevel--},h.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var R=this._source_text,O=this._options.eol;O==="auto"&&(O=`
`,R&&f.test(R||"")&&(O=R.match(f)[0])),R=R.replace(s,`
`);var g=R.match(/^[\t ]*/)[0];this._output=new r(this._options,g),this._input=new i(R),this._indentLevel=0,this._nestedLevel=0,this._ch=null;for(var _=0,E=!1,T=!1,L=!1,I=!1,P=!1,G=!1,W=this._ch,H=!1,z,B,k;z=this._input.read(t),B=z!=="",k=W,this._ch=this._input.next(),this._ch==="\\"&&this._input.hasNext()&&(this._ch+=this._input.next()),W=this._ch,this._ch;)if(this._ch==="/"&&this._input.peek()==="*"){this._output.add_new_line(),this._input.back();var K=this._input.read(S),Y=u.get_directives(K);Y&&Y.ignore==="start"&&(K+=u.readIgnored(this._input)),this.print_string(K),this.eatWhitespace(!0),this._output.add_new_line()}else if(this._ch==="/"&&this._input.peek()==="/")this._output.space_before_token=!0,this._input.back(),this.print_string(this._input.read(x)),this.eatWhitespace(!0);else if(this._ch==="@"||this._ch==="$")if(this.preserveSingleSpace(B),this._input.peek()==="{")this.print_string(this._ch+this.eatString("}"));else{this.print_string(this._ch);var ne=this._input.peekUntilAfter(/[: ,;{}()[\]\/='"]/g);ne.match(/[ :]$/)&&(ne=this.eatString(": ").replace(/\s$/,""),this.print_string(ne),this._output.space_before_token=!0),ne=ne.replace(/\s$/,""),ne==="extend"?I=!0:ne==="import"&&(P=!0),ne in this.NESTED_AT_RULE?(this._nestedLevel+=1,ne in this.CONDITIONAL_GROUP_RULE&&(L=!0)):!E&&_===0&&ne.indexOf(":")!==-1&&(T=!0,this.indent())}else if(this._ch==="#"&&this._input.peek()==="{")this.preserveSingleSpace(B),this.print_string(this._ch+this.eatString("}"));else if(this._ch==="{")T&&(T=!1,this.outdent()),L?(L=!1,E=this._indentLevel>=this._nestedLevel):E=this._indentLevel>=this._nestedLevel-1,this._options.newline_between_rules&&E&&(this._output.previous_line&&this._output.previous_line.item(-1)!=="{"&&this._output.ensure_empty_line_above("/",",")),this._output.space_before_token=!0,this._options.brace_style==="expand"?(this._output.add_new_line(),this.print_string(this._ch),this.indent(),this._output.set_indent(this._indentLevel)):(k==="("?this._output.space_before_token=!1:k!==","&&this.indent(),this.print_string(this._ch)),this.eatWhitespace(!0),this._output.add_new_line();else if(this._ch==="}")this.outdent(),this._output.add_new_line(),k==="{"&&this._output.trim(!0),P=!1,I=!1,T&&(this.outdent(),T=!1),this.print_string(this._ch),E=!1,this._nestedLevel&&this._nestedLevel--,this.eatWhitespace(!0),this._output.add_new_line(),this._options.newline_between_rules&&!this._output.just_added_blankline()&&(this._input.peek()!=="}"&&this._output.add_new_line(!0)),this._input.peek()===")"&&(this._output.trim(!0),this._options.brace_style==="expand"&&this._output.add_new_line(!0));else if(this._ch===":"){for(var oe=0;oe<this.NON_SEMICOLON_NEWLINE_PROPERTY.length;oe++)if(this._input.lookBack(this.NON_SEMICOLON_NEWLINE_PROPERTY[oe])){H=!0;break}(E||L)&&!(this._input.lookBack("&")||this.foundNestedPseudoClass())&&!this._input.lookBack("(")&&!I&&_===0?(this.print_string(":"),T||(T=!0,this._output.space_before_token=!0,this.eatWhitespace(!0),this.indent())):(this._input.lookBack(" ")&&(this._output.space_before_token=!0),this._input.peek()===":"?(this._ch=this._input.next(),this.print_string("::")):this.print_string(":"))}else if(this._ch==='"'||this._ch==="'"){var _e=k==='"'||k==="'";this.preserveSingleSpace(_e||B),this.print_string(this._ch+this.eatString(this._ch)),this.eatWhitespace(!0)}else if(this._ch===";")H=!1,_===0?(T&&(this.outdent(),T=!1),I=!1,P=!1,this.print_string(this._ch),this.eatWhitespace(!0),this._input.peek()!=="/"&&this._output.add_new_line()):(this.print_string(this._ch),this.eatWhitespace(!0),this._output.space_before_token=!0);else if(this._ch==="(")if(this._input.lookBack("url"))this.print_string(this._ch),this.eatWhitespace(),_++,this.indent(),this._ch=this._input.next(),this._ch===")"||this._ch==='"'||this._ch==="'"?this._input.back():this._ch&&(this.print_string(this._ch+this.eatString(")")),_&&(_--,this.outdent()));else{var xe=!1;this._input.lookBack("with")&&(xe=!0),this.preserveSingleSpace(B||xe),this.print_string(this._ch),T&&k==="$"&&this._options.selector_separator_newline?(this._output.add_new_line(),G=!0):(this.eatWhitespace(),_++,this.indent())}else if(this._ch===")")_&&(_--,this.outdent()),G&&this._input.peek()===";"&&this._options.selector_separator_newline&&(G=!1,this.outdent(),this._output.add_new_line()),this.print_string(this._ch);else if(this._ch===",")this.print_string(this._ch),this.eatWhitespace(!0),this._options.selector_separator_newline&&(!T||G)&&_===0&&!P&&!I?this._output.add_new_line():this._output.space_before_token=!0;else if((this._ch===">"||this._ch==="+"||this._ch==="~")&&!T&&_===0)this._options.space_around_combinator?(this._output.space_before_token=!0,this.print_string(this._ch),this._output.space_before_token=!0):(this.print_string(this._ch),this.eatWhitespace(),this._ch&&l.test(this._ch)&&(this._ch=""));else if(this._ch==="]")this.print_string(this._ch);else if(this._ch==="[")this.preserveSingleSpace(B),this.print_string(this._ch);else if(this._ch==="=")this.eatWhitespace(),this.print_string("="),l.test(this._ch)&&(this._ch="");else if(this._ch==="!"&&!this._input.lookBack("\\"))this._output.space_before_token=!0,this.print_string(this._ch);else{var le=k==='"'||k==="'";this.preserveSingleSpace(le||B),this.print_string(this._ch),!this._output.just_added_newline()&&this._input.peek()===`
`&&H&&this._output.add_new_line()}var me=this._output.get_code(O);return me},p.exports.Beautifier=h},function(p,d,n){var c=n(6).Options;function r(i){c.call(this,i,"css"),this.selector_separator_newline=this._get_boolean("selector_separator_newline",!0),this.newline_between_rules=this._get_boolean("newline_between_rules",!0);var o=this._get_boolean("space_around_selector_separator");this.space_around_combinator=this._get_boolean("space_around_combinator")||o;var u=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_style="collapse";for(var f=0;f<u.length;f++)u[f]!=="expand"?this.brace_style="collapse":this.brace_style=u[f]}r.prototype=new c,p.exports.Options=r}],y={};function w(p){var d=y[p];if(d!==void 0)return d.exports;var n=y[p]={exports:{}};return m[p](n,n.exports,w),n.exports}var b=w(15);C=b})();var M=C;!(N=[],v=function(){return{css_beautify:M}}.apply(Q,N),v!==void 0&&(F.exports=v))})()},UfjD:function(F,Q,j){"use strict";var N=j("2qtc"),v=j("kLXV"),C=j("5NDa"),M=j("5rEg"),m=j("miYZ"),y=j("tsqr"),w=j("tJVT"),b=j("cDcd"),p=j.n(b),d=j("4i/N");function n(c){var r=c.isjoin,i=c.setJoin,o=c.JoinTeams,u=Object(b.useState)(""),f=Object(w.a)(u,2),s=f[0],l=f[1];return p.a.createElement(v.a,{centered:!0,title:p.a.createElement("div",{style:{alignItems:"center",display:"flex"}},p.a.createElement("div",{style:{textAlign:"left",flex:"1"}},"\u52A0\u5165\u6218\u961F"),p.a.createElement(d.a,{onClick:function(){return i(!1)},style:{cursor:"porint"}})),visible:r,closable:!1,destroyOnClose:!0,onOk:function(){if(!s){y.b.info("\u9080\u8BF7\u7801\u4E0D\u80FD\u4E3A\u7A7A");return}o(s)},onCancel:function(){return i(!1)}},p.a.createElement("div",null,p.a.createElement("p",{style:{marginTop:"15px",marginLeft:"15px",display:"flex",alignItems:"center"}},p.a.createElement("span",{style:{flex:"none"}},"\u9080\u8BF7\u7801\uFF1A")," ",p.a.createElement(M.a,{placeholder:"\u8BF7\u8F93\u5165\u9080\u8BF7\u7801",value:s,maxLength:60,addonAfter:String(s&&s.length||0)+"/60",onChange:function(S){return l(S.target.value)}}))))}Q.a=n},"VrN/":function(F,Q,j){(function(N,v){F.exports=v()})(this,function(){"use strict";var N=navigator.userAgent,v=navigator.platform,C=/gecko\/\d/i.test(N),M=/MSIE \d/.test(N),m=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(N),y=/Edge\/(\d+)/.exec(N),w=M||m||y,b=w&&(M?document.documentMode||6:+(y||m)[1]),p=!y&&/WebKit\//.test(N),d=p&&/Qt\/\d+\.\d+/.test(N),n=!y&&/Chrome\//.test(N),c=/Opera\//.test(N),r=/Apple Computer/.test(navigator.vendor),i=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(N),o=/PhantomJS/.test(N),u=!y&&/AppleWebKit/.test(N)&&/Mobile\/\w+/.test(N),f=/Android/.test(N),s=u||f||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(N),l=u||/Mac/.test(v),t=/\bCrOS\b/.test(N),S=/win/i.test(v),x=c&&N.match(/Version\/(\d*\.\d*)/);x&&(x=Number(x[1])),x&&x>=15&&(c=!1,p=!0);var h=l&&(d||c&&(x==null||x<12.11)),R=C||w&&b>=9;function O(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var g=function(e,a){var D=e.className,A=O(a).exec(D);if(A){var U=D.slice(A.index+A[0].length);e.className=D.slice(0,A.index)+(U?A[1]+U:"")}};function _(e){for(var a=e.childNodes.length;a>0;--a)e.removeChild(e.firstChild);return e}function E(e,a){return _(e).appendChild(a)}function T(e,a,D,A){var U=document.createElement(e);if(D&&(U.className=D),A&&(U.style.cssText=A),typeof a=="string")U.appendChild(document.createTextNode(a));else if(a)for(var V=0;V<a.length;++V)U.appendChild(a[V]);return U}function L(e,a,D,A){var U=T(e,a,D,A);return U.setAttribute("role","presentation"),U}var I;document.createRange?I=function(e,a,D,A){var U=document.createRange();return U.setEnd(A||e,D),U.setStart(e,a),U}:I=function(e,a,D){var A=document.body.createTextRange();try{A.moveToElementText(e.parentNode)}catch(U){return A}return A.collapse(!0),A.moveEnd("character",D),A.moveStart("character",a),A};function P(e,a){if(a.nodeType==3&&(a=a.parentNode),e.contains)return e.contains(a);do if(a.nodeType==11&&(a=a.host),a==e)return!0;while(a=a.parentNode)}function G(){var e;try{e=document.activeElement}catch(a){e=document.body||null}for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function W(e,a){var D=e.className;O(a).test(D)||(e.className+=(D?" ":"")+a)}function H(e,a){for(var D=e.split(" "),A=0;A<D.length;A++)D[A]&&!O(D[A]).test(a)&&(a+=" "+D[A]);return a}var z=function(e){e.select()};u?z=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:w&&(z=function(e){try{e.select()}catch(a){}});function B(e){var a=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,a)}}function k(e,a,D){a||(a={});for(var A in e)e.hasOwnProperty(A)&&(D!==!1||!a.hasOwnProperty(A))&&(a[A]=e[A]);return a}function K(e,a,D,A,U){a==null&&(a=e.search(/[^\s\u00a0]/),a==-1&&(a=e.length));for(var V=A||0,re=U||0;;){var se=e.indexOf(" ",V);if(se<0||se>=a)return re+(a-V);re+=se-V,re+=D-re%D,V=se+1}}var Y=function(){this.id=null,this.f=null,this.time=0,this.handler=B(this.onTimeout,this)};Y.prototype.onTimeout=function(e){e.id=0,e.time<=+new Date?e.f():setTimeout(e.handler,e.time-+new Date)},Y.prototype.set=function(e,a){this.f=a;var D=+new Date+e;(!this.id||D<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,e),this.time=D)};function ne(e,a){for(var D=0;D<e.length;++D)if(e[D]==a)return D;return-1}var oe=50,_e={toString:function(){return"CodeMirror.Pass"}},xe={scroll:!1},le={origin:"*mouse"},me={origin:"+move"};function de(e,a,D){for(var A=0,U=0;;){var V=e.indexOf(" ",A);V==-1&&(V=e.length);var re=V-A;if(V==e.length||U+re>=a)return A+Math.min(re,a-U);if(U+=V-A,U+=D-U%D,A=V+1,U>=a)return A}}var ae=[""];function ie(e){for(;ae.length<=e;)ae.push(q(ae)+" ");return ae[e]}function q(e){return e[e.length-1]}function ue(e,a){for(var D=[],A=0;A<e.length;A++)D[A]=a(e[A],A);return D}function Z(e,a,D){for(var A=0,U=D(a);A<e.length&&D(e[A])<=U;)A++;e.splice(A,0,a)}function ee(){}function Ee(e,a){var D;return Object.create?D=Object.create(e):(ee.prototype=e,D=new ee),a&&k(a,D),D}var te=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function J(e){return/\w/.test(e)||e>"\x80"&&(e.toUpperCase()!=e.toLowerCase()||te.test(e))}function X(e,a){return a?a.source.indexOf("\\w")>-1&&J(e)?!0:a.test(e):J(e)}function $(e){for(var a in e)if(e.hasOwnProperty(a)&&e[a])return!1;return!0}var ge=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function fe(e){return e.charCodeAt(0)>=768&&ge.test(e)}function Te(e,a,D){for(;(D<0?a>0:a<e.length)&&fe(e.charAt(a));)a+=D;return a}function ze(e,a,D){for(var A=a>D?-1:1;;){if(a==D)return a;var U=(a+D)/2,V=A<0?Math.ceil(U):Math.floor(U);if(V==a)return e(V)?a:D;e(V)?D=V:a=V+A}}function Xe(e,a,D,A){if(!e)return A(a,D,"ltr",0);for(var U=!1,V=0;V<e.length;++V){var re=e[V];(re.from<D&&re.to>a||a==D&&re.to==a)&&(A(Math.max(re.from,a),Math.min(re.to,D),re.level==1?"rtl":"ltr",V),U=!0)}U||A(a,D,"ltr")}var Ye=null;function rt(e,a,D){var A;Ye=null;for(var U=0;U<e.length;++U){var V=e[U];if(V.from<a&&V.to>a)return U;V.to==a&&(V.from!=V.to&&D=="before"?A=U:Ye=U),V.from==a&&(V.from!=V.to&&D!="before"?A=U:Ye=U)}return A!=null?A:Ye}var at=function(){var e="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",a="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function D(ve){return ve<=247?e.charAt(ve):1424<=ve&&ve<=1524?"R":1536<=ve&&ve<=1785?a.charAt(ve-1536):1774<=ve&&ve<=2220?"r":8192<=ve&&ve<=8203?"w":ve==8204?"b":"L"}var A=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,U=/[stwN]/,V=/[LRr]/,re=/[Lb1n]/,se=/[1n]/;function ce(ve,Ne,He){this.level=ve,this.from=Ne,this.to=He}return function(ve,Ne){var He=Ne=="ltr"?"L":"R";if(ve.length==0||Ne=="ltr"&&!A.test(ve))return!1;for(var tt=ve.length,$e=[],vt=0;vt<tt;++vt)$e.push(D(ve.charCodeAt(vt)));for(var Rt=0,Ft=He;Rt<tt;++Rt){var Yt=$e[Rt];Yt=="m"?$e[Rt]=Ft:Ft=Yt}for(var sr=0,$t=He;sr<tt;++sr){var pr=$e[sr];pr=="1"&&$t=="r"?$e[sr]="n":V.test(pr)&&($t=pr,pr=="r"&&($e[sr]="R"))}for(var Fr=1,Dr=$e[0];Fr<tt-1;++Fr){var sn=$e[Fr];sn=="+"&&Dr=="1"&&$e[Fr+1]=="1"?$e[Fr]="1":sn==","&&Dr==$e[Fr+1]&&(Dr=="1"||Dr=="n")&&($e[Fr]=Dr),Dr=sn}for(var Dn=0;Dn<tt;++Dn){var ca=$e[Dn];if(ca==",")$e[Dn]="N";else if(ca=="%"){var Wn=void 0;for(Wn=Dn+1;Wn<tt&&$e[Wn]=="%";++Wn);for(var Ga=Dn&&$e[Dn-1]=="!"||Wn<tt&&$e[Wn]=="1"?"1":"N",Ua=Dn;Ua<Wn;++Ua)$e[Ua]=Ga;Dn=Wn-1}}for(var qn=0,Ba=He;qn<tt;++qn){var ya=$e[qn];Ba=="L"&&ya=="1"?$e[qn]="L":V.test(ya)&&(Ba=ya)}for(var sa=0;sa<tt;++sa)if(U.test($e[sa])){var ea=void 0;for(ea=sa+1;ea<tt&&U.test($e[ea]);++ea);for(var Gn=(sa?$e[sa-1]:He)=="L",Ha=(ea<tt?$e[ea]:He)=="L",lo=Gn==Ha?Gn?"L":"R":He,Ui=sa;Ui<ea;++Ui)$e[Ui]=lo;sa=ea-1}for(var Oa=[],yi,da=0;da<tt;)if(re.test($e[da])){var ps=da;for(++da;da<tt&&re.test($e[da]);++da);Oa.push(new ce(0,ps,da))}else{var Ii=da,Gi=Oa.length,Xi=Ne=="rtl"?1:0;for(++da;da<tt&&$e[da]!="L";++da);for(var La=Ii;La<da;)if(se.test($e[La])){Ii<La&&(Oa.splice(Gi,0,new ce(1,Ii,La)),Gi+=Xi);var uo=La;for(++La;La<da&&se.test($e[La]);++La);Oa.splice(Gi,0,new ce(2,uo,La)),Gi+=Xi,Ii=La}else++La;Ii<da&&Oa.splice(Gi,0,new ce(1,Ii,da))}return Ne=="ltr"&&(Oa[0].level==1&&(yi=ve.match(/^\s+/))&&(Oa[0].from=yi[0].length,Oa.unshift(new ce(0,0,yi[0].length))),q(Oa).level==1&&(yi=ve.match(/\s+$/))&&(q(Oa).to-=yi[0].length,Oa.push(new ce(0,tt-yi[0].length,tt)))),Ne=="rtl"?Oa.reverse():Oa}}();function ot(e,a){var D=e.order;return D==null&&(D=e.order=at(e.text,a)),D}var Pe=[],Se=function(e,a,D){if(e.addEventListener)e.addEventListener(a,D,!1);else if(e.attachEvent)e.attachEvent("on"+a,D);else{var A=e._handlers||(e._handlers={});A[a]=(A[a]||Pe).concat(D)}};function Je(e,a){return e._handlers&&e._handlers[a]||Pe}function nt(e,a,D){if(e.removeEventListener)e.removeEventListener(a,D,!1);else if(e.detachEvent)e.detachEvent("on"+a,D);else{var A=e._handlers,U=A&&A[a];if(U){var V=ne(U,D);V>-1&&(A[a]=U.slice(0,V).concat(U.slice(V+1)))}}}function We(e,a){var D=Je(e,a);if(!D.length)return;for(var A=Array.prototype.slice.call(arguments,2),U=0;U<D.length;++U)D[U].apply(null,A)}function et(e,a,D){return typeof a=="string"&&(a={type:a,preventDefault:function(){this.defaultPrevented=!0}}),We(e,D||a.type,e,a),we(a)||a.codemirrorIgnore}function Me(e){var a=e._handlers&&e._handlers.cursorActivity;if(!a)return;for(var D=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),A=0;A<a.length;++A)ne(D,a[A])==-1&&D.push(a[A])}function Ce(e,a){return Je(e,a).length>0}function Re(e){e.prototype.on=function(a,D){Se(this,a,D)},e.prototype.off=function(a,D){nt(this,a,D)}}function pe(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function ye(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function we(e){return e.defaultPrevented!=null?e.defaultPrevented:e.returnValue==!1}function Ie(e){pe(e),ye(e)}function ke(e){return e.target||e.srcElement}function Ve(e){var a=e.which;return a==null&&(e.button&1?a=1:e.button&2?a=3:e.button&4&&(a=2)),l&&e.ctrlKey&&a==1&&(a=3),a}var ut=function(){if(w&&b<9)return!1;var e=T("div");return"draggable"in e||"dragDrop"in e}(),ct;function Lt(e){if(ct==null){var a=T("span","\u200B");E(e,T("span",[a,document.createTextNode("x")])),e.firstChild.offsetHeight!=0&&(ct=a.offsetWidth<=1&&a.offsetHeight>2&&!(w&&b<8))}var D=ct?T("span","\u200B"):T("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return D.setAttribute("cm-text",""),D}var Dt;function Er(e){if(Dt!=null)return Dt;var a=E(e,document.createTextNode("A\u062EA")),D=I(a,0,1).getBoundingClientRect(),A=I(a,1,2).getBoundingClientRect();return _(e),!D||D.left==D.right?!1:Dt=A.right-D.right<3}var rr=`
b`.split(/\n/).length!=3?function(e){for(var a=0,D=[],A=e.length;a<=A;){var U=e.indexOf(`
`,a);U==-1&&(U=e.length);var V=e.slice(a,e.charAt(U-1)=="\r"?U-1:U),re=V.indexOf("\r");re!=-1?(D.push(V.slice(0,re)),a+=re+1):(D.push(V),a=U+1)}return D}:function(e){return e.split(/\r\n?|\n/)},xt=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(a){return!1}}:function(e){var a;try{a=e.ownerDocument.selection.createRange()}catch(D){}return!a||a.parentElement()!=e?!1:a.compareEndPoints("StartToEnd",a)!=0},kr=function(){var e=T("div");return"oncopy"in e?!0:(e.setAttribute("oncopy","return;"),typeof e.oncopy=="function")}(),Mr=null;function Ur(e){if(Mr!=null)return Mr;var a=E(e,T("span","x")),D=a.getBoundingClientRect(),A=I(a,0,1).getBoundingClientRect();return Mr=Math.abs(D.left-A.left)>1}var ln={},Sr={};function an(e,a){arguments.length>2&&(a.dependencies=Array.prototype.slice.call(arguments,2)),ln[e]=a}function qr(e,a){Sr[e]=a}function Bt(e){if(typeof e=="string"&&Sr.hasOwnProperty(e))e=Sr[e];else if(e&&typeof e.name=="string"&&Sr.hasOwnProperty(e.name)){var a=Sr[e.name];typeof a=="string"&&(a={name:a}),e=Ee(a,e),e.name=a.name}else{if(typeof e=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(e))return Bt("application/xml");if(typeof e=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(e))return Bt("application/json")}return typeof e=="string"?{name:e}:e||{name:"null"}}function ur(e,a){a=Bt(a);var D=ln[a.name];if(!D)return ur(e,"text/plain");var A=D(e,a);if(jr.hasOwnProperty(a.name)){var U=jr[a.name];for(var V in U){if(!U.hasOwnProperty(V))continue;A.hasOwnProperty(V)&&(A["_"+V]=A[V]),A[V]=U[V]}}if(A.name=a.name,a.helperType&&(A.helperType=a.helperType),a.modeProps)for(var re in a.modeProps)A[re]=a.modeProps[re];return A}var jr={};function en(e,a){var D=jr.hasOwnProperty(e)?jr[e]:jr[e]={};k(a,D)}function Jr(e,a){if(a===!0)return a;if(e.copyState)return e.copyState(a);var D={};for(var A in a){var U=a[A];U instanceof Array&&(U=U.concat([])),D[A]=U}return D}function _a(e,a){for(var D;e.innerMode&&!(D=e.innerMode(a),!D||D.mode==e);)a=D.state,e=D.mode;return D||{mode:e,state:a}}function Wa(e,a,D){return e.startState?e.startState(a,D):!0}var _n=function(e,a,D){this.pos=this.start=0,this.string=e,this.tabSize=a||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=D};_n.prototype.eol=function(){return this.pos>=this.string.length},_n.prototype.sol=function(){return this.pos==this.lineStart},_n.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},_n.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},_n.prototype.eat=function(e){var a=this.string.charAt(this.pos),D;if(typeof e=="string"?D=a==e:D=a&&(e.test?e.test(a):e(a)),D)return++this.pos,a},_n.prototype.eatWhile=function(e){for(var a=this.pos;this.eat(e););return this.pos>a},_n.prototype.eatSpace=function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},_n.prototype.skipToEnd=function(){this.pos=this.string.length},_n.prototype.skipTo=function(e){var a=this.string.indexOf(e,this.pos);if(a>-1)return this.pos=a,!0},_n.prototype.backUp=function(e){this.pos-=e},_n.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=K(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?K(this.string,this.lineStart,this.tabSize):0)},_n.prototype.indentation=function(){return K(this.string,null,this.tabSize)-(this.lineStart?K(this.string,this.lineStart,this.tabSize):0)},_n.prototype.match=function(e,a,D){if(typeof e=="string"){var A=function(re){return D?re.toLowerCase():re},U=this.string.substr(this.pos,e.length);if(A(U)==A(e))return a!==!1&&(this.pos+=e.length),!0}else{var V=this.string.slice(this.pos).match(e);return V&&V.index>0?null:(V&&a!==!1&&(this.pos+=V[0].length),V)}},_n.prototype.current=function(){return this.string.slice(this.start,this.pos)},_n.prototype.hideFirstChars=function(e,a){this.lineStart+=e;try{return a()}finally{this.lineStart-=e}},_n.prototype.lookAhead=function(e){var a=this.lineOracle;return a&&a.lookAhead(e)},_n.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};function er(e,a){if(a-=e.first,a<0||a>=e.size)throw new Error("There is no line "+(a+e.first)+" in the document.");for(var D=e;!D.lines;)for(var A=0;;++A){var U=D.children[A],V=U.chunkSize();if(a<V){D=U;break}a-=V}return D.lines[a]}function Xn(e,a,D){var A=[],U=a.line;return e.iter(a.line,D.line+1,function(V){var re=V.text;U==D.line&&(re=re.slice(0,D.ch)),U==a.line&&(re=re.slice(a.ch)),A.push(re),++U}),A}function Ea(e,a,D){var A=[];return e.iter(a,D,function(U){A.push(U.text)}),A}function Pn(e,a){var D=a-e.height;if(D)for(var A=e;A;A=A.parent)A.height+=D}function Qr(e){if(e.parent==null)return null;for(var a=e.parent,D=ne(a.lines,e),A=a.parent;A;a=A,A=A.parent)for(var U=0;!(A.children[U]==a);++U)D+=A.children[U].chunkSize();return D+a.first}function Ln(e,a){var D=e.first;e:do{for(var A=0;A<e.children.length;++A){var U=e.children[A],V=U.height;if(a<V){e=U;continue e}a-=V,D+=U.chunkSize()}return D}while(!e.lines);for(var re=0;re<e.lines.length;++re){var se=e.lines[re],ce=se.height;if(a<ce)break;a-=ce}return D+re}function la(e,a){return a>=e.first&&a<e.first+e.size}function fa(e,a){return String(e.lineNumberFormatter(a+e.firstLineNumber))}function It(e,a,D){if(D===void 0&&(D=null),!(this instanceof It))return new It(e,a,D);this.line=e,this.ch=a,this.sticky=D}function dr(e,a){return e.line-a.line||e.ch-a.ch}function ha(e,a){return e.sticky==a.sticky&&dr(e,a)==0}function xa(e){return It(e.line,e.ch)}function Pa(e,a){return dr(e,a)<0?a:e}function pa(e,a){return dr(e,a)<0?e:a}function kn(e,a){return Math.max(e.first,Math.min(a,e.first+e.size-1))}function xr(e,a){if(a.line<e.first)return It(e.first,0);var D=e.first+e.size-1;return a.line>D?It(D,er(e,D).text.length):ta(a,er(e,a.line).text.length)}function ta(e,a){var D=e.ch;return D==null||D>a?It(e.line,a):D<0?It(e.line,0):e}function Ct(e,a){for(var D=[],A=0;A<a.length;A++)D[A]=xr(e,a[A]);return D}var Vn=function(e,a){this.state=e,this.lookAhead=a},Mn=function(e,a,D,A){this.state=a,this.doc=e,this.line=D,this.maxLookAhead=A||0,this.baseTokens=null,this.baseTokenPos=1};Mn.prototype.lookAhead=function(e){var a=this.doc.getLine(this.line+e);return a!=null&&e>this.maxLookAhead&&(this.maxLookAhead=e),a},Mn.prototype.baseToken=function(e){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)this.baseTokenPos+=2;var a=this.baseTokens[this.baseTokenPos+1];return{type:a&&a.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},Mn.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},Mn.fromSaved=function(e,a,D){return a instanceof Vn?new Mn(e,Jr(e.mode,a.state),D,a.lookAhead):new Mn(e,Jr(e.mode,a),D)},Mn.prototype.save=function(e){var a=e!==!1?Jr(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new Vn(a,this.maxLookAhead):a};function Ka(e,a,D,A){var U=[e.state.modeGen],V={};ma(e,a.text,e.doc.mode,D,function(ve,Ne){return U.push(ve,Ne)},V,A);for(var re=D.state,se=function(ve){D.baseTokens=U;var Ne=e.state.overlays[ve],He=1,tt=0;D.state=!0,ma(e,a.text,Ne.mode,D,function($e,vt){for(var Rt=He;tt<$e;){var Ft=U[He];Ft>$e&&U.splice(He,1,$e,U[He+1],Ft),He+=2,tt=Math.min($e,Ft)}if(!vt)return;if(Ne.opaque)U.splice(Rt,He-Rt,$e,"overlay "+vt),He=Rt+2;else for(;Rt<He;Rt+=2){var Yt=U[Rt+1];U[Rt+1]=(Yt?Yt+" ":"")+"overlay "+vt}},V),D.state=re,D.baseTokens=null,D.baseTokenPos=1},ce=0;ce<e.state.overlays.length;++ce)se(ce);return{styles:U,classes:V.bgClass||V.textClass?V:null}}function Ta(e,a,D){if(!a.styles||a.styles[0]!=e.state.modeGen){var A=Qn(e,Qr(a)),U=a.text.length>e.options.maxHighlightLength&&Jr(e.doc.mode,A.state),V=Ka(e,a,A);U&&(A.state=U),a.stateAfter=A.save(!U),a.styles=V.styles,V.classes?a.styleClasses=V.classes:a.styleClasses&&(a.styleClasses=null),D===e.doc.highlightFrontier&&(e.doc.modeFrontier=Math.max(e.doc.modeFrontier,++e.doc.highlightFrontier))}return a.styles}function Qn(e,a,D){var A=e.doc,U=e.display;if(!A.mode.startState)return new Mn(A,!0,a);var V=va(e,a,D),re=V>A.first&&er(A,V-1).stateAfter,se=re?Mn.fromSaved(A,re,V):new Mn(A,Wa(A.mode),V);return A.iter(V,a,function(ce){Qa(e,ce.text,se);var ve=se.line;ce.stateAfter=ve==a-1||ve%5==0||ve>=U.viewFrom&&ve<U.viewTo?se.save():null,se.nextLine()}),D&&(A.modeFrontier=se.line),se}function Qa(e,a,D,A){var U=e.doc.mode,V=new _n(a,e.options.tabSize,D);for(V.start=V.pos=A||0,a==""&&Za(U,D.state);!V.eol();)ra(U,V,D.state),V.start=V.pos}function Za(e,a){if(e.blankLine)return e.blankLine(a);if(!e.innerMode)return;var D=_a(e,a);if(D.mode.blankLine)return D.mode.blankLine(D.state)}function ra(e,a,D,A){for(var U=0;U<10;U++){A&&(A[0]=_a(e,D).mode);var V=e.token(a,D);if(a.pos>a.start)return V}throw new Error("Mode "+e.name+" failed to advance stream.")}var wn=function(e,a,D){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=a||null,this.state=D};function na(e,a,D,A){var U=e.doc,V=U.mode,re;a=xr(U,a);var se=er(U,a.line),ce=Qn(e,a.line,D),ve=new _n(se.text,e.options.tabSize,ce),Ne;for(A&&(Ne=[]);(A||ve.pos<a.ch)&&!ve.eol();)ve.start=ve.pos,re=ra(V,ve,ce.state),A&&Ne.push(new wn(ve,re,Jr(U.mode,ce.state)));return A?Ne:new wn(ve,re,ce.state)}function ka(e,a){if(e)for(;;){var D=e.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!D)break;e=e.slice(0,D.index)+e.slice(D.index+D[0].length);var A=D[1]?"bgClass":"textClass";a[A]==null?a[A]=D[2]:new RegExp("(?:^|\\s)"+D[2]+"(?:$|\\s)").test(a[A])||(a[A]+=" "+D[2])}return e}function ma(e,a,D,A,U,V,re){var se=D.flattenSpans;se==null&&(se=e.options.flattenSpans);var ce=0,ve=null,Ne=new _n(a,e.options.tabSize,A),He,tt=e.options.addModeClass&&[null];for(a==""&&ka(Za(D,A.state),V);!Ne.eol();){if(Ne.pos>e.options.maxHighlightLength?(se=!1,re&&Qa(e,a,A,Ne.pos),Ne.pos=a.length,He=null):He=ka(ra(D,Ne,A.state,tt),V),tt){var $e=tt[0].name;$e&&(He="m-"+(He?$e+" "+He:$e))}if(!se||ve!=He){for(;ce<Ne.start;)ce=Math.min(Ne.start,ce+5e3),U(ce,ve);ve=He}Ne.start=Ne.pos}for(;ce<Ne.pos;){var vt=Math.min(Ne.pos,ce+5e3);U(vt,ve),ce=vt}}function va(e,a,D){for(var A,U,V=e.doc,re=D?-1:a-(e.doc.mode.innerMode?1e3:100),se=a;se>re;--se){if(se<=V.first)return V.first;var ce=er(V,se-1),ve=ce.stateAfter;if(ve&&(!D||se+(ve instanceof Vn?ve.lookAhead:0)<=V.modeFrontier))return se;var Ne=K(ce.text,null,e.options.tabSize);(U==null||A>Ne)&&(U=se-1,A=Ne)}return U}function Di(e,a){if(e.modeFrontier=Math.min(e.modeFrontier,a),e.highlightFrontier<a-10)return;for(var D=e.first,A=a-1;A>D;A--){var U=er(e,A).stateAfter;if(U&&(!(U instanceof Vn)||A+U.lookAhead<a)){D=A+1;break}}e.highlightFrontier=Math.min(e.highlightFrontier,D)}var Xa=!1,jn=!1;function za(){Xa=!0}function _i(){jn=!0}function Ma(e,a,D){this.marker=e,this.from=a,this.to=D}function aa(e,a){if(e)for(var D=0;D<e.length;++D){var A=e[D];if(A.marker==a)return A}}function oi(e,a){for(var D,A=0;A<e.length;++A)e[A]!=a&&(D||(D=[])).push(e[A]);return D}function pi(e,a){e.markedSpans=e.markedSpans?e.markedSpans.concat([a]):[a],a.marker.attachLine(e)}function si(e,a,D){var A;if(e)for(var U=0;U<e.length;++U){var V=e[U],re=V.marker,se=V.from==null||(re.inclusiveLeft?V.from<=a:V.from<a);if(se||V.from==a&&re.type=="bookmark"&&(!D||!V.marker.insertLeft)){var ce=V.to==null||(re.inclusiveRight?V.to>=a:V.to>a);(A||(A=[])).push(new Ma(re,V.from,ce?null:V.to))}}return A}function mi(e,a,D){var A;if(e)for(var U=0;U<e.length;++U){var V=e[U],re=V.marker,se=V.to==null||(re.inclusiveRight?V.to>=a:V.to>a);if(se||V.from==a&&re.type=="bookmark"&&(!D||V.marker.insertLeft)){var ce=V.from==null||(re.inclusiveLeft?V.from<=a:V.from<a);(A||(A=[])).push(new Ma(re,ce?null:V.from-a,V.to==null?null:V.to-a))}}return A}function qa(e,a){if(a.full)return null;var D=la(e,a.from.line)&&er(e,a.from.line).markedSpans,A=la(e,a.to.line)&&er(e,a.to.line).markedSpans;if(!D&&!A)return null;var U=a.from.ch,V=a.to.ch,re=dr(a.from,a.to)==0,se=si(D,U,re),ce=mi(A,V,re),ve=a.text.length==1,Ne=q(a.text).length+(ve?U:0);if(se)for(var He=0;He<se.length;++He){var tt=se[He];if(tt.to==null){var $e=aa(ce,tt.marker);$e?ve&&(tt.to=$e.to==null?null:$e.to+Ne):tt.to=U}}if(ce)for(var vt=0;vt<ce.length;++vt){var Rt=ce[vt];if(Rt.to!=null&&(Rt.to+=Ne),Rt.from==null){var Ft=aa(se,Rt.marker);Ft||(Rt.from=Ne,ve&&(se||(se=[])).push(Rt))}else Rt.from+=Ne,ve&&(se||(se=[])).push(Rt)}se&&(se=wa(se)),ce&&ce!=se&&(ce=wa(ce));var Yt=[se];if(!ve){var sr=a.text.length-2,$t;if(sr>0&&se)for(var pr=0;pr<se.length;++pr)se[pr].to==null&&($t||($t=[])).push(new Ma(se[pr].marker,null,null));for(var Fr=0;Fr<sr;++Fr)Yt.push($t);Yt.push(ce)}return Yt}function wa(e){for(var a=0;a<e.length;++a){var D=e[a];D.from!=null&&D.from==D.to&&D.marker.clearWhenEmpty!==!1&&e.splice(a--,1)}return e.length?e:null}function ei(e,a,D){var A=null;if(e.iter(a.line,D.line+1,function($e){if($e.markedSpans)for(var vt=0;vt<$e.markedSpans.length;++vt){var Rt=$e.markedSpans[vt].marker;Rt.readOnly&&(!A||ne(A,Rt)==-1)&&(A||(A=[])).push(Rt)}}),!A)return null;for(var U=[{from:a,to:D}],V=0;V<A.length;++V)for(var re=A[V],se=re.find(0),ce=0;ce<U.length;++ce){var ve=U[ce];if(dr(ve.to,se.from)<0||dr(ve.from,se.to)>0)continue;var Ne=[ce,1],He=dr(ve.from,se.from),tt=dr(ve.to,se.to);(He<0||!re.inclusiveLeft&&!He)&&Ne.push({from:ve.from,to:se.from}),(tt>0||!re.inclusiveRight&&!tt)&&Ne.push({from:se.to,to:ve.to}),U.splice.apply(U,Ne),ce+=Ne.length-3}return U}function Ei(e){var a=e.markedSpans;if(!a)return;for(var D=0;D<a.length;++D)a[D].marker.detachLine(e);e.markedSpans=null}function mt(e,a){if(!a)return;for(var D=0;D<a.length;++D)a[D].marker.attachLine(e);e.markedSpans=a}function qe(e){return e.inclusiveLeft?-1:0}function pt(e){return e.inclusiveRight?1:0}function _t(e,a){var D=e.lines.length-a.lines.length;if(D!=0)return D;var A=e.find(),U=a.find(),V=dr(A.from,U.from)||qe(e)-qe(a);if(V)return-V;var re=dr(A.to,U.to)||pt(e)-pt(a);return re||a.id-e.id}function Ut(e,a){var D=jn&&e.markedSpans,A;if(D)for(var U=void 0,V=0;V<D.length;++V)U=D[V],U.marker.collapsed&&(a?U.from:U.to)==null&&(!A||_t(A,U.marker)<0)&&(A=U.marker);return A}function At(e){return Ut(e,!0)}function Xt(e){return Ut(e,!1)}function kt(e,a){var D=jn&&e.markedSpans,A;if(D)for(var U=0;U<D.length;++U){var V=D[U];V.marker.collapsed&&(V.from==null||V.from<a)&&(V.to==null||V.to>a)&&(!A||_t(A,V.marker)<0)&&(A=V.marker)}return A}function st(e,a,D,A,U){var V=er(e,a),re=jn&&V.markedSpans;if(re)for(var se=0;se<re.length;++se){var ce=re[se];if(!ce.marker.collapsed)continue;var ve=ce.marker.find(0),Ne=dr(ve.from,D)||qe(ce.marker)-qe(U),He=dr(ve.to,A)||pt(ce.marker)-pt(U);if(Ne>=0&&He<=0||Ne<=0&&He>=0)continue;if(Ne<=0&&(ce.marker.inclusiveRight&&U.inclusiveLeft?dr(ve.to,D)>=0:dr(ve.to,D)>0)||Ne>=0&&(ce.marker.inclusiveRight&&U.inclusiveLeft?dr(ve.from,A)<=0:dr(ve.from,A)<0))return!0}}function gt(e){for(var a;a=At(e);)e=a.find(-1,!0).line;return e}function bt(e){for(var a;a=Xt(e);)e=a.find(1,!0).line;return e}function tr(e){for(var a,D;a=Xt(e);)e=a.find(1,!0).line,(D||(D=[])).push(e);return D}function Jt(e,a){var D=er(e,a),A=gt(D);return D==A?a:Qr(A)}function Wt(e,a){if(a>e.lastLine())return a;var D=er(e,a),A;if(!jt(e,D))return a;for(;A=Xt(D);)D=A.find(1,!0).line;return Qr(D)+1}function jt(e,a){var D=jn&&a.markedSpans;if(D)for(var A=void 0,U=0;U<D.length;++U){if(A=D[U],!A.marker.collapsed)continue;if(A.from==null)return!0;if(A.marker.widgetNode)continue;if(A.from==0&&A.marker.inclusiveLeft&&Vt(e,a,A))return!0}}function Vt(e,a,D){if(D.to==null){var A=D.marker.find(1,!0);return Vt(e,A.line,aa(A.line.markedSpans,D.marker))}if(D.marker.inclusiveRight&&D.to==a.text.length)return!0;for(var U=void 0,V=0;V<a.markedSpans.length;++V)if(U=a.markedSpans[V],U.marker.collapsed&&!U.marker.widgetNode&&U.from==D.to&&(U.to==null||U.to!=D.from)&&(U.marker.inclusiveLeft||D.marker.inclusiveRight)&&Vt(e,a,U))return!0}function Zt(e){e=gt(e);for(var a=0,D=e.parent,A=0;A<D.lines.length;++A){var U=D.lines[A];if(U==e)break;a+=U.height}for(var V=D.parent;V;D=V,V=D.parent)for(var re=0;re<V.children.length;++re){var se=V.children[re];if(se==D)break;a+=se.height}return a}function Ze(e){if(e.height==0)return 0;for(var a=e.text.length,D,A=e;D=At(A);){var U=D.find(0,!0);A=U.from.line,a+=U.from.ch-U.to.ch}for(A=e;D=Xt(A);){var V=D.find(0,!0);a-=A.text.length-V.from.ch,A=V.to.line,a+=A.text.length-V.to.ch}return a}function vr(e){var a=e.display,D=e.doc;a.maxLine=er(D,D.first),a.maxLineLength=Ze(a.maxLine),a.maxLineChanged=!0,D.iter(function(A){var U=Ze(A);U>a.maxLineLength&&(a.maxLineLength=U,a.maxLine=A)})}var Or=function(e,a,D){this.text=e,mt(this,a),this.height=D?D(this):1};Or.prototype.lineNo=function(){return Qr(this)},Re(Or);function nr(e,a,D,A){e.text=a,e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null),e.order!=null&&(e.order=null),Ei(e),mt(e,D);var U=A?A(e):1;U!=e.height&&Pn(e,U)}function ft(e){e.parent=null,Ei(e)}var yt={},ht={};function wt(e,a){if(!e||/^\s*$/.test(e))return null;var D=a.addModeClass?ht:yt;return D[e]||(D[e]=e.replace(/\S+/g,"cm-$&"))}function Kt(e,a){var D=L("span",null,null,p?"padding-right: .1px":null),A={pre:L("pre",[D],"CodeMirror-line"),content:D,col:0,pos:0,cm:e,trailingSpace:!1,splitSpaces:e.getOption("lineWrapping")};a.measure={};for(var U=0;U<=(a.rest?a.rest.length:0);U++){var V=U?a.rest[U-1]:a.line,re=void 0;A.pos=0,A.addToken=zt,Er(e.display.measure)&&(re=ot(V,e.doc.direction))&&(A.addToken=Rr(A.addToken,re)),A.map=[];var se=a!=e.display.externalMeasured&&Qr(V);Qe(V,A,Ta(e,V,se)),V.styleClasses&&(V.styleClasses.bgClass&&(A.bgClass=H(V.styleClasses.bgClass,A.bgClass||"")),V.styleClasses.textClass&&(A.textClass=H(V.styleClasses.textClass,A.textClass||""))),A.map.length==0&&A.map.push(0,0,A.content.appendChild(Lt(e.display.measure))),U==0?(a.measure.map=A.map,a.measure.cache={}):((a.measure.maps||(a.measure.maps=[])).push(A.map),(a.measure.caches||(a.measure.caches=[])).push({}))}if(p){var ce=A.content.lastChild;(/\bcm-tab\b/.test(ce.className)||ce.querySelector&&ce.querySelector(".cm-tab"))&&(A.content.className="cm-tab-wrap-hack")}return We(e,"renderLine",e,a.line,A.pre),A.pre.className&&(A.textClass=H(A.pre.className,A.textClass||"")),A}function ar(e){var a=T("span","\u2022","cm-invalidchar");return a.title="\\u"+e.charCodeAt(0).toString(16),a.setAttribute("aria-label",a.title),a}function zt(e,a,D,A,U,V,re){if(!a)return;var se=e.splitSpaces?gr(a,e.trailingSpace):a,ce=e.cm.state.specialChars,ve=!1,Ne;if(!ce.test(a))e.col+=a.length,Ne=document.createTextNode(se),e.map.push(e.pos,e.pos+a.length,Ne),w&&b<9&&(ve=!0),e.pos+=a.length;else{Ne=document.createDocumentFragment();for(var He=0;;){ce.lastIndex=He;var tt=ce.exec(a),$e=tt?tt.index-He:a.length-He;if($e){var vt=document.createTextNode(se.slice(He,He+$e));w&&b<9?Ne.appendChild(T("span",[vt])):Ne.appendChild(vt),e.map.push(e.pos,e.pos+$e,vt),e.col+=$e,e.pos+=$e}if(!tt)break;He+=$e+1;var Rt=void 0;if(tt[0]==" "){var Ft=e.cm.options.tabSize,Yt=Ft-e.col%Ft;Rt=Ne.appendChild(T("span",ie(Yt),"cm-tab")),Rt.setAttribute("role","presentation"),Rt.setAttribute("cm-text"," "),e.col+=Yt}else tt[0]=="\r"||tt[0]==`
`?(Rt=Ne.appendChild(T("span",tt[0]=="\r"?"\u240D":"\u2424","cm-invalidchar")),Rt.setAttribute("cm-text",tt[0]),e.col+=1):(Rt=e.cm.options.specialCharPlaceholder(tt[0]),Rt.setAttribute("cm-text",tt[0]),w&&b<9?Ne.appendChild(T("span",[Rt])):Ne.appendChild(Rt),e.col+=1);e.map.push(e.pos,e.pos+1,Rt),e.pos++}}if(e.trailingSpace=se.charCodeAt(a.length-1)==32,D||A||U||ve||V||re){var sr=D||"";A&&(sr+=A),U&&(sr+=U);var $t=T("span",[Ne],sr,V);if(re)for(var pr in re)re.hasOwnProperty(pr)&&pr!="style"&&pr!="class"&&$t.setAttribute(pr,re[pr]);return e.content.appendChild($t)}e.content.appendChild(Ne)}function gr(e,a){if(e.length>1&&!/ /.test(e))return e;for(var D=a,A="",U=0;U<e.length;U++){var V=e.charAt(U);V==" "&&D&&(U==e.length-1||e.charCodeAt(U+1)==32)&&(V="\xA0"),A+=V,D=V==" "}return A}function Rr(e,a){return function(D,A,U,V,re,se,ce){U=U?U+" cm-force-border":"cm-force-border";for(var ve=D.pos,Ne=ve+A.length;;){for(var He=void 0,tt=0;tt<a.length&&!(He=a[tt],He.to>ve&&He.from<=ve);tt++);if(He.to>=Ne)return e(D,A,U,V,re,se,ce);e(D,A.slice(0,He.to-ve),U,V,null,se,ce),V=null,A=A.slice(He.to-ve),ve=He.to}}}function lr(e,a,D,A){var U=!A&&D.widgetNode;U&&e.map.push(e.pos,e.pos+a,U),!A&&e.cm.display.input.needsContentAttribute&&(U||(U=e.content.appendChild(document.createElement("span"))),U.setAttribute("cm-marker",D.id)),U&&(e.cm.display.input.setUneditable(U),e.content.appendChild(U)),e.pos+=a,e.trailingSpace=!1}function Qe(e,a,D){var A=e.markedSpans,U=e.text,V=0;if(!A){for(var re=1;re<D.length;re+=2)a.addToken(a,U.slice(V,V=D[re]),wt(D[re+1],a.cm.options));return}for(var se=U.length,ce=0,ve=1,Ne="",He,tt,$e=0,vt,Rt,Ft,Yt,sr;;){if($e==ce){vt=Rt=Ft=tt="",sr=null,Yt=null,$e=Infinity;for(var $t=[],pr=void 0,Fr=0;Fr<A.length;++Fr){var Dr=A[Fr],sn=Dr.marker;if(sn.type=="bookmark"&&Dr.from==ce&&sn.widgetNode)$t.push(sn);else if(Dr.from<=ce&&(Dr.to==null||Dr.to>ce||sn.collapsed&&Dr.to==ce&&Dr.from==ce)){if(Dr.to!=null&&Dr.to!=ce&&$e>Dr.to&&($e=Dr.to,Rt=""),sn.className&&(vt+=" "+sn.className),sn.css&&(tt=(tt?tt+";":"")+sn.css),sn.startStyle&&Dr.from==ce&&(Ft+=" "+sn.startStyle),sn.endStyle&&Dr.to==$e&&(pr||(pr=[])).push(sn.endStyle,Dr.to),sn.title&&((sr||(sr={})).title=sn.title),sn.attributes)for(var Dn in sn.attributes)(sr||(sr={}))[Dn]=sn.attributes[Dn];sn.collapsed&&(!Yt||_t(Yt.marker,sn)<0)&&(Yt=Dr)}else Dr.from>ce&&$e>Dr.from&&($e=Dr.from)}if(pr)for(var ca=0;ca<pr.length;ca+=2)pr[ca+1]==$e&&(Rt+=" "+pr[ca]);if(!Yt||Yt.from==ce)for(var Wn=0;Wn<$t.length;++Wn)lr(a,0,$t[Wn]);if(Yt&&(Yt.from||0)==ce){if(lr(a,(Yt.to==null?se+1:Yt.to)-ce,Yt.marker,Yt.from==null),Yt.to==null)return;Yt.to==ce&&(Yt=!1)}}if(ce>=se)break;for(var Ga=Math.min(se,$e);;){if(Ne){var Ua=ce+Ne.length;if(!Yt){var qn=Ua>Ga?Ne.slice(0,Ga-ce):Ne;a.addToken(a,qn,He?He+vt:vt,Ft,ce+qn.length==$e?Rt:"",tt,sr)}if(Ua>=Ga){Ne=Ne.slice(Ga-ce),ce=Ga;break}ce=Ua,Ft=""}Ne=U.slice(V,V=D[ve++]),He=wt(D[ve++],a.cm.options)}}}function Pt(e,a,D){this.line=a,this.rest=tr(a),this.size=this.rest?Qr(q(this.rest))-D+1:1,this.node=this.text=null,this.hidden=jt(e,a)}function Vr(e,a,D){for(var A=[],U,V=a;V<D;V=U){var re=new Pt(e.doc,er(e.doc,V),V);U=V+re.size,A.push(re)}return A}var Hr=null;function ir(e){Hr?Hr.ops.push(e):e.ownsGroup=Hr={ops:[e],delayedCallbacks:[]}}function br(e){var a=e.delayedCallbacks,D=0;do{for(;D<a.length;D++)a[D].call(null);for(var A=0;A<e.ops.length;A++){var U=e.ops[A];if(U.cursorActivityHandlers)for(;U.cursorActivityCalled<U.cursorActivityHandlers.length;)U.cursorActivityHandlers[U.cursorActivityCalled++].call(null,U.cm)}}while(D<a.length)}function Tr(e,a){var D=e.ownsGroup;if(!D)return;try{br(D)}finally{Hr=null,a(D)}}var Ot=null;function Ht(e,a){var D=Je(e,a);if(!D.length)return;var A=Array.prototype.slice.call(arguments,2),U;Hr?U=Hr.delayedCallbacks:Ot?U=Ot:(U=Ot=[],setTimeout(or,0));for(var V=function(se){U.push(function(){return D[se].apply(null,A)})},re=0;re<D.length;++re)V(re)}function or(){var e=Ot;Ot=null;for(var a=0;a<e.length;++a)e[a]()}function Gt(e,a,D,A){for(var U=0;U<a.changes.length;U++){var V=a.changes[U];V=="text"?Tt(e,a):V=="gutter"?Gr(e,a,D,A):V=="class"?yr(e,a):V=="widget"&&Yr(e,a,A)}a.changes=null}function lt(e){return e.node==e.text&&(e.node=T("div",null,null,"position: relative"),e.text.parentNode&&e.text.parentNode.replaceChild(e.node,e.text),e.node.appendChild(e.text),w&&b<8&&(e.node.style.zIndex=2)),e.node}function dt(e,a){var D=a.bgClass?a.bgClass+" "+(a.line.bgClass||""):a.line.bgClass;if(D&&(D+=" CodeMirror-linebackground"),a.background)D?a.background.className=D:(a.background.parentNode.removeChild(a.background),a.background=null);else if(D){var A=lt(a);a.background=A.insertBefore(T("div",null,D),A.firstChild),e.display.input.setUneditable(a.background)}}function Mt(e,a){var D=e.display.externalMeasured;return D&&D.line==a.line?(e.display.externalMeasured=null,a.measure=D.measure,D.built):Kt(e,a)}function Tt(e,a){var D=a.text.className,A=Mt(e,a);a.text==a.node&&(a.node=A.pre),a.text.parentNode.replaceChild(A.pre,a.text),a.text=A.pre,A.bgClass!=a.bgClass||A.textClass!=a.textClass?(a.bgClass=A.bgClass,a.textClass=A.textClass,yr(e,a)):D&&(a.text.className=D)}function yr(e,a){dt(e,a),a.line.wrapClass?lt(a).className=a.line.wrapClass:a.node!=a.text&&(a.node.className="");var D=a.textClass?a.textClass+" "+(a.line.textClass||""):a.line.textClass;a.text.className=D||""}function Gr(e,a,D,A){if(a.gutter&&(a.node.removeChild(a.gutter),a.gutter=null),a.gutterBackground&&(a.node.removeChild(a.gutterBackground),a.gutterBackground=null),a.line.gutterClass){var U=lt(a);a.gutterBackground=T("div",null,"CodeMirror-gutter-background "+a.line.gutterClass,"left: "+(e.options.fixedGutter?A.fixedPos:-A.gutterTotalWidth)+"px; width: "+A.gutterTotalWidth+"px"),e.display.input.setUneditable(a.gutterBackground),U.insertBefore(a.gutterBackground,a.text)}var V=a.line.gutterMarkers;if(e.options.lineNumbers||V){var re=lt(a),se=a.gutter=T("div",null,"CodeMirror-gutter-wrapper","left: "+(e.options.fixedGutter?A.fixedPos:-A.gutterTotalWidth)+"px");if(e.display.input.setUneditable(se),re.insertBefore(se,a.text),a.line.gutterClass&&(se.className+=" "+a.line.gutterClass),e.options.lineNumbers&&(!V||!V["CodeMirror-linenumbers"])&&(a.lineNumber=se.appendChild(T("div",fa(e.options,D),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+A.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+e.display.lineNumInnerWidth+"px"))),V)for(var ce=0;ce<e.display.gutterSpecs.length;++ce){var ve=e.display.gutterSpecs[ce].className,Ne=V.hasOwnProperty(ve)&&V[ve];Ne&&se.appendChild(T("div",[Ne],"CodeMirror-gutter-elt","left: "+A.gutterLeft[ve]+"px; width: "+A.gutterWidth[ve]+"px"))}}}function Yr(e,a,D){a.alignable&&(a.alignable=null);for(var A=O("CodeMirror-linewidget"),U=a.node.firstChild,V=void 0;U;U=V)V=U.nextSibling,A.test(U.className)&&a.node.removeChild(U);Wr(e,a,D)}function mr(e,a,D,A){var U=Mt(e,a);return a.text=a.node=U.pre,U.bgClass&&(a.bgClass=U.bgClass),U.textClass&&(a.textClass=U.textClass),yr(e,a),Gr(e,a,D,A),Wr(e,a,A),a.node}function Wr(e,a,D){if(Cr(e,a.line,a,D,!0),a.rest)for(var A=0;A<a.rest.length;A++)Cr(e,a.rest[A],a,D,!1)}function Cr(e,a,D,A,U){if(!a.widgets)return;for(var V=lt(D),re=0,se=a.widgets;re<se.length;++re){var ce=se[re],ve=T("div",[ce.node],"CodeMirror-linewidget"+(ce.className?" "+ce.className:""));ce.handleMouseEvents||ve.setAttribute("cm-ignore-events","true"),tn(ce,ve,D,A),e.display.input.setUneditable(ve),U&&ce.above?V.insertBefore(ve,D.gutter||D.text):V.appendChild(ve),Ht(ce,"redraw")}}function tn(e,a,D,A){if(e.noHScroll){(D.alignable||(D.alignable=[])).push(a);var U=A.wrapperWidth;a.style.left=A.fixedPos+"px",e.coverGutter||(U-=A.gutterTotalWidth,a.style.paddingLeft=A.gutterTotalWidth+"px"),a.style.width=U+"px"}e.coverGutter&&(a.style.zIndex=5,a.style.position="relative",e.noHScroll||(a.style.marginLeft=-A.gutterTotalWidth+"px"))}function Lr(e){if(e.height!=null)return e.height;var a=e.doc.cm;if(!a)return 0;if(!P(document.body,e.node)){var D="position: relative;";e.coverGutter&&(D+="margin-left: -"+a.display.gutters.offsetWidth+"px;"),e.noHScroll&&(D+="width: "+a.display.wrapper.clientWidth+"px;"),E(a.display.measure,T("div",[e.node],null,D))}return e.height=e.node.parentNode.offsetHeight}function rn(e,a){for(var D=ke(a);D!=e.wrapper;D=D.parentNode)if(!D||D.nodeType==1&&D.getAttribute("cm-ignore-events")=="true"||D.parentNode==e.sizer&&D!=e.mover)return!0}function Nn(e){return e.lineSpace.offsetTop}function Ae(e){return e.mover.offsetHeight-e.lineSpace.offsetHeight}function Ue(e){if(e.cachedPaddingH)return e.cachedPaddingH;var a=E(e.measure,T("pre","x","CodeMirror-line-like")),D=window.getComputedStyle?window.getComputedStyle(a):a.currentStyle,A={left:parseInt(D.paddingLeft),right:parseInt(D.paddingRight)};return!isNaN(A.left)&&!isNaN(A.right)&&(e.cachedPaddingH=A),A}function Ke(e){return oe-e.display.nativeBarWidth}function Le(e){return e.display.scroller.clientWidth-Ke(e)-e.display.barWidth}function he(e){return e.display.scroller.clientHeight-Ke(e)-e.display.barHeight}function Oe(e,a,D){var A=e.options.lineWrapping,U=A&&Le(e);if(!a.measure.heights||A&&a.measure.width!=U){var V=a.measure.heights=[];if(A){a.measure.width=U;for(var re=a.text.firstChild.getClientRects(),se=0;se<re.length-1;se++){var ce=re[se],ve=re[se+1];Math.abs(ce.bottom-ve.bottom)>2&&V.push((ce.bottom+ve.top)/2-D.top)}}V.push(D.bottom-D.top)}}function be(e,a,D){if(e.line==a)return{map:e.measure.map,cache:e.measure.cache};for(var A=0;A<e.rest.length;A++)if(e.rest[A]==a)return{map:e.measure.maps[A],cache:e.measure.caches[A]};for(var U=0;U<e.rest.length;U++)if(Qr(e.rest[U])>D)return{map:e.measure.maps[U],cache:e.measure.caches[U],before:!0}}function De(e,a){a=gt(a);var D=Qr(a),A=e.display.externalMeasured=new Pt(e.doc,a,D);A.lineN=D;var U=A.built=Kt(e,A);return A.text=U.pre,E(e.display.lineMeasure,U.pre),A}function Fe(e,a,D,A){return Ge(e,je(e,a),D,A)}function Be(e,a){if(a>=e.display.viewFrom&&a<e.display.viewTo)return e.display.view[xn(e,a)];var D=e.display.externalMeasured;if(D&&a>=D.lineN&&a<D.lineN+D.size)return D}function je(e,a){var D=Qr(a),A=Be(e,D);A&&!A.text?A=null:A&&A.changes&&(Gt(e,A,D,Rn(e)),e.curOp.forceUpdate=!0),A||(A=De(e,a));var U=be(A,a,D);return{line:a,view:A,rect:null,map:U.map,cache:U.cache,before:U.before,hasHeights:!1}}function Ge(e,a,D,A,U){a.before&&(D=-1);var V=D+(A||""),re;return a.cache.hasOwnProperty(V)?re=a.cache[V]:(a.rect||(a.rect=a.view.text.getBoundingClientRect()),a.hasHeights||(Oe(e,a.view,a.rect),a.hasHeights=!0),re=Nt(e,a,D,A),re.bogus||(a.cache[V]=re)),{left:re.left,right:re.right,top:U?re.rtop:re.top,bottom:U?re.rbottom:re.bottom}}var it={left:0,right:0,top:0,bottom:0};function Et(e,a,D){for(var A,U,V,re,se,ce,ve=0;ve<e.length;ve+=3)if(se=e[ve],ce=e[ve+1],a<se?(U=0,V=1,re="left"):a<ce?(U=a-se,V=U+1):(ve==e.length-3||a==ce&&e[ve+3]>a)&&(V=ce-se,U=V-1,a>=ce&&(re="right")),U!=null){if(A=e[ve+2],se==ce&&D==(A.insertLeft?"left":"right")&&(re=D),D=="left"&&U==0)for(;ve&&e[ve-2]==e[ve-3]&&e[ve-1].insertLeft;)A=e[(ve-=3)+2],re="left";if(D=="right"&&U==ce-se)for(;ve<e.length-3&&e[ve+3]==e[ve+4]&&!e[ve+5].insertLeft;)A=e[(ve+=3)+2],re="right";break}return{node:A,start:U,end:V,collapse:re,coverStart:se,coverEnd:ce}}function St(e,a){var D=it;if(a=="left")for(var A=0;A<e.length&&!((D=e[A]).left!=D.right);A++);else for(var U=e.length-1;U>=0&&!((D=e[U]).left!=D.right);U--);return D}function Nt(e,a,D,A){var U=Et(a.map,D,A),V=U.node,re=U.start,se=U.end,ce=U.collapse,ve;if(V.nodeType==3){for(var Ne=0;Ne<4;Ne++){for(;re&&fe(a.line.text.charAt(U.coverStart+re));)--re;for(;U.coverStart+se<U.coverEnd&&fe(a.line.text.charAt(U.coverStart+se));)++se;if(w&&b<9&&re==0&&se==U.coverEnd-U.coverStart?ve=V.parentNode.getBoundingClientRect():ve=St(I(V,re,se).getClientRects(),A),ve.left||ve.right||re==0)break;se=re,re=re-1,ce="right"}w&&b<11&&(ve=_r(e.display.measure,ve))}else{re>0&&(ce=A="right");var He;e.options.lineWrapping&&(He=V.getClientRects()).length>1?ve=He[A=="right"?He.length-1:0]:ve=V.getBoundingClientRect()}if(w&&b<9&&!re&&(!ve||!ve.left&&!ve.right)){var tt=V.parentNode.getClientRects()[0];tt?ve={left:tt.left,right:tt.left+Kn(e.display),top:tt.top,bottom:tt.bottom}:ve=it}for(var $e=ve.top-a.rect.top,vt=ve.bottom-a.rect.top,Rt=($e+vt)/2,Ft=a.view.measure.heights,Yt=0;Yt<Ft.length-1&&!(Rt<Ft[Yt]);Yt++);var sr=Yt?Ft[Yt-1]:0,$t=Ft[Yt],pr={left:(ce=="right"?ve.right:ve.left)-a.rect.left,right:(ce=="left"?ve.left:ve.right)-a.rect.left,top:sr,bottom:$t};return!ve.left&&!ve.right&&(pr.bogus=!0),e.options.singleCursorHeightPerLine||(pr.rtop=$e,pr.rbottom=vt),pr}function _r(e,a){if(!window.screen||screen.logicalXDPI==null||screen.logicalXDPI==screen.deviceXDPI||!Ur(e))return a;var D=screen.logicalXDPI/screen.deviceXDPI,A=screen.logicalYDPI/screen.deviceYDPI;return{left:a.left*D,right:a.right*D,top:a.top*A,bottom:a.bottom*A}}function Nr(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var a=0;a<e.rest.length;a++)e.measure.caches[a]={}}function Pr(e){e.display.externalMeasure=null,_(e.display.lineMeasure);for(var a=0;a<e.display.view.length;a++)Nr(e.display.view[a])}function Br(e){Pr(e),e.display.cachedCharWidth=e.display.cachedTextHeight=e.display.cachedPaddingH=null,e.options.lineWrapping||(e.display.maxLineChanged=!0),e.display.lineNumChars=null}function Ir(){return n&&f?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function Kr(){return n&&f?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function zr(e){var a=0;if(e.widgets)for(var D=0;D<e.widgets.length;++D)e.widgets[D].above&&(a+=Lr(e.widgets[D]));return a}function on(e,a,D,A,U){if(!U){var V=zr(a);D.top+=V,D.bottom+=V}if(A=="line")return D;A||(A="local");var re=Zt(a);if(A=="local"?re+=Nn(e.display):re-=e.display.viewOffset,A=="page"||A=="window"){var se=e.display.lineSpace.getBoundingClientRect();re+=se.top+(A=="window"?0:Kr());var ce=se.left+(A=="window"?0:Ir());D.left+=ce,D.right+=ce}return D.top+=re,D.bottom+=re,D}function $r(e,a,D){if(D=="div")return a;var A=a.left,U=a.top;if(D=="page")A-=Ir(),U-=Kr();else if(D=="local"||!D){var V=e.display.sizer.getBoundingClientRect();A+=V.left,U+=V.top}var re=e.display.lineSpace.getBoundingClientRect();return{left:A-re.left,top:U-re.top}}function gn(e,a,D,A,U){return A||(A=er(e.doc,a.line)),on(e,A,Fe(e,A,a.ch,U),D)}function Zr(e,a,D,A,U,V){A=A||er(e.doc,a.line),U||(U=je(e,A));function re(vt,Rt){var Ft=Ge(e,U,vt,Rt?"right":"left",V);return Rt?Ft.left=Ft.right:Ft.right=Ft.left,on(e,A,Ft,D)}var se=ot(A,e.doc.direction),ce=a.ch,ve=a.sticky;if(ce>=A.text.length?(ce=A.text.length,ve="before"):ce<=0&&(ce=0,ve="after"),!se)return re(ve=="before"?ce-1:ce,ve=="before");function Ne(vt,Rt,Ft){var Yt=se[Rt],sr=Yt.level==1;return re(Ft?vt-1:vt,sr!=Ft)}var He=rt(se,ce,ve),tt=Ye,$e=Ne(ce,He,ve=="before");return tt!=null&&($e.other=Ne(ce,tt,ve!="before")),$e}function wr(e,a){var D=0;a=xr(e.doc,a),e.options.lineWrapping||(D=Kn(e.display)*a.ch);var A=er(e.doc,a.line),U=Zt(A)+Nn(e.display);return{left:D,right:D,top:U,bottom:U+A.height}}function Ar(e,a,D,A,U){var V=It(e,a,D);return V.xRel=U,A&&(V.outside=A),V}function Xr(e,a,D){var A=e.doc;if(D+=e.display.viewOffset,D<0)return Ar(A.first,0,null,-1,-1);var U=Ln(A,D),V=A.first+A.size-1;if(U>V)return Ar(A.first+A.size-1,er(A,V).text.length,null,1,1);a<0&&(a=0);for(var re=er(A,U);;){var se=An(e,re,U,a,D),ce=kt(re,se.ch+(se.xRel>0||se.outside>0?1:0));if(!ce)return se;var ve=ce.find(1);if(ve.line==U)return ve;re=er(A,U=ve.line)}}function nn(e,a,D,A){A-=zr(a);var U=a.text.length,V=ze(function(re){return Ge(e,D,re-1).bottom<=A},U,0);return U=ze(function(re){return Ge(e,D,re).top>A},V,U),{begin:V,end:U}}function fr(e,a,D,A){D||(D=je(e,a));var U=on(e,a,Ge(e,D,A),"line").top;return nn(e,a,D,U)}function un(e,a,D,A){return e.bottom<=D?!1:e.top>D?!0:(A?e.left:e.right)>a}function An(e,a,D,A,U){U-=Zt(a);var V=je(e,a),re=zr(a),se=0,ce=a.text.length,ve=!0,Ne=ot(a,e.doc.direction);if(Ne){var He=(e.options.lineWrapping?En:fn)(e,a,D,V,Ne,A,U);ve=He.level!=1,se=ve?He.from:He.to-1,ce=ve?He.to:He.from-1}var tt=null,$e=null,vt=ze(function(Fr){var Dr=Ge(e,V,Fr);return Dr.top+=re,Dr.bottom+=re,un(Dr,A,U,!1)?(Dr.top<=U&&Dr.left<=A&&(tt=Fr,$e=Dr),!0):!1},se,ce),Rt,Ft,Yt=!1;if($e){var sr=A-$e.left<$e.right-A,$t=sr==ve;vt=tt+($t?0:1),Ft=$t?"after":"before",Rt=sr?$e.left:$e.right}else{!ve&&(vt==ce||vt==se)&&vt++,Ft=vt==0?"after":vt==a.text.length?"before":Ge(e,V,vt-(ve?1:0)).bottom+re<=U==ve?"after":"before";var pr=Zr(e,It(D,vt,Ft),"line",a,V);Rt=pr.left,Yt=U<pr.top?-1:U>=pr.bottom?1:0}return vt=Te(a.text,vt,1),Ar(D,vt,Ft,Yt,A-Rt)}function fn(e,a,D,A,U,V,re){var se=ze(function(He){var tt=U[He],$e=tt.level!=1;return un(Zr(e,It(D,$e?tt.to:tt.from,$e?"before":"after"),"line",a,A),V,re,!0)},0,U.length-1),ce=U[se];if(se>0){var ve=ce.level!=1,Ne=Zr(e,It(D,ve?ce.from:ce.to,ve?"after":"before"),"line",a,A);un(Ne,V,re,!0)&&Ne.top>re&&(ce=U[se-1])}return ce}function En(e,a,D,A,U,V,re){var se=nn(e,a,A,re),ce=se.begin,ve=se.end;/\s/.test(a.text.charAt(ve-1))&&ve--;for(var Ne=null,He=null,tt=0;tt<U.length;tt++){var $e=U[tt];if($e.from>=ve||$e.to<=ce)continue;var vt=$e.level!=1,Rt=Ge(e,A,vt?Math.min(ve,$e.to)-1:Math.max(ce,$e.from)).right,Ft=Rt<V?V-Rt+1e9:Rt-V;(!Ne||He>Ft)&&(Ne=$e,He=Ft)}return Ne||(Ne=U[U.length-1]),Ne.from<ce&&(Ne={from:ce,to:Ne.to,level:Ne.level}),Ne.to>ve&&(Ne={from:Ne.from,to:ve,level:Ne.level}),Ne}var hn;function Fn(e){if(e.cachedTextHeight!=null)return e.cachedTextHeight;if(hn==null){hn=T("pre",null,"CodeMirror-line-like");for(var a=0;a<49;++a)hn.appendChild(document.createTextNode("x")),hn.appendChild(T("br"));hn.appendChild(document.createTextNode("x"))}E(e.measure,hn);var D=hn.offsetHeight/50;return D>3&&(e.cachedTextHeight=D),_(e.measure),D||1}function Kn(e){if(e.cachedCharWidth!=null)return e.cachedCharWidth;var a=T("span","xxxxxxxxxx"),D=T("pre",[a],"CodeMirror-line-like");E(e.measure,D);var A=a.getBoundingClientRect(),U=(A.right-A.left)/10;return U>2&&(e.cachedCharWidth=U),U||10}function Rn(e){for(var a=e.display,D={},A={},U=a.gutters.clientLeft,V=a.gutters.firstChild,re=0;V;V=V.nextSibling,++re){var se=e.display.gutterSpecs[re].className;D[se]=V.offsetLeft+V.clientLeft+U,A[se]=V.clientWidth}return{fixedPos:Zn(a),gutterTotalWidth:a.gutters.offsetWidth,gutterLeft:D,gutterWidth:A,wrapperWidth:a.wrapper.clientWidth}}function Zn(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function Na(e){var a=Fn(e.display),D=e.options.lineWrapping,A=D&&Math.max(5,e.display.scroller.clientWidth/Kn(e.display)-3);return function(U){if(jt(e.doc,U))return 0;var V=0;if(U.widgets)for(var re=0;re<U.widgets.length;re++)U.widgets[re].height&&(V+=U.widgets[re].height);return D?V+(Math.ceil(U.text.length/A)||1)*a:V+a}}function ua(e){var a=e.doc,D=Na(e);a.iter(function(A){var U=D(A);U!=A.height&&Pn(A,U)})}function zn(e,a,D,A){var U=e.display;if(!D&&ke(a).getAttribute("cm-not-content")=="true")return null;var V,re,se=U.lineSpace.getBoundingClientRect();try{V=a.clientX-se.left,re=a.clientY-se.top}catch(He){return null}var ce=Xr(e,V,re),ve;if(A&&ce.xRel>0&&(ve=er(e.doc,ce.line).text).length==ce.ch){var Ne=K(ve,ve.length,e.options.tabSize)-ve.length;ce=It(ce.line,Math.max(0,Math.round((V-Ue(e.display).left)/Kn(e.display))-Ne))}return ce}function xn(e,a){if(a>=e.display.viewTo)return null;if(a-=e.display.viewFrom,a<0)return null;for(var D=e.display.view,A=0;A<D.length;A++)if(a-=D[A].size,a<0)return A}function Tn(e,a,D,A){a==null&&(a=e.doc.first),D==null&&(D=e.doc.first+e.doc.size),A||(A=0);var U=e.display;if(A&&D<U.viewTo&&(U.updateLineNumbers==null||U.updateLineNumbers>a)&&(U.updateLineNumbers=a),e.curOp.viewChanged=!0,a>=U.viewTo)jn&&Jt(e.doc,a)<U.viewTo&&Cn(e);else if(D<=U.viewFrom)jn&&Wt(e.doc,D+A)>U.viewFrom?Cn(e):(U.viewFrom+=A,U.viewTo+=A);else if(a<=U.viewFrom&&D>=U.viewTo)Cn(e);else if(a<=U.viewFrom){var V=Bn(e,D,D+A,1);V?(U.view=U.view.slice(V.index),U.viewFrom=V.lineN,U.viewTo+=A):Cn(e)}else if(D>=U.viewTo){var re=Bn(e,a,a,-1);re?(U.view=U.view.slice(0,re.index),U.viewTo=re.lineN):Cn(e)}else{var se=Bn(e,a,a,-1),ce=Bn(e,D,D+A,1);se&&ce?(U.view=U.view.slice(0,se.index).concat(Vr(e,se.lineN,ce.lineN)).concat(U.view.slice(ce.index)),U.viewTo+=A):Cn(e)}var ve=U.externalMeasured;ve&&(D<ve.lineN?ve.lineN+=A:a<ve.lineN+ve.size&&(U.externalMeasured=null))}function In(e,a,D){e.curOp.viewChanged=!0;var A=e.display,U=e.display.externalMeasured;if(U&&a>=U.lineN&&a<U.lineN+U.size&&(A.externalMeasured=null),a<A.viewFrom||a>=A.viewTo)return;var V=A.view[xn(e,a)];if(V.node==null)return;var re=V.changes||(V.changes=[]);ne(re,D)==-1&&re.push(D)}function Cn(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function Bn(e,a,D,A){var U=xn(e,a),V,re=e.display.view;if(!jn||D==e.doc.first+e.doc.size)return{index:U,lineN:D};for(var se=e.display.viewFrom,ce=0;ce<U;ce++)se+=re[ce].size;if(se!=a){if(A>0){if(U==re.length-1)return null;V=se+re[U].size-a,U++}else V=se-a;a+=V,D+=V}for(;Jt(e.doc,D)!=D;){if(U==(A<0?0:re.length-1))return null;D+=A*re[U-(A<0?1:0)].size,U+=A}return{index:U,lineN:D}}function ga(e,a,D){var A=e.display,U=A.view;U.length==0||a>=A.viewTo||D<=A.viewFrom?(A.view=Vr(e,a,D),A.viewFrom=a):(A.viewFrom>a?A.view=Vr(e,a,A.viewFrom).concat(A.view):A.viewFrom<a&&(A.view=A.view.slice(xn(e,a))),A.viewFrom=a,A.viewTo<D?A.view=A.view.concat(Vr(e,A.viewTo,D)):A.viewTo>D&&(A.view=A.view.slice(0,xn(e,D)))),A.viewTo=D}function Va(e){for(var a=e.display.view,D=0,A=0;A<a.length;A++){var U=a[A];!U.hidden&&(!U.node||U.changes)&&++D}return D}function mn(e){e.display.input.showSelection(e.display.input.prepareSelection())}function Ca(e,a){a===void 0&&(a=!0);for(var D=e.doc,A={},U=A.cursors=document.createDocumentFragment(),V=A.selection=document.createDocumentFragment(),re=0;re<D.sel.ranges.length;re++){if(!a&&re==D.sel.primIndex)continue;var se=D.sel.ranges[re];if(se.from().line>=e.display.viewTo||se.to().line<e.display.viewFrom)continue;var ce=se.empty();(ce||e.options.showCursorWhenSelecting)&&Aa(e,se.head,U),ce||pn(e,se,V)}return A}function Aa(e,a,D){var A=Zr(e,a,"div",null,null,!e.options.singleCursorHeightPerLine),U=D.appendChild(T("div","\xA0","CodeMirror-cursor"));if(U.style.left=A.left+"px",U.style.top=A.top+"px",U.style.height=Math.max(0,A.bottom-A.top)*e.options.cursorHeight+"px",A.other){var V=D.appendChild(T("div","\xA0","CodeMirror-cursor CodeMirror-secondarycursor"));V.style.display="",V.style.left=A.other.left+"px",V.style.top=A.other.top+"px",V.style.height=(A.other.bottom-A.other.top)*.85+"px"}}function bn(e,a){return e.top-a.top||e.left-a.left}function pn(e,a,D){var A=e.display,U=e.doc,V=document.createDocumentFragment(),re=Ue(e.display),se=re.left,ce=Math.max(A.sizerWidth,Le(e)-A.sizer.offsetLeft)-re.right,ve=U.direction=="ltr";function Ne($t,pr,Fr,Dr){pr<0&&(pr=0),pr=Math.round(pr),Dr=Math.round(Dr),V.appendChild(T("div",null,"CodeMirror-selected","position: absolute; left: "+$t+`px;
top: `+pr+"px; width: "+(Fr==null?ce-$t:Fr)+`px;
height: `+(Dr-pr)+"px"))}function He($t,pr,Fr){var Dr=er(U,$t),sn=Dr.text.length,Dn,ca;function Wn(qn,Ba){return gn(e,It($t,qn),"div",Dr,Ba)}function Ga(qn,Ba,ya){var sa=fr(e,Dr,null,qn),ea=Ba=="ltr"==(ya=="after")?"left":"right",Gn=ya=="after"?sa.begin:sa.end-(/\s/.test(Dr.text.charAt(sa.end-1))?2:1);return Wn(Gn,ea)[ea]}var Ua=ot(Dr,U.direction);return Xe(Ua,pr||0,Fr==null?sn:Fr,function(qn,Ba,ya,sa){var ea=ya=="ltr",Gn=Wn(qn,ea?"left":"right"),Ha=Wn(Ba-1,ea?"right":"left"),lo=pr==null&&qn==0,Ui=Fr==null&&Ba==sn,Oa=sa==0,yi=!Ua||sa==Ua.length-1;if(Ha.top-Gn.top<=3){var da=(ve?lo:Ui)&&Oa,ps=(ve?Ui:lo)&&yi,Ii=da?se:(ea?Gn:Ha).left,Gi=ps?ce:(ea?Ha:Gn).right;Ne(Ii,Gn.top,Gi-Ii,Gn.bottom)}else{var Xi,La,uo,ms;ea?(Xi=ve&&lo&&Oa?se:Gn.left,La=ve?ce:Ga(qn,ya,"before"),uo=ve?se:Ga(Ba,ya,"after"),ms=ve&&Ui&&yi?ce:Ha.right):(Xi=ve?Ga(qn,ya,"before"):se,La=!ve&&lo&&Oa?ce:Gn.right,uo=!ve&&Ui&&yi?se:Ha.left,ms=ve?Ga(Ba,ya,"after"):ce),Ne(Xi,Gn.top,La-Xi,Gn.bottom),Gn.bottom<Ha.top&&Ne(se,Gn.bottom,null,Ha.top),Ne(uo,Ha.top,ms-uo,Ha.bottom)}(!Dn||bn(Gn,Dn)<0)&&(Dn=Gn),bn(Ha,Dn)<0&&(Dn=Ha),(!ca||bn(Gn,ca)<0)&&(ca=Gn),bn(Ha,ca)<0&&(ca=Ha)}),{start:Dn,end:ca}}var tt=a.from(),$e=a.to();if(tt.line==$e.line)He(tt.line,tt.ch,$e.ch);else{var vt=er(U,tt.line),Rt=er(U,$e.line),Ft=gt(vt)==gt(Rt),Yt=He(tt.line,tt.ch,Ft?vt.text.length+1:null).end,sr=He($e.line,Ft?0:null,$e.ch).start;Ft&&(Yt.top<sr.top-2?(Ne(Yt.right,Yt.top,null,Yt.bottom),Ne(se,sr.top,sr.left,sr.bottom)):Ne(Yt.right,Yt.top,sr.left-Yt.right,Yt.bottom)),Yt.bottom<sr.top&&Ne(se,Yt.bottom,null,sr.top)}D.appendChild(V)}function Hn(e){if(!e.state.focused)return;var a=e.display;clearInterval(a.blinker);var D=!0;a.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?a.blinker=setInterval(function(){e.hasFocus()||ri(e),a.cursorDiv.style.visibility=(D=!D)?"":"hidden"},e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(a.cursorDiv.style.visibility="hidden")}function Bi(e){e.state.focused||(e.display.input.focus(),ti(e))}function xi(e){e.state.delayingBlurEvent=!0,setTimeout(function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,ri(e))},100)}function ti(e,a){if(e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1),e.options.readOnly=="nocursor")return;e.state.focused||(We(e,"focus",e,a),e.state.focused=!0,W(e.display.wrapper,"CodeMirror-focused"),!e.curOp&&e.display.selForContextMenu!=e.doc.sel&&(e.display.input.reset(),p&&setTimeout(function(){return e.display.input.reset(!0)},20)),e.display.input.receivedFocus()),Hn(e)}function ri(e,a){if(e.state.delayingBlurEvent)return;e.state.focused&&(We(e,"blur",e,a),e.state.focused=!1,g(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout(function(){e.state.focused||(e.display.shift=!1)},150)}function Li(e){for(var a=e.display,D=a.lineDiv.offsetTop,A=0;A<a.view.length;A++){var U=a.view[A],V=e.options.lineWrapping,re=void 0,se=0;if(U.hidden)continue;if(w&&b<8){var ce=U.node.offsetTop+U.node.offsetHeight;re=ce-D,D=ce}else{var ve=U.node.getBoundingClientRect();re=ve.bottom-ve.top,!V&&U.text.firstChild&&(se=U.text.firstChild.getBoundingClientRect().right-ve.left-1)}var Ne=U.line.height-re;if((Ne>.005||Ne<-.005)&&(Pn(U.line,re),Ti(U.line),U.rest))for(var He=0;He<U.rest.length;He++)Ti(U.rest[He]);if(se>e.display.sizerWidth){var tt=Math.ceil(se/Kn(e.display));tt>e.display.maxLineLength&&(e.display.maxLineLength=tt,e.display.maxLine=U.line,e.display.maxLineChanged=!0)}}}function Ti(e){if(e.widgets)for(var a=0;a<e.widgets.length;++a){var D=e.widgets[a],A=D.node.parentNode;A&&(D.height=A.offsetHeight)}}function Pi(e,a,D){var A=D&&D.top!=null?Math.max(0,D.top):e.scroller.scrollTop;A=Math.floor(A-Nn(e));var U=D&&D.bottom!=null?D.bottom:A+e.wrapper.clientHeight,V=Ln(a,A),re=Ln(a,U);if(D&&D.ensure){var se=D.ensure.from.line,ce=D.ensure.to.line;se<V?(V=se,re=Ln(a,Zt(er(a,se))+e.wrapper.clientHeight)):Math.min(ce,a.lastLine())>=re&&(V=Ln(a,Zt(er(a,ce))-e.wrapper.clientHeight),re=ce)}return{from:V,to:Math.max(re,V+1)}}function Hi(e,a){if(et(e,"scrollCursorIntoView"))return;var D=e.display,A=D.sizer.getBoundingClientRect(),U=null;if(a.top+A.top<0?U=!0:a.bottom+A.top>(window.innerHeight||document.documentElement.clientHeight)&&(U=!1),U!=null&&!o){var V=T("div","\u200B",null,`position: absolute;
top: `+(a.top-D.viewOffset-Nn(e.display))+`px;
height: `+(a.bottom-a.top+Ke(e)+D.barHeight)+`px;
left: `+a.left+"px; width: "+Math.max(2,a.right-a.left)+"px;");e.display.lineSpace.appendChild(V),V.scrollIntoView(U),e.display.lineSpace.removeChild(V)}}function Vi(e,a,D,A){A==null&&(A=0);var U;!e.options.lineWrapping&&a==D&&(a=a.ch?It(a.line,a.sticky=="before"?a.ch-1:a.ch,"after"):a,D=a.sticky=="before"?It(a.line,a.ch+1,"before"):a);for(var V=0;V<5;V++){var re=!1,se=Zr(e,a),ce=!D||D==a?se:Zr(e,D);U={left:Math.min(se.left,ce.left),top:Math.min(se.top,ce.top)-A,right:Math.max(se.left,ce.left),bottom:Math.max(se.bottom,ce.bottom)+A};var ve=ni(e,U),Ne=e.doc.scrollTop,He=e.doc.scrollLeft;if(ve.scrollTop!=null&&(ii(e,ve.scrollTop),Math.abs(e.doc.scrollTop-Ne)>1&&(re=!0)),ve.scrollLeft!=null&&(ja(e,ve.scrollLeft),Math.abs(e.doc.scrollLeft-He)>1&&(re=!0)),!re)break}return U}function ki(e,a){var D=ni(e,a);D.scrollTop!=null&&ii(e,D.scrollTop),D.scrollLeft!=null&&ja(e,D.scrollLeft)}function ni(e,a){var D=e.display,A=Fn(e.display);a.top<0&&(a.top=0);var U=e.curOp&&e.curOp.scrollTop!=null?e.curOp.scrollTop:D.scroller.scrollTop,V=he(e),re={};a.bottom-a.top>V&&(a.bottom=a.top+V);var se=e.doc.height+Ae(D),ce=a.top<A,ve=a.bottom>se-A;if(a.top<U)re.scrollTop=ce?0:a.top;else if(a.bottom>U+V){var Ne=Math.min(a.top,(ve?se:a.bottom)-V);Ne!=U&&(re.scrollTop=Ne)}var He=e.options.fixedGutter?0:D.gutters.offsetWidth,tt=e.curOp&&e.curOp.scrollLeft!=null?e.curOp.scrollLeft:D.scroller.scrollLeft-He,$e=Le(e)-D.gutters.offsetWidth,vt=a.right-a.left>$e;return vt&&(a.right=a.left+$e),a.left<10?re.scrollLeft=0:a.left<tt?re.scrollLeft=Math.max(0,a.left+He-(vt?0:10)):a.right>$e+tt-3&&(re.scrollLeft=a.right+(vt?0:10)-$e),re}function wi(e,a){if(a==null)return;gi(e),e.curOp.scrollTop=(e.curOp.scrollTop==null?e.doc.scrollTop:e.curOp.scrollTop)+a}function vi(e){gi(e);var a=e.getCursor();e.curOp.scrollToPos={from:a,to:a,margin:e.options.cursorScrollMargin}}function ai(e,a,D){(a!=null||D!=null)&&gi(e),a!=null&&(e.curOp.scrollLeft=a),D!=null&&(e.curOp.scrollTop=D)}function co(e,a){gi(e),e.curOp.scrollToPos=a}function gi(e){var a=e.curOp.scrollToPos;if(a){e.curOp.scrollToPos=null;var D=wr(e,a.from),A=wr(e,a.to);Si(e,D,A,a.margin)}}function Si(e,a,D,A){var U=ni(e,{left:Math.min(a.left,D.left),top:Math.min(a.top,D.top)-A,right:Math.max(a.right,D.right),bottom:Math.max(a.bottom,D.bottom)+A});ai(e,U.scrollLeft,U.scrollTop)}function ii(e,a){if(Math.abs(e.doc.scrollTop-a)<2)return;C||Ki(e,{top:a}),li(e,a,!0),C&&Ki(e),Wi(e,100)}function li(e,a,D){if(a=Math.max(0,Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,a)),e.display.scroller.scrollTop==a&&!D)return;e.doc.scrollTop=a,e.display.scrollbars.setScrollTop(a),e.display.scroller.scrollTop!=a&&(e.display.scroller.scrollTop=a)}function ja(e,a,D,A){if(a=Math.max(0,Math.min(a,e.display.scroller.scrollWidth-e.display.scroller.clientWidth)),(D?a==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-a)<2)&&!A)return;e.doc.scrollLeft=a,dn(e),e.display.scroller.scrollLeft!=a&&(e.display.scroller.scrollLeft=a),e.display.scrollbars.setScrollLeft(a)}function Ya(e){var a=e.display,D=a.gutters.offsetWidth,A=Math.round(e.doc.height+Ae(e.display));return{clientHeight:a.scroller.clientHeight,viewHeight:a.wrapper.clientHeight,scrollWidth:a.scroller.scrollWidth,clientWidth:a.scroller.clientWidth,viewWidth:a.wrapper.clientWidth,barLeft:e.options.fixedGutter?D:0,docHeight:A,scrollHeight:A+Ke(e)+a.barHeight,nativeBarWidth:a.nativeBarWidth,gutterWidth:D}}var cr=function(e,a,D){this.cm=D;var A=this.vert=T("div",[T("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),U=this.horiz=T("div",[T("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");A.tabIndex=U.tabIndex=-1,e(A),e(U),Se(A,"scroll",function(){A.clientHeight&&a(A.scrollTop,"vertical")}),Se(U,"scroll",function(){U.clientWidth&&a(U.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,w&&b<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};cr.prototype.update=function(e){var a=e.scrollWidth>e.clientWidth+1,D=e.scrollHeight>e.clientHeight+1,A=e.nativeBarWidth;if(D){this.vert.style.display="block",this.vert.style.bottom=a?A+"px":"0";var U=e.viewHeight-(a?A:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+U)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(a){this.horiz.style.display="block",this.horiz.style.right=D?A+"px":"0",this.horiz.style.left=e.barLeft+"px";var V=e.viewWidth-e.barLeft-(D?A:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+V)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(A==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:D?A:0,bottom:a?A:0}},cr.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},cr.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},cr.prototype.zeroWidthHack=function(){var e=l&&!i?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new Y,this.disableVert=new Y},cr.prototype.enableZeroWidthBar=function(e,a,D){e.style.pointerEvents="auto";function A(){var U=e.getBoundingClientRect(),V=D=="vert"?document.elementFromPoint(U.right-1,(U.top+U.bottom)/2):document.elementFromPoint((U.right+U.left)/2,U.bottom-1);V!=e?e.style.pointerEvents="none":a.set(1e3,A)}a.set(1e3,A)},cr.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var hr=function(){};hr.prototype.update=function(){return{bottom:0,right:0}},hr.prototype.setScrollLeft=function(){},hr.prototype.setScrollTop=function(){},hr.prototype.clear=function(){};function Qt(e,a){a||(a=Ya(e));var D=e.display.barWidth,A=e.display.barHeight;cn(e,a);for(var U=0;U<4&&D!=e.display.barWidth||A!=e.display.barHeight;U++)D!=e.display.barWidth&&e.options.lineWrapping&&Li(e),cn(e,Ya(e)),D=e.display.barWidth,A=e.display.barHeight}function cn(e,a){var D=e.display,A=D.scrollbars.update(a);D.sizer.style.paddingRight=(D.barWidth=A.right)+"px",D.sizer.style.paddingBottom=(D.barHeight=A.bottom)+"px",D.heightForcer.style.borderBottom=A.bottom+"px solid transparent",A.right&&A.bottom?(D.scrollbarFiller.style.display="block",D.scrollbarFiller.style.height=A.bottom+"px",D.scrollbarFiller.style.width=A.right+"px"):D.scrollbarFiller.style.display="",A.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(D.gutterFiller.style.display="block",D.gutterFiller.style.height=A.bottom+"px",D.gutterFiller.style.width=a.gutterWidth+"px"):D.gutterFiller.style.display=""}var qt={native:cr,null:hr};function ui(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&g(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new qt[e.options.scrollbarStyle](function(a){e.display.wrapper.insertBefore(a,e.display.scrollbarFiller),Se(a,"mousedown",function(){e.state.focused&&setTimeout(function(){return e.display.input.focus()},0)}),a.setAttribute("cm-not-content","true")},function(a,D){D=="horizontal"?ja(e,a):ii(e,a)},e),e.display.scrollbars.addClass&&W(e.display.wrapper,e.display.scrollbars.addClass)}var Yi=0;function Sn(e){e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Yi},ir(e.curOp)}function Oi(e){var a=e.curOp;a&&Tr(a,function(D){for(var A=0;A<D.ops.length;A++)D.ops[A].cm.curOp=null;Io(D)})}function Io(e){for(var a=e.ops,D=0;D<a.length;D++)Jo(a[D]);for(var A=0;A<a.length;A++)Qo(a[A]);for(var U=0;U<a.length;U++)Zo(a[U]);for(var V=0;V<a.length;V++)fo(a[V]);for(var re=0;re<a.length;re++)qo(a[re])}function Jo(e){var a=e.cm,D=a.display;Do(a),e.updateMaxLine&&vr(a),e.mustUpdate=e.viewChanged||e.forceUpdate||e.scrollTop!=null||e.scrollToPos&&(e.scrollToPos.from.line<D.viewFrom||e.scrollToPos.to.line>=D.viewTo)||D.maxLineChanged&&a.options.lineWrapping,e.update=e.mustUpdate&&new $a(a,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function Qo(e){e.updatedDisplay=e.mustUpdate&&Ci(e.cm,e.update)}function Zo(e){var a=e.cm,D=a.display;e.updatedDisplay&&Li(a),e.barMeasure=Ya(a),D.maxLineChanged&&!a.options.lineWrapping&&(e.adjustWidthTo=Fe(a,D.maxLine,D.maxLine.text.length).left+3,a.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(D.scroller.clientWidth,D.sizer.offsetLeft+e.adjustWidthTo+Ke(a)+a.display.barWidth),e.maxScrollLeft=Math.max(0,D.sizer.offsetLeft+e.adjustWidthTo-Le(a))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=D.input.prepareSelection())}function fo(e){var a=e.cm;e.adjustWidthTo!=null&&(a.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<a.doc.scrollLeft&&ja(a,Math.min(a.display.scroller.scrollLeft,e.maxScrollLeft),!0),a.display.maxLineChanged=!1);var D=e.focus&&e.focus==G();e.preparedSelection&&a.display.input.showSelection(e.preparedSelection,D),(e.updatedDisplay||e.startHeight!=a.doc.height)&&Qt(a,e.barMeasure),e.updatedDisplay&&yn(a,e.barMeasure),e.selectionChanged&&Hn(a),a.state.focused&&e.updateInput&&a.display.input.reset(e.typing),D&&Bi(e.cm)}function qo(e){var a=e.cm,D=a.display,A=a.doc;if(e.updatedDisplay&&$i(a,e.update),D.wheelStartX!=null&&(e.scrollTop!=null||e.scrollLeft!=null||e.scrollToPos)&&(D.wheelStartX=D.wheelStartY=null),e.scrollTop!=null&&li(a,e.scrollTop,e.forceScroll),e.scrollLeft!=null&&ja(a,e.scrollLeft,!0,!0),e.scrollToPos){var U=Vi(a,xr(A,e.scrollToPos.from),xr(A,e.scrollToPos.to),e.scrollToPos.margin);Hi(a,U)}var V=e.maybeHiddenMarkers,re=e.maybeUnhiddenMarkers;if(V)for(var se=0;se<V.length;++se)V[se].lines.length||We(V[se],"hide");if(re)for(var ce=0;ce<re.length;++ce)re[ce].lines.length&&We(re[ce],"unhide");D.wrapper.offsetHeight&&(A.scrollTop=a.display.scroller.scrollTop),e.changeObjs&&We(a,"changes",a,e.changeObjs),e.update&&e.update.finish()}function Ra(e,a){if(e.curOp)return a();Sn(e);try{return a()}finally{Oi(e)}}function Yn(e,a){return function(){if(e.curOp)return a.apply(e,arguments);Sn(e);try{return a.apply(e,arguments)}finally{Oi(e)}}}function ba(e){return function(){if(this.curOp)return e.apply(this,arguments);Sn(this);try{return e.apply(this,arguments)}finally{Oi(this)}}}function $n(e){return function(){var a=this.cm;if(!a||a.curOp)return e.apply(this,arguments);Sn(a);try{return e.apply(this,arguments)}finally{Oi(a)}}}function Wi(e,a){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(a,B(es,e))}function es(e){var a=e.doc;if(a.highlightFrontier>=e.display.viewTo)return;var D=+new Date+e.options.workTime,A=Qn(e,a.highlightFrontier),U=[];a.iter(A.line,Math.min(a.first+a.size,e.display.viewTo+500),function(V){if(A.line>=e.display.viewFrom){var re=V.styles,se=V.text.length>e.options.maxHighlightLength?Jr(a.mode,A.state):null,ce=Ka(e,V,A,!0);se&&(A.state=se),V.styles=ce.styles;var ve=V.styleClasses,Ne=ce.classes;Ne?V.styleClasses=Ne:ve&&(V.styleClasses=null);for(var He=!re||re.length!=V.styles.length||ve!=Ne&&(!ve||!Ne||ve.bgClass!=Ne.bgClass||ve.textClass!=Ne.textClass),tt=0;!He&&tt<re.length;++tt)He=re[tt]!=V.styles[tt];He&&U.push(A.line),V.stateAfter=A.save(),A.nextLine()}else V.text.length<=e.options.maxHighlightLength&&Qa(e,V.text,A),V.stateAfter=A.line%5==0?A.save():null,A.nextLine();if(+new Date>D)return Wi(e,e.options.workDelay),!0}),a.highlightFrontier=A.line,a.modeFrontier=Math.max(a.modeFrontier,A.line),U.length&&Ra(e,function(){for(var V=0;V<U.length;V++)In(e,U[V],"text")})}var $a=function(e,a,D){var A=e.display;this.viewport=a,this.visible=Pi(A,e.doc,a),this.editorIsHidden=!A.wrapper.offsetWidth,this.wrapperHeight=A.wrapper.clientHeight,this.wrapperWidth=A.wrapper.clientWidth,this.oldDisplayWidth=Le(e),this.force=D,this.dims=Rn(e),this.events=[]};$a.prototype.signal=function(e,a){Ce(e,a)&&this.events.push(arguments)},$a.prototype.finish=function(){for(var e=0;e<this.events.length;e++)We.apply(null,this.events[e])};function Do(e){var a=e.display;!a.scrollbarsClipped&&a.scroller.offsetWidth&&(a.nativeBarWidth=a.scroller.offsetWidth-a.scroller.clientWidth,a.heightForcer.style.height=Ke(e)+"px",a.sizer.style.marginBottom=-a.nativeBarWidth+"px",a.sizer.style.borderRightWidth=Ke(e)+"px",a.scrollbarsClipped=!0)}function Lo(e){if(e.hasFocus())return null;var a=G();if(!a||!P(e.display.lineDiv,a))return null;var D={activeElt:a};if(window.getSelection){var A=window.getSelection();A.anchorNode&&A.extend&&P(e.display.lineDiv,A.anchorNode)&&(D.anchorNode=A.anchorNode,D.anchorOffset=A.anchorOffset,D.focusNode=A.focusNode,D.focusOffset=A.focusOffset)}return D}function Po(e){if(!e||!e.activeElt||e.activeElt==G())return;if(e.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName)&&e.anchorNode&&P(document.body,e.anchorNode)&&P(document.body,e.focusNode)){var a=window.getSelection(),D=document.createRange();D.setEnd(e.anchorNode,e.anchorOffset),D.collapse(!1),a.removeAllRanges(),a.addRange(D),a.extend(e.focusNode,e.focusOffset)}}function Ci(e,a){var D=e.display,A=e.doc;if(a.editorIsHidden)return Cn(e),!1;if(!a.force&&a.visible.from>=D.viewFrom&&a.visible.to<=D.viewTo&&(D.updateLineNumbers==null||D.updateLineNumbers>=D.viewTo)&&D.renderedView==D.view&&Va(e)==0)return!1;ia(e)&&(Cn(e),a.dims=Rn(e));var U=A.first+A.size,V=Math.max(a.visible.from-e.options.viewportMargin,A.first),re=Math.min(U,a.visible.to+e.options.viewportMargin);D.viewFrom<V&&V-D.viewFrom<20&&(V=Math.max(A.first,D.viewFrom)),D.viewTo>re&&D.viewTo-re<20&&(re=Math.min(U,D.viewTo)),jn&&(V=Jt(e.doc,V),re=Wt(e.doc,re));var se=V!=D.viewFrom||re!=D.viewTo||D.lastWrapHeight!=a.wrapperHeight||D.lastWrapWidth!=a.wrapperWidth;ga(e,V,re),D.viewOffset=Zt(er(e.doc,D.viewFrom)),e.display.mover.style.top=D.viewOffset+"px";var ce=Va(e);if(!se&&ce==0&&!a.force&&D.renderedView==D.view&&(D.updateLineNumbers==null||D.updateLineNumbers>=D.viewTo))return!1;var ve=Lo(e);return ce>4&&(D.lineDiv.style.display="none"),ko(e,D.updateLineNumbers,a.dims),ce>4&&(D.lineDiv.style.display=""),D.renderedView=D.view,Po(ve),_(D.cursorDiv),_(D.selectionDiv),D.gutters.style.height=D.sizer.style.minHeight=0,se&&(D.lastWrapHeight=a.wrapperHeight,D.lastWrapWidth=a.wrapperWidth,Wi(e,400)),D.updateLineNumbers=null,!0}function $i(e,a){for(var D=a.viewport,A=!0;;A=!1){if(!A||!e.options.lineWrapping||a.oldDisplayWidth==Le(e)){if(D&&D.top!=null&&(D={top:Math.min(e.doc.height+Ae(e.display)-he(e),D.top)}),a.visible=Pi(e.display,e.doc,D),a.visible.from>=e.display.viewFrom&&a.visible.to<=e.display.viewTo)break}else A&&(a.visible=Pi(e.display,e.doc,D));if(!Ci(e,a))break;Li(e);var U=Ya(e);mn(e),Qt(e,U),yn(e,U),a.force=!1}a.signal(e,"update",e),(e.display.viewFrom!=e.display.reportedViewFrom||e.display.viewTo!=e.display.reportedViewTo)&&(a.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function Ki(e,a){var D=new $a(e,a);if(Ci(e,D)){Li(e),$i(e,D);var A=Ya(e);mn(e),Qt(e,A),yn(e,A),D.finish()}}function ko(e,a,D){var A=e.display,U=e.options.lineNumbers,V=A.lineDiv,re=V.firstChild;function se(vt){var Rt=vt.nextSibling;return p&&l&&e.display.currentWheelTarget==vt?vt.style.display="none":vt.parentNode.removeChild(vt),Rt}for(var ce=A.view,ve=A.viewFrom,Ne=0;Ne<ce.length;Ne++){var He=ce[Ne];if(!He.hidden)if(!He.node||He.node.parentNode!=V){var tt=mr(e,He,ve,D);V.insertBefore(tt,re)}else{for(;re!=He.node;)re=se(re);var $e=U&&a!=null&&a<=ve&&He.lineNumber;He.changes&&(ne(He.changes,"gutter")>-1&&($e=!1),Gt(e,He,ve,D)),$e&&(_(He.lineNumber),He.lineNumber.appendChild(document.createTextNode(fa(e.options,ve)))),re=He.node.nextSibling}ve+=He.size}for(;re;)re=se(re)}function Ji(e){var a=e.gutters.offsetWidth;e.sizer.style.marginLeft=a+"px"}function yn(e,a){e.display.sizer.style.minHeight=a.docHeight+"px",e.display.heightForcer.style.top=a.docHeight+"px",e.display.gutters.style.height=a.docHeight+e.display.barHeight+Ke(e)+"px"}function dn(e){var a=e.display,D=a.view;if(!a.alignWidgets&&(!a.gutters.firstChild||!e.options.fixedGutter))return;for(var A=Zn(a)-a.scroller.scrollLeft+e.doc.scrollLeft,U=a.gutters.offsetWidth,V=A+"px",re=0;re<D.length;re++)if(!D[re].hidden){e.options.fixedGutter&&(D[re].gutter&&(D[re].gutter.style.left=V),D[re].gutterBackground&&(D[re].gutterBackground.style.left=V));var se=D[re].alignable;if(se)for(var ce=0;ce<se.length;ce++)se[ce].style.left=V}e.options.fixedGutter&&(a.gutters.style.left=A+U+"px")}function ia(e){if(!e.options.lineNumbers)return!1;var a=e.doc,D=fa(e.options,a.first+a.size-1),A=e.display;if(D.length!=A.lineNumChars){var U=A.measure.appendChild(T("div",[T("div",D)],"CodeMirror-linenumber CodeMirror-gutter-elt")),V=U.firstChild.offsetWidth,re=U.offsetWidth-V;return A.lineGutter.style.width="",A.lineNumInnerWidth=Math.max(V,A.lineGutter.offsetWidth-re)+1,A.lineNumWidth=A.lineNumInnerWidth+re,A.lineNumChars=A.lineNumInnerWidth?D.length:-1,A.lineGutter.style.width=A.lineNumWidth+"px",Ji(e.display),!0}return!1}function Ia(e,a){for(var D=[],A=!1,U=0;U<e.length;U++){var V=e[U],re=null;if(typeof V!="string"&&(re=V.style,V=V.className),V=="CodeMirror-linenumbers")if(a)A=!0;else continue;D.push({className:V,style:re})}return a&&!A&&D.push({className:"CodeMirror-linenumbers",style:null}),D}function Mi(e){var a=e.gutters,D=e.gutterSpecs;_(a),e.lineGutter=null;for(var A=0;A<D.length;++A){var U=D[A],V=U.className,re=U.style,se=a.appendChild(T("div",null,"CodeMirror-gutter "+V));re&&(se.style.cssText=re),V=="CodeMirror-linenumbers"&&(e.lineGutter=se,se.style.width=(e.lineNumWidth||1)+"px")}a.style.display=D.length?"":"none",Ji(e)}function ci(e){Mi(e.display),Tn(e),dn(e)}function zi(e,a,D,A){var U=this;this.input=D,U.scrollbarFiller=T("div",null,"CodeMirror-scrollbar-filler"),U.scrollbarFiller.setAttribute("cm-not-content","true"),U.gutterFiller=T("div",null,"CodeMirror-gutter-filler"),U.gutterFiller.setAttribute("cm-not-content","true"),U.lineDiv=L("div",null,"CodeMirror-code"),U.selectionDiv=T("div",null,null,"position: relative; z-index: 1"),U.cursorDiv=T("div",null,"CodeMirror-cursors"),U.measure=T("div",null,"CodeMirror-measure"),U.lineMeasure=T("div",null,"CodeMirror-measure"),U.lineSpace=L("div",[U.measure,U.lineMeasure,U.selectionDiv,U.cursorDiv,U.lineDiv],null,"position: relative; outline: none");var V=L("div",[U.lineSpace],"CodeMirror-lines");U.mover=T("div",[V],null,"position: relative"),U.sizer=T("div",[U.mover],"CodeMirror-sizer"),U.sizerWidth=null,U.heightForcer=T("div",null,null,"position: absolute; height: "+oe+"px; width: 1px;"),U.gutters=T("div",null,"CodeMirror-gutters"),U.lineGutter=null,U.scroller=T("div",[U.sizer,U.heightForcer,U.gutters],"CodeMirror-scroll"),U.scroller.setAttribute("tabIndex","-1"),U.wrapper=T("div",[U.scrollbarFiller,U.gutterFiller,U.scroller],"CodeMirror"),w&&b<8&&(U.gutters.style.zIndex=-1,U.scroller.style.paddingRight=0),!p&&!(C&&s)&&(U.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(U.wrapper):e(U.wrapper)),U.viewFrom=U.viewTo=a.first,U.reportedViewFrom=U.reportedViewTo=a.first,U.view=[],U.renderedView=null,U.externalMeasured=null,U.viewOffset=0,U.lastWrapHeight=U.lastWrapWidth=0,U.updateLineNumbers=null,U.nativeBarWidth=U.barHeight=U.barWidth=0,U.scrollbarsClipped=!1,U.lineNumWidth=U.lineNumInnerWidth=U.lineNumChars=null,U.alignWidgets=!1,U.cachedCharWidth=U.cachedTextHeight=U.cachedPaddingH=null,U.maxLine=null,U.maxLineLength=0,U.maxLineChanged=!1,U.wheelDX=U.wheelDY=U.wheelStartX=U.wheelStartY=null,U.shift=!1,U.selForContextMenu=null,U.activeTouch=null,U.gutterSpecs=Ia(A.gutters,A.lineNumbers),Mi(U),D.init(U)}var bi=0,oa=null;w?oa=-.53:C?oa=15:n?oa=-.7:r&&(oa=-1/3);function Qi(e){var a=e.wheelDeltaX,D=e.wheelDeltaY;return a==null&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(a=e.detail),D==null&&e.detail&&e.axis==e.VERTICAL_AXIS?D=e.detail:D==null&&(D=e.wheelDelta),{x:a,y:D}}function ho(e){var a=Qi(e);return a.x*=oa,a.y*=oa,a}function po(e,a){var D=Qi(a),A=D.x,U=D.y,V=e.display,re=V.scroller,se=re.scrollWidth>re.clientWidth,ce=re.scrollHeight>re.clientHeight;if(!(A&&se||U&&ce))return;if(U&&l&&p){e:for(var ve=a.target,Ne=V.view;ve!=re;ve=ve.parentNode)for(var He=0;He<Ne.length;He++)if(Ne[He].node==ve){e.display.currentWheelTarget=ve;break e}}if(A&&!C&&!c&&oa!=null){U&&ce&&ii(e,Math.max(0,re.scrollTop+U*oa)),ja(e,Math.max(0,re.scrollLeft+A*oa)),(!U||U&&ce)&&pe(a),V.wheelStartX=null;return}if(U&&oa!=null){var tt=U*oa,$e=e.doc.scrollTop,vt=$e+V.wrapper.clientHeight;tt<0?$e=Math.max(0,$e+tt-50):vt=Math.min(e.doc.height,vt+tt+50),Ki(e,{top:$e,bottom:vt})}bi<20&&(V.wheelStartX==null?(V.wheelStartX=re.scrollLeft,V.wheelStartY=re.scrollTop,V.wheelDX=A,V.wheelDY=U,setTimeout(function(){if(V.wheelStartX==null)return;var Rt=re.scrollLeft-V.wheelStartX,Ft=re.scrollTop-V.wheelStartY,Yt=Ft&&V.wheelDY&&Ft/V.wheelDY||Rt&&V.wheelDX&&Rt/V.wheelDX;if(V.wheelStartX=V.wheelStartY=null,!Yt)return;oa=(oa*bi+Yt)/(bi+1),++bi},200)):(V.wheelDX+=A,V.wheelDY+=U))}var Da=function(e,a){this.ranges=e,this.primIndex=a};Da.prototype.primary=function(){return this.ranges[this.primIndex]},Da.prototype.equals=function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var a=0;a<this.ranges.length;a++){var D=this.ranges[a],A=e.ranges[a];if(!ha(D.anchor,A.anchor)||!ha(D.head,A.head))return!1}return!0},Da.prototype.deepCopy=function(){for(var e=[],a=0;a<this.ranges.length;a++)e[a]=new vn(xa(this.ranges[a].anchor),xa(this.ranges[a].head));return new Da(e,this.primIndex)},Da.prototype.somethingSelected=function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},Da.prototype.contains=function(e,a){a||(a=e);for(var D=0;D<this.ranges.length;D++){var A=this.ranges[D];if(dr(a,A.from())>=0&&dr(e,A.to())<=0)return D}return-1};var vn=function(e,a){this.anchor=e,this.head=a};vn.prototype.from=function(){return pa(this.anchor,this.head)},vn.prototype.to=function(){return Pa(this.anchor,this.head)},vn.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function Ja(e,a,D){var A=e&&e.options.selectionsMayTouch,U=a[D];a.sort(function(tt,$e){return dr(tt.from(),$e.from())}),D=ne(a,U);for(var V=1;V<a.length;V++){var re=a[V],se=a[V-1],ce=dr(se.to(),re.from());if(A&&!re.empty()?ce>0:ce>=0){var ve=pa(se.from(),re.from()),Ne=Pa(se.to(),re.to()),He=se.empty()?re.from()==re.head:se.from()==se.head;V<=D&&--D,a.splice(--V,2,new vn(He?Ne:ve,He?ve:Ne))}}return new Da(a,D)}function di(e,a){return new Da([new vn(e,a||e)],0)}function fi(e){return e.text?It(e.from.line+e.text.length-1,q(e.text).length+(e.text.length==1?e.from.ch:0)):e.to}function mo(e,a){if(dr(e,a.from)<0)return e;if(dr(e,a.to)<=0)return fi(a);var D=e.line+a.text.length-(a.to.line-a.from.line)-1,A=e.ch;return e.line==a.to.line&&(A+=fi(a).ch-a.to.ch),It(D,A)}function Zi(e,a){for(var D=[],A=0;A<e.sel.ranges.length;A++){var U=e.sel.ranges[A];D.push(new vn(mo(U.anchor,a),mo(U.head,a)))}return Ja(e.cm,D,e.sel.primIndex)}function Mo(e,a,D){return e.line==a.line?It(D.line,e.ch-a.ch+D.ch):It(D.line+(e.line-a.line),e.ch)}function No(e,a,D){for(var A=[],U=It(e.first,0),V=U,re=0;re<a.length;re++){var se=a[re],ce=Mo(se.from,U,V),ve=Mo(fi(se),U,V);if(U=se.to,V=ve,D=="around"){var Ne=e.sel.ranges[re],He=dr(Ne.head,Ne.anchor)<0;A[re]=new vn(He?ve:ce,He?ce:ve)}else A[re]=new vn(ce,ce)}return new Da(A,e.sel.primIndex)}function Ai(e){e.doc.mode=ur(e.options,e.doc.modeOption),vo(e)}function vo(e){e.doc.iter(function(a){a.stateAfter&&(a.stateAfter=null),a.styles&&(a.styles=null)}),e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,Wi(e,100),e.state.modeGen++,e.curOp&&Tn(e)}function vs(e,a){return a.from.ch==0&&a.to.ch==0&&q(a.text)==""&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function ts(e,a,D,A){function U(sr){return D?D[sr]:null}function V(sr,$t,pr){nr(sr,$t,pr,A),Ht(sr,"change",sr,a)}function re(sr,$t){for(var pr=[],Fr=sr;Fr<$t;++Fr)pr.push(new Or(ve[Fr],U(Fr),A));return pr}var se=a.from,ce=a.to,ve=a.text,Ne=er(e,se.line),He=er(e,ce.line),tt=q(ve),$e=U(ve.length-1),vt=ce.line-se.line;if(a.full)e.insert(0,re(0,ve.length)),e.remove(ve.length,e.size-ve.length);else if(vs(e,a)){var Rt=re(0,ve.length-1);V(He,He.text,$e),vt&&e.remove(se.line,vt),Rt.length&&e.insert(se.line,Rt)}else if(Ne==He)if(ve.length==1)V(Ne,Ne.text.slice(0,se.ch)+tt+Ne.text.slice(ce.ch),$e);else{var Ft=re(1,ve.length-1);Ft.push(new Or(tt+Ne.text.slice(ce.ch),$e,A)),V(Ne,Ne.text.slice(0,se.ch)+ve[0],U(0)),e.insert(se.line+1,Ft)}else if(ve.length==1)V(Ne,Ne.text.slice(0,se.ch)+ve[0]+He.text.slice(ce.ch),U(0)),e.remove(se.line+1,vt);else{V(Ne,Ne.text.slice(0,se.ch)+ve[0],U(0)),V(He,tt+He.text.slice(ce.ch),$e);var Yt=re(1,ve.length-1);vt>1&&e.remove(se.line+1,vt-1),e.insert(se.line+1,Yt)}Ht(e,"change",e,a)}function Ni(e,a,D){function A(U,V,re){if(U.linked)for(var se=0;se<U.linked.length;++se){var ce=U.linked[se];if(ce.doc==V)continue;var ve=re&&ce.sharedHist;if(D&&!ve)continue;a(ce.doc,ve),A(ce.doc,U,ve)}}A(e,null,!0)}function gs(e,a){if(a.cm)throw new Error("This document is already in use.");e.doc=a,a.cm=e,ua(e),Ai(e),bs(e),e.options.lineWrapping||vr(e),e.options.mode=a.modeOption,Tn(e)}function bs(e){(e.doc.direction=="rtl"?W:g)(e.display.lineDiv,"CodeMirror-rtl")}function pl(e){Ra(e,function(){bs(e),Tn(e)})}function jo(e){this.done=[],this.undone=[],this.undoDepth=Infinity,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e||1}function rs(e,a){var D={from:xa(a.from),to:fi(a),text:Xn(e,a.from,a.to)};return Es(e,D,a.from.line,a.to.line+1),Ni(e,function(A){return Es(A,D,a.from.line,a.to.line+1)},!0),D}function ys(e){for(;e.length;){var a=q(e);if(a.ranges)e.pop();else break}}function ml(e,a){if(a)return ys(e.done),q(e.done);if(e.done.length&&!q(e.done).ranges)return q(e.done);if(e.done.length>1&&!e.done[e.done.length-2].ranges)return e.done.pop(),q(e.done)}function _s(e,a,D,A){var U=e.history;U.undone.length=0;var V=+new Date,re,se;if((U.lastOp==A||U.lastOrigin==a.origin&&a.origin&&(a.origin.charAt(0)=="+"&&U.lastModTime>V-(e.cm?e.cm.options.historyEventDelay:500)||a.origin.charAt(0)=="*"))&&(re=ml(U,U.lastOp==A)))se=q(re.changes),dr(a.from,a.to)==0&&dr(a.from,se.to)==0?se.to=fi(a):re.changes.push(rs(e,a));else{var ce=q(U.done);for((!ce||!ce.ranges)&&Fo(e.sel,U.done),re={changes:[rs(e,a)],generation:U.generation},U.done.push(re);U.done.length>U.undoDepth;)U.done.shift(),U.done[0].ranges||U.done.shift()}U.done.push(D),U.generation=++U.maxGeneration,U.lastModTime=U.lastSelTime=V,U.lastOp=U.lastSelOp=A,U.lastOrigin=U.lastSelOrigin=a.origin,se||We(e,"historyAdded")}function vl(e,a,D,A){var U=a.charAt(0);return U=="*"||U=="+"&&D.ranges.length==A.ranges.length&&D.somethingSelected()==A.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}function gl(e,a,D,A){var U=e.history,V=A&&A.origin;D==U.lastSelOp||V&&U.lastSelOrigin==V&&(U.lastModTime==U.lastSelTime&&U.lastOrigin==V||vl(e,V,q(U.done),a))?U.done[U.done.length-1]=a:Fo(a,U.done),U.lastSelTime=+new Date,U.lastSelOrigin=V,U.lastSelOp=D,A&&A.clearRedo!==!1&&ys(U.undone)}function Fo(e,a){var D=q(a);D&&D.ranges&&D.equals(e)||a.push(e)}function Es(e,a,D,A){var U=a["spans_"+e.id],V=0;e.iter(Math.max(e.first,D),Math.min(e.first+e.size,A),function(re){re.markedSpans&&((U||(U=a["spans_"+e.id]={}))[V]=re.markedSpans),++V})}function bl(e){if(!e)return null;for(var a,D=0;D<e.length;++D)e[D].marker.explicitlyCleared?a||(a=e.slice(0,D)):a&&a.push(e[D]);return a?a.length?a:null:e}function yl(e,a){var D=a["spans_"+e.id];if(!D)return null;for(var A=[],U=0;U<a.text.length;++U)A.push(bl(D[U]));return A}function xs(e,a){var D=yl(e,a),A=qa(e,a);if(!D)return A;if(!A)return D;for(var U=0;U<D.length;++U){var V=D[U],re=A[U];if(V&&re){e:for(var se=0;se<re.length;++se){for(var ce=re[se],ve=0;ve<V.length;++ve)if(V[ve].marker==ce.marker)continue e;V.push(ce)}}else re&&(D[U]=re)}return D}function qi(e,a,D){for(var A=[],U=0;U<e.length;++U){var V=e[U];if(V.ranges){A.push(D?Da.prototype.deepCopy.call(V):V);continue}var re=V.changes,se=[];A.push({changes:se});for(var ce=0;ce<re.length;++ce){var ve=re[ce],Ne=void 0;if(se.push({from:ve.from,to:ve.to,text:ve.text}),a)for(var He in ve)(Ne=He.match(/^spans_(\d+)$/))&&(ne(a,Number(Ne[1]))>-1&&(q(se)[He]=ve[He],delete ve[He]))}}return A}function ns(e,a,D,A){if(A){var U=e.anchor;if(D){var V=dr(a,U)<0;V!=dr(D,U)<0?(U=a,a=D):V!=dr(a,D)<0&&(a=D)}return new vn(U,a)}else return new vn(D||a,a)}function Uo(e,a,D,A,U){U==null&&(U=e.cm&&(e.cm.display.shift||e.extend)),Sa(e,new Da([ns(e.sel.primary(),a,D,U)],0),A)}function Ts(e,a,D){for(var A=[],U=e.cm&&(e.cm.display.shift||e.extend),V=0;V<e.sel.ranges.length;V++)A[V]=ns(e.sel.ranges[V],a[V],null,U);var re=Ja(e.cm,A,e.sel.primIndex);Sa(e,re,D)}function as(e,a,D,A){var U=e.sel.ranges.slice(0);U[a]=D,Sa(e,Ja(e.cm,U,e.sel.primIndex),A)}function ws(e,a,D,A){Sa(e,di(a,D),A)}function _l(e,a,D){var A={ranges:a.ranges,update:function(U){this.ranges=[];for(var V=0;V<U.length;V++)this.ranges[V]=new vn(xr(e,U[V].anchor),xr(e,U[V].head))},origin:D&&D.origin};return We(e,"beforeSelectionChange",e,A),e.cm&&We(e.cm,"beforeSelectionChange",e.cm,A),A.ranges!=a.ranges?Ja(e.cm,A.ranges,A.ranges.length-1):a}function Ss(e,a,D){var A=e.history.done,U=q(A);U&&U.ranges?(A[A.length-1]=a,Bo(e,a,D)):Sa(e,a,D)}function Sa(e,a,D){Bo(e,a,D),gl(e,e.sel,e.cm?e.cm.curOp.id:NaN,D)}function Bo(e,a,D){(Ce(e,"beforeSelectionChange")||e.cm&&Ce(e.cm,"beforeSelectionChange"))&&(a=_l(e,a,D));var A=D&&D.bias||(dr(a.primary().head,e.sel.primary().head)<0?-1:1);Os(e,As(e,a,A,!0)),!(D&&D.scroll===!1)&&e.cm&&vi(e.cm)}function Os(e,a){if(a.equals(e.sel))return;e.sel=a,e.cm&&(e.cm.curOp.updateInput=1,e.cm.curOp.selectionChanged=!0,Me(e.cm)),Ht(e,"cursorActivity",e)}function Cs(e){Os(e,As(e,e.sel,null,!1))}function As(e,a,D,A){for(var U,V=0;V<a.ranges.length;V++){var re=a.ranges[V],se=a.ranges.length==e.sel.ranges.length&&e.sel.ranges[V],ce=Ho(e,re.anchor,se&&se.anchor,D,A),ve=Ho(e,re.head,se&&se.head,D,A);(U||ce!=re.anchor||ve!=re.head)&&(U||(U=a.ranges.slice(0,V)),U[V]=new vn(ce,ve))}return U?Ja(e.cm,U,a.primIndex):a}function eo(e,a,D,A,U){var V=er(e,a.line);if(V.markedSpans)for(var re=0;re<V.markedSpans.length;++re){var se=V.markedSpans[re],ce=se.marker,ve="selectLeft"in ce?!ce.selectLeft:ce.inclusiveLeft,Ne="selectRight"in ce?!ce.selectRight:ce.inclusiveRight;if((se.from==null||(ve?se.from<=a.ch:se.from<a.ch))&&(se.to==null||(Ne?se.to>=a.ch:se.to>a.ch))){if(U&&(We(ce,"beforeCursorEnter"),ce.explicitlyCleared))if(V.markedSpans){--re;continue}else break;if(!ce.atomic)continue;if(D){var He=ce.find(A<0?1:-1),tt=void 0;if((A<0?Ne:ve)&&(He=Rs(e,He,-A,He&&He.line==a.line?V:null)),He&&He.line==a.line&&(tt=dr(He,D))&&(A<0?tt<0:tt>0))return eo(e,He,a,A,U)}var $e=ce.find(A<0?-1:1);return(A<0?ve:Ne)&&($e=Rs(e,$e,A,$e.line==a.line?V:null)),$e?eo(e,$e,a,A,U):null}}return a}function Ho(e,a,D,A,U){var V=A||1,re=eo(e,a,D,V,U)||!U&&eo(e,a,D,V,!0)||eo(e,a,D,-V,U)||!U&&eo(e,a,D,-V,!0);return re||(e.cantEdit=!0,It(e.first,0))}function Rs(e,a,D,A){return D<0&&a.ch==0?a.line>e.first?xr(e,It(a.line-1)):null:D>0&&a.ch==(A||er(e,a.line)).text.length?a.line<e.first+e.size-1?It(a.line+1,0):null:new It(a.line,a.ch+D)}function Is(e){e.setSelection(It(e.firstLine(),0),It(e.lastLine()),xe)}function Ds(e,a,D){var A={canceled:!1,from:a.from,to:a.to,text:a.text,origin:a.origin,cancel:function(){return A.canceled=!0}};return D&&(A.update=function(U,V,re,se){U&&(A.from=xr(e,U)),V&&(A.to=xr(e,V)),re&&(A.text=re),se!==void 0&&(A.origin=se)}),We(e,"beforeChange",e,A),e.cm&&We(e.cm,"beforeChange",e.cm,A),A.canceled?(e.cm&&(e.cm.curOp.updateInput=2),null):{from:A.from,to:A.to,text:A.text,origin:A.origin}}function to(e,a,D){if(e.cm){if(!e.cm.curOp)return Yn(e.cm,to)(e,a,D);if(e.cm.state.suppressEdits)return}if((Ce(e,"beforeChange")||e.cm&&Ce(e.cm,"beforeChange"))&&(a=Ds(e,a,!0),!a))return;var A=Xa&&!D&&ei(e,a.from,a.to);if(A)for(var U=A.length-1;U>=0;--U)Ls(e,{from:A[U].from,to:A[U].to,text:U?[""]:a.text,origin:a.origin});else Ls(e,a)}function Ls(e,a){if(a.text.length==1&&a.text[0]==""&&dr(a.from,a.to)==0)return;var D=Zi(e,a);_s(e,a,D,e.cm?e.cm.curOp.id:NaN),go(e,a,D,qa(e,a));var A=[];Ni(e,function(U,V){!V&&ne(A,U.history)==-1&&(Ns(U.history,a),A.push(U.history)),go(U,a,null,qa(U,a))})}function Wo(e,a,D){var A=e.cm&&e.cm.state.suppressEdits;if(A&&!D)return;for(var U=e.history,V,re=e.sel,se=a=="undo"?U.done:U.undone,ce=a=="undo"?U.undone:U.done,ve=0;ve<se.length&&!(V=se[ve],D?V.ranges&&!V.equals(e.sel):!V.ranges);ve++);if(ve==se.length)return;for(U.lastOrigin=U.lastSelOrigin=null;;)if(V=se.pop(),V.ranges){if(Fo(V,ce),D&&!V.equals(e.sel)){Sa(e,V,{clearRedo:!1});return}re=V}else if(A){se.push(V);return}else break;var Ne=[];Fo(re,ce),ce.push({changes:Ne,generation:U.generation}),U.generation=V.generation||++U.maxGeneration;for(var He=Ce(e,"beforeChange")||e.cm&&Ce(e.cm,"beforeChange"),tt=function(Rt){var Ft=V.changes[Rt];if(Ft.origin=a,He&&!Ds(e,Ft,!1))return se.length=0,{};Ne.push(rs(e,Ft));var Yt=Rt?Zi(e,Ft):q(se);go(e,Ft,Yt,xs(e,Ft)),!Rt&&e.cm&&e.cm.scrollIntoView({from:Ft.from,to:fi(Ft)});var sr=[];Ni(e,function($t,pr){!pr&&ne(sr,$t.history)==-1&&(Ns($t.history,Ft),sr.push($t.history)),go($t,Ft,null,xs($t,Ft))})},$e=V.changes.length-1;$e>=0;--$e){var vt=tt($e);if(vt)return vt.v}}function Ps(e,a){if(a==0)return;if(e.first+=a,e.sel=new Da(ue(e.sel.ranges,function(U){return new vn(It(U.anchor.line+a,U.anchor.ch),It(U.head.line+a,U.head.ch))}),e.sel.primIndex),e.cm){Tn(e.cm,e.first,e.first-a,a);for(var D=e.cm.display,A=D.viewFrom;A<D.viewTo;A++)In(e.cm,A,"gutter")}}function go(e,a,D,A){if(e.cm&&!e.cm.curOp)return Yn(e.cm,go)(e,a,D,A);if(a.to.line<e.first){Ps(e,a.text.length-1-(a.to.line-a.from.line));return}if(a.from.line>e.lastLine())return;if(a.from.line<e.first){var U=a.text.length-1-(e.first-a.from.line);Ps(e,U),a={from:It(e.first,0),to:It(a.to.line+U,a.to.ch),text:[q(a.text)],origin:a.origin}}var V=e.lastLine();a.to.line>V&&(a={from:a.from,to:It(V,er(e,V).text.length),text:[a.text[0]],origin:a.origin}),a.removed=Xn(e,a.from,a.to),D||(D=Zi(e,a)),e.cm?El(e.cm,a,A):ts(e,a,A),Bo(e,D,xe),e.cantEdit&&Ho(e,It(e.firstLine(),0))&&(e.cantEdit=!1)}function El(e,a,D){var A=e.doc,U=e.display,V=a.from,re=a.to,se=!1,ce=V.line;e.options.lineWrapping||(ce=Qr(gt(er(A,V.line))),A.iter(ce,re.line+1,function($e){if($e==U.maxLine)return se=!0,!0})),A.sel.contains(a.from,a.to)>-1&&Me(e),ts(A,a,D,Na(e)),e.options.lineWrapping||(A.iter(ce,V.line+a.text.length,function($e){var vt=Ze($e);vt>U.maxLineLength&&(U.maxLine=$e,U.maxLineLength=vt,U.maxLineChanged=!0,se=!1)}),se&&(e.curOp.updateMaxLine=!0)),Di(A,V.line),Wi(e,400);var ve=a.text.length-(re.line-V.line)-1;a.full?Tn(e):V.line==re.line&&a.text.length==1&&!vs(e.doc,a)?In(e,V.line,"text"):Tn(e,V.line,re.line+1,ve);var Ne=Ce(e,"changes"),He=Ce(e,"change");if(He||Ne){var tt={from:V,to:re,text:a.text,removed:a.removed,origin:a.origin};He&&Ht(e,"change",e,tt),Ne&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(tt)}e.display.selForContextMenu=null}function ro(e,a,D,A,U){var V;A||(A=D),dr(A,D)<0&&(V=[A,D],D=V[0],A=V[1]),typeof a=="string"&&(a=e.splitLines(a)),to(e,{from:D,to:A,text:a,origin:U})}function ks(e,a,D,A){D<e.line?e.line+=A:a<e.line&&(e.line=a,e.ch=0)}function Ms(e,a,D,A){for(var U=0;U<e.length;++U){var V=e[U],re=!0;if(V.ranges){V.copied||(V=e[U]=V.deepCopy(),V.copied=!0);for(var se=0;se<V.ranges.length;se++)ks(V.ranges[se].anchor,a,D,A),ks(V.ranges[se].head,a,D,A);continue}for(var ce=0;ce<V.changes.length;++ce){var ve=V.changes[ce];if(D<ve.from.line)ve.from=It(ve.from.line+A,ve.from.ch),ve.to=It(ve.to.line+A,ve.to.ch);else if(a<=ve.to.line){re=!1;break}}re||(e.splice(0,U+1),U=0)}}function Ns(e,a){var D=a.from.line,A=a.to.line,U=a.text.length-(A-D)-1;Ms(e.done,D,A,U),Ms(e.undone,D,A,U)}function bo(e,a,D,A){var U=a,V=a;return typeof a=="number"?V=er(e,kn(e,a)):U=Qr(a),U==null?null:(A(V,U)&&e.cm&&In(e.cm,U,D),V)}function yo(e){this.lines=e,this.parent=null;for(var a=0,D=0;D<e.length;++D)e[D].parent=this,a+=e[D].height;this.height=a}yo.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,a){for(var D=e,A=e+a;D<A;++D){var U=this.lines[D];this.height-=U.height,ft(U),Ht(U,"delete")}this.lines.splice(e,a)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,a,D){this.height+=D,this.lines=this.lines.slice(0,e).concat(a).concat(this.lines.slice(e));for(var A=0;A<a.length;++A)a[A].parent=this},iterN:function(e,a,D){for(var A=e+a;e<A;++e)if(D(this.lines[e]))return!0}};function _o(e){this.children=e;for(var a=0,D=0,A=0;A<e.length;++A){var U=e[A];a+=U.chunkSize(),D+=U.height,U.parent=this}this.size=a,this.height=D,this.parent=null}_o.prototype={chunkSize:function(){return this.size},removeInner:function(e,a){this.size-=a;for(var D=0;D<this.children.length;++D){var A=this.children[D],U=A.chunkSize();if(e<U){var V=Math.min(a,U-e),re=A.height;if(A.removeInner(e,V),this.height-=re-A.height,U==V&&(this.children.splice(D--,1),A.parent=null),(a-=V)==0)break;e=0}else e-=U}if(this.size-a<25&&(this.children.length>1||!(this.children[0]instanceof yo))){var se=[];this.collapse(se),this.children=[new yo(se)],this.children[0].parent=this}},collapse:function(e){for(var a=0;a<this.children.length;++a)this.children[a].collapse(e)},insertInner:function(e,a,D){this.size+=a.length,this.height+=D;for(var A=0;A<this.children.length;++A){var U=this.children[A],V=U.chunkSize();if(e<=V){if(U.insertInner(e,a,D),U.lines&&U.lines.length>50){for(var re=U.lines.length%25+25,se=re;se<U.lines.length;){var ce=new yo(U.lines.slice(se,se+=25));U.height-=ce.height,this.children.splice(++A,0,ce),ce.parent=this}U.lines=U.lines.slice(0,re),this.maybeSpill()}break}e-=V}},maybeSpill:function(){if(this.children.length<=10)return;var e=this;do{var a=e.children.splice(e.children.length-5,5),D=new _o(a);if(e.parent){e.size-=D.size,e.height-=D.height;var U=ne(e.parent.children,e);e.parent.children.splice(U+1,0,D)}else{var A=new _o(e.children);A.parent=e,e.children=[A,D],e=A}D.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()},iterN:function(e,a,D){for(var A=0;A<this.children.length;++A){var U=this.children[A],V=U.chunkSize();if(e<V){var re=Math.min(a,V-e);if(U.iterN(e,re,D))return!0;if((a-=re)==0)break;e=0}else e-=V}}};var Eo=function(e,a,D){if(D)for(var A in D)D.hasOwnProperty(A)&&(this[A]=D[A]);this.doc=e,this.node=a};Eo.prototype.clear=function(){var e=this.doc.cm,a=this.line.widgets,D=this.line,A=Qr(D);if(A==null||!a)return;for(var U=0;U<a.length;++U)a[U]==this&&a.splice(U--,1);a.length||(D.widgets=null);var V=Lr(this);Pn(D,Math.max(0,D.height-V)),e&&(Ra(e,function(){js(e,D,-V),In(e,A,"widget")}),Ht(e,"lineWidgetCleared",e,this,A))},Eo.prototype.changed=function(){var e=this,a=this.height,D=this.doc.cm,A=this.line;this.height=null;var U=Lr(this)-a;if(!U)return;jt(this.doc,A)||Pn(A,A.height+U),D&&Ra(D,function(){D.curOp.forceUpdate=!0,js(D,A,U),Ht(D,"lineWidgetChanged",D,e,Qr(A))})},Re(Eo);function js(e,a,D){Zt(a)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&wi(e,D)}function xl(e,a,D,A){var U=new Eo(e,D,A),V=e.cm;return V&&U.noHScroll&&(V.display.alignWidgets=!0),bo(e,a,"widget",function(re){var se=re.widgets||(re.widgets=[]);if(U.insertAt==null?se.push(U):se.splice(Math.min(se.length-1,Math.max(0,U.insertAt)),0,U),U.line=re,V&&!jt(e,re)){var ce=Zt(re)<e.scrollTop;Pn(re,re.height+Lr(U)),ce&&wi(V,U.height),V.curOp.forceUpdate=!0}return!0}),V&&Ht(V,"lineWidgetAdded",V,U,typeof a=="number"?a:Qr(a)),U}var Fs=0,ji=function(e,a){this.lines=[],this.type=a,this.doc=e,this.id=++Fs};ji.prototype.clear=function(){if(this.explicitlyCleared)return;var e=this.doc.cm,a=e&&!e.curOp;if(a&&Sn(e),Ce(this,"clear")){var D=this.find();D&&Ht(this,"clear",D.from,D.to)}for(var A=null,U=null,V=0;V<this.lines.length;++V){var re=this.lines[V],se=aa(re.markedSpans,this);e&&!this.collapsed?In(e,Qr(re),"text"):e&&(se.to!=null&&(U=Qr(re)),se.from!=null&&(A=Qr(re))),re.markedSpans=oi(re.markedSpans,se),se.from==null&&this.collapsed&&!jt(this.doc,re)&&e&&Pn(re,Fn(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var ce=0;ce<this.lines.length;++ce){var ve=gt(this.lines[ce]),Ne=Ze(ve);Ne>e.display.maxLineLength&&(e.display.maxLine=ve,e.display.maxLineLength=Ne,e.display.maxLineChanged=!0)}A!=null&&e&&this.collapsed&&Tn(e,A,U+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&Cs(e.doc)),e&&Ht(e,"markerCleared",e,this,A,U),a&&Oi(e),this.parent&&this.parent.clear()},ji.prototype.find=function(e,a){e==null&&this.type=="bookmark"&&(e=1);for(var D,A,U=0;U<this.lines.length;++U){var V=this.lines[U],re=aa(V.markedSpans,this);if(re.from!=null&&(D=It(a?V:Qr(V),re.from),e==-1))return D;if(re.to!=null&&(A=It(a?V:Qr(V),re.to),e==1))return A}return D&&{from:D,to:A}},ji.prototype.changed=function(){var e=this,a=this.find(-1,!0),D=this,A=this.doc.cm;if(!a||!A)return;Ra(A,function(){var U=a.line,V=Qr(a.line),re=Be(A,V);if(re&&(Nr(re),A.curOp.selectionChanged=A.curOp.forceUpdate=!0),A.curOp.updateMaxLine=!0,!jt(D.doc,U)&&D.height!=null){var se=D.height;D.height=null;var ce=Lr(D)-se;ce&&Pn(U,U.height+ce)}Ht(A,"markerChanged",A,e)})},ji.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var a=this.doc.cm.curOp;(!a.maybeHiddenMarkers||ne(a.maybeHiddenMarkers,this)==-1)&&(a.maybeUnhiddenMarkers||(a.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},ji.prototype.detachLine=function(e){if(this.lines.splice(ne(this.lines,e),1),!this.lines.length&&this.doc.cm){var a=this.doc.cm.curOp;(a.maybeHiddenMarkers||(a.maybeHiddenMarkers=[])).push(this)}},Re(ji);function no(e,a,D,A,U){if(A&&A.shared)return Tl(e,a,D,A,U);if(e.cm&&!e.cm.curOp)return Yn(e.cm,no)(e,a,D,A,U);var V=new ji(e,U),re=dr(a,D);if(A&&k(A,V,!1),re>0||re==0&&V.clearWhenEmpty!==!1)return V;if(V.replacedWith&&(V.collapsed=!0,V.widgetNode=L("span",[V.replacedWith],"CodeMirror-widget"),A.handleMouseEvents||V.widgetNode.setAttribute("cm-ignore-events","true"),A.insertLeft&&(V.widgetNode.insertLeft=!0)),V.collapsed){if(st(e,a.line,a,D,V)||a.line!=D.line&&st(e,D.line,a,D,V))throw new Error("Inserting collapsed marker partially overlapping an existing one");_i()}V.addToHistory&&_s(e,{from:a,to:D,origin:"markText"},e.sel,NaN);var se=a.line,ce=e.cm,ve;if(e.iter(se,D.line+1,function(He){ce&&V.collapsed&&!ce.options.lineWrapping&&gt(He)==ce.display.maxLine&&(ve=!0),V.collapsed&&se!=a.line&&Pn(He,0),pi(He,new Ma(V,se==a.line?a.ch:null,se==D.line?D.ch:null)),++se}),V.collapsed&&e.iter(a.line,D.line+1,function(He){jt(e,He)&&Pn(He,0)}),V.clearOnEnter&&Se(V,"beforeCursorEnter",function(){return V.clear()}),V.readOnly&&(za(),(e.history.done.length||e.history.undone.length)&&e.clearHistory()),V.collapsed&&(V.id=++Fs,V.atomic=!0),ce){if(ve&&(ce.curOp.updateMaxLine=!0),V.collapsed)Tn(ce,a.line,D.line+1);else if(V.className||V.startStyle||V.endStyle||V.css||V.attributes||V.title)for(var Ne=a.line;Ne<=D.line;Ne++)In(ce,Ne,"text");V.atomic&&Cs(ce.doc),Ht(ce,"markerAdded",ce,V)}return V}var xo=function(e,a){this.markers=e,this.primary=a;for(var D=0;D<e.length;++D)e[D].parent=this};xo.prototype.clear=function(){if(this.explicitlyCleared)return;this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();Ht(this,"clear")},xo.prototype.find=function(e,a){return this.primary.find(e,a)},Re(xo);function Tl(e,a,D,A,U){A=k(A),A.shared=!1;var V=[no(e,a,D,A,U)],re=V[0],se=A.widgetNode;return Ni(e,function(ce){se&&(A.widgetNode=se.cloneNode(!0)),V.push(no(ce,xr(ce,a),xr(ce,D),A,U));for(var ve=0;ve<ce.linked.length;++ve)if(ce.linked[ve].isParent)return;re=q(V)}),new xo(V,re)}function Us(e){return e.findMarks(It(e.first,0),e.clipPos(It(e.lastLine())),function(a){return a.parent})}function wl(e,a){for(var D=0;D<a.length;D++){var A=a[D],U=A.find(),V=e.clipPos(U.from),re=e.clipPos(U.to);if(dr(V,re)){var se=no(e,V,re,A.primary,A.primary.type);A.markers.push(se),se.parent=A}}}function Sl(e){for(var a=function(A){var U=e[A],V=[U.primary.doc];Ni(U.primary.doc,function(ce){return V.push(ce)});for(var re=0;re<U.markers.length;re++){var se=U.markers[re];ne(V,se.doc)==-1&&(se.parent=null,U.markers.splice(re--,1))}},D=0;D<e.length;D++)a(D)}var Ol=0,Fa=function(e,a,D,A,U){if(!(this instanceof Fa))return new Fa(e,a,D,A,U);D==null&&(D=0),_o.call(this,[new yo([new Or("",null)])]),this.first=D,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=D;var V=It(D,0);this.sel=di(V),this.history=new jo(null),this.id=++Ol,this.modeOption=a,this.lineSep=A,this.direction=U=="rtl"?"rtl":"ltr",this.extend=!1,typeof e=="string"&&(e=this.splitLines(e)),ts(this,{from:V,to:V,text:e}),Sa(this,di(V),xe)};Fa.prototype=Ee(_o.prototype,{constructor:Fa,iter:function(e,a,D){D?this.iterN(e-this.first,a-e,D):this.iterN(this.first,this.first+this.size,e)},insert:function(e,a){for(var D=0,A=0;A<a.length;++A)D+=a[A].height;this.insertInner(e-this.first,a,D)},remove:function(e,a){this.removeInner(e-this.first,a)},getValue:function(e){var a=Ea(this,this.first,this.first+this.size);return e===!1?a:a.join(e||this.lineSeparator())},setValue:$n(function(e){var a=It(this.first,0),D=this.first+this.size-1;to(this,{from:a,to:It(D,er(this,D).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&ai(this.cm,0,0),Sa(this,di(a),xe)}),replaceRange:function(e,a,D,A){a=xr(this,a),D=D?xr(this,D):a,ro(this,e,a,D,A)},getRange:function(e,a,D){var A=Xn(this,xr(this,e),xr(this,a));return D===!1?A:A.join(D||this.lineSeparator())},getLine:function(e){var a=this.getLineHandle(e);return a&&a.text},getLineHandle:function(e){if(la(this,e))return er(this,e)},getLineNumber:function(e){return Qr(e)},getLineHandleVisualStart:function(e){return typeof e=="number"&&(e=er(this,e)),gt(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return xr(this,e)},getCursor:function(e){var a=this.sel.primary(),D;return e==null||e=="head"?D=a.head:e=="anchor"?D=a.anchor:e=="end"||e=="to"||e===!1?D=a.to():D=a.from(),D},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:$n(function(e,a,D){ws(this,xr(this,typeof e=="number"?It(e,a||0):e),null,D)}),setSelection:$n(function(e,a,D){ws(this,xr(this,e),xr(this,a||e),D)}),extendSelection:$n(function(e,a,D){Uo(this,xr(this,e),a&&xr(this,a),D)}),extendSelections:$n(function(e,a){Ts(this,Ct(this,e),a)}),extendSelectionsBy:$n(function(e,a){var D=ue(this.sel.ranges,e);Ts(this,Ct(this,D),a)}),setSelections:$n(function(e,a,D){if(!e.length)return;for(var A=[],U=0;U<e.length;U++)A[U]=new vn(xr(this,e[U].anchor),xr(this,e[U].head));a==null&&(a=Math.min(e.length-1,this.sel.primIndex)),Sa(this,Ja(this.cm,A,a),D)}),addSelection:$n(function(e,a,D){var A=this.sel.ranges.slice(0);A.push(new vn(xr(this,e),xr(this,a||e))),Sa(this,Ja(this.cm,A,A.length-1),D)}),getSelection:function(e){for(var a=this.sel.ranges,D,A=0;A<a.length;A++){var U=Xn(this,a[A].from(),a[A].to());D=D?D.concat(U):U}return e===!1?D:D.join(e||this.lineSeparator())},getSelections:function(e){for(var a=[],D=this.sel.ranges,A=0;A<D.length;A++){var U=Xn(this,D[A].from(),D[A].to());e!==!1&&(U=U.join(e||this.lineSeparator())),a[A]=U}return a},replaceSelection:function(e,a,D){for(var A=[],U=0;U<this.sel.ranges.length;U++)A[U]=e;this.replaceSelections(A,a,D||"+input")},replaceSelections:$n(function(e,a,D){for(var A=[],U=this.sel,V=0;V<U.ranges.length;V++){var re=U.ranges[V];A[V]={from:re.from(),to:re.to(),text:this.splitLines(e[V]),origin:D}}for(var se=a&&a!="end"&&No(this,A,a),ce=A.length-1;ce>=0;ce--)to(this,A[ce]);se?Ss(this,se):this.cm&&vi(this.cm)}),undo:$n(function(){Wo(this,"undo")}),redo:$n(function(){Wo(this,"redo")}),undoSelection:$n(function(){Wo(this,"undo",!0)}),redoSelection:$n(function(){Wo(this,"redo",!0)}),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,a=0,D=0,A=0;A<e.done.length;A++)e.done[A].ranges||++a;for(var U=0;U<e.undone.length;U++)e.undone[U].ranges||++D;return{undo:a,redo:D}},clearHistory:function(){var e=this;this.history=new jo(this.history.maxGeneration),Ni(this,function(a){return a.history=e.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:qi(this.history.done),undone:qi(this.history.undone)}},setHistory:function(e){var a=this.history=new jo(this.history.maxGeneration);a.done=qi(e.done.slice(0),null,!0),a.undone=qi(e.undone.slice(0),null,!0)},setGutterMarker:$n(function(e,a,D){return bo(this,e,"gutter",function(A){var U=A.gutterMarkers||(A.gutterMarkers={});return U[a]=D,!D&&$(U)&&(A.gutterMarkers=null),!0})}),clearGutter:$n(function(e){var a=this;this.iter(function(D){D.gutterMarkers&&D.gutterMarkers[e]&&bo(a,D,"gutter",function(){return D.gutterMarkers[e]=null,$(D.gutterMarkers)&&(D.gutterMarkers=null),!0})})}),lineInfo:function(e){var a;if(typeof e=="number"){if(!la(this,e))return null;if(a=e,e=er(this,e),!e)return null}else if(a=Qr(e),a==null)return null;return{line:a,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:$n(function(e,a,D){return bo(this,e,a=="gutter"?"gutter":"class",function(A){var U=a=="text"?"textClass":a=="background"?"bgClass":a=="gutter"?"gutterClass":"wrapClass";if(!A[U])A[U]=D;else{if(O(D).test(A[U]))return!1;A[U]+=" "+D}return!0})}),removeLineClass:$n(function(e,a,D){return bo(this,e,a=="gutter"?"gutter":"class",function(A){var U=a=="text"?"textClass":a=="background"?"bgClass":a=="gutter"?"gutterClass":"wrapClass",V=A[U];if(V)if(D==null)A[U]=null;else{var re=V.match(O(D));if(!re)return!1;var se=re.index+re[0].length;A[U]=V.slice(0,re.index)+(!re.index||se==V.length?"":" ")+V.slice(se)||null}else return!1;return!0})}),addLineWidget:$n(function(e,a,D){return xl(this,e,a,D)}),removeLineWidget:function(e){e.clear()},markText:function(e,a,D){return no(this,xr(this,e),xr(this,a),D,D&&D.type||"range")},setBookmark:function(e,a){var D={replacedWith:a&&(a.nodeType==null?a.widget:a),insertLeft:a&&a.insertLeft,clearWhenEmpty:!1,shared:a&&a.shared,handleMouseEvents:a&&a.handleMouseEvents};return e=xr(this,e),no(this,e,e,D,"bookmark")},findMarksAt:function(e){e=xr(this,e);var a=[],D=er(this,e.line).markedSpans;if(D)for(var A=0;A<D.length;++A){var U=D[A];(U.from==null||U.from<=e.ch)&&(U.to==null||U.to>=e.ch)&&a.push(U.marker.parent||U.marker)}return a},findMarks:function(e,a,D){e=xr(this,e),a=xr(this,a);var A=[],U=e.line;return this.iter(e.line,a.line+1,function(V){var re=V.markedSpans;if(re)for(var se=0;se<re.length;se++){var ce=re[se];!(ce.to!=null&&U==e.line&&e.ch>=ce.to||ce.from==null&&U!=e.line||ce.from!=null&&U==a.line&&ce.from>=a.ch)&&(!D||D(ce.marker))&&A.push(ce.marker.parent||ce.marker)}++U}),A},getAllMarks:function(){var e=[];return this.iter(function(a){var D=a.markedSpans;if(D)for(var A=0;A<D.length;++A)D[A].from!=null&&e.push(D[A].marker)}),e},posFromIndex:function(e){var a,D=this.first,A=this.lineSeparator().length;return this.iter(function(U){var V=U.text.length+A;if(V>e)return a=e,!0;e-=V,++D}),xr(this,It(D,a))},indexFromPos:function(e){e=xr(this,e);var a=e.ch;if(e.line<this.first||e.ch<0)return 0;var D=this.lineSeparator().length;return this.iter(this.first,e.line,function(A){a+=A.text.length+D}),a},copy:function(e){var a=new Fa(Ea(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return a.scrollTop=this.scrollTop,a.scrollLeft=this.scrollLeft,a.sel=this.sel,a.extend=!1,e&&(a.history.undoDepth=this.history.undoDepth,a.setHistory(this.getHistory())),a},linkedDoc:function(e){e||(e={});var a=this.first,D=this.first+this.size;e.from!=null&&e.from>a&&(a=e.from),e.to!=null&&e.to<D&&(D=e.to);var A=new Fa(Ea(this,a,D),e.mode||this.modeOption,a,this.lineSep,this.direction);return e.sharedHist&&(A.history=this.history),(this.linked||(this.linked=[])).push({doc:A,sharedHist:e.sharedHist}),A.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],wl(A,Us(this)),A},unlinkDoc:function(e){if(e instanceof Un&&(e=e.doc),this.linked)for(var a=0;a<this.linked.length;++a){var D=this.linked[a];if(D.doc!=e)continue;this.linked.splice(a,1),e.unlinkDoc(this),Sl(Us(this));break}if(e.history==this.history){var A=[e.id];Ni(e,function(U){return A.push(U.id)},!0),e.history=new jo(null),e.history.done=qi(this.history.done,A),e.history.undone=qi(this.history.undone,A)}},iterLinkedDocs:function(e){Ni(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):rr(e)},lineSeparator:function(){return this.lineSep||`
`},setDirection:$n(function(e){if(e!="rtl"&&(e="ltr"),e==this.direction)return;this.direction=e,this.iter(function(a){return a.order=null}),this.cm&&pl(this.cm)})}),Fa.prototype.eachLine=Fa.prototype.iter;var Bs=0;function Cl(e){var a=this;if(Hs(a),et(a,e)||rn(a.display,e))return;pe(e),w&&(Bs=+new Date);var D=zn(a,e,!0),A=e.dataTransfer.files;if(!D||a.isReadOnly())return;if(A&&A.length&&window.FileReader&&window.File)for(var U=A.length,V=Array(U),re=0,se=function(){++re==U&&Yn(a,function(){D=xr(a.doc,D);var $e={from:D,to:D,text:a.doc.splitLines(V.filter(function(vt){return vt!=null}).join(a.doc.lineSeparator())),origin:"paste"};to(a.doc,$e),Ss(a.doc,di(xr(a.doc,D),xr(a.doc,fi($e))))})()},ce=function($e,vt){if(a.options.allowDropFileTypes&&ne(a.options.allowDropFileTypes,$e.type)==-1){se();return}var Rt=new FileReader;Rt.onerror=function(){return se()},Rt.onload=function(){var Ft=Rt.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(Ft)){se();return}V[vt]=Ft,se()},Rt.readAsText($e)},ve=0;ve<A.length;ve++)ce(A[ve],ve);else{if(a.state.draggingText&&a.doc.sel.contains(D)>-1){a.state.draggingText(e),setTimeout(function(){return a.display.input.focus()},20);return}try{var Ne=e.dataTransfer.getData("Text");if(Ne){var He;if(a.state.draggingText&&!a.state.draggingText.copy&&(He=a.listSelections()),Bo(a.doc,di(D,D)),He)for(var tt=0;tt<He.length;++tt)ro(a.doc,"",He[tt].anchor,He[tt].head,"drag");a.replaceSelection(Ne,"around","paste"),a.display.input.focus()}}catch($e){}}}function Al(e,a){if(w&&(!e.state.draggingText||+new Date-Bs<100)){Ie(a);return}if(et(e,a)||rn(e.display,a))return;if(a.dataTransfer.setData("Text",e.getSelection()),a.dataTransfer.effectAllowed="copyMove",a.dataTransfer.setDragImage&&!r){var D=T("img",null,null,"position: fixed; left: 0; top: 0;");D.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",c&&(D.width=D.height=1,e.display.wrapper.appendChild(D),D._top=D.offsetTop),a.dataTransfer.setDragImage(D,0,0),c&&D.parentNode.removeChild(D)}}function Rl(e,a){var D=zn(e,a);if(!D)return;var A=document.createDocumentFragment();Aa(e,D,A),e.display.dragCursor||(e.display.dragCursor=T("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),E(e.display.dragCursor,A)}function Hs(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function Ws(e){if(!document.getElementsByClassName)return;for(var a=document.getElementsByClassName("CodeMirror"),D=[],A=0;A<a.length;A++){var U=a[A].CodeMirror;U&&D.push(U)}D.length&&D[0].operation(function(){for(var V=0;V<D.length;V++)e(D[V])})}var Ks=!1;function Il(){if(Ks)return;Dl(),Ks=!0}function Dl(){var e;Se(window,"resize",function(){e==null&&(e=setTimeout(function(){e=null,Ws(Ll)},100))}),Se(window,"blur",function(){return Ws(ri)})}function Ll(e){var a=e.display;a.cachedCharWidth=a.cachedTextHeight=a.cachedPaddingH=null,a.scrollbarsClipped=!1,e.setSize()}for(var Fi={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},To=0;To<10;To++)Fi[To+48]=Fi[To+96]=String(To);for(var Ko=65;Ko<=90;Ko++)Fi[Ko]=String.fromCharCode(Ko);for(var wo=1;wo<=12;wo++)Fi[wo+111]=Fi[wo+63235]="F"+wo;var Ri={};Ri.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Ri.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Ri.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Ri.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Ri.default=l?Ri.macDefault:Ri.pcDefault;function Pl(e){var a=e.split(/-(?!$)/);e=a[a.length-1];for(var D,A,U,V,re=0;re<a.length-1;re++){var se=a[re];if(/^(cmd|meta|m)$/i.test(se))V=!0;else if(/^a(lt)?$/i.test(se))D=!0;else if(/^(c|ctrl|control)$/i.test(se))A=!0;else if(/^s(hift)?$/i.test(se))U=!0;else throw new Error("Unrecognized modifier name: "+se)}return D&&(e="Alt-"+e),A&&(e="Ctrl-"+e),V&&(e="Cmd-"+e),U&&(e="Shift-"+e),e}function kl(e){var a={};for(var D in e)if(e.hasOwnProperty(D)){var A=e[D];if(/^(name|fallthrough|(de|at)tach)$/.test(D))continue;if(A=="..."){delete e[D];continue}for(var U=ue(D.split(" "),Pl),V=0;V<U.length;V++){var re=void 0,se=void 0;V==U.length-1?(se=U.join(" "),re=A):(se=U.slice(0,V+1).join(" "),re="...");var ce=a[se];if(!ce)a[se]=re;else if(ce!=re)throw new Error("Inconsistent bindings for "+se)}delete e[D]}for(var ve in a)e[ve]=a[ve];return e}function ao(e,a,D,A){a=zo(a);var U=a.call?a.call(e,A):a[e];if(U===!1)return"nothing";if(U==="...")return"multi";if(U!=null&&D(U))return"handled";if(a.fallthrough){if(Object.prototype.toString.call(a.fallthrough)!="[object Array]")return ao(e,a.fallthrough,D,A);for(var V=0;V<a.fallthrough.length;V++){var re=ao(e,a.fallthrough[V],D,A);if(re)return re}}}function zs(e){var a=typeof e=="string"?e:Fi[e.keyCode];return a=="Ctrl"||a=="Alt"||a=="Shift"||a=="Mod"}function Gs(e,a,D){var A=e;return a.altKey&&A!="Alt"&&(e="Alt-"+e),(h?a.metaKey:a.ctrlKey)&&A!="Ctrl"&&(e="Ctrl-"+e),(h?a.ctrlKey:a.metaKey)&&A!="Mod"&&(e="Cmd-"+e),!D&&a.shiftKey&&A!="Shift"&&(e="Shift-"+e),e}function Xs(e,a){if(c&&e.keyCode==34&&e.char)return!1;var D=Fi[e.keyCode];return D==null||e.altGraphKey?!1:(e.keyCode==3&&e.code&&(D=e.code),Gs(D,e,a))}function zo(e){return typeof e=="string"?Ri[e]:e}function io(e,a){for(var D=e.doc.sel.ranges,A=[],U=0;U<D.length;U++){for(var V=a(D[U]);A.length&&dr(V.from,q(A).to)<=0;){var re=A.pop();if(dr(re.from,V.from)<0){V.from=re.from;break}}A.push(V)}Ra(e,function(){for(var se=A.length-1;se>=0;se--)ro(e.doc,"",A[se].from,A[se].to,"+delete");vi(e)})}function is(e,a,D){var A=Te(e.text,a+D,D);return A<0||A>e.text.length?null:A}function os(e,a,D){var A=is(e,a.ch,D);return A==null?null:new It(a.line,A,D<0?"after":"before")}function ss(e,a,D,A,U){if(e){a.doc.direction=="rtl"&&(U=-U);var V=ot(D,a.doc.direction);if(V){var re=U<0?q(V):V[0],se=U<0==(re.level==1),ce=se?"after":"before",ve;if(re.level>0||a.doc.direction=="rtl"){var Ne=je(a,D);ve=U<0?D.text.length-1:0;var He=Ge(a,Ne,ve).top;ve=ze(function(tt){return Ge(a,Ne,tt).top==He},U<0==(re.level==1)?re.from:re.to-1,ve),ce=="before"&&(ve=is(D,ve,1))}else ve=U<0?re.to:re.from;return new It(A,ve,ce)}}return new It(A,U<0?D.text.length:0,U<0?"before":"after")}function Ml(e,a,D,A){var U=ot(a,e.doc.direction);if(!U)return os(a,D,A);D.ch>=a.text.length?(D.ch=a.text.length,D.sticky="before"):D.ch<=0&&(D.ch=0,D.sticky="after");var V=rt(U,D.ch,D.sticky),re=U[V];if(e.doc.direction=="ltr"&&re.level%2==0&&(A>0?re.to>D.ch:re.from<D.ch))return os(a,D,A);var se=function(Yt,sr){return is(a,Yt instanceof It?Yt.ch:Yt,sr)},ce,ve=function(Yt){return e.options.lineWrapping?(ce=ce||je(e,a),fr(e,a,ce,Yt)):{begin:0,end:a.text.length}},Ne=ve(D.sticky=="before"?se(D,-1):D.ch);if(e.doc.direction=="rtl"||re.level==1){var He=re.level==1==A<0,tt=se(D,He?1:-1);if(tt!=null&&(He?tt<=re.to&&tt<=Ne.end:tt>=re.from&&tt>=Ne.begin)){var $e=He?"before":"after";return new It(D.line,tt,$e)}}var vt=function(Yt,sr,$t){for(var pr=function(Dn,ca){return ca?new It(D.line,se(Dn,1),"before"):new It(D.line,Dn,"after")};Yt>=0&&Yt<U.length;Yt+=sr){var Fr=U[Yt],Dr=sr>0==(Fr.level!=1),sn=Dr?$t.begin:se($t.end,-1);if(Fr.from<=sn&&sn<Fr.to)return pr(sn,Dr);if(sn=Dr?Fr.from:se(Fr.to,-1),$t.begin<=sn&&sn<$t.end)return pr(sn,Dr)}},Rt=vt(V+A,A,Ne);if(Rt)return Rt;var Ft=A>0?Ne.end:se(Ne.begin,-1);return Ft!=null&&!(A>0&&Ft==a.text.length)&&(Rt=vt(A>0?0:U.length-1,A,ve(Ft)),Rt)?Rt:null}var So={selectAll:Is,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),xe)},killLine:function(e){return io(e,function(a){if(a.empty()){var D=er(e.doc,a.head.line).text.length;return a.head.ch==D&&a.head.line<e.lastLine()?{from:a.head,to:It(a.head.line+1,0)}:{from:a.head,to:It(a.head.line,D)}}else return{from:a.from(),to:a.to()}})},deleteLine:function(e){return io(e,function(a){return{from:It(a.from().line,0),to:xr(e.doc,It(a.to().line+1,0))}})},delLineLeft:function(e){return io(e,function(a){return{from:It(a.from().line,0),to:a.from()}})},delWrappedLineLeft:function(e){return io(e,function(a){var D=e.charCoords(a.head,"div").top+5,A=e.coordsChar({left:0,top:D},"div");return{from:A,to:a.from()}})},delWrappedLineRight:function(e){return io(e,function(a){var D=e.charCoords(a.head,"div").top+5,A=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:D},"div");return{from:a.from(),to:A}})},undo:function(e){return e.undo()},redo:function(e){return e.redo()},undoSelection:function(e){return e.undoSelection()},redoSelection:function(e){return e.redoSelection()},goDocStart:function(e){return e.extendSelection(It(e.firstLine(),0))},goDocEnd:function(e){return e.extendSelection(It(e.lastLine()))},goLineStart:function(e){return e.extendSelectionsBy(function(a){return Vs(e,a.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(e){return e.extendSelectionsBy(function(a){return Ys(e,a.head)},{origin:"+move",bias:1})},goLineEnd:function(e){return e.extendSelectionsBy(function(a){return Nl(e,a.head.line)},{origin:"+move",bias:-1})},goLineRight:function(e){return e.extendSelectionsBy(function(a){var D=e.cursorCoords(a.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:D},"div")},me)},goLineLeft:function(e){return e.extendSelectionsBy(function(a){var D=e.cursorCoords(a.head,"div").top+5;return e.coordsChar({left:0,top:D},"div")},me)},goLineLeftSmart:function(e){return e.extendSelectionsBy(function(a){var D=e.cursorCoords(a.head,"div").top+5,A=e.coordsChar({left:0,top:D},"div");return A.ch<e.getLine(A.line).search(/\S/)?Ys(e,a.head):A},me)},goLineUp:function(e){return e.moveV(-1,"line")},goLineDown:function(e){return e.moveV(1,"line")},goPageUp:function(e){return e.moveV(-1,"page")},goPageDown:function(e){return e.moveV(1,"page")},goCharLeft:function(e){return e.moveH(-1,"char")},goCharRight:function(e){return e.moveH(1,"char")},goColumnLeft:function(e){return e.moveH(-1,"column")},goColumnRight:function(e){return e.moveH(1,"column")},goWordLeft:function(e){return e.moveH(-1,"word")},goGroupRight:function(e){return e.moveH(1,"group")},goGroupLeft:function(e){return e.moveH(-1,"group")},goWordRight:function(e){return e.moveH(1,"word")},delCharBefore:function(e){return e.deleteH(-1,"codepoint")},delCharAfter:function(e){return e.deleteH(1,"char")},delWordBefore:function(e){return e.deleteH(-1,"word")},delWordAfter:function(e){return e.deleteH(1,"word")},delGroupBefore:function(e){return e.deleteH(-1,"group")},delGroupAfter:function(e){return e.deleteH(1,"group")},indentAuto:function(e){return e.indentSelection("smart")},indentMore:function(e){return e.indentSelection("add")},indentLess:function(e){return e.indentSelection("subtract")},insertTab:function(e){return e.replaceSelection(" ")},insertSoftTab:function(e){for(var a=[],D=e.listSelections(),A=e.options.tabSize,U=0;U<D.length;U++){var V=D[U].from(),re=K(e.getLine(V.line),V.ch,A);a.push(ie(A-re%A))}e.replaceSelections(a)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){return Ra(e,function(){for(var a=e.listSelections(),D=[],A=0;A<a.length;A++){if(!a[A].empty())continue;var U=a[A].head,V=er(e.doc,U.line).text;if(V){if(U.ch==V.length&&(U=new It(U.line,U.ch-1)),U.ch>0)U=new It(U.line,U.ch+1),e.replaceRange(V.charAt(U.ch-1)+V.charAt(U.ch-2),It(U.line,U.ch-2),U,"+transpose");else if(U.line>e.doc.first){var re=er(e.doc,U.line-1).text;re&&(U=new It(U.line,1),e.replaceRange(V.charAt(0)+e.doc.lineSeparator()+re.charAt(re.length-1),It(U.line-1,re.length-1),U,"+transpose"))}}D.push(new vn(U,U))}e.setSelections(D)})},newlineAndIndent:function(e){return Ra(e,function(){for(var a=e.listSelections(),D=a.length-1;D>=0;D--)e.replaceRange(e.doc.lineSeparator(),a[D].anchor,a[D].head,"+input");a=e.listSelections();for(var A=0;A<a.length;A++)e.indentLine(a[A].from().line,null,!0);vi(e)})},openLine:function(e){return e.replaceSelection(`
`,"start")},toggleOverwrite:function(e){return e.toggleOverwrite()}};function Vs(e,a){var D=er(e.doc,a),A=gt(D);return A!=D&&(a=Qr(A)),ss(!0,e,A,a,1)}function Nl(e,a){var D=er(e.doc,a),A=bt(D);return A!=D&&(a=Qr(A)),ss(!0,e,D,a,-1)}function Ys(e,a){var D=Vs(e,a.line),A=er(e.doc,D.line),U=ot(A,e.doc.direction);if(!U||U[0].level==0){var V=Math.max(D.ch,A.text.search(/\S/)),re=a.line==D.line&&a.ch<=V&&a.ch;return It(D.line,re?0:V,D.sticky)}return D}function Go(e,a,D){if(typeof a=="string"&&(a=So[a],!a))return!1;e.display.input.ensurePolled();var A=e.display.shift,U=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),D&&(e.display.shift=!1),U=a(e)!=_e}finally{e.display.shift=A,e.state.suppressEdits=!1}return U}function jl(e,a,D){for(var A=0;A<e.state.keyMaps.length;A++){var U=ao(a,e.state.keyMaps[A],D,e);if(U)return U}return e.options.extraKeys&&ao(a,e.options.extraKeys,D,e)||ao(a,e.options.keyMap,D,e)}var Fl=new Y;function Oo(e,a,D,A){var U=e.state.keySeq;if(U){if(zs(a))return"handled";if(/\'$/.test(a)?e.state.keySeq=null:Fl.set(50,function(){e.state.keySeq==U&&(e.state.keySeq=null,e.display.input.reset())}),$s(e,U+" "+a,D,A))return!0}return $s(e,a,D,A)}function $s(e,a,D,A){var U=jl(e,a,A);return U=="multi"&&(e.state.keySeq=a),U=="handled"&&Ht(e,"keyHandled",e,a,D),(U=="handled"||U=="multi")&&(pe(D),Hn(e)),!!U}function Js(e,a){var D=Xs(a,!0);return D?a.shiftKey&&!e.state.keySeq?Oo(e,"Shift-"+D,a,function(A){return Go(e,A,!0)})||Oo(e,D,a,function(A){if(typeof A=="string"?/^go[A-Z]/.test(A):A.motion)return Go(e,A)}):Oo(e,D,a,function(A){return Go(e,A)}):!1}function Ul(e,a,D){return Oo(e,"'"+D+"'",a,function(A){return Go(e,A,!0)})}var ls=null;function Qs(e){var a=this;if(e.target&&e.target!=a.display.input.getField())return;if(a.curOp.focus=G(),et(a,e))return;w&&b<11&&e.keyCode==27&&(e.returnValue=!1);var D=e.keyCode;a.display.shift=D==16||e.shiftKey;var A=Js(a,e);c&&(ls=A?D:null,!A&&D==88&&!kr&&(l?e.metaKey:e.ctrlKey)&&a.replaceSelection("",null,"cut")),C&&!l&&!A&&D==46&&e.shiftKey&&!e.ctrlKey&&document.execCommand&&document.execCommand("cut"),D==18&&!/\bCodeMirror-crosshair\b/.test(a.display.lineDiv.className)&&Bl(a)}function Bl(e){var a=e.display.lineDiv;W(a,"CodeMirror-crosshair");function D(A){(A.keyCode==18||!A.altKey)&&(g(a,"CodeMirror-crosshair"),nt(document,"keyup",D),nt(document,"mouseover",D))}Se(document,"keyup",D),Se(document,"mouseover",D)}function Zs(e){e.keyCode==16&&(this.doc.sel.shift=!1),et(this,e)}function el(e){var a=this;if(e.target&&e.target!=a.display.input.getField())return;if(rn(a.display,e)||et(a,e)||e.ctrlKey&&!e.altKey||l&&e.metaKey)return;var D=e.keyCode,A=e.charCode;if(c&&D==ls){ls=null,pe(e);return}if(c&&(!e.which||e.which<10)&&Js(a,e))return;var U=String.fromCharCode(A==null?D:A);if(U=="\b")return;if(Ul(a,e,U))return;a.display.input.onKeyPress(e)}var Hl=400,us=function(e,a,D){this.time=e,this.pos=a,this.button=D};us.prototype.compare=function(e,a,D){return this.time+Hl>e&&dr(a,this.pos)==0&&D==this.button};var Co,Ao;function Wl(e,a){var D=+new Date;return Ao&&Ao.compare(D,e,a)?(Co=Ao=null,"triple"):Co&&Co.compare(D,e,a)?(Ao=new us(D,e,a),Co=null,"double"):(Co=new us(D,e,a),Ao=null,"single")}function tl(e){var a=this,D=a.display;if(et(a,e)||D.activeTouch&&D.input.supportsTouch())return;if(D.input.ensurePolled(),D.shift=e.shiftKey,rn(D,e)){p||(D.scroller.draggable=!1,setTimeout(function(){return D.scroller.draggable=!0},100));return}if(cs(a,e))return;var A=zn(a,e),U=Ve(e),V=A?Wl(A,U):"single";if(window.focus(),U==1&&a.state.selectingText&&a.state.selectingText(e),A&&Kl(a,U,A,V,e))return;U==1?A?Gl(a,A,V,e):ke(e)==D.scroller&&pe(e):U==2?(A&&Uo(a.doc,A),setTimeout(function(){return D.input.focus()},20)):U==3&&(R?a.display.input.onContextMenu(e):xi(a))}function Kl(e,a,D,A,U){var V="Click";return A=="double"?V="Double"+V:A=="triple"&&(V="Triple"+V),V=(a==1?"Left":a==2?"Middle":"Right")+V,Oo(e,Gs(V,U),U,function(re){if(typeof re=="string"&&(re=So[re]),!re)return!1;var se=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),se=re(e,D)!=_e}finally{e.state.suppressEdits=!1}return se})}function zl(e,a,D){var A=e.getOption("configureMouse"),U=A?A(e,a,D):{};if(U.unit==null){var V=t?D.shiftKey&&D.metaKey:D.altKey;U.unit=V?"rectangle":a=="single"?"char":a=="double"?"word":"line"}return(U.extend==null||e.doc.extend)&&(U.extend=e.doc.extend||D.shiftKey),U.addNew==null&&(U.addNew=l?D.metaKey:D.ctrlKey),U.moveOnDrag==null&&(U.moveOnDrag=!(l?D.altKey:D.ctrlKey)),U}function Gl(e,a,D,A){w?setTimeout(B(Bi,e),0):e.curOp.focus=G();var U=zl(e,D,A),V=e.doc.sel,re;e.options.dragDrop&&ut&&!e.isReadOnly()&&D=="single"&&(re=V.contains(a))>-1&&(dr((re=V.ranges[re]).from(),a)<0||a.xRel>0)&&(dr(re.to(),a)>0||a.xRel<0)?Xl(e,A,a,U):Vl(e,A,a,U)}function Xl(e,a,D,A){var U=e.display,V=!1,re=Yn(e,function(ve){p&&(U.scroller.draggable=!1),e.state.draggingText=!1,nt(U.wrapper.ownerDocument,"mouseup",re),nt(U.wrapper.ownerDocument,"mousemove",se),nt(U.scroller,"dragstart",ce),nt(U.scroller,"drop",re),V||(pe(ve),A.addNew||Uo(e.doc,D,null,null,A.extend),p&&!r||w&&b==9?setTimeout(function(){U.wrapper.ownerDocument.body.focus({preventScroll:!0}),U.input.focus()},20):U.input.focus())}),se=function(ve){V=V||Math.abs(a.clientX-ve.clientX)+Math.abs(a.clientY-ve.clientY)>=10},ce=function(){return V=!0};p&&(U.scroller.draggable=!0),e.state.draggingText=re,re.copy=!A.moveOnDrag,U.scroller.dragDrop&&U.scroller.dragDrop(),Se(U.wrapper.ownerDocument,"mouseup",re),Se(U.wrapper.ownerDocument,"mousemove",se),Se(U.scroller,"dragstart",ce),Se(U.scroller,"drop",re),xi(e),setTimeout(function(){return U.input.focus()},20)}function rl(e,a,D){if(D=="char")return new vn(a,a);if(D=="word")return e.findWordAt(a);if(D=="line")return new vn(It(a.line,0),xr(e.doc,It(a.line+1,0)));var A=D(e,a);return new vn(A.from,A.to)}function Vl(e,a,D,A){var U=e.display,V=e.doc;pe(a);var re,se,ce=V.sel,ve=ce.ranges;if(A.addNew&&!A.extend?(se=V.sel.contains(D),se>-1?re=ve[se]:re=new vn(D,D)):(re=V.sel.primary(),se=V.sel.primIndex),A.unit=="rectangle")A.addNew||(re=new vn(D,D)),D=zn(e,a,!0,!0),se=-1;else{var Ne=rl(e,D,A.unit);A.extend?re=ns(re,Ne.anchor,Ne.head,A.extend):re=Ne}A.addNew?se==-1?(se=ve.length,Sa(V,Ja(e,ve.concat([re]),se),{scroll:!1,origin:"*mouse"})):ve.length>1&&ve[se].empty()&&A.unit=="char"&&!A.extend?(Sa(V,Ja(e,ve.slice(0,se).concat(ve.slice(se+1)),0),{scroll:!1,origin:"*mouse"}),ce=V.sel):as(V,se,re,le):(se=0,Sa(V,new Da([re],0),le),ce=V.sel);var He=D;function tt($t){if(dr(He,$t)==0)return;if(He=$t,A.unit=="rectangle"){for(var pr=[],Fr=e.options.tabSize,Dr=K(er(V,D.line).text,D.ch,Fr),sn=K(er(V,$t.line).text,$t.ch,Fr),Dn=Math.min(Dr,sn),ca=Math.max(Dr,sn),Wn=Math.min(D.line,$t.line),Ga=Math.min(e.lastLine(),Math.max(D.line,$t.line));Wn<=Ga;Wn++){var Ua=er(V,Wn).text,qn=de(Ua,Dn,Fr);Dn==ca?pr.push(new vn(It(Wn,qn),It(Wn,qn))):Ua.length>qn&&pr.push(new vn(It(Wn,qn),It(Wn,de(Ua,ca,Fr))))}pr.length||pr.push(new vn(D,D)),Sa(V,Ja(e,ce.ranges.slice(0,se).concat(pr),se),{origin:"*mouse",scroll:!1}),e.scrollIntoView($t)}else{var Ba=re,ya=rl(e,$t,A.unit),sa=Ba.anchor,ea;dr(ya.anchor,sa)>0?(ea=ya.head,sa=pa(Ba.from(),ya.anchor)):(ea=ya.anchor,sa=Pa(Ba.to(),ya.head));var Gn=ce.ranges.slice(0);Gn[se]=Yl(e,new vn(xr(V,sa),ea)),Sa(V,Ja(e,Gn,se),le)}}var $e=U.wrapper.getBoundingClientRect(),vt=0;function Rt($t){var pr=++vt,Fr=zn(e,$t,!0,A.unit=="rectangle");if(!Fr)return;if(dr(Fr,He)!=0){e.curOp.focus=G(),tt(Fr);var Dr=Pi(U,V);(Fr.line>=Dr.to||Fr.line<Dr.from)&&setTimeout(Yn(e,function(){vt==pr&&Rt($t)}),150)}else{var sn=$t.clientY<$e.top?-20:$t.clientY>$e.bottom?20:0;sn&&setTimeout(Yn(e,function(){if(vt!=pr)return;U.scroller.scrollTop+=sn,Rt($t)}),50)}}function Ft($t){e.state.selectingText=!1,vt=Infinity,$t&&(pe($t),U.input.focus()),nt(U.wrapper.ownerDocument,"mousemove",Yt),nt(U.wrapper.ownerDocument,"mouseup",sr),V.history.lastSelOrigin=null}var Yt=Yn(e,function($t){$t.buttons===0||!Ve($t)?Ft($t):Rt($t)}),sr=Yn(e,Ft);e.state.selectingText=sr,Se(U.wrapper.ownerDocument,"mousemove",Yt),Se(U.wrapper.ownerDocument,"mouseup",sr)}function Yl(e,a){var D=a.anchor,A=a.head,U=er(e.doc,D.line);if(dr(D,A)==0&&D.sticky==A.sticky)return a;var V=ot(U);if(!V)return a;var re=rt(V,D.ch,D.sticky),se=V[re];if(se.from!=D.ch&&se.to!=D.ch)return a;var ce=re+(se.from==D.ch==(se.level!=1)?0:1);if(ce==0||ce==V.length)return a;var ve;if(A.line!=D.line)ve=(A.line-D.line)*(e.doc.direction=="ltr"?1:-1)>0;else{var Ne=rt(V,A.ch,A.sticky),He=Ne-re||(A.ch-D.ch)*(se.level==1?-1:1);Ne==ce-1||Ne==ce?ve=He<0:ve=He>0}var tt=V[ce+(ve?-1:0)],$e=ve==(tt.level==1),vt=$e?tt.from:tt.to,Rt=$e?"after":"before";return D.ch==vt&&D.sticky==Rt?a:new vn(new It(D.line,vt,Rt),A)}function nl(e,a,D,A){var U,V;if(a.touches)U=a.touches[0].clientX,V=a.touches[0].clientY;else try{U=a.clientX,V=a.clientY}catch(tt){return!1}if(U>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;A&&pe(a);var re=e.display,se=re.lineDiv.getBoundingClientRect();if(V>se.bottom||!Ce(e,D))return we(a);V-=se.top-re.viewOffset;for(var ce=0;ce<e.display.gutterSpecs.length;++ce){var ve=re.gutters.childNodes[ce];if(ve&&ve.getBoundingClientRect().right>=U){var Ne=Ln(e.doc,V),He=e.display.gutterSpecs[ce];return We(e,D,e,Ne,He.className,a),we(a)}}}function cs(e,a){return nl(e,a,"gutterClick",!0)}function al(e,a){if(rn(e.display,a)||$l(e,a))return;if(et(e,a,"contextmenu"))return;R||e.display.input.onContextMenu(a)}function $l(e,a){return Ce(e,"gutterContextMenu")?nl(e,a,"gutterContextMenu",!1):!1}function il(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Br(e)}var oo={toString:function(){return"CodeMirror.Init"}},ol={},Xo={};function Jl(e){var a=e.optionHandlers;function D(A,U,V,re){e.defaults[A]=U,V&&(a[A]=re?function(se,ce,ve){ve!=oo&&V(se,ce,ve)}:V)}e.defineOption=D,e.Init=oo,D("value","",function(A,U){return A.setValue(U)},!0),D("mode",null,function(A,U){A.doc.modeOption=U,Ai(A)},!0),D("indentUnit",2,Ai,!0),D("indentWithTabs",!1),D("smartIndent",!0),D("tabSize",4,function(A){vo(A),Br(A),Tn(A)},!0),D("lineSeparator",null,function(A,U){if(A.doc.lineSep=U,!U)return;var V=[],re=A.doc.first;A.doc.iter(function(ce){for(var ve=0;;){var Ne=ce.text.indexOf(U,ve);if(Ne==-1)break;ve=Ne+U.length,V.push(It(re,Ne))}re++});for(var se=V.length-1;se>=0;se--)ro(A.doc,U,V[se],It(V[se].line,V[se].ch+U.length))}),D("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,function(A,U,V){A.state.specialChars=new RegExp(U.source+(U.test(" ")?"":"| "),"g"),V!=oo&&A.refresh()}),D("specialCharPlaceholder",ar,function(A){return A.refresh()},!0),D("electricChars",!0),D("inputStyle",s?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),D("spellcheck",!1,function(A,U){return A.getInputField().spellcheck=U},!0),D("autocorrect",!1,function(A,U){return A.getInputField().autocorrect=U},!0),D("autocapitalize",!1,function(A,U){return A.getInputField().autocapitalize=U},!0),D("rtlMoveVisually",!S),D("wholeLineUpdateBefore",!0),D("theme","default",function(A){il(A),ci(A)},!0),D("keyMap","default",function(A,U,V){var re=zo(U),se=V!=oo&&zo(V);se&&se.detach&&se.detach(A,re),re.attach&&re.attach(A,se||null)}),D("extraKeys",null),D("configureMouse",null),D("lineWrapping",!1,Zl,!0),D("gutters",[],function(A,U){A.display.gutterSpecs=Ia(U,A.options.lineNumbers),ci(A)},!0),D("fixedGutter",!0,function(A,U){A.display.gutters.style.left=U?Zn(A.display)+"px":"0",A.refresh()},!0),D("coverGutterNextToScrollbar",!1,function(A){return Qt(A)},!0),D("scrollbarStyle","native",function(A){ui(A),Qt(A),A.display.scrollbars.setScrollTop(A.doc.scrollTop),A.display.scrollbars.setScrollLeft(A.doc.scrollLeft)},!0),D("lineNumbers",!1,function(A,U){A.display.gutterSpecs=Ia(A.options.gutters,U),ci(A)},!0),D("firstLineNumber",1,ci,!0),D("lineNumberFormatter",function(A){return A},ci,!0),D("showCursorWhenSelecting",!1,mn,!0),D("resetSelectionOnContextMenu",!0),D("lineWiseCopyCut",!0),D("pasteLinesPerSelection",!0),D("selectionsMayTouch",!1),D("readOnly",!1,function(A,U){U=="nocursor"&&(ri(A),A.display.input.blur()),A.display.input.readOnlyChanged(U)}),D("screenReaderLabel",null,function(A,U){U=U===""?null:U,A.display.input.screenReaderLabelChanged(U)}),D("disableInput",!1,function(A,U){U||A.display.input.reset()},!0),D("dragDrop",!0,Ql),D("allowDropFileTypes",null),D("cursorBlinkRate",530),D("cursorScrollMargin",0),D("cursorHeight",1,mn,!0),D("singleCursorHeightPerLine",!0,mn,!0),D("workTime",100),D("workDelay",100),D("flattenSpans",!0,vo,!0),D("addModeClass",!1,vo,!0),D("pollInterval",100),D("undoDepth",200,function(A,U){return A.doc.history.undoDepth=U}),D("historyEventDelay",1250),D("viewportMargin",10,function(A){return A.refresh()},!0),D("maxHighlightLength",1e4,vo,!0),D("moveInputWithCursor",!0,function(A,U){U||A.display.input.resetPosition()}),D("tabindex",null,function(A,U){return A.display.input.getField().tabIndex=U||""}),D("autofocus",null),D("direction","ltr",function(A,U){return A.doc.setDirection(U)},!0),D("phrases",null)}function Ql(e,a,D){var A=D&&D!=oo;if(!a!=!A){var U=e.display.dragFunctions,V=a?Se:nt;V(e.display.scroller,"dragstart",U.start),V(e.display.scroller,"dragenter",U.enter),V(e.display.scroller,"dragover",U.over),V(e.display.scroller,"dragleave",U.leave),V(e.display.scroller,"drop",U.drop)}}function Zl(e){e.options.lineWrapping?(W(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(g(e.display.wrapper,"CodeMirror-wrap"),vr(e)),ua(e),Tn(e),Br(e),setTimeout(function(){return Qt(e)},100)}function Un(e,a){var D=this;if(!(this instanceof Un))return new Un(e,a);this.options=a=a?k(a):{},k(ol,a,!1);var A=a.value;typeof A=="string"?A=new Fa(A,a.mode,null,a.lineSeparator,a.direction):a.mode&&(A.modeOption=a.mode),this.doc=A;var U=new Un.inputStyles[a.inputStyle](this),V=this.display=new zi(e,A,U,a);V.wrapper.CodeMirror=this,il(this),a.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),ui(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new Y,keySeq:null,specialChars:null},a.autofocus&&!s&&V.input.focus(),w&&b<11&&setTimeout(function(){return D.display.input.reset(!0)},20),ql(this),Il(),Sn(this),this.curOp.forceUpdate=!0,gs(this,A),a.autofocus&&!s||this.hasFocus()?setTimeout(function(){D.hasFocus()&&!D.state.focused&&ti(D)},20):ri(this);for(var re in Xo)Xo.hasOwnProperty(re)&&Xo[re](this,a[re],oo);ia(this),a.finishInit&&a.finishInit(this);for(var se=0;se<ds.length;++se)ds[se](this);Oi(this),p&&a.lineWrapping&&getComputedStyle(V.lineDiv).textRendering=="optimizelegibility"&&(V.lineDiv.style.textRendering="auto")}Un.defaults=ol,Un.optionHandlers=Xo;function ql(e){var a=e.display;Se(a.scroller,"mousedown",Yn(e,tl)),w&&b<11?Se(a.scroller,"dblclick",Yn(e,function(ce){if(et(e,ce))return;var ve=zn(e,ce);if(!ve||cs(e,ce)||rn(e.display,ce))return;pe(ce);var Ne=e.findWordAt(ve);Uo(e.doc,Ne.anchor,Ne.head)})):Se(a.scroller,"dblclick",function(ce){return et(e,ce)||pe(ce)}),Se(a.scroller,"contextmenu",function(ce){return al(e,ce)}),Se(a.input.getField(),"contextmenu",function(ce){a.scroller.contains(ce.target)||al(e,ce)});var D,A={end:0};function U(){a.activeTouch&&(D=setTimeout(function(){return a.activeTouch=null},1e3),A=a.activeTouch,A.end=+new Date)}function V(ce){if(ce.touches.length!=1)return!1;var ve=ce.touches[0];return ve.radiusX<=1&&ve.radiusY<=1}function re(ce,ve){if(ve.left==null)return!0;var Ne=ve.left-ce.left,He=ve.top-ce.top;return Ne*Ne+He*He>20*20}Se(a.scroller,"touchstart",function(ce){if(!et(e,ce)&&!V(ce)&&!cs(e,ce)){a.input.ensurePolled(),clearTimeout(D);var ve=+new Date;a.activeTouch={start:ve,moved:!1,prev:ve-A.end<=300?A:null},ce.touches.length==1&&(a.activeTouch.left=ce.touches[0].pageX,a.activeTouch.top=ce.touches[0].pageY)}}),Se(a.scroller,"touchmove",function(){a.activeTouch&&(a.activeTouch.moved=!0)}),Se(a.scroller,"touchend",function(ce){var ve=a.activeTouch;if(ve&&!rn(a,ce)&&ve.left!=null&&!ve.moved&&new Date-ve.start<300){var Ne=e.coordsChar(a.activeTouch,"page"),He;!ve.prev||re(ve,ve.prev)?He=new vn(Ne,Ne):!ve.prev.prev||re(ve,ve.prev.prev)?He=e.findWordAt(Ne):He=new vn(It(Ne.line,0),xr(e.doc,It(Ne.line+1,0))),e.setSelection(He.anchor,He.head),e.focus(),pe(ce)}U()}),Se(a.scroller,"touchcancel",U),Se(a.scroller,"scroll",function(){a.scroller.clientHeight&&(ii(e,a.scroller.scrollTop),ja(e,a.scroller.scrollLeft,!0),We(e,"scroll",e))}),Se(a.scroller,"mousewheel",function(ce){return po(e,ce)}),Se(a.scroller,"DOMMouseScroll",function(ce){return po(e,ce)}),Se(a.wrapper,"scroll",function(){return a.wrapper.scrollTop=a.wrapper.scrollLeft=0}),a.dragFunctions={enter:function(ce){et(e,ce)||Ie(ce)},over:function(ce){et(e,ce)||(Rl(e,ce),Ie(ce))},start:function(ce){return Al(e,ce)},drop:Yn(e,Cl),leave:function(ce){et(e,ce)||Hs(e)}};var se=a.input.getField();Se(se,"keyup",function(ce){return Zs.call(e,ce)}),Se(se,"keydown",Yn(e,Qs)),Se(se,"keypress",Yn(e,el)),Se(se,"focus",function(ce){return ti(e,ce)}),Se(se,"blur",function(ce){return ri(e,ce)})}var ds=[];Un.defineInitHook=function(e){return ds.push(e)};function Ro(e,a,D,A){var U=e.doc,V;D==null&&(D="add"),D=="smart"&&(U.mode.indent?V=Qn(e,a).state:D="prev");var re=e.options.tabSize,se=er(U,a),ce=K(se.text,null,re);se.stateAfter&&(se.stateAfter=null);var ve=se.text.match(/^\s*/)[0],Ne;if(!A&&!/\S/.test(se.text))Ne=0,D="not";else if(D=="smart"&&(Ne=U.mode.indent(V,se.text.slice(ve.length),se.text),Ne==_e||Ne>150)){if(!A)return;D="prev"}D=="prev"?a>U.first?Ne=K(er(U,a-1).text,null,re):Ne=0:D=="add"?Ne=ce+e.options.indentUnit:D=="subtract"?Ne=ce-e.options.indentUnit:typeof D=="number"&&(Ne=ce+D),Ne=Math.max(0,Ne);var He="",tt=0;if(e.options.indentWithTabs)for(var $e=Math.floor(Ne/re);$e;--$e)tt+=re,He+=" ";if(tt<Ne&&(He+=ie(Ne-tt)),He!=ve)return ro(U,He,It(a,0),It(a,ve.length),"+input"),se.stateAfter=null,!0;for(var vt=0;vt<U.sel.ranges.length;vt++){var Rt=U.sel.ranges[vt];if(Rt.head.line==a&&Rt.head.ch<ve.length){var Ft=It(a,ve.length);as(U,vt,new vn(Ft,Ft));break}}}var hi=null;function Vo(e){hi=e}function fs(e,a,D,A,U){var V=e.doc;e.display.shift=!1,A||(A=V.sel);var re=+new Date-200,se=U=="paste"||e.state.pasteIncoming>re,ce=rr(a),ve=null;if(se&&A.ranges.length>1)if(hi&&hi.text.join(`
`)==a){if(A.ranges.length%hi.text.length==0){ve=[];for(var Ne=0;Ne<hi.text.length;Ne++)ve.push(V.splitLines(hi.text[Ne]))}}else ce.length==A.ranges.length&&e.options.pasteLinesPerSelection&&(ve=ue(ce,function(Yt){return[Yt]}));for(var He=e.curOp.updateInput,tt=A.ranges.length-1;tt>=0;tt--){var $e=A.ranges[tt],vt=$e.from(),Rt=$e.to();$e.empty()&&(D&&D>0?vt=It(vt.line,vt.ch-D):e.state.overwrite&&!se?Rt=It(Rt.line,Math.min(er(V,Rt.line).text.length,Rt.ch+q(ce).length)):se&&hi&&hi.lineWise&&hi.text.join(`
`)==ce.join(`
`)&&(vt=Rt=It(vt.line,0)));var Ft={from:vt,to:Rt,text:ve?ve[tt%ve.length]:ce,origin:U||(se?"paste":e.state.cutIncoming>re?"cut":"+input")};to(e.doc,Ft),Ht(e,"inputRead",e,Ft)}a&&!se&&ll(e,a),vi(e),e.curOp.updateInput<2&&(e.curOp.updateInput=He),e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=-1}function sl(e,a){var D=e.clipboardData&&e.clipboardData.getData("Text");if(D)return e.preventDefault(),!a.isReadOnly()&&!a.options.disableInput&&Ra(a,function(){return fs(a,D,0,null,"paste")}),!0}function ll(e,a){if(!e.options.electricChars||!e.options.smartIndent)return;for(var D=e.doc.sel,A=D.ranges.length-1;A>=0;A--){var U=D.ranges[A];if(U.head.ch>100||A&&D.ranges[A-1].head.line==U.head.line)continue;var V=e.getModeAt(U.head),re=!1;if(V.electricChars){for(var se=0;se<V.electricChars.length;se++)if(a.indexOf(V.electricChars.charAt(se))>-1){re=Ro(e,U.head.line,"smart");break}}else V.electricInput&&(V.electricInput.test(er(e.doc,U.head.line).text.slice(0,U.head.ch))&&(re=Ro(e,U.head.line,"smart")));re&&Ht(e,"electricInput",e,U.head.line)}}function ul(e){for(var a=[],D=[],A=0;A<e.doc.sel.ranges.length;A++){var U=e.doc.sel.ranges[A].head.line,V={anchor:It(U,0),head:It(U+1,0)};D.push(V),a.push(e.getRange(V.anchor,V.head))}return{text:a,ranges:D}}function cl(e,a,D,A){e.setAttribute("autocorrect",D?"":"off"),e.setAttribute("autocapitalize",A?"":"off"),e.setAttribute("spellcheck",!!a)}function dl(){var e=T("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),a=T("div",[e],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return p?e.style.width="1000px":e.setAttribute("wrap","off"),u&&(e.style.border="1px solid black"),cl(e),a}function eu(e){var a=e.optionHandlers,D=e.helpers={};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(A,U){var V=this.options,re=V[A];if(V[A]==U&&A!="mode")return;V[A]=U,a.hasOwnProperty(A)&&Yn(this,a[A])(this,U,re),We(this,"optionChange",this,A)},getOption:function(A){return this.options[A]},getDoc:function(){return this.doc},addKeyMap:function(A,U){this.state.keyMaps[U?"push":"unshift"](zo(A))},removeKeyMap:function(A){for(var U=this.state.keyMaps,V=0;V<U.length;++V)if(U[V]==A||U[V].name==A)return U.splice(V,1),!0},addOverlay:ba(function(A,U){var V=A.token?A:e.getMode(this.options,A);if(V.startState)throw new Error("Overlays may not be stateful.");Z(this.state.overlays,{mode:V,modeSpec:A,opaque:U&&U.opaque,priority:U&&U.priority||0},function(re){return re.priority}),this.state.modeGen++,Tn(this)}),removeOverlay:ba(function(A){for(var U=this.state.overlays,V=0;V<U.length;++V){var re=U[V].modeSpec;if(re==A||typeof A=="string"&&re.name==A){U.splice(V,1),this.state.modeGen++,Tn(this);return}}}),indentLine:ba(function(A,U,V){typeof U!="string"&&typeof U!="number"&&(U==null?U=this.options.smartIndent?"smart":"prev":U=U?"add":"subtract"),la(this.doc,A)&&Ro(this,A,U,V)}),indentSelection:ba(function(A){for(var U=this.doc.sel.ranges,V=-1,re=0;re<U.length;re++){var se=U[re];if(se.empty())se.head.line>V&&(Ro(this,se.head.line,A,!0),V=se.head.line,re==this.doc.sel.primIndex&&vi(this));else{var ce=se.from(),ve=se.to(),Ne=Math.max(V,ce.line);V=Math.min(this.lastLine(),ve.line-(ve.ch?0:1))+1;for(var He=Ne;He<V;++He)Ro(this,He,A);var tt=this.doc.sel.ranges;ce.ch==0&&U.length==tt.length&&tt[re].from().ch>0&&as(this.doc,re,new vn(ce,tt[re].to()),xe)}}}),getTokenAt:function(A,U){return na(this,A,U)},getLineTokens:function(A,U){return na(this,It(A),U,!0)},getTokenTypeAt:function(A){A=xr(this.doc,A);var U=Ta(this,er(this.doc,A.line)),V=0,re=(U.length-1)/2,se=A.ch,ce;if(se==0)ce=U[2];else for(;;){var ve=V+re>>1;if((ve?U[ve*2-1]:0)>=se)re=ve;else if(U[ve*2+1]<se)V=ve+1;else{ce=U[ve*2+2];break}}var Ne=ce?ce.indexOf("overlay "):-1;return Ne<0?ce:Ne==0?null:ce.slice(0,Ne-1)},getModeAt:function(A){var U=this.doc.mode;return U.innerMode?e.innerMode(U,this.getTokenAt(A).state).mode:U},getHelper:function(A,U){return this.getHelpers(A,U)[0]},getHelpers:function(A,U){var V=[];if(!D.hasOwnProperty(U))return V;var re=D[U],se=this.getModeAt(A);if(typeof se[U]=="string")re[se[U]]&&V.push(re[se[U]]);else if(se[U])for(var ce=0;ce<se[U].length;ce++){var ve=re[se[U][ce]];ve&&V.push(ve)}else se.helperType&&re[se.helperType]?V.push(re[se.helperType]):re[se.name]&&V.push(re[se.name]);for(var Ne=0;Ne<re._global.length;Ne++){var He=re._global[Ne];He.pred(se,this)&&ne(V,He.val)==-1&&V.push(He.val)}return V},getStateAfter:function(A,U){var V=this.doc;return A=kn(V,A==null?V.first+V.size-1:A),Qn(this,A+1,U).state},cursorCoords:function(A,U){var V,re=this.doc.sel.primary();return A==null?V=re.head:typeof A=="object"?V=xr(this.doc,A):V=A?re.from():re.to(),Zr(this,V,U||"page")},charCoords:function(A,U){return gn(this,xr(this.doc,A),U||"page")},coordsChar:function(A,U){return A=$r(this,A,U||"page"),Xr(this,A.left,A.top)},lineAtHeight:function(A,U){return A=$r(this,{top:A,left:0},U||"page").top,Ln(this.doc,A+this.display.viewOffset)},heightAtLine:function(A,U,V){var re=!1,se;if(typeof A=="number"){var ce=this.doc.first+this.doc.size-1;A<this.doc.first?A=this.doc.first:A>ce&&(A=ce,re=!0),se=er(this.doc,A)}else se=A;return on(this,se,{top:0,left:0},U||"page",V||re).top+(re?this.doc.height-Zt(se):0)},defaultTextHeight:function(){return Fn(this.display)},defaultCharWidth:function(){return Kn(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(A,U,V,re,se){var ce=this.display;A=Zr(this,xr(this.doc,A));var ve=A.bottom,Ne=A.left;if(U.style.position="absolute",U.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(U),ce.sizer.appendChild(U),re=="over")ve=A.top;else if(re=="above"||re=="near"){var He=Math.max(ce.wrapper.clientHeight,this.doc.height),tt=Math.max(ce.sizer.clientWidth,ce.lineSpace.clientWidth);(re=="above"||A.bottom+U.offsetHeight>He)&&A.top>U.offsetHeight?ve=A.top-U.offsetHeight:A.bottom+U.offsetHeight<=He&&(ve=A.bottom),Ne+U.offsetWidth>tt&&(Ne=tt-U.offsetWidth)}U.style.top=ve+"px",U.style.left=U.style.right="",se=="right"?(Ne=ce.sizer.clientWidth-U.offsetWidth,U.style.right="0px"):(se=="left"?Ne=0:se=="middle"&&(Ne=(ce.sizer.clientWidth-U.offsetWidth)/2),U.style.left=Ne+"px"),V&&ki(this,{left:Ne,top:ve,right:Ne+U.offsetWidth,bottom:ve+U.offsetHeight})},triggerOnKeyDown:ba(Qs),triggerOnKeyPress:ba(el),triggerOnKeyUp:Zs,triggerOnMouseDown:ba(tl),execCommand:function(A){if(So.hasOwnProperty(A))return So[A].call(null,this)},triggerElectric:ba(function(A){ll(this,A)}),findPosH:function(A,U,V,re){var se=1;U<0&&(se=-1,U=-U);for(var ce=xr(this.doc,A),ve=0;ve<U&&!(ce=hs(this.doc,ce,se,V,re),ce.hitSide);++ve);return ce},moveH:ba(function(A,U){var V=this;this.extendSelectionsBy(function(re){return V.display.shift||V.doc.extend||re.empty()?hs(V.doc,re.head,A,U,V.options.rtlMoveVisually):A<0?re.from():re.to()},me)}),deleteH:ba(function(A,U){var V=this.doc.sel,re=this.doc;V.somethingSelected()?re.replaceSelection("",null,"+delete"):io(this,function(se){var ce=hs(re,se.head,A,U,!1);return A<0?{from:ce,to:se.head}:{from:se.head,to:ce}})}),findPosV:function(A,U,V,re){var se=1,ce=re;U<0&&(se=-1,U=-U);for(var ve=xr(this.doc,A),Ne=0;Ne<U;++Ne){var He=Zr(this,ve,"div");if(ce==null?ce=He.left:He.left=ce,ve=fl(this,He,se,V),ve.hitSide)break}return ve},moveV:ba(function(A,U){var V=this,re=this.doc,se=[],ce=!this.display.shift&&!re.extend&&re.sel.somethingSelected();if(re.extendSelectionsBy(function(Ne){if(ce)return A<0?Ne.from():Ne.to();var He=Zr(V,Ne.head,"div");Ne.goalColumn!=null&&(He.left=Ne.goalColumn),se.push(He.left);var tt=fl(V,He,A,U);return U=="page"&&Ne==re.sel.primary()&&wi(V,gn(V,tt,"div").top-He.top),tt},me),se.length)for(var ve=0;ve<re.sel.ranges.length;ve++)re.sel.ranges[ve].goalColumn=se[ve]}),findWordAt:function(A){var U=this.doc,V=er(U,A.line).text,re=A.ch,se=A.ch;if(V){var ce=this.getHelper(A,"wordChars");(A.sticky=="before"||se==V.length)&&re?--re:++se;for(var ve=V.charAt(re),Ne=X(ve,ce)?function(He){return X(He,ce)}:/\s/.test(ve)?function(He){return/\s/.test(He)}:function(He){return!/\s/.test(He)&&!X(He)};re>0&&Ne(V.charAt(re-1));)--re;for(;se<V.length&&Ne(V.charAt(se));)++se}return new vn(It(A.line,re),It(A.line,se))},toggleOverwrite:function(A){if(A!=null&&A==this.state.overwrite)return;(this.state.overwrite=!this.state.overwrite)?W(this.display.cursorDiv,"CodeMirror-overwrite"):g(this.display.cursorDiv,"CodeMirror-overwrite"),We(this,"overwriteToggle",this,this.state.overwrite)},hasFocus:function(){return this.display.input.getField()==G()},isReadOnly:function(){return!!(this.options.readOnly||this.doc.cantEdit)},scrollTo:ba(function(A,U){ai(this,A,U)}),getScrollInfo:function(){var A=this.display.scroller;return{left:A.scrollLeft,top:A.scrollTop,height:A.scrollHeight-Ke(this)-this.display.barHeight,width:A.scrollWidth-Ke(this)-this.display.barWidth,clientHeight:he(this),clientWidth:Le(this)}},scrollIntoView:ba(function(A,U){A==null?(A={from:this.doc.sel.primary().head,to:null},U==null&&(U=this.options.cursorScrollMargin)):typeof A=="number"?A={from:It(A,0),to:null}:A.from==null&&(A={from:A,to:null}),A.to||(A.to=A.from),A.margin=U||0,A.from.line!=null?co(this,A):Si(this,A.from,A.to,A.margin)}),setSize:ba(function(A,U){var V=this,re=function(ce){return typeof ce=="number"||/^\d+$/.test(String(ce))?ce+"px":ce};A!=null&&(this.display.wrapper.style.width=re(A)),U!=null&&(this.display.wrapper.style.height=re(U)),this.options.lineWrapping&&Pr(this);var se=this.display.viewFrom;this.doc.iter(se,this.display.viewTo,function(ce){if(ce.widgets){for(var ve=0;ve<ce.widgets.length;ve++)if(ce.widgets[ve].noHScroll){In(V,se,"widget");break}}++se}),this.curOp.forceUpdate=!0,We(this,"refresh",this)}),operation:function(A){return Ra(this,A)},startOperation:function(){return Sn(this)},endOperation:function(){return Oi(this)},refresh:ba(function(){var A=this.display.cachedTextHeight;Tn(this),this.curOp.forceUpdate=!0,Br(this),ai(this,this.doc.scrollLeft,this.doc.scrollTop),Ji(this.display),(A==null||Math.abs(A-Fn(this.display))>.5||this.options.lineWrapping)&&ua(this),We(this,"refresh",this)}),swapDoc:ba(function(A){var U=this.doc;return U.cm=null,this.state.selectingText&&this.state.selectingText(),gs(this,A),Br(this),this.display.input.reset(),ai(this,A.scrollLeft,A.scrollTop),this.curOp.forceScroll=!0,Ht(this,"swapDoc",this,U),U}),phrase:function(A){var U=this.options.phrases;return U&&Object.prototype.hasOwnProperty.call(U,A)?U[A]:A},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},Re(e),e.registerHelper=function(A,U,V){D.hasOwnProperty(A)||(D[A]=e[A]={_global:[]}),D[A][U]=V},e.registerGlobalHelper=function(A,U,V,re){e.registerHelper(A,U,re),D[A]._global.push({pred:V,val:re})}}function hs(e,a,D,A,U){var V=a,re=D,se=er(e,a.line),ce=U&&e.direction=="rtl"?-D:D;function ve(){var sr=a.line+ce;return sr<e.first||sr>=e.first+e.size?!1:(a=new It(sr,a.ch,a.sticky),se=er(e,sr))}function Ne(sr){var $t;if(A=="codepoint"){var pr=se.text.charCodeAt(a.ch+(A>0?0:-1));isNaN(pr)?$t=null:$t=new It(a.line,Math.max(0,Math.min(se.text.length,a.ch+D*(pr>=55296&&pr<56320?2:1))),-D)}else U?$t=Ml(e.cm,se,a,D):$t=os(se,a,D);if($t==null)if(!sr&&ve())a=ss(U,e.cm,se,a.line,ce);else return!1;else a=$t;return!0}if(A=="char"||A=="codepoint")Ne();else if(A=="column")Ne(!0);else if(A=="word"||A=="group")for(var He=null,tt=A=="group",$e=e.cm&&e.cm.getHelper(a,"wordChars"),vt=!0;!(D<0&&!Ne(!vt));vt=!1){var Rt=se.text.charAt(a.ch)||`
`,Ft=X(Rt,$e)?"w":tt&&Rt==`
`?"n":!tt||/\s/.test(Rt)?null:"p";if(tt&&!vt&&!Ft&&(Ft="s"),He&&He!=Ft){D<0&&(D=1,Ne(),a.sticky="after");break}if(Ft&&(He=Ft),D>0&&!Ne(!vt))break}var Yt=Ho(e,a,V,re,!0);return ha(V,Yt)&&(Yt.hitSide=!0),Yt}function fl(e,a,D,A){var U=e.doc,V=a.left,re;if(A=="page"){var se=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),ce=Math.max(se-.5*Fn(e.display),3);re=(D>0?a.bottom:a.top)+D*ce}else A=="line"&&(re=D>0?a.bottom+3:a.top-3);for(var ve;!(ve=Xr(e,V,re),!ve.outside);){if(D<0?re<=0:re>=U.height){ve.hitSide=!0;break}re+=D*5}return ve}var On=function(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new Y,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};On.prototype.init=function(e){var a=this,D=this,A=D.cm,U=D.div=e.lineDiv;cl(U,A.options.spellcheck,A.options.autocorrect,A.options.autocapitalize);function V(se){for(var ce=se.target;ce;ce=ce.parentNode){if(ce==U)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(ce.className))break}return!1}Se(U,"paste",function(se){if(!V(se)||et(A,se)||sl(se,A))return;b<=11&&setTimeout(Yn(A,function(){return a.updateFromDOM()}),20)}),Se(U,"compositionstart",function(se){a.composing={data:se.data,done:!1}}),Se(U,"compositionupdate",function(se){a.composing||(a.composing={data:se.data,done:!1})}),Se(U,"compositionend",function(se){a.composing&&(se.data!=a.composing.data&&a.readFromDOMSoon(),a.composing.done=!0)}),Se(U,"touchstart",function(){return D.forceCompositionEnd()}),Se(U,"input",function(){a.composing||a.readFromDOMSoon()});function re(se){if(!V(se)||et(A,se))return;if(A.somethingSelected())Vo({lineWise:!1,text:A.getSelections()}),se.type=="cut"&&A.replaceSelection("",null,"cut");else if(A.options.lineWiseCopyCut){var ce=ul(A);Vo({lineWise:!0,text:ce.text}),se.type=="cut"&&A.operation(function(){A.setSelections(ce.ranges,0,xe),A.replaceSelection("",null,"cut")})}else return;if(se.clipboardData){se.clipboardData.clearData();var ve=hi.text.join(`
`);if(se.clipboardData.setData("Text",ve),se.clipboardData.getData("Text")==ve){se.preventDefault();return}}var Ne=dl(),He=Ne.firstChild;A.display.lineSpace.insertBefore(Ne,A.display.lineSpace.firstChild),He.value=hi.text.join(`
`);var tt=document.activeElement;z(He),setTimeout(function(){A.display.lineSpace.removeChild(Ne),tt.focus(),tt==U&&D.showPrimarySelection()},50)}Se(U,"copy",re),Se(U,"cut",re)},On.prototype.screenReaderLabelChanged=function(e){e?this.div.setAttribute("aria-label",e):this.div.removeAttribute("aria-label")},On.prototype.prepareSelection=function(){var e=Ca(this.cm,!1);return e.focus=document.activeElement==this.div,e},On.prototype.showSelection=function(e,a){if(!e||!this.cm.display.view.length)return;(e.focus||a)&&this.showPrimarySelection(),this.showMultipleSelections(e)},On.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},On.prototype.showPrimarySelection=function(){var e=this.getSelection(),a=this.cm,D=a.doc.sel.primary(),A=D.from(),U=D.to();if(a.display.viewTo==a.display.viewFrom||A.line>=a.display.viewTo||U.line<a.display.viewFrom){e.removeAllRanges();return}var V=Yo(a,e.anchorNode,e.anchorOffset),re=Yo(a,e.focusNode,e.focusOffset);if(V&&!V.bad&&re&&!re.bad&&dr(pa(V,re),A)==0&&dr(Pa(V,re),U)==0)return;var se=a.display.view,ce=A.line>=a.display.viewFrom&&hl(a,A)||{node:se[0].measure.map[2],offset:0},ve=U.line<a.display.viewTo&&hl(a,U);if(!ve){var Ne=se[se.length-1].measure,He=Ne.maps?Ne.maps[Ne.maps.length-1]:Ne.map;ve={node:He[He.length-1],offset:He[He.length-2]-He[He.length-3]}}if(!ce||!ve){e.removeAllRanges();return}var tt=e.rangeCount&&e.getRangeAt(0),$e;try{$e=I(ce.node,ce.offset,ve.offset,ve.node)}catch(vt){}$e&&(!C&&a.state.focused?(e.collapse(ce.node,ce.offset),$e.collapsed||(e.removeAllRanges(),e.addRange($e))):(e.removeAllRanges(),e.addRange($e)),tt&&e.anchorNode==null?e.addRange(tt):C&&this.startGracePeriod()),this.rememberSelection()},On.prototype.startGracePeriod=function(){var e=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){e.gracePeriod=!1,e.selectionChanged()&&e.cm.operation(function(){return e.cm.curOp.selectionChanged=!0})},20)},On.prototype.showMultipleSelections=function(e){E(this.cm.display.cursorDiv,e.cursors),E(this.cm.display.selectionDiv,e.selection)},On.prototype.rememberSelection=function(){var e=this.getSelection();this.lastAnchorNode=e.anchorNode,this.lastAnchorOffset=e.anchorOffset,this.lastFocusNode=e.focusNode,this.lastFocusOffset=e.focusOffset},On.prototype.selectionInEditor=function(){var e=this.getSelection();if(!e.rangeCount)return!1;var a=e.getRangeAt(0).commonAncestorContainer;return P(this.div,a)},On.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||document.activeElement!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},On.prototype.blur=function(){this.div.blur()},On.prototype.getField=function(){return this.div},On.prototype.supportsTouch=function(){return!0},On.prototype.receivedFocus=function(){var e=this;this.selectionInEditor()?this.pollSelection():Ra(this.cm,function(){return e.cm.curOp.selectionChanged=!0});function a(){e.cm.state.focused&&(e.pollSelection(),e.polling.set(e.cm.options.pollInterval,a))}this.polling.set(this.cm.options.pollInterval,a)},On.prototype.selectionChanged=function(){var e=this.getSelection();return e.anchorNode!=this.lastAnchorNode||e.anchorOffset!=this.lastAnchorOffset||e.focusNode!=this.lastFocusNode||e.focusOffset!=this.lastFocusOffset},On.prototype.pollSelection=function(){if(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())return;var e=this.getSelection(),a=this.cm;if(f&&n&&this.cm.display.gutterSpecs.length&&tu(e.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(this.composing)return;this.rememberSelection();var D=Yo(a,e.anchorNode,e.anchorOffset),A=Yo(a,e.focusNode,e.focusOffset);D&&A&&Ra(a,function(){Sa(a.doc,di(D,A),xe),(D.bad||A.bad)&&(a.curOp.selectionChanged=!0)})},On.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var e=this.cm,a=e.display,D=e.doc.sel.primary(),A=D.from(),U=D.to();if(A.ch==0&&A.line>e.firstLine()&&(A=It(A.line-1,er(e.doc,A.line-1).length)),U.ch==er(e.doc,U.line).text.length&&U.line<e.lastLine()&&(U=It(U.line+1,0)),A.line<a.viewFrom||U.line>a.viewTo-1)return!1;var V,re,se;A.line==a.viewFrom||(V=xn(e,A.line))==0?(re=Qr(a.view[0].line),se=a.view[0].node):(re=Qr(a.view[V].line),se=a.view[V-1].node.nextSibling);var ce=xn(e,U.line),ve,Ne;if(ce==a.view.length-1?(ve=a.viewTo-1,Ne=a.lineDiv.lastChild):(ve=Qr(a.view[ce+1].line)-1,Ne=a.view[ce+1].node.previousSibling),!se)return!1;for(var He=e.doc.splitLines(ru(e,se,Ne,re,ve)),tt=Xn(e.doc,It(re,0),It(ve,er(e.doc,ve).text.length));He.length>1&&tt.length>1;)if(q(He)==q(tt))He.pop(),tt.pop(),ve--;else if(He[0]==tt[0])He.shift(),tt.shift(),re++;else break;for(var $e=0,vt=0,Rt=He[0],Ft=tt[0],Yt=Math.min(Rt.length,Ft.length);$e<Yt&&Rt.charCodeAt($e)==Ft.charCodeAt($e);)++$e;for(var sr=q(He),$t=q(tt),pr=Math.min(sr.length-(He.length==1?$e:0),$t.length-(tt.length==1?$e:0));vt<pr&&sr.charCodeAt(sr.length-vt-1)==$t.charCodeAt($t.length-vt-1);)++vt;if(He.length==1&&tt.length==1&&re==A.line)for(;$e&&$e>A.ch&&sr.charCodeAt(sr.length-vt-1)==$t.charCodeAt($t.length-vt-1);)$e--,vt++;He[He.length-1]=sr.slice(0,sr.length-vt).replace(/^\u200b+/,""),He[0]=He[0].slice($e).replace(/\u200b+$/,"");var Fr=It(re,$e),Dr=It(ve,tt.length?q(tt).length-vt:0);if(He.length>1||He[0]||dr(Fr,Dr))return ro(e.doc,He,Fr,Dr,"+input"),!0},On.prototype.ensurePolled=function(){this.forceCompositionEnd()},On.prototype.reset=function(){this.forceCompositionEnd()},On.prototype.forceCompositionEnd=function(){if(!this.composing)return;clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus()},On.prototype.readFromDOMSoon=function(){var e=this;if(this.readDOMTimeout!=null)return;this.readDOMTimeout=setTimeout(function(){if(e.readDOMTimeout=null,e.composing)if(e.composing.done)e.composing=null;else return;e.updateFromDOM()},80)},On.prototype.updateFromDOM=function(){var e=this;(this.cm.isReadOnly()||!this.pollContent())&&Ra(this.cm,function(){return Tn(e.cm)})},On.prototype.setUneditable=function(e){e.contentEditable="false"},On.prototype.onKeyPress=function(e){if(e.charCode==0||this.composing)return;e.preventDefault(),this.cm.isReadOnly()||Yn(this.cm,fs)(this.cm,String.fromCharCode(e.charCode==null?e.keyCode:e.charCode),0)},On.prototype.readOnlyChanged=function(e){this.div.contentEditable=String(e!="nocursor")},On.prototype.onContextMenu=function(){},On.prototype.resetPosition=function(){},On.prototype.needsContentAttribute=!0;function hl(e,a){var D=Be(e,a.line);if(!D||D.hidden)return null;var A=er(e.doc,a.line),U=be(D,A,a.line),V=ot(A,e.doc.direction),re="left";if(V){var se=rt(V,a.ch);re=se%2?"right":"left"}var ce=Et(U.map,a.ch,re);return ce.offset=ce.collapse=="right"?ce.end:ce.start,ce}function tu(e){for(var a=e;a;a=a.parentNode)if(/CodeMirror-gutter-wrapper/.test(a.className))return!0;return!1}function so(e,a){return a&&(e.bad=!0),e}function ru(e,a,D,A,U){var V="",re=!1,se=e.doc.lineSeparator(),ce=!1;function ve($e){return function(vt){return vt.id==$e}}function Ne(){re&&(V+=se,ce&&(V+=se),re=ce=!1)}function He($e){$e&&(Ne(),V+=$e)}function tt($e){if($e.nodeType==1){var vt=$e.getAttribute("cm-text");if(vt){He(vt);return}var Rt=$e.getAttribute("cm-marker"),Ft;if(Rt){var Yt=e.findMarks(It(A,0),It(U+1,0),ve(+Rt));Yt.length&&(Ft=Yt[0].find(0))&&He(Xn(e.doc,Ft.from,Ft.to).join(se));return}if($e.getAttribute("contenteditable")=="false")return;var sr=/^(pre|div|p|li|table|br)$/i.test($e.nodeName);if(!/^br$/i.test($e.nodeName)&&$e.textContent.length==0)return;sr&&Ne();for(var $t=0;$t<$e.childNodes.length;$t++)tt($e.childNodes[$t]);/^(pre|p)$/i.test($e.nodeName)&&(ce=!0),sr&&(re=!0)}else $e.nodeType==3&&He($e.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;!(tt(a),a==D);)a=a.nextSibling,ce=!1;return V}function Yo(e,a,D){var A;if(a==e.display.lineDiv){if(A=e.display.lineDiv.childNodes[D],!A)return so(e.clipPos(It(e.display.viewTo-1)),!0);a=null,D=0}else for(A=a;;A=A.parentNode){if(!A||A==e.display.lineDiv)return null;if(A.parentNode&&A.parentNode==e.display.lineDiv)break}for(var U=0;U<e.display.view.length;U++){var V=e.display.view[U];if(V.node==A)return nu(V,a,D)}}function nu(e,a,D){var A=e.text.firstChild,U=!1;if(!a||!P(A,a))return so(It(Qr(e.line),0),!0);if(a==A&&(U=!0,a=A.childNodes[D],D=0,!a)){var V=e.rest?q(e.rest):e.line;return so(It(Qr(V),V.text.length),U)}var re=a.nodeType==3?a:null,se=a;for(!re&&a.childNodes.length==1&&a.firstChild.nodeType==3&&(re=a.firstChild,D&&(D=re.nodeValue.length));se.parentNode!=A;)se=se.parentNode;var ce=e.measure,ve=ce.maps;function Ne(Ft,Yt,sr){for(var $t=-1;$t<(ve?ve.length:0);$t++)for(var pr=$t<0?ce.map:ve[$t],Fr=0;Fr<pr.length;Fr+=3){var Dr=pr[Fr+2];if(Dr==Ft||Dr==Yt){var sn=Qr($t<0?e.line:e.rest[$t]),Dn=pr[Fr]+sr;return(sr<0||Dr!=Ft)&&(Dn=pr[Fr+(sr?1:0)]),It(sn,Dn)}}}var He=Ne(re,se,D);if(He)return so(He,U);for(var tt=se.nextSibling,$e=re?re.nodeValue.length-D:0;tt;tt=tt.nextSibling){if(He=Ne(tt,tt.firstChild,0),He)return so(It(He.line,He.ch-$e),U);$e+=tt.textContent.length}for(var vt=se.previousSibling,Rt=D;vt;vt=vt.previousSibling){if(He=Ne(vt,vt.firstChild,-1),He)return so(It(He.line,He.ch+Rt),U);Rt+=vt.textContent.length}}var Jn=function(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new Y,this.hasSelection=!1,this.composing=null};Jn.prototype.init=function(e){var a=this,D=this,A=this.cm;this.createField(e);var U=this.textarea;e.wrapper.insertBefore(this.wrapper,e.wrapper.firstChild),u&&(U.style.width="0px"),Se(U,"input",function(){w&&b>=9&&a.hasSelection&&(a.hasSelection=null),D.poll()}),Se(U,"paste",function(re){if(et(A,re)||sl(re,A))return;A.state.pasteIncoming=+new Date,D.fastPoll()});function V(re){if(et(A,re))return;if(A.somethingSelected())Vo({lineWise:!1,text:A.getSelections()});else if(A.options.lineWiseCopyCut){var se=ul(A);Vo({lineWise:!0,text:se.text}),re.type=="cut"?A.setSelections(se.ranges,null,xe):(D.prevInput="",U.value=se.text.join(`
`),z(U))}else return;re.type=="cut"&&(A.state.cutIncoming=+new Date)}Se(U,"cut",V),Se(U,"copy",V),Se(e.scroller,"paste",function(re){if(rn(e,re)||et(A,re))return;if(!U.dispatchEvent){A.state.pasteIncoming=+new Date,D.focus();return}var se=new Event("paste");se.clipboardData=re.clipboardData,U.dispatchEvent(se)}),Se(e.lineSpace,"selectstart",function(re){rn(e,re)||pe(re)}),Se(U,"compositionstart",function(){var re=A.getCursor("from");D.composing&&D.composing.range.clear(),D.composing={start:re,range:A.markText(re,A.getCursor("to"),{className:"CodeMirror-composing"})}}),Se(U,"compositionend",function(){D.composing&&(D.poll(),D.composing.range.clear(),D.composing=null)})},Jn.prototype.createField=function(e){this.wrapper=dl(),this.textarea=this.wrapper.firstChild},Jn.prototype.screenReaderLabelChanged=function(e){e?this.textarea.setAttribute("aria-label",e):this.textarea.removeAttribute("aria-label")},Jn.prototype.prepareSelection=function(){var e=this.cm,a=e.display,D=e.doc,A=Ca(e);if(e.options.moveInputWithCursor){var U=Zr(e,D.sel.primary().head,"div"),V=a.wrapper.getBoundingClientRect(),re=a.lineDiv.getBoundingClientRect();A.teTop=Math.max(0,Math.min(a.wrapper.clientHeight-10,U.top+re.top-V.top)),A.teLeft=Math.max(0,Math.min(a.wrapper.clientWidth-10,U.left+re.left-V.left))}return A},Jn.prototype.showSelection=function(e){var a=this.cm,D=a.display;E(D.cursorDiv,e.cursors),E(D.selectionDiv,e.selection),e.teTop!=null&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},Jn.prototype.reset=function(e){if(this.contextMenuPending||this.composing)return;var a=this.cm;if(a.somethingSelected()){this.prevInput="";var D=a.getSelection();this.textarea.value=D,a.state.focused&&z(this.textarea),w&&b>=9&&(this.hasSelection=D)}else e||(this.prevInput=this.textarea.value="",w&&b>=9&&(this.hasSelection=null))},Jn.prototype.getField=function(){return this.textarea},Jn.prototype.supportsTouch=function(){return!1},Jn.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!s||G()!=this.textarea))try{this.textarea.focus()}catch(e){}},Jn.prototype.blur=function(){this.textarea.blur()},Jn.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Jn.prototype.receivedFocus=function(){this.slowPoll()},Jn.prototype.slowPoll=function(){var e=this;if(this.pollingFast)return;this.polling.set(this.cm.options.pollInterval,function(){e.poll(),e.cm.state.focused&&e.slowPoll()})},Jn.prototype.fastPoll=function(){var e=!1,a=this;a.pollingFast=!0;function D(){var A=a.poll();!A&&!e?(e=!0,a.polling.set(60,D)):(a.pollingFast=!1,a.slowPoll())}a.polling.set(20,D)},Jn.prototype.poll=function(){var e=this,a=this.cm,D=this.textarea,A=this.prevInput;if(this.contextMenuPending||!a.state.focused||xt(D)&&!A&&!this.composing||a.isReadOnly()||a.options.disableInput||a.state.keySeq)return!1;var U=D.value;if(U==A&&!a.somethingSelected())return!1;if(w&&b>=9&&this.hasSelection===U||l&&/[\uf700-\uf7ff]/.test(U))return a.display.input.reset(),!1;if(a.doc.sel==a.display.selForContextMenu){var V=U.charCodeAt(0);if(V==8203&&!A&&(A="\u200B"),V==8666)return this.reset(),this.cm.execCommand("undo")}for(var re=0,se=Math.min(A.length,U.length);re<se&&A.charCodeAt(re)==U.charCodeAt(re);)++re;return Ra(a,function(){fs(a,U.slice(re),A.length-re,null,e.composing?"*compose":null),U.length>1e3||U.indexOf(`
`)>-1?D.value=e.prevInput="":e.prevInput=U,e.composing&&(e.composing.range.clear(),e.composing.range=a.markText(e.composing.start,a.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Jn.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Jn.prototype.onKeyPress=function(){w&&b>=9&&(this.hasSelection=null),this.fastPoll()},Jn.prototype.onContextMenu=function(e){var a=this,D=a.cm,A=D.display,U=a.textarea;a.contextMenuPending&&a.contextMenuPending();var V=zn(D,e),re=A.scroller.scrollTop;if(!V||c)return;var se=D.options.resetSelectionOnContextMenu;se&&D.doc.sel.contains(V)==-1&&Yn(D,Sa)(D.doc,di(V),xe);var ce=U.style.cssText,ve=a.wrapper.style.cssText,Ne=a.wrapper.offsetParent.getBoundingClientRect();a.wrapper.style.cssText="position: static",U.style.cssText=`position: absolute; width: 30px; height: 30px;
top: `+(e.clientY-Ne.top-5)+"px; left: "+(e.clientX-Ne.left-5)+`px;
z-index: 1000; background: `+(w?"rgba(255, 255, 255, .05)":"transparent")+`;
outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var He;p&&(He=window.scrollY),A.input.focus(),p&&window.scrollTo(null,He),A.input.reset(),D.somethingSelected()||(U.value=a.prevInput=" "),a.contextMenuPending=$e,A.selForContextMenu=D.doc.sel,clearTimeout(A.detectingSelectAll);function tt(){if(U.selectionStart!=null){var Rt=D.somethingSelected(),Ft="\u200B"+(Rt?U.value:"");U.value="\u21DA",U.value=Ft,a.prevInput=Rt?"":"\u200B",U.selectionStart=1,U.selectionEnd=Ft.length,A.selForContextMenu=D.doc.sel}}function $e(){if(a.contextMenuPending!=$e)return;if(a.contextMenuPending=!1,a.wrapper.style.cssText=ve,U.style.cssText=ce,w&&b<9&&A.scrollbars.setScrollTop(A.scroller.scrollTop=re),U.selectionStart!=null){(!w||w&&b<9)&&tt();var Rt=0,Ft=function(){A.selForContextMenu==D.doc.sel&&U.selectionStart==0&&U.selectionEnd>0&&a.prevInput=="\u200B"?Yn(D,Is)(D):Rt++<10?A.detectingSelectAll=setTimeout(Ft,500):(A.selForContextMenu=null,A.input.reset())};A.detectingSelectAll=setTimeout(Ft,200)}}if(w&&b>=9&&tt(),R){Ie(e);var vt=function(){nt(window,"mouseup",vt),setTimeout($e,20)};Se(window,"mouseup",vt)}else setTimeout($e,50)},Jn.prototype.readOnlyChanged=function(e){e||this.reset(),this.textarea.disabled=e=="nocursor",this.textarea.readOnly=!!e},Jn.prototype.setUneditable=function(){},Jn.prototype.needsContentAttribute=!1;function au(e,a){if(a=a?k(a):{},a.value=e.value,!a.tabindex&&e.tabIndex&&(a.tabindex=e.tabIndex),!a.placeholder&&e.placeholder&&(a.placeholder=e.placeholder),a.autofocus==null){var D=G();a.autofocus=D==e||e.getAttribute("autofocus")!=null&&D==document.body}function A(){e.value=se.getValue()}var U;if(e.form&&(Se(e.form,"submit",A),!a.leaveSubmitMethodAlone)){var V=e.form;U=V.submit;try{var re=V.submit=function(){A(),V.submit=U,V.submit(),V.submit=re}}catch(ce){}}a.finishInit=function(ce){ce.save=A,ce.getTextArea=function(){return e},ce.toTextArea=function(){ce.toTextArea=isNaN,A(),e.parentNode.removeChild(ce.getWrapperElement()),e.style.display="",e.form&&(nt(e.form,"submit",A),!a.leaveSubmitMethodAlone&&typeof e.form.submit=="function"&&(e.form.submit=U))}},e.style.display="none";var se=Un(function(ce){return e.parentNode.insertBefore(ce,e.nextSibling)},a);return se}function iu(e){e.off=nt,e.on=Se,e.wheelEventPixels=ho,e.Doc=Fa,e.splitLines=rr,e.countColumn=K,e.findColumn=de,e.isWordChar=J,e.Pass=_e,e.signal=We,e.Line=Or,e.changeEnd=fi,e.scrollbarModel=qt,e.Pos=It,e.cmpPos=dr,e.modes=ln,e.mimeModes=Sr,e.resolveMode=Bt,e.getMode=ur,e.modeExtensions=jr,e.extendMode=en,e.copyState=Jr,e.startState=Wa,e.innerMode=_a,e.commands=So,e.keyMap=Ri,e.keyName=Xs,e.isModifierKey=zs,e.lookupKey=ao,e.normalizeKeyMap=kl,e.StringStream=_n,e.SharedTextMarker=xo,e.TextMarker=ji,e.LineWidget=Eo,e.e_preventDefault=pe,e.e_stopPropagation=ye,e.e_stop=Ie,e.addClass=W,e.contains=P,e.rmClass=g,e.keyNames=Fi}Jl(Un),eu(Un);var ou="iter insert remove copy getEditor constructor".split(" ");for(var $o in Fa.prototype)Fa.prototype.hasOwnProperty($o)&&ne(ou,$o)<0&&(Un.prototype[$o]=function(e){return function(){return e.apply(this.doc,arguments)}}(Fa.prototype[$o]));return Re(Fa),Un.inputStyles={textarea:Jn,contenteditable:On},Un.defineMode=function(e){!Un.defaults.mode&&e!="null"&&(Un.defaults.mode=e),an.apply(this,arguments)},Un.defineMIME=qr,Un.defineMode("null",function(){return{token:function(e){return e.skipToEnd()}}}),Un.defineMIME("text/plain","null"),Un.defineExtension=function(e,a){Un.prototype[e]=a},Un.defineDocExtension=function(e,a){Fa.prototype[e]=a},Un.fromTextArea=au,iu(Un),Un.version="5.58.2",Un})},WYAk:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){(function(){var v=N,C=v.lib,M=C.Base,m=v.enc,y=m.Utf8,w=v.algo,b=w.HMAC=M.extend({init:function(p,d){p=this._hasher=new p.init,typeof d=="string"&&(d=y.parse(d));var n=p.blockSize,c=n*4;d.sigBytes>c&&(d=p.finalize(d)),d.clamp();for(var r=this._oKey=d.clone(),i=this._iKey=d.clone(),o=r.words,u=i.words,f=0;f<n;f++)o[f]^=1549556828,u[f]^=909522486;r.sigBytes=i.sigBytes=c,this.reset()},reset:function(){var p=this._hasher;p.reset(),p.update(this._iKey)},update:function(p){return this._hasher.update(p),this},finalize:function(p){var d=this._hasher,n=d.finalize(p);d.reset();var c=d.finalize(this._oKey.clone().concat(n));return c}})})()})},WaYH:function(F,Q,j){"use strict";var N=j("rePB"),v=j("Ff2n"),C=j("VTBJ"),M=j("1OyB"),m=j("vuIU"),y=j("JX7q"),w=j("Ji7U"),b=j("LK+K"),p=j("cDcd"),d=j("TSYQ"),n=j.n(d),c=j("sboe"),r=j("OZM5"),i=function(R){var O=R.prefixCls,g=R.level,_=R.isStart,E=R.isEnd;if(!g)return null;for(var T="".concat(O,"-indent-unit"),L=[],I=0;I<g;I+=1){var P;L.push(p.createElement("span",{key:I,className:n()(T,(P={},Object(N.a)(P,"".concat(T,"-start"),_[I+1]),Object(N.a)(P,"".concat(T,"-end"),E[I+1]),Object(N.a)(P,"".concat(T,"-end-first-level"),!I&&E[0]),P))}))}return p.createElement("span",{"aria-hidden":"true",className:"".concat(O,"-indent")},L)},o=i,u=j("815F"),f="open",s="close",l="---",t=function(h){Object(w.a)(O,h);var R=Object(b.a)(O);function O(){var g;return Object(M.a)(this,O),g=R.apply(this,arguments),g.state={dragNodeHighlight:!1},g.onSelectorClick=function(_){var E=g.props.context.onNodeClick;E(_,Object(u.b)(g.props)),g.isSelectable()?g.onSelect(_):g.onCheck(_)},g.onSelectorDoubleClick=function(_){var E=g.props.context.onNodeDoubleClick;E(_,Object(u.b)(g.props))},g.onSelect=function(_){if(g.isDisabled())return;var E=g.props.context.onNodeSelect;_.preventDefault(),E(_,Object(u.b)(g.props))},g.onCheck=function(_){if(g.isDisabled())return;var E=g.props,T=E.disableCheckbox,L=E.checked,I=g.props.context.onNodeCheck;if(!g.isCheckable()||T)return;_.preventDefault();var P=!L;I(_,Object(u.b)(g.props),P)},g.onMouseEnter=function(_){var E=g.props.context.onNodeMouseEnter;E(_,Object(u.b)(g.props))},g.onMouseLeave=function(_){var E=g.props.context.onNodeMouseLeave;E(_,Object(u.b)(g.props))},g.onContextMenu=function(_){var E=g.props.context.onNodeContextMenu;E(_,Object(u.b)(g.props))},g.onDragStart=function(_){var E=g.props.context.onNodeDragStart;_.stopPropagation(),g.setState({dragNodeHighlight:!0}),E(_,Object(y.a)(g));try{_.dataTransfer.setData("text/plain","")}catch(T){}},g.onDragEnter=function(_){var E=g.props.context.onNodeDragEnter;_.preventDefault(),_.stopPropagation(),E(_,Object(y.a)(g))},g.onDragOver=function(_){var E=g.props.context.onNodeDragOver;_.preventDefault(),_.stopPropagation(),E(_,Object(y.a)(g))},g.onDragLeave=function(_){var E=g.props.context.onNodeDragLeave;_.stopPropagation(),E(_,Object(y.a)(g))},g.onDragEnd=function(_){var E=g.props.context.onNodeDragEnd;_.stopPropagation(),g.setState({dragNodeHighlight:!1}),E(_,Object(y.a)(g))},g.onDrop=function(_){var E=g.props.context.onNodeDrop;_.preventDefault(),_.stopPropagation(),g.setState({dragNodeHighlight:!1}),E(_,Object(y.a)(g))},g.onExpand=function(_){var E=g.props.context.onNodeExpand;E(_,Object(u.b)(g.props))},g.setSelectHandle=function(_){g.selectHandle=_},g.getNodeState=function(){var _=g.props.expanded;return g.isLeaf()?null:_?f:s},g.hasChildren=function(){var _=g.props.eventKey,E=g.props.context.keyEntities,T=E[_]||{},L=T.children;return!!(L||[]).length},g.isLeaf=function(){var _=g.props,E=_.isLeaf,T=_.loaded,L=g.props.context.loadData,I=g.hasChildren();return E===!1?!1:E||!L&&!I||L&&T&&!I},g.isDisabled=function(){var _=g.props.disabled,E=g.props.context.disabled;return!!(E||_)},g.isCheckable=function(){var _=g.props.checkable,E=g.props.context.checkable;return!E||_===!1?!1:E},g.syncLoadData=function(_){var E=_.expanded,T=_.loading,L=_.loaded,I=g.props.context,P=I.loadData,G=I.onNodeLoad;if(T)return;P&&E&&!g.isLeaf()&&(!g.hasChildren()&&!L&&G(Object(u.b)(g.props)))},g.renderSwitcher=function(){var _=g.props,E=_.expanded,T=_.switcherIcon,L=g.props.context,I=L.prefixCls,P=L.switcherIcon,G=T||P;if(g.isLeaf())return p.createElement("span",{className:n()("".concat(I,"-switcher"),"".concat(I,"-switcher-noop"))},typeof G=="function"?G(Object(C.a)(Object(C.a)({},g.props),{},{isLeaf:!0})):G);var W=n()("".concat(I,"-switcher"),"".concat(I,"-switcher_").concat(E?f:s));return p.createElement("span",{onClick:g.onExpand,className:W},typeof G=="function"?G(Object(C.a)(Object(C.a)({},g.props),{},{isLeaf:!1})):G)},g.renderCheckbox=function(){var _=g.props,E=_.checked,T=_.halfChecked,L=_.disableCheckbox,I=g.props.context.prefixCls,P=g.isDisabled(),G=g.isCheckable();if(!G)return null;var W=typeof G!="boolean"?G:null;return p.createElement("span",{className:n()("".concat(I,"-checkbox"),E&&"".concat(I,"-checkbox-checked"),!E&&T&&"".concat(I,"-checkbox-indeterminate"),(P||L)&&"".concat(I,"-checkbox-disabled")),onClick:g.onCheck},W)},g.renderIcon=function(){var _=g.props.loading,E=g.props.context.prefixCls;return p.createElement("span",{className:n()("".concat(E,"-iconEle"),"".concat(E,"-icon__").concat(g.getNodeState()||"docu"),_&&"".concat(E,"-icon_loading"))})},g.renderSelector=function(){var _=g.state.dragNodeHighlight,E=g.props,T=E.title,L=E.selected,I=E.icon,P=E.loading,G=E.data,W=g.props.context,H=W.prefixCls,z=W.showIcon,B=W.icon,k=W.draggable,K=W.loadData,Y=W.titleRender,ne=g.isDisabled(),oe="".concat(H,"-node-content-wrapper"),_e;if(z){var xe=I||B;_e=xe?p.createElement("span",{className:n()("".concat(H,"-iconEle"),"".concat(H,"-icon__customize"))},typeof xe=="function"?xe(g.props):xe):g.renderIcon()}else K&&P&&(_e=g.renderIcon());var le;typeof T=="function"?le=T(G):Y?le=Y(G):le=T;var me=p.createElement("span",{className:"".concat(H,"-title")},le);return p.createElement("span",{ref:g.setSelectHandle,title:typeof T=="string"?T:"",className:n()("".concat(oe),"".concat(oe,"-").concat(g.getNodeState()||"normal"),!ne&&(L||_)&&"".concat(H,"-node-selected"),!ne&&k&&"draggable"),draggable:!ne&&k||void 0,"aria-grabbed":!ne&&k||void 0,onMouseEnter:g.onMouseEnter,onMouseLeave:g.onMouseLeave,onContextMenu:g.onContextMenu,onClick:g.onSelectorClick,onDoubleClick:g.onSelectorDoubleClick,onDragStart:k?g.onDragStart:void 0},_e,me)},g}return Object(m.a)(O,[{key:"componentDidMount",value:function(){this.syncLoadData(this.props)}},{key:"componentDidUpdate",value:function(){this.syncLoadData(this.props)}},{key:"isSelectable",value:function(){var _=this.props.selectable,E=this.props.context.selectable;return typeof _=="boolean"?_:E}},{key:"render",value:function(){var _,E=this.props,T=E.eventKey,L=E.className,I=E.style,P=E.dragOver,G=E.dragOverGapTop,W=E.dragOverGapBottom,H=E.isLeaf,z=E.isStart,B=E.isEnd,k=E.expanded,K=E.selected,Y=E.checked,ne=E.halfChecked,oe=E.loading,_e=E.domRef,xe=E.active,le=E.onMouseMove,me=Object(v.a)(E,["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","onMouseMove"]),de=this.props.context,ae=de.prefixCls,ie=de.filterTreeNode,q=de.draggable,ue=de.keyEntities,Z=this.isDisabled(),ee=Object(r.f)(me),Ee=ue[T]||{},te=Ee.level,J=B[B.length-1];return p.createElement("div",Object.assign({ref:_e,className:n()(L,"".concat(ae,"-treenode"),(_={},Object(N.a)(_,"".concat(ae,"-treenode-disabled"),Z),Object(N.a)(_,"".concat(ae,"-treenode-switcher-").concat(k?"open":"close"),!H),Object(N.a)(_,"".concat(ae,"-treenode-checkbox-checked"),Y),Object(N.a)(_,"".concat(ae,"-treenode-checkbox-indeterminate"),ne),Object(N.a)(_,"".concat(ae,"-treenode-selected"),K),Object(N.a)(_,"".concat(ae,"-treenode-loading"),oe),Object(N.a)(_,"".concat(ae,"-treenode-active"),xe),Object(N.a)(_,"".concat(ae,"-treenode-leaf-last"),J),Object(N.a)(_,"drag-over",!Z&&P),Object(N.a)(_,"drag-over-gap-top",!Z&&G),Object(N.a)(_,"drag-over-gap-bottom",!Z&&W),Object(N.a)(_,"filter-node",ie&&ie(Object(u.b)(this.props))),_)),style:I,onDragEnter:q?this.onDragEnter:void 0,onDragOver:q?this.onDragOver:void 0,onDragLeave:q?this.onDragLeave:void 0,onDrop:q?this.onDrop:void 0,onDragEnd:q?this.onDragEnd:void 0,onMouseMove:le},ee),p.createElement(o,{prefixCls:ae,level:te,isStart:z,isEnd:B}),this.renderSwitcher(),this.renderCheckbox(),this.renderSelector())}}]),O}(p.Component),S=function(R){return p.createElement(c.a.Consumer,null,function(O){return p.createElement(t,Object.assign({},R,{context:O}))})};S.displayName="TreeNode",S.defaultProps={title:l},S.isTreeNode=1;var x=Q.a=S},Y1PL:function(F,Q,j){"use strict";j.r(Q),j.d(Q,"ResizableTextArea",function(){return ne});var N=j("wx14"),v=j("1OyB"),C=j("vuIU"),M=j("Ji7U"),m=j("LK+K"),y=j("cDcd"),w=j("VTBJ"),b=j("rePB"),p=j("Zm9Q"),d=j("Kwbf"),n=j("c+Xe"),c=j("m+aA"),r=j("bdgK"),i=new Map;function o(xe){xe.forEach(function(le){var me,de=le.target;(me=i.get(de))===null||me===void 0||me.forEach(function(ae){return ae(de)})})}var u=new r.default(o),f=null,s=null;function l(xe,le){i.has(xe)||(i.set(xe,new Set),u.observe(xe)),i.get(xe).add(le)}function t(xe,le){i.has(xe)&&(i.get(xe).delete(le),i.get(xe).size||(u.unobserve(xe),i.delete(xe)))}var S=function(xe){Object(M.a)(me,xe);var le=Object(m.a)(me);function me(){return Object(v.a)(this,me),le.apply(this,arguments)}return Object(C.a)(me,[{key:"render",value:function(){return this.props.children}}]),me}(y.Component),x=y.createContext(null);function h(xe){var le=xe.children,me=xe.onBatchResize,de=y.useRef(0),ae=y.useRef([]),ie=y.useContext(x),q=y.useCallback(function(ue,Z,ee){de.current+=1;var Ee=de.current;ae.current.push({size:ue,element:Z,data:ee}),Promise.resolve().then(function(){Ee===de.current&&(me==null||me(ae.current),ae.current=[])}),ie==null||ie(ue,Z,ee)},[me,ie]);return y.createElement(x.Provider,{value:q},le)}function R(xe){var le=xe.children,me=xe.disabled,de=y.useRef(null),ae=y.useRef(null),ie=y.useContext(x),q=y.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),ue=y.isValidElement(le)&&Object(n.c)(le),Z=ue?le.ref:null,ee=y.useMemo(function(){return Object(n.a)(Z,de)},[Z,de]),Ee=y.useRef(xe);Ee.current=xe;var te=y.useCallback(function(J){var X=Ee.current,$=X.onResize,ge=X.data,fe=J.getBoundingClientRect(),Te=fe.width,ze=fe.height,Xe=J.offsetWidth,Ye=J.offsetHeight,rt=Math.floor(Te),at=Math.floor(ze);if(q.current.width!==rt||q.current.height!==at||q.current.offsetWidth!==Xe||q.current.offsetHeight!==Ye){var ot={width:rt,height:at,offsetWidth:Xe,offsetHeight:Ye};q.current=ot;var Pe=Xe===Math.round(Te)?Te:Xe,Se=Ye===Math.round(ze)?ze:Ye,Je=Object(w.a)(Object(w.a)({},ot),{},{offsetWidth:Pe,offsetHeight:Se});ie==null||ie(Je,J,ge),$&&Promise.resolve().then(function(){$(Je,J)})}},[]);return y.useEffect(function(){var J=Object(c.a)(de.current)||Object(c.a)(ae.current);return J&&!me&&l(J,te),function(){return t(J,te)}},[de.current,me]),y.createElement(S,{ref:ae},ue?y.cloneElement(le,{ref:ee}):le)}var O="rc-observer-key";function g(xe){var le=xe.children,me=Object(p.a)(le);return me.map(function(de,ae){var ie=(de==null?void 0:de.key)||"".concat(O,"-").concat(ae);return y.createElement(R,Object(N.a)({},xe,{key:ie}),de)})}g.Collection=h;var _=g,E=j("bT9E"),T=j("TSYQ"),L=j.n(T),I=`
min-height:0 !important;
max-height:none !important;
height:0 !important;
visibility:hidden !important;
overflow:hidden !important;
position:absolute !important;
z-index:-1000 !important;
top:0 !important;
right:0 !important
`,P=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break"],G={},W;function H(xe){var le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,me=xe.getAttribute("id")||xe.getAttribute("data-reactid")||xe.getAttribute("name");if(le&&G[me])return G[me];var de=window.getComputedStyle(xe),ae=de.getPropertyValue("box-sizing")||de.getPropertyValue("-moz-box-sizing")||de.getPropertyValue("-webkit-box-sizing"),ie=parseFloat(de.getPropertyValue("padding-bottom"))+parseFloat(de.getPropertyValue("padding-top")),q=parseFloat(de.getPropertyValue("border-bottom-width"))+parseFloat(de.getPropertyValue("border-top-width")),ue=P.map(function(ee){return"".concat(ee,":").concat(de.getPropertyValue(ee))}).join(";"),Z={sizingStyle:ue,paddingSize:ie,borderSize:q,boxSizing:ae};return le&&me&&(G[me]=Z),Z}function z(xe){var le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,me=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,de=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null;W||(W=document.createElement("textarea"),W.setAttribute("tab-index","-1"),W.setAttribute("aria-hidden","true"),document.body.appendChild(W)),xe.getAttribute("wrap")?W.setAttribute("wrap",xe.getAttribute("wrap")):W.removeAttribute("wrap");var ae=H(xe,le),ie=ae.paddingSize,q=ae.borderSize,ue=ae.boxSizing,Z=ae.sizingStyle;W.setAttribute("style","".concat(Z,";").concat(I)),W.value=xe.value||xe.placeholder||"";var ee=Number.MIN_SAFE_INTEGER,Ee=Number.MAX_SAFE_INTEGER,te=W.scrollHeight,J;if(ue==="border-box"?te+=q:ue==="content-box"&&(te-=ie),me!==null||de!==null){W.value=" ";var X=W.scrollHeight-ie;me!==null&&(ee=X*me,ue==="border-box"&&(ee=ee+ie+q),te=Math.max(ee,te)),de!==null&&(Ee=X*de,ue==="border-box"&&(Ee=Ee+ie+q),J=te>Ee?"":"hidden",te=Math.min(Ee,te))}return{height:te,minHeight:ee,maxHeight:Ee,overflowY:J,resize:"none"}}var B=j("Gytx"),k=j.n(B),K;(function(xe){xe[xe.NONE=0]="NONE",xe[xe.RESIZING=1]="RESIZING",xe[xe.RESIZED=2]="RESIZED"})(K||(K={}));var Y=function(xe){Object(M.a)(me,xe);var le=Object(m.a)(me);function me(de){var ae;return Object(v.a)(this,me),ae=le.call(this,de),ae.nextFrameActionId=void 0,ae.resizeFrameId=void 0,ae.textArea=void 0,ae.saveTextArea=function(ie){ae.textArea=ie},ae.handleResize=function(ie){var q=ae.state.resizeStatus,ue=ae.props,Z=ue.autoSize,ee=ue.onResize;if(q!==K.NONE)return;typeof ee=="function"&&ee(ie),Z&&ae.resizeOnNextFrame()},ae.resizeOnNextFrame=function(){cancelAnimationFrame(ae.nextFrameActionId),ae.nextFrameActionId=requestAnimationFrame(ae.resizeTextarea)},ae.resizeTextarea=function(){var ie=ae.props.autoSize;if(!ie||!ae.textArea)return;var q=ie.minRows,ue=ie.maxRows,Z=z(ae.textArea,!1,q,ue);ae.setState({textareaStyles:Z,resizeStatus:K.RESIZING},function(){cancelAnimationFrame(ae.resizeFrameId),ae.resizeFrameId=requestAnimationFrame(function(){ae.setState({resizeStatus:K.RESIZED},function(){ae.resizeFrameId=requestAnimationFrame(function(){ae.setState({resizeStatus:K.NONE}),ae.fixFirefoxAutoScroll()})})})})},ae.renderTextArea=function(){var ie=ae.props,q=ie.prefixCls,ue=q===void 0?"rc-textarea":q,Z=ie.autoSize,ee=ie.onResize,Ee=ie.className,te=ie.disabled,J=ae.state,X=J.textareaStyles,$=J.resizeStatus,ge=Object(E.a)(ae.props,["prefixCls","onPressEnter","autoSize","defaultValue","onResize"]),fe=L()(ue,Ee,Object(b.a)({},"".concat(ue,"-disabled"),te));"value"in ge&&(ge.value=ge.value||"");var Te=Object(w.a)(Object(w.a)(Object(w.a)({},ae.props.style),X),$===K.RESIZING?{overflowX:"hidden",overflowY:"hidden"}:null);return y.createElement(_,{onResize:ae.handleResize,disabled:!(Z||ee)},y.createElement("textarea",Object(N.a)({},ge,{className:fe,style:Te,ref:ae.saveTextArea})))},ae.state={textareaStyles:{},resizeStatus:K.NONE},ae}return Object(C.a)(me,[{key:"componentDidUpdate",value:function(ae){(ae.value!==this.props.value||!k()(ae.autoSize,this.props.autoSize))&&this.resizeTextarea()}},{key:"componentWillUnmount",value:function(){cancelAnimationFrame(this.nextFrameActionId),cancelAnimationFrame(this.resizeFrameId)}},{key:"fixFirefoxAutoScroll",value:function(){try{if(document.activeElement===this.textArea){var ae=this.textArea.selectionStart,ie=this.textArea.selectionEnd;this.textArea.setSelectionRange(ae,ie)}}catch(q){}}},{key:"render",value:function(){return this.renderTextArea()}}]),me}(y.Component),ne=Y,oe=function(xe){Object(M.a)(me,xe);var le=Object(m.a)(me);function me(de){var ae;Object(v.a)(this,me),ae=le.call(this,de),ae.resizableTextArea=void 0,ae.focus=function(){ae.resizableTextArea.textArea.focus()},ae.saveTextArea=function(q){ae.resizableTextArea=q},ae.handleChange=function(q){var ue=ae.props.onChange;ae.setValue(q.target.value,function(){ae.resizableTextArea.resizeTextarea()}),ue&&ue(q)},ae.handleKeyDown=function(q){var ue=ae.props,Z=ue.onPressEnter,ee=ue.onKeyDown;q.keyCode===13&&Z&&Z(q),ee&&ee(q)};var ie=typeof de.value=="undefined"||de.value===null?de.defaultValue:de.value;return ae.state={value:ie},ae}return Object(C.a)(me,[{key:"setValue",value:function(ae,ie){"value"in this.props||this.setState({value:ae},ie)}},{key:"blur",value:function(){this.resizableTextArea.textArea.blur()}},{key:"render",value:function(){return y.createElement(ne,Object(N.a)({},this.props,{value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,ref:this.saveTextArea}))}}],[{key:"getDerivedStateFromProps",value:function(ae){return"value"in ae?{value:ae.value}:null}}]),me}(y.Component),_e=Q.default=oe},ZW9T:function(F,Q,j){"use strict";j.d(Q,"a",function(){return z});var N=j("k1fw"),v=j("miYZ"),C=j("tsqr"),M=j("rAM+"),m=j("tJVT"),y=j("PpiC"),w=j("cDcd"),b=j.n(w),p=j("bdgK"),d=j("oBTY"),n=j("9og8"),c=j("WmNS"),r=j.n(c),i={keywords:["print","auto","break","case","char","const","continue","default","do","double","else","enum","extern","float","for","goto","if","int","long","register","return","short","signed","sizeof","static","struct","switch","typedef","union","unsigned","void","volatile","while"]},o={quickKey:[{label:"main",content:["public static void main(String[] args) {"," $0","}"].join(`
`)},{label:"System.out.println",content:["System.out.println($0)"].join(`
`)},{label:"System.out.print",content:["System.out.print($0)"].join(`
`)}],keywords:["abstract","continue","for","new","switch","assert","default","goto","package","synchronized","boolean","do","if","private","this","break","double","implements","protected","throw","byte","else","import","public","throws","case","enum","instanceof","return","transient","catch","extends","int","short","try","char","final","interface","static","void","class","finally","long","strictfp","volatile","const","float","native","super","while","true","false"]},u={keywords:["abstract","amp","array","auto","bool","break","case","catch","char","class","const","constexpr","const_cast","continue","cpu","decltype","default","delegate","delete","do","double","dynamic_cast","each","else","enum","event","explicit","export","extern","false","final","finally","float","for","friend","gcnew","generic","goto","if","in","initonly","inline","int","interface","interior_ptr","internal","literal","long","mutable","namespace","new","noexcept","nullptr","__nullptr","operator","override","partial","pascal","pin_ptr","private","property","protected","public","ref","register","reinterpret_cast","restrict","return","safe_cast","sealed","short","signed","sizeof","static","static_assert","static_cast","struct","switch","template","this","thread_local","throw","tile_static","true","try","typedef","typeid","typename","union","unsigned","using","virtual","void","volatile","wchar_t","where","while","_asm","_based","_cdecl","_declspec","_fastcall","_if_exists","_if_not_exists","_inline","_multiple_inheritance","_pascal","_single_inheritance","_stdcall","_virtual_inheritance","_w64","__abstract","__alignof","__asm","__assume","__based","__box","__builtin_alignof","__cdecl","__clrcall","__declspec","__delegate","__event","__except","__fastcall","__finally","__forceinline","__gc","__hook","__identifier","__if_exists","__if_not_exists","__inline","__int128","__int16","__int32","__int64","__int8","__interface","__leave","__m128","__m128d","__m128i","__m256","__m256d","__m256i","__m64","__multiple_inheritance","__newslot","__nogc","__noop","__nounwind","__novtordisp","__pascal","__pin","__pragma","__property","__ptr32","__ptr64","__raise","__restrict","__resume","__sealed","__single_inheritance","__stdcall","__super","__thiscall","__try","__try_cast","__typeof","__unaligned","__unhook","__uuidof","__value","__virtual_inheritance","__w64","__wchar_t"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],quickKey:[{label:"ifelse",content:["if (${1:condition}) {"," $0","} else {"," ","}"].join(`
`)},{label:"#include",content:'include "$0"'},{label:"printf",content:"printf($0)"},{label:"main",content:["int main () {"," $0","}"].join(`
`)},{label:"for",content:["for( ; ; ){"," $0","}"].join(`
`)},{label:"trycatch",content:["try{"," $0","}catch(ExceptionName e){","}"].join(`
`)},{label:"using namespace std;",content:["using namespace std;"].join(`
`)},{label:"#include <iostream>",content:["#include <iostream>"].join(`
`)},{label:"#include <vector>",content:["#include <vector>"].join(`
`)},{label:"#include <sstream>",content:["#include <sstream>"].join(`
`)},{label:"#include <string>",content:["#include <string>"].join(`
`)},{label:"#include <cmath>",content:["#include <cmath>"].join(`
`)}]},f={keywords:["and","as","assert","break","class","continue","def","del","elif","else","except","exec","finally","for","from","global","if","import","in","is","lambda","None","not","or","pass","raise","return","self","try","while","with","yield","int","float","long","complex","hex","abs","all","any","apply","basestring","bin","bool","buffer","bytearray","callable","chr","classmethod","cmp","coerce","compile","complex","delattr","dict","dir","divmod","enumerate","eval","execfile","file","filter","format","frozenset","getattr","globals","hasattr","hash","help","id","input","intern","isinstance","issubclass","iter","len","locals","list","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","reversed","range","raw_input","reduce","reload","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","unichr","unicode","vars","xrange","zip","True","False","__dict__","__methods__","__members__","__class__","__bases__","__name__","__mro__","__subclasses__","__init__","__import__"],quickKey:[{label:"print",content:["print($0)"].join(`
`)}]},s=j("5VLF"),l=j.n(s),t={languages:["c","abap","apex","azcli","bat","cameligo","clojure","coffee","cpp","csharp","csp","css","dockerfile","fsharp","go","graphql","handlebars","html","ini","java","javascript","json","kotlin","less","lua","markdown","mips","msdax","mysql","objective-c","pascal","pascaligo","perl","pgsql","php","postiats","powerquery","powershell","pug","python","r","razor","redis","redshift","restructuredtext","ruby","rust","sb","scheme","scss","shell","solidity","sophia","sql","st","swift","tcl","twig","vb","xml","yaml'"],tables:{users:["name","id","email","phone","password"],roles:["id","name","order","created_at","updated_at","deleted_at"]}},S=function(k,K){return K.map(function(Y){return{label:Y,kind:k.languages.CompletionItemKind.Keyword,insertText:Y}})},x=function(k){return Object.keys(t.tables).map(function(K){return{label:K,kind:k.languages.CompletionItemKind.Variable,insertText:K}})},h=function(k,K){var Y=t.tables[k];return Y?Y.map(function(ne){return{label:ne,kind:K.languages.CompletionItemKind.Field,insertText:ne}}):[]};function R(B,k,K,Y,ne){var oe=k.getWordUntilPosition(K),_e={startLineNumber:K.lineNumber,endLineNumber:K.lineNumber,startColumn:oe.startColumn,endColumn:oe.endColumn},xe=Y.map(function(le){return{label:le,kind:B.languages.CompletionItemKind.Keyword,insertText:le,insertTextRules:B.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:_e}});return ne.map(function(le){xe.push(Object(N.a)(Object(N.a)({},le),{},{range:_e}))}),xe}var O=function(B){t.languages.map(function(ne){return B.languages.registerDocumentFormattingEditProvider(ne,{provideDocumentFormattingEdits:function(_e,xe,le){return Object(n.a)(r.a.mark(function me(){var de;return r.a.wrap(function(ie){for(;;)switch(ie.prev=ie.next){case 0:return de=l()(_e.getValue(),{indent_size:"2",indent_char:" ",max_preserve_newlines:"2",preserve_newlines:!0,keep_array_indentation:!0,break_chained_methods:!1,indent_scripts:"normal",brace_style:"collapse",space_before_conditional:!0,unescape_strings:!1,jslint_happy:!1,end_with_newline:!0,wrap_line_length:"0",indent_inner_html:!1,comma_first:!1,e4x:!1,indent_empty_lines:!1}),ie.abrupt("return",[{range:_e.getFullModelRange(),text:de}]);case 2:case"end":return ie.stop()}},me)}))()}}),ne});var k=u.quickKey.map(function(ne){return{label:ne.label,kind:B.languages.CompletionItemKind.Method,insertText:ne.content,insertTextRules:B.languages.CompletionItemInsertTextRule.InsertAsSnippet}}),K=f.quickKey.map(function(ne){return{label:ne.label,kind:B.languages.CompletionItemKind.Method,insertText:ne.content,insertTextRules:B.languages.CompletionItemInsertTextRule.InsertAsSnippet}}),Y=o.quickKey.map(function(ne){return{label:ne.label,kind:B.languages.CompletionItemKind.Method,insertText:ne.content,insertTextRules:B.languages.CompletionItemInsertTextRule.InsertAsSnippet}});B.languages.registerCompletionItemProvider("cpp",{triggerCharacters:["."," ","#"].concat(Object(d.a)(u.keywords),Object(d.a)(u.quickKey.map(function(ne){return ne.label}))),provideCompletionItems:function(oe,_e){var xe=oe.getValueInRange({startLineNumber:_e.lineNumber,startColumn:1,endLineNumber:_e.lineNumber,endColumn:_e.column}),le=xe.match(/cu/gim);console.log("match:",le,_e,xe,oe);var me=[],de=_e.lineNumber,ae=_e.column,ie=oe.getValueInRange({startLineNumber:de,startColumn:0,endLineNumber:de,endColumn:ae}),q=ie.trim().split(/\s+/),ue=q[q.length-1];if(ue.endsWith(".")){var Z=ue.slice(0,ue.length-1);Object.keys(t.tables).includes(Z)&&(me=Object(d.a)(h(Z,B)))}else ue==="."?me=[]:me=[].concat(Object(d.a)(x(B)),Object(d.a)(S(B,u.keywords)),Object(d.a)(k));return{suggestions:me}}}),B.languages.registerCompletionItemProvider("c",{triggerCharacters:["."," ","#"].concat(Object(d.a)(i.keywords)),provideCompletionItems:function(oe,_e){var xe=oe.getValueInRange({startLineNumber:_e.lineNumber,startColumn:1,endLineNumber:_e.lineNumber,endColumn:_e.column}),le=xe.match(/cu/gim);console.log("match:",le,_e,xe,oe);var me=[],de=_e.lineNumber,ae=_e.column,ie=oe.getValueInRange({startLineNumber:de,startColumn:0,endLineNumber:de,endColumn:ae}),q=ie.trim().split(/\s+/),ue=q[q.length-1];if(ue.endsWith(".")){var Z=ue.slice(0,ue.length-1);Object.keys(t.tables).includes(Z)&&(me=Object(d.a)(h(Z,B)))}else ue==="."?me=[]:me=[].concat(Object(d.a)(x(B)),Object(d.a)(S(B,i.keywords)));return{suggestions:me}}}),B.languages.registerCompletionItemProvider("java",{triggerCharacters:["."," "].concat(Object(d.a)(o.keywords)),provideCompletionItems:function(oe,_e){var xe=[],le=_e.lineNumber,me=_e.column,de=oe.getValueInRange({startLineNumber:le,startColumn:0,endLineNumber:le,endColumn:me}),ae=de.trim().split(/\s+/),ie=ae[ae.length-1];if(ie.endsWith(".")){var q=ie.slice(0,ie.length-1);Object.keys(t.tables).includes(q)&&(xe=Object(d.a)(h(q,B)))}else ie==="."?xe=[]:xe=[].concat(Object(d.a)(x(B)),Object(d.a)(S(B,o.keywords)),Object(d.a)(Y));return{suggestions:xe}}}),B.languages.registerCompletionItemProvider("python",{triggerCharacters:["."," "].concat(Object(d.a)(f.keywords)),provideCompletionItems:function(oe,_e){var xe=[],le=_e.lineNumber,me=_e.column,de=oe.getValueInRange({startLineNumber:le,startColumn:0,endLineNumber:le,endColumn:me}),ae=de.trim().split(/\s+/),ie=ae[ae.length-1];if(ie.endsWith(".")){var q=ie.slice(0,ie.length-1);Object.keys(t.tables).includes(q)&&(xe=Object(d.a)(h(q,B)))}else ie==="."?xe=[]:xe=[].concat(Object(d.a)(x(B)),Object(d.a)(S(B,f.keywords)),Object(d.a)(K));return{suggestions:xe}}})},g="\u8BE5\u4EFB\u52A1\u5173\u5361\u8BBE\u7F6E\u4E86\u7981\u6B62\u590D\u5236\u7C98\u8D34\uFF0C\u8BF7\u624B\u52A8\u8F93\u5165\u4EE3\u7801\u3002",_=j("LvDl"),E=j("+ua5");function T(B){return/^\d+$/.test(B)?"".concat(B,"px"):B}function L(){}var I=!1,P={"Python3.6":"python","Python2.7":"python",Dynamips:"cpp",Java:"java",Web:"php",Html:"html",Hive:"sql",Hadoop:"java",SDL:"cpp",PHP:"php",Matlab:"python",Git:"python",Python:"python","C/C++":"cpp","C++":"cpp",C:"cpp",Ruby:"ruby",Shell:"shell",JavaScript:"javascript",Perl6:"perl",Kotlin:"kotlin",Elixir:"elixir",Android:"java",JavaWeb:"java",Go:"go",Spark:"sql",MachineLearning:"python",Verilog:"xml","Verilog/VNC":"xml",Docker:"dockerfile","C#":"csharp",SQLite3:"sql",Oracle:"sql",Vhdl:"vhdl",R:"r",Swift:"swift",SQLServer:"mysql",MySQL:"mysql",Mongo:"sql",PostgreSql:"pgsql",Hbase:"powershell",Sqoop:"sql",Nasm:"cpp",Kafka:"java",Flink:"java",Sml:"javascript",OpenGL:"cpp",Perl5:"perl",Orange:"python"};function G(){var B=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],k=B;if(Array.isArray(B)){for(var K=0;K<B.length;K++){var Y=P[B[K]];if(Y)return Y}return k[0]}return P[k]||k}var W=null,H=Q.b=function(B){var k=B.width,K=k===void 0?"100%":k,Y=B.height,ne=Y===void 0?"100%":Y,oe=B.value,_e=B.language,xe=_e===void 0?"javascript":_e,le=B.style,me=le===void 0?{}:le,de=B.options,ae=de===void 0?{}:de,ie=B.overrideServices,q=ie===void 0?{}:ie,ue=B.theme,Z=ue===void 0?"vs-dark":ue,ee=B.onEditBlur,Ee=B.onSave,te=B.autoHeight,J=te===void 0?!1:te,X=B.forbidCopy,$=X===void 0?!1:X,ge=B.onChange,fe=ge===void 0?L:ge,Te=B.editorDidMount,ze=Te===void 0?L:Te,Xe=B.onFocus,Ye=Xe===void 0?L:Xe,rt=B.filename,at=rt===void 0?"educoder.txt":rt,ot=B.errorLine,Pe=B.errorContent,Se=Pe===void 0?"":Pe,Je=Object(y.a)(B,["width","height","value","language","style","options","overrideServices","theme","onEditBlur","onSave","autoHeight","forbidCopy","onChange","editorDidMount","onFocus","filename","errorLine","errorContent"]),nt=Object(w.useRef)(),We=Object(w.useRef)({}),et=Object(w.useRef)(),Me=Object(w.useRef)(!1),Ce=Object(w.useRef)(),Re=Object(w.useState)(!1),pe=Object(m.a)(Re,2),ye=pe[0],we=pe[1];function Ie(){var Bt;return nt.current&&(Bt=new p.default(function(ur){var jr=Object(M.a)(ur),en;try{for(jr.s();!(en=jr.n()).done;){var Jr=en.value;(Jr.target.offsetHeight>0||Jr.target.offsetWidth>0)&&We.current.instance.layout()}}catch(_a){jr.e(_a)}finally{jr.f()}}),Bt.observe(nt.current)),Bt}function ke(){C.b.warn(decodeURIComponent(g))}var Ve=function(){var ur=We.current.instance;if(oe!=null&&ur&&ye){var jr=ur.getModel();jr&&oe!==jr.getValue()&&(I=!0,jr.setValue(oe),ur.layout(),I=!1)}};Object(w.useEffect)(function(){et.current&&clearTimeout(et.current),et.current=setTimeout(function(){Ve()},500)},[oe,ye,We.current]),Object(w.useEffect)(function(){if(ot&&We.current&&We.current.instance){var Bt=We.current.instance;Bt.changeViewZones(function(jr){var en=document.createElement("div");en.style.padding="10px 20px",en.style.width="calc(100% - 20px)",en.className="my-error-line-wrp",en.innerHTML=Se,jr.addZone({afterLineNumber:ot||11,heightInLines:3,domNode:en})});var ur={domNode:null,getId:function(){return"my.overlay.widget"},getDomNode:function(){return this.domNode||(this.domNode=document.createElement("div"),this.domNode.innerHTML="",this.domNode.style.width="100%",this.domNode.style.padding="20px 100px",this.domNode.style.right="0px",this.domNode.style.top="50px",this.domNode.style.position="relative",this.domNode.style.color="#333"),this.domNode},getPosition:function(){return null}};Bt.addOverlayWidget(ur),Bt.revealPositionInCenter({lineNumber:20,column:1})}},[ot,We.current,ye]);function ut(){var Bt=We.current.instance;if(Bt){var ur=Bt.getSelection(),jr=We.current.pastePos||{},en=new W.Range(jr.startLineNumber||ur.endLineNumber,jr.startColumn||ur.endColumn,jr.endLineNumber||ur.endLineNumber,jr.endColumn||ur.endColumn);setTimeout(function(){Bt.executeEdits("",[{range:en,text:""}])},300)}}function ct(Bt){(window.navigator.platform.match("Mac")?Bt.metaKey:Bt.ctrlKey)&&Bt.keyCode==83&&(Bt.preventDefault(),Ee())}var Lt=function(){if(J&&We.current.instance){var ur=We.current.instance.getContentHeight();an(ur<ne?ne:ur)}else an(ne)};function Dt(Bt){var ur=document.createEvent("MouseEvents");ur.initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),Bt.dispatchEvent(ur)}function Er(Bt,ur){var jr=window.URL||window.webkitURL||window,en=new Blob([ur]),Jr=document.createElementNS("http://www.w3.org/1999/xhtml","a");Jr.href=jr.createObjectURL(en),Jr.download=Bt,Dt(Jr)}Object(w.useEffect)(function(){Lt()},[Lt]),Object(w.useEffect)(function(){nt.current&&!ye&&j.e(27).then(j.t.bind(null,"M/lh",7)).then(function(Bt){try{W=Bt,We.current.instance=W.editor.create(nt.current,{value:oe,language:G(xe),theme:Z,requireConfig:{"vs/nls":{availableLanguages:{"*":"zh-cn"}}},wordWrap:!0},q);var ur=We.current.instance;if(ze(ur,W),setTimeout(function(){Lt(),We.current.instance.addAction({id:"d123123",label:"Download File",contextMenuGroupId:"9_cutcopypaste",run:function(){Er(at||"educoder.txt",ur.getValue())}})},500),We.current.subscription=ur.onDidChangeModelContent(function(en){Me.current?clearTimeout(Ce.current):(Lt(),fe(ur.getValue(),en)),Ce.current=setTimeout(function(){Me.current=!1},500)}),window.Monaco||O(W),$&&(ur.addCommand(W.KeyMod.CtrlCmd|W.KeyMod.Shift|W.KeyCode.KEY_V,function(){return ke(),null}),ur.addCommand(W.KeyMod.CtrlCmd|W.KeyCode.KEY_C,function(){return ke(),null})),window.Monaco=W,ee&&ur.onDidBlurEditorWidget(function(){ee(ur.getValue())}),Ye&&ur.onDidFocusEditorText(function(){Ye(ur.getValue())}),$){ur.addCommand(W.KeyMod.CtrlCmd|W.KeyCode.KEY_V,function(){return ke(),null}),ur.onDidPaste(function(en){We.current.pastePos=en});try{window.addEventListener("paste",ut)}catch(en){}}var jr=Ie();return we(!0),function(){var en=We.current.instance;en.dispose();var Jr=en.getModel();Jr&&Jr.dispose(),We.current.subscription&&We.current.subscription.dispose(),$&&window.removeEventListener("paste",ut),jr.unobserve(nt.current)}}catch(en){}})},[]),Object(w.useEffect)(function(){var Bt=We.current.instance;if(Bt&&ye)return document.addEventListener("keydown",ct,!1),function(){document.removeEventListener("keydown",ct)}},[Ee,ye]),Object(w.useEffect)(function(){var Bt=We.current.instance;if(Bt&&ye){var ur=G(xe);W.editor.setModelLanguage(Bt.getModel(),ur),console.log("language:",xe,Bt.getModel(),ur)}},[xe,ye]),Object(w.useEffect)(function(){var Bt=We.current.instance;Bt&&ye&&W.editor.setTheme(Z)},[Z,ye]),Object(w.useEffect)(function(){var Bt=We.current.instance;Bt&&ye&&(Bt.updateOptions(Object(N.a)({},ae)),setTimeout(function(){Bt.getModel().updateOptions(Object(N.a)({},ae))},200))},[JSON.stringify(ae),ye]),Object(w.useEffect)(function(){var Bt=We.current.instance;Bt&&ye&&Bt.layout()},[K,ne,ye]);var rr=Object(w.useState)(T(K)),xt=Object(m.a)(rr,2),kr=xt[0],Mr=xt[1],Ur=Object(w.useState)(T(ne)),ln=Object(m.a)(Ur,2),Sr=ln[0],an=ln[1],qr=Object(N.a)(Object(N.a)({},me),{},{width:kr,height:Sr});return b.a.createElement("div",{className:"my-monaco-editor",ref:nt,style:qr})};function z(B){var k=B.width,K=k===void 0?"100%":k,Y=B.height,ne=Y===void 0?"100%":Y,oe=B.original,_e=B.modified,xe=B.language,le=B.options,me=le===void 0?{}:le,de=Object(w.useRef)(),ae=Object(w.useState)(null),ie=Object(m.a)(ae,2),q=ie[0],ue=ie[1];function Z(J){var X;return de.current&&(X=new p.default(function($){var ge=Object(M.a)($),fe;try{for(ge.s();!(fe=ge.n()).done;){var Te=fe.value;(Te.target.offsetHeight>0||Te.target.offsetWidth>0)&&J.layout()}}catch(ze){ge.e(ze)}finally{ge.f()}}),X.observe(de.current)),X}Object(w.useEffect)(function(){de.current&&j.e(27).then(j.t.bind(null,"M/lh",7)).then(function(J){W=J;var X=W.editor.createDiffEditor(de.current,Object(N.a)(Object(N.a)({enableSplitViewResizing:!1,scrollBeyondLastLine:!1,roundedSelection:!1,renderIndicators:!1,useShadows:!1,horizontal:"hidden",lineNumbers:"off",ignoreTrimWhitespace:!1,followsCaret:!0,ignoreCharChanges:!0,minimap:{enabled:!1},readOnly:!0},me),{},{wordWrap:!0}));ue(X);var $=Z(X);return function(){X.dispose();var ge=X.getModel();ge&&ge.dispose(),$.unobserve(de.current)}})},[]),Object(w.useEffect)(function(){q&&q.setModel({original:W.editor.createModel(oe,xe),modified:W.editor.createModel(_e,xe)})},[oe,_e,xe,q]);var ee=T(K),Ee=T(ne),te={width:ee,height:Ee};return b.a.createElement("div",{className:"my-diff-editor",ref:de,style:te})}},ZpRC:function(F,Q,j){"use strict";function N(n){return typeof n=="object"&&n!=null&&n.nodeType===1}function v(n,c){return(!c||n!=="hidden")&&n!=="visible"&&n!=="clip"}function C(n,c){if(n.clientHeight<n.scrollHeight||n.clientWidth<n.scrollWidth){var r=getComputedStyle(n,null);return v(r.overflowY,c)||v(r.overflowX,c)||function(i){var o=function(u){if(!u.ownerDocument||!u.ownerDocument.defaultView)return null;try{return u.ownerDocument.defaultView.frameElement}catch(f){return null}}(i);return!!o&&(o.clientHeight<i.scrollHeight||o.clientWidth<i.scrollWidth)}(n)}return!1}function M(n,c,r,i,o,u,f,s){return u<n&&f>c||u>n&&f<c?0:u<=n&&s<=r||f>=c&&s>=r?u-n-i:f>c&&s<r||u<n&&s>r?f-c+o:0}var m=function(n,c){var r=window,i=c.scrollMode,o=c.block,u=c.inline,f=c.boundary,s=c.skipOverflowHiddenElements,l=typeof f=="function"?f:function(X){return X!==f};if(!N(n))throw new TypeError("Invalid target");for(var t=document.scrollingElement||document.documentElement,S=[],x=n;N(x)&&l(x);){if((x=x.parentElement)===t){S.push(x);break}x!=null&&x===document.body&&C(x)&&!C(document.documentElement)||x!=null&&C(x,s)&&S.push(x)}for(var h=r.visualViewport?r.visualViewport.width:innerWidth,R=r.visualViewport?r.visualViewport.height:innerHeight,O=window.scrollX||pageXOffset,g=window.scrollY||pageYOffset,_=n.getBoundingClientRect(),E=_.height,T=_.width,L=_.top,I=_.right,P=_.bottom,G=_.left,W=o==="start"||o==="nearest"?L:o==="end"?P:L+E/2,H=u==="center"?G+T/2:u==="end"?I:G,z=[],B=0;B<S.length;B++){var k=S[B],K=k.getBoundingClientRect(),Y=K.height,ne=K.width,oe=K.top,_e=K.right,xe=K.bottom,le=K.left;if(i==="if-needed"&&L>=0&&G>=0&&P<=R&&I<=h&&L>=oe&&P<=xe&&G>=le&&I<=_e)return z;var me=getComputedStyle(k),de=parseInt(me.borderLeftWidth,10),ae=parseInt(me.borderTopWidth,10),ie=parseInt(me.borderRightWidth,10),q=parseInt(me.borderBottomWidth,10),ue=0,Z=0,ee="offsetWidth"in k?k.offsetWidth-k.clientWidth-de-ie:0,Ee="offsetHeight"in k?k.offsetHeight-k.clientHeight-ae-q:0;if(t===k)ue=o==="start"?W:o==="end"?W-R:o==="nearest"?M(g,g+R,R,ae,q,g+W,g+W+E,E):W-R/2,Z=u==="start"?H:u==="center"?H-h/2:u==="end"?H-h:M(O,O+h,h,de,ie,O+H,O+H+T,T),ue=Math.max(0,ue+g),Z=Math.max(0,Z+O);else{ue=o==="start"?W-oe-ae:o==="end"?W-xe+q+Ee:o==="nearest"?M(oe,xe,Y,ae,q+Ee,W,W+E,E):W-(oe+Y/2)+Ee/2,Z=u==="start"?H-le-de:u==="center"?H-(le+ne/2)+ee/2:u==="end"?H-_e+ie+ee:M(le,_e,ne,de,ie+ee,H,H+T,T);var te=k.scrollLeft,J=k.scrollTop;W+=J-(ue=Math.max(0,Math.min(J+ue,k.scrollHeight-Y+Ee))),H+=te-(Z=Math.max(0,Math.min(te+Z,k.scrollWidth-ne+ee)))}z.push({el:k,top:ue,left:Z})}return z};function y(n){return n===Object(n)&&Object.keys(n).length!==0}function w(n,c){c===void 0&&(c="auto");var r="scrollBehavior"in document.body.style;n.forEach(function(i){var o=i.el,u=i.top,f=i.left;o.scroll&&r?o.scroll({top:u,left:f,behavior:c}):(o.scrollTop=u,o.scrollLeft=f)})}function b(n){return n===!1?{block:"end",inline:"nearest"}:y(n)?n:{block:"start",inline:"nearest"}}function p(n,c){var r=!n.ownerDocument.documentElement.contains(n);if(y(c)&&typeof c.behavior=="function")return c.behavior(r?[]:m(n,c));if(r)return;var i=b(c);return w(m(n,i),i.behavior)}var d=Q.a=p},Zss7:function(F,Q,j){var N;(function(v){var C=/^\s+/,M=/\s+$/,m=0,y=v.round,w=v.min,b=v.max,p=v.random;function d(q,ue){if(q=q||"",ue=ue||{},q instanceof d)return q;if(!(this instanceof d))return new d(q,ue);var Z=n(q);this._originalInput=q,this._r=Z.r,this._g=Z.g,this._b=Z.b,this._a=Z.a,this._roundA=y(100*this._a)/100,this._format=ue.format||Z.format,this._gradientType=ue.gradientType,this._r<1&&(this._r=y(this._r)),this._g<1&&(this._g=y(this._g)),this._b<1&&(this._b=y(this._b)),this._ok=Z.ok,this._tc_id=m++}d.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var q=this.toRgb();return(q.r*299+q.g*587+q.b*114)/1e3},getLuminance:function(){var q=this.toRgb(),ue,Z,ee,Ee,te,J;return ue=q.r/255,Z=q.g/255,ee=q.b/255,ue<=.03928?Ee=ue/12.92:Ee=v.pow((ue+.055)/1.055,2.4),Z<=.03928?te=Z/12.92:te=v.pow((Z+.055)/1.055,2.4),ee<=.03928?J=ee/12.92:J=v.pow((ee+.055)/1.055,2.4),.2126*Ee+.7152*te+.0722*J},setAlpha:function(q){return this._a=z(q),this._roundA=y(100*this._a)/100,this},toHsv:function(){var q=o(this._r,this._g,this._b);return{h:q.h*360,s:q.s,v:q.v,a:this._a}},toHsvString:function(){var q=o(this._r,this._g,this._b),ue=y(q.h*360),Z=y(q.s*100),ee=y(q.v*100);return this._a==1?"hsv("+ue+", "+Z+"%, "+ee+"%)":"hsva("+ue+", "+Z+"%, "+ee+"%, "+this._roundA+")"},toHsl:function(){var q=r(this._r,this._g,this._b);return{h:q.h*360,s:q.s,l:q.l,a:this._a}},toHslString:function(){var q=r(this._r,this._g,this._b),ue=y(q.h*360),Z=y(q.s*100),ee=y(q.l*100);return this._a==1?"hsl("+ue+", "+Z+"%, "+ee+"%)":"hsla("+ue+", "+Z+"%, "+ee+"%, "+this._roundA+")"},toHex:function(q){return f(this._r,this._g,this._b,q)},toHexString:function(q){return"#"+this.toHex(q)},toHex8:function(q){return s(this._r,this._g,this._b,this._a,q)},toHex8String:function(q){return"#"+this.toHex8(q)},toRgb:function(){return{r:y(this._r),g:y(this._g),b:y(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+y(this._r)+", "+y(this._g)+", "+y(this._b)+")":"rgba("+y(this._r)+", "+y(this._g)+", "+y(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:y(B(this._r,255)*100)+"%",g:y(B(this._g,255)*100)+"%",b:y(B(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+y(B(this._r,255)*100)+"%, "+y(B(this._g,255)*100)+"%, "+y(B(this._b,255)*100)+"%)":"rgba("+y(B(this._r,255)*100)+"%, "+y(B(this._g,255)*100)+"%, "+y(B(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:W[f(this._r,this._g,this._b,!0)]||!1},toFilter:function(q){var ue="#"+l(this._r,this._g,this._b,this._a),Z=ue,ee=this._gradientType?"GradientType = 1, ":"";if(q){var Ee=d(q);Z="#"+l(Ee._r,Ee._g,Ee._b,Ee._a)}return"progid:DXImageTransform.Microsoft.gradient("+ee+"startColorstr="+ue+",endColorstr="+Z+")"},toString:function(q){var ue=!!q;q=q||this._format;var Z=!1,ee=this._a<1&&this._a>=0,Ee=!ue&&ee&&(q==="hex"||q==="hex6"||q==="hex3"||q==="hex4"||q==="hex8"||q==="name");return Ee?q==="name"&&this._a===0?this.toName():this.toRgbString():(q==="rgb"&&(Z=this.toRgbString()),q==="prgb"&&(Z=this.toPercentageRgbString()),(q==="hex"||q==="hex6")&&(Z=this.toHexString()),q==="hex3"&&(Z=this.toHexString(!0)),q==="hex4"&&(Z=this.toHex8String(!0)),q==="hex8"&&(Z=this.toHex8String()),q==="name"&&(Z=this.toName()),q==="hsl"&&(Z=this.toHslString()),q==="hsv"&&(Z=this.toHsvString()),Z||this.toHexString())},clone:function(){return d(this.toString())},_applyModification:function(q,ue){var Z=q.apply(null,[this].concat([].slice.call(ue)));return this._r=Z._r,this._g=Z._g,this._b=Z._b,this.setAlpha(Z._a),this},lighten:function(){return this._applyModification(h,arguments)},brighten:function(){return this._applyModification(R,arguments)},darken:function(){return this._applyModification(O,arguments)},desaturate:function(){return this._applyModification(t,arguments)},saturate:function(){return this._applyModification(S,arguments)},greyscale:function(){return this._applyModification(x,arguments)},spin:function(){return this._applyModification(g,arguments)},_applyCombination:function(q,ue){return q.apply(null,[this].concat([].slice.call(ue)))},analogous:function(){return this._applyCombination(I,arguments)},complement:function(){return this._applyCombination(_,arguments)},monochromatic:function(){return this._applyCombination(P,arguments)},splitcomplement:function(){return this._applyCombination(L,arguments)},triad:function(){return this._applyCombination(E,arguments)},tetrad:function(){return this._applyCombination(T,arguments)}},d.fromRatio=function(q,ue){if(typeof q=="object"){var Z={};for(var ee in q)q.hasOwnProperty(ee)&&(ee==="a"?Z[ee]=q[ee]:Z[ee]=_e(q[ee]));q=Z}return d(q,ue)};function n(q){var ue={r:0,g:0,b:0},Z=1,ee=null,Ee=null,te=null,J=!1,X=!1;return typeof q=="string"&&(q=ae(q)),typeof q=="object"&&(de(q.r)&&de(q.g)&&de(q.b)?(ue=c(q.r,q.g,q.b),J=!0,X=String(q.r).substr(-1)==="%"?"prgb":"rgb"):de(q.h)&&de(q.s)&&de(q.v)?(ee=_e(q.s),Ee=_e(q.v),ue=u(q.h,ee,Ee),J=!0,X="hsv"):de(q.h)&&de(q.s)&&de(q.l)&&(ee=_e(q.s),te=_e(q.l),ue=i(q.h,ee,te),J=!0,X="hsl"),q.hasOwnProperty("a")&&(Z=q.a)),Z=z(Z),{ok:J,format:q.format||X,r:w(255,b(ue.r,0)),g:w(255,b(ue.g,0)),b:w(255,b(ue.b,0)),a:Z}}function c(q,ue,Z){return{r:B(q,255)*255,g:B(ue,255)*255,b:B(Z,255)*255}}function r(q,ue,Z){q=B(q,255),ue=B(ue,255),Z=B(Z,255);var ee=b(q,ue,Z),Ee=w(q,ue,Z),te,J,X=(ee+Ee)/2;if(ee==Ee)te=J=0;else{var $=ee-Ee;J=X>.5?$/(2-ee-Ee):$/(ee+Ee);switch(ee){case q:te=(ue-Z)/$+(ue<Z?6:0);break;case ue:te=(Z-q)/$+2;break;case Z:te=(q-ue)/$+4;break}te/=6}return{h:te,s:J,l:X}}function i(q,ue,Z){var ee,Ee,te;q=B(q,360),ue=B(ue,100),Z=B(Z,100);function J(ge,fe,Te){return Te<0&&(Te+=1),Te>1&&(Te-=1),Te<1/6?ge+(fe-ge)*6*Te:Te<1/2?fe:Te<2/3?ge+(fe-ge)*(2/3-Te)*6:ge}if(ue===0)ee=Ee=te=Z;else{var X=Z<.5?Z*(1+ue):Z+ue-Z*ue,$=2*Z-X;ee=J($,X,q+1/3),Ee=J($,X,q),te=J($,X,q-1/3)}return{r:ee*255,g:Ee*255,b:te*255}}function o(q,ue,Z){q=B(q,255),ue=B(ue,255),Z=B(Z,255);var ee=b(q,ue,Z),Ee=w(q,ue,Z),te,J,X=ee,$=ee-Ee;if(J=ee===0?0:$/ee,ee==Ee)te=0;else{switch(ee){case q:te=(ue-Z)/$+(ue<Z?6:0);break;case ue:te=(Z-q)/$+2;break;case Z:te=(q-ue)/$+4;break}te/=6}return{h:te,s:J,v:X}}function u(q,ue,Z){q=B(q,360)*6,ue=B(ue,100),Z=B(Z,100);var ee=v.floor(q),Ee=q-ee,te=Z*(1-ue),J=Z*(1-Ee*ue),X=Z*(1-(1-Ee)*ue),$=ee%6,ge=[Z,J,te,te,X,Z][$],fe=[X,Z,Z,J,te,te][$],Te=[te,te,X,Z,Z,J][$];return{r:ge*255,g:fe*255,b:Te*255}}function f(q,ue,Z,ee){var Ee=[oe(y(q).toString(16)),oe(y(ue).toString(16)),oe(y(Z).toString(16))];return ee&&Ee[0].charAt(0)==Ee[0].charAt(1)&&Ee[1].charAt(0)==Ee[1].charAt(1)&&Ee[2].charAt(0)==Ee[2].charAt(1)?Ee[0].charAt(0)+Ee[1].charAt(0)+Ee[2].charAt(0):Ee.join("")}function s(q,ue,Z,ee,Ee){var te=[oe(y(q).toString(16)),oe(y(ue).toString(16)),oe(y(Z).toString(16)),oe(xe(ee))];return Ee&&te[0].charAt(0)==te[0].charAt(1)&&te[1].charAt(0)==te[1].charAt(1)&&te[2].charAt(0)==te[2].charAt(1)&&te[3].charAt(0)==te[3].charAt(1)?te[0].charAt(0)+te[1].charAt(0)+te[2].charAt(0)+te[3].charAt(0):te.join("")}function l(q,ue,Z,ee){var Ee=[oe(xe(ee)),oe(y(q).toString(16)),oe(y(ue).toString(16)),oe(y(Z).toString(16))];return Ee.join("")}d.equals=function(q,ue){return!q||!ue?!1:d(q).toRgbString()==d(ue).toRgbString()},d.random=function(){return d.fromRatio({r:p(),g:p(),b:p()})};function t(q,ue){ue=ue===0?0:ue||10;var Z=d(q).toHsl();return Z.s-=ue/100,Z.s=k(Z.s),d(Z)}function S(q,ue){ue=ue===0?0:ue||10;var Z=d(q).toHsl();return Z.s+=ue/100,Z.s=k(Z.s),d(Z)}function x(q){return d(q).desaturate(100)}function h(q,ue){ue=ue===0?0:ue||10;var Z=d(q).toHsl();return Z.l+=ue/100,Z.l=k(Z.l),d(Z)}function R(q,ue){ue=ue===0?0:ue||10;var Z=d(q).toRgb();return Z.r=b(0,w(255,Z.r-y(255*-(ue/100)))),Z.g=b(0,w(255,Z.g-y(255*-(ue/100)))),Z.b=b(0,w(255,Z.b-y(255*-(ue/100)))),d(Z)}function O(q,ue){ue=ue===0?0:ue||10;var Z=d(q).toHsl();return Z.l-=ue/100,Z.l=k(Z.l),d(Z)}function g(q,ue){var Z=d(q).toHsl(),ee=(Z.h+ue)%360;return Z.h=ee<0?360+ee:ee,d(Z)}function _(q){var ue=d(q).toHsl();return ue.h=(ue.h+180)%360,d(ue)}function E(q){var ue=d(q).toHsl(),Z=ue.h;return[d(q),d({h:(Z+120)%360,s:ue.s,l:ue.l}),d({h:(Z+240)%360,s:ue.s,l:ue.l})]}function T(q){var ue=d(q).toHsl(),Z=ue.h;return[d(q),d({h:(Z+90)%360,s:ue.s,l:ue.l}),d({h:(Z+180)%360,s:ue.s,l:ue.l}),d({h:(Z+270)%360,s:ue.s,l:ue.l})]}function L(q){var ue=d(q).toHsl(),Z=ue.h;return[d(q),d({h:(Z+72)%360,s:ue.s,l:ue.l}),d({h:(Z+216)%360,s:ue.s,l:ue.l})]}function I(q,ue,Z){ue=ue||6,Z=Z||30;var ee=d(q).toHsl(),Ee=360/Z,te=[d(q)];for(ee.h=(ee.h-(Ee*ue>>1)+720)%360;--ue;)ee.h=(ee.h+Ee)%360,te.push(d(ee));return te}function P(q,ue){ue=ue||6;for(var Z=d(q).toHsv(),ee=Z.h,Ee=Z.s,te=Z.v,J=[],X=1/ue;ue--;)J.push(d({h:ee,s:Ee,v:te})),te=(te+X)%1;return J}d.mix=function(q,ue,Z){Z=Z===0?0:Z||50;var ee=d(q).toRgb(),Ee=d(ue).toRgb(),te=Z/100,J={r:(Ee.r-ee.r)*te+ee.r,g:(Ee.g-ee.g)*te+ee.g,b:(Ee.b-ee.b)*te+ee.b,a:(Ee.a-ee.a)*te+ee.a};return d(J)},d.readability=function(q,ue){var Z=d(q),ee=d(ue);return(v.max(Z.getLuminance(),ee.getLuminance())+.05)/(v.min(Z.getLuminance(),ee.getLuminance())+.05)},d.isReadable=function(q,ue,Z){var ee=d.readability(q,ue),Ee,te;te=!1,Ee=ie(Z);switch(Ee.level+Ee.size){case"AAsmall":case"AAAlarge":te=ee>=4.5;break;case"AAlarge":te=ee>=3;break;case"AAAsmall":te=ee>=7;break}return te},d.mostReadable=function(q,ue,Z){var ee=null,Ee=0,te,J,X,$;Z=Z||{},J=Z.includeFallbackColors,X=Z.level,$=Z.size;for(var ge=0;ge<ue.length;ge++)te=d.readability(q,ue[ge]),te>Ee&&(Ee=te,ee=d(ue[ge]));return d.isReadable(q,ee,{level:X,size:$})||!J?ee:(Z.includeFallbackColors=!1,d.mostReadable(q,["#fff","#000"],Z))};var G=d.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},W=d.hexNames=H(G);function H(q){var ue={};for(var Z in q)q.hasOwnProperty(Z)&&(ue[q[Z]]=Z);return ue}function z(q){return q=parseFloat(q),(isNaN(q)||q<0||q>1)&&(q=1),q}function B(q,ue){Y(q)&&(q="100%");var Z=ne(q);return q=w(ue,b(0,parseFloat(q))),Z&&(q=parseInt(q*ue,10)/100),v.abs(q-ue)<1e-6?1:q%ue/parseFloat(ue)}function k(q){return w(1,b(0,q))}function K(q){return parseInt(q,16)}function Y(q){return typeof q=="string"&&q.indexOf(".")!=-1&&parseFloat(q)===1}function ne(q){return typeof q=="string"&&q.indexOf("%")!=-1}function oe(q){return q.length==1?"0"+q:""+q}function _e(q){return q<=1&&(q=q*100+"%"),q}function xe(q){return v.round(parseFloat(q)*255).toString(16)}function le(q){return K(q)/255}var me=function(){var q="[-\\+]?\\d+%?",ue="[-\\+]?\\d*\\.\\d+%?",Z="(?:"+ue+")|(?:"+q+")",ee="[\\s|\\(]+("+Z+")[,|\\s]+("+Z+")[,|\\s]+("+Z+")\\s*\\)?",Ee="[\\s|\\(]+("+Z+")[,|\\s]+("+Z+")[,|\\s]+("+Z+")[,|\\s]+("+Z+")\\s*\\)?";return{CSS_UNIT:new RegExp(Z),rgb:new RegExp("rgb"+ee),rgba:new RegExp("rgba"+Ee),hsl:new RegExp("hsl"+ee),hsla:new RegExp("hsla"+Ee),hsv:new RegExp("hsv"+ee),hsva:new RegExp("hsva"+Ee),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function de(q){return!!me.CSS_UNIT.exec(q)}function ae(q){q=q.replace(C,"").replace(M,"").toLowerCase();var ue=!1;if(G[q])q=G[q],ue=!0;else if(q=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var Z;return(Z=me.rgb.exec(q))?{r:Z[1],g:Z[2],b:Z[3]}:(Z=me.rgba.exec(q))?{r:Z[1],g:Z[2],b:Z[3],a:Z[4]}:(Z=me.hsl.exec(q))?{h:Z[1],s:Z[2],l:Z[3]}:(Z=me.hsla.exec(q))?{h:Z[1],s:Z[2],l:Z[3],a:Z[4]}:(Z=me.hsv.exec(q))?{h:Z[1],s:Z[2],v:Z[3]}:(Z=me.hsva.exec(q))?{h:Z[1],s:Z[2],v:Z[3],a:Z[4]}:(Z=me.hex8.exec(q))?{r:K(Z[1]),g:K(Z[2]),b:K(Z[3]),a:le(Z[4]),format:ue?"name":"hex8"}:(Z=me.hex6.exec(q))?{r:K(Z[1]),g:K(Z[2]),b:K(Z[3]),format:ue?"name":"hex"}:(Z=me.hex4.exec(q))?{r:K(Z[1]+""+Z[1]),g:K(Z[2]+""+Z[2]),b:K(Z[3]+""+Z[3]),a:le(Z[4]+""+Z[4]),format:ue?"name":"hex8"}:(Z=me.hex3.exec(q))?{r:K(Z[1]+""+Z[1]),g:K(Z[2]+""+Z[2]),b:K(Z[3]+""+Z[3]),format:ue?"name":"hex"}:!1}function ie(q){var ue,Z;return q=q||{level:"AA",size:"small"},ue=(q.level||"AA").toUpperCase(),Z=(q.size||"small").toLowerCase(),ue!=="AA"&&ue!=="AAA"&&(ue="AA"),Z!=="small"&&Z!=="large"&&(Z="small"),{level:ue,size:Z}}F.exports?F.exports=d:!(N=function(){return d}.call(Q,j,Q,F),N!==void 0&&(F.exports=N))})(Math)},bQjk:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return function(v){var C=N,M=C.lib,m=M.CipherParams,y=C.enc,w=y.Hex,b=C.format,p=b.Hex={stringify:function(d){return d.ciphertext.toString(w)},parse:function(d){var n=w.parse(d);return m.create({ciphertext:n})}}}(),N.format.Hex})},bT9E:function(F,Q,j){"use strict";j.d(Q,"a",function(){return v});var N=j("VTBJ");function v(C,M){var m=Object(N.a)({},C);return Array.isArray(M)&&M.forEach(function(y){delete m[y]}),m}},biw7:function(F,Q,j){"use strict";var N=j("cDcd"),v=j.n(N),C=N.createContext(null);Q.a=C},c5Ni:function(F,Q,j){},cv67:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(v){var C=N,M=C.lib,m=M.WordArray,y=M.Hasher,w=C.algo,b=[];(function(){for(var i=0;i<64;i++)b[i]=v.abs(v.sin(i+1))*4294967296|0})();var p=w.MD5=y.extend({_doReset:function(){this._hash=new m.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(i,o){for(var u=0;u<16;u++){var f=o+u,s=i[f];i[f]=(s<<8|s>>>24)&16711935|(s<<24|s>>>8)&4278255360}var l=this._hash.words,t=i[o+0],S=i[o+1],x=i[o+2],h=i[o+3],R=i[o+4],O=i[o+5],g=i[o+6],_=i[o+7],E=i[o+8],T=i[o+9],L=i[o+10],I=i[o+11],P=i[o+12],G=i[o+13],W=i[o+14],H=i[o+15],z=l[0],B=l[1],k=l[2],K=l[3];z=d(z,B,k,K,t,7,b[0]),K=d(K,z,B,k,S,12,b[1]),k=d(k,K,z,B,x,17,b[2]),B=d(B,k,K,z,h,22,b[3]),z=d(z,B,k,K,R,7,b[4]),K=d(K,z,B,k,O,12,b[5]),k=d(k,K,z,B,g,17,b[6]),B=d(B,k,K,z,_,22,b[7]),z=d(z,B,k,K,E,7,b[8]),K=d(K,z,B,k,T,12,b[9]),k=d(k,K,z,B,L,17,b[10]),B=d(B,k,K,z,I,22,b[11]),z=d(z,B,k,K,P,7,b[12]),K=d(K,z,B,k,G,12,b[13]),k=d(k,K,z,B,W,17,b[14]),B=d(B,k,K,z,H,22,b[15]),z=n(z,B,k,K,S,5,b[16]),K=n(K,z,B,k,g,9,b[17]),k=n(k,K,z,B,I,14,b[18]),B=n(B,k,K,z,t,20,b[19]),z=n(z,B,k,K,O,5,b[20]),K=n(K,z,B,k,L,9,b[21]),k=n(k,K,z,B,H,14,b[22]),B=n(B,k,K,z,R,20,b[23]),z=n(z,B,k,K,T,5,b[24]),K=n(K,z,B,k,W,9,b[25]),k=n(k,K,z,B,h,14,b[26]),B=n(B,k,K,z,E,20,b[27]),z=n(z,B,k,K,G,5,b[28]),K=n(K,z,B,k,x,9,b[29]),k=n(k,K,z,B,_,14,b[30]),B=n(B,k,K,z,P,20,b[31]),z=c(z,B,k,K,O,4,b[32]),K=c(K,z,B,k,E,11,b[33]),k=c(k,K,z,B,I,16,b[34]),B=c(B,k,K,z,W,23,b[35]),z=c(z,B,k,K,S,4,b[36]),K=c(K,z,B,k,R,11,b[37]),k=c(k,K,z,B,_,16,b[38]),B=c(B,k,K,z,L,23,b[39]),z=c(z,B,k,K,G,4,b[40]),K=c(K,z,B,k,t,11,b[41]),k=c(k,K,z,B,h,16,b[42]),B=c(B,k,K,z,g,23,b[43]),z=c(z,B,k,K,T,4,b[44]),K=c(K,z,B,k,P,11,b[45]),k=c(k,K,z,B,H,16,b[46]),B=c(B,k,K,z,x,23,b[47]),z=r(z,B,k,K,t,6,b[48]),K=r(K,z,B,k,_,10,b[49]),k=r(k,K,z,B,W,15,b[50]),B=r(B,k,K,z,O,21,b[51]),z=r(z,B,k,K,P,6,b[52]),K=r(K,z,B,k,h,10,b[53]),k=r(k,K,z,B,L,15,b[54]),B=r(B,k,K,z,S,21,b[55]),z=r(z,B,k,K,E,6,b[56]),K=r(K,z,B,k,H,10,b[57]),k=r(k,K,z,B,g,15,b[58]),B=r(B,k,K,z,G,21,b[59]),z=r(z,B,k,K,R,6,b[60]),K=r(K,z,B,k,I,10,b[61]),k=r(k,K,z,B,x,15,b[62]),B=r(B,k,K,z,T,21,b[63]),l[0]=l[0]+z|0,l[1]=l[1]+B|0,l[2]=l[2]+k|0,l[3]=l[3]+K|0},_doFinalize:function(){var i=this._data,o=i.words,u=this._nDataBytes*8,f=i.sigBytes*8;o[f>>>5]|=128<<24-f%32;var s=v.floor(u/4294967296),l=u;o[(f+64>>>9<<4)+15]=(s<<8|s>>>24)&16711935|(s<<24|s>>>8)&4278255360,o[(f+64>>>9<<4)+14]=(l<<8|l>>>24)&16711935|(l<<24|l>>>8)&4278255360,i.sigBytes=(o.length+1)*4,this._process();for(var t=this._hash,S=t.words,x=0;x<4;x++){var h=S[x];S[x]=(h<<8|h>>>24)&16711935|(h<<24|h>>>8)&4278255360}return t},clone:function(){var i=y.clone.call(this);return i._hash=this._hash.clone(),i}});function d(i,o,u,f,s,l,t){var S=i+(o&u|~o&f)+s+t;return(S<<l|S>>>32-l)+o}function n(i,o,u,f,s,l,t){var S=i+(o&f|u&~f)+s+t;return(S<<l|S>>>32-l)+o}function c(i,o,u,f,s,l,t){var S=i+(o^u^f)+s+t;return(S<<l|S>>>32-l)+o}function r(i,o,u,f,s,l,t){var S=i+(u^(o|~f))+s+t;return(S<<l|S>>>32-l)+o}C.MD5=y._createHelper(p),C.HmacMD5=y._createHmacHelper(p)}(Math),N.MD5})},dejd:function(F,Q,j){},dmUQ:function(F,Q,j){"use strict";var N=j("Ff2n"),v=j("rePB"),C=j("1OyB"),M=j("vuIU"),m=j("Ji7U"),y=j("md7G"),w=j("foSv"),b=j("cDcd"),p=j.n(b),d=j("TSYQ"),n=j.n(d),c=j("4IlW");function r(E,T){var L=Object.keys(E);if(Object.getOwnPropertySymbols){var I=Object.getOwnPropertySymbols(E);T&&(I=I.filter(function(P){return Object.getOwnPropertyDescriptor(E,P).enumerable})),L.push.apply(L,I)}return L}function i(E){for(var T=1;T<arguments.length;T++){var L=arguments[T]!=null?arguments[T]:{};T%2?r(Object(L),!0).forEach(function(I){Object(v.a)(E,I,L[I])}):Object.getOwnPropertyDescriptors?Object.defineProperties(E,Object.getOwnPropertyDescriptors(L)):r(Object(L)).forEach(function(I){Object.defineProperty(E,I,Object.getOwnPropertyDescriptor(L,I))})}return E}function o(E){var T=u();return function(){var I=Object(w.a)(E),P;if(T){var G=Object(w.a)(this).constructor;P=Reflect.construct(I,arguments,G)}else P=I.apply(this,arguments);return Object(y.a)(this,P)}}function u(){if(typeof Reflect=="undefined"||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch(E){return!1}}function f(){}function s(E){E.preventDefault()}var l=function(T){return T.replace(/[^\w.-]+/g,"")},t=200,S=600,x=Number.MAX_SAFE_INTEGER||Math.pow(2,53)-1,h=function(T){return T!=null},R=function(T,L){return L===T||typeof L=="number"&&typeof T=="number"&&isNaN(L)&&isNaN(T)},O=function(E){Object(m.a)(L,E);var T=o(L);function L(I){var P;Object(C.a)(this,L),P=T.call(this,I),P.onKeyDown=function(H){var z=P.props,B=z.onKeyDown,k=z.onPressEnter;if(H.keyCode===c.a.UP){var K=P.getRatio(H);P.up(H,K,null),P.stop()}else if(H.keyCode===c.a.DOWN){var Y=P.getRatio(H);P.down(H,Y,null),P.stop()}else H.keyCode===c.a.ENTER&&k&&k(H);if(P.recordCursorPosition(),P.lastKeyCode=H.keyCode,B){for(var ne=arguments.length,oe=new Array(ne>1?ne-1:0),_e=1;_e<ne;_e++)oe[_e-1]=arguments[_e];B.apply(void 0,[H].concat(oe))}},P.onKeyUp=function(H){var z=P.props.onKeyUp;if(P.stop(),P.recordCursorPosition(),z){for(var B=arguments.length,k=new Array(B>1?B-1:0),K=1;K<B;K++)k[K-1]=arguments[K];z.apply(void 0,[H].concat(k))}},P.onChange=function(H){var z=P.props.onChange;P.state.focused&&(P.inputting=!0),P.rawInput=P.props.parser(P.getValueFromEvent(H)),P.setState({inputValue:P.rawInput}),z(P.toNumber(P.rawInput))},P.onMouseUp=function(){var H=P.props.onMouseUp;P.recordCursorPosition(),H&&H.apply(void 0,arguments)},P.onFocus=function(){var H;P.setState({focused:!0}),(H=P.props).onFocus.apply(H,arguments)},P.onBlur=function(){var H=P.props.onBlur;P.inputting=!1,P.setState({focused:!1});var z=P.getCurrentValidValue(P.state.inputValue),B=P.setValue(z,f);if(H){var k=P.input.value,K=P.getInputDisplayValue({focus:!1,value:B});P.input.value=K&&Number(K),H.apply(void 0,arguments),P.input.value=k}},P.getRatio=function(H){var z=1;return H.metaKey||H.ctrlKey?z=.1:H.shiftKey&&(z=10),z},P.getFullNum=function(H){return isNaN(H)?H:/e/i.test(String(H))?Number(H).toFixed(18).replace(/\.?0+$/,""):H},P.getPrecision=function(H){if(h(P.props.precision))return P.props.precision;var z=String(H);if(z.indexOf("e-")>=0)return parseInt(z.slice(z.indexOf("e-")+2),10);var B=0;return z.indexOf(".")>=0&&(B=z.length-z.indexOf(".")-1),B},P.getInputDisplayValue=function(H){var z=H||P.state,B=z.focused,k=z.inputValue,K=z.value,Y;B?Y=k:Y=P.toPrecisionAsStep(K),Y==null&&(Y="");var ne=P.formatWrapper(Y);return h(P.props.decimalSeparator)&&(ne=ne.toString().replace(".",P.props.decimalSeparator)),ne},P.recordCursorPosition=function(){try{P.cursorStart=P.input.selectionStart,P.cursorEnd=P.input.selectionEnd,P.currentValue=P.input.value,P.cursorBefore=P.input.value.substring(0,P.cursorStart),P.cursorAfter=P.input.value.substring(P.cursorEnd)}catch(H){}},P.restoreByAfter=function(H){if(H===void 0)return!1;var z=P.input.value,B=z.lastIndexOf(H);if(B===-1)return!1;var k=P.cursorBefore.length;return P.lastKeyCode===c.a.DELETE&&P.cursorBefore.charAt(k-1)===H[0]?(P.fixCaret(k,k),!0):B+H.length===z.length?(P.fixCaret(B,B),!0):!1},P.partRestoreByAfter=function(H){return H===void 0?!1:Array.prototype.some.call(H,function(z,B){var k=H.substring(B);return P.restoreByAfter(k)})},P.isNotCompleteNumber=function(H){return isNaN(H)||H===""||H===null||H&&H.toString().indexOf(".")===H.toString().length-1},P.stop=function(){P.autoStepTimer&&clearTimeout(P.autoStepTimer)},P.down=function(H,z,B){P.pressingUpOrDown=!0,P.step("down",H,z,B)},P.up=function(H,z,B){P.pressingUpOrDown=!0,P.step("up",H,z,B)},P.saveInput=function(H){P.input=H};var G=I.value;G===void 0&&(G=I.defaultValue),P.state={focused:I.autoFocus};var W=P.getValidValue(P.toNumber(G));return P.state=i(i({},P.state),{},{inputValue:P.toPrecisionAsStep(W),value:W}),P}return Object(M.a)(L,[{key:"componentDidMount",value:function(){this.componentDidUpdate(null)}},{key:"componentDidUpdate",value:function(P){var G=this.props,W=G.value,H=G.onChange,z=G.max,B=G.min,k=this.state.focused;if(P){if(!R(P.value,W)||!R(P.max,z)||!R(P.min,B)){var K=k?W:this.getValidValue(W),Y;this.pressingUpOrDown?Y=K:this.inputting?Y=this.rawInput:Y=this.toPrecisionAsStep(K),this.setState({value:K,inputValue:Y})}var ne="value"in this.props?W:this.state.value;"max"in this.props&&P.max!==z&&typeof ne=="number"&&ne>z&&H&&H(z),"min"in this.props&&P.min!==B&&typeof ne=="number"&&ne<B&&H&&H(B)}try{if(this.cursorStart!==void 0&&this.state.focused){if(!this.partRestoreByAfter(this.cursorAfter)&&this.state.value!==this.props.value){var oe=this.cursorStart+1;this.cursorAfter?this.lastKeyCode===c.a.BACKSPACE?oe=this.cursorStart-1:this.lastKeyCode===c.a.DELETE&&(oe=this.cursorStart):oe=this.input.value.length,this.fixCaret(oe,oe)}else if(this.currentValue===this.input.value)switch(this.lastKeyCode){case c.a.BACKSPACE:this.fixCaret(this.cursorStart-1,this.cursorStart-1);break;case c.a.DELETE:this.fixCaret(this.cursorStart+1,this.cursorStart+1);break;default:}}}catch(_e){}if(this.lastKeyCode=null,!this.pressingUpOrDown)return;this.props.focusOnUpDown&&this.state.focused&&(document.activeElement!==this.input&&this.focus())}},{key:"componentWillUnmount",value:function(){this.stop()}},{key:"getCurrentValidValue",value:function(P){var G=P;return G===""?G="":this.isNotCompleteNumber(parseFloat(G))?G=this.state.value:G=this.getValidValue(G),this.toNumber(G)}},{key:"getValueFromEvent",value:function(P){var G=P.target.value.trim().replace(/。/g,".");return h(this.props.decimalSeparator)&&(G=G.replace(this.props.decimalSeparator,".")),G}},{key:"getValidValue",value:function(P){var G=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.props.min,W=arguments.length>2&&arguments[2]!==void 0?arguments[2]:this.props.max,H=parseFloat(P);return isNaN(H)?P:(H<G&&(H=G),H>W&&(H=W),H)}},{key:"setValue",value:function(P,G){var W=this.props.precision,H=this.isNotCompleteNumber(parseFloat(P))?null:parseFloat(P),z=this.state.value,B=z===void 0?null:z,k=this.state.inputValue,K=k===void 0?null:k,Y=typeof H=="number"?H.toFixed(W):"".concat(H),ne=H!==B||Y!=="".concat(K);return"value"in this.props?(K=this.toPrecisionAsStep(this.state.value),this.setState({inputValue:K},G)):this.setState({value:H,inputValue:this.toPrecisionAsStep(P)},G),ne&&this.props.onChange(H),H}},{key:"getMaxPrecision",value:function(P){var G=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,W=this.props,H=W.precision,z=W.step;if(h(H))return H;var B=this.getPrecision(G),k=this.getPrecision(z),K=this.getPrecision(P);return P?Math.max(K,B+k):B+k}},{key:"getPrecisionFactor",value:function(P){var G=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,W=this.getMaxPrecision(P,G);return Math.pow(10,W)}},{key:"focus",value:function(){this.input.focus(),this.recordCursorPosition()}},{key:"blur",value:function(){this.input.blur()}},{key:"select",value:function(){this.input.select()}},{key:"formatWrapper",value:function(P){return this.props.formatter?this.props.formatter(P):P}},{key:"toPrecisionAsStep",value:function(P){if(this.isNotCompleteNumber(P)||P==="")return P;var G=Math.abs(this.getMaxPrecision(P));return isNaN(G)?P.toString():Number(P).toFixed(G)}},{key:"toNumber",value:function(P){var G=this.props.precision,W=this.state.focused,H=P&&P.length>16&&W;return this.isNotCompleteNumber(P)||H?P:h(G)?Math.round(P*Math.pow(10,G))/Math.pow(10,G):Number(P)}},{key:"upStep",value:function(P,G){var W=this.props.step,H=this.getPrecisionFactor(P,G),z=Math.abs(this.getMaxPrecision(P,G)),B=((H*P+H*W*G)/H).toFixed(z);return this.toNumber(B)}},{key:"downStep",value:function(P,G){var W=this.props.step,H=this.getPrecisionFactor(P,G),z=Math.abs(this.getMaxPrecision(P,G)),B=((H*P-H*W*G)/H).toFixed(z);return this.toNumber(B)}},{key:"step",value:function(P,G){var W=this,H=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,z=arguments.length>3?arguments[3]:void 0;this.stop(),G&&(G.persist(),G.preventDefault());var B=this.props;if(B.disabled)return;var k=this.getCurrentValidValue(this.state.inputValue)||0;if(this.isNotCompleteNumber(k))return;var K=this["".concat(P,"Step")](k,H),Y=K>B.max||K<B.min;if(K>B.max?K=B.max:K<B.min&&(K=B.min),this.setValue(K,null),this.setState({focused:!0},function(){W.pressingUpOrDown=!1}),Y)return;this.autoStepTimer=setTimeout(function(){W[P](G,H,!0)},z?t:S)}},{key:"fixCaret",value:function(P,G){if(P===void 0||G===void 0||!this.input||!this.input.value)return;try{var W=this.input.selectionStart,H=this.input.selectionEnd;(P!==W||G!==H)&&this.input.setSelectionRange(P,G)}catch(z){}}},{key:"render",value:function(){var P,G=this.props,W=G.prefixCls,H=G.disabled,z=G.readOnly,B=G.useTouch,k=G.autoComplete,K=G.upHandler,Y=G.downHandler,ne=G.className,oe=G.max,_e=G.min,xe=G.style,le=G.title,me=G.onMouseEnter,de=G.onMouseLeave,ae=G.onMouseOver,ie=G.onMouseOut,q=G.required,ue=G.onClick,Z=G.tabIndex,ee=G.type,Ee=G.placeholder,te=G.id,J=G.inputMode,X=G.pattern,$=G.step,ge=G.maxLength,fe=G.autoFocus,Te=G.name,ze=G.onPaste,Xe=G.onInput,Ye=Object(N.a)(G,["prefixCls","disabled","readOnly","useTouch","autoComplete","upHandler","downHandler","className","max","min","style","title","onMouseEnter","onMouseLeave","onMouseOver","onMouseOut","required","onClick","tabIndex","type","placeholder","id","inputMode","pattern","step","maxLength","autoFocus","name","onPaste","onInput"]),rt=this.state,at=rt.value,ot=rt.focused,Pe=n()(W,(P={},Object(v.a)(P,ne,!!ne),Object(v.a)(P,"".concat(W,"-disabled"),H),Object(v.a)(P,"".concat(W,"-focused"),ot),P)),Se={};Object.keys(Ye).forEach(function(Ie){(Ie.substr(0,5)==="data-"||Ie.substr(0,5)==="aria-"||Ie==="role")&&(Se[Ie]=Ye[Ie])});var Je=!z&&!H,nt=this.getInputDisplayValue(null),We=(at||at===0)&&(isNaN(at)||Number(at)>=oe),et=(at||at===0)&&(isNaN(at)||Number(at)<=_e),Me=We||H||z,Ce=et||H||z,Re=n()("".concat(W,"-handler"),"".concat(W,"-handler-up"),Object(v.a)({},"".concat(W,"-handler-up-disabled"),Me)),pe=n()("".concat(W,"-handler"),"".concat(W,"-handler-down"),Object(v.a)({},"".concat(W,"-handler-down-disabled"),Ce)),ye=B?{onTouchStart:Me?f:this.up,onTouchEnd:this.stop}:{onMouseDown:Me?f:this.up,onMouseUp:this.stop,onMouseLeave:this.stop},we=B?{onTouchStart:Ce?f:this.down,onTouchEnd:this.stop}:{onMouseDown:Ce?f:this.down,onMouseUp:this.stop,onMouseLeave:this.stop};return p.a.createElement("div",{className:Pe,style:xe,title:le,onMouseEnter:me,onMouseLeave:de,onMouseOver:ae,onMouseOut:ie,onFocus:function(){return null},onBlur:function(){return null}},p.a.createElement("div",{className:"".concat(W,"-handler-wrap")},p.a.createElement("span",Object.assign({unselectable:"on"},ye,{role:"button","aria-label":"Increase Value","aria-disabled":Me,className:Re}),K||p.a.createElement("span",{unselectable:"on",className:"".concat(W,"-handler-up-inner"),onClick:s})),p.a.createElement("span",Object.assign({unselectable:"on"},we,{role:"button","aria-label":"Decrease Value","aria-disabled":Ce,className:pe}),Y||p.a.createElement("span",{unselectable:"on",className:"".concat(W,"-handler-down-inner"),onClick:s}))),p.a.createElement("div",{className:"".concat(W,"-input-wrap")},p.a.createElement("input",Object.assign({role:"spinbutton","aria-valuemin":_e,"aria-valuemax":oe,"aria-valuenow":at,required:q,type:ee,placeholder:Ee,onPaste:ze,onClick:ue,onMouseUp:this.onMouseUp,className:"".concat(W,"-input"),tabIndex:Z,autoComplete:k,onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:Je?this.onKeyDown:f,onKeyUp:Je?this.onKeyUp:f,autoFocus:fe,maxLength:ge,readOnly:z,disabled:H,max:oe,min:_e,step:$,name:Te,title:le,id:te,onChange:this.onChange,ref:this.saveInput,value:this.getFullNum(nt),pattern:X,inputMode:J,onInput:Xe},Se))))}}]),L}(p.a.Component);O.defaultProps={focusOnUpDown:!0,useTouch:!1,prefixCls:"rc-input-number",max:x,min:-x,step:1,style:{},onChange:f,onKeyDown:f,onPressEnter:f,onFocus:f,onBlur:f,parser:l,required:!1,autoComplete:"off"};var g=O,_=Q.a=g},e7zE:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("3y9D"),j("WYAk"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.Base,m=C.WordArray,y=v.algo,w=y.SHA1,b=y.HMAC,p=y.PBKDF2=M.extend({cfg:M.extend({keySize:128/32,hasher:w,iterations:1}),init:function(d){this.cfg=this.cfg.extend(d)},compute:function(d,n){for(var c=this.cfg,r=b.create(c.hasher,d),i=m.create(),o=m.create([1]),u=i.words,f=o.words,s=c.keySize,l=c.iterations;u.length<s;){var t=r.update(n).finalize(o);r.reset();for(var S=t.words,x=S.length,h=t,R=1;R<l;R++){h=r.finalize(h),r.reset();for(var O=h.words,g=0;g<x;g++)S[g]^=O[g]}i.concat(t),f[0]++}return i.sigBytes=s*4,i}});v.PBKDF2=function(d,n,c){return p.create(c).compute(d,n)}}(),N.PBKDF2})},fyJ8:function(F,Q,j){"use strict";var N=j("rePB"),v=j("VTBJ"),C=j("Ff2n"),M=j("U8pU"),m=j("cDcd"),y=j.n(m),w=j("TSYQ"),b=j.n(w),p=j("c+Xe"),d=j("sR1s");function n(u){return u&&Object(M.a)(u)==="object"&&!Array.isArray(u)&&!m.isValidElement(u)}function c(u){return typeof u=="string"?!0:Object(p.c)(u)}function r(u,f){var s,l=u.prefixCls,t=u.className,S=u.record,x=u.index,h=u.dataIndex,R=u.render,O=u.children,g=u.component,_=g===void 0?"td":g,E=u.colSpan,T=u.rowSpan,L=u.fixLeft,I=u.fixRight,P=u.firstFixLeft,G=u.lastFixLeft,W=u.firstFixRight,H=u.lastFixRight,z=u.appendNode,B=u.additionalProps,k=B===void 0?{}:B,K=u.ellipsis,Y=u.align,ne=u.rowType,oe=u.isSticky,_e="".concat(l,"-cell"),xe,le;if(O)le=O;else{var me=Object(d.b)(S,h);if(le=me,R){var de=R(me,S,x);n(de)?(le=de.children,xe=de.props):le=de}}Object(M.a)(le)==="object"&&!Array.isArray(le)&&!m.isValidElement(le)&&(le=null),K&&(G||W)&&(le=m.createElement("span",{className:"".concat(_e,"-content")},le));var ae=xe||{},ie=ae.colSpan,q=ae.rowSpan,ue=ae.style,Z=ae.className,ee=Object(C.a)(ae,["colSpan","rowSpan","style","className"]),Ee=ie!==void 0?ie:E,te=q!==void 0?q:T;if(Ee===0||te===0)return null;var J={},X=typeof L=="number",$=typeof I=="number";X&&(J.position="sticky",J.left=L),$&&(J.position="sticky",J.right=I);var ge={};Y&&(ge.textAlign=Y);var fe,Te=K===!0?{showTitle:!0}:K;Te&&(Te.showTitle||ne==="header")&&(typeof le=="string"||typeof le=="number"?fe=le.toString():m.isValidElement(le)&&typeof le.props.children=="string"&&(fe=le.props.children));var ze=Object(v.a)(Object(v.a)(Object(v.a)({title:fe},ee),k),{},{colSpan:Ee&&Ee!==1?Ee:null,rowSpan:te&&te!==1?te:null,className:b()(_e,t,(s={},Object(N.a)(s,"".concat(_e,"-fix-left"),X),Object(N.a)(s,"".concat(_e,"-fix-left-first"),P),Object(N.a)(s,"".concat(_e,"-fix-left-last"),G),Object(N.a)(s,"".concat(_e,"-fix-right"),$),Object(N.a)(s,"".concat(_e,"-fix-right-first"),W),Object(N.a)(s,"".concat(_e,"-fix-right-last"),H),Object(N.a)(s,"".concat(_e,"-ellipsis"),K),Object(N.a)(s,"".concat(_e,"-with-append"),z),Object(N.a)(s,"".concat(_e,"-fix-sticky"),(X||$)&&oe),s),k.className,Z),style:Object(v.a)(Object(v.a)(Object(v.a)(Object(v.a)({},k.style),ge),J),ue),ref:c(_)?f:null});return m.createElement(_,Object.assign({},ze),z,le)}var i=m.forwardRef(r);i.displayName="Cell";var o=m.memo(i,function(u,f){return f.shouldCellUpdate?!f.shouldCellUpdate(f.record,u.record):!1});Q.a=o},gJ3r:function(F,Q,j){"use strict";j.d(Q,"a",function(){return N});var N=[{value:"\u5317\u4EAC",label:"\u5317\u4EAC",children:[{value:"\u4E1C\u57CE",label:"\u4E1C\u57CE"},{value:"\u897F\u57CE",label:"\u897F\u57CE"},{value:"\u671D\u9633",label:"\u671D\u9633"},{value:"\u4E30\u53F0",label:"\u4E30\u53F0"},{value:"\u77F3\u666F\u5C71",label:"\u77F3\u666F\u5C71"},{value:"\u6D77\u6DC0",label:"\u6D77\u6DC0"},{value:"\u95E8\u5934\u6C9F",label:"\u95E8\u5934\u6C9F"},{value:"\u623F\u5C71",label:"\u623F\u5C71"},{value:"\u901A\u5DDE",label:"\u901A\u5DDE"},{value:"\u987A\u4E49",label:"\u987A\u4E49"},{value:"\u660C\u5E73",label:"\u660C\u5E73"},{value:"\u5927\u5174",label:"\u5927\u5174"},{value:"\u5E73\u8C37",label:"\u5E73\u8C37"},{value:"\u6000\u67D4",label:"\u6000\u67D4"},{value:"\u5BC6\u4E91",label:"\u5BC6\u4E91"},{value:"\u5EF6\u5E86",label:"\u5EF6\u5E86"}]},{value:"\u4E0A\u6D77",label:"\u4E0A\u6D77",children:[{value:"\u5D07\u660E",label:"\u5D07\u660E"},{value:"\u9EC4\u6D66",label:"\u9EC4\u6D66"},{value:"\u5362\u6E7E",label:"\u5362\u6E7E"},{value:"\u5F90\u6C47",label:"\u5F90\u6C47"},{value:"\u957F\u5B81",label:"\u957F\u5B81"},{value:"\u9759\u5B89",label:"\u9759\u5B89"},{value:"\u666E\u9640",label:"\u666E\u9640"},{value:"\u95F8\u5317",label:"\u95F8\u5317"},{value:"\u8679\u53E3",label:"\u8679\u53E3"},{value:"\u6768\u6D66",label:"\u6768\u6D66"},{value:"\u95F5\u884C",label:"\u95F5\u884C"},{value:"\u5B9D\u5C71",label:"\u5B9D\u5C71"},{value:"\u5609\u5B9A",label:"\u5609\u5B9A"},{value:"\u6D66\u4E1C",label:"\u6D66\u4E1C"},{value:"\u91D1\u5C71",label:"\u91D1\u5C71"},{value:"\u677E\u6C5F",label:"\u677E\u6C5F"},{value:"\u9752\u6D66",label:"\u9752\u6D66"},{value:"\u5357\u6C47",label:"\u5357\u6C47"},{value:"\u5949\u8D24",label:"\u5949\u8D24"}]},{value:"\u5E7F\u4E1C",label:"\u5E7F\u4E1C",children:[{value:"\u5E7F\u5DDE",label:"\u5E7F\u5DDE"},{value:"\u6DF1\u5733",label:"\u6DF1\u5733"},{value:"\u73E0\u6D77",label:"\u73E0\u6D77"},{value:"\u4E1C\u839E",label:"\u4E1C\u839E"},{value:"\u4E2D\u5C71",label:"\u4E2D\u5C71"},{value:"\u4F5B\u5C71",label:"\u4F5B\u5C71"},{value:"\u60E0\u5DDE",label:"\u60E0\u5DDE"},{value:"\u6CB3\u6E90",label:"\u6CB3\u6E90"},{value:"\u6F6E\u5DDE",label:"\u6F6E\u5DDE"},{value:"\u6C5F\u95E8",label:"\u6C5F\u95E8"},{value:"\u63ED\u9633",label:"\u63ED\u9633"},{value:"\u8302\u540D",label:"\u8302\u540D"},{value:"\u6885\u5DDE",label:"\u6885\u5DDE"},{value:"\u6E05\u8FDC",label:"\u6E05\u8FDC"},{value:"\u6C55\u5934",label:"\u6C55\u5934"},{value:"\u6C55\u5C3E",label:"\u6C55\u5C3E"},{value:"\u97F6\u5173",label:"\u97F6\u5173"},{value:"\u987A\u5FB7",label:"\u987A\u5FB7"},{value:"\u9633\u6C5F",label:"\u9633\u6C5F"},{value:"\u4E91\u6D6E",label:"\u4E91\u6D6E"},{value:"\u6E5B\u6C5F",label:"\u6E5B\u6C5F"},{value:"\u8087\u5E86",label:"\u8087\u5E86"}]},{value:"\u6C5F\u82CF",label:"\u6C5F\u82CF",children:[{value:"\u5357\u4EAC",label:"\u5357\u4EAC"},{value:"\u5E38\u719F",label:"\u5E38\u719F"},{value:"\u5E38\u5DDE",label:"\u5E38\u5DDE"},{value:"\u6D77\u95E8",label:"\u6D77\u95E8"},{value:"\u6DEE\u5B89",label:"\u6DEE\u5B89"},{value:"\u6C5F\u90FD",label:"\u6C5F\u90FD"},{value:"\u6C5F\u9634",label:"\u6C5F\u9634"},{value:"\u6606\u5C71",label:"\u6606\u5C71"},{value:"\u8FDE\u4E91\u6E2F",label:"\u8FDE\u4E91\u6E2F"},{value:"\u5357\u901A",label:"\u5357\u901A"},{value:"\u542F\u4E1C",label:"\u542F\u4E1C"},{value:"\u6CAD\u9633",label:"\u6CAD\u9633"},{value:"\u5BBF\u8FC1",label:"\u5BBF\u8FC1"},{value:"\u82CF\u5DDE",label:"\u82CF\u5DDE"},{value:"\u592A\u4ED3",label:"\u592A\u4ED3"},{value:"\u6CF0\u5DDE",label:"\u6CF0\u5DDE"},{value:"\u540C\u91CC",label:"\u540C\u91CC"},{value:"\u65E0\u9521",label:"\u65E0\u9521"},{value:"\u5F90\u5DDE",label:"\u5F90\u5DDE"},{value:"\u76D0\u57CE",label:"\u76D0\u57CE"},{value:"\u626C\u5DDE",label:"\u626C\u5DDE"},{value:"\u5B9C\u5174",label:"\u5B9C\u5174"},{value:"\u4EEA\u5F81",label:"\u4EEA\u5F81"},{value:"\u5F20\u5BB6\u6E2F",label:"\u5F20\u5BB6\u6E2F"},{value:"\u9547\u6C5F",label:"\u9547\u6C5F"}]},{value:"\u91CD\u5E86",label:"\u91CD\u5E86",children:[{value:"\u4E07\u5DDE",label:"\u4E07\u5DDE"},{value:"\u6DAA\u9675",label:"\u6DAA\u9675"},{value:"\u6E1D\u4E2D",label:"\u6E1D\u4E2D"},{value:"\u5927\u6E21\u53E3",label:"\u5927\u6E21\u53E3"},{value:"\u6C5F\u5317",label:"\u6C5F\u5317"},{value:"\u6C99\u576A\u575D",label:"\u6C99\u576A\u575D"},{value:"\u4E5D\u9F99\u5761",label:"\u4E5D\u9F99\u5761"},{value:"\u5357\u5CB8",label:"\u5357\u5CB8"},{value:"\u5317\u789A",label:"\u5317\u789A"},{value:"\u4E07\u76DB",label:"\u4E07\u76DB"},{value:"\u53CC\u6322",label:"\u53CC\u6322"},{value:"\u6E1D\u5317",label:"\u6E1D\u5317"},{value:"\u5DF4\u5357",label:"\u5DF4\u5357"},{value:"\u9ED4\u6C5F",label:"\u9ED4\u6C5F"},{value:"\u957F\u5BFF",label:"\u957F\u5BFF"},{value:"\u7DA6\u6C5F",label:"\u7DA6\u6C5F"},{value:"\u6F7C\u5357",label:"\u6F7C\u5357"},{value:"\u94DC\u6881",label:"\u94DC\u6881"},{value:"\u5927\u8DB3",label:"\u5927\u8DB3"},{value:"\u8363\u660C",label:"\u8363\u660C"},{value:"\u58C1\u5C71",label:"\u58C1\u5C71"},{value:"\u6881\u5E73",label:"\u6881\u5E73"},{value:"\u57CE\u53E3",label:"\u57CE\u53E3"},{value:"\u4E30\u90FD",label:"\u4E30\u90FD"},{value:"\u57AB\u6C5F",label:"\u57AB\u6C5F"},{value:"\u6B66\u9686",label:"\u6B66\u9686"},{value:"\u5FE0\u53BF",label:"\u5FE0\u53BF"},{value:"\u5F00\u53BF",label:"\u5F00\u53BF"},{value:"\u4E91\u9633",label:"\u4E91\u9633"},{value:"\u5949\u8282",label:"\u5949\u8282"},{value:"\u5DEB\u5C71",label:"\u5DEB\u5C71"},{value:"\u5DEB\u6EAA",label:"\u5DEB\u6EAA"},{value:"\u77F3\u67F1",label:"\u77F3\u67F1"},{value:"\u79C0\u5C71",label:"\u79C0\u5C71"},{value:"\u9149\u9633",label:"\u9149\u9633"},{value:"\u5F6D\u6C34",label:"\u5F6D\u6C34"},{value:"\u6C5F\u6D25",label:"\u6C5F\u6D25"},{value:"\u5408\u5DDD",label:"\u5408\u5DDD"},{value:"\u6C38\u5DDD",label:"\u6C38\u5DDD"},{value:"\u5357\u5DDD",label:"\u5357\u5DDD"}]},{value:"\u5B89\u5FBD",label:"\u5B89\u5FBD",children:[{value:"\u5408\u80A5",label:"\u5408\u80A5"},{value:"\u5B89\u5E86",label:"\u5B89\u5E86"},{value:"\u868C\u57E0",label:"\u868C\u57E0"},{value:"\u4EB3\u5DDE",label:"\u4EB3\u5DDE"},{value:"\u5DE2\u6E56",label:"\u5DE2\u6E56"},{value:"\u6EC1\u5DDE",label:"\u6EC1\u5DDE"},{value:"\u961C\u9633",label:"\u961C\u9633"},{value:"\u8D35\u6C60",label:"\u8D35\u6C60"},{value:"\u6DEE\u5317",label:"\u6DEE\u5317"},{value:"\u6DEE\u5316",label:"\u6DEE\u5316"},{value:"\u6DEE\u5357",label:"\u6DEE\u5357"},{value:"\u9EC4\u5C71",label:"\u9EC4\u5C71"},{value:"\u4E5D\u534E\u5C71",label:"\u4E5D\u534E\u5C71"},{value:"\u516D\u5B89",label:"\u516D\u5B89"},{value:"\u9A6C\u978D\u5C71",label:"\u9A6C\u978D\u5C71"},{value:"\u5BBF\u5DDE",label:"\u5BBF\u5DDE"},{value:"\u94DC\u9675",label:"\u94DC\u9675"},{value:"\u5C6F\u6EAA",label:"\u5C6F\u6EAA"},{value:"\u829C\u6E56",label:"\u829C\u6E56"},{value:"\u5BA3\u57CE",label:"\u5BA3\u57CE"}]},{value:"\u798F\u5EFA",label:"\u798F\u5EFA",children:[{value:"\u798F\u5DDE",label:"\u798F\u5DDE"},{value:"\u53A6\u95E8",label:"\u53A6\u95E8"},{value:"\u6CC9\u5DDE",label:"\u6CC9\u5DDE"},{value:"\u6F33\u5DDE",label:"\u6F33\u5DDE"},{value:"\u9F99\u5CA9",label:"\u9F99\u5CA9"},{value:"\u5357\u5E73",label:"\u5357\u5E73"},{value:"\u5B81\u5FB7",label:"\u5B81\u5FB7"},{value:"\u8386\u7530",label:"\u8386\u7530"},{value:"\u4E09\u660E",label:"\u4E09\u660E"}]},{value:"\u7518\u8083",label:"\u7518\u8083",children:[{value:"\u5170\u5DDE",label:"\u5170\u5DDE"},{value:"\u5609\u5CEA\u5173",label:"\u5609\u5CEA\u5173"},{value:"\u767D\u94F6",label:"\u767D\u94F6"},{value:"\u5B9A\u897F",label:"\u5B9A\u897F"},{value:"\u6566\u714C",label:"\u6566\u714C"},{value:"\u7518\u5357",label:"\u7518\u5357"},{value:"\u91D1\u660C",label:"\u91D1\u660C"},{value:"\u9152\u6CC9",label:"\u9152\u6CC9"},{value:"\u4E34\u590F",label:"\u4E34\u590F"},{value:"\u5E73\u51C9",label:"\u5E73\u51C9"},{value:"\u5929\u6C34",label:"\u5929\u6C34"},{value:"\u9647\u5357",label:"\u9647\u5357"},{value:"\u6B66\u5A01",label:"\u6B66\u5A01"},{value:"\u897F\u5CF0",label:"\u897F\u5CF0"},{value:"\u5F20\u6396",label:"\u5F20\u6396"}]},{value:"\u5E7F\u897F",label:"\u5E7F\u897F",children:[{value:"\u5357\u5B81",label:"\u5357\u5B81"},{value:"\u6765\u5BBE",label:"\u6765\u5BBE"},{value:"\u767E\u8272",label:"\u767E\u8272"},{value:"\u5317\u6D77",label:"\u5317\u6D77"},{value:"\u6842\u6797",label:"\u6842\u6797"},{value:"\u9632\u57CE\u6E2F",label:"\u9632\u57CE\u6E2F"},{value:"\u8D35\u6E2F",label:"\u8D35\u6E2F"},{value:"\u6CB3\u6C60",label:"\u6CB3\u6C60"},{value:"\u8D3A\u5DDE",label:"\u8D3A\u5DDE"},{value:"\u67F3\u5DDE",label:"\u67F3\u5DDE"},{value:"\u94A6\u5DDE",label:"\u94A6\u5DDE"},{value:"\u68A7\u5DDE",label:"\u68A7\u5DDE"},{value:"\u7389\u6797",label:"\u7389\u6797"}]},{value:"\u8D35\u5DDE",label:"\u8D35\u5DDE",children:[{value:"\u8D35\u9633",label:"\u8D35\u9633"},{value:"\u5B89\u987A",label:"\u5B89\u987A"},{value:"\u6BD5\u8282",label:"\u6BD5\u8282"},{value:"\u90FD\u5300",label:"\u90FD\u5300"},{value:"\u51EF\u91CC",label:"\u51EF\u91CC"},{value:"\u516D\u76D8\u6C34",label:"\u516D\u76D8\u6C34"},{value:"\u94DC\u4EC1",label:"\u94DC\u4EC1"},{value:"\u5174\u4E49",label:"\u5174\u4E49"},{value:"\u7389\u5C4F",label:"\u7389\u5C4F"},{value:"\u9075\u4E49",label:"\u9075\u4E49"}]},{value:"\u6D77\u5357",label:"\u6D77\u5357",children:[{value:"\u6D77\u53E3",label:"\u6D77\u53E3"},{value:"\u510B\u53BF",label:"\u510B\u53BF"},{value:"\u9675\u6C34",label:"\u9675\u6C34"},{value:"\u743C\u6D77",label:"\u743C\u6D77"},{value:"\u4E09\u4E9A",label:"\u4E09\u4E9A"},{value:"\u901A\u4EC0",label:"\u901A\u4EC0"},{value:"\u4E07\u5B81",label:"\u4E07\u5B81"}]},{value:"\u6CB3\u5317",label:"\u6CB3\u5317",children:[{value:"\u77F3\u5BB6\u5E84",label:"\u77F3\u5BB6\u5E84"},{value:"\u4FDD\u5B9A",label:"\u4FDD\u5B9A"},{value:"\u5317\u6234\u6CB3",label:"\u5317\u6234\u6CB3"},{value:"\u6CA7\u5DDE",label:"\u6CA7\u5DDE"},{value:"\u627F\u5FB7",label:"\u627F\u5FB7"},{value:"\u4E30\u6DA6",label:"\u4E30\u6DA6"},{value:"\u90AF\u90F8",label:"\u90AF\u90F8"},{value:"\u8861\u6C34",label:"\u8861\u6C34"},{value:"\u5ECA\u574A",label:"\u5ECA\u574A"},{value:"\u5357\u6234\u6CB3",label:"\u5357\u6234\u6CB3"},{value:"\u79E6\u7687\u5C9B",label:"\u79E6\u7687\u5C9B"},{value:"\u5510\u5C71",label:"\u5510\u5C71"},{value:"\u65B0\u57CE",label:"\u65B0\u57CE"},{value:"\u90A2\u53F0",label:"\u90A2\u53F0"},{value:"\u5F20\u5BB6\u53E3",label:"\u5F20\u5BB6\u53E3"}]},{value:"\u9ED1\u9F99\u6C5F",label:"\u9ED1\u9F99\u6C5F",children:[{value:"\u54C8\u5C14\u6EE8",label:"\u54C8\u5C14\u6EE8"},{value:"\u5317\u5B89",label:"\u5317\u5B89"},{value:"\u5927\u5E86",label:"\u5927\u5E86"},{value:"\u5927\u5174\u5B89\u5CAD",label:"\u5927\u5174\u5B89\u5CAD"},{value:"\u9E64\u5C97",label:"\u9E64\u5C97"},{value:"\u9ED1\u6CB3",label:"\u9ED1\u6CB3"},{value:"\u4F73\u6728\u65AF",label:"\u4F73\u6728\u65AF"},{value:"\u9E21\u897F",label:"\u9E21\u897F"},{value:"\u7261\u4E39\u6C5F",label:"\u7261\u4E39\u6C5F"},{value:"\u9F50\u9F50\u54C8\u5C14",label:"\u9F50\u9F50\u54C8\u5C14"},{value:"\u4E03\u53F0\u6CB3",label:"\u4E03\u53F0\u6CB3"},{value:"\u53CC\u9E2D\u5C71",label:"\u53CC\u9E2D\u5C71"},{value:"\u7EE5\u5316",label:"\u7EE5\u5316"},{value:"\u4F0A\u6625",label:"\u4F0A\u6625"}]},{value:"\u6CB3\u5357",label:"\u6CB3\u5357",children:[{value:"\u90D1\u5DDE",label:"\u90D1\u5DDE"},{value:"\u5B89\u9633",label:"\u5B89\u9633"},{value:"\u9E64\u58C1",label:"\u9E64\u58C1"},{value:"\u6F62\u5DDD",label:"\u6F62\u5DDD"},{value:"\u7126\u4F5C",label:"\u7126\u4F5C"},{value:"\u6D4E\u6E90",label:"\u6D4E\u6E90"},{value:"\u5F00\u5C01",label:"\u5F00\u5C01"},{value:"\u6F2F\u6CB3",label:"\u6F2F\u6CB3"},{value:"\u6D1B\u9633",label:"\u6D1B\u9633"},{value:"\u5357\u9633",label:"\u5357\u9633"},{value:"\u5E73\u9876\u5C71",label:"\u5E73\u9876\u5C71"},{value:"\u6FEE\u9633",label:"\u6FEE\u9633"},{value:"\u4E09\u95E8\u5CE1",label:"\u4E09\u95E8\u5CE1"},{value:"\u5546\u4E18",label:"\u5546\u4E18"},{value:"\u65B0\u4E61",label:"\u65B0\u4E61"},{value:"\u4FE1\u9633",label:"\u4FE1\u9633"},{value:"\u8BB8\u660C",label:"\u8BB8\u660C"},{value:"\u5468\u53E3",label:"\u5468\u53E3"},{value:"\u9A7B\u9A6C\u5E97",label:"\u9A7B\u9A6C\u5E97"}]},{value:"\u9999\u6E2F",label:"\u9999\u6E2F",children:[{value:"\u9999\u6E2F",label:"\u9999\u6E2F"},{value:"\u4E5D\u9F99",label:"\u4E5D\u9F99"},{value:"\u65B0\u754C",label:"\u65B0\u754C"}]},{value:"\u6E56\u5317",label:"\u6E56\u5317",children:[{value:"\u6B66\u6C49",label:"\u6B66\u6C49"},{value:"\u5929\u95E8",label:"\u5929\u95E8"},{value:"\u6069\u65BD",label:"\u6069\u65BD"},{value:"\u9102\u5DDE",label:"\u9102\u5DDE"},{value:"\u9EC4\u5188",label:"\u9EC4\u5188"},{value:"\u9EC4\u77F3",label:"\u9EC4\u77F3"},{value:"\u8346\u95E8",label:"\u8346\u95E8"},{value:"\u8346\u5DDE",label:"\u8346\u5DDE"},{value:"\u6F5C\u6C5F",label:"\u6F5C\u6C5F"},{value:"\u5341\u5830",label:"\u5341\u5830"},{value:"\u968F\u5DDE",label:"\u968F\u5DDE"},{value:"\u6B66\u7A74",label:"\u6B66\u7A74"},{value:"\u4ED9\u6843",label:"\u4ED9\u6843"},{value:"\u54B8\u5B81",label:"\u54B8\u5B81"},{value:"\u8944\u9633",label:"\u8944\u9633"},{value:"\u8944\u6A0A",label:"\u8944\u6A0A"},{value:"\u5B5D\u611F",label:"\u5B5D\u611F"},{value:"\u5B9C\u660C",label:"\u5B9C\u660C"}]},{value:"\u6E56\u5357",label:"\u6E56\u5357",children:[{value:"\u957F\u6C99",label:"\u957F\u6C99"},{value:"\u5E38\u5FB7",label:"\u5E38\u5FB7"},{value:"\u90F4\u5DDE",label:"\u90F4\u5DDE"},{value:"\u8861\u9633",label:"\u8861\u9633"},{value:"\u6000\u5316",label:"\u6000\u5316"},{value:"\u5409\u9996",label:"\u5409\u9996"},{value:"\u5A04\u5E95",label:"\u5A04\u5E95"},{value:"\u90B5\u9633",label:"\u90B5\u9633"},{value:"\u6E58\u6F6D",label:"\u6E58\u6F6D"},{value:"\u76CA\u9633",label:"\u76CA\u9633"},{value:"\u5CB3\u9633",label:"\u5CB3\u9633"},{value:"\u6C38\u5DDE",label:"\u6C38\u5DDE"},{value:"\u5F20\u5BB6\u754C",label:"\u5F20\u5BB6\u754C"},{value:"\u682A\u6D32",label:"\u682A\u6D32"}]},{value:"\u6C5F\u897F",label:"\u6C5F\u897F",children:[{value:"\u5357\u660C",label:"\u5357\u660C"},{value:"\u629A\u5DDE",label:"\u629A\u5DDE"},{value:"\u8D63\u5DDE",label:"\u8D63\u5DDE"},{value:"\u5409\u5B89",label:"\u5409\u5B89"},{value:"\u666F\u5FB7\u9547",label:"\u666F\u5FB7\u9547"},{value:"\u4E95\u5188\u5C71",label:"\u4E95\u5188\u5C71"},{value:"\u4E5D\u6C5F",label:"\u4E5D\u6C5F"},{value:"\u5E90\u5C71",label:"\u5E90\u5C71"},{value:"\u840D\u4E61",label:"\u840D\u4E61"},{value:"\u4E0A\u9976",label:"\u4E0A\u9976"},{value:"\u65B0\u4F59",label:"\u65B0\u4F59"},{value:"\u5B9C\u6625",label:"\u5B9C\u6625"},{value:"\u9E70\u6F6D",label:"\u9E70\u6F6D"}]},{value:"\u5409\u6797",label:"\u5409\u6797",children:[{value:"\u957F\u6625",label:"\u957F\u6625"},{value:"\u5409\u6797",label:"\u5409\u6797"},{value:"\u767D\u57CE",label:"\u767D\u57CE"},{value:"\u767D\u5C71",label:"\u767D\u5C71"},{value:"\u73F2\u6625",label:"\u73F2\u6625"},{value:"\u8FBD\u6E90",label:"\u8FBD\u6E90"},{value:"\u6885\u6CB3",label:"\u6885\u6CB3"},{value:"\u56DB\u5E73",label:"\u56DB\u5E73"},{value:"\u677E\u539F",label:"\u677E\u539F"},{value:"\u901A\u5316",label:"\u901A\u5316"},{value:"\u5EF6\u5409",label:"\u5EF6\u5409"}]},{value:"\u8FBD\u5B81",label:"\u8FBD\u5B81",children:[{value:"\u6C88\u9633",label:"\u6C88\u9633"},{value:"\u978D\u5C71",label:"\u978D\u5C71"},{value:"\u672C\u6EAA",label:"\u672C\u6EAA"},{value:"\u671D\u9633",label:"\u671D\u9633"},{value:"\u5927\u8FDE",label:"\u5927\u8FDE"},{value:"\u4E39\u4E1C",label:"\u4E39\u4E1C"},{value:"\u629A\u987A",label:"\u629A\u987A"},{value:"\u961C\u65B0",label:"\u961C\u65B0"},{value:"\u846B\u82A6\u5C9B",label:"\u846B\u82A6\u5C9B"},{value:"\u9526\u5DDE",label:"\u9526\u5DDE"},{value:"\u8FBD\u9633",label:"\u8FBD\u9633"},{value:"\u76D8\u9526",label:"\u76D8\u9526"},{value:"\u94C1\u5CAD",label:"\u94C1\u5CAD"},{value:"\u8425\u53E3",label:"\u8425\u53E3"}]},{value:"\u6FB3\u95E8",label:"\u6FB3\u95E8",children:[{value:"\u6FB3\u95E8",label:"\u6FB3\u95E8"}]},{value:"\u5185\u8499\u53E4",label:"\u5185\u8499\u53E4",children:[{value:"\u547C\u548C\u6D69\u7279",label:"\u547C\u548C\u6D69\u7279"},{value:"\u963F\u62C9\u5584\u76DF",label:"\u963F\u62C9\u5584\u76DF"},{value:"\u5305\u5934",label:"\u5305\u5934"},{value:"\u8D64\u5CF0",label:"\u8D64\u5CF0"},{value:"\u4E1C\u80DC",label:"\u4E1C\u80DC"},{value:"\u6D77\u62C9\u5C14",label:"\u6D77\u62C9\u5C14"},{value:"\u96C6\u5B81",label:"\u96C6\u5B81"},{value:"\u4E34\u6CB3",label:"\u4E34\u6CB3"},{value:"\u901A\u8FBD",label:"\u901A\u8FBD"},{value:"\u4E4C\u6D77",label:"\u4E4C\u6D77"},{value:"\u4E4C\u5170\u6D69\u7279",label:"\u4E4C\u5170\u6D69\u7279"},{value:"\u9521\u6797\u6D69\u7279",label:"\u9521\u6797\u6D69\u7279"}]},{value:"\u5B81\u590F",label:"\u5B81\u590F",children:[{value:"\u94F6\u5DDD",label:"\u94F6\u5DDD"},{value:"\u56FA\u6E90",label:"\u56FA\u6E90"},{value:"\u77F3\u5634\u5C71",label:"\u77F3\u5634\u5C71"},{value:"\u5434\u5FE0",label:"\u5434\u5FE0"}]},{value:"\u9752\u6D77",label:"\u9752\u6D77",children:[{value:"\u897F\u5B81",label:"\u897F\u5B81"},{value:"\u5FB7\u4EE4\u54C8",label:"\u5FB7\u4EE4\u54C8"},{value:"\u683C\u5C14\u6728",label:"\u683C\u5C14\u6728"},{value:"\u5171\u548C",label:"\u5171\u548C"},{value:"\u6D77\u4E1C",label:"\u6D77\u4E1C"},{value:"\u6D77\u664F",label:"\u6D77\u664F"},{value:"\u739B\u6C81",label:"\u739B\u6C81"},{value:"\u540C\u4EC1",label:"\u540C\u4EC1"},{value:"\u7389\u6811",label:"\u7389\u6811"}]},{value:"\u5C71\u4E1C",label:"\u5C71\u4E1C",children:[{value:"\u6D4E\u5357",label:"\u6D4E\u5357"},{value:"\u6EE8\u5DDE",label:"\u6EE8\u5DDE"},{value:"\u5156\u5DDE",label:"\u5156\u5DDE"},{value:"\u5FB7\u5DDE",label:"\u5FB7\u5DDE"},{value:"\u4E1C\u8425",label:"\u4E1C\u8425"},{value:"\u83CF\u6CFD",label:"\u83CF\u6CFD"},{value:"\u6D4E\u5B81",label:"\u6D4E\u5B81"},{value:"\u83B1\u829C",label:"\u83B1\u829C"},{value:"\u804A\u57CE",label:"\u804A\u57CE"},{value:"\u4E34\u6C82",label:"\u4E34\u6C82"},{value:"\u84EC\u83B1",label:"\u84EC\u83B1"},{value:"\u9752\u5C9B",label:"\u9752\u5C9B"},{value:"\u66F2\u961C",label:"\u66F2\u961C"},{value:"\u65E5\u7167",label:"\u65E5\u7167"},{value:"\u6CF0\u5B89",label:"\u6CF0\u5B89"},{value:"\u6F4D\u574A",label:"\u6F4D\u574A"},{value:"\u5A01\u6D77",label:"\u5A01\u6D77"},{value:"\u70DF\u53F0",label:"\u70DF\u53F0"},{value:"\u67A3\u5E84",label:"\u67A3\u5E84"},{value:"\u6DC4\u535A",label:"\u6DC4\u535A"}]},{value:"\u5C71\u897F",label:"\u5C71\u897F",children:[{value:"\u592A\u539F",label:"\u592A\u539F"},{value:"\u5415\u6881",label:"\u5415\u6881"},{value:"\u957F\u6CBB",label:"\u957F\u6CBB"},{value:"\u5927\u540C",label:"\u5927\u540C"},{value:"\u5019\u9A6C",label:"\u5019\u9A6C"},{value:"\u664B\u57CE",label:"\u664B\u57CE"},{value:"\u79BB\u77F3",label:"\u79BB\u77F3"},{value:"\u4E34\u6C7E",label:"\u4E34\u6C7E"},{value:"\u5B81\u6B66",label:"\u5B81\u6B66"},{value:"\u6714\u5DDE",label:"\u6714\u5DDE"},{value:"\u5FFB\u5DDE",label:"\u5FFB\u5DDE"},{value:"\u9633\u6CC9",label:"\u9633\u6CC9"},{value:"\u6986\u6B21",label:"\u6986\u6B21"},{value:"\u664B\u4E2D",label:"\u664B\u4E2D"},{value:"\u8FD0\u57CE",label:"\u8FD0\u57CE"}]},{value:"\u9655\u897F",label:"\u9655\u897F",children:[{value:"\u897F\u5B89",label:"\u897F\u5B89"},{value:"\u5B89\u5EB7",label:"\u5B89\u5EB7"},{value:"\u5B9D\u9E21",label:"\u5B9D\u9E21"},{value:"\u6C49\u4E2D",label:"\u6C49\u4E2D"},{value:"\u6E2D\u5357",label:"\u6E2D\u5357"},{value:"\u5546\u5DDE",label:"\u5546\u5DDE"},{value:"\u7EE5\u5FB7",label:"\u7EE5\u5FB7"},{value:"\u94DC\u5DDD",label:"\u94DC\u5DDD"},{value:"\u54B8\u9633",label:"\u54B8\u9633"},{value:"\u5EF6\u5B89",label:"\u5EF6\u5B89"},{value:"\u6986\u6797",label:"\u6986\u6797"}]},{value:"\u56DB\u5DDD",label:"\u56DB\u5DDD",children:[{value:"\u6210\u90FD",label:"\u6210\u90FD"},{value:"\u5DF4\u4E2D",label:"\u5DF4\u4E2D"},{value:"\u8FBE\u5DDD",label:"\u8FBE\u5DDD"},{value:"\u5FB7\u9633",label:"\u5FB7\u9633"},{value:"\u90FD\u6C5F\u5830",label:"\u90FD\u6C5F\u5830"},{value:"\u5CE8\u7709\u5C71",label:"\u5CE8\u7709\u5C71"},{value:"\u6DAA\u9675",label:"\u6DAA\u9675"},{value:"\u5E7F\u5B89",label:"\u5E7F\u5B89"},{value:"\u5E7F\u5143",label:"\u5E7F\u5143"},{value:"\u4E5D\u5BE8\u6C9F",label:"\u4E5D\u5BE8\u6C9F"},{value:"\u5EB7\u5B9A",label:"\u5EB7\u5B9A"},{value:"\u4E50\u5C71",label:"\u4E50\u5C71"},{value:"\u6CF8\u5DDE",label:"\u6CF8\u5DDE"},{value:"\u9A6C\u5C14\u5EB7",label:"\u9A6C\u5C14\u5EB7"},{value:"\u7EF5\u9633",label:"\u7EF5\u9633"},{value:"\u7709\u5C71",label:"\u7709\u5C71"},{value:"\u5357\u5145",label:"\u5357\u5145"},{value:"\u5185\u6C5F",label:"\u5185\u6C5F"},{value:"\u6500\u679D\u82B1",label:"\u6500\u679D\u82B1"},{value:"\u9042\u5B81",label:"\u9042\u5B81"},{value:"\u6C76\u5DDD",label:"\u6C76\u5DDD"},{value:"\u897F\u660C",label:"\u897F\u660C"},{value:"\u96C5\u5B89",label:"\u96C5\u5B89"},{value:"\u5B9C\u5BBE",label:"\u5B9C\u5BBE"},{value:"\u81EA\u8D21",label:"\u81EA\u8D21"},{value:"\u8D44\u9633",label:"\u8D44\u9633"}]},{value:"\u53F0\u6E7E",label:"\u53F0\u6E7E",children:[{value:"\u53F0\u5317",label:"\u53F0\u5317"},{value:"\u57FA\u9686",label:"\u57FA\u9686"},{value:"\u53F0\u5357",label:"\u53F0\u5357"},{value:"\u53F0\u4E2D",label:"\u53F0\u4E2D"},{value:"\u9AD8\u96C4",label:"\u9AD8\u96C4"},{value:"\u5C4F\u4E1C",label:"\u5C4F\u4E1C"},{value:"\u5357\u6295",label:"\u5357\u6295"},{value:"\u4E91\u6797",label:"\u4E91\u6797"},{value:"\u65B0\u7AF9",label:"\u65B0\u7AF9"},{value:"\u5F70\u5316",label:"\u5F70\u5316"},{value:"\u82D7\u6817",label:"\u82D7\u6817"},{value:"\u5609\u4E49",label:"\u5609\u4E49"},{value:"\u6843\u56ED",label:"\u6843\u56ED"},{value:"\u5B9C\u5170",label:"\u5B9C\u5170"},{value:"\u53F0\u4E1C",label:"\u53F0\u4E1C"},{value:"\u91D1\u95E8",label:"\u91D1\u95E8"},{value:"\u9A6C\u7956",label:"\u9A6C\u7956"},{value:"\u6F8E\u6E56",label:"\u6F8E\u6E56"}]},{value:"\u5929\u6D25",label:"\u5929\u6D25",children:[{value:"\u5929\u6D25",label:"\u5929\u6D25"},{value:"\u548C\u5E73",label:"\u548C\u5E73"},{value:"\u4E1C\u4E3D",label:"\u4E1C\u4E3D"},{value:"\u6CB3\u4E1C",label:"\u6CB3\u4E1C"},{value:"\u897F\u9752",label:"\u897F\u9752"},{value:"\u6CB3\u897F",label:"\u6CB3\u897F"},{value:"\u6D25\u5357",label:"\u6D25\u5357"},{value:"\u5357\u5F00",label:"\u5357\u5F00"},{value:"\u5317\u8FB0",label:"\u5317\u8FB0"},{value:"\u6CB3\u5317",label:"\u6CB3\u5317"},{value:"\u6B66\u6E05",label:"\u6B66\u6E05"},{value:"\u7EA2\u6322",label:"\u7EA2\u6322"},{value:"\u5858\u6CBD",label:"\u5858\u6CBD"},{value:"\u6C49\u6CBD",label:"\u6C49\u6CBD"},{value:"\u5927\u6E2F",label:"\u5927\u6E2F"},{value:"\u5B81\u6CB3",label:"\u5B81\u6CB3"},{value:"\u9759\u6D77",label:"\u9759\u6D77"},{value:"\u5B9D\u577B",label:"\u5B9D\u577B"},{value:"\u84DF\u53BF",label:"\u84DF\u53BF"}]},{value:"\u65B0\u7586",label:"\u65B0\u7586",children:[{value:"\u4E4C\u9C81\u6728\u9F50",label:"\u4E4C\u9C81\u6728\u9F50"},{value:"\u963F\u514B\u82CF",label:"\u963F\u514B\u82CF"},{value:"\u963F\u52D2\u6CF0",label:"\u963F\u52D2\u6CF0"},{value:"\u963F\u56FE\u4EC0",label:"\u963F\u56FE\u4EC0"},{value:"\u535A\u4E50",label:"\u535A\u4E50"},{value:"\u660C\u5409",label:"\u660C\u5409"},{value:"\u4E1C\u5C71",label:"\u4E1C\u5C71"},{value:"\u54C8\u5BC6",label:"\u54C8\u5BC6"},{value:"\u548C\u7530",label:"\u548C\u7530"},{value:"\u5580\u4EC0",label:"\u5580\u4EC0"},{value:"\u514B\u62C9\u739B\u4F9D",label:"\u514B\u62C9\u739B\u4F9D"},{value:"\u5E93\u8F66",label:"\u5E93\u8F66"},{value:"\u5E93\u5C14\u52D2",label:"\u5E93\u5C14\u52D2"},{value:"\u594E\u5C6F",label:"\u594E\u5C6F"},{value:"\u77F3\u6CB3\u5B50",label:"\u77F3\u6CB3\u5B50"},{value:"\u5854\u57CE",label:"\u5854\u57CE"},{value:"\u5410\u9C81\u756A",label:"\u5410\u9C81\u756A"},{value:"\u4F0A\u5B81",label:"\u4F0A\u5B81"}]},{value:"\u897F\u85CF",label:"\u897F\u85CF",children:[{value:"\u62C9\u8428",label:"\u62C9\u8428"},{value:"\u963F\u91CC",label:"\u963F\u91CC"},{value:"\u660C\u90FD",label:"\u660C\u90FD"},{value:"\u6797\u829D",label:"\u6797\u829D"},{value:"\u90A3\u66F2",label:"\u90A3\u66F2"},{value:"\u65E5\u5580\u5219",label:"\u65E5\u5580\u5219"},{value:"\u5C71\u5357",label:"\u5C71\u5357"}]},{value:"\u4E91\u5357",label:"\u4E91\u5357",children:[{value:"\u6606\u660E",label:"\u6606\u660E"},{value:"\u5927\u7406",label:"\u5927\u7406"},{value:"\u4FDD\u5C71",label:"\u4FDD\u5C71"},{value:"\u695A\u96C4",label:"\u695A\u96C4"},{value:"\u5927\u7406",label:"\u5927\u7406"},{value:"\u4E1C\u5DDD",label:"\u4E1C\u5DDD"},{value:"\u4E2A\u65E7",label:"\u4E2A\u65E7"},{value:"\u666F\u6D2A",label:"\u666F\u6D2A"},{value:"\u5F00\u8FDC",label:"\u5F00\u8FDC"},{value:"\u4E34\u6CA7",label:"\u4E34\u6CA7"},{value:"\u4E3D\u6C5F",label:"\u4E3D\u6C5F"},{value:"\u516D\u5E93",label:"\u516D\u5E93"},{value:"\u6F5E\u897F",label:"\u6F5E\u897F"},{value:"\u66F2\u9756",label:"\u66F2\u9756"},{value:"\u601D\u8305",label:"\u601D\u8305"},{value:"\u6587\u5C71",label:"\u6587\u5C71"},{value:"\u897F\u53CC\u7248\u7EB3",label:"\u897F\u53CC\u7248\u7EB3"},{value:"\u7389\u6EAA",label:"\u7389\u6EAA"},{value:"\u4E2D\u7538",label:"\u4E2D\u7538"},{value:"\u662D\u901A",label:"\u662D\u901A"}]},{value:"\u6D59\u6C5F",label:"\u6D59\u6C5F",children:[{value:"\u676D\u5DDE",label:"\u676D\u5DDE"},{value:"\u6E29\u5DDE",label:"\u6E29\u5DDE"},{value:"\u5B89\u5409",label:"\u5B89\u5409"},{value:"\u6148\u6EAA",label:"\u6148\u6EAA"},{value:"\u5B9A\u6D77",label:"\u5B9A\u6D77"},{value:"\u5949\u5316",label:"\u5949\u5316"},{value:"\u6D77\u76D0",label:"\u6D77\u76D0"},{value:"\u9EC4\u5CA9",label:"\u9EC4\u5CA9"},{value:"\u6E56\u5DDE",label:"\u6E56\u5DDE"},{value:"\u5609\u5174",label:"\u5609\u5174"},{value:"\u91D1\u534E",label:"\u91D1\u534E"},{value:"\u4E34\u5B89",label:"\u4E34\u5B89"},{value:"\u4E34\u6D77",label:"\u4E34\u6D77"},{value:"\u4E3D\u6C34",label:"\u4E3D\u6C34"},{value:"\u5B81\u6CE2",label:"\u5B81\u6CE2"},{value:"\u74EF\u6D77",label:"\u74EF\u6D77"},{value:"\u5E73\u6E56",label:"\u5E73\u6E56"},{value:"\u5343\u5C9B\u6E56",label:"\u5343\u5C9B\u6E56"},{value:"\u8862\u5DDE",label:"\u8862\u5DDE"},{value:"\u6C5F\u5C71",label:"\u6C5F\u5C71"},{value:"\u745E\u5B89",label:"\u745E\u5B89"},{value:"\u7ECD\u5174",label:"\u7ECD\u5174"},{value:"\u5D4A\u5DDE",label:"\u5D4A\u5DDE"},{value:"\u53F0\u5DDE",label:"\u53F0\u5DDE"},{value:"\u6E29\u5CAD",label:"\u6E29\u5CAD"},{value:"\u4F59\u59DA",label:"\u4F59\u59DA"},{value:"\u821F\u5C71",label:"\u821F\u5C71"}]},{value:"\u6D77\u5916",label:"\u6D77\u5916",children:[{value:"\u7F8E\u56FD",label:"\u7F8E\u56FD"},{value:"\u65E5\u672C",label:"\u65E5\u672C"},{value:"\u82F1\u56FD",label:"\u82F1\u56FD"},{value:"\u6CD5\u56FD",label:"\u6CD5\u56FD"},{value:"\u5FB7\u56FD",label:"\u5FB7\u56FD"},{value:"\u5176\u4ED6",label:"\u5176\u4ED6"}]}]},"gb/T":function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.mode.ECB=function(){var v=N.lib.BlockCipherMode.extend();return v.Encryptor=v.extend({processBlock:function(C,M){this._cipher.encryptBlock(C,M)}}),v.Decryptor=v.extend({processBlock:function(C,M){this._cipher.decryptBlock(C,M)}}),v}(),N.mode.ECB})},h78n:function(F,Q,j){"use strict";j.d(Q,"a",function(){return P});var N=j("cDcd"),v=j.n(N),C=j("TSYQ"),M=j.n(C),m={className:"",percent:0,prefixCls:"rc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,style:{},trailColor:"#D9D9D9",trailWidth:1},y=function(H){var z=H.map(function(){return Object(N.useRef)()}),B=Object(N.useRef)();return Object(N.useEffect)(function(){var k=Date.now(),K=!1;Object.keys(z).forEach(function(Y){var ne=z[Y].current;if(!ne)return;K=!0;var oe=ne.style;oe.transitionDuration=".3s, .3s, .3s, .06s",B.current&&k-B.current<100&&(oe.transitionDuration="0s, 0s")}),K&&(B.current=Date.now())}),[z]};function w(){return w=Object.assign||function(W){for(var H=1;H<arguments.length;H++){var z=arguments[H];for(var B in z)Object.prototype.hasOwnProperty.call(z,B)&&(W[B]=z[B])}return W},w.apply(this,arguments)}function b(W,H){return r(W)||c(W,H)||d(W,H)||p()}function p(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function d(W,H){if(!W)return;if(typeof W=="string")return n(W,H);var z=Object.prototype.toString.call(W).slice(8,-1);if(z==="Object"&&W.constructor&&(z=W.constructor.name),z==="Map"||z==="Set")return Array.from(W);if(z==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(z))return n(W,H)}function n(W,H){(H==null||H>W.length)&&(H=W.length);for(var z=0,B=new Array(H);z<H;z++)B[z]=W[z];return B}function c(W,H){if(typeof Symbol=="undefined"||!(Symbol.iterator in Object(W)))return;var z=[],B=!0,k=!1,K=void 0;try{for(var Y=W[Symbol.iterator](),ne;!(B=(ne=Y.next()).done)&&!(z.push(ne.value),H&&z.length===H);B=!0);}catch(oe){k=!0,K=oe}finally{try{!B&&Y.return!=null&&Y.return()}finally{if(k)throw K}}return z}function r(W){if(Array.isArray(W))return W}function i(W,H){if(W==null)return{};var z=o(W,H),B,k;if(Object.getOwnPropertySymbols){var K=Object.getOwnPropertySymbols(W);for(k=0;k<K.length;k++){if(B=K[k],H.indexOf(B)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(W,B))continue;z[B]=W[B]}}return z}function o(W,H){if(W==null)return{};var z={},B=Object.keys(W),k,K;for(K=0;K<B.length;K++){if(k=B[K],H.indexOf(k)>=0)continue;z[k]=W[k]}return z}var u=function(H){var z=H.className,B=H.percent,k=H.prefixCls,K=H.strokeColor,Y=H.strokeLinecap,ne=H.strokeWidth,oe=H.style,_e=H.trailColor,xe=H.trailWidth,le=H.transition,me=i(H,["className","percent","prefixCls","strokeColor","strokeLinecap","strokeWidth","style","trailColor","trailWidth","transition"]);delete me.gapPosition;var de=Array.isArray(B)?B:[B],ae=Array.isArray(K)?K:[K],ie=y(de),q=b(ie,1),ue=q[0],Z=ne/2,ee=100-ne/2,Ee="M ".concat(Y==="round"?Z:0,",").concat(Z,`
L `).concat(Y==="round"?ee:100,",").concat(Z),te="0 0 100 ".concat(ne),J=0;return v.a.createElement("svg",w({className:M()("".concat(k,"-line"),z),viewBox:te,preserveAspectRatio:"none",style:oe},me),v.a.createElement("path",{className:"".concat(k,"-line-trail"),d:Ee,strokeLinecap:Y,stroke:_e,strokeWidth:xe||ne,fillOpacity:"0"}),de.map(function(X,$){var ge={strokeDasharray:"".concat(X,"px, 100px"),strokeDashoffset:"-".concat(J,"px"),transition:le||"stroke-dashoffset 0.3s ease 0s, stroke-dasharray .3s ease 0s, stroke 0.3s linear"},fe=ae[$]||ae[ae.length-1];return J+=X,v.a.createElement("path",{key:$,className:"".concat(k,"-line-path"),d:Ee,strokeLinecap:Y,stroke:fe,strokeWidth:ne,fillOpacity:"0",ref:ue[$],style:ge})}))};u.defaultProps=m;var f=u;function s(){return s=Object.assign||function(W){for(var H=1;H<arguments.length;H++){var z=arguments[H];for(var B in z)Object.prototype.hasOwnProperty.call(z,B)&&(W[B]=z[B])}return W},s.apply(this,arguments)}function l(W,H){return R(W)||h(W,H)||S(W,H)||t()}function t(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function S(W,H){if(!W)return;if(typeof W=="string")return x(W,H);var z=Object.prototype.toString.call(W).slice(8,-1);if(z==="Object"&&W.constructor&&(z=W.constructor.name),z==="Map"||z==="Set")return Array.from(W);if(z==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(z))return x(W,H)}function x(W,H){(H==null||H>W.length)&&(H=W.length);for(var z=0,B=new Array(H);z<H;z++)B[z]=W[z];return B}function h(W,H){if(typeof Symbol=="undefined"||!(Symbol.iterator in Object(W)))return;var z=[],B=!0,k=!1,K=void 0;try{for(var Y=W[Symbol.iterator](),ne;!(B=(ne=Y.next()).done)&&!(z.push(ne.value),H&&z.length===H);B=!0);}catch(oe){k=!0,K=oe}finally{try{!B&&Y.return!=null&&Y.return()}finally{if(k)throw K}}return z}function R(W){if(Array.isArray(W))return W}function O(W,H){if(W==null)return{};var z=g(W,H),B,k;if(Object.getOwnPropertySymbols){var K=Object.getOwnPropertySymbols(W);for(k=0;k<K.length;k++){if(B=K[k],H.indexOf(B)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(W,B))continue;z[B]=W[B]}}return z}function g(W,H){if(W==null)return{};var z={},B=Object.keys(W),k,K;for(K=0;K<B.length;K++){if(k=B[K],H.indexOf(k)>=0)continue;z[k]=W[k]}return z}var _=0;function E(W){return+W.replace("%","")}function T(W){return Array.isArray(W)?W:[W]}function L(W,H,z,B){var k=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,K=arguments.length>5?arguments[5]:void 0,Y=50-B/2,ne=0,oe=-Y,_e=0,xe=-2*Y;switch(K){case"left":ne=-Y,oe=0,_e=2*Y,xe=0;break;case"right":ne=Y,oe=0,_e=-2*Y,xe=0;break;case"bottom":oe=Y,xe=2*Y;break;default:}var le="M 50,50 m ".concat(ne,",").concat(oe,`
a `).concat(Y,",").concat(Y," 0 1 1 ").concat(_e,",").concat(-xe,`
a `).concat(Y,",").concat(Y," 0 1 1 ").concat(-_e,",").concat(xe),me=Math.PI*2*Y,de={stroke:z,strokeDasharray:"".concat(H/100*(me-k),"px ").concat(me,"px"),strokeDashoffset:"-".concat(k/2+W/100*(me-k),"px"),transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s"};return{pathString:le,pathStyle:de}}var I=function(H){var z=H.prefixCls,B=H.strokeWidth,k=H.trailWidth,K=H.gapDegree,Y=H.gapPosition,ne=H.trailColor,oe=H.strokeLinecap,_e=H.style,xe=H.className,le=H.strokeColor,me=H.percent,de=O(H,["prefixCls","strokeWidth","trailWidth","gapDegree","gapPosition","trailColor","strokeLinecap","style","className","strokeColor","percent"]),ae=Object(N.useMemo)(function(){return _+=1,_},[]),ie=L(0,100,ne,B,K,Y),q=ie.pathString,ue=ie.pathStyle,Z=T(me),ee=T(le),Ee=ee.find(function(ge){return Object.prototype.toString.call(ge)==="[object Object]"}),te=y(Z),J=l(te,1),X=J[0],$=function(){var fe=0;return Z.map(function(Te,ze){var Xe=ee[ze]||ee[ee.length-1],Ye=Object.prototype.toString.call(Xe)==="[object Object]"?"url(#".concat(z,"-gradient-").concat(ae,")"):"",rt=L(fe,Te,Xe,B,K,Y);return fe+=Te,v.a.createElement("path",{key:ze,className:"".concat(z,"-circle-path"),d:rt.pathString,stroke:Ye,strokeLinecap:oe,strokeWidth:B,opacity:Te===0?0:1,fillOpacity:"0",style:rt.pathStyle,ref:X[ze]})})};return v.a.createElement("svg",s({className:M()("".concat(z,"-circle"),xe),viewBox:"0 0 100 100",style:_e},de),Ee&&v.a.createElement("defs",null,v.a.createElement("linearGradient",{id:"".concat(z,"-gradient-").concat(ae),x1:"100%",y1:"0%",x2:"0%",y2:"0%"},Object.keys(Ee).sort(function(ge,fe){return E(ge)-E(fe)}).map(function(ge,fe){return v.a.createElement("stop",{key:fe,offset:ge,stopColor:Ee[ge]})}))),v.a.createElement("path",{className:"".concat(z,"-circle-trail"),d:q,stroke:ne,strokeLinecap:oe,strokeWidth:k||B,fillOpacity:"0",style:ue}),$().reverse())};I.defaultProps=m;var P=I,G={Line:f,Circle:P}},hW8S:function(F,Q,j){"use strict";j.d(Q,"a",function(){return M}),j.d(Q,"c",function(){return m}),j.d(Q,"b",function(){return y});var N=j("VTBJ"),v=j("Ff2n"),C=j("Kwbf"),M="RC_TABLE_INTERNAL_COL_DEFINE";function m(w){var b=w.expandable,p=Object(v.a)(w,["expandable"]);return"expandable"in w?Object(N.a)(Object(N.a)({},p),b):p}function y(w){return Object.keys(w).reduce(function(b,p){return(p.substr(0,5)==="data-"||p.substr(0,5)==="aria-")&&(b[p]=w[p]),b},{})}},jO9C:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.pad.Iso97971={pad:function(v,C){v.concat(N.lib.WordArray.create([2147483648],1)),N.pad.ZeroPadding.pad(v,C)},unpad:function(v){N.pad.ZeroPadding.unpad(v),v.sigBytes--}},N.pad.Iso97971})},jwmR:function(F,Q,j){F.exports={flexRow:"flexRow___3nMh-",flexColumn:"flexColumn___Xpn5L",formWrap:"formWrap___3t9mN",example:"example___5c8Eu",footerWrap:"footerWrap___20Wal"}},k3GJ:function(F,Q,j){"use strict";j.d(Q,"a",function(){return mr});var N=j("rePB"),v=j("ODXe"),C=j("Ff2n"),M=j("VTBJ"),m=j("cDcd"),y=j("TSYQ"),w=j.n(y),b=j("Zm9Q"),p=j("6cGi"),d=j("KQm4"),n=j("xEkU"),c=j.n(n),r=j("t23M");function i(Ae){var Ue=Object(m.useRef)(),Ke=Object(m.useRef)(!1);function Le(){for(var he=arguments.length,Oe=new Array(he),be=0;be<he;be++)Oe[be]=arguments[be];Ke.current||(c.a.cancel(Ue.current),Ue.current=c()(function(){Ae.apply(void 0,Oe)}))}return Object(m.useEffect)(function(){return function(){Ke.current=!0,c.a.cancel(Ue.current)}},[]),Le}function o(Ae){var Ue=Object(m.useRef)([]),Ke=Object(m.useState)({}),Le=Object(v.a)(Ke,2),he=Le[1],Oe=Object(m.useRef)(typeof Ae=="function"?Ae():Ae),be=i(function(){var Fe=Oe.current;Ue.current.forEach(function(Be){Fe=Be(Fe)}),Ue.current=[],Oe.current=Fe,he({})});function De(Fe){Ue.current.push(Fe),be()}return[Oe.current,De]}var u=j("4IlW");function f(Ae,Ue){var Ke,Le=Ae.prefixCls,he=Ae.id,Oe=Ae.active,be=Ae.rtl,De=Ae.tab,Fe=De.key,Be=De.tab,je=De.disabled,Ge=De.closeIcon,it=Ae.tabBarGutter,Et=Ae.tabPosition,St=Ae.closable,Nt=Ae.renderWrapper,_r=Ae.removeAriaLabel,Nr=Ae.editable,Pr=Ae.onClick,Br=Ae.onRemove,Ir=Ae.onFocus,Kr="".concat(Le,"-tab");m.useEffect(function(){return Br},[]);var zr={};Et==="top"||Et==="bottom"?zr[be?"marginLeft":"marginRight"]=it:zr.marginBottom=it;var on=Nr&&St!==!1&&!je;function $r(wr){if(je)return;Pr(wr)}function gn(wr){wr.preventDefault(),wr.stopPropagation(),Nr.onEdit("remove",{key:Fe,event:wr})}var Zr=m.createElement("div",{key:Fe,ref:Ue,className:w()(Kr,(Ke={},Object(N.a)(Ke,"".concat(Kr,"-with-remove"),on),Object(N.a)(Ke,"".concat(Kr,"-active"),Oe),Object(N.a)(Ke,"".concat(Kr,"-disabled"),je),Ke)),style:zr,onClick:$r},m.createElement("div",{role:"tab","aria-selected":Oe,id:he&&"".concat(he,"-tab-").concat(Fe),className:"".concat(Kr,"-btn"),"aria-controls":he&&"".concat(he,"-panel-").concat(Fe),"aria-disabled":je,tabIndex:je?null:0,onClick:function(Ar){Ar.stopPropagation(),$r(Ar)},onKeyDown:function(Ar){[u.a.SPACE,u.a.ENTER].includes(Ar.which)&&(Ar.preventDefault(),$r(Ar))},onFocus:Ir},Be),on&&m.createElement("button",{type:"button","aria-label":_r||"remove",tabIndex:0,className:"".concat(Kr,"-remove"),onClick:function(Ar){Ar.stopPropagation(),gn(Ar)}},Ge||Nr.removeIcon||"\xD7"));return Nt&&(Zr=Nt(Zr)),Zr}var s=m.forwardRef(f),l={width:0,height:0,left:0,top:0};function t(Ae,Ue,Ke){return Object(m.useMemo)(function(){for(var Le,he=new Map,Oe=Ue.get((Le=Ae[0])===null||Le===void 0?void 0:Le.key)||l,be=Oe.left+Oe.width,De=0;De<Ae.length;De+=1){var Fe=Ae[De].key,Be=Ue.get(Fe);if(!Be){var je;Be=Ue.get((je=Ae[De-1])===null||je===void 0?void 0:je.key)||l}var Ge=he.get(Fe)||Object(M.a)({},Be);Ge.right=be-Ge.left-Ge.width,he.set(Fe,Ge)}return he},[Ae.map(function(Le){return Le.key}).join("_"),Ue,Ke])}var S={width:0,height:0,left:0,top:0,right:0};function x(Ae,Ue,Ke,Le,he){var Oe=he.tabs,be=he.tabPosition,De=he.rtl,Fe,Be,je;["top","bottom"].includes(be)?(Fe="width",Be=De?"right":"left",je=Math.abs(Ue.left)):(Fe="height",Be="top",je=-Ue.top);var Ge=Ue[Fe],it=Ke[Fe],Et=Le[Fe],St=Ge;return it+Et>Ge&&(St=Ge-Et),Object(m.useMemo)(function(){if(!Oe.length)return[0,0];for(var Nt=Oe.length,_r=Nt,Nr=0;Nr<Nt;Nr+=1){var Pr=Ae.get(Oe[Nr].key)||S;if(Pr[Be]+Pr[Fe]>je+St){_r=Nr-1;break}}for(var Br=0,Ir=Nt-1;Ir>=0;Ir-=1){var Kr=Ae.get(Oe[Ir].key)||S;if(Kr[Be]<je){Br=Ir+1;break}}return[Br,_r]},[Ae,je,St,be,Oe.map(function(Nt){return Nt.key}).join("_"),De])}var h=j("wx14"),R=j("1OyB"),O=j("vuIU"),g=j("JX7q"),_=j("Ji7U"),E=j("LK+K"),T=j("I8Z2"),L=j("bT9E"),I=j("2GS6"),P=j("Gytx"),G=j.n(P),W=j("U8pU"),H=/iPhone/i,z=/iPod/i,B=/iPad/i,k=/\bAndroid(?:.+)Mobile\b/i,K=/Android/i,Y=/\bAndroid(?:.+)SD4930UR\b/i,ne=/\bAndroid(?:.+)(?:KF[A-Z]{2,4})\b/i,oe=/Windows Phone/i,_e=/\bWindows(?:.+)ARM\b/i,xe=/BlackBerry/i,le=/BB10/i,me=/Opera Mini/i,de=/\b(CriOS|Chrome)(?:.+)Mobile/i,ae=/Mobile(?:.+)Firefox\b/i;function ie(Ae,Ue){return Ae.test(Ue)}function q(Ae){var Ue=Ae||(typeof navigator!="undefined"?navigator.userAgent:""),Ke=(Ue||"").split("[FBAN");if(typeof Ke[1]!="undefined"){var Le=Ke,he=Object(v.a)(Le,1);Ue=he[0]}if(Ke=Ue.split("Twitter"),typeof Ke[1]!="undefined"){var Oe=Ke,be=Object(v.a)(Oe,1);Ue=be[0]}var De={apple:{phone:ie(H,Ue)&&!ie(oe,Ue),ipod:ie(z,Ue),tablet:!ie(H,Ue)&&ie(B,Ue)&&!ie(oe,Ue),device:(ie(H,Ue)||ie(z,Ue)||ie(B,Ue))&&!ie(oe,Ue)},amazon:{phone:ie(Y,Ue),tablet:!ie(Y,Ue)&&ie(ne,Ue),device:ie(Y,Ue)||ie(ne,Ue)},android:{phone:!ie(oe,Ue)&&ie(Y,Ue)||!ie(oe,Ue)&&ie(k,Ue),tablet:!ie(oe,Ue)&&!ie(Y,Ue)&&!ie(k,Ue)&&(ie(ne,Ue)||ie(K,Ue)),device:!ie(oe,Ue)&&(ie(Y,Ue)||ie(ne,Ue)||ie(k,Ue)||ie(K,Ue))||ie(/\bokhttp\b/i,Ue)},windows:{phone:ie(oe,Ue),tablet:ie(_e,Ue),device:ie(oe,Ue)||ie(_e,Ue)},other:{blackberry:ie(xe,Ue),blackberry10:ie(le,Ue),opera:ie(me,Ue),firefox:ie(ae,Ue),chrome:ie(de,Ue),device:ie(xe,Ue)||ie(le,Ue)||ie(me,Ue)||ie(ae,Ue)||ie(de,Ue)},any:null,phone:null,tablet:null};return De.any=De.apple.device||De.android.device||De.windows.device||De.other.device,De.phone=De.apple.phone||De.android.phone||De.windows.phone,De.tablet=De.apple.tablet||De.android.tablet||De.windows.tablet,De}var ue=Object(M.a)(Object(M.a)({},q()),{},{isMobile:q}),Z=ue;function ee(){}function Ee(Ae,Ue,Ke){var Le=Ue||"";return Ae.key||"".concat(Le,"item_").concat(Ke)}function te(Ae){return"".concat(Ae,"-menu-")}function J(Ae,Ue){var Ke=-1;m.Children.forEach(Ae,function(Le){Ke+=1,Le&&Le.type&&Le.type.isMenuItemGroup?m.Children.forEach(Le.props.children,function(he){Ke+=1,Ue(he,Ke)}):Ue(Le,Ke)})}function X(Ae,Ue,Ke){if(!Ae||Ke.find)return;m.Children.forEach(Ae,function(Le){if(Le){var he=Le.type;if(!he||!(he.isSubMenu||he.isMenuItem||he.isMenuItemGroup))return;Ue.indexOf(Le.key)!==-1?Ke.find=!0:Le.props.children&&X(Le.props.children,Ue,Ke)}})}var $=["defaultSelectedKeys","selectedKeys","defaultOpenKeys","openKeys","mode","getPopupContainer","onSelect","onDeselect","onDestroy","openTransitionName","openAnimation","subMenuOpenDelay","subMenuCloseDelay","forceSubMenuRender","triggerSubMenuAction","level","selectable","multiple","onOpenChange","visible","focusable","defaultActiveFirst","prefixCls","inlineIndent","parentMenu","title","rootPrefixCls","eventKey","active","onItemHover","onTitleMouseEnter","onTitleMouseLeave","onTitleClick","popupAlign","popupOffset","isOpen","renderMenuItem","manualRef","subMenuKey","disabled","index","isSelected","store","activeKey","builtinPlacements","overflowedIndicator","motion","attribute","value","popupClassName","inlineCollapsed","menu","theme","itemIcon","expandIcon"],ge=function(Ue){var Ke=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Le=Ue&&typeof Ue.getBoundingClientRect=="function"&&Ue.getBoundingClientRect().width;if(Le){if(Ke){var he=getComputedStyle(Ue),Oe=he.marginLeft,be=he.marginRight;Le+=+Oe.replace("px","")+ +be.replace("px","")}Le=+Le.toFixed(6)}return Le||0},fe=function(Ue,Ke,Le){Ue&&Object(W.a)(Ue.style)==="object"&&(Ue.style[Ke]=Le)},Te=function(){return Z.any},ze=j("bdgK"),Xe=j("faye"),Ye=j.n(Xe),rt=j("wgJM"),at=j("l4aY"),ot=j("m+aA"),Pe=j("c+Xe"),Se=j("zT1h"),Je=j("QC+M");function nt(Ae,Ue,Ke){return Ke?Ae[0]===Ue[0]:Ae[0]===Ue[0]&&Ae[1]===Ue[1]}function We(Ae,Ue,Ke){var Le=Ae[Ue]||{};return Object(M.a)(Object(M.a)({},Le),Ke)}function et(Ae,Ue,Ke,Le){for(var he=Ke.points,Oe=Object.keys(Ae),be=0;be<Oe.length;be+=1){var De=Oe[be];if(nt(Ae[De].points,he,Le))return"".concat(Ue,"-placement-").concat(De)}return""}var Me=function(){if(typeof navigator=="undefined"||typeof window=="undefined")return!1;var Ae=navigator.userAgent||navigator.vendor||window.opera;return!!(/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(Ae)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(Ae==null?void 0:Ae.substr(0,4)))},Ce=j("MNnm");function Re(Ae,Ue){var Ke={};return Ke[Ae.toLowerCase()]=Ue.toLowerCase(),Ke["Webkit".concat(Ae)]="webkit".concat(Ue),Ke["Moz".concat(Ae)]="moz".concat(Ue),Ke["ms".concat(Ae)]="MS".concat(Ue),Ke["O".concat(Ae)]="o".concat(Ue.toLowerCase()),Ke}function pe(Ae,Ue){var Ke={animationend:Re("Animation","AnimationEnd"),transitionend:Re("Transition","TransitionEnd")};return Ae&&("AnimationEvent"in Ue||delete Ke.animationend.animation,"TransitionEvent"in Ue||delete Ke.transitionend.transition),Ke}var ye=pe(Object(Ce.a)(),typeof window!="undefined"?window:{}),we={};if(Object(Ce.a)()){var Ie=document.createElement("div");we=Ie.style}var ke={};function Ve(Ae){if(ke[Ae])return ke[Ae];var Ue=ye[Ae];if(Ue)for(var Ke=Object.keys(Ue),Le=Ke.length,he=0;he<Le;he+=1){var Oe=Ke[he];if(Object.prototype.hasOwnProperty.call(Ue,Oe)&&Oe in we)return ke[Ae]=Ue[Oe],ke[Ae]}return""}var ut=Ve("animationend"),ct=Ve("transitionend"),Lt=!!(ut&&ct),Dt=ut||"animationend",Er=ct||"transitionend";function rr(Ae,Ue){if(!Ae)return null;if(Object(W.a)(Ae)==="object"){var Ke=Ue.replace(/-\w/g,function(Le){return Le[1].toUpperCase()});return Ae[Ke]}return"".concat(Ae,"-").concat(Ue)}var xt="none",kr="appear",Mr="enter",Ur="leave",ln="none",Sr="prepare",an="start",qr="active",Bt="end";function ur(Ae){var Ue=Object(m.useRef)(!1),Ke=Object(m.useState)(Ae),Le=Object(v.a)(Ke,2),he=Le[0],Oe=Le[1];function be(De){Ue.current||Oe(De)}return Object(m.useEffect)(function(){return function(){Ue.current=!0}},[]),[he,be]}var jr=Object(Ce.a)()?m.useLayoutEffect:m.useEffect,en=jr,Jr=function(){var Ae=m.useRef(null);function Ue(){rt.a.cancel(Ae.current)}function Ke(Le){var he=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2;Ue();var Oe=Object(rt.a)(function(){he<=1?Le({isCanceled:function(){return Oe!==Ae.current}}):Ke(Le,he-1)});Ae.current=Oe}return m.useEffect(function(){return function(){Ue()}},[]),[Ke,Ue]},_a=[Sr,an,qr,Bt],Wa=!1,_n=!0;function er(Ae){return Ae===qr||Ae===Bt}var Xn=function(Ae,Ue){var Ke=m.useState(ln),Le=Object(v.a)(Ke,2),he=Le[0],Oe=Le[1],be=Jr(),De=Object(v.a)(be,2),Fe=De[0],Be=De[1];function je(){Oe(Sr)}return en(function(){if(he!==ln&&he!==Bt){var Ge=_a.indexOf(he),it=_a[Ge+1],Et=Ue(he);Et===Wa?Oe(it):Fe(function(St){function Nt(){if(St.isCanceled())return;Oe(it)}Et===!0?Nt():Promise.resolve(Et).then(Nt)})}},[Ae,he]),m.useEffect(function(){return function(){Be()}},[]),[je,he]},Ea=function(Ae){var Ue=Object(m.useRef)(),Ke=Object(m.useRef)(Ae);Ke.current=Ae;var Le=m.useCallback(function(be){Ke.current(be)},[]);function he(be){be&&(be.removeEventListener(Er,Le),be.removeEventListener(Dt,Le))}function Oe(be){Ue.current&&Ue.current!==be&&he(Ue.current),be&&be!==Ue.current&&(be.addEventListener(Er,Le),be.addEventListener(Dt,Le),Ue.current=be)}return m.useEffect(function(){return function(){he(Ue.current)}},[]),[Oe,he]};function Pn(Ae,Ue,Ke,Le){var he=Le.motionEnter,Oe=he===void 0?!0:he,be=Le.motionAppear,De=be===void 0?!0:be,Fe=Le.motionLeave,Be=Fe===void 0?!0:Fe,je=Le.motionDeadline,Ge=Le.motionLeaveImmediately,it=Le.onAppearPrepare,Et=Le.onEnterPrepare,St=Le.onLeavePrepare,Nt=Le.onAppearStart,_r=Le.onEnterStart,Nr=Le.onLeaveStart,Pr=Le.onAppearActive,Br=Le.onEnterActive,Ir=Le.onLeaveActive,Kr=Le.onAppearEnd,zr=Le.onEnterEnd,on=Le.onLeaveEnd,$r=Le.onVisibleChanged,gn=ur(),Zr=Object(v.a)(gn,2),wr=Zr[0],Ar=Zr[1],Xr=ur(xt),nn=Object(v.a)(Xr,2),fr=nn[0],un=nn[1],An=ur(null),fn=Object(v.a)(An,2),En=fn[0],hn=fn[1],Fn=Object(m.useRef)(!1),Kn=Object(m.useRef)(null),Rn=Object(m.useRef)(!1),Zn=Object(m.useRef)(null);function Na(){var bn=Ke();return bn||Zn.current}var ua=Object(m.useRef)(!1);function zn(bn){var pn=Na();if(bn&&!bn.deadline&&bn.target!==pn)return;var Hn;fr===kr&&ua.current?Hn=Kr==null?void 0:Kr(pn,bn):fr===Mr&&ua.current?Hn=zr==null?void 0:zr(pn,bn):fr===Ur&&ua.current&&(Hn=on==null?void 0:on(pn,bn)),Hn!==!1&&!Rn.current&&(un(xt),hn(null))}var xn=Ea(zn),Tn=Object(v.a)(xn,1),In=Tn[0],Cn=m.useMemo(function(){var bn,pn,Hn;switch(fr){case"appear":return bn={},Object(N.a)(bn,Sr,it),Object(N.a)(bn,an,Nt),Object(N.a)(bn,qr,Pr),bn;case"enter":return pn={},Object(N.a)(pn,Sr,Et),Object(N.a)(pn,an,_r),Object(N.a)(pn,qr,Br),pn;case"leave":return Hn={},Object(N.a)(Hn,Sr,St),Object(N.a)(Hn,an,Nr),Object(N.a)(Hn,qr,Ir),Hn;default:return{}}},[fr]),Bn=Xn(fr,function(bn){if(bn===Sr){var pn=Cn[Sr];return pn?pn(Na()):Wa}if(mn in Cn){var Hn;hn(((Hn=Cn[mn])===null||Hn===void 0?void 0:Hn.call(Cn,Na(),null))||null)}return mn===qr&&(In(Na()),je>0&&(clearTimeout(Kn.current),Kn.current=setTimeout(function(){zn({deadline:!0})},je))),_n}),ga=Object(v.a)(Bn,2),Va=ga[0],mn=ga[1],Ca=er(mn);ua.current=Ca,en(function(){Ar(Ue);var bn=Fn.current;if(Fn.current=!0,!Ae)return;var pn;!bn&&Ue&&De&&(pn=kr),bn&&Ue&&Oe&&(pn=Mr),(bn&&!Ue&&Be||!bn&&Ge&&!Ue&&Be)&&(pn=Ur),pn&&(un(pn),Va())},[Ue]),Object(m.useEffect)(function(){(fr===kr&&!De||fr===Mr&&!Oe||fr===Ur&&!Be)&&un(xt)},[De,Oe,Be]),Object(m.useEffect)(function(){return function(){clearTimeout(Kn.current),Rn.current=!0}},[]),Object(m.useEffect)(function(){wr!==void 0&&fr===xt&&($r==null||$r(wr))},[wr,fr]);var Aa=En;return Cn[Sr]&&mn===an&&(Aa=Object(M.a)({transition:"none"},Aa)),[fr,mn,Aa,wr!=null?wr:Ue]}var Qr=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(){return Object(R.a)(this,Ke),Ue.apply(this,arguments)}return Object(O.a)(Ke,[{key:"render",value:function(){return this.props.children}}]),Ke}(m.Component),Ln=Qr;function la(Ae){var Ue=Ae;Object(W.a)(Ae)==="object"&&(Ue=Ae.transitionSupport);function Ke(he){return!!(he.motionName&&Ue)}var Le=m.forwardRef(function(he,Oe){var be=he.visible,De=be===void 0?!0:be,Fe=he.removeOnLeave,Be=Fe===void 0?!0:Fe,je=he.forceRender,Ge=he.children,it=he.motionName,Et=he.leavedClassName,St=he.eventProps,Nt=Ke(he),_r=Object(m.useRef)(),Nr=Object(m.useRef)();function Pr(){try{return Object(ot.a)(_r.current||Nr.current)}catch(un){return null}}var Br=Pn(Nt,De,Pr,he),Ir=Object(v.a)(Br,4),Kr=Ir[0],zr=Ir[1],on=Ir[2],$r=Ir[3],gn=m.useRef($r);$r&&(gn.current=!0);var Zr=Object(m.useRef)(Oe);Zr.current=Oe;var wr=m.useCallback(function(un){_r.current=un,Object(Pe.b)(Zr.current,un)},[]),Ar,Xr=Object(M.a)(Object(M.a)({},St),{},{visible:De});if(!Ge)Ar=null;else if(Kr===xt||!Ke(he))$r?Ar=Ge(Object(M.a)({},Xr),wr):!Be&&gn.current?Ar=Ge(Object(M.a)(Object(M.a)({},Xr),{},{className:Et}),wr):je?Ar=Ge(Object(M.a)(Object(M.a)({},Xr),{},{style:{display:"none"}}),wr):Ar=null;else{var nn,fr;zr===Sr?fr="prepare":er(zr)?fr="active":zr===an&&(fr="start"),Ar=Ge(Object(M.a)(Object(M.a)({},Xr),{},{className:w()(rr(it,Kr),(nn={},Object(N.a)(nn,rr(it,"".concat(Kr,"-").concat(fr)),fr),Object(N.a)(nn,it,typeof it=="string"),nn)),style:on}),wr)}return m.createElement(Ln,{ref:Nr},Ar)});return Le.displayName="CSSMotion",Le}var fa=la(Lt),It="add",dr="keep",ha="remove",xa="removed";function Pa(Ae){var Ue;return Ae&&Object(W.a)(Ae)==="object"&&"key"in Ae?Ue=Ae:Ue={key:Ae},Object(M.a)(Object(M.a)({},Ue),{},{key:String(Ue.key)})}function pa(){var Ae=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return Ae.map(Pa)}function kn(){var Ae=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],Ue=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],Ke=[],Le=0,he=Ue.length,Oe=pa(Ae),be=pa(Ue);Oe.forEach(function(Be){for(var je=!1,Ge=Le;Ge<he;Ge+=1){var it=be[Ge];if(it.key===Be.key){Le<Ge&&(Ke=Ke.concat(be.slice(Le,Ge).map(function(Et){return Object(M.a)(Object(M.a)({},Et),{},{status:It})})),Le=Ge),Ke.push(Object(M.a)(Object(M.a)({},it),{},{status:dr})),Le+=1,je=!0;break}}je||Ke.push(Object(M.a)(Object(M.a)({},Be),{},{status:ha}))}),Le<he&&(Ke=Ke.concat(be.slice(Le).map(function(Be){return Object(M.a)(Object(M.a)({},Be),{},{status:It})})));var De={};Ke.forEach(function(Be){var je=Be.key;De[je]=(De[je]||0)+1});var Fe=Object.keys(De).filter(function(Be){return De[Be]>1});return Fe.forEach(function(Be){Ke=Ke.filter(function(je){var Ge=je.key,it=je.status;return Ge!==Be||it!==ha}),Ke.forEach(function(je){je.key===Be&&(je.status=dr)})}),Ke}var xr=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function ta(Ae){var Ue=arguments.length>1&&arguments[1]!==void 0?arguments[1]:fa,Ke=function(Le){Object(_.a)(Oe,Le);var he=Object(E.a)(Oe);function Oe(){var be;return Object(R.a)(this,Oe),be=he.apply(this,arguments),be.state={keyEntities:[]},be.removeKey=function(De){be.setState(function(Fe){var Be=Fe.keyEntities;return{keyEntities:Be.map(function(je){return je.key!==De?je:Object(M.a)(Object(M.a)({},je),{},{status:xa})})}})},be}return Object(O.a)(Oe,[{key:"render",value:function(){var De=this,Fe=this.state.keyEntities,Be=this.props,je=Be.component,Ge=Be.children,it=Be.onVisibleChanged,Et=Object(C.a)(Be,["component","children","onVisibleChanged"]),St=je||m.Fragment,Nt={};return xr.forEach(function(_r){Nt[_r]=Et[_r],delete Et[_r]}),delete Et.keys,m.createElement(St,Et,Fe.map(function(_r){var Nr=_r.status,Pr=Object(C.a)(_r,["status"]),Br=Nr===It||Nr===dr;return m.createElement(Ue,Object(h.a)({},Nt,{key:Pr.key,visible:Br,eventProps:Pr,onVisibleChanged:function(Kr){it==null||it(Kr,{key:Pr.key}),Kr||De.removeKey(Pr.key)}}),Ge)}))}}],[{key:"getDerivedStateFromProps",value:function(De,Fe){var Be=De.keys,je=Fe.keyEntities,Ge=pa(Be),it=kn(je,Ge);return{keyEntities:it.filter(function(Et){var St=je.find(function(Nt){var _r=Nt.key;return Et.key===_r});return!(St&&St.status===xa&&Et.status===ha)})}}}]),Oe}(m.Component);return Ke.defaultProps={component:"div"},Ke}var Ct=ta(Lt),Vn=fa;function Mn(Ae){var Ue=Ae.prefixCls,Ke=Ae.motion,Le=Ae.animation,he=Ae.transitionName;return Ke||(Le?{motionName:"".concat(Ue,"-").concat(Le)}:he?{motionName:he}:null)}function Ka(Ae){var Ue=Ae.prefixCls,Ke=Ae.visible,Le=Ae.zIndex,he=Ae.mask,Oe=Ae.maskMotion,be=Ae.maskAnimation,De=Ae.maskTransitionName;if(!he)return null;var Fe={};return(Oe||De||be)&&(Fe=Object(M.a)({motionAppear:!0},Mn({motion:Oe,prefixCls:Ue,transitionName:De,animation:be}))),m.createElement(Vn,Object(h.a)({},Fe,{visible:Ke,removeOnLeave:!0}),function(Be){var je=Be.className;return m.createElement("div",{style:{zIndex:Le},className:w()("".concat(Ue,"-mask"),je)})})}var Ta=j("9mu1"),Qn=j("o0o1"),Qa=j.n(Qn),Za=j("HaE+"),ra=["measure","align",null,"motion"],wn=function(Ae,Ue){var Ke=Object(m.useState)(null),Le=Object(v.a)(Ke,2),he=Le[0],Oe=Le[1],be=Object(m.useRef)(),De=Object(m.useRef)(!1);function Fe(Ge){De.current||Oe(Ge)}function Be(){rt.a.cancel(be.current)}function je(Ge){Be(),be.current=Object(rt.a)(function(){Fe(function(it){switch(he){case"align":return"motion";case"motion":return"stable";default:}return it}),Ge==null||Ge()})}return Object(m.useEffect)(function(){Fe("measure")},[Ae]),Object(m.useEffect)(function(){switch(he){case"measure":Ue();break;default:}he&&(be.current=Object(rt.a)(Object(Za.a)(Qa.a.mark(function Ge(){var it,Et;return Qa.a.wrap(function(Nt){for(;;)switch(Nt.prev=Nt.next){case 0:it=ra.indexOf(he),Et=ra[it+1],Et&&it!==-1&&Fe(Et);case 3:case"end":return Nt.stop()}},Ge)}))))},[he]),Object(m.useEffect)(function(){return function(){De.current=!0,Be()}},[]),[he,je]},na=function(Ae){var Ue=m.useState({width:0,height:0}),Ke=Object(v.a)(Ue,2),Le=Ke[0],he=Ke[1];function Oe(De){he({width:De.offsetWidth,height:De.offsetHeight})}var be=m.useMemo(function(){var De={};if(Ae){var Fe=Le.width,Be=Le.height;Ae.indexOf("height")!==-1&&Be?De.height=Be:Ae.indexOf("minHeight")!==-1&&Be&&(De.minHeight=Be),Ae.indexOf("width")!==-1&&Fe?De.width=Fe:Ae.indexOf("minWidth")!==-1&&Fe&&(De.minWidth=Fe)}return De},[Ae,Le]);return[be,Oe]},ka=m.forwardRef(function(Ae,Ue){var Ke=Ae.visible,Le=Ae.prefixCls,he=Ae.className,Oe=Ae.style,be=Ae.children,De=Ae.zIndex,Fe=Ae.stretch,Be=Ae.destroyPopupOnHide,je=Ae.forceRender,Ge=Ae.align,it=Ae.point,Et=Ae.getRootDomNode,St=Ae.getClassNameFromAlign,Nt=Ae.onAlign,_r=Ae.onMouseEnter,Nr=Ae.onMouseLeave,Pr=Ae.onMouseDown,Br=Ae.onTouchStart,Ir=Object(m.useRef)(),Kr=Object(m.useRef)(),zr=Object(m.useState)(),on=Object(v.a)(zr,2),$r=on[0],gn=on[1],Zr=na(Fe),wr=Object(v.a)(Zr,2),Ar=wr[0],Xr=wr[1];function nn(){Fe&&Xr(Et())}var fr=wn(Ke,nn),un=Object(v.a)(fr,2),An=un[0],fn=un[1],En=Object(m.useRef)();function hn(){return it||Et}function Fn(){var xn;(xn=Ir.current)===null||xn===void 0||xn.forceAlign()}function Kn(xn,Tn){var In=St(Tn);$r!==In&&gn(In),An==="align"&&($r!==In?Promise.resolve().then(function(){Fn()}):fn(function(){var Cn;(Cn=En.current)===null||Cn===void 0||Cn.call(En)}),Nt==null||Nt(xn,Tn))}var Rn=Object(M.a)({},Mn(Ae));["onAppearEnd","onEnterEnd","onLeaveEnd"].forEach(function(xn){var Tn=Rn[xn];Rn[xn]=function(In,Cn){return fn(),Tn==null?void 0:Tn(In,Cn)}});function Zn(){return new Promise(function(xn){En.current=xn})}m.useEffect(function(){!Rn.motionName&&An==="motion"&&fn()},[Rn.motionName,An]),m.useImperativeHandle(Ue,function(){return{forceAlign:Fn,getElement:function(){return Kr.current}}});var Na=Object(M.a)(Object(M.a)({},Ar),{},{zIndex:De,opacity:An==="motion"||An==="stable"||!Ke?void 0:0,pointerEvents:An==="stable"?void 0:"none"},Oe),ua=!0;(Ge==null?void 0:Ge.points)&&(An==="align"||An==="stable")&&(ua=!1);var zn=be;return m.Children.count(be)>1&&(zn=m.createElement("div",{className:"".concat(Le,"-content")},be)),m.createElement(Vn,Object(h.a)({visible:Ke,ref:Kr,leavedClassName:"".concat(Le,"-hidden")},Rn,{onAppearPrepare:Zn,onEnterPrepare:Zn,removeOnLeave:Be,forceRender:je}),function(xn,Tn){var In=xn.className,Cn=xn.style,Bn=w()(Le,he,$r,In);return m.createElement(Ta.a,{target:hn(),key:"popup",ref:Ir,monitorWindowResize:!0,disabled:ua,align:Ge,onAlign:Kn},m.createElement("div",{ref:Tn,className:Bn,onMouseEnter:_r,onMouseLeave:Nr,onMouseDownCapture:Pr,onTouchStartCapture:Br,style:Object(M.a)(Object(M.a)({},Cn),Na)},zn))})});ka.displayName="PopupInner";var ma=ka,va=m.forwardRef(function(Ae,Ue){var Ke=Ae.prefixCls,Le=Ae.visible,he=Ae.zIndex,Oe=Ae.children,be=Ae.mobile;be=be===void 0?{}:be;var De=be.popupClassName,Fe=be.popupStyle,Be=be.popupMotion,je=Be===void 0?{}:Be,Ge=be.popupRender,it=m.useRef();m.useImperativeHandle(Ue,function(){return{forceAlign:function(){},getElement:function(){return it.current}}});var Et=Object(M.a)({zIndex:he},Fe),St=Oe;return m.Children.count(Oe)>1&&(St=m.createElement("div",{className:"".concat(Ke,"-content")},Oe)),Ge&&(St=Ge(St)),m.createElement(Vn,Object(h.a)({visible:Le,ref:it,removeOnLeave:!0},je),function(Nt,_r){var Nr=Nt.className,Pr=Nt.style,Br=w()(Ke,De,Nr);return m.createElement("div",{ref:_r,className:Br,style:Object(M.a)(Object(M.a)({},Pr),Et)},St)})});va.displayName="MobilePopupInner";var Di=va,Xa=["visible","mobile"],jn=m.forwardRef(function(Ae,Ue){var Ke=Ae.visible,Le=Ae.mobile,he=Object(C.a)(Ae,Xa),Oe=Object(m.useState)(Ke),be=Object(v.a)(Oe,2),De=be[0],Fe=be[1],Be=Object(m.useState)(!1),je=Object(v.a)(Be,2),Ge=je[0],it=je[1],Et=Object(M.a)(Object(M.a)({},he),{},{visible:De});Object(m.useEffect)(function(){Fe(Ke),Ke&&Le&&it(Me())},[Ke,Le]);var St=Ge?m.createElement(Di,Object(h.a)({},Et,{mobile:Le,ref:Ue})):m.createElement(ma,Object(h.a)({},Et,{ref:Ue}));return m.createElement("div",null,m.createElement(Ka,Et),St)});jn.displayName="Popup";var za=jn,_i=m.createContext(null),Ma=_i;function aa(){}function oi(){return""}function pi(Ae){return Ae?Ae.ownerDocument:window.document}var si=["onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur","onContextMenu"];function mi(Ae){var Ue=function(Ke){Object(_.a)(he,Ke);var Le=Object(E.a)(he);function he(Oe){var be;Object(R.a)(this,he),be=Le.call(this,Oe),be.popupRef=m.createRef(),be.triggerRef=m.createRef(),be.attachId=void 0,be.clickOutsideHandler=void 0,be.touchOutsideHandler=void 0,be.contextMenuOutsideHandler1=void 0,be.contextMenuOutsideHandler2=void 0,be.mouseDownTimeout=void 0,be.focusTime=void 0,be.preClickTime=void 0,be.preTouchTime=void 0,be.delayTimer=void 0,be.hasPopupMouseDown=void 0,be.onMouseEnter=function(Fe){var Be=be.props.mouseEnterDelay;be.fireEvents("onMouseEnter",Fe),be.delaySetPopupVisible(!0,Be,Be?null:Fe)},be.onMouseMove=function(Fe){be.fireEvents("onMouseMove",Fe),be.setPoint(Fe)},be.onMouseLeave=function(Fe){be.fireEvents("onMouseLeave",Fe),be.delaySetPopupVisible(!1,be.props.mouseLeaveDelay)},be.onPopupMouseEnter=function(){be.clearDelayTimer()},be.onPopupMouseLeave=function(Fe){var Be;if(Fe.relatedTarget&&!Fe.relatedTarget.setTimeout&&Object(at.a)((Be=be.popupRef.current)===null||Be===void 0?void 0:Be.getElement(),Fe.relatedTarget))return;be.delaySetPopupVisible(!1,be.props.mouseLeaveDelay)},be.onFocus=function(Fe){be.fireEvents("onFocus",Fe),be.clearDelayTimer(),be.isFocusToShow()&&(be.focusTime=Date.now(),be.delaySetPopupVisible(!0,be.props.focusDelay))},be.onMouseDown=function(Fe){be.fireEvents("onMouseDown",Fe),be.preClickTime=Date.now()},be.onTouchStart=function(Fe){be.fireEvents("onTouchStart",Fe),be.preTouchTime=Date.now()},be.onBlur=function(Fe){be.fireEvents("onBlur",Fe),be.clearDelayTimer(),be.isBlurToHide()&&be.delaySetPopupVisible(!1,be.props.blurDelay)},be.onContextMenu=function(Fe){Fe.preventDefault(),be.fireEvents("onContextMenu",Fe),be.setPopupVisible(!0,Fe)},be.onContextMenuClose=function(){be.isContextMenuToShow()&&be.close()},be.onClick=function(Fe){if(be.fireEvents("onClick",Fe),be.focusTime){var Be;if(be.preClickTime&&be.preTouchTime?Be=Math.min(be.preClickTime,be.preTouchTime):be.preClickTime?Be=be.preClickTime:be.preTouchTime&&(Be=be.preTouchTime),Math.abs(Be-be.focusTime)<20)return;be.focusTime=0}be.preClickTime=0,be.preTouchTime=0,be.isClickToShow()&&(be.isClickToHide()||be.isBlurToHide())&&Fe&&Fe.preventDefault&&Fe.preventDefault();var je=!be.state.popupVisible;(be.isClickToHide()&&!je||je&&be.isClickToShow())&&be.setPopupVisible(!be.state.popupVisible,Fe)},be.onPopupMouseDown=function(){if(be.hasPopupMouseDown=!0,clearTimeout(be.mouseDownTimeout),be.mouseDownTimeout=window.setTimeout(function(){be.hasPopupMouseDown=!1},0),be.context){var Fe;(Fe=be.context).onPopupMouseDown.apply(Fe,arguments)}},be.onDocumentClick=function(Fe){if(be.props.mask&&!be.props.maskClosable)return;var Be=Fe.target,je=be.getRootDomNode(),Ge=be.getPopupDomNode();(!Object(at.a)(je,Be)||be.isContextMenuOnly())&&!Object(at.a)(Ge,Be)&&!be.hasPopupMouseDown&&be.close()},be.getRootDomNode=function(){var Fe=be.props.getTriggerDOMNode;if(Fe)return Fe(be.triggerRef.current);try{var Be=Object(ot.a)(be.triggerRef.current);if(Be)return Be}catch(je){}return Ye.a.findDOMNode(Object(g.a)(be))},be.getPopupClassNameFromAlign=function(Fe){var Be=[],je=be.props,Ge=je.popupPlacement,it=je.builtinPlacements,Et=je.prefixCls,St=je.alignPoint,Nt=je.getPopupClassNameFromAlign;return Ge&&it&&Be.push(et(it,Et,Fe,St)),Nt&&Be.push(Nt(Fe)),Be.join(" ")},be.getComponent=function(){var Fe=be.props,Be=Fe.prefixCls,je=Fe.destroyPopupOnHide,Ge=Fe.popupClassName,it=Fe.onPopupAlign,Et=Fe.popupMotion,St=Fe.popupAnimation,Nt=Fe.popupTransitionName,_r=Fe.popupStyle,Nr=Fe.mask,Pr=Fe.maskAnimation,Br=Fe.maskTransitionName,Ir=Fe.maskMotion,Kr=Fe.zIndex,zr=Fe.popup,on=Fe.stretch,$r=Fe.alignPoint,gn=Fe.mobile,Zr=Fe.forceRender,wr=be.state,Ar=wr.popupVisible,Xr=wr.point,nn=be.getPopupAlign(),fr={};return be.isMouseEnterToShow()&&(fr.onMouseEnter=be.onPopupMouseEnter),be.isMouseLeaveToHide()&&(fr.onMouseLeave=be.onPopupMouseLeave),fr.onMouseDown=be.onPopupMouseDown,fr.onTouchStart=be.onPopupMouseDown,m.createElement(za,Object(h.a)({prefixCls:Be,destroyPopupOnHide:je,visible:Ar,point:$r&&Xr,className:Ge,align:nn,onAlign:it,animation:St,getClassNameFromAlign:be.getPopupClassNameFromAlign},fr,{stretch:on,getRootDomNode:be.getRootDomNode,style:_r,mask:Nr,zIndex:Kr,transitionName:Nt,maskAnimation:Pr,maskTransitionName:Br,maskMotion:Ir,ref:be.popupRef,motion:Et,mobile:gn,forceRender:Zr}),typeof zr=="function"?zr():zr)},be.attachParent=function(Fe){rt.a.cancel(be.attachId);var Be=be.props,je=Be.getPopupContainer,Ge=Be.getDocument,it=be.getRootDomNode(),Et;je?(it||je.length===0)&&(Et=je(it)):Et=Ge(be.getRootDomNode()).body,Et?Et.appendChild(Fe):be.attachId=Object(rt.a)(function(){be.attachParent(Fe)})},be.getContainer=function(){var Fe=be.props.getDocument,Be=Fe(be.getRootDomNode()).createElement("div");return Be.style.position="absolute",Be.style.top="0",Be.style.left="0",Be.style.width="100%",be.attachParent(Be),Be},be.setPoint=function(Fe){var Be=be.props.alignPoint;if(!Be||!Fe)return;be.setState({point:{pageX:Fe.pageX,pageY:Fe.pageY}})},be.handlePortalUpdate=function(){be.state.prevPopupVisible!==be.state.popupVisible&&be.props.afterPopupVisibleChange(be.state.popupVisible)},be.triggerContextValue={onPopupMouseDown:be.onPopupMouseDown};var De;return"popupVisible"in Oe?De=!!Oe.popupVisible:De=!!Oe.defaultPopupVisible,be.state={prevPopupVisible:De,popupVisible:De},si.forEach(function(Fe){be["fire".concat(Fe)]=function(Be){be.fireEvents(Fe,Be)}}),be}return Object(O.a)(he,[{key:"componentDidMount",value:function(){this.componentDidUpdate()}},{key:"componentDidUpdate",value:function(){var be=this.props,De=this.state;if(De.popupVisible){var Fe;!this.clickOutsideHandler&&(this.isClickToHide()||this.isContextMenuToShow())&&(Fe=be.getDocument(this.getRootDomNode()),this.clickOutsideHandler=Object(Se.a)(Fe,"mousedown",this.onDocumentClick)),this.touchOutsideHandler||(Fe=Fe||be.getDocument(this.getRootDomNode()),this.touchOutsideHandler=Object(Se.a)(Fe,"touchstart",this.onDocumentClick)),!this.contextMenuOutsideHandler1&&this.isContextMenuToShow()&&(Fe=Fe||be.getDocument(this.getRootDomNode()),this.contextMenuOutsideHandler1=Object(Se.a)(Fe,"scroll",this.onContextMenuClose)),!this.contextMenuOutsideHandler2&&this.isContextMenuToShow()&&(this.contextMenuOutsideHandler2=Object(Se.a)(window,"blur",this.onContextMenuClose));return}this.clearOutsideHandler()}},{key:"componentWillUnmount",value:function(){this.clearDelayTimer(),this.clearOutsideHandler(),clearTimeout(this.mouseDownTimeout),rt.a.cancel(this.attachId)}},{key:"getPopupDomNode",value:function(){var be;return((be=this.popupRef.current)===null||be===void 0?void 0:be.getElement())||null}},{key:"getPopupAlign",value:function(){var be=this.props,De=be.popupPlacement,Fe=be.popupAlign,Be=be.builtinPlacements;return De&&Be?We(Be,De,Fe):Fe}},{key:"setPopupVisible",value:function(be,De){var Fe=this.props.alignPoint,Be=this.state.popupVisible;this.clearDelayTimer(),Be!==be&&("popupVisible"in this.props||this.setState({popupVisible:be,prevPopupVisible:Be}),this.props.onPopupVisibleChange(be)),Fe&&De&&be&&this.setPoint(De)}},{key:"delaySetPopupVisible",value:function(be,De,Fe){var Be=this,je=De*1e3;if(this.clearDelayTimer(),je){var Ge=Fe?{pageX:Fe.pageX,pageY:Fe.pageY}:null;this.delayTimer=window.setTimeout(function(){Be.setPopupVisible(be,Ge),Be.clearDelayTimer()},je)}else this.setPopupVisible(be,Fe)}},{key:"clearDelayTimer",value:function(){this.delayTimer&&(clearTimeout(this.delayTimer),this.delayTimer=null)}},{key:"clearOutsideHandler",value:function(){this.clickOutsideHandler&&(this.clickOutsideHandler.remove(),this.clickOutsideHandler=null),this.contextMenuOutsideHandler1&&(this.contextMenuOutsideHandler1.remove(),this.contextMenuOutsideHandler1=null),this.contextMenuOutsideHandler2&&(this.contextMenuOutsideHandler2.remove(),this.contextMenuOutsideHandler2=null),this.touchOutsideHandler&&(this.touchOutsideHandler.remove(),this.touchOutsideHandler=null)}},{key:"createTwoChains",value:function(be){var De=this.props.children.props,Fe=this.props;return De[be]&&Fe[be]?this["fire".concat(be)]:De[be]||Fe[be]}},{key:"isClickToShow",value:function(){var be=this.props,De=be.action,Fe=be.showAction;return De.indexOf("click")!==-1||Fe.indexOf("click")!==-1}},{key:"isContextMenuOnly",value:function(){var be=this.props.action;return be==="contextMenu"||be.length===1&&be[0]==="contextMenu"}},{key:"isContextMenuToShow",value:function(){var be=this.props,De=be.action,Fe=be.showAction;return De.indexOf("contextMenu")!==-1||Fe.indexOf("contextMenu")!==-1}},{key:"isClickToHide",value:function(){var be=this.props,De=be.action,Fe=be.hideAction;return De.indexOf("click")!==-1||Fe.indexOf("click")!==-1}},{key:"isMouseEnterToShow",value:function(){var be=this.props,De=be.action,Fe=be.showAction;return De.indexOf("hover")!==-1||Fe.indexOf("mouseEnter")!==-1}},{key:"isMouseLeaveToHide",value:function(){var be=this.props,De=be.action,Fe=be.hideAction;return De.indexOf("hover")!==-1||Fe.indexOf("mouseLeave")!==-1}},{key:"isFocusToShow",value:function(){var be=this.props,De=be.action,Fe=be.showAction;return De.indexOf("focus")!==-1||Fe.indexOf("focus")!==-1}},{key:"isBlurToHide",value:function(){var be=this.props,De=be.action,Fe=be.hideAction;return De.indexOf("focus")!==-1||Fe.indexOf("blur")!==-1}},{key:"forcePopupAlign",value:function(){if(this.state.popupVisible){var be;(be=this.popupRef.current)===null||be===void 0||be.forceAlign()}}},{key:"fireEvents",value:function(be,De){var Fe=this.props.children.props[be];Fe&&Fe(De);var Be=this.props[be];Be&&Be(De)}},{key:"close",value:function(){this.setPopupVisible(!1)}},{key:"render",value:function(){var be=this.state.popupVisible,De=this.props,Fe=De.children,Be=De.forceRender,je=De.alignPoint,Ge=De.className,it=De.autoDestroy,Et=m.Children.only(Fe),St={key:"trigger"};this.isContextMenuToShow()?St.onContextMenu=this.onContextMenu:St.onContextMenu=this.createTwoChains("onContextMenu"),this.isClickToHide()||this.isClickToShow()?(St.onClick=this.onClick,St.onMouseDown=this.onMouseDown,St.onTouchStart=this.onTouchStart):(St.onClick=this.createTwoChains("onClick"),St.onMouseDown=this.createTwoChains("onMouseDown"),St.onTouchStart=this.createTwoChains("onTouchStart")),this.isMouseEnterToShow()?(St.onMouseEnter=this.onMouseEnter,je&&(St.onMouseMove=this.onMouseMove)):St.onMouseEnter=this.createTwoChains("onMouseEnter"),this.isMouseLeaveToHide()?St.onMouseLeave=this.onMouseLeave:St.onMouseLeave=this.createTwoChains("onMouseLeave"),this.isFocusToShow()||this.isBlurToHide()?(St.onFocus=this.onFocus,St.onBlur=this.onBlur):(St.onFocus=this.createTwoChains("onFocus"),St.onBlur=this.createTwoChains("onBlur"));var Nt=w()(Et&&Et.props&&Et.props.className,Ge);Nt&&(St.className=Nt);var _r=Object(M.a)({},St);Object(Pe.c)(Et)&&(_r.ref=Object(Pe.a)(this.triggerRef,Et.ref));var Nr=m.cloneElement(Et,_r),Pr;return(be||this.popupRef.current||Be)&&(Pr=m.createElement(Ae,{key:"portal",getContainer:this.getContainer,didUpdate:this.handlePortalUpdate},this.getComponent())),!be&&it&&(Pr=null),m.createElement(Ma.Provider,{value:this.triggerContextValue},Nr,Pr)}}],[{key:"getDerivedStateFromProps",value:function(be,De){var Fe=be.popupVisible,Be={};return Fe!==void 0&&De.popupVisible!==Fe&&(Be.popupVisible=Fe,Be.prevPopupVisible=De.popupVisible),Be}}]),he}(m.Component);return Ue.contextType=Ma,Ue.defaultProps={prefixCls:"rc-trigger-popup",getPopupClassNameFromAlign:oi,getDocument:pi,onPopupVisibleChange:aa,afterPopupVisibleChange:aa,onPopupAlign:aa,popupClassName:"",mouseEnterDelay:0,mouseLeaveDelay:.1,focusDelay:0,blurDelay:.15,popupStyle:{},destroyPopupOnHide:!1,popupAlign:{},defaultPopupVisible:!1,mask:!1,maskClosable:!0,action:[],showAction:[],hideAction:[],autoDestroy:!1},Ue}var qa=mi(Je.a),wa={adjustX:1,adjustY:1},ei={topLeft:{points:["bl","tl"],overflow:wa,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:wa,offset:[0,7]},leftTop:{points:["tr","tl"],overflow:wa,offset:[-4,0]},rightTop:{points:["tl","tr"],overflow:wa,offset:[4,0]}},Ei={topLeft:{points:["bl","tl"],overflow:wa,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:wa,offset:[0,7]},rightTop:{points:["tr","tl"],overflow:wa,offset:[-4,0]},leftTop:{points:["tl","tr"],overflow:wa,offset:[4,0]}},mt=ei,qe=0,pt={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"},_t=function(Ue,Ke,Le){var he=te(Ke),Oe=Ue.getState();Ue.setState({defaultActiveFirst:Object(M.a)(Object(M.a)({},Oe.defaultActiveFirst),{},Object(N.a)({},he,Le))})},Ut=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(Le){var he;Object(R.a)(this,Ke),he=Ue.call(this,Le),he.onDestroy=function(je){he.props.onDestroy(je)},he.onKeyDown=function(je){var Ge=je.keyCode,it=he.menuInstance,Et=he.props.store,St=he.getVisible();if(Ge===u.a.ENTER)return he.onTitleClick(je),_t(Et,he.props.eventKey,!0),!0;if(Ge===u.a.RIGHT)return St?it.onKeyDown(je):(he.triggerOpenChange(!0),_t(Et,he.props.eventKey,!0)),!0;if(Ge===u.a.LEFT){var Nt;if(St)Nt=it.onKeyDown(je);else return;return Nt||(he.triggerOpenChange(!1),Nt=!0),Nt}return St&&(Ge===u.a.UP||Ge===u.a.DOWN)?it.onKeyDown(je):void 0},he.onOpenChange=function(je){he.props.onOpenChange(je)},he.onPopupVisibleChange=function(je){he.triggerOpenChange(je,je?"mouseenter":"mouseleave")},he.onMouseEnter=function(je){var Ge=he.props,it=Ge.eventKey,Et=Ge.onMouseEnter,St=Ge.store;_t(St,he.props.eventKey,!1),Et({key:it,domEvent:je})},he.onMouseLeave=function(je){var Ge=he.props,it=Ge.parentMenu,Et=Ge.eventKey,St=Ge.onMouseLeave;it.subMenuInstance=Object(g.a)(he),St({key:Et,domEvent:je})},he.onTitleMouseEnter=function(je){var Ge=he.props,it=Ge.eventKey,Et=Ge.onItemHover,St=Ge.onTitleMouseEnter;Et({key:it,hover:!0}),St({key:it,domEvent:je})},he.onTitleMouseLeave=function(je){var Ge=he.props,it=Ge.parentMenu,Et=Ge.eventKey,St=Ge.onItemHover,Nt=Ge.onTitleMouseLeave;it.subMenuInstance=Object(g.a)(he),St({key:Et,hover:!1}),Nt({key:Et,domEvent:je})},he.onTitleClick=function(je){var Ge=Object(g.a)(he),it=Ge.props;if(it.onTitleClick({key:it.eventKey,domEvent:je}),it.triggerSubMenuAction==="hover")return;he.triggerOpenChange(!he.getVisible(),"click"),_t(it.store,he.props.eventKey,!1)},he.onSubMenuClick=function(je){typeof he.props.onClick=="function"&&he.props.onClick(he.addKeyPath(je))},he.onSelect=function(je){he.props.onSelect(je)},he.onDeselect=function(je){he.props.onDeselect(je)},he.getPrefixCls=function(){return"".concat(he.props.rootPrefixCls,"-submenu")},he.getActiveClassName=function(){return"".concat(he.getPrefixCls(),"-active")},he.getDisabledClassName=function(){return"".concat(he.getPrefixCls(),"-disabled")},he.getSelectedClassName=function(){return"".concat(he.getPrefixCls(),"-selected")},he.getOpenClassName=function(){return"".concat(he.props.rootPrefixCls,"-submenu-open")},he.getVisible=function(){return he.state.isOpen},he.getMode=function(){return he.state.mode},he.saveMenuInstance=function(je){he.menuInstance=je},he.addKeyPath=function(je){return Object(M.a)(Object(M.a)({},je),{},{keyPath:(je.keyPath||[]).concat(he.props.eventKey)})},he.triggerOpenChange=function(je,Ge){var it=he.props.eventKey,Et=function(){he.onOpenChange({key:it,item:Object(g.a)(he),trigger:Ge,open:je})};Ge==="mouseenter"?he.mouseenterTimeout=setTimeout(function(){Et()},0):Et()},he.isChildrenSelected=function(){var je={find:!1};return X(he.props.children,he.props.selectedKeys,je),je.find},he.isInlineMode=function(){return he.getMode()==="inline"},he.adjustWidth=function(){if(!he.subMenuTitle||!he.menuInstance)return;var je=Xe.findDOMNode(he.menuInstance);if(je.offsetWidth>=he.subMenuTitle.offsetWidth)return;je.style.minWidth="".concat(he.subMenuTitle.offsetWidth,"px")},he.saveSubMenuTitle=function(je){he.subMenuTitle=je},he.getBaseProps=function(){var je=Object(g.a)(he),Ge=je.props,it=he.getMode();return{mode:it==="horizontal"?"vertical":it,visible:he.getVisible(),level:Ge.level+1,inlineIndent:Ge.inlineIndent,focusable:!1,onClick:he.onSubMenuClick,onSelect:he.onSelect,onDeselect:he.onDeselect,onDestroy:he.onDestroy,selectedKeys:Ge.selectedKeys,eventKey:"".concat(Ge.eventKey,"-menu-"),openKeys:Ge.openKeys,motion:Ge.motion,onOpenChange:he.onOpenChange,subMenuOpenDelay:Ge.subMenuOpenDelay,parentMenu:Object(g.a)(he),subMenuCloseDelay:Ge.subMenuCloseDelay,forceSubMenuRender:Ge.forceSubMenuRender,triggerSubMenuAction:Ge.triggerSubMenuAction,builtinPlacements:Ge.builtinPlacements,defaultActiveFirst:Ge.store.getState().defaultActiveFirst[te(Ge.eventKey)],multiple:Ge.multiple,prefixCls:Ge.rootPrefixCls,id:he.internalMenuId,manualRef:he.saveMenuInstance,itemIcon:Ge.itemIcon,expandIcon:Ge.expandIcon,direction:Ge.direction}},he.getMotion=function(je,Ge){var it=Object(g.a)(he),Et=it.haveRendered,St=he.props,Nt=St.motion,_r=St.rootPrefixCls,Nr=Object(M.a)(Object(M.a)({},Nt),{},{leavedClassName:"".concat(_r,"-hidden"),removeOnLeave:!1,motionAppear:Et||!Ge||je!=="inline"});return Nr};var Oe=Le.store,be=Le.eventKey,De=Oe.getState(),Fe=De.defaultActiveFirst;he.isRootMenu=!1;var Be=!1;return Fe&&(Be=Fe[be]),_t(Oe,be,Be),he.state={mode:Le.mode,isOpen:Le.isOpen},he}return Object(O.a)(Ke,[{key:"componentDidMount",value:function(){this.componentDidUpdate()}},{key:"componentDidUpdate",value:function(){var he=this,Oe=this.props,be=Oe.mode,De=Oe.parentMenu,Fe=Oe.manualRef,Be=Oe.isOpen,je=function(){he.setState({mode:be,isOpen:Be})},Ge=Be!==this.state.isOpen,it=be!==this.state.mode;if((it||Ge)&&(rt.a.cancel(this.updateStateRaf),it?this.updateStateRaf=Object(rt.a)(je):je()),Fe&&Fe(this),be!=="horizontal"||!(De==null?void 0:De.isRootMenu)||!Be)return;this.minWidthTimeout=setTimeout(function(){return he.adjustWidth()},0)}},{key:"componentWillUnmount",value:function(){var he=this.props,Oe=he.onDestroy,be=he.eventKey;Oe&&Oe(be),this.minWidthTimeout&&clearTimeout(this.minWidthTimeout),this.mouseenterTimeout&&clearTimeout(this.mouseenterTimeout),rt.a.cancel(this.updateStateRaf)}},{key:"renderPopupMenu",value:function(he,Oe){var be=this.getBaseProps();return m.createElement(vr,Object(h.a)({},be,{id:this.internalMenuId,className:he,style:Oe}),this.props.children)}},{key:"renderChildren",value:function(){var he=this,Oe=this.getBaseProps(),be=Oe.mode,De=Oe.visible,Fe=Oe.forceSubMenuRender,Be=Oe.direction,je=this.getMotion(be,De);if(this.haveRendered=!0,this.haveOpened=this.haveOpened||De||Fe,!this.haveOpened)return m.createElement("div",null);var Ge=w()("".concat(Oe.prefixCls,"-sub"),Object(N.a)({},"".concat(Oe.prefixCls,"-rtl"),Be==="rtl"));return this.isInlineMode()?m.createElement(Vn,Object(h.a)({visible:Oe.visible,forceRender:Fe},je),function(it){var Et=it.className,St=it.style,Nt=w()(Ge,Et);return he.renderPopupMenu(Nt,St)}):this.renderPopupMenu(Ge)}},{key:"render",value:function(){var he,Oe,be,De=Object(M.a)({},this.props),Fe=this.getVisible(),Be=this.getPrefixCls(),je=this.isInlineMode(),Ge=this.getMode(),it=w()(Be,"".concat(Be,"-").concat(Ge),(he={},Object(N.a)(he,De.className,!!De.className),Object(N.a)(he,this.getOpenClassName(),Fe),Object(N.a)(he,this.getActiveClassName(),De.active||Fe&&!je),Object(N.a)(he,this.getDisabledClassName(),De.disabled),Object(N.a)(he,this.getSelectedClassName(),this.isChildrenSelected()),he));this.internalMenuId||(De.eventKey?this.internalMenuId="".concat(De.eventKey,"$Menu"):(qe+=1,this.internalMenuId="$__$".concat(qe,"$Menu")));var Et={},St={},Nt={};De.disabled||(Et={onMouseLeave:this.onMouseLeave,onMouseEnter:this.onMouseEnter},St={onClick:this.onTitleClick},Nt={onMouseEnter:this.onTitleMouseEnter,onMouseLeave:this.onTitleMouseLeave});var _r={},Nr=De.direction,Pr=Nr==="rtl";je&&(Pr?_r.paddingRight=De.inlineIndent*De.level:_r.paddingLeft=De.inlineIndent*De.level);var Br={};this.getVisible()&&(Br={"aria-owns":this.internalMenuId});var Ir=null;Ge!=="horizontal"&&(Ir=this.props.expandIcon,typeof this.props.expandIcon=="function"&&(Ir=m.createElement(this.props.expandIcon,Object(M.a)({},this.props))));var Kr=m.createElement("div",Object(h.a)({ref:this.saveSubMenuTitle,style:_r,className:"".concat(Be,"-title"),role:"button"},Nt,St,{"aria-expanded":Fe},Br,{"aria-haspopup":"true",title:typeof De.title=="string"?De.title:void 0}),De.title,Ir||m.createElement("i",{className:"".concat(Be,"-arrow")})),zr=this.renderChildren(),on=((Oe=De.parentMenu)===null||Oe===void 0?void 0:Oe.isRootMenu)?De.parentMenu.props.getPopupContainer:function(hn){return hn.parentNode},$r=pt[Ge],gn=De.popupOffset?{offset:De.popupOffset}:{},Zr=w()((be={},Object(N.a)(be,De.popupClassName,De.popupClassName&&!je),Object(N.a)(be,"".concat(Be,"-rtl"),Pr),be)),wr=De.disabled,Ar=De.triggerSubMenuAction,Xr=De.subMenuOpenDelay,nn=De.forceSubMenuRender,fr=De.subMenuCloseDelay,un=De.builtinPlacements;$.forEach(function(hn){return delete De[hn]}),delete De.onClick;var An=Pr?Object(M.a)(Object(M.a)({},Ei),un):Object(M.a)(Object(M.a)({},ei),un);delete De.direction;var fn=this.getBaseProps(),En=je?null:this.getMotion(fn.mode,fn.visible);return m.createElement("li",Object(h.a)({},De,Et,{className:it,role:"menuitem"}),m.createElement(qa,{prefixCls:Be,popupClassName:w()("".concat(Be,"-popup"),Zr),getPopupContainer:on,builtinPlacements:An,popupPlacement:$r,popupVisible:je?!1:Fe,popupAlign:gn,popup:je?null:zr,action:wr||je?[]:[Ar],mouseEnterDelay:Xr,mouseLeaveDelay:fr,onPopupVisibleChange:this.onPopupVisibleChange,forceRender:nn,popupMotion:En},Kr),je?zr:null)}}]),Ke}(m.Component);Ut.defaultProps={onMouseEnter:ee,onMouseLeave:ee,onTitleMouseEnter:ee,onTitleMouseLeave:ee,onTitleClick:ee,manualRef:ee,mode:"vertical",title:""};var At=Object(T.b)(function(Ae,Ue){var Ke=Ae.openKeys,Le=Ae.activeKey,he=Ae.selectedKeys,Oe=Ue.eventKey,be=Ue.subMenuKey;return{isOpen:Ke.indexOf(Oe)>-1,active:Le[be]===Oe,selectedKeys:he}})(Ut);At.isSubMenu=!0;var Xt=At,kt="menuitem-overflowed",st=.5,gt=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(){var Le;return Object(R.a)(this,Ke),Le=Ue.apply(this,arguments),Le.resizeObserver=null,Le.mutationObserver=null,Le.originalTotalWidth=0,Le.overflowedItems=[],Le.menuItemSizes=[],Le.cancelFrameId=null,Le.state={lastVisibleIndex:void 0},Le.childRef=m.createRef(),Le.getMenuItemNodes=function(){var he=Le.props.prefixCls,Oe=Le.childRef.current;return Oe?[].slice.call(Oe.children).filter(function(be){return be.className.split(" ").indexOf("".concat(he,"-overflowed-submenu"))<0}):[]},Le.getOverflowedSubMenuItem=function(he,Oe,be){var De=Le.props,Fe=De.overflowedIndicator,Be=De.level,je=De.mode,Ge=De.prefixCls,it=De.theme;if(Be!==1||je!=="horizontal")return null;var Et=Le.props.children[0],St=Et.props,Nt=St.children,_r=St.title,Nr=St.style,Pr=Object(C.a)(St,["children","title","style"]),Br=Object(M.a)({},Nr),Ir="".concat(he,"-overflowed-indicator"),Kr="".concat(he,"-overflowed-indicator");Oe.length===0&&be!==!0?Br=Object(M.a)(Object(M.a)({},Br),{},{display:"none"}):be&&(Br=Object(M.a)(Object(M.a)({},Br),{},{visibility:"hidden",position:"absolute"}),Ir="".concat(Ir,"-placeholder"),Kr="".concat(Kr,"-placeholder"));var zr=it?"".concat(Ge,"-").concat(it):"",on={};return $.forEach(function($r){Pr[$r]!==void 0&&(on[$r]=Pr[$r])}),m.createElement(Xt,Object(h.a)({title:Fe,className:"".concat(Ge,"-overflowed-submenu"),popupClassName:zr},on,{key:Ir,eventKey:Kr,disabled:!1,style:Br}),Oe)},Le.setChildrenWidthAndResize=function(){if(Le.props.mode!=="horizontal")return;var he=Le.childRef.current;if(!he)return;var Oe=he.children;if(!Oe||Oe.length===0)return;var be=he.children[Oe.length-1];fe(be,"display","inline-block");var De=Le.getMenuItemNodes(),Fe=De.filter(function(Be){return Be.className.split(" ").indexOf(kt)>=0});Fe.forEach(function(Be){fe(Be,"display","inline-block")}),Le.menuItemSizes=De.map(function(Be){return ge(Be,!0)}),Fe.forEach(function(Be){fe(Be,"display","none")}),Le.overflowedIndicatorWidth=ge(he.children[he.children.length-1],!0),Le.originalTotalWidth=Le.menuItemSizes.reduce(function(Be,je){return Be+je},0),Le.handleResize(),fe(be,"display","none")},Le.handleResize=function(){if(Le.props.mode!=="horizontal")return;var he=Le.childRef.current;if(!he)return;var Oe=ge(he);Le.overflowedItems=[];var be=0,De;Le.originalTotalWidth>Oe+st&&(De=-1,Le.menuItemSizes.forEach(function(Fe){be+=Fe,be+Le.overflowedIndicatorWidth<=Oe&&(De+=1)})),Le.setState({lastVisibleIndex:De})},Le}return Object(O.a)(Ke,[{key:"componentDidMount",value:function(){var he=this;if(this.setChildrenWidthAndResize(),this.props.level===1&&this.props.mode==="horizontal"){var Oe=this.childRef.current;if(!Oe)return;this.resizeObserver=new ze.default(function(be){be.forEach(function(){var De=he.cancelFrameId;cancelAnimationFrame(De),he.cancelFrameId=requestAnimationFrame(he.setChildrenWidthAndResize)})}),[].slice.call(Oe.children).concat(Oe).forEach(function(be){he.resizeObserver.observe(be)}),typeof MutationObserver!="undefined"&&(this.mutationObserver=new MutationObserver(function(){he.resizeObserver.disconnect(),[].slice.call(Oe.children).concat(Oe).forEach(function(be){he.resizeObserver.observe(be)}),he.setChildrenWidthAndResize()}),this.mutationObserver.observe(Oe,{attributes:!1,childList:!0,subTree:!1}))}}},{key:"componentWillUnmount",value:function(){this.resizeObserver&&this.resizeObserver.disconnect(),this.mutationObserver&&this.mutationObserver.disconnect(),cancelAnimationFrame(this.cancelFrameId)}},{key:"renderChildren",value:function(he){var Oe=this,be=this.state.lastVisibleIndex;return(he||[]).reduce(function(De,Fe,Be){var je=Fe;if(Oe.props.mode==="horizontal"){var Ge=Oe.getOverflowedSubMenuItem(Fe.props.eventKey,[]);be!==void 0&&Oe.props.className.indexOf("".concat(Oe.props.prefixCls,"-root"))!==-1&&(Be>be&&(je=m.cloneElement(Fe,{style:{display:"none"},eventKey:"".concat(Fe.props.eventKey,"-hidden"),className:"".concat(kt)})),Be===be+1&&(Oe.overflowedItems=he.slice(be+1).map(function(Et){return m.cloneElement(Et,{key:Et.props.eventKey,mode:"vertical-left"})}),Ge=Oe.getOverflowedSubMenuItem(Fe.props.eventKey,Oe.overflowedItems)));var it=[].concat(Object(d.a)(De),[Ge,je]);return Be===he.length-1&&it.push(Oe.getOverflowedSubMenuItem(Fe.props.eventKey,[],!0)),it}return[].concat(Object(d.a)(De),[je])},[])}},{key:"render",value:function(){var he=this.props,Oe=he.visible,be=he.prefixCls,De=he.overflowedIndicator,Fe=he.mode,Be=he.level,je=he.tag,Ge=he.children,it=he.theme,Et=Object(C.a)(he,["visible","prefixCls","overflowedIndicator","mode","level","tag","children","theme"]),St=je;return m.createElement(St,Object(h.a)({ref:this.childRef},Et),this.renderChildren(Ge))}}]),Ke}(m.Component);gt.defaultProps={tag:"div",className:""};var bt=gt;function tr(Ae){return Ae.length?Ae.every(function(Ue){return!!Ue.props.disabled}):!0}function Jt(Ae,Ue,Ke){var Le=Ae.getState();Ae.setState({activeKey:Object(M.a)(Object(M.a)({},Le.activeKey),{},Object(N.a)({},Ue,Ke))})}function Wt(Ae){return Ae.eventKey||"0-menu-"}function jt(Ae,Ue){var Ke=Ue,Le=Ae.children,he=Ae.eventKey;if(Ke){var Oe;if(J(Le,function(be,De){be&&be.props&&!be.props.disabled&&Ke===Ee(be,he,De)&&(Oe=!0)}),Oe)return Ke}return Ke=null,Ae.defaultActiveFirst&&J(Le,function(be,De){!Ke&&be&&!be.props.disabled&&(Ke=Ee(be,he,De))}),Ke}function Vt(Ae){if(!Ae)return;var Ue=this.instanceArray.indexOf(Ae);Ue!==-1?this.instanceArray[Ue]=Ae:this.instanceArray.push(Ae)}var Zt=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(Le){var he;return Object(R.a)(this,Ke),he=Ue.call(this,Le),he.onKeyDown=function(Oe,be){var De=Oe.keyCode,Fe;if(he.getFlatInstanceArray().forEach(function(je){je&&je.props.active&&je.onKeyDown&&(Fe=je.onKeyDown(Oe))}),Fe)return 1;var Be=null;return(De===u.a.UP||De===u.a.DOWN)&&(Be=he.step(De===u.a.UP?-1:1)),Be?(Oe.preventDefault(),Jt(he.props.store,Wt(he.props),Be.props.eventKey),typeof be=="function"&&be(Be),1):void 0},he.onItemHover=function(Oe){var be=Oe.key,De=Oe.hover;Jt(he.props.store,Wt(he.props),De?be:null)},he.onDeselect=function(Oe){he.props.onDeselect(Oe)},he.onSelect=function(Oe){he.props.onSelect(Oe)},he.onClick=function(Oe){he.props.onClick(Oe)},he.onOpenChange=function(Oe){he.props.onOpenChange(Oe)},he.onDestroy=function(Oe){he.props.onDestroy(Oe)},he.getFlatInstanceArray=function(){return he.instanceArray},he.step=function(Oe){var be=he.getFlatInstanceArray(),De=he.props.store.getState().activeKey[Wt(he.props)],Fe=be.length;if(!Fe)return null;Oe<0&&(be=be.concat().reverse());var Be=-1;if(be.every(function(Et,St){return Et&&Et.props.eventKey===De?(Be=St,!1):!0}),!he.props.defaultActiveFirst&&Be!==-1&&tr(be.slice(Be,Fe-1)))return;var je=(Be+1)%Fe,Ge=je;do{var it=be[Ge];if(!it||it.props.disabled)Ge=(Ge+1)%Fe;else return it}while(Ge!==je);return null},he.renderCommonMenuItem=function(Oe,be,De){var Fe=he.props.store.getState(),Be=Object(g.a)(he),je=Be.props,Ge=Ee(Oe,je.eventKey,be),it=Oe.props;if(!it||typeof Oe.type=="string")return Oe;var Et=Ge===Fe.activeKey,St=Object(M.a)(Object(M.a)({mode:it.mode||je.mode,level:je.level,inlineIndent:je.inlineIndent,renderMenuItem:he.renderMenuItem,rootPrefixCls:je.prefixCls,index:be,parentMenu:je.parentMenu,manualRef:it.disabled?void 0:Object(I.a)(Oe.ref,Vt.bind(Object(g.a)(he))),eventKey:Ge,active:!it.disabled&&Et,multiple:je.multiple,onClick:function(_r){(it.onClick||ee)(_r),he.onClick(_r)},onItemHover:he.onItemHover,motion:je.motion,subMenuOpenDelay:je.subMenuOpenDelay,subMenuCloseDelay:je.subMenuCloseDelay,forceSubMenuRender:je.forceSubMenuRender,onOpenChange:he.onOpenChange,onDeselect:he.onDeselect,onSelect:he.onSelect,builtinPlacements:je.builtinPlacements,itemIcon:it.itemIcon||he.props.itemIcon,expandIcon:it.expandIcon||he.props.expandIcon},De),{},{direction:je.direction});return(je.mode==="inline"||Te())&&(St.triggerSubMenuAction="click"),m.cloneElement(Oe,Object(M.a)(Object(M.a)({},St),{},{key:Ge||be}))},he.renderMenuItem=function(Oe,be,De){if(!Oe)return null;var Fe=he.props.store.getState(),Be={openKeys:Fe.openKeys,selectedKeys:Fe.selectedKeys,triggerSubMenuAction:he.props.triggerSubMenuAction,subMenuKey:De};return he.renderCommonMenuItem(Oe,be,Be)},Le.store.setState({activeKey:Object(M.a)(Object(M.a)({},Le.store.getState().activeKey),{},Object(N.a)({},Le.eventKey,jt(Le,Le.activeKey)))}),he.instanceArray=[],he}return Object(O.a)(Ke,[{key:"componentDidMount",value:function(){this.props.manualRef&&this.props.manualRef(this)}},{key:"shouldComponentUpdate",value:function(he){return this.props.visible||he.visible||this.props.className!==he.className||!G()(this.props.style,he.style)}},{key:"componentDidUpdate",value:function(he){var Oe=this.props,be="activeKey"in Oe?Oe.activeKey:Oe.store.getState().activeKey[Wt(Oe)],De=jt(Oe,be);if(De!==be)Jt(Oe.store,Wt(Oe),De);else if("activeKey"in he){var Fe=jt(he,he.activeKey);De!==Fe&&Jt(Oe.store,Wt(Oe),De)}}},{key:"render",value:function(){var he=this,Oe=Object(h.a)({},this.props);this.instanceArray=[];var be=w()(Oe.prefixCls,Oe.className,"".concat(Oe.prefixCls,"-").concat(Oe.mode)),De={className:be,role:Oe.role||"menu"};Oe.id&&(De.id=Oe.id),Oe.focusable&&(De.tabIndex=0,De.onKeyDown=this.onKeyDown);var Fe=Oe.prefixCls,Be=Oe.eventKey,je=Oe.visible,Ge=Oe.level,it=Oe.mode,Et=Oe.overflowedIndicator,St=Oe.theme;return $.forEach(function(Nt){return delete Oe[Nt]}),delete Oe.onClick,m.createElement(bt,Object(h.a)({},Oe,{prefixCls:Fe,mode:it,tag:"ul",level:Ge,theme:St,visible:je,overflowedIndicator:Et},De),Object(b.a)(Oe.children).map(function(Nt,_r){return he.renderMenuItem(Nt,_r,Be||"0-menu-")}))}}]),Ke}(m.Component);Zt.defaultProps={prefixCls:"rc-menu",className:"",mode:"vertical",level:1,inlineIndent:24,visible:!0,focusable:!0,style:{},manualRef:ee};var Ze=Object(T.b)()(Zt),vr=Ze,Or=j("Kwbf");function nr(Ae,Ue,Ke){var Le=Ae.prefixCls,he=Ae.motion,Oe=Ae.defaultMotions,be=Oe===void 0?{}:Oe,De=Ae.openAnimation,Fe=Ae.openTransitionName,Be=Ue.switchingModeFromInline;if(he)return he;if(Object(W.a)(De)==="object"&&De)Object(Or.a)(!1,"Object type of `openAnimation` is removed. Please use `motion` instead.");else if(typeof De=="string")return{motionName:"".concat(Le,"-open-").concat(De)};if(Fe)return{motionName:Fe};var je=be[Ke];return je||(Be?null:be.other)}var ft=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(Le){var he;Object(R.a)(this,Ke),he=Ue.call(this,Le),he.onSelect=function(De){var Fe=Object(g.a)(he),Be=Fe.props;if(Be.selectable){var je=he.store.getState(),Ge=je.selectedKeys,it=De.key;Be.multiple?Ge=Ge.concat([it]):Ge=[it],"selectedKeys"in Be||he.store.setState({selectedKeys:Ge}),Be.onSelect(Object(M.a)(Object(M.a)({},De),{},{selectedKeys:Ge}))}},he.onClick=function(De){var Fe=he.getRealMenuMode(),Be=Object(g.a)(he),je=Be.store,Ge=Be.props.onOpenChange;Fe!=="inline"&&!("openKeys"in he.props)&&(je.setState({openKeys:[]}),Ge([])),he.props.onClick(De)},he.onKeyDown=function(De,Fe){he.innerMenu.getWrappedInstance().onKeyDown(De,Fe)},he.onOpenChange=function(De){var Fe=Object(g.a)(he),Be=Fe.props,je=he.store.getState().openKeys.concat(),Ge=!1,it=function(St){var Nt=!1;if(St.open)Nt=je.indexOf(St.key)===-1,Nt&&je.push(St.key);else{var _r=je.indexOf(St.key);Nt=_r!==-1,Nt&&je.splice(_r,1)}Ge=Ge||Nt};Array.isArray(De)?De.forEach(it):it(De),Ge&&("openKeys"in he.props||he.store.setState({openKeys:je}),Be.onOpenChange(je))},he.onDeselect=function(De){var Fe=Object(g.a)(he),Be=Fe.props;if(Be.selectable){var je=he.store.getState().selectedKeys.concat(),Ge=De.key,it=je.indexOf(Ge);it!==-1&&je.splice(it,1),"selectedKeys"in Be||he.store.setState({selectedKeys:je}),Be.onDeselect(Object(M.a)(Object(M.a)({},De),{},{selectedKeys:je}))}},he.onMouseEnter=function(De){he.restoreModeVerticalFromInline();var Fe=he.props.onMouseEnter;Fe&&Fe(De)},he.onTransitionEnd=function(De){var Fe=De.propertyName==="width"&&De.target===De.currentTarget,Be=De.target.className,je=Object.prototype.toString.call(Be)==="[object SVGAnimatedString]"?Be.animVal:Be,Ge=De.propertyName==="font-size"&&je.indexOf("anticon")>=0;(Fe||Ge)&&he.restoreModeVerticalFromInline()},he.setInnerMenu=function(De){he.innerMenu=De},he.isRootMenu=!0;var Oe=Le.defaultSelectedKeys,be=Le.defaultOpenKeys;return"selectedKeys"in Le&&(Oe=Le.selectedKeys||[]),"openKeys"in Le&&(be=Le.openKeys||[]),he.store=Object(T.c)({selectedKeys:Oe,openKeys:be,activeKey:{"0-menu-":jt(Le,Le.activeKey)}}),he.state={switchingModeFromInline:!1,prevProps:Le,inlineOpenKeys:[],store:he.store},he}return Object(O.a)(Ke,[{key:"componentDidMount",value:function(){this.updateMiniStore(),this.updateMenuDisplay()}},{key:"componentDidUpdate",value:function(he){var Oe=this.props,be=Oe.siderCollapsed,De=Oe.inlineCollapsed,Fe=Oe.onOpenChange;(!he.inlineCollapsed&&De||!he.siderCollapsed&&be)&&Fe([]),this.updateMiniStore(),this.updateMenuDisplay()}},{key:"updateMenuDisplay",value:function(){var he=this.props.collapsedWidth,Oe=this.store,be=this.prevOpenKeys,De=this.getInlineCollapsed()&&(he===0||he==="0"||he==="0px");De?(this.prevOpenKeys=Oe.getState().openKeys.concat(),this.store.setState({openKeys:[]})):be&&(this.store.setState({openKeys:be}),this.prevOpenKeys=null)}},{key:"getRealMenuMode",value:function(){var he=this.props.mode,Oe=this.state.switchingModeFromInline,be=this.getInlineCollapsed();return Oe&&be?"inline":be?"vertical":he}},{key:"getInlineCollapsed",value:function(){var he=this.props,Oe=he.inlineCollapsed,be=he.siderCollapsed;return be!==void 0?be:Oe}},{key:"restoreModeVerticalFromInline",value:function(){var he=this.state.switchingModeFromInline;he&&this.setState({switchingModeFromInline:!1})}},{key:"updateMiniStore",value:function(){"selectedKeys"in this.props&&this.store.setState({selectedKeys:this.props.selectedKeys||[]}),"openKeys"in this.props&&this.store.setState({openKeys:this.props.openKeys||[]})}},{key:"render",value:function(){var he=Object(M.a)({},Object(L.a)(this.props,["collapsedWidth","siderCollapsed","defaultMotions"])),Oe=this.getRealMenuMode();return he.className+=" ".concat(he.prefixCls,"-root"),he.direction==="rtl"&&(he.className+=" ".concat(he.prefixCls,"-rtl")),he=Object(M.a)(Object(M.a)({},he),{},{mode:Oe,onClick:this.onClick,onOpenChange:this.onOpenChange,onDeselect:this.onDeselect,onSelect:this.onSelect,onMouseEnter:this.onMouseEnter,onTransitionEnd:this.onTransitionEnd,parentMenu:this,motion:nr(this.props,this.state,Oe)}),delete he.openAnimation,delete he.openTransitionName,m.createElement(T.a,{store:this.store},m.createElement(vr,Object(h.a)({},he,{ref:this.setInnerMenu}),this.props.children))}}],[{key:"getDerivedStateFromProps",value:function(he,Oe){var be=Oe.prevProps,De=Oe.store,Fe=De.getState(),Be={},je={prevProps:he};return be.mode==="inline"&&he.mode!=="inline"&&(je.switchingModeFromInline=!0),"openKeys"in he?Be.openKeys=he.openKeys||[]:((he.inlineCollapsed&&!be.inlineCollapsed||he.siderCollapsed&&!be.siderCollapsed)&&(je.switchingModeFromInline=!0,je.inlineOpenKeys=Fe.openKeys,Be.openKeys=[]),(!he.inlineCollapsed&&be.inlineCollapsed||!he.siderCollapsed&&be.siderCollapsed)&&(Be.openKeys=Oe.inlineOpenKeys,je.inlineOpenKeys=[])),Object.keys(Be).length&&De.setState(Be),je}}]),Ke}(m.Component);ft.defaultProps={selectable:!0,onClick:ee,onSelect:ee,onOpenChange:ee,onDeselect:ee,defaultSelectedKeys:[],defaultOpenKeys:[],subMenuOpenDelay:.1,subMenuCloseDelay:.1,triggerSubMenuAction:"hover",prefixCls:"rc-menu",className:"",mode:"vertical",style:{},builtinPlacements:{},overflowedIndicator:m.createElement("span",null,"\xB7\xB7\xB7")};var yt=ft,ht=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(){var Le;return Object(R.a)(this,Ke),Le=Ue.apply(this,arguments),Le.onKeyDown=function(he){var Oe=he.keyCode;return Oe===u.a.ENTER?(Le.onClick(he),!0):void 0},Le.onMouseLeave=function(he){var Oe=Le.props,be=Oe.eventKey,De=Oe.onItemHover,Fe=Oe.onMouseLeave;De({key:be,hover:!1}),Fe({key:be,domEvent:he})},Le.onMouseEnter=function(he){var Oe=Le.props,be=Oe.eventKey,De=Oe.onItemHover,Fe=Oe.onMouseEnter;De({key:be,hover:!0}),Fe({key:be,domEvent:he})},Le.onClick=function(he){var Oe=Le.props,be=Oe.eventKey,De=Oe.multiple,Fe=Oe.onClick,Be=Oe.onSelect,je=Oe.onDeselect,Ge=Oe.isSelected,it={key:be,keyPath:[be],item:Object(g.a)(Le),domEvent:he};Fe(it),De?Ge?je(it):Be(it):Ge||Be(it)},Le.saveNode=function(he){Le.node=he},Le}return Object(O.a)(Ke,[{key:"componentDidMount",value:function(){this.callRef()}},{key:"componentDidUpdate",value:function(){this.callRef()}},{key:"componentWillUnmount",value:function(){var he=this.props;he.onDestroy&&he.onDestroy(he.eventKey)}},{key:"getPrefixCls",value:function(){return"".concat(this.props.rootPrefixCls,"-item")}},{key:"getActiveClassName",value:function(){return"".concat(this.getPrefixCls(),"-active")}},{key:"getSelectedClassName",value:function(){return"".concat(this.getPrefixCls(),"-selected")}},{key:"getDisabledClassName",value:function(){return"".concat(this.getPrefixCls(),"-disabled")}},{key:"callRef",value:function(){this.props.manualRef&&this.props.manualRef(this)}},{key:"render",value:function(){var he,Oe=Object(M.a)({},this.props),be=w()(this.getPrefixCls(),Oe.className,(he={},Object(N.a)(he,this.getActiveClassName(),!Oe.disabled&&Oe.active),Object(N.a)(he,this.getSelectedClassName(),Oe.isSelected),Object(N.a)(he,this.getDisabledClassName(),Oe.disabled),he)),De=Object(M.a)(Object(M.a)({},Oe.attribute),{},{title:typeof Oe.title=="string"?Oe.title:void 0,className:be,role:Oe.role||"menuitem","aria-disabled":Oe.disabled});Oe.role==="option"?De=Object(M.a)(Object(M.a)({},De),{},{role:"option","aria-selected":Oe.isSelected}):(Oe.role===null||Oe.role==="none")&&(De.role="none");var Fe={onClick:Oe.disabled?null:this.onClick,onMouseLeave:Oe.disabled?null:this.onMouseLeave,onMouseEnter:Oe.disabled?null:this.onMouseEnter},Be=Object(M.a)({},Oe.style);Oe.mode==="inline"&&(Oe.direction==="rtl"?Be.paddingRight=Oe.inlineIndent*Oe.level:Be.paddingLeft=Oe.inlineIndent*Oe.level),$.forEach(function(Ge){return delete Oe[Ge]}),delete Oe.direction;var je=this.props.itemIcon;return typeof this.props.itemIcon=="function"&&(je=m.createElement(this.props.itemIcon,this.props)),m.createElement("li",Object(h.a)({},Object(L.a)(Oe,["onClick","onMouseEnter","onMouseLeave","onSelect"]),De,Fe,{style:Be,ref:this.saveNode}),Oe.children,je)}}]),Ke}(m.Component);ht.isMenuItem=!0,ht.defaultProps={onSelect:ee,onMouseEnter:ee,onMouseLeave:ee,manualRef:ee};var wt=Object(T.b)(function(Ae,Ue){var Ke=Ae.activeKey,Le=Ae.selectedKeys,he=Ue.eventKey,Oe=Ue.subMenuKey;return{active:Ke[Oe]===he,isSelected:Array.isArray(Le)?Le.indexOf(he)!==-1:Le===he}})(ht),Kt=wt,ar=function(Ae){Object(_.a)(Ke,Ae);var Ue=Object(E.a)(Ke);function Ke(){var Le;return Object(R.a)(this,Ke),Le=Ue.apply(this,arguments),Le.renderInnerMenuItem=function(he){var Oe=Le.props,be=Oe.renderMenuItem,De=Oe.index;return be(he,De,Le.props.subMenuKey)},Le}return Object(O.a)(Ke,[{key:"render",value:function(){var he=Object(h.a)({},this.props),Oe=he.className,be=Oe===void 0?"":Oe,De=he.rootPrefixCls,Fe="".concat(De,"-item-group-title"),Be="".concat(De,"-item-group-list"),je=he.title,Ge=he.children;return $.forEach(function(it){return delete he[it]}),delete he.direction,m.createElement("li",Object(h.a)({},he,{onClick:function(Et){return Et.stopPropagation()},className:"".concat(be," ").concat(De,"-item-group")}),m.createElement("div",{className:Fe,title:typeof je=="string"?je:void 0},je),m.createElement("ul",{className:Be},m.Children.map(Ge,this.renderInnerMenuItem)))}}]),Ke}(m.Component);ar.isMenuItemGroup=!0,ar.defaultProps={disabled:!0};var zt=ar,gr=function(Ue){var Ke=Ue.className,Le=Ue.rootPrefixCls,he=Ue.style;return m.createElement("li",{className:"".concat(Ke," ").concat(Le,"-item-divider"),style:he})};gr.defaultProps={disabled:!0,className:"",style:{}};var Rr=gr,lr=yt,Qe=j("eDIo");function Pt(Ae,Ue){var Ke=Ae.prefixCls,Le=Ae.editable,he=Ae.locale,Oe=Ae.style;return!Le||Le.showAdd===!1?null:m.createElement("button",{ref:Ue,type:"button",className:"".concat(Ke,"-nav-add"),style:Oe,"aria-label":(he==null?void 0:he.addAriaLabel)||"Add tab",onClick:function(De){Le.onEdit("add",{event:De})}},Le.addIcon||"+")}var Vr=m.forwardRef(Pt);function Hr(Ae,Ue){var Ke=Ae.prefixCls,Le=Ae.id,he=Ae.tabs,Oe=Ae.locale,be=Ae.mobile,De=Ae.moreIcon,Fe=De===void 0?"More":De,Be=Ae.moreTransitionName,je=Ae.style,Ge=Ae.className,it=Ae.editable,Et=Ae.tabBarGutter,St=Ae.rtl,Nt=Ae.onTabClick,_r=Object(m.useState)(!1),Nr=Object(v.a)(_r,2),Pr=Nr[0],Br=Nr[1],Ir=Object(m.useState)(null),Kr=Object(v.a)(Ir,2),zr=Kr[0],on=Kr[1],$r="".concat(Le,"-more-popup"),gn="".concat(Ke,"-dropdown"),Zr=zr!==null?"".concat($r,"-").concat(zr):null,wr=Oe==null?void 0:Oe.dropdownAriaLabel,Ar=m.createElement(lr,{onClick:function(En){var hn=En.key,Fn=En.domEvent;Nt(hn,Fn),Br(!1)},id:$r,tabIndex:-1,role:"listbox","aria-activedescendant":Zr,selectedKeys:[zr],"aria-label":wr!==void 0?wr:"expanded dropdown"},he.map(function(fn){return m.createElement(Kt,{key:fn.key,id:"".concat($r,"-").concat(fn.key),role:"option","aria-controls":Le&&"".concat(Le,"-panel-").concat(fn.key),disabled:fn.disabled},fn.tab)}));function Xr(fn){for(var En=he.filter(function(Zn){return!Zn.disabled}),hn=En.findIndex(function(Zn){return Zn.key===zr})||0,Fn=En.length,Kn=0;Kn<Fn;Kn+=1){hn=(hn+fn+Fn)%Fn;var Rn=En[hn];if(!Rn.disabled){on(Rn.key);return}}}function nn(fn){var En=fn.which;if(!Pr){[u.a.DOWN,u.a.SPACE,u.a.ENTER].includes(En)&&(Br(!0),fn.preventDefault());return}switch(En){case u.a.UP:Xr(-1),fn.preventDefault();break;case u.a.DOWN:Xr(1),fn.preventDefault();break;case u.a.ESC:Br(!1);break;case u.a.SPACE:case u.a.ENTER:zr!==null&&Nt(zr,fn);break}}Object(m.useEffect)(function(){var fn=document.getElementById(Zr);fn&&fn.scrollIntoView&&fn.scrollIntoView(!1)},[zr]),Object(m.useEffect)(function(){Pr||on(null)},[Pr]);var fr=Object(N.a)({},St?"marginLeft":"marginRight",Et);he.length||(fr.visibility="hidden",fr.order=1);var un=w()(Object(N.a)({},"".concat(gn,"-rtl"),St)),An=be?null:m.createElement(Qe.a,{prefixCls:gn,overlay:Ar,trigger:["hover"],visible:Pr,transitionName:Be,onVisibleChange:Br,overlayClassName:un,mouseEnterDelay:.1,mouseLeaveDelay:.1},m.createElement("button",{type:"button",className:"".concat(Ke,"-nav-more"),style:fr,tabIndex:-1,"aria-hidden":"true","aria-haspopup":"listbox","aria-controls":$r,id:"".concat(Le,"-more"),"aria-expanded":Pr,onKeyDown:nn},Fe));return m.createElement("div",{className:w()("".concat(Ke,"-nav-operations"),Ge),style:je,ref:Ue},An,m.createElement(Vr,{prefixCls:Ke,locale:Oe,editable:it}))}var ir=m.forwardRef(Hr),br=Object(m.createContext)(null),Tr=.1,Ot=.01,Ht=20,or=Math.pow(.995,Ht);function Gt(){var Ae=navigator.userAgent||navigator.vendor||window.opera;return!!(/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(Ae)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(Ae.substr(0,4)))}function lt(Ae,Ue){var Ke=Object(m.useState)(),Le=Object(v.a)(Ke,2),he=Le[0],Oe=Le[1],be=Object(m.useState)(0),De=Object(v.a)(be,2),Fe=De[0],Be=De[1],je=Object(m.useState)(0),Ge=Object(v.a)(je,2),it=Ge[0],Et=Ge[1],St=Object(m.useState)(),Nt=Object(v.a)(St,2),_r=Nt[0],Nr=Nt[1],Pr=Object(m.useRef)();function Br(wr){var Ar=wr.touches[0],Xr=Ar.screenX,nn=Ar.screenY;Oe({x:Xr,y:nn}),window.clearInterval(Pr.current)}function Ir(wr){if(!he)return;wr.preventDefault();var Ar=wr.touches[0],Xr=Ar.screenX,nn=Ar.screenY;Oe({x:Xr,y:nn});var fr=Xr-he.x,un=nn-he.y;Ue(fr,un);var An=Date.now();Be(An),Et(An-Fe),Nr({x:fr,y:un})}function Kr(){if(!he)return;if(Oe(null),Nr(null),_r){var wr=_r.x/it,Ar=_r.y/it,Xr=Math.abs(wr),nn=Math.abs(Ar);if(Math.max(Xr,nn)<Tr)return;var fr=wr,un=Ar;Pr.current=window.setInterval(function(){if(Math.abs(fr)<Ot&&Math.abs(un)<Ot){window.clearInterval(Pr.current);return}fr*=or,un*=or,Ue(fr*Ht,un*Ht)},Ht)}}var zr=Object(m.useRef)(0),on=Object(m.useRef)(!1),$r=Object(m.useRef)();function gn(wr){var Ar=wr.deltaX,Xr=wr.deltaY,nn=0,fr=Math.abs(Ar),un=Math.abs(Xr);fr===un?nn=$r.current==="x"?Ar:Xr:fr>un?(nn=Ar,$r.current="x"):(nn=Xr,$r.current="y");var An=Date.now();An-zr.current>100&&(on.current=!1),(Ue(-nn,-nn)||on.current)&&(wr.preventDefault(),on.current=!0),zr.current=An}var Zr=Object(m.useRef)(null);Zr.current={onTouchStart:Br,onTouchMove:Ir,onTouchEnd:Kr,onWheel:gn},m.useEffect(function(){function wr(fr){Zr.current.onTouchStart(fr)}function Ar(fr){Zr.current.onTouchMove(fr)}function Xr(fr){Zr.current.onTouchEnd(fr)}function nn(fr){Zr.current.onWheel(fr)}return document.addEventListener("touchmove",Ar,{passive:!1}),document.addEventListener("touchend",Xr,{passive:!1}),Ae.current.addEventListener("touchstart",wr,{passive:!1}),Ae.current.addEventListener("wheel",nn),function(){document.removeEventListener("touchmove",Ar),document.removeEventListener("touchend",Xr)}},[])}function dt(){var Ae=Object(m.useRef)(new Map);function Ue(Le){return Ae.current.has(Le)||Ae.current.set(Le,m.createRef()),Ae.current.get(Le)}function Ke(Le){Ae.current.delete(Le)}return[Ue,Ke]}function Mt(Ae,Ue){var Ke=m.useRef(Ae),Le=m.useState({}),he=Object(v.a)(Le,2),Oe=he[1];function be(De){var Fe=typeof De=="function"?De(Ke.current):De;Fe!==Ke.current&&Ue(Fe,Ke.current),Ke.current=Fe,Oe({})}return[Ke.current,be]}var Tt=function(Ue){var Ke=Ue.position,Le=Ue.prefixCls,he=Ue.extra;if(!he)return null;var Oe,be=he;return Ke==="right"&&(Oe=be.right||!be.left&&be||null),Ke==="left"&&(Oe=be.left||null),Oe?m.createElement("div",{className:"".concat(Le,"-extra-content")},Oe):null};function yr(Ae,Ue){var Ke,Le=m.useContext(br),he=Le.prefixCls,Oe=Le.tabs,be=Ae.className,De=Ae.style,Fe=Ae.id,Be=Ae.animated,je=Ae.activeKey,Ge=Ae.rtl,it=Ae.extra,Et=Ae.editable,St=Ae.locale,Nt=Ae.tabPosition,_r=Ae.tabBarGutter,Nr=Ae.children,Pr=Ae.onTabClick,Br=Ae.onTabScroll,Ir=Object(m.useRef)(),Kr=Object(m.useRef)(),zr=Object(m.useRef)(),on=Object(m.useRef)(),$r=dt(),gn=Object(v.a)($r,2),Zr=gn[0],wr=gn[1],Ar=Nt==="top"||Nt==="bottom",Xr=Mt(0,function(yn,dn){Ar&&Br&&Br({direction:yn>dn?"left":"right"})}),nn=Object(v.a)(Xr,2),fr=nn[0],un=nn[1],An=Mt(0,function(yn,dn){!Ar&&Br&&Br({direction:yn>dn?"top":"bottom"})}),fn=Object(v.a)(An,2),En=fn[0],hn=fn[1],Fn=Object(m.useState)(0),Kn=Object(v.a)(Fn,2),Rn=Kn[0],Zn=Kn[1],Na=Object(m.useState)(0),ua=Object(v.a)(Na,2),zn=ua[0],xn=ua[1],Tn=Object(m.useState)(0),In=Object(v.a)(Tn,2),Cn=In[0],Bn=In[1],ga=Object(m.useState)(0),Va=Object(v.a)(ga,2),mn=Va[0],Ca=Va[1],Aa=Object(m.useState)(null),bn=Object(v.a)(Aa,2),pn=bn[0],Hn=bn[1],Bi=Object(m.useState)(null),xi=Object(v.a)(Bi,2),ti=xi[0],ri=xi[1],Li=Object(m.useState)(0),Ti=Object(v.a)(Li,2),Pi=Ti[0],Hi=Ti[1],Vi=Object(m.useState)(0),ki=Object(v.a)(Vi,2),ni=ki[0],wi=ki[1],vi=o(new Map),ai=Object(v.a)(vi,2),co=ai[0],gi=ai[1],Si=t(Oe,co,Rn),ii="".concat(he,"-nav-operations-hidden"),li=0,ja=0;Ar?Ge?(li=0,ja=Math.max(0,Rn-pn)):(li=Math.min(0,pn-Rn),ja=0):(li=Math.min(0,ti-zn),ja=0);function Ya(yn){return yn<li?[li,!1]:yn>ja?[ja,!1]:[yn,!0]}var cr=Object(m.useRef)(),hr=Object(m.useState)(),Qt=Object(v.a)(hr,2),cn=Qt[0],qt=Qt[1];function ui(){qt(Date.now())}function Yi(){window.clearTimeout(cr.current)}lt(Ir,function(yn,dn){var ia=!1;function Ia(Mi,ci){Mi(function(zi){var bi=Ya(zi+ci),oa=Object(v.a)(bi,2),Qi=oa[0],ho=oa[1];return ia=ho,Qi})}if(Ar){if(pn>=Rn)return ia;Ia(un,yn)}else{if(ti>=zn)return ia;Ia(hn,dn)}return Yi(),ui(),ia}),Object(m.useEffect)(function(){return Yi(),cn&&(cr.current=window.setTimeout(function(){qt(0)},100)),Yi},[cn]);function Sn(){var yn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:je,dn=Si.get(yn);if(!dn)return;if(Ar){var ia=fr;Ge?dn.right<fr?ia=dn.right:dn.right+dn.width>fr+pn&&(ia=dn.right+dn.width-pn):dn.left<-fr?ia=-dn.left:dn.left+dn.width>-fr+pn&&(ia=-(dn.left+dn.width-pn)),hn(0),un(Ya(ia)[0])}else{var Ia=En;dn.top<-En?Ia=-dn.top:dn.top+dn.height>-En+ti&&(Ia=-(dn.top+dn.height-ti)),un(0),hn(Ya(Ia)[0])}}var Oi=x(Si,{width:pn,height:ti,left:fr,top:En},{width:Cn,height:mn},{width:Pi,height:ni},Object(M.a)(Object(M.a)({},Ae),{},{tabs:Oe})),Io=Object(v.a)(Oi,2),Jo=Io[0],Qo=Io[1],Zo=Oe.map(function(yn){var dn=yn.key;return m.createElement(s,{id:Fe,prefixCls:he,key:dn,rtl:Ge,tab:yn,closable:yn.closable,editable:Et,active:dn===je,tabPosition:Nt,tabBarGutter:_r,renderWrapper:Nr,removeAriaLabel:St==null?void 0:St.removeAriaLabel,ref:Zr(dn),onClick:function(Ia){Pr(dn,Ia)},onRemove:function(){wr(dn)},onFocus:function(){Sn(dn),ui(),Ge||(Ir.current.scrollLeft=0),Ir.current.scrollTop=0}})}),fo=i(function(){var yn,dn,ia,Ia,Mi,ci,zi,bi,oa,Qi=((yn=Ir.current)===null||yn===void 0?void 0:yn.offsetWidth)||0,ho=((dn=Ir.current)===null||dn===void 0?void 0:dn.offsetHeight)||0,po=((ia=on.current)===null||ia===void 0?void 0:ia.offsetWidth)||0,Da=((Ia=on.current)===null||Ia===void 0?void 0:Ia.offsetHeight)||0,vn=((Mi=zr.current)===null||Mi===void 0?void 0:Mi.offsetWidth)||0,Ja=((ci=zr.current)===null||ci===void 0?void 0:ci.offsetHeight)||0;Hn(Qi),ri(ho),Hi(po),wi(Da);var di=(((zi=Kr.current)===null||zi===void 0?void 0:zi.offsetWidth)||0)-po,fi=(((bi=Kr.current)===null||bi===void 0?void 0:bi.offsetHeight)||0)-Da;Zn(di),xn(fi);var mo=(oa=zr.current)===null||oa===void 0?void 0:oa.className.includes(ii);Bn(di-(mo?0:vn)),Ca(fi-(mo?0:Ja)),gi(function(){var Zi=new Map;return Oe.forEach(function(Mo){var No=Mo.key,Ai=Zr(No).current;Ai&&Zi.set(No,{width:Ai.offsetWidth,height:Ai.offsetHeight,left:Ai.offsetLeft,top:Ai.offsetTop})}),Zi})}),qo=Oe.slice(0,Jo),Ra=Oe.slice(Qo+1),Yn=[].concat(Object(d.a)(qo),Object(d.a)(Ra)),ba=Object(m.useState)(),$n=Object(v.a)(ba,2),Wi=$n[0],es=$n[1],$a=Si.get(je),Do=Object(m.useRef)();function Lo(){c.a.cancel(Do.current)}Object(m.useEffect)(function(){var yn={};return $a&&(Ar?(Ge?yn.right=$a.right:yn.left=$a.left,yn.width=$a.width):(yn.top=$a.top,yn.height=$a.height)),Lo(),Do.current=c()(function(){es(yn)}),Lo},[$a,Ar,Ge]),Object(m.useEffect)(function(){Sn()},[je,$a,Si,Ar]),Object(m.useEffect)(function(){fo()},[Ge,_r,je,Oe.map(function(yn){return yn.key}).join("_")]);var Po=!!Yn.length,Ci="".concat(he,"-nav-wrap"),$i,Ki,ko,Ji;return Ar?Ge?(Ki=fr>0,$i=fr+pn<Rn):($i=fr<0,Ki=-fr+pn<Rn):(ko=En<0,Ji=-En+ti<zn),m.createElement("div",{ref:Ue,role:"tablist",className:w()("".concat(he,"-nav"),be),style:De,onKeyDown:function(){ui()}},m.createElement(Tt,{position:"left",extra:it,prefixCls:he}),m.createElement(r.a,{onResize:fo},m.createElement("div",{className:w()(Ci,(Ke={},Object(N.a)(Ke,"".concat(Ci,"-ping-left"),$i),Object(N.a)(Ke,"".concat(Ci,"-ping-right"),Ki),Object(N.a)(Ke,"".concat(Ci,"-ping-top"),ko),Object(N.a)(Ke,"".concat(Ci,"-ping-bottom"),Ji),Ke)),ref:Ir},m.createElement(r.a,{onResize:fo},m.createElement("div",{ref:Kr,className:"".concat(he,"-nav-list"),style:{transform:"translate(".concat(fr,"px, ").concat(En,"px)"),transition:cn?"none":void 0}},Zo,m.createElement(Vr,{ref:on,prefixCls:he,locale:St,editable:Et,style:{visibility:Po?"hidden":null}}),m.createElement("div",{className:w()("".concat(he,"-ink-bar"),Object(N.a)({},"".concat(he,"-ink-bar-animated"),Be.inkBar)),style:Wi}))))),m.createElement(ir,Object.assign({},Ae,{ref:zr,prefixCls:he,tabs:Yn,className:!Po&&ii})),m.createElement(Tt,{position:"right",extra:it,prefixCls:he}))}var Gr=m.forwardRef(yr);function Yr(Ae){var Ue=Ae.id,Ke=Ae.activeKey,Le=Ae.animated,he=Ae.tabPosition,Oe=Ae.rtl,be=Ae.destroyInactiveTabPane,De=m.useContext(br),Fe=De.prefixCls,Be=De.tabs,je=Le.tabPane,Ge=Be.findIndex(function(it){return it.key===Ke});return m.createElement("div",{className:w()("".concat(Fe,"-content-holder"))},m.createElement("div",{className:w()("".concat(Fe,"-content"),"".concat(Fe,"-content-").concat(he),Object(N.a)({},"".concat(Fe,"-content-animated"),je)),style:Ge&&je?Object(N.a)({},Oe?"marginRight":"marginLeft","-".concat(Ge,"00%")):null},Be.map(function(it){return m.cloneElement(it.node,{key:it.key,prefixCls:Fe,tabKey:it.key,id:Ue,animated:je,active:it.key===Ke,destroyInactiveTabPane:be})})))}function mr(Ae){var Ue=Ae.prefixCls,Ke=Ae.forceRender,Le=Ae.className,he=Ae.style,Oe=Ae.id,be=Ae.active,De=Ae.animated,Fe=Ae.destroyInactiveTabPane,Be=Ae.tabKey,je=Ae.children,Ge=m.useState(Ke),it=Object(v.a)(Ge,2),Et=it[0],St=it[1];m.useEffect(function(){be?St(!0):Fe&&St(!1)},[be,Fe]);var Nt={};return be||(De?(Nt.visibility="hidden",Nt.height=0,Nt.overflowY="hidden"):Nt.display="none"),m.createElement("div",{id:Oe&&"".concat(Oe,"-panel-").concat(Be),role:"tabpanel",tabIndex:be?0:-1,"aria-labelledby":Oe&&"".concat(Oe,"-tab-").concat(Be),"aria-hidden":!be,style:Object(M.a)(Object(M.a)({},Nt),he),className:w()("".concat(Ue,"-tabpane"),be&&"".concat(Ue,"-tabpane-active"),Le)},(be||Et||Ke)&&je)}var Wr=0;function Cr(Ae){return Object(b.a)(Ae).map(function(Ue){if(m.isValidElement(Ue)){var Ke=Ue.key!==void 0?String(Ue.key):void 0;return Object(M.a)(Object(M.a)({key:Ke},Ue.props),{},{node:Ue})}return null}).filter(function(Ue){return Ue})}function tn(Ae,Ue){var Ke,Le=Ae.id,he=Ae.prefixCls,Oe=he===void 0?"rc-tabs":he,be=Ae.className,De=Ae.children,Fe=Ae.direction,Be=Ae.activeKey,je=Ae.defaultActiveKey,Ge=Ae.editable,it=Ae.animated,Et=Ae.tabPosition,St=Et===void 0?"top":Et,Nt=Ae.tabBarGutter,_r=Ae.tabBarStyle,Nr=Ae.tabBarExtraContent,Pr=Ae.locale,Br=Ae.moreIcon,Ir=Ae.moreTransitionName,Kr=Ae.destroyInactiveTabPane,zr=Ae.renderTabBar,on=Ae.onChange,$r=Ae.onTabClick,gn=Ae.onTabScroll,Zr=Object(C.a)(Ae,["id","prefixCls","className","children","direction","activeKey","defaultActiveKey","editable","animated","tabPosition","tabBarGutter","tabBarStyle","tabBarExtraContent","locale","moreIcon","moreTransitionName","destroyInactiveTabPane","renderTabBar","onChange","onTabClick","onTabScroll"]),wr=Cr(De),Ar=Fe==="rtl",Xr;it===!1?Xr={inkBar:!1,tabPane:!1}:Xr=Object(M.a)({inkBar:!0,tabPane:!1},it!==!0?it:null);var nn=Object(m.useState)(!1),fr=Object(v.a)(nn,2),un=fr[0],An=fr[1];Object(m.useEffect)(function(){An(Gt())},[]);var fn=Object(p.a)(function(){var mn;return(mn=wr[0])===null||mn===void 0?void 0:mn.key},{value:Be,defaultValue:je}),En=Object(v.a)(fn,2),hn=En[0],Fn=En[1],Kn=Object(m.useState)(function(){return wr.findIndex(function(mn){return mn.key===hn})}),Rn=Object(v.a)(Kn,2),Zn=Rn[0],Na=Rn[1];Object(m.useEffect)(function(){var mn=wr.findIndex(function(Aa){return Aa.key===hn});if(mn===-1){var Ca;mn=Math.max(0,Math.min(Zn,wr.length-1)),Fn((Ca=wr[mn])===null||Ca===void 0?void 0:Ca.key)}Na(mn)},[wr.map(function(mn){return mn.key}).join("_"),hn,Zn]);var ua=Object(p.a)(null,{value:Le}),zn=Object(v.a)(ua,2),xn=zn[0],Tn=zn[1],In=St;un&&!["left","right"].includes(St)&&(In="top"),Object(m.useEffect)(function(){Le||(Tn("rc-tabs-".concat(Wr)),Wr+=1)},[]);function Cn(mn,Ca){$r==null||$r(mn,Ca),Fn(mn),on==null||on(mn)}var Bn={id:xn,activeKey:hn,animated:Xr,tabPosition:In,rtl:Ar,mobile:un},ga,Va=Object(M.a)(Object(M.a)({},Bn),{},{editable:Ge,locale:Pr,moreIcon:Br,moreTransitionName:Ir,tabBarGutter:Nt,onTabClick:Cn,onTabScroll:gn,extra:Nr,style:_r,panes:De});return zr?ga=zr(Va,Gr):ga=m.createElement(Gr,Object.assign({},Va)),m.createElement(br.Provider,{value:{tabs:wr,prefixCls:Oe}},m.createElement("div",Object.assign({ref:Ue,id:Le,className:w()(Oe,"".concat(Oe,"-").concat(In),(Ke={},Object(N.a)(Ke,"".concat(Oe,"-mobile"),un),Object(N.a)(Ke,"".concat(Oe,"-editable"),Ge),Object(N.a)(Ke,"".concat(Oe,"-rtl"),Ar),Ke),be)},Zr),ga,m.createElement(Yr,Object.assign({destroyInactiveTabPane:Kr},Bn,{animated:Xr}))))}var Lr=m.forwardRef(tn);Lr.TabPane=mr;var rn=Lr,Nn=Q.b=rn},kSUc:function(F,Q,j){},lPiR:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(v){var C=N,M=C.lib,m=M.WordArray,y=M.Hasher,w=C.algo,b=[],p=[];(function(){function c(u){for(var f=v.sqrt(u),s=2;s<=f;s++)if(!(u%s))return!1;return!0}function r(u){return(u-(u|0))*4294967296|0}for(var i=2,o=0;o<64;)c(i)&&(o<8&&(b[o]=r(v.pow(i,1/2))),p[o]=r(v.pow(i,1/3)),o++),i++})();var d=[],n=w.SHA256=y.extend({_doReset:function(){this._hash=new m.init(b.slice(0))},_doProcessBlock:function(c,r){for(var i=this._hash.words,o=i[0],u=i[1],f=i[2],s=i[3],l=i[4],t=i[5],S=i[6],x=i[7],h=0;h<64;h++){if(h<16)d[h]=c[r+h]|0;else{var R=d[h-15],O=(R<<25|R>>>7)^(R<<14|R>>>18)^R>>>3,g=d[h-2],_=(g<<15|g>>>17)^(g<<13|g>>>19)^g>>>10;d[h]=O+d[h-7]+_+d[h-16]}var E=l&t^~l&S,T=o&u^o&f^u&f,L=(o<<30|o>>>2)^(o<<19|o>>>13)^(o<<10|o>>>22),I=(l<<26|l>>>6)^(l<<21|l>>>11)^(l<<7|l>>>25),P=x+I+E+p[h]+d[h],G=L+T;x=S,S=t,t=l,l=s+P|0,s=f,f=u,u=o,o=P+G|0}i[0]=i[0]+o|0,i[1]=i[1]+u|0,i[2]=i[2]+f|0,i[3]=i[3]+s|0,i[4]=i[4]+l|0,i[5]=i[5]+t|0,i[6]=i[6]+S|0,i[7]=i[7]+x|0},_doFinalize:function(){var c=this._data,r=c.words,i=this._nDataBytes*8,o=c.sigBytes*8;return r[o>>>5]|=128<<24-o%32,r[(o+64>>>9<<4)+14]=v.floor(i/4294967296),r[(o+64>>>9<<4)+15]=i,c.sigBytes=r.length*4,this._process(),this._hash},clone:function(){var c=y.clone.call(this);return c._hash=this._hash.clone(),c}});C.SHA256=y._createHelper(n),C.HmacSHA256=y._createHmacHelper(n)}(Math),N.SHA256})},lZu9:function(F,Q,j){(function(N){N(j("VrN/"),j("1eCo"),j("8EBN"))})(function(N){"use strict";N.defineMode("markdown",function(v,C){var M=N.getMode(v,"text/html"),m=M.name=="null";function y(B){if(N.findModeByName){var k=N.findModeByName(B);k&&(B=k.mime||k.mimes[0])}var K=N.getMode(v,B);return K.name=="null"?null:K}C.highlightFormatting===void 0&&(C.highlightFormatting=!1),C.maxBlockquoteDepth===void 0&&(C.maxBlockquoteDepth=0),C.taskLists===void 0&&(C.taskLists=!1),C.strikethrough===void 0&&(C.strikethrough=!1),C.emoji===void 0&&(C.emoji=!1),C.fencedCodeBlockHighlighting===void 0&&(C.fencedCodeBlockHighlighting=!0),C.fencedCodeBlockDefaultMode===void 0&&(C.fencedCodeBlockDefaultMode="text/plain"),C.xml===void 0&&(C.xml=!0),C.tokenTypeOverrides===void 0&&(C.tokenTypeOverrides={});var w={header:"header",code:"comment",quote:"quote",list1:"variable-2",list2:"variable-3",list3:"keyword",hr:"hr",image:"image",imageAltText:"image-alt-text",imageMarker:"image-marker",formatting:"formatting",linkInline:"link",linkEmail:"link",linkText:"link",linkHref:"string",em:"em",strong:"strong",strikethrough:"strikethrough",emoji:"builtin"};for(var b in w)w.hasOwnProperty(b)&&C.tokenTypeOverrides[b]&&(w[b]=C.tokenTypeOverrides[b]);var p=/^([*\-_])(?:\s*\1){2,}\s*$/,d=/^(?:[*\-+]|^[0-9]+([.)]))\s+/,n=/^\[(x| )\](?=\s)/i,c=C.allowAtxHeaderWithoutSpace?/^(#+)/:/^(#+)(?: |$)/,r=/^ {0,3}(?:\={1,}|-{2,})\s*$/,i=/^[^#!\[\]*_\\<>` "'(~:]+/,o=/^(~~~+|```+)[ \t]*([\w\/+#-]*)[^\n`]*$/,u=/^\s*\[[^\]]+?\]:.*$/,f=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC9\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDF3C-\uDF3E]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]/,s=" ";function l(B,k,K){return k.f=k.inline=K,K(B,k)}function t(B,k,K){return k.f=k.block=K,K(B,k)}function S(B){return!B||!/\S/.test(B.string)}function x(B){if(B.linkTitle=!1,B.linkHref=!1,B.linkText=!1,B.em=!1,B.strong=!1,B.strikethrough=!1,B.quote=0,B.indentedCode=!1,B.f==R){var k=m;if(!k){var K=N.innerMode(M,B.htmlState);k=K.mode.name=="xml"&&K.state.tagStart===null&&!K.state.context&&K.state.tokenize.isInText}k&&(B.f=E,B.block=h,B.htmlState=null)}return B.trailingSpace=0,B.trailingSpaceNewLine=!1,B.prevLine=B.thisLine,B.thisLine={stream:null},null}function h(B,k){var K=B.column()===k.indentation,Y=S(k.prevLine.stream),ne=k.indentedCode,oe=k.prevLine.hr,_e=k.list!==!1,xe=(k.listStack[k.listStack.length-1]||0)+3;k.indentedCode=!1;var le=k.indentation;if(k.indentationDiff===null&&(k.indentationDiff=k.indentation,_e)){for(k.list=null;le<k.listStack[k.listStack.length-1];)k.listStack.pop(),k.listStack.length?k.indentation=k.listStack[k.listStack.length-1]:k.list=!1;k.list!==!1&&(k.indentationDiff=le-k.listStack[k.listStack.length-1])}var me=!Y&&!oe&&!k.prevLine.header&&(!_e||!ne)&&!k.prevLine.fencedCodeEnd,de=(k.list===!1||oe||Y)&&k.indentation<=xe&&B.match(p),ae=null;if(k.indentationDiff>=4&&(ne||k.prevLine.fencedCodeEnd||k.prevLine.header||Y))return B.skipToEnd(),k.indentedCode=!0,w.code;if(B.eatSpace())return null;if(K&&k.indentation<=xe&&(ae=B.match(c))&&ae[1].length<=6)return k.quote=0,k.header=ae[1].length,k.thisLine.header=!0,C.highlightFormatting&&(k.formatting="header"),k.f=k.inline,g(k);if(k.indentation<=xe&&B.eat(">"))return k.quote=K?1:k.quote+1,C.highlightFormatting&&(k.formatting="quote"),B.eatSpace(),g(k);if(!de&&!k.setext&&K&&k.indentation<=xe&&(ae=B.match(d))){var ie=ae[1]?"ol":"ul";return k.indentation=le+B.current().length,k.list=!0,k.quote=0,k.listStack.push(k.indentation),k.em=!1,k.strong=!1,k.code=!1,k.strikethrough=!1,C.taskLists&&B.match(n,!1)&&(k.taskList=!0),k.f=k.inline,C.highlightFormatting&&(k.formatting=["list","list-"+ie]),g(k)}else{if(K&&k.indentation<=xe&&(ae=B.match(o,!0)))return k.quote=0,k.fencedEndRE=new RegExp(ae[1]+"+ *$"),k.localMode=C.fencedCodeBlockHighlighting&&y(ae[2]||C.fencedCodeBlockDefaultMode),k.localMode&&(k.localState=N.startState(k.localMode)),k.f=k.block=O,C.highlightFormatting&&(k.formatting="code-block"),k.code=-1,g(k);if(k.setext||(!me||!_e)&&!k.quote&&k.list===!1&&!k.code&&!de&&!u.test(B.string)&&(ae=B.lookAhead(1))&&(ae=ae.match(r)))return k.setext?(k.header=k.setext,k.setext=0,B.skipToEnd(),C.highlightFormatting&&(k.formatting="header")):(k.header=ae[0].charAt(0)=="="?1:2,k.setext=k.header),k.thisLine.header=!0,k.f=k.inline,g(k);if(de)return B.skipToEnd(),k.hr=!0,k.thisLine.hr=!0,w.hr;if(B.peek()==="[")return l(B,k,G)}return l(B,k,k.inline)}function R(B,k){var K=M.token(B,k.htmlState);if(!m){var Y=N.innerMode(M,k.htmlState);(Y.mode.name=="xml"&&Y.state.tagStart===null&&!Y.state.context&&Y.state.tokenize.isInText||k.md_inside&&B.current().indexOf(">")>-1)&&(k.f=E,k.block=h,k.htmlState=null)}return K}function O(B,k){var K=k.listStack[k.listStack.length-1]||0,Y=k.indentation<K,ne=K+3;if(k.fencedEndRE&&k.indentation<=ne&&(Y||B.match(k.fencedEndRE))){C.highlightFormatting&&(k.formatting="code-block");var oe;return Y||(oe=g(k)),k.localMode=k.localState=null,k.block=h,k.f=E,k.fencedEndRE=null,k.code=0,k.thisLine.fencedCodeEnd=!0,Y?t(B,k,k.block):oe}else return k.localMode?k.localMode.token(B,k.localState):(B.skipToEnd(),w.code)}function g(B){var k=[];if(B.formatting){k.push(w.formatting),typeof B.formatting=="string"&&(B.formatting=[B.formatting]);for(var K=0;K<B.formatting.length;K++)k.push(w.formatting+"-"+B.formatting[K]),B.formatting[K]==="header"&&k.push(w.formatting+"-"+B.formatting[K]+"-"+B.header),B.formatting[K]==="quote"&&(!C.maxBlockquoteDepth||C.maxBlockquoteDepth>=B.quote?k.push(w.formatting+"-"+B.formatting[K]+"-"+B.quote):k.push("error"))}if(B.taskOpen)return k.push("meta"),k.length?k.join(" "):null;if(B.taskClosed)return k.push("property"),k.length?k.join(" "):null;if(B.linkHref?k.push(w.linkHref,"url"):(B.strong&&k.push(w.strong),B.em&&k.push(w.em),B.strikethrough&&k.push(w.strikethrough),B.emoji&&k.push(w.emoji),B.linkText&&k.push(w.linkText),B.code&&k.push(w.code),B.image&&k.push(w.image),B.imageAltText&&k.push(w.imageAltText,"link"),B.imageMarker&&k.push(w.imageMarker)),B.header&&k.push(w.header,w.header+"-"+B.header),B.quote&&(k.push(w.quote),!C.maxBlockquoteDepth||C.maxBlockquoteDepth>=B.quote?k.push(w.quote+"-"+B.quote):k.push(w.quote+"-"+C.maxBlockquoteDepth)),B.list!==!1){var Y=(B.listStack.length-1)%3;Y?Y===1?k.push(w.list2):k.push(w.list3):k.push(w.list1)}return B.trailingSpaceNewLine?k.push("trailing-space-new-line"):B.trailingSpace&&k.push("trailing-space-"+(B.trailingSpace%2?"a":"b")),k.length?k.join(" "):null}function _(B,k){return B.match(i,!0)?g(k):void 0}function E(B,k){var K=k.text(B,k);if(typeof K!="undefined")return K;if(k.list)return k.list=null,g(k);if(k.taskList){var Y=B.match(n,!0)[1]===" ";return Y?k.taskOpen=!0:k.taskClosed=!0,C.highlightFormatting&&(k.formatting="task"),k.taskList=!1,g(k)}if(k.taskOpen=!1,k.taskClosed=!1,k.header&&B.match(/^#+$/,!0))return C.highlightFormatting&&(k.formatting="header"),g(k);var ne=B.next();if(k.linkTitle){k.linkTitle=!1;var oe=ne;ne==="("&&(oe=")"),oe=(oe+"").replace(/([.?*+^\[\]\\(){}|-])/g,"\\$1");var _e="^\\s*(?:[^"+oe+"\\\\]+|\\\\\\\\|\\\\.)"+oe;if(B.match(new RegExp(_e),!0))return w.linkHref}if(ne==="`"){var xe=k.formatting;C.highlightFormatting&&(k.formatting="code"),B.eatWhile("`");var le=B.current().length;if(k.code==0&&(!k.quote||le==1))return k.code=le,g(k);if(le==k.code){var me=g(k);return k.code=0,me}else return k.formatting=xe,g(k)}else if(k.code)return g(k);if(ne==="\\"&&(B.next(),C.highlightFormatting)){var de=g(k),ae=w.formatting+"-escape";return de?de+" "+ae:ae}if(ne==="!"&&B.match(/\[[^\]]*\] ?(?:\(|\[)/,!1))return k.imageMarker=!0,k.image=!0,C.highlightFormatting&&(k.formatting="image"),g(k);if(ne==="["&&k.imageMarker&&B.match(/[^\]]*\](\(.*?\)| ?\[.*?\])/,!1))return k.imageMarker=!1,k.imageAltText=!0,C.highlightFormatting&&(k.formatting="image"),g(k);if(ne==="]"&&k.imageAltText){C.highlightFormatting&&(k.formatting="image");var de=g(k);return k.imageAltText=!1,k.image=!1,k.inline=k.f=L,de}if(ne==="["&&!k.image)return k.linkText&&B.match(/^.*?\]/)||(k.linkText=!0,C.highlightFormatting&&(k.formatting="link")),g(k);if(ne==="]"&&k.linkText){C.highlightFormatting&&(k.formatting="link");var de=g(k);return k.linkText=!1,k.inline=k.f=B.match(/\(.*?\)| ?\[.*?\]/,!1)?L:E,de}if(ne==="<"&&B.match(/^(https?|ftps?):\/\/(?:[^\\>]|\\.)+>/,!1)){k.f=k.inline=T,C.highlightFormatting&&(k.formatting="link");var de=g(k);return de?de+=" ":de="",de+w.linkInline}if(ne==="<"&&B.match(/^[^> \\]+@(?:[^\\>]|\\.)+>/,!1)){k.f=k.inline=T,C.highlightFormatting&&(k.formatting="link");var de=g(k);return de?de+=" ":de="",de+w.linkEmail}if(C.xml&&ne==="<"&&B.match(/^(!--|\?|!\[CDATA\[|[a-z][a-z0-9-]*(?:\s+[a-z_:.\-]+(?:\s*=\s*[^>]+)?)*\s*(?:>|$))/i,!1)){var ie=B.string.indexOf(">",B.pos);if(ie!=-1){var q=B.string.substring(B.start,ie);/markdown\s*=\s*('|"){0,1}1('|"){0,1}/.test(q)&&(k.md_inside=!0)}return B.backUp(1),k.htmlState=N.startState(M),t(B,k,R)}if(C.xml&&ne==="<"&&B.match(/^\/\w*?>/))return k.md_inside=!1,"tag";if(ne==="*"||ne==="_"){for(var ue=1,Z=B.pos==1?" ":B.string.charAt(B.pos-2);ue<3&&B.eat(ne);)ue++;var ee=B.peek()||" ",Ee=!/\s/.test(ee)&&(!f.test(ee)||/\s/.test(Z)||f.test(Z)),te=!/\s/.test(Z)&&(!f.test(Z)||/\s/.test(ee)||f.test(ee)),J=null,X=null;if(ue%2&&(!k.em&&Ee&&(ne==="*"||!te||f.test(Z))?J=!0:k.em==ne&&te&&(ne==="*"||!Ee||f.test(ee))&&(J=!1)),ue>1&&(!k.strong&&Ee&&(ne==="*"||!te||f.test(Z))?X=!0:k.strong==ne&&te&&(ne==="*"||!Ee||f.test(ee))&&(X=!1)),X!=null||J!=null){C.highlightFormatting&&(k.formatting=J==null?"strong":X==null?"em":"strong em"),J===!0&&(k.em=ne),X===!0&&(k.strong=ne);var me=g(k);return J===!1&&(k.em=!1),X===!1&&(k.strong=!1),me}}else if(ne===" "&&(B.eat("*")||B.eat("_"))){if(B.peek()===" ")return g(k);B.backUp(1)}if(C.strikethrough){if(ne==="~"&&B.eatWhile(ne)){if(k.strikethrough){C.highlightFormatting&&(k.formatting="strikethrough");var me=g(k);return k.strikethrough=!1,me}else if(B.match(/^[^\s]/,!1))return k.strikethrough=!0,C.highlightFormatting&&(k.formatting="strikethrough"),g(k)}else if(ne===" "&&B.match(/^~~/,!0)){if(B.peek()===" ")return g(k);B.backUp(2)}}if(C.emoji&&ne===":"&&B.match(/^(?:[a-z_\d+][a-z_\d+-]*|\-[a-z_\d+][a-z_\d+-]*):/)){k.emoji=!0,C.highlightFormatting&&(k.formatting="emoji");var $=g(k);return k.emoji=!1,$}return ne===" "&&(B.match(/^ +$/,!1)?k.trailingSpace++:k.trailingSpace&&(k.trailingSpaceNewLine=!0)),g(k)}function T(B,k){var K=B.next();if(K===">"){k.f=k.inline=E,C.highlightFormatting&&(k.formatting="link");var Y=g(k);return Y?Y+=" ":Y="",Y+w.linkInline}return B.match(/^[^>]+/,!0),w.linkInline}function L(B,k){if(B.eatSpace())return null;var K=B.next();return K==="("||K==="["?(k.f=k.inline=P(K==="("?")":"]"),C.highlightFormatting&&(k.formatting="link-string"),k.linkHref=!0,g(k)):"error"}var I={")":/^(?:[^\\\(\)]|\\.|\((?:[^\\\(\)]|\\.)*\))*?(?=\))/,"]":/^(?:[^\\\[\]]|\\.|\[(?:[^\\\[\]]|\\.)*\])*?(?=\])/};function P(B){return function(k,K){var Y=k.next();if(Y===B){K.f=K.inline=E,C.highlightFormatting&&(K.formatting="link-string");var ne=g(K);return K.linkHref=!1,ne}return k.match(I[B]),K.linkHref=!0,g(K)}}function G(B,k){return B.match(/^([^\]\\]|\\.)*\]:/,!1)?(k.f=W,B.next(),C.highlightFormatting&&(k.formatting="link"),k.linkText=!0,g(k)):l(B,k,E)}function W(B,k){if(B.match(/^\]:/,!0)){k.f=k.inline=H,C.highlightFormatting&&(k.formatting="link");var K=g(k);return k.linkText=!1,K}return B.match(/^([^\]\\]|\\.)+/,!0),w.linkText}function H(B,k){return B.eatSpace()?null:(B.match(/^[^\s]+/,!0),B.peek()===void 0?k.linkTitle=!0:B.match(/^(?:\s+(?:"(?:[^"\\]|\\\\|\\.)+"|'(?:[^'\\]|\\\\|\\.)+'|\((?:[^)\\]|\\\\|\\.)+\)))?/,!0),k.f=k.inline=E,w.linkHref+" url")}var z={startState:function(){return{f:h,prevLine:{stream:null},thisLine:{stream:null},block:h,htmlState:null,indentation:0,inline:E,text:_,formatting:!1,linkText:!1,linkHref:!1,linkTitle:!1,code:0,em:!1,strong:!1,header:0,setext:0,hr:!1,taskList:!1,list:!1,listStack:[],quote:0,trailingSpace:0,trailingSpaceNewLine:!1,strikethrough:!1,emoji:!1,fencedEndRE:null}},copyState:function(B){return{f:B.f,prevLine:B.prevLine,thisLine:B.thisLine,block:B.block,htmlState:B.htmlState&&N.copyState(M,B.htmlState),indentation:B.indentation,localMode:B.localMode,localState:B.localMode?N.copyState(B.localMode,B.localState):null,inline:B.inline,text:B.text,formatting:!1,linkText:B.linkText,linkTitle:B.linkTitle,linkHref:B.linkHref,code:B.code,em:B.em,strong:B.strong,strikethrough:B.strikethrough,emoji:B.emoji,header:B.header,setext:B.setext,hr:B.hr,taskList:B.taskList,list:B.list,listStack:B.listStack.slice(0),quote:B.quote,indentedCode:B.indentedCode,trailingSpace:B.trailingSpace,trailingSpaceNewLine:B.trailingSpaceNewLine,md_inside:B.md_inside,fencedEndRE:B.fencedEndRE}},token:function(B,k){if(k.formatting=!1,B!=k.thisLine.stream){if(k.header=0,k.hr=!1,B.match(/^\s*$/,!0))return x(k),null;if(k.prevLine=k.thisLine,k.thisLine={stream:B},k.taskList=!1,k.trailingSpace=0,k.trailingSpaceNewLine=!1,!k.localState&&(k.f=k.block,k.f!=R)){var K=B.match(/^\s*/,!0)[0].replace(/\t/g,s).length;if(k.indentation=K,k.indentationDiff=null,K>0)return null}}return k.f(B,k)},innerMode:function(B){return B.block==R?{state:B.htmlState,mode:M}:B.localState?{state:B.localState,mode:B.localMode}:{state:B,mode:z}},indent:function(B,k,K){return B.block==R&&M.indent?M.indent(B.htmlState,k,K):B.localState&&B.localMode.indent?B.localMode.indent(B.localState,k,K):N.Pass},blankLine:x,getType:g,blockCommentStart:"<!--",blockCommentEnd:"-->",closeBrackets:"()[]{}''\"\"``",fold:"markdown"};return z},"xml"),N.defineMIME("text/markdown","markdown"),N.defineMIME("text/x-markdown","markdown")})},mOS8:function(F,Q,j){F.exports=j.p+"static/403Qrcode.6c17b6f4.png"},mxV5:function(module,exports,__webpack_require__){(function(global){var require,require;(function(F){if(!0)module.exports=F();else var Q})(function(){var define,module,exports;return function(){function F(Q,j,N){function v(m,y){if(!j[m]){if(!Q[m]){var w=typeof require=="function"&&require;if(!y&&w)return require(m,!0);if(C)return C(m,!0);var b=new Error("Cannot find module '"+m+"'");throw b.code="MODULE_NOT_FOUND",b}var p=j[m]={exports:{}};Q[m][0].call(p.exports,function(d){var n=Q[m][1][d];return v(n||d)},p,p.exports,F,Q,j,N)}return j[m].exports}for(var C=typeof require=="function"&&require,M=0;M<N.length;M++)v(N[M]);return v}return F}()({1:[function(F,Q,j){"use strict";var N=F("./browser/client");N.Buffer=F("buffer").Buffer,N.urllib=F("../shims/xhr"),N.version=F("./browser/version").version,Q.exports=N},{"../shims/xhr":291,"./browser/client":2,"./browser/version":5,buffer:73}],2:[function(F,Q,j){(function(N,v){"use strict";var C=F("babel-runtime/core-js/promise"),M=p(C),m=F("babel-runtime/regenerator"),y=p(m),w=F("babel-runtime/core-js/object/assign"),b=p(w);function p(G){return G&&G.__esModule?G:{default:G}}var d=F("debug")("ali-oss"),n=F("copy-to"),c=F("xml2js"),r=F("agentkeepalive"),i=F("merge-descriptors"),o=F("url"),u=F("is-type-of"),f=F("platform"),s=F("utility"),l=F("urllib"),t=F("./version"),S=F("bowser"),x=F("../common/signUtils"),h=F("../common/utils/isIP"),R=h.isIP,O=F("../common/client/initOptions"),g=F("../common/utils/createRequest"),_=g.createRequest,E=new r;function T(){var G=f.name,W=f.version;G&&G.toLowerCase&&G.toLowerCase()==="ie"&&W.split(".")[0]<10&&console.warn("ali-oss does not support the current browser")}function L(){return location&&location.protocol==="https:"}function I(G,W){if(T(),!(this instanceof I))return new I(G,W);G&&G.inited?this.options=G:this.options=I.initOptions(G),this.options.cancelFlag=!1,this.options.urllib?this.urllib=this.options.urllib:(this.urllib=l,this.agent=this.options.agent||E),this.ctx=W,this.userAgent=this._getUserAgent(),this.options.amendTimeSkewed=0}Q.exports=I,I.initOptions=function(W){W.stsToken||console.warn("Please use STS Token for safety, see more details at https://help.aliyun.com/document_detail/32077.html");var H=(0,b.default)({secure:L(),useFetch:!1},W);return O(H)};var P=I.prototype;P.debug=d,i(P,F("./object")),i(P,F("../common/bucket/getBucketWebsite")),i(P,F("../common/bucket/putBucketWebsite")),i(P,F("../common/bucket/deleteBucketWebsite")),i(P,F("../common/bucket/getBucketLifecycle")),i(P,F("../common/bucket/putBucketLifecycle")),i(P,F("../common/bucket/deleteBucketLifecycle")),i(P,F("../common/bucket/putBucketVersioning")),i(P,F("../common/bucket/getBucketVersioning")),i(P,F("./managed-upload")),i(P,F("../common/multipart")),i(P,F("../common/parallel")),P.signature=function(W){return this.debug("authorization stringToSign: %s",W,"info"),x.computeSignature(this.options.accessKeySecret,W)},P.authorization=function(W,H,z,B){var k=x.buildCanonicalString(W.toUpperCase(),H,{headers:B,parameters:z});return x.authorization(this.options.accessKeyId,this.options.accessKeySecret,k)},P.request=function(W){var H,z,B,k,K,Y;return y.default.async(function(oe){for(;;)switch(oe.prev=oe.next){case 0:return H=_.call(this,W),this.options.useFetch||(H.params.mode="disable-fetch"),z=void 0,B=void 0,k=!!W.stream,oe.prev=5,oe.next=8,y.default.awrap(this.urllib.request(H.url,H.params));case 8:z=oe.sent,this.debug("response %s %s, got %s, headers: %j",W.method,H.url,z.status,z.headers,"info"),oe.next=15;break;case 12:oe.prev=12,oe.t0=oe.catch(5),B=oe.t0;case 15:if(K=void 0,!(z&&W.successStatuses&&W.successStatuses.indexOf(z.status)===-1)){oe.next=28;break}return oe.next=19,y.default.awrap(this.requestError(z));case 19:if(K=oe.sent,!(K.code==="RequestTimeTooSkewed"&&!k)){oe.next=25;break}return this.options.amendTimeSkewed=+new Date(K.serverTime)-new Date,oe.next=24,y.default.awrap(this.request(W));case 24:return oe.abrupt("return",oe.sent);case 25:K.params=W,oe.next=32;break;case 28:if(!B){oe.next=32;break}return oe.next=31,y.default.awrap(this.requestError(B));case 31:K=oe.sent;case 32:if(!K){oe.next=34;break}throw K;case 34:if(!W.xmlResponse){oe.next=39;break}return oe.next=37,y.default.awrap(this.parseXML(z.data));case 37:Y=oe.sent,z.data=Y;case 39:return oe.abrupt("return",z);case 40:case"end":return oe.stop()}},null,this,[[5,12]])},P._getResource=function(W){var H="/";return W.bucket&&(H+=W.bucket+"/"),W.object&&(H+=W.object),H},P._isIP=R,P._escape=function(W){return s.encodeURIComponent(W).replace(/%2F/g,"/")},P._getReqUrl=function(W){var H={};n(this.options.endpoint).to(H);var z=this._isIP(H.hostname),B=this.options.cname;W.bucket&&!B&&!z&&(H.host=W.bucket+"."+H.host);var k="/";W.bucket&&z&&(k+=W.bucket+"/"),W.object&&(k+=this._escape(W.object).replace(/\+/g,"%2B")),H.pathname=k;var K={};if(W.query&&i(K,W.query),W.subres){var Y={};u.string(W.subres)?Y[W.subres]="":u.array(W.subres)?W.subres.forEach(function(ne){Y[ne]=""}):Y=W.subres,i(K,Y)}return H.query=K,o.format(H)},P._getUserAgent=function(){var W=v&&v.browser?"js":"nodejs",H="aliyun-sdk-"+W+"/"+t.version,z=f.description;return!z&&v&&(z="Node.js "+v.version.slice(1)+" on "+v.platform+" "+v.arch),this._checkUserAgent(H+" "+z)},P._checkUserAgent=function(W){var H=W.replace(/\u03b1/,"alpha").replace(/\u03b2/,"beta");return H},P.checkBrowserAndVersion=function(W,H){return S.name===W&&S.version.split(".")[0]===H},P.parseXML=function(W){return new M.default(function(H,z){N.isBuffer(W)&&(W=W.toString()),c.parseString(W,{explicitRoot:!1,explicitArray:!1},function(B,k){B?z(B):H(k)})})},P.requestError=function(W){var H,z,B,k;return y.default.async(function(Y){for(;;)switch(Y.prev=Y.next){case 0:if(H=null,!(!W.data||!W.data.length)){Y.next=5;break}W.status===-1||W.status===-2?(H=new Error(W.message),H.name=W.name,H.status=W.status,H.code=W.name):(W.status===404?(H=new Error("Object not exists"),H.name="NoSuchKeyError",H.status=404,H.code="NoSuchKey"):W.status===412?(H=new Error("Pre condition failed"),H.name="PreconditionFailedError",H.status=412,H.code="PreconditionFailed"):(H=new Error("Unknow error, status: "+W.status),H.name="UnknowError",H.status=W.status),H.requestId=W.headers["x-oss-request-id"],H.host=""),Y.next=33;break;case 5:return z=String(W.data),this.debug("request response error data: %s",z,"error"),B=void 0,Y.prev=8,Y.next=11,y.default.awrap(this.parseXML(z));case 11:if(Y.t0=Y.sent,Y.t0){Y.next=14;break}Y.t0={};case 14:B=Y.t0,Y.next=24;break;case 17:return Y.prev=17,Y.t1=Y.catch(8),this.debug(z,"error"),Y.t1.message+=`
raw xml: `+z,Y.t1.status=W.status,Y.t1.requestId=W.headers["x-oss-request-id"],Y.abrupt("return",Y.t1);case 24:k=B.Message||"unknow request error, status: "+W.status,B.Condition&&(k+=" (condition: "+B.Condition+")"),H=new Error(k),H.name=B.Code?B.Code+"Error":"UnknowError",H.status=W.status,H.code=B.Code,H.requestId=B.RequestId,H.hostId=B.HostId,H.serverTime=B.ServerTime;case 33:return this.debug("generate error %j",H,"error"),Y.abrupt("return",H);case 35:case"end":return Y.stop()}},null,this,[[8,17]])}}).call(this,{isBuffer:F("../../node_modules/is-buffer/index.js")},F("_process"))},{"../../node_modules/is-buffer/index.js":197,"../common/bucket/deleteBucketLifecycle":6,"../common/bucket/deleteBucketWebsite":7,"../common/bucket/getBucketLifecycle":8,"../common/bucket/getBucketVersioning":9,"../common/bucket/getBucketWebsite":10,"../common/bucket/putBucketLifecycle":11,"../common/bucket/putBucketVersioning":12,"../common/bucket/putBucketWebsite":13,"../common/client/initOptions":15,"../common/multipart":18,"../common/parallel":33,"../common/signUtils":34,"../common/utils/createRequest":38,"../common/utils/isIP":45,"./managed-upload":3,"./object":4,"./version":5,_process:208,agentkeepalive:48,"babel-runtime/core-js/object/assign":54,"babel-runtime/core-js/promise":61,"babel-runtime/regenerator":68,bowser:70,"copy-to":76,debug:288,"is-type-of":289,"merge-descriptors":200,platform:206,url:238,urllib:291,utility:290,xml2js:249}],3:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/core-js/array/from"),C=b(v),M=F("babel-runtime/core-js/promise"),m=b(M),y=F("babel-runtime/regenerator"),w=b(y);function b(x){return x&&x.__esModule?x:{default:x}}var p=F("is-type-of"),d=F("util"),n=F("path"),c=F("mime"),r=F("copy-to"),i=F("../common/utils/isBlob"),o=i.isBlob,u=F("../common/utils/isFile"),f=u.isFile,s=j;s.multipartUpload=function(h,R,O){var g,_,E,T,L,I,P,G,W;return w.default.async(function(z){for(;;)switch(z.prev=z.next){case 0:if(this.resetCancelFlag(),O=O||{},!(O.checkpoint&&O.checkpoint.uploadId)){z.next=6;break}return z.next=5,w.default.awrap(this._resumeMultipart(O.checkpoint,O));case 5:return z.abrupt("return",z.sent);case 6:return g=100*1024,O.mime||(f(R)?O.mime=c.getType(n.extname(R.name)):o(R)?O.mime=R.type:O.mime=c.getType(n.extname(R))),O.headers=O.headers||{},this._convertMetaToHeaders(O.meta,O.headers),z.next=12,w.default.awrap(this._getFileSize(R));case 12:if(_=z.sent,!(_<g)){z.next=25;break}return E=this._createStream(R,0,_),O.contentLength=_,z.next=18,w.default.awrap(this.putStream(h,E,O));case 18:if(T=z.sent,!(O&&O.progress)){z.next=22;break}return z.next=22,w.default.awrap(O.progress(1));case 22:return L={res:T.res,bucket:this.options.bucket,name:h,etag:T.res.headers.etag},(O.headers&&O.headers["x-oss-callback"]||O.callback)&&(L.data=T.data),z.abrupt("return",L);case 25:if(!(O.partSize&&!(parseInt(O.partSize,10)===O.partSize))){z.next=27;break}throw new Error("partSize must be int number");case 27:if(!(O.partSize&&O.partSize<g)){z.next=29;break}throw new Error("partSize must not be smaller than "+g);case 29:return z.next=31,w.default.awrap(this.initMultipartUpload(h,O));case 31:if(I=z.sent,P=I.uploadId,G=this._getPartSize(_,O.partSize),W={file:R,name:h,fileSize:_,partSize:G,uploadId:P,doneParts:[]},!(O&&O.progress)){z.next=38;break}return z.next=38,w.default.awrap(O.progress(0,W,I.res));case 38:return z.next=40,w.default.awrap(this._resumeMultipart(W,O));case 40:return z.abrupt("return",z.sent);case 41:case"end":return z.stop()}},null,this)},s._resumeMultipart=function(h,R){var O,g,_,E,T,L,I,P,G,W,H,z,B,k,K,Y,ne,oe;return w.default.async(function(xe){for(;;)switch(xe.prev=xe.next){case 0:if(O=this,!this.isCancel()){xe.next=3;break}throw this._makeCancelEvent();case 3:return g=h.file,_=h.fileSize,E=h.partSize,T=h.uploadId,L=h.doneParts,I=h.name,P=[],L.length>0&&r(L).to(P),G=this._divideParts(_,E),W=G.length,H=!1,z=function(me,de){var ae=this;return new m.default(function(q,ue){var Z,ee,Ee,te;return w.default.async(function(X){for(;;)switch(X.prev=X.next){case 0:if(X.prev=0,me.isCancel()){X.next=18;break}return Z=G[de-1],ee={stream:me._createStream(g,Z.start,Z.end),size:Z.end-Z.start},X.next=6,w.default.awrap(me._uploadPart(I,T,de,ee));case 6:if(Ee=X.sent,!(!me.isCancel()&&!H)){X.next=15;break}if(h.doneParts.push({number:de,etag:Ee.res.headers.etag}),!R.progress){X.next=12;break}return X.next=12,w.default.awrap(R.progress(L.length/W,h,Ee.res));case 12:q({number:de,etag:Ee.res.headers.etag}),X.next=16;break;case 15:q();case 16:X.next=19;break;case 18:q();case 19:X.next=30;break;case 21:X.prev=21,X.t0=X.catch(0),te=new Error,te.name=X.t0.name,te.message=X.t0.message,te.stack=X.t0.stack,te.partNum=de,r(X.t0).to(te),ue(te);case 30:case"end":return X.stop()}},null,ae,[[0,21]])})},B=(0,C.default)(new Array(W),function(le,me){return me+1}),k=P.map(function(le){return le.number}),K=B.filter(function(le){return k.indexOf(le)<0}),Y=5,ne=R.parallel||Y,xe.next=17,w.default.awrap(this._parallel(K,ne,function(le){return new m.default(function(me,de){z(O,le).then(function(ae){ae&&P.push(ae),me()}).catch(function(ae){de(ae)})})}));case 17:if(oe=xe.sent,H=!0,!this.isCancel()){xe.next=22;break}throw z=null,this._makeCancelEvent();case 22:if(!(oe&&oe.length>0)){xe.next=25;break}throw oe[0].message="Failed to upload some parts with error: "+oe[0].toString()+" part_num: "+oe[0].partNum,oe[0];case 25:return xe.next=27,w.default.awrap(this.completeMultipartUpload(I,T,P,R));case 27:return xe.abrupt("return",xe.sent);case 28:case"end":return xe.stop()}},null,this)},s._getFileSize=function(h){return w.default.async(function(O){for(;;)switch(O.prev=O.next){case 0:if(!p.buffer(h)){O.next=4;break}return O.abrupt("return",h.length);case 4:if(!(o(h)||f(h))){O.next=6;break}return O.abrupt("return",h.size);case 6:throw new Error("_getFileSize requires Buffer/File/Blob.");case 7:case"end":return O.stop()}},null,this)};var l=F("stream"),t=l.Readable;function S(x,h){if(!(this instanceof S))return new S(x,h);t.call(this,h),this.file=x,this.reader=new FileReader,this.start=0,this.finish=!1,this.fileBuffer=null}d.inherits(S,t),S.prototype.readFileAndPush=function(h){if(this.fileBuffer)for(var R=!0;R&&this.fileBuffer&&this.start<this.fileBuffer.length;){var O=this.start,g=O+h;g=g>this.fileBuffer.length?this.fileBuffer.length:g,this.start=g,R=this.push(this.fileBuffer.slice(O,g))}},S.prototype._read=function(h){if(this.file&&this.start>=this.file.size||this.fileBuffer&&this.start>=this.fileBuffer.length||this.finish||this.start===0&&!this.file){this.finish||(this.fileBuffer=null,this.finish=!0),this.push(null);return}var R=16*1024;h=h||R;var O=this;this.reader.onload=function(_){O.fileBuffer=N.from(new Uint8Array(_.target.result)),O.file=null,O.readFileAndPush(h)},this.start===0?this.reader.readAsArrayBuffer(this.file):this.readFileAndPush(h)},s._createStream=function(h,R,O){if(o(h)||f(h))return new S(h.slice(R,O));throw new Error("_createStream requires File/Blob.")},s._getPartSize=function(h,R){var O=10*1e3,g=1024*1024;return R?Math.max(Math.ceil(h/O),R):g},s._divideParts=function(h,R){for(var O=Math.ceil(h/R),g=[],_=0;_<O;_++){var E=R*_,T=Math.min(E+R,h);g.push({start:E,end:T})}return g}}).call(this,F("buffer").Buffer)},{"../common/utils/isBlob":43,"../common/utils/isFile":44,"babel-runtime/core-js/array/from":52,"babel-runtime/core-js/promise":61,"babel-runtime/regenerator":68,buffer:73,"copy-to":76,"is-type-of":289,mime:202,path:205,stream:230,util:243}],4:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/promise"),v=p(N),C=F("babel-runtime/core-js/object/keys"),M=p(C),m=F("babel-runtime/core-js/object/assign"),y=p(m),w=F("babel-runtime/regenerator"),b=p(w);function p(O){return O&&O.__esModule?O:{default:O}}var d=F("utility"),n=F("fs"),c=F("is-type-of"),r=F("url"),i=F("copy-to"),o=F("path"),u=F("mime"),f=F("../common/callback"),s=F("../common/signUtils"),l=F("merge-descriptors"),t=F("../common/utils/isBlob"),S=t.isBlob,x=F("../common/utils/isFile"),h=x.isFile,R=j;R.append=function(g,_,E){var T;return b.default.async(function(I){for(;;)switch(I.prev=I.next){case 0:return E=E||{},E.position===void 0&&(E.position="0"),E.subres={append:"",position:E.position},E.method="POST",I.next=6,b.default.awrap(this.put(g,_,E));case 6:return T=I.sent,T.nextAppendPosition=T.res.headers["x-oss-next-append-position"],I.abrupt("return",T);case 9:case"end":return I.stop()}},null,this)},R.put=function(g,_,E){var T,L,I,P,G,W,H;return b.default.async(function(B){for(;;)switch(B.prev=B.next){case 0:if(T=void 0,E=E||{},g=this._objectName(g),!c.buffer(_)){B.next=7;break}T=_,B.next=33;break;case 7:if(!(S(_)||h(_))){B.next=32;break}return E.mime||(h(_)?E.mime=u.getType(o.extname(_.name)):E.mime=_.type),L=this._createStream(_,0,_.size),B.next=12,b.default.awrap(this._getFileSize(_));case 12:return E.contentLength=B.sent,B.prev=13,B.next=16,b.default.awrap(this.putStream(g,L,E));case 16:return I=B.sent,B.abrupt("return",I);case 20:if(B.prev=20,B.t0=B.catch(13),!(B.t0.code==="RequestTimeTooSkewed")){B.next=29;break}return this.options.amendTimeSkewed=+new Date(B.t0.serverTime)-new Date,B.next=26,b.default.awrap(this.put(g,_,E));case 26:return B.abrupt("return",B.sent);case 29:throw B.t0;case 30:B.next=33;break;case 32:throw new TypeError("Must provide Buffer/Blob/File for put.");case 33:return E.headers=E.headers||{},this._convertMetaToHeaders(E.meta,E.headers),P=E.method||"PUT",G=this._objectRequestParams(P,g,E),f.encodeCallback(G,E),G.mime=E.mime,G.content=T,G.successStatuses=[200],B.next=43,b.default.awrap(this.request(G));case 43:return W=B.sent,H={name:g,url:this._objectUrl(g),res:W.res},G.headers&&G.headers["x-oss-callback"]&&(H.data=JSON.parse(W.data.toString())),B.abrupt("return",H);case 47:case"end":return B.stop()}},null,this,[[13,20]])},R.putStream=function(g,_,E){var T,L,I,P;return b.default.async(function(W){for(;;)switch(W.prev=W.next){case 0:return E=E||{},E.headers=E.headers||{},g=this._objectName(g),E.contentLength?E.headers["Content-Length"]=E.contentLength:E.headers["Transfer-Encoding"]="chunked",this._convertMetaToHeaders(E.meta,E.headers),T=E.method||"PUT",L=this._objectRequestParams(T,g,E),f.encodeCallback(L,E),L.mime=E.mime,L.stream=_,L.successStatuses=[200],W.next=13,b.default.awrap(this.request(L));case 13:return I=W.sent,P={name:g,url:this._objectUrl(g),res:I.res},L.headers&&L.headers["x-oss-callback"]&&(P.data=JSON.parse(I.data.toString())),W.abrupt("return",P);case 17:case"end":return W.stop()}},null,this)},l(R,F("../common/object/copyObject")),l(R,F("../common/object/getObjectTagging")),l(R,F("../common/object/putObjectTagging")),l(R,F("../common/object/deleteObjectTagging")),l(R,F("../common/image")),l(R,F("../common/object/getBucketVersions")),l(R,F("../common/object/getACL")),l(R,F("../common/object/putACL")),l(R,F("../common/object/head")),l(R,F("../common/object/delete")),l(R,F("../common/object/get")),l(R,F("../common/object/putSymlink")),l(R,F("../common/object/getSymlink")),l(R,F("../common/object/deleteMulti")),l(R,F("../common/object/getObjectMeta")),R.putMeta=function(g,_,E){var T;return b.default.async(function(I){for(;;)switch(I.prev=I.next){case 0:return I.next=2,b.default.awrap(this.copy(g,g,{meta:_||{},timeout:E&&E.timeout,ctx:E&&E.ctx}));case 2:return T=I.sent,I.abrupt("return",T);case 4:case"end":return I.stop()}},null,this)},R.list=function(g,_){var E,T,L,I,P;return b.default.async(function(W){for(;;)switch(W.prev=W.next){case 0:return E=this._objectRequestParams("GET","",_),E.query=g,E.xmlResponse=!0,E.successStatuses=[200],W.next=6,b.default.awrap(this.request(E));case 6:return T=W.sent,L=T.data.Contents,I=this,L&&(Array.isArray(L)||(L=[L]),L=L.map(function(H){return{name:H.Key,url:I._objectUrl(H.Key),lastModified:H.LastModified,etag:H.ETag,type:H.Type,size:Number(H.Size),storageClass:H.StorageClass,owner:{id:H.Owner.ID,displayName:H.Owner.DisplayName}}})),P=T.data.CommonPrefixes||null,P&&(Array.isArray(P)||(P=[P]),P=P.map(function(H){return H.Prefix})),W.abrupt("return",{res:T.res,objects:L,prefixes:P,nextMarker:T.data.NextMarker||null,isTruncated:T.data.IsTruncated==="true"});case 13:case"end":return W.stop()}},null,this)},R.restore=function(g,_){var E,T;return b.default.async(function(I){for(;;)switch(I.prev=I.next){case 0:return _=_||{},_.subres=(0,y.default)({restore:""},_.subres),_.versionId&&(_.subres.versionId=_.versionId),E=this._objectRequestParams("POST",g,_),E.successStatuses=[202],I.next=7,b.default.awrap(this.request(E));case 7:return T=I.sent,I.abrupt("return",{res:T.res});case 9:case"end":return I.stop()}},null,this)},R.signatureUrl=function(g,_){_=_||{},g=this._objectName(g),_.method=_.method||"GET";var E=d.timestamp()+(_.expires||1800),T={bucket:this.options.bucket,object:g},L=this._getResource(T);this.options.stsToken&&(_["security-token"]=this.options.stsToken);var I=s._signatureForURL(this.options.accessKeySecret,_,L,E),P=r.parse(this._getReqUrl(T));return P.query={OSSAccessKeyId:this.options.accessKeyId,Expires:E,Signature:I.Signature},i(I.subResource).to(P.query),P.format()},R.getObjectUrl=function(g,_){return _?_[_.length-1]!=="/"&&(_+="/"):_=this.options.endpoint.format(),_+this._escape(this._objectName(g))},R._objectUrl=function(g){return this._getReqUrl({bucket:this.options.bucket,object:g})},R.generateObjectUrl=function(O,g){if(g)g[g.length-1]!=="/"&&(g+="/");else{g=this.options.endpoint.format();var _=r.parse(g),E=this.options.bucket;_.hostname=E+"."+_.hostname,_.host=E+"."+_.host,g=_.format()}return g+this._escape(this._objectName(O))},R._objectRequestParams=function(g,_,E){if(!this.options.bucket)throw new Error("Please create a bucket first");E=E||{},_=this._objectName(_);var T={object:_,bucket:this.options.bucket,method:g,subres:E&&E.subres,timeout:E&&E.timeout,ctx:E&&E.ctx};return E.headers&&(T.headers={},i(E.headers).to(T.headers)),T},R._objectName=function(g){return g.replace(/^\/+/,"")},R._convertMetaToHeaders=function(g,_){if(!g)return;(0,M.default)(g).forEach(function(E){_["x-oss-meta-"+E]=g[E]})},R._deleteFileSafe=function(g){var _=this;return new v.default(function(E){n.exists(g,function(T){T?n.unlink(g,function(L){L&&_.debug("unlink %j error: %s",g,L,"error"),E()}):E()})})}},{"../common/callback":14,"../common/image":16,"../common/object/copyObject":19,"../common/object/delete":20,"../common/object/deleteMulti":21,"../common/object/deleteObjectTagging":22,"../common/object/get":23,"../common/object/getACL":24,"../common/object/getBucketVersions":25,"../common/object/getObjectMeta":26,"../common/object/getObjectTagging":27,"../common/object/getSymlink":28,"../common/object/head":29,"../common/object/putACL":30,"../common/object/putObjectTagging":31,"../common/object/putSymlink":32,"../common/signUtils":34,"../common/utils/isBlob":43,"../common/utils/isFile":44,"babel-runtime/core-js/object/assign":54,"babel-runtime/core-js/object/keys":60,"babel-runtime/core-js/promise":61,"babel-runtime/regenerator":68,"copy-to":76,fs:71,"is-type-of":289,"merge-descriptors":200,mime:202,path:205,url:238,utility:290}],5:[function(F,Q,j){"use strict";j.version="6.10.0"},{}],6:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(w){return w&&w.__esModule?w:{default:w}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=j;y.deleteBucketLifecycle=function(b,p){var d,n;return v.default.async(function(r){for(;;)switch(r.prev=r.next){case 0:return m(b),d=this._bucketRequestParams("DELETE",b,"lifecycle",p),d.successStatuses=[204],r.next=5,v.default.awrap(this.request(d));case 5:return n=r.sent,r.abrupt("return",{res:n.res});case 7:case"end":return r.stop()}},null,this)}},{"../utils/checkBucketName":35,"babel-runtime/regenerator":68}],7:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(w){return w&&w.__esModule?w:{default:w}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=j;y.deleteBucketWebsite=function(b,p){var d,n;return v.default.async(function(r){for(;;)switch(r.prev=r.next){case 0:return m(b),d=this._bucketRequestParams("DELETE",b,"website",p),d.successStatuses=[204],r.next=5,v.default.awrap(this.request(d));case 5:return n=r.sent,r.abrupt("return",{res:n.res});case 7:case"end":return r.stop()}},null,this)}},{"../utils/checkBucketName":35,"babel-runtime/regenerator":68}],8:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(n){return n&&n.__esModule?n:{default:n}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=F("../utils/isArray"),w=y.isArray,b=F("../utils/formatObjKey"),p=b.formatObjKey,d=j;d.getBucketLifecycle=function(c,r){var i,o,u;return v.default.async(function(s){for(;;)switch(s.prev=s.next){case 0:return m(c),i=this._bucketRequestParams("GET",c,"lifecycle",r),i.successStatuses=[200],i.xmlResponse=!0,s.next=6,v.default.awrap(this.request(i));case 6:return o=s.sent,u=o.data.Rule||null,u&&(w(u)||(u=[u]),u=u.map(function(l){return l.ID&&(l.id=l.ID,delete l.ID),l.Tag&&!w(l.Tag)&&(l.Tag=[l.Tag]),p(l,"firstLowerCase")})),s.abrupt("return",{rules:u,res:o.res});case 10:case"end":return s.stop()}},null,this)}},{"../utils/checkBucketName":35,"../utils/formatObjKey":40,"../utils/isArray":42,"babel-runtime/regenerator":68}],9:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(w){return w&&w.__esModule?w:{default:w}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=j;y.getBucketVersioning=function(b,p){var d,n,c;return v.default.async(function(i){for(;;)switch(i.prev=i.next){case 0:return m(b),d=this._bucketRequestParams("GET",b,"versioning",p),d.xmlResponse=!0,d.successStatuses=[200],i.next=6,v.default.awrap(this.request(d));case 6:return n=i.sent,c=n.data.Status,i.abrupt("return",{status:n.status,versionStatus:c,res:n.res});case 9:case"end":return i.stop()}},null,this)}},{"../utils/checkBucketName":35,"babel-runtime/regenerator":68}],10:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(p){return p&&p.__esModule?p:{default:p}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=F("../utils/isObject"),w=y.isObject,b=j;b.getBucketWebsite=function(d,n){var c,r,i;return v.default.async(function(u){for(;;)switch(u.prev=u.next){case 0:return m(d),c=this._bucketRequestParams("GET",d,"website",n),c.successStatuses=[200],c.xmlResponse=!0,u.next=6,v.default.awrap(this.request(c));case 6:return r=u.sent,i=[],r.data.RoutingRules&&r.data.RoutingRules.RoutingRule&&(w(r.data.RoutingRules.RoutingRule)?i=[r.data.RoutingRules.RoutingRule]:i=r.data.RoutingRules.RoutingRule),u.abrupt("return",{index:r.data.IndexDocument&&r.data.IndexDocument.Suffix||"",supportSubDir:r.data.IndexDocument&&r.data.IndexDocument.SupportSubDir||"false",type:r.data.IndexDocument&&r.data.IndexDocument.Type,routingRules:i,error:r.data.ErrorDocument&&r.data.ErrorDocument.Key||null,res:r.res});case 10:case"end":return u.stop()}},null,this)}},{"../utils/checkBucketName":35,"../utils/isObject":46,"babel-runtime/regenerator":68}],11:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(h){return h&&h.__esModule?h:{default:h}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=F("../utils/isArray"),w=y.isArray,b=F("../utils/deepCopy"),p=b.deepCopy,d=F("../utils/isObject"),n=d.isObject,c=F("../utils/obj2xml"),r=c.obj2xml,i=F("../utils/checkObjectTag"),o=i.checkObjectTag,u=F("../utils/getStrBytesCount"),f=u.getStrBytesCount,s=j;s.putBucketLifecycle=function(R,O,g){var _,E,T,L,I;return v.default.async(function(G){for(;;)switch(G.prev=G.next){case 0:if(m(R),w(O)){G.next=3;break}throw new Error("rules must be Array");case 3:return _=this._bucketRequestParams("PUT",R,"lifecycle",g),E=[],T={LifecycleConfiguration:{Rule:E}},O.forEach(function(W){l(W),x(W),W.id&&(W.ID=W.id,delete W.id),E.push(W)}),L=r(T,{headers:!0,firstUpperCase:!0}),_.content=L,_.mime="xml",_.successStatuses=[200],G.next=13,v.default.awrap(this.request(_));case 13:return I=G.sent,G.abrupt("return",{res:I.res});case 15:case"end":return G.stop()}},null,this)};function l(h){h.days&&(h.expiration={days:h.days}),h.date&&(h.expiration={createdBeforeDate:h.date})}function t(h,R){var O=h.days,g=h.createdBeforeDate;if(!O&&!g)throw new Error(R+" must includes days or createdBeforeDate");if(O&&!/^[1-9][0-9]*$/.test(O))throw new Error("days must be a positive integer");if(g&&!/\d{4}-\d{2}-\d{2}T00:00:00.000Z/.test(g))throw new Error("createdBeforeDate must be date and conform to iso8601 format")}function S(h){if(!w(h)&&!n(h))throw new Error("tag must be Object or Array");h=n(h)?[h]:h;var R={},O=p(h);O.forEach(function(g){R[g.key]=g.value}),o(R)}function x(h){if(h.id&&f(h.id)>255)throw new Error("ID is composed of 255 bytes at most");if(h.prefix===""||h.prefix===void 0)throw new Error("Rule must includes prefix");if(!["Enabled","Disabled"].includes(h.status))throw new Error("Status must be Enabled or Disabled");if(h.transition){if(!["IA","Archive"].includes(h.transition.storageClass))throw new Error("StorageClass must be IA or Archive");t(h.transition,"Transition")}if(h.expiration){if(!h.expiration.expiredObjectDeleteMarker)t(h.expiration,"Expiration");else if(h.expiration.days||h.expiration.createdBeforeDate)throw new Error("expiredObjectDeleteMarker cannot be used with days or createdBeforeDate")}if(h.abortMultipartUpload&&t(h.abortMultipartUpload,"AbortMultipartUpload"),!h.expiration&&!h.abortMultipartUpload&&!h.transition&&!h.noncurrentVersionTransition)throw new Error("Rule must includes expiration or abortMultipartUpload or transition or noncurrentVersionTransition");if(h.tag){if(h.abortMultipartUpload)throw new Error("Tag cannot be used with abortMultipartUpload");S(h.tag)}}},{"../utils/checkBucketName":35,"../utils/checkObjectTag":36,"../utils/deepCopy":39,"../utils/getStrBytesCount":41,"../utils/isArray":42,"../utils/isObject":46,"../utils/obj2xml":47,"babel-runtime/regenerator":68}],12:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(p){return p&&p.__esModule?p:{default:p}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=F("../utils/obj2xml"),w=y.obj2xml,b=j;b.putBucketVersioning=function(d,n){var c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r,i,o;return v.default.async(function(f){for(;;)switch(f.prev=f.next){case 0:if(m(d),["Enabled","Suspended"].includes(n)){f.next=3;break}throw new Error("status must be Enabled or Suspended");case 3:return r=this._bucketRequestParams("PUT",d,"versioning",c),i={VersioningConfiguration:{Status:n}},r.mime="xml",r.content=w(i,{headers:!0}),f.next=9,v.default.awrap(this.request(r));case 9:return o=f.sent,f.abrupt("return",{res:o.res,status:o.status});case 11:case"end":return f.stop()}},null,this)}},{"../utils/checkBucketName":35,"../utils/obj2xml":47,"babel-runtime/regenerator":68}],13:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(n){return n&&n.__esModule?n:{default:n}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=F("../utils/obj2xml"),w=y.obj2xml,b=F("../utils/isArray"),p=b.isArray,d=j;d.putBucketWebsite=function(c){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments[2],o,u,f,s,l;return v.default.async(function(S){for(;;)switch(S.prev=S.next){case 0:if(m(c),o=this._bucketRequestParams("PUT",c,"website",i),u={Suffix:r.index||"index.html"},f={IndexDocument:u},s={WebsiteConfiguration:f},r.supportSubDir&&(u.SupportSubDir=r.supportSubDir),r.type&&(u.Type=r.type),r.error&&(f.ErrorDocument={Key:r.error}),!(r.routingRules!==void 0)){S.next=12;break}if(p(r.routingRules)){S.next=11;break}throw new Error("RoutingRules must be Array");case 11:f.RoutingRules={RoutingRule:r.routingRules};case 12:return s=w(s),o.content=s,o.mime="xml",o.successStatuses=[200],S.next=18,v.default.awrap(this.request(o));case 18:return l=S.sent,S.abrupt("return",{res:l.res});case 20:case"end":return S.stop()}},null,this)}},{"../utils/checkBucketName":35,"../utils/isArray":42,"../utils/obj2xml":47,"babel-runtime/regenerator":68}],14:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/core-js/object/keys"),C=y(v),M=F("babel-runtime/core-js/json/stringify"),m=y(M);function y(w){return w&&w.__esModule?w:{default:w}}j.encodeCallback=function(b,p){if(b.headers=b.headers||{},!Object.prototype.hasOwnProperty.call(b.headers,"x-oss-callback")&&p.callback){var d={callbackUrl:encodeURI(p.callback.url),callbackBody:p.callback.body};p.callback.host&&(d.callbackHost=p.callback.host),p.callback.contentType&&(d.callbackBodyType=p.callback.contentType);var n=N.from((0,m.default)(d)).toString("base64");if(b.headers["x-oss-callback"]=n,p.callback.customValue){var c={};(0,C.default)(p.callback.customValue).forEach(function(r){c["x:"+r]=p.callback.customValue[r]}),b.headers["x-oss-callback-var"]=N.from((0,m.default)(c)).toString("base64")}}}}).call(this,F("buffer").Buffer)},{"babel-runtime/core-js/json/stringify":53,"babel-runtime/core-js/object/keys":60,buffer:73}],15:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/assign"),v=C(N);function C(d){return d&&d.__esModule?d:{default:d}}var M=F("humanize-ms"),m=F("url"),y=F("../utils/checkBucketName"),w=y.checkBucketName;function b(d,n){var c=m.parse(d);if(c.protocol||(c=m.parse("http"+(n?"s":"")+"://"+d)),c.protocol!=="http:"&&c.protocol!=="https:")throw new Error("Endpoint protocol must be http or https.");return c}function p(d,n,c){var r=c?"https://":"http://",i=n?"-internal.aliyuncs.com":".aliyuncs.com",o="vpc100-oss-cn-";return d.substr(0,o.length)===o&&(i=".aliyuncs.com"),m.parse(r+d+i)}Q.exports=function(d){if(!d||!d.accessKeyId||!d.accessKeySecret)throw new Error("require accessKeyId, accessKeySecret");d.bucket&&w(d.bucket);var n=(0,v.default)({region:"oss-cn-hangzhou",internal:!1,secure:!1,timeout:6e4,bucket:null,endpoint:null,cname:!1,isRequestPay:!1,sldEnable:!1},d);if(n.accessKeyId=n.accessKeyId.trim(),n.accessKeySecret=n.accessKeySecret.trim(),n.timeout&&(n.timeout=M(n.timeout)),n.endpoint)n.endpoint=b(n.endpoint,n.secure);else if(n.region)n.endpoint=p(n.region,n.internal,n.secure);else throw new Error("require options.endpoint or options.region");return n.inited=!0,n}},{"../utils/checkBucketName":35,"babel-runtime/core-js/object/assign":54,"humanize-ms":194,url:238}],16:[function(F,Q,j){"use strict";var N=F("merge-descriptors"),v=j;N(v,F("./processObjectSave"))},{"./processObjectSave":17,"merge-descriptors":200}],17:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(n){return n&&n.__esModule?n:{default:n}}var M=F("../utils/checkBucketName"),m=M.checkBucketName,y=F("querystring"),w=F("js-base64"),b=w.Base64.encode,p=j;p.processObjectSave=function(c,r,i,o){var u,f,s,l;return v.default.async(function(S){for(;;)switch(S.prev=S.next){case 0:return d(c,"sourceObject"),d(r,"targetObject"),d(i,"process"),r=this._objectName(r),o&&m(o),u=this._objectRequestParams("POST",c,{subres:"x-oss-process"}),f=o?",b_"+b(o):"",r=b(r),s={"x-oss-process":i+"|sys/saveas,o_"+r+f},u.content=y.stringify(s),S.next=12,v.default.awrap(this.request(u));case 12:return l=S.sent,S.abrupt("return",{res:l.res,status:l.res.status});case 14:case"end":return S.stop()}},null,this)};function d(n,c){if(!n)throw new Error(c+" is required");if(typeof n!="string")throw new Error(c+" must be String")}},{"../utils/checkBucketName":35,"babel-runtime/regenerator":68,"js-base64":199,querystring:212}],18:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=C(N);function C(p){return p&&p.__esModule?p:{default:p}}var M=F("copy-to"),m=F("./callback"),y=F("./utils/deepCopy"),w=y.deepCopy,b=j;b.listUploads=function(d,n){var c,r,i,o;return v.default.async(function(f){for(;;)switch(f.prev=f.next){case 0:return n=n||{},c={},M(n).to(c),c.subres="uploads",r=this._objectRequestParams("GET","",c),r.query=d,r.xmlResponse=!0,r.successStatuses=[200],f.next=10,v.default.awrap(this.request(r));case 10:return i=f.sent,o=i.data.Upload||[],Array.isArray(o)||(o=[o]),o=o.map(function(s){return{name:s.Key,uploadId:s.UploadId,initiated:s.Initiated}}),f.abrupt("return",{res:i.res,uploads:o,bucket:i.data.Bucket,nextKeyMarker:i.data.NextKeyMarker,nextUploadIdMarker:i.data.NextUploadIdMarker,isTruncated:i.data.IsTruncated==="true"});case 15:case"end":return f.stop()}},null,this)},b.listParts=function(d,n,c,r){var i,o,u;return v.default.async(function(s){for(;;)switch(s.prev=s.next){case 0:return r=r||{},i={},M(r).to(i),i.subres={uploadId:n},o=this._objectRequestParams("GET",d,i),o.query=c,o.xmlResponse=!0,o.successStatuses=[200],s.next=10,v.default.awrap(this.request(o));case 10:return u=s.sent,s.abrupt("return",{res:u.res,uploadId:u.data.UploadId,bucket:u.data.Bucket,name:u.data.Key,partNumberMarker:u.data.PartNumberMarker,nextPartNumberMarker:u.data.NextPartNumberMarker,maxParts:u.data.MaxParts,isTruncated:u.data.IsTruncated,parts:u.data.Part||[]});case 12:case"end":return s.stop()}},null,this)},b.abortMultipartUpload=function(d,n,c){var r,i,o;return v.default.async(function(f){for(;;)switch(f.prev=f.next){case 0:return this._stop(),c=c||{},r={},M(c).to(r),r.subres={uploadId:n},i=this._objectRequestParams("DELETE",d,r),i.successStatuses=[204],f.next=9,v.default.awrap(this.request(i));case 9:return o=f.sent,f.abrupt("return",{res:o.res});case 11:case"end":return f.stop()}},null,this)},b.initMultipartUpload=function(d,n){var c,r,i;return v.default.async(function(u){for(;;)switch(u.prev=u.next){case 0:return n=n||{},c={},M(n).to(c),c.headers=c.headers||{},this._convertMetaToHeaders(n.meta,c.headers),c.subres="uploads",r=this._objectRequestParams("POST",d,c),r.mime=n.mime,r.xmlResponse=!0,r.successStatuses=[200],u.next=12,v.default.awrap(this.request(r));case 12:return i=u.sent,u.abrupt("return",{res:i.res,bucket:i.data.Bucket,name:i.data.Key,uploadId:i.data.UploadId});case 14:case"end":return u.stop()}},null,this)},b.uploadPart=function(d,n,c,r,i,o,u){var f;return v.default.async(function(l){for(;;)switch(l.prev=l.next){case 0:return f={stream:this._createStream(r,i,o),size:o-i},l.next=3,v.default.awrap(this._uploadPart(d,n,c,f,u));case 3:return l.abrupt("return",l.sent);case 4:case"end":return l.stop()}},null,this)},b.completeMultipartUpload=function(d,n,c,r){var i,o,u,f,s,l,t,S;return v.default.async(function(h){for(;;)switch(h.prev=h.next){case 0:for(i=c.concat().sort(function(R,O){return R.number-O.number}).filter(function(R,O,g){return!O||R.number!==g[O-1].number}),o=`<?xml version="1.0" encoding="UTF-8"?>
<CompleteMultipartUpload>
`,u=0;u<i.length;u++)f=i[u],o+=`<Part>
`,o+="<PartNumber>"+f.number+`</PartNumber>
`,o+="<ETag>"+f.etag+`</ETag>
`,o+=`</Part>
`;return o+="</CompleteMultipartUpload>",r=r||{},s={},s=w(r),s.headers&&delete s.headers["x-oss-server-side-encryption"],s.subres={uploadId:n},l=this._objectRequestParams("POST",d,s),m.encodeCallback(l,s),l.mime="xml",l.content=o,l.headers&&l.headers["x-oss-callback"]||(l.xmlResponse=!0),l.successStatuses=[200],h.next=17,v.default.awrap(this.request(l));case 17:return t=h.sent,S={res:t.res,bucket:l.bucket,name:d,etag:t.res.headers.etag},l.headers&&l.headers["x-oss-callback"]&&(S.data=JSON.parse(t.data.toString())),h.abrupt("return",S);case 21:case"end":return h.stop()}},null,this)},b._uploadPart=function(d,n,c,r,i){var o,u,f;return v.default.async(function(l){for(;;)switch(l.prev=l.next){case 0:return i=i||{},o={},M(i).to(o),o.headers={"Content-Length":r.size},o.subres={partNumber:c,uploadId:n},u=this._objectRequestParams("PUT",d,o),u.mime=o.mime,u.stream=r.stream,u.successStatuses=[200],l.next=11,v.default.awrap(this.request(u));case 11:if(f=l.sent,f.res.headers.etag){l.next=14;break}throw new Error(`Please set the etag of expose-headers in OSS
https://help.aliyun.com/document_detail/32069.html`);case 14:return r.stream=null,u.stream=null,l.abrupt("return",{name:d,etag:f.res.headers.etag,res:f.res});case 17:case"end":return l.stop()}},null,this)}},{"./callback":14,"./utils/deepCopy":39,"babel-runtime/regenerator":68,"copy-to":76}],19:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=w(N),C=F("babel-runtime/core-js/object/keys"),M=w(C),m=F("babel-runtime/helpers/typeof"),y=w(m);function w(n){return n&&n.__esModule?n:{default:n}}var b=F("../utils/checkBucketName"),p=b.checkBucketName,d=j;d.copy=function(c,r,i,o){var u,f,s;return v.default.async(function(t){for(;;)switch(t.prev=t.next){case 0:return(typeof i=="undefined"?"undefined":(0,y.default)(i))==="object"&&(o=i),o=o||{},o.headers=o.headers||{},(0,M.default)(o.headers).forEach(function(S){o.headers["x-oss-copy-source-"+S.toLowerCase()]=o.headers[S]}),o.meta&&(o.headers["x-oss-metadata-directive"]="REPLACE"),this._convertMetaToHeaders(o.meta,o.headers),r=this._getSourceName(r,i),o.versionId&&(r=r+"?versionId="+o.versionId),o.headers["x-oss-copy-source"]=r,u=this._objectRequestParams("PUT",c,o),u.xmlResponse=!0,u.successStatuses=[200,304],t.next=14,v.default.awrap(this.request(u));case 14:return f=t.sent,s=f.data,s&&(s={etag:s.ETag,lastModified:s.LastModified}),t.abrupt("return",{data:s,res:f.res});case 18:case"end":return t.stop()}},null,this)},d._getSourceName=function(c,r){return typeof r=="string"?c=this._objectName(c):c[0]!=="/"?r=this.options.bucket:(r=c.replace(/\/(.+?)(\/.*)/,"$1"),c=c.replace(/(\/.+?\/)(.*)/,"$2")),p(r),c=encodeURI(c),c="/"+r+"/"+c,c}},{"../utils/checkBucketName":35,"babel-runtime/core-js/object/keys":60,"babel-runtime/helpers/typeof":67,"babel-runtime/regenerator":68}],20:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.delete=function(b){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},d,n;return v.default.async(function(r){for(;;)switch(r.prev=r.next){case 0:return p.subres=(0,M.default)({},p.subres),p.versionId&&(p.subres.versionId=p.versionId),d=this._objectRequestParams("DELETE",b,p),d.successStatuses=[204],r.next=6,v.default.awrap(this.request(d));case 6:return n=r.sent,r.abrupt("return",{res:n.res});case 8:case"end":return r.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],21:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(d){return d&&d.__esModule?d:{default:d}}var y=F("utility"),w=F("../utils/obj2xml"),b=w.obj2xml,p=j;p.deleteMulti=function(n){var c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r,i,o,u,f,s,l,t,S,x,h,R;return v.default.async(function(g){for(;;)switch(g.prev=g.next){case 0:if(r=[],!(!n||!n.length)){g.next=3;break}throw new Error("names is required");case 3:for(i=0;i<n.length;i++)o={},typeof n[i]=="string"?o.Key=y.escape(this._objectName(n[i])):(u=n[i],f=u.key,s=u.versionId,o.Key=y.escape(this._objectName(f)),o.VersionId=s),r.push(o);return l={Delete:{Quiet:!!c.quiet,Object:r}},t=b(l,{headers:!0}),c.subres=(0,M.default)({delete:""},c.subres),c.versionId&&(c.subres.versionId=c.versionId),S=this._objectRequestParams("POST","",c),S.mime="xml",S.content=t,S.xmlResponse=!0,S.successStatuses=[200],g.next=15,v.default.awrap(this.request(S));case 15:return x=g.sent,h=x.data,R=h&&h.Deleted||null,R&&(Array.isArray(R)||(R=[R])),g.abrupt("return",{res:x.res,deleted:R||[]});case 20:case"end":return g.stop()}},null,this)}},{"../utils/obj2xml":47,"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68,utility:290}],22:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.deleteObjectTagging=function(b){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},d,n;return v.default.async(function(r){for(;;)switch(r.prev=r.next){case 0:return p.subres=(0,M.default)({tagging:""},p.subres),p.versionId&&(p.subres.versionId=p.versionId),b=this._objectName(b),d=this._objectRequestParams("DELETE",b,p),d.successStatuses=[204],r.next=7,v.default.awrap(this.request(d));case 7:return n=r.sent,r.abrupt("return",{status:n.status,res:n.res});case 9:case"end":return r.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],23:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(p){return p&&p.__esModule?p:{default:p}}var y=F("fs"),w=F("is-type-of"),b=j;b.get=function(d,n){var c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r,i,o,u;return v.default.async(function(s){for(;;)switch(s.prev=s.next){case 0:return r=null,i=!1,w.writableStream(n)?r=n:w.string(n)?(r=y.createWriteStream(n),i=!0):c=n,c=c||{},c.subres=(0,M.default)({},c.subres),c.versionId&&(c.subres.versionId=c.versionId),c.process&&(c.subres["x-oss-process"]=c.process),o=void 0,s.prev=8,u=this._objectRequestParams("GET",d,c),u.writeStream=r,u.successStatuses=[200,206,304],s.next=14,v.default.awrap(this.request(u));case 14:o=s.sent,i&&r.destroy(),s.next=25;break;case 18:if(s.prev=18,s.t0=s.catch(8),!i){s.next=24;break}return r.destroy(),s.next=24,v.default.awrap(this._deleteFileSafe(n));case 24:throw s.t0;case 25:return s.abrupt("return",{res:o.res,content:o.data});case 26:case"end":return s.stop()}},null,this,[[8,18]])}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68,fs:71,"is-type-of":289}],24:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.getACL=function(b){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},d,n;return v.default.async(function(r){for(;;)switch(r.prev=r.next){case 0:return p.subres=(0,M.default)({acl:""},p.subres),p.versionId&&(p.subres.versionId=p.versionId),b=this._objectName(b),d=this._objectRequestParams("GET",b,p),d.successStatuses=[200],d.xmlResponse=!0,r.next=8,v.default.awrap(this.request(d));case 8:return n=r.sent,r.abrupt("return",{acl:n.data.AccessControlList.Grant,owner:{id:n.data.Owner.ID,displayName:n.data.Owner.DisplayName},res:n.res});case 10:case"end":return r.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],25:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/keys"),v=w(N),C=F("babel-runtime/regenerator"),M=w(C),m=F("babel-runtime/core-js/object/assign"),y=w(m);function w(u){return u&&u.__esModule?u:{default:u}}var b=j,p=F("../utils/isObject"),d=p.isObject,n=F("../utils/isArray"),c=n.isArray;b.getBucketVersions=r,b.listObjectVersions=r;function r(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s,l,t,S,x,h;return M.default.async(function(O){for(;;)switch(O.prev=O.next){case 0:if(!(u.versionIdMarker&&u.keyMarker===void 0)){O.next=2;break}throw new Error("A version-id marker cannot be specified without a key marker");case 2:return f.subres=(0,y.default)({versions:""},f.subres),f.versionId&&(f.subres.versionId=f.versionId),s=this._objectRequestParams("GET","",f),s.xmlResponse=!0,s.successStatuses=[200],s.query=o(u),O.next=10,M.default.awrap(this.request(s));case 10:return l=O.sent,t=l.data.Version||[],S=l.data.DeleteMarker||[],x=this,t&&(Array.isArray(t)||(t=[t]),t=t.map(function(g){return{name:g.Key,url:x._objectUrl(g.Key),lastModified:g.LastModified,isLatest:g.IsLatest==="true",versionId:g.VersionId,etag:g.ETag,type:g.Type,size:Number(g.Size),storageClass:g.StorageClass,owner:{id:g.Owner.ID,displayName:g.Owner.DisplayName}}})),S&&(c(S)||(S=[S]),S=S.map(function(g){return{name:g.Key,lastModified:g.LastModified,versionId:g.VersionId,owner:{id:g.Owner.ID,displayName:g.Owner.DisplayName}}})),h=l.data.CommonPrefixes||null,h&&(c(h)||(h=[h]),h=h.map(function(g){return g.Prefix})),O.abrupt("return",{res:l.res,objects:t,deleteMarker:S,prefixes:h,nextMarker:l.data.NextMarker||null,NextVersionIdMarker:l.data.NextVersionIdMarker||null,isTruncated:l.data.IsTruncated==="true"});case 19:case"end":return O.stop()}},null,this)}function i(u){return u.replace(/([A-Z])/g,"-$1").toLowerCase()}function o(){var u=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},f={};return d(u)&&(0,v.default)(u).forEach(function(s){f[i(s)]=u[s]}),f}},{"../utils/isArray":42,"../utils/isObject":46,"babel-runtime/core-js/object/assign":54,"babel-runtime/core-js/object/keys":60,"babel-runtime/regenerator":68}],26:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.getObjectMeta=function(b,p){var d,n;return v.default.async(function(r){for(;;)switch(r.prev=r.next){case 0:return p=p||{},b=this._objectName(b),p.subres=(0,M.default)({objectMeta:""},p.subres),p.versionId&&(p.subres.versionId=p.versionId),d=this._objectRequestParams("HEAD",b,p),d.successStatuses=[200],r.next=8,v.default.awrap(this.request(d));case 8:return n=r.sent,r.abrupt("return",{status:n.status,res:n.res});case 10:case"end":return r.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],27:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(p){return p&&p.__esModule?p:{default:p}}var y=j,w=F("../utils/isObject"),b=w.isObject;y.getObjectTagging=function(d){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c,r,i,o,u;return v.default.async(function(s){for(;;)switch(s.prev=s.next){case 0:return n.subres=(0,M.default)({tagging:""},n.subres),n.versionId&&(n.subres.versionId=n.versionId),d=this._objectName(d),c=this._objectRequestParams("GET",d,n),c.successStatuses=[200],s.next=7,v.default.awrap(this.request(c));case 7:return r=s.sent,s.next=10,v.default.awrap(this.parseXML(r.data));case 10:return i=s.sent,o=i.TagSet.Tag,o=o&&b(o)?[o]:o||[],u={},o.forEach(function(l){u[l.Key]=l.Value}),s.abrupt("return",{status:r.status,res:r.res,tag:u});case 16:case"end":return s.stop()}},null,this)}},{"../utils/isObject":46,"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],28:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.getSymlink=function(b){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},d,n,c;return v.default.async(function(i){for(;;)switch(i.prev=i.next){case 0:return p.subres=(0,M.default)({symlink:""},p.subres),p.versionId&&(p.subres.versionId=p.versionId),b=this._objectName(b),d=this._objectRequestParams("GET",b,p),d.successStatuses=[200],i.next=7,v.default.awrap(this.request(d));case 7:return n=i.sent,c=n.res.headers["x-oss-symlink-target"],i.abrupt("return",{targetName:decodeURIComponent(c),res:n.res});case 10:case"end":return i.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],29:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=w(N),C=F("babel-runtime/core-js/object/keys"),M=w(C),m=F("babel-runtime/core-js/object/assign"),y=w(m);function w(p){return p&&p.__esModule?p:{default:p}}var b=j;b.head=function(d){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c,r,i;return v.default.async(function(u){for(;;)switch(u.prev=u.next){case 0:return n.subres=(0,y.default)({},n.subres),n.versionId&&(n.subres.versionId=n.versionId),c=this._objectRequestParams("HEAD",d,n),c.successStatuses=[200,304],u.next=6,v.default.awrap(this.request(c));case 6:return r=u.sent,i={meta:null,res:r.res,status:r.status},r.status===200&&(0,M.default)(r.headers).forEach(function(f){f.indexOf("x-oss-meta-")===0&&(i.meta||(i.meta={}),i.meta[f.substring(11)]=r.headers[f])}),u.abrupt("return",i);case 10:case"end":return u.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/core-js/object/keys":60,"babel-runtime/regenerator":68}],30:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.putACL=function(b,p,d){var n,c;return v.default.async(function(i){for(;;)switch(i.prev=i.next){case 0:return d=d||{},d.subres=(0,M.default)({acl:""},d.subres),d.versionId&&(d.subres.versionId=d.versionId),d.headers=d.headers||{},d.headers["x-oss-object-acl"]=p,b=this._objectName(b),n=this._objectRequestParams("PUT",b,d),n.successStatuses=[200],i.next=10,v.default.awrap(this.request(n));case 10:return c=i.sent,i.abrupt("return",{res:c.res});case 12:case"end":return i.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],31:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=w(N),C=F("babel-runtime/core-js/object/keys"),M=w(C),m=F("babel-runtime/core-js/object/assign"),y=w(m);function w(r){return r&&r.__esModule?r:{default:r}}var b=F("../utils/obj2xml"),p=b.obj2xml,d=F("../utils/checkObjectTag"),n=d.checkObjectTag,c=j;c.putObjectTagging=function(i,o){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},f,s,l;return v.default.async(function(S){for(;;)switch(S.prev=S.next){case 0:return n(o),u.subres=(0,y.default)({tagging:""},u.subres),u.versionId&&(u.subres.versionId=u.versionId),i=this._objectName(i),f=this._objectRequestParams("PUT",i,u),f.successStatuses=[200],o=(0,M.default)(o).map(function(x){return{Key:x,Value:o[x]}}),s={Tagging:{TagSet:{Tag:o}}},f.mime="xml",f.content=p(s),S.next=12,v.default.awrap(this.request(f));case 12:return l=S.sent,S.abrupt("return",{res:l.res,status:l.status});case 14:case"end":return S.stop()}},null,this)}},{"../utils/checkObjectTag":36,"../utils/obj2xml":47,"babel-runtime/core-js/object/assign":54,"babel-runtime/core-js/object/keys":60,"babel-runtime/regenerator":68}],32:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/object/assign"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y.putSymlink=function(b,p,d){var n,c;return v.default.async(function(i){for(;;)switch(i.prev=i.next){case 0:return d=d||{},d.headers=d.headers||{},p=this._escape(this._objectName(p)),this._convertMetaToHeaders(d.meta,d.headers),d.headers["x-oss-symlink-target"]=p,d.subres=(0,M.default)({symlink:""},d.subres),d.versionId&&(d.subres.versionId=d.versionId),d.storageClass&&(d.headers["x-oss-storage-class"]=d.storageClass),b=this._objectName(b),n=this._objectRequestParams("PUT",b,d),n.successStatuses=[200],i.next=13,v.default.awrap(this.request(n));case 13:return c=i.sent,i.abrupt("return",{res:c.res});case 15:case"end":return i.stop()}},null,this)}},{"babel-runtime/core-js/object/assign":54,"babel-runtime/regenerator":68}],33:[function(F,Q,j){"use strict";var N=F("babel-runtime/regenerator"),v=m(N),C=F("babel-runtime/core-js/promise"),M=m(C);function m(w){return w&&w.__esModule?w:{default:w}}var y=j;y._parallelNode=function(b,p,d,n){var c,r,i,o,u,f,s,l;return v.default.async(function(S){for(;;)switch(S.prev=S.next){case 0:c=this,r=[],i=[],o=b.length/p,u=b.length%p,f=u===0?o:(b.length-u)/p+1,s=1,l=0;case 8:if(!(l<b.length)){S.next=26;break}if(!c.isCancel()){S.next=11;break}return S.abrupt("break",26);case 11:if(n?i.push(d(c,b[l],n)):i.push(d(c,b[l])),!(i.length===p||s===f&&l===b.length-1)){S.next=23;break}return S.prev=13,s+=1,S.next=17,v.default.awrap(M.default.all(i));case 17:S.next=22;break;case 19:S.prev=19,S.t0=S.catch(13),r.push(S.t0);case 22:i=[];case 23:l++,S.next=8;break;case 26:return S.abrupt("return",r);case 27:case"end":return S.stop()}},null,this,[[13,19]])},y._parallel=function(b,p,d){var n=this;return new M.default(function(c){var r=[];if(p<=0||!b){c(r);return}function i(h){return function(){if(h===null)throw new Error("Callback was already called.");var R=h;h=null;for(var O=arguments.length,g=Array(O),_=0;_<O;_++)g[_]=arguments[_];R.apply(this,g)}}function o(h){var R=-1,O=h.length;return function(){return++R<O&&!n.isCancel()?{value:h[R],key:R}:null}}var u=o(b),f=!1,s=0,l=!1;function t(h,R){s-=1,h?(f=!0,r.push(h),c(r)):R==={}||f&&s<=0?(f=!0,c(r)):l||(n.isCancel()?c(r):x())}function S(h,R){d(h).then(function(O){R(null,O)}).catch(function(O){R(O)})}function x(){for(l=!0;s<p&&!f&&!n.isCancel();){var h=u();if(h===null||r.length>0){f=!0,s<=0&&c(r);return}s+=1,S(h.value,i(t))}l=!1}x()})},y.cancel=function(b){this.options.cancelFlag=!0,b&&this.abortMultipartUpload(b.name,b.uploadId,b.options)},y.isCancel=function(){return this.options.cancelFlag},y.resetCancelFlag=function(){this.options.cancelFlag=!1},y._stop=function(){this.options.cancelFlag=!0},y._makeCancelEvent=function(){var b={status:0,name:"cancel"};return b}},{"babel-runtime/core-js/promise":61,"babel-runtime/regenerator":68}],34:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/core-js/json/stringify"),C=y(v),M=F("babel-runtime/core-js/object/keys"),m=y(M);function y(p){return p&&p.__esModule?p:{default:p}}var w=F("./../../shims/crypto/crypto.js"),b=F("is-type-of");j.buildCanonicalizedResource=function(d,n){var c=""+d,r="?";if(b.string(n)&&n.trim()!=="")c+=r+n;else if(b.array(n))n.sort(),c+=r+n.join("&");else if(n){var i=function(f,s){return f[0]>s[0]?1:f[0]<s[0]?-1:0},o=function(f){c+=r+f,n[f]&&(c+="="+n[f]),r="&"};(0,m.default)(n).sort(i).forEach(o)}return c},j.buildCanonicalString=function(d,n,c,r){c=c||{};var i=c.headers||{},o="x-oss-",u=[],f={},s=[d.toUpperCase(),i["Content-Md5"]||"",i["Content-Type"]||i["Content-Type".toLowerCase()],r||i["x-oss-date"]];return(0,m.default)(i).forEach(function(l){var t=l.toLowerCase();t.indexOf(o)===0&&(f[t]=String(i[l]).trim())}),(0,m.default)(f).sort().forEach(function(l){u.push(l+":"+f[l])}),s=s.concat(u),s.push(this.buildCanonicalizedResource(n,c.parameters)),s.join(`
`)},j.computeSignature=function(d,n){var c=w.createHmac("sha1",d);return c.update(N.from(n,"utf8")).digest("base64")},j.authorization=function(d,n,c){return"OSS "+d+":"+this.computeSignature(n,c)},j._signatureForURL=function(d){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},c=arguments[2],r=arguments[3],i={},o=n.subResource,u=o===void 0?{}:o;if(n.process){var f="x-oss-process";u[f]=n.process}if(n.trafficLimit){var s="x-oss-traffic-limit";u[s]=n.trafficLimit}if(n.response&&(0,m.default)(n.response).forEach(function(x){var h="response-"+x.toLowerCase();u[h]=n.response[x]}),(0,m.default)(n).forEach(function(x){var h=x.toLowerCase(),R=n[x];h.indexOf("x-oss-")===0?i[h]=R:(h.indexOf("content-md5")===0||h.indexOf("content-type")===0)&&(i[x]=R)}),Object.prototype.hasOwnProperty.call(n,"security-token")&&(u["security-token"]=n["security-token"]),Object.prototype.hasOwnProperty.call(n,"callback")){var l={callbackUrl:encodeURI(n.callback.url),callbackBody:n.callback.body};if(n.callback.host&&(l.callbackHost=n.callback.host),n.callback.contentType&&(l.callbackBodyType=n.callback.contentType),u.callback=N.from((0,C.default)(l)).toString("base64"),n.callback.customValue){var t={};(0,m.default)(n.callback.customValue).forEach(function(x){t["x:"+x]=n.callback.customValue[x]}),u["callback-var"]=N.from((0,C.default)(t)).toString("base64")}}var S=this.buildCanonicalString(n.method,c,{headers:i,parameters:u},r.toString());return{Signature:this.computeSignature(d,S),subResource:u}}}).call(this,F("buffer").Buffer)},{"./../../shims/crypto/crypto.js":284,"babel-runtime/core-js/json/stringify":53,"babel-runtime/core-js/object/keys":60,buffer:73,"is-type-of":289}],35:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.checkBucketName=void 0,j.checkBucketName=function(N,v){var C=v?/^[a-z0-9][a-z0-9-]{1,61}[a-z0-9]$/:/^[a-z0-9_][a-z0-9-_]{1,61}[a-z0-9_]$/;if(!C.test(N))throw new Error("The bucket must be conform to the specifications")}},{}],36:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/entries"),v=C(N);function C(n){return n&&n.__esModule?n:{default:n}}Object.defineProperty(j,"__esModule",{value:!0}),j.checkObjectTag=void 0;var M=F("./checkValid"),m=M.checkValid,y=F("./isObject"),w=y.isObject,b=[{validator:function(c){if(typeof c!="string")throw new Error("the key and value of the tag must be String")}},{pattern:/^[a-zA-Z0-9 +-=._:/]+$/,msg:"tag can contain letters, numbers, spaces, and the following symbols: plus sign (+), hyphen (-), equal sign (=), period (.), underscore (_), colon (:), and forward slash (/)"}],p={key:[].concat(b,[{pattern:/^.{1,128}$/,msg:"tag key can be a maximum of 128 bytes in length"}]),value:[].concat(b,[{pattern:/^.{0,256}$/,msg:"tag value can be a maximum of 256 bytes in length"}])};function d(n){if(!w(n))throw new Error("tag must be Object");var c=(0,v.default)(n);if(c.length>10)throw new Error("maximum of 10 tags for a object");var r=["key","value"];c.forEach(function(i){i.forEach(function(o,u){m(o,p[r[u]])})})}j.checkObjectTag=d},{"./checkValid":37,"./isObject":46,"babel-runtime/core-js/object/entries":57}],37:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.checkValid=void 0;function N(v,C){C.forEach(function(M){if(M.validator)M.validator(v);else if(M.pattern&&!M.pattern.test(v))throw new Error(M.msg)})}j.checkValid=N},{}],38:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/core-js/object/assign"),C=M(v);function M(i){return i&&i.__esModule?i:{default:i}}Object.defineProperty(j,"__esModule",{value:!0}),j.createRequest=void 0;var m=F("./../../../shims/crypto/crypto.js"),y=F("debug")("ali-oss"),w=F("mime"),b=F("dateformat"),p=F("copy-to"),d=F("path");function n(i,o){return i[o]||i[o.toLowerCase()]}function c(i,o){delete i[o],delete i[o.toLowerCase()]}function r(i){var o=new Date;this.options.amendTimeSkewed&&(o=+new Date+this.options.amendTimeSkewed);var u={"x-oss-date":b(o,"UTC:ddd, dd mmm yyyy HH:MM:ss 'GMT'"),"x-oss-user-agent":this.userAgent};this.userAgent.includes("nodejs")&&(u["User-Agent"]=this.userAgent),this.options.isRequestPay&&(0,C.default)(u,{"x-oss-request-payer":"requester"}),this.options.stsToken&&(u["x-oss-security-token"]=this.options.stsToken),p(i.headers).to(u),n(u,"Content-Type")||(i.mime&&i.mime.indexOf("/")>0?u["Content-Type"]=i.mime:u["Content-Type"]=w.getType(i.mime||d.extname(i.object||""))),n(u,"Content-Type")||c(u,"Content-Type"),i.content&&(u["Content-Md5"]=m.createHash("md5").update(N.from(i.content,"utf8")).digest("base64"),u["Content-Length"]||(u["Content-Length"]=i.content.length));var f=this._getResource(i);u.authorization=this.authorization(i.method,f,i.subres,u);var s=this._getReqUrl(i);y("request %s %s, with headers %j, !!stream: %s",i.method,s,u,!!i.stream);var l=i.timeout||this.options.timeout,t={method:i.method,content:i.content,stream:i.stream,headers:u,timeout:l,writeStream:i.writeStream,customResponse:i.customResponse,ctx:i.ctx||this.ctx};return this.agent&&(t.agent=this.agent),this.httpsAgent&&(t.httpsAgent=this.httpsAgent),{url:s,params:t}}j.createRequest=r}).call(this,F("buffer").Buffer)},{"./../../../shims/crypto/crypto.js":284,"babel-runtime/core-js/object/assign":54,buffer:73,"copy-to":76,dateformat:190,debug:288,mime:202,path:205}],39:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/keys"),v=m(N),C=F("babel-runtime/helpers/typeof"),M=m(C);function m(y){return y&&y.__esModule?y:{default:y}}Object.defineProperty(j,"__esModule",{value:!0}),j.deepCopy=void 0,j.deepCopy=function(y){if(y===null||(typeof y=="undefined"?"undefined":(0,M.default)(y))!=="object")return y;var w=Array.isArray(y)?[]:{};return(0,v.default)(y).forEach(function(b){w[b]=j.deepCopy(y[b])}),w}},{"babel-runtime/core-js/object/keys":60,"babel-runtime/helpers/typeof":67}],40:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/keys"),v=m(N),C=F("babel-runtime/helpers/typeof"),M=m(C);function m(b){return b&&b.__esModule?b:{default:b}}Object.defineProperty(j,"__esModule",{value:!0}),j.formatObjKey=void 0;function y(b,p){if(b===null||(typeof b=="undefined"?"undefined":(0,M.default)(b))!=="object")return b;var d=void 0;if(Array.isArray(b)){d=[];for(var n=0;n<b.length;n++)d.push(y(b[n],p))}else d={},(0,v.default)(b).forEach(function(c){d[w(c,p)]=y(b[c],p)});return d}j.formatObjKey=y;function w(b,p){return p==="firstUpperCase"?b=b.replace(/^./,function(d){return d.toUpperCase()}):p==="firstLowerCase"&&(b=b.replace(/^./,function(d){return d.toLowerCase()})),b}},{"babel-runtime/core-js/object/keys":60,"babel-runtime/helpers/typeof":67}],41:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.getStrBytesCount=void 0;function N(v){for(var C=0,M=0;M<v.length;M++){var m=v.charAt(M);/^[\u00-\uff]$/.test(m)?C+=1:C+=2}return C}j.getStrBytesCount=N},{}],42:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.isArray=void 0,j.isArray=function(N){return Object.prototype.toString.call(N)==="[object Array]"}},{}],43:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.isBlob=void 0;function N(v){return typeof Blob!="undefined"&&v instanceof Blob}j.isBlob=N},{}],44:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.isFile=void 0,j.isFile=function(N){return typeof File!="undefined"&&N instanceof File}},{}],45:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.isIP=void 0,j.isIP=function(N){var v=/^(25[0-5]|2[0-4]\d|[0-1]?\d?\d)(\.(25[0-5]|2[0-4]\d|[0-1]?\d?\d)){3}$/,C=/^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?\s*$/;return v.test(N)||C.test(N)}},{}],46:[function(F,Q,j){"use strict";Object.defineProperty(j,"__esModule",{value:!0}),j.isObject=void 0,j.isObject=function(N){return Object.prototype.toString.call(N)==="[object Object]"}},{}],47:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/keys"),v=C(N);function C(w){return w&&w.__esModule?w:{default:w}}Object.defineProperty(j,"__esModule",{value:!0}),j.obj2xml=void 0;var M=F("./formatObjKey");function m(w){return Object.prototype.toString.call(w).replace(/(.*? |])/g,"").toLowerCase()}function y(w,b){var p="";return b&&b.headers&&(p=`<?xml version="1.0" encoding="UTF-8"?>
`),b&&b.firstUpperCase&&(w=M.formatObjKey(w,"firstUpperCase")),m(w)==="object"?(0,v.default)(w).forEach(function(d){m(w[d])==="string"||m(w[d])==="number"?p+="<"+d+">"+w[d]+"</"+d+">":m(w[d])==="object"?p+="<"+d+">"+y(w[d])+"</"+d+">":m(w[d])==="array"?p+=w[d].map(function(n){return"<"+d+">"+y(n)+"</"+d+">"}).join(""):p+="<"+d+">"+w[d].toString()+"</"+d+">"}):p+=w.toString(),p}j.obj2xml=y},{"./formatObjKey":40,"babel-runtime/core-js/object/keys":60}],48:[function(F,Q,j){Q.exports=N,Q.exports.HttpsAgent=N;function N(){}},{}],49:[function(F,Q,j){Q.exports=F("./register")().Promise},{"./register":51}],50:[function(F,Q,j){"use strict";var N="@@any-promise/REGISTRATION",v=null;Q.exports=function(C,M){return function(y,w){y=y||null,w=w||{};var b=w.global!==!1;if(v===null&&b&&(v=C[N]||null),v!==null&&y!==null&&v.implementation!==y)throw new Error('any-promise already defined as "'+v.implementation+'". You can only register an implementation before the first call to require("any-promise") and an implementation cannot be changed');return v===null&&(y!==null&&typeof w.Promise!="undefined"?v={Promise:w.Promise,implementation:y}:v=M(y),b&&(C[N]=v)),v}}},{}],51:[function(F,Q,j){"use strict";Q.exports=F("./loader")(window,N);function N(){if(typeof window.Promise=="undefined")throw new Error("any-promise browser requires a polyfill or explicit registration e.g: require('any-promise/register/bluebird')");return{Promise:window.Promise,implementation:"window.Promise"}}},{"./loader":50}],52:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/array/from"),__esModule:!0}},{"core-js/library/fn/array/from":77}],53:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/json/stringify"),__esModule:!0}},{"core-js/library/fn/json/stringify":78}],54:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/assign"),__esModule:!0}},{"core-js/library/fn/object/assign":79}],55:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/create"),__esModule:!0}},{"core-js/library/fn/object/create":80}],56:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/define-property"),__esModule:!0}},{"core-js/library/fn/object/define-property":81}],57:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/entries"),__esModule:!0}},{"core-js/library/fn/object/entries":82}],58:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/get-own-property-names"),__esModule:!0}},{"core-js/library/fn/object/get-own-property-names":83}],59:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/get-prototype-of"),__esModule:!0}},{"core-js/library/fn/object/get-prototype-of":84}],60:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/object/keys"),__esModule:!0}},{"core-js/library/fn/object/keys":85}],61:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/promise"),__esModule:!0}},{"core-js/library/fn/promise":86}],62:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/set-immediate"),__esModule:!0}},{"core-js/library/fn/set-immediate":87}],63:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/string/from-code-point"),__esModule:!0}},{"core-js/library/fn/string/from-code-point":88}],64:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/symbol"),__esModule:!0}},{"core-js/library/fn/symbol":90}],65:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/symbol/has-instance"),__esModule:!0}},{"core-js/library/fn/symbol/has-instance":89}],66:[function(F,Q,j){Q.exports={default:F("core-js/library/fn/symbol/iterator"),__esModule:!0}},{"core-js/library/fn/symbol/iterator":91}],67:[function(F,Q,j){"use strict";j.__esModule=!0;var N=F("../core-js/symbol/iterator"),v=y(N),C=F("../core-js/symbol"),M=y(C),m=typeof M.default=="function"&&typeof v.default=="symbol"?function(w){return typeof w}:function(w){return w&&typeof M.default=="function"&&w.constructor===M.default&&w!==M.default.prototype?"symbol":typeof w};function y(w){return w&&w.__esModule?w:{default:w}}j.default=typeof M.default=="function"&&m(v.default)==="symbol"?function(w){return typeof w=="undefined"?"undefined":m(w)}:function(w){return w&&typeof M.default=="function"&&w.constructor===M.default&&w!==M.default.prototype?"symbol":typeof w=="undefined"?"undefined":m(w)}},{"../core-js/symbol":64,"../core-js/symbol/iterator":66}],68:[function(F,Q,j){Q.exports=F("regenerator-runtime")},{"regenerator-runtime":226}],69:[function(F,Q,j){"use strict";j.byteLength=b,j.toByteArray=d,j.fromByteArray=r;for(var N=[],v=[],C=typeof Uint8Array!="undefined"?Uint8Array:Array,M="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",m=0,y=M.length;m<y;++m)N[m]=M[m],v[M.charCodeAt(m)]=m;v["-".charCodeAt(0)]=62,v["_".charCodeAt(0)]=63;function w(i){var o=i.length;if(o%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var u=i.indexOf("=");u===-1&&(u=o);var f=u===o?0:4-u%4;return[u,f]}function b(i){var o=w(i),u=o[0],f=o[1];return(u+f)*3/4-f}function p(i,o,u){return(o+u)*3/4-u}function d(i){var o,u=w(i),f=u[0],s=u[1],l=new C(p(i,f,s)),t=0,S=s>0?f-4:f,x;for(x=0;x<S;x+=4)o=v[i.charCodeAt(x)]<<18|v[i.charCodeAt(x+1)]<<12|v[i.charCodeAt(x+2)]<<6|v[i.charCodeAt(x+3)],l[t++]=o>>16&255,l[t++]=o>>8&255,l[t++]=o&255;return s===2&&(o=v[i.charCodeAt(x)]<<2|v[i.charCodeAt(x+1)]>>4,l[t++]=o&255),s===1&&(o=v[i.charCodeAt(x)]<<10|v[i.charCodeAt(x+1)]<<4|v[i.charCodeAt(x+2)]>>2,l[t++]=o>>8&255,l[t++]=o&255),l}function n(i){return N[i>>18&63]+N[i>>12&63]+N[i>>6&63]+N[i&63]}function c(i,o,u){for(var f,s=[],l=o;l<u;l+=3)f=(i[l]<<16&16711680)+(i[l+1]<<8&65280)+(i[l+2]&255),s.push(n(f));return s.join("")}function r(i){for(var o,u=i.length,f=u%3,s=[],l=16383,t=0,S=u-f;t<S;t+=l)s.push(c(i,t,t+l>S?S:t+l));return f===1?(o=i[u-1],s.push(N[o>>2]+N[o<<4&63]+"==")):f===2&&(o=(i[u-2]<<8)+i[u-1],s.push(N[o>>10]+N[o>>4&63]+N[o<<2&63]+"=")),s.join("")}},{}],70:[function(F,Q,j){/*!
* Bowser - a browser detector
* https://github.com/ded/bowser
* MIT License | (c) Dustin Diaz 2015
*/!function(N,v,C){typeof Q!="undefined"&&Q.exports?Q.exports=C():typeof define=="function"&&define.amd?define(v,C):N[v]=C()}(this,"bowser",function(){var N=!0;function v(p){function d(z){var B=p.match(z);return B&&B.length>1&&B[1]||""}function n(z){var B=p.match(z);return B&&B.length>1&&B[2]||""}var c=d(/(ipod|iphone|ipad)/i).toLowerCase(),r=/like android/i.test(p),i=!r&&/android/i.test(p),o=/nexus\s*[0-6]\s*/i.test(p),u=!o&&/nexus\s*[0-9]+/i.test(p),f=/CrOS/.test(p),s=/silk/i.test(p),l=/sailfish/i.test(p),t=/tizen/i.test(p),S=/(web|hpw)(o|0)s/i.test(p),x=/windows phone/i.test(p),h=/SamsungBrowser/i.test(p),R=!x&&/windows/i.test(p),O=!c&&!s&&/macintosh/i.test(p),g=!i&&!l&&!t&&!S&&/linux/i.test(p),_=n(/edg([ea]|ios)\/(\d+(\.\d+)?)/i),E=d(/version\/(\d+(\.\d+)?)/i),T=/tablet/i.test(p)&&!/tablet pc/i.test(p),L=!T&&/[^-]mobi/i.test(p),I=/xbox/i.test(p),P;/opera/i.test(p)?P={name:"Opera",opera:N,version:E||d(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)}:/opr\/|opios/i.test(p)?P={name:"Opera",opera:N,version:d(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||E}:/SamsungBrowser/i.test(p)?P={name:"Samsung Internet for Android",samsungBrowser:N,version:E||d(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)}:/Whale/i.test(p)?P={name:"NAVER Whale browser",whale:N,version:d(/(?:whale)[\s\/](\d+(?:\.\d+)+)/i)}:/MZBrowser/i.test(p)?P={name:"MZ Browser",mzbrowser:N,version:d(/(?:MZBrowser)[\s\/](\d+(?:\.\d+)+)/i)}:/coast/i.test(p)?P={name:"Opera Coast",coast:N,version:E||d(/(?:coast)[\s\/](\d+(\.\d+)?)/i)}:/focus/i.test(p)?P={name:"Focus",focus:N,version:d(/(?:focus)[\s\/](\d+(?:\.\d+)+)/i)}:/yabrowser/i.test(p)?P={name:"Yandex Browser",yandexbrowser:N,version:E||d(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)}:/ucbrowser/i.test(p)?P={name:"UC Browser",ucbrowser:N,version:d(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)}:/mxios/i.test(p)?P={name:"Maxthon",maxthon:N,version:d(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)}:/epiphany/i.test(p)?P={name:"Epiphany",epiphany:N,version:d(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)}:/puffin/i.test(p)?P={name:"Puffin",puffin:N,version:d(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)}:/sleipnir/i.test(p)?P={name:"Sleipnir",sleipnir:N,version:d(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)}:/k-meleon/i.test(p)?P={name:"K-Meleon",kMeleon:N,version:d(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)}:x?(P={name:"Windows Phone",osname:"Windows Phone",windowsphone:N},_?(P.msedge=N,P.version=_):(P.msie=N,P.version=d(/iemobile\/(\d+(\.\d+)?)/i))):/msie|trident/i.test(p)?P={name:"Internet Explorer",msie:N,version:d(/(?:msie |rv:)(\d+(\.\d+)?)/i)}:f?P={name:"Chrome",osname:"Chrome OS",chromeos:N,chromeBook:N,chrome:N,version:d(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:/edg([ea]|ios)/i.test(p)?P={name:"Microsoft Edge",msedge:N,version:_}:/vivaldi/i.test(p)?P={name:"Vivaldi",vivaldi:N,version:d(/vivaldi\/(\d+(\.\d+)?)/i)||E}:l?P={name:"Sailfish",osname:"Sailfish OS",sailfish:N,version:d(/sailfish\s?browser\/(\d+(\.\d+)?)/i)}:/seamonkey\//i.test(p)?P={name:"SeaMonkey",seamonkey:N,version:d(/seamonkey\/(\d+(\.\d+)?)/i)}:/firefox|iceweasel|fxios/i.test(p)?(P={name:"Firefox",firefox:N,version:d(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(p)&&(P.firefoxos=N,P.osname="Firefox OS")):s?P={name:"Amazon Silk",silk:N,version:d(/silk\/(\d+(\.\d+)?)/i)}:/phantom/i.test(p)?P={name:"PhantomJS",phantom:N,version:d(/phantomjs\/(\d+(\.\d+)?)/i)}:/slimerjs/i.test(p)?P={name:"SlimerJS",slimer:N,version:d(/slimerjs\/(\d+(\.\d+)?)/i)}:/blackberry|\bbb\d+/i.test(p)||/rim\stablet/i.test(p)?P={name:"BlackBerry",osname:"BlackBerry OS",blackberry:N,version:E||d(/blackberry[\d]+\/(\d+(\.\d+)?)/i)}:S?(P={name:"WebOS",osname:"WebOS",webos:N,version:E||d(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(p)&&(P.touchpad=N)):/bada/i.test(p)?P={name:"Bada",osname:"Bada",bada:N,version:d(/dolfin\/(\d+(\.\d+)?)/i)}:t?P={name:"Tizen",osname:"Tizen",tizen:N,version:d(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||E}:/qupzilla/i.test(p)?P={name:"QupZilla",qupzilla:N,version:d(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||E}:/chromium/i.test(p)?P={name:"Chromium",chromium:N,version:d(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||E}:/chrome|crios|crmo/i.test(p)?P={name:"Chrome",chrome:N,version:d(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:i?P={name:"Android",version:E}:/safari|applewebkit/i.test(p)?(P={name:"Safari",safari:N},E&&(P.version=E)):c?(P={name:c=="iphone"?"iPhone":c=="ipad"?"iPad":"iPod"},E&&(P.version=E)):/googlebot/i.test(p)?P={name:"Googlebot",googlebot:N,version:d(/googlebot\/(\d+(\.\d+))/i)||E}:P={name:d(/^(.*)\/(.*) /),version:n(/^(.*)\/(.*) /)},!P.msedge&&/(apple)?webkit/i.test(p)?(/(apple)?webkit\/537\.36/i.test(p)?(P.name=P.name||"Blink",P.blink=N):(P.name=P.name||"Webkit",P.webkit=N),!P.version&&E&&(P.version=E)):!P.opera&&/gecko\//i.test(p)&&(P.name=P.name||"Gecko",P.gecko=N,P.version=P.version||d(/gecko\/(\d+(\.\d+)?)/i)),!P.windowsphone&&(i||P.silk)?(P.android=N,P.osname="Android"):!P.windowsphone&&c?(P[c]=N,P.ios=N,P.osname="iOS"):O?(P.mac=N,P.osname="macOS"):I?(P.xbox=N,P.osname="Xbox"):R?(P.windows=N,P.osname="Windows"):g&&(P.linux=N,P.osname="Linux");function G(z){switch(z){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}}var W="";P.windows?W=G(d(/Windows ((NT|XP)( \d\d?.\d)?)/i)):P.windowsphone?W=d(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i):P.mac?(W=d(/Mac OS X (\d+([_\.\s]\d+)*)/i),W=W.replace(/[_\s]/g,".")):c?(W=d(/os (\d+([_\s]\d+)*) like mac os x/i),W=W.replace(/[_\s]/g,".")):i?W=d(/android[ \/-](\d+(\.\d+)*)/i):P.webos?W=d(/(?:web|hpw)os\/(\d+(\.\d+)*)/i):P.blackberry?W=d(/rim\stablet\sos\s(\d+(\.\d+)*)/i):P.bada?W=d(/bada\/(\d+(\.\d+)*)/i):P.tizen&&(W=d(/tizen[\/\s](\d+(\.\d+)*)/i)),W&&(P.osversion=W);var H=!P.windows&&W.split(".")[0];return T||u||c=="ipad"||i&&(H==3||H>=4&&!L)||P.silk?P.tablet=N:(L||c=="iphone"||c=="ipod"||i||o||P.blackberry||P.webos||P.bada)&&(P.mobile=N),P.msedge||P.msie&&P.version>=10||P.yandexbrowser&&P.version>=15||P.vivaldi&&P.version>=1||P.chrome&&P.version>=20||P.samsungBrowser&&P.version>=4||P.whale&&y([P.version,"1.0"])===1||P.mzbrowser&&y([P.version,"6.0"])===1||P.focus&&y([P.version,"1.0"])===1||P.firefox&&P.version>=20||P.safari&&P.version>=6||P.opera&&P.version>=10||P.ios&&P.osversion&&P.osversion.split(".")[0]>=6||P.blackberry&&P.version>=10.1||P.chromium&&P.version>=20?P.a=N:P.msie&&P.version<10||P.chrome&&P.version<20||P.firefox&&P.version<20||P.safari&&P.version<6||P.opera&&P.version<10||P.ios&&P.osversion&&P.osversion.split(".")[0]<6||P.chromium&&P.version<20?P.c=N:P.x=N,P}var C=v(typeof navigator!="undefined"&&navigator.userAgent||"");C.test=function(p){for(var d=0;d<p.length;++d){var n=p[d];if(typeof n=="string"&&n in C)return!0}return!1};function M(p){return p.split(".").length}function m(p,d){var n=[],c;if(Array.prototype.map)return Array.prototype.map.call(p,d);for(c=0;c<p.length;c++)n.push(d(p[c]));return n}function y(p){for(var d=Math.max(M(p[0]),M(p[1])),n=m(p,function(c){var r=d-M(c);return c=c+new Array(r+1).join(".0"),m(c.split("."),function(i){return new Array(20-i.length).join("0")+i}).reverse()});--d>=0;){if(n[0][d]>n[1][d])return 1;if(n[0][d]===n[1][d]){if(d===0)return 0}else return-1}}function w(p,d,n){var c=C;typeof d=="string"&&(n=d,d=void 0),d===void 0&&(d=!1),n&&(c=v(n));var r=""+c.version;for(var i in p)if(p.hasOwnProperty(i)&&c[i]){if(typeof p[i]!="string")throw new Error("Browser version in the minVersion map should be a string: "+i+": "+String(p));return y([r,p[i]])<0}return d}function b(p,d,n){return!w(p,d,n)}return C.isUnsupportedBrowser=w,C.compareVersions=y,C.check=b,C._detect=v,C.detect=v,C})},{}],71:[function(F,Q,j){},{}],72:[function(F,Q,j){var N=F("buffer").Buffer,v=N.isEncoding||function(b){switch(b&&b.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function C(b){if(b&&!v(b))throw new Error("Unknown encoding: "+b)}var M=j.StringDecoder=function(b){this.encoding=(b||"utf8").toLowerCase().replace(/[-_]/,""),C(b);switch(this.encoding){case"utf8":this.surrogateSize=3;break;case"ucs2":case"utf16le":this.surrogateSize=2,this.detectIncompleteChar=y;break;case"base64":this.surrogateSize=3,this.detectIncompleteChar=w;break;default:this.write=m;return}this.charBuffer=new N(6),this.charReceived=0,this.charLength=0};M.prototype.write=function(b){for(var p="";this.charLength;){var d=b.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:b.length;if(b.copy(this.charBuffer,this.charReceived,0,d),this.charReceived+=d,this.charReceived<this.charLength)return"";b=b.slice(d,b.length),p=this.charBuffer.slice(0,this.charLength).toString(this.encoding);var c=p.charCodeAt(p.length-1);if(c>=55296&&c<=56319){this.charLength+=this.surrogateSize,p="";continue}if(this.charReceived=this.charLength=0,b.length===0)return p;break}this.detectIncompleteChar(b);var n=b.length;this.charLength&&(b.copy(this.charBuffer,0,b.length-this.charReceived,n),n-=this.charReceived),p+=b.toString(this.encoding,0,n);var n=p.length-1,c=p.charCodeAt(n);if(c>=55296&&c<=56319){var r=this.surrogateSize;return this.charLength+=r,this.charReceived+=r,this.charBuffer.copy(this.charBuffer,r,0,r),b.copy(this.charBuffer,0,0,r),p.substring(0,n)}return p},M.prototype.detectIncompleteChar=function(b){for(var p=b.length>=3?3:b.length;p>0;p--){var d=b[b.length-p];if(p==1&&d>>5==6){this.charLength=2;break}if(p<=2&&d>>4==14){this.charLength=3;break}if(p<=3&&d>>3==30){this.charLength=4;break}}this.charReceived=p},M.prototype.end=function(b){var p="";if(b&&b.length&&(p=this.write(b)),this.charReceived){var d=this.charReceived,n=this.charBuffer,c=this.encoding;p+=n.slice(0,d).toString(c)}return p};function m(b){return b.toString(this.encoding)}function y(b){this.charReceived=b.length%2,this.charLength=this.charReceived?2:0}function w(b){this.charReceived=b.length%3,this.charLength=this.charReceived?3:0}},{buffer:73}],73:[function(F,Q,j){(function(N,v){/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <http://feross.org>
* @license MIT
*/"use strict";var C=F("base64-js"),M=F("ieee754"),m=F("isarray");j.Buffer=v,j.SlowBuffer=s,j.INSPECT_MAX_BYTES=50,v.TYPED_ARRAY_SUPPORT=N.TYPED_ARRAY_SUPPORT!==void 0?N.TYPED_ARRAY_SUPPORT:y(),j.kMaxLength=w();function y(){try{var te=new Uint8Array(1);return te.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},te.foo()===42&&typeof te.subarray=="function"&&te.subarray(1,1).byteLength===0}catch(J){return!1}}function w(){return v.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function b(te,J){if(w()<J)throw new RangeError("Invalid typed array length");return v.TYPED_ARRAY_SUPPORT?(te=new Uint8Array(J),te.__proto__=v.prototype):(te===null&&(te=new v(J)),te.length=J),te}function v(te,J,X){if(!v.TYPED_ARRAY_SUPPORT&&!(this instanceof v))return new v(te,J,X);if(typeof te=="number"){if(typeof J=="string")throw new Error("If encoding is specified then the first argument must be a string");return c(this,te)}return p(this,te,J,X)}v.poolSize=8192,v._augment=function(te){return te.__proto__=v.prototype,te};function p(te,J,X,$){if(typeof J=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer!="undefined"&&J instanceof ArrayBuffer?o(te,J,X,$):typeof J=="string"?r(te,J,X):u(te,J)}v.from=function(te,J,X){return p(null,te,J,X)},v.TYPED_ARRAY_SUPPORT&&(v.prototype.__proto__=Uint8Array.prototype,v.__proto__=Uint8Array,typeof Symbol!="undefined"&&Symbol.species&&v[Symbol.species]===v&&Object.defineProperty(v,Symbol.species,{value:null,configurable:!0}));function d(te){if(typeof te!="number")throw new TypeError('"size" argument must be a number');if(te<0)throw new RangeError('"size" argument must not be negative')}function n(te,J,X,$){return d(J),J<=0?b(te,J):X!==void 0?typeof $=="string"?b(te,J).fill(X,$):b(te,J).fill(X):b(te,J)}v.alloc=function(te,J,X){return n(null,te,J,X)};function c(te,J){if(d(J),te=b(te,J<0?0:f(J)|0),!v.TYPED_ARRAY_SUPPORT)for(var X=0;X<J;++X)te[X]=0;return te}v.allocUnsafe=function(te){return c(null,te)},v.allocUnsafeSlow=function(te){return c(null,te)};function r(te,J,X){if((typeof X!="string"||X==="")&&(X="utf8"),!v.isEncoding(X))throw new TypeError('"encoding" must be a valid string encoding');var $=l(J,X)|0;te=b(te,$);var ge=te.write(J,X);return ge!==$&&(te=te.slice(0,ge)),te}function i(te,J){var X=J.length<0?0:f(J.length)|0;te=b(te,X);for(var $=0;$<X;$+=1)te[$]=J[$]&255;return te}function o(te,J,X,$){if(J.byteLength,X<0||J.byteLength<X)throw new RangeError("'offset' is out of bounds");if(J.byteLength<X+($||0))throw new RangeError("'length' is out of bounds");return X===void 0&&$===void 0?J=new Uint8Array(J):$===void 0?J=new Uint8Array(J,X):J=new Uint8Array(J,X,$),v.TYPED_ARRAY_SUPPORT?(te=J,te.__proto__=v.prototype):te=i(te,J),te}function u(te,J){if(v.isBuffer(J)){var X=f(J.length)|0;return te=b(te,X),te.length===0||J.copy(te,0,0,X),te}if(J){if(typeof ArrayBuffer!="undefined"&&J.buffer instanceof ArrayBuffer||"length"in J)return typeof J.length!="number"||Ee(J.length)?b(te,0):i(te,J);if(J.type==="Buffer"&&m(J.data))return i(te,J.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function f(te){if(te>=w())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+w().toString(16)+" bytes");return te|0}function s(te){return+te!=te&&(te=0),v.alloc(+te)}v.isBuffer=function(J){return!!(J!=null&&J._isBuffer)},v.compare=function(J,X){if(!v.isBuffer(J)||!v.isBuffer(X))throw new TypeError("Arguments must be Buffers");if(J===X)return 0;for(var $=J.length,ge=X.length,fe=0,Te=Math.min($,ge);fe<Te;++fe)if(J[fe]!==X[fe]){$=J[fe],ge=X[fe];break}return $<ge?-1:ge<$?1:0},v.isEncoding=function(J){switch(String(J).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},v.concat=function(J,X){if(!m(J))throw new TypeError('"list" argument must be an Array of Buffers');if(J.length===0)return v.alloc(0);var $;if(X===void 0)for(X=0,$=0;$<J.length;++$)X+=J[$].length;var ge=v.allocUnsafe(X),fe=0;for($=0;$<J.length;++$){var Te=J[$];if(!v.isBuffer(Te))throw new TypeError('"list" argument must be an Array of Buffers');Te.copy(ge,fe),fe+=Te.length}return ge};function l(te,J){if(v.isBuffer(te))return te.length;if(typeof ArrayBuffer!="undefined"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(te)||te instanceof ArrayBuffer))return te.byteLength;typeof te!="string"&&(te=""+te);var X=te.length;if(X===0)return 0;for(var $=!1;;)switch(J){case"ascii":case"latin1":case"binary":return X;case"utf8":case"utf-8":case void 0:return ie(te).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return X*2;case"hex":return X>>>1;case"base64":return Z(te).length;default:if($)return ie(te).length;J=(""+J).toLowerCase(),$=!0}}v.byteLength=l;function t(te,J,X){var $=!1;if((J===void 0||J<0)&&(J=0),J>this.length)return"";if((X===void 0||X>this.length)&&(X=this.length),X<=0)return"";if(X>>>=0,J>>>=0,X<=J)return"";for(te||(te="utf8");;)switch(te){case"hex":return z(this,J,X);case"utf8":case"utf-8":return I(this,J,X);case"ascii":return W(this,J,X);case"latin1":case"binary":return H(this,J,X);case"base64":return L(this,J,X);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B(this,J,X);default:if($)throw new TypeError("Unknown encoding: "+te);te=(te+"").toLowerCase(),$=!0}}v.prototype._isBuffer=!0;function S(te,J,X){var $=te[J];te[J]=te[X],te[X]=$}v.prototype.swap16=function(){var J=this.length;if(J%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var X=0;X<J;X+=2)S(this,X,X+1);return this},v.prototype.swap32=function(){var J=this.length;if(J%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var X=0;X<J;X+=4)S(this,X,X+3),S(this,X+1,X+2);return this},v.prototype.swap64=function(){var J=this.length;if(J%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var X=0;X<J;X+=8)S(this,X,X+7),S(this,X+1,X+6),S(this,X+2,X+5),S(this,X+3,X+4);return this},v.prototype.toString=function(){var J=this.length|0;return J===0?"":arguments.length===0?I(this,0,J):t.apply(this,arguments)},v.prototype.equals=function(J){if(!v.isBuffer(J))throw new TypeError("Argument must be a Buffer");return this===J?!0:v.compare(this,J)===0},v.prototype.inspect=function(){var J="",X=j.INSPECT_MAX_BYTES;return this.length>0&&(J=this.toString("hex",0,X).match(/.{2}/g).join(" "),this.length>X&&(J+=" ... ")),"<Buffer "+J+">"},v.prototype.compare=function(J,X,$,ge,fe){if(!v.isBuffer(J))throw new TypeError("Argument must be a Buffer");if(X===void 0&&(X=0),$===void 0&&($=J?J.length:0),ge===void 0&&(ge=0),fe===void 0&&(fe=this.length),X<0||$>J.length||ge<0||fe>this.length)throw new RangeError("out of range index");if(ge>=fe&&X>=$)return 0;if(ge>=fe)return-1;if(X>=$)return 1;if(X>>>=0,$>>>=0,ge>>>=0,fe>>>=0,this===J)return 0;for(var Te=fe-ge,ze=$-X,Xe=Math.min(Te,ze),Ye=this.slice(ge,fe),rt=J.slice(X,$),at=0;at<Xe;++at)if(Ye[at]!==rt[at]){Te=Ye[at],ze=rt[at];break}return Te<ze?-1:ze<Te?1:0};function x(te,J,X,$,ge){if(te.length===0)return-1;if(typeof X=="string"?($=X,X=0):X>2147483647?X=2147483647:X<-2147483648&&(X=-2147483648),X=+X,isNaN(X)&&(X=ge?0:te.length-1),X<0&&(X=te.length+X),X>=te.length){if(ge)return-1;X=te.length-1}else if(X<0)if(ge)X=0;else return-1;if(typeof J=="string"&&(J=v.from(J,$)),v.isBuffer(J))return J.length===0?-1:h(te,J,X,$,ge);if(typeof J=="number")return J=J&255,v.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?ge?Uint8Array.prototype.indexOf.call(te,J,X):Uint8Array.prototype.lastIndexOf.call(te,J,X):h(te,[J],X,$,ge);throw new TypeError("val must be string, number or Buffer")}function h(te,J,X,$,ge){var fe=1,Te=te.length,ze=J.length;if($!==void 0&&($=String($).toLowerCase(),$==="ucs2"||$==="ucs-2"||$==="utf16le"||$==="utf-16le")){if(te.length<2||J.length<2)return-1;fe=2,Te/=2,ze/=2,X/=2}function Xe(Pe,Se){return fe===1?Pe[Se]:Pe.readUInt16BE(Se*fe)}var Ye;if(ge){var rt=-1;for(Ye=X;Ye<Te;Ye++)if(Xe(te,Ye)===Xe(J,rt===-1?0:Ye-rt)){if(rt===-1&&(rt=Ye),Ye-rt+1===ze)return rt*fe}else rt!==-1&&(Ye-=Ye-rt),rt=-1}else for(X+ze>Te&&(X=Te-ze),Ye=X;Ye>=0;Ye--){for(var at=!0,ot=0;ot<ze;ot++)if(Xe(te,Ye+ot)!==Xe(J,ot)){at=!1;break}if(at)return Ye}return-1}v.prototype.includes=function(J,X,$){return this.indexOf(J,X,$)!==-1},v.prototype.indexOf=function(J,X,$){return x(this,J,X,$,!0)},v.prototype.lastIndexOf=function(J,X,$){return x(this,J,X,$,!1)};function R(te,J,X,$){X=Number(X)||0;var ge=te.length-X;$?($=Number($),$>ge&&($=ge)):$=ge;var fe=J.length;if(fe%2!==0)throw new TypeError("Invalid hex string");$>fe/2&&($=fe/2);for(var Te=0;Te<$;++Te){var ze=parseInt(J.substr(Te*2,2),16);if(isNaN(ze))return Te;te[X+Te]=ze}return Te}function O(te,J,X,$){return ee(ie(J,te.length-X),te,X,$)}function g(te,J,X,$){return ee(q(J),te,X,$)}function _(te,J,X,$){return g(te,J,X,$)}function E(te,J,X,$){return ee(Z(J),te,X,$)}function T(te,J,X,$){return ee(ue(J,te.length-X),te,X,$)}v.prototype.write=function(J,X,$,ge){if(X===void 0)ge="utf8",$=this.length,X=0;else if($===void 0&&typeof X=="string")ge=X,$=this.length,X=0;else if(isFinite(X))X=X|0,isFinite($)?($=$|0,ge===void 0&&(ge="utf8")):(ge=$,$=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var fe=this.length-X;if(($===void 0||$>fe)&&($=fe),J.length>0&&($<0||X<0)||X>this.length)throw new RangeError("Attempt to write outside buffer bounds");ge||(ge="utf8");for(var Te=!1;;)switch(ge){case"hex":return R(this,J,X,$);case"utf8":case"utf-8":return O(this,J,X,$);case"ascii":return g(this,J,X,$);case"latin1":case"binary":return _(this,J,X,$);case"base64":return E(this,J,X,$);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,J,X,$);default:if(Te)throw new TypeError("Unknown encoding: "+ge);ge=(""+ge).toLowerCase(),Te=!0}},v.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function L(te,J,X){return J===0&&X===te.length?C.fromByteArray(te):C.fromByteArray(te.slice(J,X))}function I(te,J,X){X=Math.min(te.length,X);for(var $=[],ge=J;ge<X;){var fe=te[ge],Te=null,ze=fe>239?4:fe>223?3:fe>191?2:1;if(ge+ze<=X){var Xe,Ye,rt,at;switch(ze){case 1:fe<128&&(Te=fe);break;case 2:Xe=te[ge+1],(Xe&192)===128&&(at=(fe&31)<<6|Xe&63,at>127&&(Te=at));break;case 3:Xe=te[ge+1],Ye=te[ge+2],(Xe&192)===128&&(Ye&192)===128&&(at=(fe&15)<<12|(Xe&63)<<6|Ye&63,at>2047&&(at<55296||at>57343)&&(Te=at));break;case 4:Xe=te[ge+1],Ye=te[ge+2],rt=te[ge+3],(Xe&192)===128&&(Ye&192)===128&&(rt&192)===128&&(at=(fe&15)<<18|(Xe&63)<<12|(Ye&63)<<6|rt&63,at>65535&&at<1114112&&(Te=at))}}Te===null?(Te=65533,ze=1):Te>65535&&(Te-=65536,$.push(Te>>>10&1023|55296),Te=56320|Te&1023),$.push(Te),ge+=ze}return G($)}var P=4096;function G(te){var J=te.length;if(J<=P)return String.fromCharCode.apply(String,te);for(var X="",$=0;$<J;)X+=String.fromCharCode.apply(String,te.slice($,$+=P));return X}function W(te,J,X){var $="";X=Math.min(te.length,X);for(var ge=J;ge<X;++ge)$+=String.fromCharCode(te[ge]&127);return $}function H(te,J,X){var $="";X=Math.min(te.length,X);for(var ge=J;ge<X;++ge)$+=String.fromCharCode(te[ge]);return $}function z(te,J,X){var $=te.length;(!J||J<0)&&(J=0),(!X||X<0||X>$)&&(X=$);for(var ge="",fe=J;fe<X;++fe)ge+=ae(te[fe]);return ge}function B(te,J,X){for(var $=te.slice(J,X),ge="",fe=0;fe<$.length;fe+=2)ge+=String.fromCharCode($[fe]+$[fe+1]*256);return ge}v.prototype.slice=function(J,X){var $=this.length;J=~~J,X=X===void 0?$:~~X,J<0?(J+=$,J<0&&(J=0)):J>$&&(J=$),X<0?(X+=$,X<0&&(X=0)):X>$&&(X=$),X<J&&(X=J);var ge;if(v.TYPED_ARRAY_SUPPORT)ge=this.subarray(J,X),ge.__proto__=v.prototype;else{var fe=X-J;ge=new v(fe,void 0);for(var Te=0;Te<fe;++Te)ge[Te]=this[Te+J]}return ge};function k(te,J,X){if(te%1!==0||te<0)throw new RangeError("offset is not uint");if(te+J>X)throw new RangeError("Trying to access beyond buffer length")}v.prototype.readUIntLE=function(J,X,$){J=J|0,X=X|0,$||k(J,X,this.length);for(var ge=this[J],fe=1,Te=0;++Te<X&&(fe*=256);)ge+=this[J+Te]*fe;return ge},v.prototype.readUIntBE=function(J,X,$){J=J|0,X=X|0,$||k(J,X,this.length);for(var ge=this[J+--X],fe=1;X>0&&(fe*=256);)ge+=this[J+--X]*fe;return ge},v.prototype.readUInt8=function(J,X){return X||k(J,1,this.length),this[J]},v.prototype.readUInt16LE=function(J,X){return X||k(J,2,this.length),this[J]|this[J+1]<<8},v.prototype.readUInt16BE=function(J,X){return X||k(J,2,this.length),this[J]<<8|this[J+1]},v.prototype.readUInt32LE=function(J,X){return X||k(J,4,this.length),(this[J]|this[J+1]<<8|this[J+2]<<16)+this[J+3]*16777216},v.prototype.readUInt32BE=function(J,X){return X||k(J,4,this.length),this[J]*16777216+(this[J+1]<<16|this[J+2]<<8|this[J+3])},v.prototype.readIntLE=function(J,X,$){J=J|0,X=X|0,$||k(J,X,this.length);for(var ge=this[J],fe=1,Te=0;++Te<X&&(fe*=256);)ge+=this[J+Te]*fe;return fe*=128,ge>=fe&&(ge-=Math.pow(2,8*X)),ge},v.prototype.readIntBE=function(J,X,$){J=J|0,X=X|0,$||k(J,X,this.length);for(var ge=X,fe=1,Te=this[J+--ge];ge>0&&(fe*=256);)Te+=this[J+--ge]*fe;return fe*=128,Te>=fe&&(Te-=Math.pow(2,8*X)),Te},v.prototype.readInt8=function(J,X){return X||k(J,1,this.length),this[J]&128?(255-this[J]+1)*-1:this[J]},v.prototype.readInt16LE=function(J,X){X||k(J,2,this.length);var $=this[J]|this[J+1]<<8;return $&32768?$|4294901760:$},v.prototype.readInt16BE=function(J,X){X||k(J,2,this.length);var $=this[J+1]|this[J]<<8;return $&32768?$|4294901760:$},v.prototype.readInt32LE=function(J,X){return X||k(J,4,this.length),this[J]|this[J+1]<<8|this[J+2]<<16|this[J+3]<<24},v.prototype.readInt32BE=function(J,X){return X||k(J,4,this.length),this[J]<<24|this[J+1]<<16|this[J+2]<<8|this[J+3]},v.prototype.readFloatLE=function(J,X){return X||k(J,4,this.length),M.read(this,J,!0,23,4)},v.prototype.readFloatBE=function(J,X){return X||k(J,4,this.length),M.read(this,J,!1,23,4)},v.prototype.readDoubleLE=function(J,X){return X||k(J,8,this.length),M.read(this,J,!0,52,8)},v.prototype.readDoubleBE=function(J,X){return X||k(J,8,this.length),M.read(this,J,!1,52,8)};function K(te,J,X,$,ge,fe){if(!v.isBuffer(te))throw new TypeError('"buffer" argument must be a Buffer instance');if(J>ge||J<fe)throw new RangeError('"value" argument is out of bounds');if(X+$>te.length)throw new RangeError("Index out of range")}v.prototype.writeUIntLE=function(J,X,$,ge){if(J=+J,X=X|0,$=$|0,!ge){var fe=Math.pow(2,8*$)-1;K(this,J,X,$,fe,0)}var Te=1,ze=0;for(this[X]=J&255;++ze<$&&(Te*=256);)this[X+ze]=J/Te&255;return X+$},v.prototype.writeUIntBE=function(J,X,$,ge){if(J=+J,X=X|0,$=$|0,!ge){var fe=Math.pow(2,8*$)-1;K(this,J,X,$,fe,0)}var Te=$-1,ze=1;for(this[X+Te]=J&255;--Te>=0&&(ze*=256);)this[X+Te]=J/ze&255;return X+$},v.prototype.writeUInt8=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,1,255,0),v.TYPED_ARRAY_SUPPORT||(J=Math.floor(J)),this[X]=J&255,X+1};function Y(te,J,X,$){J<0&&(J=65535+J+1);for(var ge=0,fe=Math.min(te.length-X,2);ge<fe;++ge)te[X+ge]=(J&255<<8*($?ge:1-ge))>>>($?ge:1-ge)*8}v.prototype.writeUInt16LE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,2,65535,0),v.TYPED_ARRAY_SUPPORT?(this[X]=J&255,this[X+1]=J>>>8):Y(this,J,X,!0),X+2},v.prototype.writeUInt16BE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,2,65535,0),v.TYPED_ARRAY_SUPPORT?(this[X]=J>>>8,this[X+1]=J&255):Y(this,J,X,!1),X+2};function ne(te,J,X,$){J<0&&(J=4294967295+J+1);for(var ge=0,fe=Math.min(te.length-X,4);ge<fe;++ge)te[X+ge]=J>>>($?ge:3-ge)*8&255}v.prototype.writeUInt32LE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,4,4294967295,0),v.TYPED_ARRAY_SUPPORT?(this[X+3]=J>>>24,this[X+2]=J>>>16,this[X+1]=J>>>8,this[X]=J&255):ne(this,J,X,!0),X+4},v.prototype.writeUInt32BE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,4,4294967295,0),v.TYPED_ARRAY_SUPPORT?(this[X]=J>>>24,this[X+1]=J>>>16,this[X+2]=J>>>8,this[X+3]=J&255):ne(this,J,X,!1),X+4},v.prototype.writeIntLE=function(J,X,$,ge){if(J=+J,X=X|0,!ge){var fe=Math.pow(2,8*$-1);K(this,J,X,$,fe-1,-fe)}var Te=0,ze=1,Xe=0;for(this[X]=J&255;++Te<$&&(ze*=256);)J<0&&Xe===0&&this[X+Te-1]!==0&&(Xe=1),this[X+Te]=(J/ze>>0)-Xe&255;return X+$},v.prototype.writeIntBE=function(J,X,$,ge){if(J=+J,X=X|0,!ge){var fe=Math.pow(2,8*$-1);K(this,J,X,$,fe-1,-fe)}var Te=$-1,ze=1,Xe=0;for(this[X+Te]=J&255;--Te>=0&&(ze*=256);)J<0&&Xe===0&&this[X+Te+1]!==0&&(Xe=1),this[X+Te]=(J/ze>>0)-Xe&255;return X+$},v.prototype.writeInt8=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,1,127,-128),v.TYPED_ARRAY_SUPPORT||(J=Math.floor(J)),J<0&&(J=255+J+1),this[X]=J&255,X+1},v.prototype.writeInt16LE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,2,32767,-32768),v.TYPED_ARRAY_SUPPORT?(this[X]=J&255,this[X+1]=J>>>8):Y(this,J,X,!0),X+2},v.prototype.writeInt16BE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,2,32767,-32768),v.TYPED_ARRAY_SUPPORT?(this[X]=J>>>8,this[X+1]=J&255):Y(this,J,X,!1),X+2},v.prototype.writeInt32LE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,4,2147483647,-2147483648),v.TYPED_ARRAY_SUPPORT?(this[X]=J&255,this[X+1]=J>>>8,this[X+2]=J>>>16,this[X+3]=J>>>24):ne(this,J,X,!0),X+4},v.prototype.writeInt32BE=function(J,X,$){return J=+J,X=X|0,$||K(this,J,X,4,2147483647,-2147483648),J<0&&(J=4294967295+J+1),v.TYPED_ARRAY_SUPPORT?(this[X]=J>>>24,this[X+1]=J>>>16,this[X+2]=J>>>8,this[X+3]=J&255):ne(this,J,X,!1),X+4};function oe(te,J,X,$,ge,fe){if(X+$>te.length)throw new RangeError("Index out of range");if(X<0)throw new RangeError("Index out of range")}function _e(te,J,X,$,ge){return ge||oe(te,J,X,4,34028234663852886e22,-34028234663852886e22),M.write(te,J,X,$,23,4),X+4}v.prototype.writeFloatLE=function(J,X,$){return _e(this,J,X,!0,$)},v.prototype.writeFloatBE=function(J,X,$){return _e(this,J,X,!1,$)};function xe(te,J,X,$,ge){return ge||oe(te,J,X,8,17976931348623157e292,-17976931348623157e292),M.write(te,J,X,$,52,8),X+8}v.prototype.writeDoubleLE=function(J,X,$){return xe(this,J,X,!0,$)},v.prototype.writeDoubleBE=function(J,X,$){return xe(this,J,X,!1,$)},v.prototype.copy=function(J,X,$,ge){if($||($=0),!ge&&ge!==0&&(ge=this.length),X>=J.length&&(X=J.length),X||(X=0),ge>0&&ge<$&&(ge=$),ge===$)return 0;if(J.length===0||this.length===0)return 0;if(X<0)throw new RangeError("targetStart out of bounds");if($<0||$>=this.length)throw new RangeError("sourceStart out of bounds");if(ge<0)throw new RangeError("sourceEnd out of bounds");ge>this.length&&(ge=this.length),J.length-X<ge-$&&(ge=J.length-X+$);var fe=ge-$,Te;if(this===J&&$<X&&X<ge)for(Te=fe-1;Te>=0;--Te)J[Te+X]=this[Te+$];else if(fe<1e3||!v.TYPED_ARRAY_SUPPORT)for(Te=0;Te<fe;++Te)J[Te+X]=this[Te+$];else Uint8Array.prototype.set.call(J,this.subarray($,$+fe),X);return fe},v.prototype.fill=function(J,X,$,ge){if(typeof J=="string"){if(typeof X=="string"?(ge=X,X=0,$=this.length):typeof $=="string"&&(ge=$,$=this.length),J.length===1){var fe=J.charCodeAt(0);fe<256&&(J=fe)}if(ge!==void 0&&typeof ge!="string")throw new TypeError("encoding must be a string");if(typeof ge=="string"&&!v.isEncoding(ge))throw new TypeError("Unknown encoding: "+ge)}else typeof J=="number"&&(J=J&255);if(X<0||this.length<X||this.length<$)throw new RangeError("Out of range index");if($<=X)return this;X=X>>>0,$=$===void 0?this.length:$>>>0,J||(J=0);var Te;if(typeof J=="number")for(Te=X;Te<$;++Te)this[Te]=J;else{var ze=v.isBuffer(J)?J:ie(new v(J,ge).toString()),Xe=ze.length;for(Te=0;Te<$-X;++Te)this[Te+X]=ze[Te%Xe]}return this};var le=/[^+\/0-9A-Za-z-_]/g;function me(te){if(te=de(te).replace(le,""),te.length<2)return"";for(;te.length%4!==0;)te=te+"=";return te}function de(te){return te.trim?te.trim():te.replace(/^\s+|\s+$/g,"")}function ae(te){return te<16?"0"+te.toString(16):te.toString(16)}function ie(te,J){J=J||Infinity;for(var X,$=te.length,ge=null,fe=[],Te=0;Te<$;++Te){if(X=te.charCodeAt(Te),X>55295&&X<57344){if(!ge){if(X>56319){(J-=3)>-1&&fe.push(239,191,189);continue}else if(Te+1===$){(J-=3)>-1&&fe.push(239,191,189);continue}ge=X;continue}if(X<56320){(J-=3)>-1&&fe.push(239,191,189),ge=X;continue}X=(ge-55296<<10|X-56320)+65536}else ge&&((J-=3)>-1&&fe.push(239,191,189));if(ge=null,X<128){if((J-=1)<0)break;fe.push(X)}else if(X<2048){if((J-=2)<0)break;fe.push(X>>6|192,X&63|128)}else if(X<65536){if((J-=3)<0)break;fe.push(X>>12|224,X>>6&63|128,X&63|128)}else if(X<1114112){if((J-=4)<0)break;fe.push(X>>18|240,X>>12&63|128,X>>6&63|128,X&63|128)}else throw new Error("Invalid code point")}return fe}function q(te){for(var J=[],X=0;X<te.length;++X)J.push(te.charCodeAt(X)&255);return J}function ue(te,J){for(var X,$,ge,fe=[],Te=0;Te<te.length&&!((J-=2)<0);++Te)X=te.charCodeAt(Te),$=X>>8,ge=X%256,fe.push(ge),fe.push($);return fe}function Z(te){return C.toByteArray(me(te))}function ee(te,J,X,$){for(var ge=0;ge<$&&!(ge+X>=J.length||ge>=te.length);++ge)J[ge+X]=te[ge];return ge}function Ee(te){return te!==te}}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{},F("buffer").Buffer)},{"base64-js":69,buffer:73,ieee754:195,isarray:198}],74:[function(F,Q,j){Q.exports={"100":"Continue","101":"Switching Protocols","102":"Processing","200":"OK","201":"Created","202":"Accepted","203":"Non-Authoritative Information","204":"No Content","205":"Reset Content","206":"Partial Content","207":"Multi-Status","208":"Already Reported","226":"IM Used","300":"Multiple Choices","301":"Moved Permanently","302":"Found","303":"See Other","304":"Not Modified","305":"Use Proxy","307":"Temporary Redirect","308":"Permanent Redirect","400":"Bad Request","401":"Unauthorized","402":"Payment Required","403":"Forbidden","404":"Not Found","405":"Method Not Allowed","406":"Not Acceptable","407":"Proxy Authentication Required","408":"Request Timeout","409":"Conflict","410":"Gone","411":"Length Required","412":"Precondition Failed","413":"Payload Too Large","414":"URI Too Long","415":"Unsupported Media Type","416":"Range Not Satisfiable","417":"Expectation Failed","418":"I'm a teapot","421":"Misdirected Request","422":"Unprocessable Entity","423":"Locked","424":"Failed Dependency","425":"Unordered Collection","426":"Upgrade Required","428":"Precondition Required","429":"Too Many Requests","431":"Request Header Fields Too Large","451":"Unavailable For Legal Reasons","500":"Internal Server Error","501":"Not Implemented","502":"Bad Gateway","503":"Service Unavailable","504":"Gateway Timeout","505":"HTTP Version Not Supported","506":"Variant Also Negotiates","507":"Insufficient Storage","508":"Loop Detected","509":"Bandwidth Limit Exceeded","510":"Not Extended","511":"Network Authentication Required"}},{}],75:[function(F,Q,j){Q.exports={O_RDONLY:0,O_WRONLY:1,O_RDWR:2,S_IFMT:61440,S_IFREG:32768,S_IFDIR:16384,S_IFCHR:8192,S_IFBLK:24576,S_IFIFO:4096,S_IFLNK:40960,S_IFSOCK:49152,O_CREAT:512,O_EXCL:2048,O_NOCTTY:131072,O_TRUNC:1024,O_APPEND:8,O_DIRECTORY:1048576,O_NOFOLLOW:256,O_SYNC:128,O_SYMLINK:2097152,O_NONBLOCK:4,S_IRWXU:448,S_IRUSR:256,S_IWUSR:128,S_IXUSR:64,S_IRWXG:56,S_IRGRP:32,S_IWGRP:16,S_IXGRP:8,S_IRWXO:7,S_IROTH:4,S_IWOTH:2,S_IXOTH:1,E2BIG:7,EACCES:13,EADDRINUSE:48,EADDRNOTAVAIL:49,EAFNOSUPPORT:47,EAGAIN:35,EALREADY:37,EBADF:9,EBADMSG:94,EBUSY:16,ECANCELED:89,ECHILD:10,ECONNABORTED:53,ECONNREFUSED:61,ECONNRESET:54,EDEADLK:11,EDESTADDRREQ:39,EDOM:33,EDQUOT:69,EEXIST:17,EFAULT:14,EFBIG:27,EHOSTUNREACH:65,EIDRM:90,EILSEQ:92,EINPROGRESS:36,EINTR:4,EINVAL:22,EIO:5,EISCONN:56,EISDIR:21,ELOOP:62,EMFILE:24,EMLINK:31,EMSGSIZE:40,EMULTIHOP:95,ENAMETOOLONG:63,ENETDOWN:50,ENETRESET:52,ENETUNREACH:51,ENFILE:23,ENOBUFS:55,ENODATA:96,ENODEV:19,ENOENT:2,ENOEXEC:8,ENOLCK:77,ENOLINK:97,ENOMEM:12,ENOMSG:91,ENOPROTOOPT:42,ENOSPC:28,ENOSR:98,ENOSTR:99,ENOSYS:78,ENOTCONN:57,ENOTDIR:20,ENOTEMPTY:66,ENOTSOCK:38,ENOTSUP:45,ENOTTY:25,ENXIO:6,EOPNOTSUPP:102,EOVERFLOW:84,EPERM:1,EPIPE:32,EPROTO:100,EPROTONOSUPPORT:43,EPROTOTYPE:41,ERANGE:34,EROFS:30,ESPIPE:29,ESRCH:3,ESTALE:70,ETIME:101,ETIMEDOUT:60,ETXTBSY:26,EWOULDBLOCK:35,EXDEV:18,SIGHUP:1,SIGINT:2,SIGQUIT:3,SIGILL:4,SIGTRAP:5,SIGABRT:6,SIGIOT:6,SIGBUS:10,SIGFPE:8,SIGKILL:9,SIGUSR1:30,SIGSEGV:11,SIGUSR2:31,SIGPIPE:13,SIGALRM:14,SIGTERM:15,SIGCHLD:20,SIGCONT:19,SIGSTOP:17,SIGTSTP:18,SIGTTIN:21,SIGTTOU:22,SIGURG:16,SIGXCPU:24,SIGXFSZ:25,SIGVTALRM:26,SIGPROF:27,SIGWINCH:28,SIGIO:23,SIGSYS:12,SSL_OP_ALL:2147486719,SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION:262144,SSL_OP_CIPHER_SERVER_PREFERENCE:4194304,SSL_OP_CISCO_ANYCONNECT:32768,SSL_OP_COOKIE_EXCHANGE:8192,SSL_OP_CRYPTOPRO_TLSEXT_BUG:2147483648,SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS:2048,SSL_OP_EPHEMERAL_RSA:0,SSL_OP_LEGACY_SERVER_CONNECT:4,SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER:32,SSL_OP_MICROSOFT_SESS_ID_BUG:1,SSL_OP_MSIE_SSLV2_RSA_PADDING:0,SSL_OP_NETSCAPE_CA_DN_BUG:536870912,SSL_OP_NETSCAPE_CHALLENGE_BUG:2,SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG:1073741824,SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG:8,SSL_OP_NO_COMPRESSION:131072,SSL_OP_NO_QUERY_MTU:4096,SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION:65536,SSL_OP_NO_SSLv2:16777216,SSL_OP_NO_SSLv3:33554432,SSL_OP_NO_TICKET:16384,SSL_OP_NO_TLSv1:67108864,SSL_OP_NO_TLSv1_1:268435456,SSL_OP_NO_TLSv1_2:134217728,SSL_OP_PKCS1_CHECK_1:0,SSL_OP_PKCS1_CHECK_2:0,SSL_OP_SINGLE_DH_USE:1048576,SSL_OP_SINGLE_ECDH_USE:524288,SSL_OP_SSLEAY_080_CLIENT_DH_BUG:128,SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG:0,SSL_OP_TLS_BLOCK_PADDING_BUG:512,SSL_OP_TLS_D5_BUG:256,SSL_OP_TLS_ROLLBACK_BUG:8388608,ENGINE_METHOD_DSA:2,ENGINE_METHOD_DH:4,ENGINE_METHOD_RAND:8,ENGINE_METHOD_ECDH:16,ENGINE_METHOD_ECDSA:32,ENGINE_METHOD_CIPHERS:64,ENGINE_METHOD_DIGESTS:128,ENGINE_METHOD_STORE:256,ENGINE_METHOD_PKEY_METHS:512,ENGINE_METHOD_PKEY_ASN1_METHS:1024,ENGINE_METHOD_ALL:65535,ENGINE_METHOD_NONE:0,DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6,F_OK:0,R_OK:4,W_OK:2,X_OK:1,UV_UDP_REUSEADDR:4}},{}],76:[function(F,Q,j){/*!
* copy-to - index.js
* Copyright(c) 2014 dead_horse <dead_horse@qq.com>
* MIT Licensed
*/"use strict";var N=Array.prototype.slice;Q.exports=v;function v(M,m){if(!(this instanceof v))return new v(M,m);this.src=M,this._withAccess=m}v.prototype.withAccess=function(M){return this._withAccess=M!==!1,this},v.prototype.pick=function(M){return Array.isArray(M)||(M=N.call(arguments)),M.length&&(this.keys=M),this},v.prototype.to=function(M){if(M=M||{},!this.src)return M;var m=this.keys||Object.keys(this.src);if(!this._withAccess){for(var y=0;y<m.length;y++){if(w=m[y],M[w]!==void 0)continue;M[w]=this.src[w]}return M}for(var y=0;y<m.length;y++){var w=m[y];if(!C(M,w))continue;var b=this.src.__lookupGetter__(w),p=this.src.__lookupSetter__(w);b&&M.__defineGetter__(w,b),p&&M.__defineSetter__(w,p),!b&&!p&&(M[w]=this.src[w])}return M},v.prototype.toCover=function(M){for(var m=this.keys||Object.keys(this.src),y=0;y<m.length;y++){var w=m[y];delete M[w];var b=this.src.__lookupGetter__(w),p=this.src.__lookupSetter__(w);b&&M.__defineGetter__(w,b),p&&M.__defineSetter__(w,p),!b&&!p&&(M[w]=this.src[w])}},v.prototype.override=v.prototype.toCover,v.prototype.and=function(M){var m={};return this.to(m),this.src=M,this.to(m),this.src=m,this};function C(M,m){return M[m]===void 0&&M.__lookupGetter__(m)===void 0&&M.__lookupSetter__(m)===void 0}},{}],77:[function(F,Q,j){F("../../modules/es6.string.iterator"),F("../../modules/es6.array.from"),Q.exports=F("../../modules/_core").Array.from},{"../../modules/_core":99,"../../modules/es6.array.from":168,"../../modules/es6.string.iterator":180}],78:[function(F,Q,j){var N=F("../../modules/_core"),v=N.JSON||(N.JSON={stringify:JSON.stringify});Q.exports=function(M){return v.stringify.apply(v,arguments)}},{"../../modules/_core":99}],79:[function(F,Q,j){F("../../modules/es6.object.assign"),Q.exports=F("../../modules/_core").Object.assign},{"../../modules/_core":99,"../../modules/es6.object.assign":171}],80:[function(F,Q,j){F("../../modules/es6.object.create");var N=F("../../modules/_core").Object;Q.exports=function(C,M){return N.create(C,M)}},{"../../modules/_core":99,"../../modules/es6.object.create":172}],81:[function(F,Q,j){F("../../modules/es6.object.define-property");var N=F("../../modules/_core").Object;Q.exports=function(C,M,m){return N.defineProperty(C,M,m)}},{"../../modules/_core":99,"../../modules/es6.object.define-property":173}],82:[function(F,Q,j){F("../../modules/es7.object.entries"),Q.exports=F("../../modules/_core").Object.entries},{"../../modules/_core":99,"../../modules/es7.object.entries":182}],83:[function(F,Q,j){F("../../modules/es6.object.get-own-property-names");var N=F("../../modules/_core").Object;Q.exports=function(C){return N.getOwnPropertyNames(C)}},{"../../modules/_core":99,"../../modules/es6.object.get-own-property-names":174}],84:[function(F,Q,j){F("../../modules/es6.object.get-prototype-of"),Q.exports=F("../../modules/_core").Object.getPrototypeOf},{"../../modules/_core":99,"../../modules/es6.object.get-prototype-of":175}],85:[function(F,Q,j){F("../../modules/es6.object.keys"),Q.exports=F("../../modules/_core").Object.keys},{"../../modules/_core":99,"../../modules/es6.object.keys":176}],86:[function(F,Q,j){F("../modules/es6.object.to-string"),F("../modules/es6.string.iterator"),F("../modules/web.dom.iterable"),F("../modules/es6.promise"),F("../modules/es7.promise.finally"),F("../modules/es7.promise.try"),Q.exports=F("../modules/_core").Promise},{"../modules/_core":99,"../modules/es6.object.to-string":177,"../modules/es6.promise":178,"../modules/es6.string.iterator":180,"../modules/es7.promise.finally":183,"../modules/es7.promise.try":184,"../modules/web.dom.iterable":187}],87:[function(F,Q,j){F("../modules/web.immediate"),Q.exports=F("../modules/_core").setImmediate},{"../modules/_core":99,"../modules/web.immediate":188}],88:[function(F,Q,j){F("../../modules/es6.string.from-code-point"),Q.exports=F("../../modules/_core").String.fromCodePoint},{"../../modules/_core":99,"../../modules/es6.string.from-code-point":179}],89:[function(F,Q,j){F("../../modules/es6.function.has-instance"),Q.exports=F("../../modules/_wks-ext").f("hasInstance")},{"../../modules/_wks-ext":165,"../../modules/es6.function.has-instance":170}],90:[function(F,Q,j){F("../../modules/es6.symbol"),F("../../modules/es6.object.to-string"),F("../../modules/es7.symbol.async-iterator"),F("../../modules/es7.symbol.observable"),Q.exports=F("../../modules/_core").Symbol},{"../../modules/_core":99,"../../modules/es6.object.to-string":177,"../../modules/es6.symbol":181,"../../modules/es7.symbol.async-iterator":185,"../../modules/es7.symbol.observable":186}],91:[function(F,Q,j){F("../../modules/es6.string.iterator"),F("../../modules/web.dom.iterable"),Q.exports=F("../../modules/_wks-ext").f("iterator")},{"../../modules/_wks-ext":165,"../../modules/es6.string.iterator":180,"../../modules/web.dom.iterable":187}],92:[function(F,Q,j){Q.exports=function(N){if(typeof N!="function")throw TypeError(N+" is not a function!");return N}},{}],93:[function(F,Q,j){Q.exports=function(){}},{}],94:[function(F,Q,j){Q.exports=function(N,v,C,M){if(!(N instanceof v)||M!==void 0&&M in N)throw TypeError(C+": incorrect invocation!");return N}},{}],95:[function(F,Q,j){var N=F("./_is-object");Q.exports=function(v){if(!N(v))throw TypeError(v+" is not an object!");return v}},{"./_is-object":119}],96:[function(F,Q,j){var N=F("./_to-iobject"),v=F("./_to-length"),C=F("./_to-absolute-index");Q.exports=function(M){return function(m,y,w){var b=N(m),p=v(b.length),d=C(w,p),n;if(M&&y!=y){for(;p>d;)if(n=b[d++],n!=n)return!0}else for(;p>d;d++)if((M||d in b)&&b[d]===y)return M||d||0;return!M&&-1}}},{"./_to-absolute-index":156,"./_to-iobject":158,"./_to-length":159}],97:[function(F,Q,j){var N=F("./_cof"),v=F("./_wks")("toStringTag"),C=N(function(){return arguments}())=="Arguments",M=function(m,y){try{return m[y]}catch(w){}};Q.exports=function(m){var y,w,b;return m===void 0?"Undefined":m===null?"Null":typeof(w=M(y=Object(m),v))=="string"?w:C?N(y):(b=N(y))=="Object"&&typeof y.callee=="function"?"Arguments":b}},{"./_cof":98,"./_wks":166}],98:[function(F,Q,j){var N={}.toString;Q.exports=function(v){return N.call(v).slice(8,-1)}},{}],99:[function(F,Q,j){var N=Q.exports={version:"2.6.11"};typeof __e=="number"&&(__e=N)},{}],100:[function(F,Q,j){"use strict";var N=F("./_object-dp"),v=F("./_property-desc");Q.exports=function(C,M,m){M in C?N.f(C,M,v(0,m)):C[M]=m}},{"./_object-dp":132,"./_property-desc":146}],101:[function(F,Q,j){var N=F("./_a-function");Q.exports=function(v,C,M){if(N(v),C===void 0)return v;switch(M){case 1:return function(m){return v.call(C,m)};case 2:return function(m,y){return v.call(C,m,y)};case 3:return function(m,y,w){return v.call(C,m,y,w)}}return function(){return v.apply(C,arguments)}}},{"./_a-function":92}],102:[function(F,Q,j){Q.exports=function(N){if(N==null)throw TypeError("Can't call method on "+N);return N}},{}],103:[function(F,Q,j){Q.exports=!F("./_fails")(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})},{"./_fails":108}],104:[function(F,Q,j){var N=F("./_is-object"),v=F("./_global").document,C=N(v)&&N(v.createElement);Q.exports=function(M){return C?v.createElement(M):{}}},{"./_global":110,"./_is-object":119}],105:[function(F,Q,j){Q.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},{}],106:[function(F,Q,j){var N=F("./_object-keys"),v=F("./_object-gops"),C=F("./_object-pie");Q.exports=function(M){var m=N(M),y=v.f;if(y)for(var w=y(M),b=C.f,p=0,d;w.length>p;)b.call(M,d=w[p++])&&m.push(d);return m}},{"./_object-gops":137,"./_object-keys":140,"./_object-pie":141}],107:[function(F,Q,j){var N=F("./_global"),v=F("./_core"),C=F("./_ctx"),M=F("./_hide"),m=F("./_has"),y="prototype",w=function(b,p,d){var n=b&w.F,c=b&w.G,r=b&w.S,i=b&w.P,o=b&w.B,u=b&w.W,f=c?v:v[p]||(v[p]={}),s=f[y],l=c?N:r?N[p]:(N[p]||{})[y],t,S,x;c&&(d=p);for(t in d){if(S=!n&&l&&l[t]!==void 0,S&&m(f,t))continue;x=S?l[t]:d[t],f[t]=c&&typeof l[t]!="function"?d[t]:o&&S?C(x,N):u&&l[t]==x?function(h){var R=function(O,g,_){if(this instanceof h){switch(arguments.length){case 0:return new h;case 1:return new h(O);case 2:return new h(O,g)}return new h(O,g,_)}return h.apply(this,arguments)};return R[y]=h[y],R}(x):i&&typeof x=="function"?C(Function.call,x):x,i&&((f.virtual||(f.virtual={}))[t]=x,b&w.R&&s&&!s[t]&&M(s,t,x))}};w.F=1,w.G=2,w.S=4,w.P=8,w.B=16,w.W=32,w.U=64,w.R=128,Q.exports=w},{"./_core":99,"./_ctx":101,"./_global":110,"./_has":111,"./_hide":112}],108:[function(F,Q,j){Q.exports=function(N){try{return!!N()}catch(v){return!0}}},{}],109:[function(F,Q,j){var N=F("./_ctx"),v=F("./_iter-call"),C=F("./_is-array-iter"),M=F("./_an-object"),m=F("./_to-length"),y=F("./core.get-iterator-method"),w={},b={},j=Q.exports=function(p,d,n,c,r){var i=r?function(){return p}:y(p),o=N(n,c,d?2:1),u=0,f,s,l,t;if(typeof i!="function")throw TypeError(p+" is not iterable!");if(C(i)){for(f=m(p.length);f>u;u++)if(t=d?o(M(s=p[u])[0],s[1]):o(p[u]),t===w||t===b)return t}else for(l=i.call(p);!(s=l.next()).done;)if(t=v(l,o,s.value,d),t===w||t===b)return t};j.BREAK=w,j.RETURN=b},{"./_an-object":95,"./_ctx":101,"./_is-array-iter":117,"./_iter-call":120,"./_to-length":159,"./core.get-iterator-method":167}],110:[function(F,Q,j){var N=Q.exports=typeof window!="undefined"&&window.Math==Math?window:typeof self!="undefined"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=N)},{}],111:[function(F,Q,j){var N={}.hasOwnProperty;Q.exports=function(v,C){return N.call(v,C)}},{}],112:[function(F,Q,j){var N=F("./_object-dp"),v=F("./_property-desc");Q.exports=F("./_descriptors")?function(C,M,m){return N.f(C,M,v(1,m))}:function(C,M,m){return C[M]=m,C}},{"./_descriptors":103,"./_object-dp":132,"./_property-desc":146}],113:[function(F,Q,j){var N=F("./_global").document;Q.exports=N&&N.documentElement},{"./_global":110}],114:[function(F,Q,j){Q.exports=!F("./_descriptors")&&!F("./_fails")(function(){return Object.defineProperty(F("./_dom-create")("div"),"a",{get:function(){return 7}}).a!=7})},{"./_descriptors":103,"./_dom-create":104,"./_fails":108}],115:[function(F,Q,j){Q.exports=function(N,v,C){var M=C===void 0;switch(v.length){case 0:return M?N():N.call(C);case 1:return M?N(v[0]):N.call(C,v[0]);case 2:return M?N(v[0],v[1]):N.call(C,v[0],v[1]);case 3:return M?N(v[0],v[1],v[2]):N.call(C,v[0],v[1],v[2]);case 4:return M?N(v[0],v[1],v[2],v[3]):N.call(C,v[0],v[1],v[2],v[3])}return N.apply(C,v)}},{}],116:[function(F,Q,j){var N=F("./_cof");Q.exports=Object("z").propertyIsEnumerable(0)?Object:function(v){return N(v)=="String"?v.split(""):Object(v)}},{"./_cof":98}],117:[function(F,Q,j){var N=F("./_iterators"),v=F("./_wks")("iterator"),C=Array.prototype;Q.exports=function(M){return M!==void 0&&(N.Array===M||C[v]===M)}},{"./_iterators":125,"./_wks":166}],118:[function(F,Q,j){var N=F("./_cof");Q.exports=Array.isArray||function(C){return N(C)=="Array"}},{"./_cof":98}],119:[function(F,Q,j){Q.exports=function(N){return typeof N=="object"?N!==null:typeof N=="function"}},{}],120:[function(F,Q,j){var N=F("./_an-object");Q.exports=function(v,C,M,m){try{return m?C(N(M)[0],M[1]):C(M)}catch(w){var y=v.return;throw y!==void 0&&N(y.call(v)),w}}},{"./_an-object":95}],121:[function(F,Q,j){"use strict";var N=F("./_object-create"),v=F("./_property-desc"),C=F("./_set-to-string-tag"),M={};F("./_hide")(M,F("./_wks")("iterator"),function(){return this}),Q.exports=function(m,y,w){m.prototype=N(M,{next:v(1,w)}),C(m,y+" Iterator")}},{"./_hide":112,"./_object-create":131,"./_property-desc":146,"./_set-to-string-tag":150,"./_wks":166}],122:[function(F,Q,j){"use strict";var N=F("./_library"),v=F("./_export"),C=F("./_redefine"),M=F("./_hide"),m=F("./_iterators"),y=F("./_iter-create"),w=F("./_set-to-string-tag"),b=F("./_object-gpo"),p=F("./_wks")("iterator"),d=!([].keys&&"next"in[].keys()),n="@@iterator",c="keys",r="values",i=function(){return this};Q.exports=function(o,u,f,s,l,t,S){y(f,u,s);var x=function(W){if(!d&&W in g)return g[W];switch(W){case c:return function(){return new f(this,W)};case r:return function(){return new f(this,W)}}return function(){return new f(this,W)}},h=u+" Iterator",R=l==r,O=!1,g=o.prototype,_=g[p]||g[n]||l&&g[l],E=_||x(l),T=l?R?x("entries"):E:void 0,L=u=="Array"&&g.entries||_,I,P,G;if(L&&(G=b(L.call(new o)),G!==Object.prototype&&G.next&&(w(G,h,!0),!N&&typeof G[p]!="function"&&M(G,p,i))),R&&_&&_.name!==r&&(O=!0,E=function(){return _.call(this)}),(!N||S)&&(d||O||!g[p])&&M(g,p,E),m[u]=E,m[h]=i,l)if(I={values:R?E:x(r),keys:t?E:x(c),entries:T},S)for(P in I)P in g||C(g,P,I[P]);else v(v.P+v.F*(d||O),u,I);return I}},{"./_export":107,"./_hide":112,"./_iter-create":121,"./_iterators":125,"./_library":126,"./_object-gpo":138,"./_redefine":148,"./_set-to-string-tag":150,"./_wks":166}],123:[function(F,Q,j){var N=F("./_wks")("iterator"),v=!1;try{var C=[7][N]();C.return=function(){v=!0},Array.from(C,function(){throw 2})}catch(M){}Q.exports=function(M,m){if(!m&&!v)return!1;var y=!1;try{var w=[7],b=w[N]();b.next=function(){return{done:y=!0}},w[N]=function(){return b},M(w)}catch(p){}return y}},{"./_wks":166}],124:[function(F,Q,j){Q.exports=function(N,v){return{value:v,done:!!N}}},{}],125:[function(F,Q,j){Q.exports={}},{}],126:[function(F,Q,j){Q.exports=!0},{}],127:[function(F,Q,j){var N=F("./_uid")("meta"),v=F("./_is-object"),C=F("./_has"),M=F("./_object-dp").f,m=0,y=Object.isExtensible||function(){return!0},w=!F("./_fails")(function(){return y(Object.preventExtensions({}))}),b=function(r){M(r,N,{value:{i:"O"+ ++m,w:{}}})},p=function(r,i){if(!v(r))return typeof r=="symbol"?r:(typeof r=="string"?"S":"P")+r;if(!C(r,N)){if(!y(r))return"F";if(!i)return"E";b(r)}return r[N].i},d=function(r,i){if(!C(r,N)){if(!y(r))return!0;if(!i)return!1;b(r)}return r[N].w},n=function(r){return w&&c.NEED&&y(r)&&!C(r,N)&&b(r),r},c=Q.exports={KEY:N,NEED:!1,fastKey:p,getWeak:d,onFreeze:n}},{"./_fails":108,"./_has":111,"./_is-object":119,"./_object-dp":132,"./_uid":162}],128:[function(F,Q,j){var N=F("./_global"),v=F("./_task").set,C=N.MutationObserver||N.WebKitMutationObserver,M=N.process,m=N.Promise,y=F("./_cof")(M)=="process";Q.exports=function(){var w,b,p,d=function(){var i,o;for(y&&(i=M.domain)&&i.exit();w;){o=w.fn,w=w.next;try{o()}catch(u){throw w?p():b=void 0,u}}b=void 0,i&&i.enter()};if(y)p=function(){M.nextTick(d)};else if(C&&!(N.navigator&&N.navigator.standalone)){var n=!0,c=document.createTextNode("");new C(d).observe(c,{characterData:!0}),p=function(){c.data=n=!n}}else if(m&&m.resolve){var r=m.resolve(void 0);p=function(){r.then(d)}}else p=function(){v.call(N,d)};return function(i){var o={fn:i,next:void 0};b&&(b.next=o),w||(w=o,p()),b=o}}},{"./_cof":98,"./_global":110,"./_task":155}],129:[function(F,Q,j){"use strict";var N=F("./_a-function");function v(C){var M,m;this.promise=new C(function(y,w){if(M!==void 0||m!==void 0)throw TypeError("Bad Promise constructor");M=y,m=w}),this.resolve=N(M),this.reject=N(m)}Q.exports.f=function(C){return new v(C)}},{"./_a-function":92}],130:[function(F,Q,j){"use strict";var N=F("./_descriptors"),v=F("./_object-keys"),C=F("./_object-gops"),M=F("./_object-pie"),m=F("./_to-object"),y=F("./_iobject"),w=Object.assign;Q.exports=!w||F("./_fails")(function(){var b={},p={},d=Symbol(),n="abcdefghijklmnopqrst";return b[d]=7,n.split("").forEach(function(c){p[c]=c}),w({},b)[d]!=7||Object.keys(w({},p)).join("")!=n})?function(p,d){for(var n=m(p),c=arguments.length,r=1,i=C.f,o=M.f;c>r;)for(var u=y(arguments[r++]),f=i?v(u).concat(i(u)):v(u),s=f.length,l=0,t;s>l;)t=f[l++],(!N||o.call(u,t))&&(n[t]=u[t]);return n}:w},{"./_descriptors":103,"./_fails":108,"./_iobject":116,"./_object-gops":137,"./_object-keys":140,"./_object-pie":141,"./_to-object":160}],131:[function(F,Q,j){var N=F("./_an-object"),v=F("./_object-dps"),C=F("./_enum-bug-keys"),M=F("./_shared-key")("IE_PROTO"),m=function(){},y="prototype",w=function(){var b=F("./_dom-create")("iframe"),p=C.length,d="<",n=">",c;for(b.style.display="none",F("./_html").appendChild(b),b.src="javascript:",c=b.contentWindow.document,c.open(),c.write(d+"script"+n+"document.F=Object"+d+"/script"+n),c.close(),w=c.F;p--;)delete w[y][C[p]];return w()};Q.exports=Object.create||function(p,d){var n;return p!==null?(m[y]=N(p),n=new m,m[y]=null,n[M]=p):n=w(),d===void 0?n:v(n,d)}},{"./_an-object":95,"./_dom-create":104,"./_enum-bug-keys":105,"./_html":113,"./_object-dps":133,"./_shared-key":151}],132:[function(F,Q,j){var N=F("./_an-object"),v=F("./_ie8-dom-define"),C=F("./_to-primitive"),M=Object.defineProperty;j.f=F("./_descriptors")?Object.defineProperty:function(y,w,b){if(N(y),w=C(w,!0),N(b),v)try{return M(y,w,b)}catch(p){}if("get"in b||"set"in b)throw TypeError("Accessors not supported!");return"value"in b&&(y[w]=b.value),y}},{"./_an-object":95,"./_descriptors":103,"./_ie8-dom-define":114,"./_to-primitive":161}],133:[function(F,Q,j){var N=F("./_object-dp"),v=F("./_an-object"),C=F("./_object-keys");Q.exports=F("./_descriptors")?Object.defineProperties:function(m,y){v(m);for(var w=C(y),b=w.length,p=0,d;b>p;)N.f(m,d=w[p++],y[d]);return m}},{"./_an-object":95,"./_descriptors":103,"./_object-dp":132,"./_object-keys":140}],134:[function(F,Q,j){var N=F("./_object-pie"),v=F("./_property-desc"),C=F("./_to-iobject"),M=F("./_to-primitive"),m=F("./_has"),y=F("./_ie8-dom-define"),w=Object.getOwnPropertyDescriptor;j.f=F("./_descriptors")?w:function(p,d){if(p=C(p),d=M(d,!0),y)try{return w(p,d)}catch(n){}if(m(p,d))return v(!N.f.call(p,d),p[d])}},{"./_descriptors":103,"./_has":111,"./_ie8-dom-define":114,"./_object-pie":141,"./_property-desc":146,"./_to-iobject":158,"./_to-primitive":161}],135:[function(F,Q,j){var N=F("./_to-iobject"),v=F("./_object-gopn").f,C={}.toString,M=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],m=function(y){try{return v(y)}catch(w){return M.slice()}};Q.exports.f=function(w){return M&&C.call(w)=="[object Window]"?m(w):v(N(w))}},{"./_object-gopn":136,"./_to-iobject":158}],136:[function(F,Q,j){var N=F("./_object-keys-internal"),v=F("./_enum-bug-keys").concat("length","prototype");j.f=Object.getOwnPropertyNames||function(M){return N(M,v)}},{"./_enum-bug-keys":105,"./_object-keys-internal":139}],137:[function(F,Q,j){j.f=Object.getOwnPropertySymbols},{}],138:[function(F,Q,j){var N=F("./_has"),v=F("./_to-object"),C=F("./_shared-key")("IE_PROTO"),M=Object.prototype;Q.exports=Object.getPrototypeOf||function(m){return m=v(m),N(m,C)?m[C]:typeof m.constructor=="function"&&m instanceof m.constructor?m.constructor.prototype:m instanceof Object?M:null}},{"./_has":111,"./_shared-key":151,"./_to-object":160}],139:[function(F,Q,j){var N=F("./_has"),v=F("./_to-iobject"),C=F("./_array-includes")(!1),M=F("./_shared-key")("IE_PROTO");Q.exports=function(m,y){var w=v(m),b=0,p=[],d;for(d in w)d!=M&&(N(w,d)&&p.push(d));for(;y.length>b;)N(w,d=y[b++])&&(~C(p,d)||p.push(d));return p}},{"./_array-includes":96,"./_has":111,"./_shared-key":151,"./_to-iobject":158}],140:[function(F,Q,j){var N=F("./_object-keys-internal"),v=F("./_enum-bug-keys");Q.exports=Object.keys||function(M){return N(M,v)}},{"./_enum-bug-keys":105,"./_object-keys-internal":139}],141:[function(F,Q,j){j.f={}.propertyIsEnumerable},{}],142:[function(F,Q,j){var N=F("./_export"),v=F("./_core"),C=F("./_fails");Q.exports=function(M,m){var y=(v.Object||{})[M]||Object[M],w={};w[M]=m(y),N(N.S+N.F*C(function(){y(1)}),"Object",w)}},{"./_core":99,"./_export":107,"./_fails":108}],143:[function(F,Q,j){var N=F("./_descriptors"),v=F("./_object-keys"),C=F("./_to-iobject"),M=F("./_object-pie").f;Q.exports=function(m){return function(y){for(var w=C(y),b=v(w),p=b.length,d=0,n=[],c;p>d;)c=b[d++],(!N||M.call(w,c))&&n.push(m?[c,w[c]]:w[c]);return n}}},{"./_descriptors":103,"./_object-keys":140,"./_object-pie":141,"./_to-iobject":158}],144:[function(F,Q,j){Q.exports=function(N){try{return{e:!1,v:N()}}catch(v){return{e:!0,v}}}},{}],145:[function(F,Q,j){var N=F("./_an-object"),v=F("./_is-object"),C=F("./_new-promise-capability");Q.exports=function(M,m){if(N(M),v(m)&&m.constructor===M)return m;var y=C.f(M),w=y.resolve;return w(m),y.promise}},{"./_an-object":95,"./_is-object":119,"./_new-promise-capability":129}],146:[function(F,Q,j){Q.exports=function(N,v){return{enumerable:!(N&1),configurable:!(N&2),writable:!(N&4),value:v}}},{}],147:[function(F,Q,j){var N=F("./_hide");Q.exports=function(v,C,M){for(var m in C)M&&v[m]?v[m]=C[m]:N(v,m,C[m]);return v}},{"./_hide":112}],148:[function(F,Q,j){Q.exports=F("./_hide")},{"./_hide":112}],149:[function(F,Q,j){"use strict";var N=F("./_global"),v=F("./_core"),C=F("./_object-dp"),M=F("./_descriptors"),m=F("./_wks")("species");Q.exports=function(y){var w=typeof v[y]=="function"?v[y]:N[y];M&&w&&!w[m]&&C.f(w,m,{configurable:!0,get:function(){return this}})}},{"./_core":99,"./_descriptors":103,"./_global":110,"./_object-dp":132,"./_wks":166}],150:[function(F,Q,j){var N=F("./_object-dp").f,v=F("./_has"),C=F("./_wks")("toStringTag");Q.exports=function(M,m,y){M&&!v(M=y?M:M.prototype,C)&&N(M,C,{configurable:!0,value:m})}},{"./_has":111,"./_object-dp":132,"./_wks":166}],151:[function(F,Q,j){var N=F("./_shared")("keys"),v=F("./_uid");Q.exports=function(C){return N[C]||(N[C]=v(C))}},{"./_shared":152,"./_uid":162}],152:[function(F,Q,j){var N=F("./_core"),v=F("./_global"),C="__core-js_shared__",M=v[C]||(v[C]={});(Q.exports=function(m,y){return M[m]||(M[m]=y!==void 0?y:{})})("versions",[]).push({version:N.version,mode:F("./_library")?"pure":"global",copyright:"\xA9 2019 Denis Pushkarev (zloirock.ru)"})},{"./_core":99,"./_global":110,"./_library":126}],153:[function(F,Q,j){var N=F("./_an-object"),v=F("./_a-function"),C=F("./_wks")("species");Q.exports=function(M,m){var y=N(M).constructor,w;return y===void 0||(w=N(y)[C])==null?m:v(w)}},{"./_a-function":92,"./_an-object":95,"./_wks":166}],154:[function(F,Q,j){var N=F("./_to-integer"),v=F("./_defined");Q.exports=function(C){return function(M,m){var y=String(v(M)),w=N(m),b=y.length,p,d;return w<0||w>=b?C?"":void 0:(p=y.charCodeAt(w),p<55296||p>56319||w+1===b||(d=y.charCodeAt(w+1))<56320||d>57343?C?y.charAt(w):p:C?y.slice(w,w+2):(p-55296<<10)+(d-56320)+65536)}}},{"./_defined":102,"./_to-integer":157}],155:[function(F,Q,j){var N=F("./_ctx"),v=F("./_invoke"),C=F("./_html"),M=F("./_dom-create"),m=F("./_global"),y=m.process,w=m.setImmediate,b=m.clearImmediate,p=m.MessageChannel,d=m.Dispatch,n=0,c={},r="onreadystatechange",i,o,u,f=function(){var l=+this;if(c.hasOwnProperty(l)){var t=c[l];delete c[l],t()}},s=function(l){f.call(l.data)};(!w||!b)&&(w=function(t){for(var S=[],x=1;arguments.length>x;)S.push(arguments[x++]);return c[++n]=function(){v(typeof t=="function"?t:Function(t),S)},i(n),n},b=function(t){delete c[t]},F("./_cof")(y)=="process"?i=function(l){y.nextTick(N(f,l,1))}:d&&d.now?i=function(l){d.now(N(f,l,1))}:p?(o=new p,u=o.port2,o.port1.onmessage=s,i=N(u.postMessage,u,1)):m.addEventListener&&typeof postMessage=="function"&&!m.importScripts?(i=function(l){m.postMessage(l+"","*")},m.addEventListener("message",s,!1)):r in M("script")?i=function(l){C.appendChild(M("script"))[r]=function(){C.removeChild(this),f.call(l)}}:i=function(l){setTimeout(N(f,l,1),0)}),Q.exports={set:w,clear:b}},{"./_cof":98,"./_ctx":101,"./_dom-create":104,"./_global":110,"./_html":113,"./_invoke":115}],156:[function(F,Q,j){var N=F("./_to-integer"),v=Math.max,C=Math.min;Q.exports=function(M,m){return M=N(M),M<0?v(M+m,0):C(M,m)}},{"./_to-integer":157}],157:[function(F,Q,j){var N=Math.ceil,v=Math.floor;Q.exports=function(C){return isNaN(C=+C)?0:(C>0?v:N)(C)}},{}],158:[function(F,Q,j){var N=F("./_iobject"),v=F("./_defined");Q.exports=function(C){return N(v(C))}},{"./_defined":102,"./_iobject":116}],159:[function(F,Q,j){var N=F("./_to-integer"),v=Math.min;Q.exports=function(C){return C>0?v(N(C),9007199254740991):0}},{"./_to-integer":157}],160:[function(F,Q,j){var N=F("./_defined");Q.exports=function(v){return Object(N(v))}},{"./_defined":102}],161:[function(F,Q,j){var N=F("./_is-object");Q.exports=function(v,C){if(!N(v))return v;var M,m;if(C&&typeof(M=v.toString)=="function"&&!N(m=M.call(v)))return m;if(typeof(M=v.valueOf)=="function"&&!N(m=M.call(v)))return m;if(!C&&typeof(M=v.toString)=="function"&&!N(m=M.call(v)))return m;throw TypeError("Can't convert object to primitive value")}},{"./_is-object":119}],162:[function(F,Q,j){var N=0,v=Math.random();Q.exports=function(C){return"Symbol(".concat(C===void 0?"":C,")_",(++N+v).toString(36))}},{}],163:[function(F,Q,j){var N=F("./_global"),v=N.navigator;Q.exports=v&&v.userAgent||""},{"./_global":110}],164:[function(F,Q,j){var N=F("./_global"),v=F("./_core"),C=F("./_library"),M=F("./_wks-ext"),m=F("./_object-dp").f;Q.exports=function(y){var w=v.Symbol||(v.Symbol=C?{}:N.Symbol||{});y.charAt(0)!="_"&&!(y in w)&&m(w,y,{value:M.f(y)})}},{"./_core":99,"./_global":110,"./_library":126,"./_object-dp":132,"./_wks-ext":165}],165:[function(F,Q,j){j.f=F("./_wks")},{"./_wks":166}],166:[function(F,Q,j){var N=F("./_shared")("wks"),v=F("./_uid"),C=F("./_global").Symbol,M=typeof C=="function",m=Q.exports=function(y){return N[y]||(N[y]=M&&C[y]||(M?C:v)("Symbol."+y))};m.store=N},{"./_global":110,"./_shared":152,"./_uid":162}],167:[function(F,Q,j){var N=F("./_classof"),v=F("./_wks")("iterator"),C=F("./_iterators");Q.exports=F("./_core").getIteratorMethod=function(M){if(M!=null)return M[v]||M["@@iterator"]||C[N(M)]}},{"./_classof":97,"./_core":99,"./_iterators":125,"./_wks":166}],168:[function(F,Q,j){"use strict";var N=F("./_ctx"),v=F("./_export"),C=F("./_to-object"),M=F("./_iter-call"),m=F("./_is-array-iter"),y=F("./_to-length"),w=F("./_create-property"),b=F("./core.get-iterator-method");v(v.S+v.F*!F("./_iter-detect")(function(p){Array.from(p)}),"Array",{from:function(d){var n=C(d),c=typeof this=="function"?this:Array,r=arguments.length,i=r>1?arguments[1]:void 0,o=i!==void 0,u=0,f=b(n),s,l,t,S;if(o&&(i=N(i,r>2?arguments[2]:void 0,2)),f!=null&&!(c==Array&&m(f)))for(S=f.call(n),l=new c;!(t=S.next()).done;u++)w(l,u,o?M(S,i,[t.value,u],!0):t.value);else for(s=y(n.length),l=new c(s);s>u;u++)w(l,u,o?i(n[u],u):n[u]);return l.length=u,l}})},{"./_create-property":100,"./_ctx":101,"./_export":107,"./_is-array-iter":117,"./_iter-call":120,"./_iter-detect":123,"./_to-length":159,"./_to-object":160,"./core.get-iterator-method":167}],169:[function(F,Q,j){"use strict";var N=F("./_add-to-unscopables"),v=F("./_iter-step"),C=F("./_iterators"),M=F("./_to-iobject");Q.exports=F("./_iter-define")(Array,"Array",function(m,y){this._t=M(m),this._i=0,this._k=y},function(){var m=this._t,y=this._k,w=this._i++;return!m||w>=m.length?(this._t=void 0,v(1)):y=="keys"?v(0,w):y=="values"?v(0,m[w]):v(0,[w,m[w]])},"values"),C.Arguments=C.Array,N("keys"),N("values"),N("entries")},{"./_add-to-unscopables":93,"./_iter-define":122,"./_iter-step":124,"./_iterators":125,"./_to-iobject":158}],170:[function(F,Q,j){"use strict";var N=F("./_is-object"),v=F("./_object-gpo"),C=F("./_wks")("hasInstance"),M=Function.prototype;C in M||F("./_object-dp").f(M,C,{value:function(m){if(typeof this!="function"||!N(m))return!1;if(!N(this.prototype))return m instanceof this;for(;m=v(m);)if(this.prototype===m)return!0;return!1}})},{"./_is-object":119,"./_object-dp":132,"./_object-gpo":138,"./_wks":166}],171:[function(F,Q,j){var N=F("./_export");N(N.S+N.F,"Object",{assign:F("./_object-assign")})},{"./_export":107,"./_object-assign":130}],172:[function(F,Q,j){var N=F("./_export");N(N.S,"Object",{create:F("./_object-create")})},{"./_export":107,"./_object-create":131}],173:[function(F,Q,j){var N=F("./_export");N(N.S+N.F*!F("./_descriptors"),"Object",{defineProperty:F("./_object-dp").f})},{"./_descriptors":103,"./_export":107,"./_object-dp":132}],174:[function(F,Q,j){F("./_object-sap")("getOwnPropertyNames",function(){return F("./_object-gopn-ext").f})},{"./_object-gopn-ext":135,"./_object-sap":142}],175:[function(F,Q,j){var N=F("./_to-object"),v=F("./_object-gpo");F("./_object-sap")("getPrototypeOf",function(){return function(M){return v(N(M))}})},{"./_object-gpo":138,"./_object-sap":142,"./_to-object":160}],176:[function(F,Q,j){var N=F("./_to-object"),v=F("./_object-keys");F("./_object-sap")("keys",function(){return function(M){return v(N(M))}})},{"./_object-keys":140,"./_object-sap":142,"./_to-object":160}],177:[function(F,Q,j){arguments[4][71][0].apply(j,arguments)},{dup:71}],178:[function(F,Q,j){"use strict";var N=F("./_library"),v=F("./_global"),C=F("./_ctx"),M=F("./_classof"),m=F("./_export"),y=F("./_is-object"),w=F("./_a-function"),b=F("./_an-instance"),p=F("./_for-of"),d=F("./_species-constructor"),n=F("./_task").set,c=F("./_microtask")(),r=F("./_new-promise-capability"),i=F("./_perform"),o=F("./_user-agent"),u=F("./_promise-resolve"),f="Promise",s=v.TypeError,l=v.process,t=l&&l.versions,S=t&&t.v8||"",x=v[f],h=M(l)=="process",R=function(){},O,g,_,E,T=g=r.f,L=!!function(){try{var k=x.resolve(1),K=(k.constructor={})[F("./_wks")("species")]=function(Y){Y(R,R)};return(h||typeof PromiseRejectionEvent=="function")&&k.then(R)instanceof K&&S.indexOf("6.6")!==0&&o.indexOf("Chrome/66")===-1}catch(Y){}}(),I=function(k){var K;return y(k)&&typeof(K=k.then)=="function"?K:!1},P=function(k,K){if(k._n)return;k._n=!0;var Y=k._c;c(function(){for(var ne=k._v,oe=k._s==1,_e=0,xe=function(le){var me=oe?le.ok:le.fail,de=le.resolve,ae=le.reject,ie=le.domain,q,ue,Z;try{me?(oe||(k._h==2&&H(k),k._h=1),me===!0?q=ne:(ie&&ie.enter(),q=me(ne),ie&&(ie.exit(),Z=!0)),q===le.promise?ae(s("Promise-chain cycle")):(ue=I(q))?ue.call(q,de,ae):de(q)):ae(ne)}catch(ee){ie&&!Z&&ie.exit(),ae(ee)}};Y.length>_e;)xe(Y[_e++]);k._c=[],k._n=!1,K&&!k._h&&G(k)})},G=function(k){n.call(v,function(){var K=k._v,Y=W(k),ne,oe,_e;if(Y&&(ne=i(function(){h?l.emit("unhandledRejection",K,k):(oe=v.onunhandledrejection)?oe({promise:k,reason:K}):(_e=v.console)&&_e.error&&_e.error("Unhandled promise rejection",K)}),k._h=h||W(k)?2:1),k._a=void 0,Y&&ne.e)throw ne.v})},W=function(k){return k._h!==1&&(k._a||k._c).length===0},H=function(k){n.call(v,function(){var K;h?l.emit("rejectionHandled",k):(K=v.onrejectionhandled)&&K({promise:k,reason:k._v})})},z=function(k){var K=this;if(K._d)return;K._d=!0,K=K._w||K,K._v=k,K._s=2,K._a||(K._a=K._c.slice()),P(K,!0)},B=function(k){var K=this,Y;if(K._d)return;K._d=!0,K=K._w||K;try{if(K===k)throw s("Promise can't be resolved itself");(Y=I(k))?c(function(){var ne={_w:K,_d:!1};try{Y.call(k,C(B,ne,1),C(z,ne,1))}catch(oe){z.call(ne,oe)}}):(K._v=k,K._s=1,P(K,!1))}catch(ne){z.call({_w:K,_d:!1},ne)}};L||(x=function(K){b(this,x,f,"_h"),w(K),O.call(this);try{K(C(B,this,1),C(z,this,1))}catch(Y){z.call(this,Y)}},O=function(K){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},O.prototype=F("./_redefine-all")(x.prototype,{then:function(K,Y){var ne=T(d(this,x));return ne.ok=typeof K=="function"?K:!0,ne.fail=typeof Y=="function"&&Y,ne.domain=h?l.domain:void 0,this._c.push(ne),this._a&&this._a.push(ne),this._s&&P(this,!1),ne.promise},catch:function(k){return this.then(void 0,k)}}),_=function(){var k=new O;this.promise=k,this.resolve=C(B,k,1),this.reject=C(z,k,1)},r.f=T=function(k){return k===x||k===E?new _(k):g(k)}),m(m.G+m.W+m.F*!L,{Promise:x}),F("./_set-to-string-tag")(x,f),F("./_set-species")(f),E=F("./_core")[f],m(m.S+m.F*!L,f,{reject:function(K){var Y=T(this),ne=Y.reject;return ne(K),Y.promise}}),m(m.S+m.F*(N||!L),f,{resolve:function(K){return u(N&&this===E?x:this,K)}}),m(m.S+m.F*!(L&&F("./_iter-detect")(function(k){x.all(k).catch(R)})),f,{all:function(K){var Y=this,ne=T(Y),oe=ne.resolve,_e=ne.reject,xe=i(function(){var le=[],me=0,de=1;p(K,!1,function(ae){var ie=me++,q=!1;le.push(void 0),de++,Y.resolve(ae).then(function(ue){if(q)return;q=!0,le[ie]=ue,--de||oe(le)},_e)}),--de||oe(le)});return xe.e&&_e(xe.v),ne.promise},race:function(K){var Y=this,ne=T(Y),oe=ne.reject,_e=i(function(){p(K,!1,function(xe){Y.resolve(xe).then(ne.resolve,oe)})});return _e.e&&oe(_e.v),ne.promise}})},{"./_a-function":92,"./_an-instance":94,"./_classof":97,"./_core":99,"./_ctx":101,"./_export":107,"./_for-of":109,"./_global":110,"./_is-object":119,"./_iter-detect":123,"./_library":126,"./_microtask":128,"./_new-promise-capability":129,"./_perform":144,"./_promise-resolve":145,"./_redefine-all":147,"./_set-species":149,"./_set-to-string-tag":150,"./_species-constructor":153,"./_task":155,"./_user-agent":163,"./_wks":166}],179:[function(F,Q,j){var N=F("./_export"),v=F("./_to-absolute-index"),C=String.fromCharCode,M=String.fromCodePoint;N(N.S+N.F*(!!M&&M.length!=1),"String",{fromCodePoint:function(y){for(var w=[],b=arguments.length,p=0,d;b>p;){if(d=+arguments[p++],v(d,1114111)!==d)throw RangeError(d+" is not a valid code point");w.push(d<65536?C(d):C(((d-=65536)>>10)+55296,d%1024+56320))}return w.join("")}})},{"./_export":107,"./_to-absolute-index":156}],180:[function(F,Q,j){"use strict";var N=F("./_string-at")(!0);F("./_iter-define")(String,"String",function(v){this._t=String(v),this._i=0},function(){var v=this._t,C=this._i,M;return C>=v.length?{value:void 0,done:!0}:(M=N(v,C),this._i+=M.length,{value:M,done:!1})})},{"./_iter-define":122,"./_string-at":154}],181:[function(F,Q,j){"use strict";var N=F("./_global"),v=F("./_has"),C=F("./_descriptors"),M=F("./_export"),m=F("./_redefine"),y=F("./_meta").KEY,w=F("./_fails"),b=F("./_shared"),p=F("./_set-to-string-tag"),d=F("./_uid"),n=F("./_wks"),c=F("./_wks-ext"),r=F("./_wks-define"),i=F("./_enum-keys"),o=F("./_is-array"),u=F("./_an-object"),f=F("./_is-object"),s=F("./_to-object"),l=F("./_to-iobject"),t=F("./_to-primitive"),S=F("./_property-desc"),x=F("./_object-create"),h=F("./_object-gopn-ext"),R=F("./_object-gopd"),O=F("./_object-gops"),g=F("./_object-dp"),_=F("./_object-keys"),E=R.f,T=g.f,L=h.f,I=N.Symbol,P=N.JSON,G=P&&P.stringify,W="prototype",H=n("_hidden"),z=n("toPrimitive"),B={}.propertyIsEnumerable,k=b("symbol-registry"),K=b("symbols"),Y=b("op-symbols"),ne=Object[W],oe=typeof I=="function"&&!!O.f,_e=N.QObject,xe=!_e||!_e[W]||!_e[W].findChild,le=C&&w(function(){return x(T({},"a",{get:function(){return T(this,"a",{value:7}).a}})).a!=7})?function(fe,Te,ze){var Xe=E(ne,Te);Xe&&delete ne[Te],T(fe,Te,ze),Xe&&fe!==ne&&T(ne,Te,Xe)}:T,me=function(fe){var Te=K[fe]=x(I[W]);return Te._k=fe,Te},de=oe&&typeof I.iterator=="symbol"?function(fe){return typeof fe=="symbol"}:function(fe){return fe instanceof I},ae=function(Te,ze,Xe){return Te===ne&&ae(Y,ze,Xe),u(Te),ze=t(ze,!0),u(Xe),v(K,ze)?(Xe.enumerable?(v(Te,H)&&Te[H][ze]&&(Te[H][ze]=!1),Xe=x(Xe,{enumerable:S(0,!1)})):(v(Te,H)||T(Te,H,S(1,{})),Te[H][ze]=!0),le(Te,ze,Xe)):T(Te,ze,Xe)},ie=function(Te,ze){u(Te);for(var Xe=i(ze=l(ze)),Ye=0,rt=Xe.length,at;rt>Ye;)ae(Te,at=Xe[Ye++],ze[at]);return Te},q=function(Te,ze){return ze===void 0?x(Te):ie(x(Te),ze)},ue=function(Te){var ze=B.call(this,Te=t(Te,!0));return this===ne&&v(K,Te)&&!v(Y,Te)?!1:ze||!v(this,Te)||!v(K,Te)||v(this,H)&&this[H][Te]?ze:!0},Z=function(Te,ze){if(Te=l(Te),ze=t(ze,!0),Te===ne&&v(K,ze)&&!v(Y,ze))return;var Xe=E(Te,ze);return Xe&&v(K,ze)&&!(v(Te,H)&&Te[H][ze])&&(Xe.enumerable=!0),Xe},ee=function(Te){for(var ze=L(l(Te)),Xe=[],Ye=0,rt;ze.length>Ye;)!v(K,rt=ze[Ye++])&&rt!=H&&rt!=y&&Xe.push(rt);return Xe},Ee=function(Te){for(var ze=Te===ne,Xe=L(ze?Y:l(Te)),Ye=[],rt=0,at;Xe.length>rt;)v(K,at=Xe[rt++])&&(ze?v(ne,at):!0)&&Ye.push(K[at]);return Ye};oe||(I=function(){if(this instanceof I)throw TypeError("Symbol is not a constructor!");var Te=d(arguments.length>0?arguments[0]:void 0),ze=function(Xe){this===ne&&ze.call(Y,Xe),v(this,H)&&v(this[H],Te)&&(this[H][Te]=!1),le(this,Te,S(1,Xe))};return C&&xe&&le(ne,Te,{configurable:!0,set:ze}),me(Te)},m(I[W],"toString",function(){return this._k}),R.f=Z,g.f=ae,F("./_object-gopn").f=h.f=ee,F("./_object-pie").f=ue,O.f=Ee,C&&!F("./_library")&&m(ne,"propertyIsEnumerable",ue,!0),c.f=function(fe){return me(n(fe))}),M(M.G+M.W+M.F*!oe,{Symbol:I});for(var te="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),J=0;te.length>J;)n(te[J++]);for(var X=_(n.store),$=0;X.length>$;)r(X[$++]);M(M.S+M.F*!oe,"Symbol",{for:function(fe){return v(k,fe+="")?k[fe]:k[fe]=I(fe)},keyFor:function(Te){if(!de(Te))throw TypeError(Te+" is not a symbol!");for(var ze in k)if(k[ze]===Te)return ze},useSetter:function(){xe=!0},useSimple:function(){xe=!1}}),M(M.S+M.F*!oe,"Object",{create:q,defineProperty:ae,defineProperties:ie,getOwnPropertyDescriptor:Z,getOwnPropertyNames:ee,getOwnPropertySymbols:Ee});var ge=w(function(){O.f(1)});M(M.S+M.F*ge,"Object",{getOwnPropertySymbols:function(Te){return O.f(s(Te))}}),P&&M(M.S+M.F*(!oe||w(function(){var fe=I();return G([fe])!="[null]"||G({a:fe})!="{}"||G(Object(fe))!="{}"})),"JSON",{stringify:function(Te){for(var ze=[Te],Xe=1,Ye,rt;arguments.length>Xe;)ze.push(arguments[Xe++]);return rt=Ye=ze[1],!f(Ye)&&Te===void 0||de(Te)?void 0:(o(Ye)||(Ye=function(at,ot){if(typeof rt=="function"&&(ot=rt.call(this,at,ot)),!de(ot))return ot}),ze[1]=Ye,G.apply(P,ze))}}),I[W][z]||F("./_hide")(I[W],z,I[W].valueOf),p(I,"Symbol"),p(Math,"Math",!0),p(N.JSON,"JSON",!0)},{"./_an-object":95,"./_descriptors":103,"./_enum-keys":106,"./_export":107,"./_fails":108,"./_global":110,"./_has":111,"./_hide":112,"./_is-array":118,"./_is-object":119,"./_library":126,"./_meta":127,"./_object-create":131,"./_object-dp":132,"./_object-gopd":134,"./_object-gopn":136,"./_object-gopn-ext":135,"./_object-gops":137,"./_object-keys":140,"./_object-pie":141,"./_property-desc":146,"./_redefine":148,"./_set-to-string-tag":150,"./_shared":152,"./_to-iobject":158,"./_to-object":160,"./_to-primitive":161,"./_uid":162,"./_wks":166,"./_wks-define":164,"./_wks-ext":165}],182:[function(F,Q,j){var N=F("./_export"),v=F("./_object-to-array")(!0);N(N.S,"Object",{entries:function(M){return v(M)}})},{"./_export":107,"./_object-to-array":143}],183:[function(F,Q,j){"use strict";var N=F("./_export"),v=F("./_core"),C=F("./_global"),M=F("./_species-constructor"),m=F("./_promise-resolve");N(N.P+N.R,"Promise",{finally:function(y){var w=M(this,v.Promise||C.Promise),b=typeof y=="function";return this.then(b?function(p){return m(w,y()).then(function(){return p})}:y,b?function(p){return m(w,y()).then(function(){throw p})}:y)}})},{"./_core":99,"./_export":107,"./_global":110,"./_promise-resolve":145,"./_species-constructor":153}],184:[function(F,Q,j){"use strict";var N=F("./_export"),v=F("./_new-promise-capability"),C=F("./_perform");N(N.S,"Promise",{try:function(M){var m=v.f(this),y=C(M);return(y.e?m.reject:m.resolve)(y.v),m.promise}})},{"./_export":107,"./_new-promise-capability":129,"./_perform":144}],185:[function(F,Q,j){F("./_wks-define")("asyncIterator")},{"./_wks-define":164}],186:[function(F,Q,j){F("./_wks-define")("observable")},{"./_wks-define":164}],187:[function(F,Q,j){F("./es6.array.iterator");for(var N=F("./_global"),v=F("./_hide"),C=F("./_iterators"),M=F("./_wks")("toStringTag"),m="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),y=0;y<m.length;y++){var w=m[y],b=N[w],p=b&&b.prototype;p&&!p[M]&&v(p,M,w),C[w]=C.Array}},{"./_global":110,"./_hide":112,"./_iterators":125,"./_wks":166,"./es6.array.iterator":169}],188:[function(F,Q,j){var N=F("./_export"),v=F("./_task");N(N.G+N.B,{setImmediate:v.set,clearImmediate:v.clear})},{"./_export":107,"./_task":155}],189:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/helpers/typeof"),C=M(v);function M(t){return t&&t.__esModule?t:{default:t}}function m(t){return Array.isArray?Array.isArray(t):l(t)==="[object Array]"}j.isArray=m;function y(t){return typeof t=="boolean"}j.isBoolean=y;function w(t){return t===null}j.isNull=w;function b(t){return t==null}j.isNullOrUndefined=b;function p(t){return typeof t=="number"}j.isNumber=p;function d(t){return typeof t=="string"}j.isString=d;function n(t){return(typeof t=="undefined"?"undefined":(0,C.default)(t))==="symbol"}j.isSymbol=n;function c(t){return t===void 0}j.isUndefined=c;function r(t){return l(t)==="[object RegExp]"}j.isRegExp=r;function i(t){return(typeof t=="undefined"?"undefined":(0,C.default)(t))==="object"&&t!==null}j.isObject=i;function o(t){return l(t)==="[object Date]"}j.isDate=o;function u(t){return l(t)==="[object Error]"||t instanceof Error}j.isError=u;function f(t){return typeof t=="function"}j.isFunction=f;function s(t){return t===null||typeof t=="boolean"||typeof t=="number"||typeof t=="string"||(typeof t=="undefined"?"undefined":(0,C.default)(t))==="symbol"||typeof t=="undefined"}j.isPrimitive=s,j.isBuffer=N.isBuffer;function l(t){return Object.prototype.toString.call(t)}}).call(this,{isBuffer:F("../../is-buffer/index.js")})},{"../../is-buffer/index.js":197,"babel-runtime/helpers/typeof":67}],190:[function(F,Q,j){"use strict";var N=F("babel-runtime/helpers/typeof"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(M){"use strict";var m=function(){var d=/d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZWN]|'[^']*'|'[^']*'/g,n=/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,c=/[^-+\dA-Z]/g;return function(r,i,o,u){if(arguments.length===1&&p(r)==="string"&&!/\d/.test(r)&&(i=r,r=void 0),r=r||new Date,r instanceof Date||(r=new Date(r)),isNaN(r))throw TypeError("Invalid date");i=String(m.masks[i]||i||m.masks.default);var f=i.slice(0,4);(f==="UTC:"||f==="GMT:")&&(i=i.slice(4),o=!0,f==="GMT:"&&(u=!0));var s=o?"getUTC":"get",l=r[s+"Date"](),t=r[s+"Day"](),S=r[s+"Month"](),x=r[s+"FullYear"](),h=r[s+"Hours"](),R=r[s+"Minutes"](),O=r[s+"Seconds"](),g=r[s+"Milliseconds"](),_=o?0:r.getTimezoneOffset(),E=w(r),T=b(r),L={d:l,dd:y(l),ddd:m.i18n.dayNames[t],dddd:m.i18n.dayNames[t+7],m:S+1,mm:y(S+1),mmm:m.i18n.monthNames[S],mmmm:m.i18n.monthNames[S+12],yy:String(x).slice(2),yyyy:x,h:h%12||12,hh:y(h%12||12),H:h,HH:y(h),M:R,MM:y(R),s:O,ss:y(O),l:y(g,3),L:y(Math.round(g/10)),t:h<12?"a":"p",tt:h<12?"am":"pm",T:h<12?"A":"P",TT:h<12?"AM":"PM",Z:u?"GMT":o?"UTC":(String(r).match(n)||[""]).pop().replace(c,""),o:(_>0?"-":"+")+y(Math.floor(Math.abs(_)/60)*100+Math.abs(_)%60,4),S:["th","st","nd","rd"][l%10>3?0:(l%100-l%10!=10)*l%10],W:E,N:T};return i.replace(d,function(I){return I in L?L[I]:I.slice(1,I.length-1)})}}();m.masks={default:"ddd mmm dd yyyy HH:MM:ss",shortDate:"m/d/yy",mediumDate:"mmm d, yyyy",longDate:"mmmm d, yyyy",fullDate:"dddd, mmmm d, yyyy",shortTime:"h:MM TT",mediumTime:"h:MM:ss TT",longTime:"h:MM:ss TT Z",isoDate:"yyyy-mm-dd",isoTime:"HH:MM:ss",isoDateTime:"yyyy-mm-dd'T'HH:MM:sso",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'",expiresHeaderFormat:"ddd, dd mmm yyyy HH:MM:ss Z"},m.i18n={dayNames:["Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],monthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","January","February","March","April","May","June","July","August","September","October","November","December"]};function y(d,n){for(d=String(d),n=n||2;d.length<n;)d="0"+d;return d}function w(d){var n=new Date(d.getFullYear(),d.getMonth(),d.getDate());n.setDate(n.getDate()-(n.getDay()+6)%7+3);var c=new Date(n.getFullYear(),0,4);c.setDate(c.getDate()-(c.getDay()+6)%7+3);var r=n.getTimezoneOffset()-c.getTimezoneOffset();n.setHours(n.getHours()-r);var i=(n-c)/(864e5*7);return 1+Math.floor(i)}function b(d){var n=d.getDay();return n===0&&(n=7),n}function p(d){return d===null?"null":d===void 0?"undefined":(typeof d=="undefined"?"undefined":(0,v.default)(d))!=="object"?typeof d=="undefined"?"undefined":(0,v.default)(d):Array.isArray(d)?"array":{}.toString.call(d).slice(8,-1).toLowerCase()}typeof define=="function"&&define.amd?define(function(){return m}):(typeof j=="undefined"?"undefined":(0,v.default)(j))==="object"?Q.exports=m:M.dateFormat=m})(void 0)},{"babel-runtime/helpers/typeof":67}],191:[function(F,Q,j){/*!
* escape-html
* Copyright(c) 2012-2013 TJ Holowaychuk
* Copyright(c) 2015 Andreas Lubbe
* Copyright(c) 2015 Tiancheng "Timothy" Gu
* MIT Licensed
*/"use strict";var N=/["'&<>]/;Q.exports=v;function v(C){var M=""+C,m=N.exec(M);if(!m)return M;var y,w="",b=0,p=0;for(b=m.index;b<M.length;b++){switch(M.charCodeAt(b)){case 34:y="&quot;";break;case 38:y="&amp;";break;case 39:y="&#39;";break;case 60:y="&lt;";break;case 62:y="&gt;";break;default:continue}p!==b&&(w+=M.substring(p,b)),p=b+1,w+=y}return p!==b?w+M.substring(p,b):w}},{}],192:[function(F,Q,j){function N(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}Q.exports=N,N.EventEmitter=N,N.prototype._events=void 0,N.prototype._maxListeners=void 0,N.defaultMaxListeners=10,N.prototype.setMaxListeners=function(y){if(!C(y)||y<0||isNaN(y))throw TypeError("n must be a positive number");return this._maxListeners=y,this},N.prototype.emit=function(y){var w,b,p,d,n,c;if(this._events||(this._events={}),y==="error"&&(!this._events.error||M(this._events.error)&&!this._events.error.length)){if(w=arguments[1],w instanceof Error)throw w;var r=new Error('Uncaught, unspecified "error" event. ('+w+")");throw r.context=w,r}if(b=this._events[y],m(b))return!1;if(v(b))switch(arguments.length){case 1:b.call(this);break;case 2:b.call(this,arguments[1]);break;case 3:b.call(this,arguments[1],arguments[2]);break;default:d=Array.prototype.slice.call(arguments,1),b.apply(this,d)}else if(M(b))for(d=Array.prototype.slice.call(arguments,1),c=b.slice(),p=c.length,n=0;n<p;n++)c[n].apply(this,d);return!0},N.prototype.addListener=function(y,w){var b;if(!v(w))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",y,v(w.listener)?w.listener:w),this._events[y]?M(this._events[y])?this._events[y].push(w):this._events[y]=[this._events[y],w]:this._events[y]=w,M(this._events[y])&&!this._events[y].warned&&(m(this._maxListeners)?b=N.defaultMaxListeners:b=this._maxListeners,b&&b>0&&this._events[y].length>b&&(this._events[y].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[y].length),typeof console.trace=="function"&&console.trace())),this},N.prototype.on=N.prototype.addListener,N.prototype.once=function(y,w){if(!v(w))throw TypeError("listener must be a function");var b=!1;function p(){this.removeListener(y,p),b||(b=!0,w.apply(this,arguments))}return p.listener=w,this.on(y,p),this},N.prototype.removeListener=function(y,w){var b,p,d,n;if(!v(w))throw TypeError("listener must be a function");if(!this._events||!this._events[y])return this;if(b=this._events[y],d=b.length,p=-1,b===w||v(b.listener)&&b.listener===w)delete this._events[y],this._events.removeListener&&this.emit("removeListener",y,w);else if(M(b)){for(n=d;n-- >0;)if(b[n]===w||b[n].listener&&b[n].listener===w){p=n;break}if(p<0)return this;b.length===1?(b.length=0,delete this._events[y]):b.splice(p,1),this._events.removeListener&&this.emit("removeListener",y,w)}return this},N.prototype.removeAllListeners=function(y){var w,b;if(!this._events)return this;if(!this._events.removeListener)return arguments.length===0?this._events={}:this._events[y]&&delete this._events[y],this;if(arguments.length===0){for(w in this._events){if(w==="removeListener")continue;this.removeAllListeners(w)}return this.removeAllListeners("removeListener"),this._events={},this}if(b=this._events[y],v(b))this.removeListener(y,b);else if(b)for(;b.length;)this.removeListener(y,b[b.length-1]);return delete this._events[y],this},N.prototype.listeners=function(y){var w;return!this._events||!this._events[y]?w=[]:v(this._events[y])?w=[this._events[y]]:w=this._events[y].slice(),w},N.prototype.listenerCount=function(y){if(this._events){var w=this._events[y];if(v(w))return 1;if(w)return w.length}return 0},N.listenerCount=function(y,w){return y.listenerCount(w)};function v(y){return typeof y=="function"}function C(y){return typeof y=="number"}function M(y){return typeof y=="object"&&y!==null}function m(y){return y===void 0}},{}],193:[function(F,Q,j){var N=F("http"),v=Q.exports;for(var C in N)N.hasOwnProperty(C)&&(v[C]=N[C]);v.request=function(M,m){return M||(M={}),M.scheme="https",M.protocol="https:",N.request.call(this,M,m)}},{http:231}],194:[function(F,Q,j){/*!
* humanize-ms - index.js
* Copyright(c) 2014 dead_horse <dead_horse@qq.com>
* MIT Licensed
*/"use strict";var N=F("util"),v=F("ms");Q.exports=function(C){if(typeof C=="number")return C;var M=v(C);if(M===void 0){var m=new Error(N.format("humanize-ms(%j) result undefined",C));console.warn(m.stack)}return M}},{ms:204,util:243}],195:[function(F,Q,j){j.read=function(N,v,C,M,m){var y,w,b=m*8-M-1,p=(1<<b)-1,d=p>>1,n=-7,c=C?m-1:0,r=C?-1:1,i=N[v+c];for(c+=r,y=i&(1<<-n)-1,i>>=-n,n+=b;n>0;y=y*256+N[v+c],c+=r,n-=8);for(w=y&(1<<-n)-1,y>>=-n,n+=M;n>0;w=w*256+N[v+c],c+=r,n-=8);if(y===0)y=1-d;else{if(y===p)return w?NaN:(i?-1:1)*Infinity;w=w+Math.pow(2,M),y=y-d}return(i?-1:1)*w*Math.pow(2,y-M)},j.write=function(N,v,C,M,m,y){var w,b,p,d=y*8-m-1,n=(1<<d)-1,c=n>>1,r=m===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=M?0:y-1,o=M?1:-1,u=v<0||v===0&&1/v<0?1:0;for(v=Math.abs(v),isNaN(v)||v===Infinity?(b=isNaN(v)?1:0,w=n):(w=Math.floor(Math.log(v)/Math.LN2),v*(p=Math.pow(2,-w))<1&&(w--,p*=2),w+c>=1?v+=r/p:v+=r*Math.pow(2,1-c),v*p>=2&&(w++,p/=2),w+c>=n?(b=0,w=n):w+c>=1?(b=(v*p-1)*Math.pow(2,m),w=w+c):(b=v*Math.pow(2,c-1)*Math.pow(2,m),w=0));m>=8;N[C+i]=b&255,i+=o,b/=256,m-=8);for(w=w<<m|b,d+=m;d>0;N[C+i]=w&255,i+=o,w/=256,d-=8);N[C+i-o]|=u*128}},{}],196:[function(F,Q,j){typeof Object.create=="function"?Q.exports=function(v,C){C&&(v.super_=C,v.prototype=Object.create(C.prototype,{constructor:{value:v,enumerable:!1,writable:!0,configurable:!0}}))}:Q.exports=function(v,C){if(C){v.super_=C;var M=function(){};M.prototype=C.prototype,v.prototype=new M,v.prototype.constructor=v}}},{}],197:[function(F,Q,j){/*!
* Determine if an object is a Buffer
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/Q.exports=function(C){return C!=null&&(N(C)||v(C)||!!C._isBuffer)};function N(C){return!!C.constructor&&typeof C.constructor.isBuffer=="function"&&C.constructor.isBuffer(C)}function v(C){return typeof C.readFloatLE=="function"&&typeof C.slice=="function"&&N(C.slice(0,0))}},{}],198:[function(F,Q,j){var N={}.toString;Q.exports=Array.isArray||function(v){return N.call(v)=="[object Array]"}},{}],199:[function(require,module,exports){(function(global){(function(F,Q){typeof exports=="object"&&typeof module!="undefined"?module.exports=Q(F):typeof define=="function"&&define.amd?define(Q):Q(F)})(typeof self!="undefined"?self:typeof window!="undefined"?window:typeof global!="undefined"?global:this,function(global){"use strict";global=global||{};var _Base64=global.Base64,version="2.5.2",buffer;if(typeof module!="undefined"&&module.exports)try{buffer=eval("require('buffer').Buffer")}catch(F){buffer=void 0}var b64chars="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",b64tab=function(F){for(var Q={},j=0,N=F.length;j<N;j++)Q[F.charAt(j)]=j;return Q}(b64chars),fromCharCode=String.fromCharCode,cb_utob=function(F){if(F.length<2){var Q=F.charCodeAt(0);return Q<128?F:Q<2048?fromCharCode(192|Q>>>6)+fromCharCode(128|Q&63):fromCharCode(224|Q>>>12&15)+fromCharCode(128|Q>>>6&63)+fromCharCode(128|Q&63)}else{var Q=65536+(F.charCodeAt(0)-55296)*1024+(F.charCodeAt(1)-56320);return fromCharCode(240|Q>>>18&7)+fromCharCode(128|Q>>>12&63)+fromCharCode(128|Q>>>6&63)+fromCharCode(128|Q&63)}},re_utob=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,utob=function(F){return F.replace(re_utob,cb_utob)},cb_encode=function(F){var Q=[0,2,1][F.length%3],j=F.charCodeAt(0)<<16|(F.length>1?F.charCodeAt(1):0)<<8|(F.length>2?F.charCodeAt(2):0),N=[b64chars.charAt(j>>>18),b64chars.charAt(j>>>12&63),Q>=2?"=":b64chars.charAt(j>>>6&63),Q>=1?"=":b64chars.charAt(j&63)];return N.join("")},btoa=global.btoa?function(F){return global.btoa(F)}:function(F){return F.replace(/[\s\S]{1,3}/g,cb_encode)},_encode=function(F){var Q=Object.prototype.toString.call(F)==="[object Uint8Array]";return Q?F.toString("base64"):btoa(utob(String(F)))},encode=function(F,Q){return Q?_encode(String(F)).replace(/[+\/]/g,function(j){return j=="+"?"-":"_"}).replace(/=/g,""):_encode(F)},encodeURI=function(F){return encode(F,!0)},re_btou=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,cb_btou=function(F){switch(F.length){case 4:var Q=(7&F.charCodeAt(0))<<18|(63&F.charCodeAt(1))<<12|(63&F.charCodeAt(2))<<6|63&F.charCodeAt(3),j=Q-65536;return fromCharCode((j>>>10)+55296)+fromCharCode((j&1023)+56320);case 3:return fromCharCode((15&F.charCodeAt(0))<<12|(63&F.charCodeAt(1))<<6|63&F.charCodeAt(2));default:return fromCharCode((31&F.charCodeAt(0))<<6|63&F.charCodeAt(1))}},btou=function(F){return F.replace(re_btou,cb_btou)},cb_decode=function(F){var Q=F.length,j=Q%4,N=(Q>0?b64tab[F.charAt(0)]<<18:0)|(Q>1?b64tab[F.charAt(1)]<<12:0)|(Q>2?b64tab[F.charAt(2)]<<6:0)|(Q>3?b64tab[F.charAt(3)]:0),v=[fromCharCode(N>>>16),fromCharCode(N>>>8&255),fromCharCode(N&255)];return v.length-=[0,0,2,1][j],v.join("")},_atob=global.atob?function(F){return global.atob(F)}:function(F){return F.replace(/\S{1,4}/g,cb_decode)},atob=function(F){return _atob(String(F).replace(/[^A-Za-z0-9\+\/]/g,""))},_decode=buffer?buffer.from&&Uint8Array&&buffer.from!==Uint8Array.from?function(F){return(F.constructor===buffer.constructor?F:buffer.from(F,"base64")).toString()}:function(F){return(F.constructor===buffer.constructor?F:new buffer(F,"base64")).toString()}:function(F){return btou(_atob(F))},decode=function(F){return _decode(String(F).replace(/[-_]/g,function(Q){return Q=="-"?"+":"/"}).replace(/[^A-Za-z0-9\+\/]/g,""))},noConflict=function(){var F=global.Base64;return global.Base64=_Base64,F};if(global.Base64={VERSION:version,atob,btoa,fromBase64:decode,toBase64:encode,utob,encode,encodeURI,btou,decode,noConflict,__buffer__:buffer},typeof Object.defineProperty=="function"){var noEnum=function(F){return{value:F,enumerable:!1,writable:!0,configurable:!0}};global.Base64.extendString=function(){Object.defineProperty(String.prototype,"fromBase64",noEnum(function(){return decode(this)})),Object.defineProperty(String.prototype,"toBase64",noEnum(function(F){return encode(this,F)})),Object.defineProperty(String.prototype,"toBase64URI",noEnum(function(){return encode(this,!0)}))}}return global.Meteor&&(Base64=global.Base64),typeof module!="undefined"&&module.exports?module.exports.Base64=global.Base64:typeof define=="function"&&define.amd&&define([],function(){return global.Base64}),{Base64:global.Base64}})}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],200:[function(F,Q,j){/*!
* merge-descriptors
* Copyright(c) 2014 Jonathan Ong
* Copyright(c) 2015 Douglas Christopher Wilson
* MIT Licensed
*/"use strict";Q.exports=v;var N=Object.prototype.hasOwnProperty;function v(C,M,m){if(!C)throw new TypeError("argument dest is required");if(!M)throw new TypeError("argument src is required");return m===void 0&&(m=!0),Object.getOwnPropertyNames(M).forEach(function(w){if(!m&&N.call(C,w))return;var b=Object.getOwnPropertyDescriptor(M,w);Object.defineProperty(C,w,b)}),C}},{}],201:[function(F,Q,j){"use strict";function N(){this._types=Object.create(null),this._extensions=Object.create(null);for(var v=0;v<arguments.length;v++)this.define(arguments[v]);this.define=this.define.bind(this),this.getType=this.getType.bind(this),this.getExtension=this.getExtension.bind(this)}N.prototype.define=function(v,C){for(var M in v){var m=v[M].map(function(b){return b.toLowerCase()});M=M.toLowerCase();for(var y=0;y<m.length;y++){var w=m[y];if(w[0]=="*")continue;if(!C&&w in this._types)throw new Error('Attempt to change mapping for "'+w+'" extension from "'+this._types[w]+'" to "'+M+'". Pass `force=true` to allow this, otherwise remove "'+w+'" from the list of extensions for "'+M+'".');this._types[w]=M}if(C||!this._extensions[M]){var w=m[0];this._extensions[M]=w[0]!="*"?w:w.substr(1)}}},N.prototype.getType=function(v){v=String(v);var C=v.replace(/^.*[/\\]/,"").toLowerCase(),M=C.replace(/^.*\./,"").toLowerCase(),m=C.length<v.length,y=M.length<C.length-1;return(y||!m)&&this._types[M]||null},N.prototype.getExtension=function(v){return v=/^\s*([^;\s]*)/.test(v)&&RegExp.$1,v&&this._extensions[v.toLowerCase()]||null},Q.exports=N},{}],202:[function(F,Q,j){"use strict";var N=F("./Mime");Q.exports=new N(F("./types/standard"))},{"./Mime":201,"./types/standard":203}],203:[function(F,Q,j){Q.exports={"application/andrew-inset":["ez"],"application/applixware":["aw"],"application/atom+xml":["atom"],"application/atomcat+xml":["atomcat"],"application/atomdeleted+xml":["atomdeleted"],"application/atomsvc+xml":["atomsvc"],"application/atsc-dwd+xml":["dwd"],"application/atsc-held+xml":["held"],"application/atsc-rsat+xml":["rsat"],"application/bdoc":["bdoc"],"application/calendar+xml":["xcs"],"application/ccxml+xml":["ccxml"],"application/cdfx+xml":["cdfx"],"application/cdmi-capability":["cdmia"],"application/cdmi-container":["cdmic"],"application/cdmi-domain":["cdmid"],"application/cdmi-object":["cdmio"],"application/cdmi-queue":["cdmiq"],"application/cu-seeme":["cu"],"application/dash+xml":["mpd"],"application/davmount+xml":["davmount"],"application/docbook+xml":["dbk"],"application/dssc+der":["dssc"],"application/dssc+xml":["xdssc"],"application/ecmascript":["ecma","es"],"application/emma+xml":["emma"],"application/emotionml+xml":["emotionml"],"application/epub+zip":["epub"],"application/exi":["exi"],"application/fdt+xml":["fdt"],"application/font-tdpfr":["pfr"],"application/geo+json":["geojson"],"application/gml+xml":["gml"],"application/gpx+xml":["gpx"],"application/gxf":["gxf"],"application/gzip":["gz"],"application/hjson":["hjson"],"application/hyperstudio":["stk"],"application/inkml+xml":["ink","inkml"],"application/ipfix":["ipfix"],"application/its+xml":["its"],"application/java-archive":["jar","war","ear"],"application/java-serialized-object":["ser"],"application/java-vm":["class"],"application/javascript":["js","mjs"],"application/json":["json","map"],"application/json5":["json5"],"application/jsonml+json":["jsonml"],"application/ld+json":["jsonld"],"application/lgr+xml":["lgr"],"application/lost+xml":["lostxml"],"application/mac-binhex40":["hqx"],"application/mac-compactpro":["cpt"],"application/mads+xml":["mads"],"application/manifest+json":["webmanifest"],"application/marc":["mrc"],"application/marcxml+xml":["mrcx"],"application/mathematica":["ma","nb","mb"],"application/mathml+xml":["mathml"],"application/mbox":["mbox"],"application/mediaservercontrol+xml":["mscml"],"application/metalink+xml":["metalink"],"application/metalink4+xml":["meta4"],"application/mets+xml":["mets"],"application/mmt-aei+xml":["maei"],"application/mmt-usd+xml":["musd"],"application/mods+xml":["mods"],"application/mp21":["m21","mp21"],"application/mp4":["mp4s","m4p"],"application/mrb-consumer+xml":["*xdf"],"application/mrb-publish+xml":["*xdf"],"application/msword":["doc","dot"],"application/mxf":["mxf"],"application/n-quads":["nq"],"application/n-triples":["nt"],"application/node":["cjs"],"application/octet-stream":["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"],"application/oda":["oda"],"application/oebps-package+xml":["opf"],"application/ogg":["ogx"],"application/omdoc+xml":["omdoc"],"application/onenote":["onetoc","onetoc2","onetmp","onepkg"],"application/oxps":["oxps"],"application/p2p-overlay+xml":["relo"],"application/patch-ops-error+xml":["*xer"],"application/pdf":["pdf"],"application/pgp-encrypted":["pgp"],"application/pgp-signature":["asc","sig"],"application/pics-rules":["prf"],"application/pkcs10":["p10"],"application/pkcs7-mime":["p7m","p7c"],"application/pkcs7-signature":["p7s"],"application/pkcs8":["p8"],"application/pkix-attr-cert":["ac"],"application/pkix-cert":["cer"],"application/pkix-crl":["crl"],"application/pkix-pkipath":["pkipath"],"application/pkixcmp":["pki"],"application/pls+xml":["pls"],"application/postscript":["ai","eps","ps"],"application/provenance+xml":["provx"],"application/pskc+xml":["pskcxml"],"application/raml+yaml":["raml"],"application/rdf+xml":["rdf","owl"],"application/reginfo+xml":["rif"],"application/relax-ng-compact-syntax":["rnc"],"application/resource-lists+xml":["rl"],"application/resource-lists-diff+xml":["rld"],"application/rls-services+xml":["rs"],"application/route-apd+xml":["rapd"],"application/route-s-tsid+xml":["sls"],"application/route-usd+xml":["rusd"],"application/rpki-ghostbusters":["gbr"],"application/rpki-manifest":["mft"],"application/rpki-roa":["roa"],"application/rsd+xml":["rsd"],"application/rss+xml":["rss"],"application/rtf":["rtf"],"application/sbml+xml":["sbml"],"application/scvp-cv-request":["scq"],"application/scvp-cv-response":["scs"],"application/scvp-vp-request":["spq"],"application/scvp-vp-response":["spp"],"application/sdp":["sdp"],"application/senml+xml":["senmlx"],"application/sensml+xml":["sensmlx"],"application/set-payment-initiation":["setpay"],"application/set-registration-initiation":["setreg"],"application/shf+xml":["shf"],"application/sieve":["siv","sieve"],"application/smil+xml":["smi","smil"],"application/sparql-query":["rq"],"application/sparql-results+xml":["srx"],"application/srgs":["gram"],"application/srgs+xml":["grxml"],"application/sru+xml":["sru"],"application/ssdl+xml":["ssdl"],"application/ssml+xml":["ssml"],"application/swid+xml":["swidtag"],"application/tei+xml":["tei","teicorpus"],"application/thraud+xml":["tfi"],"application/timestamped-data":["tsd"],"application/toml":["toml"],"application/ttml+xml":["ttml"],"application/urc-ressheet+xml":["rsheet"],"application/voicexml+xml":["vxml"],"application/wasm":["wasm"],"application/widget":["wgt"],"application/winhlp":["hlp"],"application/wsdl+xml":["wsdl"],"application/wspolicy+xml":["wspolicy"],"application/xaml+xml":["xaml"],"application/xcap-att+xml":["xav"],"application/xcap-caps+xml":["xca"],"application/xcap-diff+xml":["xdf"],"application/xcap-el+xml":["xel"],"application/xcap-error+xml":["xer"],"application/xcap-ns+xml":["xns"],"application/xenc+xml":["xenc"],"application/xhtml+xml":["xhtml","xht"],"application/xliff+xml":["xlf"],"application/xml":["xml","xsl","xsd","rng"],"application/xml-dtd":["dtd"],"application/xop+xml":["xop"],"application/xproc+xml":["xpl"],"application/xslt+xml":["xslt"],"application/xspf+xml":["xspf"],"application/xv+xml":["mxml","xhvml","xvml","xvm"],"application/yang":["yang"],"application/yin+xml":["yin"],"application/zip":["zip"],"audio/3gpp":["*3gpp"],"audio/adpcm":["adp"],"audio/basic":["au","snd"],"audio/midi":["mid","midi","kar","rmi"],"audio/mobile-xmf":["mxmf"],"audio/mp3":["*mp3"],"audio/mp4":["m4a","mp4a"],"audio/mpeg":["mpga","mp2","mp2a","mp3","m2a","m3a"],"audio/ogg":["oga","ogg","spx"],"audio/s3m":["s3m"],"audio/silk":["sil"],"audio/wav":["wav"],"audio/wave":["*wav"],"audio/webm":["weba"],"audio/xm":["xm"],"font/collection":["ttc"],"font/otf":["otf"],"font/ttf":["ttf"],"font/woff":["woff"],"font/woff2":["woff2"],"image/aces":["exr"],"image/apng":["apng"],"image/bmp":["bmp"],"image/cgm":["cgm"],"image/dicom-rle":["drle"],"image/emf":["emf"],"image/fits":["fits"],"image/g3fax":["g3"],"image/gif":["gif"],"image/heic":["heic"],"image/heic-sequence":["heics"],"image/heif":["heif"],"image/heif-sequence":["heifs"],"image/hej2k":["hej2"],"image/hsj2":["hsj2"],"image/ief":["ief"],"image/jls":["jls"],"image/jp2":["jp2","jpg2"],"image/jpeg":["jpeg","jpg","jpe"],"image/jph":["jph"],"image/jphc":["jhc"],"image/jpm":["jpm"],"image/jpx":["jpx","jpf"],"image/jxr":["jxr"],"image/jxra":["jxra"],"image/jxrs":["jxrs"],"image/jxs":["jxs"],"image/jxsc":["jxsc"],"image/jxsi":["jxsi"],"image/jxss":["jxss"],"image/ktx":["ktx"],"image/png":["png"],"image/sgi":["sgi"],"image/svg+xml":["svg","svgz"],"image/t38":["t38"],"image/tiff":["tif","tiff"],"image/tiff-fx":["tfx"],"image/webp":["webp"],"image/wmf":["wmf"],"message/disposition-notification":["disposition-notification"],"message/global":["u8msg"],"message/global-delivery-status":["u8dsn"],"message/global-disposition-notification":["u8mdn"],"message/global-headers":["u8hdr"],"message/rfc822":["eml","mime"],"model/3mf":["3mf"],"model/gltf+json":["gltf"],"model/gltf-binary":["glb"],"model/iges":["igs","iges"],"model/mesh":["msh","mesh","silo"],"model/mtl":["mtl"],"model/obj":["obj"],"model/stl":["stl"],"model/vrml":["wrl","vrml"],"model/x3d+binary":["*x3db","x3dbz"],"model/x3d+fastinfoset":["x3db"],"model/x3d+vrml":["*x3dv","x3dvz"],"model/x3d+xml":["x3d","x3dz"],"model/x3d-vrml":["x3dv"],"text/cache-manifest":["appcache","manifest"],"text/calendar":["ics","ifb"],"text/coffeescript":["coffee","litcoffee"],"text/css":["css"],"text/csv":["csv"],"text/html":["html","htm","shtml"],"text/jade":["jade"],"text/jsx":["jsx"],"text/less":["less"],"text/markdown":["markdown","md"],"text/mathml":["mml"],"text/mdx":["mdx"],"text/n3":["n3"],"text/plain":["txt","text","conf","def","list","log","in","ini"],"text/richtext":["rtx"],"text/rtf":["*rtf"],"text/sgml":["sgml","sgm"],"text/shex":["shex"],"text/slim":["slim","slm"],"text/stylus":["stylus","styl"],"text/tab-separated-values":["tsv"],"text/troff":["t","tr","roff","man","me","ms"],"text/turtle":["ttl"],"text/uri-list":["uri","uris","urls"],"text/vcard":["vcard"],"text/vtt":["vtt"],"text/xml":["*xml"],"text/yaml":["yaml","yml"],"video/3gpp":["3gp","3gpp"],"video/3gpp2":["3g2"],"video/h261":["h261"],"video/h263":["h263"],"video/h264":["h264"],"video/jpeg":["jpgv"],"video/jpm":["*jpm","jpgm"],"video/mj2":["mj2","mjp2"],"video/mp2t":["ts"],"video/mp4":["mp4","mp4v","mpg4"],"video/mpeg":["mpeg","mpg","mpe","m1v","m2v"],"video/ogg":["ogv"],"video/quicktime":["qt","mov"],"video/webm":["webm"]}},{}],204:[function(F,Q,j){var N=1e3,v=N*60,C=v*60,M=C*24,m=M*7,y=M*365.25;Q.exports=function(n,c){c=c||{};var r=typeof n;if(r==="string"&&n.length>0)return w(n);if(r==="number"&&isFinite(n))return c.long?p(n):b(n);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(n))};function w(n){if(n=String(n),n.length>100)return;var c=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(n);if(!c)return;var r=parseFloat(c[1]),i=(c[2]||"ms").toLowerCase();switch(i){case"years":case"year":case"yrs":case"yr":case"y":return r*y;case"weeks":case"week":case"w":return r*m;case"days":case"day":case"d":return r*M;case"hours":case"hour":case"hrs":case"hr":case"h":return r*C;case"minutes":case"minute":case"mins":case"min":case"m":return r*v;case"seconds":case"second":case"secs":case"sec":case"s":return r*N;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}function b(n){var c=Math.abs(n);return c>=M?Math.round(n/M)+"d":c>=C?Math.round(n/C)+"h":c>=v?Math.round(n/v)+"m":c>=N?Math.round(n/N)+"s":n+"ms"}function p(n){var c=Math.abs(n);return c>=M?d(n,c,M,"day"):c>=C?d(n,c,C,"hour"):c>=v?d(n,c,v,"minute"):c>=N?d(n,c,N,"second"):n+" ms"}function d(n,c,r,i){var o=c>=r*1.5;return Math.round(n/r)+" "+i+(o?"s":"")}},{}],205:[function(F,Q,j){(function(N){function v(y,w){for(var b=0,p=y.length-1;p>=0;p--){var d=y[p];d==="."?y.splice(p,1):d===".."?(y.splice(p,1),b++):b&&(y.splice(p,1),b--)}if(w)for(;b--;b)y.unshift("..");return y}j.resolve=function(){for(var y="",w=!1,b=arguments.length-1;b>=-1&&!w;b--){var p=b>=0?arguments[b]:N.cwd();if(typeof p!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!p)continue;y=p+"/"+y,w=p.charAt(0)==="/"}return y=v(M(y.split("/"),function(d){return!!d}),!w).join("/"),(w?"/":"")+y||"."},j.normalize=function(y){var w=j.isAbsolute(y),b=m(y,-1)==="/";return y=v(M(y.split("/"),function(p){return!!p}),!w).join("/"),!y&&!w&&(y="."),y&&b&&(y+="/"),(w?"/":"")+y},j.isAbsolute=function(y){return y.charAt(0)==="/"},j.join=function(){var y=Array.prototype.slice.call(arguments,0);return j.normalize(M(y,function(w,b){if(typeof w!="string")throw new TypeError("Arguments to path.join must be strings");return w}).join("/"))},j.relative=function(y,w){y=j.resolve(y).substr(1),w=j.resolve(w).substr(1);function b(o){for(var u=0;u<o.length&&!(o[u]!=="");u++);for(var f=o.length-1;f>=0&&!(o[f]!=="");f--);return u>f?[]:o.slice(u,f-u+1)}for(var p=b(y.split("/")),d=b(w.split("/")),n=Math.min(p.length,d.length),c=n,r=0;r<n;r++)if(p[r]!==d[r]){c=r;break}for(var i=[],r=c;r<p.length;r++)i.push("..");return i=i.concat(d.slice(c)),i.join("/")},j.sep="/",j.delimiter=":",j.dirname=function(y){if(typeof y!="string"&&(y=y+""),y.length===0)return".";for(var w=y.charCodeAt(0),b=w===47,p=-1,d=!0,n=y.length-1;n>=1;--n)if(w=y.charCodeAt(n),w===47){if(!d){p=n;break}}else d=!1;return p===-1?b?"/":".":b&&p===1?"/":y.slice(0,p)};function C(y){typeof y!="string"&&(y=y+"");var w=0,b=-1,p=!0,d;for(d=y.length-1;d>=0;--d)if(y.charCodeAt(d)===47){if(!p){w=d+1;break}}else b===-1&&(p=!1,b=d+1);return b===-1?"":y.slice(w,b)}j.basename=function(y,w){var b=C(y);return w&&b.substr(-1*w.length)===w&&(b=b.substr(0,b.length-w.length)),b},j.extname=function(y){typeof y!="string"&&(y=y+"");for(var w=-1,b=0,p=-1,d=!0,n=0,c=y.length-1;c>=0;--c){var r=y.charCodeAt(c);if(r===47){if(!d){b=c+1;break}continue}p===-1&&(d=!1,p=c+1),r===46?w===-1?w=c:n!==1&&(n=1):w!==-1&&(n=-1)}return w===-1||p===-1||n===0||n===1&&w===p-1&&w===b+1?"":y.slice(w,p)};function M(y,w){if(y.filter)return y.filter(w);for(var b=[],p=0;p<y.length;p++)w(y[p],p,y)&&b.push(y[p]);return b}var m="ab".substr(-1)==="b"?function(y,w,b){return y.substr(w,b)}:function(y,w,b){return w<0&&(w=y.length+w),y.substr(w,b)}}).call(this,F("_process"))},{_process:208}],206:[function(F,Q,j){(function(N){/*!
* Platform.js <https://mths.be/platform>
* Copyright 2014-2018 Benjamin Tan <https://bnjmnt4n.now.sh/>
* Copyright 2011-2013 John-David Dalton <http://allyoucanleet.com/>
* Available under MIT license <https://mths.be/mit>
*/(function(){"use strict";var v={function:!0,object:!0},C=v[typeof window]&&window||this,M=C,m=v[typeof j]&&j,y=v[typeof Q]&&Q&&!Q.nodeType&&Q,w=m&&y&&typeof N=="object"&&N;w&&(w.global===w||w.window===w||w.self===w)&&(C=w);var b=Math.pow(2,53)-1,p=/\bOpera/,d=this,n=Object.prototype,c=n.hasOwnProperty,r=n.toString;function i(g){return g=String(g),g.charAt(0).toUpperCase()+g.slice(1)}function o(g,_,E){var T={"10.0":"10","6.4":"10 Technical Preview","6.3":"8.1","6.2":"8","6.1":"Server 2008 R2 / 7","6.0":"Server 2008 / Vista","5.2":"Server 2003 / XP 64-bit","5.1":"XP","5.01":"2000 SP1","5.0":"2000","4.0":"NT","4.90":"ME"};return _&&E&&/^Win/i.test(g)&&!/^Windows Phone /i.test(g)&&(T=T[/[\d.]+$/.exec(g)])&&(g="Windows "+T),g=String(g),_&&E&&(g=g.replace(RegExp(_,"i"),E)),g=f(g.replace(/ ce$/i," CE").replace(/\bhpw/i,"web").replace(/\bMacintosh\b/,"Mac OS").replace(/_PowerPC\b/i," OS").replace(/\b(OS X) [^ \d]+/i,"$1").replace(/\bMac (OS X)\b/,"$1").replace(/\/(\d)/," $1").replace(/_/g,".").replace(/(?: BePC|[ .]*fc[ \d.]+)$/i,"").replace(/\bx86\.64\b/gi,"x86_64").replace(/\b(Windows Phone) OS\b/,"$1").replace(/\b(Chrome OS \w+) [\d.]+\b/,"$1").split(" on ")[0]),g}function u(g,_){var E=-1,T=g?g.length:0;if(typeof T=="number"&&T>-1&&T<=b)for(;++E<T;)_(g[E],E,g);else s(g,_)}function f(g){return g=h(g),/^(?:webOS|i(?:OS|P))/.test(g)?g:i(g)}function s(g,_){for(var E in g)c.call(g,E)&&_(g[E],E,g)}function l(g){return g==null?i(g):r.call(g).slice(8,-1)}function t(g,_){var E=g!=null?typeof g[_]:"number";return!/^(?:boolean|number|string|undefined)$/.test(E)&&(E=="object"?!!g[_]:!0)}function S(g){return String(g).replace(/([ -])(?!$)/g,"$1?")}function x(g,_){var E=null;return u(g,function(T,L){E=_(E,T,L,g)}),E}function h(g){return String(g).replace(/^ +| +$/g,"")}function R(g){var _=C,E=g&&typeof g=="object"&&l(g)!="String";E&&(_=g,g=null);var T=_.navigator||{},L=T.userAgent||"";g||(g=L);var I=E||d==M,P=E?!!T.likeChrome:/\bChrome\b/.test(g)&&!/internal|\n/i.test(r.toString()),G="Object",W=E?G:"ScriptBridgingProxyObject",H=E?G:"Environment",z=E&&_.java?"JavaPackage":l(_.java),B=E?G:"RuntimeObject",k=/\bJava/.test(z)&&_.java,K=k&&l(_.environment)==H,Y=k?"a":"\u03B1",ne=k?"b":"\u03B2",oe=_.document||{},_e=_.operamini||_.opera,xe=p.test(xe=E&&_e?_e["[[Class]]"]:l(_e))?xe:_e=null,le,me=g,de=[],ae=null,ie=g==L,q=ie&&_e&&typeof _e.version=="function"&&_e.version(),ue,Z=X([{label:"EdgeHTML",pattern:"Edge"},"Trident",{label:"WebKit",pattern:"AppleWebKit"},"iCab","Presto","NetFront","Tasman","KHTML","Gecko"]),ee=ge(["Adobe AIR","Arora","Avant Browser","Breach","Camino","Electron","Epiphany","Fennec","Flock","Galeon","GreenBrowser","iCab","Iceweasel","K-Meleon","Konqueror","Lunascape","Maxthon",{label:"Microsoft Edge",pattern:"Edge"},"Midori","Nook Browser","PaleMoon","PhantomJS","Raven","Rekonq","RockMelt",{label:"Samsung Internet",pattern:"SamsungBrowser"},"SeaMonkey",{label:"Silk",pattern:"(?:Cloud9|Silk-Accelerated)"},"Sleipnir","SlimBrowser",{label:"SRWare Iron",pattern:"Iron"},"Sunrise","Swiftfox","Waterfox","WebPositive","Opera Mini",{label:"Opera Mini",pattern:"OPiOS"},"Opera",{label:"Opera",pattern:"OPR"},"Chrome",{label:"Chrome Mobile",pattern:"(?:CriOS|CrMo)"},{label:"Firefox",pattern:"(?:Firefox|Minefield)"},{label:"Firefox for iOS",pattern:"FxiOS"},{label:"IE",pattern:"IEMobile"},{label:"IE",pattern:"MSIE"},"Safari"]),Ee=Te([{label:"BlackBerry",pattern:"BB10"},"BlackBerry",{label:"Galaxy S",pattern:"GT-I9000"},{label:"Galaxy S2",pattern:"GT-I9100"},{label:"Galaxy S3",pattern:"GT-I9300"},{label:"Galaxy S4",pattern:"GT-I9500"},{label:"Galaxy S5",pattern:"SM-G900"},{label:"Galaxy S6",pattern:"SM-G920"},{label:"Galaxy S6 Edge",pattern:"SM-G925"},{label:"Galaxy S7",pattern:"SM-G930"},{label:"Galaxy S7 Edge",pattern:"SM-G935"},"Google TV","Lumia","iPad","iPod","iPhone","Kindle",{label:"Kindle Fire",pattern:"(?:Cloud9|Silk-Accelerated)"},"Nexus","Nook","PlayBook","PlayStation Vita","PlayStation","TouchPad","Transformer",{label:"Wii U",pattern:"WiiU"},"Wii","Xbox One",{label:"Xbox 360",pattern:"Xbox"},"Xoom"]),te=$({Apple:{iPad:1,iPhone:1,iPod:1},Archos:{},Amazon:{Kindle:1,"Kindle Fire":1},Asus:{Transformer:1},"Barnes & Noble":{Nook:1},BlackBerry:{PlayBook:1},Google:{"Google TV":1,Nexus:1},HP:{TouchPad:1},HTC:{},LG:{},Microsoft:{Xbox:1,"Xbox One":1},Motorola:{Xoom:1},Nintendo:{"Wii U":1,Wii:1},Nokia:{Lumia:1},Samsung:{"Galaxy S":1,"Galaxy S2":1,"Galaxy S3":1,"Galaxy S4":1},Sony:{PlayStation:1,"PlayStation Vita":1}}),J=fe(["Windows Phone","Android","CentOS",{label:"Chrome OS",pattern:"CrOS"},"Debian","Fedora","FreeBSD","Gentoo","Haiku","Kubuntu","Linux Mint","OpenBSD","Red Hat","SuSE","Ubuntu","Xubuntu","Cygwin","Symbian OS","hpwOS","webOS ","webOS","Tablet OS","Tizen","Linux","Mac OS X","Macintosh","Mac","Windows 98;","Windows "]);function X(rt){return x(rt,function(at,ot){return at||RegExp("\\b"+(ot.pattern||S(ot))+"\\b","i").exec(g)&&(ot.label||ot)})}function $(rt){return x(rt,function(at,ot,Pe){return at||(ot[Ee]||ot[/^[a-z]+(?: +[a-z]+\b)*/i.exec(Ee)]||RegExp("\\b"+S(Pe)+"(?:\\b|\\w*\\d)","i").exec(g))&&Pe})}function ge(rt){return x(rt,function(at,ot){return at||RegExp("\\b"+(ot.pattern||S(ot))+"\\b","i").exec(g)&&(ot.label||ot)})}function fe(rt){return x(rt,function(at,ot){var Pe=ot.pattern||S(ot);return!at&&(at=RegExp("\\b"+Pe+"(?:/[\\d.]+|[ \\w.]*)","i").exec(g))&&(at=o(at,Pe,ot.label||ot)),at})}function Te(rt){return x(rt,function(at,ot){var Pe=ot.pattern||S(ot);return!at&&(at=RegExp("\\b"+Pe+" *\\d+[.\\w_]*","i").exec(g)||RegExp("\\b"+Pe+" *\\w+-[\\w]*","i").exec(g)||RegExp("\\b"+Pe+"(?:; *(?:[a-z]+[_-])?[a-z]+\\d+|[^ ();-]*)","i").exec(g))&&((at=String(ot.label&&!RegExp(Pe,"i").test(ot.label)?ot.label:at).split("/"))[1]&&!/[\d.]+/.test(at[0])&&(at[0]+=" "+at[1]),ot=ot.label||ot,at=f(at[0].replace(RegExp(Pe,"i"),ot).replace(RegExp("; *(?:"+ot+"[_-])?","i")," ").replace(RegExp("("+ot+")[-_.]?(\\w)","i"),"$1 $2"))),at})}function ze(rt){return x(rt,function(at,ot){return at||(RegExp(ot+"(?:-[\\d.]+/|(?: for [\\w-]+)?[ /-])([\\d.]+[^ ();/_-]*)","i").exec(g)||0)[1]||null})}function Xe(){return this.description||""}if(Z&&(Z=[Z]),te&&!Ee&&(Ee=Te([te])),(le=/\bGoogle TV\b/.exec(Ee))&&(Ee=le[0]),/\bSimulator\b/i.test(g)&&(Ee=(Ee?Ee+" ":"")+"Simulator"),ee=="Opera Mini"&&/\bOPiOS\b/.test(g)&&de.push("running in Turbo/Uncompressed mode"),ee=="IE"&&/\blike iPhone OS\b/.test(g)?(le=R(g.replace(/like iPhone OS/,"")),te=le.manufacturer,Ee=le.product):/^iP/.test(Ee)?(ee||(ee="Safari"),J="iOS"+((le=/ OS ([\d_]+)/i.exec(g))?" "+le[1].replace(/_/g,"."):"")):ee=="Konqueror"&&!/buntu/i.test(J)?J="Kubuntu":te&&te!="Google"&&(/Chrome/.test(ee)&&!/\bMobile Safari\b/i.test(g)||/\bVita\b/.test(Ee))||/\bAndroid\b/.test(J)&&/^Chrome/.test(ee)&&/\bVersion\//i.test(g)?(ee="Android Browser",J=/\bAndroid\b/.test(J)?J:"Android"):ee=="Silk"?(/\bMobi/i.test(g)||(J="Android",de.unshift("desktop mode")),/Accelerated *= *true/i.test(g)&&de.unshift("accelerated")):ee=="PaleMoon"&&(le=/\bFirefox\/([\d.]+)\b/.exec(g))?de.push("identifying as Firefox "+le[1]):ee=="Firefox"&&(le=/\b(Mobile|Tablet|TV)\b/i.exec(g))?(J||(J="Firefox OS"),Ee||(Ee=le[1])):!ee||(le=!/\bMinefield\b/i.test(g)&&/\b(?:Firefox|Safari)\b/.exec(ee))?(ee&&!Ee&&/[\/,]|^[^(]+?\)/.test(g.slice(g.indexOf(le+"/")+8))&&(ee=null),(le=Ee||te||J)&&(Ee||te||/\b(?:Android|Symbian OS|Tablet OS|webOS)\b/.test(J))&&(ee=/[a-z]+(?: Hat)?/i.exec(/\bAndroid\b/.test(J)?J:le)+" Browser")):ee=="Electron"&&(le=(/\bChrome\/([\d.]+)\b/.exec(g)||0)[1])&&de.push("Chromium "+le),q||(q=ze(["(?:Cloud9|CriOS|CrMo|Edge|FxiOS|IEMobile|Iron|Opera ?Mini|OPiOS|OPR|Raven|SamsungBrowser|Silk(?!/[\\d.]+$))","Version",S(ee),"(?:Firefox|Minefield|NetFront)"])),(le=Z=="iCab"&&parseFloat(q)>3&&"WebKit"||/\bOpera\b/.test(ee)&&(/\bOPR\b/.test(g)?"Blink":"Presto")||/\b(?:Midori|Nook|Safari)\b/i.test(g)&&!/^(?:Trident|EdgeHTML)$/.test(Z)&&"WebKit"||!Z&&/\bMSIE\b/i.test(g)&&(J=="Mac OS"?"Tasman":"Trident")||Z=="WebKit"&&/\bPlayStation\b(?! Vita\b)/i.test(ee)&&"NetFront")&&(Z=[le]),ee=="IE"&&(le=(/; *(?:XBLWP|ZuneWP)(\d+)/i.exec(g)||0)[1])?(ee+=" Mobile",J="Windows Phone "+(/\+$/.test(le)?le:le+".x"),de.unshift("desktop mode")):/\bWPDesktop\b/i.test(g)?(ee="IE Mobile",J="Windows Phone 8.x",de.unshift("desktop mode"),q||(q=(/\brv:([\d.]+)/.exec(g)||0)[1])):ee!="IE"&&Z=="Trident"&&(le=/\brv:([\d.]+)/.exec(g))&&(ee&&de.push("identifying as "+ee+(q?" "+q:"")),ee="IE",q=le[1]),ie){if(t(_,"global"))if(k&&(le=k.lang.System,me=le.getProperty("os.arch"),J=J||le.getProperty("os.name")+" "+le.getProperty("os.version")),K){try{q=_.require("ringo/engine").version.join("."),ee="RingoJS"}catch(rt){(le=_.system)&&le.global.system==_.system&&(ee="Narwhal",J||(J=le[0].os||null))}ee||(ee="Rhino")}else typeof _.process=="object"&&!_.process.browser&&(le=_.process)&&(typeof le.versions=="object"&&(typeof le.versions.electron=="string"?(de.push("Node "+le.versions.node),ee="Electron",q=le.versions.electron):typeof le.versions.nw=="string"&&(de.push("Chromium "+q,"Node "+le.versions.node),ee="NW.js",q=le.versions.nw)),ee||(ee="Node.js",me=le.arch,J=le.platform,q=/[\d.]+/.exec(le.version),q=q?q[0]:null));else l(le=_.runtime)==W?(ee="Adobe AIR",J=le.flash.system.Capabilities.os):l(le=_.phantom)==B?(ee="PhantomJS",q=(le=le.version||null)&&le.major+"."+le.minor+"."+le.patch):typeof oe.documentMode=="number"&&(le=/\bTrident\/(\d+)/i.exec(g))?(q=[q,oe.documentMode],(le=+le[1]+4)!=q[1]&&(de.push("IE "+q[1]+" mode"),Z&&(Z[1]=""),q[1]=le),q=ee=="IE"?String(q[1].toFixed(1)):q[0]):typeof oe.documentMode=="number"&&/^(?:Chrome|Firefox)\b/.test(ee)&&(de.push("masking as "+ee+" "+q),ee="IE",q="11.0",Z=["Trident"],J="Windows");J=J&&f(J)}if(q&&(le=/(?:[ab]|dp|pre|[ab]\d+pre)(?:\d+\+?)?$/i.exec(q)||/(?:alpha|beta)(?: ?\d)?/i.exec(g+";"+(ie&&T.appMinorVersion))||/\bMinefield\b/i.test(g)&&"a")&&(ae=/b/i.test(le)?"beta":"alpha",q=q.replace(RegExp(le+"\\+?$"),"")+(ae=="beta"?ne:Y)+(/\d+\+?/.exec(le)||"")),ee=="Fennec"||ee=="Firefox"&&/\b(?:Android|Firefox OS)\b/.test(J))ee="Firefox Mobile";else if(ee=="Maxthon"&&q)q=q.replace(/\.[\d.]+/,".x");else if(/\bXbox\b/i.test(Ee))Ee=="Xbox 360"&&(J=null),Ee=="Xbox 360"&&/\bIEMobile\b/.test(g)&&de.unshift("mobile mode");else if((/^(?:Chrome|IE|Opera)$/.test(ee)||ee&&!Ee&&!/Browser|Mobi/.test(ee))&&(J=="Windows CE"||/Mobi/i.test(g)))ee+=" Mobile";else if(ee=="IE"&&ie)try{_.external===null&&de.unshift("platform preview")}catch(rt){de.unshift("embedded")}else(/\bBlackBerry\b/.test(Ee)||/\bBB10\b/.test(g))&&(le=(RegExp(Ee.replace(/ +/g," *")+"/([.\\d]+)","i").exec(g)||0)[1]||q)?(le=[le,/BB10/.test(g)],J=(le[1]?(Ee=null,te="BlackBerry"):"Device Software")+" "+le[0],q=null):this!=s&&Ee!="Wii"&&(ie&&_e||/Opera/.test(ee)&&/\b(?:MSIE|Firefox)\b/i.test(g)||ee=="Firefox"&&/\bOS X (?:\d+\.){2,}/.test(J)||ee=="IE"&&(J&&!/^Win/.test(J)&&q>5.5||/\bWindows XP\b/.test(J)&&q>8||q==8&&!/\bTrident\b/.test(g)))&&!p.test(le=R.call(s,g.replace(p,"")+";"))&&le.name&&(le="ing as "+le.name+((le=le.version)?" "+le:""),p.test(ee)?(/\bIE\b/.test(le)&&J=="Mac OS"&&(J=null),le="identify"+le):(le="mask"+le,xe?ee=f(xe.replace(/([a-z])([A-Z])/g,"$1 $2")):ee="Opera",/\bIE\b/.test(le)&&(J=null),ie||(q=null)),Z=["Presto"],de.push(le));(le=(/\bAppleWebKit\/([\d.]+\+?)/i.exec(g)||0)[1])&&(le=[parseFloat(le.replace(/\.(\d)$/,".0$1")),le],ee=="Safari"&&le[1].slice(-1)=="+"?(ee="WebKit Nightly",ae="alpha",q=le[1].slice(0,-1)):(q==le[1]||q==(le[2]=(/\bSafari\/([\d.]+\+?)/i.exec(g)||0)[1]))&&(q=null),le[1]=(/\bChrome\/([\d.]+)/i.exec(g)||0)[1],le[0]==537.36&&le[2]==537.36&&parseFloat(le[1])>=28&&Z=="WebKit"&&(Z=["Blink"]),!ie||!P&&!le[1]?(Z&&(Z[1]="like Safari"),le=(le=le[0],le<400?1:le<500?2:le<526?3:le<533?4:le<534?"4+":le<535?5:le<537?6:le<538?7:le<601?8:"8")):(Z&&(Z[1]="like Chrome"),le=le[1]||(le=le[0],le<530?1:le<532?2:le<532.05?3:le<533?4:le<534.03?5:le<534.07?6:le<534.1?7:le<534.13?8:le<534.16?9:le<534.24?10:le<534.3?11:le<535.01?12:le<535.02?"13+":le<535.07?15:le<535.11?16:le<535.19?17:le<536.05?18:le<536.1?19:le<537.01?20:le<537.11?"21+":le<537.13?23:le<537.18?24:le<537.24?25:le<537.36?26:Z!="Blink"?"27":"28")),Z&&(Z[1]+=" "+(le+=typeof le=="number"?".x":/[.+]/.test(le)?"":"+")),ee=="Safari"&&(!q||parseInt(q)>45)&&(q=le)),ee=="Opera"&&(le=/\bzbov|zvav$/.exec(J))?(ee+=" ",de.unshift("desktop mode"),le=="zvav"?(ee+="Mini",q=null):ee+="Mobile",J=J.replace(RegExp(" *"+le+"$"),"")):ee=="Safari"&&/\bChrome\b/.exec(Z&&Z[1])&&(de.unshift("desktop mode"),ee="Chrome Mobile",q=null,/\bOS X\b/.test(J)?(te="Apple",J="iOS 4.3+"):J=null),q&&q.indexOf(le=/[\d.]+$/.exec(J))==0&&g.indexOf("/"+le+"-")>-1&&(J=h(J.replace(le,""))),Z&&!/\b(?:Avant|Nook)\b/.test(ee)&&(/Browser|Lunascape|Maxthon/.test(ee)||ee!="Safari"&&/^iOS/.test(J)&&/\bSafari\b/.test(Z[1])||/^(?:Adobe|Arora|Breach|Midori|Opera|Phantom|Rekonq|Rock|Samsung Internet|Sleipnir|Web)/.test(ee)&&Z[1])&&((le=Z[Z.length-1])&&de.push(le)),de.length&&(de=["("+de.join("; ")+")"]),te&&Ee&&Ee.indexOf(te)<0&&de.push("on "+te),Ee&&de.push((/^on /.test(de[de.length-1])?"":"on ")+Ee),J&&(le=/ ([\d.+]+)$/.exec(J),ue=le&&J.charAt(J.length-le[0].length-1)=="/",J={architecture:32,family:le&&!ue?J.replace(le[0],""):J,version:le?le[1]:null,toString:function(){var rt=this.version;return this.family+(rt&&!ue?" "+rt:"")+(this.architecture==64?" 64-bit":"")}}),(le=/\b(?:AMD|IA|Win|WOW|x86_|x)64\b/i.exec(me))&&!/\bi686\b/i.test(me)?(J&&(J.architecture=64,J.family=J.family.replace(RegExp(" *"+le),"")),ee&&(/\bWOW64\b/i.test(g)||ie&&/\w(?:86|32)$/.test(T.cpuClass||T.platform)&&!/\bWin64; x64\b/i.test(g))&&de.unshift("32-bit")):J&&/^OS X/.test(J.family)&&ee=="Chrome"&&parseFloat(q)>=39&&(J.architecture=64),g||(g=null);var Ye={};return Ye.description=g,Ye.layout=Z&&Z[0],Ye.manufacturer=te,Ye.name=ee,Ye.prerelease=ae,Ye.product=Ee,Ye.ua=g,Ye.version=ee&&q,Ye.os=J||{architecture:null,family:null,version:null,toString:function(){return"null"}},Ye.parse=R,Ye.toString=Xe,Ye.version&&de.unshift(q),Ye.name&&de.unshift(ee),J&&ee&&!(J==String(J).split(" ")[0]&&(J==ee.split(" ")[0]||Ee))&&de.push(Ee?"("+J+")":"on "+J),de.length&&(Ye.description=de.join(" ")),Ye}var O=R();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(C.platform=O,define(function(){return O})):m&&y?s(O,function(g,_){m[_]=g}):C.platform=O}).call(this)}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],207:[function(F,Q,j){(function(N){"use strict";typeof N=="undefined"||!N.version||N.version.indexOf("v0.")===0||N.version.indexOf("v1.")===0&&N.version.indexOf("v1.8.")!==0?Q.exports={nextTick:v}:Q.exports=N;function v(C,M,m,y){if(typeof C!="function")throw new TypeError('"callback" argument must be a function');var w=arguments.length,b,p;switch(w){case 0:case 1:return N.nextTick(C);case 2:return N.nextTick(function(){C.call(null,M)});case 3:return N.nextTick(function(){C.call(null,M,m)});case 4:return N.nextTick(function(){C.call(null,M,m,y)});default:for(b=new Array(w-1),p=0;p<b.length;)b[p++]=arguments[p];return N.nextTick(function(){C.apply(null,b)})}}}).call(this,F("_process"))},{_process:208}],208:[function(F,Q,j){var N=Q.exports={},v,C;function M(){throw new Error("setTimeout has not been defined")}function m(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?v=setTimeout:v=M}catch(u){v=M}try{typeof clearTimeout=="function"?C=clearTimeout:C=m}catch(u){C=m}})();function y(u){if(v===setTimeout)return setTimeout(u,0);if((v===M||!v)&&setTimeout)return v=setTimeout,setTimeout(u,0);try{return v(u,0)}catch(f){try{return v.call(null,u,0)}catch(s){return v.call(this,u,0)}}}function w(u){if(C===clearTimeout)return clearTimeout(u);if((C===m||!C)&&clearTimeout)return C=clearTimeout,clearTimeout(u);try{return C(u)}catch(f){try{return C.call(null,u)}catch(s){return C.call(this,u)}}}var b=[],p=!1,d,n=-1;function c(){if(!p||!d)return;p=!1,d.length?b=d.concat(b):n=-1,b.length&&r()}function r(){if(p)return;var u=y(c);p=!0;for(var f=b.length;f;){for(d=b,b=[];++n<f;)d&&d[n].run();n=-1,f=b.length}d=null,p=!1,w(u)}N.nextTick=function(u){var f=new Array(arguments.length-1);if(arguments.length>1)for(var s=1;s<arguments.length;s++)f[s-1]=arguments[s];b.push(new i(u,f)),b.length===1&&!p&&y(r)};function i(u,f){this.fun=u,this.array=f}i.prototype.run=function(){this.fun.apply(null,this.array)},N.title="browser",N.browser=!0,N.env={},N.argv=[],N.version="",N.versions={};function o(){}N.on=o,N.addListener=o,N.once=o,N.off=o,N.removeListener=o,N.removeAllListeners=o,N.emit=o,N.prependListener=o,N.prependOnceListener=o,N.listeners=function(u){return[]},N.binding=function(u){throw new Error("process.binding is not supported")},N.cwd=function(){return"/"},N.chdir=function(u){throw new Error("process.chdir is not supported")},N.umask=function(){return 0}},{}],209:[function(F,Q,j){(function(N){/*! https://mths.be/punycode v1.4.1 by @mathias */(function(v){var C=typeof j=="object"&&j&&!j.nodeType&&j,M=typeof Q=="object"&&Q&&!Q.nodeType&&Q,m=typeof N=="object"&&N;(m.global===m||m.window===m||m.self===m)&&(v=m);var y,w=2147483647,b=36,p=1,d=26,n=38,c=700,r=72,i=128,o="-",u=/^xn--/,f=/[^\x20-\x7E]/,s=/[\x2E\u3002\uFF0E\uFF61]/g,l={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},t=b-p,S=Math.floor,x=String.fromCharCode,h;function R(z){throw new RangeError(l[z])}function O(z,B){for(var k=z.length,K=[];k--;)K[k]=B(z[k]);return K}function g(z,B){var k=z.split("@"),K="";k.length>1&&(K=k[0]+"@",z=k[1]),z=z.replace(s,".");var Y=z.split("."),ne=O(Y,B).join(".");return K+ne}function _(z){for(var B=[],k=0,K=z.length,Y,ne;k<K;)Y=z.charCodeAt(k++),Y>=55296&&Y<=56319&&k<K?(ne=z.charCodeAt(k++),(ne&64512)==56320?B.push(((Y&1023)<<10)+(ne&1023)+65536):(B.push(Y),k--)):B.push(Y);return B}function E(z){return O(z,function(B){var k="";return B>65535&&(B-=65536,k+=x(B>>>10&1023|55296),B=56320|B&1023),k+=x(B),k}).join("")}function T(z){return z-48<10?z-22:z-65<26?z-65:z-97<26?z-97:b}function L(z,B){return z+22+75*(z<26)-((B!=0)<<5)}function I(z,B,k){var K=0;for(z=k?S(z/c):z>>1,z+=S(z/B);z>t*d>>1;K+=b)z=S(z/t);return S(K+(t+1)*z/(z+n))}function P(z){var B=[],k=z.length,K,Y=0,ne=i,oe=r,_e,xe,le,me,de,ae,ie,q,ue;for(_e=z.lastIndexOf(o),_e<0&&(_e=0),xe=0;xe<_e;++xe)z.charCodeAt(xe)>=128&&R("not-basic"),B.push(z.charCodeAt(xe));for(le=_e>0?_e+1:0;le<k;){for(me=Y,de=1,ae=b;!(le>=k&&R("invalid-input"),ie=T(z.charCodeAt(le++)),(ie>=b||ie>S((w-Y)/de))&&R("overflow"),Y+=ie*de,q=ae<=oe?p:ae>=oe+d?d:ae-oe,ie<q);ae+=b)ue=b-q,de>S(w/ue)&&R("overflow"),de*=ue;K=B.length+1,oe=I(Y-me,K,me==0),S(Y/K)>w-ne&&R("overflow"),ne+=S(Y/K),Y%=K,B.splice(Y++,0,ne)}return E(B)}function G(z){var B,k,K,Y,ne,oe,_e,xe,le,me,de,ae=[],ie,q,ue,Z;for(z=_(z),ie=z.length,B=i,k=0,ne=r,oe=0;oe<ie;++oe)de=z[oe],de<128&&ae.push(x(de));for(K=Y=ae.length,Y&&ae.push(o);K<ie;){for(_e=w,oe=0;oe<ie;++oe)de=z[oe],de>=B&&de<_e&&(_e=de);for(q=K+1,_e-B>S((w-k)/q)&&R("overflow"),k+=(_e-B)*q,B=_e,oe=0;oe<ie;++oe)if(de=z[oe],de<B&&++k>w&&R("overflow"),de==B){for(xe=k,le=b;!(me=le<=ne?p:le>=ne+d?d:le-ne,xe<me);le+=b)Z=xe-me,ue=b-me,ae.push(x(L(me+Z%ue,0))),xe=S(Z/ue);ae.push(x(L(xe,0))),ne=I(k,q,K==Y),k=0,++K}++k,++B}return ae.join("")}function W(z){return g(z,function(B){return u.test(B)?P(B.slice(4).toLowerCase()):B})}function H(z){return g(z,function(B){return f.test(B)?"xn--"+G(B):B})}if(y={version:"1.4.1",ucs2:{decode:_,encode:E},decode:P,encode:G,toASCII:H,toUnicode:W},typeof define=="function"&&typeof define.amd=="object"&&define.amd)define("punycode",function(){return y});else if(C&&M)if(Q.exports==C)M.exports=y;else for(h in y)y.hasOwnProperty(h)&&(C[h]=y[h]);else v.punycode=y})(this)}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],210:[function(F,Q,j){"use strict";function N(C,M){return Object.prototype.hasOwnProperty.call(C,M)}Q.exports=function(C,M,m,y){M=M||"&",m=m||"=";var w={};if(typeof C!="string"||C.length===0)return w;var b=/\+/g;C=C.split(M);var p=1e3;y&&typeof y.maxKeys=="number"&&(p=y.maxKeys);var d=C.length;p>0&&d>p&&(d=p);for(var n=0;n<d;++n){var c=C[n].replace(b,"%20"),r=c.indexOf(m),i,o,u,f;r>=0?(i=c.substr(0,r),o=c.substr(r+1)):(i=c,o=""),u=decodeURIComponent(i),f=decodeURIComponent(o),N(w,u)?v(w[u])?w[u].push(f):w[u]=[w[u],f]:w[u]=f}return w};var v=Array.isArray||function(C){return Object.prototype.toString.call(C)==="[object Array]"}},{}],211:[function(F,Q,j){"use strict";var N=function(m){switch(typeof m){case"string":return m;case"boolean":return m?"true":"false";case"number":return isFinite(m)?m:"";default:return""}};Q.exports=function(m,y,w,b){return y=y||"&",w=w||"=",m===null&&(m=void 0),typeof m=="object"?C(M(m),function(p){var d=encodeURIComponent(N(p))+w;return v(m[p])?C(m[p],function(n){return d+encodeURIComponent(N(n))}).join(y):d+encodeURIComponent(N(m[p]))}).join(y):b?encodeURIComponent(N(b))+w+encodeURIComponent(N(m)):""};var v=Array.isArray||function(m){return Object.prototype.toString.call(m)==="[object Array]"};function C(m,y){if(m.map)return m.map(y);for(var w=[],b=0;b<m.length;b++)w.push(y(m[b],b));return w}var M=Object.keys||function(m){var y=[];for(var w in m)Object.prototype.hasOwnProperty.call(m,w)&&y.push(w);return y}},{}],212:[function(F,Q,j){"use strict";j.decode=j.parse=F("./decode"),j.encode=j.stringify=F("./encode")},{"./decode":210,"./encode":211}],213:[function(F,Q,j){Q.exports=F("./lib/_stream_duplex.js")},{"./lib/_stream_duplex.js":214}],214:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=m(N),C=F("babel-runtime/core-js/object/keys"),M=m(C);function m(f){return f&&f.__esModule?f:{default:f}}var y=F("process-nextick-args"),w=M.default||function(f){var s=[];for(var l in f)s.push(l);return s};Q.exports=i;var b=(0,v.default)(F("core-util-is"));b.inherits=F("inherits");var p=F("./_stream_readable"),d=F("./_stream_writable");b.inherits(i,p);for(var n=w(d.prototype),c=0;c<n.length;c++){var r=n[c];i.prototype[r]||(i.prototype[r]=d.prototype[r])}function i(f){if(!(this instanceof i))return new i(f);p.call(this,f),d.call(this,f),f&&f.readable===!1&&(this.readable=!1),f&&f.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,f&&f.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",o)}Object.defineProperty(i.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function o(){if(this.allowHalfOpen||this._writableState.ended)return;y.nextTick(u,this)}function u(f){f.end()}Object.defineProperty(i.prototype,"destroyed",{get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(s){if(this._readableState===void 0||this._writableState===void 0)return;this._readableState.destroyed=s,this._writableState.destroyed=s}}),i.prototype._destroy=function(f,s){this.push(null),this.end(),y.nextTick(s,f)}},{"./_stream_readable":216,"./_stream_writable":218,"babel-runtime/core-js/object/create":55,"babel-runtime/core-js/object/keys":60,"core-util-is":189,inherits:196,"process-nextick-args":207}],215:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(w){return w&&w.__esModule?w:{default:w}}Q.exports=y;var M=F("./_stream_transform"),m=(0,v.default)(F("core-util-is"));m.inherits=F("inherits"),m.inherits(y,M);function y(w){if(!(this instanceof y))return new y(w);M.call(this,w)}y.prototype._transform=function(w,b,p){p(null,w)}},{"./_stream_transform":217,"babel-runtime/core-js/object/create":55,"core-util-is":189,inherits:196}],216:[function(F,Q,j){(function(N,v){"use strict";var C=F("babel-runtime/core-js/object/get-prototype-of"),M=w(C),m=F("babel-runtime/core-js/object/create"),y=w(m);function w(Z){return Z&&Z.__esModule?Z:{default:Z}}var b=F("process-nextick-args");Q.exports=_;var p=F("isarray"),d;_.ReadableState=g;var n=F("events").EventEmitter,c=function(ee,Ee){return ee.listeners(Ee).length},r=F("./internal/streams/stream"),i=F("safe-buffer").Buffer,o=v.Uint8Array||function(){};function u(Z){return i.from(Z)}function f(Z){return i.isBuffer(Z)||Z instanceof o}var s=(0,y.default)(F("core-util-is"));s.inherits=F("inherits");var l=F("util"),t=void 0;l&&l.debuglog?t=l.debuglog("stream"):t=function(){};var S=F("./internal/streams/BufferList"),x=F("./internal/streams/destroy"),h;s.inherits(_,r);var R=["error","close","destroy","pause","resume"];function O(Z,ee,Ee){if(typeof Z.prependListener=="function")return Z.prependListener(ee,Ee);!Z._events||!Z._events[ee]?Z.on(ee,Ee):p(Z._events[ee])?Z._events[ee].unshift(Ee):Z._events[ee]=[Ee,Z._events[ee]]}function g(Z,ee){d=d||F("./_stream_duplex"),Z=Z||{};var Ee=ee instanceof d;this.objectMode=!!Z.objectMode,Ee&&(this.objectMode=this.objectMode||!!Z.readableObjectMode);var te=Z.highWaterMark,J=Z.readableHighWaterMark,X=this.objectMode?16:16*1024;te||te===0?this.highWaterMark=te:Ee&&(J||J===0)?this.highWaterMark=J:this.highWaterMark=X,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new S,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=Z.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,Z.encoding&&(h||(h=F("string_decoder/").StringDecoder),this.decoder=new h(Z.encoding),this.encoding=Z.encoding)}function _(Z){if(d=d||F("./_stream_duplex"),!(this instanceof _))return new _(Z);this._readableState=new g(Z,this),this.readable=!0,Z&&(typeof Z.read=="function"&&(this._read=Z.read),typeof Z.destroy=="function"&&(this._destroy=Z.destroy)),r.call(this)}Object.defineProperty(_.prototype,"destroyed",{get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(ee){if(!this._readableState)return;this._readableState.destroyed=ee}}),_.prototype.destroy=x.destroy,_.prototype._undestroy=x.undestroy,_.prototype._destroy=function(Z,ee){this.push(null),ee(Z)},_.prototype.push=function(Z,ee){var Ee=this._readableState,te;return Ee.objectMode?te=!0:typeof Z=="string"&&(ee=ee||Ee.defaultEncoding,ee!==Ee.encoding&&(Z=i.from(Z,ee),ee=""),te=!0),E(this,Z,ee,!1,te)},_.prototype.unshift=function(Z){return E(this,Z,null,!0,!1)};function E(Z,ee,Ee,te,J){var X=Z._readableState;if(ee===null)X.reading=!1,H(Z,X);else{var $;J||($=L(X,ee)),$?Z.emit("error",$):X.objectMode||ee&&ee.length>0?(typeof ee!="string"&&!X.objectMode&&(0,M.default)(ee)!==i.prototype&&(ee=u(ee)),te?X.endEmitted?Z.emit("error",new Error("stream.unshift() after end event")):T(Z,X,ee,!0):X.ended?Z.emit("error",new Error("stream.push() after EOF")):(X.reading=!1,X.decoder&&!Ee?(ee=X.decoder.write(ee),X.objectMode||ee.length!==0?T(Z,X,ee,!1):k(Z,X)):T(Z,X,ee,!1))):te||(X.reading=!1)}return I(X)}function T(Z,ee,Ee,te){ee.flowing&&ee.length===0&&!ee.sync?(Z.emit("data",Ee),Z.read(0)):(ee.length+=ee.objectMode?1:Ee.length,te?ee.buffer.unshift(Ee):ee.buffer.push(Ee),ee.needReadable&&z(Z)),k(Z,ee)}function L(Z,ee){var Ee;return!f(ee)&&typeof ee!="string"&&ee!==void 0&&!Z.objectMode&&(Ee=new TypeError("Invalid non-string/buffer chunk")),Ee}function I(Z){return!Z.ended&&(Z.needReadable||Z.length<Z.highWaterMark||Z.length===0)}_.prototype.isPaused=function(){return this._readableState.flowing===!1},_.prototype.setEncoding=function(Z){return h||(h=F("string_decoder/").StringDecoder),this._readableState.decoder=new h(Z),this._readableState.encoding=Z,this};var P=8388608;function G(Z){return Z>=P?Z=P:(Z--,Z|=Z>>>1,Z|=Z>>>2,Z|=Z>>>4,Z|=Z>>>8,Z|=Z>>>16,Z++),Z}function W(Z,ee){return Z<=0||ee.length===0&&ee.ended?0:ee.objectMode?1:Z!==Z?ee.flowing&&ee.length?ee.buffer.head.data.length:ee.length:(Z>ee.highWaterMark&&(ee.highWaterMark=G(Z)),Z<=ee.length?Z:ee.ended?ee.length:(ee.needReadable=!0,0))}_.prototype.read=function(Z){t("read",Z),Z=parseInt(Z,10);var ee=this._readableState,Ee=Z;if(Z!==0&&(ee.emittedReadable=!1),Z===0&&ee.needReadable&&(ee.length>=ee.highWaterMark||ee.ended))return t("read: emitReadable",ee.length,ee.ended),ee.length===0&&ee.ended?ie(this):z(this),null;if(Z=W(Z,ee),Z===0&&ee.ended)return ee.length===0&&ie(this),null;var te=ee.needReadable;t("need readable",te),(ee.length===0||ee.length-Z<ee.highWaterMark)&&(te=!0,t("length less than watermark",te)),ee.ended||ee.reading?(te=!1,t("reading or ended",te)):te&&(t("do read"),ee.reading=!0,ee.sync=!0,ee.length===0&&(ee.needReadable=!0),this._read(ee.highWaterMark),ee.sync=!1,ee.reading||(Z=W(Ee,ee)));var J;return Z>0?J=le(Z,ee):J=null,J===null?(ee.needReadable=!0,Z=0):ee.length-=Z,ee.length===0&&(ee.ended||(ee.needReadable=!0),Ee!==Z&&ee.ended&&ie(this)),J!==null&&this.emit("data",J),J};function H(Z,ee){if(ee.ended)return;if(ee.decoder){var Ee=ee.decoder.end();Ee&&Ee.length&&(ee.buffer.push(Ee),ee.length+=ee.objectMode?1:Ee.length)}ee.ended=!0,z(Z)}function z(Z){var ee=Z._readableState;ee.needReadable=!1,ee.emittedReadable||(t("emitReadable",ee.flowing),ee.emittedReadable=!0,ee.sync?b.nextTick(B,Z):B(Z))}function B(Z){t("emit readable"),Z.emit("readable"),xe(Z)}function k(Z,ee){ee.readingMore||(ee.readingMore=!0,b.nextTick(K,Z,ee))}function K(Z,ee){for(var Ee=ee.length;!ee.reading&&!ee.flowing&&!ee.ended&&ee.length<ee.highWaterMark&&!(t("maybeReadMore read 0"),Z.read(0),Ee===ee.length);)Ee=ee.length;ee.readingMore=!1}_.prototype._read=function(Z){this.emit("error",new Error("_read() is not implemented"))},_.prototype.pipe=function(Z,ee){var Ee=this,te=this._readableState;switch(te.pipesCount){case 0:te.pipes=Z;break;case 1:te.pipes=[te.pipes,Z];break;default:te.pipes.push(Z);break}te.pipesCount+=1,t("pipe count=%d opts=%j",te.pipesCount,ee);var J=(!ee||ee.end!==!1)&&Z!==N.stdout&&Z!==N.stderr,X=J?ge:Pe;te.endEmitted?b.nextTick(X):Ee.once("end",X),Z.on("unpipe",$);function $(Se,Je){t("onunpipe"),Se===Ee&&(Je&&Je.hasUnpiped===!1&&(Je.hasUnpiped=!0,ze()))}function ge(){t("onend"),Z.end()}var fe=Y(Ee);Z.on("drain",fe);var Te=!1;function ze(){t("cleanup"),Z.removeListener("close",at),Z.removeListener("finish",ot),Z.removeListener("drain",fe),Z.removeListener("error",rt),Z.removeListener("unpipe",$),Ee.removeListener("end",ge),Ee.removeListener("end",Pe),Ee.removeListener("data",Ye),Te=!0,te.awaitDrain&&(!Z._writableState||Z._writableState.needDrain)&&fe()}var Xe=!1;Ee.on("data",Ye);function Ye(Se){t("ondata"),Xe=!1;var Je=Z.write(Se);Je===!1&&!Xe&&((te.pipesCount===1&&te.pipes===Z||te.pipesCount>1&&ue(te.pipes,Z)!==-1)&&!Te&&(t("false write response, pause",Ee._readableState.awaitDrain),Ee._readableState.awaitDrain++,Xe=!0),Ee.pause())}function rt(Se){t("onerror",Se),Pe(),Z.removeListener("error",rt),c(Z,"error")===0&&Z.emit("error",Se)}O(Z,"error",rt);function at(){Z.removeListener("finish",ot),Pe()}Z.once("close",at);function ot(){t("onfinish"),Z.removeListener("close",at),Pe()}Z.once("finish",ot);function Pe(){t("unpipe"),Ee.unpipe(Z)}return Z.emit("pipe",Ee),te.flowing||(t("pipe resume"),Ee.resume()),Z};function Y(Z){return function(){var ee=Z._readableState;t("pipeOnDrain",ee.awaitDrain),ee.awaitDrain&&ee.awaitDrain--,ee.awaitDrain===0&&c(Z,"data")&&(ee.flowing=!0,xe(Z))}}_.prototype.unpipe=function(Z){var ee=this._readableState,Ee={hasUnpiped:!1};if(ee.pipesCount===0)return this;if(ee.pipesCount===1)return Z&&Z!==ee.pipes?this:(Z||(Z=ee.pipes),ee.pipes=null,ee.pipesCount=0,ee.flowing=!1,Z&&Z.emit("unpipe",this,Ee),this);if(!Z){var te=ee.pipes,J=ee.pipesCount;ee.pipes=null,ee.pipesCount=0,ee.flowing=!1;for(var X=0;X<J;X++)te[X].emit("unpipe",this,Ee);return this}var $=ue(ee.pipes,Z);return $===-1?this:(ee.pipes.splice($,1),ee.pipesCount-=1,ee.pipesCount===1&&(ee.pipes=ee.pipes[0]),Z.emit("unpipe",this,Ee),this)},_.prototype.on=function(Z,ee){var Ee=r.prototype.on.call(this,Z,ee);if(Z==="data")this._readableState.flowing!==!1&&this.resume();else if(Z==="readable"){var te=this._readableState;!te.endEmitted&&!te.readableListening&&(te.readableListening=te.needReadable=!0,te.emittedReadable=!1,te.reading?te.length&&z(this):b.nextTick(ne,this))}return Ee},_.prototype.addListener=_.prototype.on;function ne(Z){t("readable nexttick read 0"),Z.read(0)}_.prototype.resume=function(){var Z=this._readableState;return Z.flowing||(t("resume"),Z.flowing=!0,oe(this,Z)),this};function oe(Z,ee){ee.resumeScheduled||(ee.resumeScheduled=!0,b.nextTick(_e,Z,ee))}function _e(Z,ee){ee.reading||(t("resume read 0"),Z.read(0)),ee.resumeScheduled=!1,ee.awaitDrain=0,Z.emit("resume"),xe(Z),ee.flowing&&!ee.reading&&Z.read(0)}_.prototype.pause=function(){return t("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(t("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function xe(Z){var ee=Z._readableState;for(t("flow",ee.flowing);ee.flowing&&Z.read()!==null;);}_.prototype.wrap=function(Z){var ee=this,Ee=this._readableState,te=!1;Z.on("end",function(){if(t("wrapped end"),Ee.decoder&&!Ee.ended){var $=Ee.decoder.end();$&&$.length&&ee.push($)}ee.push(null)}),Z.on("data",function($){if(t("wrapped data"),Ee.decoder&&($=Ee.decoder.write($)),Ee.objectMode&&$==null)return;if(!Ee.objectMode&&(!$||!$.length))return;var ge=ee.push($);ge||(te=!0,Z.pause())});for(var J in Z)this[J]===void 0&&typeof Z[J]=="function"&&(this[J]=function($){return function(){return Z[$].apply(Z,arguments)}}(J));for(var X=0;X<R.length;X++)Z.on(R[X],this.emit.bind(this,R[X]));return this._read=function($){t("wrapped _read",$),te&&(te=!1,Z.resume())},this},Object.defineProperty(_.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),_._fromList=le;function le(Z,ee){if(ee.length===0)return null;var Ee;return ee.objectMode?Ee=ee.buffer.shift():!Z||Z>=ee.length?(ee.decoder?Ee=ee.buffer.join(""):ee.buffer.length===1?Ee=ee.buffer.head.data:Ee=ee.buffer.concat(ee.length),ee.buffer.clear()):Ee=me(Z,ee.buffer,ee.decoder),Ee}function me(Z,ee,Ee){var te;return Z<ee.head.data.length?(te=ee.head.data.slice(0,Z),ee.head.data=ee.head.data.slice(Z)):Z===ee.head.data.length?te=ee.shift():te=Ee?de(Z,ee):ae(Z,ee),te}function de(Z,ee){var Ee=ee.head,te=1,J=Ee.data;for(Z-=J.length;Ee=Ee.next;){var X=Ee.data,$=Z>X.length?X.length:Z;if($===X.length?J+=X:J+=X.slice(0,Z),Z-=$,Z===0){$===X.length?(++te,Ee.next?ee.head=Ee.next:ee.head=ee.tail=null):(ee.head=Ee,Ee.data=X.slice($));break}++te}return ee.length-=te,J}function ae(Z,ee){var Ee=i.allocUnsafe(Z),te=ee.head,J=1;for(te.data.copy(Ee),Z-=te.data.length;te=te.next;){var X=te.data,$=Z>X.length?X.length:Z;if(X.copy(Ee,Ee.length-Z,0,$),Z-=$,Z===0){$===X.length?(++J,te.next?ee.head=te.next:ee.head=ee.tail=null):(ee.head=te,te.data=X.slice($));break}++J}return ee.length-=J,Ee}function ie(Z){var ee=Z._readableState;if(ee.length>0)throw new Error('"endReadable()" called on non-empty stream');ee.endEmitted||(ee.ended=!0,b.nextTick(q,ee,Z))}function q(Z,ee){!Z.endEmitted&&Z.length===0&&(Z.endEmitted=!0,ee.readable=!1,ee.emit("end"))}function ue(Z,ee){for(var Ee=0,te=Z.length;Ee<te;Ee++)if(Z[Ee]===ee)return Ee;return-1}}).call(this,F("_process"),typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./_stream_duplex":214,"./internal/streams/BufferList":219,"./internal/streams/destroy":220,"./internal/streams/stream":221,_process:208,"babel-runtime/core-js/object/create":55,"babel-runtime/core-js/object/get-prototype-of":59,"core-util-is":189,events:192,inherits:196,isarray:198,"process-nextick-args":207,"safe-buffer":228,"string_decoder/":235,util:71}],217:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(d){return d&&d.__esModule?d:{default:d}}Q.exports=w;var M=F("./_stream_duplex"),m=(0,v.default)(F("core-util-is"));m.inherits=F("inherits"),m.inherits(w,M);function y(d,n){var c=this._transformState;c.transforming=!1;var r=c.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));c.writechunk=null,c.writecb=null,n!=null&&this.push(n),r(d);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function w(d){if(!(this instanceof w))return new w(d);M.call(this,d),this._transformState={afterTransform:y.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,d&&(typeof d.transform=="function"&&(this._transform=d.transform),typeof d.flush=="function"&&(this._flush=d.flush)),this.on("prefinish",b)}function b(){var d=this;typeof this._flush=="function"?this._flush(function(n,c){p(d,n,c)}):p(this,null,null)}w.prototype.push=function(d,n){return this._transformState.needTransform=!1,M.prototype.push.call(this,d,n)},w.prototype._transform=function(d,n,c){throw new Error("_transform() is not implemented")},w.prototype._write=function(d,n,c){var r=this._transformState;if(r.writecb=c,r.writechunk=d,r.writeencoding=n,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},w.prototype._read=function(d){var n=this._transformState;n.writechunk!==null&&n.writecb&&!n.transforming?(n.transforming=!0,this._transform(n.writechunk,n.writeencoding,n.afterTransform)):n.needTransform=!0},w.prototype._destroy=function(d,n){var c=this;M.prototype._destroy.call(this,d,function(r){n(r),c.emit("close")})};function p(d,n,c){if(n)return d.emit("error",n);if(c!=null&&d.push(c),d._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(d._transformState.transforming)throw new Error("Calling transform done when still transforming");return d.push(null)}},{"./_stream_duplex":214,"babel-runtime/core-js/object/create":55,"core-util-is":189,inherits:196}],218:[function(F,Q,j){(function(N,v){"use strict";var C=F("babel-runtime/core-js/object/define-property"),M=r(C),m=F("babel-runtime/core-js/symbol/has-instance"),y=r(m),w=F("babel-runtime/core-js/symbol"),b=r(w),p=F("babel-runtime/core-js/object/create"),d=r(p),n=F("babel-runtime/core-js/set-immediate"),c=r(n);function r(ae){return ae&&ae.__esModule?ae:{default:ae}}var i=F("process-nextick-args");Q.exports=L;function o(ae,ie,q){this.chunk=ae,this.encoding=ie,this.callback=q,this.next=null}function u(ae){var ie=this;this.next=null,this.entry=null,this.finish=function(){de(ie,ae)}}var f=!N.browser&&["v0.10","v0.9."].indexOf(N.version.slice(0,5))>-1?c.default:i.nextTick,s;L.WritableState=E;var l=(0,d.default)(F("core-util-is"));l.inherits=F("inherits");var t={deprecate:F("util-deprecate")},S=F("./internal/streams/stream"),x=F("safe-buffer").Buffer,h=v.Uint8Array||function(){};function R(ae){return x.from(ae)}function O(ae){return x.isBuffer(ae)||ae instanceof h}var g=F("./internal/streams/destroy");l.inherits(L,S);function _(){}function E(ae,ie){s=s||F("./_stream_duplex"),ae=ae||{};var q=ie instanceof s;this.objectMode=!!ae.objectMode,q&&(this.objectMode=this.objectMode||!!ae.writableObjectMode);var ue=ae.highWaterMark,Z=ae.writableHighWaterMark,ee=this.objectMode?16:16*1024;ue||ue===0?this.highWaterMark=ue:q&&(Z||Z===0)?this.highWaterMark=Z:this.highWaterMark=ee,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var Ee=ae.decodeStrings===!1;this.decodeStrings=!Ee,this.defaultEncoding=ae.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(te){k(ie,te)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new u(this)}E.prototype.getBuffer=function(){for(var ie=this.bufferedRequest,q=[];ie;)q.push(ie),ie=ie.next;return q},function(){try{Object.defineProperty(E.prototype,"buffer",{get:t.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(ae){}}();var T;typeof b.default=="function"&&y.default&&typeof Function.prototype[y.default]=="function"?(T=Function.prototype[y.default],(0,M.default)(L,y.default,{value:function(ie){return T.call(this,ie)?!0:this!==L?!1:ie&&ie._writableState instanceof E}})):T=function(ie){return ie instanceof this};function L(ae){if(s=s||F("./_stream_duplex"),!T.call(L,this)&&!(this instanceof s))return new L(ae);this._writableState=new E(ae,this),this.writable=!0,ae&&(typeof ae.write=="function"&&(this._write=ae.write),typeof ae.writev=="function"&&(this._writev=ae.writev),typeof ae.destroy=="function"&&(this._destroy=ae.destroy),typeof ae.final=="function"&&(this._final=ae.final)),S.call(this)}L.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function I(ae,ie){var q=new Error("write after end");ae.emit("error",q),i.nextTick(ie,q)}function P(ae,ie,q,ue){var Z=!0,ee=!1;return q===null?ee=new TypeError("May not write null values to stream"):typeof q!="string"&&q!==void 0&&!ie.objectMode&&(ee=new TypeError("Invalid non-string/buffer chunk")),ee&&(ae.emit("error",ee),i.nextTick(ue,ee),Z=!1),Z}L.prototype.write=function(ae,ie,q){var ue=this._writableState,Z=!1,ee=!ue.objectMode&&O(ae);return ee&&!x.isBuffer(ae)&&(ae=R(ae)),typeof ie=="function"&&(q=ie,ie=null),ee?ie="buffer":ie||(ie=ue.defaultEncoding),typeof q!="function"&&(q=_),ue.ended?I(this,q):(ee||P(this,ue,ae,q))&&(ue.pendingcb++,Z=W(this,ue,ee,ae,ie,q)),Z},L.prototype.cork=function(){var ae=this._writableState;ae.corked++},L.prototype.uncork=function(){var ae=this._writableState;ae.corked&&(ae.corked--,!ae.writing&&!ae.corked&&!ae.finished&&!ae.bufferProcessing&&ae.bufferedRequest&&ne(this,ae))},L.prototype.setDefaultEncoding=function(ie){if(typeof ie=="string"&&(ie=ie.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((ie+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+ie);return this._writableState.defaultEncoding=ie,this};function G(ae,ie,q){return!ae.objectMode&&ae.decodeStrings!==!1&&typeof ie=="string"&&(ie=x.from(ie,q)),ie}Object.defineProperty(L.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function W(ae,ie,q,ue,Z,ee){if(!q){var Ee=G(ie,ue,Z);ue!==Ee&&(q=!0,Z="buffer",ue=Ee)}var te=ie.objectMode?1:ue.length;ie.length+=te;var J=ie.length<ie.highWaterMark;if(J||(ie.needDrain=!0),ie.writing||ie.corked){var X=ie.lastBufferedRequest;ie.lastBufferedRequest={chunk:ue,encoding:Z,isBuf:q,callback:ee,next:null},X?X.next=ie.lastBufferedRequest:ie.bufferedRequest=ie.lastBufferedRequest,ie.bufferedRequestCount+=1}else H(ae,ie,!1,te,ue,Z,ee);return J}function H(ae,ie,q,ue,Z,ee,Ee){ie.writelen=ue,ie.writecb=Ee,ie.writing=!0,ie.sync=!0,q?ae._writev(Z,ie.onwrite):ae._write(Z,ee,ie.onwrite),ie.sync=!1}function z(ae,ie,q,ue,Z){--ie.pendingcb,q?(i.nextTick(Z,ue),i.nextTick(le,ae,ie),ae._writableState.errorEmitted=!0,ae.emit("error",ue)):(Z(ue),ae._writableState.errorEmitted=!0,ae.emit("error",ue),le(ae,ie))}function B(ae){ae.writing=!1,ae.writecb=null,ae.length-=ae.writelen,ae.writelen=0}function k(ae,ie){var q=ae._writableState,ue=q.sync,Z=q.writecb;if(B(q),ie)z(ae,q,ue,ie,Z);else{var ee=oe(q);!ee&&!q.corked&&!q.bufferProcessing&&q.bufferedRequest&&ne(ae,q),ue?f(K,ae,q,ee,Z):K(ae,q,ee,Z)}}function K(ae,ie,q,ue){q||Y(ae,ie),ie.pendingcb--,ue(),le(ae,ie)}function Y(ae,ie){ie.length===0&&ie.needDrain&&(ie.needDrain=!1,ae.emit("drain"))}function ne(ae,ie){ie.bufferProcessing=!0;var q=ie.bufferedRequest;if(ae._writev&&q&&q.next){var ue=ie.bufferedRequestCount,Z=new Array(ue),ee=ie.corkedRequestsFree;ee.entry=q;for(var Ee=0,te=!0;q;)Z[Ee]=q,q.isBuf||(te=!1),q=q.next,Ee+=1;Z.allBuffers=te,H(ae,ie,!0,ie.length,Z,"",ee.finish),ie.pendingcb++,ie.lastBufferedRequest=null,ee.next?(ie.corkedRequestsFree=ee.next,ee.next=null):ie.corkedRequestsFree=new u(ie),ie.bufferedRequestCount=0}else{for(;q;){var J=q.chunk,X=q.encoding,$=q.callback,ge=ie.objectMode?1:J.length;if(H(ae,ie,!1,ge,J,X,$),q=q.next,ie.bufferedRequestCount--,ie.writing)break}q===null&&(ie.lastBufferedRequest=null)}ie.bufferedRequest=q,ie.bufferProcessing=!1}L.prototype._write=function(ae,ie,q){q(new Error("_write() is not implemented"))},L.prototype._writev=null,L.prototype.end=function(ae,ie,q){var ue=this._writableState;typeof ae=="function"?(q=ae,ae=null,ie=null):typeof ie=="function"&&(q=ie,ie=null),ae!=null&&this.write(ae,ie),ue.corked&&(ue.corked=1,this.uncork()),!ue.ending&&!ue.finished&&me(this,ue,q)};function oe(ae){return ae.ending&&ae.length===0&&ae.bufferedRequest===null&&!ae.finished&&!ae.writing}function _e(ae,ie){ae._final(function(q){ie.pendingcb--,q&&ae.emit("error",q),ie.prefinished=!0,ae.emit("prefinish"),le(ae,ie)})}function xe(ae,ie){!ie.prefinished&&!ie.finalCalled&&(typeof ae._final=="function"?(ie.pendingcb++,ie.finalCalled=!0,i.nextTick(_e,ae,ie)):(ie.prefinished=!0,ae.emit("prefinish")))}function le(ae,ie){var q=oe(ie);return q&&(xe(ae,ie),ie.pendingcb===0&&(ie.finished=!0,ae.emit("finish"))),q}function me(ae,ie,q){ie.ending=!0,le(ae,ie),q&&(ie.finished?i.nextTick(q):ae.once("finish",q)),ie.ended=!0,ae.writable=!1}function de(ae,ie,q){var ue=ae.entry;for(ae.entry=null;ue;){var Z=ue.callback;ie.pendingcb--,Z(q),ue=ue.next}ie.corkedRequestsFree?ie.corkedRequestsFree.next=ae:ie.corkedRequestsFree=ae}Object.defineProperty(L.prototype,"destroyed",{get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(ie){if(!this._writableState)return;this._writableState.destroyed=ie}}),L.prototype.destroy=g.destroy,L.prototype._undestroy=g.undestroy,L.prototype._destroy=function(ae,ie){this.end(),ie(ae)}}).call(this,F("_process"),typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./_stream_duplex":214,"./internal/streams/destroy":220,"./internal/streams/stream":221,_process:208,"babel-runtime/core-js/object/create":55,"babel-runtime/core-js/object/define-property":56,"babel-runtime/core-js/set-immediate":62,"babel-runtime/core-js/symbol":64,"babel-runtime/core-js/symbol/has-instance":65,"core-util-is":189,inherits:196,"process-nextick-args":207,"safe-buffer":228,"util-deprecate":240}],219:[function(F,Q,j){"use strict";function N(m,y){if(!(m instanceof y))throw new TypeError("Cannot call a class as a function")}var v=F("safe-buffer").Buffer,C=F("util");function M(m,y,w){m.copy(y,w)}Q.exports=function(){function m(){N(this,m),this.head=null,this.tail=null,this.length=0}return m.prototype.push=function(w){var b={data:w,next:null};this.length>0?this.tail.next=b:this.head=b,this.tail=b,++this.length},m.prototype.unshift=function(w){var b={data:w,next:this.head};this.length===0&&(this.tail=b),this.head=b,++this.length},m.prototype.shift=function(){if(this.length===0)return;var w=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,w},m.prototype.clear=function(){this.head=this.tail=null,this.length=0},m.prototype.join=function(w){if(this.length===0)return"";for(var b=this.head,p=""+b.data;b=b.next;)p+=w+b.data;return p},m.prototype.concat=function(w){if(this.length===0)return v.alloc(0);if(this.length===1)return this.head.data;for(var b=v.allocUnsafe(w>>>0),p=this.head,d=0;p;)M(p.data,b,d),d+=p.data.length,p=p.next;return b},m}(),C&&C.inspect&&C.inspect.custom&&(Q.exports.prototype[C.inspect.custom]=function(){var m=C.inspect({length:this.length});return this.constructor.name+" "+m})},{"safe-buffer":228,util:71}],220:[function(F,Q,j){"use strict";var N=F("process-nextick-args");function v(m,y){var w=this,b=this._readableState&&this._readableState.destroyed,p=this._writableState&&this._writableState.destroyed;return b||p?(y?y(m):m&&(!this._writableState||!this._writableState.errorEmitted)&&N.nextTick(M,this,m),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(m||null,function(d){!y&&d?(N.nextTick(M,w,d),w._writableState&&(w._writableState.errorEmitted=!0)):y&&y(d)}),this)}function C(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function M(m,y){m.emit("error",y)}Q.exports={destroy:v,undestroy:C}},{"process-nextick-args":207}],221:[function(F,Q,j){"use strict";Q.exports=F("events").EventEmitter},{events:192}],222:[function(F,Q,j){Q.exports=F("./readable").PassThrough},{"./readable":223}],223:[function(F,Q,j){j=Q.exports=F("./lib/_stream_readable.js"),j.Stream=j,j.Readable=j,j.Writable=F("./lib/_stream_writable.js"),j.Duplex=F("./lib/_stream_duplex.js"),j.Transform=F("./lib/_stream_transform.js"),j.PassThrough=F("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":214,"./lib/_stream_passthrough.js":215,"./lib/_stream_readable.js":216,"./lib/_stream_transform.js":217,"./lib/_stream_writable.js":218}],224:[function(F,Q,j){Q.exports=F("./readable").Transform},{"./readable":223}],225:[function(F,Q,j){Q.exports=F("./lib/_stream_writable.js")},{"./lib/_stream_writable.js":218}],226:[function(F,Q,j){var N=function(){return this}()||Function("return this")(),v=N.regeneratorRuntime&&Object.getOwnPropertyNames(N).indexOf("regeneratorRuntime")>=0,C=v&&N.regeneratorRuntime;if(N.regeneratorRuntime=void 0,Q.exports=F("./runtime"),v)N.regeneratorRuntime=C;else try{delete N.regeneratorRuntime}catch(M){N.regeneratorRuntime=void 0}},{"./runtime":227}],227:[function(F,Q,j){!function(N){"use strict";var v=Object.prototype,C=v.hasOwnProperty,M,m=typeof Symbol=="function"?Symbol:{},y=m.iterator||"@@iterator",w=m.asyncIterator||"@@asyncIterator",b=m.toStringTag||"@@toStringTag",p=typeof Q=="object",d=N.regeneratorRuntime;if(d){p&&(Q.exports=d);return}d=N.regeneratorRuntime=p?Q.exports:{};function n(W,H,z,B){var k=H&&H.prototype instanceof s?H:s,K=Object.create(k.prototype),Y=new I(B||[]);return K._invoke=_(W,z,Y),K}d.wrap=n;function c(W,H,z){try{return{type:"normal",arg:W.call(H,z)}}catch(B){return{type:"throw",arg:B}}}var r="suspendedStart",i="suspendedYield",o="executing",u="completed",f={};function s(){}function l(){}function t(){}var S={};S[y]=function(){return this};var x=Object.getPrototypeOf,h=x&&x(x(P([])));h&&h!==v&&C.call(h,y)&&(S=h);var R=t.prototype=s.prototype=Object.create(S);l.prototype=R.constructor=t,t.constructor=l,t[b]=l.displayName="GeneratorFunction";function O(W){["next","throw","return"].forEach(function(H){W[H]=function(z){return this._invoke(H,z)}})}d.isGeneratorFunction=function(W){var H=typeof W=="function"&&W.constructor;return H?H===l||(H.displayName||H.name)==="GeneratorFunction":!1},d.mark=function(W){return Object.setPrototypeOf?Object.setPrototypeOf(W,t):(W.__proto__=t,b in W||(W[b]="GeneratorFunction")),W.prototype=Object.create(R),W},d.awrap=function(W){return{__await:W}};function g(W){function H(k,K,Y,ne){var oe=c(W[k],W,K);if(oe.type==="throw")ne(oe.arg);else{var _e=oe.arg,xe=_e.value;return xe&&typeof xe=="object"&&C.call(xe,"__await")?Promise.resolve(xe.__await).then(function(le){H("next",le,Y,ne)},function(le){H("throw",le,Y,ne)}):Promise.resolve(xe).then(function(le){_e.value=le,Y(_e)},ne)}}var z;function B(k,K){function Y(){return new Promise(function(ne,oe){H(k,K,ne,oe)})}return z=z?z.then(Y,Y):Y()}this._invoke=B}O(g.prototype),g.prototype[w]=function(){return this},d.AsyncIterator=g,d.async=function(W,H,z,B){var k=new g(n(W,H,z,B));return d.isGeneratorFunction(H)?k:k.next().then(function(K){return K.done?K.value:k.next()})};function _(W,H,z){var B=r;return function(K,Y){if(B===o)throw new Error("Generator is already running");if(B===u){if(K==="throw")throw Y;return G()}for(z.method=K,z.arg=Y;;){var ne=z.delegate;if(ne){var oe=E(ne,z);if(oe){if(oe===f)continue;return oe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(B===r)throw B=u,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);B=o;var _e=c(W,H,z);if(_e.type==="normal"){if(B=z.done?u:i,_e.arg===f)continue;return{value:_e.arg,done:z.done}}else _e.type==="throw"&&(B=u,z.method="throw",z.arg=_e.arg)}}}function E(W,H){var z=W.iterator[H.method];if(z===M){if(H.delegate=null,H.method==="throw"){if(W.iterator.return&&(H.method="return",H.arg=M,E(W,H),H.method==="throw"))return f;H.method="throw",H.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var B=c(z,W.iterator,H.arg);if(B.type==="throw")return H.method="throw",H.arg=B.arg,H.delegate=null,f;var k=B.arg;if(!k)return H.method="throw",H.arg=new TypeError("iterator result is not an object"),H.delegate=null,f;if(k.done)H[W.resultName]=k.value,H.next=W.nextLoc,H.method!=="return"&&(H.method="next",H.arg=M);else return k;return H.delegate=null,f}O(R),R[b]="Generator",R[y]=function(){return this},R.toString=function(){return"[object Generator]"};function T(W){var H={tryLoc:W[0]};1 in W&&(H.catchLoc=W[1]),2 in W&&(H.finallyLoc=W[2],H.afterLoc=W[3]),this.tryEntries.push(H)}function L(W){var H=W.completion||{};H.type="normal",delete H.arg,W.completion=H}function I(W){this.tryEntries=[{tryLoc:"root"}],W.forEach(T,this),this.reset(!0)}d.keys=function(W){var H=[];for(var z in W)H.push(z);return H.reverse(),function B(){for(;H.length;){var k=H.pop();if(k in W)return B.value=k,B.done=!1,B}return B.done=!0,B}};function P(W){if(W){var H=W[y];if(H)return H.call(W);if(typeof W.next=="function")return W;if(!isNaN(W.length)){var z=-1,B=function k(){for(;++z<W.length;)if(C.call(W,z))return k.value=W[z],k.done=!1,k;return k.value=M,k.done=!0,k};return B.next=B}}return{next:G}}d.values=P;function G(){return{value:M,done:!0}}I.prototype={constructor:I,reset:function(W){if(this.prev=0,this.next=0,this.sent=this._sent=M,this.done=!1,this.delegate=null,this.method="next",this.arg=M,this.tryEntries.forEach(L),!W)for(var H in this)H.charAt(0)==="t"&&C.call(this,H)&&!isNaN(+H.slice(1))&&(this[H]=M)},stop:function(){this.done=!0;var W=this.tryEntries[0],H=W.completion;if(H.type==="throw")throw H.arg;return this.rval},dispatchException:function(W){if(this.done)throw W;var H=this;function z(oe,_e){return K.type="throw",K.arg=W,H.next=oe,_e&&(H.method="next",H.arg=M),!!_e}for(var B=this.tryEntries.length-1;B>=0;--B){var k=this.tryEntries[B],K=k.completion;if(k.tryLoc==="root")return z("end");if(k.tryLoc<=this.prev){var Y=C.call(k,"catchLoc"),ne=C.call(k,"finallyLoc");if(Y&&ne){if(this.prev<k.catchLoc)return z(k.catchLoc,!0);if(this.prev<k.finallyLoc)return z(k.finallyLoc)}else if(Y){if(this.prev<k.catchLoc)return z(k.catchLoc,!0)}else if(ne){if(this.prev<k.finallyLoc)return z(k.finallyLoc)}else throw new Error("try statement without catch or finally")}}},abrupt:function(W,H){for(var z=this.tryEntries.length-1;z>=0;--z){var B=this.tryEntries[z];if(B.tryLoc<=this.prev&&C.call(B,"finallyLoc")&&this.prev<B.finallyLoc){var k=B;break}}k&&(W==="break"||W==="continue")&&k.tryLoc<=H&&H<=k.finallyLoc&&(k=null);var K=k?k.completion:{};return K.type=W,K.arg=H,k?(this.method="next",this.next=k.finallyLoc,f):this.complete(K)},complete:function(W,H){if(W.type==="throw")throw W.arg;return W.type==="break"||W.type==="continue"?this.next=W.arg:W.type==="return"?(this.rval=this.arg=W.arg,this.method="return",this.next="end"):W.type==="normal"&&H&&(this.next=H),f},finish:function(W){for(var H=this.tryEntries.length-1;H>=0;--H){var z=this.tryEntries[H];if(z.finallyLoc===W)return this.complete(z.completion,z.afterLoc),L(z),f}},catch:function(W){for(var H=this.tryEntries.length-1;H>=0;--H){var z=this.tryEntries[H];if(z.tryLoc===W){var B=z.completion;if(B.type==="throw"){var k=B.arg;L(z)}return k}}throw new Error("illegal catch attempt")},delegateYield:function(W,H,z){return this.delegate={iterator:P(W),resultName:H,nextLoc:z},this.method==="next"&&(this.arg=M),f}}}(function(){return this}()||Function("return this")())},{}],228:[function(F,Q,j){var N=F("buffer"),v=N.Buffer;function C(m,y){for(var w in m)y[w]=m[w]}v.from&&v.alloc&&v.allocUnsafe&&v.allocUnsafeSlow?Q.exports=N:(C(N,j),j.Buffer=M);function M(m,y,w){return v(m,y,w)}C(v,M),M.from=function(m,y,w){if(typeof m=="number")throw new TypeError("Argument must not be a number");return v(m,y,w)},M.alloc=function(m,y,w){if(typeof m!="number")throw new TypeError("Argument must be a number");var b=v(m);return y!==void 0?typeof w=="string"?b.fill(y,w):b.fill(y):b.fill(0),b},M.allocUnsafe=function(m){if(typeof m!="number")throw new TypeError("Argument must be a number");return v(m)},M.allocUnsafeSlow=function(m){if(typeof m!="number")throw new TypeError("Argument must be a number");return N.SlowBuffer(m)}},{buffer:73}],229:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/core-js/string/from-code-point"),C=i(v),M=F("babel-runtime/core-js/json/stringify"),m=i(M),y=F("babel-runtime/helpers/typeof"),w=i(y),b=F("babel-runtime/core-js/object/define-property"),p=i(b),d=F("babel-runtime/core-js/object/keys"),n=i(d),c=F("babel-runtime/core-js/object/create"),r=i(c);function i(o){return o&&o.__esModule?o:{default:o}}(function(o){o.parser=function(X,$){return new f(X,$)},o.SAXParser=f,o.SAXStream=R,o.createStream=h,o.MAX_BUFFER_LENGTH=64*1024;var u=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];o.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"];function f(X,$){if(!(this instanceof f))return new f(X,$);var ge=this;l(ge),ge.q=ge.c="",ge.bufferCheckPosition=o.MAX_BUFFER_LENGTH,ge.opt=$||{},ge.opt.lowercase=ge.opt.lowercase||ge.opt.lowercasetags,ge.looseCase=ge.opt.lowercase?"toLowerCase":"toUpperCase",ge.tags=[],ge.closed=ge.closedRoot=ge.sawRoot=!1,ge.tag=ge.error=null,ge.strict=!!X,ge.noscript=!!(X||ge.opt.noscript),ge.state=K.BEGIN,ge.strictEntities=ge.opt.strictEntities,ge.ENTITIES=ge.strictEntities?(0,r.default)(o.XML_ENTITIES):(0,r.default)(o.ENTITIES),ge.attribList=[],ge.opt.xmlns&&(ge.ns=(0,r.default)(T)),ge.trackPosition=ge.opt.position!==!1,ge.trackPosition&&(ge.position=ge.line=ge.column=0),ne(ge,"onready")}r.default||(Object.create=function(X){function $(){}$.prototype=X;var ge=new $;return ge}),n.default||(Object.keys=function(X){var $=[];for(var ge in X)X.hasOwnProperty(ge)&&$.push(ge);return $});function s(X){for(var $=Math.max(o.MAX_BUFFER_LENGTH,10),ge=0,fe=0,Te=u.length;fe<Te;fe++){var ze=X[u[fe]].length;if(ze>$)switch(u[fe]){case"textNode":_e(X);break;case"cdata":oe(X,"oncdata",X.cdata),X.cdata="";break;case"script":oe(X,"onscript",X.script),X.script="";break;default:le(X,"Max buffer length exceeded: "+u[fe])}ge=Math.max(ge,ze)}var Xe=o.MAX_BUFFER_LENGTH-ge;X.bufferCheckPosition=Xe+X.position}function l(X){for(var $=0,ge=u.length;$<ge;$++)X[u[$]]=""}function t(X){_e(X),X.cdata!==""&&(oe(X,"oncdata",X.cdata),X.cdata=""),X.script!==""&&(oe(X,"onscript",X.script),X.script="")}f.prototype={end:function(){me(this)},write:J,resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){t(this)}};var S;try{S=F("stream").Stream}catch(X){S=function(){}}var x=o.EVENTS.filter(function(X){return X!=="error"&&X!=="end"});function h(X,$){return new R(X,$)}function R(X,$){if(!(this instanceof R))return new R(X,$);S.apply(this),this._parser=new f(X,$),this.writable=!0,this.readable=!0;var ge=this;this._parser.onend=function(){ge.emit("end")},this._parser.onerror=function(fe){ge.emit("error",fe),ge._parser.error=null},this._decoder=null,x.forEach(function(fe){(0,p.default)(ge,"on"+fe,{get:function(){return ge._parser["on"+fe]},set:function(ze){if(!ze)return ge.removeAllListeners(fe),ge._parser["on"+fe]=ze,ze;ge.on(fe,ze)},enumerable:!0,configurable:!1})})}R.prototype=(0,r.default)(S.prototype,{constructor:{value:R}}),R.prototype.write=function(X){if(typeof N=="function"&&typeof N.isBuffer=="function"&&N.isBuffer(X)){if(!this._decoder){var $=F("string_decoder").StringDecoder;this._decoder=new $("utf8")}X=this._decoder.write(X)}return this._parser.write(X.toString()),this.emit("data",X),!0},R.prototype.end=function(X){return X&&X.length&&this.write(X),this._parser.end(),!0},R.prototype.on=function(X,$){var ge=this;return!ge._parser["on"+X]&&x.indexOf(X)!==-1&&(ge._parser["on"+X]=function(){var fe=arguments.length===1?[arguments[0]]:Array.apply(null,arguments);fe.splice(0,0,X),ge.emit.apply(ge,fe)}),S.prototype.on.call(ge,X,$)};var O="[CDATA[",g="DOCTYPE",_="http://www.w3.org/XML/1998/namespace",E="http://www.w3.org/2000/xmlns/",T={xml:_,xmlns:E},L=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,I=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,P=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,G=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function W(X){return X===" "||X===`
`||X==="\r"||X===" "}function H(X){return X==='"'||X==="'"}function z(X){return X===">"||W(X)}function B(X,$){return X.test($)}function k(X,$){return!B(X,$)}var K=0;o.STATE={BEGIN:K++,BEGIN_WHITESPACE:K++,TEXT:K++,TEXT_ENTITY:K++,OPEN_WAKA:K++,SGML_DECL:K++,SGML_DECL_QUOTED:K++,DOCTYPE:K++,DOCTYPE_QUOTED:K++,DOCTYPE_DTD:K++,DOCTYPE_DTD_QUOTED:K++,COMMENT_STARTING:K++,COMMENT:K++,COMMENT_ENDING:K++,COMMENT_ENDED:K++,CDATA:K++,CDATA_ENDING:K++,CDATA_ENDING_2:K++,PROC_INST:K++,PROC_INST_BODY:K++,PROC_INST_ENDING:K++,OPEN_TAG:K++,OPEN_TAG_SLASH:K++,ATTRIB:K++,ATTRIB_NAME:K++,ATTRIB_NAME_SAW_WHITE:K++,ATTRIB_VALUE:K++,ATTRIB_VALUE_QUOTED:K++,ATTRIB_VALUE_CLOSED:K++,ATTRIB_VALUE_UNQUOTED:K++,ATTRIB_VALUE_ENTITY_Q:K++,ATTRIB_VALUE_ENTITY_U:K++,CLOSE_TAG:K++,CLOSE_TAG_SAW_WHITE:K++,SCRIPT:K++,SCRIPT_ENDING:K++},o.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},o.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},(0,n.default)(o.ENTITIES).forEach(function(X){var $=o.ENTITIES[X],ge=typeof $=="number"?String.fromCharCode($):$;o.ENTITIES[X]=ge});for(var Y in o.STATE)o.STATE[o.STATE[Y]]=Y;K=o.STATE;function ne(X,$,ge){X[$]&&X[$](ge)}function oe(X,$,ge){X.textNode&&_e(X),ne(X,$,ge)}function _e(X){X.textNode=xe(X.opt,X.textNode),X.textNode&&ne(X,"ontext",X.textNode),X.textNode=""}function xe(X,$){return X.trim&&($=$.trim()),X.normalize&&($=$.replace(/\s+/g," ")),$}function le(X,$){return _e(X),X.trackPosition&&($+=`
Line: `+X.line+`
Column: `+X.column+`
Char: `+X.c),$=new Error($),X.error=$,ne(X,"onerror",$),X}function me(X){return X.sawRoot&&!X.closedRoot&&de(X,"Unclosed root tag"),X.state!==K.BEGIN&&X.state!==K.BEGIN_WHITESPACE&&X.state!==K.TEXT&&le(X,"Unexpected end"),_e(X),X.c="",X.closed=!0,ne(X,"onend"),f.call(X,X.strict,X.opt),X}function de(X,$){if((typeof X=="undefined"?"undefined":(0,w.default)(X))!=="object"||!(X instanceof f))throw new Error("bad call to strictFail");X.strict&&le(X,$)}function ae(X){X.strict||(X.tagName=X.tagName[X.looseCase]());var $=X.tags[X.tags.length-1]||X,ge=X.tag={name:X.tagName,attributes:{}};X.opt.xmlns&&(ge.ns=$.ns),X.attribList.length=0,oe(X,"onopentagstart",ge)}function ie(X,$){var ge=X.indexOf(":"),fe=ge<0?["",X]:X.split(":"),Te=fe[0],ze=fe[1];return $&&X==="xmlns"&&(Te="xmlns",ze=""),{prefix:Te,local:ze}}function q(X){if(X.strict||(X.attribName=X.attribName[X.looseCase]()),X.attribList.indexOf(X.attribName)!==-1||X.tag.attributes.hasOwnProperty(X.attribName)){X.attribName=X.attribValue="";return}if(X.opt.xmlns){var $=ie(X.attribName,!0),ge=$.prefix,fe=$.local;if(ge==="xmlns")if(fe==="xml"&&X.attribValue!==_)de(X,"xml: prefix must be bound to "+_+`
Actual: `+X.attribValue);else if(fe==="xmlns"&&X.attribValue!==E)de(X,"xmlns: prefix must be bound to "+E+`
Actual: `+X.attribValue);else{var Te=X.tag,ze=X.tags[X.tags.length-1]||X;Te.ns===ze.ns&&(Te.ns=(0,r.default)(ze.ns)),Te.ns[fe]=X.attribValue}X.attribList.push([X.attribName,X.attribValue])}else X.tag.attributes[X.attribName]=X.attribValue,oe(X,"onattribute",{name:X.attribName,value:X.attribValue});X.attribName=X.attribValue=""}function ue(X,$){if(X.opt.xmlns){var ge=X.tag,fe=ie(X.tagName);ge.prefix=fe.prefix,ge.local=fe.local,ge.uri=ge.ns[fe.prefix]||"",ge.prefix&&!ge.uri&&(de(X,"Unbound namespace prefix: "+(0,m.default)(X.tagName)),ge.uri=fe.prefix);var Te=X.tags[X.tags.length-1]||X;ge.ns&&Te.ns!==ge.ns&&(0,n.default)(ge.ns).forEach(function(We){oe(X,"onopennamespace",{prefix:We,uri:ge.ns[We]})});for(var ze=0,Xe=X.attribList.length;ze<Xe;ze++){var Ye=X.attribList[ze],rt=Ye[0],at=Ye[1],ot=ie(rt,!0),Pe=ot.prefix,Se=ot.local,Je=Pe===""?"":ge.ns[Pe]||"",nt={name:rt,value:at,prefix:Pe,local:Se,uri:Je};Pe&&Pe!=="xmlns"&&!Je&&(de(X,"Unbound namespace prefix: "+(0,m.default)(Pe)),nt.uri=Pe),X.tag.attributes[rt]=nt,oe(X,"onattribute",nt)}X.attribList.length=0}X.tag.isSelfClosing=!!$,X.sawRoot=!0,X.tags.push(X.tag),oe(X,"onopentag",X.tag),$||(!X.noscript&&X.tagName.toLowerCase()==="script"?X.state=K.SCRIPT:X.state=K.TEXT,X.tag=null,X.tagName=""),X.attribName=X.attribValue="",X.attribList.length=0}function Z(X){if(!X.tagName){de(X,"Weird empty close tag."),X.textNode+="</>",X.state=K.TEXT;return}if(X.script){if(X.tagName!=="script"){X.script+="</"+X.tagName+">",X.tagName="",X.state=K.SCRIPT;return}oe(X,"onscript",X.script),X.script=""}var $=X.tags.length,ge=X.tagName;X.strict||(ge=ge[X.looseCase]());for(var fe=ge;$--;){var Te=X.tags[$];if(Te.name!==fe)de(X,"Unexpected close tag");else break}if($<0){de(X,"Unmatched closing tag: "+X.tagName),X.textNode+="</"+X.tagName+">",X.state=K.TEXT;return}X.tagName=ge;for(var ze=X.tags.length;ze-- >$;){var Xe=X.tag=X.tags.pop();X.tagName=X.tag.name,oe(X,"onclosetag",X.tagName);var Ye={};for(var rt in Xe.ns)Ye[rt]=Xe.ns[rt];var at=X.tags[X.tags.length-1]||X;X.opt.xmlns&&Xe.ns!==at.ns&&(0,n.default)(Xe.ns).forEach(function(ot){var Pe=Xe.ns[ot];oe(X,"onclosenamespace",{prefix:ot,uri:Pe})})}$===0&&(X.closedRoot=!0),X.tagName=X.attribValue=X.attribName="",X.attribList.length=0,X.state=K.TEXT}function ee(X){var $=X.entity,ge=$.toLowerCase(),fe,Te="";return X.ENTITIES[$]?X.ENTITIES[$]:X.ENTITIES[ge]?X.ENTITIES[ge]:($=ge,$.charAt(0)==="#"&&($.charAt(1)==="x"?($=$.slice(2),fe=parseInt($,16),Te=fe.toString(16)):($=$.slice(1),fe=parseInt($,10),Te=fe.toString(10))),$=$.replace(/^0+/,""),isNaN(fe)||Te.toLowerCase()!==$?(de(X,"Invalid character entity"),"&"+X.entity+";"):(0,C.default)(fe))}function Ee(X,$){$==="<"?(X.state=K.OPEN_WAKA,X.startTagPosition=X.position):W($)||(de(X,"Non-whitespace before first tag."),X.textNode=$,X.state=K.TEXT)}function te(X,$){var ge="";return $<X.length&&(ge=X.charAt($)),ge}function J(X){var $=this;if(this.error)throw this.error;if($.closed)return le($,"Cannot write after close. Assign an onready handler.");if(X===null)return me($);(typeof X=="undefined"?"undefined":(0,w.default)(X))==="object"&&(X=X.toString());for(var ge=0,fe="";!(fe=te(X,ge++),$.c=fe,!fe);){$.trackPosition&&($.position++,fe===`
`?($.line++,$.column=0):$.column++);switch($.state){case K.BEGIN:if($.state=K.BEGIN_WHITESPACE,fe==="\uFEFF")continue;Ee($,fe);continue;case K.BEGIN_WHITESPACE:Ee($,fe);continue;case K.TEXT:if($.sawRoot&&!$.closedRoot){for(var Te=ge-1;fe&&fe!=="<"&&fe!=="&";)fe=te(X,ge++),fe&&$.trackPosition&&($.position++,fe===`
`?($.line++,$.column=0):$.column++);$.textNode+=X.substring(Te,ge-1)}fe==="<"&&!($.sawRoot&&$.closedRoot&&!$.strict)?($.state=K.OPEN_WAKA,$.startTagPosition=$.position):(!W(fe)&&(!$.sawRoot||$.closedRoot)&&de($,"Text data outside of root node."),fe==="&"?$.state=K.TEXT_ENTITY:$.textNode+=fe);continue;case K.SCRIPT:fe==="<"?$.state=K.SCRIPT_ENDING:$.script+=fe;continue;case K.SCRIPT_ENDING:fe==="/"?$.state=K.CLOSE_TAG:($.script+="<"+fe,$.state=K.SCRIPT);continue;case K.OPEN_WAKA:if(fe==="!")$.state=K.SGML_DECL,$.sgmlDecl="";else if(!W(fe))if(B(L,fe))$.state=K.OPEN_TAG,$.tagName=fe;else if(fe==="/")$.state=K.CLOSE_TAG,$.tagName="";else if(fe==="?")$.state=K.PROC_INST,$.procInstName=$.procInstBody="";else{if(de($,"Unencoded <"),$.startTagPosition+1<$.position){var ze=$.position-$.startTagPosition;fe=new Array(ze).join(" ")+fe}$.textNode+="<"+fe,$.state=K.TEXT}continue;case K.SGML_DECL:($.sgmlDecl+fe).toUpperCase()===O?(oe($,"onopencdata"),$.state=K.CDATA,$.sgmlDecl="",$.cdata=""):$.sgmlDecl+fe==="--"?($.state=K.COMMENT,$.comment="",$.sgmlDecl=""):($.sgmlDecl+fe).toUpperCase()===g?($.state=K.DOCTYPE,($.doctype||$.sawRoot)&&de($,"Inappropriately located doctype declaration"),$.doctype="",$.sgmlDecl=""):fe===">"?(oe($,"onsgmldeclaration",$.sgmlDecl),$.sgmlDecl="",$.state=K.TEXT):(H(fe)&&($.state=K.SGML_DECL_QUOTED),$.sgmlDecl+=fe);continue;case K.SGML_DECL_QUOTED:fe===$.q&&($.state=K.SGML_DECL,$.q=""),$.sgmlDecl+=fe;continue;case K.DOCTYPE:fe===">"?($.state=K.TEXT,oe($,"ondoctype",$.doctype),$.doctype=!0):($.doctype+=fe,fe==="["?$.state=K.DOCTYPE_DTD:H(fe)&&($.state=K.DOCTYPE_QUOTED,$.q=fe));continue;case K.DOCTYPE_QUOTED:$.doctype+=fe,fe===$.q&&($.q="",$.state=K.DOCTYPE);continue;case K.DOCTYPE_DTD:$.doctype+=fe,fe==="]"?$.state=K.DOCTYPE:H(fe)&&($.state=K.DOCTYPE_DTD_QUOTED,$.q=fe);continue;case K.DOCTYPE_DTD_QUOTED:$.doctype+=fe,fe===$.q&&($.state=K.DOCTYPE_DTD,$.q="");continue;case K.COMMENT:fe==="-"?$.state=K.COMMENT_ENDING:$.comment+=fe;continue;case K.COMMENT_ENDING:fe==="-"?($.state=K.COMMENT_ENDED,$.comment=xe($.opt,$.comment),$.comment&&oe($,"oncomment",$.comment),$.comment=""):($.comment+="-"+fe,$.state=K.COMMENT);continue;case K.COMMENT_ENDED:fe!==">"?(de($,"Malformed comment"),$.comment+="--"+fe,$.state=K.COMMENT):$.state=K.TEXT;continue;case K.CDATA:fe==="]"?$.state=K.CDATA_ENDING:$.cdata+=fe;continue;case K.CDATA_ENDING:fe==="]"?$.state=K.CDATA_ENDING_2:($.cdata+="]"+fe,$.state=K.CDATA);continue;case K.CDATA_ENDING_2:fe===">"?($.cdata&&oe($,"oncdata",$.cdata),oe($,"onclosecdata"),$.cdata="",$.state=K.TEXT):fe==="]"?$.cdata+="]":($.cdata+="]]"+fe,$.state=K.CDATA);continue;case K.PROC_INST:fe==="?"?$.state=K.PROC_INST_ENDING:W(fe)?$.state=K.PROC_INST_BODY:$.procInstName+=fe;continue;case K.PROC_INST_BODY:if(!$.procInstBody&&W(fe))continue;fe==="?"?$.state=K.PROC_INST_ENDING:$.procInstBody+=fe;continue;case K.PROC_INST_ENDING:fe===">"?(oe($,"onprocessinginstruction",{name:$.procInstName,body:$.procInstBody}),$.procInstName=$.procInstBody="",$.state=K.TEXT):($.procInstBody+="?"+fe,$.state=K.PROC_INST_BODY);continue;case K.OPEN_TAG:B(I,fe)?$.tagName+=fe:(ae($),fe===">"?ue($):fe==="/"?$.state=K.OPEN_TAG_SLASH:(W(fe)||de($,"Invalid character in tag name"),$.state=K.ATTRIB));continue;case K.OPEN_TAG_SLASH:fe===">"?(ue($,!0),Z($)):(de($,"Forward-slash in opening tag not followed by >"),$.state=K.ATTRIB);continue;case K.ATTRIB:if(W(fe))continue;fe===">"?ue($):fe==="/"?$.state=K.OPEN_TAG_SLASH:B(L,fe)?($.attribName=fe,$.attribValue="",$.state=K.ATTRIB_NAME):de($,"Invalid attribute name");continue;case K.ATTRIB_NAME:fe==="="?$.state=K.ATTRIB_VALUE:fe===">"?(de($,"Attribute without value"),$.attribValue=$.attribName,q($),ue($)):W(fe)?$.state=K.ATTRIB_NAME_SAW_WHITE:B(I,fe)?$.attribName+=fe:de($,"Invalid attribute name");continue;case K.ATTRIB_NAME_SAW_WHITE:if(fe==="=")$.state=K.ATTRIB_VALUE;else{if(W(fe))continue;de($,"Attribute without value"),$.tag.attributes[$.attribName]="",$.attribValue="",oe($,"onattribute",{name:$.attribName,value:""}),$.attribName="",fe===">"?ue($):B(L,fe)?($.attribName=fe,$.state=K.ATTRIB_NAME):(de($,"Invalid attribute name"),$.state=K.ATTRIB)}continue;case K.ATTRIB_VALUE:if(W(fe))continue;H(fe)?($.q=fe,$.state=K.ATTRIB_VALUE_QUOTED):(de($,"Unquoted attribute value"),$.state=K.ATTRIB_VALUE_UNQUOTED,$.attribValue=fe);continue;case K.ATTRIB_VALUE_QUOTED:if(fe!==$.q){fe==="&"?$.state=K.ATTRIB_VALUE_ENTITY_Q:$.attribValue+=fe;continue}q($),$.q="",$.state=K.ATTRIB_VALUE_CLOSED;continue;case K.ATTRIB_VALUE_CLOSED:W(fe)?$.state=K.ATTRIB:fe===">"?ue($):fe==="/"?$.state=K.OPEN_TAG_SLASH:B(L,fe)?(de($,"No whitespace between attributes"),$.attribName=fe,$.attribValue="",$.state=K.ATTRIB_NAME):de($,"Invalid attribute name");continue;case K.ATTRIB_VALUE_UNQUOTED:if(!z(fe)){fe==="&"?$.state=K.ATTRIB_VALUE_ENTITY_U:$.attribValue+=fe;continue}q($),fe===">"?ue($):$.state=K.ATTRIB;continue;case K.CLOSE_TAG:if($.tagName)fe===">"?Z($):B(I,fe)?$.tagName+=fe:$.script?($.script+="</"+$.tagName,$.tagName="",$.state=K.SCRIPT):(W(fe)||de($,"Invalid tagname in closing tag"),$.state=K.CLOSE_TAG_SAW_WHITE);else{if(W(fe))continue;k(L,fe)?$.script?($.script+="</"+fe,$.state=K.SCRIPT):de($,"Invalid tagname in closing tag."):$.tagName=fe}continue;case K.CLOSE_TAG_SAW_WHITE:if(W(fe))continue;fe===">"?Z($):de($,"Invalid characters in closing tag");continue;case K.TEXT_ENTITY:case K.ATTRIB_VALUE_ENTITY_Q:case K.ATTRIB_VALUE_ENTITY_U:var Xe,Ye;switch($.state){case K.TEXT_ENTITY:Xe=K.TEXT,Ye="textNode";break;case K.ATTRIB_VALUE_ENTITY_Q:Xe=K.ATTRIB_VALUE_QUOTED,Ye="attribValue";break;case K.ATTRIB_VALUE_ENTITY_U:Xe=K.ATTRIB_VALUE_UNQUOTED,Ye="attribValue";break}fe===";"?($[Ye]+=ee($),$.entity="",$.state=Xe):B($.entity.length?G:P,fe)?$.entity+=fe:(de($,"Invalid character in entity name"),$[Ye]+="&"+$.entity+fe,$.entity="",$.state=Xe);continue;default:throw new Error($,"Unknown state: "+$.state)}}return $.position>=$.bufferCheckPosition&&s($),$}/*! http://mths.be/fromcodepoint v0.1.0 by @mathias */C.default||function(){var X=String.fromCharCode,$=Math.floor,ge=function(){var Te=16384,ze=[],Xe,Ye,rt=-1,at=arguments.length;if(!at)return"";for(var ot="";++rt<at;){var Pe=Number(arguments[rt]);if(!isFinite(Pe)||Pe<0||Pe>1114111||$(Pe)!==Pe)throw RangeError("Invalid code point: "+Pe);Pe<=65535?ze.push(Pe):(Pe-=65536,Xe=(Pe>>10)+55296,Ye=Pe%1024+56320,ze.push(Xe,Ye)),(rt+1===at||ze.length>Te)&&(ot+=X.apply(null,ze),ze.length=0)}return ot};p.default?Object.defineProperty(String,"fromCodePoint",{value:ge,configurable:!0,writable:!0}):String.fromCodePoint=ge}()})(typeof j=="undefined"?(void 0).sax={}:j)}).call(this,F("buffer").Buffer)},{"babel-runtime/core-js/json/stringify":53,"babel-runtime/core-js/object/create":55,"babel-runtime/core-js/object/define-property":56,"babel-runtime/core-js/object/keys":60,"babel-runtime/core-js/string/from-code-point":63,"babel-runtime/helpers/typeof":67,buffer:73,stream:230,string_decoder:72}],230:[function(F,Q,j){Q.exports=C;var N=F("events").EventEmitter,v=F("inherits");v(C,N),C.Readable=F("readable-stream/readable.js"),C.Writable=F("readable-stream/writable.js"),C.Duplex=F("readable-stream/duplex.js"),C.Transform=F("readable-stream/transform.js"),C.PassThrough=F("readable-stream/passthrough.js"),C.Stream=C;function C(){N.call(this)}C.prototype.pipe=function(M,m){var y=this;function w(i){M.writable&&(M.write(i)===!1&&y.pause&&y.pause())}y.on("data",w);function b(){y.readable&&y.resume&&y.resume()}M.on("drain",b),!M._isStdio&&(!m||m.end!==!1)&&(y.on("end",d),y.on("close",n));var p=!1;function d(){if(p)return;p=!0,M.end()}function n(){if(p)return;p=!0,typeof M.destroy=="function"&&M.destroy()}function c(i){if(r(),N.listenerCount(this,"error")===0)throw i}y.on("error",c),M.on("error",c);function r(){y.removeListener("data",w),M.removeListener("drain",b),y.removeListener("end",d),y.removeListener("close",n),y.removeListener("error",c),M.removeListener("error",c),y.removeListener("end",r),y.removeListener("close",r),M.removeListener("close",r)}return y.on("end",r),y.on("close",r),M.on("close",r),M.emit("pipe",y),M}},{events:192,inherits:196,"readable-stream/duplex.js":213,"readable-stream/passthrough.js":222,"readable-stream/readable.js":223,"readable-stream/transform.js":224,"readable-stream/writable.js":225}],231:[function(F,Q,j){(function(N){var v=F("./lib/request"),C=F("./lib/response"),M=F("xtend"),m=F("builtin-status-codes"),y=F("url"),w=j;w.request=function(b,p){typeof b=="string"?b=y.parse(b):b=M(b);var d=N.location.protocol.search(/^https?:$/)===-1?"http:":"",n=b.protocol||d,c=b.hostname||b.host,r=b.port,i=b.path||"/";c&&c.indexOf(":")!==-1&&(c="["+c+"]"),b.url=(c?n+"//"+c:"")+(r?":"+r:"")+i,b.method=(b.method||"GET").toUpperCase(),b.headers=b.headers||{};var o=new v(b);return p&&o.on("response",p),o},w.get=function(p,d){var n=w.request(p,d);return n.end(),n},w.ClientRequest=v,w.IncomingMessage=C.IncomingMessage,w.Agent=function(){},w.Agent.defaultMaxSockets=4,w.globalAgent=new w.Agent,w.STATUS_CODES=m,w.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./lib/request":233,"./lib/response":234,"builtin-status-codes":74,url:238,xtend:283}],232:[function(F,Q,j){(function(N){"use strict";j.fetch=w(N.fetch)&&w(N.ReadableStream),j.writableStream=w(N.WritableStream),j.abortController=w(N.AbortController),j.blobConstructor=!1;try{new Blob([new ArrayBuffer(1)]),j.blobConstructor=!0}catch(b){}var v;function C(){if(v!==void 0)return v;if(N.XMLHttpRequest){v=new N.XMLHttpRequest;try{v.open("GET",N.XDomainRequest?"/":"https://example.com")}catch(b){v=null}}else v=null;return v}function M(b){var p=C();if(!p)return!1;try{return p.responseType=b,p.responseType===b}catch(d){}return!1}var m=typeof N.ArrayBuffer!="undefined",y=m&&w(N.ArrayBuffer.prototype.slice);j.arraybuffer=j.fetch||m&&M("arraybuffer"),j.msstream=!j.fetch&&y&&M("ms-stream"),j.mozchunkedarraybuffer=!j.fetch&&m&&M("moz-chunked-arraybuffer"),j.overrideMimeType=j.fetch||(C()?w(C().overrideMimeType):!1),j.vbArray=w(N.VBArray);function w(b){return typeof b=="function"}v=null}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],233:[function(F,Q,j){(function(N,v,C){"use strict";var M=F("babel-runtime/core-js/object/keys"),m=y(M);function y(s){return s&&s.__esModule?s:{default:s}}var w=F("./capability"),b=F("inherits"),p=F("./response"),d=F("readable-stream"),n=F("to-arraybuffer"),c=p.IncomingMessage,r=p.readyStates;function i(s,l){return w.fetch&&l?"fetch":w.mozchunkedarraybuffer?"moz-chunked-arraybuffer":w.msstream?"ms-stream":w.arraybuffer&&s?"arraybuffer":w.vbArray&&s?"text:vbarray":"text"}var o=Q.exports=function(s){var l=this;d.Writable.call(l),l._opts=s,l._body=[],l._headers={},s.auth&&l.setHeader("Authorization","Basic "+new C(s.auth).toString("base64")),(0,m.default)(s.headers).forEach(function(x){l.setHeader(x,s.headers[x])});var t,S=!0;if(s.mode==="disable-fetch"||"requestTimeout"in s&&!w.abortController)S=!1,t=!0;else if(s.mode==="prefer-streaming")t=!1;else if(s.mode==="allow-wrong-content-type")t=!w.overrideMimeType;else if(!s.mode||s.mode==="default"||s.mode==="prefer-fast")t=!0;else throw new Error("Invalid value for opts.mode");l._mode=i(t,S),l._fetchTimer=null,l.on("finish",function(){l._onFinish()})};b(o,d.Writable),o.prototype.setHeader=function(s,l){var t=this,S=s.toLowerCase();if(f.indexOf(S)!==-1)return;t._headers[S]={name:s,value:l}},o.prototype.getHeader=function(s){var l=this._headers[s.toLowerCase()];return l?l.value:null},o.prototype.removeHeader=function(s){var l=this;delete l._headers[s.toLowerCase()]},o.prototype._onFinish=function(){var s=this;if(s._destroyed)return;var l=s._opts,t=s._headers,S=null;l.method!=="GET"&&l.method!=="HEAD"&&(w.arraybuffer?S=n(C.concat(s._body)):w.blobConstructor?S=new v.Blob(s._body.map(function(_){return n(_)}),{type:(t["content-type"]||{}).value||""}):S=C.concat(s._body).toString());var x=[];if((0,m.default)(t).forEach(function(_){var E=t[_].name,T=t[_].value;Array.isArray(T)?T.forEach(function(L){x.push([E,L])}):x.push([E,T])}),s._mode==="fetch"){var h=null,R=null;if(w.abortController){var O=new AbortController;h=O.signal,s._fetchAbortController=O,"requestTimeout"in l&&l.requestTimeout!==0&&(s._fetchTimer=v.setTimeout(function(){s.emit("requestTimeout"),s._fetchAbortController&&s._fetchAbortController.abort()},l.requestTimeout))}v.fetch(s._opts.url,{method:s._opts.method,headers:x,body:S||void 0,mode:"cors",credentials:l.withCredentials?"include":"same-origin",signal:h}).then(function(_){s._fetchResponse=_,s._connect()},function(_){v.clearTimeout(s._fetchTimer),s._destroyed||s.emit("error",_)})}else{var g=s._xhr=new v.XMLHttpRequest;try{g.open(s._opts.method,s._opts.url,!0)}catch(_){N.nextTick(function(){s.emit("error",_)});return}"responseType"in g&&(g.responseType=s._mode.split(":")[0]),"withCredentials"in g&&(g.withCredentials=!!l.withCredentials),s._mode==="text"&&"overrideMimeType"in g&&g.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in l&&(g.timeout=l.requestTimeout,g.ontimeout=function(){s.emit("requestTimeout")}),x.forEach(function(_){g.setRequestHeader(_[0],_[1])}),s._response=null,g.onreadystatechange=function(){switch(g.readyState){case r.LOADING:case r.DONE:s._onXHRProgress();break}},s._mode==="moz-chunked-arraybuffer"&&(g.onprogress=function(){s._onXHRProgress()}),g.onerror=function(){if(s._destroyed)return;s.emit("error",new Error("XHR error"))};try{g.send(S)}catch(_){N.nextTick(function(){s.emit("error",_)});return}}};function u(s){try{var l=s.status;return l!==null&&l!==0}catch(t){return!1}}o.prototype._onXHRProgress=function(){var s=this;if(!u(s._xhr)||s._destroyed)return;s._response||s._connect(),s._response._onXHRProgress()},o.prototype._connect=function(){var s=this;if(s._destroyed)return;s._response=new c(s._xhr,s._fetchResponse,s._mode,s._fetchTimer),s._response.on("error",function(l){s.emit("error",l)}),s.emit("response",s._response)},o.prototype._write=function(s,l,t){var S=this;S._body.push(s),t()},o.prototype.abort=o.prototype.destroy=function(){var s=this;s._destroyed=!0,v.clearTimeout(s._fetchTimer),s._response&&(s._response._destroyed=!0),s._xhr?s._xhr.abort():s._fetchAbortController&&s._fetchAbortController.abort()},o.prototype.end=function(s,l,t){var S=this;typeof s=="function"&&(t=s,s=void 0),d.Writable.prototype.end.call(S,s,l,t)},o.prototype.flushHeaders=function(){},o.prototype.setTimeout=function(){},o.prototype.setNoDelay=function(){},o.prototype.setSocketKeepAlive=function(){};var f=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","user-agent","via"]}).call(this,F("_process"),typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{},F("buffer").Buffer)},{"./capability":232,"./response":234,_process:208,"babel-runtime/core-js/object/keys":60,buffer:73,inherits:196,"readable-stream":223,"to-arraybuffer":237}],234:[function(F,Q,j){(function(N,v,C){"use strict";var M=F("babel-runtime/core-js/promise"),m=y(M);function y(c){return c&&c.__esModule?c:{default:c}}var w=F("./capability"),b=F("inherits"),p=F("readable-stream"),d=j.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},n=j.IncomingMessage=function(c,r,i,o){var u=this;if(p.Readable.call(u),u._mode=i,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",function(){N.nextTick(function(){u.emit("close")})}),i==="fetch"){var f=function h(){l.read().then(function(R){if(u._destroyed)return;if(R.done){v.clearTimeout(o),u.push(null);return}u.push(new C(R.value)),h()}).catch(function(R){v.clearTimeout(o),u._destroyed||u.emit("error",R)})};if(u._fetchResponse=r,u.url=r.url,u.statusCode=r.status,u.statusMessage=r.statusText,r.headers.forEach(function(h,R){u.headers[R.toLowerCase()]=h,u.rawHeaders.push(R,h)}),w.writableStream){var s=new WritableStream({write:function(R){return new m.default(function(O,g){u._destroyed?g():u.push(new C(R))?O():u._resumeFetch=O})},close:function(){v.clearTimeout(o),u._destroyed||u.push(null)},abort:function(R){u._destroyed||u.emit("error",R)}});try{r.body.pipeTo(s).catch(function(h){v.clearTimeout(o),u._destroyed||u.emit("error",h)});return}catch(h){}}var l=r.body.getReader();f()}else{u._xhr=c,u._pos=0,u.url=c.responseURL,u.statusCode=c.status,u.statusMessage=c.statusText;var t=c.getAllResponseHeaders().split(/\r?\n/);if(t.forEach(function(h){var R=h.match(/^([^:]+):\s*(.*)/);if(R){var O=R[1].toLowerCase();O==="set-cookie"?(u.headers[O]===void 0&&(u.headers[O]=[]),u.headers[O].push(R[2])):u.headers[O]!==void 0?u.headers[O]+=", "+R[2]:u.headers[O]=R[2],u.rawHeaders.push(R[1],R[2])}}),u._charset="x-user-defined",!w.overrideMimeType){var S=u.rawHeaders["mime-type"];if(S){var x=S.match(/;\s*charset=([^;])(;|$)/);x&&(u._charset=x[1].toLowerCase())}u._charset||(u._charset="utf-8")}}};b(n,p.Readable),n.prototype._read=function(){var c=this,r=c._resumeFetch;r&&(c._resumeFetch=null,r())},n.prototype._onXHRProgress=function(){var c=this,r=c._xhr,i=null;switch(c._mode){case"text:vbarray":if(r.readyState!==d.DONE)break;try{i=new v.VBArray(r.responseBody).toArray()}catch(l){}if(i!==null){c.push(new C(i));break}case"text":try{i=r.responseText}catch(l){c._mode="text:vbarray";break}if(i.length>c._pos){var o=i.substr(c._pos);if(c._charset==="x-user-defined"){for(var u=new C(o.length),f=0;f<o.length;f++)u[f]=o.charCodeAt(f)&255;c.push(u)}else c.push(o,c._charset);c._pos=i.length}break;case"arraybuffer":if(r.readyState!==d.DONE||!r.response)break;i=r.response,c.push(new C(new Uint8Array(i)));break;case"moz-chunked-arraybuffer":if(i=r.response,r.readyState!==d.LOADING||!i)break;c.push(new C(new Uint8Array(i)));break;case"ms-stream":if(i=r.response,r.readyState!==d.LOADING)break;var s=new v.MSStreamReader;s.onprogress=function(){s.result.byteLength>c._pos&&(c.push(new C(new Uint8Array(s.result.slice(c._pos)))),c._pos=s.result.byteLength)},s.onload=function(){c.push(null)},s.readAsArrayBuffer(i);break}c._xhr.readyState===d.DONE&&c._mode!=="ms-stream"&&c.push(null)}}).call(this,F("_process"),typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{},F("buffer").Buffer)},{"./capability":232,_process:208,"babel-runtime/core-js/promise":61,buffer:73,inherits:196,"readable-stream":223}],235:[function(F,Q,j){"use strict";var N=F("safe-buffer").Buffer,v=N.isEncoding||function(s){s=""+s;switch(s&&s.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function C(s){if(!s)return"utf8";for(var l;;)switch(s){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return s;default:if(l)return;s=(""+s).toLowerCase(),l=!0}}function M(s){var l=C(s);if(typeof l!="string"&&(N.isEncoding===v||!v(s)))throw new Error("Unknown encoding: "+s);return l||s}j.StringDecoder=m;function m(s){this.encoding=M(s);var l;switch(this.encoding){case"utf16le":this.text=c,this.end=r,l=4;break;case"utf8":this.fillLast=p,l=4;break;case"base64":this.text=i,this.end=o,l=3;break;default:this.write=u,this.end=f;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=N.allocUnsafe(l)}m.prototype.write=function(s){if(s.length===0)return"";var l,t;if(this.lastNeed){if(l=this.fillLast(s),l===void 0)return"";t=this.lastNeed,this.lastNeed=0}else t=0;return t<s.length?l?l+this.text(s,t):this.text(s,t):l||""},m.prototype.end=n,m.prototype.text=d,m.prototype.fillLast=function(s){if(this.lastNeed<=s.length)return s.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);s.copy(this.lastChar,this.lastTotal-this.lastNeed,0,s.length),this.lastNeed-=s.length};function y(s){return s<=127?0:s>>5===6?2:s>>4===14?3:s>>3===30?4:s>>6===2?-1:-2}function w(s,l,t){var S=l.length-1;if(S<t)return 0;var x=y(l[S]);return x>=0?(x>0&&(s.lastNeed=x-1),x):--S<t||x===-2?0:(x=y(l[S]),x>=0?(x>0&&(s.lastNeed=x-2),x):--S<t||x===-2?0:(x=y(l[S]),x>=0?(x>0&&(x===2?x=0:s.lastNeed=x-3),x):0))}function b(s,l,t){if((l[0]&192)!==128)return s.lastNeed=0,"\uFFFD";if(s.lastNeed>1&&l.length>1){if((l[1]&192)!==128)return s.lastNeed=1,"\uFFFD";if(s.lastNeed>2&&l.length>2&&(l[2]&192)!==128)return s.lastNeed=2,"\uFFFD"}}function p(s){var l=this.lastTotal-this.lastNeed,t=b(this,s,l);if(t!==void 0)return t;if(this.lastNeed<=s.length)return s.copy(this.lastChar,l,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);s.copy(this.lastChar,l,0,s.length),this.lastNeed-=s.length}function d(s,l){var t=w(this,s,l);if(!this.lastNeed)return s.toString("utf8",l);this.lastTotal=t;var S=s.length-(t-this.lastNeed);return s.copy(this.lastChar,0,S),s.toString("utf8",l,S)}function n(s){var l=s&&s.length?this.write(s):"";return this.lastNeed?l+"\uFFFD":l}function c(s,l){if((s.length-l)%2===0){var t=s.toString("utf16le",l);if(t){var S=t.charCodeAt(t.length-1);if(S>=55296&&S<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=s[s.length-2],this.lastChar[1]=s[s.length-1],t.slice(0,-1)}return t}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=s[s.length-1],s.toString("utf16le",l,s.length-1)}function r(s){var l=s&&s.length?this.write(s):"";if(this.lastNeed){var t=this.lastTotal-this.lastNeed;return l+this.lastChar.toString("utf16le",0,t)}return l}function i(s,l){var t=(s.length-l)%3;return t===0?s.toString("base64",l):(this.lastNeed=3-t,this.lastTotal=3,t===1?this.lastChar[0]=s[s.length-1]:(this.lastChar[0]=s[s.length-2],this.lastChar[1]=s[s.length-1]),s.toString("base64",l,s.length-t))}function o(s){var l=s&&s.length?this.write(s):"";return this.lastNeed?l+this.lastChar.toString("base64",0,3-this.lastNeed):l}function u(s){return s.toString(this.encoding)}function f(s){return s&&s.length?this.write(s):""}},{"safe-buffer":228}],236:[function(F,Q,j){(function(N,v){var C=F("process/browser.js").nextTick,M=Function.prototype.apply,m=Array.prototype.slice,y={},w=0;j.setTimeout=function(){return new b(M.call(setTimeout,window,arguments),clearTimeout)},j.setInterval=function(){return new b(M.call(setInterval,window,arguments),clearInterval)},j.clearTimeout=j.clearInterval=function(p){p.close()};function b(p,d){this._id=p,this._clearFn=d}b.prototype.unref=b.prototype.ref=function(){},b.prototype.close=function(){this._clearFn.call(window,this._id)},j.enroll=function(p,d){clearTimeout(p._idleTimeoutId),p._idleTimeout=d},j.unenroll=function(p){clearTimeout(p._idleTimeoutId),p._idleTimeout=-1},j._unrefActive=j.active=function(p){clearTimeout(p._idleTimeoutId);var d=p._idleTimeout;d>=0&&(p._idleTimeoutId=setTimeout(function(){p._onTimeout&&p._onTimeout()},d))},j.setImmediate=typeof N=="function"?N:function(p){var d=w++,n=arguments.length<2?!1:m.call(arguments,1);return y[d]=!0,C(function(){y[d]&&(n?p.apply(null,n):p.call(null),j.clearImmediate(d))}),d},j.clearImmediate=typeof v=="function"?v:function(p){delete y[p]}}).call(this,F("timers").setImmediate,F("timers").clearImmediate)},{"process/browser.js":208,timers:236}],237:[function(F,Q,j){var N=F("buffer").Buffer;Q.exports=function(v){if(v instanceof Uint8Array){if(v.byteOffset===0&&v.byteLength===v.buffer.byteLength)return v.buffer;if(typeof v.buffer.slice=="function")return v.buffer.slice(v.byteOffset,v.byteOffset+v.byteLength)}if(N.isBuffer(v)){for(var C=new Uint8Array(v.length),M=v.length,m=0;m<M;m++)C[m]=v[m];return C.buffer}else throw new Error("Argument must be a Buffer")}},{buffer:73}],238:[function(F,Q,j){"use strict";var N=F("punycode"),v=F("./util");j.parse=l,j.resolve=S,j.resolveObject=x,j.format=t,j.Url=C;function C(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var M=/^([a-z0-9.+-]+:)/i,m=/:[0-9]*$/,y=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,w=["<",">",'"',"`"," ","\r",`
`," "],b=["{","}","|","\\","^","`"].concat(w),p=["'"].concat(b),d=["%","/","?",";","#"].concat(p),n=["/","?","#"],c=255,r=/^[+a-z0-9A-Z_-]{0,63}$/,i=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,o={javascript:!0,"javascript:":!0},u={javascript:!0,"javascript:":!0},f={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},s=F("querystring");function l(h,R,O){if(h&&v.isObject(h)&&h instanceof C)return h;var g=new C;return g.parse(h,R,O),g}C.prototype.parse=function(h,R,O){if(!v.isString(h))throw new TypeError("Parameter 'url' must be a string, not "+typeof h);var g=h.indexOf("?"),_=g!==-1&&g<h.indexOf("#")?"?":"#",E=h.split(_),T=/\\/g;E[0]=E[0].replace(T,"/"),h=E.join(_);var L=h;if(L=L.trim(),!O&&h.split("#").length===1){var I=y.exec(L);if(I)return this.path=L,this.href=L,this.pathname=I[1],I[2]?(this.search=I[2],R?this.query=s.parse(this.search.substr(1)):this.query=this.search.substr(1)):R&&(this.search="",this.query={}),this}var P=M.exec(L);if(P){P=P[0];var G=P.toLowerCase();this.protocol=G,L=L.substr(P.length)}if(O||P||L.match(/^\/\/[^@\/]+@[^@\/]+/)){var W=L.substr(0,2)==="//";W&&!(P&&u[P])&&(L=L.substr(2),this.slashes=!0)}if(!u[P]&&(W||P&&!f[P])){for(var H=-1,z=0;z<n.length;z++){var B=L.indexOf(n[z]);B!==-1&&(H===-1||B<H)&&(H=B)}var k,K;H===-1?K=L.lastIndexOf("@"):K=L.lastIndexOf("@",H),K!==-1&&(k=L.slice(0,K),L=L.slice(K+1),this.auth=decodeURIComponent(k)),H=-1;for(var z=0;z<d.length;z++){var B=L.indexOf(d[z]);B!==-1&&(H===-1||B<H)&&(H=B)}H===-1&&(H=L.length),this.host=L.slice(0,H),L=L.slice(H),this.parseHost(),this.hostname=this.hostname||"";var Y=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!Y)for(var ne=this.hostname.split(/\./),z=0,oe=ne.length;z<oe;z++){var _e=ne[z];if(!_e)continue;if(!_e.match(r)){for(var xe="",le=0,me=_e.length;le<me;le++)_e.charCodeAt(le)>127?xe+="x":xe+=_e[le];if(!xe.match(r)){var de=ne.slice(0,z),ae=ne.slice(z+1),ie=_e.match(i);ie&&(de.push(ie[1]),ae.unshift(ie[2])),ae.length&&(L="/"+ae.join(".")+L),this.hostname=de.join(".");break}}}this.hostname.length>c?this.hostname="":this.hostname=this.hostname.toLowerCase(),Y||(this.hostname=N.toASCII(this.hostname));var q=this.port?":"+this.port:"",ue=this.hostname||"";this.host=ue+q,this.href+=this.host,Y&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),L[0]!=="/"&&(L="/"+L))}if(!o[G])for(var z=0,oe=p.length;z<oe;z++){var Z=p[z];if(L.indexOf(Z)===-1)continue;var ee=encodeURIComponent(Z);ee===Z&&(ee=escape(Z)),L=L.split(Z).join(ee)}var Ee=L.indexOf("#");Ee!==-1&&(this.hash=L.substr(Ee),L=L.slice(0,Ee));var te=L.indexOf("?");if(te!==-1?(this.search=L.substr(te),this.query=L.substr(te+1),R&&(this.query=s.parse(this.query)),L=L.slice(0,te)):R&&(this.search="",this.query={}),L&&(this.pathname=L),f[G]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var q=this.pathname||"",J=this.search||"";this.path=q+J}return this.href=this.format(),this};function t(h){return v.isString(h)&&(h=l(h)),h instanceof C?h.format():C.prototype.format.call(h)}C.prototype.format=function(){var h=this.auth||"";h&&(h=encodeURIComponent(h),h=h.replace(/%3A/i,":"),h+="@");var R=this.protocol||"",O=this.pathname||"",g=this.hash||"",_=!1,E="";this.host?_=h+this.host:this.hostname&&(_=h+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(_+=":"+this.port)),this.query&&v.isObject(this.query)&&Object.keys(this.query).length&&(E=s.stringify(this.query));var T=this.search||E&&"?"+E||"";return R&&R.substr(-1)!==":"&&(R+=":"),this.slashes||(!R||f[R])&&_!==!1?(_="//"+(_||""),O&&O.charAt(0)!=="/"&&(O="/"+O)):_||(_=""),g&&g.charAt(0)!=="#"&&(g="#"+g),T&&T.charAt(0)!=="?"&&(T="?"+T),O=O.replace(/[?#]/g,function(L){return encodeURIComponent(L)}),T=T.replace("#","%23"),R+_+O+T+g};function S(h,R){return l(h,!1,!0).resolve(R)}C.prototype.resolve=function(h){return this.resolveObject(l(h,!1,!0)).format()};function x(h,R){return h?l(h,!1,!0).resolveObject(R):R}C.prototype.resolveObject=function(h){if(v.isString(h)){var R=new C;R.parse(h,!1,!0),h=R}for(var O=new C,g=Object.keys(this),_=0;_<g.length;_++){var E=g[_];O[E]=this[E]}if(O.hash=h.hash,h.href==="")return O.href=O.format(),O;if(h.slashes&&!h.protocol){for(var T=Object.keys(h),L=0;L<T.length;L++){var I=T[L];I!=="protocol"&&(O[I]=h[I])}return f[O.protocol]&&O.hostname&&!O.pathname&&(O.path=O.pathname="/"),O.href=O.format(),O}if(h.protocol&&h.protocol!==O.protocol){if(!f[h.protocol]){for(var P=Object.keys(h),G=0;G<P.length;G++){var W=P[G];O[W]=h[W]}return O.href=O.format(),O}if(O.protocol=h.protocol,!h.host&&!u[h.protocol]){for(var oe=(h.pathname||"").split("/");oe.length&&!(h.host=oe.shift()););h.host||(h.host=""),h.hostname||(h.hostname=""),oe[0]!==""&&oe.unshift(""),oe.length<2&&oe.unshift(""),O.pathname=oe.join("/")}else O.pathname=h.pathname;if(O.search=h.search,O.query=h.query,O.host=h.host||"",O.auth=h.auth,O.hostname=h.hostname||h.host,O.port=h.port,O.pathname||O.search){var H=O.pathname||"",z=O.search||"";O.path=H+z}return O.slashes=O.slashes||h.slashes,O.href=O.format(),O}var B=O.pathname&&O.pathname.charAt(0)==="/",k=h.host||h.pathname&&h.pathname.charAt(0)==="/",K=k||B||O.host&&h.pathname,Y=K,ne=O.pathname&&O.pathname.split("/")||[],oe=h.pathname&&h.pathname.split("/")||[],_e=O.protocol&&!f[O.protocol];if(_e&&(O.hostname="",O.port=null,O.host&&(ne[0]===""?ne[0]=O.host:ne.unshift(O.host)),O.host="",h.protocol&&(h.hostname=null,h.port=null,h.host&&(oe[0]===""?oe[0]=h.host:oe.unshift(h.host)),h.host=null),K=K&&(oe[0]===""||ne[0]==="")),k)O.host=h.host||h.host===""?h.host:O.host,O.hostname=h.hostname||h.hostname===""?h.hostname:O.hostname,O.search=h.search,O.query=h.query,ne=oe;else if(oe.length)ne||(ne=[]),ne.pop(),ne=ne.concat(oe),O.search=h.search,O.query=h.query;else if(!v.isNullOrUndefined(h.search)){if(_e){O.hostname=O.host=ne.shift();var xe=O.host&&O.host.indexOf("@")>0?O.host.split("@"):!1;xe&&(O.auth=xe.shift(),O.host=O.hostname=xe.shift())}return O.search=h.search,O.query=h.query,(!v.isNull(O.pathname)||!v.isNull(O.search))&&(O.path=(O.pathname?O.pathname:"")+(O.search?O.search:"")),O.href=O.format(),O}if(!ne.length)return O.pathname=null,O.search?O.path="/"+O.search:O.path=null,O.href=O.format(),O;for(var le=ne.slice(-1)[0],me=(O.host||h.host||ne.length>1)&&(le==="."||le==="..")||le==="",de=0,ae=ne.length;ae>=0;ae--)le=ne[ae],le==="."?ne.splice(ae,1):le===".."?(ne.splice(ae,1),de++):de&&(ne.splice(ae,1),de--);if(!K&&!Y)for(;de--;de)ne.unshift("..");K&&ne[0]!==""&&(!ne[0]||ne[0].charAt(0)!=="/")&&ne.unshift(""),me&&ne.join("/").substr(-1)!=="/"&&ne.push("");var ie=ne[0]===""||ne[0]&&ne[0].charAt(0)==="/";if(_e){O.hostname=O.host=ie?"":ne.length?ne.shift():"";var xe=O.host&&O.host.indexOf("@")>0?O.host.split("@"):!1;xe&&(O.auth=xe.shift(),O.host=O.hostname=xe.shift())}return K=K||O.host&&ne.length,K&&!ie&&ne.unshift(""),ne.length?O.pathname=ne.join("/"):(O.pathname=null,O.path=null),(!v.isNull(O.pathname)||!v.isNull(O.search))&&(O.path=(O.pathname?O.pathname:"")+(O.search?O.search:"")),O.auth=h.auth||O.auth,O.slashes=O.slashes||h.slashes,O.href=O.format(),O},C.prototype.parseHost=function(){var h=this.host,R=m.exec(h);R&&(R=R[0],R!==":"&&(this.port=R.substr(1)),h=h.substr(0,h.length-R.length)),h&&(this.hostname=h)}},{"./util":239,punycode:209,querystring:212}],239:[function(F,Q,j){"use strict";Q.exports={isString:function(N){return typeof N=="string"},isObject:function(N){return typeof N=="object"&&N!==null},isNull:function(N){return N===null},isNullOrUndefined:function(N){return N==null}}},{}],240:[function(F,Q,j){(function(N){Q.exports=v;function v(M,m){if(C("noDeprecation"))return M;var y=!1;function w(){if(!y){if(C("throwDeprecation"))throw new Error(m);C("traceDeprecation")?console.trace(m):console.warn(m),y=!0}return M.apply(this,arguments)}return w}function C(M){try{if(!N.localStorage)return!1}catch(y){return!1}var m=N.localStorage[M];return m==null?!1:String(m).toLowerCase()==="true"}}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],241:[function(F,Q,j){typeof Object.create=="function"?Q.exports=function(v,C){v.super_=C,v.prototype=Object.create(C.prototype,{constructor:{value:v,enumerable:!1,writable:!0,configurable:!0}})}:Q.exports=function(v,C){v.super_=C;var M=function(){};M.prototype=C.prototype,v.prototype=new M,v.prototype.constructor=v}},{}],242:[function(F,Q,j){Q.exports=function(v){return v&&typeof v=="object"&&typeof v.copy=="function"&&typeof v.fill=="function"&&typeof v.readUInt8=="function"}},{}],243:[function(F,Q,j){(function(N,v){var C=/%[sdj%]/g;j.format=function(H){if(!S(H)){for(var z=[],B=0;B<arguments.length;B++)z.push(y(arguments[B]));return z.join(" ")}for(var B=1,k=arguments,K=k.length,Y=String(H).replace(C,function(oe){if(oe==="%%")return"%";if(B>=K)return oe;switch(oe){case"%s":return String(k[B++]);case"%d":return Number(k[B++]);case"%j":try{return JSON.stringify(k[B++])}catch(_e){return"[Circular]"}default:return oe}}),ne=k[B];B<K;ne=k[++B])s(ne)||!O(ne)?Y+=" "+ne:Y+=" "+y(ne);return Y},j.deprecate=function(H,z){if(h(v.process))return function(){return j.deprecate(H,z).apply(this,arguments)};if(N.noDeprecation===!0)return H;var B=!1;function k(){if(!B){if(N.throwDeprecation)throw new Error(z);N.traceDeprecation?console.trace(z):console.error(z),B=!0}return H.apply(this,arguments)}return k};var M={},m;j.debuglog=function(H){if(h(m)&&(m=N.env.NODE_DEBUG||""),H=H.toUpperCase(),!M[H])if(new RegExp("\\b"+H+"\\b","i").test(m)){var z=N.pid;M[H]=function(){var B=j.format.apply(j,arguments);console.error("%s %d: %s",H,z,B)}}else M[H]=function(){};return M[H]};function y(H,z){var B={seen:[],stylize:b};return arguments.length>=3&&(B.depth=arguments[2]),arguments.length>=4&&(B.colors=arguments[3]),f(z)?B.showHidden=z:z&&j._extend(B,z),h(B.showHidden)&&(B.showHidden=!1),h(B.depth)&&(B.depth=2),h(B.colors)&&(B.colors=!1),h(B.customInspect)&&(B.customInspect=!0),B.colors&&(B.stylize=w),d(B,H,B.depth)}j.inspect=y,y.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},y.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function w(H,z){var B=y.styles[z];return B?"["+y.colors[B][0]+"m"+H+"["+y.colors[B][1]+"m":H}function b(H,z){return H}function p(H){var z={};return H.forEach(function(B,k){z[B]=!0}),z}function d(H,z,B){if(H.customInspect&&z&&E(z.inspect)&&z.inspect!==j.inspect&&!(z.constructor&&z.constructor.prototype===z)){var k=z.inspect(B,H);return S(k)||(k=d(H,k,B)),k}var K=n(H,z);if(K)return K;var Y=Object.keys(z),ne=p(Y);if(H.showHidden&&(Y=Object.getOwnPropertyNames(z)),_(z)&&(Y.indexOf("message")>=0||Y.indexOf("description")>=0))return c(z);if(Y.length===0){if(E(z)){var oe=z.name?": "+z.name:"";return H.stylize("[Function"+oe+"]","special")}if(R(z))return H.stylize(RegExp.prototype.toString.call(z),"regexp");if(g(z))return H.stylize(Date.prototype.toString.call(z),"date");if(_(z))return c(z)}var _e="",xe=!1,le=["{","}"];if(u(z)&&(xe=!0,le=["[","]"]),E(z)){var me=z.name?": "+z.name:"";_e=" [Function"+me+"]"}if(R(z)&&(_e=" "+RegExp.prototype.toString.call(z)),g(z)&&(_e=" "+Date.prototype.toUTCString.call(z)),_(z)&&(_e=" "+c(z)),Y.length===0&&(!xe||z.length==0))return le[0]+_e+le[1];if(B<0)return R(z)?H.stylize(RegExp.prototype.toString.call(z),"regexp"):H.stylize("[Object]","special");H.seen.push(z);var de;return xe?de=r(H,z,B,ne,Y):de=Y.map(function(ae){return i(H,z,B,ne,ae,xe)}),H.seen.pop(),o(de,_e,le)}function n(H,z){if(h(z))return H.stylize("undefined","undefined");if(S(z)){var B="'"+JSON.stringify(z).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return H.stylize(B,"string")}if(t(z))return H.stylize(""+z,"number");if(f(z))return H.stylize(""+z,"boolean");if(s(z))return H.stylize("null","null")}function c(H){return"["+Error.prototype.toString.call(H)+"]"}function r(H,z,B,k,K){for(var Y=[],ne=0,oe=z.length;ne<oe;++ne)W(z,String(ne))?Y.push(i(H,z,B,k,String(ne),!0)):Y.push("");return K.forEach(function(_e){_e.match(/^\d+$/)||Y.push(i(H,z,B,k,_e,!0))}),Y}function i(H,z,B,k,K,Y){var ne,oe,_e;if(_e=Object.getOwnPropertyDescriptor(z,K)||{value:z[K]},_e.get?_e.set?oe=H.stylize("[Getter/Setter]","special"):oe=H.stylize("[Getter]","special"):_e.set&&(oe=H.stylize("[Setter]","special")),W(k,K)||(ne="["+K+"]"),oe||(H.seen.indexOf(_e.value)<0?(s(B)?oe=d(H,_e.value,null):oe=d(H,_e.value,B-1),oe.indexOf(`
`)>-1&&(Y?oe=oe.split(`
`).map(function(xe){return" "+xe}).join(`
`).substr(2):oe=`
`+oe.split(`
`).map(function(xe){return" "+xe}).join(`
`))):oe=H.stylize("[Circular]","special")),h(ne)){if(Y&&K.match(/^\d+$/))return oe;ne=JSON.stringify(""+K),ne.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(ne=ne.substr(1,ne.length-2),ne=H.stylize(ne,"name")):(ne=ne.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),ne=H.stylize(ne,"string"))}return ne+": "+oe}function o(H,z,B){var k=0,K=H.reduce(function(Y,ne){return k++,ne.indexOf(`
`)>=0&&k++,Y+ne.replace(/\u001b\[\d\d?m/g,"").length+1},0);return K>60?B[0]+(z===""?"":z+`
`)+" "+H.join(`,
`)+" "+B[1]:B[0]+z+" "+H.join(", ")+" "+B[1]}function u(H){return Array.isArray(H)}j.isArray=u;function f(H){return typeof H=="boolean"}j.isBoolean=f;function s(H){return H===null}j.isNull=s;function l(H){return H==null}j.isNullOrUndefined=l;function t(H){return typeof H=="number"}j.isNumber=t;function S(H){return typeof H=="string"}j.isString=S;function x(H){return typeof H=="symbol"}j.isSymbol=x;function h(H){return H===void 0}j.isUndefined=h;function R(H){return O(H)&&L(H)==="[object RegExp]"}j.isRegExp=R;function O(H){return typeof H=="object"&&H!==null}j.isObject=O;function g(H){return O(H)&&L(H)==="[object Date]"}j.isDate=g;function _(H){return O(H)&&(L(H)==="[object Error]"||H instanceof Error)}j.isError=_;function E(H){return typeof H=="function"}j.isFunction=E;function T(H){return H===null||typeof H=="boolean"||typeof H=="number"||typeof H=="string"||typeof H=="symbol"||typeof H=="undefined"}j.isPrimitive=T,j.isBuffer=F("./support/isBuffer");function L(H){return Object.prototype.toString.call(H)}function I(H){return H<10?"0"+H.toString(10):H.toString(10)}var P=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function G(){var H=new Date,z=[I(H.getHours()),I(H.getMinutes()),I(H.getSeconds())].join(":");return[H.getDate(),P[H.getMonth()],z].join(" ")}j.log=function(){console.log("%s - %s",G(),j.format.apply(j,arguments))},j.inherits=F("inherits"),j._extend=function(H,z){if(!z||!O(z))return H;for(var B=Object.keys(z),k=B.length;k--;)H[B[k]]=z[B[k]];return H};function W(H,z){return Object.prototype.hasOwnProperty.call(H,z)}}).call(this,F("_process"),typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./support/isBuffer":242,_process:208,inherits:241}],244:[function(F,Q,j){"use strict";(function(){"use strict";j.stripBOM=function(N){return N[0]==="\uFEFF"?N.substring(1):N}}).call(void 0)},{}],245:[function(F,Q,j){"use strict";var N=F("babel-runtime/helpers/typeof"),v=m(N),C=F("babel-runtime/core-js/object/keys"),M=m(C);function m(y){return y&&y.__esModule?y:{default:y}}(function(){"use strict";var y,w,b,p,d,n={}.hasOwnProperty;y=F("xmlbuilder"),w=F("./defaults").defaults,p=function(r){return typeof r=="string"&&(r.indexOf("&")>=0||r.indexOf(">")>=0||r.indexOf("<")>=0)},d=function(r){return"<![CDATA["+b(r)+"]]>"},b=function(r){return r.replace("]]>","]]]]><![CDATA[>")},j.Builder=function(){function c(r){var i,o,u;this.options={},o=w["0.2"];for(i in o){if(!n.call(o,i))continue;u=o[i],this.options[i]=u}for(i in r){if(!n.call(r,i))continue;u=r[i],this.options[i]=u}}return c.prototype.buildObject=function(r){var i,o,u,f,s;return i=this.options.attrkey,o=this.options.charkey,(0,M.default)(r).length===1&&this.options.rootName===w["0.2"].rootName?(s=(0,M.default)(r)[0],r=r[s]):s=this.options.rootName,u=function(l){return function(t,S){var x,h,R,O,g,_;if((typeof S=="undefined"?"undefined":(0,v.default)(S))!=="object")l.options.cdata&&p(S)?t.raw(d(S)):t.txt(S);else if(Array.isArray(S))for(O in S){if(!n.call(S,O))continue;h=S[O];for(g in h)R=h[g],t=u(t.ele(g),R).up()}else for(g in S){if(!n.call(S,g))continue;if(h=S[g],g===i){if((typeof h=="undefined"?"undefined":(0,v.default)(h))==="object")for(x in h)_=h[x],t=t.att(x,_)}else if(g===o)l.options.cdata&&p(h)?t=t.raw(d(h)):t=t.txt(h);else if(Array.isArray(h))for(O in h){if(!n.call(h,O))continue;R=h[O],typeof R=="string"?l.options.cdata&&p(R)?t=t.ele(g).raw(d(R)).up():t=t.ele(g,R).up():t=u(t.ele(g),R).up()}else(typeof h=="undefined"?"undefined":(0,v.default)(h))==="object"?t=u(t.ele(g),h).up():typeof h=="string"&&l.options.cdata&&p(h)?t=t.ele(g).raw(d(h)).up():(h==null&&(h=""),t=t.ele(g,h.toString()).up())}return t}}(this),f=y.create(s,this.options.xmldec,this.options.doctype,{headless:this.options.headless,allowSurrogateChars:this.options.allowSurrogateChars}),u(f,r).end(this.options.renderOpts)},c}()}).call(void 0)},{"./defaults":246,"babel-runtime/core-js/object/keys":60,"babel-runtime/helpers/typeof":67,xmlbuilder:282}],246:[function(F,Q,j){"use strict";(function(){j.defaults={"0.1":{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},"0.2":{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:"$",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:"$$",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:" ",newline:`
`},headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(void 0)},{}],247:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/promise"),v=p(N),C=F("babel-runtime/core-js/object/get-own-property-names"),M=p(C),m=F("babel-runtime/core-js/object/keys"),y=p(m),w=F("babel-runtime/helpers/typeof"),b=p(w);function p(d){return d&&d.__esModule?d:{default:d}}(function(){"use strict";var d,n,c,r,i,o,u,f,s=function(x,h){return function(){return x.apply(h,arguments)}},l=function(x,h){for(var R in h)t.call(h,R)&&(x[R]=h[R]);function O(){this.constructor=x}return O.prototype=h.prototype,x.prototype=new O,x.__super__=h.prototype,x},t={}.hasOwnProperty;u=F("sax"),c=F("events"),d=F("./bom"),o=F("./processors"),f=F("timers").setImmediate,n=F("./defaults").defaults,r=function(x){return(typeof x=="undefined"?"undefined":(0,b.default)(x))==="object"&&x!=null&&(0,y.default)(x).length===0},i=function(x,h,R){var O,g,_;for(O=0,g=x.length;O<g;O++)_=x[O],h=_(h,R);return h},j.Parser=function(S){l(x,S);function x(h){this.parseStringPromise=s(this.parseStringPromise,this),this.parseString=s(this.parseString,this),this.reset=s(this.reset,this),this.assignOrPush=s(this.assignOrPush,this),this.processAsync=s(this.processAsync,this);var R,O,g;if(!(this instanceof j.Parser))return new j.Parser(h);this.options={},O=n["0.2"];for(R in O){if(!t.call(O,R))continue;g=O[R],this.options[R]=g}for(R in h){if(!t.call(h,R))continue;g=h[R],this.options[R]=g}this.options.xmlns&&(this.options.xmlnskey=this.options.attrkey+"ns"),this.options.normalizeTags&&(this.options.tagNameProcessors||(this.options.tagNameProcessors=[]),this.options.tagNameProcessors.unshift(o.normalize)),this.reset()}return x.prototype.processAsync=function(){var h,R;try{return this.remaining.length<=this.options.chunkSize?(h=this.remaining,this.remaining="",this.saxParser=this.saxParser.write(h),this.saxParser.close()):(h=this.remaining.substr(0,this.options.chunkSize),this.remaining=this.remaining.substr(this.options.chunkSize,this.remaining.length),this.saxParser=this.saxParser.write(h),f(this.processAsync))}catch(O){if(R=O,!this.saxParser.errThrown)return this.saxParser.errThrown=!0,this.emit(R)}},x.prototype.assignOrPush=function(h,R,O){return R in h?(h[R]instanceof Array||(h[R]=[h[R]]),h[R].push(O)):this.options.explicitArray?h[R]=[O]:h[R]=O},x.prototype.reset=function(){var h,R,O,g;return this.removeAllListeners(),this.saxParser=u.parser(this.options.strict,{trim:!1,normalize:!1,xmlns:this.options.xmlns}),this.saxParser.errThrown=!1,this.saxParser.onerror=function(_){return function(E){if(_.saxParser.resume(),!_.saxParser.errThrown)return _.saxParser.errThrown=!0,_.emit("error",E)}}(this),this.saxParser.onend=function(_){return function(){if(!_.saxParser.ended)return _.saxParser.ended=!0,_.emit("end",_.resultObject)}}(this),this.saxParser.ended=!1,this.EXPLICIT_CHARKEY=this.options.explicitCharkey,this.resultObject=null,g=[],h=this.options.attrkey,R=this.options.charkey,this.saxParser.onopentag=function(_){return function(E){var T,L,I,P,G;if(I={},I[R]="",!_.options.ignoreAttrs){G=E.attributes;for(T in G){if(!t.call(G,T))continue;!(h in I)&&!_.options.mergeAttrs&&(I[h]={}),L=_.options.attrValueProcessors?i(_.options.attrValueProcessors,E.attributes[T],T):E.attributes[T],P=_.options.attrNameProcessors?i(_.options.attrNameProcessors,T):T,_.options.mergeAttrs?_.assignOrPush(I,P,L):I[h][P]=L}}return I["#name"]=_.options.tagNameProcessors?i(_.options.tagNameProcessors,E.name):E.name,_.options.xmlns&&(I[_.options.xmlnskey]={uri:E.uri,local:E.local}),g.push(I)}}(this),this.saxParser.onclosetag=function(_){return function(){var E,T,L,I,P,G,W,H,z,B;if(G=g.pop(),P=G["#name"],(!_.options.explicitChildren||!_.options.preserveChildrenOrder)&&delete G["#name"],G.cdata===!0&&(E=G.cdata,delete G.cdata),z=g[g.length-1],G[R].match(/^\s*$/)&&!E?(T=G[R],delete G[R]):(_.options.trim&&(G[R]=G[R].trim()),_.options.normalize&&(G[R]=G[R].replace(/\s{2,}/g," ").trim()),G[R]=_.options.valueProcessors?i(_.options.valueProcessors,G[R],P):G[R],(0,y.default)(G).length===1&&R in G&&!_.EXPLICIT_CHARKEY&&(G=G[R])),r(G)&&(G=_.options.emptyTag!==""?_.options.emptyTag:T),_.options.validator!=null&&(B="/"+function(){var k,K,Y;for(Y=[],k=0,K=g.length;k<K;k++)I=g[k],Y.push(I["#name"]);return Y}().concat(P).join("/"),function(){var k;try{return G=_.options.validator(B,z&&z[P],G)}catch(K){return k=K,_.emit("error",k)}}()),_.options.explicitChildren&&!_.options.mergeAttrs&&(typeof G=="undefined"?"undefined":(0,b.default)(G))==="object"){if(!_.options.preserveChildrenOrder)I={},_.options.attrkey in G&&(I[_.options.attrkey]=G[_.options.attrkey],delete G[_.options.attrkey]),!_.options.charsAsChildren&&_.options.charkey in G&&(I[_.options.charkey]=G[_.options.charkey],delete G[_.options.charkey]),(0,M.default)(G).length>0&&(I[_.options.childkey]=G),G=I;else if(z){z[_.options.childkey]=z[_.options.childkey]||[],W={};for(L in G){if(!t.call(G,L))continue;W[L]=G[L]}z[_.options.childkey].push(W),delete G["#name"],(0,y.default)(G).length===1&&R in G&&!_.EXPLICIT_CHARKEY&&(G=G[R])}}return g.length>0?_.assignOrPush(z,P,G):(_.options.explicitRoot&&(H=G,G={},G[P]=H),_.resultObject=G,_.saxParser.ended=!0,_.emit("end",_.resultObject))}}(this),O=function(_){return function(E){var T,L;if(L=g[g.length-1],L)return L[R]+=E,_.options.explicitChildren&&_.options.preserveChildrenOrder&&_.options.charsAsChildren&&(_.options.includeWhiteChars||E.replace(/\\n/g,"").trim()!=="")&&(L[_.options.childkey]=L[_.options.childkey]||[],T={"#name":"__text__"},T[R]=E,_.options.normalize&&(T[R]=T[R].replace(/\s{2,}/g," ").trim()),L[_.options.childkey].push(T)),L}}(this),this.saxParser.ontext=O,this.saxParser.oncdata=function(_){return function(E){var T;if(T=O(E),T)return T.cdata=!0}}(this)},x.prototype.parseString=function(h,R){var O;R!=null&&typeof R=="function"&&(this.on("end",function(g){return this.reset(),R(null,g)}),this.on("error",function(g){return this.reset(),R(g)}));try{return h=h.toString(),h.trim()===""?(this.emit("end",null),!0):(h=d.stripBOM(h),this.options.async?(this.remaining=h,f(this.processAsync),this.saxParser):this.saxParser.write(h).close())}catch(g){if(O=g,this.saxParser.errThrown||this.saxParser.ended){if(this.saxParser.ended)throw O}else return this.emit("error",O),this.saxParser.errThrown=!0}},x.prototype.parseStringPromise=function(h){return new v.default(function(R){return function(O,g){return R.parseString(h,function(_,E){return _?g(_):O(E)})}}(this))},x}(c),j.parseString=function(S,x,h){var R,O,g;return h!=null?(typeof h=="function"&&(R=h),(typeof x=="undefined"?"undefined":(0,b.default)(x))==="object"&&(O=x)):(typeof x=="function"&&(R=x),O={}),g=new j.Parser(O),g.parseString(S,R)},j.parseStringPromise=function(S,x){var h,R;return(typeof x=="undefined"?"undefined":(0,b.default)(x))==="object"&&(h=x),R=new j.Parser(h),R.parseStringPromise(S)}}).call(void 0)},{"./bom":244,"./defaults":246,"./processors":248,"babel-runtime/core-js/object/get-own-property-names":58,"babel-runtime/core-js/object/keys":60,"babel-runtime/core-js/promise":61,"babel-runtime/helpers/typeof":67,events:192,sax:229,timers:236}],248:[function(F,Q,j){"use strict";(function(){"use strict";var N;N=new RegExp(/(?!xmlns)^.*:/),j.normalize=function(v){return v.toLowerCase()},j.firstCharLowerCase=function(v){return v.charAt(0).toLowerCase()+v.slice(1)},j.stripPrefix=function(v){return v.replace(N,"")},j.parseNumbers=function(v){return isNaN(v)||(v=v%1===0?parseInt(v,10):parseFloat(v)),v},j.parseBooleans=function(v){return/^(?:true|false)$/i.test(v)&&(v=v.toLowerCase()==="true"),v}}).call(void 0)},{}],249:[function(F,Q,j){"use strict";(function(){"use strict";var N,v,C,M,m=function(b,p){for(var d in p)y.call(p,d)&&(b[d]=p[d]);function n(){this.constructor=b}return n.prototype=p.prototype,b.prototype=new n,b.__super__=p.prototype,b},y={}.hasOwnProperty;v=F("./defaults"),N=F("./builder"),C=F("./parser"),M=F("./processors"),j.defaults=v.defaults,j.processors=M,j.ValidationError=function(w){m(b,w);function b(p){this.message=p}return b}(Error),j.Builder=N.Builder,j.Parser=C.Parser,j.parseString=C.parseString,j.parseStringPromise=C.parseStringPromise}).call(void 0)},{"./builder":245,"./defaults":246,"./parser":247,"./processors":248}],250:[function(F,Q,j){"use strict";(function(){Q.exports={Disconnected:1,Preceding:2,Following:4,Contains:8,ContainedBy:16,ImplementationSpecific:32}}).call(void 0)},{}],251:[function(F,Q,j){"use strict";(function(){Q.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(void 0)},{}],252:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/get-prototype-of"),v=w(N),C=F("babel-runtime/helpers/typeof"),M=w(C),m=F("babel-runtime/core-js/object/assign"),y=w(m);function w(b){return b&&b.__esModule?b:{default:b}}(function(){var b,p,d,n,c,r,i,o=[].slice,u={}.hasOwnProperty;b=function(){var s,l,t,S,x,h;if(h=arguments[0],x=2<=arguments.length?o.call(arguments,1):[],c(y.default))y.default.apply(null,arguments);else for(s=0,t=x.length;s<t;s++)if(S=x[s],S!=null)for(l in S){if(!u.call(S,l))continue;h[l]=S[l]}return h},c=function(s){return!!s&&Object.prototype.toString.call(s)==="[object Function]"},r=function(s){var l;return!!s&&((l=typeof s=="undefined"?"undefined":(0,M.default)(s))==="function"||l==="object")},d=function(s){return c(Array.isArray)?Array.isArray(s):Object.prototype.toString.call(s)==="[object Array]"},n=function(s){var l;if(d(s))return!s.length;for(l in s){if(!u.call(s,l))continue;return!1}return!0},i=function(s){var l,t;return r(s)&&(t=(0,v.default)(s))&&(l=t.constructor)&&typeof l=="function"&&l instanceof l&&Function.prototype.toString.call(l)===Function.prototype.toString.call(Object)},p=function(s){return c(s.valueOf)?s.valueOf():s},Q.exports.assign=b,Q.exports.isFunction=c,Q.exports.isObject=r,Q.exports.isArray=d,Q.exports.isEmpty=n,Q.exports.isPlainObject=i,Q.exports.getValue=p}).call(void 0)},{"babel-runtime/core-js/object/assign":54,"babel-runtime/core-js/object/get-prototype-of":59,"babel-runtime/helpers/typeof":67}],253:[function(F,Q,j){"use strict";(function(){Q.exports={None:0,OpenTag:1,InsideTag:2,CloseTag:3}}).call(void 0)},{}],254:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y;M=F("./NodeType"),y=F("./XMLNode"),Q.exports=m=function(){function w(b,p,d){if(this.parent=b,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),p==null)throw new Error("Missing attribute name. "+this.debugInfo(p));this.name=this.stringify.name(p),this.value=this.stringify.attValue(d),this.type=M.Attribute,this.isId=!1,this.schemaTypeInfo=null}return Object.defineProperty(w.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(w.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(w.prototype,"textContent",{get:function(){return this.value},set:function(p){return this.value=p||""}}),Object.defineProperty(w.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(w.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(w.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(w.prototype,"specified",{get:function(){return!0}}),w.prototype.clone=function(){return(0,v.default)(this)},w.prototype.toString=function(b){return this.options.writer.attribute(this,this.options.writer.filterOptions(b))},w.prototype.debugInfo=function(b){return b=b||this.name,b==null?"parent: <"+this.parent.name+">":"attribute: {"+b+"}, parent: <"+this.parent.name+">"},w.prototype.isEqualNode=function(b){return b.namespaceURI!==this.namespaceURI||(b.prefix!==this.prefix||b.localName!==this.localName)?!1:!(b.value!==this.value)},w}()}).call(void 0)},{"./NodeType":251,"./XMLNode":273,"babel-runtime/core-js/object/create":55}],255:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w=function(d,n){for(var c in n)b.call(n,c)&&(d[c]=n[c]);function r(){this.constructor=d}return r.prototype=n.prototype,d.prototype=new r,d.__super__=n.prototype,d},b={}.hasOwnProperty;M=F("./NodeType"),y=F("./XMLCharacterData"),Q.exports=m=function(p){w(d,p);function d(n,c){if(d.__super__.constructor.call(this,n),c==null)throw new Error("Missing CDATA text. "+this.debugInfo());this.name="#cdata-section",this.type=M.CData,this.value=this.stringify.cdata(c)}return d.prototype.clone=function(){return(0,v.default)(this)},d.prototype.toString=function(n){return this.options.writer.cdata(this,this.options.writer.filterOptions(n))},d}(y)}).call(void 0)},{"./NodeType":251,"./XMLCharacterData":256,"babel-runtime/core-js/object/create":55}],256:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y=function(p,d){for(var n in d)w.call(d,n)&&(p[n]=d[n]);function c(){this.constructor=p}return c.prototype=d.prototype,p.prototype=new c,p.__super__=d.prototype,p},w={}.hasOwnProperty;m=F("./XMLNode"),Q.exports=M=function(b){y(p,b);function p(d){p.__super__.constructor.call(this,d),this.value=""}return Object.defineProperty(p.prototype,"data",{get:function(){return this.value},set:function(n){return this.value=n||""}}),Object.defineProperty(p.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(p.prototype,"textContent",{get:function(){return this.value},set:function(n){return this.value=n||""}}),p.prototype.clone=function(){return(0,v.default)(this)},p.prototype.substringData=function(d,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},p.prototype.appendData=function(d){throw new Error("This DOM method is not implemented."+this.debugInfo())},p.prototype.insertData=function(d,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},p.prototype.deleteData=function(d,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},p.prototype.replaceData=function(d,n,c){throw new Error("This DOM method is not implemented."+this.debugInfo())},p.prototype.isEqualNode=function(d){return p.__super__.isEqualNode.apply(this,arguments).isEqualNode(d)?!(d.data!==this.data):!1},p}(m)}).call(void 0)},{"./XMLNode":273,"babel-runtime/core-js/object/create":55}],257:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w=function(d,n){for(var c in n)b.call(n,c)&&(d[c]=n[c]);function r(){this.constructor=d}return r.prototype=n.prototype,d.prototype=new r,d.__super__=n.prototype,d},b={}.hasOwnProperty;M=F("./NodeType"),m=F("./XMLCharacterData"),Q.exports=y=function(p){w(d,p);function d(n,c){if(d.__super__.constructor.call(this,n),c==null)throw new Error("Missing comment text. "+this.debugInfo());this.name="#comment",this.type=M.Comment,this.value=this.stringify.comment(c)}return d.prototype.clone=function(){return(0,v.default)(this)},d.prototype.toString=function(n){return this.options.writer.comment(this,this.options.writer.filterOptions(n))},d}(m)}).call(void 0)},{"./NodeType":251,"./XMLCharacterData":256,"babel-runtime/core-js/object/create":55}],258:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/keys"),v=m(N),C=F("babel-runtime/core-js/object/create"),M=m(C);function m(y){return y&&y.__esModule?y:{default:y}}(function(){var y,w,b;w=F("./XMLDOMErrorHandler"),b=F("./XMLDOMStringList"),Q.exports=y=function(){function p(){var d;this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new w,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=d=(0,M.default)(this.defaultParams)}return Object.defineProperty(p.prototype,"parameterNames",{get:function(){return new b((0,v.default)(this.defaultParams))}}),p.prototype.getParameter=function(d){return this.params.hasOwnProperty(d)?this.params[d]:null},p.prototype.canSetParameter=function(d,n){return!0},p.prototype.setParameter=function(d,n){return n!=null?this.params[d]=n:delete this.params[d]},p}()}).call(void 0)},{"./XMLDOMErrorHandler":259,"./XMLDOMStringList":261,"babel-runtime/core-js/object/create":55,"babel-runtime/core-js/object/keys":60}],259:[function(F,Q,j){"use strict";(function(){var N;Q.exports=N=function(){function v(){}return v.prototype.handleError=function(C){throw new Error(C)},v}()}).call(void 0)},{}],260:[function(F,Q,j){"use strict";(function(){var N;Q.exports=N=function(){function v(){}return v.prototype.hasFeature=function(C,M){return!0},v.prototype.createDocumentType=function(C,M,m){throw new Error("This DOM method is not implemented.")},v.prototype.createDocument=function(C,M,m){throw new Error("This DOM method is not implemented.")},v.prototype.createHTMLDocument=function(C){throw new Error("This DOM method is not implemented.")},v.prototype.getFeature=function(C,M){throw new Error("This DOM method is not implemented.")},v}()}).call(void 0)},{}],261:[function(F,Q,j){"use strict";(function(){var N;Q.exports=N=function(){function v(C){this.arr=C||[]}return Object.defineProperty(v.prototype,"length",{get:function(){return this.arr.length}}),v.prototype.item=function(C){return this.arr[C]||null},v.prototype.contains=function(C){return this.arr.indexOf(C)!==-1},v}()}).call(void 0)},{}],262:[function(F,Q,j){"use strict";(function(){var N,v,C,M=function(w,b){for(var p in b)m.call(b,p)&&(w[p]=b[p]);function d(){this.constructor=w}return d.prototype=b.prototype,w.prototype=new d,w.__super__=b.prototype,w},m={}.hasOwnProperty;C=F("./XMLNode"),N=F("./NodeType"),Q.exports=v=function(y){M(w,y);function w(b,p,d,n,c,r){if(w.__super__.constructor.call(this,b),p==null)throw new Error("Missing DTD element name. "+this.debugInfo());if(d==null)throw new Error("Missing DTD attribute name. "+this.debugInfo(p));if(!n)throw new Error("Missing DTD attribute type. "+this.debugInfo(p));if(!c)throw new Error("Missing DTD attribute default. "+this.debugInfo(p));if(c.indexOf("#")!==0&&(c="#"+c),!c.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. "+this.debugInfo(p));if(r&&!c.match(/^(#FIXED|#DEFAULT)$/))throw new Error("Default value only applies to #FIXED or #DEFAULT. "+this.debugInfo(p));this.elementName=this.stringify.name(p),this.type=N.AttributeDeclaration,this.attributeName=this.stringify.name(d),this.attributeType=this.stringify.dtdAttType(n),r&&(this.defaultValue=this.stringify.dtdAttDefault(r)),this.defaultValueType=c}return w.prototype.toString=function(b){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(b))},w}(C)}).call(void 0)},{"./NodeType":251,"./XMLNode":273}],263:[function(F,Q,j){"use strict";(function(){var N,v,C,M=function(w,b){for(var p in b)m.call(b,p)&&(w[p]=b[p]);function d(){this.constructor=w}return d.prototype=b.prototype,w.prototype=new d,w.__super__=b.prototype,w},m={}.hasOwnProperty;C=F("./XMLNode"),N=F("./NodeType"),Q.exports=v=function(y){M(w,y);function w(b,p,d){if(w.__super__.constructor.call(this,b),p==null)throw new Error("Missing DTD element name. "+this.debugInfo());d||(d="(#PCDATA)"),Array.isArray(d)&&(d="("+d.join(",")+")"),this.name=this.stringify.name(p),this.type=N.ElementDeclaration,this.value=this.stringify.dtdElementValue(d)}return w.prototype.toString=function(b){return this.options.writer.dtdElement(this,this.options.writer.filterOptions(b))},w}(C)}).call(void 0)},{"./NodeType":251,"./XMLNode":273}],264:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m=function(b,p){for(var d in p)y.call(p,d)&&(b[d]=p[d]);function n(){this.constructor=b}return n.prototype=p.prototype,b.prototype=new n,b.__super__=p.prototype,b},y={}.hasOwnProperty;M=F("./Utility").isObject,C=F("./XMLNode"),N=F("./NodeType"),Q.exports=v=function(w){m(b,w);function b(p,d,n,c){if(b.__super__.constructor.call(this,p),n==null)throw new Error("Missing DTD entity name. "+this.debugInfo(n));if(c==null)throw new Error("Missing DTD entity value. "+this.debugInfo(n));if(this.pe=!!d,this.name=this.stringify.name(n),this.type=N.EntityDeclaration,!M(c))this.value=this.stringify.dtdEntityValue(c),this.internal=!0;else{if(!c.pubID&&!c.sysID)throw new Error("Public and/or system identifiers are required for an external entity. "+this.debugInfo(n));if(c.pubID&&!c.sysID)throw new Error("System identifier is required for a public external entity. "+this.debugInfo(n));if(this.internal=!1,c.pubID!=null&&(this.pubID=this.stringify.dtdPubID(c.pubID)),c.sysID!=null&&(this.sysID=this.stringify.dtdSysID(c.sysID)),c.nData!=null&&(this.nData=this.stringify.dtdNData(c.nData)),this.pe&&this.nData)throw new Error("Notation declaration is not allowed in a parameter entity. "+this.debugInfo(n))}}return Object.defineProperty(b.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(b.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(b.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(b.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(b.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(b.prototype,"xmlVersion",{get:function(){return null}}),b.prototype.toString=function(p){return this.options.writer.dtdEntity(this,this.options.writer.filterOptions(p))},b}(C)}).call(void 0)},{"./NodeType":251,"./Utility":252,"./XMLNode":273}],265:[function(F,Q,j){"use strict";(function(){var N,v,C,M=function(w,b){for(var p in b)m.call(b,p)&&(w[p]=b[p]);function d(){this.constructor=w}return d.prototype=b.prototype,w.prototype=new d,w.__super__=b.prototype,w},m={}.hasOwnProperty;C=F("./XMLNode"),N=F("./NodeType"),Q.exports=v=function(y){M(w,y);function w(b,p,d){if(w.__super__.constructor.call(this,b),p==null)throw new Error("Missing DTD notation name. "+this.debugInfo(p));if(!d.pubID&&!d.sysID)throw new Error("Public or system identifiers are required for an external entity. "+this.debugInfo(p));this.name=this.stringify.name(p),this.type=N.NotationDeclaration,d.pubID!=null&&(this.pubID=this.stringify.dtdPubID(d.pubID)),d.sysID!=null&&(this.sysID=this.stringify.dtdSysID(d.sysID))}return Object.defineProperty(w.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(w.prototype,"systemId",{get:function(){return this.sysID}}),w.prototype.toString=function(b){return this.options.writer.dtdNotation(this,this.options.writer.filterOptions(b))},w}(C)}).call(void 0)},{"./NodeType":251,"./XMLNode":273}],266:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m=function(b,p){for(var d in p)y.call(p,d)&&(b[d]=p[d]);function n(){this.constructor=b}return n.prototype=p.prototype,b.prototype=new n,b.__super__=p.prototype,b},y={}.hasOwnProperty;M=F("./Utility").isObject,C=F("./XMLNode"),N=F("./NodeType"),Q.exports=v=function(w){m(b,w);function b(p,d,n,c){var r;b.__super__.constructor.call(this,p),M(d)&&(r=d,d=r.version,n=r.encoding,c=r.standalone),d||(d="1.0"),this.type=N.Declaration,this.version=this.stringify.xmlVersion(d),n!=null&&(this.encoding=this.stringify.xmlEncoding(n)),c!=null&&(this.standalone=this.stringify.xmlStandalone(c))}return b.prototype.toString=function(p){return this.options.writer.declaration(this,this.options.writer.filterOptions(p))},b}(C)}).call(void 0)},{"./NodeType":251,"./Utility":252,"./XMLNode":273}],267:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m,y,w,b,p,d=function(r,i){for(var o in i)n.call(i,o)&&(r[o]=i[o]);function u(){this.constructor=r}return u.prototype=i.prototype,r.prototype=new u,r.__super__=i.prototype,r},n={}.hasOwnProperty;p=F("./Utility").isObject,b=F("./XMLNode"),N=F("./NodeType"),v=F("./XMLDTDAttList"),M=F("./XMLDTDEntity"),C=F("./XMLDTDElement"),m=F("./XMLDTDNotation"),w=F("./XMLNamedNodeMap"),Q.exports=y=function(c){d(r,c);function r(i,o,u){var f,s,l,t,S,x;if(r.__super__.constructor.call(this,i),this.type=N.DocType,i.children){for(t=i.children,s=0,l=t.length;s<l;s++)if(f=t[s],f.type===N.Element){this.name=f.name;break}}this.documentObject=i,p(o)&&(S=o,o=S.pubID,u=S.sysID),u==null&&(x=[o,u],u=x[0],o=x[1]),o!=null&&(this.pubID=this.stringify.dtdPubID(o)),u!=null&&(this.sysID=this.stringify.dtdSysID(u))}return Object.defineProperty(r.prototype,"entities",{get:function(){var o,u,f,s,l;for(s={},l=this.children,u=0,f=l.length;u<f;u++)o=l[u],o.type===N.EntityDeclaration&&!o.pe&&(s[o.name]=o);return new w(s)}}),Object.defineProperty(r.prototype,"notations",{get:function(){var o,u,f,s,l;for(s={},l=this.children,u=0,f=l.length;u<f;u++)o=l[u],o.type===N.NotationDeclaration&&(s[o.name]=o);return new w(s)}}),Object.defineProperty(r.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(r.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(r.prototype,"internalSubset",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),r.prototype.element=function(i,o){var u;return u=new C(this,i,o),this.children.push(u),this},r.prototype.attList=function(i,o,u,f,s){var l;return l=new v(this,i,o,u,f,s),this.children.push(l),this},r.prototype.entity=function(i,o){var u;return u=new M(this,!1,i,o),this.children.push(u),this},r.prototype.pEntity=function(i,o){var u;return u=new M(this,!0,i,o),this.children.push(u),this},r.prototype.notation=function(i,o){var u;return u=new m(this,i,o),this.children.push(u),this},r.prototype.toString=function(i){return this.options.writer.docType(this,this.options.writer.filterOptions(i))},r.prototype.ele=function(i,o){return this.element(i,o)},r.prototype.att=function(i,o,u,f,s){return this.attList(i,o,u,f,s)},r.prototype.ent=function(i,o){return this.entity(i,o)},r.prototype.pent=function(i,o){return this.pEntity(i,o)},r.prototype.not=function(i,o){return this.notation(i,o)},r.prototype.up=function(){return this.root()||this.documentObject},r.prototype.isEqualNode=function(i){return r.__super__.isEqualNode.apply(this,arguments).isEqualNode(i)?i.name!==this.name||i.publicId!==this.publicId?!1:!(i.systemId!==this.systemId):!1},r}(b)}).call(void 0)},{"./NodeType":251,"./Utility":252,"./XMLDTDAttList":262,"./XMLDTDElement":263,"./XMLDTDEntity":264,"./XMLDTDNotation":265,"./XMLNamedNodeMap":272,"./XMLNode":273}],268:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m,y,w,b,p=function(c,r){for(var i in r)d.call(r,i)&&(c[i]=r[i]);function o(){this.constructor=c}return o.prototype=r.prototype,c.prototype=new o,c.__super__=r.prototype,c},d={}.hasOwnProperty;b=F("./Utility").isPlainObject,C=F("./XMLDOMImplementation"),v=F("./XMLDOMConfiguration"),m=F("./XMLNode"),N=F("./NodeType"),w=F("./XMLStringifier"),y=F("./XMLStringWriter"),Q.exports=M=function(n){p(c,n);function c(r){c.__super__.constructor.call(this,null),this.name="#document",this.type=N.Document,this.documentURI=null,this.domConfig=new v,r||(r={}),r.writer||(r.writer=new y),this.options=r,this.stringify=new w(r)}return Object.defineProperty(c.prototype,"implementation",{value:new C}),Object.defineProperty(c.prototype,"doctype",{get:function(){var i,o,u,f;for(f=this.children,o=0,u=f.length;o<u;o++)if(i=f[o],i.type===N.DocType)return i;return null}}),Object.defineProperty(c.prototype,"documentElement",{get:function(){return this.rootObject||null}}),Object.defineProperty(c.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(c.prototype,"strictErrorChecking",{get:function(){return!1}}),Object.defineProperty(c.prototype,"xmlEncoding",{get:function(){return this.children.length!==0&&this.children[0].type===N.Declaration?this.children[0].encoding:null}}),Object.defineProperty(c.prototype,"xmlStandalone",{get:function(){return this.children.length!==0&&this.children[0].type===N.Declaration?this.children[0].standalone==="yes":!1}}),Object.defineProperty(c.prototype,"xmlVersion",{get:function(){return this.children.length!==0&&this.children[0].type===N.Declaration?this.children[0].version:"1.0"}}),Object.defineProperty(c.prototype,"URL",{get:function(){return this.documentURI}}),Object.defineProperty(c.prototype,"origin",{get:function(){return null}}),Object.defineProperty(c.prototype,"compatMode",{get:function(){return null}}),Object.defineProperty(c.prototype,"characterSet",{get:function(){return null}}),Object.defineProperty(c.prototype,"contentType",{get:function(){return null}}),c.prototype.end=function(r){var i;return i={},r?b(r)&&(i=r,r=this.options.writer):r=this.options.writer,r.document(this,r.filterOptions(i))},c.prototype.toString=function(r){return this.options.writer.document(this,this.options.writer.filterOptions(r))},c.prototype.createElement=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createDocumentFragment=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createTextNode=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createComment=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createCDATASection=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createProcessingInstruction=function(r,i){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createAttribute=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createEntityReference=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.getElementsByTagName=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.importNode=function(r,i){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createElementNS=function(r,i){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createAttributeNS=function(r,i){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.getElementsByTagNameNS=function(r,i){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.getElementById=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.adoptNode=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.normalizeDocument=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.renameNode=function(r,i,o){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.getElementsByClassName=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createEvent=function(r){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createRange=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createNodeIterator=function(r,i,o){throw new Error("This DOM method is not implemented."+this.debugInfo())},c.prototype.createTreeWalker=function(r,i,o){throw new Error("This DOM method is not implemented."+this.debugInfo())},c}(m)}).call(void 0)},{"./NodeType":251,"./Utility":252,"./XMLDOMConfiguration":258,"./XMLDOMImplementation":260,"./XMLNode":273,"./XMLStringWriter":278,"./XMLStringifier":279}],269:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m,y,w,b,p,d,n,c,r,i,o,u,f,s,l,t,S,x,h,R,O={}.hasOwnProperty;R=F("./Utility"),x=R.isObject,S=R.isFunction,h=R.isPlainObject,t=R.getValue,N=F("./NodeType"),c=F("./XMLDocument"),i=F("./XMLElement"),M=F("./XMLCData"),m=F("./XMLComment"),u=F("./XMLRaw"),l=F("./XMLText"),o=F("./XMLProcessingInstruction"),d=F("./XMLDeclaration"),n=F("./XMLDocType"),y=F("./XMLDTDAttList"),b=F("./XMLDTDEntity"),w=F("./XMLDTDElement"),p=F("./XMLDTDNotation"),C=F("./XMLAttribute"),s=F("./XMLStringifier"),f=F("./XMLStringWriter"),v=F("./WriterState"),Q.exports=r=function(){function g(_,E,T){var L;this.name="?xml",this.type=N.Document,_||(_={}),L={},_.writer?h(_.writer)&&(L=_.writer,_.writer=new f):_.writer=new f,this.options=_,this.writer=_.writer,this.writerOptions=this.writer.filterOptions(L),this.stringify=new s(_),this.onDataCallback=E||function(){},this.onEndCallback=T||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}return g.prototype.createChildNode=function(_){var E,T,L,I,P,G,W,H;switch(_.type){case N.CData:this.cdata(_.value);break;case N.Comment:this.comment(_.value);break;case N.Element:L={},W=_.attribs;for(T in W){if(!O.call(W,T))continue;E=W[T],L[T]=E.value}this.node(_.name,L);break;case N.Dummy:this.dummy();break;case N.Raw:this.raw(_.value);break;case N.Text:this.text(_.value);break;case N.ProcessingInstruction:this.instruction(_.target,_.value);break;default:throw new Error("This XML node type is not supported in a JS object: "+_.constructor.name)}for(H=_.children,P=0,G=H.length;P<G;P++)I=H[P],this.createChildNode(I),I.type===N.Element&&this.up();return this},g.prototype.dummy=function(){return this},g.prototype.node=function(_,E,T){var L;if(_==null)throw new Error("Missing node name.");if(this.root&&this.currentLevel===-1)throw new Error("Document can only have one root node. "+this.debugInfo(_));return this.openCurrent(),_=t(_),E==null&&(E={}),E=t(E),x(E)||(L=[E,T],T=L[0],E=L[1]),this.currentNode=new i(this,_,E),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,T!=null&&this.text(T),this},g.prototype.element=function(_,E,T){var L,I,P,G,W,H;if(this.currentNode&&this.currentNode.type===N.DocType)this.dtdElement.apply(this,arguments);else if(Array.isArray(_)||x(_)||S(_))for(G=this.options.noValidation,this.options.noValidation=!0,H=new c(this.options).element("TEMP_ROOT"),H.element(_),this.options.noValidation=G,W=H.children,I=0,P=W.length;I<P;I++)L=W[I],this.createChildNode(L),L.type===N.Element&&this.up();else this.node(_,E,T);return this},g.prototype.attribute=function(_,E){var T,L;if(!this.currentNode||this.currentNode.children)throw new Error("att() can only be used immediately after an ele() call in callback mode. "+this.debugInfo(_));if(_!=null&&(_=t(_)),x(_))for(T in _){if(!O.call(_,T))continue;L=_[T],this.attribute(T,L)}else S(E)&&(E=E.apply()),this.options.keepNullAttributes&&E==null?this.currentNode.attribs[_]=new C(this,_,""):E!=null&&(this.currentNode.attribs[_]=new C(this,_,E));return this},g.prototype.text=function(_){var E;return this.openCurrent(),E=new l(this,_),this.onData(this.writer.text(E,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.cdata=function(_){var E;return this.openCurrent(),E=new M(this,_),this.onData(this.writer.cdata(E,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.comment=function(_){var E;return this.openCurrent(),E=new m(this,_),this.onData(this.writer.comment(E,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.raw=function(_){var E;return this.openCurrent(),E=new u(this,_),this.onData(this.writer.raw(E,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.instruction=function(_,E){var T,L,I,P,G;if(this.openCurrent(),_!=null&&(_=t(_)),E!=null&&(E=t(E)),Array.isArray(_))for(T=0,P=_.length;T<P;T++)L=_[T],this.instruction(L);else if(x(_))for(L in _){if(!O.call(_,L))continue;I=_[L],this.instruction(L,I)}else S(E)&&(E=E.apply()),G=new o(this,_,E),this.onData(this.writer.processingInstruction(G,this.writerOptions,this.currentLevel+1),this.currentLevel+1);return this},g.prototype.declaration=function(_,E,T){var L;if(this.openCurrent(),this.documentStarted)throw new Error("declaration() must be the first node.");return L=new d(this,_,E,T),this.onData(this.writer.declaration(L,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.doctype=function(_,E,T){if(this.openCurrent(),_==null)throw new Error("Missing root node name.");if(this.root)throw new Error("dtd() must come before the root node.");return this.currentNode=new n(this,E,T),this.currentNode.rootNodeName=_,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this},g.prototype.dtdElement=function(_,E){var T;return this.openCurrent(),T=new w(this,_,E),this.onData(this.writer.dtdElement(T,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.attList=function(_,E,T,L,I){var P;return this.openCurrent(),P=new y(this,_,E,T,L,I),this.onData(this.writer.dtdAttList(P,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.entity=function(_,E){var T;return this.openCurrent(),T=new b(this,!1,_,E),this.onData(this.writer.dtdEntity(T,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.pEntity=function(_,E){var T;return this.openCurrent(),T=new b(this,!0,_,E),this.onData(this.writer.dtdEntity(T,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.notation=function(_,E){var T;return this.openCurrent(),T=new p(this,_,E),this.onData(this.writer.dtdNotation(T,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},g.prototype.up=function(){if(this.currentLevel<0)throw new Error("The document node has no parent.");return this.currentNode?(this.currentNode.children?this.closeNode(this.currentNode):this.openNode(this.currentNode),this.currentNode=null):this.closeNode(this.openTags[this.currentLevel]),delete this.openTags[this.currentLevel],this.currentLevel--,this},g.prototype.end=function(){for(;this.currentLevel>=0;)this.up();return this.onEnd()},g.prototype.openCurrent=function(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)},g.prototype.openNode=function(_){var E,T,L,I;if(!_.isOpen){if(!this.root&&this.currentLevel===0&&_.type===N.Element&&(this.root=_),T="",_.type===N.Element){this.writerOptions.state=v.OpenTag,T=this.writer.indent(_,this.writerOptions,this.currentLevel)+"<"+_.name,I=_.attribs;for(L in I){if(!O.call(I,L))continue;E=I[L],T+=this.writer.attribute(E,this.writerOptions,this.currentLevel)}T+=(_.children?">":"/>")+this.writer.endline(_,this.writerOptions,this.currentLevel),this.writerOptions.state=v.InsideTag}else this.writerOptions.state=v.OpenTag,T=this.writer.indent(_,this.writerOptions,this.currentLevel)+"<!DOCTYPE "+_.rootNodeName,_.pubID&&_.sysID?T+=' PUBLIC "'+_.pubID+'" "'+_.sysID+'"':_.sysID&&(T+=' SYSTEM "'+_.sysID+'"'),_.children?(T+=" [",this.writerOptions.state=v.InsideTag):(this.writerOptions.state=v.CloseTag,T+=">"),T+=this.writer.endline(_,this.writerOptions,this.currentLevel);return this.onData(T,this.currentLevel),_.isOpen=!0}},g.prototype.closeNode=function(_){var E;if(!_.isClosed)return E="",this.writerOptions.state=v.CloseTag,_.type===N.Element?E=this.writer.indent(_,this.writerOptions,this.currentLevel)+"</"+_.name+">"+this.writer.endline(_,this.writerOptions,this.currentLevel):E=this.writer.indent(_,this.writerOptions,this.currentLevel)+"]>"+this.writer.endline(_,this.writerOptions,this.currentLevel),this.writerOptions.state=v.None,this.onData(E,this.currentLevel),_.isClosed=!0},g.prototype.onData=function(_,E){return this.documentStarted=!0,this.onDataCallback(_,E+1)},g.prototype.onEnd=function(){return this.documentCompleted=!0,this.onEndCallback()},g.prototype.debugInfo=function(_){return _==null?"":"node: <"+_+">"},g.prototype.ele=function(){return this.element.apply(this,arguments)},g.prototype.nod=function(_,E,T){return this.node(_,E,T)},g.prototype.txt=function(_){return this.text(_)},g.prototype.dat=function(_){return this.cdata(_)},g.prototype.com=function(_){return this.comment(_)},g.prototype.ins=function(_,E){return this.instruction(_,E)},g.prototype.dec=function(_,E,T){return this.declaration(_,E,T)},g.prototype.dtd=function(_,E,T){return this.doctype(_,E,T)},g.prototype.e=function(_,E,T){return this.element(_,E,T)},g.prototype.n=function(_,E,T){return this.node(_,E,T)},g.prototype.t=function(_){return this.text(_)},g.prototype.d=function(_){return this.cdata(_)},g.prototype.c=function(_){return this.comment(_)},g.prototype.r=function(_){return this.raw(_)},g.prototype.i=function(_,E){return this.instruction(_,E)},g.prototype.att=function(){return this.currentNode&&this.currentNode.type===N.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},g.prototype.a=function(){return this.currentNode&&this.currentNode.type===N.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},g.prototype.ent=function(_,E){return this.entity(_,E)},g.prototype.pent=function(_,E){return this.pEntity(_,E)},g.prototype.not=function(_,E){return this.notation(_,E)},g}()}).call(void 0)},{"./NodeType":251,"./Utility":252,"./WriterState":253,"./XMLAttribute":254,"./XMLCData":255,"./XMLComment":257,"./XMLDTDAttList":262,"./XMLDTDElement":263,"./XMLDTDEntity":264,"./XMLDTDNotation":265,"./XMLDeclaration":266,"./XMLDocType":267,"./XMLDocument":268,"./XMLElement":271,"./XMLProcessingInstruction":275,"./XMLRaw":276,"./XMLStringWriter":278,"./XMLStringifier":279,"./XMLText":280}],270:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w=function(d,n){for(var c in n)b.call(n,c)&&(d[c]=n[c]);function r(){this.constructor=d}return r.prototype=n.prototype,d.prototype=new r,d.__super__=n.prototype,d},b={}.hasOwnProperty;y=F("./XMLNode"),M=F("./NodeType"),Q.exports=m=function(p){w(d,p);function d(n){d.__super__.constructor.call(this,n),this.type=M.Dummy}return d.prototype.clone=function(){return(0,v.default)(this)},d.prototype.toString=function(n){return""},d}(y)}).call(void 0)},{"./NodeType":251,"./XMLNode":273,"babel-runtime/core-js/object/create":55}],271:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w,b,p,d,n,c,r=function(u,f){for(var s in f)i.call(f,s)&&(u[s]=f[s]);function l(){this.constructor=u}return l.prototype=f.prototype,u.prototype=new l,u.__super__=f.prototype,u},i={}.hasOwnProperty;c=F("./Utility"),n=c.isObject,d=c.isFunction,p=c.getValue,b=F("./XMLNode"),M=F("./NodeType"),m=F("./XMLAttribute"),w=F("./XMLNamedNodeMap"),Q.exports=y=function(o){r(u,o);function u(f,s,l){var t,S,x,h;if(u.__super__.constructor.call(this,f),s==null)throw new Error("Missing element name. "+this.debugInfo());if(this.name=this.stringify.name(s),this.type=M.Element,this.attribs={},this.schemaTypeInfo=null,l!=null&&this.attribute(l),f.type===M.Document&&(this.isRoot=!0,this.documentObject=f,f.rootObject=this,f.children)){for(h=f.children,S=0,x=h.length;S<x;S++)if(t=h[S],t.type===M.DocType){t.name=this.name;break}}}return Object.defineProperty(u.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(u.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(u.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(u.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(u.prototype,"id",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(u.prototype,"className",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(u.prototype,"classList",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(u.prototype,"attributes",{get:function(){return(!this.attributeMap||!this.attributeMap.nodes)&&(this.attributeMap=new w(this.attribs)),this.attributeMap}}),u.prototype.clone=function(){var f,s,l,t;l=(0,v.default)(this),l.isRoot&&(l.documentObject=null),l.attribs={},t=this.attribs;for(s in t){if(!i.call(t,s))continue;f=t[s],l.attribs[s]=f.clone()}return l.children=[],this.children.forEach(function(S){var x;return x=S.clone(),x.parent=l,l.children.push(x)}),l},u.prototype.attribute=function(f,s){var l,t;if(f!=null&&(f=p(f)),n(f))for(l in f){if(!i.call(f,l))continue;t=f[l],this.attribute(l,t)}else d(s)&&(s=s.apply()),this.options.keepNullAttributes&&s==null?this.attribs[f]=new m(this,f,""):s!=null&&(this.attribs[f]=new m(this,f,s));return this},u.prototype.removeAttribute=function(f){var s,l,t;if(f==null)throw new Error("Missing attribute name. "+this.debugInfo());if(f=p(f),Array.isArray(f))for(l=0,t=f.length;l<t;l++)s=f[l],delete this.attribs[s];else delete this.attribs[f];return this},u.prototype.toString=function(f){return this.options.writer.element(this,this.options.writer.filterOptions(f))},u.prototype.att=function(f,s){return this.attribute(f,s)},u.prototype.a=function(f,s){return this.attribute(f,s)},u.prototype.getAttribute=function(f){return this.attribs.hasOwnProperty(f)?this.attribs[f].value:null},u.prototype.setAttribute=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getAttributeNode=function(f){return this.attribs.hasOwnProperty(f)?this.attribs[f]:null},u.prototype.setAttributeNode=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.removeAttributeNode=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getElementsByTagName=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getAttributeNS=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.setAttributeNS=function(f,s,l){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.removeAttributeNS=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getAttributeNodeNS=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.setAttributeNodeNS=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getElementsByTagNameNS=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.hasAttribute=function(f){return this.attribs.hasOwnProperty(f)},u.prototype.hasAttributeNS=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.setIdAttribute=function(f,s){return this.attribs.hasOwnProperty(f)?this.attribs[f].isId:s},u.prototype.setIdAttributeNS=function(f,s,l){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.setIdAttributeNode=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getElementsByTagName=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getElementsByTagNameNS=function(f,s){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.getElementsByClassName=function(f){throw new Error("This DOM method is not implemented."+this.debugInfo())},u.prototype.isEqualNode=function(f){var s,l,t;if(!u.__super__.isEqualNode.apply(this,arguments).isEqualNode(f))return!1;if(f.namespaceURI!==this.namespaceURI)return!1;if(f.prefix!==this.prefix)return!1;if(f.localName!==this.localName)return!1;if(f.attribs.length!==this.attribs.length)return!1;for(s=l=0,t=this.attribs.length-1;0<=t?l<=t:l>=t;s=0<=t?++l:--l)if(!this.attribs[s].isEqualNode(f.attribs[s]))return!1;return!0},u}(b)}).call(void 0)},{"./NodeType":251,"./Utility":252,"./XMLAttribute":254,"./XMLNamedNodeMap":272,"./XMLNode":273,"babel-runtime/core-js/object/create":55}],272:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/keys"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M;Q.exports=M=function(){function m(y){this.nodes=y}return Object.defineProperty(m.prototype,"length",{get:function(){return(0,v.default)(this.nodes).length||0}}),m.prototype.clone=function(){return this.nodes=null},m.prototype.getNamedItem=function(y){return this.nodes[y]},m.prototype.setNamedItem=function(y){var w;return w=this.nodes[y.nodeName],this.nodes[y.nodeName]=y,w||null},m.prototype.removeNamedItem=function(y){var w;return w=this.nodes[y],delete this.nodes[y],w||null},m.prototype.item=function(y){return this.nodes[(0,v.default)(this.nodes)[y]]||null},m.prototype.getNamedItemNS=function(y,w){throw new Error("This DOM method is not implemented.")},m.prototype.setNamedItemNS=function(y){throw new Error("This DOM method is not implemented.")},m.prototype.removeNamedItemNS=function(y,w){throw new Error("This DOM method is not implemented.")},m}()}).call(void 0)},{"babel-runtime/core-js/object/keys":60}],273:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m,y,w,b,p,d,n,c,r,i,o,u,f,s,l,t={}.hasOwnProperty;l=F("./Utility"),s=l.isObject,f=l.isFunction,u=l.isEmpty,o=l.getValue,b=null,C=null,M=null,m=null,y=null,r=null,i=null,c=null,w=null,v=null,n=null,p=null,N=null,Q.exports=d=function(){function S(x){this.parent=x,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.value=null,this.children=[],this.baseURI=null,b||(b=F("./XMLElement"),C=F("./XMLCData"),M=F("./XMLComment"),m=F("./XMLDeclaration"),y=F("./XMLDocType"),r=F("./XMLRaw"),i=F("./XMLText"),c=F("./XMLProcessingInstruction"),w=F("./XMLDummy"),v=F("./NodeType"),n=F("./XMLNodeList"),p=F("./XMLNamedNodeMap"),N=F("./DocumentPosition"))}return Object.defineProperty(S.prototype,"nodeName",{get:function(){return this.name}}),Object.defineProperty(S.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(S.prototype,"nodeValue",{get:function(){return this.value}}),Object.defineProperty(S.prototype,"parentNode",{get:function(){return this.parent}}),Object.defineProperty(S.prototype,"childNodes",{get:function(){return(!this.childNodeList||!this.childNodeList.nodes)&&(this.childNodeList=new n(this.children)),this.childNodeList}}),Object.defineProperty(S.prototype,"firstChild",{get:function(){return this.children[0]||null}}),Object.defineProperty(S.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null}}),Object.defineProperty(S.prototype,"previousSibling",{get:function(){var h;return h=this.parent.children.indexOf(this),this.parent.children[h-1]||null}}),Object.defineProperty(S.prototype,"nextSibling",{get:function(){var h;return h=this.parent.children.indexOf(this),this.parent.children[h+1]||null}}),Object.defineProperty(S.prototype,"ownerDocument",{get:function(){return this.document()||null}}),Object.defineProperty(S.prototype,"textContent",{get:function(){var h,R,O,g,_;if(this.nodeType===v.Element||this.nodeType===v.DocumentFragment){for(_="",g=this.children,R=0,O=g.length;R<O;R++)h=g[R],h.textContent&&(_+=h.textContent);return _}else return null},set:function(h){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),S.prototype.setParent=function(x){var h,R,O,g,_;for(this.parent=x,x&&(this.options=x.options,this.stringify=x.stringify),g=this.children,_=[],R=0,O=g.length;R<O;R++)h=g[R],_.push(h.setParent(this));return _},S.prototype.element=function(x,h,R){var O,g,_,E,T,L,I,P,G,W,H;if(L=null,h===null&&R==null&&(G=[{},null],h=G[0],R=G[1]),h==null&&(h={}),h=o(h),s(h)||(W=[h,R],R=W[0],h=W[1]),x!=null&&(x=o(x)),Array.isArray(x))for(_=0,I=x.length;_<I;_++)g=x[_],L=this.element(g);else if(f(x))L=this.element(x.apply());else if(s(x))for(T in x){if(!t.call(x,T))continue;if(H=x[T],f(H)&&(H=H.apply()),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&T.indexOf(this.stringify.convertAttKey)===0)L=this.attribute(T.substr(this.stringify.convertAttKey.length),H);else if(!this.options.separateArrayItems&&Array.isArray(H)&&u(H))L=this.dummy();else if(s(H)&&u(H))L=this.element(T);else if(!this.options.keepNullNodes&&H==null)L=this.dummy();else if(!this.options.separateArrayItems&&Array.isArray(H))for(E=0,P=H.length;E<P;E++)g=H[E],O={},O[T]=g,L=this.element(O);else s(H)?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&T.indexOf(this.stringify.convertTextKey)===0?L=this.element(H):(L=this.element(T),L.element(H)):L=this.element(T,H)}else!this.options.keepNullNodes&&R===null?L=this.dummy():!this.options.ignoreDecorators&&this.stringify.convertTextKey&&x.indexOf(this.stringify.convertTextKey)===0?L=this.text(R):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&x.indexOf(this.stringify.convertCDataKey)===0?L=this.cdata(R):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&x.indexOf(this.stringify.convertCommentKey)===0?L=this.comment(R):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&x.indexOf(this.stringify.convertRawKey)===0?L=this.raw(R):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&x.indexOf(this.stringify.convertPIKey)===0?L=this.instruction(x.substr(this.stringify.convertPIKey.length),R):L=this.node(x,h,R);if(L==null)throw new Error("Could not create any elements with: "+x+". "+this.debugInfo());return L},S.prototype.insertBefore=function(x,h,R){var O,g,_,E,T;if(x!=null?x.type:void 0)return _=x,E=h,_.setParent(this),E?(g=children.indexOf(E),T=children.splice(g),children.push(_),Array.prototype.push.apply(children,T)):children.push(_),_;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(x));return g=this.parent.children.indexOf(this),T=this.parent.children.splice(g),O=this.parent.element(x,h,R),Array.prototype.push.apply(this.parent.children,T),O},S.prototype.insertAfter=function(x,h,R){var O,g,_;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(x));return g=this.parent.children.indexOf(this),_=this.parent.children.splice(g+1),O=this.parent.element(x,h,R),Array.prototype.push.apply(this.parent.children,_),O},S.prototype.remove=function(){var x,h;if(this.isRoot)throw new Error("Cannot remove the root element. "+this.debugInfo());return x=this.parent.children.indexOf(this),[].splice.apply(this.parent.children,[x,x-x+1].concat(h=[])),this.parent},S.prototype.node=function(x,h,R){var O,g;return x!=null&&(x=o(x)),h||(h={}),h=o(h),s(h)||(g=[h,R],R=g[0],h=g[1]),O=new b(this,x,h),R!=null&&O.text(R),this.children.push(O),O},S.prototype.text=function(x){var h;return s(x)&&this.element(x),h=new i(this,x),this.children.push(h),this},S.prototype.cdata=function(x){var h;return h=new C(this,x),this.children.push(h),this},S.prototype.comment=function(x){var h;return h=new M(this,x),this.children.push(h),this},S.prototype.commentBefore=function(x){var h,R,O;return R=this.parent.children.indexOf(this),O=this.parent.children.splice(R),h=this.parent.comment(x),Array.prototype.push.apply(this.parent.children,O),this},S.prototype.commentAfter=function(x){var h,R,O;return R=this.parent.children.indexOf(this),O=this.parent.children.splice(R+1),h=this.parent.comment(x),Array.prototype.push.apply(this.parent.children,O),this},S.prototype.raw=function(x){var h;return h=new r(this,x),this.children.push(h),this},S.prototype.dummy=function(){var x;return x=new w(this),x},S.prototype.instruction=function(x,h){var R,O,g,_,E;if(x!=null&&(x=o(x)),h!=null&&(h=o(h)),Array.isArray(x))for(_=0,E=x.length;_<E;_++)R=x[_],this.instruction(R);else if(s(x))for(R in x){if(!t.call(x,R))continue;O=x[R],this.instruction(R,O)}else f(h)&&(h=h.apply()),g=new c(this,x,h),this.children.push(g);return this},S.prototype.instructionBefore=function(x,h){var R,O,g;return O=this.parent.children.indexOf(this),g=this.parent.children.splice(O),R=this.parent.instruction(x,h),Array.prototype.push.apply(this.parent.children,g),this},S.prototype.instructionAfter=function(x,h){var R,O,g;return O=this.parent.children.indexOf(this),g=this.parent.children.splice(O+1),R=this.parent.instruction(x,h),Array.prototype.push.apply(this.parent.children,g),this},S.prototype.declaration=function(x,h,R){var O,g;return O=this.document(),g=new m(O,x,h,R),O.children.length===0?O.children.unshift(g):O.children[0].type===v.Declaration?O.children[0]=g:O.children.unshift(g),O.root()||O},S.prototype.dtd=function(x,h){var R,O,g,_,E,T,L,I,P,G;for(O=this.document(),g=new y(O,x,h),P=O.children,_=E=0,L=P.length;E<L;_=++E)if(R=P[_],R.type===v.DocType)return O.children[_]=g,g;for(G=O.children,_=T=0,I=G.length;T<I;_=++T)if(R=G[_],R.isRoot)return O.children.splice(_,0,g),g;return O.children.push(g),g},S.prototype.up=function(){if(this.isRoot)throw new Error("The root node has no parent. Use doc() if you need to get the document object.");return this.parent},S.prototype.root=function(){var x;for(x=this;x;){if(x.type===v.Document)return x.rootObject;if(x.isRoot)return x;x=x.parent}},S.prototype.document=function(){var x;for(x=this;x;){if(x.type===v.Document)return x;x=x.parent}},S.prototype.end=function(x){return this.document().end(x)},S.prototype.prev=function(){var x;if(x=this.parent.children.indexOf(this),x<1)throw new Error("Already at the first node. "+this.debugInfo());return this.parent.children[x-1]},S.prototype.next=function(){var x;if(x=this.parent.children.indexOf(this),x===-1||x===this.parent.children.length-1)throw new Error("Already at the last node. "+this.debugInfo());return this.parent.children[x+1]},S.prototype.importDocument=function(x){var h;return h=x.root().clone(),h.parent=this,h.isRoot=!1,this.children.push(h),this},S.prototype.debugInfo=function(x){var h,R;return x=x||this.name,x==null&&!((h=this.parent)!=null?h.name:void 0)?"":x==null?"parent: <"+this.parent.name+">":((R=this.parent)!=null?R.name:void 0)?"node: <"+x+">, parent: <"+this.parent.name+">":"node: <"+x+">"},S.prototype.ele=function(x,h,R){return this.element(x,h,R)},S.prototype.nod=function(x,h,R){return this.node(x,h,R)},S.prototype.txt=function(x){return this.text(x)},S.prototype.dat=function(x){return this.cdata(x)},S.prototype.com=function(x){return this.comment(x)},S.prototype.ins=function(x,h){return this.instruction(x,h)},S.prototype.doc=function(){return this.document()},S.prototype.dec=function(x,h,R){return this.declaration(x,h,R)},S.prototype.e=function(x,h,R){return this.element(x,h,R)},S.prototype.n=function(x,h,R){return this.node(x,h,R)},S.prototype.t=function(x){return this.text(x)},S.prototype.d=function(x){return this.cdata(x)},S.prototype.c=function(x){return this.comment(x)},S.prototype.r=function(x){return this.raw(x)},S.prototype.i=function(x,h){return this.instruction(x,h)},S.prototype.u=function(){return this.up()},S.prototype.importXMLBuilder=function(x){return this.importDocument(x)},S.prototype.replaceChild=function(x,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.removeChild=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.appendChild=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.hasChildNodes=function(){return this.children.length!==0},S.prototype.cloneNode=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.normalize=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.isSupported=function(x,h){return!0},S.prototype.hasAttributes=function(){return this.attribs.length!==0},S.prototype.compareDocumentPosition=function(x){var h,R;return h=this,h===x?0:this.document()!==x.document()?(R=N.Disconnected|N.ImplementationSpecific,Math.random()<.5?R|=N.Preceding:R|=N.Following,R):h.isAncestor(x)?N.Contains|N.Preceding:h.isDescendant(x)?N.Contains|N.Following:h.isPreceding(x)?N.Preceding:N.Following},S.prototype.isSameNode=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.lookupPrefix=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.isDefaultNamespace=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.lookupNamespaceURI=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.isEqualNode=function(x){var h,R,O;if(x.nodeType!==this.nodeType)return!1;if(x.children.length!==this.children.length)return!1;for(h=R=0,O=this.children.length-1;0<=O?R<=O:R>=O;h=0<=O?++R:--R)if(!this.children[h].isEqualNode(x.children[h]))return!1;return!0},S.prototype.getFeature=function(x,h){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.setUserData=function(x,h,R){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.getUserData=function(x){throw new Error("This DOM method is not implemented."+this.debugInfo())},S.prototype.contains=function(x){return x?x===this||this.isDescendant(x):!1},S.prototype.isDescendant=function(x){var h,R,O,g,_;for(_=this.children,O=0,g=_.length;O<g;O++){if(h=_[O],x===h)return!0;if(R=h.isDescendant(x),R)return!0}return!1},S.prototype.isAncestor=function(x){return x.isDescendant(this)},S.prototype.isPreceding=function(x){var h,R;return h=this.treePosition(x),R=this.treePosition(this),h===-1||R===-1?!1:h<R},S.prototype.isFollowing=function(x){var h,R;return h=this.treePosition(x),R=this.treePosition(this),h===-1||R===-1?!1:h>R},S.prototype.treePosition=function(x){var h,R;return R=0,h=!1,this.foreachTreeNode(this.document(),function(O){if(R++,!h&&O===x)return h=!0}),h?R:-1},S.prototype.foreachTreeNode=function(x,h){var R,O,g,_,E;for(x||(x=this.document()),_=x.children,O=0,g=_.length;O<g;O++){if(R=_[O],E=h(R))return E;if(E=this.foreachTreeNode(R,h),E)return E}},S}()}).call(void 0)},{"./DocumentPosition":250,"./NodeType":251,"./Utility":252,"./XMLCData":255,"./XMLComment":257,"./XMLDeclaration":266,"./XMLDocType":267,"./XMLDummy":270,"./XMLElement":271,"./XMLNamedNodeMap":272,"./XMLNodeList":274,"./XMLProcessingInstruction":275,"./XMLRaw":276,"./XMLText":280}],274:[function(F,Q,j){"use strict";(function(){var N;Q.exports=N=function(){function v(C){this.nodes=C}return Object.defineProperty(v.prototype,"length",{get:function(){return this.nodes.length||0}}),v.prototype.clone=function(){return this.nodes=null},v.prototype.item=function(C){return this.nodes[C]||null},v}()}).call(void 0)},{}],275:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w=function(d,n){for(var c in n)b.call(n,c)&&(d[c]=n[c]);function r(){this.constructor=d}return r.prototype=n.prototype,d.prototype=new r,d.__super__=n.prototype,d},b={}.hasOwnProperty;M=F("./NodeType"),m=F("./XMLCharacterData"),Q.exports=y=function(p){w(d,p);function d(n,c,r){if(d.__super__.constructor.call(this,n),c==null)throw new Error("Missing instruction target. "+this.debugInfo());this.type=M.ProcessingInstruction,this.target=this.stringify.insTarget(c),this.name=this.target,r&&(this.value=this.stringify.insValue(r))}return d.prototype.clone=function(){return(0,v.default)(this)},d.prototype.toString=function(n){return this.options.writer.processingInstruction(this,this.options.writer.filterOptions(n))},d.prototype.isEqualNode=function(n){return d.__super__.isEqualNode.apply(this,arguments).isEqualNode(n)?!(n.target!==this.target):!1},d}(m)}).call(void 0)},{"./NodeType":251,"./XMLCharacterData":256,"babel-runtime/core-js/object/create":55}],276:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w=function(d,n){for(var c in n)b.call(n,c)&&(d[c]=n[c]);function r(){this.constructor=d}return r.prototype=n.prototype,d.prototype=new r,d.__super__=n.prototype,d},b={}.hasOwnProperty;M=F("./NodeType"),m=F("./XMLNode"),Q.exports=y=function(p){w(d,p);function d(n,c){if(d.__super__.constructor.call(this,n),c==null)throw new Error("Missing raw text. "+this.debugInfo());this.type=M.Raw,this.value=this.stringify.raw(c)}return d.prototype.clone=function(){return(0,v.default)(this)},d.prototype.toString=function(n){return this.options.writer.raw(this,this.options.writer.filterOptions(n))},d}(m)}).call(void 0)},{"./NodeType":251,"./XMLNode":273,"babel-runtime/core-js/object/create":55}],277:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m=function(b,p){for(var d in p)y.call(p,d)&&(b[d]=p[d]);function n(){this.constructor=b}return n.prototype=p.prototype,b.prototype=new n,b.__super__=p.prototype,b},y={}.hasOwnProperty;N=F("./NodeType"),M=F("./XMLWriterBase"),v=F("./WriterState"),Q.exports=C=function(w){m(b,w);function b(p,d){this.stream=p,b.__super__.constructor.call(this,d)}return b.prototype.endline=function(p,d,n){return p.isLastRootNode&&d.state===v.CloseTag?"":b.__super__.endline.call(this,p,d,n)},b.prototype.document=function(p,d){var n,c,r,i,o,u,f,s,l;for(f=p.children,c=r=0,o=f.length;r<o;c=++r)n=f[c],n.isLastRootNode=c===p.children.length-1;for(d=this.filterOptions(d),s=p.children,l=[],i=0,u=s.length;i<u;i++)n=s[i],l.push(this.writeChildNode(n,d,0));return l},b.prototype.attribute=function(p,d,n){return this.stream.write(b.__super__.attribute.call(this,p,d,n))},b.prototype.cdata=function(p,d,n){return this.stream.write(b.__super__.cdata.call(this,p,d,n))},b.prototype.comment=function(p,d,n){return this.stream.write(b.__super__.comment.call(this,p,d,n))},b.prototype.declaration=function(p,d,n){return this.stream.write(b.__super__.declaration.call(this,p,d,n))},b.prototype.docType=function(p,d,n){var c,r,i,o;if(n||(n=0),this.openNode(p,d,n),d.state=v.OpenTag,this.stream.write(this.indent(p,d,n)),this.stream.write("<!DOCTYPE "+p.root().name),p.pubID&&p.sysID?this.stream.write(' PUBLIC "'+p.pubID+'" "'+p.sysID+'"'):p.sysID&&this.stream.write(' SYSTEM "'+p.sysID+'"'),p.children.length>0){for(this.stream.write(" ["),this.stream.write(this.endline(p,d,n)),d.state=v.InsideTag,o=p.children,r=0,i=o.length;r<i;r++)c=o[r],this.writeChildNode(c,d,n+1);d.state=v.CloseTag,this.stream.write("]")}return d.state=v.CloseTag,this.stream.write(d.spaceBeforeSlash+">"),this.stream.write(this.endline(p,d,n)),d.state=v.None,this.closeNode(p,d,n)},b.prototype.element=function(p,d,n){var c,r,i,o,u,f,s,l,t,S;n||(n=0),this.openNode(p,d,n),d.state=v.OpenTag,this.stream.write(this.indent(p,d,n)+"<"+p.name),t=p.attribs;for(s in t){if(!y.call(t,s))continue;c=t[s],this.attribute(c,d,n)}if(i=p.children.length,o=i===0?null:p.children[0],i===0||p.children.every(function(x){return(x.type===N.Text||x.type===N.Raw)&&x.value===""}))d.allowEmpty?(this.stream.write(">"),d.state=v.CloseTag,this.stream.write("</"+p.name+">")):(d.state=v.CloseTag,this.stream.write(d.spaceBeforeSlash+"/>"));else if(d.pretty&&i===1&&(o.type===N.Text||o.type===N.Raw)&&o.value!=null)this.stream.write(">"),d.state=v.InsideTag,d.suppressPrettyCount++,l=!0,this.writeChildNode(o,d,n+1),d.suppressPrettyCount--,l=!1,d.state=v.CloseTag,this.stream.write("</"+p.name+">");else{for(this.stream.write(">"+this.endline(p,d,n)),d.state=v.InsideTag,S=p.children,u=0,f=S.length;u<f;u++)r=S[u],this.writeChildNode(r,d,n+1);d.state=v.CloseTag,this.stream.write(this.indent(p,d,n)+"</"+p.name+">")}return this.stream.write(this.endline(p,d,n)),d.state=v.None,this.closeNode(p,d,n)},b.prototype.processingInstruction=function(p,d,n){return this.stream.write(b.__super__.processingInstruction.call(this,p,d,n))},b.prototype.raw=function(p,d,n){return this.stream.write(b.__super__.raw.call(this,p,d,n))},b.prototype.text=function(p,d,n){return this.stream.write(b.__super__.text.call(this,p,d,n))},b.prototype.dtdAttList=function(p,d,n){return this.stream.write(b.__super__.dtdAttList.call(this,p,d,n))},b.prototype.dtdElement=function(p,d,n){return this.stream.write(b.__super__.dtdElement.call(this,p,d,n))},b.prototype.dtdEntity=function(p,d,n){return this.stream.write(b.__super__.dtdEntity.call(this,p,d,n))},b.prototype.dtdNotation=function(p,d,n){return this.stream.write(b.__super__.dtdNotation.call(this,p,d,n))},b}(M)}).call(void 0)},{"./NodeType":251,"./WriterState":253,"./XMLWriterBase":281}],278:[function(F,Q,j){"use strict";(function(){var N,v,C=function(y,w){for(var b in w)M.call(w,b)&&(y[b]=w[b]);function p(){this.constructor=y}return p.prototype=w.prototype,y.prototype=new p,y.__super__=w.prototype,y},M={}.hasOwnProperty;v=F("./XMLWriterBase"),Q.exports=N=function(m){C(y,m);function y(w){y.__super__.constructor.call(this,w)}return y.prototype.document=function(w,b){var p,d,n,c,r;for(b=this.filterOptions(b),c="",r=w.children,d=0,n=r.length;d<n;d++)p=r[d],c+=this.writeChildNode(p,b,0);return b.pretty&&c.slice(-b.newline.length)===b.newline&&(c=c.slice(0,-b.newline.length)),c},y}(v)}).call(void 0)},{"./XMLWriterBase":281}],279:[function(F,Q,j){"use strict";(function(){var N,v=function(m,y){return function(){return m.apply(y,arguments)}},C={}.hasOwnProperty;Q.exports=N=function(){function M(m){this.assertLegalName=v(this.assertLegalName,this),this.assertLegalChar=v(this.assertLegalChar,this);var y,w,b;m||(m={}),this.options=m,this.options.version||(this.options.version="1.0"),w=m.stringify||{};for(y in w){if(!C.call(w,y))continue;b=w[y],this[y]=b}}return M.prototype.name=function(m){return this.options.noValidation?m:this.assertLegalName(""+m||"")},M.prototype.text=function(m){return this.options.noValidation?m:this.assertLegalChar(this.textEscape(""+m||""))},M.prototype.cdata=function(m){return this.options.noValidation?m:(m=""+m||"",m=m.replace("]]>","]]]]><![CDATA[>"),this.assertLegalChar(m))},M.prototype.comment=function(m){if(this.options.noValidation)return m;if(m=""+m||"",m.match(/--/))throw new Error("Comment text cannot contain double-hypen: "+m);return this.assertLegalChar(m)},M.prototype.raw=function(m){return this.options.noValidation?m:""+m||""},M.prototype.attValue=function(m){return this.options.noValidation?m:this.assertLegalChar(this.attEscape(m=""+m||""))},M.prototype.insTarget=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.insValue=function(m){if(this.options.noValidation)return m;if(m=""+m||"",m.match(/\?>/))throw new Error("Invalid processing instruction value: "+m);return this.assertLegalChar(m)},M.prototype.xmlVersion=function(m){if(this.options.noValidation)return m;if(m=""+m||"",!m.match(/1\.[0-9]+/))throw new Error("Invalid version number: "+m);return m},M.prototype.xmlEncoding=function(m){if(this.options.noValidation)return m;if(m=""+m||"",!m.match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw new Error("Invalid encoding: "+m);return this.assertLegalChar(m)},M.prototype.xmlStandalone=function(m){return this.options.noValidation?m:m?"yes":"no"},M.prototype.dtdPubID=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.dtdSysID=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.dtdElementValue=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.dtdAttType=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.dtdAttDefault=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.dtdEntityValue=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.dtdNData=function(m){return this.options.noValidation?m:this.assertLegalChar(""+m||"")},M.prototype.convertAttKey="@",M.prototype.convertPIKey="?",M.prototype.convertTextKey="#text",M.prototype.convertCDataKey="#cdata",M.prototype.convertCommentKey="#comment",M.prototype.convertRawKey="#raw",M.prototype.assertLegalChar=function(m){var y,w;if(this.options.noValidation)return m;if(y="",this.options.version==="1.0"){if(y=/[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,w=m.match(y))throw new Error("Invalid character in string: "+m+" at index "+w.index)}else if(this.options.version==="1.1"&&(y=/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,w=m.match(y)))throw new Error("Invalid character in string: "+m+" at index "+w.index);return m},M.prototype.assertLegalName=function(m){var y;if(this.options.noValidation)return m;if(this.assertLegalChar(m),y=/^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/,!m.match(y))throw new Error("Invalid character in name");return m},M.prototype.textEscape=function(m){var y;return this.options.noValidation?m:(y=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,m.replace(y,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\r/g,"&#xD;"))},M.prototype.attEscape=function(m){var y;return this.options.noValidation?m:(y=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,m.replace(y,"&amp;").replace(/</g,"&lt;").replace(/"/g,"&quot;").replace(/\t/g,"&#x9;").replace(/\n/g,"&#xA;").replace(/\r/g,"&#xD;"))},M}()}).call(void 0)},{}],280:[function(F,Q,j){"use strict";var N=F("babel-runtime/core-js/object/create"),v=C(N);function C(M){return M&&M.__esModule?M:{default:M}}(function(){var M,m,y,w=function(d,n){for(var c in n)b.call(n,c)&&(d[c]=n[c]);function r(){this.constructor=d}return r.prototype=n.prototype,d.prototype=new r,d.__super__=n.prototype,d},b={}.hasOwnProperty;M=F("./NodeType"),m=F("./XMLCharacterData"),Q.exports=y=function(p){w(d,p);function d(n,c){if(d.__super__.constructor.call(this,n),c==null)throw new Error("Missing element text. "+this.debugInfo());this.name="#text",this.type=M.Text,this.value=this.stringify.text(c)}return Object.defineProperty(d.prototype,"isElementContentWhitespace",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(d.prototype,"wholeText",{get:function(){var c,r,i;for(i="",r=this.previousSibling;r;)i=r.data+i,r=r.previousSibling;for(i+=this.data,c=this.nextSibling;c;)i=i+c.data,c=c.nextSibling;return i}}),d.prototype.clone=function(){return(0,v.default)(this)},d.prototype.toString=function(n){return this.options.writer.text(this,this.options.writer.filterOptions(n))},d.prototype.splitText=function(n){throw new Error("This DOM method is not implemented."+this.debugInfo())},d.prototype.replaceWholeText=function(n){throw new Error("This DOM method is not implemented."+this.debugInfo())},d}(m)}).call(void 0)},{"./NodeType":251,"./XMLCharacterData":256,"babel-runtime/core-js/object/create":55}],281:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m,y,w,b,p,d,n,c,r,i,o,u,f,s={}.hasOwnProperty;f=F("./Utility").assign,N=F("./NodeType"),p=F("./XMLDeclaration"),d=F("./XMLDocType"),C=F("./XMLCData"),M=F("./XMLComment"),c=F("./XMLElement"),i=F("./XMLRaw"),o=F("./XMLText"),r=F("./XMLProcessingInstruction"),n=F("./XMLDummy"),m=F("./XMLDTDAttList"),y=F("./XMLDTDElement"),w=F("./XMLDTDEntity"),b=F("./XMLDTDNotation"),v=F("./WriterState"),Q.exports=u=function(){function l(t){var S,x,h;t||(t={}),this.options=t,x=t.writer||{};for(S in x){if(!s.call(x,S))continue;h=x[S],this["_"+S]=this[S],this[S]=h}}return l.prototype.filterOptions=function(t){var S,x,h,R,O,g,_,E;return t||(t={}),t=f({},this.options,t),S={writer:this},S.pretty=t.pretty||!1,S.allowEmpty=t.allowEmpty||!1,S.indent=(x=t.indent)!=null?x:" ",S.newline=(h=t.newline)!=null?h:`
`,S.offset=(R=t.offset)!=null?R:0,S.dontPrettyTextNodes=(O=(g=t.dontPrettyTextNodes)!=null?g:t.dontprettytextnodes)!=null?O:0,S.spaceBeforeSlash=(_=(E=t.spaceBeforeSlash)!=null?E:t.spacebeforeslash)!=null?_:"",S.spaceBeforeSlash===!0&&(S.spaceBeforeSlash=" "),S.suppressPrettyCount=0,S.user={},S.state=v.None,S},l.prototype.indent=function(t,S,x){var h;return!S.pretty||S.suppressPrettyCount?"":S.pretty&&(h=(x||0)+S.offset+1,h>0)?new Array(h).join(S.indent):""},l.prototype.endline=function(t,S,x){return!S.pretty||S.suppressPrettyCount?"":S.newline},l.prototype.attribute=function(t,S,x){var h;return this.openAttribute(t,S,x),h=" "+t.name+'="'+t.value+'"',this.closeAttribute(t,S,x),h},l.prototype.cdata=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<![CDATA[",S.state=v.InsideTag,h+=t.value,S.state=v.CloseTag,h+="]]>"+this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.comment=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<!-- ",S.state=v.InsideTag,h+=t.value,S.state=v.CloseTag,h+=" -->"+this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.declaration=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<?xml",S.state=v.InsideTag,h+=' version="'+t.version+'"',t.encoding!=null&&(h+=' encoding="'+t.encoding+'"'),t.standalone!=null&&(h+=' standalone="'+t.standalone+'"'),S.state=v.CloseTag,h+=S.spaceBeforeSlash+"?>",h+=this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.docType=function(t,S,x){var h,R,O,g,_;if(x||(x=0),this.openNode(t,S,x),S.state=v.OpenTag,g=this.indent(t,S,x),g+="<!DOCTYPE "+t.root().name,t.pubID&&t.sysID?g+=' PUBLIC "'+t.pubID+'" "'+t.sysID+'"':t.sysID&&(g+=' SYSTEM "'+t.sysID+'"'),t.children.length>0){for(g+=" [",g+=this.endline(t,S,x),S.state=v.InsideTag,_=t.children,R=0,O=_.length;R<O;R++)h=_[R],g+=this.writeChildNode(h,S,x+1);S.state=v.CloseTag,g+="]"}return S.state=v.CloseTag,g+=S.spaceBeforeSlash+">",g+=this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),g},l.prototype.element=function(t,S,x){var h,R,O,g,_,E,T,L,I,P,G,W,H,z;x||(x=0),P=!1,G="",this.openNode(t,S,x),S.state=v.OpenTag,G+=this.indent(t,S,x)+"<"+t.name,W=t.attribs;for(I in W){if(!s.call(W,I))continue;h=W[I],G+=this.attribute(h,S,x)}if(O=t.children.length,g=O===0?null:t.children[0],O===0||t.children.every(function(B){return(B.type===N.Text||B.type===N.Raw)&&B.value===""}))S.allowEmpty?(G+=">",S.state=v.CloseTag,G+="</"+t.name+">"+this.endline(t,S,x)):(S.state=v.CloseTag,G+=S.spaceBeforeSlash+"/>"+this.endline(t,S,x));else if(S.pretty&&O===1&&(g.type===N.Text||g.type===N.Raw)&&g.value!=null)G+=">",S.state=v.InsideTag,S.suppressPrettyCount++,P=!0,G+=this.writeChildNode(g,S,x+1),S.suppressPrettyCount--,P=!1,S.state=v.CloseTag,G+="</"+t.name+">"+this.endline(t,S,x);else{if(S.dontPrettyTextNodes){for(H=t.children,_=0,T=H.length;_<T;_++)if(R=H[_],(R.type===N.Text||R.type===N.Raw)&&R.value!=null){S.suppressPrettyCount++,P=!0;break}}for(G+=">"+this.endline(t,S,x),S.state=v.InsideTag,z=t.children,E=0,L=z.length;E<L;E++)R=z[E],G+=this.writeChildNode(R,S,x+1);S.state=v.CloseTag,G+=this.indent(t,S,x)+"</"+t.name+">",P&&S.suppressPrettyCount--,G+=this.endline(t,S,x),S.state=v.None}return this.closeNode(t,S,x),G},l.prototype.writeChildNode=function(t,S,x){switch(t.type){case N.CData:return this.cdata(t,S,x);case N.Comment:return this.comment(t,S,x);case N.Element:return this.element(t,S,x);case N.Raw:return this.raw(t,S,x);case N.Text:return this.text(t,S,x);case N.ProcessingInstruction:return this.processingInstruction(t,S,x);case N.Dummy:return"";case N.Declaration:return this.declaration(t,S,x);case N.DocType:return this.docType(t,S,x);case N.AttributeDeclaration:return this.dtdAttList(t,S,x);case N.ElementDeclaration:return this.dtdElement(t,S,x);case N.EntityDeclaration:return this.dtdEntity(t,S,x);case N.NotationDeclaration:return this.dtdNotation(t,S,x);default:throw new Error("Unknown XML node type: "+t.constructor.name)}},l.prototype.processingInstruction=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<?",S.state=v.InsideTag,h+=t.target,t.value&&(h+=" "+t.value),S.state=v.CloseTag,h+=S.spaceBeforeSlash+"?>",h+=this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.raw=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x),S.state=v.InsideTag,h+=t.value,S.state=v.CloseTag,h+=this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.text=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x),S.state=v.InsideTag,h+=t.value,S.state=v.CloseTag,h+=this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.dtdAttList=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<!ATTLIST",S.state=v.InsideTag,h+=" "+t.elementName+" "+t.attributeName+" "+t.attributeType,t.defaultValueType!=="#DEFAULT"&&(h+=" "+t.defaultValueType),t.defaultValue&&(h+=' "'+t.defaultValue+'"'),S.state=v.CloseTag,h+=S.spaceBeforeSlash+">"+this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.dtdElement=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<!ELEMENT",S.state=v.InsideTag,h+=" "+t.name+" "+t.value,S.state=v.CloseTag,h+=S.spaceBeforeSlash+">"+this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.dtdEntity=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<!ENTITY",S.state=v.InsideTag,t.pe&&(h+=" %"),h+=" "+t.name,t.value?h+=' "'+t.value+'"':(t.pubID&&t.sysID?h+=' PUBLIC "'+t.pubID+'" "'+t.sysID+'"':t.sysID&&(h+=' SYSTEM "'+t.sysID+'"'),t.nData&&(h+=" NDATA "+t.nData)),S.state=v.CloseTag,h+=S.spaceBeforeSlash+">"+this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.dtdNotation=function(t,S,x){var h;return this.openNode(t,S,x),S.state=v.OpenTag,h=this.indent(t,S,x)+"<!NOTATION",S.state=v.InsideTag,h+=" "+t.name,t.pubID&&t.sysID?h+=' PUBLIC "'+t.pubID+'" "'+t.sysID+'"':t.pubID?h+=' PUBLIC "'+t.pubID+'"':t.sysID&&(h+=' SYSTEM "'+t.sysID+'"'),S.state=v.CloseTag,h+=S.spaceBeforeSlash+">"+this.endline(t,S,x),S.state=v.None,this.closeNode(t,S,x),h},l.prototype.openNode=function(t,S,x){},l.prototype.closeNode=function(t,S,x){},l.prototype.openAttribute=function(t,S,x){},l.prototype.closeAttribute=function(t,S,x){},l}()}).call(void 0)},{"./NodeType":251,"./Utility":252,"./WriterState":253,"./XMLCData":255,"./XMLComment":257,"./XMLDTDAttList":262,"./XMLDTDElement":263,"./XMLDTDEntity":264,"./XMLDTDNotation":265,"./XMLDeclaration":266,"./XMLDocType":267,"./XMLDummy":270,"./XMLElement":271,"./XMLProcessingInstruction":275,"./XMLRaw":276,"./XMLText":280}],282:[function(F,Q,j){"use strict";(function(){var N,v,C,M,m,y,w,b,p,d;d=F("./Utility"),b=d.assign,p=d.isFunction,C=F("./XMLDOMImplementation"),M=F("./XMLDocument"),m=F("./XMLDocumentCB"),w=F("./XMLStringWriter"),y=F("./XMLStreamWriter"),N=F("./NodeType"),v=F("./WriterState"),Q.exports.create=function(n,c,r,i){var o,u;if(n==null)throw new Error("Root element needs a name.");return i=b({},c,r,i),o=new M(i),u=o.element(n),i.headless||(o.declaration(i),(i.pubID!=null||i.sysID!=null)&&o.dtd(i)),u},Q.exports.begin=function(n,c,r){var i;return p(n)&&(i=[n,c],c=i[0],r=i[1],n={}),c?new m(n,c,r):new M(n)},Q.exports.stringWriter=function(n){return new w(n)},Q.exports.streamWriter=function(n,c){return new y(n,c)},Q.exports.implementation=new C,Q.exports.nodeType=N,Q.exports.writerState=v}).call(void 0)},{"./NodeType":251,"./Utility":252,"./WriterState":253,"./XMLDOMImplementation":260,"./XMLDocument":268,"./XMLDocumentCB":269,"./XMLStreamWriter":277,"./XMLStringWriter":278}],283:[function(F,Q,j){Q.exports=v;var N=Object.prototype.hasOwnProperty;function v(){for(var C={},M=0;M<arguments.length;M++){var m=arguments[M];for(var y in m)N.call(m,y)&&(C[y]=m[y])}return C}},{}],284:[function(F,Q,j){"use strict";var N=F("buffer").Buffer,v=F("./sha"),C=F("./md5"),M={sha1:v,md5:C},m=64,y=N.alloc(m);y.fill(0);function w(d,n,c){N.isBuffer(n)||(n=N.from(n)),N.isBuffer(c)||(c=N.from(c)),n.length>m?n=d(n):n.length<m&&(n=N.concat([n,y],m));for(var r=N.alloc(m),i=N.alloc(m),o=0;o<m;o++)r[o]=n[o]^54,i[o]=n[o]^92;var u=d(N.concat([r,c]));return d(N.concat([i,u]))}function b(d,n){d=d||"sha1";var c=M[d],r=[],i=0;return c||p("algorithm:",d,"is not yet supported"),{update:function(u){return N.isBuffer(u)||(u=N.from(u)),r.push(u),i+=u.length,this},digest:function(u){var f=N.concat(r),s=n?w(c,n,f):c(f);return r=null,u?s.toString(u):s}}}function p(){var d=[].slice.call(arguments).join(" ");throw new Error([d,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join(`
`))}j.createHash=function(d){return b(d)},j.createHmac=function(d,n){return b(d,n)},j.createCredentials=function(){p("sorry,createCredentials is not implemented yet")},j.createCipher=function(){p("sorry,createCipher is not implemented yet")},j.createCipheriv=function(){p("sorry,createCipheriv is not implemented yet")},j.createDecipher=function(){p("sorry,createDecipher is not implemented yet")},j.createDecipheriv=function(){p("sorry,createDecipheriv is not implemented yet")},j.createSign=function(){p("sorry,createSign is not implemented yet")},j.createVerify=function(){p("sorry,createVerify is not implemented yet")},j.createDiffieHellman=function(){p("sorry,createDiffieHellman is not implemented yet")},j.pbkdf2=function(){p("sorry,pbkdf2 is not implemented yet")}},{"./md5":286,"./sha":287,buffer:73}],285:[function(F,Q,j){"use strict";var N=F("buffer").Buffer,v=4,C=N.alloc(v);C.fill(0);var M=8;function m(b,p){if(b.length%v!==0){var d=b.length+(v-b.length%v);b=N.concat([b,C],d)}for(var n=[],c=p?b.readInt32BE:b.readInt32LE,r=0;r<b.length;r+=v)n.push(c.call(b,r));return n}function y(b,p,d){for(var n=N.alloc(p),c=d?n.writeInt32BE:n.writeInt32LE,r=0;r<b.length;r++)c.call(n,b[r],r*4,!0);return n}function w(b,p,d,n){N.isBuffer(b)||(b=N.from(b));var c=p(m(b,n),b.length*M);return y(c,d,n)}Q.exports={hash:w}},{buffer:73}],286:[function(F,Q,j){"use strict";var N=F("./helpers");function v(){return hex_md5("abc")=="900150983cd24fb0d6963f7d28e17f72"}function C(n,c){n[c>>5]|=128<<c%32,n[(c+64>>>9<<4)+14]=c;for(var r=1732584193,i=-271733879,o=-1732584194,u=271733878,f=0;f<n.length;f+=16){var s=r,l=i,t=o,S=u;r=m(r,i,o,u,n[f+0],7,-680876936),u=m(u,r,i,o,n[f+1],12,-389564586),o=m(o,u,r,i,n[f+2],17,606105819),i=m(i,o,u,r,n[f+3],22,-1044525330),r=m(r,i,o,u,n[f+4],7,-176418897),u=m(u,r,i,o,n[f+5],12,1200080426),o=m(o,u,r,i,n[f+6],17,-1473231341),i=m(i,o,u,r,n[f+7],22,-45705983),r=m(r,i,o,u,n[f+8],7,1770035416),u=m(u,r,i,o,n[f+9],12,-1958414417),o=m(o,u,r,i,n[f+10],17,-42063),i=m(i,o,u,r,n[f+11],22,-1990404162),r=m(r,i,o,u,n[f+12],7,1804603682),u=m(u,r,i,o,n[f+13],12,-40341101),o=m(o,u,r,i,n[f+14],17,-1502002290),i=m(i,o,u,r,n[f+15],22,1236535329),r=y(r,i,o,u,n[f+1],5,-165796510),u=y(u,r,i,o,n[f+6],9,-1069501632),o=y(o,u,r,i,n[f+11],14,643717713),i=y(i,o,u,r,n[f+0],20,-373897302),r=y(r,i,o,u,n[f+5],5,-701558691),u=y(u,r,i,o,n[f+10],9,38016083),o=y(o,u,r,i,n[f+15],14,-660478335),i=y(i,o,u,r,n[f+4],20,-405537848),r=y(r,i,o,u,n[f+9],5,568446438),u=y(u,r,i,o,n[f+14],9,-1019803690),o=y(o,u,r,i,n[f+3],14,-187363961),i=y(i,o,u,r,n[f+8],20,1163531501),r=y(r,i,o,u,n[f+13],5,-1444681467),u=y(u,r,i,o,n[f+2],9,-51403784),o=y(o,u,r,i,n[f+7],14,1735328473),i=y(i,o,u,r,n[f+12],20,-1926607734),r=w(r,i,o,u,n[f+5],4,-378558),u=w(u,r,i,o,n[f+8],11,-2022574463),o=w(o,u,r,i,n[f+11],16,1839030562),i=w(i,o,u,r,n[f+14],23,-35309556),r=w(r,i,o,u,n[f+1],4,-1530992060),u=w(u,r,i,o,n[f+4],11,1272893353),o=w(o,u,r,i,n[f+7],16,-155497632),i=w(i,o,u,r,n[f+10],23,-1094730640),r=w(r,i,o,u,n[f+13],4,681279174),u=w(u,r,i,o,n[f+0],11,-358537222),o=w(o,u,r,i,n[f+3],16,-722521979),i=w(i,o,u,r,n[f+6],23,76029189),r=w(r,i,o,u,n[f+9],4,-640364487),u=w(u,r,i,o,n[f+12],11,-421815835),o=w(o,u,r,i,n[f+15],16,530742520),i=w(i,o,u,r,n[f+2],23,-995338651),r=b(r,i,o,u,n[f+0],6,-198630844),u=b(u,r,i,o,n[f+7],10,1126891415),o=b(o,u,r,i,n[f+14],15,-1416354905),i=b(i,o,u,r,n[f+5],21,-57434055),r=b(r,i,o,u,n[f+12],6,1700485571),u=b(u,r,i,o,n[f+3],10,-1894986606),o=b(o,u,r,i,n[f+10],15,-1051523),i=b(i,o,u,r,n[f+1],21,-2054922799),r=b(r,i,o,u,n[f+8],6,1873313359),u=b(u,r,i,o,n[f+15],10,-30611744),o=b(o,u,r,i,n[f+6],15,-1560198380),i=b(i,o,u,r,n[f+13],21,1309151649),r=b(r,i,o,u,n[f+4],6,-145523070),u=b(u,r,i,o,n[f+11],10,-1120210379),o=b(o,u,r,i,n[f+2],15,718787259),i=b(i,o,u,r,n[f+9],21,-343485551),r=p(r,s),i=p(i,l),o=p(o,t),u=p(u,S)}return Array(r,i,o,u)}function M(n,c,r,i,o,u){return p(d(p(p(c,n),p(i,u)),o),r)}function m(n,c,r,i,o,u,f){return M(c&r|~c&i,n,c,o,u,f)}function y(n,c,r,i,o,u,f){return M(c&i|r&~i,n,c,o,u,f)}function w(n,c,r,i,o,u,f){return M(c^r^i,n,c,o,u,f)}function b(n,c,r,i,o,u,f){return M(r^(c|~i),n,c,o,u,f)}function p(n,c){var r=(n&65535)+(c&65535),i=(n>>16)+(c>>16)+(r>>16);return i<<16|r&65535}function d(n,c){return n<<c|n>>>32-c}Q.exports=function(c){return N.hash(c,C,16)}},{"./helpers":285}],287:[function(F,Q,j){"use strict";var N=F("./helpers");function v(w,b){w[b>>5]|=128<<24-b%32,w[(b+64>>9<<4)+15]=b;for(var p=Array(80),d=1732584193,n=-271733879,c=-1732584194,r=271733878,i=-1009589776,o=0;o<w.length;o+=16){for(var u=d,f=n,s=c,l=r,t=i,S=0;S<80;S++){S<16?p[S]=w[o+S]:p[S]=y(p[S-3]^p[S-8]^p[S-14]^p[S-16],1);var x=m(m(y(d,5),C(S,n,c,r)),m(m(i,p[S]),M(S)));i=r,r=c,c=y(n,30),n=d,d=x}d=m(d,u),n=m(n,f),c=m(c,s),r=m(r,l),i=m(i,t)}return Array(d,n,c,r,i)}function C(w,b,p,d){return w<20?b&p|~b&d:w<40?b^p^d:w<60?b&p|b&d|p&d:b^p^d}function M(w){return w<20?1518500249:w<40?1859775393:w<60?-1894007588:-899497514}function m(w,b){var p=(w&65535)+(b&65535),d=(w>>16)+(b>>16)+(p>>16);return d<<16|p&65535}function y(w,b){return w<<b|w>>>32-b}Q.exports=function(b){return N.hash(b,v,20,!0)}},{"./helpers":285}],288:[function(F,Q,j){"use strict";Q.exports=function(){return function(){}}},{}],289:[function(F,Q,j){(function(N){"use strict";var v=F("babel-runtime/helpers/typeof"),C=M(v);function M(d){return d&&d.__esModule?d:{default:d}}var m=F("stream"),y=m.Stream,w=F("../lib/common/utils/isArray"),b=w.isArray;Q.exports.string=function(n){return typeof n=="string"},Q.exports.array=b,Q.exports.buffer=N.isBuffer;function p(d){return d instanceof y}Q.exports.writableStream=function(n){return p(n)&&typeof n._write=="function"&&(0,C.default)(n._writableState)==="object"}}).call(this,{isBuffer:F("../node_modules/is-buffer/index.js")})},{"../lib/common/utils/isArray":42,"../node_modules/is-buffer/index.js":197,"babel-runtime/helpers/typeof":67,stream:230}],290:[function(F,Q,j){"use strict";j.encodeURIComponent=function(N){try{return encodeURIComponent(N)}catch(v){return N}},j.escape=F("escape-html"),j.timestamp=function(v){if(v){var C=v;return typeof C=="string"&&(C=Number(C)),String(v).length===10&&(C*=1e3),new Date(C)}return Math.round(Date.now()/1e3)}},{"escape-html":191}],291:[function(F,Q,j){(function(N,v){"use strict";var C=F("babel-runtime/core-js/json/stringify"),M=w(C),m=F("babel-runtime/helpers/typeof"),y=w(m);function w(S){return S&&S.__esModule?S:{default:S}}var b=F("util"),p=F("url"),d=F("http"),n=F("https"),c=F("debug")("urllib"),r=F("humanize-ms"),i,o=0,u=Math.pow(2,31)-10,f=/^https?:\/\//i;function s(S,x){return S===void 0?x:S}function l(S,x){return function(h,R,O){if(h)return x(h);S({data:R,status:O.statusCode,headers:O.headers,res:O})}}j.TIMEOUTS=[r("300s"),r("300s")];var t=["json","text"];j.request=function(x,h,R){return arguments.length===2&&typeof h=="function"&&(R=h,h=null),typeof R=="function"?j.requestWithCallback(x,h,R):(i||(i=F("any-promise")),new i(function(O,g){j.requestWithCallback(x,h,l(O,g))}))},j.requestWithCallback=function(x,h,R){if(!x||typeof x!="string"&&(typeof x=="undefined"?"undefined":(0,y.default)(x))!=="object"){var O=b.format("expect request url to be a string or a http request options, but got %j",x);throw new Error(O)}arguments.length===2&&typeof h=="function"&&(R=h,h=null),h=h||{},o>=u&&(o=0);var g=++o;h.requestUrls=h.requestUrls||[];var _={requestId:g,url:x,args:h,ctx:h.ctx};h.emitter&&h.emitter.emit("request",_),h.timeout=h.timeout||j.TIMEOUTS,h.maxRedirects=h.maxRedirects||10,h.streaming=h.streaming||h.customResponse;var E=Date.now(),T;typeof x=="string"?(f.test(x)||(x="http://"+x),T=p.parse(x)):T=x;var L=(h.type||h.method||T.method||"GET").toUpperCase(),I=T.port||80,P=d,G=s(h.agent,j.agent),W=h.fixJSONCtlChars;T.protocol==="https:"&&(P=n,G=s(h.httpsAgent,j.httpsAgent),T.port||(I=443));var H={host:T.hostname||T.host||"localhost",path:T.path||"/",method:L,port:I,agent:G,headers:h.headers||{},lookup:h.lookup};Array.isArray(h.timeout)?H.requestTimeout=h.timeout[h.timeout.length-1]:typeof h.timeout!="undefined"&&(H.requestTimeout=h.timeout);for(var z=["pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","secureProtocol","secureOptions"],B=0;B<z.length;B++){var k=z[B];h.hasOwnProperty(k)&&(H[k]=h[k])}H.rejectUnauthorized===!1&&!H.hasOwnProperty("secureOptions")&&(H.secureOptions=F("constants").SSL_OP_NO_TLSv1_2);var K=h.auth||T.auth;K&&(H.auth=K);var Y=h.content||h.data,ne=L==="GET"||L==="HEAD"||h.dataAsQueryString;if(!h.content&&(Y&&!(typeof Y=="string"||v.isBuffer(Y))))if(ne)Y=h.nestedQuerystring?qs.stringify(Y):querystring.stringify(Y);else{var oe=H.headers["Content-Type"]||H.headers["content-type"];oe||(h.contentType==="json"?oe="application/json":oe="application/x-www-form-urlencoded",H.headers["Content-Type"]=oe),parseContentType(oe).type==="application/json"?Y=(0,M.default)(Y):Y=h.nestedQuerystring?qs.stringify(Y):querystring.stringify(Y)}ne&&Y&&(H.path+=(T.query?"&":"?")+Y,Y=null);var _e=0;if(Y){var xe=Y.length;v.isBuffer(Y)||(xe=v.byteLength(Y)),_e=H.headers["Content-Length"]=xe}h.dataType==="json"&&(H.headers.Accept="application/json"),typeof h.beforeRequest=="function"&&h.beforeRequest(H);var le=null,me=null,de=null,ae=!1,ie=!1,q=0,ue=-1,Z=!1,ee="",Ee="",te=null;h.timing&&(te={queuing:0,dnslookup:0,connected:0,requestSent:0,waiting:0,contentDownload:0});function J(){le&&(clearTimeout(le),le=null)}function X(){me&&(clearTimeout(me),me=null)}function $(Se,Je,nt){if(X(),!R){console.warn("[urllib:warn] [%s] [%s] [worker:%s] %s %s callback twice!!!",Date(),g,N.pid,H.method,x),Se&&console.warn(`[urllib:warn] [%s] [%s] [worker:%s] %s: %s
stack: %s`,Date(),g,N.pid,Se.name,Se.message,Se.stack);return}var We=R;R=null;var et={};if(nt&&(ue=nt.statusCode,et=nt.headers),ue===401&&et["www-authenticate"]&&(!h.headers||!h.headers.Authorization)&&h.digestAuth){var Me=et["www-authenticate"];if(Me.indexOf("Digest ")>=0)return c("Request#%d %s: got digest auth header WWW-Authenticate: %s",g,x,Me),h.headers=h.headers||{},h.headers.Authorization=digestAuthHeader(H.method,H.path,Me,h.digestAuth),c("Request#%d %s: auth with digest header: %s",g,x,h.headers.Authorization),nt.headers["set-cookie"]&&(h.headers.Cookie=nt.headers["set-cookie"].join(";")),j.requestWithCallback(x,h,We)}var Ce=Date.now()-E;te&&(te.contentDownload=Ce),c("[%sms] done, %s bytes HTTP %s %s %s %s, keepAliveSocket: %s, timing: %j",Ce,q,ue,H.method,H.host,H.path,ie,te);var Re={status:ue,statusCode:ue,headers:et,size:q,aborted:Z,rt:Ce,keepAliveSocket:ie,data:Je,requestUrls:h.requestUrls,timing:te,remoteAddress:ee,remotePort:Ee};if(Se){var pe="";G&&typeof G.getCurrentStatus=="function"&&(pe=", agent status: "+(0,M.default)(G.getCurrentStatus())),Se.message+=", "+H.method+" "+x+" "+ue+" (connected: "+ae+", keepalive socket: "+ie+pe+`)
headers: `+(0,M.default)(et),Se.data=Je,Se.path=H.path,Se.status=ue,Se.headers=et,Se.res=Re}We(Se,Je,h.streaming?nt:Re),h.emitter&&(_.url=x,_.socket=ot&&ot.connection,_.options=H,_.size=_e,h.emitter.emit("response",{requestId:g,error:Se,ctx:h.ctx,req:_,res:Re}))}function ge(Se){var Je=null;if(h.followRedirect&&statuses.redirect[Se.statusCode]){h._followRedirectCount=(h._followRedirectCount||0)+1;var nt=Se.headers.location;if(!nt)Je=new Error("Got statusCode "+Se.statusCode+" but cannot resolve next location from headers"),Je.name="FollowRedirectError";else if(h._followRedirectCount>h.maxRedirects)Je=new Error("Exceeded maxRedirects. Probably stuck in a redirect loop "+x),Je.name="MaxRedirectError";else{var We=h.formatRedirectUrl?h.formatRedirectUrl(x,nt):p.resolve(x,nt);c("Request#%d %s: `redirected` from %s to %s",g,H.path,x,We),X(),h.headers&&h.headers.Host&&f.test(nt)&&(h.headers.Host=null);var et=R;return R=null,j.requestWithCallback(We,h,et),{redirect:!0,error:null}}}return{redirect:!1,error:Je}}!H.headers["User-Agent"]&&!H.headers["user-agent"]&&(H.headers["User-Agent"]=navigator.userAgent),h.gzip&&(!H.headers["Accept-Encoding"]&&!H.headers["accept-encoding"]&&(H.headers["Accept-Encoding"]="gzip"));function fe(Se,Je,nt){var We=Se.headers["content-encoding"];return nt(null,Je,We)}var Te=h.writeStream;c("Request#%d %s %s with headers %j, options.path: %s",g,L,x,H.headers,H.path),h.requestUrls.push(x);function ze(Se){if(te&&(te.waiting=Date.now()-E),c("Request#%d %s `req response` event emit: status %d, headers: %j",g,x,Se.statusCode,Se.headers),h.streaming){var Je=ge(Se);if(Je.redirect){Se.resume();return}return Je.error?(Se.resume(),$(Je.error,null,Se)):$(null,null,Se)}if(Se.on("close",function(){c("Request#%d %s: `res close` event emit, total size %d",g,x,q)}),Se.on("error",function(){c("Request#%d %s: `res error` event emit, total size %d",g,x,q)}),Se.on("aborted",function(){Z=!0,c("Request#%d %s: `res aborted` event emit, total size %d",g,x,q)}),Te){var Je=ge(Se);if(Je.redirect){Se.resume();return}return Je.error?(Se.resume(),Te.end(),$(Je.error,null,Se)):(h.consumeWriteStream===!1?Se.on("end",$.bind(null,null,null,Se)):isNode010||isNode012?first([[Te,"close"],[Se,"aborted"]],function(et,Me,Ce){c("Request#%d %s: writeStream or res %s event emitted",g,x,Ce),$(de||null,null,Se)}):Te.on("close",function(){c("Request#%d %s: writeStream close event emitted",g,x),$(de||null,null,Se)}),Se.pipe(Te))}var nt=[];Se.on("data",function(We){c("Request#%d %s: `res data` event emit, size %d",g,x,We.length),q+=We.length,nt.push(We)}),Se.on("end",function(){var We=v.concat(nt,q);if(c("Request#%d %s: `res end` event emit, total size %d, _dumped: %s",g,x,q,Se._dumped),de)return $(de,We,Se);var et=ge(Se);if(et.error)return $(et.error,We,Se);if(et.redirect)return;fe(Se,We,function(Me,Ce,Re){if(Me)return $(Me,We,Se);if(!Re&&t.indexOf(h.dataType)>=0){try{Ce=decodeBodyByCharset(Ce,Se)}catch(ye){return c("decodeBodyByCharset error: %s",ye),$(null,Ce,Se)}if(h.dataType==="json")if(q===0)Ce=null;else{var pe=parseJSON(Ce,W);pe.error?Me=pe.error:Ce=pe.data}}Z&&c("Request#%d %s: Remote socket was terminated before `response.end()` was called",g,x),$(Me,Ce,Se)})})}var Xe,Ye;Array.isArray(h.timeout)?(Xe=r(h.timeout[0]),Ye=r(h.timeout[1])):Xe=Ye=r(h.timeout),c("ConnectTimeout: %d, ResponseTimeout: %d",Xe,Ye);function rt(){c("Connect timer ticking, timeout: %d",Xe),le=setTimeout(function(){le=null,ue===-1&&(ue=-2);var Se="Connect timeout for "+Xe+"ms",Je="ConnectionTimeoutError";ot.socket||(Je="SocketAssignTimeoutError",Se+=", working sockets is full"),de=new Error(Se),de.name=Je,de.requestId=g,c("ConnectTimeout: Request#%d %s %s: %s, connected: %s",g,x,de.name,Se,ae),Pe()},Xe)}function at(){c("Response timer ticking, timeout: %d",Ye),me=setTimeout(function(){me=null;var Se="Response timeout for "+Ye+"ms",Je="ResponseTimeoutError";de=new Error(Se),de.name=Je,de.requestId=g,c("ResponseTimeout: Request#%d %s %s: %s, connected: %s",g,x,de.name,Se,ae),Pe()},Ye)}var ot;H.mode=h.mode?h.mode:"";try{ot=P.request(H,ze)}catch(Se){return $(Se)}typeof window=="undefined"?rt():ot.on("requestTimeout",function(){ue===-1&&(ue=-2);var Se="Connect timeout for "+Xe+"ms",Je="ConnectionTimeoutError";de=new Error(Se),de.name=Je,de.requestId=g,Pe()});function Pe(){c("Request#%d %s abort, connected: %s",g,x,ae),ot.socket||(de.noSocket=!0,$(de)),ot.abort()}return te&&ot.on("finish",function(){te.requestSent=Date.now()-E}),ot.once("socket",function(Se){te&&(te.queuing=Date.now()-E),isNode010&&Se.socket&&(Se=Se.socket);var Je=Se.readyState;if(Je==="opening"){Se.once("lookup",function(nt,We,et){c("Request#%d %s lookup: %s, %s, %s",g,x,nt,We,et),te&&(te.dnslookup=Date.now()-E),We&&(ee=We)}),Se.once("connect",function(){te&&(te.connected=Date.now()-E),J(),at(),c("Request#%d %s new socket connected",g,x),ae=!0,ee||(ee=Se.remoteAddress),Ee=Se.remotePort});return}c("Request#%d %s reuse socket connected, readyState: %s",g,x,Je),ae=!0,ie=!0,ee||(ee=Se.remoteAddress),Ee=Se.remotePort,J(),at()}),ot.on("error",function(Se){(Se.name==="Error"||Se.name==="TypeError")&&(Se.name=ae?"ResponseError":"RequestError"),Se.message+=' (req "error")',c("Request#%d %s `req error` event emit, %s: %s",g,x,Se.name,Se.message),$(de||Se)}),Te&&Te.once("error",function(Se){Se.message+=' (writeStream "error")',de=Se,c("Request#%d %s `writeStream error` event emit, %s: %s",g,x,Se.name,Se.message),Pe()}),h.stream?(h.stream.pipe(ot),h.stream.once("error",function(Se){Se.message+=' (stream "error")',de=Se,c("Request#%d %s `readStream error` event emit, %s: %s",g,x,Se.name,Se.message),Pe()})):ot.end(Y),ot.requestId=g,ot}}).call(this,F("_process"),F("buffer").Buffer)},{_process:208,"any-promise":49,"babel-runtime/core-js/json/stringify":53,"babel-runtime/helpers/typeof":67,buffer:73,constants:75,debug:288,http:231,https:193,"humanize-ms":194,url:238,util:243}]},{},[1])(1)})}).call(this,__webpack_require__("IyRk"))},n6Qo:function(F,Q,j){"use strict";j.d(Q,"a",function(){return b});var N=j("cDcd"),v=j("biw7"),C=j("fyJ8");function M(p){var d=p.className,n=p.index,c=p.children,r=p.colSpan,i=p.rowSpan,o=N.useContext(v.a),u=o.prefixCls,f=o.fixedInfoList,s=f[n];return N.createElement(C.a,Object.assign({className:d,index:n,component:"td",prefixCls:u,record:null,dataIndex:null,render:function(){return{children:c,props:{colSpan:r,rowSpan:i}}}},s))}function m(p){return N.createElement("tr",Object.assign({},p))}function y(p){var d=p.children,n=N.useContext(v.a),c=n.prefixCls;return N.createElement("tfoot",{className:"".concat(c,"-summary")},d)}var w=Q.b=y,b={Cell:M,Row:m}},oRuE:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.pad.Iso10126={pad:function(v,C){var M=C*4,m=M-v.sigBytes%M;v.concat(N.lib.WordArray.random(m-1)).concat(N.lib.WordArray.create([m<<24],1))},unpad:function(v){var C=v.words[v.sigBytes-1>>>2]&255;v.sigBytes-=C}},N.pad.Iso10126})},osHv:function(F,Q,j){(function(N){N(j("VrN/"))})(function(N){"use strict";var v=N.Pos;function C(f,s){return f.line-s.line||f.ch-s.ch}var M="A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",m=M+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",y=new RegExp("<(/?)(["+M+"]["+m+"]*)","g");function w(f,s,l,t){this.line=s,this.ch=l,this.cm=f,this.text=f.getLine(s),this.min=t?Math.max(t.from,f.firstLine()):f.firstLine(),this.max=t?Math.min(t.to-1,f.lastLine()):f.lastLine()}function b(f,s){var l=f.cm.getTokenTypeAt(v(f.line,s));return l&&/\btag\b/.test(l)}function p(f){return f.line>=f.max?void 0:(f.ch=0,f.text=f.cm.getLine(++f.line),!0)}function d(f){return f.line<=f.min?void 0:(f.text=f.cm.getLine(--f.line),f.ch=f.text.length,!0)}function n(f){for(;;){var s=f.text.indexOf(">",f.ch);if(s==-1){if(p(f))continue;return}if(!b(f,s+1)){f.ch=s+1;continue}var l=f.text.lastIndexOf("/",s),t=l>-1&&!/\S/.test(f.text.slice(l+1,s));return f.ch=s+1,t?"selfClose":"regular"}}function c(f){for(;;){var s=f.ch?f.text.lastIndexOf("<",f.ch-1):-1;if(s==-1){if(d(f))continue;return}if(!b(f,s+1)){f.ch=s;continue}y.lastIndex=s,f.ch=s;var l=y.exec(f.text);if(l&&l.index==s)return l}}function r(f){for(;;){y.lastIndex=f.ch;var s=y.exec(f.text);if(!s){if(p(f))continue;return}if(!b(f,s.index+1)){f.ch=s.index+1;continue}return f.ch=s.index+s[0].length,s}}function i(f){for(;;){var s=f.ch?f.text.lastIndexOf(">",f.ch-1):-1;if(s==-1){if(d(f))continue;return}if(!b(f,s+1)){f.ch=s;continue}var l=f.text.lastIndexOf("/",s),t=l>-1&&!/\S/.test(f.text.slice(l+1,s));return f.ch=s+1,t?"selfClose":"regular"}}function o(f,s){for(var l=[];;){var t=r(f),S,x=f.line,h=f.ch-(t?t[0].length:0);if(!t||!(S=n(f)))return;if(S=="selfClose")continue;if(t[1]){for(var R=l.length-1;R>=0;--R)if(l[R]==t[2]){l.length=R;break}if(R<0&&(!s||s==t[2]))return{tag:t[2],from:v(x,h),to:v(f.line,f.ch)}}else l.push(t[2])}}function u(f,s){for(var l=[];;){var t=i(f);if(!t)return;if(t=="selfClose"){c(f);continue}var S=f.line,x=f.ch,h=c(f);if(!h)return;if(h[1])l.push(h[2]);else{for(var R=l.length-1;R>=0;--R)if(l[R]==h[2]){l.length=R;break}if(R<0&&(!s||s==h[2]))return{tag:h[2],from:v(f.line,f.ch),to:v(S,x)}}}}N.registerHelper("fold","xml",function(f,s){for(var l=new w(f,s.line,0);;){var t=r(l);if(!t||l.line!=s.line)return;var S=n(l);if(!S)return;if(!t[1]&&S!="selfClose"){var x=v(l.line,l.ch),h=o(l,t[2]);return h&&C(h.from,x)>0?{from:x,to:h.from}:null}}}),N.findMatchingTag=function(f,s,l){var t=new w(f,s.line,s.ch,l);if(t.text.indexOf(">")==-1&&t.text.indexOf("<")==-1)return;var S=n(t),x=S&&v(t.line,t.ch),h=S&&c(t);if(!S||!h||C(t,s)>0)return;var R={from:v(t.line,t.ch),to:x,tag:h[2]};return S=="selfClose"?{open:R,close:null,at:"open"}:h[1]?{open:u(t,h[2]),close:R,at:"close"}:(t=new w(f,x.line,x.ch,l),{open:R,close:o(t,h[2]),at:"open"})},N.findEnclosingTag=function(f,s,l,t){for(var S=new w(f,s.line,s.ch,l);;){var x=u(S,t);if(!x)break;var h=new w(f,s.line,s.ch,l),R=o(h,x.tag);if(R)return{open:x,close:R}}},N.scanForClosingTag=function(f,s,l,t){var S=new w(f,s.line,s.ch,t?{from:0,to:t}:null);return o(S,l)}})},p5ED:function(F,Q,j){"use strict";var N=j("+L6B"),v=j("2/Rp"),C=j("5Dmo"),M=j("3S7+"),m=j("k1fw"),y=j("tJVT"),w=j("cDcd"),b=j.n(w),p=j("vHTk"),d=j.n(p),n=j("yEEn"),c=j("ZW9T"),r=j("1vsH");Q.a=function(i){var o=i.name,u=i.data,f=i.theme,s=i.type,l=i.filename,t=i.monacoEditor,S=i.className,x=i.style,h=i.close,R=i.onClose,O=i.hasMask,g=Object(w.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),_=Object(y.a)(g,2),E=_[0],T=_[1],L=Object(w.useState)(""),I=Object(y.a)(L,2),P=I[0],G=I[1],W,H=1024*1024,z=10*H,B=Object(w.useRef)();s==="office"&&(W=Object(r.V)(u).filesize,W>z&&(s="other")),l&&(t.filename=l),Object(w.useEffect)(function(){var Y,ne,oe=(Y=document.cookie)===null||Y===void 0||((ne=Y.replace(/\s/g,""))===null||ne===void 0)?void 0:ne.split(";");oe==null||oe.map(function(_e){var xe=_e.split("=");xe[0]==="_educoder_session"&&G(xe[1])})},[]);var k=function(){if(u.startsWith("http")||u.startsWith("/")){K();return}Object(r.z)(l||"educoder",u,l)},K=function(){Object(r.x)(l||o,u)};return console.log("data:",u,"fileanme:",l," name:",o),b.a.createElement("div",{style:Object(m.a)({},x||{}),className:"".concat(O&&d.a.bgBlack," ").concat(s?d.a.wrp:"hide")},h&&b.a.createElement("div",{className:d.a.close,ref:B},b.a.createElement(M.a,{title:"\u70B9\u51FB\u4E0B\u8F7D\u6B64\u6587\u4EF6",getPopupContainer:function(){return B.current}},b.a.createElement("span",{onClick:K},b.a.createElement("i",{className:"icon-quxiaozhiding"}))),b.a.createElement(M.a,{title:"\u5173\u95ED",getPopupContainer:function(){return B.current}},b.a.createElement("span",{className:"",onClick:R},b.a.createElement("i",{className:"icon-guanbi1"})))),b.a.createElement("div",{className:"".concat(d.a[S]," ").concat(S," ").concat(d.a.monaco," ").concat(s==="txt"?"show":"hide")},s==="txt"&&b.a.createElement(c.b,t)),s==="audio"&&b.a.createElement("audio",{src:"".concat(u!=null&&u.startsWith("/")||(u==null?void 0:u.indexOf("https://"))>-1?u:"data:audio/mp3;base64,").concat(u),autoPlay:!0}),s==="video"&&b.a.createElement(b.a.Fragment,null,u!=null&&u.startsWith("/")?b.a.createElement("video",{controls:!0,src:"".concat(u),autoPlay:!0}):b.a.createElement("video",{controls:!0,src:"data:video/mp4;base64,".concat(u),autoPlay:!0})),s==="html"&&b.a.createElement("iframe",{src:u+"&disposition=inline"}),s==="pdf"&&b.a.createElement("embed",{className:d.a.embed,src:u}),s==="image"&&b.a.createElement(b.a.Fragment,null,b.a.createElement("img",{src:"".concat(u!=null&&u.startsWith("/")||(u==null?void 0:u.indexOf("https://"))>-1?"":"data:image/png;base64,").concat(u)})),s==="other"&&b.a.createElement("div",null,b.a.createElement(v.a,{type:"primary",size:"large",onClick:k},b.a.createElement(n.a,null),"\u70B9\u51FB\u4E0B\u8F7D")),(s==="download"||s==="office")&&b.a.createElement(v.a,{type:"primary",size:"large",onClick:k},b.a.createElement(n.a,null),"\u70B9\u51FB\u4E0B\u8F7D"))}},"p77/":function(F,Q,j){},pA7S:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("ETIr"),j("cv67"),j("K3mO"),j("OLod"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.WordArray,m=C.BlockCipher,y=v.algo,w=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],b=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],p=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],d=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],n=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],c=y.DES=m.extend({_doReset:function(){for(var u=this._key,f=u.words,s=[],l=0;l<56;l++){var t=w[l]-1;s[l]=f[t>>>5]>>>31-t%32&1}for(var S=this._subKeys=[],x=0;x<16;x++){for(var h=S[x]=[],R=p[x],l=0;l<24;l++)h[l/6|0]|=s[(b[l]-1+R)%28]<<31-l%6,h[4+(l/6|0)]|=s[28+(b[l+24]-1+R)%28]<<31-l%6;h[0]=h[0]<<1|h[0]>>>31;for(var l=1;l<7;l++)h[l]=h[l]>>>(l-1)*4+3;h[7]=h[7]<<5|h[7]>>>27}for(var O=this._invSubKeys=[],l=0;l<16;l++)O[l]=S[15-l]},encryptBlock:function(u,f){this._doCryptBlock(u,f,this._subKeys)},decryptBlock:function(u,f){this._doCryptBlock(u,f,this._invSubKeys)},_doCryptBlock:function(u,f,s){this._lBlock=u[f],this._rBlock=u[f+1],r.call(this,4,252645135),r.call(this,16,65535),i.call(this,2,858993459),i.call(this,8,16711935),r.call(this,1,1431655765);for(var l=0;l<16;l++){for(var t=s[l],S=this._lBlock,x=this._rBlock,h=0,R=0;R<8;R++)h|=d[R][((x^t[R])&n[R])>>>0];this._lBlock=x,this._rBlock=S^h}var O=this._lBlock;this._lBlock=this._rBlock,this._rBlock=O,r.call(this,1,1431655765),i.call(this,8,16711935),i.call(this,2,858993459),r.call(this,16,65535),r.call(this,4,252645135),u[f]=this._lBlock,u[f+1]=this._rBlock},keySize:64/32,ivSize:64/32,blockSize:64/32});function r(u,f){var s=(this._lBlock>>>u^this._rBlock)&f;this._rBlock^=s,this._lBlock^=s<<u}function i(u,f){var s=(this._rBlock>>>u^this._lBlock)&f;this._lBlock^=s,this._rBlock^=s<<u}v.DES=m._createHelper(c);var o=y.TripleDES=m.extend({_doReset:function(){var u=this._key,f=u.words;if(f.length!==2&&f.length!==4&&f.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var s=f.slice(0,2),l=f.length<4?f.slice(0,2):f.slice(2,4),t=f.length<6?f.slice(0,2):f.slice(4,6);this._des1=c.createEncryptor(M.create(s)),this._des2=c.createEncryptor(M.create(l)),this._des3=c.createEncryptor(M.create(t))},encryptBlock:function(u,f){this._des1.encryptBlock(u,f),this._des2.decryptBlock(u,f),this._des3.encryptBlock(u,f)},decryptBlock:function(u,f){this._des3.decryptBlock(u,f),this._des2.encryptBlock(u,f),this._des1.decryptBlock(u,f)},keySize:192/32,ivSize:64/32,blockSize:64/32});v.TripleDES=m._createHelper(o)}(),N.TripleDES})},pIsd:function(F,Q,j){var N=j("BJfS"),v=function(m){var y=/[height|width]$/;return y.test(m)},C=function(m){var y="",w=Object.keys(m);return w.forEach(function(b,p){var d=m[b];b=N(b),v(b)&&typeof d=="number"&&(d=d+"px"),d===!0?y+=b:d===!1?y+="not "+b:y+="("+b+": "+d+")",p<w.length-1&&(y+=" and ")}),y},M=function(m){var y="";return typeof m=="string"?m:m instanceof Array?(m.forEach(function(w,b){y+=C(w),b<m.length-1&&(y+=", ")}),y):C(m)};F.exports=M},psGv:function(F,Q,j){var N,v;(function(){var C;(function(){"use strict";var w=[,,function(n){function c(o){this.__parent=o,this.__character_count=0,this.__indent_count=-1,this.__alignment_count=0,this.__wrap_point_index=0,this.__wrap_point_character_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}c.prototype.clone_empty=function(){var o=new c(this.__parent);return o.set_indent(this.__indent_count,this.__alignment_count),o},c.prototype.item=function(o){return o<0?this.__items[this.__items.length+o]:this.__items[o]},c.prototype.has_match=function(o){for(var u=this.__items.length-1;u>=0;u--)if(this.__items[u].match(o))return!0;return!1},c.prototype.set_indent=function(o,u){this.is_empty()&&(this.__indent_count=o||0,this.__alignment_count=u||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},c.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},c.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},c.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var o=this.__parent.current_line;return o.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),o.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),o.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count,o.__items[0]===" "&&(o.__items.splice(0,1),o.__character_count-=1),!0}return!1},c.prototype.is_empty=function(){return this.__items.length===0},c.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},c.prototype.push=function(o){this.__items.push(o);var u=o.lastIndexOf(`
`);u!==-1?this.__character_count=o.length-u:this.__character_count+=o.length},c.prototype.pop=function(){var o=null;return this.is_empty()||(o=this.__items.pop(),this.__character_count-=o.length),o},c.prototype._remove_indent=function(){this.__indent_count>0&&(this.__indent_count-=1,this.__character_count-=this.__parent.indent_size)},c.prototype._remove_wrap_indent=function(){this.__wrap_point_indent_count>0&&(this.__wrap_point_indent_count-=1)},c.prototype.trim=function(){for(;this.last()===" ";)this.__items.pop(),this.__character_count-=1},c.prototype.toString=function(){var o="";return this.is_empty()?this.__parent.indent_empty_lines&&(o=this.__parent.get_indent_string(this.__indent_count)):(o=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),o+=this.__items.join("")),o};function r(o,u){this.__cache=[""],this.__indent_size=o.indent_size,this.__indent_string=o.indent_char,o.indent_with_tabs||(this.__indent_string=new Array(o.indent_size+1).join(o.indent_char)),u=u||"",o.indent_level>0&&(u=new Array(o.indent_level+1).join(this.__indent_string)),this.__base_string=u,this.__base_string_length=u.length}r.prototype.get_indent_size=function(o,u){var f=this.__base_string_length;return u=u||0,o<0&&(f=0),f+=o*this.__indent_size,f+=u,f},r.prototype.get_indent_string=function(o,u){var f=this.__base_string;return u=u||0,o<0&&(o=0,f=""),u+=o*this.__indent_size,this.__ensure_cache(u),f+=this.__cache[u],f},r.prototype.__ensure_cache=function(o){for(;o>=this.__cache.length;)this.__add_column()},r.prototype.__add_column=function(){var o=this.__cache.length,u=0,f="";this.__indent_size&&o>=this.__indent_size&&(u=Math.floor(o/this.__indent_size),o-=u*this.__indent_size,f=new Array(u+1).join(this.__indent_string)),o&&(f+=new Array(o+1).join(" ")),this.__cache.push(f)};function i(o,u){this.__indent_cache=new r(o,u),this.raw=!1,this._end_with_newline=o.end_with_newline,this.indent_size=o.indent_size,this.wrap_line_length=o.wrap_line_length,this.indent_empty_lines=o.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new c(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}i.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},i.prototype.get_line_number=function(){return this.__lines.length},i.prototype.get_indent_string=function(o,u){return this.__indent_cache.get_indent_string(o,u)},i.prototype.get_indent_size=function(o,u){return this.__indent_cache.get_indent_size(o,u)},i.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},i.prototype.add_new_line=function(o){return this.is_empty()||!o&&this.just_added_newline()?!1:(this.raw||this.__add_outputline(),!0)},i.prototype.get_code=function(o){this.trim(!0);var u=this.current_line.pop();u&&(u[u.length-1]===`
`&&(u=u.replace(/\n+$/g,"")),this.current_line.push(u)),this._end_with_newline&&this.__add_outputline();var f=this.__lines.join(`
`);return o!==`
`&&(f=f.replace(/[\n]/g,o)),f},i.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},i.prototype.set_indent=function(o,u){return o=o||0,u=u||0,this.next_line.set_indent(o,u),this.__lines.length>1?(this.current_line.set_indent(o,u),!0):(this.current_line.set_indent(),!1)},i.prototype.add_raw_token=function(o){for(var u=0;u<o.newlines;u++)this.__add_outputline();this.current_line.set_indent(-1),this.current_line.push(o.whitespace_before),this.current_line.push(o.text),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1},i.prototype.add_token=function(o){this.__add_space_before_token(),this.current_line.push(o),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=this.current_line._allow_wrap()},i.prototype.__add_space_before_token=function(){this.space_before_token&&!this.just_added_newline()&&(this.non_breaking_space||this.set_wrap_point(),this.current_line.push(" "))},i.prototype.remove_indent=function(o){for(var u=this.__lines.length;o<u;)this.__lines[o]._remove_indent(),o++;this.current_line._remove_wrap_indent()},i.prototype.trim=function(o){for(o=o===void 0?!1:o,this.current_line.trim();o&&this.__lines.length>1&&this.current_line.is_empty();)this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null},i.prototype.just_added_newline=function(){return this.current_line.is_empty()},i.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()},i.prototype.ensure_empty_line_above=function(o,u){for(var f=this.__lines.length-2;f>=0;){var s=this.__lines[f];if(s.is_empty())break;if(s.item(0).indexOf(o)!==0&&s.item(-1)!==u){this.__lines.splice(f+1,0,new c(this)),this.previous_line=this.__lines[this.__lines.length-2];break}f--}},n.exports.Output=i},function(n){function c(r,i,o,u){this.type=r,this.text=i,this.comments_before=null,this.newlines=o||0,this.whitespace_before=u||"",this.parent=null,this.next=null,this.previous=null,this.opened=null,this.closed=null,this.directives=null}n.exports.Token=c},,,function(n){function c(o,u){this.raw_options=r(o,u),this.disabled=this._get_boolean("disabled"),this.eol=this._get_characters("eol","auto"),this.end_with_newline=this._get_boolean("end_with_newline"),this.indent_size=this._get_number("indent_size",4),this.indent_char=this._get_characters("indent_char"," "),this.indent_level=this._get_number("indent_level"),this.preserve_newlines=this._get_boolean("preserve_newlines",!0),this.max_preserve_newlines=this._get_number("max_preserve_newlines",32786),this.preserve_newlines||(this.max_preserve_newlines=0),this.indent_with_tabs=this._get_boolean("indent_with_tabs",this.indent_char===" "),this.indent_with_tabs&&(this.indent_char=" ",this.indent_size===1&&(this.indent_size=4)),this.wrap_line_length=this._get_number("wrap_line_length",this._get_number("max_char")),this.indent_empty_lines=this._get_boolean("indent_empty_lines"),this.templating=this._get_selection_list("templating",["auto","none","django","erb","handlebars","php","smarty"],["auto"])}c.prototype._get_array=function(o,u){var f=this.raw_options[o],s=u||[];return typeof f=="object"?f!==null&&typeof f.concat=="function"&&(s=f.concat()):typeof f=="string"&&(s=f.split(/[^a-zA-Z0-9_\/\-]+/)),s},c.prototype._get_boolean=function(o,u){var f=this.raw_options[o],s=f===void 0?!!u:!!f;return s},c.prototype._get_characters=function(o,u){var f=this.raw_options[o],s=u||"";return typeof f=="string"&&(s=f.replace(/\\r/,"\r").replace(/\\n/,`
`).replace(/\\t/," ")),s},c.prototype._get_number=function(o,u){var f=this.raw_options[o];u=parseInt(u,10),isNaN(u)&&(u=0);var s=parseInt(f,10);return isNaN(s)&&(s=u),s},c.prototype._get_selection=function(o,u,f){var s=this._get_selection_list(o,u,f);if(s.length!==1)throw new Error("Invalid Option Value: The option '"+o+`' can only be one of the following values:
`+u+`
You passed in: '`+this.raw_options[o]+"'");return s[0]},c.prototype._get_selection_list=function(o,u,f){if(!u||u.length===0)throw new Error("Selection list cannot be empty.");if(f=f||[u[0]],!this._is_valid_selection(f,u))throw new Error("Invalid Default Value!");var s=this._get_array(o,f);if(!this._is_valid_selection(s,u))throw new Error("Invalid Option Value: The option '"+o+`' can contain only the following values:
`+u+`
You passed in: '`+this.raw_options[o]+"'");return s},c.prototype._is_valid_selection=function(o,u){return o.length&&u.length&&!o.some(function(f){return u.indexOf(f)===-1})};function r(o,u){var f={};o=i(o);var s;for(s in o)s!==u&&(f[s]=o[s]);if(u&&o[u])for(s in o[u])f[s]=o[u][s];return f}function i(o){var u={},f;for(f in o){var s=f.replace(/-/g,"_");u[s]=o[f]}return u}n.exports.Options=c,n.exports.normalizeOpts=i,n.exports.mergeOpts=r},,function(n){var c=RegExp.prototype.hasOwnProperty("sticky");function r(i){this.__input=i||"",this.__input_length=this.__input.length,this.__position=0}r.prototype.restart=function(){this.__position=0},r.prototype.back=function(){this.__position>0&&(this.__position-=1)},r.prototype.hasNext=function(){return this.__position<this.__input_length},r.prototype.next=function(){var i=null;return this.hasNext()&&(i=this.__input.charAt(this.__position),this.__position+=1),i},r.prototype.peek=function(i){var o=null;return i=i||0,i+=this.__position,i>=0&&i<this.__input_length&&(o=this.__input.charAt(i)),o},r.prototype.__match=function(i,o){i.lastIndex=o;var u=i.exec(this.__input);return u&&!(c&&i.sticky)&&(u.index!==o&&(u=null)),u},r.prototype.test=function(i,o){return o=o||0,o+=this.__position,o>=0&&o<this.__input_length?!!this.__match(i,o):!1},r.prototype.testChar=function(i,o){var u=this.peek(o);return i.lastIndex=0,u!==null&&i.test(u)},r.prototype.match=function(i){var o=this.__match(i,this.__position);return o?this.__position+=o[0].length:o=null,o},r.prototype.read=function(i,o,u){var f="",s;return i&&(s=this.match(i),s&&(f+=s[0])),o&&(s||!i)&&(f+=this.readUntil(o,u)),f},r.prototype.readUntil=function(i,o){var u="",f=this.__position;i.lastIndex=this.__position;var s=i.exec(this.__input);return s?(f=s.index,o&&(f+=s[0].length)):f=this.__input_length,u=this.__input.substring(this.__position,f),this.__position=f,u},r.prototype.readUntilAfter=function(i){return this.readUntil(i,!0)},r.prototype.get_regexp=function(i,o){var u=null,f="g";return o&&c&&(f="y"),typeof i=="string"&&i!==""?u=new RegExp(i,f):i&&(u=new RegExp(i.source,f)),u},r.prototype.get_literal_regexp=function(i){return RegExp(i.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))},r.prototype.peekUntilAfter=function(i){var o=this.__position,u=this.readUntilAfter(i);return this.__position=o,u},r.prototype.lookBack=function(i){var o=this.__position-1;return o>=i.length&&this.__input.substring(o-i.length,o).toLowerCase()===i},n.exports.InputScanner=r},function(n,c,r){var i=r(8).InputScanner,o=r(3).Token,u=r(10).TokenStream,f=r(11).WhitespacePattern,s={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"},l=function(t,S){this._input=new i(t),this._options=S||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new f(this._input)};l.prototype.tokenize=function(){this._input.restart(),this.__tokens=new u,this._reset();for(var t,S=new o(s.START,""),x=null,h=[],R=new u;S.type!==s.EOF;){for(t=this._get_next_token(S,x);this._is_comment(t);)R.add(t),t=this._get_next_token(S,x);R.isEmpty()||(t.comments_before=R,R=new u),t.parent=x,this._is_opening(t)?(h.push(x),x=t):x&&this._is_closing(t,x)&&(t.opened=x,x.closed=t,x=h.pop(),t.parent=x),t.previous=S,S.next=t,this.__tokens.add(t),S=t}return this.__tokens},l.prototype._is_first_token=function(){return this.__tokens.isEmpty()},l.prototype._reset=function(){},l.prototype._get_next_token=function(t,S){this._readWhitespace();var x=this._input.read(/.+/g);return x?this._create_token(s.RAW,x):this._create_token(s.EOF,"")},l.prototype._is_comment=function(t){return!1},l.prototype._is_opening=function(t){return!1},l.prototype._is_closing=function(t,S){return!1},l.prototype._create_token=function(t,S){var x=new o(t,S,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token);return x},l.prototype._readWhitespace=function(){return this._patterns.whitespace.read()},n.exports.Tokenizer=l,n.exports.TOKEN=s},function(n){function c(r){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=r}c.prototype.restart=function(){this.__position=0},c.prototype.isEmpty=function(){return this.__tokens_length===0},c.prototype.hasNext=function(){return this.__position<this.__tokens_length},c.prototype.next=function(){var r=null;return this.hasNext()&&(r=this.__tokens[this.__position],this.__position+=1),r},c.prototype.peek=function(r){var i=null;return r=r||0,r+=this.__position,r>=0&&r<this.__tokens_length&&(i=this.__tokens[r]),i},c.prototype.add=function(r){this.__parent_token&&(r.parent=this.__parent_token),this.__tokens.push(r),this.__tokens_length+=1},n.exports.TokenStream=c},function(n,c,r){var i=r(12).Pattern;function o(u,f){i.call(this,u,f),f?this._line_regexp=this._input.get_regexp(f._line_regexp):this.__set_whitespace_patterns("",""),this.newline_count=0,this.whitespace_before_token=""}o.prototype=new i,o.prototype.__set_whitespace_patterns=function(u,f){u+="\\t ",f+="\\n\\r",this._match_pattern=this._input.get_regexp("["+u+f+"]+",!0),this._newline_regexp=this._input.get_regexp("\\r\\n|["+f+"]")},o.prototype.read=function(){this.newline_count=0,this.whitespace_before_token="";var u=this._input.read(this._match_pattern);if(u===" ")this.whitespace_before_token=" ";else if(u){var f=this.__split(this._newline_regexp,u);this.newline_count=f.length-1,this.whitespace_before_token=f[this.newline_count]}return u},o.prototype.matching=function(u,f){var s=this._create();return s.__set_whitespace_patterns(u,f),s._update(),s},o.prototype._create=function(){return new o(this._input,this)},o.prototype.__split=function(u,f){u.lastIndex=0;for(var s=0,l=[],t=u.exec(f);t;)l.push(f.substring(s,t.index)),s=t.index+t[0].length,t=u.exec(f);return s<f.length?l.push(f.substring(s,f.length)):l.push(""),l},n.exports.WhitespacePattern=o},function(n){function c(r,i){this._input=r,this._starting_pattern=null,this._match_pattern=null,this._until_pattern=null,this._until_after=!1,i&&(this._starting_pattern=this._input.get_regexp(i._starting_pattern,!0),this._match_pattern=this._input.get_regexp(i._match_pattern,!0),this._until_pattern=this._input.get_regexp(i._until_pattern),this._until_after=i._until_after)}c.prototype.read=function(){var r=this._input.read(this._starting_pattern);return(!this._starting_pattern||r)&&(r+=this._input.read(this._match_pattern,this._until_pattern,this._until_after)),r},c.prototype.read_match=function(){return this._input.match(this._match_pattern)},c.prototype.until_after=function(r){var i=this._create();return i._until_after=!0,i._until_pattern=this._input.get_regexp(r),i._update(),i},c.prototype.until=function(r){var i=this._create();return i._until_after=!1,i._until_pattern=this._input.get_regexp(r),i._update(),i},c.prototype.starting_with=function(r){var i=this._create();return i._starting_pattern=this._input.get_regexp(r,!0),i._update(),i},c.prototype.matching=function(r){var i=this._create();return i._match_pattern=this._input.get_regexp(r,!0),i._update(),i},c.prototype._create=function(){return new c(this._input,this)},c.prototype._update=function(){},n.exports.Pattern=c},function(n){function c(r,i){r=typeof r=="string"?r:r.source,i=typeof i=="string"?i:i.source,this.__directives_block_pattern=new RegExp(r+/ beautify( \w+[:]\w+)+ /.source+i,"g"),this.__directive_pattern=/ (\w+)[:](\w+)/g,this.__directives_end_ignore_pattern=new RegExp(r+/\sbeautify\signore:end\s/.source+i,"g")}c.prototype.get_directives=function(r){if(!r.match(this.__directives_block_pattern))return null;var i={};this.__directive_pattern.lastIndex=0;for(var o=this.__directive_pattern.exec(r);o;)i[o[1]]=o[2],o=this.__directive_pattern.exec(r);return i},c.prototype.readIgnored=function(r){return r.readUntilAfter(this.__directives_end_ignore_pattern)},n.exports.Directives=c},function(n,c,r){var i=r(12).Pattern,o={django:!1,erb:!1,handlebars:!1,php:!1,smarty:!1};function u(f,s){i.call(this,f,s),this.__template_pattern=null,this._disabled=Object.assign({},o),this._excluded=Object.assign({},o),s&&(this.__template_pattern=this._input.get_regexp(s.__template_pattern),this._excluded=Object.assign(this._excluded,s._excluded),this._disabled=Object.assign(this._disabled,s._disabled));var l=new i(f);this.__patterns={handlebars_comment:l.starting_with(/{{!--/).until_after(/--}}/),handlebars_unescaped:l.starting_with(/{{{/).until_after(/}}}/),handlebars:l.starting_with(/{{/).until_after(/}}/),php:l.starting_with(/<\?(?:[= ]|php)/).until_after(/\?>/),erb:l.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:l.starting_with(/{%/).until_after(/%}/),django_value:l.starting_with(/{{/).until_after(/}}/),django_comment:l.starting_with(/{#/).until_after(/#}/),smarty:l.starting_with(/{(?=[^}{\s\n])/).until_after(/[^\s\n]}/),smarty_comment:l.starting_with(/{\*/).until_after(/\*}/),smarty_literal:l.starting_with(/{literal}/).until_after(/{\/literal}/)}}u.prototype=new i,u.prototype._create=function(){return new u(this._input,this)},u.prototype._update=function(){this.__set_templated_pattern()},u.prototype.disable=function(f){var s=this._create();return s._disabled[f]=!0,s._update(),s},u.prototype.read_options=function(f){var s=this._create();for(var l in o)s._disabled[l]=f.templating.indexOf(l)===-1;return s._update(),s},u.prototype.exclude=function(f){var s=this._create();return s._excluded[f]=!0,s._update(),s},u.prototype.read=function(){var f="";this._match_pattern?f=this._input.read(this._starting_pattern):f=this._input.read(this._starting_pattern,this.__template_pattern);for(var s=this._read_template();s;)this._match_pattern?s+=this._input.read(this._match_pattern):s+=this._input.readUntil(this.__template_pattern),f+=s,s=this._read_template();return this._until_after&&(f+=this._input.readUntilAfter(this._until_pattern)),f},u.prototype.__set_templated_pattern=function(){var f=[];this._disabled.php||f.push(this.__patterns.php._starting_pattern.source),this._disabled.handlebars||f.push(this.__patterns.handlebars._starting_pattern.source),this._disabled.erb||f.push(this.__patterns.erb._starting_pattern.source),this._disabled.django||(f.push(this.__patterns.django._starting_pattern.source),f.push(this.__patterns.django_value._starting_pattern.source),f.push(this.__patterns.django_comment._starting_pattern.source)),this._disabled.smarty||f.push(this.__patterns.smarty._starting_pattern.source),this._until_pattern&&f.push(this._until_pattern.source),this.__template_pattern=this._input.get_regexp("(?:"+f.join("|")+")")},u.prototype._read_template=function(){var f="",s=this._input.peek();if(s==="<"){var l=this._input.peek(1);!this._disabled.php&&!this._excluded.php&&l==="?"&&(f=f||this.__patterns.php.read()),!this._disabled.erb&&!this._excluded.erb&&l==="%"&&(f=f||this.__patterns.erb.read())}else s==="{"&&(!this._disabled.handlebars&&!this._excluded.handlebars&&(f=f||this.__patterns.handlebars_comment.read(),f=f||this.__patterns.handlebars_unescaped.read(),f=f||this.__patterns.handlebars.read()),this._disabled.django||(!this._excluded.django&&!this._excluded.handlebars&&(f=f||this.__patterns.django_value.read()),this._excluded.django||(f=f||this.__patterns.django_comment.read(),f=f||this.__patterns.django.read())),this._disabled.smarty||this._disabled.django&&this._disabled.handlebars&&(f=f||this.__patterns.smarty_comment.read(),f=f||this.__patterns.smarty_literal.read(),f=f||this.__patterns.smarty.read()));return f},n.exports.TemplatablePattern=u},,,,function(n,c,r){var i=r(19).Beautifier,o=r(20).Options;function u(f,s,l,t){var S=new i(f,s,l,t);return S.beautify()}n.exports=u,n.exports.defaultOptions=function(){return new o}},function(n,c,r){var i=r(20).Options,o=r(2).Output,u=r(21).Tokenizer,f=r(21).TOKEN,s=/\r\n|[\r\n]/,l=/\r\n|[\r\n]/g,t=function(L,I){this.indent_level=0,this.alignment_size=0,this.max_preserve_newlines=L.max_preserve_newlines,this.preserve_newlines=L.preserve_newlines,this._output=new o(L,I)};t.prototype.current_line_has_match=function(L){return this._output.current_line.has_match(L)},t.prototype.set_space_before_token=function(L,I){this._output.space_before_token=L,this._output.non_breaking_space=I},t.prototype.set_wrap_point=function(){this._output.set_indent(this.indent_level,this.alignment_size),this._output.set_wrap_point()},t.prototype.add_raw_token=function(L){this._output.add_raw_token(L)},t.prototype.print_preserved_newlines=function(L){var I=0;L.type!==f.TEXT&&L.previous.type!==f.TEXT&&(I=L.newlines?1:0),this.preserve_newlines&&(I=L.newlines<this.max_preserve_newlines+1?L.newlines:this.max_preserve_newlines+1);for(var P=0;P<I;P++)this.print_newline(P>0);return I!==0},t.prototype.traverse_whitespace=function(L){return L.whitespace_before||L.newlines?(this.print_preserved_newlines(L)||(this._output.space_before_token=!0),!0):!1},t.prototype.previous_token_wrapped=function(){return this._output.previous_token_wrapped},t.prototype.print_newline=function(L){this._output.add_new_line(L)},t.prototype.print_token=function(L){L.text&&(this._output.set_indent(this.indent_level,this.alignment_size),this._output.add_token(L.text))},t.prototype.indent=function(){this.indent_level++},t.prototype.get_full_indent=function(L){return L=this.indent_level+(L||0),L<1?"":this._output.get_indent_string(L)};var S=function(L){for(var I=null,P=L.next;P.type!==f.EOF&&L.closed!==P;){if(P.type===f.ATTRIBUTE&&P.text==="type"){P.next&&P.next.type===f.EQUALS&&P.next.next&&P.next.next.type===f.VALUE&&(I=P.next.next.text);break}P=P.next}return I},x=function(L,I){var P=null,G=null;return I.closed?(L==="script"?P="text/javascript":L==="style"&&(P="text/css"),P=S(I)||P,P.search("text/css")>-1?G="css":P.search(/module|((text|application|dojo)\/(x-)?(javascript|ecmascript|jscript|livescript|(ld\+)?json|method|aspect))/)>-1?G="javascript":P.search(/(text|application|dojo)\/(x-)?(html)/)>-1?G="html":P.search(/test\/null/)>-1&&(G="null"),G):null};function h(L,I){return I.indexOf(L)!==-1}function R(L,I,P){this.parent=L||null,this.tag=I?I.tag_name:"",this.indent_level=P||0,this.parser_token=I||null}function O(L){this._printer=L,this._current_frame=null}O.prototype.get_parser_token=function(){return this._current_frame?this._current_frame.parser_token:null},O.prototype.record_tag=function(L){var I=new R(this._current_frame,L,this._printer.indent_level);this._current_frame=I},O.prototype._try_pop_frame=function(L){var I=null;return L&&(I=L.parser_token,this._printer.indent_level=L.indent_level,this._current_frame=L.parent),I},O.prototype._get_frame=function(L,I){for(var P=this._current_frame;P&&!(L.indexOf(P.tag)!==-1);){if(I&&I.indexOf(P.tag)!==-1){P=null;break}P=P.parent}return P},O.prototype.try_pop=function(L,I){var P=this._get_frame([L],I);return this._try_pop_frame(P)},O.prototype.indent_to_tag=function(L){var I=this._get_frame(L);I&&(this._printer.indent_level=I.indent_level)};function g(L,I,P,G){this._source_text=L||"",I=I||{},this._js_beautify=P,this._css_beautify=G,this._tag_stack=null;var W=new i(I,"html");this._options=W,this._is_wrap_attributes_force=this._options.wrap_attributes.substr(0,"force".length)==="force",this._is_wrap_attributes_force_expand_multiline=this._options.wrap_attributes==="force-expand-multiline",this._is_wrap_attributes_force_aligned=this._options.wrap_attributes==="force-aligned",this._is_wrap_attributes_aligned_multiple=this._options.wrap_attributes==="aligned-multiple",this._is_wrap_attributes_preserve=this._options.wrap_attributes.substr(0,"preserve".length)==="preserve",this._is_wrap_attributes_preserve_aligned=this._options.wrap_attributes==="preserve-aligned"}g.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var L=this._source_text,I=this._options.eol;this._options.eol==="auto"&&(I=`
`,L&&s.test(L)&&(I=L.match(s)[0])),L=L.replace(l,`
`);var P=L.match(/^[\t ]*/)[0],G={text:"",type:""},W=new _,H=new t(this._options,P),z=new u(L,this._options).tokenize();this._tag_stack=new O(H);for(var B=null,k=z.next();k.type!==f.EOF;)k.type===f.TAG_OPEN||k.type===f.COMMENT?(B=this._handle_tag_open(H,k,W,G),W=B):k.type===f.ATTRIBUTE||k.type===f.EQUALS||k.type===f.VALUE||k.type===f.TEXT&&!W.tag_complete?B=this._handle_inside_tag(H,k,W,z):k.type===f.TAG_CLOSE?B=this._handle_tag_close(H,k,W):k.type===f.TEXT?B=this._handle_text(H,k,W):H.add_raw_token(k),G=B,k=z.next();var K=H._output.get_code(I);return K},g.prototype._handle_tag_close=function(L,I,P){var G={text:I.text,type:I.type};return L.alignment_size=0,P.tag_complete=!0,L.set_space_before_token(I.newlines||I.whitespace_before!=="",!0),P.is_unformatted?L.add_raw_token(I):(P.tag_start_char==="<"&&(L.set_space_before_token(I.text[0]==="/",!0),this._is_wrap_attributes_force_expand_multiline&&P.has_wrapped_attrs&&L.print_newline(!1)),L.print_token(I)),P.indent_content&&!(P.is_unformatted||P.is_content_unformatted)&&(L.indent(),P.indent_content=!1),!P.is_inline_element&&!(P.is_unformatted||P.is_content_unformatted)&&L.set_wrap_point(),G},g.prototype._handle_inside_tag=function(L,I,P,G){var W=P.has_wrapped_attrs,H={text:I.text,type:I.type};if(L.set_space_before_token(I.newlines||I.whitespace_before!=="",!0),P.is_unformatted)L.add_raw_token(I);else if(P.tag_start_char==="{"&&I.type===f.TEXT)L.print_preserved_newlines(I)?(I.newlines=0,L.add_raw_token(I)):L.print_token(I);else{if(I.type===f.ATTRIBUTE?(L.set_space_before_token(!0),P.attr_count+=1):(I.type===f.EQUALS||I.type===f.VALUE&&I.previous.type===f.EQUALS)&&L.set_space_before_token(!1),I.type===f.ATTRIBUTE&&P.tag_start_char==="<"&&((this._is_wrap_attributes_preserve||this._is_wrap_attributes_preserve_aligned)&&(L.traverse_whitespace(I),W=W||I.newlines!==0),this._is_wrap_attributes_force)){var z=P.attr_count>1;if(this._is_wrap_attributes_force_expand_multiline&&P.attr_count===1){var B=!0,k=0,K;do{if(K=G.peek(k),K.type===f.ATTRIBUTE){B=!1;break}k+=1}while(k<4&&K.type!==f.EOF&&K.type!==f.TAG_CLOSE);z=!B}z&&(L.print_newline(!1),W=!0)}L.print_token(I),W=W||L.previous_token_wrapped(),P.has_wrapped_attrs=W}return H},g.prototype._handle_text=function(L,I,P){var G={text:I.text,type:"TK_CONTENT"};return P.custom_beautifier_name?this._print_custom_beatifier_text(L,I,P):P.is_unformatted||P.is_content_unformatted?L.add_raw_token(I):(L.traverse_whitespace(I),L.print_token(I)),G},g.prototype._print_custom_beatifier_text=function(L,I,P){var G=this;if(I.text!==""){var W=I.text,H,z=1,B="",k="";P.custom_beautifier_name==="javascript"&&typeof this._js_beautify=="function"?H=this._js_beautify:P.custom_beautifier_name==="css"&&typeof this._css_beautify=="function"?H=this._css_beautify:P.custom_beautifier_name==="html"&&(H=function(xe,le){var me=new g(xe,le,G._js_beautify,G._css_beautify);return me.beautify()}),this._options.indent_scripts==="keep"?z=0:this._options.indent_scripts==="separate"&&(z=-L.indent_level);var K=L.get_full_indent(z);if(W=W.replace(/\n[ \t]*$/,""),P.custom_beautifier_name!=="html"&&W[0]==="<"&&W.match(/^(<!--|<!\[CDATA\[)/)){var Y=/^(<!--[^\n]*|<!\[CDATA\[)(\n?)([ \t\n]*)([\s\S]*)(-->|]]>)$/.exec(W);if(!Y){L.add_raw_token(I);return}B=K+Y[1]+`
`,W=Y[4],Y[5]&&(k=K+Y[5]),W=W.replace(/\n[ \t]*$/,""),(Y[2]||Y[3].indexOf(`
`)!==-1)&&(Y=Y[3].match(/[ \t]+$/),Y&&(I.whitespace_before=Y[0]))}if(W)if(H){var ne=function(){this.eol=`
`};ne.prototype=this._options.raw_options;var oe=new ne;W=H(K+W,oe)}else{var _e=I.whitespace_before;_e&&(W=W.replace(new RegExp(`
(`+_e+")?","g"),`
`)),W=K+W.replace(/\n/g,`
`+K)}B&&(W?W=B+W+`
`+k:W=B+k),L.print_newline(!1),W&&(I.text=W,I.whitespace_before="",I.newlines=0,L.add_raw_token(I),L.print_newline(!0))}},g.prototype._handle_tag_open=function(L,I,P,G){var W=this._get_tag_open_token(I);return(P.is_unformatted||P.is_content_unformatted)&&!P.is_empty_element&&I.type===f.TAG_OPEN&&I.text.indexOf("</")===0?(L.add_raw_token(I),W.start_tag_token=this._tag_stack.try_pop(W.tag_name)):(L.traverse_whitespace(I),this._set_tag_position(L,I,W,P,G),W.is_inline_element||L.set_wrap_point(),L.print_token(I)),(this._is_wrap_attributes_force_aligned||this._is_wrap_attributes_aligned_multiple||this._is_wrap_attributes_preserve_aligned)&&(W.alignment_size=I.text.length+1),!W.tag_complete&&!W.is_unformatted&&(L.alignment_size=W.alignment_size),W};var _=function(L,I){if(this.parent=L||null,this.text="",this.type="TK_TAG_OPEN",this.tag_name="",this.is_inline_element=!1,this.is_unformatted=!1,this.is_content_unformatted=!1,this.is_empty_element=!1,this.is_start_tag=!1,this.is_end_tag=!1,this.indent_content=!1,this.multiline_content=!1,this.custom_beautifier_name=null,this.start_tag_token=null,this.attr_count=0,this.has_wrapped_attrs=!1,this.alignment_size=0,this.tag_complete=!1,this.tag_start_char="",this.tag_check="",!I)this.tag_complete=!0;else{var P;this.tag_start_char=I.text[0],this.text=I.text,this.tag_start_char==="<"?(P=I.text.match(/^<([^\s>]*)/),this.tag_check=P?P[1]:""):(P=I.text.match(/^{{~?(?:[\^]|#\*?)?([^\s}]+)/),this.tag_check=P?P[1]:"",(I.text.startsWith("{{#>")||I.text.startsWith("{{~#>"))&&this.tag_check[0]===">"&&(this.tag_check===">"&&I.next!==null?this.tag_check=I.next.text.split(" ")[0]:this.tag_check=I.text.split(">")[1])),this.tag_check=this.tag_check.toLowerCase(),I.type===f.COMMENT&&(this.tag_complete=!0),this.is_start_tag=this.tag_check.charAt(0)!=="/",this.tag_name=this.is_start_tag?this.tag_check:this.tag_check.substr(1),this.is_end_tag=!this.is_start_tag||I.closed&&I.closed.text==="/>";var G=2;this.tag_start_char==="{"&&this.text.length>=3&&(this.text.charAt(2)==="~"&&(G=3)),this.is_end_tag=this.is_end_tag||this.tag_start_char==="{"&&(this.text.length<3||/[^#\^]/.test(this.text.charAt(G)))}};g.prototype._get_tag_open_token=function(L){var I=new _(this._tag_stack.get_parser_token(),L);return I.alignment_size=this._options.wrap_attributes_indent_size,I.is_end_tag=I.is_end_tag||h(I.tag_check,this._options.void_elements),I.is_empty_element=I.tag_complete||I.is_start_tag&&I.is_end_tag,I.is_unformatted=!I.tag_complete&&h(I.tag_check,this._options.unformatted),I.is_content_unformatted=!I.is_empty_element&&h(I.tag_check,this._options.content_unformatted),I.is_inline_element=h(I.tag_name,this._options.inline)||I.tag_name.includes("-")||I.tag_start_char==="{",I},g.prototype._set_tag_position=function(L,I,P,G,W){if(P.is_empty_element||(P.is_end_tag?P.start_tag_token=this._tag_stack.try_pop(P.tag_name):(this._do_optional_end_element(P)&&(P.is_inline_element||L.print_newline(!1)),this._tag_stack.record_tag(P),(P.tag_name==="script"||P.tag_name==="style")&&!(P.is_unformatted||P.is_content_unformatted)&&(P.custom_beautifier_name=x(P.tag_check,I)))),h(P.tag_check,this._options.extra_liners)&&(L.print_newline(!1),L._output.just_added_blankline()||L.print_newline(!0)),P.is_empty_element){if(P.tag_start_char==="{"&&P.tag_check==="else"){this._tag_stack.indent_to_tag(["if","unless","each"]),P.indent_content=!0;var H=L.current_line_has_match(/{{#if/);H||L.print_newline(!1)}P.tag_name==="!--"&&W.type===f.TAG_CLOSE&&G.is_end_tag&&P.text.indexOf(`
`)===-1||(P.is_inline_element||P.is_unformatted||L.print_newline(!1),this._calcluate_parent_multiline(L,P))}else if(P.is_end_tag){var z=!1;z=P.start_tag_token&&P.start_tag_token.multiline_content,z=z||!P.is_inline_element&&!(G.is_inline_element||G.is_unformatted)&&!(W.type===f.TAG_CLOSE&&P.start_tag_token===G)&&W.type!=="TK_CONTENT",(P.is_content_unformatted||P.is_unformatted)&&(z=!1),z&&L.print_newline(!1)}else P.indent_content=!P.custom_beautifier_name,P.tag_start_char==="<"&&(P.tag_name==="html"?P.indent_content=this._options.indent_inner_html:P.tag_name==="head"?P.indent_content=this._options.indent_head_inner_html:P.tag_name==="body"&&(P.indent_content=this._options.indent_body_inner_html)),!(P.is_inline_element||P.is_unformatted)&&(W.type!=="TK_CONTENT"||P.is_content_unformatted)&&L.print_newline(!1),this._calcluate_parent_multiline(L,P)},g.prototype._calcluate_parent_multiline=function(L,I){I.parent&&L._output.just_added_newline()&&!((I.is_inline_element||I.is_unformatted)&&I.parent.is_inline_element)&&(I.parent.multiline_content=!0)};var E=["address","article","aside","blockquote","details","div","dl","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hr","main","nav","ol","p","pre","section","table","ul"],T=["a","audio","del","ins","map","noscript","video"];g.prototype._do_optional_end_element=function(L){var I=null;if(L.is_empty_element||!L.is_start_tag||!L.parent)return;if(L.tag_name==="body")I=I||this._tag_stack.try_pop("head");else if(L.tag_name==="li")I=I||this._tag_stack.try_pop("li",["ol","ul"]);else if(L.tag_name==="dd"||L.tag_name==="dt")I=I||this._tag_stack.try_pop("dt",["dl"]),I=I||this._tag_stack.try_pop("dd",["dl"]);else if(L.parent.tag_name==="p"&&E.indexOf(L.tag_name)!==-1){var P=L.parent.parent;(!P||T.indexOf(P.tag_name)===-1)&&(I=I||this._tag_stack.try_pop("p"))}else L.tag_name==="rp"||L.tag_name==="rt"?(I=I||this._tag_stack.try_pop("rt",["ruby","rtc"]),I=I||this._tag_stack.try_pop("rp",["ruby","rtc"])):L.tag_name==="optgroup"?I=I||this._tag_stack.try_pop("optgroup",["select"]):L.tag_name==="option"?I=I||this._tag_stack.try_pop("option",["select","datalist","optgroup"]):L.tag_name==="colgroup"?I=I||this._tag_stack.try_pop("caption",["table"]):L.tag_name==="thead"?(I=I||this._tag_stack.try_pop("caption",["table"]),I=I||this._tag_stack.try_pop("colgroup",["table"])):L.tag_name==="tbody"||L.tag_name==="tfoot"?(I=I||this._tag_stack.try_pop("caption",["table"]),I=I||this._tag_stack.try_pop("colgroup",["table"]),I=I||this._tag_stack.try_pop("thead",["table"]),I=I||this._tag_stack.try_pop("tbody",["table"])):L.tag_name==="tr"?(I=I||this._tag_stack.try_pop("caption",["table"]),I=I||this._tag_stack.try_pop("colgroup",["table"]),I=I||this._tag_stack.try_pop("tr",["table","thead","tbody","tfoot"])):(L.tag_name==="th"||L.tag_name==="td")&&(I=I||this._tag_stack.try_pop("td",["table","thead","tbody","tfoot","tr"]),I=I||this._tag_stack.try_pop("th",["table","thead","tbody","tfoot","tr"]));return L.parent=this._tag_stack.get_parser_token(),I},n.exports.Beautifier=g},function(n,c,r){var i=r(6).Options;function o(u){i.call(this,u,"html"),this.templating.length===1&&this.templating[0]==="auto"&&(this.templating=["django","erb","handlebars","php"]),this.indent_inner_html=this._get_boolean("indent_inner_html"),this.indent_body_inner_html=this._get_boolean("indent_body_inner_html",!0),this.indent_head_inner_html=this._get_boolean("indent_head_inner_html",!0),this.indent_handlebars=this._get_boolean("indent_handlebars",!0),this.wrap_attributes=this._get_selection("wrap_attributes",["auto","force","force-aligned","force-expand-multiline","aligned-multiple","preserve","preserve-aligned"]),this.wrap_attributes_indent_size=this._get_number("wrap_attributes_indent_size",this.indent_size),this.extra_liners=this._get_array("extra_liners",["head","body","/html"]),this.inline=this._get_array("inline",["a","abbr","area","audio","b","bdi","bdo","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","keygen","label","map","mark","math","meter","noscript","object","output","progress","q","ruby","s","samp","select","small","span","strong","sub","sup","svg","template","textarea","time","u","var","video","wbr","text","acronym","big","strike","tt"]),this.void_elements=this._get_array("void_elements",["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr","!doctype","?xml","basefont","isindex"]),this.unformatted=this._get_array("unformatted",[]),this.content_unformatted=this._get_array("content_unformatted",["pre","textarea"]),this.unformatted_content_delimiter=this._get_characters("unformatted_content_delimiter"),this.indent_scripts=this._get_selection("indent_scripts",["normal","keep","separate"])}o.prototype=new i,n.exports.Options=o},function(n,c,r){var i=r(9).Tokenizer,o=r(9).TOKEN,u=r(13).Directives,f=r(14).TemplatablePattern,s=r(12).Pattern,l={TAG_OPEN:"TK_TAG_OPEN",TAG_CLOSE:"TK_TAG_CLOSE",ATTRIBUTE:"TK_ATTRIBUTE",EQUALS:"TK_EQUALS",VALUE:"TK_VALUE",COMMENT:"TK_COMMENT",TEXT:"TK_TEXT",UNKNOWN:"TK_UNKNOWN",START:o.START,RAW:o.RAW,EOF:o.EOF},t=new u(/<\!--/,/-->/),S=function(x,h){i.call(this,x,h),this._current_tag_name="";var R=new f(this._input).read_options(this._options),O=new s(this._input);if(this.__patterns={word:R.until(/[\n\r\t <]/),single_quote:R.until_after(/'/),double_quote:R.until_after(/"/),attribute:R.until(/[\n\r\t =>]|\/>/),element_name:R.until(/[\n\r\t >\/]/),handlebars_comment:O.starting_with(/{{!--/).until_after(/--}}/),handlebars:O.starting_with(/{{/).until_after(/}}/),handlebars_open:O.until(/[\n\r\t }]/),handlebars_raw_close:O.until(/}}/),comment:O.starting_with(/<!--/).until_after(/-->/),cdata:O.starting_with(/<!\[CDATA\[/).until_after(/]]>/),conditional_comment:O.starting_with(/<!\[/).until_after(/]>/),processing:O.starting_with(/<\?/).until_after(/\?>/)},this._options.indent_handlebars&&(this.__patterns.word=this.__patterns.word.exclude("handlebars")),this._unformatted_content_delimiter=null,this._options.unformatted_content_delimiter){var g=this._input.get_literal_regexp(this._options.unformatted_content_delimiter);this.__patterns.unformatted_content_delimiter=O.matching(g).until_after(g)}};S.prototype=new i,S.prototype._is_comment=function(x){return!1},S.prototype._is_opening=function(x){return x.type===l.TAG_OPEN},S.prototype._is_closing=function(x,h){return x.type===l.TAG_CLOSE&&h&&((x.text===">"||x.text==="/>")&&h.text[0]==="<"||x.text==="}}"&&h.text[0]==="{"&&h.text[1]==="{")},S.prototype._reset=function(){this._current_tag_name=""},S.prototype._get_next_token=function(x,h){var R=null;this._readWhitespace();var O=this._input.peek();return O===null?this._create_token(l.EOF,""):(R=R||this._read_open_handlebars(O,h),R=R||this._read_attribute(O,x,h),R=R||this._read_close(O,h),R=R||this._read_raw_content(O,x,h),R=R||this._read_content_word(O),R=R||this._read_comment_or_cdata(O),R=R||this._read_processing(O),R=R||this._read_open(O,h),R=R||this._create_token(l.UNKNOWN,this._input.next()),R)},S.prototype._read_comment_or_cdata=function(x){var h=null,R=null,O=null;if(x==="<"){var g=this._input.peek(1);g==="!"&&(R=this.__patterns.comment.read(),R?(O=t.get_directives(R),O&&O.ignore==="start"&&(R+=t.readIgnored(this._input))):R=this.__patterns.cdata.read()),R&&(h=this._create_token(l.COMMENT,R),h.directives=O)}return h},S.prototype._read_processing=function(x){var h=null,R=null,O=null;if(x==="<"){var g=this._input.peek(1);(g==="!"||g==="?")&&(R=this.__patterns.conditional_comment.read(),R=R||this.__patterns.processing.read()),R&&(h=this._create_token(l.COMMENT,R),h.directives=O)}return h},S.prototype._read_open=function(x,h){var R=null,O=null;return h||x==="<"&&(R=this._input.next(),this._input.peek()==="/"&&(R+=this._input.next()),R+=this.__patterns.element_name.read(),O=this._create_token(l.TAG_OPEN,R)),O},S.prototype._read_open_handlebars=function(x,h){var R=null,O=null;return h||this._options.indent_handlebars&&x==="{"&&this._input.peek(1)==="{"&&(this._input.peek(2)==="!"?(R=this.__patterns.handlebars_comment.read(),R=R||this.__patterns.handlebars.read(),O=this._create_token(l.COMMENT,R)):(R=this.__patterns.handlebars_open.read(),O=this._create_token(l.TAG_OPEN,R))),O},S.prototype._read_close=function(x,h){var R=null,O=null;return h&&(h.text[0]==="<"&&(x===">"||x==="/"&&this._input.peek(1)===">")?(R=this._input.next(),x==="/"&&(R+=this._input.next()),O=this._create_token(l.TAG_CLOSE,R)):h.text[0]==="{"&&x==="}"&&this._input.peek(1)==="}"&&(this._input.next(),this._input.next(),O=this._create_token(l.TAG_CLOSE,"}}"))),O},S.prototype._read_attribute=function(x,h,R){var O=null,g="";if(R&&R.text[0]==="<")if(x==="=")O=this._create_token(l.EQUALS,this._input.next());else if(x==='"'||x==="'"){var _=this._input.next();x==='"'?_+=this.__patterns.double_quote.read():_+=this.__patterns.single_quote.read(),O=this._create_token(l.VALUE,_)}else g=this.__patterns.attribute.read(),g&&(h.type===l.EQUALS?O=this._create_token(l.VALUE,g):O=this._create_token(l.ATTRIBUTE,g));return O},S.prototype._is_content_unformatted=function(x){return this._options.void_elements.indexOf(x)===-1&&(this._options.content_unformatted.indexOf(x)!==-1||this._options.unformatted.indexOf(x)!==-1)},S.prototype._read_raw_content=function(x,h,R){var O="";if(R&&R.text[0]==="{")O=this.__patterns.handlebars_raw_close.read();else if(h.type===l.TAG_CLOSE&&h.opened.text[0]==="<"&&h.text[0]!=="/"){var g=h.opened.text.substr(1).toLowerCase();if(g==="script"||g==="style"){var _=this._read_comment_or_cdata(x);if(_)return _.type=l.TEXT,_;O=this._input.readUntil(new RegExp("</"+g+"[\\n\\r\\t ]*?>","ig"))}else this._is_content_unformatted(g)&&(O=this._input.readUntil(new RegExp("</"+g+"[\\n\\r\\t ]*?>","ig")))}return O?this._create_token(l.TEXT,O):null},S.prototype._read_content_word=function(x){var h="";if(this._options.unformatted_content_delimiter&&(x===this._options.unformatted_content_delimiter[0]&&(h=this.__patterns.unformatted_content_delimiter.read())),h||(h=this.__patterns.word.read()),h)return this._create_token(l.TEXT,h)},n.exports.Tokenizer=S,n.exports.TOKEN=l}],b={};function p(n){var c=b[n];if(c!==void 0)return c.exports;var r=b[n]={exports:{}};return w[n](r,r.exports,p),r.exports}var d=p(18);C=d})();var M=C;if(!0)!(N=[j,j("6UM0"),j("TXwP")],v=function(w){var b=j("6UM0"),p=j("TXwP");return{html_beautify:function(d,n){return M(d,n,b.js_beautify,p.css_beautify)}}}.apply(Q,N),v!==void 0&&(F.exports=v));else var m,y})()},qBft:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.pad.AnsiX923={pad:function(v,C){var M=v.sigBytes,m=C*4,y=m-M%m,w=M+y-1;v.clamp(),v.words[w>>>2]|=y<<24-w%4*8,v.sigBytes+=y},unpad:function(v){var C=v.words[v.sigBytes-1>>>2]&255;v.sigBytes-=C}},N.pad.Ansix923})},qHvr:function(F,Q,j){"use strict";var N=j("2qtc"),v=j("kLXV"),C=j("5NDa"),M=j("5rEg"),m=j("miYZ"),y=j("tsqr"),w=j("tJVT"),b=j("cDcd"),p=j.n(b),d=j("4i/N");function n(c){var r=c.isAddmodle,i=c.setIsAdd,o=c.createTeam,u=Object(b.useState)(""),f=Object(w.a)(u,2),s=f[0],l=f[1];return p.a.createElement(v.a,{centered:!0,title:p.a.createElement("div",{style:{alignItems:"center",display:"flex"}},p.a.createElement("div",{style:{textAlign:"left",flex:"1"}},"\u521B\u5EFA\u6218\u961F"),p.a.createElement(d.a,{onClick:function(){return i(!1)},style:{cursor:"porint"}})),visible:r,closable:!1,destroyOnClose:!0,onOk:function(){if(!s){y.b.info("\u6218\u961F\u540D\u4E0D\u80FD\u4E3A\u7A7A");return}o(s)},onCancel:function(){return i(!1)}},p.a.createElement("div",null,p.a.createElement("span",{style:{fontSize:"14px",color:"#F73737"}},"*"),"\u961F\u540D\uFF1A",p.a.createElement("p",{style:{marginTop:"15px",marginLeft:"15px"}},p.a.createElement(M.a,{placeholder:"\u8BF7\u8F93\u5165\u961F\u540D",value:s,maxLength:60,addonAfter:String(s&&s.length||0)+"/60",onChange:function(S){return l(S.target.value)}}))))}Q.a=n},qM6L:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.WordArray,m=v.enc,y=m.Utf16=m.Utf16BE={stringify:function(b){for(var p=b.words,d=b.sigBytes,n=[],c=0;c<d;c+=2){var r=p[c>>>2]>>>16-c%4*8&65535;n.push(String.fromCharCode(r))}return n.join("")},parse:function(b){for(var p=b.length,d=[],n=0;n<p;n++)d[n>>>1]|=b.charCodeAt(n)<<16-n%2*16;return M.create(d,p*2)}};m.Utf16LE={stringify:function(b){for(var p=b.words,d=b.sigBytes,n=[],c=0;c<d;c+=2){var r=w(p[c>>>2]>>>16-c%4*8&65535);n.push(String.fromCharCode(r))}return n.join("")},parse:function(b){for(var p=b.length,d=[],n=0;n<p;n++)d[n>>>1]|=w(b.charCodeAt(n)<<16-n%2*16);return M.create(d,p*2)}};function w(b){return b<<8&4278255360|b>>>8&16711935}}(),N.enc.Utf16})},qu8F:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){/** @preserve
* Counter block mode compatible with Dr Brian Gladman fileenc.c
* derived from CryptoJS.mode.CTR
* Jan Hruby jhruby.web@gmail.com
*/return N.mode.CTRGladman=function(){var v=N.lib.BlockCipherMode.extend();function C(y){if((y>>24&255)===255){var w=y>>16&255,b=y>>8&255,p=y&255;w===255?(w=0,b===255?(b=0,p===255?p=0:++p):++b):++w,y=0,y+=w<<16,y+=b<<8,y+=p}else y+=1<<24;return y}function M(y){return(y[0]=C(y[0]))===0&&(y[1]=C(y[1])),y}var m=v.Encryptor=v.extend({processBlock:function(y,w){var b=this._cipher,p=b.blockSize,d=this._iv,n=this._counter;d&&(n=this._counter=d.slice(0),this._iv=void 0),M(n);var c=n.slice(0);b.encryptBlock(c,0);for(var r=0;r<p;r++)y[w+r]^=c[r]}});return v.Decryptor=m,v}(),N.mode.CTRGladman})},"rAM+":function(F,Q,j){"use strict";j.d(Q,"a",function(){return v});var N=j("Qw5x");function v(C,M){var m;if(typeof Symbol=="undefined"||C[Symbol.iterator]==null){if(Array.isArray(C)||(m=Object(N.a)(C))||M&&C&&typeof C.length=="number"){m&&(C=m);var y=0,w=function(){};return{s:w,n:function(){return y>=C.length?{done:!0}:{done:!1,value:C[y++]}},e:function(c){throw c},f:w}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var b=!0,p=!1,d;return{s:function(){m=C[Symbol.iterator]()},n:function(){var c=m.next();return b=c.done,c},e:function(c){p=!0,d=c},f:function(){try{!b&&m.return!=null&&m.return()}finally{if(p)throw d}}}}},rUJ1:function(F,Q){const j=/[&<>"']/,N=/[&<>"']/g,v=/[<>"']|&(?!#?\w+;)/,C=/[<>"']|&(?!#?\w+;)/g,M={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},m=O=>M[O];function y(O,g){if(g){if(j.test(O))return O.replace(N,m)}else if(v.test(O))return O.replace(C,m);return O}const w=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function b(O){return O.replace(w,(g,_)=>(_=_.toLowerCase(),_==="colon"?":":_.charAt(0)==="#"?_.charAt(1)==="x"?String.fromCharCode(parseInt(_.substring(2),16)):String.fromCharCode(+_.substring(1)):""))}const p=/(^|[^\[])\^/g;function d(O,g){O=O.source||O,g=g||"";const _={replace:(E,T)=>(T=T.source||T,T=T.replace(p,"$1"),O=O.replace(E,T),_),getRegex:()=>new RegExp(O,g)};return _}const n=/[^\w:]/g,c=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function r(O,g,_){if(O){let E;try{E=decodeURIComponent(b(_)).replace(n,"").toLowerCase()}catch(T){return null}if(E.indexOf("javascript:")===0||E.indexOf("vbscript:")===0||E.indexOf("data:")===0)return null}g&&!c.test(_)&&(_=s(g,_));try{_=encodeURI(_).replace(/%25/g,"%")}catch(E){return null}return _}const i={},o=/^[^:]+:\/*[^/]*$/,u=/^([^:]+:)[\s\S]*$/,f=/^([^:]+:\/*[^/]*)[\s\S]*$/;function s(O,g){i[" "+O]||(o.test(O)?i[" "+O]=O+"/":i[" "+O]=x(O,"/",!0)),O=i[" "+O];const _=O.indexOf(":")===-1;return g.substring(0,2)==="//"?_?g:O.replace(u,"$1")+g:g.charAt(0)==="/"?_?g:O.replace(f,"$1")+g:O+g}const l={exec:function(){}};function t(O){let g=1,_,E;for(;g<arguments.length;g++){_=arguments[g];for(E in _)Object.prototype.hasOwnProperty.call(_,E)&&(O[E]=_[E])}return O}function S(O,g){const _=O.replace(/\|/g,(L,I,P)=>{let G=!1,W=I;for(;--W>=0&&P[W]==="\\";)G=!G;return G?"|":" |"}),E=_.split(/ \|/);let T=0;if(E.length>g)E.splice(g);else for(;E.length<g;)E.push("");for(;T<E.length;T++)E[T]=E[T].trim().replace(/\\\|/g,"|");return E}function x(O,g,_){const E=O.length;if(E===0)return"";let T=0;for(;T<E;){const L=O.charAt(E-T-1);if(L===g&&!_)T++;else if(L!==g&&_)T++;else break}return O.substr(0,E-T)}function h(O,g){if(O.indexOf(g[1])===-1)return-1;const _=O.length;let E=0,T=0;for(;T<_;T++)if(O[T]==="\\")T++;else if(O[T]===g[0])E++;else if(O[T]===g[1]&&(E--,E<0))return T;return-1}function R(O){O&&O.sanitize&&!O.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}F.exports={escape:y,unescape:b,edit:d,cleanUrl:r,resolveUrl:s,noopTest:l,merge:t,splitCells:S,rtrim:x,findClosingBracket:h,checkSanitizeDeprecation:R}},sR1s:function(F,Q,j){"use strict";j.d(Q,"b",function(){return M}),j.d(Q,"a",function(){return m}),j.d(Q,"c",function(){return y}),j.d(Q,"d",function(){return w});var N=j("U8pU"),v="RC_TABLE_KEY";function C(b){return b==null?[]:Array.isArray(b)?b:[b]}function M(b,p){if(!p&&typeof p!="number")return b;for(var d=C(p),n=b,c=0;c<d.length;c+=1){if(!n)return null;var r=d[c];n=n[r]}return n}function m(b){var p=[],d={};return b.forEach(function(n){for(var c=n||{},r=c.key,i=c.dataIndex,o=r||C(i).join("-")||v;d[o];)o="".concat(o,"_next");d[o]=!0,p.push(o)}),p}function y(){var b={};function p(r,i){i&&Object.keys(i).forEach(function(o){var u=i[o];u&&Object(N.a)(u)==="object"?(r[o]=r[o]||{},p(r[o],u)):r[o]=u})}for(var d=arguments.length,n=new Array(d),c=0;c<d;c++)n[c]=arguments[c];return n.forEach(function(r){p(b,r)}),b}function w(b){return b!=null}},sboe:function(F,Q,j){"use strict";j.d(Q,"a",function(){return C});var N=j("cDcd"),v=j.n(N),C=N.createContext(null)},t23M:function(F,Q,j){"use strict";var N=j("VTBJ"),v=j("1OyB"),C=j("vuIU"),M=j("Ji7U"),m=j("LK+K"),y=j("cDcd"),w=j.n(y),b=j("m+aA"),p=j("Zm9Q"),d=j("Kwbf"),n=j("c+Xe"),c=j("bdgK"),r="rc-observer-key",i=function(o){Object(M.a)(f,o);var u=Object(m.a)(f);function f(){var s;return Object(v.a)(this,f),s=u.apply(this,arguments),s.resizeObserver=null,s.childNode=null,s.currentElement=null,s.state={width:0,height:0,offsetHeight:0,offsetWidth:0},s.onResize=function(l){var t=s.props.onResize,S=l[0].target,x=S.getBoundingClientRect(),h=x.width,R=x.height,O=S.offsetWidth,g=S.offsetHeight,_=Math.floor(h),E=Math.floor(R);if(s.state.width!==_||s.state.height!==E||s.state.offsetWidth!==O||s.state.offsetHeight!==g){var T={width:_,height:E,offsetWidth:O,offsetHeight:g};s.setState(T),t&&Promise.resolve().then(function(){t(Object(N.a)(Object(N.a)({},T),{},{offsetWidth:O,offsetHeight:g}))})}},s.setChildNode=function(l){s.childNode=l},s}return Object(C.a)(f,[{key:"componentDidMount",value:function(){this.onComponentUpdated()}},{key:"componentDidUpdate",value:function(){this.onComponentUpdated()}},{key:"componentWillUnmount",value:function(){this.destroyObserver()}},{key:"onComponentUpdated",value:function(){var l=this.props.disabled;if(l){this.destroyObserver();return}var t=Object(b.a)(this.childNode||this),S=t!==this.currentElement;S&&(this.destroyObserver(),this.currentElement=t),!this.resizeObserver&&t&&(this.resizeObserver=new c.default(this.onResize),this.resizeObserver.observe(t))}},{key:"destroyObserver",value:function(){this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=null)}},{key:"render",value:function(){var l=this.props.children,t=Object(p.a)(l);if(t.length>1)Object(d.a)(!1,"Find more than one child node with `children` in ResizeObserver. Will only observe first one.");else if(t.length===0)return Object(d.a)(!1,"`children` of ResizeObserver is empty. Nothing is in observe."),null;var S=t[0];if(y.isValidElement(S)&&Object(n.c)(S)){var x=S.ref;t[0]=y.cloneElement(S,{ref:Object(n.a)(x,this.setChildNode)})}return t.length===1?t[0]:t.map(function(h,R){return!y.isValidElement(h)||"key"in h&&h.key!==null?h:y.cloneElement(h,{key:"".concat(r,"-").concat(R)})})}}]),f}(y.Component);i.displayName="ResizeObserver",Q.a=i},uGsb:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("MlIO"),j("1uat"))})(this,function(N){return function(){var v=N,C=v.x64,M=C.Word,m=C.WordArray,y=v.algo,w=y.SHA512,b=y.SHA384=w.extend({_doReset:function(){this._hash=new m.init([new M.init(3418070365,3238371032),new M.init(1654270250,914150663),new M.init(2438529370,812702999),new M.init(355462360,4144912697),new M.init(1731405415,4290775857),new M.init(2394180231,1750603025),new M.init(3675008525,1694076839),new M.init(1203062813,3204075428)])},_doFinalize:function(){var p=w._doFinalize.call(this);return p.sigBytes-=16,p}});v.SHA384=w._createHelper(b),v.HmacSHA384=w._createHmacHelper(b)}(),N.SHA384})},uGxW:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("OLod"))})(this,function(N){return N.pad.NoPadding={pad:function(){},unpad:function(){}},N.pad.NoPadding})},uK0f:function(F,Q,j){(function(N,v){F.exports=v()})(this,function(){"use strict";function N(v,C,M){M=M||{},M.childrenKeyName=M.childrenKeyName||"children";var m=v||[],y=[],w=0;do{var b=m.filter(function(p){return C(p,w)})[0];if(!b)break;y.push(b),m=b[M.childrenKeyName]||[],w+=1}while(m.length>0);return y}return N})},ulZh:function(F,Q,j){typeof window!="undefined"&&function(v,C){F.exports=C()}(this,function(){return function(N){var v={};function C(M){if(v[M])return v[M].exports;var m=v[M]={i:M,l:!1,exports:{}};return N[M].call(m.exports,m,m.exports,C),m.l=!0,m.exports}return C.m=N,C.c=v,C.d=function(M,m,y){C.o(M,m)||Object.defineProperty(M,m,{enumerable:!0,get:y})},C.r=function(M){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(M,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(M,"__esModule",{value:!0})},C.t=function(M,m){if(m&1&&(M=C(M)),m&8)return M;if(m&4&&typeof M=="object"&&M&&M.__esModule)return M;var y=Object.create(null);if(C.r(y),Object.defineProperty(y,"default",{enumerable:!0,value:M}),m&2&&typeof M!="string")for(var w in M)C.d(y,w,function(b){return M[b]}.bind(null,w));return y},C.n=function(M){var m=M&&M.__esModule?function(){return M.default}:function(){return M};return C.d(m,"a",m),m},C.o=function(M,m){return Object.prototype.hasOwnProperty.call(M,m)},C.p="/dist/",C(C.s="./src/hls.ts")}({"./node_modules/eventemitter3/index.js":function(N,v,C){"use strict";var M=Object.prototype.hasOwnProperty,m="~";function y(){}Object.create&&(y.prototype=Object.create(null),new y().__proto__||(m=!1));function w(n,c,r){this.fn=n,this.context=c,this.once=r||!1}function b(n,c,r,i,o){if(typeof r!="function")throw new TypeError("The listener must be a function");var u=new w(r,i||n,o),f=m?m+c:c;return n._events[f]?n._events[f].fn?n._events[f]=[n._events[f],u]:n._events[f].push(u):(n._events[f]=u,n._eventsCount++),n}function p(n,c){--n._eventsCount===0?n._events=new y:delete n._events[c]}function d(){this._events=new y,this._eventsCount=0}d.prototype.eventNames=function(){var c=[],r,i;if(this._eventsCount===0)return c;for(i in r=this._events)M.call(r,i)&&c.push(m?i.slice(1):i);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(r)):c},d.prototype.listeners=function(c){var r=m?m+c:c,i=this._events[r];if(!i)return[];if(i.fn)return[i.fn];for(var o=0,u=i.length,f=new Array(u);o<u;o++)f[o]=i[o].fn;return f},d.prototype.listenerCount=function(c){var r=m?m+c:c,i=this._events[r];return i?i.fn?1:i.length:0},d.prototype.emit=function(c,r,i,o,u,f){var s=m?m+c:c;if(!this._events[s])return!1;var l=this._events[s],t=arguments.length,S,x;if(l.fn){l.once&&this.removeListener(c,l.fn,void 0,!0);switch(t){case 1:return l.fn.call(l.context),!0;case 2:return l.fn.call(l.context,r),!0;case 3:return l.fn.call(l.context,r,i),!0;case 4:return l.fn.call(l.context,r,i,o),!0;case 5:return l.fn.call(l.context,r,i,o,u),!0;case 6:return l.fn.call(l.context,r,i,o,u,f),!0}for(x=1,S=new Array(t-1);x<t;x++)S[x-1]=arguments[x];l.fn.apply(l.context,S)}else{var h=l.length,R;for(x=0;x<h;x++){l[x].once&&this.removeListener(c,l[x].fn,void 0,!0);switch(t){case 1:l[x].fn.call(l[x].context);break;case 2:l[x].fn.call(l[x].context,r);break;case 3:l[x].fn.call(l[x].context,r,i);break;case 4:l[x].fn.call(l[x].context,r,i,o);break;default:if(!S)for(R=1,S=new Array(t-1);R<t;R++)S[R-1]=arguments[R];l[x].fn.apply(l[x].context,S)}}}return!0},d.prototype.on=function(c,r,i){return b(this,c,r,i,!1)},d.prototype.once=function(c,r,i){return b(this,c,r,i,!0)},d.prototype.removeListener=function(c,r,i,o){var u=m?m+c:c;if(!this._events[u])return this;if(!r)return p(this,u),this;var f=this._events[u];if(f.fn)f.fn===r&&(!o||f.once)&&(!i||f.context===i)&&p(this,u);else{for(var s=0,l=[],t=f.length;s<t;s++)(f[s].fn!==r||o&&!f[s].once||i&&f[s].context!==i)&&l.push(f[s]);l.length?this._events[u]=l.length===1?l[0]:l:p(this,u)}return this},d.prototype.removeAllListeners=function(c){var r;return c?(r=m?m+c:c,this._events[r]&&p(this,r)):(this._events=new y,this._eventsCount=0),this},d.prototype.off=d.prototype.removeListener,d.prototype.addListener=d.prototype.on,d.prefixed=m,d.EventEmitter=d,N.exports=d},"./node_modules/url-toolkit/src/url-toolkit.js":function(N,v,C){(function(M){var m=/^((?:[a-zA-Z0-9+\-.]+:)?)(\/\/[^\/?#]*)?((?:[^\/?#]*\/)*[^;?#]*)?(;[^?#]*)?(\?[^#]*)?(#[^]*)?$/,y=/^([^\/?#]*)([^]*)$/,w=/(?:\/|^)\.(?=\/)/g,b=/(?:\/|^)\.\.\/(?!\.\.\/)[^\/]*(?=\/)/g,p={buildAbsoluteURL:function(d,n,c){if(c=c||{},d=d.trim(),n=n.trim(),!n){if(!c.alwaysNormalize)return d;var r=p.parseURL(d);if(!r)throw new Error("Error trying to parse base URL.");return r.path=p.normalizePath(r.path),p.buildURLFromParts(r)}var i=p.parseURL(n);if(!i)throw new Error("Error trying to parse relative URL.");if(i.scheme)return c.alwaysNormalize?(i.path=p.normalizePath(i.path),p.buildURLFromParts(i)):n;var o=p.parseURL(d);if(!o)throw new Error("Error trying to parse base URL.");if(!o.netLoc&&o.path&&o.path[0]!=="/"){var u=y.exec(o.path);o.netLoc=u[1],o.path=u[2]}o.netLoc&&!o.path&&(o.path="/");var f={scheme:o.scheme,netLoc:i.netLoc,path:null,params:i.params,query:i.query,fragment:i.fragment};if(!i.netLoc&&(f.netLoc=o.netLoc,i.path[0]!=="/"))if(!i.path)f.path=o.path,i.params||(f.params=o.params,i.query||(f.query=o.query));else{var s=o.path,l=s.substring(0,s.lastIndexOf("/")+1)+i.path;f.path=p.normalizePath(l)}return f.path===null&&(f.path=c.alwaysNormalize?p.normalizePath(i.path):i.path),p.buildURLFromParts(f)},parseURL:function(d){var n=m.exec(d);return n?{scheme:n[1]||"",netLoc:n[2]||"",path:n[3]||"",params:n[4]||"",query:n[5]||"",fragment:n[6]||""}:null},normalizePath:function(d){for(d=d.split("").reverse().join("").replace(w,"");d.length!==(d=d.replace(b,"")).length;);return d.split("").reverse().join("")},buildURLFromParts:function(d){return d.scheme+d.netLoc+d.path+d.params+d.query+d.fragment}};N.exports=p})(this)},"./node_modules/webworkify-webpack/index.js":function(N,v,C){function M(c){var r={};function i(u){if(r[u])return r[u].exports;var f=r[u]={i:u,l:!1,exports:{}};return c[u].call(f.exports,f,f.exports,i),f.l=!0,f.exports}i.m=c,i.c=r,i.i=function(u){return u},i.d=function(u,f,s){i.o(u,f)||Object.defineProperty(u,f,{configurable:!1,enumerable:!0,get:s})},i.r=function(u){Object.defineProperty(u,"__esModule",{value:!0})},i.n=function(u){var f=u&&u.__esModule?function(){return u.default}:function(){return u};return i.d(f,"a",f),f},i.o=function(u,f){return Object.prototype.hasOwnProperty.call(u,f)},i.p="/",i.oe=function(u){throw console.error(u),u};var o=i(i.s=ENTRY_MODULE);return o.default||o}var m="[\\.|\\-|\\+|\\w|/|@]+",y="\\(\\s*(/\\*.*?\\*/)?\\s*.*?("+m+").*?\\)";function w(c){return(c+"").replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}function b(c){return!isNaN(1*c)}function p(c,r,i){var o={};o[i]=[];var u=r.toString(),f=u.match(/^function\s?\w*\(\w+,\s*\w+,\s*(\w+)\)/);if(!f)return o;for(var s=f[1],l=new RegExp("(\\\\n|\\W)"+w(s)+y,"g"),t;t=l.exec(u);){if(t[3]==="dll-reference")continue;o[i].push(t[3])}for(l=new RegExp("\\("+w(s)+'\\("(dll-reference\\s('+m+'))"\\)\\)'+y,"g");t=l.exec(u);)c[t[2]]||(o[i].push(t[1]),c[t[2]]=C(t[1]).m),o[t[2]]=o[t[2]]||[],o[t[2]].push(t[4]);for(var S=Object.keys(o),x=0;x<S.length;x++)for(var h=0;h<o[S[x]].length;h++)b(o[S[x]][h])&&(o[S[x]][h]=1*o[S[x]][h]);return o}function d(c){var r=Object.keys(c);return r.reduce(function(i,o){return i||c[o].length>0},!1)}function n(c,r){for(var i={main:[r]},o={main:[]},u={main:{}};d(i);)for(var f=Object.keys(i),s=0;s<f.length;s++){var l=f[s],t=i[l],S=t.pop();if(u[l]=u[l]||{},u[l][S]||!c[l][S])continue;u[l][S]=!0,o[l]=o[l]||[],o[l].push(S);for(var x=p(c,c[l][S],l),h=Object.keys(x),R=0;R<h.length;R++)i[h[R]]=i[h[R]]||[],i[h[R]]=i[h[R]].concat(x[h[R]])}return o}N.exports=function(c,r){r=r||{};var i={main:C.m},o=r.all?{main:Object.keys(i.main)}:n(i,c),u="";Object.keys(o).filter(function(S){return S!=="main"}).forEach(function(S){for(var x=0;o[S][x];)x++;o[S].push(x),i[S][x]="(function(module, exports, __webpack_require__) { module.exports = __webpack_require__; })",u=u+"var "+S+" = ("+M.toString().replace("ENTRY_MODULE",JSON.stringify(x))+")({"+o[S].map(function(h){return""+JSON.stringify(h)+": "+i[S][h].toString()}).join(",")+`});
`}),u=u+"new (("+M.toString().replace("ENTRY_MODULE",JSON.stringify(c))+")({"+o.main.map(function(S){return""+JSON.stringify(S)+": "+i.main[S].toString()}).join(",")+"}))(self);";var f=new window.Blob([u],{type:"text/javascript"});if(r.bare)return f;var s=window.URL||window.webkitURL||window.mozURL||window.msURL,l=s.createObjectURL(f),t=new window.Worker(l);return t.objectURL=l,t}},"./src/config.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"hlsDefaultConfig",function(){return R}),C.d(v,"mergeConfig",function(){return g}),C.d(v,"enableStreamingMode",function(){return _});var M=C("./src/controller/abr-controller.ts"),m=C("./src/controller/audio-stream-controller.ts"),y=C("./src/controller/audio-track-controller.ts"),w=C("./src/controller/subtitle-stream-controller.ts"),b=C("./src/controller/subtitle-track-controller.ts"),p=C("./src/controller/buffer-controller.ts"),d=C("./src/controller/timeline-controller.ts"),n=C("./src/controller/cap-level-controller.ts"),c=C("./src/controller/fps-controller.ts"),r=C("./src/controller/eme-controller.ts"),i=C("./src/controller/cmcd-controller.ts"),o=C("./src/utils/xhr-loader.ts"),u=C("./src/utils/fetch-loader.ts"),f=C("./src/utils/cues.ts"),s=C("./src/utils/mediakeys-helper.ts"),l=C("./src/utils/logger.ts");function t(){return t=Object.assign||function(E){for(var T=1;T<arguments.length;T++){var L=arguments[T];for(var I in L)Object.prototype.hasOwnProperty.call(L,I)&&(E[I]=L[I])}return E},t.apply(this,arguments)}function S(E,T){var L=Object.keys(E);if(Object.getOwnPropertySymbols){var I=Object.getOwnPropertySymbols(E);T&&(I=I.filter(function(P){return Object.getOwnPropertyDescriptor(E,P).enumerable})),L.push.apply(L,I)}return L}function x(E){for(var T=1;T<arguments.length;T++){var L=arguments[T]!=null?arguments[T]:{};T%2?S(Object(L),!0).forEach(function(I){h(E,I,L[I])}):Object.getOwnPropertyDescriptors?Object.defineProperties(E,Object.getOwnPropertyDescriptors(L)):S(Object(L)).forEach(function(I){Object.defineProperty(E,I,Object.getOwnPropertyDescriptor(L,I))})}return E}function h(E,T,L){return T in E?Object.defineProperty(E,T,{value:L,enumerable:!0,configurable:!0,writable:!0}):E[T]=L,E}var R=x(x({autoStartLoad:!0,startPosition:-1,defaultAudioCodec:void 0,debug:!1,capLevelOnFPSDrop:!1,capLevelToPlayerSize:!1,initialLiveManifestSize:1,maxBufferLength:30,backBufferLength:Infinity,maxBufferSize:60*1e3*1e3,maxBufferHole:.1,highBufferWatchdogPeriod:2,nudgeOffset:.1,nudgeMaxRetry:3,maxFragLookUpTolerance:.25,liveSyncDurationCount:3,liveMaxLatencyDurationCount:Infinity,liveSyncDuration:void 0,liveMaxLatencyDuration:void 0,maxLiveSyncPlaybackRate:1,liveDurationInfinity:!1,liveBackBufferLength:null,maxMaxBufferLength:600,enableWorker:!0,enableSoftwareAES:!0,manifestLoadingTimeOut:1e4,manifestLoadingMaxRetry:1,manifestLoadingRetryDelay:1e3,manifestLoadingMaxRetryTimeout:64e3,startLevel:void 0,levelLoadingTimeOut:1e4,levelLoadingMaxRetry:4,levelLoadingRetryDelay:1e3,levelLoadingMaxRetryTimeout:64e3,fragLoadingTimeOut:2e4,fragLoadingMaxRetry:6,fragLoadingRetryDelay:1e3,fragLoadingMaxRetryTimeout:64e3,startFragPrefetch:!1,fpsDroppedMonitoringPeriod:5e3,fpsDroppedMonitoringThreshold:.2,appendErrorMaxRetry:3,loader:o.default,fLoader:void 0,pLoader:void 0,xhrSetup:void 0,licenseXhrSetup:void 0,licenseResponseCallback:void 0,abrController:M.default,bufferController:p.default,capLevelController:n.default,fpsController:c.default,stretchShortVideoTrack:!1,maxAudioFramesDrift:1,forceKeyFrameOnDiscontinuity:!0,abrEwmaFastLive:3,abrEwmaSlowLive:9,abrEwmaFastVoD:3,abrEwmaSlowVoD:9,abrEwmaDefaultEstimate:5e5,abrBandWidthFactor:.95,abrBandWidthUpFactor:.7,abrMaxWithRealBitrate:!1,maxStarvationDelay:4,maxLoadingDelay:4,minAutoBitrate:0,emeEnabled:!1,widevineLicenseUrl:void 0,drmSystemOptions:{},requestMediaKeySystemAccessFunc:s.requestMediaKeySystemAccess,testBandwidth:!0,progressive:!1,lowLatencyMode:!0,cmcd:void 0},O()),{},{subtitleStreamController:w.SubtitleStreamController,subtitleTrackController:b.default,timelineController:d.TimelineController,audioStreamController:m.default,audioTrackController:y.default,emeController:r.default,cmcdController:i.default});function O(){return{cueHandler:f.default,enableCEA708Captions:!0,enableWebVTT:!0,enableIMSC1:!0,captionsTextTrack1Label:"English",captionsTextTrack1LanguageCode:"en",captionsTextTrack2Label:"Spanish",captionsTextTrack2LanguageCode:"es",captionsTextTrack3Label:"Unknown CC",captionsTextTrack3LanguageCode:"",captionsTextTrack4Label:"Unknown CC",captionsTextTrack4LanguageCode:"",renderTextTracksNatively:!0}}function g(E,T){if((T.liveSyncDurationCount||T.liveMaxLatencyDurationCount)&&(T.liveSyncDuration||T.liveMaxLatencyDuration))throw new Error("Illegal hls.js config: don't mix up liveSyncDurationCount/liveMaxLatencyDurationCount and liveSyncDuration/liveMaxLatencyDuration");if(T.liveMaxLatencyDurationCount!==void 0&&(T.liveSyncDurationCount===void 0||T.liveMaxLatencyDurationCount<=T.liveSyncDurationCount))throw new Error('Illegal hls.js config: "liveMaxLatencyDurationCount" must be greater than "liveSyncDurationCount"');if(T.liveMaxLatencyDuration!==void 0&&(T.liveSyncDuration===void 0||T.liveMaxLatencyDuration<=T.liveSyncDuration))throw new Error('Illegal hls.js config: "liveMaxLatencyDuration" must be greater than "liveSyncDuration"');return t({},E,T)}function _(E){var T=E.loader;if(T!==u.default&&T!==o.default)l.logger.log("[config]: Custom loader detected, cannot enable progressive streaming"),E.progressive=!1;else{var L=Object(u.fetchSupported)();L&&(E.loader=u.default,E.progressive=!0,E.enableSoftwareAES=!0,l.logger.log("[config]: Progressive streaming enabled, using FetchLoader"))}}},"./src/controller/abr-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/polyfills/number.ts"),m=C("./src/utils/ewma-bandwidth-estimator.ts"),y=C("./src/events.ts"),w=C("./src/utils/buffer-helper.ts"),b=C("./src/errors.ts"),p=C("./src/types/loader.ts"),d=C("./src/utils/logger.ts");function n(i,o){for(var u=0;u<o.length;u++){var f=o[u];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(i,f.key,f)}}function c(i,o,u){return o&&n(i.prototype,o),u&&n(i,u),i}var r=function(){function i(u){this.hls=void 0,this.lastLoadedFragLevel=0,this._nextAutoLevel=-1,this.timer=void 0,this.onCheck=this._abandonRulesCheck.bind(this),this.fragCurrent=null,this.partCurrent=null,this.bitrateTestDelay=0,this.bwEstimator=void 0,this.hls=u;var f=u.config;this.bwEstimator=new m.default(f.abrEwmaSlowVoD,f.abrEwmaFastVoD,f.abrEwmaDefaultEstimate),this.registerListeners()}var o=i.prototype;return o.registerListeners=function(){var f=this.hls;f.on(y.Events.FRAG_LOADING,this.onFragLoading,this),f.on(y.Events.FRAG_LOADED,this.onFragLoaded,this),f.on(y.Events.FRAG_BUFFERED,this.onFragBuffered,this),f.on(y.Events.LEVEL_LOADED,this.onLevelLoaded,this),f.on(y.Events.ERROR,this.onError,this)},o.unregisterListeners=function(){var f=this.hls;f.off(y.Events.FRAG_LOADING,this.onFragLoading,this),f.off(y.Events.FRAG_LOADED,this.onFragLoaded,this),f.off(y.Events.FRAG_BUFFERED,this.onFragBuffered,this),f.off(y.Events.LEVEL_LOADED,this.onLevelLoaded,this),f.off(y.Events.ERROR,this.onError,this)},o.destroy=function(){this.unregisterListeners(),this.clearTimer(),this.hls=this.onCheck=null,this.fragCurrent=this.partCurrent=null},o.onFragLoading=function(f,s){var l=s.frag;if(l.type===p.PlaylistLevelType.MAIN&&!this.timer){var t;this.fragCurrent=l,this.partCurrent=(t=s.part)!=null?t:null,this.timer=self.setInterval(this.onCheck,100)}},o.onLevelLoaded=function(f,s){var l=this.hls.config;s.details.live?this.bwEstimator.update(l.abrEwmaSlowLive,l.abrEwmaFastLive):this.bwEstimator.update(l.abrEwmaSlowVoD,l.abrEwmaFastVoD)},o._abandonRulesCheck=function(){var f=this.fragCurrent,s=this.partCurrent,l=this.hls,t=l.autoLevelEnabled,S=l.config,x=l.media;if(!f||!x)return;var h=s?s.stats:f.stats,R=s?s.duration:f.duration;if(h.aborted){d.logger.warn("frag loader destroy or aborted, disarm abandonRules"),this.clearTimer(),this._nextAutoLevel=-1;return}if(!t||x.paused||!x.playbackRate||!x.readyState)return;var O=performance.now()-h.loading.start,g=Math.abs(x.playbackRate);if(O<=500*R/g)return;var _=l.levels,E=l.minAutoLevel,T=_[f.level],L=h.total||Math.max(h.loaded,Math.round(R*T.maxBitrate/8)),I=Math.max(1,h.bwEstimate?h.bwEstimate/8:h.loaded*1e3/O),P=(L-h.loaded)/I,G=x.currentTime,W=(w.BufferHelper.bufferInfo(x,G,S.maxBufferHole).end-G)/g;if(W>=2*R/g||P<=W)return;var H=Number.POSITIVE_INFINITY,z;for(z=f.level-1;z>E;z--){var B=_[z].maxBitrate;if(H=R*B/(8*.8*I),H<W)break}if(H>=P)return;var k=this.bwEstimator.getEstimate();d.logger.warn("Fragment "+f.sn+(s?" part "+s.index:"")+" of level "+f.level+" is loading too slowly and will cause an underbuffer; aborting and switching to level "+z+`
Current BW estimate: `+(Object(M.isFiniteNumber)(k)?(k/1024).toFixed(3):"Unknown")+` Kb/s
Estimated load time for current fragment: `+P.toFixed(3)+` s
Estimated load time for the next fragment: `+H.toFixed(3)+` s
Time to underbuffer: `+W.toFixed(3)+" s"),l.nextLoadLevel=z,this.bwEstimator.sample(O,h.loaded),this.clearTimer(),f.loader&&(this.fragCurrent=this.partCurrent=null,f.loader.abort()),l.trigger(y.Events.FRAG_LOAD_EMERGENCY_ABORTED,{frag:f,part:s,stats:h})},o.onFragLoaded=function(f,s){var l=s.frag,t=s.part;if(l.type===p.PlaylistLevelType.MAIN&&Object(M.isFiniteNumber)(l.sn)){var S=t?t.stats:l.stats,x=t?t.duration:l.duration;if(this.clearTimer(),this.lastLoadedFragLevel=l.level,this._nextAutoLevel=-1,this.hls.config.abrMaxWithRealBitrate){var h=this.hls.levels[l.level],R=(h.loaded?h.loaded.bytes:0)+S.loaded,O=(h.loaded?h.loaded.duration:0)+x;h.loaded={bytes:R,duration:O},h.realBitrate=Math.round(8*R/O)}if(l.bitrateTest){var g={stats:S,frag:l,part:t,id:l.type};this.onFragBuffered(y.Events.FRAG_BUFFERED,g),l.bitrateTest=!1}}},o.onFragBuffered=function(f,s){var l=s.frag,t=s.part,S=t?t.stats:l.stats;if(S.aborted)return;if(l.type!==p.PlaylistLevelType.MAIN||l.sn==="initSegment")return;var x=S.parsing.end-S.loading.start;this.bwEstimator.sample(x,S.loaded),S.bwEstimate=this.bwEstimator.getEstimate(),l.bitrateTest?this.bitrateTestDelay=x/1e3:this.bitrateTestDelay=0},o.onError=function(f,s){switch(s.details){case b.ErrorDetails.FRAG_LOAD_ERROR:case b.ErrorDetails.FRAG_LOAD_TIMEOUT:this.clearTimer();break;default:break}},o.clearTimer=function(){self.clearInterval(this.timer),this.timer=void 0},o.getNextABRAutoLevel=function(){var f=this.fragCurrent,s=this.partCurrent,l=this.hls,t=l.maxAutoLevel,S=l.config,x=l.minAutoLevel,h=l.media,R=s?s.duration:f?f.duration:0,O=h?h.currentTime:0,g=h&&h.playbackRate!==0?Math.abs(h.playbackRate):1,_=this.bwEstimator?this.bwEstimator.getEstimate():S.abrEwmaDefaultEstimate,E=(w.BufferHelper.bufferInfo(h,O,S.maxBufferHole).end-O)/g,T=this.findBestLevel(_,x,t,E,S.abrBandWidthFactor,S.abrBandWidthUpFactor);if(T>=0)return T;d.logger.trace((E?"rebuffering expected":"buffer is empty")+", finding optimal quality level");var L=R?Math.min(R,S.maxStarvationDelay):S.maxStarvationDelay,I=S.abrBandWidthFactor,P=S.abrBandWidthUpFactor;if(!E){var G=this.bitrateTestDelay;if(G){var W=R?Math.min(R,S.maxLoadingDelay):S.maxLoadingDelay;L=W-G,d.logger.trace("bitrate test took "+Math.round(1e3*G)+"ms, set first fragment max fetchDuration to "+Math.round(1e3*L)+" ms"),I=P=1}}return T=this.findBestLevel(_,x,t,E+L,I,P),Math.max(T,0)},o.findBestLevel=function(f,s,l,t,S,x){for(var h,R=this.fragCurrent,O=this.partCurrent,g=this.lastLoadedFragLevel,_=this.hls.levels,E=_[g],T=!!(E!=null&&(h=E.details)!==null&&h!==void 0&&h.live),L=E==null?void 0:E.codecSet,I=O?O.duration:R?R.duration:0,P=l;P>=s;P--){var G=_[P];if(!G||L&&G.codecSet!==L)continue;var W=G.details,H=(O?W==null?void 0:W.partTarget:W==null?void 0:W.averagetargetduration)||I,z=void 0;P<=g?z=S*f:z=x*f;var B=_[P].maxBitrate,k=B*H/z;if(d.logger.trace("level/adjustedbw/bitrate/avgDuration/maxFetchDuration/fetchDuration: "+P+"/"+Math.round(z)+"/"+B+"/"+H+"/"+t+"/"+k),z>B&&(!k||T&&!this.bitrateTestDelay||k<t))return P}return-1},c(i,[{key:"nextAutoLevel",get:function(){var f=this._nextAutoLevel,s=this.bwEstimator;if(f!==-1&&(!s||!s.canEstimate()))return f;var l=this.getNextABRAutoLevel();return f!==-1&&(l=Math.min(f,l)),l},set:function(f){this._nextAutoLevel=f}}]),i}();v.default=r},"./src/controller/audio-stream-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/polyfills/number.ts"),m=C("./src/controller/base-stream-controller.ts"),y=C("./src/events.ts"),w=C("./src/utils/buffer-helper.ts"),b=C("./src/controller/fragment-tracker.ts"),p=C("./src/types/level.ts"),d=C("./src/types/loader.ts"),n=C("./src/loader/fragment.ts"),c=C("./src/demux/chunk-cache.ts"),r=C("./src/demux/transmuxer-interface.ts"),i=C("./src/types/transmuxer.ts"),o=C("./src/controller/fragment-finders.ts"),u=C("./src/utils/discontinuities.ts"),f=C("./src/errors.ts"),s=C("./src/utils/logger.ts");function l(){return l=Object.assign||function(R){for(var O=1;O<arguments.length;O++){var g=arguments[O];for(var _ in g)Object.prototype.hasOwnProperty.call(g,_)&&(R[_]=g[_])}return R},l.apply(this,arguments)}function t(R,O){R.prototype=Object.create(O.prototype),R.prototype.constructor=R,S(R,O)}function S(R,O){return S=Object.setPrototypeOf||function(_,E){return _.__proto__=E,_},S(R,O)}var x=100,h=function(R){t(O,R);function O(_,E){var T;return T=R.call(this,_,E,"[audio-stream-controller]")||this,T.videoBuffer=null,T.videoTrackCC=-1,T.waitingVideoCC=-1,T.audioSwitch=!1,T.trackId=-1,T.waitingData=null,T.mainDetails=null,T.bufferFlushed=!1,T._registerListeners(),T}var g=O.prototype;return g.onHandlerDestroying=function(){this._unregisterListeners(),this.mainDetails=null},g._registerListeners=function(){var E=this.hls;E.on(y.Events.MEDIA_ATTACHED,this.onMediaAttached,this),E.on(y.Events.MEDIA_DETACHING,this.onMediaDetaching,this),E.on(y.Events.MANIFEST_LOADING,this.onManifestLoading,this),E.on(y.Events.LEVEL_LOADED,this.onLevelLoaded,this),E.on(y.Events.AUDIO_TRACKS_UPDATED,this.onAudioTracksUpdated,this),E.on(y.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),E.on(y.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),E.on(y.Events.ERROR,this.onError,this),E.on(y.Events.BUFFER_RESET,this.onBufferReset,this),E.on(y.Events.BUFFER_CREATED,this.onBufferCreated,this),E.on(y.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),E.on(y.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),E.on(y.Events.FRAG_BUFFERED,this.onFragBuffered,this)},g._unregisterListeners=function(){var E=this.hls;E.off(y.Events.MEDIA_ATTACHED,this.onMediaAttached,this),E.off(y.Events.MEDIA_DETACHING,this.onMediaDetaching,this),E.off(y.Events.MANIFEST_LOADING,this.onManifestLoading,this),E.off(y.Events.LEVEL_LOADED,this.onLevelLoaded,this),E.off(y.Events.AUDIO_TRACKS_UPDATED,this.onAudioTracksUpdated,this),E.off(y.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),E.off(y.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),E.off(y.Events.ERROR,this.onError,this),E.off(y.Events.BUFFER_RESET,this.onBufferReset,this),E.off(y.Events.BUFFER_CREATED,this.onBufferCreated,this),E.off(y.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),E.off(y.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),E.off(y.Events.FRAG_BUFFERED,this.onFragBuffered,this)},g.onInitPtsFound=function(E,T){var L=T.frag,I=T.id,P=T.initPTS;if(I==="main"){var G=L.cc;this.initPTS[L.cc]=P,this.log("InitPTS for cc: "+G+" found from main: "+P),this.videoTrackCC=G,this.state===m.State.WAITING_INIT_PTS&&this.tick()}},g.startLoad=function(E){if(!this.levels){this.startPosition=E,this.state=m.State.STOPPED;return}var T=this.lastCurrentTime;this.stopLoad(),this.setInterval(x),this.fragLoadError=0,T>0&&E===-1?(this.log("Override startPosition with lastCurrentTime @"+T.toFixed(3)),this.state=m.State.IDLE):(this.loadedmetadata=!1,this.state=m.State.WAITING_TRACK),this.nextLoadPosition=this.startPosition=this.lastCurrentTime=E,this.tick()},g.doTick=function(){switch(this.state){case m.State.IDLE:this.doTickIdle();break;case m.State.WAITING_TRACK:{var E,T=this.levels,L=this.trackId,I=T==null||((E=T[L])===null||E===void 0)?void 0:E.details;if(I){if(this.waitForCdnTuneIn(I))break;this.state=m.State.WAITING_INIT_PTS}break}case m.State.FRAG_LOADING_WAITING_RETRY:{var P,G=performance.now(),W=this.retryDate;(!W||G>=W||(P=this.media)!==null&&P!==void 0&&P.seeking)&&(this.log("RetryDate reached, switch back to IDLE state"),this.state=m.State.IDLE);break}case m.State.WAITING_INIT_PTS:{var H=this.waitingData;if(H){var z=H.frag,B=H.part,k=H.cache,K=H.complete;if(this.initPTS[z.cc]!==void 0){this.waitingData=null,this.waitingVideoCC=-1,this.state=m.State.FRAG_LOADING;var Y=k.flush(),ne={frag:z,part:B,payload:Y,networkDetails:null};this._handleFragmentLoadProgress(ne),K&&R.prototype._handleFragmentLoadComplete.call(this,ne)}else if(this.videoTrackCC!==this.waitingVideoCC)s.logger.log("Waiting fragment cc ("+z.cc+") cancelled because video is at cc "+this.videoTrackCC),this.clearWaitingFragment();else{var oe=this.getLoadPosition(),_e=w.BufferHelper.bufferInfo(this.mediaBuffer,oe,this.config.maxBufferHole),xe=Object(o.fragmentWithinToleranceTest)(_e.end,this.config.maxFragLookUpTolerance,z);xe<0&&(s.logger.log("Waiting fragment cc ("+z.cc+") @ "+z.start+" cancelled because another fragment at "+_e.end+" is needed"),this.clearWaitingFragment())}}else this.state=m.State.IDLE}}this.onTickEnd()},g.clearWaitingFragment=function(){var E=this.waitingData;E&&(this.fragmentTracker.removeFragment(E.frag),this.waitingData=null,this.waitingVideoCC=-1,this.state=m.State.IDLE)},g.onTickEnd=function(){var E=this.media;if(!E||!E.readyState)return;var T=this.mediaBuffer?this.mediaBuffer:E,L=T.buffered;!this.loadedmetadata&&L.length&&(this.loadedmetadata=!0),this.lastCurrentTime=E.currentTime},g.doTickIdle=function(){var E,T,L=this.hls,I=this.levels,P=this.media,G=this.trackId,W=L.config;if(!I||!I[G])return;if(!P&&(this.startFragRequested||!W.startFragPrefetch))return;var H=I[G],z=H.details;if(!z||z.live&&this.levelLastLoaded!==G||this.waitForCdnTuneIn(z)){this.state=m.State.WAITING_TRACK;return}this.bufferFlushed&&(this.bufferFlushed=!1,this.afterBufferFlushed(this.mediaBuffer?this.mediaBuffer:this.media,n.ElementaryStreamTypes.AUDIO,d.PlaylistLevelType.AUDIO));var B=this.getFwdBufferInfo(this.mediaBuffer?this.mediaBuffer:this.media,d.PlaylistLevelType.AUDIO);if(B===null)return;var k=B.len,K=this.getMaxBufferLength(),Y=this.audioSwitch;if(k>=K&&!Y)return;if(!Y&&this._streamEnded(B,z)){L.trigger(y.Events.BUFFER_EOS,{type:"audio"}),this.state=m.State.ENDED;return}var ne=z.fragments,oe=ne[0].start,_e=B.end;if(Y){var xe=this.getLoadPosition();_e=xe,z.PTSKnown&&xe<oe&&((B.end>oe||B.nextStart)&&(this.log("Alt audio track ahead of main track, seek to start of alt audio track"),P.currentTime=oe+.05))}var le=this.getNextFragment(_e,z);if(!le){this.bufferFlushed=!0;return}((E=le.decryptdata)===null||E===void 0?void 0:E.keyFormat)==="identity"&&!((T=le.decryptdata)!==null&&T!==void 0&&T.key)?this.loadKey(le,z):this.loadFragment(le,z,_e)},g.getMaxBufferLength=function(){var E=R.prototype.getMaxBufferLength.call(this),T=this.getFwdBufferInfo(this.videoBuffer?this.videoBuffer:this.media,d.PlaylistLevelType.MAIN);return T===null?E:Math.max(E,T.len)},g.onMediaDetaching=function(){this.videoBuffer=null,R.prototype.onMediaDetaching.call(this)},g.onAudioTracksUpdated=function(E,T){var L=T.audioTracks;this.resetTransmuxer(),this.levels=L.map(function(I){return new p.Level(I)})},g.onAudioTrackSwitching=function(E,T){var L=!!T.url;this.trackId=T.id;var I=this.fragCurrent;I!=null&&I.loader&&I.loader.abort(),this.fragCurrent=null,this.clearWaitingFragment(),L?this.setInterval(x):this.resetTransmuxer(),L?(this.audioSwitch=!0,this.state=m.State.IDLE):this.state=m.State.STOPPED,this.tick()},g.onManifestLoading=function(){this.mainDetails=null,this.fragmentTracker.removeAllFragments(),this.startPosition=this.lastCurrentTime=0,this.bufferFlushed=!1},g.onLevelLoaded=function(E,T){this.mainDetails=T.details},g.onAudioTrackLoaded=function(E,T){var L,I=this.levels,P=T.details,G=T.id;if(!I){this.warn("Audio tracks were reset while loading level "+G);return}this.log("Track "+G+" loaded ["+P.startSN+","+P.endSN+"],duration:"+P.totalduration);var W=I[G],H=0;if(P.live||(L=W.details)!==null&&L!==void 0&&L.live){var z=this.mainDetails;if(P.fragments[0]||(P.deltaUpdateFailed=!0),P.deltaUpdateFailed||!z)return;!W.details&&P.hasProgramDateTime&&z.hasProgramDateTime?(Object(u.alignMediaPlaylistByPDT)(P,z),H=P.fragments[0].start):H=this.alignPlaylists(P,W.details)}W.details=P,this.levelLastLoaded=G,!this.startFragRequested&&(this.mainDetails||!P.live)&&this.setStartPosition(W.details,H),this.state===m.State.WAITING_TRACK&&!this.waitForCdnTuneIn(P)&&(this.state=m.State.IDLE),this.tick()},g._handleFragmentLoadProgress=function(E){var T,L=E.frag,I=E.part,P=E.payload,G=this.config,W=this.trackId,H=this.levels;if(!H){this.warn("Audio tracks were reset while fragment load was in progress. Fragment "+L.sn+" of level "+L.level+" will not be buffered");return}var z=H[W];console.assert(z,"Audio track is defined on fragment load progress");var B=z.details;console.assert(B,"Audio track details are defined on fragment load progress");var k=G.defaultAudioCodec||z.audioCodec||"mp4a.40.2",K=this.transmuxer;K||(K=this.transmuxer=new r.default(this.hls,d.PlaylistLevelType.AUDIO,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)));var Y=this.initPTS[L.cc],ne=(T=L.initSegment)===null||T===void 0?void 0:T.data;if(Y!==void 0){var oe=!1,_e=I?I.index:-1,xe=_e!==-1,le=new i.ChunkMetadata(L.level,L.sn,L.stats.chunkCount,P.byteLength,_e,xe);K.push(P,ne,k,"",L,I,B.totalduration,oe,le,Y)}else{s.logger.log("Unknown video PTS for cc "+L.cc+", waiting for video PTS before demuxing audio frag "+L.sn+" of ["+B.startSN+" ,"+B.endSN+"],track "+W);var me=this.waitingData=this.waitingData||{frag:L,part:I,cache:new c.default,complete:!1},de=me.cache;de.push(new Uint8Array(P)),this.waitingVideoCC=this.videoTrackCC,this.state=m.State.WAITING_INIT_PTS}},g._handleFragmentLoadComplete=function(E){if(this.waitingData){this.waitingData.complete=!0;return}R.prototype._handleFragmentLoadComplete.call(this,E)},g.onBufferReset=function(){this.mediaBuffer=this.videoBuffer=null,this.loadedmetadata=!1},g.onBufferCreated=function(E,T){var L=T.tracks.audio;L&&(this.mediaBuffer=L.buffer),T.tracks.video&&(this.videoBuffer=T.tracks.video.buffer)},g.onFragBuffered=function(E,T){var L=T.frag,I=T.part;if(L.type!==d.PlaylistLevelType.AUDIO)return;if(this.fragContextChanged(L)){this.warn("Fragment "+L.sn+(I?" p: "+I.index:"")+" of level "+L.level+" finished buffering, but was aborted. state: "+this.state+", audioSwitch: "+this.audioSwitch);return}L.sn!=="initSegment"&&(this.fragPrevious=L,this.audioSwitch&&(this.audioSwitch=!1,this.hls.trigger(y.Events.AUDIO_TRACK_SWITCHED,{id:this.trackId}))),this.fragBufferedComplete(L,I)},g.onError=function(E,T){switch(T.details){case f.ErrorDetails.FRAG_LOAD_ERROR:case f.ErrorDetails.FRAG_LOAD_TIMEOUT:case f.ErrorDetails.KEY_LOAD_ERROR:case f.ErrorDetails.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(d.PlaylistLevelType.AUDIO,T);break;case f.ErrorDetails.AUDIO_TRACK_LOAD_ERROR:case f.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:this.state!==m.State.ERROR&&this.state!==m.State.STOPPED&&(this.state=T.fatal?m.State.ERROR:m.State.IDLE,this.warn(T.details+" while loading frag, switching to "+this.state+" state"));break;case f.ErrorDetails.BUFFER_FULL_ERROR:if(T.parent==="audio"&&(this.state===m.State.PARSING||this.state===m.State.PARSED)){var L=!0,I=this.getFwdBufferInfo(this.mediaBuffer,d.PlaylistLevelType.AUDIO);I&&I.len>.5&&(L=!this.reduceMaxBufferLength(I.len)),L&&(this.warn("Buffer full error also media.currentTime is not buffered, flush audio buffer"),this.fragCurrent=null,R.prototype.flushMainBuffer.call(this,0,Number.POSITIVE_INFINITY,"audio")),this.resetLoadingState()}break;default:break}},g.onBufferFlushed=function(E,T){var L=T.type;L===n.ElementaryStreamTypes.AUDIO&&(this.bufferFlushed=!0)},g._handleTransmuxComplete=function(E){var T,L="audio",I=this.hls,P=E.remuxResult,G=E.chunkMeta,W=this.getCurrentContext(G);if(!W){this.warn("The loading context changed while buffering fragment "+G.sn+" of level "+G.level+". This chunk will not be buffered."),this.resetLiveStartWhenNotLoaded(G.level);return}var H=W.frag,z=W.part,B=P.audio,k=P.text,K=P.id3,Y=P.initSegment;if(this.fragContextChanged(H))return;if(this.state=m.State.PARSING,this.audioSwitch&&B&&this.completeAudioSwitch(),Y!=null&&Y.tracks&&(this._bufferInitSegment(Y.tracks,H,G),I.trigger(y.Events.FRAG_PARSING_INIT_SEGMENT,{frag:H,id:L,tracks:Y.tracks})),B){var ne=B.startPTS,oe=B.endPTS,_e=B.startDTS,xe=B.endDTS;z&&(z.elementaryStreams[n.ElementaryStreamTypes.AUDIO]={startPTS:ne,endPTS:oe,startDTS:_e,endDTS:xe}),H.setElementaryStreamInfo(n.ElementaryStreamTypes.AUDIO,ne,oe,_e,xe),this.bufferFragmentData(B,H,z,G)}if(K!=null&&(T=K.samples)!==null&&T!==void 0&&T.length){var le=l({frag:H,id:L},K);I.trigger(y.Events.FRAG_PARSING_METADATA,le)}if(k){var me=l({frag:H,id:L},k);I.trigger(y.Events.FRAG_PARSING_USERDATA,me)}},g._bufferInitSegment=function(E,T,L){if(this.state!==m.State.PARSING)return;E.video&&delete E.video;var I=E.audio;if(!I)return;I.levelCodec=I.codec,I.id="audio",this.log("Init audio buffer, container:"+I.container+", codecs[parsed]=["+I.codec+"]"),this.hls.trigger(y.Events.BUFFER_CODECS,E);var P=I.initSegment;if(P!=null&&P.byteLength){var G={type:"audio",frag:T,part:null,chunkMeta:L,parent:T.type,data:P};this.hls.trigger(y.Events.BUFFER_APPENDING,G)}this.tick()},g.loadFragment=function(E,T,L){var I=this.fragmentTracker.getState(E);this.fragCurrent=E,(this.audioSwitch||I===b.FragmentState.NOT_LOADED||I===b.FragmentState.PARTIAL)&&(E.sn==="initSegment"?this._loadInitSegment(E):T.live&&!Object(M.isFiniteNumber)(this.initPTS[E.cc])?(this.log("Waiting for video PTS in continuity counter "+E.cc+" of live stream before loading audio fragment "+E.sn+" of level "+this.trackId),this.state=m.State.WAITING_INIT_PTS):(this.startFragRequested=!0,R.prototype.loadFragment.call(this,E,T,L)))},g.completeAudioSwitch=function(){var E=this.hls,T=this.media,L=this.trackId;T&&(this.log("Switching audio track : flushing all audio"),R.prototype.flushMainBuffer.call(this,0,Number.POSITIVE_INFINITY,"audio")),this.audioSwitch=!1,E.trigger(y.Events.AUDIO_TRACK_SWITCHED,{id:L})},O}(m.default);v.default=h},"./src/controller/audio-track-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/events.ts"),m=C("./src/errors.ts"),y=C("./src/controller/base-playlist-controller.ts"),w=C("./src/types/loader.ts");function b(r,i){for(var o=0;o<i.length;o++){var u=i[o];u.enumerable=u.enumerable||!1,u.configurable=!0,"value"in u&&(u.writable=!0),Object.defineProperty(r,u.key,u)}}function p(r,i,o){return i&&b(r.prototype,i),o&&b(r,o),r}function d(r,i){r.prototype=Object.create(i.prototype),r.prototype.constructor=r,n(r,i)}function n(r,i){return n=Object.setPrototypeOf||function(u,f){return u.__proto__=f,u},n(r,i)}var c=function(r){d(i,r);function i(u){var f;return f=r.call(this,u,"[audio-track-controller]")||this,f.tracks=[],f.groupId=null,f.tracksInGroup=[],f.trackId=-1,f.trackName="",f.selectDefaultTrack=!0,f.registerListeners(),f}var o=i.prototype;return o.registerListeners=function(){var f=this.hls;f.on(M.Events.MANIFEST_LOADING,this.onManifestLoading,this),f.on(M.Events.MANIFEST_PARSED,this.onManifestParsed,this),f.on(M.Events.LEVEL_LOADING,this.onLevelLoading,this),f.on(M.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),f.on(M.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),f.on(M.Events.ERROR,this.onError,this)},o.unregisterListeners=function(){var f=this.hls;f.off(M.Events.MANIFEST_LOADING,this.onManifestLoading,this),f.off(M.Events.MANIFEST_PARSED,this.onManifestParsed,this),f.off(M.Events.LEVEL_LOADING,this.onLevelLoading,this),f.off(M.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),f.off(M.Events.AUDIO_TRACK_LOADED,this.onAudioTrackLoaded,this),f.off(M.Events.ERROR,this.onError,this)},o.destroy=function(){this.unregisterListeners(),this.tracks.length=0,this.tracksInGroup.length=0,r.prototype.destroy.call(this)},o.onManifestLoading=function(){this.tracks=[],this.groupId=null,this.tracksInGroup=[],this.trackId=-1,this.trackName="",this.selectDefaultTrack=!0},o.onManifestParsed=function(f,s){this.tracks=s.audioTracks||[]},o.onAudioTrackLoaded=function(f,s){var l=s.id,t=s.details,S=this.tracksInGroup[l];if(!S){this.warn("Invalid audio track id "+l);return}var x=S.details;S.details=s.details,this.log("audioTrack "+l+" loaded ["+t.startSN+"-"+t.endSN+"]"),l===this.trackId&&(this.retryCount=0,this.playlistLoaded(l,s,x))},o.onLevelLoading=function(f,s){this.switchLevel(s.level)},o.onLevelSwitching=function(f,s){this.switchLevel(s.level)},o.switchLevel=function(f){var s=this.hls.levels[f];if(!(s!=null&&s.audioGroupIds))return;var l=s.audioGroupIds[s.urlId];if(this.groupId!==l){this.groupId=l;var t=this.tracks.filter(function(x){return!l||x.groupId===l});this.selectDefaultTrack&&!t.some(function(x){return x.default})&&(this.selectDefaultTrack=!1),this.tracksInGroup=t;var S={audioTracks:t};this.log("Updating audio tracks, "+t.length+' track(s) found in "'+l+'" group-id'),this.hls.trigger(M.Events.AUDIO_TRACKS_UPDATED,S),this.selectInitialTrack()}},o.onError=function(f,s){if(r.prototype.onError.call(this,f,s),s.fatal||!s.context)return;s.context.type===w.PlaylistContextType.AUDIO_TRACK&&s.context.id===this.trackId&&s.context.groupId===this.groupId&&this.retryLoadingOrFail(s)},o.setAudioTrack=function(f){var s=this.tracksInGroup;if(f<0||f>=s.length){this.warn("Invalid id passed to audio-track controller");return}this.clearTimer();var l=s[this.trackId];this.log("Now switching to audio-track index "+f);var t=s[f],S=t.id,x=t.groupId,h=x===void 0?"":x,R=t.name,O=t.type,g=t.url;if(this.trackId=f,this.trackName=R,this.selectDefaultTrack=!1,this.hls.trigger(M.Events.AUDIO_TRACK_SWITCHING,{id:S,groupId:h,name:R,type:O,url:g}),t.details&&!t.details.live)return;var _=this.switchParams(t.url,l==null?void 0:l.details);this.loadPlaylist(_)},o.selectInitialTrack=function(){var f=this.tracksInGroup;console.assert(f.length,"Initial audio track should be selected when tracks are known");var s=this.trackName,l=this.findTrackId(s)||this.findTrackId();l!==-1?this.setAudioTrack(l):(this.warn("No track found for running audio group-ID: "+this.groupId),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,fatal:!0}))},o.findTrackId=function(f){for(var s=this.tracksInGroup,l=0;l<s.length;l++){var t=s[l];if((!this.selectDefaultTrack||t.default)&&(!f||f===t.name))return t.id}return-1},o.loadPlaylist=function(f){var s=this.tracksInGroup[this.trackId];if(this.shouldLoadTrack(s)){var l=s.id,t=s.groupId,S=s.url;if(f)try{S=f.addDirectives(S)}catch(x){this.warn("Could not construct new URL with HLS Delivery Directives: "+x)}this.log("loading audio-track playlist for id: "+l),this.clearTimer(),this.hls.trigger(M.Events.AUDIO_TRACK_LOADING,{url:S,id:l,groupId:t,deliveryDirectives:f||null})}},p(i,[{key:"audioTracks",get:function(){return this.tracksInGroup}},{key:"audioTrack",get:function(){return this.trackId},set:function(f){this.selectDefaultTrack=!1,this.setAudioTrack(f)}}]),i}(y.default);v.default=c},"./src/controller/base-playlist-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return p});var M=C("./src/polyfills/number.ts"),m=C("./src/types/level.ts"),y=C("./src/controller/level-helper.ts"),w=C("./src/utils/logger.ts"),b=C("./src/errors.ts"),p=function(){function d(c,r){this.hls=void 0,this.timer=-1,this.canLoad=!1,this.retryCount=0,this.log=void 0,this.warn=void 0,this.log=w.logger.log.bind(w.logger,r+":"),this.warn=w.logger.warn.bind(w.logger,r+":"),this.hls=c}var n=d.prototype;return n.destroy=function(){this.clearTimer(),this.hls=this.log=this.warn=null},n.onError=function(r,i){i.fatal&&i.type===b.ErrorTypes.NETWORK_ERROR&&this.clearTimer()},n.clearTimer=function(){clearTimeout(this.timer),this.timer=-1},n.startLoad=function(){this.canLoad=!0,this.retryCount=0,this.loadPlaylist()},n.stopLoad=function(){this.canLoad=!1,this.clearTimer()},n.switchParams=function(r,i){var o=i==null?void 0:i.renditionReports;if(o)for(var u=0;u<o.length;u++){var f=o[u],s=""+f.URI;if(s===r.substr(-s.length)){var l=parseInt(f["LAST-MSN"]),t=parseInt(f["LAST-PART"]);if(i&&this.hls.config.lowLatencyMode){var S=Math.min(i.age-i.partTarget,i.targetduration);t!==void 0&&S>i.partTarget&&(t+=1)}if(Object(M.isFiniteNumber)(l))return new m.HlsUrlParameters(l,Object(M.isFiniteNumber)(t)?t:void 0,m.HlsSkip.No)}}},n.loadPlaylist=function(r){},n.shouldLoadTrack=function(r){return this.canLoad&&r&&!!r.url&&(!r.details||r.details.live)},n.playlistLoaded=function(r,i,o){var u=this,f=i.details,s=i.stats,l=s.loading.end?Math.max(0,self.performance.now()-s.loading.end):0;if(f.advancedDateTime=Date.now()-l,f.live||o!=null&&o.live){if(f.reloaded(o),o&&this.log("live playlist "+r+" "+(f.advanced?"REFRESHED "+f.lastPartSn+"-"+f.lastPartIndex:"MISSED")),o&&f.fragments.length>0&&Object(y.mergeDetails)(o,f),!this.canLoad||!f.live)return;var t,S=void 0,x=void 0;if(f.canBlockReload&&f.endSN&&f.advanced){var h=this.hls.config.lowLatencyMode,R=f.lastPartSn,O=f.endSN,g=f.lastPartIndex,_=g!==-1,E=R===O,T=h?0:g;_?(S=E?O+1:R,x=E?T:g+1):S=O+1;var L=f.age,I=L+f.ageHeader,P=Math.min(I-f.partTarget,f.targetduration*1.5);if(P>0){if(o&&P>o.tuneInGoal)this.warn("CDN Tune-in goal increased from: "+o.tuneInGoal+" to: "+P+" with playlist age: "+f.age),P=0;else{var G=Math.floor(P/f.targetduration);if(S+=G,x!==void 0){var W=Math.round(P%f.targetduration/f.partTarget);x+=W}this.log("CDN Tune-in age: "+f.ageHeader+"s last advanced "+L.toFixed(2)+"s goal: "+P+" skip sn "+G+" to part "+x)}f.tuneInGoal=P}if(t=this.getDeliveryDirectives(f,i.deliveryDirectives,S,x),h||!E){this.loadPlaylist(t);return}}else t=this.getDeliveryDirectives(f,i.deliveryDirectives,S,x);var H=Object(y.computeReloadInterval)(f,s);S!==void 0&&f.canBlockReload&&(H-=f.partTarget||1),this.log("reload live playlist "+r+" in "+Math.round(H)+" ms"),this.timer=self.setTimeout(function(){return u.loadPlaylist(t)},H)}else this.clearTimer()},n.getDeliveryDirectives=function(r,i,o,u){var f=Object(m.getSkipValue)(r,o);return i!=null&&i.skip&&r.deltaUpdateFailed&&(o=i.msn,u=i.part,f=m.HlsSkip.No),new m.HlsUrlParameters(o,u,f)},n.retryLoadingOrFail=function(r){var i=this,o=this.hls.config,u=this.retryCount<o.levelLoadingMaxRetry;if(u){var f;if(this.retryCount++,r.details.indexOf("LoadTimeOut")>-1&&(f=r.context)!==null&&f!==void 0&&f.deliveryDirectives)this.warn("retry playlist loading #"+this.retryCount+' after "'+r.details+'"'),this.loadPlaylist();else{var s=Math.min(Math.pow(2,this.retryCount)*o.levelLoadingRetryDelay,o.levelLoadingMaxRetryTimeout);this.timer=self.setTimeout(function(){return i.loadPlaylist()},s),this.warn("retry playlist loading #"+this.retryCount+" in "+s+' ms after "'+r.details+'"')}}else this.warn('cannot recover from error "'+r.details+'"'),this.clearTimer(),r.fatal=!0;return u},d}()},"./src/controller/base-stream-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"State",function(){return O}),C.d(v,"default",function(){return g});var M=C("./src/polyfills/number.ts"),m=C("./src/task-loop.ts"),y=C("./src/controller/fragment-tracker.ts"),w=C("./src/utils/buffer-helper.ts"),b=C("./src/utils/logger.ts"),p=C("./src/events.ts"),d=C("./src/errors.ts"),n=C("./src/types/transmuxer.ts"),c=C("./src/utils/mp4-tools.ts"),r=C("./src/utils/discontinuities.ts"),i=C("./src/controller/fragment-finders.ts"),o=C("./src/controller/level-helper.ts"),u=C("./src/loader/fragment-loader.ts"),f=C("./src/crypt/decrypter.ts"),s=C("./src/utils/time-ranges.ts"),l=C("./src/types/loader.ts");function t(_,E){for(var T=0;T<E.length;T++){var L=E[T];L.enumerable=L.enumerable||!1,L.configurable=!0,"value"in L&&(L.writable=!0),Object.defineProperty(_,L.key,L)}}function S(_,E,T){return E&&t(_.prototype,E),T&&t(_,T),_}function x(_){if(_===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return _}function h(_,E){_.prototype=Object.create(E.prototype),_.prototype.constructor=_,R(_,E)}function R(_,E){return R=Object.setPrototypeOf||function(L,I){return L.__proto__=I,L},R(_,E)}var O={STOPPED:"STOPPED",IDLE:"IDLE",KEY_LOADING:"KEY_LOADING",FRAG_LOADING:"FRAG_LOADING",FRAG_LOADING_WAITING_RETRY:"FRAG_LOADING_WAITING_RETRY",WAITING_TRACK:"WAITING_TRACK",PARSING:"PARSING",PARSED:"PARSED",BACKTRACKING:"BACKTRACKING",ENDED:"ENDED",ERROR:"ERROR",WAITING_INIT_PTS:"WAITING_INIT_PTS",WAITING_LEVEL:"WAITING_LEVEL"},g=function(_){h(E,_);function E(L,I,P){var G;return G=_.call(this)||this,G.hls=void 0,G.fragPrevious=null,G.fragCurrent=null,G.fragmentTracker=void 0,G.transmuxer=null,G._state=O.STOPPED,G.media=void 0,G.mediaBuffer=void 0,G.config=void 0,G.bitrateTest=!1,G.lastCurrentTime=0,G.nextLoadPosition=0,G.startPosition=0,G.loadedmetadata=!1,G.fragLoadError=0,G.retryDate=0,G.levels=null,G.fragmentLoader=void 0,G.levelLastLoaded=null,G.startFragRequested=!1,G.decrypter=void 0,G.initPTS=[],G.onvseeking=null,G.onvended=null,G.logPrefix="",G.log=void 0,G.warn=void 0,G.logPrefix=P,G.log=b.logger.log.bind(b.logger,P+":"),G.warn=b.logger.warn.bind(b.logger,P+":"),G.hls=L,G.fragmentLoader=new u.default(L.config),G.fragmentTracker=I,G.config=L.config,G.decrypter=new f.default(L,L.config),L.on(p.Events.KEY_LOADED,G.onKeyLoaded,x(G)),G}var T=E.prototype;return T.doTick=function(){this.onTickEnd()},T.onTickEnd=function(){},T.startLoad=function(I){},T.stopLoad=function(){this.fragmentLoader.abort();var I=this.fragCurrent;I&&this.fragmentTracker.removeFragment(I),this.resetTransmuxer(),this.fragCurrent=null,this.fragPrevious=null,this.clearInterval(),this.clearNextTick(),this.state=O.STOPPED},T._streamEnded=function(I,P){var G=this.fragCurrent,W=this.fragmentTracker;if(!P.live&&G&&G.sn===P.endSN&&!I.nextStart){var H=W.getState(G);return H===y.FragmentState.PARTIAL||H===y.FragmentState.OK}return!1},T.onMediaAttached=function(I,P){var G=this.media=this.mediaBuffer=P.media;this.onvseeking=this.onMediaSeeking.bind(this),this.onvended=this.onMediaEnded.bind(this),G.addEventListener("seeking",this.onvseeking),G.addEventListener("ended",this.onvended);var W=this.config;this.levels&&W.autoStartLoad&&this.state===O.STOPPED&&this.startLoad(W.startPosition)},T.onMediaDetaching=function(){var I=this.media;I!=null&&I.ended&&(this.log("MSE detaching and video ended, reset startPosition"),this.startPosition=this.lastCurrentTime=0),I&&(I.removeEventListener("seeking",this.onvseeking),I.removeEventListener("ended",this.onvended),this.onvseeking=this.onvended=null),this.media=this.mediaBuffer=null,this.loadedmetadata=!1,this.fragmentTracker.removeAllFragments(),this.stopLoad()},T.onMediaSeeking=function(){var I=this.config,P=this.fragCurrent,G=this.media,W=this.mediaBuffer,H=this.state,z=G?G.currentTime:0,B=w.BufferHelper.bufferInfo(W||G,z,I.maxBufferHole);if(this.log("media seeking to "+(Object(M.isFiniteNumber)(z)?z.toFixed(3):z)+", state: "+H),H===O.ENDED)this.resetLoadingState();else if(P&&!B.len){var k=I.maxFragLookUpTolerance,K=P.start-k,Y=P.start+P.duration+k,ne=z>Y;(z<K||ne)&&(ne&&P.loader&&(this.log("seeking outside of buffer while fragment load in progress, cancel fragment load"),P.loader.abort()),this.resetLoadingState())}G&&(this.lastCurrentTime=z),!this.loadedmetadata&&!B.len&&(this.nextLoadPosition=this.startPosition=z),this.tickImmediate()},T.onMediaEnded=function(){this.startPosition=this.lastCurrentTime=0},T.onKeyLoaded=function(I,P){if(this.state!==O.KEY_LOADING||P.frag!==this.fragCurrent||!this.levels)return;this.state=O.IDLE;var G=this.levels[P.frag.level].details;G&&this.loadFragment(P.frag,G,P.frag.start)},T.onHandlerDestroying=function(){this.stopLoad(),_.prototype.onHandlerDestroying.call(this)},T.onHandlerDestroyed=function(){this.state=O.STOPPED,this.hls.off(p.Events.KEY_LOADED,this.onKeyLoaded,this),this.fragmentLoader&&this.fragmentLoader.destroy(),this.decrypter&&this.decrypter.destroy(),this.hls=this.log=this.warn=this.decrypter=this.fragmentLoader=this.fragmentTracker=null,_.prototype.onHandlerDestroyed.call(this)},T.loadKey=function(I,P){this.log("Loading key for "+I.sn+" of ["+P.startSN+"-"+P.endSN+"], "+(this.logPrefix==="[stream-controller]"?"level":"track")+" "+I.level),this.state=O.KEY_LOADING,this.fragCurrent=I,this.hls.trigger(p.Events.KEY_LOADING,{frag:I})},T.loadFragment=function(I,P,G){this._loadFragForPlayback(I,P,G)},T._loadFragForPlayback=function(I,P,G){var W=this,H=function(B){if(W.fragContextChanged(I)){W.warn("Fragment "+I.sn+(B.part?" p: "+B.part.index:"")+" of level "+I.level+" was dropped during download."),W.fragmentTracker.removeFragment(I);return}I.stats.chunkCount++,W._handleFragmentLoadProgress(B)};this._doFragLoad(I,P,G,H).then(function(z){if(!z)return;W.fragLoadError=0;var B=W.state;if(W.fragContextChanged(I)){(B===O.FRAG_LOADING||B===O.BACKTRACKING||!W.fragCurrent&&B===O.PARSING)&&(W.fragmentTracker.removeFragment(I),W.state=O.IDLE);return}if("payload"in z&&(W.log("Loaded fragment "+I.sn+" of level "+I.level),W.hls.trigger(p.Events.FRAG_LOADED,z),W.state===O.BACKTRACKING)){W.fragmentTracker.backtrack(I,z),W.resetFragmentLoading(I);return}W._handleFragmentLoadComplete(z)}).catch(function(z){W.warn(z),W.resetFragmentLoading(I)})},T.flushMainBuffer=function(I,P,G){if(G===void 0&&(G=null),!(I-P))return;var W={startOffset:I,endOffset:P,type:G};this.fragLoadError=0,this.hls.trigger(p.Events.BUFFER_FLUSHING,W)},T._loadInitSegment=function(I){var P=this;this._doFragLoad(I).then(function(G){if(!G||P.fragContextChanged(I)||!P.levels)throw new Error("init load aborted");return G}).then(function(G){var W=P.hls,H=G.payload,z=I.decryptdata;if(H&&H.byteLength>0&&z&&z.key&&z.iv&&z.method==="AES-128"){var B=self.performance.now();return P.decrypter.webCryptoDecrypt(new Uint8Array(H),z.key.buffer,z.iv.buffer).then(function(k){var K=self.performance.now();return W.trigger(p.Events.FRAG_DECRYPTED,{frag:I,payload:k,stats:{tstart:B,tdecrypt:K}}),G.payload=k,G})}return G}).then(function(G){var W=P.fragCurrent,H=P.hls,z=P.levels;if(!z)throw new Error("init load aborted, missing levels");var B=z[I.level].details;console.assert(B,"Level details are defined when init segment is loaded");var k=I.stats;P.state=O.IDLE,P.fragLoadError=0,I.data=new Uint8Array(G.payload),k.parsing.start=k.buffering.start=self.performance.now(),k.parsing.end=k.buffering.end=self.performance.now(),G.frag===W&&H.trigger(p.Events.FRAG_BUFFERED,{stats:k,frag:W,part:null,id:I.type}),P.tick()}).catch(function(G){P.warn(G),P.resetFragmentLoading(I)})},T.fragContextChanged=function(I){var P=this.fragCurrent;return!I||!P||I.level!==P.level||I.sn!==P.sn||I.urlId!==P.urlId},T.fragBufferedComplete=function(I,P){var G=this.mediaBuffer?this.mediaBuffer:this.media;this.log("Buffered "+I.type+" sn: "+I.sn+(P?" part: "+P.index:"")+" of "+(this.logPrefix==="[stream-controller]"?"level":"track")+" "+I.level+" "+s.default.toString(w.BufferHelper.getBuffered(G))),this.state=O.IDLE,this.tick()},T._handleFragmentLoadComplete=function(I){var P=this.transmuxer;if(!P)return;var G=I.frag,W=I.part,H=I.partsLoaded,z=!H||H.length===0||H.some(function(k){return!k}),B=new n.ChunkMetadata(G.level,G.sn,G.stats.chunkCount+1,0,W?W.index:-1,!z);P.flush(B)},T._handleFragmentLoadProgress=function(I){},T._doFragLoad=function(I,P,G,W){var H=this;if(G===void 0&&(G=null),!this.levels)throw new Error("frag load aborted, missing levels");if(G=Math.max(I.start,G||0),this.config.lowLatencyMode&&P){var z=P.partList;if(z&&W){G>I.end&&P.fragmentHint&&(I=P.fragmentHint);var B=this.getNextPart(z,I,G);if(B>-1){var k=z[B];return this.log("Loading part sn: "+I.sn+" p: "+k.index+" cc: "+I.cc+" of playlist ["+P.startSN+"-"+P.endSN+"] parts [0-"+B+"-"+(z.length-1)+"] "+(this.logPrefix==="[stream-controller]"?"level":"track")+": "+I.level+", target: "+parseFloat(G.toFixed(3))),this.nextLoadPosition=k.start+k.duration,this.state=O.FRAG_LOADING,this.hls.trigger(p.Events.FRAG_LOADING,{frag:I,part:z[B],targetBufferTime:G}),this.doFragPartsLoad(I,z,B,W).catch(function(K){return H.handleFragLoadError(K)})}else if(!I.url||this.loadedEndOfParts(z,G))return Promise.resolve(null)}}return this.log("Loading fragment "+I.sn+" cc: "+I.cc+" "+(P?"of ["+P.startSN+"-"+P.endSN+"] ":"")+(this.logPrefix==="[stream-controller]"?"level":"track")+": "+I.level+", target: "+parseFloat(G.toFixed(3))),Object(M.isFiniteNumber)(I.sn)&&!this.bitrateTest&&(this.nextLoadPosition=I.start+I.duration),this.state=O.FRAG_LOADING,this.hls.trigger(p.Events.FRAG_LOADING,{frag:I,targetBufferTime:G}),this.fragmentLoader.load(I,W).catch(function(K){return H.handleFragLoadError(K)})},T.doFragPartsLoad=function(I,P,G,W){var H=this;return new Promise(function(z,B){var k=[],K=function Y(ne){var oe=P[ne];H.fragmentLoader.loadPart(I,oe,W).then(function(_e){k[oe.index]=_e;var xe=_e.part;H.hls.trigger(p.Events.FRAG_LOADED,_e);var le=P[ne+1];if(le&&le.fragment===I)Y(ne+1);else return z({frag:I,part:xe,partsLoaded:k})}).catch(B)};K(G)})},T.handleFragLoadError=function(I){var P=I.data;return P&&P.details===d.ErrorDetails.INTERNAL_ABORTED?this.handleFragLoadAborted(P.frag,P.part):this.hls.trigger(p.Events.ERROR,P),null},T._handleTransmuxerFlush=function(I){var P=this.getCurrentContext(I);if(!P||this.state!==O.PARSING){this.fragCurrent||(this.state=O.IDLE);return}var G=P.frag,W=P.part,H=P.level,z=self.performance.now();G.stats.parsing.end=z,W&&(W.stats.parsing.end=z),this.updateLevelTiming(G,W,H,I.partial)},T.getCurrentContext=function(I){var P=this.levels,G=I.level,W=I.sn,H=I.part;if(!P||!P[G])return this.warn("Levels object was unset while buffering fragment "+W+" of level "+G+". The current chunk will not be buffered."),null;var z=P[G],B=H>-1?Object(o.getPartWith)(z,W,H):null,k=B?B.fragment:Object(o.getFragmentWithSN)(z,W,this.fragCurrent);return k?{frag:k,part:B,level:z}:null},T.bufferFragmentData=function(I,P,G,W){if(!I||this.state!==O.PARSING)return;var H=I.data1,z=I.data2,B=H;if(H&&z&&(B=Object(c.appendUint8Array)(H,z)),!B||!B.length)return;var k={type:I.type,frag:P,part:G,chunkMeta:W,parent:P.type,data:B};this.hls.trigger(p.Events.BUFFER_APPENDING,k),I.dropped&&I.independent&&!G&&this.flushBufferGap(P)},T.flushBufferGap=function(I){var P=this.media;if(!P)return;if(!w.BufferHelper.isBuffered(P,P.currentTime)){this.flushMainBuffer(0,I.start);return}var G=P.currentTime,W=w.BufferHelper.bufferInfo(P,G,0),H=I.duration,z=Math.min(this.config.maxFragLookUpTolerance*2,H*.25),B=Math.max(Math.min(I.start-z,W.end-z),G+z);I.start-B>z&&this.flushMainBuffer(B,I.start)},T.getFwdBufferInfo=function(I,P){var G=this.config,W=this.getLoadPosition();if(!Object(M.isFiniteNumber)(W))return null;var H=w.BufferHelper.bufferInfo(I,W,G.maxBufferHole);if(H.len===0&&H.nextStart!==void 0){var z=this.fragmentTracker.getBufferedFrag(W,P);if(z&&H.nextStart<z.end)return w.BufferHelper.bufferInfo(I,W,Math.max(H.nextStart,G.maxBufferHole))}return H},T.getMaxBufferLength=function(I){var P=this.config,G;return I?G=Math.max(8*P.maxBufferSize/I,P.maxBufferLength):G=P.maxBufferLength,Math.min(G,P.maxMaxBufferLength)},T.reduceMaxBufferLength=function(I){var P=this.config,G=I||P.maxBufferLength;return P.maxMaxBufferLength>=G?(P.maxMaxBufferLength/=2,this.warn("Reduce max buffer length to "+P.maxMaxBufferLength+"s"),!0):!1},T.getNextFragment=function(I,P){var G,W,H=P.fragments,z=H.length;if(!z)return null;var B=this.config,k=H[0].start,K;if(P.live){var Y=B.initialLiveManifestSize;if(z<Y)return this.warn("Not enough fragments to start playback (have: "+z+", need: "+Y+")"),null;!P.PTSKnown&&!this.startFragRequested&&this.startPosition===-1&&(K=this.getInitialLiveFragment(P,H),this.startPosition=K?this.hls.liveSyncPosition||K.start:I)}else I<=k&&(K=H[0]);if(!K){var ne=B.lowLatencyMode?P.partEnd:P.fragmentEnd;K=this.getFragmentAtPosition(I,ne,P)}return(G=K)!==null&&G!==void 0&&G.initSegment&&!((W=K)!==null&&W!==void 0&&W.initSegment.data)&&!this.bitrateTest&&(K=K.initSegment),K},T.getNextPart=function(I,P,G){for(var W=-1,H=!1,z=!0,B=0,k=I.length;B<k;B++){var K=I[B];if(z=z&&!K.independent,W>-1&&G<K.start)break;var Y=K.loaded;!Y&&(H||K.independent||z)&&K.fragment===P&&(W=B),H=Y}return W},T.loadedEndOfParts=function(I,P){var G=I[I.length-1];return G&&P>G.start&&G.loaded},T.getInitialLiveFragment=function(I,P){var G=this.fragPrevious,W=null;if(G){if(I.hasProgramDateTime&&(this.log("Live playlist, switching playlist, load frag with same PDT: "+G.programDateTime),W=Object(i.findFragmentByPDT)(P,G.endProgramDateTime,this.config.maxFragLookUpTolerance)),!W){var H=G.sn+1;if(H>=I.startSN&&H<=I.endSN){var z=P[H-I.startSN];G.cc===z.cc&&(W=z,this.log("Live playlist, switching playlist, load frag with next SN: "+W.sn))}W||(W=Object(i.findFragWithCC)(P,G.cc),W&&this.log("Live playlist, switching playlist, load frag with same CC: "+W.sn))}}else{var B=this.hls.liveSyncPosition;B!==null&&(W=this.getFragmentAtPosition(B,this.bitrateTest?I.fragmentEnd:I.edge,I))}return W},T.getFragmentAtPosition=function(I,P,G){var W=this.config,H=this.fragPrevious,z=G.fragments,B=G.endSN,k=G.fragmentHint,K=W.maxFragLookUpTolerance,Y=!!(W.lowLatencyMode&&G.partList&&k);Y&&k&&!this.bitrateTest&&(z=z.concat(k),B=k.sn);var ne;if(I<P){var oe=I>P-K?0:K;ne=Object(i.findFragmentByPTS)(H,z,I,oe)}else ne=z[z.length-1];if(ne){var _e=ne.sn-G.startSN,xe=H&&ne.level===H.level,le=z[_e+1],me=this.fragmentTracker.getState(ne);if(me===y.FragmentState.BACKTRACKED){ne=null;for(var de=_e;z[de]&&this.fragmentTracker.getState(z[de])===y.FragmentState.BACKTRACKED;)H?ne=z[de--]:ne=z[--de];ne||(ne=le)}else H&&ne.sn===H.sn&&!Y&&(xe&&(ne.sn<B&&this.fragmentTracker.getState(le)!==y.FragmentState.OK?(this.log("SN "+ne.sn+" just loaded, load next one: "+le.sn),ne=le):ne=null))}return ne},T.synchronizeToLiveEdge=function(I){var P=this.config,G=this.media;if(!G)return;var W=this.hls.liveSyncPosition,H=G.currentTime,z=I.fragments[0].start,B=I.edge,k=H>=z-P.maxFragLookUpTolerance&&H<=B;if(W!==null&&G.duration>W&&(H<W||!k)){var K=P.liveMaxLatencyDuration!==void 0?P.liveMaxLatencyDuration:P.liveMaxLatencyDurationCount*I.targetduration;(!k&&G.readyState<4||H<B-K)&&(this.loadedmetadata||(this.nextLoadPosition=W),G.readyState&&(this.warn("Playback: "+H.toFixed(3)+" is located too far from the end of live sliding playlist: "+B+", reset currentTime to : "+W.toFixed(3)),G.currentTime=W))}},T.alignPlaylists=function(I,P){var G=this.levels,W=this.levelLastLoaded,H=this.fragPrevious,z=W!==null?G[W]:null,B=I.fragments.length;if(!B)return this.warn("No fragments in live playlist"),0;var k=I.fragments[0].start,K=!P,Y=I.alignedSliding&&Object(M.isFiniteNumber)(k);if(K||!Y&&!k){Object(r.alignStream)(H,z,I);var ne=I.fragments[0].start;return this.log("Live playlist sliding: "+ne.toFixed(2)+" start-sn: "+(P?P.startSN:"na")+"->"+I.startSN+" prev-sn: "+(H?H.sn:"na")+" fragments: "+B),ne}return k},T.waitForCdnTuneIn=function(I){var P=3;return I.live&&I.canBlockReload&&I.tuneInGoal>Math.max(I.partHoldBack,I.partTarget*P)},T.setStartPosition=function(I,P){var G=this.startPosition;if(G<P&&(G=-1),G===-1||this.lastCurrentTime===-1){var W=I.startTimeOffset;Object(M.isFiniteNumber)(W)?(G=P+W,W<0&&(G+=I.totalduration),G=Math.min(Math.max(P,G),P+I.totalduration),this.log("Start time offset "+W+" found in playlist, adjust startPosition to "+G),this.startPosition=G):I.live?G=this.hls.liveSyncPosition||P:this.startPosition=G=0,this.lastCurrentTime=G}this.nextLoadPosition=G},T.getLoadPosition=function(){var I=this.media,P=0;return this.loadedmetadata&&I?P=I.currentTime:this.nextLoadPosition&&(P=this.nextLoadPosition),P},T.handleFragLoadAborted=function(I,P){this.transmuxer&&I.sn!=="initSegment"&&I.stats.aborted&&(this.warn("Fragment "+I.sn+(P?" part"+P.index:"")+" of level "+I.level+" was aborted"),this.resetFragmentLoading(I))},T.resetFragmentLoading=function(I){(!this.fragCurrent||!this.fragContextChanged(I))&&(this.state=O.IDLE)},T.onFragmentOrKeyLoadError=function(I,P){if(P.fatal)return;var G=P.frag;if(!G||G.type!==I)return;var W=this.fragCurrent;console.assert(W&&G.sn===W.sn&&G.level===W.level&&G.urlId===W.urlId,"Frag load error must match current frag to retry");var H=this.config;if(this.fragLoadError+1<=H.fragLoadingMaxRetry){if(this.resetLiveStartWhenNotLoaded(G.level))return;var z=Math.min(Math.pow(2,this.fragLoadError)*H.fragLoadingRetryDelay,H.fragLoadingMaxRetryTimeout);this.warn("Fragment "+G.sn+" of "+I+" "+G.level+" failed to load, retrying in "+z+"ms"),this.retryDate=self.performance.now()+z,this.fragLoadError++,this.state=O.FRAG_LOADING_WAITING_RETRY}else P.levelRetry?(I===l.PlaylistLevelType.AUDIO&&(this.fragCurrent=null),this.fragLoadError=0,this.state=O.IDLE):(b.logger.error(P.details+" reaches max retry, redispatch as fatal ..."),P.fatal=!0,this.hls.stopLoad(),this.state=O.ERROR)},T.afterBufferFlushed=function(I,P,G){if(!I)return;var W=w.BufferHelper.getBuffered(I);this.fragmentTracker.detectEvictedFragments(P,W,G),this.state===O.ENDED&&this.resetLoadingState()},T.resetLoadingState=function(){this.fragCurrent=null,this.fragPrevious=null,this.state=O.IDLE},T.resetLiveStartWhenNotLoaded=function(I){if(!this.loadedmetadata){this.startFragRequested=!1;var P=this.levels?this.levels[I].details:null;if(P!=null&&P.live)return this.startPosition=-1,this.setStartPosition(P,0),this.resetLoadingState(),!0;this.nextLoadPosition=this.startPosition}return!1},T.updateLevelTiming=function(I,P,G,W){var H=this,z=G.details;console.assert(!!z,"level.details must be defined");var B=Object.keys(I.elementaryStreams).reduce(function(k,K){var Y=I.elementaryStreams[K];if(Y){var ne=Y.endPTS-Y.startPTS;if(ne<=0)return H.warn("Could not parse fragment "+I.sn+" "+K+" duration reliably ("+ne+") resetting transmuxer to fallback to playlist timing"),H.resetTransmuxer(),k||!1;var oe=W?0:Object(o.updateFragPTSDTS)(z,I,Y.startPTS,Y.endPTS,Y.startDTS,Y.endDTS);return H.hls.trigger(p.Events.LEVEL_PTS_UPDATED,{details:z,level:G,drift:oe,type:K,frag:I,start:Y.startPTS,end:Y.endPTS}),!0}return k},!1);B?(this.state=O.PARSED,this.hls.trigger(p.Events.FRAG_PARSED,{frag:I,part:P})):this.resetLoadingState()},T.resetTransmuxer=function(){this.transmuxer&&(this.transmuxer.destroy(),this.transmuxer=null)},S(E,[{key:"state",get:function(){return this._state},set:function(I){var P=this._state;P!==I&&(this._state=I,this.log(P+"->"+I))}}]),E}(m.default)},"./src/controller/buffer-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return i});var M=C("./src/polyfills/number.ts"),m=C("./src/events.ts"),y=C("./src/utils/logger.ts"),w=C("./src/errors.ts"),b=C("./src/utils/buffer-helper.ts"),p=C("./src/utils/mediasource-helper.ts"),d=C("./src/loader/fragment.ts"),n=C("./src/controller/buffer-operation-queue.ts"),c=Object(p.getMediaSource)(),r=/([ha]vc.)(?:\.[^.,]+)+/,i=function(){function o(f){var s=this;this.details=null,this._objectUrl=null,this.operationQueue=void 0,this.listeners=void 0,this.hls=void 0,this.bufferCodecEventsExpected=0,this._bufferCodecEventsTotal=0,this.media=null,this.mediaSource=null,this.appendError=0,this.tracks={},this.pendingTracks={},this.sourceBuffer=void 0,this._onMediaSourceOpen=function(){var l=s.hls,t=s.media,S=s.mediaSource;y.logger.log("[buffer-controller]: Media source opened"),t&&(s.updateMediaElementDuration(),l.trigger(m.Events.MEDIA_ATTACHED,{media:t})),S&&S.removeEventListener("sourceopen",s._onMediaSourceOpen),s.checkPendingTracks()},this._onMediaSourceClose=function(){y.logger.log("[buffer-controller]: Media source closed")},this._onMediaSourceEnded=function(){y.logger.log("[buffer-controller]: Media source ended")},this.hls=f,this._initSourceBuffer(),this.registerListeners()}var u=o.prototype;return u.hasSourceTypes=function(){return this.getSourceBufferTypes().length>0||Object.keys(this.pendingTracks).length>0},u.destroy=function(){this.unregisterListeners(),this.details=null},u.registerListeners=function(){var s=this.hls;s.on(m.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),s.on(m.Events.MEDIA_DETACHING,this.onMediaDetaching,this),s.on(m.Events.MANIFEST_PARSED,this.onManifestParsed,this),s.on(m.Events.BUFFER_RESET,this.onBufferReset,this),s.on(m.Events.BUFFER_APPENDING,this.onBufferAppending,this),s.on(m.Events.BUFFER_CODECS,this.onBufferCodecs,this),s.on(m.Events.BUFFER_EOS,this.onBufferEos,this),s.on(m.Events.BUFFER_FLUSHING,this.onBufferFlushing,this),s.on(m.Events.LEVEL_UPDATED,this.onLevelUpdated,this),s.on(m.Events.FRAG_PARSED,this.onFragParsed,this),s.on(m.Events.FRAG_CHANGED,this.onFragChanged,this)},u.unregisterListeners=function(){var s=this.hls;s.off(m.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),s.off(m.Events.MEDIA_DETACHING,this.onMediaDetaching,this),s.off(m.Events.MANIFEST_PARSED,this.onManifestParsed,this),s.off(m.Events.BUFFER_RESET,this.onBufferReset,this),s.off(m.Events.BUFFER_APPENDING,this.onBufferAppending,this),s.off(m.Events.BUFFER_CODECS,this.onBufferCodecs,this),s.off(m.Events.BUFFER_EOS,this.onBufferEos,this),s.off(m.Events.BUFFER_FLUSHING,this.onBufferFlushing,this),s.off(m.Events.LEVEL_UPDATED,this.onLevelUpdated,this),s.off(m.Events.FRAG_PARSED,this.onFragParsed,this),s.off(m.Events.FRAG_CHANGED,this.onFragChanged,this)},u._initSourceBuffer=function(){this.sourceBuffer={},this.operationQueue=new n.default(this.sourceBuffer),this.listeners={audio:[],video:[],audiovideo:[]}},u.onManifestParsed=function(s,l){var t=2;(l.audio&&!l.video||!l.altAudio)&&(t=1),this.bufferCodecEventsExpected=this._bufferCodecEventsTotal=t,this.details=null,y.logger.log(this.bufferCodecEventsExpected+" bufferCodec event(s) expected")},u.onMediaAttaching=function(s,l){var t=this.media=l.media;if(t&&c){var S=this.mediaSource=new c;S.addEventListener("sourceopen",this._onMediaSourceOpen),S.addEventListener("sourceended",this._onMediaSourceEnded),S.addEventListener("sourceclose",this._onMediaSourceClose),t.src=self.URL.createObjectURL(S),this._objectUrl=t.src}},u.onMediaDetaching=function(){var s=this.media,l=this.mediaSource,t=this._objectUrl;if(l){if(y.logger.log("[buffer-controller]: media source detaching"),l.readyState==="open")try{l.endOfStream()}catch(S){y.logger.warn("[buffer-controller]: onMediaDetaching: "+S.message+" while calling endOfStream")}this.onBufferReset(),l.removeEventListener("sourceopen",this._onMediaSourceOpen),l.removeEventListener("sourceended",this._onMediaSourceEnded),l.removeEventListener("sourceclose",this._onMediaSourceClose),s&&(t&&self.URL.revokeObjectURL(t),s.src===t?(s.removeAttribute("src"),s.load()):y.logger.warn("[buffer-controller]: media.src was changed by a third party - skip cleanup")),this.mediaSource=null,this.media=null,this._objectUrl=null,this.bufferCodecEventsExpected=this._bufferCodecEventsTotal,this.pendingTracks={},this.tracks={}}this.hls.trigger(m.Events.MEDIA_DETACHED,void 0)},u.onBufferReset=function(){var s=this;this.getSourceBufferTypes().forEach(function(l){var t=s.sourceBuffer[l];try{t&&(s.removeBufferListeners(l),s.mediaSource&&s.mediaSource.removeSourceBuffer(t),s.sourceBuffer[l]=void 0)}catch(S){y.logger.warn("[buffer-controller]: Failed to reset the "+l+" buffer",S)}}),this._initSourceBuffer()},u.onBufferCodecs=function(s,l){var t=this,S=this.getSourceBufferTypes().length;if(Object.keys(l).forEach(function(x){if(S){var h=t.tracks[x];if(h&&typeof h.buffer.changeType=="function"){var R=l[x],O=R.codec,g=R.levelCodec,_=R.container,E=(h.levelCodec||h.codec).replace(r,"$1"),T=(g||O).replace(r,"$1");if(E!==T){var L=_+";codecs="+(g||O);t.appendChangeType(x,L)}}}else t.pendingTracks[x]=l[x]}),S)return;this.bufferCodecEventsExpected=Math.max(this.bufferCodecEventsExpected-1,0),this.mediaSource&&this.mediaSource.readyState==="open"&&this.checkPendingTracks()},u.appendChangeType=function(s,l){var t=this,S=this.operationQueue,x={execute:function(){var R=t.sourceBuffer[s];R&&(y.logger.log("[buffer-controller]: changing "+s+" sourceBuffer type to "+l),R.changeType(l)),S.shiftAndExecuteNext(s)},onStart:function(){},onComplete:function(){},onError:function(R){y.logger.warn("[buffer-controller]: Failed to change "+s+" SourceBuffer type",R)}};S.append(x,s)},u.onBufferAppending=function(s,l){var t=this,S=this.hls,x=this.operationQueue,h=this.tracks,R=l.data,O=l.type,g=l.frag,_=l.part,E=l.chunkMeta,T=E.buffering[O],L=self.performance.now();T.start=L;var I=g.stats.buffering,P=_?_.stats.buffering:null;I.start===0&&(I.start=L),P&&P.start===0&&(P.start=L);var G=h.audio,W=O==="audio"&&E.id===1&&(G==null?void 0:G.container)==="audio/mpeg",H={execute:function(){if(T.executeStart=self.performance.now(),W){var B=t.sourceBuffer[O];if(B){var k=g.start-B.timestampOffset;Math.abs(k)>=.1&&(y.logger.log("[buffer-controller]: Updating audio SourceBuffer timestampOffset to "+g.start+" (delta: "+k+") sn: "+g.sn+")"),B.timestampOffset=g.start)}}t.appendExecutor(R,O)},onStart:function(){},onComplete:function(){var B=self.performance.now();T.executeEnd=T.end=B,I.first===0&&(I.first=B),P&&P.first===0&&(P.first=B);var k=t.sourceBuffer,K={};for(var Y in k)K[Y]=b.BufferHelper.getBuffered(k[Y]);t.appendError=0,t.hls.trigger(m.Events.BUFFER_APPENDED,{type:O,frag:g,part:_,chunkMeta:E,parent:g.type,timeRanges:K})},onError:function(B){y.logger.error("[buffer-controller]: Error encountered while trying to append to the "+O+" SourceBuffer",B);var k={type:w.ErrorTypes.MEDIA_ERROR,parent:g.type,details:w.ErrorDetails.BUFFER_APPEND_ERROR,err:B,fatal:!1};B.code===DOMException.QUOTA_EXCEEDED_ERR?k.details=w.ErrorDetails.BUFFER_FULL_ERROR:(t.appendError++,k.details=w.ErrorDetails.BUFFER_APPEND_ERROR,t.appendError>S.config.appendErrorMaxRetry&&(y.logger.error("[buffer-controller]: Failed "+S.config.appendErrorMaxRetry+" times to append segment in sourceBuffer"),k.fatal=!0)),S.trigger(m.Events.ERROR,k)}};x.append(H,O)},u.onBufferFlushing=function(s,l){var t=this,S=this.operationQueue,x=function(R){return{execute:t.removeExecutor.bind(t,R,l.startOffset,l.endOffset),onStart:function(){},onComplete:function(){t.hls.trigger(m.Events.BUFFER_FLUSHED,{type:R})},onError:function(g){y.logger.warn("[buffer-controller]: Failed to remove from "+R+" SourceBuffer",g)}}};l.type?S.append(x(l.type),l.type):this.getSourceBufferTypes().forEach(function(h){S.append(x(h),h)})},u.onFragParsed=function(s,l){var t=this,S=l.frag,x=l.part,h=[],R=x?x.elementaryStreams:S.elementaryStreams;R[d.ElementaryStreamTypes.AUDIOVIDEO]?h.push("audiovideo"):(R[d.ElementaryStreamTypes.AUDIO]&&h.push("audio"),R[d.ElementaryStreamTypes.VIDEO]&&h.push("video"));var O=function(){var _=self.performance.now();S.stats.buffering.end=_,x&&(x.stats.buffering.end=_);var E=x?x.stats:S.stats;t.hls.trigger(m.Events.FRAG_BUFFERED,{frag:S,part:x,stats:E,id:S.type})};h.length===0&&y.logger.warn("Fragments must have at least one ElementaryStreamType set. type: "+S.type+" level: "+S.level+" sn: "+S.sn),this.blockBuffers(O,h)},u.onFragChanged=function(s,l){this.flushBackBuffer()},u.onBufferEos=function(s,l){var t=this,S=this.getSourceBufferTypes().reduce(function(x,h){var R=t.sourceBuffer[h];return(!l.type||l.type===h)&&(R&&!R.ended&&(R.ended=!0,y.logger.log("[buffer-controller]: "+h+" sourceBuffer now EOS"))),x&&!!(!R||R.ended)},!0);S&&this.blockBuffers(function(){var x=t.mediaSource;if(!x||x.readyState!=="open")return;x.endOfStream()})},u.onLevelUpdated=function(s,l){var t=l.details;if(!t.fragments.length)return;this.details=t,this.getSourceBufferTypes().length?this.blockBuffers(this.updateMediaElementDuration.bind(this)):this.updateMediaElementDuration()},u.flushBackBuffer=function(){var s=this.hls,l=this.details,t=this.media,S=this.sourceBuffer;if(!t||l===null)return;var x=this.getSourceBufferTypes();if(!x.length)return;var h=l.live&&s.config.liveBackBufferLength!==null?s.config.liveBackBufferLength:s.config.backBufferLength;if(!Object(M.isFiniteNumber)(h)||h<0)return;var R=t.currentTime,O=l.levelTargetDuration,g=Math.max(h,O),_=Math.floor(R/O)*O-g;x.forEach(function(E){var T=S[E];if(T){var L=b.BufferHelper.getBuffered(T);L.length>0&&_>L.start(0)&&(s.trigger(m.Events.BACK_BUFFER_REACHED,{bufferEnd:_}),l.live&&s.trigger(m.Events.LIVE_BACK_BUFFER_REACHED,{bufferEnd:_}),s.trigger(m.Events.BUFFER_FLUSHING,{startOffset:0,endOffset:_,type:E}))}})},u.updateMediaElementDuration=function(){if(!this.details||!this.media||!this.mediaSource||this.mediaSource.readyState!=="open")return;var s=this.details,l=this.hls,t=this.media,S=this.mediaSource,x=s.fragments[0].start+s.totalduration,h=t.duration,R=Object(M.isFiniteNumber)(S.duration)?S.duration:0;s.live&&l.config.liveDurationInfinity?(y.logger.log("[buffer-controller]: Media Source duration is set to Infinity"),S.duration=Infinity,this.updateSeekableRange(s)):(x>R&&x>h||!Object(M.isFiniteNumber)(h))&&(y.logger.log("[buffer-controller]: Updating Media Source duration to "+x.toFixed(3)),S.duration=x)},u.updateSeekableRange=function(s){var l=this.mediaSource,t=s.fragments,S=t.length;if(S&&s.live&&l!==null&&l!==void 0&&l.setLiveSeekableRange){var x=Math.max(0,t[0].start),h=Math.max(x,x+s.totalduration);l.setLiveSeekableRange(x,h)}},u.checkPendingTracks=function(){var s=this.bufferCodecEventsExpected,l=this.operationQueue,t=this.pendingTracks,S=Object.keys(t).length;if(S&&!s||S===2){this.createSourceBuffers(t),this.pendingTracks={};var x=this.getSourceBufferTypes();if(x.length===0){this.hls.trigger(m.Events.ERROR,{type:w.ErrorTypes.MEDIA_ERROR,details:w.ErrorDetails.BUFFER_INCOMPATIBLE_CODECS_ERROR,fatal:!0,reason:"could not create source buffer for media codec(s)"});return}x.forEach(function(h){l.executeNext(h)})}},u.createSourceBuffers=function(s){var l=this.sourceBuffer,t=this.mediaSource;if(!t)throw Error("createSourceBuffers called when mediaSource was null");var S=0;for(var x in s)if(!l[x]){var h=s[x];if(!h)throw Error("source buffer exists for track "+x+", however track does not");var R=h.levelCodec||h.codec,O=h.container+";codecs="+R;y.logger.log("[buffer-controller]: creating sourceBuffer("+O+")");try{var g=l[x]=t.addSourceBuffer(O),_=x;this.addBufferListener(_,"updatestart",this._onSBUpdateStart),this.addBufferListener(_,"updateend",this._onSBUpdateEnd),this.addBufferListener(_,"error",this._onSBUpdateError),this.tracks[x]={buffer:g,codec:R,container:h.container,levelCodec:h.levelCodec,id:h.id},S++}catch(E){y.logger.error("[buffer-controller]: error while trying to add sourceBuffer: "+E.message),this.hls.trigger(m.Events.ERROR,{type:w.ErrorTypes.MEDIA_ERROR,details:w.ErrorDetails.BUFFER_ADD_CODEC_ERROR,fatal:!1,error:E,mimeType:O})}}S&&this.hls.trigger(m.Events.BUFFER_CREATED,{tracks:this.tracks})},u._onSBUpdateStart=function(s){var l=this.operationQueue,t=l.current(s);t.onStart()},u._onSBUpdateEnd=function(s){var l=this.operationQueue,t=l.current(s);t.onComplete(),l.shiftAndExecuteNext(s)},u._onSBUpdateError=function(s,l){y.logger.error("[buffer-controller]: "+s+" SourceBuffer error",l),this.hls.trigger(m.Events.ERROR,{type:w.ErrorTypes.MEDIA_ERROR,details:w.ErrorDetails.BUFFER_APPENDING_ERROR,fatal:!1});var t=this.operationQueue.current(s);t&&t.onError(l)},u.removeExecutor=function(s,l,t){var S=this.media,x=this.mediaSource,h=this.operationQueue,R=this.sourceBuffer,O=R[s];if(!S||!x||!O){y.logger.warn("[buffer-controller]: Attempting to remove from the "+s+" SourceBuffer, but it does not exist"),h.shiftAndExecuteNext(s);return}var g=Object(M.isFiniteNumber)(S.duration)?S.duration:Infinity,_=Object(M.isFiniteNumber)(x.duration)?x.duration:Infinity,E=Math.max(0,l),T=Math.min(t,g,_);T>E?(y.logger.log("[buffer-controller]: Removing ["+E+","+T+"] from the "+s+" SourceBuffer"),console.assert(!O.updating,s+" sourceBuffer must not be updating"),O.remove(E,T)):h.shiftAndExecuteNext(s)},u.appendExecutor=function(s,l){var t=this.operationQueue,S=this.sourceBuffer,x=S[l];if(!x){y.logger.warn("[buffer-controller]: Attempting to append to the "+l+" SourceBuffer, but it does not exist"),t.shiftAndExecuteNext(l);return}x.ended=!1,console.assert(!x.updating,l+" sourceBuffer must not be updating"),x.appendBuffer(s)},u.blockBuffers=function(s,l){var t=this;if(l===void 0&&(l=this.getSourceBufferTypes()),!l.length){y.logger.log("[buffer-controller]: Blocking operation requested, but no SourceBuffers exist"),Promise.resolve(s);return}var S=this.operationQueue,x=l.map(function(h){return S.appendBlocker(h)});Promise.all(x).then(function(){s(),l.forEach(function(h){var R=t.sourceBuffer[h];(!R||!R.updating)&&S.shiftAndExecuteNext(h)})})},u.getSourceBufferTypes=function(){return Object.keys(this.sourceBuffer)},u.addBufferListener=function(s,l,t){var S=this.sourceBuffer[s];if(!S)return;var x=t.bind(this,s);this.listeners[s].push({event:l,listener:x}),S.addEventListener(l,x)},u.removeBufferListeners=function(s){var l=this.sourceBuffer[s];if(!l)return;this.listeners[s].forEach(function(t){l.removeEventListener(t.event,t.listener)})},o}()},"./src/controller/buffer-operation-queue.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return m});var M=C("./src/utils/logger.ts"),m=function(){function y(b){this.buffers=void 0,this.queues={video:[],audio:[],audiovideo:[]},this.buffers=b}var w=y.prototype;return w.append=function(p,d){var n=this.queues[d];n.push(p),n.length===1&&this.buffers[d]&&this.executeNext(d)},w.insertAbort=function(p,d){var n=this.queues[d];n.unshift(p),this.executeNext(d)},w.appendBlocker=function(p){var d,n=new Promise(function(r){d=r}),c={execute:d,onStart:function(){},onComplete:function(){},onError:function(){}};return this.append(c,p),n},w.executeNext=function(p){var d=this.buffers,n=this.queues,c=d[p],r=n[p];if(r.length){var i=r[0];try{i.execute()}catch(o){M.logger.warn("[buffer-operation-queue]: Unhandled exception executing the current operation"),i.onError(o),(!c||!c.updating)&&(r.shift(),this.executeNext(p))}}},w.shiftAndExecuteNext=function(p){this.queues[p].shift(),this.executeNext(p)},w.current=function(p){return this.queues[p][0]},y}()},"./src/controller/cap-level-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/events.ts");function m(b,p){for(var d=0;d<p.length;d++){var n=p[d];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(b,n.key,n)}}function y(b,p,d){return p&&m(b.prototype,p),d&&m(b,d),b}var w=function(){function b(d){this.autoLevelCapping=void 0,this.firstLevel=void 0,this.media=void 0,this.restrictedLevels=void 0,this.timer=void 0,this.hls=void 0,this.streamController=void 0,this.clientRect=void 0,this.hls=d,this.autoLevelCapping=Number.POSITIVE_INFINITY,this.firstLevel=-1,this.media=null,this.restrictedLevels=[],this.timer=void 0,this.clientRect=null,this.registerListeners()}var p=b.prototype;return p.setStreamController=function(n){this.streamController=n},p.destroy=function(){this.unregisterListener(),this.hls.config.capLevelToPlayerSize&&this.stopCapping(),this.media=null,this.clientRect=null,this.hls=this.streamController=null},p.registerListeners=function(){var n=this.hls;n.on(M.Events.FPS_DROP_LEVEL_CAPPING,this.onFpsDropLevelCapping,this),n.on(M.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),n.on(M.Events.MANIFEST_PARSED,this.onManifestParsed,this),n.on(M.Events.BUFFER_CODECS,this.onBufferCodecs,this),n.on(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this)},p.unregisterListener=function(){var n=this.hls;n.off(M.Events.FPS_DROP_LEVEL_CAPPING,this.onFpsDropLevelCapping,this),n.off(M.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),n.off(M.Events.MANIFEST_PARSED,this.onManifestParsed,this),n.off(M.Events.BUFFER_CODECS,this.onBufferCodecs,this),n.off(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this)},p.onFpsDropLevelCapping=function(n,c){b.isLevelAllowed(c.droppedLevel,this.restrictedLevels)&&this.restrictedLevels.push(c.droppedLevel)},p.onMediaAttaching=function(n,c){this.media=c.media instanceof HTMLVideoElement?c.media:null},p.onManifestParsed=function(n,c){var r=this.hls;this.restrictedLevels=[],this.firstLevel=c.firstLevel,r.config.capLevelToPlayerSize&&c.video&&this.startCapping()},p.onBufferCodecs=function(n,c){var r=this.hls;r.config.capLevelToPlayerSize&&c.video&&this.startCapping()},p.onMediaDetaching=function(){this.stopCapping()},p.detectPlayerSize=function(){if(this.media&&this.mediaHeight>0&&this.mediaWidth>0){var n=this.hls.levels;if(n.length){var c=this.hls;c.autoLevelCapping=this.getMaxLevel(n.length-1),c.autoLevelCapping>this.autoLevelCapping&&this.streamController&&this.streamController.nextLevelSwitch(),this.autoLevelCapping=c.autoLevelCapping}}},p.getMaxLevel=function(n){var c=this,r=this.hls.levels;if(!r.length)return-1;var i=r.filter(function(o,u){return b.isLevelAllowed(u,c.restrictedLevels)&&u<=n});return this.clientRect=null,b.getMaxLevelByMediaSize(i,this.mediaWidth,this.mediaHeight)},p.startCapping=function(){if(this.timer)return;this.autoLevelCapping=Number.POSITIVE_INFINITY,this.hls.firstLevel=this.getMaxLevel(this.firstLevel),self.clearInterval(this.timer),this.timer=self.setInterval(this.detectPlayerSize.bind(this),1e3),this.detectPlayerSize()},p.stopCapping=function(){this.restrictedLevels=[],this.firstLevel=-1,this.autoLevelCapping=Number.POSITIVE_INFINITY,this.timer&&(self.clearInterval(this.timer),this.timer=void 0)},p.getDimensions=function(){if(this.clientRect)return this.clientRect;var n=this.media,c={width:0,height:0};if(n){var r=n.getBoundingClientRect();c.width=r.width,c.height=r.height,!c.width&&!c.height&&(c.width=r.right-r.left||n.width||0,c.height=r.bottom-r.top||n.height||0)}return this.clientRect=c,c},b.isLevelAllowed=function(n,c){return c===void 0&&(c=[]),c.indexOf(n)===-1},b.getMaxLevelByMediaSize=function(n,c,r){if(!n||!n.length)return-1;for(var i=function(l,t){return t?l.width!==t.width||l.height!==t.height:!0},o=n.length-1,u=0;u<n.length;u+=1){var f=n[u];if((f.width>=c||f.height>=r)&&i(f,n[u+1])){o=u;break}}return o},y(b,[{key:"mediaWidth",get:function(){return this.getDimensions().width*b.contentScaleFactor}},{key:"mediaHeight",get:function(){return this.getDimensions().height*b.contentScaleFactor}}],[{key:"contentScaleFactor",get:function(){var n=1;try{n=self.devicePixelRatio}catch(c){}return n}}]),b}();v.default=w},"./src/controller/cmcd-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return i});var M=C("./src/events.ts"),m=C("./src/types/cmcd.ts"),y=C("./src/utils/buffer-helper.ts"),w=C("./src/utils/logger.ts");function b(o,u){for(var f=0;f<u.length;f++){var s=u[f];s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s&&(s.writable=!0),Object.defineProperty(o,s.key,s)}}function p(o,u,f){return u&&b(o.prototype,u),f&&b(o,f),o}function d(o,u){var f=typeof Symbol!="undefined"&&o[Symbol.iterator]||o["@@iterator"];if(f)return(f=f.call(o)).next.bind(f);if(Array.isArray(o)||(f=n(o))||u&&o&&typeof o.length=="number"){f&&(o=f);var s=0;return function(){return s>=o.length?{done:!0}:{done:!1,value:o[s++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function n(o,u){if(!o)return;if(typeof o=="string")return c(o,u);var f=Object.prototype.toString.call(o).slice(8,-1);if(f==="Object"&&o.constructor&&(f=o.constructor.name),f==="Map"||f==="Set")return Array.from(o);if(f==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(f))return c(o,u)}function c(o,u){(u==null||u>o.length)&&(u=o.length);for(var f=0,s=new Array(u);f<u;f++)s[f]=o[f];return s}function r(){return r=Object.assign||function(o){for(var u=1;u<arguments.length;u++){var f=arguments[u];for(var s in f)Object.prototype.hasOwnProperty.call(f,s)&&(o[s]=f[s])}return o},r.apply(this,arguments)}var i=function(){function o(f){var s=this;this.hls=void 0,this.config=void 0,this.media=void 0,this.sid=void 0,this.cid=void 0,this.useHeaders=!1,this.initialized=!1,this.starved=!1,this.buffering=!0,this.audioBuffer=void 0,this.videoBuffer=void 0,this.onWaiting=function(){s.initialized&&(s.starved=!0),s.buffering=!0},this.onPlaying=function(){s.initialized||(s.initialized=!0),s.buffering=!1},this.applyPlaylistData=function(S){try{s.apply(S,{ot:m.CMCDObjectType.MANIFEST,su:!s.initialized})}catch(x){w.logger.warn("Could not generate manifest CMCD data.",x)}},this.applyFragmentData=function(S){try{var x=S.frag,h=s.hls.levels[x.level],R=s.getObjectType(x),O={d:x.duration*1e3,ot:R};(R===m.CMCDObjectType.VIDEO||R===m.CMCDObjectType.AUDIO||R==m.CMCDObjectType.MUXED)&&(O.br=h.bitrate/1e3,O.tb=s.getTopBandwidth(R),O.bl=s.getBufferLength(R)),s.apply(S,O)}catch(g){w.logger.warn("Could not generate segment CMCD data.",g)}},this.hls=f;var l=this.config=f.config,t=l.cmcd;t!=null&&(l.pLoader=this.createPlaylistLoader(),l.fLoader=this.createFragmentLoader(),this.sid=t.sessionId||o.uuid(),this.cid=t.contentId,this.useHeaders=t.useHeaders===!0,this.registerListeners())}var u=o.prototype;return u.registerListeners=function(){var s=this.hls;s.on(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),s.on(M.Events.MEDIA_DETACHED,this.onMediaDetached,this),s.on(M.Events.BUFFER_CREATED,this.onBufferCreated,this)},u.unregisterListeners=function(){var s=this.hls;s.off(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),s.off(M.Events.MEDIA_DETACHED,this.onMediaDetached,this),s.off(M.Events.BUFFER_CREATED,this.onBufferCreated,this),this.onMediaDetached()},u.destroy=function(){this.unregisterListeners(),this.hls=this.config=this.audioBuffer=this.videoBuffer=null},u.onMediaAttached=function(s,l){this.media=l.media,this.media.addEventListener("waiting",this.onWaiting),this.media.addEventListener("playing",this.onPlaying)},u.onMediaDetached=function(){if(!this.media)return;this.media.removeEventListener("waiting",this.onWaiting),this.media.removeEventListener("playing",this.onPlaying),this.media=null},u.onBufferCreated=function(s,l){var t,S;this.audioBuffer=(t=l.tracks.audio)===null||t===void 0?void 0:t.buffer,this.videoBuffer=(S=l.tracks.video)===null||S===void 0?void 0:S.buffer},u.createData=function(){var s;return{v:m.CMCDVersion,sf:m.CMCDStreamingFormat.HLS,sid:this.sid,cid:this.cid,pr:(s=this.media)===null||s===void 0?void 0:s.playbackRate,mtp:this.hls.bandwidthEstimate/1e3}},u.apply=function(s,l){l===void 0&&(l={}),r(l,this.createData());var t=l.ot===m.CMCDObjectType.INIT||l.ot===m.CMCDObjectType.VIDEO||l.ot===m.CMCDObjectType.MUXED;if(this.starved&&t&&(l.bs=!0,l.su=!0,this.starved=!1),l.su==null&&(l.su=this.buffering),this.useHeaders){var S=o.toHeaders(l);if(!Object.keys(S).length)return;s.headers||(s.headers={}),r(s.headers,S)}else{var x=o.toQuery(l);if(!x)return;s.url=o.appendQueryToUri(s.url,x)}},u.getObjectType=function(s){var l=s.type;return l==="subtitle"?m.CMCDObjectType.TIMED_TEXT:s.sn==="initSegment"?m.CMCDObjectType.INIT:l==="audio"?m.CMCDObjectType.AUDIO:l==="main"?this.hls.audioTracks.length?m.CMCDObjectType.VIDEO:m.CMCDObjectType.MUXED:void 0},u.getTopBandwidth=function(s){for(var l=0,t=s===m.CMCDObjectType.AUDIO?this.hls.audioTracks:this.hls.levels,S=d(t),x;!(x=S()).done;){var h=x.value;h.bitrate>l&&(l=h.bitrate)}return l>0?l:NaN},u.getBufferLength=function(s){var l=this.hls.media,t=s===m.CMCDObjectType.AUDIO?this.audioBuffer:this.videoBuffer;if(!t||!l)return NaN;var S=y.BufferHelper.bufferInfo(t,l.currentTime,this.config.maxBufferHole);return S.len*1e3},u.createPlaylistLoader=function(){var s=this.config.pLoader,l=this.applyPlaylistData,t=s||this.config.loader;return function(){function S(h){this.loader=void 0,this.loader=new t(h)}var x=S.prototype;return x.destroy=function(){this.loader.destroy()},x.abort=function(){this.loader.abort()},x.load=function(R,O,g){l(R),this.loader.load(R,O,g)},p(S,[{key:"stats",get:function(){return this.loader.stats}},{key:"context",get:function(){return this.loader.context}}]),S}()},u.createFragmentLoader=function(){var s=this.config.fLoader,l=this.applyFragmentData,t=s||this.config.loader;return function(){function S(h){this.loader=void 0,this.loader=new t(h)}var x=S.prototype;return x.destroy=function(){this.loader.destroy()},x.abort=function(){this.loader.abort()},x.load=function(R,O,g){l(R),this.loader.load(R,O,g)},p(S,[{key:"stats",get:function(){return this.loader.stats}},{key:"context",get:function(){return this.loader.context}}]),S}()},o.uuid=function(){var s=URL.createObjectURL(new Blob),l=s.toString();return URL.revokeObjectURL(s),l.substr(l.lastIndexOf("/")+1)},o.serialize=function(s){for(var l=[],t=function(W){return!Number.isNaN(W)&&W!=null&&W!==""&&W!==!1},S=function(W){return Math.round(W)},x=function(W){return S(W/100)*100},h=function(W){return encodeURIComponent(W)},R={br:S,d:S,bl:x,dl:x,mtp:x,nor:h,rtp:x,tb:S},O=Object.keys(s||{}).sort(),g=d(O),_;!(_=g()).done;){var E=_.value,T=s[E];if(!t(T))continue;if(E==="v"&&T===1)continue;if(E=="pr"&&T===1)continue;var L=R[E];L&&(T=L(T));var I=typeof T,P=void 0;E==="ot"||E==="sf"||E==="st"?P=E+"="+T:I==="boolean"?P=E:I==="number"?P=E+"="+T:P=E+"="+JSON.stringify(T),l.push(P)}return l.join(",")},o.toHeaders=function(s){for(var l=Object.keys(s),t={},S=["Object","Request","Session","Status"],x=[{},{},{},{}],h={br:0,d:0,ot:0,tb:0,bl:1,dl:1,mtp:1,nor:1,nrr:1,su:1,cid:2,pr:2,sf:2,sid:2,st:2,v:2,bs:3,rtp:3},R=0,O=l;R<O.length;R++){var g=O[R],_=h[g]!=null?h[g]:1;x[_][g]=s[g]}for(var E=0;E<x.length;E++){var T=o.serialize(x[E]);T&&(t["CMCD-"+S[E]]=T)}return t},o.toQuery=function(s){return"CMCD="+encodeURIComponent(o.serialize(s))},o.appendQueryToUri=function(s,l){if(!l)return s;var t=s.includes("?")?"&":"?";return""+s+t+l},o}()},"./src/controller/eme-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/events.ts"),m=C("./src/errors.ts"),y=C("./src/utils/logger.ts"),w=C("./src/utils/mediakeys-helper.ts");function b(i,o){for(var u=0;u<o.length;u++){var f=o[u];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(i,f.key,f)}}function p(i,o,u){return o&&b(i.prototype,o),u&&b(i,u),i}var d=3,n=function(o,u,f){var s={audioCapabilities:[],videoCapabilities:[]};return o.forEach(function(l){s.audioCapabilities.push({contentType:'audio/mp4; codecs="'+l+'"',robustness:f.audioRobustness||""})}),u.forEach(function(l){s.videoCapabilities.push({contentType:'video/mp4; codecs="'+l+'"',robustness:f.videoRobustness||""})}),[s]},c=function(o,u,f,s){switch(o){case w.KeySystems.WIDEVINE:return n(u,f,s);default:throw new Error("Unknown key-system: "+o)}},r=function(){function i(u){this.hls=void 0,this._widevineLicenseUrl=void 0,this._licenseXhrSetup=void 0,this._licenseResponseCallback=void 0,this._emeEnabled=void 0,this._requestMediaKeySystemAccess=void 0,this._drmSystemOptions=void 0,this._config=void 0,this._mediaKeysList=[],this._media=null,this._hasSetMediaKeys=!1,this._requestLicenseFailureCount=0,this.mediaKeysPromise=null,this._onMediaEncrypted=this.onMediaEncrypted.bind(this),this.hls=u,this._config=u.config,this._widevineLicenseUrl=this._config.widevineLicenseUrl,this._licenseXhrSetup=this._config.licenseXhrSetup,this._licenseResponseCallback=this._config.licenseResponseCallback,this._emeEnabled=this._config.emeEnabled,this._requestMediaKeySystemAccess=this._config.requestMediaKeySystemAccessFunc,this._drmSystemOptions=this._config.drmSystemOptions,this._registerListeners()}var o=i.prototype;return o.destroy=function(){this._unregisterListeners(),this.hls=this._onMediaEncrypted=null,this._requestMediaKeySystemAccess=null},o._registerListeners=function(){this.hls.on(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.on(M.Events.MEDIA_DETACHED,this.onMediaDetached,this),this.hls.on(M.Events.MANIFEST_PARSED,this.onManifestParsed,this)},o._unregisterListeners=function(){this.hls.off(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.off(M.Events.MEDIA_DETACHED,this.onMediaDetached,this),this.hls.off(M.Events.MANIFEST_PARSED,this.onManifestParsed,this)},o.getLicenseServerUrl=function(f){switch(f){case w.KeySystems.WIDEVINE:if(!this._widevineLicenseUrl)break;return this._widevineLicenseUrl}throw new Error('no license server URL configured for key-system "'+f+'"')},o._attemptKeySystemAccess=function(f,s,l){var t=this,S=c(f,s,l,this._drmSystemOptions);y.logger.log("Requesting encrypted media key-system access");var x=this.requestMediaKeySystemAccess(f,S);this.mediaKeysPromise=x.then(function(h){return t._onMediaKeySystemAccessObtained(f,h)}),x.catch(function(h){y.logger.error('Failed to obtain key-system "'+f+'" access:',h)})},o._onMediaKeySystemAccessObtained=function(f,s){var l=this;y.logger.log('Access for key-system "'+f+'" obtained');var t={mediaKeysSessionInitialized:!1,mediaKeySystemAccess:s,mediaKeySystemDomain:f};this._mediaKeysList.push(t);var S=Promise.resolve().then(function(){return s.createMediaKeys()}).then(function(x){return t.mediaKeys=x,y.logger.log('Media-keys created for key-system "'+f+'"'),l._onMediaKeysCreated(),x});return S.catch(function(x){y.logger.error("Failed to create media-keys:",x)}),S},o._onMediaKeysCreated=function(){var f=this;this._mediaKeysList.forEach(function(s){s.mediaKeysSession||(s.mediaKeysSession=s.mediaKeys.createSession(),f._onNewMediaKeySession(s.mediaKeysSession))})},o._onNewMediaKeySession=function(f){var s=this;y.logger.log("New key-system session "+f.sessionId),f.addEventListener("message",function(l){s._onKeySessionMessage(f,l.message)},!1)},o._onKeySessionMessage=function(f,s){y.logger.log("Got EME message event, creating license request"),this._requestLicense(s,function(l){y.logger.log("Received license data (length: "+(l&&l.byteLength)+"), updating key-session"),f.update(l)})},o.onMediaEncrypted=function(f){var s=this;if(y.logger.log('Media is encrypted using "'+f.initDataType+'" init data type'),!this.mediaKeysPromise){y.logger.error("Fatal: Media is encrypted but no CDM access or no keys have been requested"),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_KEYS,fatal:!0});return}var l=function(S){if(!s._media)return;s._attemptSetMediaKeys(S),s._generateRequestWithPreferredKeySession(f.initDataType,f.initData)};this.mediaKeysPromise.then(l).catch(l)},o._attemptSetMediaKeys=function(f){if(!this._media)throw new Error("Attempted to set mediaKeys without first attaching a media element");if(!this._hasSetMediaKeys){var s=this._mediaKeysList[0];if(!s||!s.mediaKeys){y.logger.error("Fatal: Media is encrypted but no CDM access or no keys have been obtained yet"),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_KEYS,fatal:!0});return}y.logger.log("Setting keys for encrypted media"),this._media.setMediaKeys(s.mediaKeys),this._hasSetMediaKeys=!0}},o._generateRequestWithPreferredKeySession=function(f,s){var l=this,t=this._mediaKeysList[0];if(!t){y.logger.error("Fatal: Media is encrypted but not any key-system access has been obtained yet"),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_ACCESS,fatal:!0});return}if(t.mediaKeysSessionInitialized){y.logger.warn("Key-Session already initialized but requested again");return}var S=t.mediaKeysSession;if(!S){y.logger.error("Fatal: Media is encrypted but no key-session existing"),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_SESSION,fatal:!0});return}if(!s){y.logger.warn("Fatal: initData required for generating a key session is null"),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_INIT_DATA,fatal:!0});return}y.logger.log('Generating key-session request for "'+f+'" init data type'),t.mediaKeysSessionInitialized=!0,S.generateRequest(f,s).then(function(){y.logger.debug("Key-session generation succeeded")}).catch(function(x){y.logger.error("Error generating key-session request:",x),l.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_SESSION,fatal:!1})})},o._createLicenseXhr=function(f,s,l){var t=new XMLHttpRequest;t.responseType="arraybuffer",t.onreadystatechange=this._onLicenseRequestReadyStageChange.bind(this,t,f,s,l);var S=this._licenseXhrSetup;if(S)try{S.call(this.hls,t,f),S=void 0}catch(x){y.logger.error(x)}try{t.readyState||t.open("POST",f,!0),S&&S.call(this.hls,t,f)}catch(x){throw new Error("issue setting up KeySystem license XHR "+x)}return t},o._onLicenseRequestReadyStageChange=function(f,s,l,t){switch(f.readyState){case 4:if(f.status===200){this._requestLicenseFailureCount=0,y.logger.log("License request succeeded");var S=f.response,x=this._licenseResponseCallback;if(x)try{S=x.call(this.hls,f,s)}catch(R){y.logger.error(R)}t(S)}else{if(y.logger.error("License Request XHR failed ("+s+"). Status: "+f.status+" ("+f.statusText+")"),this._requestLicenseFailureCount++,this._requestLicenseFailureCount>d){this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,fatal:!0});return}var h=d-this._requestLicenseFailureCount+1;y.logger.warn("Retrying license request, "+h+" attempts left"),this._requestLicense(l,t)}break}},o._generateLicenseRequestChallenge=function(f,s){switch(f.mediaKeySystemDomain){case w.KeySystems.WIDEVINE:return s}throw new Error("unsupported key-system: "+f.mediaKeySystemDomain)},o._requestLicense=function(f,s){y.logger.log("Requesting content license for key-system");var l=this._mediaKeysList[0];if(!l){y.logger.error("Fatal error: Media is encrypted but no key-system access has been obtained yet"),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_NO_ACCESS,fatal:!0});return}try{var t=this.getLicenseServerUrl(l.mediaKeySystemDomain),S=this._createLicenseXhr(t,f,s);y.logger.log("Sending license request to URL: "+t);var x=this._generateLicenseRequestChallenge(l,f);S.send(x)}catch(h){y.logger.error("Failure requesting DRM license: "+h),this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.KEY_SYSTEM_ERROR,details:m.ErrorDetails.KEY_SYSTEM_LICENSE_REQUEST_FAILED,fatal:!0})}},o.onMediaAttached=function(f,s){if(!this._emeEnabled)return;var l=s.media;this._media=l,l.addEventListener("encrypted",this._onMediaEncrypted)},o.onMediaDetached=function(){var f=this._media,s=this._mediaKeysList;if(!f)return;f.removeEventListener("encrypted",this._onMediaEncrypted),this._media=null,this._mediaKeysList=[],Promise.all(s.map(function(l){if(l.mediaKeysSession)return l.mediaKeysSession.close().catch(function(){})})).then(function(){return f.setMediaKeys(null)}).catch(function(){})},o.onManifestParsed=function(f,s){if(!this._emeEnabled)return;var l=s.levels.map(function(S){return S.audioCodec}).filter(function(S){return!!S}),t=s.levels.map(function(S){return S.videoCodec}).filter(function(S){return!!S});this._attemptKeySystemAccess(w.KeySystems.WIDEVINE,l,t)},p(i,[{key:"requestMediaKeySystemAccess",get:function(){if(!this._requestMediaKeySystemAccess)throw new Error("No requestMediaKeySystemAccess function configured");return this._requestMediaKeySystemAccess}}]),i}();v.default=r},"./src/controller/fps-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/events.ts"),m=C("./src/utils/logger.ts"),y=function(){function w(p){this.hls=void 0,this.isVideoPlaybackQualityAvailable=!1,this.timer=void 0,this.media=null,this.lastTime=void 0,this.lastDroppedFrames=0,this.lastDecodedFrames=0,this.streamController=void 0,this.hls=p,this.registerListeners()}var b=w.prototype;return b.setStreamController=function(d){this.streamController=d},b.registerListeners=function(){this.hls.on(M.Events.MEDIA_ATTACHING,this.onMediaAttaching,this)},b.unregisterListeners=function(){this.hls.off(M.Events.MEDIA_ATTACHING,this.onMediaAttaching)},b.destroy=function(){this.timer&&clearInterval(this.timer),this.unregisterListeners(),this.isVideoPlaybackQualityAvailable=!1,this.media=null},b.onMediaAttaching=function(d,n){var c=this.hls.config;if(c.capLevelOnFPSDrop){var r=n.media instanceof self.HTMLVideoElement?n.media:null;this.media=r,r&&typeof r.getVideoPlaybackQuality=="function"&&(this.isVideoPlaybackQualityAvailable=!0),self.clearInterval(this.timer),this.timer=self.setInterval(this.checkFPSInterval.bind(this),c.fpsDroppedMonitoringPeriod)}},b.checkFPS=function(d,n,c){var r=performance.now();if(n){if(this.lastTime){var i=r-this.lastTime,o=c-this.lastDroppedFrames,u=n-this.lastDecodedFrames,f=1e3*o/i,s=this.hls;if(s.trigger(M.Events.FPS_DROP,{currentDropped:o,currentDecoded:u,totalDroppedFrames:c}),f>0&&o>s.config.fpsDroppedMonitoringThreshold*u){var l=s.currentLevel;m.logger.warn("drop FPS ratio greater than max allowed value for currentLevel: "+l),l>0&&(s.autoLevelCapping===-1||s.autoLevelCapping>=l)&&(l=l-1,s.trigger(M.Events.FPS_DROP_LEVEL_CAPPING,{level:l,droppedLevel:s.currentLevel}),s.autoLevelCapping=l,this.streamController.nextLevelSwitch())}}this.lastTime=r,this.lastDroppedFrames=c,this.lastDecodedFrames=n}},b.checkFPSInterval=function(){var d=this.media;if(d)if(this.isVideoPlaybackQualityAvailable){var n=d.getVideoPlaybackQuality();this.checkFPS(d,n.totalVideoFrames,n.droppedVideoFrames)}else this.checkFPS(d,d.webkitDecodedFrameCount,d.webkitDroppedFrameCount)},w}();v.default=y},"./src/controller/fragment-finders.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"findFragmentByPDT",function(){return y}),C.d(v,"findFragmentByPTS",function(){return w}),C.d(v,"fragmentWithinToleranceTest",function(){return b}),C.d(v,"pdtWithinToleranceTest",function(){return p}),C.d(v,"findFragWithCC",function(){return d});var M=C("./src/polyfills/number.ts"),m=C("./src/utils/binary-search.ts");function y(n,c,r){if(c===null||!Array.isArray(n)||!n.length||!Object(M.isFiniteNumber)(c))return null;var i=n[0].programDateTime;if(c<(i||0))return null;var o=n[n.length-1].endProgramDateTime;if(c>=(o||0))return null;r=r||0;for(var u=0;u<n.length;++u){var f=n[u];if(p(c,r,f))return f}return null}function w(n,c,r,i){r===void 0&&(r=0),i===void 0&&(i=0);var o=null;if(n?o=c[n.sn-c[0].sn+1]||null:r===0&&c[0].start===0&&(o=c[0]),o&&b(r,i,o)===0)return o;var u=m.default.search(c,b.bind(null,r,i));return u||o}function b(n,c,r){n===void 0&&(n=0),c===void 0&&(c=0);var i=Math.min(c,r.duration+(r.deltaPTS?r.deltaPTS:0));return r.start+r.duration-i<=n?1:r.start-i>n&&r.start?-1:0}function p(n,c,r){var i=Math.min(c,r.duration+(r.deltaPTS?r.deltaPTS:0))*1e3,o=r.endProgramDateTime||0;return o-i>n}function d(n,c){return m.default.search(n,function(r){return r.cc<c?1:r.cc>c?-1:0})}},"./src/controller/fragment-tracker.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"FragmentState",function(){return y}),C.d(v,"FragmentTracker",function(){return w});var M=C("./src/events.ts"),m=C("./src/types/loader.ts"),y;(function(d){d.NOT_LOADED="NOT_LOADED",d.BACKTRACKED="BACKTRACKED",d.APPENDING="APPENDING",d.PARTIAL="PARTIAL",d.OK="OK"})(y||(y={}));var w=function(){function d(c){this.activeFragment=null,this.activeParts=null,this.fragments=Object.create(null),this.timeRanges=Object.create(null),this.bufferPadding=.2,this.hls=void 0,this.hls=c,this._registerListeners()}var n=d.prototype;return n._registerListeners=function(){var r=this.hls;r.on(M.Events.BUFFER_APPENDED,this.onBufferAppended,this),r.on(M.Events.FRAG_BUFFERED,this.onFragBuffered,this),r.on(M.Events.FRAG_LOADED,this.onFragLoaded,this)},n._unregisterListeners=function(){var r=this.hls;r.off(M.Events.BUFFER_APPENDED,this.onBufferAppended,this),r.off(M.Events.FRAG_BUFFERED,this.onFragBuffered,this),r.off(M.Events.FRAG_LOADED,this.onFragLoaded,this)},n.destroy=function(){this._unregisterListeners(),this.fragments=this.timeRanges=null},n.getAppendedFrag=function(r,i){if(i===m.PlaylistLevelType.MAIN){var o=this.activeFragment,u=this.activeParts;if(!o)return null;if(u)for(var f=u.length;f--;){var s=u[f],l=s?s.end:o.appendedPTS;if(s.start<=r&&l!==void 0&&r<=l)return f>9&&(this.activeParts=u.slice(f-9)),s}else if(o.start<=r&&o.appendedPTS!==void 0&&r<=o.appendedPTS)return o}return this.getBufferedFrag(r,i)},n.getBufferedFrag=function(r,i){for(var o=this.fragments,u=Object.keys(o),f=u.length;f--;){var s=o[u[f]];if((s==null?void 0:s.body.type)===i&&s.buffered){var l=s.body;if(l.start<=r&&r<=l.end)return l}}return null},n.detectEvictedFragments=function(r,i,o){var u=this;Object.keys(this.fragments).forEach(function(f){var s=u.fragments[f];if(!s)return;if(!s.buffered){s.body.type===o&&u.removeFragment(s.body);return}var l=s.range[r];if(!l)return;l.time.some(function(t){var S=!u.isTimeBuffered(t.startPTS,t.endPTS,i);return S&&u.removeFragment(s.body),S})})},n.detectPartialFragments=function(r){var i=this,o=this.timeRanges,u=r.frag,f=r.part;if(!o||u.sn==="initSegment")return;var s=p(u),l=this.fragments[s];if(!l)return;Object.keys(o).forEach(function(t){var S=u.elementaryStreams[t];if(!S)return;var x=o[t],h=f!==null||S.partial===!0;l.range[t]=i.getBufferedTimes(u,f,h,x)}),l.backtrack=l.loaded=null,Object.keys(l.range).length?l.buffered=!0:this.removeFragment(l.body)},n.fragBuffered=function(r){var i=p(r),o=this.fragments[i];o&&(o.backtrack=o.loaded=null,o.buffered=!0)},n.getBufferedTimes=function(r,i,o,u){for(var f={time:[],partial:o},s=i?i.start:r.start,l=i?i.end:r.end,t=r.minEndPTS||l,S=r.maxStartPTS||s,x=0;x<u.length;x++){var h=u.start(x)-this.bufferPadding,R=u.end(x)+this.bufferPadding;if(S>=h&&t<=R){f.time.push({startPTS:Math.max(s,u.start(x)),endPTS:Math.min(l,u.end(x))});break}else if(s<R&&l>h)f.partial=!0,f.time.push({startPTS:Math.max(s,u.start(x)),endPTS:Math.min(l,u.end(x))});else if(l<=h)break}return f},n.getPartialFragment=function(r){var i=null,o,u,f,s=0,l=this.bufferPadding,t=this.fragments;return Object.keys(t).forEach(function(S){var x=t[S];if(!x)return;b(x)&&(u=x.body.start-l,f=x.body.end+l,r>=u&&r<=f&&(o=Math.min(r-u,f-r),s<=o&&(i=x.body,s=o)))}),i},n.getState=function(r){var i=p(r),o=this.fragments[i];return o?o.buffered?b(o)?y.PARTIAL:y.OK:o.backtrack?y.BACKTRACKED:y.APPENDING:y.NOT_LOADED},n.backtrack=function(r,i){var o=p(r),u=this.fragments[o];if(!u||u.backtrack)return null;var f=u.backtrack=i||u.loaded;return u.loaded=null,f},n.getBacktrackData=function(r){var i=p(r),o=this.fragments[i];if(o){var u,f=o.backtrack;if(f!=null&&(u=f.payload)!==null&&u!==void 0&&u.byteLength)return f;this.removeFragment(r)}return null},n.isTimeBuffered=function(r,i,o){for(var u,f,s=0;s<o.length;s++){if(u=o.start(s)-this.bufferPadding,f=o.end(s)+this.bufferPadding,r>=u&&i<=f)return!0;if(i<=u)return!1}return!1},n.onFragLoaded=function(r,i){var o=i.frag,u=i.part;if(o.sn==="initSegment"||o.bitrateTest||u)return;var f=p(o);this.fragments[f]={body:o,loaded:i,backtrack:null,buffered:!1,range:Object.create(null)}},n.onBufferAppended=function(r,i){var o=this,u=i.frag,f=i.part,s=i.timeRanges;if(u.type===m.PlaylistLevelType.MAIN)if(this.activeFragment=u,f){var l=this.activeParts;l||(this.activeParts=l=[]),l.push(f)}else this.activeParts=null;this.timeRanges=s,Object.keys(s).forEach(function(t){var S=s[t];if(o.detectEvictedFragments(t,S),!f)for(var x=0;x<S.length;x++)u.appendedPTS=Math.max(S.end(x),u.appendedPTS||0)})},n.onFragBuffered=function(r,i){this.detectPartialFragments(i)},n.hasFragment=function(r){var i=p(r);return!!this.fragments[i]},n.removeFragmentsInRange=function(r,i,o){var u=this;Object.keys(this.fragments).forEach(function(f){var s=u.fragments[f];if(!s)return;if(s.buffered){var l=s.body;l.type===o&&l.start<i&&l.end>r&&u.removeFragment(l)}})},n.removeFragment=function(r){var i=p(r);r.stats.loaded=0,r.clearElementaryStreamInfo(),delete this.fragments[i]},n.removeAllFragments=function(){this.fragments=Object.create(null),this.activeFragment=null,this.activeParts=null},d}();function b(d){var n,c;return d.buffered&&(((n=d.range.video)===null||n===void 0?void 0:n.partial)||((c=d.range.audio)===null||c===void 0?void 0:c.partial))}function p(d){return d.type+"_"+d.level+"_"+d.urlId+"_"+d.sn}},"./src/controller/gap-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"STALL_MINIMUM_DURATION_MS",function(){return b}),C.d(v,"MAX_START_GAP_JUMP",function(){return p}),C.d(v,"SKIP_BUFFER_HOLE_STEP_SECONDS",function(){return d}),C.d(v,"SKIP_BUFFER_RANGE_START",function(){return n}),C.d(v,"default",function(){return c});var M=C("./src/utils/buffer-helper.ts"),m=C("./src/errors.ts"),y=C("./src/events.ts"),w=C("./src/utils/logger.ts"),b=250,p=2,d=.1,n=.05,c=function(){function r(o,u,f,s){this.config=void 0,this.media=void 0,this.fragmentTracker=void 0,this.hls=void 0,this.nudgeRetry=0,this.stallReported=!1,this.stalled=null,this.moved=!1,this.seeking=!1,this.config=o,this.media=u,this.fragmentTracker=f,this.hls=s}var i=r.prototype;return i.destroy=function(){this.hls=this.fragmentTracker=this.media=null},i.poll=function(u){var f=this.config,s=this.media,l=this.stalled,t=s.currentTime,S=s.seeking,x=this.seeking&&!S,h=!this.seeking&&S;if(this.seeking=S,t!==u){if(this.moved=!0,l!==null){if(this.stallReported){var R=self.performance.now()-l;w.logger.warn("playback not stuck anymore @"+t+", after "+Math.round(R)+"ms"),this.stallReported=!1}this.stalled=null,this.nudgeRetry=0}return}if((h||x)&&(this.stalled=null),s.paused||s.ended||s.playbackRate===0||!M.BufferHelper.getBuffered(s).length)return;var O=M.BufferHelper.bufferInfo(s,t,0),g=O.len>0,_=O.nextStart||0;if(!g&&!_)return;if(S){var E=O.len>p,T=!_||_-t>p&&!this.fragmentTracker.getPartialFragment(t);if(E||T)return;this.moved=!1}if(!this.moved&&this.stalled!==null){var L,I=Math.max(_,O.start||0)-t,P=this.hls.levels?this.hls.levels[this.hls.currentLevel]:null,G=P==null||((L=P.details)===null||L===void 0)?void 0:L.live,W=G?P.details.targetduration*2:p;if(I>0&&I<=W){this._trySkipBufferHole(null);return}}var H=self.performance.now();if(l===null){this.stalled=H;return}var z=H-l;!S&&z>=b&&this._reportStall(O.len);var B=M.BufferHelper.bufferInfo(s,t,f.maxBufferHole);this._tryFixBufferStall(B,z)},i._tryFixBufferStall=function(u,f){var s=this.config,l=this.fragmentTracker,t=this.media,S=t.currentTime,x=l.getPartialFragment(S);if(x){var h=this._trySkipBufferHole(x);if(h)return}u.len>s.maxBufferHole&&f>s.highBufferWatchdogPeriod*1e3&&(w.logger.warn("Trying to nudge playhead over buffer-hole"),this.stalled=null,this._tryNudgeBuffer())},i._reportStall=function(u){var f=this.hls,s=this.media,l=this.stallReported;l||(this.stallReported=!0,w.logger.warn("Playback stalling at @"+s.currentTime+" due to low buffer (buffer="+u+")"),f.trigger(y.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.BUFFER_STALLED_ERROR,fatal:!1,buffer:u}))},i._trySkipBufferHole=function(u){for(var f=this.config,s=this.hls,l=this.media,t=l.currentTime,S=0,x=M.BufferHelper.getBuffered(l),h=0;h<x.length;h++){var R=x.start(h);if(t+f.maxBufferHole>=S&&t<R){var O=Math.max(R+n,l.currentTime+d);return w.logger.warn("skipping hole, adjusting currentTime from "+t+" to "+O),this.moved=!0,this.stalled=null,l.currentTime=O,u&&s.trigger(y.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.BUFFER_SEEK_OVER_HOLE,fatal:!1,reason:"fragment loaded with buffer holes, seeking from "+t+" to "+O,frag:u}),O}S=x.end(h)}return 0},i._tryNudgeBuffer=function(){var u=this.config,f=this.hls,s=this.media,l=s.currentTime,t=(this.nudgeRetry||0)+1;if(this.nudgeRetry=t,t<u.nudgeMaxRetry){var S=l+t*u.nudgeOffset;w.logger.warn("Nudging 'currentTime' from "+l+" to "+S),s.currentTime=S,f.trigger(y.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.BUFFER_NUDGE_ON_STALL,fatal:!1})}else w.logger.error("Playhead still not moving while enough data buffered @"+l+" after "+u.nudgeMaxRetry+" nudges"),f.trigger(y.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.BUFFER_STALLED_ERROR,fatal:!0})},r}()},"./src/controller/id3-track-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/events.ts"),m=C("./src/utils/texttrack-utils.ts"),y=C("./src/demux/id3.ts"),w=.25,b=function(){function p(n){this.hls=void 0,this.id3Track=null,this.media=null,this.hls=n,this._registerListeners()}var d=p.prototype;return d.destroy=function(){this._unregisterListeners()},d._registerListeners=function(){var c=this.hls;c.on(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),c.on(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this),c.on(M.Events.FRAG_PARSING_METADATA,this.onFragParsingMetadata,this),c.on(M.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},d._unregisterListeners=function(){var c=this.hls;c.off(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),c.off(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this),c.off(M.Events.FRAG_PARSING_METADATA,this.onFragParsingMetadata,this),c.off(M.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},d.onMediaAttached=function(c,r){this.media=r.media},d.onMediaDetaching=function(){if(!this.id3Track)return;Object(m.clearCurrentCues)(this.id3Track),this.id3Track=null,this.media=null},d.getID3Track=function(c){if(!this.media)return;for(var r=0;r<c.length;r++){var i=c[r];if(i.kind==="metadata"&&i.label==="id3")return Object(m.sendAddTrackEvent)(i,this.media),i}return this.media.addTextTrack("metadata","id3")},d.onFragParsingMetadata=function(c,r){if(!this.media)return;var i=r.frag,o=r.samples;this.id3Track||(this.id3Track=this.getID3Track(this.media.textTracks),this.id3Track.mode="hidden");for(var u=self.WebKitDataCue||self.VTTCue||self.TextTrackCue,f=0;f<o.length;f++){var s=y.getID3Frames(o[f].data);if(s){var l=o[f].pts,t=f<o.length-1?o[f+1].pts:i.end,S=t-l;S<=0&&(t=l+w);for(var x=0;x<s.length;x++){var h=s[x];if(!y.isTimeStampFrame(h)){var R=new u(l,t,"");R.value=h,this.id3Track.addCue(R)}}}}},d.onBufferFlushing=function(c,r){var i=r.startOffset,o=r.endOffset,u=r.type;if(!u||u==="audio"){var f=this.id3Track;f&&Object(m.removeCuesInRange)(f,i,o)}},p}();v.default=b},"./src/controller/latency-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return p});var M=C("./src/errors.ts"),m=C("./src/events.ts"),y=C("./src/utils/logger.ts");function w(d,n){for(var c=0;c<n.length;c++){var r=n[c];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(d,r.key,r)}}function b(d,n,c){return n&&w(d.prototype,n),c&&w(d,c),d}var p=function(){function d(c){var r=this;this.hls=void 0,this.config=void 0,this.media=null,this.levelDetails=null,this.currentTime=0,this.stallCount=0,this._latency=null,this.timeupdateHandler=function(){return r.timeupdate()},this.hls=c,this.config=c.config,this.registerListeners()}var n=d.prototype;return n.destroy=function(){this.unregisterListeners(),this.onMediaDetaching(),this.levelDetails=null,this.hls=this.timeupdateHandler=null},n.registerListeners=function(){this.hls.on(m.Events.MEDIA_ATTACHED,this.onMediaAttached,this),this.hls.on(m.Events.MEDIA_DETACHING,this.onMediaDetaching,this),this.hls.on(m.Events.MANIFEST_LOADING,this.onManifestLoading,this),this.hls.on(m.Events.LEVEL_UPDATED,this.onLevelUpdated,this),this.hls.on(m.Events.ERROR,this.onError,this)},n.unregisterListeners=function(){this.hls.off(m.Events.MEDIA_ATTACHED,this.onMediaAttached),this.hls.off(m.Events.MEDIA_DETACHING,this.onMediaDetaching),this.hls.off(m.Events.MANIFEST_LOADING,this.onManifestLoading),this.hls.off(m.Events.LEVEL_UPDATED,this.onLevelUpdated),this.hls.off(m.Events.ERROR,this.onError)},n.onMediaAttached=function(r,i){this.media=i.media,this.media.addEventListener("timeupdate",this.timeupdateHandler)},n.onMediaDetaching=function(){this.media&&(this.media.removeEventListener("timeupdate",this.timeupdateHandler),this.media=null)},n.onManifestLoading=function(){this.levelDetails=null,this._latency=null,this.stallCount=0},n.onLevelUpdated=function(r,i){var o=i.details;this.levelDetails=o,o.advanced&&this.timeupdate(),!o.live&&this.media&&this.media.removeEventListener("timeupdate",this.timeupdateHandler)},n.onError=function(r,i){if(i.details!==M.ErrorDetails.BUFFER_STALLED_ERROR)return;this.stallCount++,y.logger.warn("[playback-rate-controller]: Stall detected, adjusting target latency")},n.timeupdate=function(){var r=this.media,i=this.levelDetails;if(!r||!i)return;this.currentTime=r.currentTime;var o=this.computeLatency();if(o===null)return;this._latency=o;var u=this.config,f=u.lowLatencyMode,s=u.maxLiveSyncPlaybackRate;if(!f||s===1)return;var l=this.targetLatency;if(l===null)return;var t=o-l,S=Math.min(this.maxLatency,l+i.targetduration),x=t<S;if(i.live&&x&&t>.05&&this.forwardBufferLength>1){var h=Math.min(2,Math.max(1,s)),R=Math.round(2/(1+Math.exp(-.75*t-this.edgeStalled))*20)/20;r.playbackRate=Math.min(h,Math.max(1,R))}else r.playbackRate!==1&&r.playbackRate!==0&&(r.playbackRate=1)},n.estimateLiveEdge=function(){var r=this.levelDetails;return r===null?null:r.edge+r.age},n.computeLatency=function(){var r=this.estimateLiveEdge();return r===null?null:r-this.currentTime},b(d,[{key:"latency",get:function(){return this._latency||0}},{key:"maxLatency",get:function(){var r=this.config,i=this.levelDetails;return r.liveMaxLatencyDuration!==void 0?r.liveMaxLatencyDuration:i?r.liveMaxLatencyDurationCount*i.targetduration:0}},{key:"targetLatency",get:function(){var r=this.levelDetails;if(r===null)return null;var i=r.holdBack,o=r.partHoldBack,u=r.targetduration,f=this.config,s=f.liveSyncDuration,l=f.liveSyncDurationCount,t=f.lowLatencyMode,S=this.hls.userConfig,x=t&&o||i;(S.liveSyncDuration||S.liveSyncDurationCount||x===0)&&(x=s!==void 0?s:l*u);var h=u,R=1;return x+Math.min(this.stallCount*R,h)}},{key:"liveSyncPosition",get:function(){var r=this.estimateLiveEdge(),i=this.targetLatency,o=this.levelDetails;if(r===null||i===null||o===null)return null;var u=o.edge,f=r-i-this.edgeStalled,s=u-o.totalduration,l=u-(this.config.lowLatencyMode&&o.partTarget||o.targetduration);return Math.min(Math.max(s,f),l)}},{key:"drift",get:function(){var r=this.levelDetails;return r===null?1:r.drift}},{key:"edgeStalled",get:function(){var r=this.levelDetails;if(r===null)return 0;var i=(this.config.lowLatencyMode&&r.partTarget||r.targetduration)*3;return Math.max(r.age-i,0)}},{key:"forwardBufferLength",get:function(){var r=this.media,i=this.levelDetails;if(!r||!i)return 0;var o=r.buffered.length;return o?r.buffered.end(o-1):i.edge-this.currentTime}}]),d}()},"./src/controller/level-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return f});var M=C("./src/types/level.ts"),m=C("./src/events.ts"),y=C("./src/errors.ts"),w=C("./src/utils/codecs.ts"),b=C("./src/controller/level-helper.ts"),p=C("./src/controller/base-playlist-controller.ts"),d=C("./src/types/loader.ts");function n(){return n=Object.assign||function(s){for(var l=1;l<arguments.length;l++){var t=arguments[l];for(var S in t)Object.prototype.hasOwnProperty.call(t,S)&&(s[S]=t[S])}return s},n.apply(this,arguments)}function c(s,l){for(var t=0;t<l.length;t++){var S=l[t];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(s,S.key,S)}}function r(s,l,t){return l&&c(s.prototype,l),t&&c(s,t),s}function i(s,l){s.prototype=Object.create(l.prototype),s.prototype.constructor=s,o(s,l)}function o(s,l){return o=Object.setPrototypeOf||function(S,x){return S.__proto__=x,S},o(s,l)}var u=/chrome|firefox/.test(navigator.userAgent.toLowerCase()),f=function(s){i(l,s);function l(S){var x;return x=s.call(this,S,"[level-controller]")||this,x._levels=[],x._firstLevel=-1,x._startLevel=void 0,x.currentLevelIndex=-1,x.manualLevelIndex=-1,x.onParsedComplete=void 0,x._registerListeners(),x}var t=l.prototype;return t._registerListeners=function(){var x=this.hls;x.on(m.Events.MANIFEST_LOADED,this.onManifestLoaded,this),x.on(m.Events.LEVEL_LOADED,this.onLevelLoaded,this),x.on(m.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),x.on(m.Events.FRAG_LOADED,this.onFragLoaded,this),x.on(m.Events.ERROR,this.onError,this)},t._unregisterListeners=function(){var x=this.hls;x.off(m.Events.MANIFEST_LOADED,this.onManifestLoaded,this),x.off(m.Events.LEVEL_LOADED,this.onLevelLoaded,this),x.off(m.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),x.off(m.Events.FRAG_LOADED,this.onFragLoaded,this),x.off(m.Events.ERROR,this.onError,this)},t.destroy=function(){this._unregisterListeners(),this.manualLevelIndex=-1,this._levels.length=0,s.prototype.destroy.call(this)},t.startLoad=function(){var x=this._levels;x.forEach(function(h){h.loadError=0}),s.prototype.startLoad.call(this)},t.onManifestLoaded=function(x,h){var R=[],O=[],g=[],_,E={},T,L=!1,I=!1,P=!1;if(h.levels.forEach(function(z){var B=z.attrs;L=L||!!(z.width&&z.height),I=I||!!z.videoCodec,P=P||!!z.audioCodec,u&&z.audioCodec&&z.audioCodec.indexOf("mp4a.40.34")!==-1&&(z.audioCodec=void 0);var k=z.bitrate+"-"+z.attrs.RESOLUTION+"-"+z.attrs.CODECS;T=E[k],T?T.url.push(z.url):(T=new M.Level(z),E[k]=T,R.push(T)),B&&(B.AUDIO&&Object(b.addGroupId)(T,"audio",B.AUDIO),B.SUBTITLES&&Object(b.addGroupId)(T,"text",B.SUBTITLES))}),(L||I)&&P&&(R=R.filter(function(z){var B=z.videoCodec,k=z.width,K=z.height;return!!B||!!(k&&K)})),R=R.filter(function(z){var B=z.audioCodec,k=z.videoCodec;return(!B||Object(w.isCodecSupportedInMp4)(B,"audio"))&&(!k||Object(w.isCodecSupportedInMp4)(k,"video"))}),h.audioTracks&&(O=h.audioTracks.filter(function(z){return!z.audioCodec||Object(w.isCodecSupportedInMp4)(z.audioCodec,"audio")}),Object(b.assignTrackIdsByGroup)(O)),h.subtitles&&(g=h.subtitles,Object(b.assignTrackIdsByGroup)(g)),R.length>0){_=R[0].bitrate,R.sort(function(z,B){return z.bitrate-B.bitrate}),this._levels=R;for(var G=0;G<R.length;G++)if(R[G].bitrate===_){this._firstLevel=G,this.log("manifest loaded, "+R.length+" level(s) found, first bitrate: "+_);break}var W=P&&!I,H={levels:R,audioTracks:O,subtitleTracks:g,firstLevel:this._firstLevel,stats:h.stats,audio:P,video:I,altAudio:!W&&O.some(function(z){return!!z.url})};this.hls.trigger(m.Events.MANIFEST_PARSED,H),(this.hls.config.autoStartLoad||this.hls.forceStartLoad)&&this.hls.startLoad(this.hls.config.startPosition)}else this.hls.trigger(m.Events.ERROR,{type:y.ErrorTypes.MEDIA_ERROR,details:y.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR,fatal:!0,url:h.url,reason:"no level with compatible codecs found in manifest"})},t.onError=function(x,h){if(s.prototype.onError.call(this,x,h),h.fatal)return;var R=h.context,O=this._levels[this.currentLevelIndex];if(R&&(R.type===d.PlaylistContextType.AUDIO_TRACK&&O.audioGroupIds&&R.groupId===O.audioGroupIds[O.urlId]||R.type===d.PlaylistContextType.SUBTITLE_TRACK&&O.textGroupIds&&R.groupId===O.textGroupIds[O.urlId])){this.redundantFailover(this.currentLevelIndex);return}var g=!1,_=!0,E;switch(h.details){case y.ErrorDetails.FRAG_LOAD_ERROR:case y.ErrorDetails.FRAG_LOAD_TIMEOUT:case y.ErrorDetails.KEY_LOAD_ERROR:case y.ErrorDetails.KEY_LOAD_TIMEOUT:if(h.frag){var T=this._levels[h.frag.level];T?(T.fragmentError++,T.fragmentError>this.hls.config.fragLoadingMaxRetry&&(E=h.frag.level)):E=h.frag.level}break;case y.ErrorDetails.LEVEL_LOAD_ERROR:case y.ErrorDetails.LEVEL_LOAD_TIMEOUT:R&&(R.deliveryDirectives&&(_=!1),E=R.level),g=!0;break;case y.ErrorDetails.REMUX_ALLOC_ERROR:E=h.level,g=!0;break}E!==void 0&&this.recoverLevel(h,E,g,_)},t.recoverLevel=function(x,h,R,O){var g=x.details,_=this._levels[h];if(_.loadError++,R){var E=this.retryLoadingOrFail(x);if(E)x.levelRetry=!0;else{this.currentLevelIndex=-1;return}}if(O){var T=_.url.length;if(T>1&&_.loadError<T)x.levelRetry=!0,this.redundantFailover(h);else if(this.manualLevelIndex===-1){var L=h===0?this._levels.length-1:h-1;this.currentLevelIndex!==L&&this._levels[L].loadError===0&&(this.warn(g+": switch to "+L),x.levelRetry=!0,this.hls.nextAutoLevel=L)}}},t.redundantFailover=function(x){var h=this._levels[x],R=h.url.length;if(R>1){var O=(h.urlId+1)%R;this.warn("Switching to redundant URL-id "+O),this._levels.forEach(function(g){g.urlId=O}),this.level=x}},t.onFragLoaded=function(x,h){var R=h.frag;if(R!==void 0&&R.type===d.PlaylistLevelType.MAIN){var O=this._levels[R.level];O!==void 0&&(O.fragmentError=0,O.loadError=0)}},t.onLevelLoaded=function(x,h){var R,O=h.level,g=h.details,_=this._levels[O];if(!_){var E;this.warn("Invalid level index "+O),(E=h.deliveryDirectives)!==null&&E!==void 0&&E.skip&&(g.deltaUpdateFailed=!0);return}O===this.currentLevelIndex?(_.fragmentError===0&&(_.loadError=0,this.retryCount=0),this.playlistLoaded(O,h,_.details)):(R=h.deliveryDirectives)!==null&&R!==void 0&&R.skip&&(g.deltaUpdateFailed=!0)},t.onAudioTrackSwitched=function(x,h){var R=this.hls.levels[this.currentLevelIndex];if(!R)return;if(R.audioGroupIds){for(var O=-1,g=this.hls.audioTracks[h.id].groupId,_=0;_<R.audioGroupIds.length;_++)if(R.audioGroupIds[_]===g){O=_;break}O!==R.urlId&&(R.urlId=O,this.startLoad())}},t.loadPlaylist=function(x){var h=this.currentLevelIndex,R=this._levels[h];if(this.canLoad&&R&&R.url.length>0){var O=R.urlId,g=R.url[O];if(x)try{g=x.addDirectives(g)}catch(_){this.warn("Could not construct new URL with HLS Delivery Directives: "+_)}this.log("Attempt loading level index "+h+(x?" at sn "+x.msn+" part "+x.part:"")+" with URL-id "+O+" "+g),this.clearTimer(),this.hls.trigger(m.Events.LEVEL_LOADING,{url:g,level:h,id:O,deliveryDirectives:x||null})}},t.removeLevel=function(x,h){var R=function(_,E){return E!==h},O=this._levels.filter(function(g,_){return _!==x?!0:g.url.length>1&&h!==void 0?(g.url=g.url.filter(R),g.audioGroupIds&&(g.audioGroupIds=g.audioGroupIds.filter(R)),g.textGroupIds&&(g.textGroupIds=g.textGroupIds.filter(R)),g.urlId=0,!0):!1}).map(function(g,_){var E=g.details;return E!=null&&E.fragments&&E.fragments.forEach(function(T){T.level=_}),g});this._levels=O,this.hls.trigger(m.Events.LEVELS_UPDATED,{levels:O})},r(l,[{key:"levels",get:function(){return this._levels.length===0?null:this._levels}},{key:"level",get:function(){return this.currentLevelIndex},set:function(x){var h,R=this._levels;if(R.length===0)return;if(this.currentLevelIndex===x&&(h=R[x])!==null&&h!==void 0&&h.details)return;if(x<0||x>=R.length){var O=x<0;if(this.hls.trigger(m.Events.ERROR,{type:y.ErrorTypes.OTHER_ERROR,details:y.ErrorDetails.LEVEL_SWITCH_ERROR,level:x,fatal:O,reason:"invalid level idx"}),O)return;x=Math.min(x,R.length-1)}this.clearTimer();var g=this.currentLevelIndex,_=R[g],E=R[x];this.log("switching to level "+x+" from "+g),this.currentLevelIndex=x;var T=n({},E,{level:x,maxBitrate:E.maxBitrate,uri:E.uri,urlId:E.urlId});delete T._urlId,this.hls.trigger(m.Events.LEVEL_SWITCHING,T);var L=E.details;if(!L||L.live){var I=this.switchParams(E.uri,_==null?void 0:_.details);this.loadPlaylist(I)}}},{key:"manualLevel",get:function(){return this.manualLevelIndex},set:function(x){this.manualLevelIndex=x,this._startLevel===void 0&&(this._startLevel=x),x!==-1&&(this.level=x)}},{key:"firstLevel",get:function(){return this._firstLevel},set:function(x){this._firstLevel=x}},{key:"startLevel",get:function(){if(this._startLevel===void 0){var x=this.hls.config.startLevel;return x!==void 0?x:this._firstLevel}else return this._startLevel},set:function(x){this._startLevel=x}},{key:"nextLoadLevel",get:function(){return this.manualLevelIndex!==-1?this.manualLevelIndex:this.hls.nextAutoLevel},set:function(x){this.level=x,this.manualLevelIndex===-1&&(this.hls.nextAutoLevel=x)}}]),l}(p.default)},"./src/controller/level-helper.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"addGroupId",function(){return y}),C.d(v,"assignTrackIdsByGroup",function(){return w}),C.d(v,"updatePTS",function(){return b}),C.d(v,"updateFragPTSDTS",function(){return d}),C.d(v,"mergeDetails",function(){return n}),C.d(v,"mapPartIntersection",function(){return c}),C.d(v,"mapFragmentIntersection",function(){return r}),C.d(v,"adjustSliding",function(){return i}),C.d(v,"addSliding",function(){return o}),C.d(v,"computeReloadInterval",function(){return u}),C.d(v,"getFragmentWithSN",function(){return f}),C.d(v,"getPartWith",function(){return s});var M=C("./src/polyfills/number.ts"),m=C("./src/utils/logger.ts");function y(l,t,S){switch(t){case"audio":l.audioGroupIds||(l.audioGroupIds=[]),l.audioGroupIds.push(S);break;case"text":l.textGroupIds||(l.textGroupIds=[]),l.textGroupIds.push(S);break}}function w(l){var t={};l.forEach(function(S){var x=S.groupId||"";S.id=t[x]=t[x]||0,t[x]++})}function b(l,t,S){var x=l[t],h=l[S];p(x,h)}function p(l,t){var S=t.startPTS;if(Object(M.isFiniteNumber)(S)){var x=0,h;t.sn>l.sn?(x=S-l.start,h=l):(x=l.start-S,h=t),h.duration!==x&&(h.duration=x)}else if(t.sn>l.sn){var R=l.cc===t.cc;R&&l.minEndPTS?t.start=l.start+(l.minEndPTS-l.start):t.start=l.start+l.duration}else t.start=Math.max(l.start-t.duration,0)}function d(l,t,S,x,h,R){var O=x-S;O<=0&&(m.logger.warn("Fragment should have a positive duration",t),x=S+t.duration,R=h+t.duration);var g=S,_=x,E=t.startPTS,T=t.endPTS;if(Object(M.isFiniteNumber)(E)){var L=Math.abs(E-S);Object(M.isFiniteNumber)(t.deltaPTS)?t.deltaPTS=Math.max(L,t.deltaPTS):t.deltaPTS=L,g=Math.max(S,E),S=Math.min(S,E),h=Math.min(h,t.startDTS),_=Math.min(x,T),x=Math.max(x,T),R=Math.max(R,t.endDTS)}t.duration=x-S;var I=S-t.start;t.appendedPTS=x,t.start=t.startPTS=S,t.maxStartPTS=g,t.startDTS=h,t.endPTS=x,t.minEndPTS=_,t.endDTS=R;var P=t.sn;if(!l||P<l.startSN||P>l.endSN)return 0;var G,W=P-l.startSN,H=l.fragments;for(H[W]=t,G=W;G>0;G--)p(H[G],H[G-1]);for(G=W;G<H.length-1;G++)p(H[G],H[G+1]);return l.fragmentHint&&p(H[H.length-1],l.fragmentHint),l.PTSKnown=l.alignedSliding=!0,I}function n(l,t){for(var S=null,x=l.fragments,h=x.length-1;h>=0;h--){var R=x[h].initSegment;if(R){S=R;break}}l.fragmentHint&&delete l.fragmentHint.endPTS;var O=0,g;if(r(l,t,function(G,W){G.relurl&&(O=G.cc-W.cc),Object(M.isFiniteNumber)(G.startPTS)&&Object(M.isFiniteNumber)(G.endPTS)&&(W.start=W.startPTS=G.startPTS,W.startDTS=G.startDTS,W.appendedPTS=G.appendedPTS,W.maxStartPTS=G.maxStartPTS,W.endPTS=G.endPTS,W.endDTS=G.endDTS,W.minEndPTS=G.minEndPTS,W.duration=G.endPTS-G.startPTS,W.duration&&(g=W),t.PTSKnown=t.alignedSliding=!0),W.elementaryStreams=G.elementaryStreams,W.loader=G.loader,W.stats=G.stats,W.urlId=G.urlId,G.initSegment&&(W.initSegment=G.initSegment,S=G.initSegment)}),S){var _=t.fragmentHint?t.fragments.concat(t.fragmentHint):t.fragments;_.forEach(function(G){var W;(!G.initSegment||G.initSegment.relurl===((W=S)===null||W===void 0?void 0:W.relurl))&&(G.initSegment=S)})}if(t.skippedSegments&&(t.deltaUpdateFailed=t.fragments.some(function(G){return!G}),t.deltaUpdateFailed)){m.logger.warn("[level-helper] Previous playlist missing segments skipped in delta playlist");for(var E=t.skippedSegments;E--;)t.fragments.shift();t.startSN=t.fragments[0].sn,t.startCC=t.fragments[0].cc}var T=t.fragments;if(O){m.logger.warn("discontinuity sliding from playlist, take drift into account");for(var L=0;L<T.length;L++)T[L].cc+=O}t.skippedSegments&&(t.startCC=t.fragments[0].cc),c(l.partList,t.partList,function(G,W){W.elementaryStreams=G.elementaryStreams,W.stats=G.stats}),g?d(t,g,g.startPTS,g.endPTS,g.startDTS,g.endDTS):i(l,t),T.length&&(t.totalduration=t.edge-T[0].start),t.driftStartTime=l.driftStartTime,t.driftStart=l.driftStart;var I=t.advancedDateTime;if(t.advanced&&I){var P=t.edge;t.driftStart||(t.driftStartTime=I,t.driftStart=P),t.driftEndTime=I,t.driftEnd=P}else t.driftEndTime=l.driftEndTime,t.driftEnd=l.driftEnd,t.advancedDateTime=l.advancedDateTime}function c(l,t,S){if(l&&t)for(var x=0,h=0,R=l.length;h<=R;h++){var O=l[h],g=t[h+x];O&&g&&O.index===g.index&&O.fragment.sn===g.fragment.sn?S(O,g):x--}}function r(l,t,S){for(var x=t.skippedSegments,h=Math.max(l.startSN,t.startSN)-t.startSN,R=(l.fragmentHint?1:0)+(x?t.endSN:Math.min(l.endSN,t.endSN))-t.startSN,O=t.startSN-l.startSN,g=t.fragmentHint?t.fragments.concat(t.fragmentHint):t.fragments,_=l.fragmentHint?l.fragments.concat(l.fragmentHint):l.fragments,E=h;E<=R;E++){var T=_[O+E],L=g[E];x&&!L&&E<x&&(L=t.fragments[E]=T),T&&L&&S(T,L)}}function i(l,t){var S=t.startSN+t.skippedSegments-l.startSN,x=l.fragments;if(S<0||S>=x.length)return;o(t,x[S].start)}function o(l,t){if(t){for(var S=l.fragments,x=l.skippedSegments;x<S.length;x++)S[x].start+=t;l.fragmentHint&&(l.fragmentHint.start+=t)}}function u(l,t){var S=1e3*l.levelTargetDuration,x=S/2,h=l.age,R=h>0&&h<S*3,O=t.loading.end-t.loading.start,g,_=l.availabilityDelay;if(l.updated===!1)if(R){var E=333*l.misses;g=Math.max(Math.min(x,O*2),E),l.availabilityDelay=(l.availabilityDelay||0)+g}else g=x;else R?(_=Math.min(_||S/2,h),l.availabilityDelay=_,g=_+S-h):g=S-O;return Math.round(g)}function f(l,t,S){if(!l||!l.details)return null;var x=l.details,h=x.fragments[t-x.startSN];return h||(h=x.fragmentHint,h&&h.sn===t?h:t<x.startSN&&S&&S.sn===t?S:null)}function s(l,t,S){if(!l||!l.details)return null;var x=l.details.partList;if(x)for(var h=x.length;h--;){var R=x[h];if(R.index===S&&R.fragment.sn===t)return R}return null}},"./src/controller/stream-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return x});var M=C("./src/polyfills/number.ts"),m=C("./src/controller/base-stream-controller.ts"),y=C("./src/is-supported.ts"),w=C("./src/events.ts"),b=C("./src/utils/buffer-helper.ts"),p=C("./src/controller/fragment-tracker.ts"),d=C("./src/types/loader.ts"),n=C("./src/loader/fragment.ts"),c=C("./src/demux/transmuxer-interface.ts"),r=C("./src/types/transmuxer.ts"),i=C("./src/controller/gap-controller.ts"),o=C("./src/errors.ts"),u=C("./src/utils/logger.ts");function f(h,R){for(var O=0;O<R.length;O++){var g=R[O];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(h,g.key,g)}}function s(h,R,O){return R&&f(h.prototype,R),O&&f(h,O),h}function l(h,R){h.prototype=Object.create(R.prototype),h.prototype.constructor=h,t(h,R)}function t(h,R){return t=Object.setPrototypeOf||function(g,_){return g.__proto__=_,g},t(h,R)}var S=100,x=function(h){l(R,h);function R(g,_){var E;return E=h.call(this,g,_,"[stream-controller]")||this,E.audioCodecSwap=!1,E.gapController=null,E.level=-1,E._forceStartLoad=!1,E.altAudio=!1,E.audioOnly=!1,E.fragPlaying=null,E.onvplaying=null,E.onvseeked=null,E.fragLastKbps=0,E.stalled=!1,E.couldBacktrack=!1,E.audioCodecSwitch=!1,E.videoBuffer=null,E._registerListeners(),E}var O=R.prototype;return O._registerListeners=function(){var _=this.hls;_.on(w.Events.MEDIA_ATTACHED,this.onMediaAttached,this),_.on(w.Events.MEDIA_DETACHING,this.onMediaDetaching,this),_.on(w.Events.MANIFEST_LOADING,this.onManifestLoading,this),_.on(w.Events.MANIFEST_PARSED,this.onManifestParsed,this),_.on(w.Events.LEVEL_LOADING,this.onLevelLoading,this),_.on(w.Events.LEVEL_LOADED,this.onLevelLoaded,this),_.on(w.Events.FRAG_LOAD_EMERGENCY_ABORTED,this.onFragLoadEmergencyAborted,this),_.on(w.Events.ERROR,this.onError,this),_.on(w.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),_.on(w.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),_.on(w.Events.BUFFER_CREATED,this.onBufferCreated,this),_.on(w.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),_.on(w.Events.LEVELS_UPDATED,this.onLevelsUpdated,this),_.on(w.Events.FRAG_BUFFERED,this.onFragBuffered,this)},O._unregisterListeners=function(){var _=this.hls;_.off(w.Events.MEDIA_ATTACHED,this.onMediaAttached,this),_.off(w.Events.MEDIA_DETACHING,this.onMediaDetaching,this),_.off(w.Events.MANIFEST_LOADING,this.onManifestLoading,this),_.off(w.Events.MANIFEST_PARSED,this.onManifestParsed,this),_.off(w.Events.LEVEL_LOADED,this.onLevelLoaded,this),_.off(w.Events.FRAG_LOAD_EMERGENCY_ABORTED,this.onFragLoadEmergencyAborted,this),_.off(w.Events.ERROR,this.onError,this),_.off(w.Events.AUDIO_TRACK_SWITCHING,this.onAudioTrackSwitching,this),_.off(w.Events.AUDIO_TRACK_SWITCHED,this.onAudioTrackSwitched,this),_.off(w.Events.BUFFER_CREATED,this.onBufferCreated,this),_.off(w.Events.BUFFER_FLUSHED,this.onBufferFlushed,this),_.off(w.Events.LEVELS_UPDATED,this.onLevelsUpdated,this),_.off(w.Events.FRAG_BUFFERED,this.onFragBuffered,this)},O.onHandlerDestroying=function(){this._unregisterListeners(),this.onMediaDetaching()},O.startLoad=function(_){if(this.levels){var E=this.lastCurrentTime,T=this.hls;if(this.stopLoad(),this.setInterval(S),this.level=-1,this.fragLoadError=0,!this.startFragRequested){var L=T.startLevel;L===-1&&(T.config.testBandwidth?(L=0,this.bitrateTest=!0):L=T.nextAutoLevel),this.level=T.nextLoadLevel=L,this.loadedmetadata=!1}E>0&&_===-1&&(this.log("Override startPosition with lastCurrentTime @"+E.toFixed(3)),_=E),this.state=m.State.IDLE,this.nextLoadPosition=this.startPosition=this.lastCurrentTime=_,this.tick()}else this._forceStartLoad=!0,this.state=m.State.STOPPED},O.stopLoad=function(){this._forceStartLoad=!1,h.prototype.stopLoad.call(this)},O.doTick=function(){switch(this.state){case m.State.IDLE:this.doTickIdle();break;case m.State.WAITING_LEVEL:{var _,E=this.levels,T=this.level,L=E==null||((_=E[T])===null||_===void 0)?void 0:_.details;if(L&&(!L.live||this.levelLastLoaded===this.level)){if(this.waitForCdnTuneIn(L))break;this.state=m.State.IDLE;break}break}case m.State.FRAG_LOADING_WAITING_RETRY:{var I,P=self.performance.now(),G=this.retryDate;(!G||P>=G||(I=this.media)!==null&&I!==void 0&&I.seeking)&&(this.log("retryDate reached, switch back to IDLE state"),this.state=m.State.IDLE)}break;default:break}this.onTickEnd()},O.onTickEnd=function(){h.prototype.onTickEnd.call(this),this.checkBuffer(),this.checkFragmentChanged()},O.doTickIdle=function(){var _,E,T=this.hls,L=this.levelLastLoaded,I=this.levels,P=this.media,G=T.config,W=T.nextLoadLevel;if(L===null||!P&&(this.startFragRequested||!G.startFragPrefetch))return;if(this.altAudio&&this.audioOnly)return;if(!I||!I[W])return;var H=I[W];this.level=T.nextLoadLevel=W;var z=H.details;if(!z||this.state===m.State.WAITING_LEVEL||z.live&&this.levelLastLoaded!==W){this.state=m.State.WAITING_LEVEL;return}var B=this.getFwdBufferInfo(this.mediaBuffer?this.mediaBuffer:P,d.PlaylistLevelType.MAIN);if(B===null)return;var k=B.len,K=this.getMaxBufferLength(H.maxBitrate);if(k>=K)return;if(this._streamEnded(B,z)){var Y={};this.altAudio&&(Y.type="video"),this.hls.trigger(w.Events.BUFFER_EOS,Y),this.state=m.State.ENDED;return}var ne=B.end,oe=this.getNextFragment(ne,z);if(this.couldBacktrack&&!this.fragPrevious&&oe&&oe.sn!=="initSegment"){var _e=oe.sn-z.startSN;_e>1&&(oe=z.fragments[_e-1],this.fragmentTracker.removeFragment(oe))}if(oe&&this.fragmentTracker.getState(oe)===p.FragmentState.OK&&this.nextLoadPosition>ne){var xe=this.audioOnly&&!this.altAudio?n.ElementaryStreamTypes.AUDIO:n.ElementaryStreamTypes.VIDEO;this.afterBufferFlushed(P,xe,d.PlaylistLevelType.MAIN),oe=this.getNextFragment(this.nextLoadPosition,z)}if(!oe)return;oe.initSegment&&!oe.initSegment.data&&!this.bitrateTest&&(oe=oe.initSegment),((_=oe.decryptdata)===null||_===void 0?void 0:_.keyFormat)==="identity"&&!((E=oe.decryptdata)!==null&&E!==void 0&&E.key)?this.loadKey(oe,z):this.loadFragment(oe,z,ne)},O.loadFragment=function(_,E,T){var L,I=this.fragmentTracker.getState(_);if(this.fragCurrent=_,I===p.FragmentState.BACKTRACKED){var P=this.fragmentTracker.getBacktrackData(_);if(P){this._handleFragmentLoadProgress(P),this._handleFragmentLoadComplete(P);return}else I=p.FragmentState.NOT_LOADED}I===p.FragmentState.NOT_LOADED||I===p.FragmentState.PARTIAL?_.sn==="initSegment"?this._loadInitSegment(_):this.bitrateTest?(_.bitrateTest=!0,this.log("Fragment "+_.sn+" of level "+_.level+" is being downloaded to test bitrate and will not be buffered"),this._loadBitrateTestFrag(_)):(this.startFragRequested=!0,h.prototype.loadFragment.call(this,_,E,T)):I===p.FragmentState.APPENDING?this.reduceMaxBufferLength(_.duration)&&this.fragmentTracker.removeFragment(_):((L=this.media)===null||L===void 0?void 0:L.buffered.length)===0&&this.fragmentTracker.removeAllFragments()},O.getAppendedFrag=function(_){var E=this.fragmentTracker.getAppendedFrag(_,d.PlaylistLevelType.MAIN);return E&&"fragment"in E?E.fragment:E},O.getBufferedFrag=function(_){return this.fragmentTracker.getBufferedFrag(_,d.PlaylistLevelType.MAIN)},O.followingBufferedFrag=function(_){return _?this.getBufferedFrag(_.end+.5):null},O.immediateLevelSwitch=function(){this.abortCurrentFrag(),this.flushMainBuffer(0,Number.POSITIVE_INFINITY)},O.nextLevelSwitch=function(){var _=this.levels,E=this.media;if(E!=null&&E.readyState){var T,L=this.getAppendedFrag(E.currentTime);if(L&&L.start>1&&this.flushMainBuffer(0,L.start-1),!E.paused&&_){var I=this.hls.nextLoadLevel,P=_[I],G=this.fragLastKbps;G&&this.fragCurrent?T=this.fragCurrent.duration*P.maxBitrate/(1e3*G)+1:T=0}else T=0;var W=this.getBufferedFrag(E.currentTime+T);if(W){var H=this.followingBufferedFrag(W);if(H){this.abortCurrentFrag();var z=H.maxStartPTS?H.maxStartPTS:H.start,B=H.duration,k=Math.max(W.end,z+Math.min(Math.max(B-this.config.maxFragLookUpTolerance,B*.5),B*.75));this.flushMainBuffer(k,Number.POSITIVE_INFINITY)}}}},O.abortCurrentFrag=function(){var _=this.fragCurrent;this.fragCurrent=null,_!=null&&_.loader&&_.loader.abort(),this.state===m.State.KEY_LOADING&&(this.state=m.State.IDLE),this.nextLoadPosition=this.getLoadPosition()},O.flushMainBuffer=function(_,E){h.prototype.flushMainBuffer.call(this,_,E,this.altAudio?"video":null)},O.onMediaAttached=function(_,E){h.prototype.onMediaAttached.call(this,_,E);var T=E.media;this.onvplaying=this.onMediaPlaying.bind(this),this.onvseeked=this.onMediaSeeked.bind(this),T.addEventListener("playing",this.onvplaying),T.addEventListener("seeked",this.onvseeked),this.gapController=new i.default(this.config,T,this.fragmentTracker,this.hls)},O.onMediaDetaching=function(){var _=this.media;_&&(_.removeEventListener("playing",this.onvplaying),_.removeEventListener("seeked",this.onvseeked),this.onvplaying=this.onvseeked=null,this.videoBuffer=null),this.fragPlaying=null,this.gapController&&(this.gapController.destroy(),this.gapController=null),h.prototype.onMediaDetaching.call(this)},O.onMediaPlaying=function(){this.tick()},O.onMediaSeeked=function(){var _=this.media,E=_?_.currentTime:null;Object(M.isFiniteNumber)(E)&&this.log("Media seeked to "+E.toFixed(3)),this.tick()},O.onManifestLoading=function(){this.log("Trigger BUFFER_RESET"),this.hls.trigger(w.Events.BUFFER_RESET,void 0),this.fragmentTracker.removeAllFragments(),this.couldBacktrack=this.stalled=!1,this.startPosition=this.lastCurrentTime=0,this.fragPlaying=null},O.onManifestParsed=function(_,E){var T=!1,L=!1,I;E.levels.forEach(function(P){I=P.audioCodec,I&&(I.indexOf("mp4a.40.2")!==-1&&(T=!0),I.indexOf("mp4a.40.5")!==-1&&(L=!0))}),this.audioCodecSwitch=T&&L&&!Object(y.changeTypeSupported)(),this.audioCodecSwitch&&this.log("Both AAC/HE-AAC audio found in levels; declaring level codec as HE-AAC"),this.levels=E.levels,this.startFragRequested=!1},O.onLevelLoading=function(_,E){var T=this.levels;if(!T||this.state!==m.State.IDLE)return;var L=T[E.level];(!L.details||L.details.live&&this.levelLastLoaded!==E.level||this.waitForCdnTuneIn(L.details))&&(this.state=m.State.WAITING_LEVEL)},O.onLevelLoaded=function(_,E){var T,L=this.levels,I=E.level,P=E.details,G=P.totalduration;if(!L){this.warn("Levels were reset while loading level "+I);return}this.log("Level "+I+" loaded ["+P.startSN+","+P.endSN+"], cc ["+P.startCC+", "+P.endCC+"] duration:"+G);var W=this.fragCurrent;W&&(this.state===m.State.FRAG_LOADING||this.state===m.State.FRAG_LOADING_WAITING_RETRY)&&(W.level!==E.level&&W.loader&&(this.state=m.State.IDLE,W.loader.abort()));var H=L[I],z=0;if(P.live||(T=H.details)!==null&&T!==void 0&&T.live){if(P.fragments[0]||(P.deltaUpdateFailed=!0),P.deltaUpdateFailed)return;z=this.alignPlaylists(P,H.details)}if(H.details=P,this.levelLastLoaded=I,this.hls.trigger(w.Events.LEVEL_UPDATED,{details:P,level:I}),this.state===m.State.WAITING_LEVEL){if(this.waitForCdnTuneIn(P))return;this.state=m.State.IDLE}this.startFragRequested?P.live&&this.synchronizeToLiveEdge(P):this.setStartPosition(P,z),this.tick()},O._handleFragmentLoadProgress=function(_){var E,T=_.frag,L=_.part,I=_.payload,P=this.levels;if(!P){this.warn("Levels were reset while fragment load was in progress. Fragment "+T.sn+" of level "+T.level+" will not be buffered");return}var G=P[T.level],W=G.details;if(!W){this.warn("Dropping fragment "+T.sn+" of level "+T.level+" after level details were reset");return}var H=G.videoCodec,z=W.PTSKnown||!W.live,B=(E=T.initSegment)===null||E===void 0?void 0:E.data,k=this._getAudioCodec(G),K=this.transmuxer=this.transmuxer||new c.default(this.hls,d.PlaylistLevelType.MAIN,this._handleTransmuxComplete.bind(this),this._handleTransmuxerFlush.bind(this)),Y=L?L.index:-1,ne=Y!==-1,oe=new r.ChunkMetadata(T.level,T.sn,T.stats.chunkCount,I.byteLength,Y,ne),_e=this.initPTS[T.cc];K.push(I,B,k,H,T,L,W.totalduration,z,oe,_e)},O.onAudioTrackSwitching=function(_,E){var T=this.altAudio,L=!!E.url,I=E.id;if(!L){if(this.mediaBuffer!==this.media){this.log("Switching on main audio, use media.buffered to schedule main fragment loading"),this.mediaBuffer=this.media;var P=this.fragCurrent;P!=null&&P.loader&&(this.log("Switching to main audio track, cancel main fragment load"),P.loader.abort()),this.resetTransmuxer(),this.resetLoadingState()}else this.audioOnly&&this.resetTransmuxer();var G=this.hls;T&&G.trigger(w.Events.BUFFER_FLUSHING,{startOffset:0,endOffset:Number.POSITIVE_INFINITY,type:"audio"}),G.trigger(w.Events.AUDIO_TRACK_SWITCHED,{id:I})}},O.onAudioTrackSwitched=function(_,E){var T=E.id,L=!!this.hls.audioTracks[T].url;if(L){var I=this.videoBuffer;I&&this.mediaBuffer!==I&&(this.log("Switching on alternate audio, use video.buffered to schedule main fragment loading"),this.mediaBuffer=I)}this.altAudio=L,this.tick()},O.onBufferCreated=function(_,E){var T=E.tracks,L,I,P=!1;for(var G in T){var W=T[G];if(W.id==="main"){if(I=G,L=W,G==="video"){var H=T[G];H&&(this.videoBuffer=H.buffer)}}else P=!0}P&&L?(this.log("Alternate track found, use "+I+".buffered to schedule main fragment loading"),this.mediaBuffer=L.buffer):this.mediaBuffer=this.media},O.onFragBuffered=function(_,E){var T=E.frag,L=E.part;if(T&&T.type!==d.PlaylistLevelType.MAIN)return;if(this.fragContextChanged(T)){this.warn("Fragment "+T.sn+(L?" p: "+L.index:"")+" of level "+T.level+" finished buffering, but was aborted. state: "+this.state),this.state===m.State.PARSED&&(this.state=m.State.IDLE);return}var I=L?L.stats:T.stats;this.fragLastKbps=Math.round(8*I.total/(I.buffering.end-I.loading.first)),T.sn!=="initSegment"&&(this.fragPrevious=T),this.fragBufferedComplete(T,L)},O.onError=function(_,E){switch(E.details){case o.ErrorDetails.FRAG_LOAD_ERROR:case o.ErrorDetails.FRAG_LOAD_TIMEOUT:case o.ErrorDetails.KEY_LOAD_ERROR:case o.ErrorDetails.KEY_LOAD_TIMEOUT:this.onFragmentOrKeyLoadError(d.PlaylistLevelType.MAIN,E);break;case o.ErrorDetails.LEVEL_LOAD_ERROR:case o.ErrorDetails.LEVEL_LOAD_TIMEOUT:this.state!==m.State.ERROR&&(E.fatal?(this.warn(""+E.details),this.state=m.State.ERROR):!E.levelRetry&&this.state===m.State.WAITING_LEVEL&&(this.state=m.State.IDLE));break;case o.ErrorDetails.BUFFER_FULL_ERROR:if(E.parent==="main"&&(this.state===m.State.PARSING||this.state===m.State.PARSED)){var T=!0,L=this.getFwdBufferInfo(this.media,d.PlaylistLevelType.MAIN);L&&L.len>.5&&(T=!this.reduceMaxBufferLength(L.len)),T&&(this.warn("buffer full error also media.currentTime is not buffered, flush main"),this.immediateLevelSwitch()),this.resetLoadingState()}break;default:break}},O.checkBuffer=function(){var _=this.media,E=this.gapController;if(!_||!E||!_.readyState)return;var T=b.BufferHelper.getBuffered(_);!this.loadedmetadata&&T.length?(this.loadedmetadata=!0,this.seekToStartPos()):E.poll(this.lastCurrentTime),this.lastCurrentTime=_.currentTime},O.onFragLoadEmergencyAborted=function(){this.state=m.State.IDLE,this.loadedmetadata||(this.startFragRequested=!1,this.nextLoadPosition=this.startPosition),this.tickImmediate()},O.onBufferFlushed=function(_,E){var T=E.type;if(T!==n.ElementaryStreamTypes.AUDIO||this.audioOnly&&!this.altAudio){var L=(T===n.ElementaryStreamTypes.VIDEO?this.videoBuffer:this.mediaBuffer)||this.media;this.afterBufferFlushed(L,T,d.PlaylistLevelType.MAIN)}},O.onLevelsUpdated=function(_,E){this.levels=E.levels},O.swapAudioCodec=function(){this.audioCodecSwap=!this.audioCodecSwap},O.seekToStartPos=function(){var _=this.media,E=_.currentTime,T=this.startPosition;if(T>=0&&E<T){if(_.seeking){u.logger.log("could not seek to "+T+", already seeking at "+E);return}var L=b.BufferHelper.getBuffered(_),I=L.length?L.start(0):0,P=I-T;P>0&&(P<this.config.maxBufferHole||P<this.config.maxFragLookUpTolerance)&&(u.logger.log("adjusting start position by "+P+" to match buffer start"),T+=P,this.startPosition=T),this.log("seek to target start position "+T+" from current time "+E),_.currentTime=T}},O._getAudioCodec=function(_){var E=this.config.defaultAudioCodec||_.audioCodec;return this.audioCodecSwap&&E&&(this.log("Swapping audio codec"),E.indexOf("mp4a.40.5")!==-1?E="mp4a.40.2":E="mp4a.40.5"),E},O._loadBitrateTestFrag=function(_){var E=this;this._doFragLoad(_).then(function(T){var L=E.hls;if(!T||L.nextLoadLevel||E.fragContextChanged(_))return;E.fragLoadError=0,E.state=m.State.IDLE,E.startFragRequested=!1,E.bitrateTest=!1;var I=_.stats;I.parsing.start=I.parsing.end=I.buffering.start=I.buffering.end=self.performance.now(),L.trigger(w.Events.FRAG_LOADED,T)})},O._handleTransmuxComplete=function(_){var E,T="main",L=this.hls,I=_.remuxResult,P=_.chunkMeta,G=this.getCurrentContext(P);if(!G){this.warn("The loading context changed while buffering fragment "+P.sn+" of level "+P.level+". This chunk will not be buffered."),this.resetLiveStartWhenNotLoaded(P.level);return}var W=G.frag,H=G.part,z=G.level,B=I.video,k=I.text,K=I.id3,Y=I.initSegment,ne=this.altAudio?void 0:I.audio;if(this.fragContextChanged(W))return;if(this.state=m.State.PARSING,Y){Y.tracks&&(this._bufferInitSegment(z,Y.tracks,W,P),L.trigger(w.Events.FRAG_PARSING_INIT_SEGMENT,{frag:W,id:T,tracks:Y.tracks}));var oe=Y.initPTS,_e=Y.timescale;Object(M.isFiniteNumber)(oe)&&(this.initPTS[W.cc]=oe,L.trigger(w.Events.INIT_PTS_FOUND,{frag:W,id:T,initPTS:oe,timescale:_e}))}if(B&&I.independent!==!1){if(z.details){var xe=B.startPTS,le=B.endPTS,me=B.startDTS,de=B.endDTS;if(H)H.elementaryStreams[B.type]={startPTS:xe,endPTS:le,startDTS:me,endDTS:de};else if(B.firstKeyFrame&&B.independent&&(this.couldBacktrack=!0),B.dropped&&B.independent){var ae=this.getLoadPosition()+this.config.maxBufferHole;if(ae<xe){this.backtrack(W);return}W.setElementaryStreamInfo(B.type,W.start,le,W.start,de,!0)}W.setElementaryStreamInfo(B.type,xe,le,me,de),this.bufferFragmentData(B,W,H,P)}}else if(I.independent===!1){this.backtrack(W);return}if(ne){var ie=ne.startPTS,q=ne.endPTS,ue=ne.startDTS,Z=ne.endDTS;H&&(H.elementaryStreams[n.ElementaryStreamTypes.AUDIO]={startPTS:ie,endPTS:q,startDTS:ue,endDTS:Z}),W.setElementaryStreamInfo(n.ElementaryStreamTypes.AUDIO,ie,q,ue,Z),this.bufferFragmentData(ne,W,H,P)}if(K!=null&&(E=K.samples)!==null&&E!==void 0&&E.length){var ee={frag:W,id:T,samples:K.samples};L.trigger(w.Events.FRAG_PARSING_METADATA,ee)}if(k){var Ee={frag:W,id:T,samples:k.samples};L.trigger(w.Events.FRAG_PARSING_USERDATA,Ee)}},O._bufferInitSegment=function(_,E,T,L){var I=this;if(this.state!==m.State.PARSING)return;this.audioOnly=!!E.audio&&!E.video,this.altAudio&&!this.audioOnly&&delete E.audio;var P=E.audio,G=E.video,W=E.audiovideo;if(P){var H=_.audioCodec,z=navigator.userAgent.toLowerCase();this.audioCodecSwitch&&(H&&(H.indexOf("mp4a.40.5")!==-1?H="mp4a.40.2":H="mp4a.40.5"),P.metadata.channelCount!==1&&z.indexOf("firefox")===-1&&(H="mp4a.40.5")),z.indexOf("android")!==-1&&P.container!=="audio/mpeg"&&(H="mp4a.40.2",this.log("Android: force audio codec to "+H)),_.audioCodec&&_.audioCodec!==H&&this.log('Swapping manifest audio codec "'+_.audioCodec+'" for "'+H+'"'),P.levelCodec=H,P.id="main",this.log("Init audio buffer, container:"+P.container+", codecs[selected/level/parsed]=["+(H||"")+"/"+(_.audioCodec||"")+"/"+P.codec+"]")}G&&(G.levelCodec=_.videoCodec,G.id="main",this.log("Init video buffer, container:"+G.container+", codecs[level/parsed]=["+(_.videoCodec||"")+"/"+G.codec+"]")),W&&this.log("Init audiovideo buffer, container:"+W.container+", codecs[level/parsed]=["+(_.attrs.CODECS||"")+"/"+W.codec+"]"),this.hls.trigger(w.Events.BUFFER_CODECS,E),Object.keys(E).forEach(function(B){var k=E[B],K=k.initSegment;K!=null&&K.byteLength&&I.hls.trigger(w.Events.BUFFER_APPENDING,{type:B,data:K,frag:T,part:null,chunkMeta:L,parent:T.type})}),this.tick()},O.backtrack=function(_){this.couldBacktrack=!0,this.resetTransmuxer(),this.flushBufferGap(_);var E=this.fragmentTracker.backtrack(_);this.fragPrevious=null,this.nextLoadPosition=_.start,E?this.resetFragmentLoading(_):this.state=m.State.BACKTRACKING},O.checkFragmentChanged=function(){var _=this.media,E=null;if(_&&_.readyState>1&&_.seeking===!1){var T=_.currentTime;if(b.BufferHelper.isBuffered(_,T)?E=this.getAppendedFrag(T):b.BufferHelper.isBuffered(_,T+.1)&&(E=this.getAppendedFrag(T+.1)),E){var L=this.fragPlaying,I=E.level;(!L||E.sn!==L.sn||L.level!==I||E.urlId!==L.urlId)&&(this.hls.trigger(w.Events.FRAG_CHANGED,{frag:E}),(!L||L.level!==I)&&this.hls.trigger(w.Events.LEVEL_SWITCHED,{level:I}),this.fragPlaying=E)}}},s(R,[{key:"nextLevel",get:function(){var _=this.nextBufferedFrag;return _?_.level:-1}},{key:"currentLevel",get:function(){var _=this.media;if(_){var E=this.getAppendedFrag(_.currentTime);if(E)return E.level}return-1}},{key:"nextBufferedFrag",get:function(){var _=this.media;if(_){var E=this.getAppendedFrag(_.currentTime);return this.followingBufferedFrag(E)}else return null}},{key:"forceStartLoad",get:function(){return this._forceStartLoad}}]),R}(m.default)},"./src/controller/subtitle-stream-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"SubtitleStreamController",function(){return l});var M=C("./src/events.ts"),m=C("./src/utils/logger.ts"),y=C("./src/utils/buffer-helper.ts"),w=C("./src/controller/fragment-finders.ts"),b=C("./src/utils/discontinuities.ts"),p=C("./src/controller/level-helper.ts"),d=C("./src/controller/fragment-tracker.ts"),n=C("./src/controller/base-stream-controller.ts"),c=C("./src/types/loader.ts"),r=C("./src/types/level.ts");function i(t,S){for(var x=0;x<S.length;x++){var h=S[x];h.enumerable=h.enumerable||!1,h.configurable=!0,"value"in h&&(h.writable=!0),Object.defineProperty(t,h.key,h)}}function o(t,S,x){return S&&i(t.prototype,S),x&&i(t,x),t}function u(t,S){t.prototype=Object.create(S.prototype),t.prototype.constructor=t,f(t,S)}function f(t,S){return f=Object.setPrototypeOf||function(h,R){return h.__proto__=R,h},f(t,S)}var s=500,l=function(t){u(S,t);function S(h,R){var O;return O=t.call(this,h,R,"[subtitle-stream-controller]")||this,O.levels=[],O.currentTrackId=-1,O.tracksBuffered=[],O.mainDetails=null,O._registerListeners(),O}var x=S.prototype;return x.onHandlerDestroying=function(){this._unregisterListeners(),this.mainDetails=null},x._registerListeners=function(){var R=this.hls;R.on(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),R.on(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this),R.on(M.Events.MANIFEST_LOADING,this.onManifestLoading,this),R.on(M.Events.LEVEL_LOADED,this.onLevelLoaded,this),R.on(M.Events.ERROR,this.onError,this),R.on(M.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),R.on(M.Events.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),R.on(M.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),R.on(M.Events.SUBTITLE_FRAG_PROCESSED,this.onSubtitleFragProcessed,this),R.on(M.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},x._unregisterListeners=function(){var R=this.hls;R.off(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),R.off(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this),R.off(M.Events.MANIFEST_LOADING,this.onManifestLoading,this),R.off(M.Events.LEVEL_LOADED,this.onLevelLoaded,this),R.off(M.Events.ERROR,this.onError,this),R.off(M.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),R.off(M.Events.SUBTITLE_TRACK_SWITCH,this.onSubtitleTrackSwitch,this),R.off(M.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),R.off(M.Events.SUBTITLE_FRAG_PROCESSED,this.onSubtitleFragProcessed,this),R.off(M.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)},x.startLoad=function(){this.stopLoad(),this.state=n.State.IDLE,this.setInterval(s),this.tick()},x.onManifestLoading=function(){this.mainDetails=null,this.fragmentTracker.removeAllFragments()},x.onLevelLoaded=function(R,O){this.mainDetails=O.details},x.onSubtitleFragProcessed=function(R,O){var g=O.frag,_=O.success;if(this.fragPrevious=g,this.state=n.State.IDLE,!_)return;var E=this.tracksBuffered[this.currentTrackId];if(!E)return;for(var T,L=g.start,I=0;I<E.length;I++)if(L>=E[I].start&&L<=E[I].end){T=E[I];break}var P=g.start+g.duration;T?T.end=P:(T={start:L,end:P},E.push(T)),this.fragmentTracker.fragBuffered(g)},x.onBufferFlushing=function(R,O){var g=O.startOffset,_=O.endOffset;if(g===0&&_!==Number.POSITIVE_INFINITY){var E=this.currentTrackId,T=this.levels;if(!T.length||!T[E]||!T[E].details)return;var L=T[E].details,I=L.targetduration,P=_-I;if(P<=0)return;O.endOffsetSubtitles=Math.max(0,P),this.tracksBuffered.forEach(function(G){for(var W=0;W<G.length;){if(G[W].end<=P){G.shift();continue}else if(G[W].start<P)G[W].start=P;else break;W++}}),this.fragmentTracker.removeFragmentsInRange(g,P,c.PlaylistLevelType.SUBTITLE)}},x.onError=function(R,O){var g,_=O.frag;if(!_||_.type!==c.PlaylistLevelType.SUBTITLE)return;(g=this.fragCurrent)!==null&&g!==void 0&&g.loader&&this.fragCurrent.loader.abort(),this.state=n.State.IDLE},x.onSubtitleTracksUpdated=function(R,O){var g=this,_=O.subtitleTracks;this.tracksBuffered=[],this.levels=_.map(function(E){return new r.Level(E)}),this.fragmentTracker.removeAllFragments(),this.fragPrevious=null,this.levels.forEach(function(E){g.tracksBuffered[E.id]=[]}),this.mediaBuffer=null},x.onSubtitleTrackSwitch=function(R,O){if(this.currentTrackId=O.id,!this.levels.length||this.currentTrackId===-1){this.clearInterval();return}var g=this.levels[this.currentTrackId];g!=null&&g.details?this.mediaBuffer=this.mediaBufferTimeRanges:this.mediaBuffer=null,g&&this.setInterval(s)},x.onSubtitleTrackLoaded=function(R,O){var g,_=O.details,E=O.id,T=this.currentTrackId,L=this.levels;if(!L.length)return;var I=L[T];if(E>=L.length||E!==T||!I)return;if(this.mediaBuffer=this.mediaBufferTimeRanges,_.live||(g=I.details)!==null&&g!==void 0&&g.live){var P=this.mainDetails;if(_.deltaUpdateFailed||!P)return;var G=P.fragments[0];if(!I.details)_.hasProgramDateTime&&P.hasProgramDateTime?Object(b.alignMediaPlaylistByPDT)(_,P):G&&Object(p.addSliding)(_,G.start);else{var W=this.alignPlaylists(_,I.details);W===0&&G&&Object(p.addSliding)(_,G.start)}}if(I.details=_,this.levelLastLoaded=E,this.tick(),_.live&&!this.fragCurrent&&this.media&&this.state===n.State.IDLE){var H=Object(w.findFragmentByPTS)(null,_.fragments,this.media.currentTime,0);H||(this.warn("Subtitle playlist not aligned with playback"),I.details=void 0)}},x._handleFragmentLoadComplete=function(R){var O=R.frag,g=R.payload,_=O.decryptdata,E=this.hls;if(this.fragContextChanged(O))return;if(g&&g.byteLength>0&&_&&_.key&&_.iv&&_.method==="AES-128"){var T=performance.now();this.decrypter.webCryptoDecrypt(new Uint8Array(g),_.key.buffer,_.iv.buffer).then(function(L){var I=performance.now();E.trigger(M.Events.FRAG_DECRYPTED,{frag:O,payload:L,stats:{tstart:T,tdecrypt:I}})})}},x.doTick=function(){if(!this.media){this.state=n.State.IDLE;return}if(this.state===n.State.IDLE){var R,O=this.currentTrackId,g=this.levels;if(!g.length||!g[O]||!g[O].details)return;var _=g[O].details,E=_.targetduration,T=this.config,L=this.media,I=y.BufferHelper.bufferedInfo(this.mediaBufferTimeRanges,L.currentTime-E,T.maxBufferHole),P=I.end,G=I.len,W=this.getMaxBufferLength()+E;if(G>W)return;console.assert(_,"Subtitle track details are defined on idle subtitle stream controller tick");var H=_.fragments,z=H.length,B=_.edge,k,K=this.fragPrevious;if(P<B){var Y=T.maxFragLookUpTolerance;K&&_.hasProgramDateTime&&(k=Object(w.findFragmentByPDT)(H,K.endProgramDateTime,Y)),k||(k=Object(w.findFragmentByPTS)(K,H,P,Y),!k&&K&&K.start<H[0].start&&(k=H[0]))}else k=H[z-1];(R=k)!==null&&R!==void 0&&R.encrypted?(m.logger.log("Loading key for "+k.sn),this.state=n.State.KEY_LOADING,this.hls.trigger(M.Events.KEY_LOADING,{frag:k})):k&&this.fragmentTracker.getState(k)===d.FragmentState.NOT_LOADED&&this.loadFragment(k,_,P)}},x.loadFragment=function(R,O,g){this.fragCurrent=R,t.prototype.loadFragment.call(this,R,O,g)},o(S,[{key:"mediaBufferTimeRanges",get:function(){return this.tracksBuffered[this.currentTrackId]||[]}}]),S}(n.default)},"./src/controller/subtitle-track-controller.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/events.ts"),m=C("./src/utils/texttrack-utils.ts"),y=C("./src/controller/base-playlist-controller.ts"),w=C("./src/types/loader.ts");function b(i,o){for(var u=0;u<o.length;u++){var f=o[u];f.enumerable=f.enumerable||!1,f.configurable=!0,"value"in f&&(f.writable=!0),Object.defineProperty(i,f.key,f)}}function p(i,o,u){return o&&b(i.prototype,o),u&&b(i,u),i}function d(i,o){i.prototype=Object.create(o.prototype),i.prototype.constructor=i,n(i,o)}function n(i,o){return n=Object.setPrototypeOf||function(f,s){return f.__proto__=s,f},n(i,o)}var c=function(i){d(o,i);function o(f){var s;return s=i.call(this,f,"[subtitle-track-controller]")||this,s.media=null,s.tracks=[],s.groupId=null,s.tracksInGroup=[],s.trackId=-1,s.selectDefaultTrack=!0,s.queuedDefaultTrack=-1,s.trackChangeListener=function(){return s.onTextTracksChanged()},s.asyncPollTrackChange=function(){return s.pollTrackChange(0)},s.useTextTrackPolling=!1,s.subtitlePollingInterval=-1,s.subtitleDisplay=!0,s.registerListeners(),s}var u=o.prototype;return u.destroy=function(){this.unregisterListeners(),this.tracks.length=0,this.tracksInGroup.length=0,this.trackChangeListener=this.asyncPollTrackChange=null,i.prototype.destroy.call(this)},u.registerListeners=function(){var s=this.hls;s.on(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),s.on(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this),s.on(M.Events.MANIFEST_LOADING,this.onManifestLoading,this),s.on(M.Events.MANIFEST_PARSED,this.onManifestParsed,this),s.on(M.Events.LEVEL_LOADING,this.onLevelLoading,this),s.on(M.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),s.on(M.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),s.on(M.Events.ERROR,this.onError,this)},u.unregisterListeners=function(){var s=this.hls;s.off(M.Events.MEDIA_ATTACHED,this.onMediaAttached,this),s.off(M.Events.MEDIA_DETACHING,this.onMediaDetaching,this),s.off(M.Events.MANIFEST_LOADING,this.onManifestLoading,this),s.off(M.Events.MANIFEST_PARSED,this.onManifestParsed,this),s.off(M.Events.LEVEL_LOADING,this.onLevelLoading,this),s.off(M.Events.LEVEL_SWITCHING,this.onLevelSwitching,this),s.off(M.Events.SUBTITLE_TRACK_LOADED,this.onSubtitleTrackLoaded,this),s.off(M.Events.ERROR,this.onError,this)},u.onMediaAttached=function(s,l){if(this.media=l.media,!this.media)return;this.queuedDefaultTrack>-1&&(this.subtitleTrack=this.queuedDefaultTrack,this.queuedDefaultTrack=-1),this.useTextTrackPolling=!(this.media.textTracks&&"onchange"in this.media.textTracks),this.useTextTrackPolling?this.pollTrackChange(500):this.media.textTracks.addEventListener("change",this.asyncPollTrackChange)},u.pollTrackChange=function(s){self.clearInterval(this.subtitlePollingInterval),this.subtitlePollingInterval=self.setInterval(this.trackChangeListener,s)},u.onMediaDetaching=function(){if(!this.media)return;self.clearInterval(this.subtitlePollingInterval),this.useTextTrackPolling||this.media.textTracks.removeEventListener("change",this.asyncPollTrackChange),this.trackId>-1&&(this.queuedDefaultTrack=this.trackId);var s=r(this.media.textTracks);s.forEach(function(l){Object(m.clearCurrentCues)(l)}),this.subtitleTrack=-1,this.media=null},u.onManifestLoading=function(){this.tracks=[],this.groupId=null,this.tracksInGroup=[],this.trackId=-1,this.selectDefaultTrack=!0},u.onManifestParsed=function(s,l){this.tracks=l.subtitleTracks},u.onSubtitleTrackLoaded=function(s,l){var t=l.id,S=l.details,x=this.trackId,h=this.tracksInGroup[x];if(!h){this.warn("Invalid subtitle track id "+t);return}var R=h.details;h.details=l.details,this.log("subtitle track "+t+" loaded ["+S.startSN+"-"+S.endSN+"]"),t===this.trackId&&(this.retryCount=0,this.playlistLoaded(t,l,R))},u.onLevelLoading=function(s,l){this.switchLevel(l.level)},u.onLevelSwitching=function(s,l){this.switchLevel(l.level)},u.switchLevel=function(s){var l=this.hls.levels[s];if(!(l!=null&&l.textGroupIds))return;var t=l.textGroupIds[l.urlId];if(this.groupId!==t){var S=this.tracksInGroup?this.tracksInGroup[this.trackId]:void 0,x=this.tracks.filter(function(O){return!t||O.groupId===t});this.tracksInGroup=x;var h=this.findTrackId(S==null?void 0:S.name)||this.findTrackId();this.groupId=t;var R={subtitleTracks:x};this.log("Updating subtitle tracks, "+x.length+' track(s) found in "'+t+'" group-id'),this.hls.trigger(M.Events.SUBTITLE_TRACKS_UPDATED,R),h!==-1&&this.setSubtitleTrack(h,S)}},u.findTrackId=function(s){for(var l=this.tracksInGroup,t=0;t<l.length;t++){var S=l[t];if((!this.selectDefaultTrack||S.default)&&(!s||s===S.name))return S.id}return-1},u.onError=function(s,l){if(i.prototype.onError.call(this,s,l),l.fatal||!l.context)return;l.context.type===w.PlaylistContextType.SUBTITLE_TRACK&&l.context.id===this.trackId&&l.context.groupId===this.groupId&&this.retryLoadingOrFail(l)},u.loadPlaylist=function(s){var l=this.tracksInGroup[this.trackId];if(this.shouldLoadTrack(l)){var t=l.id,S=l.groupId,x=l.url;if(s)try{x=s.addDirectives(x)}catch(h){this.warn("Could not construct new URL with HLS Delivery Directives: "+h)}this.log("Loading subtitle playlist for id "+t),this.hls.trigger(M.Events.SUBTITLE_TRACK_LOADING,{url:x,id:t,groupId:S,deliveryDirectives:s||null})}},u.toggleTrackModes=function(s){var l=this,t=this.media,S=this.subtitleDisplay,x=this.trackId;if(!t)return;var h=r(t.textTracks),R=h.filter(function(_){return _.groupId===l.groupId});if(s===-1)[].slice.call(h).forEach(function(_){_.mode="disabled"});else{var O=R[x];O&&(O.mode="disabled")}var g=R[s];g&&(g.mode=S?"showing":"hidden")},u.setSubtitleTrack=function(s,l){var t,S=this.tracksInGroup;if(!this.media){this.queuedDefaultTrack=s;return}if(this.trackId!==s&&this.toggleTrackModes(s),this.trackId===s&&(s===-1||(t=S[s])!==null&&t!==void 0&&t.details)||s<-1||s>=S.length)return;this.clearTimer();var x=S[s];if(this.log("Switching to subtitle track "+s),this.trackId=s,x){var h=x.id,R=x.groupId,O=R===void 0?"":R,g=x.name,_=x.type,E=x.url;this.hls.trigger(M.Events.SUBTITLE_TRACK_SWITCH,{id:h,groupId:O,name:g,type:_,url:E});var T=this.switchParams(x.url,l==null?void 0:l.details);this.loadPlaylist(T)}else this.hls.trigger(M.Events.SUBTITLE_TRACK_SWITCH,{id:s})},u.onTextTracksChanged=function(){if(this.useTextTrackPolling||self.clearInterval(this.subtitlePollingInterval),!this.media||!this.hls.config.renderTextTracksNatively)return;for(var s=-1,l=r(this.media.textTracks),t=0;t<l.length;t++)if(l[t].mode==="hidden")s=t;else if(l[t].mode==="showing"){s=t;break}this.subtitleTrack!==s&&(this.subtitleTrack=s)},p(o,[{key:"subtitleTracks",get:function(){return this.tracksInGroup}},{key:"subtitleTrack",get:function(){return this.trackId},set:function(s){this.selectDefaultTrack=!1;var l=this.tracksInGroup?this.tracksInGroup[this.trackId]:void 0;this.setSubtitleTrack(s,l)}}]),o}(y.default);function r(i){for(var o=[],u=0;u<i.length;u++){var f=i[u];f.kind==="subtitles"&&f.label&&o.push(i[u])}return o}v.default=c},"./src/controller/timeline-controller.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"TimelineController",function(){return r});var M=C("./src/polyfills/number.ts"),m=C("./src/events.ts"),y=C("./src/utils/cea-608-parser.ts"),w=C("./src/utils/output-filter.ts"),b=C("./src/utils/webvtt-parser.ts"),p=C("./src/utils/texttrack-utils.ts"),d=C("./src/utils/imsc1-ttml-parser.ts"),n=C("./src/types/loader.ts"),c=C("./src/utils/logger.ts"),r=function(){function f(l){if(this.hls=void 0,this.media=null,this.config=void 0,this.enabled=!0,this.Cues=void 0,this.textTracks=[],this.tracks=[],this.initPTS=[],this.timescale=[],this.unparsedVttFrags=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.cea608Parser1=void 0,this.cea608Parser2=void 0,this.lastSn=-1,this.lastPartIndex=-1,this.prevCC=-1,this.vttCCs=u(),this.captionsProperties=void 0,this.hls=l,this.config=l.config,this.Cues=l.config.cueHandler,this.captionsProperties={textTrack1:{label:this.config.captionsTextTrack1Label,languageCode:this.config.captionsTextTrack1LanguageCode},textTrack2:{label:this.config.captionsTextTrack2Label,languageCode:this.config.captionsTextTrack2LanguageCode},textTrack3:{label:this.config.captionsTextTrack3Label,languageCode:this.config.captionsTextTrack3LanguageCode},textTrack4:{label:this.config.captionsTextTrack4Label,languageCode:this.config.captionsTextTrack4LanguageCode}},this.config.enableCEA708Captions){var t=new w.default(this,"textTrack1"),S=new w.default(this,"textTrack2"),x=new w.default(this,"textTrack3"),h=new w.default(this,"textTrack4");this.cea608Parser1=new y.default(1,t,S),this.cea608Parser2=new y.default(3,x,h)}l.on(m.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),l.on(m.Events.MEDIA_DETACHING,this.onMediaDetaching,this),l.on(m.Events.MANIFEST_LOADING,this.onManifestLoading,this),l.on(m.Events.MANIFEST_LOADED,this.onManifestLoaded,this),l.on(m.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),l.on(m.Events.FRAG_LOADING,this.onFragLoading,this),l.on(m.Events.FRAG_LOADED,this.onFragLoaded,this),l.on(m.Events.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this),l.on(m.Events.FRAG_DECRYPTED,this.onFragDecrypted,this),l.on(m.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),l.on(m.Events.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this),l.on(m.Events.BUFFER_FLUSHING,this.onBufferFlushing,this)}var s=f.prototype;return s.destroy=function(){var t=this.hls;t.off(m.Events.MEDIA_ATTACHING,this.onMediaAttaching,this),t.off(m.Events.MEDIA_DETACHING,this.onMediaDetaching,this),t.off(m.Events.MANIFEST_LOADING,this.onManifestLoading,this),t.off(m.Events.MANIFEST_LOADED,this.onManifestLoaded,this),t.off(m.Events.SUBTITLE_TRACKS_UPDATED,this.onSubtitleTracksUpdated,this),t.off(m.Events.FRAG_LOADING,this.onFragLoading,this),t.off(m.Events.FRAG_LOADED,this.onFragLoaded,this),t.off(m.Events.FRAG_PARSING_USERDATA,this.onFragParsingUserdata,this),t.off(m.Events.FRAG_DECRYPTED,this.onFragDecrypted,this),t.off(m.Events.INIT_PTS_FOUND,this.onInitPtsFound,this),t.off(m.Events.SUBTITLE_TRACKS_CLEARED,this.onSubtitleTracksCleared,this),t.off(m.Events.BUFFER_FLUSHING,this.onBufferFlushing,this),this.hls=this.config=this.cea608Parser1=this.cea608Parser2=null},s.addCues=function(t,S,x,h,R){for(var O=!1,g=R.length;g--;){var _=R[g],E=o(_[0],_[1],S,x);if(E>=0&&(_[0]=Math.min(_[0],S),_[1]=Math.max(_[1],x),O=!0,E/(x-S)>.5))return}if(O||R.push([S,x]),this.config.renderTextTracksNatively){var T=this.captionsTracks[t];this.Cues.newCue(T,S,x,h)}else{var L=this.Cues.newCue(null,S,x,h);this.hls.trigger(m.Events.CUES_PARSED,{type:"captions",cues:L,track:t})}},s.onInitPtsFound=function(t,S){var x=this,h=S.frag,R=S.id,O=S.initPTS,g=S.timescale,_=this.unparsedVttFrags;R==="main"&&(this.initPTS[h.cc]=O,this.timescale[h.cc]=g),_.length&&(this.unparsedVttFrags=[],_.forEach(function(E){x.onFragLoaded(m.Events.FRAG_LOADED,E)}))},s.getExistingTrack=function(t){var S=this.media;if(S)for(var x=0;x<S.textTracks.length;x++){var h=S.textTracks[x];if(h[t])return h}return null},s.createCaptionsTrack=function(t){this.config.renderTextTracksNatively?this.createNativeTrack(t):this.createNonNativeTrack(t)},s.createNativeTrack=function(t){if(this.captionsTracks[t])return;var S=this.captionsProperties,x=this.captionsTracks,h=this.media,R=S[t],O=R.label,g=R.languageCode,_=this.getExistingTrack(t);if(_)x[t]=_,Object(p.clearCurrentCues)(x[t]),Object(p.sendAddTrackEvent)(x[t],h);else{var E=this.createTextTrack("captions",O,g);E&&(E[t]=!0,x[t]=E)}},s.createNonNativeTrack=function(t){if(this.nonNativeCaptionsTracks[t])return;var S=this.captionsProperties[t];if(!S)return;var x=S.label,h={_id:t,label:x,kind:"captions",default:S.media?!!S.media.default:!1,closedCaptions:S.media};this.nonNativeCaptionsTracks[t]=h,this.hls.trigger(m.Events.NON_NATIVE_TEXT_TRACKS_FOUND,{tracks:[h]})},s.createTextTrack=function(t,S,x){var h=this.media;return h?h.addTextTrack(t,S,x):void 0},s.onMediaAttaching=function(t,S){this.media=S.media,this._cleanTracks()},s.onMediaDetaching=function(){var t=this.captionsTracks;Object.keys(t).forEach(function(S){Object(p.clearCurrentCues)(t[S]),delete t[S]}),this.nonNativeCaptionsTracks={}},s.onManifestLoading=function(){this.lastSn=-1,this.lastPartIndex=-1,this.prevCC=-1,this.vttCCs=u(),this._cleanTracks(),this.tracks=[],this.captionsTracks={},this.nonNativeCaptionsTracks={},this.textTracks=[],this.unparsedVttFrags=this.unparsedVttFrags||[],this.initPTS=[],this.timescale=[],this.cea608Parser1&&this.cea608Parser2&&(this.cea608Parser1.reset(),this.cea608Parser2.reset())},s._cleanTracks=function(){var t=this.media;if(!t)return;var S=t.textTracks;if(S)for(var x=0;x<S.length;x++)Object(p.clearCurrentCues)(S[x])},s.onSubtitleTracksUpdated=function(t,S){var x=this;this.textTracks=[];var h=S.subtitleTracks||[],R=h.some(function(E){return E.textCodec===d.IMSC1_CODEC});if(this.config.enableWebVTT||R&&this.config.enableIMSC1){var O=this.tracks&&h&&this.tracks.length===h.length;if(this.tracks=h||[],this.config.renderTextTracksNatively){var g=this.media?this.media.textTracks:[];this.tracks.forEach(function(E,T){var L;if(T<g.length){for(var I=null,P=0;P<g.length;P++)if(i(g[P],E)){I=g[P];break}I&&(L=I)}L?Object(p.clearCurrentCues)(L):(L=x.createTextTrack("subtitles",E.name,E.lang),L&&(L.mode="disabled")),L&&(L.groupId=E.groupId,x.textTracks.push(L))})}else if(!O&&this.tracks&&this.tracks.length){var _=this.tracks.map(function(E){return{label:E.name,kind:E.type.toLowerCase(),default:E.default,subtitleTrack:E}});this.hls.trigger(m.Events.NON_NATIVE_TEXT_TRACKS_FOUND,{tracks:_})}}},s.onManifestLoaded=function(t,S){var x=this;this.config.enableCEA708Captions&&S.captions&&S.captions.forEach(function(h){var R=/(?:CC|SERVICE)([1-4])/.exec(h.instreamId);if(!R)return;var O="textTrack"+R[1],g=x.captionsProperties[O];if(!g)return;g.label=h.name,h.lang&&(g.languageCode=h.lang),g.media=h})},s.onFragLoading=function(t,S){var x=this.cea608Parser1,h=this.cea608Parser2,R=this.lastSn,O=this.lastPartIndex;if(!this.enabled||!(x&&h))return;if(S.frag.type===n.PlaylistLevelType.MAIN){var g,_,E=S.frag.sn,T=(g=S==null||((_=S.part)===null||_===void 0)?void 0:_.index)!=null?g:-1;E===R+1||E===R&&T===O+1||(x.reset(),h.reset()),this.lastSn=E,this.lastPartIndex=T}},s.onFragLoaded=function(t,S){var x=S.frag,h=S.payload,R=this.initPTS,O=this.unparsedVttFrags;if(x.type===n.PlaylistLevelType.SUBTITLE)if(h.byteLength){if(!Object(M.isFiniteNumber)(R[x.cc])){O.push(S),R.length&&this.hls.trigger(m.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:x,error:new Error("Missing initial subtitle PTS")});return}var g=x.decryptdata;if(g==null||g.key==null||g.method!=="AES-128"){var _=this.tracks[x.level],E=this.vttCCs;E[x.cc]||(E[x.cc]={start:x.start,prevCC:this.prevCC,new:!0},this.prevCC=x.cc),_&&_.textCodec===d.IMSC1_CODEC?this._parseIMSC1(x,h):this._parseVTTs(x,h,E)}}else this.hls.trigger(m.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:x,error:new Error("Empty subtitle payload")})},s._parseIMSC1=function(t,S){var x=this,h=this.hls;Object(d.parseIMSC1)(S,this.initPTS[t.cc],this.timescale[t.cc],function(R){x._appendCues(R,t.level),h.trigger(m.Events.SUBTITLE_FRAG_PROCESSED,{success:!0,frag:t})},function(R){c.logger.log("Failed to parse IMSC1: "+R),h.trigger(m.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:t,error:R})})},s._parseVTTs=function(t,S,x){var h=this,R=this.hls;Object(b.parseWebVTT)(S,this.initPTS[t.cc],this.timescale[t.cc],x,t.cc,t.start,function(O){h._appendCues(O,t.level),R.trigger(m.Events.SUBTITLE_FRAG_PROCESSED,{success:!0,frag:t})},function(O){h._fallbackToIMSC1(t,S),c.logger.log("Failed to parse VTT cue: "+O),R.trigger(m.Events.SUBTITLE_FRAG_PROCESSED,{success:!1,frag:t,error:O})})},s._fallbackToIMSC1=function(t,S){var x=this,h=this.tracks[t.level];h.textCodec||Object(d.parseIMSC1)(S,this.initPTS[t.cc],this.timescale[t.cc],function(){h.textCodec=d.IMSC1_CODEC,x._parseIMSC1(t,S)},function(){h.textCodec="wvtt"})},s._appendCues=function(t,S){var x=this.hls;if(this.config.renderTextTracksNatively){var h=this.textTracks[S];if(h.mode==="disabled")return;t.forEach(function(g){return Object(p.addCueToTrack)(h,g)})}else{var R=this.tracks[S],O=R.default?"default":"subtitles"+S;x.trigger(m.Events.CUES_PARSED,{type:"subtitles",cues:t,track:O})}},s.onFragDecrypted=function(t,S){var x=S.frag;if(x.type===n.PlaylistLevelType.SUBTITLE){if(!Object(M.isFiniteNumber)(this.initPTS[x.cc])){this.unparsedVttFrags.push(S);return}this.onFragLoaded(m.Events.FRAG_LOADED,S)}},s.onSubtitleTracksCleared=function(){this.tracks=[],this.captionsTracks={}},s.onFragParsingUserdata=function(t,S){var x=this.cea608Parser1,h=this.cea608Parser2;if(!this.enabled||!(x&&h))return;for(var R=0;R<S.samples.length;R++){var O=S.samples[R].bytes;if(O){var g=this.extractCea608Data(O);x.addData(S.samples[R].pts,g[0]),h.addData(S.samples[R].pts,g[1])}}},s.onBufferFlushing=function(t,S){var x=S.startOffset,h=S.endOffset,R=S.endOffsetSubtitles,O=S.type,g=this.media;if(!g||g.currentTime<h)return;if(!O||O==="video"){var _=this.captionsTracks;Object.keys(_).forEach(function(T){return Object(p.removeCuesInRange)(_[T],x,h)})}if(this.config.renderTextTracksNatively&&(x===0&&R!==void 0)){var E=this.textTracks;Object.keys(E).forEach(function(T){return Object(p.removeCuesInRange)(E[T],x,R)})}},s.extractCea608Data=function(t){for(var S=t[0]&31,x=2,h=[[],[]],R=0;R<S;R++){var O=t[x++],g=127&t[x++],_=127&t[x++],E=(4&O)!==0,T=3&O;if(g===0&&_===0)continue;E&&((T===0||T===1)&&(h[T].push(g),h[T].push(_)))}return h},f}();function i(f,s){return f&&f.label===s.name&&!(f.textTrack1||f.textTrack2)}function o(f,s,l,t){return Math.min(s,t)-Math.max(f,l)}function u(){return{ccOffset:0,presentationOffset:0,0:{start:0,prevCC:-1,new:!1}}}},"./src/crypt/aes-crypto.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return M});var M=function(){function m(w,b){this.subtle=void 0,this.aesIV=void 0,this.subtle=w,this.aesIV=b}var y=m.prototype;return y.decrypt=function(b,p){return this.subtle.decrypt({name:"AES-CBC",iv:this.aesIV},p,b)},m}()},"./src/crypt/aes-decryptor.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"removePadding",function(){return m}),C.d(v,"default",function(){return y});var M=C("./src/utils/typed-array.ts");function m(w){var b=w.byteLength,p=b&&new DataView(w.buffer).getUint8(b-1);return p?Object(M.sliceUint8)(w,0,b-p):w}var y=function(){function w(){this.rcon=[0,1,2,4,8,16,32,64,128,27,54],this.subMix=[new Uint32Array(256),new Uint32Array(256),new Uint32Array(256),new Uint32Array(256)],this.invSubMix=[new Uint32Array(256),new Uint32Array(256),new Uint32Array(256),new Uint32Array(256)],this.sBox=new Uint32Array(256),this.invSBox=new Uint32Array(256),this.key=new Uint32Array(0),this.ksRows=0,this.keySize=0,this.keySchedule=void 0,this.invKeySchedule=void 0,this.initTable()}var b=w.prototype;return b.uint8ArrayToUint32Array_=function(d){for(var n=new DataView(d),c=new Uint32Array(4),r=0;r<4;r++)c[r]=n.getUint32(r*4);return c},b.initTable=function(){var d=this.sBox,n=this.invSBox,c=this.subMix,r=c[0],i=c[1],o=c[2],u=c[3],f=this.invSubMix,s=f[0],l=f[1],t=f[2],S=f[3],x=new Uint32Array(256),h=0,R=0,O=0;for(O=0;O<256;O++)O<128?x[O]=O<<1:x[O]=O<<1^283;for(O=0;O<256;O++){var g=R^R<<1^R<<2^R<<3^R<<4;g=g>>>8^g&255^99,d[h]=g,n[g]=h;var _=x[h],E=x[_],T=x[E],L=x[g]*257^g*16843008;r[h]=L<<24|L>>>8,i[h]=L<<16|L>>>16,o[h]=L<<8|L>>>24,u[h]=L,L=T*16843009^E*65537^_*257^h*16843008,s[g]=L<<24|L>>>8,l[g]=L<<16|L>>>16,t[g]=L<<8|L>>>24,S[g]=L,h?(h=_^x[x[x[T^_]]],R^=x[x[R]]):h=R=1}},b.expandKey=function(d){for(var n=this.uint8ArrayToUint32Array_(d),c=!0,r=0;r<n.length&&c;)c=n[r]===this.key[r],r++;if(c)return;this.key=n;var i=this.keySize=n.length;if(i!==4&&i!==6&&i!==8)throw new Error("Invalid aes key size="+i);var o=this.ksRows=(i+6+1)*4,u,f,s=this.keySchedule=new Uint32Array(o),l=this.invKeySchedule=new Uint32Array(o),t=this.sBox,S=this.rcon,x=this.invSubMix,h=x[0],R=x[1],O=x[2],g=x[3],_,E;for(u=0;u<o;u++){if(u<i){_=s[u]=n[u];continue}E=_,u%i===0?(E=E<<8|E>>>24,E=t[E>>>24]<<24|t[E>>>16&255]<<16|t[E>>>8&255]<<8|t[E&255],E^=S[u/i|0]<<24):i>6&&u%i===4&&(E=t[E>>>24]<<24|t[E>>>16&255]<<16|t[E>>>8&255]<<8|t[E&255]),s[u]=_=(s[u-i]^E)>>>0}for(f=0;f<o;f++)u=o-f,f&3?E=s[u]:E=s[u-4],f<4||u<=4?l[f]=E:l[f]=h[t[E>>>24]]^R[t[E>>>16&255]]^O[t[E>>>8&255]]^g[t[E&255]],l[f]=l[f]>>>0},b.networkToHostOrderSwap=function(d){return d<<24|(d&65280)<<8|(d&16711680)>>8|d>>>24},b.decrypt=function(d,n,c){for(var r=this.keySize+6,i=this.invKeySchedule,o=this.invSBox,u=this.invSubMix,f=u[0],s=u[1],l=u[2],t=u[3],S=this.uint8ArrayToUint32Array_(c),x=S[0],h=S[1],R=S[2],O=S[3],g=new Int32Array(d),_=new Int32Array(g.length),E,T,L,I,P,G,W,H,z,B,k,K,Y,ne,oe=this.networkToHostOrderSwap;n<g.length;){for(z=oe(g[n]),B=oe(g[n+1]),k=oe(g[n+2]),K=oe(g[n+3]),P=z^i[0],G=K^i[1],W=k^i[2],H=B^i[3],Y=4,ne=1;ne<r;ne++)E=f[P>>>24]^s[G>>16&255]^l[W>>8&255]^t[H&255]^i[Y],T=f[G>>>24]^s[W>>16&255]^l[H>>8&255]^t[P&255]^i[Y+1],L=f[W>>>24]^s[H>>16&255]^l[P>>8&255]^t[G&255]^i[Y+2],I=f[H>>>24]^s[P>>16&255]^l[G>>8&255]^t[W&255]^i[Y+3],P=E,G=T,W=L,H=I,Y=Y+4;E=o[P>>>24]<<24^o[G>>16&255]<<16^o[W>>8&255]<<8^o[H&255]^i[Y],T=o[G>>>24]<<24^o[W>>16&255]<<16^o[H>>8&255]<<8^o[P&255]^i[Y+1],L=o[W>>>24]<<24^o[H>>16&255]<<16^o[P>>8&255]<<8^o[G&255]^i[Y+2],I=o[H>>>24]<<24^o[P>>16&255]<<16^o[G>>8&255]<<8^o[W&255]^i[Y+3],_[n]=oe(E^x),_[n+1]=oe(I^h),_[n+2]=oe(L^R),_[n+3]=oe(T^O),x=z,h=B,R=k,O=K,n=n+4}return _.buffer},w}()},"./src/crypt/decrypter.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return n});var M=C("./src/crypt/aes-crypto.ts"),m=C("./src/crypt/fast-aes-key.ts"),y=C("./src/crypt/aes-decryptor.ts"),w=C("./src/utils/logger.ts"),b=C("./src/utils/mp4-tools.ts"),p=C("./src/utils/typed-array.ts"),d=16,n=function(){function c(i,o,u){var f=u===void 0?{}:u,s=f.removePKCS7Padding,l=s===void 0?!0:s;if(this.logEnabled=!0,this.observer=void 0,this.config=void 0,this.removePKCS7Padding=void 0,this.subtle=null,this.softwareDecrypter=null,this.key=null,this.fastAesKey=null,this.remainderData=null,this.currentIV=null,this.currentResult=null,this.observer=i,this.config=o,this.removePKCS7Padding=l,l)try{var t=self.crypto;t&&(this.subtle=t.subtle||t.webkitSubtle)}catch(S){}this.subtle===null&&(this.config.enableSoftwareAES=!0)}var r=c.prototype;return r.destroy=function(){this.observer=null},r.isSync=function(){return this.config.enableSoftwareAES},r.flush=function(){var o=this.currentResult;if(!o){this.reset();return}var u=new Uint8Array(o);return this.reset(),this.removePKCS7Padding?Object(y.removePadding)(u):u},r.reset=function(){this.currentResult=null,this.currentIV=null,this.remainderData=null,this.softwareDecrypter&&(this.softwareDecrypter=null)},r.decrypt=function(o,u,f,s){if(this.config.enableSoftwareAES){this.softwareDecrypt(new Uint8Array(o),u,f);var l=this.flush();l&&s(l.buffer)}else this.webCryptoDecrypt(new Uint8Array(o),u,f).then(s)},r.softwareDecrypt=function(o,u,f){var s=this.currentIV,l=this.currentResult,t=this.remainderData;this.logOnce("JS AES decrypt"),t&&(o=Object(b.appendUint8Array)(t,o),this.remainderData=null);var S=this.getValidChunk(o);if(!S.length)return null;s&&(f=s);var x=this.softwareDecrypter;x||(x=this.softwareDecrypter=new y.default),x.expandKey(u);var h=l;return this.currentResult=x.decrypt(S.buffer,0,f),this.currentIV=Object(p.sliceUint8)(S,-16).buffer,h||null},r.webCryptoDecrypt=function(o,u,f){var s=this,l=this.subtle;return(this.key!==u||!this.fastAesKey)&&(this.key=u,this.fastAesKey=new m.default(l,u)),this.fastAesKey.expandKey().then(function(t){if(!l)return Promise.reject(new Error("web crypto not initialized"));var S=new M.default(l,f);return S.decrypt(o.buffer,t)}).catch(function(t){return s.onWebCryptoError(t,o,u,f)})},r.onWebCryptoError=function(o,u,f,s){return w.logger.warn("[decrypter.ts]: WebCrypto Error, disable WebCrypto API:",o),this.config.enableSoftwareAES=!0,this.logEnabled=!0,this.softwareDecrypt(u,f,s)},r.getValidChunk=function(o){var u=o,f=o.length-o.length%d;return f!==o.length&&(u=Object(p.sliceUint8)(o,0,f),this.remainderData=Object(p.sliceUint8)(o,f)),u},r.logOnce=function(o){if(!this.logEnabled)return;w.logger.log("[decrypter.ts]: "+o),this.logEnabled=!1},c}()},"./src/crypt/fast-aes-key.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return M});var M=function(){function m(w,b){this.subtle=void 0,this.key=void 0,this.subtle=w,this.key=b}var y=m.prototype;return y.expandKey=function(){return this.subtle.importKey("raw",this.key,{name:"AES-CBC"},!1,["encrypt","decrypt"])},m}()},"./src/demux/aacdemuxer.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/demux/base-audio-demuxer.ts"),m=C("./src/demux/adts.ts"),y=C("./src/utils/logger.ts"),w=C("./src/demux/id3.ts");function b(n,c){n.prototype=Object.create(c.prototype),n.prototype.constructor=n,p(n,c)}function p(n,c){return p=Object.setPrototypeOf||function(i,o){return i.__proto__=o,i},p(n,c)}var d=function(n){b(c,n);function c(i,o){var u;return u=n.call(this)||this,u.observer=void 0,u.config=void 0,u.observer=i,u.config=o,u}var r=c.prototype;return r.resetInitSegment=function(o,u,f){n.prototype.resetInitSegment.call(this,o,u,f),this._audioTrack={container:"audio/adts",type:"audio",id:2,pid:-1,sequenceNumber:0,isAAC:!0,samples:[],manifestCodec:o,duration:f,inputTimeScale:9e4,dropped:0}},c.probe=function(o){if(!o)return!1;for(var u=w.getID3Data(o,0)||[],f=u.length,s=o.length;f<s;f++)if(m.probe(o,f))return y.logger.log("ADTS sync word found !"),!0;return!1},r.canParse=function(o,u){return m.canParse(o,u)},r.appendFrame=function(o,u,f){m.initTrackConfig(o,this.observer,u,f,o.manifestCodec);var s=m.appendFrame(o,u,f,this.initPTS,this.frameIndex);if(s&&s.missing===0)return s},c}(M.default);d.minProbeByteLength=9,v.default=d},"./src/demux/adts.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"getAudioConfig",function(){return w}),C.d(v,"isHeaderPattern",function(){return b}),C.d(v,"getHeaderLength",function(){return p}),C.d(v,"getFullFrameLength",function(){return d}),C.d(v,"canGetFrameLength",function(){return n}),C.d(v,"isHeader",function(){return c}),C.d(v,"canParse",function(){return r}),C.d(v,"probe",function(){return i}),C.d(v,"initTrackConfig",function(){return o}),C.d(v,"getFrameDuration",function(){return u}),C.d(v,"parseFrameHeader",function(){return f}),C.d(v,"appendFrame",function(){return s});var M=C("./src/utils/logger.ts"),m=C("./src/errors.ts"),y=C("./src/events.ts");function w(l,t,S,x){var h,R,O,g,_=navigator.userAgent.toLowerCase(),E=x,T=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];h=((t[S+2]&192)>>>6)+1;var L=(t[S+2]&60)>>>2;if(L>T.length-1){l.trigger(y.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.FRAG_PARSING_ERROR,fatal:!0,reason:"invalid ADTS sampling index:"+L});return}return O=(t[S+2]&1)<<2,O|=(t[S+3]&192)>>>6,M.logger.log("manifest codec:"+x+", ADTS type:"+h+", samplingIndex:"+L),/firefox/i.test(_)?L>=6?(h=5,g=new Array(4),R=L-3):(h=2,g=new Array(2),R=L):_.indexOf("android")!==-1?(h=2,g=new Array(2),R=L):(h=5,g=new Array(4),x&&(x.indexOf("mp4a.40.29")!==-1||x.indexOf("mp4a.40.5")!==-1)||!x&&L>=6?R=L-3:((x&&x.indexOf("mp4a.40.2")!==-1&&(L>=6&&O===1||/vivaldi/i.test(_))||!x&&O===1)&&(h=2,g=new Array(2)),R=L)),g[0]=h<<3,g[0]|=(L&14)>>1,g[1]|=(L&1)<<7,g[1]|=O<<3,h===5&&(g[1]|=(R&14)>>1,g[2]=(R&1)<<7,g[2]|=2<<2,g[3]=0),{config:g,samplerate:T[L],channelCount:O,codec:"mp4a.40."+h,manifestCodec:E}}function b(l,t){return l[t]===255&&(l[t+1]&246)===240}function p(l,t){return l[t+1]&1?7:9}function d(l,t){return(l[t+3]&3)<<11|l[t+4]<<3|(l[t+5]&224)>>>5}function n(l,t){return t+5<l.length}function c(l,t){return t+1<l.length&&b(l,t)}function r(l,t){return n(l,t)&&b(l,t)&&d(l,t)<=l.length-t}function i(l,t){if(c(l,t)){var S=p(l,t);if(t+S>=l.length)return!1;var x=d(l,t);if(x<=S)return!1;var h=t+x;return h===l.length||c(l,h)}return!1}function o(l,t,S,x,h){if(!l.samplerate){var R=w(t,S,x,h);if(!R)return;l.config=R.config,l.samplerate=R.samplerate,l.channelCount=R.channelCount,l.codec=R.codec,l.manifestCodec=R.manifestCodec,M.logger.log("parsed codec:"+l.codec+", rate:"+R.samplerate+", channels:"+R.channelCount)}}function u(l){return 1024*9e4/l}function f(l,t,S,x,h){var R=p(l,t),O=d(l,t);if(O-=R,O>0){var g=S+x*h;return{headerLength:R,frameLength:O,stamp:g}}}function s(l,t,S,x,h){var R=u(l.samplerate),O=f(t,S,x,h,R);if(O){var g=O.frameLength,_=O.headerLength,E=O.stamp,T=_+g,L=Math.max(0,S+T-t.length),I;L?(I=new Uint8Array(T-_),I.set(t.subarray(S+_,t.length),0)):I=t.subarray(S+_,S+T);var P={unit:I,pts:E};return L||l.samples.push(P),{sample:P,length:T,missing:L}}}},"./src/demux/base-audio-demuxer.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"initPTSFn",function(){return d});var M=C("./src/polyfills/number.ts"),m=C("./src/demux/id3.ts"),y=C("./src/demux/dummy-demuxed-track.ts"),w=C("./src/utils/mp4-tools.ts"),b=C("./src/utils/typed-array.ts"),p=function(){function n(){this._audioTrack=void 0,this._id3Track=void 0,this.frameIndex=0,this.cachedData=null,this.initPTS=null}var c=n.prototype;return c.resetInitSegment=function(i,o,u){this._id3Track={type:"id3",id:3,pid:-1,inputTimeScale:9e4,sequenceNumber:0,samples:[],dropped:0}},c.resetTimeStamp=function(){},c.resetContiguity=function(){},c.canParse=function(i,o){return!1},c.appendFrame=function(i,o,u){},c.demux=function(i,o){this.cachedData&&(i=Object(w.appendUint8Array)(this.cachedData,i),this.cachedData=null);var u=m.getID3Data(i,0),f=u?u.length:0,s,l,t=this._audioTrack,S=this._id3Track,x=u?m.getTimeStamp(u):void 0,h=i.length;for((this.frameIndex===0||this.initPTS===null)&&(this.initPTS=d(x,o)),u&&u.length>0&&S.samples.push({pts:this.initPTS,dts:this.initPTS,data:u}),l=this.initPTS;f<h;){if(this.canParse(i,f)){var R=this.appendFrame(t,i,f);R?(this.frameIndex++,l=R.sample.pts,f+=R.length,s=f):f=h}else m.canParse(i,f)?(u=m.getID3Data(i,f),S.samples.push({pts:l,dts:l,data:u}),f+=u.length,s=f):f++;if(f===h&&s!==h){var O=Object(b.sliceUint8)(i,s);this.cachedData?this.cachedData=Object(w.appendUint8Array)(this.cachedData,O):this.cachedData=O}}return{audioTrack:t,avcTrack:Object(y.dummyTrack)(),id3Track:S,textTrack:Object(y.dummyTrack)()}},c.demuxSampleAes=function(i,o,u){return Promise.reject(new Error("["+this+"] This demuxer does not support Sample-AES decryption"))},c.flush=function(i){var o=this.cachedData;return o&&(this.cachedData=null,this.demux(o,0)),this.frameIndex=0,{audioTrack:this._audioTrack,avcTrack:Object(y.dummyTrack)(),id3Track:this._id3Track,textTrack:Object(y.dummyTrack)()}},c.destroy=function(){},n}(),d=function(c,r){return Object(M.isFiniteNumber)(c)?c*90:r*9e4};v.default=p},"./src/demux/chunk-cache.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return M});var M=function(){function y(){this.chunks=[],this.dataLength=0}var w=y.prototype;return w.push=function(p){this.chunks.push(p),this.dataLength+=p.length},w.flush=function(){var p=this.chunks,d=this.dataLength,n;if(p.length)p.length===1?n=p[0]:n=m(p,d);else return new Uint8Array(0);return this.reset(),n},w.reset=function(){this.chunks.length=0,this.dataLength=0},y}();function m(y,w){for(var b=new Uint8Array(w),p=0,d=0;d<y.length;d++){var n=y[d];b.set(n,p),p+=n.length}return b}},"./src/demux/dummy-demuxed-track.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"dummyTrack",function(){return M});function M(){return{type:"",id:-1,pid:-1,inputTimeScale:9e4,sequenceNumber:-1,samples:[],dropped:0}}},"./src/demux/exp-golomb.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/utils/logger.ts"),m=function(){function y(b){this.data=void 0,this.bytesAvailable=void 0,this.word=void 0,this.bitsAvailable=void 0,this.data=b,this.bytesAvailable=b.byteLength,this.word=0,this.bitsAvailable=0}var w=y.prototype;return w.loadWord=function(){var p=this.data,d=this.bytesAvailable,n=p.byteLength-d,c=new Uint8Array(4),r=Math.min(4,d);if(r===0)throw new Error("no bytes available");c.set(p.subarray(n,n+r)),this.word=new DataView(c.buffer).getUint32(0),this.bitsAvailable=r*8,this.bytesAvailable-=r},w.skipBits=function(p){var d;this.bitsAvailable>p?(this.word<<=p,this.bitsAvailable-=p):(p-=this.bitsAvailable,d=p>>3,p-=d>>3,this.bytesAvailable-=d,this.loadWord(),this.word<<=p,this.bitsAvailable-=p)},w.readBits=function(p){var d=Math.min(this.bitsAvailable,p),n=this.word>>>32-d;return p>32&&M.logger.error("Cannot read more than 32 bits at a time"),this.bitsAvailable-=d,this.bitsAvailable>0?this.word<<=d:this.bytesAvailable>0&&this.loadWord(),d=p-d,d>0&&this.bitsAvailable?n<<d|this.readBits(d):n},w.skipLZ=function(){var p;for(p=0;p<this.bitsAvailable;++p)if((this.word&2147483648>>>p)!==0)return this.word<<=p,this.bitsAvailable-=p,p;return this.loadWord(),p+this.skipLZ()},w.skipUEG=function(){this.skipBits(1+this.skipLZ())},w.skipEG=function(){this.skipBits(1+this.skipLZ())},w.readUEG=function(){var p=this.skipLZ();return this.readBits(p+1)-1},w.readEG=function(){var p=this.readUEG();return 1&p?1+p>>>1:-1*(p>>>1)},w.readBoolean=function(){return this.readBits(1)===1},w.readUByte=function(){return this.readBits(8)},w.readUShort=function(){return this.readBits(16)},w.readUInt=function(){return this.readBits(32)},w.skipScalingList=function(p){for(var d=8,n=8,c,r=0;r<p;r++)n!==0&&(c=this.readEG(),n=(d+c+256)%256),d=n===0?d:n},w.readSPS=function(){var p=0,d=0,n=0,c=0,r,i,o,u=this.readUByte.bind(this),f=this.readBits.bind(this),s=this.readUEG.bind(this),l=this.readBoolean.bind(this),t=this.skipBits.bind(this),S=this.skipEG.bind(this),x=this.skipUEG.bind(this),h=this.skipScalingList.bind(this);u();var R=u();if(f(5),t(3),u(),x(),R===100||R===110||R===122||R===244||R===44||R===83||R===86||R===118||R===128){var O=s();if(O===3&&t(1),x(),x(),t(1),l())for(i=O!==3?8:12,o=0;o<i;o++)l()&&(o<6?h(16):h(64))}x();var g=s();if(g===0)s();else if(g===1)for(t(1),S(),S(),r=s(),o=0;o<r;o++)S();x(),t(1);var _=s(),E=s(),T=f(1);T===0&&t(1),t(1),l()&&(p=s(),d=s(),n=s(),c=s());var L=[1,1];if(l()&&l()){var I=u();switch(I){case 1:L=[1,1];break;case 2:L=[12,11];break;case 3:L=[10,11];break;case 4:L=[16,11];break;case 5:L=[40,33];break;case 6:L=[24,11];break;case 7:L=[20,11];break;case 8:L=[32,11];break;case 9:L=[80,33];break;case 10:L=[18,11];break;case 11:L=[15,11];break;case 12:L=[64,33];break;case 13:L=[160,99];break;case 14:L=[4,3];break;case 15:L=[3,2];break;case 16:L=[2,1];break;case 255:{L=[u()<<8|u(),u()<<8|u()];break}}}return{width:Math.ceil((_+1)*16-p*2-d*2),height:(2-T)*(E+1)*16-(T?2:4)*(n+c),pixelRatio:L}},w.readSliceType=function(){return this.readUByte(),this.readUEG(),this.readUEG()},y}();v.default=m},"./src/demux/id3.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"isHeader",function(){return M}),C.d(v,"isFooter",function(){return m}),C.d(v,"getID3Data",function(){return y}),C.d(v,"canParse",function(){return b}),C.d(v,"getTimeStamp",function(){return p}),C.d(v,"isTimeStampFrame",function(){return d}),C.d(v,"getID3Frames",function(){return c}),C.d(v,"decodeFrame",function(){return r}),C.d(v,"utf8ArrayToStr",function(){return s}),C.d(v,"testables",function(){return l});var M=function(h,R){return R+10<=h.length&&(h[R]===73&&h[R+1]===68&&h[R+2]===51&&(h[R+3]<255&&h[R+4]<255&&(h[R+6]<128&&h[R+7]<128&&h[R+8]<128&&h[R+9]<128)))},m=function(h,R){return R+10<=h.length&&(h[R]===51&&h[R+1]===68&&h[R+2]===73&&(h[R+3]<255&&h[R+4]<255&&(h[R+6]<128&&h[R+7]<128&&h[R+8]<128&&h[R+9]<128)))},y=function(h,R){for(var O=R,g=0;M(h,R);){g+=10;var _=w(h,R+6);g+=_,m(h,R+10)&&(g+=10),R+=g}return g>0?h.subarray(O,O+g):void 0},w=function(h,R){var O=0;return O=(h[R]&127)<<21,O|=(h[R+1]&127)<<14,O|=(h[R+2]&127)<<7,O|=h[R+3]&127,O},b=function(h,R){return M(h,R)&&w(h,R+6)+10<=h.length-R},p=function(h){for(var R=c(h),O=0;O<R.length;O++){var g=R[O];if(d(g))return f(g)}return},d=function(h){return h&&h.key==="PRIV"&&h.info==="com.apple.streaming.transportStreamTimestamp"},n=function(h){var R=String.fromCharCode(h[0],h[1],h[2],h[3]),O=w(h,4),g=10;return{type:R,size:O,data:h.subarray(g,g+O)}},c=function(h){for(var R=0,O=[];M(h,R);){var g=w(h,R+6);R+=10;for(var _=R+g;R+8<_;){var E=n(h.subarray(R)),T=r(E);T&&O.push(T),R+=E.size+10}m(h,R)&&(R+=10)}return O},r=function(h){return h.type==="PRIV"?i(h):h.type[0]==="W"?u(h):o(h)},i=function(h){if(h.size<2)return;var R=s(h.data,!0),O=new Uint8Array(h.data.subarray(R.length+1));return{key:h.type,info:R,data:O.buffer}},o=function(h){if(h.size<2)return;if(h.type==="TXXX"){var R=1,O=s(h.data.subarray(R),!0);R+=O.length+1;var g=s(h.data.subarray(R));return{key:h.type,info:O,data:g}}var _=s(h.data.subarray(1));return{key:h.type,data:_}},u=function(h){if(h.type==="WXXX"){if(h.size<2)return;var R=1,O=s(h.data.subarray(R),!0);R+=O.length+1;var g=s(h.data.subarray(R));return{key:h.type,info:O,data:g}}var _=s(h.data);return{key:h.type,data:_}},f=function(h){if(h.data.byteLength===8){var R=new Uint8Array(h.data),O=R[3]&1,g=(R[4]<<23)+(R[5]<<15)+(R[6]<<7)+R[7];return g/=45,O&&(g+=4772185884e-2),Math.round(g)}return},s=function(h,R){R===void 0&&(R=!1);var O=S();if(O){var g=O.decode(h);if(R){var _=g.indexOf("\0");return _!==-1?g.substring(0,_):g}return g.replace(/\0/g,"")}for(var E=h.length,T,L,I,P="",G=0;G<E;){if(T=h[G++],T===0&&R)return P;if(T===0||T===3)continue;switch(T>>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:P+=String.fromCharCode(T);break;case 12:case 13:L=h[G++],P+=String.fromCharCode((T&31)<<6|L&63);break;case 14:L=h[G++],I=h[G++],P+=String.fromCharCode((T&15)<<12|(L&63)<<6|(I&63)<<0);break;default:}}return P},l={decodeTextFrame:o},t;function S(){return!t&&typeof self.TextDecoder!="undefined"&&(t=new self.TextDecoder("utf-8")),t}},"./src/demux/mp3demuxer.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/demux/base-audio-demuxer.ts"),m=C("./src/demux/id3.ts"),y=C("./src/utils/logger.ts"),w=C("./src/demux/mpegaudio.ts");function b(n,c){n.prototype=Object.create(c.prototype),n.prototype.constructor=n,p(n,c)}function p(n,c){return p=Object.setPrototypeOf||function(i,o){return i.__proto__=o,i},p(n,c)}var d=function(n){b(c,n);function c(){return n.apply(this,arguments)||this}var r=c.prototype;return r.resetInitSegment=function(o,u,f){n.prototype.resetInitSegment.call(this,o,u,f),this._audioTrack={container:"audio/mpeg",type:"audio",id:2,pid:-1,sequenceNumber:0,isAAC:!1,samples:[],manifestCodec:o,duration:f,inputTimeScale:9e4,dropped:0}},c.probe=function(o){if(!o)return!1;for(var u=m.getID3Data(o,0)||[],f=u.length,s=o.length;f<s;f++)if(w.probe(o,f))return y.logger.log("MPEG Audio sync word found !"),!0;return!1},r.canParse=function(o,u){return w.canParse(o,u)},r.appendFrame=function(o,u,f){return this.initPTS===null?void 0:w.appendFrame(o,u,f,this.initPTS,this.frameIndex)},c}(M.default);d.minProbeByteLength=4,v.default=d},"./src/demux/mp4demuxer.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/utils/mp4-tools.ts"),m=C("./src/demux/dummy-demuxed-track.ts"),y=function(){function w(p,d){this.remainderData=null,this.config=void 0,this.config=d}var b=w.prototype;return b.resetTimeStamp=function(){},b.resetInitSegment=function(){},b.resetContiguity=function(){},w.probe=function(d){return Object(M.findBox)({data:d,start:0,end:Math.min(d.length,16384)},["moof"]).length>0},b.demux=function(d){var n=d,c=Object(m.dummyTrack)();if(this.config.progressive){this.remainderData&&(n=Object(M.appendUint8Array)(this.remainderData,d));var r=Object(M.segmentValidRange)(n);this.remainderData=r.remainder,c.samples=r.valid||new Uint8Array}else c.samples=n;return{audioTrack:Object(m.dummyTrack)(),avcTrack:c,id3Track:Object(m.dummyTrack)(),textTrack:Object(m.dummyTrack)()}},b.flush=function(){var d=Object(m.dummyTrack)();return d.samples=this.remainderData||new Uint8Array,this.remainderData=null,{audioTrack:Object(m.dummyTrack)(),avcTrack:d,id3Track:Object(m.dummyTrack)(),textTrack:Object(m.dummyTrack)()}},b.demuxSampleAes=function(d,n,c){return Promise.reject(new Error("The MP4 demuxer does not support SAMPLE-AES decryption"))},b.destroy=function(){},w}();y.minProbeByteLength=1024,v.default=y},"./src/demux/mpegaudio.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"appendFrame",function(){return p}),C.d(v,"parseHeader",function(){return d}),C.d(v,"isHeaderPattern",function(){return n}),C.d(v,"isHeader",function(){return c}),C.d(v,"canParse",function(){return r}),C.d(v,"probe",function(){return i});var M=null,m=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],y=[44100,48e3,32e3,22050,24e3,16e3,11025,12e3,8e3],w=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],b=[0,1,1,4];function p(o,u,f,s,l){if(f+24>u.length)return;var t=d(u,f);if(t&&f+t.frameLength<=u.length){var S=t.samplesPerFrame*9e4/t.sampleRate,x=s+l*S,h={unit:u.subarray(f,f+t.frameLength),pts:x,dts:x};return o.config=[],o.channelCount=t.channelCount,o.samplerate=t.sampleRate,o.samples.push(h),{sample:h,length:t.frameLength,missing:0}}}function d(o,u){var f=o[u+1]>>3&3,s=o[u+1]>>1&3,l=o[u+2]>>4&15,t=o[u+2]>>2&3;if(f!==1&&l!==0&&l!==15&&t!==3){var S=o[u+2]>>1&1,x=o[u+3]>>6,h=f===3?3-s:s===3?3:4,R=m[h*14+l-1]*1e3,O=f===3?0:f===2?1:2,g=y[O*3+t],_=x===3?1:2,E=w[f][s],T=b[s],L=E*8*T,I=Math.floor(E*R/g+S)*T;if(M===null){var P=navigator.userAgent||"",G=P.match(/Chrome\/(\d+)/i);M=G?parseInt(G[1]):0}var W=!!M&&M<=87;return W&&s===2&&R>=224e3&&x===0&&(o[u+3]=o[u+3]|128),{sampleRate:g,channelCount:_,frameLength:I,samplesPerFrame:L}}}function n(o,u){return o[u]===255&&(o[u+1]&224)===224&&(o[u+1]&6)!==0}function c(o,u){return u+1<o.length&&n(o,u)}function r(o,u){var f=4;return n(o,u)&&f<=o.length-u}function i(o,u){if(u+1<o.length&&n(o,u)){var f=4,s=d(o,u),l=f;s!=null&&s.frameLength&&(l=s.frameLength);var t=u+l;return t===o.length||c(o,t)}return!1}},"./src/demux/sample-aes.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/crypt/decrypter.ts"),m=C("./src/demux/tsdemuxer.ts"),y=function(){function w(p,d,n){this.keyData=void 0,this.decrypter=void 0,this.keyData=n,this.decrypter=new M.default(p,d,{removePKCS7Padding:!1})}var b=w.prototype;return b.decryptBuffer=function(d,n){this.decrypter.decrypt(d,this.keyData.key.buffer,this.keyData.iv.buffer,n)},b.decryptAacSample=function(d,n,c,r){var i=d[n].unit,o=i.subarray(16,i.length-i.length%16),u=o.buffer.slice(o.byteOffset,o.byteOffset+o.length),f=this;this.decryptBuffer(u,function(s){var l=new Uint8Array(s);i.set(l,16),r||f.decryptAacSamples(d,n+1,c)})},b.decryptAacSamples=function(d,n,c){for(;;n++){if(n>=d.length){c();return}if(d[n].unit.length<32)continue;var r=this.decrypter.isSync();if(this.decryptAacSample(d,n,c,r),!r)return}},b.getAvcEncryptedData=function(d){for(var n=Math.floor((d.length-48)/160)*16+16,c=new Int8Array(n),r=0,i=32;i<=d.length-16;i+=160,r+=16)c.set(d.subarray(i,i+16),r);return c},b.getAvcDecryptedUnit=function(d,n){for(var c=new Uint8Array(n),r=0,i=32;i<=d.length-16;i+=160,r+=16)d.set(c.subarray(r,r+16),i);return d},b.decryptAvcSample=function(d,n,c,r,i,o){var u=Object(m.discardEPB)(i.data),f=this.getAvcEncryptedData(u),s=this;this.decryptBuffer(f.buffer,function(l){i.data=s.getAvcDecryptedUnit(u,l),o||s.decryptAvcSamples(d,n,c+1,r)})},b.decryptAvcSamples=function(d,n,c,r){if(d instanceof Uint8Array)throw new Error("Cannot decrypt samples of type Uint8Array");for(;;n++,c=0){if(n>=d.length){r();return}for(var i=d[n].units;!(c>=i.length);c++){var o=i[c];if(o.data.length<=48||o.type!==1&&o.type!==5)continue;var u=this.decrypter.isSync();if(this.decryptAvcSample(d,n,c,r,o,u),!u)return}}},w}();v.default=y},"./src/demux/transmuxer-interface.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return i});var M=C("./node_modules/webworkify-webpack/index.js"),m=C.n(M),y=C("./src/events.ts"),w=C("./src/demux/transmuxer.ts"),b=C("./src/utils/logger.ts"),p=C("./src/errors.ts"),d=C("./src/utils/mediasource-helper.ts"),n=C("./node_modules/eventemitter3/index.js"),c=C.n(n),r=Object(d.getMediaSource)()||{isTypeSupported:function(){return!1}},i=function(){function o(f,s,l,t){var S=this;this.hls=void 0,this.id=void 0,this.observer=void 0,this.frag=null,this.part=null,this.worker=void 0,this.onwmsg=void 0,this.transmuxer=null,this.onTransmuxComplete=void 0,this.onFlush=void 0,this.hls=f,this.id=s,this.onTransmuxComplete=l,this.onFlush=t;var x=f.config,h=function(E,T){T=T||{},T.frag=S.frag,T.id=S.id,f.trigger(E,T)};this.observer=new n.EventEmitter,this.observer.on(y.Events.FRAG_DECRYPTED,h),this.observer.on(y.Events.ERROR,h);var R={mp4:r.isTypeSupported("video/mp4"),mpeg:r.isTypeSupported("audio/mpeg"),mp3:r.isTypeSupported('audio/mp4; codecs="mp3"')},O=navigator.vendor;if(x.enableWorker&&typeof Worker!="undefined"){b.logger.log("demuxing in webworker");var g;try{g=this.worker=M("./src/demux/transmuxer-worker.ts"),this.onwmsg=this.onWorkerMessage.bind(this),g.addEventListener("message",this.onwmsg),g.onerror=function(_){f.trigger(y.Events.ERROR,{type:p.ErrorTypes.OTHER_ERROR,details:p.ErrorDetails.INTERNAL_EXCEPTION,fatal:!0,event:"demuxerWorker",error:new Error(_.message+" ("+_.filename+":"+_.lineno+")")})},g.postMessage({cmd:"init",typeSupported:R,vendor:O,id:s,config:JSON.stringify(x)})}catch(_){b.logger.warn("Error in worker:",_),b.logger.error("Error while initializing DemuxerWorker, fallback to inline"),g&&self.URL.revokeObjectURL(g.objectURL),this.transmuxer=new w.default(this.observer,R,x,O,s),this.worker=null}}else this.transmuxer=new w.default(this.observer,R,x,O,s)}var u=o.prototype;return u.destroy=function(){var s=this.worker;if(s)s.removeEventListener("message",this.onwmsg),s.terminate(),this.worker=null;else{var l=this.transmuxer;l&&(l.destroy(),this.transmuxer=null)}var t=this.observer;t&&t.removeAllListeners(),this.observer=null},u.push=function(s,l,t,S,x,h,R,O,g,_){var E=this;g.transmuxing.start=self.performance.now();var T=this.transmuxer,L=this.worker,I=h?h.start:x.start,P=x.decryptdata,G=this.frag,W=!(G&&x.cc===G.cc),H=!(G&&g.level===G.level),z=G?g.sn-G.sn:-1,B=this.part?g.part-this.part.index:1,k=!H&&(z===1||z===0&&B===1),K=self.performance.now();(H||z||x.stats.parsing.start===0)&&(x.stats.parsing.start=K),h&&(B||!k)&&(h.stats.parsing.start=K);var Y=new w.TransmuxState(W,k,O,H,I);if(!k||W){b.logger.log("[transmuxer-interface, "+x.type+"]: Starting new transmux session for sn: "+g.sn+" p: "+g.part+" level: "+g.level+" id: "+g.id+`
discontinuity: `+W+`
trackSwitch: `+H+`
contiguous: `+k+`
accurateTimeOffset: `+O+`
timeOffset: `+I);var ne=new w.TransmuxConfig(t,S,l,R,_);this.configureTransmuxer(ne)}if(this.frag=x,this.part=h,L)L.postMessage({cmd:"demux",data:s,decryptdata:P,chunkMeta:g,state:Y},s instanceof ArrayBuffer?[s]:[]);else if(T){var oe=T.push(s,P,g,Y);Object(w.isPromise)(oe)?oe.then(function(_e){E.handleTransmuxComplete(_e)}):this.handleTransmuxComplete(oe)}},u.flush=function(s){var l=this;s.transmuxing.start=self.performance.now();var t=this.transmuxer,S=this.worker;if(S)S.postMessage({cmd:"flush",chunkMeta:s});else if(t){var x=t.flush(s);Object(w.isPromise)(x)?x.then(function(h){l.handleFlushResult(h,s)}):this.handleFlushResult(x,s)}},u.handleFlushResult=function(s,l){var t=this;s.forEach(function(S){t.handleTransmuxComplete(S)}),this.onFlush(l)},u.onWorkerMessage=function(s){var l=s.data,t=this.hls;switch(l.event){case"init":{self.URL.revokeObjectURL(this.worker.objectURL);break}case"transmuxComplete":{this.handleTransmuxComplete(l.data);break}case"flush":{this.onFlush(l.data);break}default:{l.data=l.data||{},l.data.frag=this.frag,l.data.id=this.id,t.trigger(l.event,l.data);break}}},u.configureTransmuxer=function(s){var l=this.worker,t=this.transmuxer;l?l.postMessage({cmd:"configure",config:s}):t&&t.configure(s)},u.handleTransmuxComplete=function(s){s.chunkMeta.transmuxing.end=self.performance.now(),this.onTransmuxComplete(s)},o}()},"./src/demux/transmuxer-worker.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return p});var M=C("./src/demux/transmuxer.ts"),m=C("./src/events.ts"),y=C("./src/utils/logger.ts"),w=C("./node_modules/eventemitter3/index.js"),b=C.n(w);function p(i){var o=new w.EventEmitter,u=function(s,l){i.postMessage({event:s,data:l})};o.on(m.Events.FRAG_DECRYPTED,u),o.on(m.Events.ERROR,u),i.addEventListener("message",function(f){var s=f.data;switch(s.cmd){case"init":{var l=JSON.parse(s.config);i.transmuxer=new M.default(o,s.typeSupported,l,s.vendor,s.id),Object(y.enableLogs)(l.debug),u("init",null);break}case"configure":{i.transmuxer.configure(s.config);break}case"demux":{var t=i.transmuxer.push(s.data,s.decryptdata,s.chunkMeta,s.state);Object(M.isPromise)(t)?t.then(function(h){d(i,h)}):d(i,t);break}case"flush":{var S=s.chunkMeta,x=i.transmuxer.flush(S);Object(M.isPromise)(x)?x.then(function(h){c(i,h,S)}):c(i,x,S);break}default:break}})}function d(i,o){if(r(o.remuxResult))return;var u=[],f=o.remuxResult,s=f.audio,l=f.video;s&&n(u,s),l&&n(u,l),i.postMessage({event:"transmuxComplete",data:o},u)}function n(i,o){o.data1&&i.push(o.data1.buffer),o.data2&&i.push(o.data2.buffer)}function c(i,o,u){o.forEach(function(f){d(i,f)}),i.postMessage({event:"flush",data:u})}function r(i){return!i.audio&&!i.video&&!i.text&&!i.id3&&!i.initSegment}},"./src/demux/transmuxer.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return l}),C.d(v,"isPromise",function(){return x}),C.d(v,"TransmuxConfig",function(){return h}),C.d(v,"TransmuxState",function(){return R});var M=C("./src/events.ts"),m=C("./src/errors.ts"),y=C("./src/crypt/decrypter.ts"),w=C("./src/demux/aacdemuxer.ts"),b=C("./src/demux/mp4demuxer.ts"),p=C("./src/demux/tsdemuxer.ts"),d=C("./src/demux/mp3demuxer.ts"),n=C("./src/remux/mp4-remuxer.ts"),c=C("./src/remux/passthrough-remuxer.ts"),r=C("./src/demux/chunk-cache.ts"),i=C("./src/utils/mp4-tools.ts"),o=C("./src/utils/logger.ts"),u;try{u=self.performance.now.bind(self.performance)}catch(O){o.logger.debug("Unable to use Performance API on this environment"),u=self.Date.now}var f=[{demux:p.default,remux:n.default},{demux:b.default,remux:c.default},{demux:w.default,remux:n.default},{demux:d.default,remux:n.default}],s=1024;f.forEach(function(O){var g=O.demux;s=Math.max(s,g.minProbeByteLength)});var l=function(){function O(_,E,T,L,I){this.observer=void 0,this.typeSupported=void 0,this.config=void 0,this.vendor=void 0,this.id=void 0,this.demuxer=void 0,this.remuxer=void 0,this.decrypter=void 0,this.probe=void 0,this.decryptionPromise=null,this.transmuxConfig=void 0,this.currentTransmuxState=void 0,this.cache=new r.default,this.observer=_,this.typeSupported=E,this.config=T,this.vendor=L,this.id=I}var g=O.prototype;return g.configure=function(E){this.transmuxConfig=E,this.decrypter&&this.decrypter.reset()},g.push=function(E,T,L,I){var P=this,G=L.transmuxing;G.executeStart=u();var W=new Uint8Array(E),H=this.cache,z=this.config,B=this.currentTransmuxState,k=this.transmuxConfig;I&&(this.currentTransmuxState=I);var K=t(W,T);if(K&&K.method==="AES-128"){var Y=this.getDecrypter();if(z.enableSoftwareAES){var ne=Y.softwareDecrypt(W,K.key.buffer,K.iv.buffer);if(!ne)return G.executeEnd=u(),S(L);W=new Uint8Array(ne)}else return this.decryptionPromise=Y.webCryptoDecrypt(W,K.key.buffer,K.iv.buffer).then(function(J){var X=P.push(J,null,L);return P.decryptionPromise=null,X}),this.decryptionPromise}var oe=I||B,_e=oe.contiguous,xe=oe.discontinuity,le=oe.trackSwitch,me=oe.accurateTimeOffset,de=oe.timeOffset,ae=k.audioCodec,ie=k.videoCodec,q=k.defaultInitPts,ue=k.duration,Z=k.initSegmentData;if((xe||le)&&this.resetInitSegment(Z,ae,ie,ue),xe&&this.resetInitialTimestamp(q),_e||this.resetContiguity(),this.needsProbing(W,xe,le)){if(H.dataLength){var ee=H.flush();W=Object(i.appendUint8Array)(ee,W)}this.configureTransmuxer(W,k)}var Ee=this.transmux(W,K,de,me,L),te=this.currentTransmuxState;return te.contiguous=!0,te.discontinuity=!1,te.trackSwitch=!1,G.executeEnd=u(),Ee},g.flush=function(E){var T=this,L=E.transmuxing;L.executeStart=u();var I=this.decrypter,P=this.cache,G=this.currentTransmuxState,W=this.decryptionPromise;if(W)return W.then(function(){return T.flush(E)});var H=[],z=G.timeOffset;if(I){var B=I.flush();B&&H.push(this.push(B,null,E))}var k=P.dataLength;P.reset();var K=this.demuxer,Y=this.remuxer;if(!K||!Y)return k>=s&&this.observer.emit(M.Events.ERROR,M.Events.ERROR,{type:m.ErrorTypes.MEDIA_ERROR,details:m.ErrorDetails.FRAG_PARSING_ERROR,fatal:!0,reason:"no demux matching with content found"}),L.executeEnd=u(),[S(E)];var ne=K.flush(z);return x(ne)?ne.then(function(oe){return T.flushRemux(H,oe,E),H}):(this.flushRemux(H,ne,E),H)},g.flushRemux=function(E,T,L){var I=T.audioTrack,P=T.avcTrack,G=T.id3Track,W=T.textTrack,H=this.currentTransmuxState,z=H.accurateTimeOffset,B=H.timeOffset;o.logger.log("[transmuxer.ts]: Flushed fragment "+L.sn+(L.part>-1?" p: "+L.part:"")+" of level "+L.level);var k=this.remuxer.remux(I,P,G,W,B,z,!0,this.id);E.push({remuxResult:k,chunkMeta:L}),L.transmuxing.executeEnd=u()},g.resetInitialTimestamp=function(E){var T=this.demuxer,L=this.remuxer;if(!T||!L)return;T.resetTimeStamp(E),L.resetTimeStamp(E)},g.resetContiguity=function(){var E=this.demuxer,T=this.remuxer;if(!E||!T)return;E.resetContiguity(),T.resetNextTimestamp()},g.resetInitSegment=function(E,T,L,I){var P=this.demuxer,G=this.remuxer;if(!P||!G)return;P.resetInitSegment(T,L,I),G.resetInitSegment(E,T,L)},g.destroy=function(){this.demuxer&&(this.demuxer.destroy(),this.demuxer=void 0),this.remuxer&&(this.remuxer.destroy(),this.remuxer=void 0)},g.transmux=function(E,T,L,I,P){var G;return T&&T.method==="SAMPLE-AES"?G=this.transmuxSampleAes(E,T,L,I,P):G=this.transmuxUnencrypted(E,L,I,P),G},g.transmuxUnencrypted=function(E,T,L,I){var P=this.demuxer.demux(E,T,!1,!this.config.progressive),G=P.audioTrack,W=P.avcTrack,H=P.id3Track,z=P.textTrack,B=this.remuxer.remux(G,W,H,z,T,L,!1,this.id);return{remuxResult:B,chunkMeta:I}},g.transmuxSampleAes=function(E,T,L,I,P){var G=this;return this.demuxer.demuxSampleAes(E,T,L).then(function(W){var H=G.remuxer.remux(W.audioTrack,W.avcTrack,W.id3Track,W.textTrack,L,I,!1,G.id);return{remuxResult:H,chunkMeta:P}})},g.configureTransmuxer=function(E,T){for(var L=this.config,I=this.observer,P=this.typeSupported,G=this.vendor,W=T.audioCodec,H=T.defaultInitPts,z=T.duration,B=T.initSegmentData,k=T.videoCodec,K,Y=0,ne=f.length;Y<ne;Y++)if(f[Y].demux.probe(E)){K=f[Y];break}K||(o.logger.warn("Failed to find demuxer by probing frag, treating as mp4 passthrough"),K={demux:b.default,remux:c.default});var oe=this.demuxer,_e=this.remuxer,xe=K.remux,le=K.demux;(!_e||!(_e instanceof xe))&&(this.remuxer=new xe(I,L,P,G)),(!oe||!(oe instanceof le))&&(this.demuxer=new le(I,L,P),this.probe=le.probe),this.resetInitSegment(B,W,k,z),this.resetInitialTimestamp(H)},g.needsProbing=function(E,T,L){return!this.demuxer||!this.remuxer||T||L},g.getDecrypter=function(){var E=this.decrypter;return E||(E=this.decrypter=new y.default(this.observer,this.config)),E},O}();function t(O,g){var _=null;return O.byteLength>0&&g!=null&&g.key!=null&&g.iv!==null&&g.method!=null&&(_=g),_}var S=function(g){return{remuxResult:{},chunkMeta:g}};function x(O){return"then"in O&&O.then instanceof Function}var h=function(g,_,E,T,L){this.audioCodec=void 0,this.videoCodec=void 0,this.initSegmentData=void 0,this.duration=void 0,this.defaultInitPts=void 0,this.audioCodec=g,this.videoCodec=_,this.initSegmentData=E,this.duration=T,this.defaultInitPts=L},R=function(g,_,E,T,L){this.discontinuity=void 0,this.contiguous=void 0,this.accurateTimeOffset=void 0,this.trackSwitch=void 0,this.timeOffset=void 0,this.discontinuity=g,this.contiguous=_,this.accurateTimeOffset=E,this.trackSwitch=T,this.timeOffset=L}},"./src/demux/tsdemuxer.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"discardEPB",function(){return S});var M=C("./src/demux/adts.ts"),m=C("./src/demux/mpegaudio.ts"),y=C("./src/demux/exp-golomb.ts"),w=C("./src/demux/id3.ts"),b=C("./src/demux/sample-aes.ts"),p=C("./src/events.ts"),d=C("./src/utils/mp4-tools.ts"),n=C("./src/utils/logger.ts"),c=C("./src/errors.ts"),r={video:1,audio:2,id3:3,text:4},i=function(){function x(R,O,g){this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.sampleAes=null,this.pmtParsed=!1,this.audioCodec=void 0,this.videoCodec=void 0,this._duration=0,this.aacLastPTS=null,this._initPTS=null,this._initDTS=null,this._pmtId=-1,this._avcTrack=void 0,this._audioTrack=void 0,this._id3Track=void 0,this._txtTrack=void 0,this.aacOverFlow=null,this.avcSample=null,this.remainderData=null,this.observer=R,this.config=O,this.typeSupported=g}x.probe=function(O){var g=x.syncOffset(O);return g<0?!1:(g&&n.logger.warn("MPEG2-TS detected but first sync word found @ offset "+g+", junk ahead ?"),!0)},x.syncOffset=function(O){for(var g=Math.min(1e3,O.length-3*188),_=0;_<g;){if(O[_]===71&&O[_+188]===71&&O[_+2*188]===71)return _;_++}return-1},x.createTrack=function(O,g){return{container:O==="video"||O==="audio"?"video/mp2t":void 0,type:O,id:r[O],pid:-1,inputTimeScale:9e4,sequenceNumber:0,samples:[],dropped:0,duration:O==="audio"?g:void 0}};var h=x.prototype;return h.resetInitSegment=function(O,g,_){this.pmtParsed=!1,this._pmtId=-1,this._avcTrack=x.createTrack("video",_),this._audioTrack=x.createTrack("audio",_),this._id3Track=x.createTrack("id3",_),this._txtTrack=x.createTrack("text",_),this._audioTrack.isAAC=!0,this.aacOverFlow=null,this.aacLastPTS=null,this.avcSample=null,this.audioCodec=O,this.videoCodec=g,this._duration=_},h.resetTimeStamp=function(){},h.resetContiguity=function(){var O=this._audioTrack,g=this._avcTrack,_=this._id3Track;O&&(O.pesData=null),g&&(g.pesData=null),_&&(_.pesData=null),this.aacOverFlow=null,this.aacLastPTS=null},h.demux=function(O,g,_,E){_===void 0&&(_=!1),E===void 0&&(E=!1),_||(this.sampleAes=null);var T,L=this._avcTrack,I=this._audioTrack,P=this._id3Track,G=L.pid,W=L.pesData,H=I.pid,z=P.pid,B=I.pesData,k=P.pesData,K=!1,Y=this.pmtParsed,ne=this._pmtId,oe=O.length;if(this.remainderData&&(O=Object(d.appendUint8Array)(this.remainderData,O),oe=O.length,this.remainderData=null),oe<188&&!E)return this.remainderData=O,{audioTrack:I,avcTrack:L,id3Track:P,textTrack:this._txtTrack};var _e=Math.max(0,x.syncOffset(O));oe-=(oe+_e)%188,oe<O.byteLength&&!E&&(this.remainderData=new Uint8Array(O.buffer,oe,O.buffer.byteLength-oe));for(var xe=_e;xe<oe;xe+=188)if(O[xe]===71){var le=!!(O[xe+1]&64),me=((O[xe+1]&31)<<8)+O[xe+2],de=(O[xe+3]&48)>>4,ae=void 0;if(de>1){if(ae=xe+5+O[xe+4],ae===xe+188)continue}else ae=xe+4;switch(me){case G:le&&(W&&(T=s(W))&&this.parseAVCPES(T,!1),W={data:[],size:0}),W&&(W.data.push(O.subarray(ae,xe+188)),W.size+=xe+188-ae);break;case H:le&&(B&&(T=s(B))&&(I.isAAC?this.parseAACPES(T):this.parseMPEGPES(T)),B={data:[],size:0}),B&&(B.data.push(O.subarray(ae,xe+188)),B.size+=xe+188-ae);break;case z:le&&(k&&(T=s(k))&&this.parseID3PES(T),k={data:[],size:0}),k&&(k.data.push(O.subarray(ae,xe+188)),k.size+=xe+188-ae);break;case 0:le&&(ae+=O[ae]+1),ne=this._pmtId=u(O,ae);break;case ne:{le&&(ae+=O[ae]+1);var ie=f(O,ae,this.typeSupported.mpeg===!0||this.typeSupported.mp3===!0,_);G=ie.avc,G>0&&(L.pid=G),H=ie.audio,H>0&&(I.pid=H,I.isAAC=ie.isAAC),z=ie.id3,z>0&&(P.pid=z),K&&!Y&&(n.logger.log("reparse from beginning"),K=!1,xe=_e-188),Y=this.pmtParsed=!0;break}case 17:case 8191:break;default:K=!0;break}}else this.observer.emit(p.Events.ERROR,p.Events.ERROR,{type:c.ErrorTypes.MEDIA_ERROR,details:c.ErrorDetails.FRAG_PARSING_ERROR,fatal:!1,reason:"TS packet did not start with 0x47"});L.pesData=W,I.pesData=B,P.pesData=k;var q={audioTrack:I,avcTrack:L,id3Track:P,textTrack:this._txtTrack};return E&&this.extractRemainingSamples(q),q},h.flush=function(){var O=this.remainderData;this.remainderData=null;var g;return O?g=this.demux(O,-1,!1,!0):g={audioTrack:this._audioTrack,avcTrack:this._avcTrack,textTrack:this._txtTrack,id3Track:this._id3Track},this.extractRemainingSamples(g),this.sampleAes?this.decrypt(g,this.sampleAes):g},h.extractRemainingSamples=function(O){var g=O.audioTrack,_=O.avcTrack,E=O.id3Track,T=_.pesData,L=g.pesData,I=E.pesData,P;T&&(P=s(T))?(this.parseAVCPES(P,!0),_.pesData=null):_.pesData=T,L&&(P=s(L))?(g.isAAC?this.parseAACPES(P):this.parseMPEGPES(P),g.pesData=null):(L!=null&&L.size&&n.logger.log("last AAC PES packet truncated,might overlap between fragments"),g.pesData=L),I&&(P=s(I))?(this.parseID3PES(P),E.pesData=null):E.pesData=I},h.demuxSampleAes=function(O,g,_){var E=this.demux(O,_,!0,!this.config.progressive),T=this.sampleAes=new b.default(this.observer,this.config,g);return this.decrypt(E,T)},h.decrypt=function(O,g){return new Promise(function(_){var E=O.audioTrack,T=O.avcTrack;E.samples&&E.isAAC?g.decryptAacSamples(E.samples,0,function(){T.samples?g.decryptAvcSamples(T.samples,0,0,function(){_(O)}):_(O)}):T.samples&&g.decryptAvcSamples(T.samples,0,0,function(){_(O)})})},h.destroy=function(){this._initPTS=this._initDTS=null,this._duration=0},h.parseAVCPES=function(O,g){var _=this,E=this._avcTrack,T=this.parseAVCNALu(O.data),L=!1,I=this.avcSample,P,G=!1;O.data=null,I&&T.length&&!E.audFound&&(l(I,E),I=this.avcSample=o(!1,O.pts,O.dts,"")),T.forEach(function(W){switch(W.type){case 1:{P=!0,I||(I=_.avcSample=o(!0,O.pts,O.dts,"")),L&&(I.debug+="NDR "),I.frame=!0;var H=W.data;if(G&&H.length>4){var z=new y.default(H).readSliceType();(z===2||z===4||z===7||z===9)&&(I.key=!0)}break}case 5:P=!0,I||(I=_.avcSample=o(!0,O.pts,O.dts,"")),L&&(I.debug+="IDR "),I.key=!0,I.frame=!0;break;case 6:{P=!0,L&&I&&(I.debug+="SEI ");var B=new y.default(S(W.data));B.readUByte();for(var k=0,K=0,Y=!1,ne=0;!Y&&B.bytesAvailable>1;){k=0;do ne=B.readUByte(),k+=ne;while(ne===255);K=0;do ne=B.readUByte(),K+=ne;while(ne===255);if(k===4&&B.bytesAvailable!==0){Y=!0;var oe=B.readUByte();if(oe===181){var _e=B.readUShort();if(_e===49){var xe=B.readUInt();if(xe===1195456820){var le=B.readUByte();if(le===3){for(var me=B.readUByte(),de=B.readUByte(),ae=31&me,ie=[me,de],q=0;q<ae;q++)ie.push(B.readUByte()),ie.push(B.readUByte()),ie.push(B.readUByte());t(_._txtTrack.samples,{type:3,pts:O.pts,bytes:ie})}}}}}else if(k===5&&B.bytesAvailable!==0){if(Y=!0,K>16){for(var ue=[],Z=0;Z<16;Z++)ue.push(B.readUByte().toString(16)),(Z===3||Z===5||Z===7||Z===9)&&ue.push("-");for(var ee=K-16,Ee=new Uint8Array(ee),te=0;te<ee;te++)Ee[te]=B.readUByte();t(_._txtTrack.samples,{pts:O.pts,payloadType:k,uuid:ue.join(""),userData:Object(w.utf8ArrayToStr)(Ee),userDataBytes:Ee})}}else if(K<B.bytesAvailable)for(var J=0;J<K;J++)B.readUByte()}break}case 7:if(P=!0,G=!0,L&&I&&(I.debug+="SPS "),!E.sps){var X=new y.default(W.data),$=X.readSPS();E.width=$.width,E.height=$.height,E.pixelRatio=$.pixelRatio,E.sps=[W.data],E.duration=_._duration;for(var ge=W.data.subarray(1,4),fe="avc1.",Te=0;Te<3;Te++){var ze=ge[Te].toString(16);ze.length<2&&(ze="0"+ze),fe+=ze}E.codec=fe}break;case 8:P=!0,L&&I&&(I.debug+="PPS "),E.pps||(E.pps=[W.data]);break;case 9:P=!1,E.audFound=!0,I&&l(I,E),I=_.avcSample=o(!1,O.pts,O.dts,L?"AUD ":"");break;case 12:P=!1;break;default:P=!1,I&&(I.debug+="unknown NAL "+W.type+" ");break}if(I&&P){var Xe=I.units;Xe.push(W)}}),g&&I&&(l(I,E),this.avcSample=null)},h.getLastNalUnit=function(){var O,g=this.avcSample,_;if(!g||g.units.length===0){var E=this._avcTrack.samples;g=E[E.length-1]}if((O=g)!==null&&O!==void 0&&O.units){var T=g.units;_=T[T.length-1]}return _},h.parseAVCNALu=function(O){var g=O.byteLength,_=this._avcTrack,E=_.naluState||0,T=E,L=[],I=0,P,G,W,H=-1,z=0;for(E===-1&&(H=0,z=O[0]&31,E=0,I=1);I<g;){if(P=O[I++],!E){E=P?0:1;continue}if(E===1){E=P?0:2;continue}if(!P)E=3;else if(P===1){if(H>=0){var B={data:O.subarray(H,I-E-1),type:z};L.push(B)}else{var k=this.getLastNalUnit();if(k&&(T&&I<=4-T&&(k.state&&(k.data=k.data.subarray(0,k.data.byteLength-T))),G=I-E-1,G>0)){var K=new Uint8Array(k.data.byteLength+G);K.set(k.data,0),K.set(O.subarray(0,G),k.data.byteLength),k.data=K,k.state=0}}I<g?(W=O[I]&31,H=I,z=W,E=0):E=-1}else E=0}if(H>=0&&E>=0){var Y={data:O.subarray(H,g),type:z,state:E};L.push(Y)}if(L.length===0){var ne=this.getLastNalUnit();if(ne){var oe=new Uint8Array(ne.data.byteLength+O.byteLength);oe.set(ne.data,0),oe.set(O,ne.data.byteLength),ne.data=oe}}return _.naluState=E,L},h.parseAACPES=function(O){var g=0,_=this._audioTrack,E=this.aacOverFlow,T=O.data;if(E){this.aacOverFlow=null;var L=E.sample.unit.byteLength,I=Math.min(E.missing,L),P=L-I;E.sample.unit.set(T.subarray(0,I),P),_.samples.push(E.sample),g=E.missing}var G,W;for(G=g,W=T.length;G<W-1&&!M.isHeader(T,G);G++);if(G!==g){var H,z;if(G<W-1?(H="AAC PES did not start with ADTS header,offset:"+G,z=!1):(H="no ADTS header found in AAC PES",z=!0),n.logger.warn("parsing error:"+H),this.observer.emit(p.Events.ERROR,p.Events.ERROR,{type:c.ErrorTypes.MEDIA_ERROR,details:c.ErrorDetails.FRAG_PARSING_ERROR,fatal:z,reason:H}),z)return}M.initTrackConfig(_,this.observer,T,G,this.audioCodec);var B;if(O.pts!==void 0)B=O.pts;else if(E){var k=M.getFrameDuration(_.samplerate);B=E.sample.pts+k}else{n.logger.warn("[tsdemuxer]: AAC PES unknown PTS");return}for(var K=0;G<W;)if(M.isHeader(T,G)){if(G+5<W){var Y=M.appendFrame(_,T,G,B,K);if(Y)if(Y.missing)this.aacOverFlow=Y;else{G+=Y.length,K++;continue}}break}else G++},h.parseMPEGPES=function(O){var g=O.data,_=g.length,E=0,T=0,L=O.pts;if(L===void 0){n.logger.warn("[tsdemuxer]: MPEG PES unknown PTS");return}for(;T<_;)if(m.isHeader(g,T)){var I=m.appendFrame(this._audioTrack,g,T,L,E);if(I)T+=I.length,E++;else break}else T++},h.parseID3PES=function(O){if(O.pts===void 0){n.logger.warn("[tsdemuxer]: ID3 PES unknown PTS");return}this._id3Track.samples.push(O)},x}();i.minProbeByteLength=188;function o(x,h,R,O){return{key:x,frame:!1,pts:h,dts:R,units:[],debug:O,length:0}}function u(x,h){return(x[h+10]&31)<<8|x[h+11]}function f(x,h,R,O){var g={audio:-1,avc:-1,id3:-1,isAAC:!0},_=(x[h+1]&15)<<8|x[h+2],E=h+3+_-4,T=(x[h+10]&15)<<8|x[h+11];for(h+=12+T;h<E;){var L=(x[h+1]&31)<<8|x[h+2];switch(x[h]){case 207:if(!O){n.logger.log("ADTS AAC with AES-128-CBC frame encryption found in unencrypted stream");break}case 15:g.audio===-1&&(g.audio=L);break;case 21:g.id3===-1&&(g.id3=L);break;case 219:if(!O){n.logger.log("H.264 with AES-128-CBC slice encryption found in unencrypted stream");break}case 27:g.avc===-1&&(g.avc=L);break;case 3:case 4:R?g.audio===-1&&(g.audio=L,g.isAAC=!1):n.logger.log("MPEG audio found, not supported in this browser");break;case 36:n.logger.warn("Unsupported HEVC stream type found");break;default:break}h+=((x[h+3]&15)<<8|x[h+4])+5}return g}function s(x){var h=0,R,O,g,_,E,T=x.data;if(!x||x.size===0)return null;for(;T[0].length<19&&T.length>1;){var L=new Uint8Array(T[0].length+T[1].length);L.set(T[0]),L.set(T[1],T[0].length),T[0]=L,T.splice(1,1)}R=T[0];var I=(R[0]<<16)+(R[1]<<8)+R[2];if(I===1){if(O=(R[4]<<8)+R[5],O&&O>x.size-6)return null;var P=R[7];P&192&&(_=(R[9]&14)*536870912+(R[10]&255)*4194304+(R[11]&254)*16384+(R[12]&255)*128+(R[13]&254)/2,P&64?(E=(R[14]&14)*536870912+(R[15]&255)*4194304+(R[16]&254)*16384+(R[17]&255)*128+(R[18]&254)/2,_-E>60*9e4&&(n.logger.warn(Math.round((_-E)/9e4)+"s delta between PTS and DTS, align them"),_=E)):E=_),g=R[8];var G=g+9;if(x.size<=G)return null;x.size-=G;for(var W=new Uint8Array(x.size),H=0,z=T.length;H<z;H++){R=T[H];var B=R.byteLength;if(G)if(G>B){G-=B;continue}else R=R.subarray(G),B-=G,G=0;W.set(R,h),h+=B}return O&&(O-=g+3),{data:W,pts:_,dts:E,len:O}}return null}function l(x,h){if(x.units.length&&x.frame){if(x.pts===void 0){var R=h.samples,O=R.length;if(O){var g=R[O-1];x.pts=g.pts,x.dts=g.dts}else{h.dropped++;return}}h.samples.push(x)}x.debug.length&&n.logger.log(x.pts+"/"+x.dts+":"+x.debug)}function t(x,h){var R=x.length;if(R>0){if(h.pts>=x[R-1].pts)x.push(h);else for(var O=R-1;O>=0;O--)if(h.pts<x[O].pts){x.splice(O,0,h);break}}else x.push(h)}function S(x){for(var h=x.byteLength,R=[],O=1;O<h-2;)x[O]===0&&x[O+1]===0&&x[O+2]===3?(R.push(O+2),O+=2):O++;if(R.length===0)return x;var g=h-R.length,_=new Uint8Array(g),E=0;for(O=0;O<g;E++,O++)E===R[0]&&(E++,R.shift()),_[O]=x[E];return _}v.default=i},"./src/errors.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"ErrorTypes",function(){return M}),C.d(v,"ErrorDetails",function(){return m});var M;(function(y){y.NETWORK_ERROR="networkError",y.MEDIA_ERROR="mediaError",y.KEY_SYSTEM_ERROR="keySystemError",y.MUX_ERROR="muxError",y.OTHER_ERROR="otherError"})(M||(M={}));var m;(function(y){y.KEY_SYSTEM_NO_KEYS="keySystemNoKeys",y.KEY_SYSTEM_NO_ACCESS="keySystemNoAccess",y.KEY_SYSTEM_NO_SESSION="keySystemNoSession",y.KEY_SYSTEM_LICENSE_REQUEST_FAILED="keySystemLicenseRequestFailed",y.KEY_SYSTEM_NO_INIT_DATA="keySystemNoInitData",y.MANIFEST_LOAD_ERROR="manifestLoadError",y.MANIFEST_LOAD_TIMEOUT="manifestLoadTimeOut",y.MANIFEST_PARSING_ERROR="manifestParsingError",y.MANIFEST_INCOMPATIBLE_CODECS_ERROR="manifestIncompatibleCodecsError",y.LEVEL_EMPTY_ERROR="levelEmptyError",y.LEVEL_LOAD_ERROR="levelLoadError",y.LEVEL_LOAD_TIMEOUT="levelLoadTimeOut",y.LEVEL_SWITCH_ERROR="levelSwitchError",y.AUDIO_TRACK_LOAD_ERROR="audioTrackLoadError",y.AUDIO_TRACK_LOAD_TIMEOUT="audioTrackLoadTimeOut",y.SUBTITLE_LOAD_ERROR="subtitleTrackLoadError",y.SUBTITLE_TRACK_LOAD_TIMEOUT="subtitleTrackLoadTimeOut",y.FRAG_LOAD_ERROR="fragLoadError",y.FRAG_LOAD_TIMEOUT="fragLoadTimeOut",y.FRAG_DECRYPT_ERROR="fragDecryptError",y.FRAG_PARSING_ERROR="fragParsingError",y.REMUX_ALLOC_ERROR="remuxAllocError",y.KEY_LOAD_ERROR="keyLoadError",y.KEY_LOAD_TIMEOUT="keyLoadTimeOut",y.BUFFER_ADD_CODEC_ERROR="bufferAddCodecError",y.BUFFER_INCOMPATIBLE_CODECS_ERROR="bufferIncompatibleCodecsError",y.BUFFER_APPEND_ERROR="bufferAppendError",y.BUFFER_APPENDING_ERROR="bufferAppendingError",y.BUFFER_STALLED_ERROR="bufferStalledError",y.BUFFER_FULL_ERROR="bufferFullError",y.BUFFER_SEEK_OVER_HOLE="bufferSeekOverHole",y.BUFFER_NUDGE_ON_STALL="bufferNudgeOnStall",y.INTERNAL_EXCEPTION="internalException",y.INTERNAL_ABORTED="aborted",y.UNKNOWN="unknown"})(m||(m={}))},"./src/events.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"Events",function(){return M});var M;(function(m){m.MEDIA_ATTACHING="hlsMediaAttaching",m.MEDIA_ATTACHED="hlsMediaAttached",m.MEDIA_DETACHING="hlsMediaDetaching",m.MEDIA_DETACHED="hlsMediaDetached",m.BUFFER_RESET="hlsBufferReset",m.BUFFER_CODECS="hlsBufferCodecs",m.BUFFER_CREATED="hlsBufferCreated",m.BUFFER_APPENDING="hlsBufferAppending",m.BUFFER_APPENDED="hlsBufferAppended",m.BUFFER_EOS="hlsBufferEos",m.BUFFER_FLUSHING="hlsBufferFlushing",m.BUFFER_FLUSHED="hlsBufferFlushed",m.MANIFEST_LOADING="hlsManifestLoading",m.MANIFEST_LOADED="hlsManifestLoaded",m.MANIFEST_PARSED="hlsManifestParsed",m.LEVEL_SWITCHING="hlsLevelSwitching",m.LEVEL_SWITCHED="hlsLevelSwitched",m.LEVEL_LOADING="hlsLevelLoading",m.LEVEL_LOADED="hlsLevelLoaded",m.LEVEL_UPDATED="hlsLevelUpdated",m.LEVEL_PTS_UPDATED="hlsLevelPtsUpdated",m.LEVELS_UPDATED="hlsLevelsUpdated",m.AUDIO_TRACKS_UPDATED="hlsAudioTracksUpdated",m.AUDIO_TRACK_SWITCHING="hlsAudioTrackSwitching",m.AUDIO_TRACK_SWITCHED="hlsAudioTrackSwitched",m.AUDIO_TRACK_LOADING="hlsAudioTrackLoading",m.AUDIO_TRACK_LOADED="hlsAudioTrackLoaded",m.SUBTITLE_TRACKS_UPDATED="hlsSubtitleTracksUpdated",m.SUBTITLE_TRACKS_CLEARED="hlsSubtitleTracksCleared",m.SUBTITLE_TRACK_SWITCH="hlsSubtitleTrackSwitch",m.SUBTITLE_TRACK_LOADING="hlsSubtitleTrackLoading",m.SUBTITLE_TRACK_LOADED="hlsSubtitleTrackLoaded",m.SUBTITLE_FRAG_PROCESSED="hlsSubtitleFragProcessed",m.CUES_PARSED="hlsCuesParsed",m.NON_NATIVE_TEXT_TRACKS_FOUND="hlsNonNativeTextTracksFound",m.INIT_PTS_FOUND="hlsInitPtsFound",m.FRAG_LOADING="hlsFragLoading",m.FRAG_LOAD_EMERGENCY_ABORTED="hlsFragLoadEmergencyAborted",m.FRAG_LOADED="hlsFragLoaded",m.FRAG_DECRYPTED="hlsFragDecrypted",m.FRAG_PARSING_INIT_SEGMENT="hlsFragParsingInitSegment",m.FRAG_PARSING_USERDATA="hlsFragParsingUserdata",m.FRAG_PARSING_METADATA="hlsFragParsingMetadata",m.FRAG_PARSED="hlsFragParsed",m.FRAG_BUFFERED="hlsFragBuffered",m.FRAG_CHANGED="hlsFragChanged",m.FPS_DROP="hlsFpsDrop",m.FPS_DROP_LEVEL_CAPPING="hlsFpsDropLevelCapping",m.ERROR="hlsError",m.DESTROYING="hlsDestroying",m.KEY_LOADING="hlsKeyLoading",m.KEY_LOADED="hlsKeyLoaded",m.LIVE_BACK_BUFFER_REACHED="hlsLiveBackBufferReached",m.BACK_BUFFER_REACHED="hlsBackBufferReached"})(M||(M={}))},"./src/hls.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return x});var M=C("./node_modules/url-toolkit/src/url-toolkit.js"),m=C.n(M),y=C("./src/loader/playlist-loader.ts"),w=C("./src/loader/key-loader.ts"),b=C("./src/controller/id3-track-controller.ts"),p=C("./src/controller/latency-controller.ts"),d=C("./src/controller/level-controller.ts"),n=C("./src/controller/fragment-tracker.ts"),c=C("./src/controller/stream-controller.ts"),r=C("./src/is-supported.ts"),i=C("./src/utils/logger.ts"),o=C("./src/config.ts"),u=C("./node_modules/eventemitter3/index.js"),f=C.n(u),s=C("./src/events.ts"),l=C("./src/errors.ts");function t(h,R){for(var O=0;O<R.length;O++){var g=R[O];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(h,g.key,g)}}function S(h,R,O){return R&&t(h.prototype,R),O&&t(h,O),h}var x=function(){h.isSupported=function(){return Object(r.isSupported)()};function h(O){O===void 0&&(O={}),this.config=void 0,this.userConfig=void 0,this.coreComponents=void 0,this.networkControllers=void 0,this._emitter=new u.EventEmitter,this._autoLevelCapping=void 0,this.abrController=void 0,this.bufferController=void 0,this.capLevelController=void 0,this.latencyController=void 0,this.levelController=void 0,this.streamController=void 0,this.audioTrackController=void 0,this.subtitleTrackController=void 0,this.emeController=void 0,this.cmcdController=void 0,this._media=null,this.url=null;var g=this.config=Object(o.mergeConfig)(h.DefaultConfig,O);this.userConfig=O,Object(i.enableLogs)(g.debug),this._autoLevelCapping=-1,g.progressive&&Object(o.enableStreamingMode)(g);var _=g.abrController,E=g.bufferController,T=g.capLevelController,L=g.fpsController,I=this.abrController=new _(this),P=this.bufferController=new E(this),G=this.capLevelController=new T(this),W=new L(this),H=new y.default(this),z=new w.default(this),B=new b.default(this),k=this.levelController=new d.default(this),K=new n.FragmentTracker(this),Y=this.streamController=new c.default(this,K);G.setStreamController(Y),W.setStreamController(Y);var ne=[k,Y];this.networkControllers=ne;var oe=[H,z,I,P,G,W,B,K];this.audioTrackController=this.createController(g.audioTrackController,null,ne),this.createController(g.audioStreamController,K,ne),this.subtitleTrackController=this.createController(g.subtitleTrackController,null,ne),this.createController(g.subtitleStreamController,K,ne),this.createController(g.timelineController,null,oe),this.emeController=this.createController(g.emeController,null,oe),this.cmcdController=this.createController(g.cmcdController,null,oe),this.latencyController=this.createController(p.default,null,oe),this.coreComponents=oe}var R=h.prototype;return R.createController=function(g,_,E){if(g){var T=_?new g(this,_):new g(this);return E&&E.push(T),T}return null},R.on=function(g,_,E){E===void 0&&(E=this),this._emitter.on(g,_,E)},R.once=function(g,_,E){E===void 0&&(E=this),this._emitter.once(g,_,E)},R.removeAllListeners=function(g){this._emitter.removeAllListeners(g)},R.off=function(g,_,E,T){E===void 0&&(E=this),this._emitter.off(g,_,E,T)},R.listeners=function(g){return this._emitter.listeners(g)},R.emit=function(g,_,E){return this._emitter.emit(g,_,E)},R.trigger=function(g,_){if(this.config.debug)return this.emit(g,g,_);try{return this.emit(g,g,_)}catch(E){i.logger.error("An internal error happened while handling event "+g+'. Error message: "'+E.message+'". Here is a stacktrace:',E),this.trigger(s.Events.ERROR,{type:l.ErrorTypes.OTHER_ERROR,details:l.ErrorDetails.INTERNAL_EXCEPTION,fatal:!1,event:g,error:E})}return!1},R.listenerCount=function(g){return this._emitter.listenerCount(g)},R.destroy=function(){i.logger.log("destroy"),this.trigger(s.Events.DESTROYING,void 0),this.detachMedia(),this.removeAllListeners(),this._autoLevelCapping=-1,this.url=null,this.networkControllers.forEach(function(g){return g.destroy()}),this.networkControllers.length=0,this.coreComponents.forEach(function(g){return g.destroy()}),this.coreComponents.length=0},R.attachMedia=function(g){i.logger.log("attachMedia"),this._media=g,this.trigger(s.Events.MEDIA_ATTACHING,{media:g})},R.detachMedia=function(){i.logger.log("detachMedia"),this.trigger(s.Events.MEDIA_DETACHING,void 0),this._media=null},R.loadSource=function(g){this.stopLoad();var _=this.media,E=this.url,T=this.url=M.buildAbsoluteURL(self.location.href,g,{alwaysNormalize:!0});i.logger.log("loadSource:"+T),_&&E&&E!==T&&this.bufferController.hasSourceTypes()&&(this.detachMedia(),this.attachMedia(_)),this.trigger(s.Events.MANIFEST_LOADING,{url:g})},R.startLoad=function(g){g===void 0&&(g=-1),i.logger.log("startLoad("+g+")"),this.networkControllers.forEach(function(_){_.startLoad(g)})},R.stopLoad=function(){i.logger.log("stopLoad"),this.networkControllers.forEach(function(g){g.stopLoad()})},R.swapAudioCodec=function(){i.logger.log("swapAudioCodec"),this.streamController.swapAudioCodec()},R.recoverMediaError=function(){i.logger.log("recoverMediaError");var g=this._media;this.detachMedia(),g&&this.attachMedia(g)},R.removeLevel=function(g,_){_===void 0&&(_=0),this.levelController.removeLevel(g,_)},S(h,[{key:"levels",get:function(){var g=this.levelController.levels;return g||[]}},{key:"currentLevel",get:function(){return this.streamController.currentLevel},set:function(g){i.logger.log("set currentLevel:"+g),this.loadLevel=g,this.abrController.clearTimer(),this.streamController.immediateLevelSwitch()}},{key:"nextLevel",get:function(){return this.streamController.nextLevel},set:function(g){i.logger.log("set nextLevel:"+g),this.levelController.manualLevel=g,this.streamController.nextLevelSwitch()}},{key:"loadLevel",get:function(){return this.levelController.level},set:function(g){i.logger.log("set loadLevel:"+g),this.levelController.manualLevel=g}},{key:"nextLoadLevel",get:function(){return this.levelController.nextLoadLevel},set:function(g){this.levelController.nextLoadLevel=g}},{key:"firstLevel",get:function(){return Math.max(this.levelController.firstLevel,this.minAutoLevel)},set:function(g){i.logger.log("set firstLevel:"+g),this.levelController.firstLevel=g}},{key:"startLevel",get:function(){return this.levelController.startLevel},set:function(g){i.logger.log("set startLevel:"+g),g!==-1&&(g=Math.max(g,this.minAutoLevel)),this.levelController.startLevel=g}},{key:"capLevelToPlayerSize",get:function(){return this.config.capLevelToPlayerSize},set:function(g){var _=!!g;_!==this.config.capLevelToPlayerSize&&(_?this.capLevelController.startCapping():(this.capLevelController.stopCapping(),this.autoLevelCapping=-1,this.streamController.nextLevelSwitch()),this.config.capLevelToPlayerSize=_)}},{key:"autoLevelCapping",get:function(){return this._autoLevelCapping},set:function(g){this._autoLevelCapping!==g&&(i.logger.log("set autoLevelCapping:"+g),this._autoLevelCapping=g)}},{key:"bandwidthEstimate",get:function(){var g=this.abrController.bwEstimator;return g?g.getEstimate():NaN}},{key:"autoLevelEnabled",get:function(){return this.levelController.manualLevel===-1}},{key:"manualLevel",get:function(){return this.levelController.manualLevel}},{key:"minAutoLevel",get:function(){var g=this.levels,_=this.config.minAutoBitrate;if(!g)return 0;for(var E=g.length,T=0;T<E;T++)if(g[T].maxBitrate>_)return T;return 0}},{key:"maxAutoLevel",get:function(){var g=this.levels,_=this.autoLevelCapping,E;return _===-1&&g&&g.length?E=g.length-1:E=_,E}},{key:"nextAutoLevel",get:function(){return Math.min(Math.max(this.abrController.nextAutoLevel,this.minAutoLevel),this.maxAutoLevel)},set:function(g){this.abrController.nextAutoLevel=Math.max(this.minAutoLevel,g)}},{key:"audioTracks",get:function(){var g=this.audioTrackController;return g?g.audioTracks:[]}},{key:"audioTrack",get:function(){var g=this.audioTrackController;return g?g.audioTrack:-1},set:function(g){var _=this.audioTrackController;_&&(_.audioTrack=g)}},{key:"subtitleTracks",get:function(){var g=this.subtitleTrackController;return g?g.subtitleTracks:[]}},{key:"subtitleTrack",get:function(){var g=this.subtitleTrackController;return g?g.subtitleTrack:-1},set:function(g){var _=this.subtitleTrackController;_&&(_.subtitleTrack=g)}},{key:"media",get:function(){return this._media}},{key:"subtitleDisplay",get:function(){var g=this.subtitleTrackController;return g?g.subtitleDisplay:!1},set:function(g){var _=this.subtitleTrackController;_&&(_.subtitleDisplay=g)}},{key:"lowLatencyMode",get:function(){return this.config.lowLatencyMode},set:function(g){this.config.lowLatencyMode=g}},{key:"liveSyncPosition",get:function(){return this.latencyController.liveSyncPosition}},{key:"latency",get:function(){return this.latencyController.latency}},{key:"maxLatency",get:function(){return this.latencyController.maxLatency}},{key:"targetLatency",get:function(){return this.latencyController.targetLatency}},{key:"drift",get:function(){return this.latencyController.drift}},{key:"forceStartLoad",get:function(){return this.streamController.forceStartLoad}}],[{key:"version",get:function(){return"1.1.2"}},{key:"Events",get:function(){return s.Events}},{key:"ErrorTypes",get:function(){return l.ErrorTypes}},{key:"ErrorDetails",get:function(){return l.ErrorDetails}},{key:"DefaultConfig",get:function(){return h.defaultConfig?h.defaultConfig:o.hlsDefaultConfig},set:function(g){h.defaultConfig=g}}]),h}();x.defaultConfig=void 0},"./src/is-supported.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"isSupported",function(){return y}),C.d(v,"changeTypeSupported",function(){return w});var M=C("./src/utils/mediasource-helper.ts");function m(){return self.SourceBuffer||self.WebKitSourceBuffer}function y(){var b=Object(M.getMediaSource)();if(!b)return!1;var p=m(),d=b&&typeof b.isTypeSupported=="function"&&b.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"'),n=!p||p.prototype&&typeof p.prototype.appendBuffer=="function"&&typeof p.prototype.remove=="function";return!!d&&!!n}function w(){var b,p=m();return typeof(p==null||((b=p.prototype)===null||b===void 0)?void 0:b.changeType)=="function"}},"./src/loader/fragment-loader.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return i}),C.d(v,"LoadError",function(){return u});var M=C("./src/polyfills/number.ts"),m=C("./src/errors.ts");function y(f,s){f.prototype=Object.create(s.prototype),f.prototype.constructor=f,n(f,s)}function w(f){var s=typeof Map=="function"?new Map:void 0;return w=function(t){if(t===null||!d(t))return t;if(typeof t!="function")throw new TypeError("Super expression must either be null or a function");if(typeof s!="undefined"){if(s.has(t))return s.get(t);s.set(t,S)}function S(){return b(t,arguments,c(this).constructor)}return S.prototype=Object.create(t.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),n(S,t)},w(f)}function b(f,s,l){return p()?b=Reflect.construct:b=function(S,x,h){var R=[null];R.push.apply(R,x);var O=Function.bind.apply(S,R),g=new O;return h&&n(g,h.prototype),g},b.apply(null,arguments)}function p(){if(typeof Reflect=="undefined"||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(f){return!1}}function d(f){return Function.toString.call(f).indexOf("[native code]")!==-1}function n(f,s){return n=Object.setPrototypeOf||function(t,S){return t.__proto__=S,t},n(f,s)}function c(f){return c=Object.setPrototypeOf?Object.getPrototypeOf:function(l){return l.__proto__||Object.getPrototypeOf(l)},c(f)}var r=Math.pow(2,17),i=function(){function f(l){this.config=void 0,this.loader=null,this.partLoadTimeout=-1,this.config=l}var s=f.prototype;return s.destroy=function(){this.loader&&(this.loader.destroy(),this.loader=null)},s.abort=function(){this.loader&&this.loader.abort()},s.load=function(t,S){var x=this,h=t.url;if(!h)return Promise.reject(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:t,networkDetails:null},"Fragment does not have a "+(h?"part list":"url")));this.abort();var R=this.config,O=R.fLoader,g=R.loader;return new Promise(function(_,E){x.loader&&x.loader.destroy();var T=x.loader=t.loader=O?new O(R):new g(R),L=o(t),I={timeout:R.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:R.fragLoadingMaxRetryTimeout,highWaterMark:r};t.stats=T.stats,T.load(L,I,{onSuccess:function(G,W,H,z){x.resetLoader(t,T),_({frag:t,part:null,payload:G.data,networkDetails:z})},onError:function(G,W,H){x.resetLoader(t,T),E(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:t,response:G,networkDetails:H}))},onAbort:function(G,W,H){x.resetLoader(t,T),E(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.INTERNAL_ABORTED,fatal:!1,frag:t,networkDetails:H}))},onTimeout:function(G,W,H){x.resetLoader(t,T),E(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.FRAG_LOAD_TIMEOUT,fatal:!1,frag:t,networkDetails:H}))},onProgress:function(G,W,H,z){S&&S({frag:t,part:null,payload:H,networkDetails:z})}})})},s.loadPart=function(t,S,x){var h=this;this.abort();var R=this.config,O=R.fLoader,g=R.loader;return new Promise(function(_,E){h.loader&&h.loader.destroy();var T=h.loader=t.loader=O?new O(R):new g(R),L=o(t,S),I={timeout:R.fragLoadingTimeOut,maxRetry:0,retryDelay:0,maxRetryDelay:R.fragLoadingMaxRetryTimeout,highWaterMark:r};S.stats=T.stats,T.load(L,I,{onSuccess:function(G,W,H,z){h.resetLoader(t,T),h.updateStatsFromPart(t,S);var B={frag:t,part:S,payload:G.data,networkDetails:z};x(B),_(B)},onError:function(G,W,H){h.resetLoader(t,T),E(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.FRAG_LOAD_ERROR,fatal:!1,frag:t,part:S,response:G,networkDetails:H}))},onAbort:function(G,W,H){t.stats.aborted=S.stats.aborted,h.resetLoader(t,T),E(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.INTERNAL_ABORTED,fatal:!1,frag:t,part:S,networkDetails:H}))},onTimeout:function(G,W,H){h.resetLoader(t,T),E(new u({type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.FRAG_LOAD_TIMEOUT,fatal:!1,frag:t,part:S,networkDetails:H}))}})})},s.updateStatsFromPart=function(t,S){var x=t.stats,h=S.stats,R=h.total;if(x.loaded+=h.loaded,R){var O=Math.round(t.duration/S.duration),g=Math.min(Math.round(x.loaded/R),O),_=O-g,E=_*Math.round(x.loaded/g);x.total=x.loaded+E}else x.total=Math.max(x.loaded,x.total);var T=x.loading,L=h.loading;T.start?T.first+=L.first-L.start:(T.start=L.start,T.first=L.first),T.end=L.end},s.resetLoader=function(t,S){t.loader=null,this.loader===S&&(self.clearTimeout(this.partLoadTimeout),this.loader=null),S.destroy()},f}();function o(f,s){s===void 0&&(s=null);var l=s||f,t={frag:f,part:s,responseType:"arraybuffer",url:l.url,headers:{},rangeStart:0,rangeEnd:0},S=l.byteRangeStartOffset,x=l.byteRangeEndOffset;return Object(M.isFiniteNumber)(S)&&Object(M.isFiniteNumber)(x)&&(t.rangeStart=S,t.rangeEnd=x),t}var u=function(f){y(s,f);function s(l){for(var t,S=arguments.length,x=new Array(S>1?S-1:0),h=1;h<S;h++)x[h-1]=arguments[h];return t=f.call.apply(f,[this].concat(x))||this,t.data=void 0,t.data=l,t}return s}(w(Error))},"./src/loader/fragment.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"ElementaryStreamTypes",function(){return i}),C.d(v,"BaseSegment",function(){return o}),C.d(v,"Fragment",function(){return u}),C.d(v,"Part",function(){return f});var M=C("./src/polyfills/number.ts"),m=C("./node_modules/url-toolkit/src/url-toolkit.js"),y=C.n(m),w=C("./src/utils/logger.ts"),b=C("./src/loader/level-key.ts"),p=C("./src/loader/load-stats.ts");function d(s,l){s.prototype=Object.create(l.prototype),s.prototype.constructor=s,n(s,l)}function n(s,l){return n=Object.setPrototypeOf||function(S,x){return S.__proto__=x,S},n(s,l)}function c(s,l){for(var t=0;t<l.length;t++){var S=l[t];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(s,S.key,S)}}function r(s,l,t){return l&&c(s.prototype,l),t&&c(s,t),s}var i;(function(s){s.AUDIO="audio",s.VIDEO="video",s.AUDIOVIDEO="audiovideo"})(i||(i={}));var o=function(){function s(t){var S;this._byteRange=null,this._url=null,this.baseurl=void 0,this.relurl=void 0,this.elementaryStreams=(S={},S[i.AUDIO]=null,S[i.VIDEO]=null,S[i.AUDIOVIDEO]=null,S),this.baseurl=t}var l=s.prototype;return l.setByteRange=function(S,x){var h=S.split("@",2),R=[];h.length===1?R[0]=x?x.byteRangeEndOffset:0:R[0]=parseInt(h[1]),R[1]=parseInt(h[0])+R[0],this._byteRange=R},r(s,[{key:"byteRange",get:function(){return this._byteRange?this._byteRange:[]}},{key:"byteRangeStartOffset",get:function(){return this.byteRange[0]}},{key:"byteRangeEndOffset",get:function(){return this.byteRange[1]}},{key:"url",get:function(){return!this._url&&this.baseurl&&this.relurl&&(this._url=Object(m.buildAbsoluteURL)(this.baseurl,this.relurl,{alwaysNormalize:!0})),this._url||""},set:function(S){this._url=S}}]),s}(),u=function(s){d(l,s);function l(S,x){var h;return h=s.call(this,x)||this,h._decryptdata=null,h.rawProgramDateTime=null,h.programDateTime=null,h.tagList=[],h.duration=0,h.sn=0,h.levelkey=void 0,h.type=void 0,h.loader=null,h.level=-1,h.cc=0,h.startPTS=void 0,h.endPTS=void 0,h.appendedPTS=void 0,h.startDTS=void 0,h.endDTS=void 0,h.start=0,h.deltaPTS=void 0,h.maxStartPTS=void 0,h.minEndPTS=void 0,h.stats=new p.LoadStats,h.urlId=0,h.data=void 0,h.bitrateTest=!1,h.title=null,h.initSegment=null,h.type=S,h}var t=l.prototype;return t.createInitializationVector=function(x){for(var h=new Uint8Array(16),R=12;R<16;R++)h[R]=x>>8*(15-R)&255;return h},t.setDecryptDataFromLevelKey=function(x,h){var R=x;return(x==null?void 0:x.method)==="AES-128"&&x.uri&&!x.iv&&(R=b.LevelKey.fromURI(x.uri),R.method=x.method,R.iv=this.createInitializationVector(h),R.keyFormat="identity"),R},t.setElementaryStreamInfo=function(x,h,R,O,g,_){_===void 0&&(_=!1);var E=this.elementaryStreams,T=E[x];if(!T){E[x]={startPTS:h,endPTS:R,startDTS:O,endDTS:g,partial:_};return}T.startPTS=Math.min(T.startPTS,h),T.endPTS=Math.max(T.endPTS,R),T.startDTS=Math.min(T.startDTS,O),T.endDTS=Math.max(T.endDTS,g)},t.clearElementaryStreamInfo=function(){var x=this.elementaryStreams;x[i.AUDIO]=null,x[i.VIDEO]=null,x[i.AUDIOVIDEO]=null},r(l,[{key:"decryptdata",get:function(){if(!this.levelkey&&!this._decryptdata)return null;if(!this._decryptdata&&this.levelkey){var x=this.sn;typeof x!="number"&&(this.levelkey&&this.levelkey.method==="AES-128"&&!this.levelkey.iv&&w.logger.warn('missing IV for initialization segment with method="'+this.levelkey.method+'" - compliance issue'),x=0),this._decryptdata=this.setDecryptDataFromLevelKey(this.levelkey,x)}return this._decryptdata}},{key:"end",get:function(){return this.start+this.duration}},{key:"endProgramDateTime",get:function(){if(this.programDateTime===null)return null;if(!Object(M.isFiniteNumber)(this.programDateTime))return null;var x=Object(M.isFiniteNumber)(this.duration)?this.duration:0;return this.programDateTime+x*1e3}},{key:"encrypted",get:function(){var x;return!!((x=this.decryptdata)!==null&&x!==void 0&&x.keyFormat&&this.decryptdata.uri)}}]),l}(o),f=function(s){d(l,s);function l(t,S,x,h,R){var O;O=s.call(this,x)||this,O.fragOffset=0,O.duration=0,O.gap=!1,O.independent=!1,O.relurl=void 0,O.fragment=void 0,O.index=void 0,O.stats=new p.LoadStats,O.duration=t.decimalFloatingPoint("DURATION"),O.gap=t.bool("GAP"),O.independent=t.bool("INDEPENDENT"),O.relurl=t.enumeratedString("URI"),O.fragment=S,O.index=h;var g=t.enumeratedString("BYTERANGE");return g&&O.setByteRange(g,R),R&&(O.fragOffset=R.fragOffset+R.duration),O}return r(l,[{key:"start",get:function(){return this.fragment.start+this.fragOffset}},{key:"end",get:function(){return this.start+this.duration}},{key:"loaded",get:function(){var S=this.elementaryStreams;return!!(S.audio||S.video||S.audiovideo)}}]),l}(o)},"./src/loader/key-loader.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return w});var M=C("./src/events.ts"),m=C("./src/errors.ts"),y=C("./src/utils/logger.ts"),w=function(){function b(d){this.hls=void 0,this.loaders={},this.decryptkey=null,this.decrypturl=null,this.hls=d,this._registerListeners()}var p=b.prototype;return p._registerListeners=function(){this.hls.on(M.Events.KEY_LOADING,this.onKeyLoading,this)},p._unregisterListeners=function(){this.hls.off(M.Events.KEY_LOADING,this.onKeyLoading)},p.destroy=function(){this._unregisterListeners();for(var n in this.loaders){var c=this.loaders[n];c&&c.destroy()}this.loaders={}},p.onKeyLoading=function(n,c){var r=c.frag,i=r.type,o=this.loaders[i];if(!r.decryptdata){y.logger.warn("Missing decryption data on fragment in onKeyLoading");return}var u=r.decryptdata.uri;if(u!==this.decrypturl||this.decryptkey===null){var f=this.hls.config;if(o&&(y.logger.warn("abort previous key loader for type:"+i),o.abort()),!u){y.logger.warn("key uri is falsy");return}var s=f.loader,l=r.loader=this.loaders[i]=new s(f);this.decrypturl=u,this.decryptkey=null;var t={url:u,frag:r,responseType:"arraybuffer"},S={timeout:f.fragLoadingTimeOut,maxRetry:0,retryDelay:f.fragLoadingRetryDelay,maxRetryDelay:f.fragLoadingMaxRetryTimeout,highWaterMark:0},x={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};l.load(t,S,x)}else this.decryptkey&&(r.decryptdata.key=this.decryptkey,this.hls.trigger(M.Events.KEY_LOADED,{frag:r}))},p.loadsuccess=function(n,c,r){var i=r.frag;if(!i.decryptdata){y.logger.error("after key load, decryptdata unset");return}this.decryptkey=i.decryptdata.key=new Uint8Array(n.data),i.loader=null,delete this.loaders[i.type],this.hls.trigger(M.Events.KEY_LOADED,{frag:i})},p.loaderror=function(n,c){var r=c.frag,i=r.loader;i&&i.abort(),delete this.loaders[r.type],this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.KEY_LOAD_ERROR,fatal:!1,frag:r,response:n})},p.loadtimeout=function(n,c){var r=c.frag,i=r.loader;i&&i.abort(),delete this.loaders[r.type],this.hls.trigger(M.Events.ERROR,{type:m.ErrorTypes.NETWORK_ERROR,details:m.ErrorDetails.KEY_LOAD_TIMEOUT,fatal:!1,frag:r})},b}()},"./src/loader/level-details.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"LevelDetails",function(){return b});var M=C("./src/polyfills/number.ts");function m(p,d){for(var n=0;n<d.length;n++){var c=d[n];c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(p,c.key,c)}}function y(p,d,n){return d&&m(p.prototype,d),n&&m(p,n),p}var w=10,b=function(){function p(n){this.PTSKnown=!1,this.alignedSliding=!1,this.averagetargetduration=void 0,this.endCC=0,this.endSN=0,this.fragments=void 0,this.fragmentHint=void 0,this.partList=null,this.live=!0,this.ageHeader=0,this.advancedDateTime=void 0,this.updated=!0,this.advanced=!0,this.availabilityDelay=void 0,this.misses=0,this.needSidxRanges=!1,this.startCC=0,this.startSN=0,this.startTimeOffset=null,this.targetduration=0,this.totalduration=0,this.type=null,this.url=void 0,this.m3u8="",this.version=null,this.canBlockReload=!1,this.canSkipUntil=0,this.canSkipDateRanges=!1,this.skippedSegments=0,this.recentlyRemovedDateranges=void 0,this.partHoldBack=0,this.holdBack=0,this.partTarget=0,this.preloadHint=void 0,this.renditionReports=void 0,this.tuneInGoal=0,this.deltaUpdateFailed=void 0,this.driftStartTime=0,this.driftEndTime=0,this.driftStart=0,this.driftEnd=0,this.fragments=[],this.url=n}var d=p.prototype;return d.reloaded=function(c){if(!c){this.advanced=!0,this.updated=!0;return}var r=this.lastPartSn-c.lastPartSn,i=this.lastPartIndex-c.lastPartIndex;this.updated=this.endSN!==c.endSN||!!i||!!r,this.advanced=this.endSN>c.endSN||r>0||r===0&&i>0,this.updated||this.advanced?this.misses=Math.floor(c.misses*.6):this.misses=c.misses+1,this.availabilityDelay=c.availabilityDelay},y(p,[{key:"hasProgramDateTime",get:function(){return this.fragments.length?Object(M.isFiniteNumber)(this.fragments[this.fragments.length-1].programDateTime):!1}},{key:"levelTargetDuration",get:function(){return this.averagetargetduration||this.targetduration||w}},{key:"drift",get:function(){var c=this.driftEndTime-this.driftStartTime;if(c>0){var r=this.driftEnd-this.driftStart;return r*1e3/c}return 1}},{key:"edge",get:function(){return this.partEnd||this.fragmentEnd}},{key:"partEnd",get:function(){var c;return(c=this.partList)!==null&&c!==void 0&&c.length?this.partList[this.partList.length-1].end:this.fragmentEnd}},{key:"fragmentEnd",get:function(){var c;return(c=this.fragments)!==null&&c!==void 0&&c.length?this.fragments[this.fragments.length-1].end:0}},{key:"age",get:function(){return this.advancedDateTime?Math.max(Date.now()-this.advancedDateTime,0)/1e3:0}},{key:"lastPartIndex",get:function(){var c;return(c=this.partList)!==null&&c!==void 0&&c.length?this.partList[this.partList.length-1].index:-1}},{key:"lastPartSn",get:function(){var c;return(c=this.partList)!==null&&c!==void 0&&c.length?this.partList[this.partList.length-1].fragment.sn:this.endSN}}]),p}()},"./src/loader/level-key.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"LevelKey",function(){return b});var M=C("./node_modules/url-toolkit/src/url-toolkit.js"),m=C.n(M);function y(p,d){for(var n=0;n<d.length;n++){var c=d[n];c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(p,c.key,c)}}function w(p,d,n){return d&&y(p.prototype,d),n&&y(p,n),p}var b=function(){p.fromURL=function(n,c){return new p(n,c)},p.fromURI=function(n){return new p(n)};function p(d,n){this._uri=null,this.method=null,this.keyFormat=null,this.keyFormatVersions=null,this.keyID=null,this.key=null,this.iv=null,n?this._uri=Object(M.buildAbsoluteURL)(d,n,{alwaysNormalize:!0}):this._uri=d}return w(p,[{key:"uri",get:function(){return this._uri}}]),p}()},"./src/loader/load-stats.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"LoadStats",function(){return M});var M=function(){this.aborted=!1,this.loaded=0,this.retry=0,this.total=0,this.chunkCount=0,this.bwEstimate=0,this.loading={start:0,first:0,end:0},this.parsing={start:0,end:0},this.buffering={start:0,first:0,end:0}}},"./src/loader/m3u8-parser.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return l});var M=C("./src/polyfills/number.ts"),m=C("./node_modules/url-toolkit/src/url-toolkit.js"),y=C.n(m),w=C("./src/loader/fragment.ts"),b=C("./src/loader/level-details.ts"),p=C("./src/loader/level-key.ts"),d=C("./src/utils/attr-list.ts"),n=C("./src/utils/logger.ts"),c=C("./src/utils/codecs.ts"),r=/#EXT-X-STREAM-INF:([^\r\n]*)(?:[\r\n](?:#[^\r\n]*)?)*([^\r\n]+)|#EXT-X-SESSION-DATA:([^\r\n]*)[\r\n]+/g,i=/#EXT-X-MEDIA:(.*)/g,o=new RegExp([/#EXTINF:\s*(\d*(?:\.\d+)?)(?:,(.*)\s+)?/.source,/(?!#) *(\S[\S ]*)/.source,/#EXT-X-BYTERANGE:*(.+)/.source,/#EXT-X-PROGRAM-DATE-TIME:(.+)/.source,/#.*/.source].join("|"),"g"),u=new RegExp([/#(EXTM3U)/.source,/#EXT-X-(PLAYLIST-TYPE):(.+)/.source,/#EXT-X-(MEDIA-SEQUENCE): *(\d+)/.source,/#EXT-X-(SKIP):(.+)/.source,/#EXT-X-(TARGETDURATION): *(\d+)/.source,/#EXT-X-(KEY):(.+)/.source,/#EXT-X-(START):(.+)/.source,/#EXT-X-(ENDLIST)/.source,/#EXT-X-(DISCONTINUITY-SEQ)UENCE: *(\d+)/.source,/#EXT-X-(DIS)CONTINUITY/.source,/#EXT-X-(VERSION):(\d+)/.source,/#EXT-X-(MAP):(.+)/.source,/#EXT-X-(SERVER-CONTROL):(.+)/.source,/#EXT-X-(PART-INF):(.+)/.source,/#EXT-X-(GAP)/.source,/#EXT-X-(BITRATE):\s*(\d+)/.source,/#EXT-X-(PART):(.+)/.source,/#EXT-X-(PRELOAD-HINT):(.+)/.source,/#EXT-X-(RENDITION-REPORT):(.+)/.source,/(#)([^:]*):(.*)/.source,/(#)(.*)(?:.*)\r?\n?/.source].join("|")),f=/\.(mp4|m4s|m4v|m4a)$/i;function s(R){var O,g;return f.test((O=(g=m.parseURL(R))===null||g===void 0?void 0:g.path)!=null?O:"")}var l=function(){function R(){}return R.findGroup=function(g,_){for(var E=0;E<g.length;E++){var T=g[E];if(T.id===_)return T}},R.convertAVC1ToAVCOTI=function(g){var _=g.split(".");if(_.length>2){var E=_.shift()+".";return E+=parseInt(_.shift()).toString(16),E+=("000"+parseInt(_.shift()).toString(16)).substr(-4),E}return g},R.resolve=function(g,_){return m.buildAbsoluteURL(_,g,{alwaysNormalize:!0})},R.parseMasterPlaylist=function(g,_){var E=[],T={},L=!1;r.lastIndex=0;for(var I;(I=r.exec(g))!=null;)if(I[1]){var P=new d.AttrList(I[1]),G={attrs:P,bitrate:P.decimalInteger("AVERAGE-BANDWIDTH")||P.decimalInteger("BANDWIDTH"),name:P.NAME,url:R.resolve(I[2],_)},W=P.decimalResolution("RESOLUTION");W&&(G.width=W.width,G.height=W.height),t((P.CODECS||"").split(/[ ,]+/).filter(function(z){return z}),G),G.videoCodec&&G.videoCodec.indexOf("avc1")!==-1&&(G.videoCodec=R.convertAVC1ToAVCOTI(G.videoCodec)),E.push(G)}else if(I[3]){var H=new d.AttrList(I[3]);H["DATA-ID"]&&(L=!0,T[H["DATA-ID"]]=H)}return{levels:E,sessionData:L?T:null}},R.parseMasterPlaylistMedia=function(g,_,E,T){T===void 0&&(T=[]);var L,I=[],P=0;for(i.lastIndex=0;(L=i.exec(g))!==null;){var G=new d.AttrList(L[1]);if(G.TYPE===E){var W={attrs:G,bitrate:0,id:P++,groupId:G["GROUP-ID"],instreamId:G["INSTREAM-ID"],name:G.NAME||G.LANGUAGE||"",type:E,default:G.bool("DEFAULT"),autoselect:G.bool("AUTOSELECT"),forced:G.bool("FORCED"),lang:G.LANGUAGE,url:G.URI?R.resolve(G.URI,_):""};if(T.length){var H=R.findGroup(T,W.groupId)||T[0];S(W,H,"audioCodec"),S(W,H,"textCodec")}I.push(W)}}return I},R.parseLevelPlaylist=function(g,_,E,T,L){var I=new b.LevelDetails(_),P=I.fragments,G=null,W=0,H=0,z=0,B=0,k=null,K=new w.Fragment(T,_),Y,ne,oe,_e=-1,xe=!1;for(o.lastIndex=0,I.m3u8=g;(Y=o.exec(g))!==null;){xe&&(xe=!1,K=new w.Fragment(T,_),K.start=z,K.sn=W,K.cc=B,K.level=E,G&&(K.initSegment=G,K.rawProgramDateTime=G.rawProgramDateTime));var le=Y[1];if(le){K.duration=parseFloat(le);var me=(" "+Y[2]).slice(1);K.title=me||null,K.tagList.push(me?["INF",le,me]:["INF",le])}else if(Y[3])Object(M.isFiniteNumber)(K.duration)&&(K.start=z,oe&&(K.levelkey=oe),K.sn=W,K.level=E,K.cc=B,K.urlId=L,P.push(K),K.relurl=(" "+Y[3]).slice(1),h(K,k),k=K,z+=K.duration,W++,H=0,xe=!0);else if(Y[4]){var de=(" "+Y[4]).slice(1);k?K.setByteRange(de,k):K.setByteRange(de)}else if(Y[5])K.rawProgramDateTime=(" "+Y[5]).slice(1),K.tagList.push(["PROGRAM-DATE-TIME",K.rawProgramDateTime]),_e===-1&&(_e=P.length);else{if(Y=Y[0].match(u),!Y){n.logger.warn("No matches on slow regex match for level playlist!");continue}for(ne=1;ne<Y.length&&!(typeof Y[ne]!="undefined");ne++);var ae=(" "+Y[ne]).slice(1),ie=(" "+Y[ne+1]).slice(1),q=Y[ne+2]?(" "+Y[ne+2]).slice(1):"";switch(ae){case"PLAYLIST-TYPE":I.type=ie.toUpperCase();break;case"MEDIA-SEQUENCE":W=I.startSN=parseInt(ie);break;case"SKIP":{var ue=new d.AttrList(ie),Z=ue.decimalInteger("SKIPPED-SEGMENTS");if(Object(M.isFiniteNumber)(Z)){I.skippedSegments=Z;for(var ee=Z;ee--;)P.unshift(null);W+=Z}var Ee=ue.enumeratedString("RECENTLY-REMOVED-DATERANGES");Ee&&(I.recentlyRemovedDateranges=Ee.split(" "));break}case"TARGETDURATION":I.targetduration=parseFloat(ie);break;case"VERSION":I.version=parseInt(ie);break;case"EXTM3U":break;case"ENDLIST":I.live=!1;break;case"#":(ie||q)&&K.tagList.push(q?[ie,q]:[ie]);break;case"DIS":B++;case"GAP":K.tagList.push([ae]);break;case"BITRATE":K.tagList.push([ae,ie]);break;case"DISCONTINUITY-SEQ":B=parseInt(ie);break;case"KEY":{var te,J=new d.AttrList(ie),X=J.enumeratedString("METHOD"),$=J.URI,ge=J.hexadecimalInteger("IV"),fe=J.enumeratedString("KEYFORMATVERSIONS"),Te=J.enumeratedString("KEYID"),ze=(te=J.enumeratedString("KEYFORMAT"))!=null?te:"identity",Xe=["com.apple.streamingkeydelivery","com.microsoft.playready","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed","com.widevine"];if(Xe.indexOf(ze)>-1){n.logger.warn("Keyformat "+ze+" is not supported from the manifest");continue}else if(ze!=="identity")continue;X&&(oe=p.LevelKey.fromURL(_,$),$&&["AES-128","SAMPLE-AES","SAMPLE-AES-CENC"].indexOf(X)>=0&&(oe.method=X,oe.keyFormat=ze,Te&&(oe.keyID=Te),fe&&(oe.keyFormatVersions=fe),oe.iv=ge));break}case"START":{var Ye=new d.AttrList(ie),rt=Ye.decimalFloatingPoint("TIME-OFFSET");Object(M.isFiniteNumber)(rt)&&(I.startTimeOffset=rt);break}case"MAP":{var at=new d.AttrList(ie);K.relurl=at.URI,at.BYTERANGE&&K.setByteRange(at.BYTERANGE),K.level=E,K.sn="initSegment",oe&&(K.levelkey=oe),K.initSegment=null,G=K,xe=!0;break}case"SERVER-CONTROL":{var ot=new d.AttrList(ie);I.canBlockReload=ot.bool("CAN-BLOCK-RELOAD"),I.canSkipUntil=ot.optionalFloat("CAN-SKIP-UNTIL",0),I.canSkipDateRanges=I.canSkipUntil>0&&ot.bool("CAN-SKIP-DATERANGES"),I.partHoldBack=ot.optionalFloat("PART-HOLD-BACK",0),I.holdBack=ot.optionalFloat("HOLD-BACK",0);break}case"PART-INF":{var Pe=new d.AttrList(ie);I.partTarget=Pe.decimalFloatingPoint("PART-TARGET");break}case"PART":{var Se=I.partList;Se||(Se=I.partList=[]);var Je=H>0?Se[Se.length-1]:void 0,nt=H++,We=new w.Part(new d.AttrList(ie),K,_,nt,Je);Se.push(We),K.duration+=We.duration;break}case"PRELOAD-HINT":{var et=new d.AttrList(ie);I.preloadHint=et;break}case"RENDITION-REPORT":{var Me=new d.AttrList(ie);I.renditionReports=I.renditionReports||[],I.renditionReports.push(Me);break}default:n.logger.warn("line parsed but not handled: "+Y);break}}}k&&!k.relurl?(P.pop(),z-=k.duration,I.partList&&(I.fragmentHint=k)):I.partList&&(h(K,k),K.cc=B,I.fragmentHint=K);var Ce=P.length,Re=P[0],pe=P[Ce-1];if(z+=I.skippedSegments*I.targetduration,z>0&&Ce&&pe){I.averagetargetduration=z/Ce;var ye=pe.sn;I.endSN=ye!=="initSegment"?ye:0,Re&&(I.startCC=Re.cc,Re.initSegment||I.fragments.every(function(we){return we.relurl&&s(we.relurl)})&&(n.logger.warn("MP4 fragments found but no init segment (probably no MAP, incomplete M3U8), trying to fetch SIDX"),K=new w.Fragment(T,_),K.relurl=pe.relurl,K.level=E,K.sn="initSegment",Re.initSegment=K,I.needSidxRanges=!0))}else I.endSN=0,I.startCC=0;return I.fragmentHint&&(z+=I.fragmentHint.duration),I.totalduration=z,I.endCC=B,_e>0&&x(P,_e),I},R}();function t(R,O){["video","audio","text"].forEach(function(g){var _=R.filter(function(T){return Object(c.isCodecType)(T,g)});if(_.length){var E=_.filter(function(T){return T.lastIndexOf("avc1",0)===0||T.lastIndexOf("mp4a",0)===0});O[g+"Codec"]=E.length>0?E[0]:_[0],R=R.filter(function(T){return _.indexOf(T)===-1})}}),O.unknownCodecs=R}function S(R,O,g){var _=O[g];_&&(R[g]=_)}function x(R,O){for(var g=R[O],_=O;_--;){var E=R[_];if(!E)return;E.programDateTime=g.programDateTime-E.duration*1e3,g=E}}function h(R,O){R.rawProgramDateTime?R.programDateTime=Date.parse(R.rawProgramDateTime):O!=null&&O.programDateTime&&(R.programDateTime=O.endProgramDateTime),Object(M.isFiniteNumber)(R.programDateTime)||(R.programDateTime=null,R.rawProgramDateTime=null)}},"./src/loader/playlist-loader.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/polyfills/number.ts"),m=C("./src/events.ts"),y=C("./src/errors.ts"),w=C("./src/utils/logger.ts"),b=C("./src/utils/mp4-tools.ts"),p=C("./src/loader/m3u8-parser.ts"),d=C("./src/types/loader.ts"),n=C("./src/utils/attr-list.ts");function c(o){var u=o.type;switch(u){case d.PlaylistContextType.AUDIO_TRACK:return d.PlaylistLevelType.AUDIO;case d.PlaylistContextType.SUBTITLE_TRACK:return d.PlaylistLevelType.SUBTITLE;default:return d.PlaylistLevelType.MAIN}}function r(o,u){var f=o.url;return(f===void 0||f.indexOf("data:")===0)&&(f=u.url),f}var i=function(){function o(f){this.hls=void 0,this.loaders=Object.create(null),this.hls=f,this.registerListeners()}var u=o.prototype;return u.registerListeners=function(){var s=this.hls;s.on(m.Events.MANIFEST_LOADING,this.onManifestLoading,this),s.on(m.Events.LEVEL_LOADING,this.onLevelLoading,this),s.on(m.Events.AUDIO_TRACK_LOADING,this.onAudioTrackLoading,this),s.on(m.Events.SUBTITLE_TRACK_LOADING,this.onSubtitleTrackLoading,this)},u.unregisterListeners=function(){var s=this.hls;s.off(m.Events.MANIFEST_LOADING,this.onManifestLoading,this),s.off(m.Events.LEVEL_LOADING,this.onLevelLoading,this),s.off(m.Events.AUDIO_TRACK_LOADING,this.onAudioTrackLoading,this),s.off(m.Events.SUBTITLE_TRACK_LOADING,this.onSubtitleTrackLoading,this)},u.createInternalLoader=function(s){var l=this.hls.config,t=l.pLoader,S=l.loader,x=t||S,h=new x(l);return s.loader=h,this.loaders[s.type]=h,h},u.getInternalLoader=function(s){return this.loaders[s.type]},u.resetInternalLoader=function(s){this.loaders[s]&&delete this.loaders[s]},u.destroyInternalLoaders=function(){for(var s in this.loaders){var l=this.loaders[s];l&&l.destroy(),this.resetInternalLoader(s)}},u.destroy=function(){this.unregisterListeners(),this.destroyInternalLoaders()},u.onManifestLoading=function(s,l){var t=l.url;this.load({id:null,groupId:null,level:0,responseType:"text",type:d.PlaylistContextType.MANIFEST,url:t,deliveryDirectives:null})},u.onLevelLoading=function(s,l){var t=l.id,S=l.level,x=l.url,h=l.deliveryDirectives;this.load({id:t,groupId:null,level:S,responseType:"text",type:d.PlaylistContextType.LEVEL,url:x,deliveryDirectives:h})},u.onAudioTrackLoading=function(s,l){var t=l.id,S=l.groupId,x=l.url,h=l.deliveryDirectives;this.load({id:t,groupId:S,level:null,responseType:"text",type:d.PlaylistContextType.AUDIO_TRACK,url:x,deliveryDirectives:h})},u.onSubtitleTrackLoading=function(s,l){var t=l.id,S=l.groupId,x=l.url,h=l.deliveryDirectives;this.load({id:t,groupId:S,level:null,responseType:"text",type:d.PlaylistContextType.SUBTITLE_TRACK,url:x,deliveryDirectives:h})},u.load=function(s){var l,t=this.hls.config,S=this.getInternalLoader(s);if(S){var x=S.context;if(x&&x.url===s.url){w.logger.trace("[playlist-loader]: playlist request ongoing");return}w.logger.log("[playlist-loader]: aborting previous loader for type: "+s.type),S.abort()}var h,R,O,g;switch(s.type){case d.PlaylistContextType.MANIFEST:h=t.manifestLoadingMaxRetry,R=t.manifestLoadingTimeOut,O=t.manifestLoadingRetryDelay,g=t.manifestLoadingMaxRetryTimeout;break;case d.PlaylistContextType.LEVEL:case d.PlaylistContextType.AUDIO_TRACK:case d.PlaylistContextType.SUBTITLE_TRACK:h=0,R=t.levelLoadingTimeOut;break;default:h=t.levelLoadingMaxRetry,R=t.levelLoadingTimeOut,O=t.levelLoadingRetryDelay,g=t.levelLoadingMaxRetryTimeout;break}if(S=this.createInternalLoader(s),(l=s.deliveryDirectives)!==null&&l!==void 0&&l.part){var _;if(s.type===d.PlaylistContextType.LEVEL&&s.level!==null?_=this.hls.levels[s.level].details:s.type===d.PlaylistContextType.AUDIO_TRACK&&s.id!==null?_=this.hls.audioTracks[s.id].details:s.type===d.PlaylistContextType.SUBTITLE_TRACK&&s.id!==null&&(_=this.hls.subtitleTracks[s.id].details),_){var E=_.partTarget,T=_.targetduration;E&&T&&(R=Math.min(Math.max(E*3,T*.8)*1e3,R))}}var L={timeout:R,maxRetry:h,retryDelay:O,maxRetryDelay:g,highWaterMark:0},I={onSuccess:this.loadsuccess.bind(this),onError:this.loaderror.bind(this),onTimeout:this.loadtimeout.bind(this)};S.load(s,L,I)},u.loadsuccess=function(s,l,t,S){if(S===void 0&&(S=null),t.isSidxRequest){this.handleSidxRequest(s,t),this.handlePlaylistLoaded(s,l,t,S);return}this.resetInternalLoader(t.type);var x=s.data;if(x.indexOf("#EXTM3U")!==0){this.handleManifestParsingError(s,t,"no EXTM3U delimiter",S);return}l.parsing.start=performance.now(),x.indexOf("#EXTINF:")>0||x.indexOf("#EXT-X-TARGETDURATION:")>0?this.handleTrackOrLevelPlaylist(s,l,t,S):this.handleMasterPlaylist(s,l,t,S)},u.loaderror=function(s,l,t){t===void 0&&(t=null),this.handleNetworkError(l,t,!1,s)},u.loadtimeout=function(s,l,t){t===void 0&&(t=null),this.handleNetworkError(l,t,!0)},u.handleMasterPlaylist=function(s,l,t,S){var x=this.hls,h=s.data,R=r(s,t),O=p.default.parseMasterPlaylist(h,R),g=O.levels,_=O.sessionData;if(!g.length){this.handleManifestParsingError(s,t,"no level found in manifest",S);return}var E=g.map(function(W){return{id:W.attrs.AUDIO,audioCodec:W.audioCodec}}),T=g.map(function(W){return{id:W.attrs.SUBTITLES,textCodec:W.textCodec}}),L=p.default.parseMasterPlaylistMedia(h,R,"AUDIO",E),I=p.default.parseMasterPlaylistMedia(h,R,"SUBTITLES",T),P=p.default.parseMasterPlaylistMedia(h,R,"CLOSED-CAPTIONS");if(L.length){var G=L.some(function(W){return!W.url});!G&&g[0].audioCodec&&!g[0].attrs.AUDIO&&(w.logger.log("[playlist-loader]: audio codec signaled in quality level, but no embedded audio track signaled, create one"),L.unshift({type:"main",name:"main",default:!1,autoselect:!1,forced:!1,id:-1,attrs:new n.AttrList({}),bitrate:0,url:""}))}x.trigger(m.Events.MANIFEST_LOADED,{levels:g,audioTracks:L,subtitles:I,captions:P,url:R,stats:l,networkDetails:S,sessionData:_})},u.handleTrackOrLevelPlaylist=function(s,l,t,S){var x=this.hls,h=t.id,R=t.level,O=t.type,g=r(s,t),_=Object(M.isFiniteNumber)(h)?h:0,E=Object(M.isFiniteNumber)(R)?R:_,T=c(t),L=p.default.parseLevelPlaylist(s.data,g,E,T,_);if(!L.fragments.length){x.trigger(m.Events.ERROR,{type:y.ErrorTypes.NETWORK_ERROR,details:y.ErrorDetails.LEVEL_EMPTY_ERROR,fatal:!1,url:g,reason:"no fragments found in level",level:typeof t.level=="number"?t.level:void 0});return}if(O===d.PlaylistContextType.MANIFEST){var I={attrs:new n.AttrList({}),bitrate:0,details:L,name:"",url:g};x.trigger(m.Events.MANIFEST_LOADED,{levels:[I],audioTracks:[],url:g,stats:l,networkDetails:S,sessionData:null})}if(l.parsing.end=performance.now(),L.needSidxRanges){var P,G=(P=L.fragments[0].initSegment)===null||P===void 0?void 0:P.url;this.load({url:G,isSidxRequest:!0,type:O,level:R,levelDetails:L,id:h,groupId:null,rangeStart:0,rangeEnd:2048,responseType:"arraybuffer",deliveryDirectives:null});return}t.levelDetails=L,this.handlePlaylistLoaded(s,l,t,S)},u.handleSidxRequest=function(s,l){var t=Object(b.parseSegmentIndex)(new Uint8Array(s.data));if(!t)return;var S=t.references,x=l.levelDetails;S.forEach(function(h,R){var O=h.info,g=x.fragments[R];g.byteRange.length===0&&g.setByteRange(String(1+O.end-O.start)+"@"+String(O.start)),g.initSegment&&g.initSegment.setByteRange(String(t.moovEndOffset)+"@0")})},u.handleManifestParsingError=function(s,l,t,S){this.hls.trigger(m.Events.ERROR,{type:y.ErrorTypes.NETWORK_ERROR,details:y.ErrorDetails.MANIFEST_PARSING_ERROR,fatal:l.type===d.PlaylistContextType.MANIFEST,url:s.url,reason:t,response:s,context:l,networkDetails:S})},u.handleNetworkError=function(s,l,t,S){t===void 0&&(t=!1),w.logger.warn("[playlist-loader]: A network "+(t?"timeout":"error")+" occurred while loading "+s.type+" level: "+s.level+" id: "+s.id+' group-id: "'+s.groupId+'"');var x=y.ErrorDetails.UNKNOWN,h=!1,R=this.getInternalLoader(s);switch(s.type){case d.PlaylistContextType.MANIFEST:x=t?y.ErrorDetails.MANIFEST_LOAD_TIMEOUT:y.ErrorDetails.MANIFEST_LOAD_ERROR,h=!0;break;case d.PlaylistContextType.LEVEL:x=t?y.ErrorDetails.LEVEL_LOAD_TIMEOUT:y.ErrorDetails.LEVEL_LOAD_ERROR,h=!1;break;case d.PlaylistContextType.AUDIO_TRACK:x=t?y.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:y.ErrorDetails.AUDIO_TRACK_LOAD_ERROR,h=!1;break;case d.PlaylistContextType.SUBTITLE_TRACK:x=t?y.ErrorDetails.SUBTITLE_TRACK_LOAD_TIMEOUT:y.ErrorDetails.SUBTITLE_LOAD_ERROR,h=!1;break}R&&this.resetInternalLoader(s.type);var O={type:y.ErrorTypes.NETWORK_ERROR,details:x,fatal:h,url:s.url,loader:R,context:s,networkDetails:l};S&&(O.response=S),this.hls.trigger(m.Events.ERROR,O)},u.handlePlaylistLoaded=function(s,l,t,S){var x=t.type,h=t.level,R=t.id,O=t.groupId,g=t.loader,_=t.levelDetails,E=t.deliveryDirectives;if(!(_!=null&&_.targetduration)){this.handleManifestParsingError(s,t,"invalid target duration",S);return}if(!g)return;_.live&&(g.getCacheAge&&(_.ageHeader=g.getCacheAge()||0),(!g.getCacheAge||isNaN(_.ageHeader))&&(_.ageHeader=0));switch(x){case d.PlaylistContextType.MANIFEST:case d.PlaylistContextType.LEVEL:this.hls.trigger(m.Events.LEVEL_LOADED,{details:_,level:h||0,id:R||0,stats:l,networkDetails:S,deliveryDirectives:E});break;case d.PlaylistContextType.AUDIO_TRACK:this.hls.trigger(m.Events.AUDIO_TRACK_LOADED,{details:_,id:R||0,groupId:O||"",stats:l,networkDetails:S,deliveryDirectives:E});break;case d.PlaylistContextType.SUBTITLE_TRACK:this.hls.trigger(m.Events.SUBTITLE_TRACK_LOADED,{details:_,id:R||0,groupId:O||"",stats:l,networkDetails:S,deliveryDirectives:E});break}},o}();v.default=i},"./src/polyfills/number.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"isFiniteNumber",function(){return M}),C.d(v,"MAX_SAFE_INTEGER",function(){return m});var M=Number.isFinite||function(y){return typeof y=="number"&&isFinite(y)},m=Number.MAX_SAFE_INTEGER||9007199254740991},"./src/remux/aac-helper.ts":function(N,v,C){"use strict";C.r(v);var M=function(){function m(){}return m.getSilentFrame=function(w,b){switch(w){case"mp4a.40.2":if(b===1)return new Uint8Array([0,200,0,128,35,128]);if(b===2)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(b===3)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(b===4)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(b===5)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(b===6)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(b===1)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(b===2)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(b===3)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]);break}return},m}();v.default=M},"./src/remux/mp4-generator.ts":function(N,v,C){"use strict";C.r(v);var M=Math.pow(2,32)-1,m=function(){function y(){}return y.init=function(){y.types={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],".mp3":[],mvex:[],mvhd:[],pasp:[],sdtp:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[],smhd:[]};var b;for(b in y.types)y.types.hasOwnProperty(b)&&(y.types[b]=[b.charCodeAt(0),b.charCodeAt(1),b.charCodeAt(2),b.charCodeAt(3)]);var p=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),d=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]);y.HDLR_TYPES={video:p,audio:d};var n=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),c=new Uint8Array([0,0,0,0,0,0,0,0]);y.STTS=y.STSC=y.STCO=c,y.STSZ=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),y.VMHD=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),y.SMHD=new Uint8Array([0,0,0,0,0,0,0,0]),y.STSD=new Uint8Array([0,0,0,0,0,0,0,1]);var r=new Uint8Array([105,115,111,109]),i=new Uint8Array([97,118,99,49]),o=new Uint8Array([0,0,0,1]);y.FTYP=y.box(y.types.ftyp,r,o,r,i),y.DINF=y.box(y.types.dinf,y.box(y.types.dref,n))},y.box=function(b){for(var p=8,d=arguments.length,n=new Array(d>1?d-1:0),c=1;c<d;c++)n[c-1]=arguments[c];for(var r=n.length,i=r;r--;)p+=n[r].byteLength;var o=new Uint8Array(p);for(o[0]=p>>24&255,o[1]=p>>16&255,o[2]=p>>8&255,o[3]=p&255,o.set(b,4),r=0,p=8;r<i;r++)o.set(n[r],p),p+=n[r].byteLength;return o},y.hdlr=function(b){return y.box(y.types.hdlr,y.HDLR_TYPES[b])},y.mdat=function(b){return y.box(y.types.mdat,b)},y.mdhd=function(b,p){p*=b;var d=Math.floor(p/(M+1)),n=Math.floor(p%(M+1));return y.box(y.types.mdhd,new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,b>>24&255,b>>16&255,b>>8&255,b&255,d>>24,d>>16&255,d>>8&255,d&255,n>>24,n>>16&255,n>>8&255,n&255,85,196,0,0]))},y.mdia=function(b){return y.box(y.types.mdia,y.mdhd(b.timescale,b.duration),y.hdlr(b.type),y.minf(b))},y.mfhd=function(b){return y.box(y.types.mfhd,new Uint8Array([0,0,0,0,b>>24,b>>16&255,b>>8&255,b&255]))},y.minf=function(b){return b.type==="audio"?y.box(y.types.minf,y.box(y.types.smhd,y.SMHD),y.DINF,y.stbl(b)):y.box(y.types.minf,y.box(y.types.vmhd,y.VMHD),y.DINF,y.stbl(b))},y.moof=function(b,p,d){return y.box(y.types.moof,y.mfhd(b),y.traf(d,p))},y.moov=function(b){for(var p=b.length,d=[];p--;)d[p]=y.trak(b[p]);return y.box.apply(null,[y.types.moov,y.mvhd(b[0].timescale,b[0].duration)].concat(d).concat(y.mvex(b)))},y.mvex=function(b){for(var p=b.length,d=[];p--;)d[p]=y.trex(b[p]);return y.box.apply(null,[y.types.mvex].concat(d))},y.mvhd=function(b,p){p*=b;var d=Math.floor(p/(M+1)),n=Math.floor(p%(M+1)),c=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,b>>24&255,b>>16&255,b>>8&255,b&255,d>>24,d>>16&255,d>>8&255,d&255,n>>24,n>>16&255,n>>8&255,n&255,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return y.box(y.types.mvhd,c)},y.sdtp=function(b){var p=b.samples||[],d=new Uint8Array(4+p.length),n,c;for(n=0;n<p.length;n++)c=p[n].flags,d[n+4]=c.dependsOn<<4|c.isDependedOn<<2|c.hasRedundancy;return y.box(y.types.sdtp,d)},y.stbl=function(b){return y.box(y.types.stbl,y.stsd(b),y.box(y.types.stts,y.STTS),y.box(y.types.stsc,y.STSC),y.box(y.types.stsz,y.STSZ),y.box(y.types.stco,y.STCO))},y.avc1=function(b){var p=[],d=[],n,c,r;for(n=0;n<b.sps.length;n++)c=b.sps[n],r=c.byteLength,p.push(r>>>8&255),p.push(r&255),p=p.concat(Array.prototype.slice.call(c));for(n=0;n<b.pps.length;n++)c=b.pps[n],r=c.byteLength,d.push(r>>>8&255),d.push(r&255),d=d.concat(Array.prototype.slice.call(c));var i=y.box(y.types.avcC,new Uint8Array([1,p[3],p[4],p[5],252|3,224|b.sps.length].concat(p).concat([b.pps.length]).concat(d))),o=b.width,u=b.height,f=b.pixelRatio[0],s=b.pixelRatio[1];return y.box(y.types.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,o>>8&255,o&255,u>>8&255,u&255,0,72,0,0,0,72,0,0,0,0,0,0,0,1,18,100,97,105,108,121,109,111,116,105,111,110,47,104,108,115,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),i,y.box(y.types.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192])),y.box(y.types.pasp,new Uint8Array([f>>24,f>>16&255,f>>8&255,f&255,s>>24,s>>16&255,s>>8&255,s&255])))},y.esds=function(b){var p=b.config.length;return new Uint8Array([0,0,0,0,3,23+p,0,1,0,4,15+p,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([p]).concat(b.config).concat([6,1,2]))},y.mp4a=function(b){var p=b.samplerate;return y.box(y.types.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,b.channelCount,0,16,0,0,0,0,p>>8&255,p&255,0,0]),y.box(y.types.esds,y.esds(b)))},y.mp3=function(b){var p=b.samplerate;return y.box(y.types[".mp3"],new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,b.channelCount,0,16,0,0,0,0,p>>8&255,p&255,0,0]))},y.stsd=function(b){return b.type==="audio"?!b.isAAC&&b.codec==="mp3"?y.box(y.types.stsd,y.STSD,y.mp3(b)):y.box(y.types.stsd,y.STSD,y.mp4a(b)):y.box(y.types.stsd,y.STSD,y.avc1(b))},y.tkhd=function(b){var p=b.id,d=b.duration*b.timescale,n=b.width,c=b.height,r=Math.floor(d/(M+1)),i=Math.floor(d%(M+1));return y.box(y.types.tkhd,new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3,p>>24&255,p>>16&255,p>>8&255,p&255,0,0,0,0,r>>24,r>>16&255,r>>8&255,r&255,i>>24,i>>16&255,i>>8&255,i&255,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,n>>8&255,n&255,0,0,c>>8&255,c&255,0,0]))},y.traf=function(b,p){var d=y.sdtp(b),n=b.id,c=Math.floor(p/(M+1)),r=Math.floor(p%(M+1));return y.box(y.types.traf,y.box(y.types.tfhd,new Uint8Array([0,0,0,0,n>>24,n>>16&255,n>>8&255,n&255])),y.box(y.types.tfdt,new Uint8Array([1,0,0,0,c>>24,c>>16&255,c>>8&255,c&255,r>>24,r>>16&255,r>>8&255,r&255])),y.trun(b,d.length+16+20+8+16+8+8),d)},y.trak=function(b){return b.duration=b.duration||4294967295,y.box(y.types.trak,y.tkhd(b),y.mdia(b))},y.trex=function(b){var p=b.id;return y.box(y.types.trex,new Uint8Array([0,0,0,0,p>>24,p>>16&255,p>>8&255,p&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))},y.trun=function(b,p){var d=b.samples||[],n=d.length,c=12+16*n,r=new Uint8Array(c),i,o,u,f,s,l;for(p+=8+c,r.set([0,0,15,1,n>>>24&255,n>>>16&255,n>>>8&255,n&255,p>>>24&255,p>>>16&255,p>>>8&255,p&255],0),i=0;i<n;i++)o=d[i],u=o.duration,f=o.size,s=o.flags,l=o.cts,r.set([u>>>24&255,u>>>16&255,u>>>8&255,u&255,f>>>24&255,f>>>16&255,f>>>8&255,f&255,s.isLeading<<2|s.dependsOn,s.isDependedOn<<6|s.hasRedundancy<<4|s.paddingValue<<1|s.isNonSync,s.degradPrio&240<<8,s.degradPrio&15,l>>>24&255,l>>>16&255,l>>>8&255,l&255],12+16*i);return y.box(y.types.trun,r)},y.initSegment=function(b){y.types||y.init();var p=y.moov(b),d=new Uint8Array(y.FTYP.byteLength+p.byteLength);return d.set(y.FTYP),d.set(p,y.FTYP.byteLength),d},y}();m.types=void 0,m.HDLR_TYPES=void 0,m.STTS=void 0,m.STSC=void 0,m.STCO=void 0,m.STSZ=void 0,m.VMHD=void 0,m.SMHD=void 0,m.STSD=void 0,m.FTYP=void 0,m.DINF=void 0,v.default=m},"./src/remux/mp4-remuxer.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return l}),C.d(v,"normalizePts",function(){return t});var M=C("./src/polyfills/number.ts"),m=C("./src/remux/aac-helper.ts"),y=C("./src/remux/mp4-generator.ts"),w=C("./src/events.ts"),b=C("./src/errors.ts"),p=C("./src/utils/logger.ts"),d=C("./src/types/loader.ts"),n=C("./src/utils/timescale-conversion.ts");function c(){return c=Object.assign||function(R){for(var O=1;O<arguments.length;O++){var g=arguments[O];for(var _ in g)Object.prototype.hasOwnProperty.call(g,_)&&(R[_]=g[_])}return R},c.apply(this,arguments)}var r=10*1e3,i=1024,o=1152,u=null,f=null,s=!1,l=function(){function R(g,_,E,T){if(T===void 0&&(T=""),this.observer=void 0,this.config=void 0,this.typeSupported=void 0,this.ISGenerated=!1,this._initPTS=void 0,this._initDTS=void 0,this.nextAvcDts=null,this.nextAudioPts=null,this.isAudioContiguous=!1,this.isVideoContiguous=!1,this.observer=g,this.config=_,this.typeSupported=E,this.ISGenerated=!1,u===null){var L=navigator.userAgent||"",I=L.match(/Chrome\/(\d+)/i);u=I?parseInt(I[1]):0}if(f===null){var P=navigator.userAgent.match(/Safari\/(\d+)/i);f=P?parseInt(P[1]):0}s=!!u&&u<75||!!f&&f<600}var O=R.prototype;return O.destroy=function(){},O.resetTimeStamp=function(_){p.logger.log("[mp4-remuxer]: initPTS & initDTS reset"),this._initPTS=this._initDTS=_},O.resetNextTimestamp=function(){p.logger.log("[mp4-remuxer]: reset next timestamp"),this.isVideoContiguous=!1,this.isAudioContiguous=!1},O.resetInitSegment=function(){p.logger.log("[mp4-remuxer]: ISGenerated flag reset"),this.ISGenerated=!1},O.getVideoStartPts=function(_){var E=!1,T=_.reduce(function(L,I){var P=I.pts-L;return P<-4294967296?(E=!0,t(L,I.pts)):P>0?L:I.pts},_[0].pts);return E&&p.logger.debug("PTS rollover detected"),T},O.remux=function(_,E,T,L,I,P,G,W){var H,z,B,k,K,Y,ne=I,oe=I,_e=_.pid>-1,xe=E.pid>-1,le=E.samples.length,me=_.samples.length>0,de=le>1,ae=(!_e||me)&&(!xe||de)||this.ISGenerated||G;if(ae){this.ISGenerated||(B=this.generateIS(_,E,I));var ie=this.isVideoContiguous,q=-1;if(de&&(q=S(E.samples),!ie&&this.config.forceKeyFrameOnDiscontinuity))if(Y=!0,q>0){p.logger.warn("[mp4-remuxer]: Dropped "+q+" out of "+le+" video samples due to a missing keyframe");var ue=this.getVideoStartPts(E.samples);E.samples=E.samples.slice(q),E.dropped+=q,oe+=(E.samples[0].pts-ue)/(E.timescale||9e4)}else q===-1&&(p.logger.warn("[mp4-remuxer]: No keyframe found out of "+le+" video samples"),Y=!1);if(this.ISGenerated){if(me&&de){var Z=this.getVideoStartPts(E.samples),ee=t(_.samples[0].pts,Z)-Z,Ee=ee/E.inputTimeScale;ne+=Math.max(0,Ee),oe+=Math.max(0,-Ee)}if(me){if(_.samplerate||(p.logger.warn("[mp4-remuxer]: regenerate InitSegment as audio detected"),B=this.generateIS(_,E,I)),z=this.remuxAudio(_,ne,this.isAudioContiguous,P,xe||de||W===d.PlaylistLevelType.AUDIO?oe:void 0),de){var te=z?z.endPTS-z.startPTS:0;E.inputTimeScale||(p.logger.warn("[mp4-remuxer]: regenerate InitSegment as video detected"),B=this.generateIS(_,E,I)),H=this.remuxVideo(E,oe,ie,te)}}else de&&(H=this.remuxVideo(E,oe,ie,0));H&&(H.firstKeyFrame=q,H.independent=q!==-1)}}return this.ISGenerated&&(T.samples.length&&(K=this.remuxID3(T,I)),L.samples.length&&(k=this.remuxText(L,I))),{audio:z,video:H,initSegment:B,independent:Y,text:k,id3:K}},O.generateIS=function(_,E,T){var L=_.samples,I=E.samples,P=this.typeSupported,G={},W=!Object(M.isFiniteNumber)(this._initPTS),H="audio/mp4",z,B,k;if(W&&(z=B=Infinity),_.config&&L.length&&(_.timescale=_.samplerate,_.isAAC||(P.mpeg?(H="audio/mpeg",_.codec=""):P.mp3&&(_.codec="mp3")),G.audio={id:"audio",container:H,codec:_.codec,initSegment:!_.isAAC&&P.mpeg?new Uint8Array(0):y.default.initSegment([_]),metadata:{channelCount:_.channelCount}},W&&(k=_.inputTimeScale,z=B=L[0].pts-Math.round(k*T))),E.sps&&E.pps&&I.length&&(E.timescale=E.inputTimeScale,G.video={id:"main",container:"video/mp4",codec:E.codec,initSegment:y.default.initSegment([E]),metadata:{width:E.width,height:E.height}},W)){k=E.inputTimeScale;var K=this.getVideoStartPts(I),Y=Math.round(k*T);B=Math.min(B,t(I[0].dts,K)-Y),z=Math.min(z,K-Y)}if(Object.keys(G).length)return this.ISGenerated=!0,W&&(this._initPTS=z,this._initDTS=B),{tracks:G,initPTS:z,timescale:k}},O.remuxVideo=function(_,E,T,L){var I=_.inputTimeScale,P=_.samples,G=[],W=P.length,H=this._initPTS,z=this.nextAvcDts,B=8,k,K,Y,ne=Number.POSITIVE_INFINITY,oe=Number.NEGATIVE_INFINITY,_e=0,xe=!1;if(!T||z===null){var le=E*I,me=P[0].pts-t(P[0].dts,P[0].pts);z=le-me}for(var de=0;de<W;de++){var ae=P[de];if(ae.pts=t(ae.pts-H,z),ae.dts=t(ae.dts-H,z),ae.dts>ae.pts){var ie=9e4*.2;_e=Math.max(Math.min(_e,ae.pts-ae.dts),-1*ie)}ae.dts<P[de>0?de-1:de].dts&&(xe=!0)}xe&&P.sort(function(Er,rr){var xt=Er.dts-rr.dts,kr=Er.pts-rr.pts;return xt||kr}),K=P[0].dts,Y=P[P.length-1].dts;var q=Math.round((Y-K)/(W-1));if(_e<0){if(_e<q*-2){p.logger.warn("PTS < DTS detected in video samples, offsetting DTS from PTS by "+Object(n.toMsFromMpegTsClock)(-q,!0)+" ms");for(var ue=_e,Z=0;Z<W;Z++)P[Z].dts=ue=Math.max(ue,P[Z].pts-q),P[Z].pts=Math.max(ue,P[Z].pts)}else{p.logger.warn("PTS < DTS detected in video samples, shifting DTS by "+Object(n.toMsFromMpegTsClock)(_e,!0)+" ms to overcome this issue");for(var ee=0;ee<W;ee++)P[ee].dts=P[ee].dts+_e}K=P[0].dts}if(T){var Ee=K-z,te=Ee>q,J=Ee<-1;if(te||J){te?p.logger.warn("AVC: "+Object(n.toMsFromMpegTsClock)(Ee,!0)+" ms ("+Ee+"dts) hole between fragments detected, filling it"):p.logger.warn("AVC: "+Object(n.toMsFromMpegTsClock)(-Ee,!0)+" ms ("+Ee+"dts) overlapping between fragments detected"),K=z;var X=P[0].pts-Ee;P[0].dts=K,P[0].pts=X,p.logger.log("Video: First PTS/DTS adjusted: "+Object(n.toMsFromMpegTsClock)(X,!0)+"/"+Object(n.toMsFromMpegTsClock)(K,!0)+", delta: "+Object(n.toMsFromMpegTsClock)(Ee,!0)+" ms")}}s&&(K=Math.max(0,K));for(var $=0,ge=0,fe=0;fe<W;fe++){for(var Te=P[fe],ze=Te.units,Xe=ze.length,Ye=0,rt=0;rt<Xe;rt++)Ye+=ze[rt].data.length;ge+=Ye,$+=Xe,Te.length=Ye,Te.dts=Math.max(Te.dts,K),Te.pts=Math.max(Te.pts,Te.dts,0),ne=Math.min(Te.pts,ne),oe=Math.max(Te.pts,oe)}Y=P[W-1].dts;var at=ge+4*$+8,ot;try{ot=new Uint8Array(at)}catch(Er){this.observer.emit(w.Events.ERROR,w.Events.ERROR,{type:b.ErrorTypes.MUX_ERROR,details:b.ErrorDetails.REMUX_ALLOC_ERROR,fatal:!1,bytes:at,reason:"fail allocating video mdat "+at});return}var Pe=new DataView(ot.buffer);Pe.setUint32(0,at),ot.set(y.default.types.mdat,4);for(var Se=0;Se<W;Se++){for(var Je=P[Se],nt=Je.units,We=0,et=0,Me=nt.length;et<Me;et++){var Ce=nt[et],Re=Ce.data,pe=Ce.data.byteLength;Pe.setUint32(B,pe),B+=4,ot.set(Re,B),B+=pe,We+=4+pe}if(Se<W-1)k=P[Se+1].dts-Je.dts;else{var ye=this.config,we=Je.dts-P[Se>0?Se-1:Se].dts;if(ye.stretchShortVideoTrack&&this.nextAudioPts!==null){var Ie=Math.floor(ye.maxBufferHole*I),ke=(L?ne+L*I:this.nextAudioPts)-Je.pts;ke>Ie?(k=ke-we,k<0&&(k=we),p.logger.log("[mp4-remuxer]: It is approximately "+ke/90+" ms to the next segment; using duration "+k/90+" ms for the last video frame.")):k=we}else k=we}var Ve=Math.round(Je.pts-Je.dts);G.push(new x(Je.key,k,We,Ve))}if(G.length&&u&&u<70){var ut=G[0].flags;ut.dependsOn=2,ut.isNonSync=0}console.assert(k!==void 0,"mp4SampleDuration must be computed"),this.nextAvcDts=z=Y+k,this.isVideoContiguous=!0;var ct=y.default.moof(_.sequenceNumber++,K,c({},_,{samples:G})),Lt="video",Dt={data1:ct,data2:ot,startPTS:ne/I,endPTS:(oe+k)/I,startDTS:K/I,endDTS:z/I,type:Lt,hasAudio:!1,hasVideo:!0,nb:G.length,dropped:_.dropped};return _.samples=[],_.dropped=0,console.assert(ot.length,"MDAT length must not be zero"),Dt},O.remuxAudio=function(_,E,T,L,I){var P=_.inputTimeScale,G=_.samplerate?_.samplerate:P,W=P/G,H=_.isAAC?i:o,z=H*W,B=this._initPTS,k=!_.isAAC&&this.typeSupported.mpeg,K=[],Y=_.samples,ne=k?0:8,oe=this.nextAudioPts||-1,_e=E*P;if(this.isAudioContiguous=T=T||Y.length&&oe>0&&(L&&Math.abs(_e-oe)<9e3||Math.abs(t(Y[0].pts-B,_e)-oe)<20*z),Y.forEach(function(Re){Re.pts=t(Re.pts-B,_e)}),!T||oe<0){if(Y=Y.filter(function(Re){return Re.pts>=0}),!Y.length)return;I===0?oe=0:L?oe=Math.max(0,_e):oe=Y[0].pts}if(_.isAAC)for(var xe=I!==void 0,le=this.config.maxAudioFramesDrift,me=0,de=oe;me<Y.length;me++){var ae=Y[me],ie=ae.pts,q=ie-de,ue=Math.abs(1e3*q/P);if(q<=-le*z&&xe)me===0&&(p.logger.warn("Audio frame @ "+(ie/P).toFixed(3)+"s overlaps nextAudioPts by "+Math.round(1e3*q/P)+" ms."),this.nextAudioPts=oe=de=ie);else if(q>=le*z&&ue<r&&xe){var Z=Math.round(q/z);de=ie-Z*z,de<0&&(Z--,de+=z),me===0&&(this.nextAudioPts=oe=de),p.logger.warn("[mp4-remuxer]: Injecting "+Z+" audio frame @ "+(de/P).toFixed(3)+"s due to "+Math.round(1e3*q/P)+" ms gap.");for(var ee=0;ee<Z;ee++){var Ee=Math.max(de,0),te=m.default.getSilentFrame(_.manifestCodec||_.codec,_.channelCount);te||(p.logger.log("[mp4-remuxer]: Unable to get silent frame for given audio codec; duplicating last frame instead."),te=ae.unit.subarray()),Y.splice(me,0,{unit:te,pts:Ee}),de+=z,me++}}ae.pts=de,de+=z}for(var J=null,X=null,$,ge=0,fe=Y.length;fe--;)ge+=Y[fe].unit.byteLength;for(var Te=0,ze=Y.length;Te<ze;Te++){var Xe=Y[Te],Ye=Xe.unit,rt=Xe.pts;if(X!==null){var at=K[Te-1];at.duration=Math.round((rt-X)/W)}else if(T&&_.isAAC&&(rt=oe),J=rt,ge>0){ge+=ne;try{$=new Uint8Array(ge)}catch(Re){this.observer.emit(w.Events.ERROR,w.Events.ERROR,{type:b.ErrorTypes.MUX_ERROR,details:b.ErrorDetails.REMUX_ALLOC_ERROR,fatal:!1,bytes:ge,reason:"fail allocating audio mdat "+ge});return}if(!k){var ot=new DataView($.buffer);ot.setUint32(0,ge),$.set(y.default.types.mdat,4)}}else return;$.set(Ye,ne);var Pe=Ye.byteLength;ne+=Pe,K.push(new x(!0,H,Pe,0)),X=rt}var Se=K.length;if(!Se)return;var Je=K[K.length-1];this.nextAudioPts=oe=X+W*Je.duration;var nt=k?new Uint8Array(0):y.default.moof(_.sequenceNumber++,J/W,c({},_,{samples:K}));_.samples=[];var We=J/P,et=oe/P,Me="audio",Ce={data1:nt,data2:$,startPTS:We,endPTS:et,startDTS:We,endDTS:et,type:Me,hasAudio:!0,hasVideo:!1,nb:Se};return this.isAudioContiguous=!0,console.assert($.length,"MDAT length must not be zero"),Ce},O.remuxEmptyAudio=function(_,E,T,L){var I=_.inputTimeScale,P=_.samplerate?_.samplerate:I,G=I/P,W=this.nextAudioPts,H=(W!==null?W:L.startDTS*I)+this._initDTS,z=L.endDTS*I+this._initDTS,B=G*i,k=Math.ceil((z-H)/B),K=m.default.getSilentFrame(_.manifestCodec||_.codec,_.channelCount);if(p.logger.warn("[mp4-remuxer]: remux empty Audio"),!K){p.logger.trace("[mp4-remuxer]: Unable to remuxEmptyAudio since we were unable to get a silent frame for given audio codec");return}for(var Y=[],ne=0;ne<k;ne++){var oe=H+ne*B;Y.push({unit:K,pts:oe,dts:oe})}return _.samples=Y,this.remuxAudio(_,E,T,!1)},O.remuxID3=function(_,E){var T=_.samples.length;if(!T)return;for(var L=_.inputTimeScale,I=this._initPTS,P=this._initDTS,G=0;G<T;G++){var W=_.samples[G];W.pts=t(W.pts-I,E*L)/L,W.dts=t(W.dts-P,E*L)/L}var H=_.samples;return _.samples=[],{samples:H}},O.remuxText=function(_,E){var T=_.samples.length;if(!T)return;for(var L=_.inputTimeScale,I=this._initPTS,P=0;P<T;P++){var G=_.samples[P];G.pts=t(G.pts-I,E*L)/L}_.samples.sort(function(H,z){return H.pts-z.pts});var W=_.samples;return _.samples=[],{samples:W}},R}();function t(R,O){var g;if(O===null)return R;for(O<R?g=-8589934592:g=8589934592;Math.abs(R-O)>4294967296;)R+=g;return R}function S(R){for(var O=0;O<R.length;O++)if(R[O].key)return O;return-1}var x=function(O,g,_,E){this.size=void 0,this.duration=void 0,this.cts=void 0,this.flags=void 0,this.duration=g,this.size=_,this.cts=E,this.flags=new h(O)},h=function(O){this.isLeading=0,this.isDependedOn=0,this.hasRedundancy=0,this.degradPrio=0,this.dependsOn=1,this.isNonSync=1,this.dependsOn=O?2:1,this.isNonSync=O?0:1}},"./src/remux/passthrough-remuxer.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/polyfills/number.ts"),m=C("./src/utils/mp4-tools.ts"),y=C("./src/loader/fragment.ts"),w=C("./src/utils/logger.ts"),b=function(){function n(){this.emitInitSegment=!1,this.audioCodec=void 0,this.videoCodec=void 0,this.initData=void 0,this.initPTS=void 0,this.initTracks=void 0,this.lastEndDTS=null}var c=n.prototype;return c.destroy=function(){},c.resetTimeStamp=function(i){this.initPTS=i,this.lastEndDTS=null},c.resetNextTimestamp=function(){this.lastEndDTS=null},c.resetInitSegment=function(i,o,u){this.audioCodec=o,this.videoCodec=u,this.generateInitSegment(i),this.emitInitSegment=!0},c.generateInitSegment=function(i){var o=this.audioCodec,u=this.videoCodec;if(!i||!i.byteLength){this.initTracks=void 0,this.initData=void 0;return}var f=this.initData=Object(m.parseInitSegment)(i);o||(o=d(f.audio,y.ElementaryStreamTypes.AUDIO)),u||(u=d(f.video,y.ElementaryStreamTypes.VIDEO));var s={};f.audio&&f.video?s.audiovideo={container:"video/mp4",codec:o+","+u,initSegment:i,id:"main"}:f.audio?s.audio={container:"audio/mp4",codec:o,initSegment:i,id:"audio"}:f.video?s.video={container:"video/mp4",codec:u,initSegment:i,id:"main"}:w.logger.warn("[passthrough-remuxer.ts]: initSegment does not contain moov or trak boxes."),this.initTracks=s},c.remux=function(i,o,u,f,s){var l=this.initPTS,t=this.lastEndDTS,S={audio:void 0,video:void 0,text:f,id3:u,initSegment:void 0};Object(M.isFiniteNumber)(t)||(t=this.lastEndDTS=s||0);var x=o.samples;if(!x||!x.length)return S;var h={initPTS:void 0,timescale:1},R=this.initData;if((!R||!R.length)&&(this.generateInitSegment(x),R=this.initData),!R||!R.length)return w.logger.warn("[passthrough-remuxer.ts]: Failed to generate initSegment."),S;this.emitInitSegment&&(h.tracks=this.initTracks,this.emitInitSegment=!1),Object(M.isFiniteNumber)(l)||(this.initPTS=h.initPTS=l=p(R,x,t));var O=Object(m.getDuration)(x,R),g=t,_=O+g;Object(m.offsetStartDTS)(R,x,l),O>0?this.lastEndDTS=_:(w.logger.warn("Duration parsed from mp4 should be greater than zero"),this.resetNextTimestamp());var E=!!R.audio,T=!!R.video,L="";E&&(L+="audio"),T&&(L+="video");var I={data1:x,startPTS:g,startDTS:g,endPTS:_,endDTS:_,type:L,hasAudio:E,hasVideo:T,nb:1,dropped:0};return S.audio=I.type==="audio"?I:void 0,S.video=I.type!=="audio"?I:void 0,S.text=f,S.id3=u,S.initSegment=h,S},n}(),p=function(c,r,i){return Object(m.getStartDTS)(c,r)-i};function d(n,c){var r=n==null?void 0:n.codec;return r&&r.length>4?r:r==="hvc1"?"hvc1.1.c.L120.90":r==="av01"?"av01.0.04M.08":r==="avc1"||c===y.ElementaryStreamTypes.VIDEO?"avc1.42e01e":"mp4a.40.5"}v.default=b},"./src/task-loop.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return M});var M=function(){function m(){this._boundTick=void 0,this._tickTimer=null,this._tickInterval=null,this._tickCallCount=0,this._boundTick=this.tick.bind(this)}var y=m.prototype;return y.destroy=function(){this.onHandlerDestroying(),this.onHandlerDestroyed()},y.onHandlerDestroying=function(){this.clearNextTick(),this.clearInterval()},y.onHandlerDestroyed=function(){},y.hasInterval=function(){return!!this._tickInterval},y.hasNextTick=function(){return!!this._tickTimer},y.setInterval=function(b){return this._tickInterval?!1:(this._tickInterval=self.setInterval(this._boundTick,b),!0)},y.clearInterval=function(){return this._tickInterval?(self.clearInterval(this._tickInterval),this._tickInterval=null,!0):!1},y.clearNextTick=function(){return this._tickTimer?(self.clearTimeout(this._tickTimer),this._tickTimer=null,!0):!1},y.tick=function(){this._tickCallCount++,this._tickCallCount===1&&(this.doTick(),this._tickCallCount>1&&this.tickImmediate(),this._tickCallCount=0)},y.tickImmediate=function(){this.clearNextTick(),this._tickTimer=self.setTimeout(this._boundTick,0)},y.doTick=function(){},m}()},"./src/types/cmcd.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"CMCDVersion",function(){return M}),C.d(v,"CMCDObjectType",function(){return m}),C.d(v,"CMCDStreamingFormat",function(){return y}),C.d(v,"CMCDStreamType",function(){return w});var M=1,m;(function(b){b.MANIFEST="m",b.AUDIO="a",b.VIDEO="v",b.MUXED="av",b.INIT="i",b.CAPTION="c",b.TIMED_TEXT="tt",b.KEY="k",b.OTHER="o"})(m||(m={}));var y;(function(b){b.DASH="d",b.HLS="h",b.SMOOTH="s",b.OTHER="o"})(y||(y={}));var w;(function(b){b.VOD="v",b.LIVE="l"})(w||(w={}))},"./src/types/level.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"HlsSkip",function(){return y}),C.d(v,"getSkipValue",function(){return w}),C.d(v,"HlsUrlParameters",function(){return b}),C.d(v,"Level",function(){return p});function M(d,n){for(var c=0;c<n.length;c++){var r=n[c];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(d,r.key,r)}}function m(d,n,c){return n&&M(d.prototype,n),c&&M(d,c),d}var y;(function(d){d.No="",d.Yes="YES",d.v2="v2"})(y||(y={}));function w(d,n){var c=d.canSkipUntil,r=d.canSkipDateRanges,i=d.endSN,o=n!==void 0?n-i:0;return c&&o<c?r?y.v2:y.Yes:y.No}var b=function(){function d(c,r,i){this.msn=void 0,this.part=void 0,this.skip=void 0,this.msn=c,this.part=r,this.skip=i}var n=d.prototype;return n.addDirectives=function(r){var i=new self.URL(r);return this.msn!==void 0&&i.searchParams.set("_HLS_msn",this.msn.toString()),this.part!==void 0&&i.searchParams.set("_HLS_part",this.part.toString()),this.skip&&i.searchParams.set("_HLS_skip",this.skip),i.toString()},d}(),p=function(){function d(n){this.attrs=void 0,this.audioCodec=void 0,this.bitrate=void 0,this.codecSet=void 0,this.height=void 0,this.id=void 0,this.name=void 0,this.videoCodec=void 0,this.width=void 0,this.unknownCodecs=void 0,this.audioGroupIds=void 0,this.details=void 0,this.fragmentError=0,this.loadError=0,this.loaded=void 0,this.realBitrate=0,this.textGroupIds=void 0,this.url=void 0,this._urlId=0,this.url=[n.url],this.attrs=n.attrs,this.bitrate=n.bitrate,n.details&&(this.details=n.details),this.id=n.id||0,this.name=n.name,this.width=n.width||0,this.height=n.height||0,this.audioCodec=n.audioCodec,this.videoCodec=n.videoCodec,this.unknownCodecs=n.unknownCodecs,this.codecSet=[n.videoCodec,n.audioCodec].filter(function(c){return c}).join(",").replace(/\.[^.,]+/g,"")}return m(d,[{key:"maxBitrate",get:function(){return Math.max(this.realBitrate,this.bitrate)}},{key:"uri",get:function(){return this.url[this._urlId]||""}},{key:"urlId",get:function(){return this._urlId},set:function(c){var r=c%this.url.length;this._urlId!==r&&(this.details=void 0,this._urlId=r)}}]),d}()},"./src/types/loader.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"PlaylistContextType",function(){return M}),C.d(v,"PlaylistLevelType",function(){return m});var M;(function(y){y.MANIFEST="manifest",y.LEVEL="level",y.AUDIO_TRACK="audioTrack",y.SUBTITLE_TRACK="subtitleTrack"})(M||(M={}));var m;(function(y){y.MAIN="main",y.AUDIO="audio",y.SUBTITLE="subtitle"})(m||(m={}))},"./src/types/transmuxer.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"ChunkMetadata",function(){return M});var M=function(w,b,p,d,n,c){d===void 0&&(d=0),n===void 0&&(n=-1),c===void 0&&(c=!1),this.level=void 0,this.sn=void 0,this.part=void 0,this.id=void 0,this.size=void 0,this.partial=void 0,this.transmuxing=m(),this.buffering={audio:m(),video:m(),audiovideo:m()},this.level=w,this.sn=b,this.id=p,this.size=d,this.part=n,this.partial=c};function m(){return{start:0,executeStart:0,executeEnd:0,end:0}}},"./src/utils/attr-list.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"AttrList",function(){return y});var M=/^(\d+)x(\d+)$/,m=/\s*(.+?)\s*=((?:\".*?\")|.*?)(?:,|$)/g,y=function(){function w(p){typeof p=="string"&&(p=w.parseAttrList(p));for(var d in p)p.hasOwnProperty(d)&&(this[d]=p[d])}var b=w.prototype;return b.decimalInteger=function(d){var n=parseInt(this[d],10);return n>Number.MAX_SAFE_INTEGER?Infinity:n},b.hexadecimalInteger=function(d){if(this[d]){var n=(this[d]||"0x").slice(2);n=(n.length&1?"0":"")+n;for(var c=new Uint8Array(n.length/2),r=0;r<n.length/2;r++)c[r]=parseInt(n.slice(r*2,r*2+2),16);return c}else return null},b.hexadecimalIntegerAsNumber=function(d){var n=parseInt(this[d],16);return n>Number.MAX_SAFE_INTEGER?Infinity:n},b.decimalFloatingPoint=function(d){return parseFloat(this[d])},b.optionalFloat=function(d,n){var c=this[d];return c?parseFloat(c):n},b.enumeratedString=function(d){return this[d]},b.bool=function(d){return this[d]==="YES"},b.decimalResolution=function(d){var n=M.exec(this[d]);return n===null?void 0:{width:parseInt(n[1],10),height:parseInt(n[2],10)}},w.parseAttrList=function(d){var n,c={},r='"';for(m.lastIndex=0;(n=m.exec(d))!==null;){var i=n[2];i.indexOf(r)===0&&i.lastIndexOf(r)===i.length-1&&(i=i.slice(1,-1)),c[n[1]]=i}return c},w}()},"./src/utils/binary-search.ts":function(N,v,C){"use strict";C.r(v);var M={search:function(y,w){for(var b=0,p=y.length-1,d=null,n=null;b<=p;){d=(b+p)/2|0,n=y[d];var c=w(n);if(c>0)b=d+1;else if(c<0)p=d-1;else return n}return null}};v.default=M},"./src/utils/buffer-helper.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"BufferHelper",function(){return y});var M=C("./src/utils/logger.ts"),m={length:0,start:function(){return 0},end:function(){return 0}},y=function(){function w(){}return w.isBuffered=function(p,d){try{if(p){for(var n=w.getBuffered(p),c=0;c<n.length;c++)if(d>=n.start(c)&&d<=n.end(c))return!0}}catch(r){}return!1},w.bufferInfo=function(p,d,n){try{if(p){var c=w.getBuffered(p),r=[],i;for(i=0;i<c.length;i++)r.push({start:c.start(i),end:c.end(i)});return this.bufferedInfo(r,d,n)}}catch(o){}return{len:0,start:d,end:d,nextStart:void 0}},w.bufferedInfo=function(p,d,n){d=Math.max(0,d),p.sort(function(h,R){var O=h.start-R.start;return O||R.end-h.end});var c=[];if(n)for(var r=0;r<p.length;r++){var i=c.length;if(i){var o=c[i-1].end;p[r].start-o<n?p[r].end>o&&(c[i-1].end=p[r].end):c.push(p[r])}else c.push(p[r])}else c=p;for(var u=0,f,s=d,l=d,t=0;t<c.length;t++){var S=c[t].start,x=c[t].end;if(d+n>=S&&d<x)s=S,l=x,u=l-d;else if(d+n<S){f=S;break}}return{len:u,start:s||0,end:l||0,nextStart:f}},w.getBuffered=function(p){try{return p.buffered}catch(d){return M.logger.log("failed to get media.buffered",d),m}},w}()},"./src/utils/cea-608-parser.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"Row",function(){return l}),C.d(v,"CaptionScreen",function(){return t});var M=C("./src/utils/logger.ts"),m={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,128:174,129:176,130:189,131:191,132:8482,133:162,134:163,135:9834,136:224,137:32,138:232,139:226,140:234,141:238,142:244,143:251,144:193,145:201,146:211,147:218,148:220,149:252,150:8216,151:161,152:42,153:8217,154:9473,155:169,156:8480,157:8226,158:8220,159:8221,160:192,161:194,162:199,163:200,164:202,165:203,166:235,167:206,168:207,169:239,170:212,171:217,172:249,173:219,174:171,175:187,176:195,177:227,178:205,179:204,180:236,181:210,182:242,183:213,184:245,185:123,186:125,187:92,188:94,189:95,190:124,191:8764,192:196,193:228,194:214,195:246,196:223,197:165,198:164,199:9475,200:197,201:229,202:216,203:248,204:9487,205:9491,206:9495,207:9499},y=function(_){var E=_;return m.hasOwnProperty(_)&&(E=m[_]),String.fromCharCode(E)},w=15,b=100,p={17:1,18:3,21:5,22:7,23:9,16:11,19:12,20:14},d={17:2,18:4,21:6,22:8,23:10,19:13,20:15},n={25:1,26:3,29:5,30:7,31:9,24:11,27:12,28:14},c={25:2,26:4,29:6,30:8,31:10,27:13,28:15},r=["white","green","blue","cyan","red","yellow","magenta","black","transparent"],i;(function(g){g[g.ERROR=0]="ERROR",g[g.TEXT=1]="TEXT",g[g.WARNING=2]="WARNING",g[g.INFO=2]="INFO",g[g.DEBUG=3]="DEBUG",g[g.DATA=3]="DATA"})(i||(i={}));var o=function(){function g(){this.time=null,this.verboseLevel=i.ERROR}var _=g.prototype;return _.log=function(T,L){this.verboseLevel>=T&&M.logger.log(this.time+" ["+T+"] "+L)},g}(),u=function(_){for(var E=[],T=0;T<_.length;T++)E.push(_[T].toString(16));return E},f=function(){function g(E,T,L,I,P){this.foreground=void 0,this.underline=void 0,this.italics=void 0,this.background=void 0,this.flash=void 0,this.foreground=E||"white",this.underline=T||!1,this.italics=L||!1,this.background=I||"black",this.flash=P||!1}var _=g.prototype;return _.reset=function(){this.foreground="white",this.underline=!1,this.italics=!1,this.background="black",this.flash=!1},_.setStyles=function(T){for(var L=["foreground","underline","italics","background","flash"],I=0;I<L.length;I++){var P=L[I];T.hasOwnProperty(P)&&(this[P]=T[P])}},_.isDefault=function(){return this.foreground==="white"&&!this.underline&&!this.italics&&this.background==="black"&&!this.flash},_.equals=function(T){return this.foreground===T.foreground&&this.underline===T.underline&&this.italics===T.italics&&this.background===T.background&&this.flash===T.flash},_.copy=function(T){this.foreground=T.foreground,this.underline=T.underline,this.italics=T.italics,this.background=T.background,this.flash=T.flash},_.toString=function(){return"color="+this.foreground+", underline="+this.underline+", italics="+this.italics+", background="+this.background+", flash="+this.flash},g}(),s=function(){function g(E,T,L,I,P,G){this.uchar=void 0,this.penState=void 0,this.uchar=E||" ",this.penState=new f(T,L,I,P,G)}var _=g.prototype;return _.reset=function(){this.uchar=" ",this.penState.reset()},_.setChar=function(T,L){this.uchar=T,this.penState.copy(L)},_.setPenState=function(T){this.penState.copy(T)},_.equals=function(T){return this.uchar===T.uchar&&this.penState.equals(T.penState)},_.copy=function(T){this.uchar=T.uchar,this.penState.copy(T.penState)},_.isEmpty=function(){return this.uchar===" "&&this.penState.isDefault()},g}(),l=function(){function g(E){this.chars=void 0,this.pos=void 0,this.currPenState=void 0,this.cueStartTime=void 0,this.logger=void 0,this.chars=[];for(var T=0;T<b;T++)this.chars.push(new s);this.logger=E,this.pos=0,this.currPenState=new f}var _=g.prototype;return _.equals=function(T){for(var L=!0,I=0;I<b;I++)if(!this.chars[I].equals(T.chars[I])){L=!1;break}return L},_.copy=function(T){for(var L=0;L<b;L++)this.chars[L].copy(T.chars[L])},_.isEmpty=function(){for(var T=!0,L=0;L<b;L++)if(!this.chars[L].isEmpty()){T=!1;break}return T},_.setCursor=function(T){this.pos!==T&&(this.pos=T),this.pos<0?(this.logger.log(i.DEBUG,"Negative cursor position "+this.pos),this.pos=0):this.pos>b&&(this.logger.log(i.DEBUG,"Too large cursor position "+this.pos),this.pos=b)},_.moveCursor=function(T){var L=this.pos+T;if(T>1)for(var I=this.pos+1;I<L+1;I++)this.chars[I].setPenState(this.currPenState);this.setCursor(L)},_.backSpace=function(){this.moveCursor(-1),this.chars[this.pos].setChar(" ",this.currPenState)},_.insertChar=function(T){T>=144&&this.backSpace();var L=y(T);if(this.pos>=b){this.logger.log(i.ERROR,"Cannot insert "+T.toString(16)+" ("+L+") at position "+this.pos+". Skipping it!");return}this.chars[this.pos].setChar(L,this.currPenState),this.moveCursor(1)},_.clearFromPos=function(T){var L;for(L=T;L<b;L++)this.chars[L].reset()},_.clear=function(){this.clearFromPos(0),this.pos=0,this.currPenState.reset()},_.clearToEndOfRow=function(){this.clearFromPos(this.pos)},_.getTextString=function(){for(var T=[],L=!0,I=0;I<b;I++){var P=this.chars[I].uchar;P!==" "&&(L=!1),T.push(P)}return L?"":T.join("")},_.setPenStyles=function(T){this.currPenState.setStyles(T);var L=this.chars[this.pos];L.setPenState(this.currPenState)},g}(),t=function(){function g(E){this.rows=void 0,this.currRow=void 0,this.nrRollUpRows=void 0,this.lastOutputScreen=void 0,this.logger=void 0,this.rows=[];for(var T=0;T<w;T++)this.rows.push(new l(E));this.logger=E,this.currRow=w-1,this.nrRollUpRows=null,this.lastOutputScreen=null,this.reset()}var _=g.prototype;return _.reset=function(){for(var T=0;T<w;T++)this.rows[T].clear();this.currRow=w-1},_.equals=function(T){for(var L=!0,I=0;I<w;I++)if(!this.rows[I].equals(T.rows[I])){L=!1;break}return L},_.copy=function(T){for(var L=0;L<w;L++)this.rows[L].copy(T.rows[L])},_.isEmpty=function(){for(var T=!0,L=0;L<w;L++)if(!this.rows[L].isEmpty()){T=!1;break}return T},_.backSpace=function(){var T=this.rows[this.currRow];T.backSpace()},_.clearToEndOfRow=function(){var T=this.rows[this.currRow];T.clearToEndOfRow()},_.insertChar=function(T){var L=this.rows[this.currRow];L.insertChar(T)},_.setPen=function(T){var L=this.rows[this.currRow];L.setPenStyles(T)},_.moveCursor=function(T){var L=this.rows[this.currRow];L.moveCursor(T)},_.setCursor=function(T){this.logger.log(i.INFO,"setCursor: "+T);var L=this.rows[this.currRow];L.setCursor(T)},_.setPAC=function(T){this.logger.log(i.INFO,"pacData = "+JSON.stringify(T));var L=T.row-1;if(this.nrRollUpRows&&L<this.nrRollUpRows-1&&(L=this.nrRollUpRows-1),this.nrRollUpRows&&this.currRow!==L){for(var I=0;I<w;I++)this.rows[I].clear();var P=this.currRow+1-this.nrRollUpRows,G=this.lastOutputScreen;if(G){var W=G.rows[P].cueStartTime,H=this.logger.time;if(W&&H!==null&&W<H)for(var z=0;z<this.nrRollUpRows;z++)this.rows[L-this.nrRollUpRows+z+1].copy(G.rows[P+z])}}this.currRow=L;var B=this.rows[this.currRow];if(T.indent!==null){var k=T.indent,K=Math.max(k-1,0);B.setCursor(T.indent),T.color=B.chars[K].penState.foreground}var Y={foreground:T.color,underline:T.underline,italics:T.italics,background:"black",flash:!1};this.setPen(Y)},_.setBkgData=function(T){this.logger.log(i.INFO,"bkgData = "+JSON.stringify(T)),this.backSpace(),this.setPen(T),this.insertChar(32)},_.setRollUpRows=function(T){this.nrRollUpRows=T},_.rollUp=function(){if(this.nrRollUpRows===null){this.logger.log(i.DEBUG,"roll_up but nrRollUpRows not set yet");return}this.logger.log(i.TEXT,this.getDisplayText());var T=this.currRow+1-this.nrRollUpRows,L=this.rows.splice(T,1)[0];L.clear(),this.rows.splice(this.currRow,0,L),this.logger.log(i.INFO,"Rolling up")},_.getDisplayText=function(T){T=T||!1;for(var L=[],I="",P=-1,G=0;G<w;G++){var W=this.rows[G].getTextString();W&&(P=G+1,T?L.push("Row "+P+": '"+W+"'"):L.push(W.trim()))}return L.length>0&&(T?I="["+L.join(" | ")+"]":I=L.join(`
`)),I},_.getTextAndFormat=function(){return this.rows},g}(),S=function(){function g(E,T,L){this.chNr=void 0,this.outputFilter=void 0,this.mode=void 0,this.verbose=void 0,this.displayedMemory=void 0,this.nonDisplayedMemory=void 0,this.lastOutputScreen=void 0,this.currRollUpRow=void 0,this.writeScreen=void 0,this.cueStartTime=void 0,this.logger=void 0,this.chNr=E,this.outputFilter=T,this.mode=null,this.verbose=0,this.displayedMemory=new t(L),this.nonDisplayedMemory=new t(L),this.lastOutputScreen=new t(L),this.currRollUpRow=this.displayedMemory.rows[w-1],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null,this.logger=L}var _=g.prototype;return _.reset=function(){this.mode=null,this.displayedMemory.reset(),this.nonDisplayedMemory.reset(),this.lastOutputScreen.reset(),this.outputFilter.reset(),this.currRollUpRow=this.displayedMemory.rows[w-1],this.writeScreen=this.displayedMemory,this.mode=null,this.cueStartTime=null},_.getHandler=function(){return this.outputFilter},_.setHandler=function(T){this.outputFilter=T},_.setPAC=function(T){this.writeScreen.setPAC(T)},_.setBkgData=function(T){this.writeScreen.setBkgData(T)},_.setMode=function(T){if(T===this.mode)return;this.mode=T,this.logger.log(i.INFO,"MODE="+T),this.mode==="MODE_POP-ON"?this.writeScreen=this.nonDisplayedMemory:(this.writeScreen=this.displayedMemory,this.writeScreen.reset()),this.mode!=="MODE_ROLL-UP"&&(this.displayedMemory.nrRollUpRows=null,this.nonDisplayedMemory.nrRollUpRows=null),this.mode=T},_.insertChars=function(T){for(var L=0;L<T.length;L++)this.writeScreen.insertChar(T[L]);var I=this.writeScreen===this.displayedMemory?"DISP":"NON_DISP";this.logger.log(i.INFO,I+": "+this.writeScreen.getDisplayText(!0)),(this.mode==="MODE_PAINT-ON"||this.mode==="MODE_ROLL-UP")&&(this.logger.log(i.TEXT,"DISPLAYED: "+this.displayedMemory.getDisplayText(!0)),this.outputDataUpdate())},_.ccRCL=function(){this.logger.log(i.INFO,"RCL - Resume Caption Loading"),this.setMode("MODE_POP-ON")},_.ccBS=function(){if(this.logger.log(i.INFO,"BS - BackSpace"),this.mode==="MODE_TEXT")return;this.writeScreen.backSpace(),this.writeScreen===this.displayedMemory&&this.outputDataUpdate()},_.ccAOF=function(){},_.ccAON=function(){},_.ccDER=function(){this.logger.log(i.INFO,"DER- Delete to End of Row"),this.writeScreen.clearToEndOfRow(),this.outputDataUpdate()},_.ccRU=function(T){this.logger.log(i.INFO,"RU("+T+") - Roll Up"),this.writeScreen=this.displayedMemory,this.setMode("MODE_ROLL-UP"),this.writeScreen.setRollUpRows(T)},_.ccFON=function(){this.logger.log(i.INFO,"FON - Flash On"),this.writeScreen.setPen({flash:!0})},_.ccRDC=function(){this.logger.log(i.INFO,"RDC - Resume Direct Captioning"),this.setMode("MODE_PAINT-ON")},_.ccTR=function(){this.logger.log(i.INFO,"TR"),this.setMode("MODE_TEXT")},_.ccRTD=function(){this.logger.log(i.INFO,"RTD"),this.setMode("MODE_TEXT")},_.ccEDM=function(){this.logger.log(i.INFO,"EDM - Erase Displayed Memory"),this.displayedMemory.reset(),this.outputDataUpdate(!0)},_.ccCR=function(){this.logger.log(i.INFO,"CR - Carriage Return"),this.writeScreen.rollUp(),this.outputDataUpdate(!0)},_.ccENM=function(){this.logger.log(i.INFO,"ENM - Erase Non-displayed Memory"),this.nonDisplayedMemory.reset()},_.ccEOC=function(){if(this.logger.log(i.INFO,"EOC - End Of Caption"),this.mode==="MODE_POP-ON"){var T=this.displayedMemory;this.displayedMemory=this.nonDisplayedMemory,this.nonDisplayedMemory=T,this.writeScreen=this.nonDisplayedMemory,this.logger.log(i.TEXT,"DISP: "+this.displayedMemory.getDisplayText())}this.outputDataUpdate(!0)},_.ccTO=function(T){this.logger.log(i.INFO,"TO("+T+") - Tab Offset"),this.writeScreen.moveCursor(T)},_.ccMIDROW=function(T){var L={flash:!1};if(L.underline=T%2===1,L.italics=T>=46,L.italics)L.foreground="white";else{var I=Math.floor(T/2)-16,P=["white","green","blue","cyan","red","yellow","magenta"];L.foreground=P[I]}this.logger.log(i.INFO,"MIDROW: "+JSON.stringify(L)),this.writeScreen.setPen(L)},_.outputDataUpdate=function(T){T===void 0&&(T=!1);var L=this.logger.time;if(L===null)return;this.outputFilter&&(this.cueStartTime===null&&!this.displayedMemory.isEmpty()?this.cueStartTime=L:this.displayedMemory.equals(this.lastOutputScreen)||(this.outputFilter.newCue(this.cueStartTime,L,this.lastOutputScreen),T&&this.outputFilter.dispatchCue&&this.outputFilter.dispatchCue(),this.cueStartTime=this.displayedMemory.isEmpty()?null:L),this.lastOutputScreen.copy(this.displayedMemory))},_.cueSplitAtTime=function(T){this.outputFilter&&(this.displayedMemory.isEmpty()||(this.outputFilter.newCue&&this.outputFilter.newCue(this.cueStartTime,T,this.displayedMemory),this.cueStartTime=T))},g}(),x=function(){function g(E,T,L){this.channels=void 0,this.currentChannel=0,this.cmdHistory=void 0,this.logger=void 0;var I=new o;this.channels=[null,new S(E,T,I),new S(E+1,L,I)],this.cmdHistory=O(),this.logger=I}var _=g.prototype;return _.getHandler=function(T){return this.channels[T].getHandler()},_.setHandler=function(T,L){this.channels[T].setHandler(L)},_.addData=function(T,L){var I,P,G,W=!1;this.logger.time=T;for(var H=0;H<L.length;H+=2){if(P=L[H]&127,G=L[H+1]&127,P===0&&G===0)continue;if(this.logger.log(i.DATA,"["+u([L[H],L[H+1]])+"] -> ("+u([P,G])+")"),I=this.parseCmd(P,G),I||(I=this.parseMidrow(P,G)),I||(I=this.parsePAC(P,G)),I||(I=this.parseBackgroundAttributes(P,G)),!I&&(W=this.parseChars(P,G),W)){var z=this.currentChannel;if(z&&z>0){var B=this.channels[z];B.insertChars(W)}else this.logger.log(i.WARNING,"No channel found yet. TEXT-MODE?")}!I&&!W&&this.logger.log(i.WARNING,"Couldn't parse cleaned data "+u([P,G])+" orig: "+u([L[H],L[H+1]]))}},_.parseCmd=function(T,L){var I=this.cmdHistory,P=(T===20||T===28||T===21||T===29)&&L>=32&&L<=47,G=(T===23||T===31)&&L>=33&&L<=35;if(!(P||G))return!1;if(R(T,L,I))return h(null,null,I),this.logger.log(i.DEBUG,"Repeated command ("+u([T,L])+") is dropped"),!0;var W=T===20||T===21||T===23?1:2,H=this.channels[W];return T===20||T===21||T===28||T===29?L===32?H.ccRCL():L===33?H.ccBS():L===34?H.ccAOF():L===35?H.ccAON():L===36?H.ccDER():L===37?H.ccRU(2):L===38?H.ccRU(3):L===39?H.ccRU(4):L===40?H.ccFON():L===41?H.ccRDC():L===42?H.ccTR():L===43?H.ccRTD():L===44?H.ccEDM():L===45?H.ccCR():L===46?H.ccENM():L===47&&H.ccEOC():H.ccTO(L-32),h(T,L,I),this.currentChannel=W,!0},_.parseMidrow=function(T,L){var I=0;if((T===17||T===25)&&L>=32&&L<=47){if(T===17?I=1:I=2,I!==this.currentChannel)return this.logger.log(i.ERROR,"Mismatch channel in midrow parsing"),!1;var P=this.channels[I];return P?(P.ccMIDROW(L),this.logger.log(i.DEBUG,"MIDROW ("+u([T,L])+")"),!0):!1}return!1},_.parsePAC=function(T,L){var I,P=this.cmdHistory,G=(T>=17&&T<=23||T>=25&&T<=31)&&L>=64&&L<=127,W=(T===16||T===24)&&L>=64&&L<=95;if(!(G||W))return!1;if(R(T,L,P))return h(null,null,P),!0;var H=T<=23?1:2;L>=64&&L<=95?I=H===1?p[T]:n[T]:I=H===1?d[T]:c[T];var z=this.channels[H];return z?(z.setPAC(this.interpretPAC(I,L)),h(T,L,P),this.currentChannel=H,!0):!1},_.interpretPAC=function(T,L){var I,P={color:null,italics:!1,indent:null,underline:!1,row:T};return L>95?I=L-96:I=L-64,P.underline=(I&1)===1,I<=13?P.color=["white","green","blue","cyan","red","yellow","magenta","white"][Math.floor(I/2)]:I<=15?(P.italics=!0,P.color="white"):P.indent=Math.floor((I-16)/2)*4,P},_.parseChars=function(T,L){var I,P=null,G=null;if(T>=25?(I=2,G=T-8):(I=1,G=T),G>=17&&G<=19){var W;G===17?W=L+80:G===18?W=L+112:W=L+144,this.logger.log(i.INFO,"Special char '"+y(W)+"' in channel "+I),P=[W]}else T>=32&&T<=127&&(P=L===0?[T]:[T,L]);if(P){var H=u(P);this.logger.log(i.DEBUG,"Char codes = "+H.join(",")),h(T,L,this.cmdHistory)}return P},_.parseBackgroundAttributes=function(T,L){var I=(T===16||T===24)&&L>=32&&L<=47,P=(T===23||T===31)&&L>=45&&L<=47;if(!(I||P))return!1;var G,W={};T===16||T===24?(G=Math.floor((L-32)/2),W.background=r[G],L%2===1&&(W.background=W.background+"_semi")):L===45?W.background="transparent":(W.foreground="black",L===47&&(W.underline=!0));var H=T<=23?1:2,z=this.channels[H];return z.setBkgData(W),h(T,L,this.cmdHistory),!0},_.reset=function(){for(var T=0;T<Object.keys(this.channels).length;T++){var L=this.channels[T];L&&L.reset()}this.cmdHistory=O()},_.cueSplitAtTime=function(T){for(var L=0;L<this.channels.length;L++){var I=this.channels[L];I&&I.cueSplitAtTime(T)}},g}();function h(g,_,E){E.a=g,E.b=_}function R(g,_,E){return E.a===g&&E.b===_}function O(){return{a:null,b:null}}v.default=x},"./src/utils/codecs.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"isCodecType",function(){return m}),C.d(v,"isCodecSupportedInMp4",function(){return y});var M={audio:{a3ds:!0,"ac-3":!0,"ac-4":!0,alac:!0,alaw:!0,dra1:!0,"dts+":!0,"dts-":!0,dtsc:!0,dtse:!0,dtsh:!0,"ec-3":!0,enca:!0,g719:!0,g726:!0,m4ae:!0,mha1:!0,mha2:!0,mhm1:!0,mhm2:!0,mlpa:!0,mp4a:!0,"raw ":!0,Opus:!0,samr:!0,sawb:!0,sawp:!0,sevc:!0,sqcp:!0,ssmv:!0,twos:!0,ulaw:!0},video:{avc1:!0,avc2:!0,avc3:!0,avc4:!0,avcp:!0,av01:!0,drac:!0,dvav:!0,dvhe:!0,encv:!0,hev1:!0,hvc1:!0,mjp2:!0,mp4v:!0,mvc1:!0,mvc2:!0,mvc3:!0,mvc4:!0,resv:!0,rv60:!0,s263:!0,svc1:!0,svc2:!0,"vc-1":!0,vp08:!0,vp09:!0},text:{stpp:!0,wvtt:!0}};function m(w,b){var p=M[b];return!!p&&p[w.slice(0,4)]===!0}function y(w,b){return MediaSource.isTypeSupported((b||"video")+'/mp4;codecs="'+w+'"')}},"./src/utils/cues.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/utils/vttparser.ts"),m=C("./src/utils/webvtt-parser.ts"),y=C("./src/utils/texttrack-utils.ts"),w=/\s/,b={newCue:function(d,n,c,r){for(var i=[],o,u,f,s,l,t=self.VTTCue||self.TextTrackCue,S=0;S<r.rows.length;S++)if(o=r.rows[S],f=!0,s=0,l="",!o.isEmpty()){for(var x=0;x<o.chars.length;x++)w.test(o.chars[x].uchar)&&f?s++:(l+=o.chars[x].uchar,f=!1);o.cueStartTime=n,n===c&&(c+=1e-4),s>=16?s--:s++;var h=Object(M.fixLineBreaks)(l.trim()),R=Object(m.generateCueId)(n,c,h);(!d||!d.cues||!d.cues.getCueById(R))&&(u=new t(n,c,h),u.id=R,u.line=S+1,u.align="left",u.position=10+Math.min(80,Math.floor(s*8/32)*10),i.push(u))}return d&&i.length&&(i.sort(function(O,g){return O.line==="auto"||g.line==="auto"?0:O.line>8&&g.line>8?g.line-O.line:O.line-g.line}),i.forEach(function(O){return Object(y.addCueToTrack)(d,O)})),i}};v.default=b},"./src/utils/discontinuities.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"findFirstFragWithCC",function(){return w}),C.d(v,"shouldAlignOnDiscontinuities",function(){return b}),C.d(v,"findDiscontinuousReferenceFrag",function(){return p}),C.d(v,"adjustSlidingStart",function(){return n}),C.d(v,"alignStream",function(){return c}),C.d(v,"alignPDT",function(){return i}),C.d(v,"alignFragmentByPDTDelta",function(){return o}),C.d(v,"alignMediaPlaylistByPDT",function(){return u});var M=C("./src/polyfills/number.ts"),m=C("./src/utils/logger.ts"),y=C("./src/controller/level-helper.ts");function w(f,s){for(var l=null,t=0,S=f.length;t<S;t++){var x=f[t];if(x&&x.cc===s){l=x;break}}return l}function b(f,s,l){return!!(s.details&&(l.endCC>l.startCC||f&&f.cc<l.startCC))}function p(f,s){var l=f.fragments,t=s.fragments;if(!t.length||!l.length){m.logger.log("No fragments to align");return}var S=w(l,t[0].cc);if(!S||S&&!S.startPTS){m.logger.log("No frag in previous level to align on");return}return S}function d(f,s){if(f){var l=f.start+s;f.start=f.startPTS=l,f.endPTS=l+f.duration}}function n(f,s){for(var l=s.fragments,t=0,S=l.length;t<S;t++)d(l[t],f);s.fragmentHint&&d(s.fragmentHint,f),s.alignedSliding=!0}function c(f,s,l){if(!s)return;r(f,l,s),!l.alignedSliding&&s.details&&i(l,s.details),!l.alignedSliding&&s.details&&!l.skippedSegments&&Object(y.adjustSliding)(s.details,l)}function r(f,s,l){if(b(f,l,s)){var t=p(l.details,s);t&&Object(M.isFiniteNumber)(t.start)&&(m.logger.log("Adjusting PTS using last level due to CC increase within current level "+s.url),n(t.start,s))}}function i(f,s){if(!s.fragments.length||!f.hasProgramDateTime||!s.hasProgramDateTime)return;var l=s.fragments[0].programDateTime,t=f.fragments[0].programDateTime,S=(t-l)/1e3+s.fragments[0].start;S&&Object(M.isFiniteNumber)(S)&&(m.logger.log("Adjusting PTS using programDateTime delta "+(t-l)+"ms, sliding:"+S.toFixed(3)+" "+f.url+" "),n(S,f))}function o(f,s){var l=f.programDateTime;if(!l)return;var t=(l-s)/1e3;f.start=f.startPTS=t,f.endPTS=t+f.duration}function u(f,s){if(!s.fragments.length||!f.hasProgramDateTime||!s.hasProgramDateTime)return;var l=s.fragments[0].programDateTime,t=s.fragments[0].start,S=l-t*1e3;f.fragments.forEach(function(x){o(x,S)}),f.fragmentHint&&o(f.fragmentHint,S),f.alignedSliding=!0}},"./src/utils/ewma-bandwidth-estimator.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/utils/ewma.ts"),m=function(){function y(b,p,d){this.defaultEstimate_=void 0,this.minWeight_=void 0,this.minDelayMs_=void 0,this.slow_=void 0,this.fast_=void 0,this.defaultEstimate_=d,this.minWeight_=.001,this.minDelayMs_=50,this.slow_=new M.default(b),this.fast_=new M.default(p)}var w=y.prototype;return w.update=function(p,d){var n=this.slow_,c=this.fast_;this.slow_.halfLife!==p&&(this.slow_=new M.default(p,n.getEstimate(),n.getTotalWeight())),this.fast_.halfLife!==d&&(this.fast_=new M.default(d,c.getEstimate(),c.getTotalWeight()))},w.sample=function(p,d){p=Math.max(p,this.minDelayMs_);var n=8*d,c=p/1e3,r=n/c;this.fast_.sample(c,r),this.slow_.sample(c,r)},w.canEstimate=function(){var p=this.fast_;return p&&p.getTotalWeight()>=this.minWeight_},w.getEstimate=function(){return this.canEstimate()?Math.min(this.fast_.getEstimate(),this.slow_.getEstimate()):this.defaultEstimate_},w.destroy=function(){},y}();v.default=m},"./src/utils/ewma.ts":function(N,v,C){"use strict";C.r(v);var M=function(){function m(w,b,p){b===void 0&&(b=0),p===void 0&&(p=0),this.halfLife=void 0,this.alpha_=void 0,this.estimate_=void 0,this.totalWeight_=void 0,this.halfLife=w,this.alpha_=w?Math.exp(Math.log(.5)/w):0,this.estimate_=b,this.totalWeight_=p}var y=m.prototype;return y.sample=function(b,p){var d=Math.pow(this.alpha_,b);this.estimate_=p*(1-d)+d*this.estimate_,this.totalWeight_+=b},y.getTotalWeight=function(){return this.totalWeight_},y.getEstimate=function(){if(this.alpha_){var b=1-Math.pow(this.alpha_,this.totalWeight_);if(b)return this.estimate_/b}return this.estimate_},m}();v.default=M},"./src/utils/fetch-loader.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"fetchSupported",function(){return o});var M=C("./src/polyfills/number.ts"),m=C("./src/loader/load-stats.ts"),y=C("./src/demux/chunk-cache.ts");function w(t,S){t.prototype=Object.create(S.prototype),t.prototype.constructor=t,c(t,S)}function b(t){var S=typeof Map=="function"?new Map:void 0;return b=function(h){if(h===null||!n(h))return h;if(typeof h!="function")throw new TypeError("Super expression must either be null or a function");if(typeof S!="undefined"){if(S.has(h))return S.get(h);S.set(h,R)}function R(){return p(h,arguments,r(this).constructor)}return R.prototype=Object.create(h.prototype,{constructor:{value:R,enumerable:!1,writable:!0,configurable:!0}}),c(R,h)},b(t)}function p(t,S,x){return d()?p=Reflect.construct:p=function(R,O,g){var _=[null];_.push.apply(_,O);var E=Function.bind.apply(R,_),T=new E;return g&&c(T,g.prototype),T},p.apply(null,arguments)}function d(){if(typeof Reflect=="undefined"||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}function n(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function c(t,S){return c=Object.setPrototypeOf||function(h,R){return h.__proto__=R,h},c(t,S)}function r(t){return r=Object.setPrototypeOf?Object.getPrototypeOf:function(x){return x.__proto__||Object.getPrototypeOf(x)},r(t)}function i(){return i=Object.assign||function(t){for(var S=1;S<arguments.length;S++){var x=arguments[S];for(var h in x)Object.prototype.hasOwnProperty.call(x,h)&&(t[h]=x[h])}return t},i.apply(this,arguments)}function o(){if(self.fetch&&self.AbortController&&self.ReadableStream&&self.Request)try{return new self.ReadableStream({}),!0}catch(t){}return!1}var u=function(){function t(x){this.fetchSetup=void 0,this.requestTimeout=void 0,this.request=void 0,this.response=void 0,this.controller=void 0,this.context=void 0,this.config=null,this.callbacks=null,this.stats=void 0,this.loader=null,this.fetchSetup=x.fetchSetup||s,this.controller=new self.AbortController,this.stats=new m.LoadStats}var S=t.prototype;return S.destroy=function(){this.loader=this.callbacks=null,this.abortInternal()},S.abortInternal=function(){var h=this.response;(!h||!h.ok)&&(this.stats.aborted=!0,this.controller.abort())},S.abort=function(){var h;this.abortInternal(),(h=this.callbacks)!==null&&h!==void 0&&h.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.response)},S.load=function(h,R,O){var g=this,_=this.stats;if(_.loading.start)throw new Error("Loader can only be used once.");_.loading.start=self.performance.now();var E=f(h,this.controller.signal),T=O.onProgress,L=h.responseType==="arraybuffer",I=L?"byteLength":"length";this.context=h,this.config=R,this.callbacks=O,this.request=this.fetchSetup(h,E),self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout(function(){g.abortInternal(),O.onTimeout(_,h,g.response)},R.timeout),self.fetch(this.request).then(function(P){if(g.response=g.loader=P,!P.ok){var G=P.status,W=P.statusText;throw new l(W||"fetch, bad network response",G,P)}return _.loading.first=Math.max(self.performance.now(),_.loading.start),_.total=parseInt(P.headers.get("Content-Length")||"0"),T&&Object(M.isFiniteNumber)(R.highWaterMark)?g.loadProgressively(P,_,h,R.highWaterMark,T):L?P.arrayBuffer():P.text()}).then(function(P){var G=g.response;self.clearTimeout(g.requestTimeout),_.loading.end=Math.max(self.performance.now(),_.loading.first),_.loaded=_.total=P[I];var W={url:G.url,data:P};T&&!Object(M.isFiniteNumber)(R.highWaterMark)&&T(_,h,P,G),O.onSuccess(W,_,h,G)}).catch(function(P){if(self.clearTimeout(g.requestTimeout),_.aborted)return;var G=P.code||0;O.onError({code:G,text:P.message},h,P.details)})},S.getCacheAge=function(){var h=null;if(this.response){var R=this.response.headers.get("age");h=R?parseFloat(R):null}return h},S.loadProgressively=function(h,R,O,g,_){g===void 0&&(g=0);var E=new y.default,T=h.body.getReader(),L=function I(){return T.read().then(function(P){if(P.done)return E.dataLength&&_(R,O,E.flush(),h),Promise.resolve(new ArrayBuffer(0));var G=P.value,W=G.length;return R.loaded+=W,W<g||E.dataLength?(E.push(G),E.dataLength>=g&&_(R,O,E.flush(),h)):_(R,O,G,h),I()}).catch(function(){return Promise.reject()})};return L()},t}();function f(t,S){var x={method:"GET",mode:"cors",credentials:"same-origin",signal:S,headers:new self.Headers(i({},t.headers))};return t.rangeEnd&&x.headers.set("Range","bytes="+t.rangeStart+"-"+String(t.rangeEnd-1)),x}function s(t,S){return new self.Request(t.url,S)}var l=function(t){w(S,t);function S(x,h,R){var O;return O=t.call(this,x)||this,O.code=void 0,O.details=void 0,O.code=h,O.details=R,O}return S}(b(Error));v.default=u},"./src/utils/imsc1-ttml-parser.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"IMSC1_CODEC",function(){return n}),C.d(v,"parseIMSC1",function(){return o});var M=C("./src/utils/mp4-tools.ts"),m=C("./src/utils/vttparser.ts"),y=C("./src/utils/vttcue.ts"),w=C("./src/demux/id3.ts"),b=C("./src/utils/timescale-conversion.ts"),p=C("./src/utils/webvtt-parser.ts");function d(){return d=Object.assign||function(g){for(var _=1;_<arguments.length;_++){var E=arguments[_];for(var T in E)Object.prototype.hasOwnProperty.call(E,T)&&(g[T]=E[T])}return g},d.apply(this,arguments)}var n="stpp.ttml.im1t",c=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,r=/^(\d*(?:\.\d*)?)(h|m|s|ms|f|t)$/,i={left:"start",center:"center",right:"end",start:"start",end:"end"};function o(g,_,E,T,L){var I=Object(M.findBox)(new Uint8Array(g),["mdat"]);if(I.length===0){L(new Error("Could not parse IMSC1 mdat"));return}var P=I[0],G=Object(w.utf8ArrayToStr)(new Uint8Array(g,P.start,P.end-P.start)),W=Object(b.toTimescaleFromScale)(_,1,E);try{T(u(G,W))}catch(H){L(H)}}function u(g,_){var E=new DOMParser,T=E.parseFromString(g,"text/xml"),L=T.getElementsByTagName("tt")[0];if(!L)throw new Error("Invalid ttml");var I={frameRate:30,subFrameRate:1,frameRateMultiplier:0,tickRate:0},P=Object.keys(I).reduce(function(B,k){return B[k]=L.getAttribute("ttp:"+k)||I[k],B},{}),G=L.getAttribute("xml:space")!=="preserve",W=s(f(L,"styling","style")),H=s(f(L,"layout","region")),z=f(L,"body","[begin]");return[].map.call(z,function(B){var k=l(B,G);if(!k||!B.hasAttribute("begin"))return null;var K=h(B.getAttribute("begin"),P),Y=h(B.getAttribute("dur"),P),ne=h(B.getAttribute("end"),P);if(K===null)throw x(B);if(ne===null){if(Y===null)throw x(B);ne=K+Y}var oe=new y.default(K-_,ne-_,k);oe.id=Object(p.generateCueId)(oe.startTime,oe.endTime,oe.text);var _e=H[B.getAttribute("region")],xe=W[B.getAttribute("style")];oe.position=10,oe.size=80;var le=t(_e,xe),me=le.textAlign;if(me){var de=i[me];de&&(oe.lineAlign=de),oe.align=me}return d(oe,le),oe}).filter(function(B){return B!==null})}function f(g,_,E){var T=g.getElementsByTagName(_)[0];return T?[].slice.call(T.querySelectorAll(E)):[]}function s(g){return g.reduce(function(_,E){var T=E.getAttribute("xml:id");return T&&(_[T]=E),_},{})}function l(g,_){return[].slice.call(g.childNodes).reduce(function(E,T,L){var I;return T.nodeName==="br"&&L?E+`
`:(I=T.childNodes)!==null&&I!==void 0&&I.length?l(T,_):_?E+T.textContent.trim().replace(/\s+/g," "):E+T.textContent},"")}function t(g,_){var E="http://www.w3.org/ns/ttml#styling",T=["displayAlign","textAlign","color","backgroundColor","fontSize","fontFamily"];return T.reduce(function(L,I){var P=S(_,E,I)||S(g,E,I);return P&&(L[I]=P),L},{})}function S(g,_,E){return g.hasAttributeNS(_,E)?g.getAttributeNS(_,E):null}function x(g){return new Error("Could not parse ttml timestamp "+g)}function h(g,_){if(!g)return null;var E=Object(m.parseTimeStamp)(g);return E===null&&(c.test(g)?E=R(g,_):r.test(g)&&(E=O(g,_))),E}function R(g,_){var E=c.exec(g),T=(E[4]|0)+(E[5]|0)/_.subFrameRate;return(E[1]|0)*3600+(E[2]|0)*60+(E[3]|0)+T/_.frameRate}function O(g,_){var E=r.exec(g),T=Number(E[1]),L=E[2];switch(L){case"h":return T*3600;case"m":return T*60;case"ms":return T*1e3;case"f":return T/_.frameRate;case"t":return T/_.tickRate}return T}},"./src/utils/logger.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"enableLogs",function(){return p}),C.d(v,"logger",function(){return d});var M=function(){},m={trace:M,debug:M,log:M,warn:M,info:M,error:M},y=m;function w(n){var c=self.console[n];return c?c.bind(self.console,"["+n+"] >"):M}function b(n){for(var c=arguments.length,r=new Array(c>1?c-1:0),i=1;i<c;i++)r[i-1]=arguments[i];r.forEach(function(o){y[o]=n[o]?n[o].bind(n):w(o)})}function p(n){if(self.console&&n===!0||typeof n=="object"){b(n,"debug","log","info","warn","error");try{y.log()}catch(c){y=m}}else y=m}var d=y},"./src/utils/mediakeys-helper.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"KeySystems",function(){return M}),C.d(v,"requestMediaKeySystemAccess",function(){return m});var M;(function(y){y.WIDEVINE="com.widevine.alpha",y.PLAYREADY="com.microsoft.playready"})(M||(M={}));var m=function(){return typeof self!="undefined"&&self.navigator&&self.navigator.requestMediaKeySystemAccess?self.navigator.requestMediaKeySystemAccess.bind(self.navigator):null}()},"./src/utils/mediasource-helper.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"getMediaSource",function(){return M});function M(){return self.MediaSource||self.WebKitMediaSource}},"./src/utils/mp4-tools.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"bin2str",function(){return b}),C.d(v,"readUint16",function(){return p}),C.d(v,"readUint32",function(){return d}),C.d(v,"writeUint32",function(){return n}),C.d(v,"findBox",function(){return c}),C.d(v,"parseSegmentIndex",function(){return r}),C.d(v,"parseInitSegment",function(){return i}),C.d(v,"getStartDTS",function(){return o}),C.d(v,"getDuration",function(){return u}),C.d(v,"computeRawDurationFromSamples",function(){return f}),C.d(v,"offsetStartDTS",function(){return s}),C.d(v,"segmentValidRange",function(){return l}),C.d(v,"appendUint8Array",function(){return t});var M=C("./src/utils/typed-array.ts"),m=C("./src/loader/fragment.ts"),y=Math.pow(2,32)-1,w=[].push;function b(S){return String.fromCharCode.apply(null,S)}function p(S,x){"data"in S&&(x+=S.start,S=S.data);var h=S[x]<<8|S[x+1];return h<0?65536+h:h}function d(S,x){"data"in S&&(x+=S.start,S=S.data);var h=S[x]<<24|S[x+1]<<16|S[x+2]<<8|S[x+3];return h<0?4294967296+h:h}function n(S,x,h){"data"in S&&(x+=S.start,S=S.data),S[x]=h>>24,S[x+1]=h>>16&255,S[x+2]=h>>8&255,S[x+3]=h&255}function c(S,x){var h=[];if(!x.length)return h;var R,O,g;"data"in S?(R=S.data,O=S.start,g=S.end):(R=S,O=0,g=R.byteLength);for(var _=O;_<g;){var E=d(R,_),T=b(R.subarray(_+4,_+8)),L=E>1?_+E:g;if(T===x[0])if(x.length===1)h.push({data:R,start:_+8,end:L});else{var I=c({data:R,start:_+8,end:L},x.slice(1));I.length&&w.apply(h,I)}_=L}return h}function r(S){var x=c(S,["moov"]),h=x[0],R=h?h.end:null,O=c(S,["sidx"]);if(!O||!O[0])return null;var g=[],_=O[0],E=_.data[0],T=E===0?8:16,L=d(_,T);T+=4;var I=0,P=0;E===0?T+=8:T+=16,T+=2;var G=_.end+P,W=p(_,T);T+=2;for(var H=0;H<W;H++){var z=T,B=d(_,z);z+=4;var k=B&2147483647,K=(B&2147483648)>>>31;if(K===1)return console.warn("SIDX has hierarchical references (not supported)"),null;var Y=d(_,z);z+=4,g.push({referenceSize:k,subsegmentDuration:Y,info:{duration:Y/L,start:G,end:G+k-1}}),G+=k,z+=4,T=z}return{earliestPresentationTime:I,timescale:L,version:E,referencesCount:W,references:g,moovEndOffset:R}}function i(S){for(var x=[],h=c(S,["moov","trak"]),R=0;R<h.length;R++){var O=h[R],g=c(O,["tkhd"])[0];if(g){var _=g.data[g.start],E=_===0?12:20,T=d(g,E),L=c(O,["mdia","mdhd"])[0];if(L){_=L.data[L.start],E=_===0?12:20;var I=d(L,E),P=c(O,["mdia","hdlr"])[0];if(P){var G=b(P.data.subarray(P.start+8,P.start+12)),W={soun:m.ElementaryStreamTypes.AUDIO,vide:m.ElementaryStreamTypes.VIDEO}[G];if(W){var H=c(O,["mdia","minf","stbl","stsd"])[0],z=void 0;H&&(z=b(H.data.subarray(H.start+12,H.start+16))),x[T]={timescale:I,type:W},x[W]={timescale:I,id:T,codec:z}}}}}}var B=c(S,["moov","mvex","trex"]);return B.forEach(function(k){var K=d(k,4),Y=x[K];Y&&(Y.default={duration:d(k,12),flags:d(k,20)})}),x}function o(S,x){return c(x,["moof","traf"]).reduce(function(h,R){var O=c(R,["tfdt"])[0],g=O.data[O.start],_=c(R,["tfhd"]).reduce(function(E,T){var L=d(T,4),I=S[L];if(I){var P=d(O,4);g===1&&(P*=Math.pow(2,32),P+=d(O,8));var G=I.timescale||9e4,W=P/G;if(isFinite(W)&&(E===null||W<E))return W}return E},null);return _!==null&&isFinite(_)&&(h===null||_<h)?_:h},null)||0}function u(S,x){for(var h=0,R=0,O=0,g=c(S,["moof","traf"]),_=0;_<g.length;_++){var E=g[_],T=c(E,["tfhd"])[0],L=d(T,4),I=x[L];if(!I)continue;var P=I.default,G=d(T,0)|(P==null?void 0:P.flags),W=P==null?void 0:P.duration;G&8&&(G&2?W=d(T,12):W=d(T,8));for(var H=I.timescale||9e4,z=c(E,["trun"]),B=0;B<z.length;B++){if(W){var k=d(z[B],4);h=W*k}else h=f(z[B]);I.type===m.ElementaryStreamTypes.VIDEO?R+=h/H:I.type===m.ElementaryStreamTypes.AUDIO&&(O+=h/H)}}if(R===0&&O===0){var K=r(S);if(K!=null&&K.references)return K.references.reduce(function(Y,ne){return Y+ne.info.duration||0},0)}return R||O}function f(S){var x=d(S,0),h=8;x&1&&(h+=4),x&4&&(h+=4);for(var R=0,O=d(S,4),g=0;g<O;g++){if(x&256){var _=d(S,h);R+=_,h+=4}x&512&&(h+=4),x&1024&&(h+=4),x&2048&&(h+=4)}return R}function s(S,x,h){c(x,["moof","traf"]).forEach(function(R){c(R,["tfhd"]).forEach(function(O){var g=d(O,4),_=S[g];if(!_)return;var E=_.timescale||9e4;c(R,["tfdt"]).forEach(function(T){var L=T.data[T.start],I=d(T,4);if(L===0)n(T,4,I-h*E);else{I*=Math.pow(2,32),I+=d(T,8),I-=h*E,I=Math.max(I,0);var P=Math.floor(I/(y+1)),G=Math.floor(I%(y+1));n(T,4,P),n(T,8,G)}})})})}function l(S){var x={valid:null,remainder:null},h=c(S,["moof"]);if(h){if(h.length<2)return x.remainder=S,x}else return x;var R=h[h.length-1];return x.valid=Object(M.sliceUint8)(S,0,R.start-8),x.remainder=Object(M.sliceUint8)(S,R.start-8),x}function t(S,x){var h=new Uint8Array(S.length+x.length);return h.set(S),h.set(x,S.length),h}},"./src/utils/output-filter.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"default",function(){return M});var M=function(){function m(w,b){this.timelineController=void 0,this.cueRanges=[],this.trackName=void 0,this.startTime=null,this.endTime=null,this.screen=null,this.timelineController=w,this.trackName=b}var y=m.prototype;return y.dispatchCue=function(){if(this.startTime===null)return;this.timelineController.addCues(this.trackName,this.startTime,this.endTime,this.screen,this.cueRanges),this.startTime=null},y.newCue=function(b,p,d){(this.startTime===null||this.startTime>b)&&(this.startTime=b),this.endTime=p,this.screen=d,this.timelineController.createCaptionsTrack(this.trackName)},y.reset=function(){this.cueRanges=[]},m}()},"./src/utils/texttrack-utils.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"sendAddTrackEvent",function(){return m}),C.d(v,"addCueToTrack",function(){return y}),C.d(v,"clearCurrentCues",function(){return w}),C.d(v,"removeCuesInRange",function(){return b}),C.d(v,"getCuesInRange",function(){return d});var M=C("./src/utils/logger.ts");function m(n,c){var r;try{r=new Event("addtrack")}catch(i){r=document.createEvent("Event"),r.initEvent("addtrack",!1,!1)}r.track=n,c.dispatchEvent(r)}function y(n,c){var r=n.mode;if(r==="disabled"&&(n.mode="hidden"),n.cues&&!n.cues.getCueById(c.id))try{if(n.addCue(c),!n.cues.getCueById(c.id))throw new Error("addCue is failed for: "+c)}catch(o){M.logger.debug("[texttrack-utils]: "+o);var i=new self.TextTrackCue(c.startTime,c.endTime,c.text);i.id=c.id,n.addCue(i)}r==="disabled"&&(n.mode=r)}function w(n){var c=n.mode;if(c==="disabled"&&(n.mode="hidden"),n.cues)for(var r=n.cues.length;r--;)n.removeCue(n.cues[r]);c==="disabled"&&(n.mode=c)}function b(n,c,r){var i=n.mode;if(i==="disabled"&&(n.mode="hidden"),n.cues&&n.cues.length>0)for(var o=d(n.cues,c,r),u=0;u<o.length;u++)n.removeCue(o[u]);i==="disabled"&&(n.mode=i)}function p(n,c){if(c<n[0].startTime)return 0;var r=n.length-1;if(c>n[r].endTime)return-1;for(var i=0,o=r;i<=o;){var u=Math.floor((o+i)/2);if(c<n[u].startTime)o=u-1;else if(c>n[u].startTime&&i<r)i=u+1;else return u}return n[i].startTime-c<c-n[o].startTime?i:o}function d(n,c,r){var i=[],o=p(n,c);if(o>-1)for(var u=o,f=n.length;u<f;u++){var s=n[u];if(s.startTime>=c&&s.endTime<=r)i.push(s);else if(s.startTime>r)return i}return i}},"./src/utils/time-ranges.ts":function(N,v,C){"use strict";C.r(v);var M={toString:function(y){for(var w="",b=y.length,p=0;p<b;p++)w+="["+y.start(p).toFixed(3)+","+y.end(p).toFixed(3)+"]";return w}};v.default=M},"./src/utils/timescale-conversion.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"toTimescaleFromBase",function(){return m}),C.d(v,"toTimescaleFromScale",function(){return y}),C.d(v,"toMsFromMpegTsClock",function(){return w}),C.d(v,"toMpegTsClockFromTimescale",function(){return b});var M=9e4;function m(p,d,n,c){n===void 0&&(n=1),c===void 0&&(c=!1);var r=p*d*n;return c?Math.round(r):r}function y(p,d,n,c){return n===void 0&&(n=1),c===void 0&&(c=!1),m(p,d,1/n,c)}function w(p,d){return d===void 0&&(d=!1),m(p,1e3,1/M,d)}function b(p,d){return d===void 0&&(d=1),m(p,M,1/d)}},"./src/utils/typed-array.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"sliceUint8",function(){return M});function M(m,y,w){return Uint8Array.prototype.slice?m.slice(y,w):new Uint8Array(Array.prototype.slice.call(m,y,w))}},"./src/utils/vttcue.ts":function(N,v,C){"use strict";C.r(v),v.default=function(){if(typeof self!="undefined"&&self.VTTCue)return self.VTTCue;var M=["","lr","rl"],m=["start","middle","end","left","right"];function y(n,c){if(typeof c!="string")return!1;if(!Array.isArray(n))return!1;var r=c.toLowerCase();return~n.indexOf(r)?r:!1}function w(n){return y(M,n)}function b(n){return y(m,n)}function p(n){for(var c=arguments.length,r=new Array(c>1?c-1:0),i=1;i<c;i++)r[i-1]=arguments[i];for(var o=1;o<arguments.length;o++){var u=arguments[o];for(var f in u)n[f]=u[f]}return n}function d(n,c,r){var i=this,o={enumerable:!0};i.hasBeenReset=!1;var u="",f=!1,s=n,l=c,t=r,S=null,x="",h=!0,R="auto",O="start",g=50,_="middle",E=50,T="middle";Object.defineProperty(i,"id",p({},o,{get:function(){return u},set:function(I){u=""+I}})),Object.defineProperty(i,"pauseOnExit",p({},o,{get:function(){return f},set:function(I){f=!!I}})),Object.defineProperty(i,"startTime",p({},o,{get:function(){return s},set:function(I){if(typeof I!="number")throw new TypeError("Start time must be set to a number.");s=I,this.hasBeenReset=!0}})),Object.defineProperty(i,"endTime",p({},o,{get:function(){return l},set:function(I){if(typeof I!="number")throw new TypeError("End time must be set to a number.");l=I,this.hasBeenReset=!0}})),Object.defineProperty(i,"text",p({},o,{get:function(){return t},set:function(I){t=""+I,this.hasBeenReset=!0}})),Object.defineProperty(i,"region",p({},o,{get:function(){return S},set:function(I){S=I,this.hasBeenReset=!0}})),Object.defineProperty(i,"vertical",p({},o,{get:function(){return x},set:function(I){var P=w(I);if(P===!1)throw new SyntaxError("An invalid or illegal string was specified.");x=P,this.hasBeenReset=!0}})),Object.defineProperty(i,"snapToLines",p({},o,{get:function(){return h},set:function(I){h=!!I,this.hasBeenReset=!0}})),Object.defineProperty(i,"line",p({},o,{get:function(){return R},set:function(I){if(typeof I!="number"&&I!=="auto")throw new SyntaxError("An invalid number or illegal string was specified.");R=I,this.hasBeenReset=!0}})),Object.defineProperty(i,"lineAlign",p({},o,{get:function(){return O},set:function(I){var P=b(I);if(!P)throw new SyntaxError("An invalid or illegal string was specified.");O=P,this.hasBeenReset=!0}})),Object.defineProperty(i,"position",p({},o,{get:function(){return g},set:function(I){if(I<0||I>100)throw new Error("Position must be between 0 and 100.");g=I,this.hasBeenReset=!0}})),Object.defineProperty(i,"positionAlign",p({},o,{get:function(){return _},set:function(I){var P=b(I);if(!P)throw new SyntaxError("An invalid or illegal string was specified.");_=P,this.hasBeenReset=!0}})),Object.defineProperty(i,"size",p({},o,{get:function(){return E},set:function(I){if(I<0||I>100)throw new Error("Size must be between 0 and 100.");E=I,this.hasBeenReset=!0}})),Object.defineProperty(i,"align",p({},o,{get:function(){return T},set:function(I){var P=b(I);if(!P)throw new SyntaxError("An invalid or illegal string was specified.");T=P,this.hasBeenReset=!0}})),i.displayState=void 0}return d.prototype.getCueAsHTML=function(){var n=self.WebVTT;return n.convertCueToDOMTree(self,this.text)},d}()},"./src/utils/vttparser.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"parseTimeStamp",function(){return y}),C.d(v,"fixLineBreaks",function(){return c}),C.d(v,"VTTParser",function(){return r});var M=C("./src/utils/vttcue.ts"),m=function(){function i(){}var o=i.prototype;return o.decode=function(f,s){if(!f)return"";if(typeof f!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(f))},i}();function y(i){function o(f,s,l,t){return(f|0)*3600+(s|0)*60+(l|0)+parseFloat(t||0)}var u=i.match(/^(?:(\d+):)?(\d{2}):(\d{2})(\.\d+)?/);return u?parseFloat(u[2])>59?o(u[2],u[3],0,u[4]):o(u[1],u[2],u[3],u[4]):null}var w=function(){function i(){this.values=Object.create(null)}var o=i.prototype;return o.set=function(f,s){!this.get(f)&&s!==""&&(this.values[f]=s)},o.get=function(f,s,l){return l?this.has(f)?this.values[f]:s[l]:this.has(f)?this.values[f]:s},o.has=function(f){return f in this.values},o.alt=function(f,s,l){for(var t=0;t<l.length;++t)if(s===l[t]){this.set(f,s);break}},o.integer=function(f,s){/^-?\d+$/.test(s)&&this.set(f,parseInt(s,10))},o.percent=function(f,s){if(/^([\d]{1,3})(\.[\d]*)?%$/.test(s)){var l=parseFloat(s);if(l>=0&&l<=100)return this.set(f,l),!0}return!1},i}();function b(i,o,u,f){var s=f?i.split(f):[i];for(var l in s){if(typeof s[l]!="string")continue;var t=s[l].split(u);if(t.length!==2)continue;var S=t[0],x=t[1];o(S,x)}}var p=new M.default(0,0,""),d=p.align==="middle"?"middle":"center";function n(i,o,u){var f=i;function s(){var S=y(i);if(S===null)throw new Error("Malformed timestamp: "+f);return i=i.replace(/^[^\sa-zA-Z-]+/,""),S}function l(S,x){var h=new w;b(S,function(g,_){var E;switch(g){case"region":for(var T=u.length-1;T>=0;T--)if(u[T].id===_){h.set(g,u[T].region);break}break;case"vertical":h.alt(g,_,["rl","lr"]);break;case"line":E=_.split(","),h.integer(g,E[0]),h.percent(g,E[0])&&h.set("snapToLines",!1),h.alt(g,E[0],["auto"]),E.length===2&&h.alt("lineAlign",E[1],["start",d,"end"]);break;case"position":E=_.split(","),h.percent(g,E[0]),E.length===2&&h.alt("positionAlign",E[1],["start",d,"end","line-left","line-right","auto"]);break;case"size":h.percent(g,_);break;case"align":h.alt(g,_,["start",d,"end","left","right"]);break}},/:/,/\s/),x.region=h.get("region",null),x.vertical=h.get("vertical","");var R=h.get("line","auto");R==="auto"&&p.line===-1&&(R=-1),x.line=R,x.lineAlign=h.get("lineAlign","start"),x.snapToLines=h.get("snapToLines",!0),x.size=h.get("size",100),x.align=h.get("align",d);var O=h.get("position","auto");O==="auto"&&p.position===50&&(O=x.align==="start"||x.align==="left"?0:x.align==="end"||x.align==="right"?100:50),x.position=O}function t(){i=i.replace(/^\s+/,"")}if(t(),o.startTime=s(),t(),i.substr(0,3)!=="-->")throw new Error("Malformed time stamp (time stamps must be separated by '-->'): "+f);i=i.substr(3),t(),o.endTime=s(),t(),l(i,o)}function c(i){return i.replace(/<br(?: \/)?>/gi,`
`)}var r=function(){function i(){this.state="INITIAL",this.buffer="",this.decoder=new m,this.regionList=[],this.cue=null,this.oncue=void 0,this.onparsingerror=void 0,this.onflush=void 0}var o=i.prototype;return o.parse=function(f){var s=this;f&&(s.buffer+=s.decoder.decode(f,{stream:!0}));function l(){var O=s.buffer,g=0;for(O=c(O);g<O.length&&O[g]!=="\r"&&O[g]!==`
`;)++g;var _=O.substr(0,g);return O[g]==="\r"&&++g,O[g]===`
`&&++g,s.buffer=O.substr(g),_}function t(O){b(O,function(g,_){},/:/)}try{var S="";if(s.state==="INITIAL"){if(!/\r\n|\n/.test(s.buffer))return this;S=l();var x=S.match(/^()?WEBVTT([ \t].*)?$/);if(!x||!x[0])throw new Error("Malformed WebVTT signature.");s.state="HEADER"}for(var h=!1;s.buffer;){if(!/\r\n|\n/.test(s.buffer))return this;h?h=!1:S=l();switch(s.state){case"HEADER":/:/.test(S)?t(S):S||(s.state="ID");continue;case"NOTE":S||(s.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(S)){s.state="NOTE";break}if(!S)continue;if(s.cue=new M.default(0,0,""),s.state="CUE",S.indexOf("-->")===-1){s.cue.id=S;continue}case"CUE":if(!s.cue){s.state="BADCUE";continue}try{n(S,s.cue,s.regionList)}catch(O){s.cue=null,s.state="BADCUE";continue}s.state="CUETEXT";continue;case"CUETEXT":{var R=S.indexOf("-->")!==-1;if(!S||R&&(h=!0)){s.oncue&&s.cue&&s.oncue(s.cue),s.cue=null,s.state="ID";continue}if(s.cue===null)continue;s.cue.text&&(s.cue.text+=`
`),s.cue.text+=S}continue;case"BADCUE":S||(s.state="ID")}}}catch(O){s.state==="CUETEXT"&&s.cue&&s.oncue&&s.oncue(s.cue),s.cue=null,s.state=s.state==="INITIAL"?"BADWEBVTT":"BADCUE"}return this},o.flush=function(){var f=this;try{if((f.cue||f.state==="HEADER")&&(f.buffer+=`
`,f.parse()),f.state==="INITIAL"||f.state==="BADWEBVTT")throw new Error("Malformed WebVTT signature.")}catch(s){f.onparsingerror&&f.onparsingerror(s)}return f.onflush&&f.onflush(),this},i}()},"./src/utils/webvtt-parser.ts":function(N,v,C){"use strict";C.r(v),C.d(v,"generateCueId",function(){return r}),C.d(v,"parseWebVTT",function(){return o});var M=C("./src/polyfills/number.ts"),m=C("./src/utils/vttparser.ts"),y=C("./src/demux/id3.ts"),w=C("./src/utils/timescale-conversion.ts"),b=C("./src/remux/mp4-remuxer.ts"),p=/\r\n|\n\r|\n|\r/g,d=function(f,s,l){return l===void 0&&(l=0),f.substr(l,s.length)===s},n=function(f){var s=parseInt(f.substr(-3)),l=parseInt(f.substr(-6,2)),t=parseInt(f.substr(-9,2)),S=f.length>9?parseInt(f.substr(0,f.indexOf(":"))):0;if(!Object(M.isFiniteNumber)(s)||!Object(M.isFiniteNumber)(l)||!Object(M.isFiniteNumber)(t)||!Object(M.isFiniteNumber)(S))throw Error("Malformed X-TIMESTAMP-MAP: Local:"+f);return s+=1e3*l,s+=60*1e3*t,s+=60*60*1e3*S,s},c=function(f){for(var s=5381,l=f.length;l;)s=s*33^f.charCodeAt(--l);return(s>>>0).toString()};function r(u,f,s){return c(u.toString())+c(f.toString())+c(s)}var i=function(f,s,l){var t=f[s],S=f[t.prevCC];if(!S||!S.new&&t.new){f.ccOffset=f.presentationOffset=t.start,t.new=!1;return}for(;(x=S)!==null&&x!==void 0&&x.new;){var x;f.ccOffset+=t.start-S.start,t.new=!1,t=S,S=f[t.prevCC]}f.presentationOffset=l};function o(u,f,s,l,t,S,x,h){var R=new m.VTTParser,O=Object(y.utf8ArrayToStr)(new Uint8Array(u)).trim().replace(p,`
`).split(`
`),g=[],_=Object(w.toMpegTsClockFromTimescale)(f,s),E="00:00.000",T=0,L=0,I,P=!0,G=!1;R.oncue=function(W){var H=l[t],z=l.ccOffset,B=(T-_)/9e4;if(H!=null&&H.new&&(L!==void 0?z=l.ccOffset=H.start:i(l,t,B)),B&&(z=B-l.presentationOffset),G){var k=W.endTime-W.startTime,K=Object(b.normalizePts)((W.startTime+z-L)*9e4,S*9e4)/9e4;W.startTime=K,W.endTime=K+k}var Y=W.text.trim();W.text=decodeURIComponent(encodeURIComponent(Y)),W.id||(W.id=r(W.startTime,W.endTime,Y)),W.endTime>0&&g.push(W)},R.onparsingerror=function(W){I=W},R.onflush=function(){if(I){h(I);return}x(g)},O.forEach(function(W){if(P)if(d(W,"X-TIMESTAMP-MAP=")){P=!1,G=!0,W.substr(16).split(",").forEach(function(H){d(H,"LOCAL:")?E=H.substr(6):d(H,"MPEGTS:")&&(T=parseInt(H.substr(7)))});try{L=n(E)/1e3}catch(H){G=!1,I=H}return}else W===""&&(P=!1);R.parse(W+`
`)}),R.flush()}},"./src/utils/xhr-loader.ts":function(N,v,C){"use strict";C.r(v);var M=C("./src/utils/logger.ts"),m=C("./src/loader/load-stats.ts"),y=/^age:\s*[\d.]+\s*$/m,w=function(){function b(d){this.xhrSetup=void 0,this.requestTimeout=void 0,this.retryTimeout=void 0,this.retryDelay=void 0,this.config=null,this.callbacks=null,this.context=void 0,this.loader=null,this.stats=void 0,this.xhrSetup=d?d.xhrSetup:null,this.stats=new m.LoadStats,this.retryDelay=0}var p=b.prototype;return p.destroy=function(){this.callbacks=null,this.abortInternal(),this.loader=null,this.config=null},p.abortInternal=function(){var n=this.loader;self.clearTimeout(this.requestTimeout),self.clearTimeout(this.retryTimeout),n&&(n.onreadystatechange=null,n.onprogress=null,n.readyState!==4&&(this.stats.aborted=!0,n.abort()))},p.abort=function(){var n;this.abortInternal(),(n=this.callbacks)!==null&&n!==void 0&&n.onAbort&&this.callbacks.onAbort(this.stats,this.context,this.loader)},p.load=function(n,c,r){if(this.stats.loading.start)throw new Error("Loader can only be used once.");this.stats.loading.start=self.performance.now(),this.context=n,this.config=c,this.callbacks=r,this.retryDelay=c.retryDelay,this.loadInternal()},p.loadInternal=function(){var n=this.config,c=this.context;if(!n)return;var r=this.loader=new self.XMLHttpRequest,i=this.stats;i.loading.first=0,i.loaded=0;var o=this.xhrSetup;try{if(o)try{o(r,c.url)}catch(s){r.open("GET",c.url,!0),o(r,c.url)}r.readyState||r.open("GET",c.url,!0);var u=this.context.headers;if(u)for(var f in u)r.setRequestHeader(f,u[f])}catch(s){this.callbacks.onError({code:r.status,text:s.message},c,r);return}c.rangeEnd&&r.setRequestHeader("Range","bytes="+c.rangeStart+"-"+(c.rangeEnd-1)),r.onreadystatechange=this.readystatechange.bind(this),r.onprogress=this.loadprogress.bind(this),r.responseType=c.responseType,self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),n.timeout),r.send()},p.readystatechange=function(){var n=this.context,c=this.loader,r=this.stats;if(!n||!c)return;var i=c.readyState,o=this.config;if(r.aborted)return;if(i>=2)if(self.clearTimeout(this.requestTimeout),r.loading.first===0&&(r.loading.first=Math.max(self.performance.now(),r.loading.start)),i===4){c.onreadystatechange=null,c.onprogress=null;var u=c.status;if(u>=200&&u<300){r.loading.end=Math.max(self.performance.now(),r.loading.first);var f,s;if(n.responseType==="arraybuffer"?(f=c.response,s=f.byteLength):(f=c.responseText,s=f.length),r.loaded=r.total=s,!this.callbacks)return;var l=this.callbacks.onProgress;if(l&&l(r,n,f,c),!this.callbacks)return;var t={url:c.responseURL,data:f};this.callbacks.onSuccess(t,r,n,c)}else r.retry>=o.maxRetry||u>=400&&u<499?(M.logger.error(u+" while loading "+n.url),this.callbacks.onError({code:u,text:c.statusText},n,c)):(M.logger.warn(u+" while loading "+n.url+", retrying in "+this.retryDelay+"..."),this.abortInternal(),this.loader=null,self.clearTimeout(this.retryTimeout),this.retryTimeout=self.setTimeout(this.loadInternal.bind(this),this.retryDelay),this.retryDelay=Math.min(2*this.retryDelay,o.maxRetryDelay),r.retry++)}else self.clearTimeout(this.requestTimeout),this.requestTimeout=self.setTimeout(this.loadtimeout.bind(this),o.timeout)},p.loadtimeout=function(){M.logger.warn("timeout while loading "+this.context.url);var n=this.callbacks;n&&(this.abortInternal(),n.onTimeout(this.stats,this.context,this.loader))},p.loadprogress=function(n){var c=this.stats;c.loaded=n.loaded,n.lengthComputable&&(c.total=n.total)},p.getCacheAge=function(){var n=null;if(this.loader&&y.test(this.loader.getAllResponseHeaders())){var c=this.loader.getResponseHeader("age");n=c?parseFloat(c):null}return n},b}();v.default=w}}).default})},vHTk:function(F,Q,j){F.exports={wrp:"wrp___z2l1F",bgBlack:"bgBlack___3ezfX",monaco:"monaco___1ypjT",darkBlue:"darkBlue___2ViJc",close:"close___3q-z4",embed:"embed___3dQqc"}},w7YG:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("ETIr"),j("cv67"),j("K3mO"),j("OLod"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.StreamCipher,m=v.algo,y=m.RC4=M.extend({_doReset:function(){for(var p=this._key,d=p.words,n=p.sigBytes,c=this._S=[],r=0;r<256;r++)c[r]=r;for(var r=0,i=0;r<256;r++){var o=r%n,u=d[o>>>2]>>>24-o%4*8&255;i=(i+c[r]+u)%256;var f=c[r];c[r]=c[i],c[i]=f}this._i=this._j=0},_doProcessBlock:function(p,d){p[d]^=w.call(this)},keySize:256/32,ivSize:0});function w(){for(var p=this._S,d=this._i,n=this._j,c=0,r=0;r<4;r++){d=(d+1)%256,n=(n+p[d])%256;var i=p[d];p[d]=p[n],p[n]=i,c|=p[(p[d]+p[n])%256]<<24-r*8}return this._i=d,this._j=n,c}v.RC4=M._createHelper(y);var b=m.RC4Drop=y.extend({cfg:y.cfg.extend({drop:192}),_doReset:function(){y._doReset.call(this);for(var p=this.cfg.drop;p>0;p--)w.call(this)}});v.RC4Drop=M._createHelper(b)}(),N.RC4})},wCXF:function(F,Q,j){"use strict";j.d(Q,"a",function(){return Ye});var N=j("rePB"),v=j("VTBJ"),C=j("KQm4"),M=j("U8pU"),m=j("ODXe"),y=j("cDcd"),w=j("TSYQ"),b=j.n(w),p=j("Gytx"),d=j.n(p),n=j("Kwbf"),c=j("t23M"),r=j("qx4F"),i=j("6eGT"),o=j("IBYe"),u=j("Ff2n"),f=j("c+Xe"),s=j("fyJ8"),l=j("biw7");function t(Pe,Se,Je,nt,We){var et=Je[Pe]||{},Me=Je[Se]||{},Ce,Re;et.fixed==="left"?Ce=nt.left[Pe]:Me.fixed==="right"&&(Re=nt.right[Se]);var pe=!1,ye=!1,we=!1,Ie=!1,ke=Je[Se+1],Ve=Je[Pe-1];if(We==="rtl"){if(Ce!==void 0){var ut=Ve&&Ve.fixed==="left";Ie=!ut}else if(Re!==void 0){var ct=ke&&ke.fixed==="right";we=!ct}}else if(Ce!==void 0){var Lt=ke&&ke.fixed==="left";pe=!Lt}else if(Re!==void 0){var Dt=Ve&&Ve.fixed==="right";ye=!Dt}return{fixLeft:Ce,fixRight:Re,lastFixLeft:pe,firstFixRight:ye,lastFixRight:we,firstFixLeft:Ie,isSticky:nt.isSticky}}var S=j("sR1s");function x(Pe){var Se=Pe.cells,Je=Pe.stickyOffsets,nt=Pe.flattenColumns,We=Pe.rowComponent,et=Pe.cellComponent,Me=Pe.onHeaderRow,Ce=Pe.index,Re=y.useContext(l.a),pe=Re.prefixCls,ye=Re.direction,we;Me&&(we=Me(Se.map(function(ke){return ke.column}),Ce));var Ie=Object(S.a)(Se.map(function(ke){return ke.column}));return y.createElement(We,Object.assign({},we),Se.map(function(ke,Ve){var ut=ke.column,ct=t(ke.colStart,ke.colEnd,nt,Je,ye),Lt;return ut&&ut.onHeaderCell&&(Lt=ke.column.onHeaderCell(ut)),y.createElement(s.a,Object.assign({},ke,{ellipsis:ut.ellipsis,align:ut.align,component:et,prefixCls:pe,key:Ie[Ve]},ct,{additionalProps:Lt,rowType:"header"}))}))}x.displayName="HeaderRow";var h=x;function R(Pe){var Se=[];function Je(Me,Ce){var Re=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;Se[Re]=Se[Re]||[];var pe=Ce,ye=Me.filter(Boolean).map(function(we){var Ie={key:we.key,className:we.className||"",children:we.title,column:we,colStart:pe},ke=1,Ve=we.children;return Ve&&Ve.length>0&&(ke=Je(Ve,pe,Re+1).reduce(function(ut,ct){return ut+ct},0),Ie.hasSubColumns=!0),"colSpan"in we&&(ke=we.colSpan),"rowSpan"in we&&(Ie.rowSpan=we.rowSpan),Ie.colSpan=ke,Ie.colEnd=Ie.colStart+ke-1,Se[Re].push(Ie),pe+=ke,ke});return ye}Je(Pe,0);for(var nt=Se.length,We=function(Ce){Se[Ce].forEach(function(Re){!("rowSpan"in Re)&&!Re.hasSubColumns&&(Re.rowSpan=nt-Ce)})},et=0;et<nt;et+=1)We(et);return Se}function O(Pe){var Se=Pe.stickyOffsets,Je=Pe.columns,nt=Pe.flattenColumns,We=Pe.onHeaderRow,et=y.useContext(l.a),Me=et.prefixCls,Ce=et.getComponent,Re=y.useMemo(function(){return R(Je)},[Je]),pe=Ce(["header","wrapper"],"thead"),ye=Ce(["header","row"],"tr"),we=Ce(["header","cell"],"th");return y.createElement(pe,{className:"".concat(Me,"-thead")},Re.map(function(Ie,ke){var Ve=y.createElement(h,{key:ke,flattenColumns:nt,cells:Ie,stickyOffsets:Se,rowComponent:ye,cellComponent:we,onHeaderRow:We,index:ke});return Ve}))}var g=O,_=j("hW8S");function E(Pe){for(var Se=Pe.colWidths,Je=Pe.columns,nt=Pe.columCount,We=[],et=nt||Je.length,Me=!1,Ce=et-1;Ce>=0;Ce-=1){var Re=Se[Ce],pe=Je&&Je[Ce],ye=pe&&pe[_.a];(Re||ye||Me)&&(We.unshift(y.createElement("col",Object.assign({key:Ce,style:{width:Re,minWidth:Re}},ye))),Me=!0)}return y.createElement("colgroup",null,We)}var T=E;function L(Pe,Se){return Object(y.useMemo)(function(){for(var Je=[],nt=0;nt<Se;nt+=1){var We=Pe[nt];if(We!==void 0)Je[nt]=We;else return null}return Je},[Pe.join("_"),Se])}var I=y.forwardRef(function(Pe,Se){var Je=Pe.noData,nt=Pe.columns,We=Pe.flattenColumns,et=Pe.colWidths,Me=Pe.columCount,Ce=Pe.stickyOffsets,Re=Pe.direction,pe=Pe.fixHeader,ye=Pe.offsetHeader,we=Pe.stickyClassName,Ie=Pe.onScroll,ke=Object(u.a)(Pe,["noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","offsetHeader","stickyClassName","onScroll"]),Ve=y.useContext(l.a),ut=Ve.prefixCls,ct=Ve.scrollbarSize,Lt=Ve.isSticky,Dt=Lt&&!pe?0:ct,Er=y.useRef(null),rr=y.useCallback(function(an){Object(f.b)(Se,an),Object(f.b)(Er,an)},[]);y.useEffect(function(){var an;function qr(Bt){var ur=Bt.currentTarget,jr=Bt.deltaX;jr&&(Ie({currentTarget:ur,scrollLeft:ur.scrollLeft+jr}),Bt.preventDefault())}return(an=Er.current)===null||an===void 0||an.addEventListener("wheel",qr),function(){var Bt;(Bt=Er.current)===null||Bt===void 0||Bt.removeEventListener("wheel",qr)}},[]);var xt=We[We.length-1],kr={fixed:xt?xt.fixed:null,onHeaderCell:function(){return{className:"".concat(ut,"-cell-scrollbar")}}},Mr=Object(y.useMemo)(function(){return Dt?[].concat(Object(C.a)(nt),[kr]):nt},[Dt,nt]),Ur=Object(y.useMemo)(function(){return Dt?[].concat(Object(C.a)(We),[kr]):We},[Dt,We]),ln=Object(y.useMemo)(function(){var an=Ce.right,qr=Ce.left;return Object(v.a)(Object(v.a)({},Ce),{},{left:Re==="rtl"?[].concat(Object(C.a)(qr.map(function(Bt){return Bt+Dt})),[0]):qr,right:Re==="rtl"?an:[].concat(Object(C.a)(an.map(function(Bt){return Bt+Dt})),[0]),isSticky:Lt})},[Dt,Ce,Lt]),Sr=L(et,Me);return y.createElement("div",{style:Object(v.a)({overflow:"hidden"},Lt?{top:ye}:{}),ref:rr,className:b()("".concat(ut,"-header"),Object(N.a)({},we,!!we))},y.createElement("table",{style:{tableLayout:"fixed",visibility:Je||Sr?null:"hidden"}},y.createElement(T,{colWidths:Sr?[].concat(Object(C.a)(Sr),[Dt]):[],columCount:Me+1,columns:Ur}),y.createElement(g,Object.assign({},ke,{stickyOffsets:ln,columns:Mr,flattenColumns:Ur}))))});I.displayName="FixedHeader";var P=I,G=y.createContext(null),W=G;function H(Pe){var Se=Pe.prefixCls,Je=Pe.children,nt=Pe.component,We=Pe.cellComponent,et=Pe.fixHeader,Me=Pe.fixColumn,Ce=Pe.horizonScroll,Re=Pe.className,pe=Pe.expanded,ye=Pe.componentWidth,we=Pe.colSpan,Ie=y.useContext(l.a),ke=Ie.scrollbarSize;return y.useMemo(function(){var Ve=Je;return Me&&(Ve=y.createElement("div",{style:{width:ye-(et?ke:0),position:"sticky",left:0,overflow:"hidden"},className:"".concat(Se,"-expanded-row-fixed")},Ve)),y.createElement(nt,{className:Re,style:{display:pe?null:"none"}},y.createElement(s.a,{component:We,prefixCls:Se,colSpan:we},Ve))},[Je,nt,et,Ce,Re,pe,ye,we,ke])}var z=H;function B(Pe){var Se=Pe.className,Je=Pe.style,nt=Pe.record,We=Pe.index,et=Pe.rowKey,Me=Pe.getRowKey,Ce=Pe.rowExpandable,Re=Pe.expandedKeys,pe=Pe.onRow,ye=Pe.indent,we=ye===void 0?0:ye,Ie=Pe.rowComponent,ke=Pe.cellComponent,Ve=Pe.childrenColumnName,ut=y.useContext(l.a),ct=ut.prefixCls,Lt=ut.fixedInfoList,Dt=y.useContext(W),Er=Dt.fixHeader,rr=Dt.fixColumn,xt=Dt.horizonScroll,kr=Dt.componentWidth,Mr=Dt.flattenColumns,Ur=Dt.expandableType,ln=Dt.expandRowByClick,Sr=Dt.onTriggerExpand,an=Dt.rowClassName,qr=Dt.expandedRowClassName,Bt=Dt.indentSize,ur=Dt.expandIcon,jr=Dt.expandedRowRender,en=Dt.expandIconColumnIndex,Jr=y.useState(!1),_a=Object(m.a)(Jr,2),Wa=_a[0],_n=_a[1],er=Re&&Re.has(Pe.recordKey);y.useEffect(function(){er&&_n(!0)},[er]);var Xn=Ur==="row"&&(!Ce||Ce(nt)),Ea=Ur==="nest",Pn=Ve&&nt&&nt[Ve],Qr=Xn||Ea,Ln;pe&&(Ln=pe(nt,We));var la=function(xr){if(ln&&Qr&&Sr(nt,xr),Ln&&Ln.onClick){for(var ta,Ct=arguments.length,Vn=new Array(Ct>1?Ct-1:0),Mn=1;Mn<Ct;Mn++)Vn[Mn-1]=arguments[Mn];(ta=Ln).onClick.apply(ta,[xr].concat(Vn))}},fa;typeof an=="string"?fa=an:typeof an=="function"&&(fa=an(nt,We,we));var It=Object(S.a)(Mr),dr=y.createElement(Ie,Object.assign({},Ln,{"data-row-key":et,className:b()(Se,"".concat(ct,"-row"),"".concat(ct,"-row-level-").concat(we),fa,Ln&&Ln.className),style:Object(v.a)(Object(v.a)({},Je),Ln?Ln.style:null),onClick:la}),Mr.map(function(kn,xr){var ta=kn.render,Ct=kn.dataIndex,Vn=kn.className,Mn=It[xr],Ka=Lt[xr],Ta;xr===(en||0)&&Ea&&(Ta=y.createElement(y.Fragment,null,y.createElement("span",{style:{paddingLeft:"".concat(Bt*we,"px")},className:"".concat(ct,"-row-indent indent-level-").concat(we)}),ur({prefixCls:ct,expanded:er,expandable:Pn,record:nt,onExpand:Sr})));var Qn;return kn.onCell&&(Qn=kn.onCell(nt,We)),y.createElement(s.a,Object.assign({className:Vn,ellipsis:kn.ellipsis,align:kn.align,component:ke,prefixCls:ct,key:Mn,record:nt,index:We,dataIndex:Ct,render:ta,shouldCellUpdate:kn.shouldCellUpdate},Ka,{appendNode:Ta,additionalProps:Qn}))})),ha;if(Xn&&(Wa||er)){var xa=jr(nt,We,we+1,er),Pa=qr&&qr(nt,We,we);ha=y.createElement(z,{expanded:er,className:b()("".concat(ct,"-expanded-row"),"".concat(ct,"-expanded-row-level-").concat(we+1),Pa),prefixCls:ct,fixHeader:Er,fixColumn:rr,horizonScroll:xt,component:Ie,componentWidth:kr,cellComponent:ke,colSpan:Mr.length},xa)}var pa;return Pn&&er&&(pa=(nt[Ve]||[]).map(function(kn,xr){var ta=Me(kn,xr);return y.createElement(B,Object.assign({},Pe,{key:ta,rowKey:ta,record:kn,recordKey:ta,index:xr,indent:we+1}))})),y.createElement(y.Fragment,null,dr,ha,pa)}B.displayName="BodyRow";var k=B,K=y.createContext(null),Y=K;function ne(Pe){var Se=Pe.columnKey,Je=Pe.onColumnResize,nt=y.useRef();return y.useEffect(function(){nt.current&&Je(Se,nt.current.offsetWidth)},[]),y.createElement(c.a,{onResize:function(et){var Me=et.offsetWidth;Je(Se,Me)}},y.createElement("td",{ref:nt,style:{padding:0,border:0,height:0}},y.createElement("div",{style:{height:0,overflow:"hidden"}},"\xA0")))}function oe(Pe){var Se=Pe.data,Je=Pe.getRowKey,nt=Pe.measureColumnWidth,We=Pe.expandedKeys,et=Pe.onRow,Me=Pe.rowExpandable,Ce=Pe.emptyNode,Re=Pe.childrenColumnName,pe=y.useContext(Y),ye=pe.onColumnResize,we=y.useContext(l.a),Ie=we.prefixCls,ke=we.getComponent,Ve=y.useContext(W),ut=Ve.fixHeader,ct=Ve.horizonScroll,Lt=Ve.flattenColumns,Dt=Ve.componentWidth;return y.useMemo(function(){var Er=ke(["body","wrapper"],"tbody"),rr=ke(["body","row"],"tr"),xt=ke(["body","cell"],"td"),kr;Se.length?kr=Se.map(function(Ur,ln){var Sr=Je(Ur,ln);return y.createElement(k,{key:Sr,rowKey:Sr,record:Ur,recordKey:Sr,index:ln,rowComponent:rr,cellComponent:xt,expandedKeys:We,onRow:et,getRowKey:Je,rowExpandable:Me,childrenColumnName:Re})}):kr=y.createElement(z,{expanded:!0,className:"".concat(Ie,"-placeholder"),prefixCls:Ie,fixHeader:ut,fixColumn:ct,horizonScroll:ct,component:rr,componentWidth:Dt,cellComponent:xt,colSpan:Lt.length},Ce);var Mr=Object(S.a)(Lt);return y.createElement(Er,{className:"".concat(Ie,"-tbody")},nt&&y.createElement("tr",{"aria-hidden":"true",className:"".concat(Ie,"-measure-row"),style:{height:0}},Mr.map(function(Ur){return y.createElement(ne,{key:Ur,columnKey:Ur,onColumnResize:ye})})),kr)},[Se,Ie,et,nt,We,Je,ke,Dt,Ce,Lt])}var _e=y.memo(oe);_e.displayName="Body";var xe=_e,le=j("wRmb"),me=j("xEkU"),de=j.n(me);function ae(Pe){var Se=Object(y.useRef)(Pe),Je=Object(y.useState)({}),nt=Object(m.a)(Je,2),We=nt[1],et=Object(y.useRef)(null),Me=Object(y.useRef)([]);function Ce(Re){et.current===null&&(Me.current=[],et.current=de()(function(){Me.current.forEach(function(pe){Se.current=pe(Se.current)}),et.current=null,We({})})),Me.current.push(Re)}return Object(y.useEffect)(function(){return function(){de.a.cancel(et.current)}},[]),[Se.current,Ce]}function ie(Pe){var Se=Object(y.useRef)(Pe),Je=Object(y.useRef)(null);function nt(){window.clearTimeout(Je.current)}function We(Me){Se.current=Me,nt(),Je.current=window.setTimeout(function(){Se.current=null,Je.current=null},100)}function et(){return Se.current}return Object(y.useEffect)(function(){return nt},[]),[We,et]}function q(Pe,Se,Je){var nt=Object(y.useMemo)(function(){for(var We=[],et=[],Me=0,Ce=0,Re=0;Re<Se;Re+=1)if(Je==="rtl"){et[Re]=Ce,Ce+=Pe[Re]||0;var pe=Se-Re-1;We[pe]=Me,Me+=Pe[pe]||0}else{We[Re]=Me,Me+=Pe[Re]||0;var ye=Se-Re-1;et[ye]=Ce,Ce+=Pe[ye]||0}return{left:We,right:et}},[Pe,Se,Je]);return nt}var ue=q;function Z(Pe){var Se=Pe.className,Je=Pe.children;return y.createElement("div",{className:Se},Je)}var ee=Z,Ee=j("n6Qo");function te(Pe){var Se,Je=Pe.prefixCls,nt=Pe.record,We=Pe.onExpand,et=Pe.expanded,Me=Pe.expandable,Ce="".concat(Je,"-row-expand-icon");if(!Me)return y.createElement("span",{className:b()(Ce,"".concat(Je,"-row-spaced"))});var Re=function(ye){We(nt,ye),ye.stopPropagation()};return y.createElement("span",{className:b()(Ce,(Se={},Object(N.a)(Se,"".concat(Je,"-row-expanded"),et),Object(N.a)(Se,"".concat(Je,"-row-collapsed"),!et),Se)),onClick:Re})}function J(Pe,Se,Je){var nt=[];function We(et){(et||[]).forEach(function(Me,Ce){nt.push(Se(Me,Ce)),We(Me[Je])})}return We(Pe),nt}var X=j("zT1h"),$=j("y0+3"),ge=function(Se,Je){var nt,We,et=Se.scrollBodyRef,Me=Se.onScroll,Ce=Se.offsetScroll,Re=y.useContext(l.a),pe=Re.prefixCls,ye=((nt=et.current)===null||nt===void 0?void 0:nt.scrollWidth)||0,we=((We=et.current)===null||We===void 0?void 0:We.clientWidth)||0,Ie=ye&&we*(we/ye),ke=y.useRef(),Ve=ae({scrollLeft:0,isHiddenScrollBar:!1}),ut=Object(m.a)(Ve,2),ct=ut[0],Lt=ut[1],Dt=y.useRef({delta:0,x:0}),Er=y.useState(!1),rr=Object(m.a)(Er,2),xt=rr[0],kr=rr[1],Mr=function(){kr(!1)},Ur=function(Bt){Bt.persist(),Dt.current.delta=Bt.pageX-ct.scrollLeft,Dt.current.x=0,kr(!0),Bt.preventDefault()},ln=function(Bt){var ur,jr=Bt||((ur=window)===null||ur===void 0?void 0:ur.event),en=jr.buttons;if(!xt||en===0){xt&&kr(!1);return}var Jr=Dt.current.x+Bt.pageX-Dt.current.x-Dt.current.delta;Jr<=0&&(Jr=0),Jr+Ie>=we&&(Jr=we-Ie),Me({scrollLeft:Jr/we*(ye+2)}),Dt.current.x=Bt.pageX},Sr=function(){var Bt=Object($.b)(et.current).top,ur=Bt+et.current.offsetHeight,jr=document.documentElement.scrollTop+window.innerHeight;ur-Object(r.a)()<=jr||Bt>=jr-Ce?Lt(function(en){return Object(v.a)(Object(v.a)({},en),{},{isHiddenScrollBar:!0})}):Lt(function(en){return Object(v.a)(Object(v.a)({},en),{},{isHiddenScrollBar:!1})})},an=function(Bt){Lt(function(ur){return Object(v.a)(Object(v.a)({},ur),{},{scrollLeft:Bt/ye*we||0})})};return y.useImperativeHandle(Je,function(){return{setScrollLeft:an}}),y.useEffect(function(){var qr=Object(X.a)(document.body,"mouseup",Mr,!1),Bt=Object(X.a)(document.body,"mousemove",ln,!1);return Sr(),function(){qr.remove(),Bt.remove()}},[Ie,xt]),y.useEffect(function(){var qr=Object(X.a)(window,"scroll",Sr,!1),Bt=Object(X.a)(window,"resize",Sr,!1);return function(){qr.remove(),Bt.remove()}},[]),y.useEffect(function(){ct.isHiddenScrollBar||Lt(function(qr){var Bt,ur;return Object(v.a)(Object(v.a)({},qr),{},{scrollLeft:et.current.scrollLeft/((Bt=et.current)===null||Bt===void 0?void 0:Bt.scrollWidth)*((ur=et.current)===null||ur===void 0?void 0:ur.clientWidth)})})},[ct.isHiddenScrollBar]),ye<=we||!Ie||ct.isHiddenScrollBar?null:y.createElement("div",{style:{height:Object(r.a)(),width:we,bottom:Ce},className:"".concat(pe,"-sticky-scroll")},y.createElement("div",{onMouseDown:Ur,ref:ke,className:b()("".concat(pe,"-sticky-scroll-bar"),Object(N.a)({},"".concat(pe,"-sticky-scroll-bar-active"),xt)),style:{width:"".concat(Ie,"px"),transform:"translate3d(".concat(ct.scrollLeft,"px, 0, 0)")}}))},fe=y.forwardRef(ge);function Te(Pe,Se){return y.useMemo(function(){var Je=!!Pe;return{isSticky:Je,stickyClassName:Je?"".concat(Se,"-sticky-header"):"",offsetHeader:Object(M.a)(Pe)==="object"&&Pe.offsetHeader||0,offsetScroll:Object(M.a)(Pe)==="object"&&Pe.offsetScroll||0}},[Pe,Se])}var ze=[],Xe={},Ye="rc-table-internal-hook",rt=y.memo(function(Pe){var Se=Pe.children;return Se},function(Pe,Se){return d()(Pe.props,Se.props)?Pe.pingLeft!==Se.pingLeft||Pe.pingRight!==Se.pingRight:!1});function at(Pe){var Se,Je=Pe.prefixCls,nt=Pe.className,We=Pe.rowClassName,et=Pe.style,Me=Pe.data,Ce=Pe.rowKey,Re=Pe.scroll,pe=Pe.tableLayout,ye=Pe.direction,we=Pe.title,Ie=Pe.footer,ke=Pe.summary,Ve=Pe.id,ut=Pe.showHeader,ct=Pe.components,Lt=Pe.emptyText,Dt=Pe.onRow,Er=Pe.onHeaderRow,rr=Pe.internalHooks,xt=Pe.transformColumns,kr=Pe.internalRefs,Mr=Pe.sticky,Ur=Me||ze,ln=!!Ur.length,Sr=y.useState(0),an=Object(m.a)(Sr,2),qr=an[0],Bt=an[1];y.useEffect(function(){Bt(Object(r.a)())});var ur=y.useMemo(function(){return Object(S.c)(ct,{})},[ct]),jr=y.useCallback(function(Tr,Ot){return Object(S.b)(ur,Tr)||Ot},[ur]),en=y.useMemo(function(){return typeof Ce=="function"?Ce:function(Tr){var Ot=Tr&&Tr[Ce];return Ot}},[Ce]),Jr=Object(_.c)(Pe),_a=Jr.expandIcon,Wa=Jr.expandedRowKeys,_n=Jr.defaultExpandedRowKeys,er=Jr.defaultExpandAllRows,Xn=Jr.expandedRowRender,Ea=Jr.onExpand,Pn=Jr.onExpandedRowsChange,Qr=Jr.expandRowByClick,Ln=Jr.rowExpandable,la=Jr.expandIconColumnIndex,fa=Jr.expandedRowClassName,It=Jr.childrenColumnName,dr=Jr.indentSize,ha=_a||te,xa=It||"children",Pa=y.useMemo(function(){return Xn?"row":Pe.expandable&&rr===Ye&&Pe.expandable.__PARENT_RENDER_ICON__||Ur.some(function(Tr){return Tr&&Object(M.a)(Tr)==="object"&&Tr[xa]})?"nest":!1},[!!Xn,Ur]),pa=y.useState(function(){return _n||(er?J(Ur,en,xa):[])}),kn=Object(m.a)(pa,2),xr=kn[0],ta=kn[1],Ct=y.useMemo(function(){return new Set(Wa||xr||[])},[Wa,xr]),Vn=y.useCallback(function(Tr){var Ot=en(Tr,Ur.indexOf(Tr)),Ht,or=Ct.has(Ot);or?(Ct.delete(Ot),Ht=Object(C.a)(Ct)):Ht=[].concat(Object(C.a)(Ct),[Ot]),ta(Ht),Ea&&Ea(!or,Tr),Pn&&Pn(Ht)},[en,Ct,Ur,Ea,Pn]),Mn=y.useState(0),Ka=Object(m.a)(Mn,2),Ta=Ka[0],Qn=Ka[1],Qa=Object(le.b)(Object(v.a)(Object(v.a)(Object(v.a)({},Pe),Jr),{},{expandable:!!Xn,expandedKeys:Ct,getRowKey:en,onTriggerExpand:Vn,expandIcon:ha,expandIconColumnIndex:la,direction:ye}),rr===Ye?xt:null),Za=Object(m.a)(Qa,2),ra=Za[0],wn=Za[1],na=y.useMemo(function(){return{columns:ra,flattenColumns:wn}},[ra,wn]),ka=y.useRef(),ma=y.useRef(),va=y.useRef(),Di=y.useState(!1),Xa=Object(m.a)(Di,2),jn=Xa[0],za=Xa[1],_i=y.useState(!1),Ma=Object(m.a)(_i,2),aa=Ma[0],oi=Ma[1],pi=ae(new Map),si=Object(m.a)(pi,2),mi=si[0],qa=si[1],wa=Object(S.a)(wn),ei=wa.map(function(Tr){return mi.get(Tr)}),Ei=y.useMemo(function(){return ei},[ei.join("_")]),mt=ue(Ei,wn.length,ye),qe=Re&&Object(S.d)(Re.y),pt=Re&&Object(S.d)(Re.x),_t=pt&&wn.some(function(Tr){var Ot=Tr.fixed;return Ot}),Ut=y.useRef(),At=Te(Mr,Je),Xt=At.isSticky,kt=At.offsetHeader,st=At.offsetScroll,gt=At.stickyClassName,bt,tr,Jt;qe&&(tr={overflowY:"scroll",maxHeight:Re.y}),pt&&(bt={overflowX:"auto"},qe||(tr={overflowY:"hidden"}),Jt={width:Re.x===!0?"auto":Re.x,minWidth:"100%"});var Wt=y.useCallback(function(Tr,Ot){qa(function(Ht){var or=new Map(Ht);return or.set(Tr,Ot),or})},[]),jt=ie(null),Vt=Object(m.a)(jt,2),Zt=Vt[0],Ze=Vt[1];function vr(Tr,Ot){if(!Ot)return;typeof Ot=="function"?Ot(Tr):Ot.scrollLeft!==Tr&&(Ot.scrollLeft=Tr)}var Or=function(Ot){var Ht=Ot.currentTarget,or=Ot.scrollLeft,Gt=typeof or=="number"?or:Ht.scrollLeft,lt=Ht||Xe;if(!Ze()||Ze()===lt){var dt;Zt(lt),vr(Gt,ma.current),vr(Gt,va.current),vr(Gt,(dt=Ut.current)===null||dt===void 0?void 0:dt.setScrollLeft)}if(Ht){var Mt=Ht.scrollWidth,Tt=Ht.clientWidth;za(Gt>0),oi(Gt<Mt-Tt)}},nr=function(){va.current&&Or({currentTarget:va.current})},ft=function(Ot){var Ht=Ot.width;nr(),Qn(ka.current?ka.current.offsetWidth:Ht)};y.useEffect(function(){return nr},[]),y.useEffect(function(){pt&&nr()},[pt]),y.useEffect(function(){rr===Ye&&kr&&(kr.body.current=va.current)});var yt=jr(["table"],"table"),ht=y.useMemo(function(){return pe||(_t?Re.x==="max-content"?"auto":"fixed":qe||wn.some(function(Tr){var Ot=Tr.ellipsis;return Ot})?"fixed":"auto")},[qe,_t,wn,pe]),wt,Kt={colWidths:Ei,columCount:wn.length,stickyOffsets:mt,onHeaderRow:Er,fixHeader:qe},ar=y.useMemo(function(){return ln?null:typeof Lt=="function"?Lt():Lt},[ln,Lt]),zt=y.createElement(xe,{data:Ur,measureColumnWidth:qe||pt||Xt,expandedKeys:Ct,rowExpandable:Ln,getRowKey:en,onRow:Dt,emptyNode:ar,childrenColumnName:xa}),gr=y.createElement(T,{colWidths:wn.map(function(Tr){var Ot=Tr.width;return Ot}),columns:wn}),Rr=ke&&y.createElement(Ee.b,null,ke(Ur)),lr=jr(["body"]);if(qe||Xt){var Qe;typeof lr=="function"?(Qe=lr(Ur,{scrollbarSize:qr,ref:va,onScroll:Or}),Kt.colWidths=wn.map(function(Tr,Ot){var Ht=Tr.width,or=Ot===ra.length-1?Ht-qr:Ht;return typeof or=="number"&&!Number.isNaN(or)?or:(Object(n.a)(!1,"When use `components.body` with render props. Each column should have a fixed value."),0)})):Qe=y.createElement("div",{style:Object(v.a)(Object(v.a)({},bt),tr),onScroll:Or,ref:va,className:b()("".concat(Je,"-body"))},y.createElement(yt,{style:Object(v.a)(Object(v.a)({},Jt),{},{tableLayout:ht})},gr,zt,Rr),Xt&&y.createElement(fe,{ref:Ut,offsetScroll:st,scrollBodyRef:va,onScroll:Or})),wt=y.createElement(y.Fragment,null,ut!==!1&&y.createElement(P,Object.assign({noData:!Ur.length},Kt,na,{direction:ye,offsetHeader:kt,stickyClassName:gt,ref:ma,onScroll:Or})),Qe)}else wt=y.createElement("div",{style:Object(v.a)(Object(v.a)({},bt),tr),className:b()("".concat(Je,"-content")),onScroll:Or,ref:va},y.createElement(yt,{style:Object(v.a)(Object(v.a)({},Jt),{},{tableLayout:ht})},gr,ut!==!1&&y.createElement(g,Object.assign({},Kt,na)),zt,Rr));var Pt=Object(_.b)(Pe),Vr=y.createElement("div",Object.assign({className:b()(Je,nt,(Se={},Object(N.a)(Se,"".concat(Je,"-rtl"),ye==="rtl"),Object(N.a)(Se,"".concat(Je,"-ping-left"),jn),Object(N.a)(Se,"".concat(Je,"-ping-right"),aa),Object(N.a)(Se,"".concat(Je,"-layout-fixed"),pe==="fixed"),Object(N.a)(Se,"".concat(Je,"-fixed-header"),qe),Object(N.a)(Se,"".concat(Je,"-fixed-column"),_t),Object(N.a)(Se,"".concat(Je,"-scroll-horizontal"),pt),Object(N.a)(Se,"".concat(Je,"-has-fix-left"),wn[0]&&wn[0].fixed),Object(N.a)(Se,"".concat(Je,"-has-fix-right"),wn[wn.length-1]&&wn[wn.length-1].fixed==="right"),Se)),style:et,id:Ve,ref:ka},Pt),y.createElement(rt,{pingLeft:jn,pingRight:aa,props:Object(v.a)(Object(v.a)({},Pe),{},{stickyOffsets:mt,mergedExpandedKeys:Ct})},we&&y.createElement(ee,{className:"".concat(Je,"-title")},we(Ur)),y.createElement("div",{className:"".concat(Je,"-container")},wt),Ie&&y.createElement(ee,{className:"".concat(Je,"-footer")},Ie(Ur))));pt&&(Vr=y.createElement(c.a,{onResize:ft},Vr));var Hr=y.useMemo(function(){return{prefixCls:Je,getComponent:jr,scrollbarSize:qr,direction:ye,fixedInfoList:wn.map(function(Tr,Ot){return t(Ot,Ot,wn,mt,ye)}),isSticky:Xt}},[Je,jr,qr,ye,wn,mt,ye,Xt]),ir=y.useMemo(function(){return Object(v.a)(Object(v.a)({},na),{},{tableLayout:ht,rowClassName:We,expandedRowClassName:fa,componentWidth:Ta,fixHeader:qe,fixColumn:_t,horizonScroll:pt,expandIcon:ha,expandableType:Pa,expandRowByClick:Qr,expandedRowRender:Xn,onTriggerExpand:Vn,expandIconColumnIndex:la,indentSize:dr})},[na,ht,We,fa,Ta,qe,_t,pt,ha,Pa,Qr,Xn,Vn,la,dr]),br=y.useMemo(function(){return{onColumnResize:Wt}},[Wt]);return y.createElement(l.a.Provider,{value:Hr},y.createElement(W.Provider,{value:ir},y.createElement(Y.Provider,{value:br},Vr)))}at.Column=o.a,at.ColumnGroup=i.a,at.Summary=Ee.a,at.defaultProps={rowKey:"key",prefixCls:"rc-table",emptyText:function(){return"No Data"}};var ot=Q.b=at},wRmb:function(F,Q,j){"use strict";j.d(Q,"a",function(){return d});var N=j("rePB"),v=j("KQm4"),C=j("VTBJ"),M=j("Ff2n"),m=j("cDcd"),y=j.n(m),w=j("Kwbf"),b=j("Zm9Q"),p=j("hW8S");function d(o){return Object(b.a)(o).filter(function(u){return m.isValidElement(u)}).map(function(u){var f=u.key,s=u.props,l=s.children,t=Object(M.a)(s,["children"]),S=Object(C.a)({key:f},t);return l&&(S.children=d(l)),S})}function n(o){return o.reduce(function(u,f){var s=f.fixed,l=s===!0?"left":s,t=f.children;return t&&t.length>0?[].concat(Object(v.a)(u),Object(v.a)(n(t).map(function(S){return Object(C.a)({fixed:l},S)}))):[].concat(Object(v.a)(u),[Object(C.a)(Object(C.a)({},f),{},{fixed:l})])},[])}function c(o){for(var u=!0,f=0;f<o.length;f+=1){var s=o[f];if(u&&s.fixed!=="left")u=!1;else if(!u&&s.fixed==="left"){Object(w.a)(!1,"Index ".concat(f-1," of `columns` missing `fixed='left'` prop."));break}}for(var l=!0,t=o.length-1;t>=0;t-=1){var S=o[t];if(l&&S.fixed!=="right")l=!1;else if(!l&&S.fixed==="right"){Object(w.a)(!1,"Index ".concat(t+1," of `columns` missing `fixed='right'` prop."));break}}}function r(o){return o.map(function(u){var f=u.fixed,s=Object(M.a)(u,["fixed"]),l=f;return f==="left"?l="right":f==="right"&&(l="left"),Object(C.a)({fixed:l},s)})}function i(o,u){var f=o.prefixCls,s=o.columns,l=o.children,t=o.expandable,S=o.expandedKeys,x=o.getRowKey,h=o.onTriggerExpand,R=o.expandIcon,O=o.rowExpandable,g=o.expandIconColumnIndex,_=o.direction,E=o.expandRowByClick,T=m.useMemo(function(){return s||d(l)},[s,l]),L=m.useMemo(function(){if(t){var G,W=g||0,H=T[W],z=(G={},Object(N.a)(G,p.a,{className:"".concat(f,"-expand-icon-col")}),Object(N.a)(G,"title",""),Object(N.a)(G,"fixed",H?H.fixed:null),Object(N.a)(G,"className","".concat(f,"-row-expand-icon-cell")),Object(N.a)(G,"render",function(K,Y,ne){var oe=x(Y,ne),_e=S.has(oe),xe=O?O(Y):!0,le=R({prefixCls:f,expanded:_e,expandable:xe,record:Y,onExpand:h});return E?m.createElement("span",{onClick:function(de){return de.stopPropagation()}},le):le}),G),B=T.slice();return W>=0&&B.splice(W,0,z),B}return T},[t,T,x,S,R,_]),I=m.useMemo(function(){var G=L;return u&&(G=u(G)),G.length||(G=[{render:function(){return null}}]),G},[u,L,_]),P=m.useMemo(function(){return _==="rtl"?r(n(I)):n(I)},[I,_]);return[I,P]}Q.b=i},wZgz:function(F,Q,j){(function(N,v,C){F.exports=Q=v(j("Ib8C"),j("ETIr"),j("cv67"),j("K3mO"),j("OLod"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.BlockCipher,m=v.algo,y=[],w=[],b=[],p=[],d=[],n=[],c=[],r=[],i=[],o=[];(function(){for(var s=[],l=0;l<256;l++)l<128?s[l]=l<<1:s[l]=l<<1^283;for(var t=0,S=0,l=0;l<256;l++){var x=S^S<<1^S<<2^S<<3^S<<4;x=x>>>8^x&255^99,y[t]=x,w[x]=t;var h=s[t],R=s[h],O=s[R],g=s[x]*257^x*16843008;b[t]=g<<24|g>>>8,p[t]=g<<16|g>>>16,d[t]=g<<8|g>>>24,n[t]=g;var g=O*16843009^R*65537^h*257^t*16843008;c[x]=g<<24|g>>>8,r[x]=g<<16|g>>>16,i[x]=g<<8|g>>>24,o[x]=g,t?(t=h^s[s[s[O^h]]],S^=s[s[S]]):t=S=1}})();var u=[0,1,2,4,8,16,32,64,128,27,54],f=m.AES=M.extend({_doReset:function(){var s;if(this._nRounds&&this._keyPriorReset===this._key)return;for(var l=this._keyPriorReset=this._key,t=l.words,S=l.sigBytes/4,x=this._nRounds=S+6,h=(x+1)*4,R=this._keySchedule=[],O=0;O<h;O++)O<S?R[O]=t[O]:(s=R[O-1],O%S?S>6&&O%S==4&&(s=y[s>>>24]<<24|y[s>>>16&255]<<16|y[s>>>8&255]<<8|y[s&255]):(s=s<<8|s>>>24,s=y[s>>>24]<<24|y[s>>>16&255]<<16|y[s>>>8&255]<<8|y[s&255],s^=u[O/S|0]<<24),R[O]=R[O-S]^s);for(var g=this._invKeySchedule=[],_=0;_<h;_++){var O=h-_;if(_%4)var s=R[O];else var s=R[O-4];_<4||O<=4?g[_]=s:g[_]=c[y[s>>>24]]^r[y[s>>>16&255]]^i[y[s>>>8&255]]^o[y[s&255]]}},encryptBlock:function(s,l){this._doCryptBlock(s,l,this._keySchedule,b,p,d,n,y)},decryptBlock:function(s,l){var t=s[l+1];s[l+1]=s[l+3],s[l+3]=t,this._doCryptBlock(s,l,this._invKeySchedule,c,r,i,o,w);var t=s[l+1];s[l+1]=s[l+3],s[l+3]=t},_doCryptBlock:function(s,l,t,S,x,h,R,O){for(var g=this._nRounds,_=s[l]^t[0],E=s[l+1]^t[1],T=s[l+2]^t[2],L=s[l+3]^t[3],I=4,P=1;P<g;P++){var G=S[_>>>24]^x[E>>>16&255]^h[T>>>8&255]^R[L&255]^t[I++],W=S[E>>>24]^x[T>>>16&255]^h[L>>>8&255]^R[_&255]^t[I++],H=S[T>>>24]^x[L>>>16&255]^h[_>>>8&255]^R[E&255]^t[I++],z=S[L>>>24]^x[_>>>16&255]^h[E>>>8&255]^R[T&255]^t[I++];_=G,E=W,T=H,L=z}var G=(O[_>>>24]<<24|O[E>>>16&255]<<16|O[T>>>8&255]<<8|O[L&255])^t[I++],W=(O[E>>>24]<<24|O[T>>>16&255]<<16|O[L>>>8&255]<<8|O[_&255])^t[I++],H=(O[T>>>24]<<24|O[L>>>16&255]<<16|O[_>>>8&255]<<8|O[E&255])^t[I++],z=(O[L>>>24]<<24|O[_>>>16&255]<<16|O[E>>>8&255]<<8|O[T&255])^t[I++];s[l]=G,s[l+1]=W,s[l+2]=H,s[l+3]=z},keySize:256/32});v.AES=M._createHelper(f)}(),N.AES})},wbyO:function(F,Q,j){(function(N,v){F.exports=Q=v(j("Ib8C"))})(this,function(N){return function(){var v=N,C=v.lib,M=C.WordArray,m=v.enc,y=m.Base64url={stringify:function(b,p=!0){var d=b.words,n=b.sigBytes,c=p?this._safe_map:this._map;b.clamp();for(var r=[],i=0;i<n;i+=3)for(var o=d[i>>>2]>>>24-i%4*8&255,u=d[i+1>>>2]>>>24-(i+1)%4*8&255,f=d[i+2>>>2]>>>24-(i+2)%4*8&255,s=o<<16|u<<8|f,l=0;l<4&&i+l*.75<n;l++)r.push(c.charAt(s>>>6*(3-l)&63));var t=c.charAt(64);if(t)for(;r.length%4;)r.push(t);return r.join("")},parse:function(b,p=!0){var d=b.length,n=p?this._safe_map:this._map,c=this._reverseMap;if(!c){c=this._reverseMap=[];for(var r=0;r<n.length;r++)c[n.charCodeAt(r)]=r}var i=n.charAt(64);if(i){var o=b.indexOf(i);o!==-1&&(d=o)}return w(b,d,c)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function w(b,p,d){for(var n=[],c=0,r=0;r<p;r++)if(r%4){var i=d[b.charCodeAt(r-1)]<<r%4*2,o=d[b.charCodeAt(r)]>>>6-r%4*2,u=i|o;n[c>>>2]|=u<<24-c%4*8,c++}return M.create(n,c)}}(),N.enc.Base64url})},"y0+3":function(F,Q,j){"use strict";j.d(Q,"a",function(){return n}),j.d(Q,"b",function(){return r});var N=/margin|padding|width|height|max|min|offset/,v={left:!0,top:!0},C={cssFloat:1,styleFloat:1,float:1};function M(i){return i.nodeType===1?i.ownerDocument.defaultView.getComputedStyle(i,null):{}}function m(i,o,u){if(o=o.toLowerCase(),u==="auto"){if(o==="height")return i.offsetHeight;if(o==="width")return i.offsetWidth}return o in v||(v[o]=N.test(o)),v[o]?parseFloat(u)||0:u}function y(i,o){var u=arguments.length,f=M(i);return o=C[o]?"cssFloat"in i.style?"cssFloat":"styleFloat":o,u===1?f:m(i,o,f[o]||i.style[o])}function w(i,o,u){var f=arguments.length;if(o=C[o]?"cssFloat"in i.style?"cssFloat":"styleFloat":o,f===3)return typeof u=="number"&&N.test(o)&&(u="".concat(u,"px")),i.style[o]=u,u;for(var s in o)o.hasOwnProperty(s)&&w(i,s,o[s]);return M(i)}function b(i){return i===document.body?document.documentElement.clientWidth:i.offsetWidth}function p(i){return i===document.body?window.innerHeight||document.documentElement.clientHeight:i.offsetHeight}function d(){var i=Math.max(document.documentElement.scrollWidth,document.body.scrollWidth),o=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);return{width:i,height:o}}function n(){var i=document.documentElement.clientWidth,o=window.innerHeight||document.documentElement.clientHeight;return{width:i,height:o}}function c(){return{scrollLeft:Math.max(document.documentElement.scrollLeft,document.body.scrollLeft),scrollTop:Math.max(document.documentElement.scrollTop,document.body.scrollTop)}}function r(i){var o=i.getBoundingClientRect(),u=document.documentElement;return{left:o.left+(window.pageXOffset||u.scrollLeft)-(u.clientLeft||document.body.clientLeft||0),top:o.top+(window.pageYOffset||u.scrollTop)-(u.clientTop||document.body.clientTop||0)}}},zrhs:function(F,Q,j){"use strict";var N=j("2qtc"),v=j("kLXV"),C=j("PpiC"),M=j("cDcd"),m=j.n(M),y=j("9kvl"),w=function(p){var d=p.shixunsDetail,n=p.globalSetting,c=p.loading,r=p.dispatch,i=Object(C.a)(p,["shixunsDetail","globalSetting","loading","dispatch"]);return m.a.createElement(v.a,{centered:!0,keyboard:!1,closable:!1,zIndex:6666,title:"\u63D0\u793A",visible:d.actionTabs.key==="Banner-Auth",okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",onOk:function(){r({type:"shixunsDetail/setActionTabs",payload:{}}),window.location.href="/account/certification"},onCancel:function(){r({type:"shixunsDetail/setActionTabs",payload:{}})}},m.a.createElement("p",{className:"tc font16"},"\u5F53\u524D\u7ADE\u8D5B\u9700\u8981\u5B9E\u540D\u8BA4\u8BC1\uFF0C\u8BF7\u5148\u5B8C\u6210\u5B9E\u540D\u8BA4\u8BC1\u540E\u518D\u62A5\u540D\u53C2\u8D5B",m.a.createElement("br",null),"\u8BF7\u95EE\u662F\u5426\u524D\u5F80\u8FDB\u884C\u8BA4\u8BC1\uFF1F"))};Q.a=Object(y.a)(function(b){var p=b.shixunsDetail,d=b.loading,n=b.globalSetting;return{shixunsDetail:p,globalSetting:n,loading:d.models.index}})(w)}}]);