|
|
(self.webpackChunk=self.webpackChunk||[]).push([[7460],{10906:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ee}});var ce=be(32855),ie=be(59301),Ce={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M904 512h-56c-4.4 0-8 3.6-8 8v320H184V184h320c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V520c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M355.9 534.9L354 653.8c-.1 8.9 7.1 16.2 16 16.2h.4l118-2.9c2-.1 4-.9 5.4-2.3l415.9-415c3.1-3.1 3.1-8.2 0-11.3L785.4 114.3c-1.6-1.6-3.6-2.3-5.7-2.3s-4.1.8-5.7 2.3l-415.8 415a8.3 8.3 0 00-2.3 5.6zm63.5 23.6L779.7 199l45.2 45.1-360.5 359.7-45.7 1.1.7-46.4z"}}]},name:"form",theme:"outlined"},ue=Ce,se=be(7657),te=function(E,b){return ie.createElement(se.Z,(0,ce.Z)({},E,{ref:b,icon:ue}))},le=ie.forwardRef(te),ee=le},76618:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ee}});var ce=be(32855),ie=be(59301),Ce={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M705.6 124.9a8 8 0 00-11.6 7.2v64.2c0 5.5 2.9 10.6 7.5 13.6a352.2 352.2 0 0162.2 49.8c32.7 32.8 58.4 70.9 76.3 113.3a355 355 0 0127.9 138.7c0 48.1-9.4 94.8-27.9 138.7a355.92 355.92 0 01-76.3 113.3 353.06 353.06 0 01-113.2 76.4c-43.8 18.6-90.5 28-138.5 28s-94.7-9.4-138.5-28a353.06 353.06 0 01-113.2-76.4A355.92 355.92 0 01184 650.4a355 355 0 01-27.9-138.7c0-48.1 9.4-94.8 27.9-138.7 17.9-42.4 43.6-80.5 76.3-113.3 19-19 39.8-35.6 62.2-49.8 4.7-2.9 7.5-8.1 7.5-13.6V132c0-6-6.3-9.8-11.6-7.2C178.5 195.2 82 339.3 80 506.3 77.2 745.1 272.5 943.5 511.2 944c239 .5 432.8-193.3 432.8-432.4 0-169.2-97-315.7-238.4-386.7zM480 560h64c4.4 0 8-3.6 8-8V88c0-4.4-3.6-8-8-8h-64c-4.4 0-8 3.6-8 8v464c0 4.4 3.6 8 8 8z"}}]},name:"poweroff",theme:"outlined"},ue=Ce,se=be(7657),te=function(E,b){return ie.createElement(se.Z,(0,ce.Z)({},E,{ref:b,icon:ue}))},le=ie.forwardRef(te),ee=le},66543:function(){"use strict"},59598:function(){"use strict"},21697:function(Xt,Mt){"use strict";Mt.Z={lists:"lists___xhHyq",item:"item___pWJAA",children:"children___sDG61",diamond:"diamond___FwgzD",button:"button___WPN6r",mathWrap:"mathWrap___FmnMJ",mathFillWrap:"mathFillWrap___PmY3H"}},12085:function(Xt,Mt){"use strict";Mt.Z={header:"header___HqHSe",checkboxs:"checkboxs___ObBnD",field:"field___w_sM6","oj-form-container":"oj-form-container____odYP","oj-left-panel":"oj-left-panel___emEB2","oj-form-info":"oj-form-info___m00Ag",footer:"footer___O4iSJ",collapse:"collapse___Ltfkj","test-case-name":"test-case-name___miZcb","btn-remove-case":"btn-remove-case___cHap2","icon-tag":"icon-tag___gmyTb",btn_back:"btn_back___tNmX3",testJi:"testJi___L3fHb",upBtn:"upBtn___RGH6X",djs:"djs____TS0n",time:"time___IAdHc"}},45298:function(){"use strict"},60515:function(Xt,Mt,be){"use strict";var ce=be(59301),ie=Object.defineProperty,Ce=Object.getOwnPropertySymbols,ue=Object.prototype.hasOwnProperty,se=Object.prototype.propertyIsEnumerable,te=(ne,E,b)=>E in ne?ie(ne,E,{enumerable:!0,configurable:!0,writable:!0,value:b}):ne[E]=b,le=(ne,E)=>{for(var b in E||(E={}))ue.call(E,b)&&te(ne,b,E[b]);if(Ce)for(var b of Ce(E))se.call(E,b)&&te(ne,b,E[b]);return ne};const ee=ne=>React.createElement("svg",le({width:30,height:30,xmlns:"http://www.w3.org/2000/svg"},ne),React.createElement("title",null,"\u5360\u7528\u5185\u5B58"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{fillOpacity:.01,fill:"#FFF",d:"M0 0h30v30H0z"}),React.createElement("path",{d:"M6.866 26.928h-1.28a2.561 2.561 0 0 1-2.562-2.561V5.585a2.561 2.561 0 0 1 2.561-2.56h1.28v4.268a2.561 2.561 0 0 0 2.562 2.56h3.842a2.561 2.561 0 0 0 2.56-2.56V3.024h2.915l8.184 8.184v13.159a2.561 2.561 0 0 1-2.561 2.561h-1.28v-5.976c0-.943-.765-1.707-1.708-1.707H8.573c-.943 0-1.707.764-1.707 1.707v5.976Z",fill:"#B6D0FC"}),React.createElement("path",{d:"M8.573 3.024h5.55v4.269a.854.854 0 0 1-.854.853H9.427a.854.854 0 0 1-.854-.853V3.024ZM8.573 26.928v-5.976H21.38v5.976z",fill:"#1890FF"})));Mt.Z="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMzAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBmaWxsLW9wYWNpdHk9Ii4wMSIgZmlsbD0iI0ZGRiIgZD0iTTAgMGgzMHYzMEgweiIvPjxwYXRoIGQ9Ik02Ljg2NiAyNi45MjhoLTEuMjhhMi41NjEgMi41NjEgMCAwIDEtMi41NjItMi41NjFWNS41ODVhMi41NjEgMi41NjEgMCAwIDEgMi41NjEtMi41NmgxLjI4djQuMjY4YTIuNTYxIDIuNTYxIDAgMCAwIDIuNTYyIDIuNTZoMy44NDJhMi41NjEgMi41NjEgMCAwIDAgMi41Ni0yLjU2VjMuMDI0aDIuOTE1bDguMTg0IDguMTg0djEzLjE1OWEyLjU2MSAyLjU2MSAwIDAgMS0yLjU2MSAyLjU2MWgtMS4yOHYtNS45NzZjMC0uOTQzLS43NjUtMS43MDctMS43MDgtMS43MDdIOC41NzNjLS45NDMgMC0xLjcwNy43NjQtMS43MDcgMS43MDd2NS45NzZaIiBmaWxsPSIjQjZEMEZDIi8+PHBhdGggZD0iTTguNTczIDMuMDI0aDUuNTV2NC4yNjlhLjg1NC44NTQgMCAwIDEtLjg1NC44NTNIOS40MjdhLjg1NC44NTQgMCAwIDEtLjg1NC0uODUzVjMuMDI0Wk04LjU3MyAyNi45Mjh2LTUuOTc2SDIxLjM4djUuOTc2eiIgZmlsbD0iIzE4OTBGRiIvPjwvZz48L3N2Zz4="},88977:function(Xt,Mt,be){"use strict";var ce=be(59301),ie=Object.defineProperty,Ce=Object.getOwnPropertySymbols,ue=Object.prototype.hasOwnProperty,se=Object.prototype.propertyIsEnumerable,te=(ne,E,b)=>E in ne?ie(ne,E,{enumerable:!0,configurable:!0,writable:!0,value:b}):ne[E]=b,le=(ne,E)=>{for(var b in E||(E={}))ue.call(E,b)&&te(ne,b,E[b]);if(Ce)for(var b of Ce(E))se.call(E,b)&&te(ne,b,E[b]);return ne};const ee=ne=>React.createElement("svg",le({width:30,height:30,xmlns:"http://www.w3.org/2000/svg"},ne),React.createElement("title",null,"\u8FD0\u884C\u65F6\u95F4"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{d:"M30 15c0 8.284-6.716 15-15 15-8.284 0-15-6.716-15-15C0 6.716 6.716 0 15 0c8.284 0 15 6.716 15 15Z",fill:"#BAFFF0"}),React.createElement("path",{d:"M25.5 15c0 5.8-4.7 10.5-10.5 10.5S4.5 20.8 4.5 15 9.2 4.5 15 4.5 25.5 9.2 25.5 15Z",fill:"#44D7B6"}),React.createElement("path",{d:"M13.5 9a1.5 1.5 0 0 1 1.5 1.5v4.379l3.56 3.56a1.5 1.5 0 0 1-2.12 2.122l-4-4A1.5 1.5 0 0 1 12 15.5v-5A1.5 1.5 0 0 1 13.5 9Z",fill:"#FFF"})));Mt.Z="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMzAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNMzAgMTVjMCA4LjI4NC02LjcxNiAxNS0xNSAxNS04LjI4NCAwLTE1LTYuNzE2LTE1LTE1QzAgNi43MTYgNi43MTYgMCAxNSAwYzguMjg0IDAgMTUgNi43MTYgMTUgMTVaIiBmaWxsPSIjQkFGRkYwIi8+PHBhdGggZD0iTTI1LjUgMTVjMCA1LjgtNC43IDEwLjUtMTAuNSAxMC41UzQuNSAyMC44IDQuNSAxNSA5LjIgNC41IDE1IDQuNSAyNS41IDkuMiAyNS41IDE1WiIgZmlsbD0iIzQ0RDdCNiIvPjxwYXRoIGQ9Ik0xMy41IDlhMS41IDEuNSAwIDAgMSAxLjUgMS41djQuMzc5bDMuNTYgMy41NmExLjUgMS41IDAgMCAxLTIuMTIgMi4xMjJsLTQtNEExLjUgMS41IDAgMCAxIDEyIDE1LjV2LTVBMS41IDEuNSAwIDAgMSAxMy41IDlaIiBmaWxsPSIjRkZGIi8+PC9nPjwvc3ZnPg=="},11081:function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__;(function(){if(typeof window.GGBApplet=="function"){console.warn("deployggb.js was loaded twice");return}var isRenderGGBElementEnabled=!1,scriptLoadStarted=!1,html5AppletsToProcess=null,ggbHTML5LoadedCodebaseIsWebSimple=!1,ggbHTML5LoadedCodebaseVersion=null,ggbHTML5LoadedScript=null,GGBApplet=function(){"use strict";for(var Xt={},Mt="5.0",be={},ce=null,ie=!1,Ce=!1,ue=null,se=!1,te=null,le=null,ee=0;ee<arguments.length;ee++){var ne=arguments[ee];if(ne!==null)switch(typeof ne){case"number":Mt=ne.toFixed(1);break;case"string":ne.match(new RegExp("^[0-9]\\.[0-9]+$"))?Mt=ne:ue=ne;break;case"object":typeof ne.is3D!="undefined"?ce=ne:be=ne;break;case"boolean":ie=ne,Ce=!0;break}}ce===null&&(ce={is3D:!1,AV:!1,SV:!1,CV:!1,EV2:!1,CP:!1,PC:!1,DA:!1,FI:!1,PV:!1,macro:!1},be.material_id!==void 0&&!Ce&&(ie=!0)),ue!==null&&be.id===void 0&&(be.id=ue);var E="",b="",z=!1,x=null,re=null,ae=null,oe=!1,ve=null,ye=null,me=null,ge=null,_e=null;be.height!==void 0&&(be.height=Math.round(be.height)),be.width!==void 0&&(be.width=Math.round(be.width));var he=function(et){return parseFloat(et)>4?parseFloat(et):5};Xt.setHTML5Codebase=function(et,pt){le=et,Ve(et,pt)},Xt.setJavaCodebase=Xt.setJavaCodebaseVersion=Xt.isCompiledInstalled=Xt.setPreCompiledScriptPath=Xt.setPreCompiledResourcePath=function(){},Xt.setHTML5CodebaseVersion=function(et,pt){var ct=parseFloat(et);if(ct!==NaN&&ct<5){console.log("The GeoGebra HTML5 codebase version "+ct+" is deprecated. Using version latest instead.");return}te=et,ze(et,pt)},Xt.getHTML5CodebaseVersion=function(){return re},Xt.getParameters=function(){return be},Xt.setFontsCSSURL=function(et){ge=et},Xt.setGiacJSURL=function(et){},Xt.setJNLPFile=function(et){E=et},Xt.setJNLPBaseDir=function(et){},Xt.inject=function(){function et(){return window.frameElement&&window.frameElement.getAttribute("data-singleton")}for(var pt="auto",ct=be.id,Ot,dt=!1,Rt=0;Rt<arguments.length;Rt++){var xt=arguments[Rt];typeof xt=="string"?(xt=xt.toLowerCase(),xt.match(/^(prefer)?(java|html5|compiled|auto|screenshot)$/)?pt=xt:ct=arguments[Rt]):typeof xt=="boolean"?dt=xt:xt instanceof HTMLElement&&(Ot=xt)}gt();function gt(){if(!se){setTimeout(gt,200);return}pt=ut(pt);var _t=Ot||document.getElementById(ct);if(!_t){console.log("possibly bug on ajax loading? ");return}if(Xt.removeExistingApplet(_t,!1),be.width===void 0&&_t.clientWidth&&(be.width=_t.clientWidth),be.height===void 0&&_t.clientHeight&&(be.height=_t.clientHeight),!(be.width&&be.height)&&pt==="html5"&&(delete be.width,delete be.height),x=pt,pt==="screenshot")Xe(_t,be);else{var We=!1;be.hasOwnProperty("playButton")&&be.playButton||be.hasOwnProperty("clickToLoad")&&be.clickToLoad?We=!0:be.hasOwnProperty("playButtonAutoDecide")&&be.playButtonAutoDecide&&(We=(!pe()||et())&&ke()),We?(x="screenshot",He(_t,be,dt,pt)):Qe(_t,be,dt)}}};function pe(){try{return window.self!==window.top}catch(et){return!0}}function ke(){return be.hasOwnProperty("screenshotGenerator")&&be.screenshotGenerator?!1:Math.max(screen.width,screen.height)<800}Xt.getViews=function(){return ce},Xt.isJavaInstalled=function(){return!1};var Te=function(et){var pt=function(Rt){var xt=JSON.parse(Rt),gt=function(Ae){return Ae.type=="G"||Ae.type=="E"},_t=xt.elements?xt.elements.filter(gt)[0]:xt;if(!_t||!_t.url){ct();return}be.fileName=_t.url,Ee(_t.settings||{}),ce.is3D=!0;var We="https://www.geogebra.org/images/";Xt.setPreviewImage(ve||_t.previewUrl,We+"GeoGebra_loading.png",We+"applet_play.png"),et()},ct=function(){be.onError&&be.onError(),$e("Error: Fetching material (id "+be.material_id+") failed.",be)},Ot=location.host.match(/(www|stage|beta|groot|alpha).geogebra.(org|net)/)?location.host:"www.geogebra.org",dt="/materials/"+be.material_id+"?scope=basic";Oe("https://"+Ot+"/api/proxy.php?path="+encodeURIComponent(dt),pt,ct)};function Ee(et){var pt=["width","height","showToolBar","showMenuBar","showAlgebraInput","allowStyleBar","showResetIcon","enableLabelDrags","enableShiftDragZoom","enableRightClick","appName"];["enableLabelDrags","enableShiftDragZoom","enableRightClick"].forEach(function(ct){et[ct]=!!et[ct]}),pt.forEach(function(ct){be[ct]===void 0&&et[ct]!==void 0&&(be[ct]=et[ct])}),be.showToolBarHelp===void 0&&(be.showToolBarHelp=be.showToolBar)}function Oe(et,pt,ct){var Ot=new XMLHttpRequest;Ot.open("GET",et),Ot.onload=function(){pt(Ot.responseText)},Ot.onerror=ct,Ot.send()}Xt.isHTML5Installed=function(){return!0},Xt.getLoadedAppletType=function(){return x},Xt.setPreviewImage=function(et,pt,ct){ve=et,ye=pt,me=ct},Xt.removeExistingApplet=function(et,pt){var ct;typeof et=="string"&&(et=document.getElementById(et)),x=null;var Ot=null;for(ct=0;ct<et.childNodes.length;ct++){var dt=et.childNodes[ct],Rt=dt.className;Rt==="applet_screenshot"?pt?(dt.style.display="block",x="screenshot"):dt.style.display="none":Rt!=="applet_scaler prerender"&&(et.removeChild(dt),Ot=Rt&&Rt.indexOf("appletParameters")!=-1?dt.id:null,ct--)}var xt=be.id!==void 0?be.id:Ot,gt=window[xt];gt&&typeof gt.getBase64=="function"&&(gt.remove(),window[xt]=null)},Xt.refreshHitPoints=function(){if(he(ggbHTML5LoadedCodebaseVersion)>=5)return!0;var et=Xt.getAppletObject();return et&&typeof et.recalculateEnvironments=="function"?(et.recalculateEnvironments(),!0):!1},Xt.startAnimation=function(){var et=Xt.getAppletObject();return et&&typeof et.startAnimation=="function"?(et.startAnimation(),!0):!1},Xt.stopAnimation=function(){var et=Xt.getAppletObject();return et&&typeof et.stopAnimation=="function"?(et.stopAnimation(),!0):!1},Xt.getAppletObject=function(){var et=be.id!==void 0?be.id:"ggbApplet";return window[et]},Xt.resize=function(){};var je=function(et,pt,ct){var Ot=document.createElement("param");Ot.setAttribute("name",pt),Ot.setAttribute("value",ct),et.appendChild(Ot)},Pe=function(et){return et&&et!=="false"},Qe=function(et,pt,ct){he(re)<=4.2&&(ct=!0);var Ot=!isRenderGGBElementEnabled&&!scriptLoadStarted;(!isRenderGGBElementEnabled&&!scriptLoadStarted||ggbHTML5LoadedCodebaseVersion!==re||ggbHTML5LoadedCodebaseIsWebSimple&&!oe)&&(Ot=!0,isRenderGGBElementEnabled=!1,scriptLoadStarted=!1);var dt=document.createElement("div");dt.classList.add("appletParameters","notranslate");var Rt=pt.width,xt=pt.height;if(pt.disableAutoScale=pt.disableAutoScale===void 0?GGBAppletUtils.isFlexibleWorksheetEditor():pt.disableAutoScale,pt.width!==void 0)if(he(re)<=4.4)Pe(pt.showToolBar)&&(pt.height-=7),Pe(pt.showAlgebraInput)&&(pt.height-=37),pt.width<605&&Pe(pt.showToolBar)&&(pt.width=605,Rt=605);else{var gt=100;(Pe(pt.showToolBar)||Pe(pt.showMenuBar))&&(pt.hasOwnProperty("customToolBar")&&(pt.customToolbar=pt.customToolBar),gt=Pe(pt.showMenuBar)?245:155),Rt<gt&&(pt.width=gt,Rt=gt)}dt.style.border="none",dt.style.display="inline-block";for(var _t in pt)pt.hasOwnProperty(_t)&&_t!=="appletOnLoad"&&dt.setAttribute("data-param-"+_t,pt[_t]);ge&&dt.setAttribute("data-param-fontscssurl",ge),Xt.resize=function(){GGBAppletUtils.responsiveResize(et,pt)},window.addEventListener("resize",function(tt){Xt.resize()});var We=typeof pt.appletOnLoad=="function"?pt.appletOnLoad:function(){};if(!ct&&pt.width!==void 0){pt.hasOwnProperty("showSplash")||dt.setAttribute("data-param-showSplash","false");var Ae=et.querySelector(".applet_scaler.prerender"),Se=Ae!==null;if(Se)var Be=Ae.querySelector(".ggb_preview");else{var Be=Ye(Rt,xt,pt.borderColor,!1);Ae=document.createElement("div"),Ae.className="applet_scaler",Ae.style.position="relative",Ae.style.display="block",Ae.style.width=Rt+"px",Ae.style.height=xt+"px"}window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(Ae,"66%"),he(re)>=5?(pt.appletOnLoad=function(tt){var lt=et.querySelector(".ggb_preview");lt&<.parentNode.removeChild(lt),window.GGBT_spinner&&window.GGBT_spinner.removeSpinner(Ae),window.GGBT_wsf_view&&$(window).trigger("resize"),We(tt)},Se||Ae.appendChild(Be)):dt.appendChild(Be),Ae.appendChild(dt),Se||et.appendChild(Ae),setTimeout(function(){Xt.resize()},1)}else{var Ke=document.createElement("div");Ke.className="applet_scaler",Ke.style.position="relative",Ke.style.display="block",Ke.appendChild(dt),et.appendChild(Ke),pt.appletOnLoad=function(tt){Xt.resize(),We(tt)}}function Ne(tt,lt){lt&&typeof lt.appletOnLoad=="function"&&typeof renderGGBElement=="function"?renderGGBElement(tt,lt.appletOnLoad):renderGGBElement(tt),$e("GeoGebra HTML5 applet injected and rendered with previously loaded codebase.",lt)}function De(tt,lt){typeof renderGGBElement=="undefined"?(html5AppletsToProcess===null&&(html5AppletsToProcess=[]),html5AppletsToProcess.push({article:tt,params:lt}),window.renderGGBElementReady=function(){isRenderGGBElementEnabled=!0,html5AppletsToProcess!==null&&html5AppletsToProcess.length&&(html5AppletsToProcess.forEach(function(Nt){Ne(Nt.article,Nt.params)}),html5AppletsToProcess=null)},he(re)<5&&(tt.className+=" geogebraweb")):Ne(tt,lt)}if(Ot){scriptLoadStarted=!0;for(var we=0;we<dt.childNodes.length;we++){var Le=dt.childNodes[we].tagName;Le==="TABLE"&&(dt.removeChild(dt.childNodes[we]),we--)}if(ggbHTML5LoadedScript!==null){var Ue=document.querySelector('script[src="'+ggbHTML5LoadedScript+'"]');Ue!=null&&Ue.parentNode.removeChild(Ue)}var Me=document.createElement("script"),Re=function(){De(dt,pt)};Me.src=b+ae,ggbHTML5LoadedCodebaseIsWebSimple=oe,ggbHTML5LoadedCodebaseVersion=re,ggbHTML5LoadedScript=Me.src,$e("GeoGebra HTML5 codebase loaded: '"+b+"'.",pt),!le&&(!te||te=="5.0")?(oe?webSimple.succeeded=webSimple.succeeded||webSimple():web3d.succeeded=web3d.succeeded||web3d(),Re()):b.requirejs?__webpack_require__.e(981).then(function(){var tt=[__webpack_require__(60981)];Re.apply(null,tt)}.bind(this)).catch(__webpack_require__.oe):(Me.onload=Re,et.appendChild(Me))}else De(dt,pt);pt.height=xt,pt.width=Rt},Xe=function(et,pt,ct){var Ot=Ye(pt.width,pt.height,pt.borderColor,ct),dt=document.createElement("div");dt.style.position="relative",dt.style.display="block",dt.style.width=pt.width+"px",dt.style.height=pt.height+"px",dt.className="applet_screenshot applet_scaler"+(ct?" applet_screenshot_play":""),dt.appendChild(Ot);var Rt=GGBAppletUtils.getScale(pt,et,ct);ct?(et.appendChild(rt()),window.GGBT_wsf_view||(et.style.position="relative")):window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(dt,"66%"),et.appendChild(dt),Rt!==1&&!isNaN(Rt)&&(GGBAppletUtils.scaleElement(dt,Rt),dt.style.width=pt.width+"px",dt.style.height=pt.height+"px",dt.parentNode.style.width=pt.width*Rt+"px",dt.parentNode.style.height=pt.height*Rt+"px"),Xt.resize=function(){ot(et,Ot,dt,ct)},window.addEventListener("resize",function(xt){Xt.resize()}),Xt.resize()};function ot(et,pt,ct,Ot){if(et.contains(pt)){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(et.id!=="fullscreencontent")return;window.GGBT_wsf_view.setCloseBtnPosition(et)}var dt=GGBAppletUtils.getScale(be,et,Ot);ct.parentNode!==null&&(!isNaN(dt)&&dt!==1?(GGBAppletUtils.scaleElement(ct,dt),ct.parentNode.style.width=be.width*dt+"px",ct.parentNode.style.height=be.height*dt+"px"):(GGBAppletUtils.scaleElement(ct,1),ct.parentNode.style.width=be.width+"px",ct.parentNode.style.height=be.height+"px")),typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&GGBAppletUtils.positionCenter(et),typeof window.GGBT_ws_header_footer=="object"&&window.GGBT_ws_header_footer.setWsScrollerHeight()}}Xt.onExitFullscreen=function(et,pt){pt.appendChild(et)};var He=function(et,pt,ct,Ot){Xe(et,pt,!0);for(var dt=function(){var gt=[];for(xt=0;xt<et.childNodes.length;xt++)gt.push(et.childNodes[xt]);if(window.GGBT_wsf_view){var _t=window.GGBT_wsf_view.renderFullScreen(et,pt.id),We=document.getElementById("fullscreencontainer"),Ae=jQuery(et).find(".fullscreencontent");Ae.length>0?(_t.remove(),Ae.attr("id","fullscreencontent").show(),jQuery(We).append(Ae),window.dispatchEvent(new Event("resize"))):Qe(_t,pt,!1),window.GGBT_wsf_view.launchFullScreen(We)}else x=Ot,Qe(et,pt,!1);if(!window.GGBT_wsf_view)for(xt=0;xt<gt.length;xt++)et.removeChild(gt[xt])},Rt=et.getElementsByClassName("ggb_preview_play"),xt=0;xt<Rt.length;xt++)Rt[xt].addEventListener("click",dt,!1),Rt[xt].addEventListener("ontouchstart",dt,!1);typeof window.ggbAppletPlayerOnload=="function"&&window.ggbAppletPlayerOnload(et),ke()&&window.GGBT_wsf_view&&$(".wsf-element-fullscreen-button").remove()},rt=function(){var et=document.createElement("div");if(et.className="ggb_preview_play icon-applet-play",!window.GGBT_wsf_view){var pt='.icon-applet-play { width: 100%; height: 100%;box-sizing: border-box;position: absolute;z-index: 1001;cursor: pointer;border-width: 0px; background-color: transparent;background-repeat: no-repeat;left: 0;top: 0;background-position: center center; background-image: url("https://www.geogebra.org/images/worksheet/icon-start-applet.png");}.icon-applet-play:hover {background-image: url("https://www.geogebra.org/images/worksheet/icon-start-applet-hover.png");}',ct=document.createElement("style");ct.styleSheet?ct.styleSheet.cssText=pt:ct.appendChild(document.createTextNode(pt)),document.getElementsByTagName("head")[0].appendChild(ct)}return et},Ye=function(et,pt,ct,Ot){var dt=document.createElement("div");dt.className="ggb_preview",dt.style.position="absolute",dt.style.zIndex="90",dt.style.width=et-2+"px",dt.style.height=pt-2+"px",dt.style.top="0px",dt.style.left="0px",dt.style.overflow="hidden",dt.style.backgroundColor="white";var Rt="lightgrey";ct!==void 0&&(ct==="none"?Rt="transparent":Rt=ct),dt.style.border="1px solid "+Rt;var xt=document.createElement("img");if(xt.style.position="relative",xt.style.zIndex="1000",xt.style.top="-1px",xt.style.left="-1px",ve!==null&&xt.setAttribute("src",ve),xt.style.opacity=.7,ye!==null){var gt,_t,We;if(!Ot){gt=document.createElement("img"),gt.style.position="absolute",gt.style.zIndex="1001",gt.style.opacity=1,xt.style.opacity=.3,_t=360,_t>et/4*3&&(_t=et/4*3),We=_t/5.8,gt.setAttribute("src",ye),gt.setAttribute("width",_t),gt.setAttribute("height",We);var Ae=(et-_t)/2,Se=(pt-We)/2;gt.style.left=Ae+"px",gt.style.top=Se+"px",dt.appendChild(gt)}}return dt.appendChild(xt),dt},ut=function(et){return et=et.toLowerCase(),et==="html5"||et==="screenshot"?et:"html5"},Ge=["web","webSimple","web3d","tablet","tablet3d","phone"],ze=function(et,pt){if(re=et,pt){Ve(re,!0);return}var ct=!ie;if(ct){var Ot=he(re);!isNaN(Ot)&&Ot<4.4&&(ct=!1)}var dt,Rt;window.location.protocol.substr(0,4)==="http"?dt=window.location.protocol:dt="http:";var xt=re.indexOf("//");xt>0?Rt=re:xt===0?Rt=dt+re:Rt="https://www.geogebra.org/apps/5.2.814.0/";for(var gt in Ge)if(re.slice(Ge[gt].length*-1)===Ge[gt]||re.slice((Ge[gt].length+1)*-1)===Ge[gt]+"/"){Ve(Rt,!1);return}!GGBAppletUtils.isFlexibleWorksheetEditor()&&ct&&!ce.is3D&&!ce.AV&&!ce.SV&&!ce.CV&&!ce.EV2&&!ce.CP&&!ce.PC&&!ce.DA&&!ce.FI&&!ce.PV&&!Pe(be.showToolBar)&&!Pe(be.showMenuBar)&&!Pe(be.showAlgebraInput)&&!Pe(be.enableRightClick)&&(!be.appName||be.appName=="classic")?Rt+="webSimple/":Rt+="web3d/",Ve(Rt,!1)},Ve=function(et,pt){if(et.requirejs){b=et;return}et.slice(-1)!=="/"&&(et+="/"),b=et,pt===null&&(pt=et.indexOf("http")===-1),z=pt,ae="web.nocache.js",oe=!1;var ct=b.split("/");ct.length>1&&(!pt&&ct[ct.length-2]==="webSimple"?(ae="webSimple.nocache.js",oe=!0):Ge.indexOf(ct[ct.length-2])>=0&&(ae=ct[ct.length-2]+".nocache.js")),ct=et.split("/"),re=ct[ct.length-3],re.substr(0,4)==="test"?re=re.substr(4,1)+"."+re.substr(5,1):(re.substr(0,3)==="war"||re.substr(0,4)==="beta")&&(re="5.0");var Ot=parseFloat(re);Ot!==NaN&&Ot<5&&et.indexOf("geogebra.org")>=0&&(console.log("The GeoGebra HTML5 codebase version "+Ot+" is deprecated. Using version latest instead."),ze("5.0",pt))},$e=function(et,pt){window.console&&window.console.log&&(!pt||typeof pt.showLogging=="undefined"||pt.showLogging&&pt.showLogging!=="false")&&console.log(et)};be.material_id!==void 0?Te(nt):nt();function nt(){var et=Mt;te!==null?et=te:parseFloat(et)<5&&(et="5.0"),ze(et,!1),le!==null&&Ve(le,z),se=!0}return Xt},GGBAppletUtils=function(){"use strict";function Xt(){return window.GGBT_wsf_edit!==void 0}function Mt(se,te){te!=1?(se.style.transformOrigin="0% 0% 0px",se.style.webkitTransformOrigin="0% 0% 0px",se.style.transform="scale("+te+","+te+")",se.style.webkitTransform="scale("+te+","+te+")",se.style.maxWidth="initial",se.querySelector(".ggb_preview")!==null&&(se.querySelector(".ggb_preview").style.maxWidth="initial"),se.querySelectorAll(".ggb_preview img")[0]!==void 0&&(se.querySelectorAll(".ggb_preview img")[0].style.maxWidth="initial"),se.querySelectorAll(".ggb_preview img")[1]!==void 0&&(se.querySelectorAll(".ggb_preview img")[1].style.maxWidth="initial")):(se.style.transform="none",se.style.webkitTransform="none")}function be(se,te,le,ee,ne,E){var b=null;if(E!=null&&E!="")for(var z=se.parentNode;z!=null;)if((" "+z.className+" ").indexOf(" "+E+" ")>-1){b=z;break}else z=z.parentNode;var x=0,re=0,ae=0,oe=0,ve=0,ye=0,me=0;if(b)x=b.offsetWidth,re=Math.max(ee?b.offsetWidth:0,b.offsetHeight);else{if(window.innerWidth&&document.documentElement.clientWidth?(x=Math.min(window.innerWidth,document.documentElement.clientWidth),re=Math.min(window.innerHeight,document.documentElement.clientHeight),ae=x):(x=window.innerWidth,re=window.innerHeight,ae=window.innerWidth),se){var ge=se.getBoundingClientRect();ge.left>0&&ge.left<=x&&(ne===void 0||!ne)&&(document.dir==="rtl"?(ve=x-ge.width-ge.left,ye=ae<=480?10:30):(ye=ge.left,ve=ae<=480?10:30),oe=ye+ve)}if(se&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){var _e=se.getBoundingClientRect();window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(oe=40,me=0):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(oe=0,me=40)}}return se&&((le===void 0||!le)&&te>0&&te+oe<x?x=te:x-=oe,typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&(le===void 0||!le)&&(re-=me)),{width:x,height:re}}function ce(se,te,le,ee,ne){if(se.isScreenshoGenerator)return 1;var E=ee!==void 0&&ee,b=se.noScaleMargin!=null&&se.noScaleMargin,z=function(_e){return _e&&_e!=="false"},x=z(se.autoHeight),re=be(te,se.width,le,x,E&&window.GGBT_wsf_view||b,ne),ae=parseInt(re.width),oe=se.width,ve=se.height;if(oe===void 0){var ye=te.querySelector(".appletParameters");ye&&(oe=ye.offsetWidth,ve=ye.offsetHeight)}var me=ae/oe,ge=E?1:re.height/ve;return le!==void 0&&!le&&(me=Math.min(1,me),ge=Math.min(1,ge)),Math.min(me,ge)}function ie(se,te,le){var ee=1,ne,E=!1;if(se.hasOwnProperty("allowUpscale")&&(E=se.allowUpscale),se.hasOwnProperty("scale")&&(ee=parseFloat(se.scale),(isNaN(ee)||ee===null||ee===0)&&(ee=1),ee>1&&(E=!0)),te&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&(E=!0),!(se.hasOwnProperty("disableAutoScale")&&se.disableAutoScale))ne=ce(se,te,E,le,se.scaleContainerClass);else return ee;return E&&(!se.hasOwnProperty("scale")||ee===1)?ne:Math.min(ee,ne)}function Ce(se){var te=Math.min(window.innerWidth,document.documentElement.clientWidth),le=Math.min(window.innerHeight,document.documentElement.clientHeight),ee=se.getBoundingClientRect(),ne=(te-ee.width)/2,E=(le-ee.height)/2;E<0&&(E=0),se.style.position="relative",window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(ne<40?se.style.left="40px":se.style.left=ne+"px",se.style.top=E+"px"):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(E<40?se.style.top="40px":se.style.top=E+"px",se.style.left=ne+"px")}function ue(se,te){var le=se.querySelector(".appletParameters");if(le){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(te.id!==le.getAttribute("data-param-id"))return;window.GGBT_wsf_view.setCloseBtnPosition(se)}if(le.parentElement&&/fullscreen/.test(le.parentElement.className))return;var ee=ie(te,se);Xt()&&le.setAttribute("data-param-scale",ee);for(var ne=null,E=0;E<se.childNodes.length;E++)if(se.childNodes[E].className!==void 0&&se.childNodes[E].className.match(/^applet_scaler/)){ne=se.childNodes[E];break}if(ne!==null&&ne.querySelector(".noscale")!==null)return;var b=te.id!==void 0?te.id:"ggbApplet",z=window[b];(z==null||!z.recalculateEnvironments)&&ne!==null&&!ne.className.match(/fullscreen/)&&(ne.parentNode.style.transform="",!isNaN(ee)&&ee!==1?(ne.parentNode.style.width=te.width*ee+"px",ne.parentNode.style.height=te.height*ee+"px",Mt(ne,ee)):(Mt(ne,1),ne.parentNode.style.width=te.width+"px",ne.parentNode.style.height=te.height+"px")),typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&Ce(se),window.GGBT_wsf_view&&!window.GGBT_wsf_view.isFullscreen()&&window.GGBT_wsf_general.adjustContentToResize($(le).parents(".content-added-content"))}}return{responsiveResize:ue,isFlexibleWorksheetEditor:Xt,positionCenter:Ce,getScale:ie,scaleElement:Mt}}();__WEBPACK_AMD_DEFINE_ARRAY__=[],__WEBPACK_AMD_DEFINE_RESULT__=function(){return GGBApplet}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__),__WEBPACK_AMD_DEFINE_RESULT__!==void 0&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__),GGBAppletUtils.makeModule=function(name,permutation){function webModule(){var H="bootstrap",I="begin",J="gwt.codesvr."+name+"=",K="gwt.codesvr=",L=name,M="startup",N="DUMMY",O=0,P=1,Q="iframe",R="position:absolute; width:0; height:0; border:none; left: -1000px;",S=" top: -1000px;",T="Chrome",U="CSS1Compat",V="<!doctype html>",W="",X="<html><head></head><body></body></html>",Y="undefined",Z="readystatechange",$=10,_="script",ab="javascript",bb="Failed to load ",cb="moduleStartup",db="scriptTagAdded",eb="moduleRequested",fb="meta",gb="name",hb=name+"::",ib="::",jb="gwt:property",kb="content",lb="=",mb="gwt:onPropertyErrorFn",nb='Bad handler "',ob='" for "gwt:onPropertyErrorFn"',pb="gwt:onLoadErrorFn",qb='" for "gwt:onLoadErrorFn"',rb="#",sb="?",tb="/",ub="img",vb="clear.cache.gif",wb="baseUrl",xb=name+".nocache.js",yb="base",zb="//",Ab="selectingPermutation",Bb=name+".devmode.js",Cb=permutation,Db=":",Eb=".cache.js",Fb="loadExternalRefs",Gb="end",n=window,o=document;function p(){var Xt=n.location.search;return Xt.indexOf(J)!=-1||Xt.indexOf(K)!=-1}function q(Xt,Mt){}webModule.__sendStats=q,webModule.__moduleName=L,webModule.__errFn=null,webModule.__moduleBase=N,webModule.__softPermutationId=O,webModule.__computePropValue=null,webModule.__getPropMap=null,webModule.__installRunAsyncCode=function(){},webModule.__gwtStartLoadingFragment=function(){return null},webModule.__gwt_isKnownPropertyValue=function(){return!1},webModule.__gwt_getMetaProperty=function(){return null};var r=null,s=n.__gwt_activeModules=n.__gwt_activeModules||{};s[L]={moduleName:L},webModule.__moduleStartupDone=function(Xt){var Mt=s[L].bindings;s[L].bindings=function(){for(var be=Mt?Mt():{},ce=Xt[webModule.__softPermutationId],ie=O;ie<ce.length;ie++){var Ce=ce[ie];be[Ce[O]]=Ce[P]}return be}};var t;function u(){return v(),t}function v(){if(!t){var Xt=o.createElement(Q);if(Xt.id=L,Xt.style.cssText=R+S,Xt.tabIndex=-1,o.body.appendChild(Xt),t=Xt.contentWindow.document,navigator.userAgent.indexOf(T)==-1){t.open();var Mt=document.compatMode==U?V:W;t.write(Mt+X),t.close()}}}function w(Xt){function Mt(ce){function ie(){return typeof o.readyState==Y?typeof o.body!=Y&&o.body!=null:/loaded|complete/.test(o.readyState)}var Ce=ie();if(Ce){ce();return}function ue(){if(!Ce){if(!ie())return;Ce=!0,ce(),o.removeEventListener&&o.removeEventListener(Z,ue,!1),se&&clearInterval(se)}}o.addEventListener&&o.addEventListener(Z,ue,!1);var se=setInterval(function(){ue()},$)}function be(ce){var ie=u(),Ce=ie.body,ue=ie.createElement(_);ue.language=ab,ue.crossOrigin=W,ue.src=ce,webModule.__errFn&&(ue.onerror=function(){webModule.__errFn(L,new Error(bb+ce))}),Ce.appendChild(ue)}Mt(function(){be(Xt)})}webModule.__startLoadingFragment=function(Xt){return C(Xt)},webModule.__installRunAsyncCode=function(Xt){var Mt=u(),be=Mt.body,ce=Mt.createElement(_);ce.language=ab,ce.text=Xt,be.appendChild(ce),be.removeChild(ce)};function A(){for(var c={},d,e,f=o.getElementsByTagName(fb),g=O,h=f.length;g<h;++g){var i=f[g],j=i.getAttribute(gb),k;if(j){if(j=j.replace(hb,W),j.indexOf(ib)>=O)continue;if(j==jb){if(k=i.getAttribute(kb),k){var l,m=k.indexOf(lb);m>=O?(j=k.substring(O,m),l=k.substring(m+P)):(j=k,l=W),c[j]=l}}else if(j==mb){if(k=i.getAttribute(kb),k)try{d=eval(k)}catch(Xt){alert(nb+k+ob)}}else if(j==pb&&(k=i.getAttribute(kb),k))try{e=eval(k)}catch(Xt){alert(nb+k+qb)}}}__gwt_getMetaProperty=function(Xt){var Mt=c[Xt];return Mt==null?null:Mt},r=d,webModule.__errFn=e}function B(){function Xt(se){var te=se.lastIndexOf(rb);te==-1&&(te=se.length);var le=se.indexOf(sb);le==-1&&(le=se.length);var ee=se.lastIndexOf(tb,Math.min(le,te));return ee>=O?se.substring(O,ee+P):W}function Mt(se){if(!se.match(/^\w+:\/\//)){var te=o.createElement(ub);te.src=se+vb,se=Xt(te.src)}return se}function be(){var se=__gwt_getMetaProperty(wb);return se!=null?se:W}function ce(){for(var se=o.getElementsByTagName(_),te=O;te<se.length;++te)if(se[te].src.indexOf(xb)!=-1)return Xt(se[te].src);return W}function ie(){var se=o.getElementsByTagName(yb);return se.length>O?se[se.length-P].href:W}function Ce(){var se=o.location;return se.href==se.protocol+zb+se.host+se.pathname+se.search+se.hash}var ue=be();return ue==W&&(ue=ce()),ue==W&&(ue=ie()),ue==W&&Ce()&&(ue=Xt(o.location.href)),ue=Mt(ue),ue}function C(Xt){return Xt.match(/^\//)||Xt.match(/^[a-zA-Z]+:\/\//)?Xt:webModule.__moduleBase+Xt}function D(){var Xt=[],Mt=O,be=[],ce=[];function ie(se){var te=ce[se](),le=be[se];if(te in le)return te;var ee=[];for(var ne in le)ee[le[ne]]=ne;throw r&&r(se,ee,te),null}if(__gwt_isKnownPropertyValue=function(se,te){return te in be[se]},webModule.__getPropMap=function(){var se={};for(var te in be)be.hasOwnProperty(te)&&(se[te]=ie(te));return se},webModule.__computePropValue=ie,n.__gwt_activeModules[L].bindings=webModule.__getPropMap,p())return C(Bb);var Ce;try{Ce=Cb;var ue=Ce.indexOf(Db);ue!=-1&&(Mt=parseInt(Ce.substring(ue+P),$),Ce=Ce.substring(O,ue))}catch(se){}return webModule.__softPermutationId=Mt,C(Ce+Eb)}function F(){n.__gwt_stylesLoaded||(n.__gwt_stylesLoaded={})}A(),webModule.__moduleBase="/js/mathematicalGraphics/"+name+"/",s[L].moduleBase=webModule.__moduleBase;var G=D();return F(),w(G),!0}return webModule},typeof window.web3d!="function"&&(window.web3d=GGBAppletUtils.makeModule("web3d","A18F540516513B1292CA7CEF2F6AFC7E")),typeof window.webSimple!="function"&&(window.webSimple=GGBAppletUtils.makeModule("webSimple","96B09BF1B436BF53F0DF54116700F16A")),window.GGBApplet=GGBApplet})()},67303:function(Xt,Mt,be){"use strict";be.d(Mt,{Ax:function(){return ue},Ds:function(){return se},KI:function(){return le},SI:function(){return Ce},f1:function(){return ie}});var ce=be(90524);function ie(ee){let ne=!0;if(ee.length>0){for(let E=0;E<ee.length;E++)if(ee[E].compile_success==0||!ee[E].compile_success){ne=!1;break}}else ne=!1;return ne}function Ce(ee,ne=""){let E=[];for(let b=0;b<ee.length;b++){let z=ee[b],x=ne?`${ne}/${z.name}`:`${z.name}`;E.push({title:z.name,type:z.type,isLeaf:z.type!=="tree",key:x})}return E}function ue(ee,ne,E){for(let b=0;b<ee.length;b++){let z=ee[b];if(z.key===ne){z.children=E;break}z.children&&ue(z.children,ne,E)}return ee}function se(ee,ne,E){let b;return function(){let z=this,x=arguments,re=function(){b=null,E||ee.apply(z,x)},ae=E&&!b;clearTimeout(b),b=setTimeout(re,ne),ae&&ee.apply(z,x)}}const te=!0,le=ce.Z.API_SERVER},6077:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return b}});var ce=be(59301),ie={imageDimensions:"imageDimensions___a7crR",img:"img___Kroat",fullWidth:"fullWidth___c492T"},Ce=be(92310),ue=be.n(Ce),se=be(29787),te=be(2859),le=be(82093),ee=be(49661),ne=(z,x,re)=>new Promise((ae,oe)=>{var ve=ge=>{try{me(re.next(ge))}catch(_e){oe(_e)}},ye=ge=>{try{me(re.throw(ge))}catch(_e){oe(_e)}},me=ge=>ge.done?ae(ge.value):Promise.resolve(ge.value).then(ve,ye);me((re=re.apply(z,x)).next())}),b=({data:z,className:x,fullWidth:re,style:ae={},onClose:oe,onOk:ve,showFullTools:ye,noAssociationId:me})=>{const ge=(0,ce.useRef)(null),_e=(0,ce.useRef)(null),he=(0,ce.useRef)(null),pe=(0,ce.useRef)(null),[ke,Te]=(0,ce.useState)(!1),[Ee,Oe]=(0,ce.useState)("\u6B63\u5728\u52A0\u8F7D\u4E2D");(0,ce.useEffect)(()=>(he.current||(he.current=document.createElement("style"),document.head.appendChild(he.current)),z!=null&&z.visible?(document.body.setAttribute("data-custom","y-hidden"),he.current.innerHTML=" html { overflow-y: hidden; }",z!=null&&z.src&&je()):(document.body.removeAttribute("data-custom"),he.current&&(document.head.removeChild(he.current),he.current=null)),()=>{document.body.removeAttribute("data-custom"),he.current&&(document.head.removeChild(he.current),he.current=null)}),[z==null?void 0:z.visible]);const je=()=>ne(void 0,null,function*(){Te(!0),Oe("\u6B63\u5728\u52A0\u8F7D\u4E2D");const ot=yield(0,ee.ZJ)(z==null?void 0:z.src);ge.current.src="",ge.current.src=ot,ge.current.onload=function(){Xe()},Te(!1),Oe("")}),Pe=ot=>ne(void 0,null,function*(){Te(!0),Oe("\u6B63\u5728\u4FDD\u5B58\u4E2D");const He=yield(0,le.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:z.title,file:ot.dataUrl}});He!=null&&He.id&&!me?(yield(0,le.ZP)(`/api/attachments/${z.id}/add_subitem.json`,{method:"post",body:{subitem_id:He==null?void 0:He.id,settings:JSON.stringify(ot.state)}})).status===0&&ve():He!=null&&He.id&&ve(He),Te(!1),Oe("")}),Qe=()=>{const ot=document.querySelector('a[href="https://markerjs.com/"]');ot&&ot.parentNode&&(ot.parentNode.style.display="none"),[{name:'[data-action="select"]',title:"\u9009\u62E9"},{name:'[data-action="delete"]',title:"\u5220\u9664\u5143\u7D20"},{name:'[data-action="undo"]',title:"\u64A4\u9500"},{name:'[data-type-name="FrameMarker"]',title:"\u77E9\u5F62"},{name:'[data-type-name="FreehandMarker"]',title:"\u753B\u7EBF"},{name:'[data-type-name="ArrowMarker"]',title:"\u7BAD\u5934"},{name:'[data-type-name="TextMarker"]',title:"\u6587\u672C"},{name:'[data-type-name="EllipseMarker"]',title:"\u692D\u5706"},{name:'[data-type-name="HighlightMarker"]',title:"\u65B9\u5757"},{name:'[data-type-name="CalloutMarker"]',title:"\u6CE8\u91CA"},{name:'[data-action="render"]',title:"\u4FDD\u5B58"},{name:'[data-action="close"]',title:"\u9000\u51FA"}].forEach(rt=>{const Ye=document.querySelector(rt.name);Ye&&Ye.setAttribute("title",rt.title)})},Xe=()=>{_e.current=new te.hP(ge.current),_e.current.targetRoot=pe.current,_e.current.addEventListener("render",Pe),_e.current.addEventListener("beforeclose",oe),ye&&(_e.current.availableMarkerTypes=_e.current.ALL_MARKER_TYPES,_e.current.uiStyleSettings.redoButtonVisible=!0,_e.current.uiStyleSettings.notesButtonVisible=!0,_e.current.uiStyleSettings.zoomButtonVisible=!0,_e.current.uiStyleSettings.zoomOutButtonVisible=!0,_e.current.uiStyleSettings.clearButtonVisible=!0),window.markerArea=_e.current.uiStyleSettings,_e.current.show(),z!=null&&z.snapshotData&&_e.current.restoreState(z.snapshotData),setTimeout(()=>{window.scrollTo(0,0),Qe()},300)};return ce.createElement(ce.Fragment,null,(z==null?void 0:z.visible)&&ce.createElement(se.Z,{spinning:ke,tip:Ee,style:{position:"absolute",width:"100vw"}},ce.createElement("div",{ref:pe,className:ue()(ie.imageDimensions,x,re?ie.fullWidth:""),style:ae},ce.createElement("img",{className:ie.img,ref:ge}))))}},88615:function(Xt,Mt,be){"use strict";var ce=be(59301),ie=be(77019),Ce=be(5269),ue=be(20554),se=be(99571),te=be(38394),le=be(21697),ee=be(48136),ne=be(59301);const E=(0,ce.forwardRef)(({callback:b,showSaveButton:z,value:x=""},re)=>{const ae=(0,ce.useRef)(),oe=[{name:"\u5206\u6570\u5F97\u5206",value:"\\frac{x}{y}",children:[{name:"\u5206\u6570 Fractions",data:[{value:"\\frac{a}{b}"},{value:"x\\tfrac{x}{a} "},{value:"\\mathrm{d}t"},{value:"\\partial t"},{value:"\\frac{\\partial y}{\\partial x}"},{value:"\\nabla\\psi"},{value:"\\frac{\\partial^2}{\\partial x_1\\partial x_2}y"},{value:"\\cfrac{1}{a + \\cfrac{7}{b + \\cfrac{2}{9}}} = c"}]},{name:"\u5BFC\u6570 Derivative",data:[{value:"\\dot{a} "},{value:"\\ddot{a}"},{value:"{f}^{\\prime}"},{value:"{f}^{\\prime\\prime}"},{value:"{f}^{(n)}"}]},{name:"\u6A21\u7B97\u672F Modular arithmetic",data:[{value:"a \\bmod b"},{value:"a \\equiv b \\pmod{m} "},{value:"\\gcd(m, n) "},{value:"\\operatorname{lcm}(m, n) "}]}]},{name:"\u6839\u5F0F\u89D2\u6807",value:"\\sqrt{x}",children:[{name:"\u6839\u5F0F Radicals",data:[{value:"\\sqrt{x}"},{value:"\\sqrt[y]{x}"}]},{name:"\u4E0A\u4E0B\u6807 Sub&Super",data:[{value:"x^{a}"},{value:"x_{a}"},{value:"x_{a}^{b} "},{value:"_{a}^{b} x"},{value:"x_{a}^{b} "}]},{name:"\u91CD\u97F3\u7B26\u53CA\u5176\u4ED6 Accents and Others",data:[{value:"\\hat{a} "},{value:"\\sqrt[y]{x}"},{value:"\\check{} "},{value:"\\grave{a} "},{value:"\\acute{a}"},{value:"\\tilde{a}"},{value:"\\breve{a}"},{value:"\\bar{a}"},{value:"\\vec{a}"},{value:"\\not{a}"},{value:"\\widetilde{abc}"},{value:"\\widehat{abc}"},{value:"\\overleftarrow{abc} "},{value:"\\overrightarrow{abc}"},{value:"\\overline{abc}"},{value:"\\underline{abc}"},{value:"\\overbrace{abc}"},{value:"\\underbrace{abc}"},{value:"\\overset{a}{abc}"},{value:"\\underset{a}{abc} \\stackrel\\frown{ab}"},{value:"\\overline{ab} "},{value:"\\overleftrightarrow{ab}"},{value:"\\overset{a}{\\leftarrow}"},{value:"\\overset{a}{\\rightarrow}"},{value:"\\xleftarrow[abc]{a}"},{value:"\\xrightarrow[abc]{a} "}]}]},{name:"\u6781\u9650\u5BF9\u6570",value:"\\lim_{x \\to 0}",children:[{name:"\u6781\u9650 Limits",data:[{value:"\\lim a"},{value:"\\lim_{x \\to 0}"},{value:"\\lim_{x \\to \\infty}"},{value:"\\max_b{a}"},{value:"\\min_a{b}"}]},{name:"\u5BF9\u6570\u6307\u6570 Logarithms and exponentials",data:[{value:"\\log_{a}{b}"},{value:"\\lg_{a}{b}"},{value:"\\ln_{a}{b}"},{value:"\\exp a"}]},{name:"\u754C\u9650 Bounds",data:[{value:"\\min x"},{value:"\\sup t"},{value:"\\inf s"},{value:"\\lim u"},{value:"\\limsup w"},{value:"\\dim p"},{value:"\\ker\\phi "}]}]},{name:"\u4E09\u89D2\u51FD\u6570",value:"\\sin a",children:[{name:"\u4E09\u89D2\u51FD\u6570 Trigonometric functions",data:[{value:"\\sin a"},{value:"\\cos a"},{value:"\\tan a"},{value:"\\cot a "},{value:"\\sec a "},{value:"\\csc a "}]},{name:"\u53CD\u4E09\u89D2\u51FD\u6570 Inverse trigonometric functions",data:[{value:"\\sin^{-1}"},{value:"\\cos^{-1}"},{value:"\\tan^{-1}"},{value:"\\cot^{-1}"},{value:"\\sec^{-1}"},{value:"\\csc^{-1}"},{value:"\\arcsin a"},{value:"\\arccos a"},{value:"\\arctan a"},{value:"\\operatorname{arccot} a"},{value:"\\operatorname{arcsec} a"},{value:"\\operatorname{arccsc} a"}]},{name:"\u53CC\u66F2\u51FD\u6570 Hyperblic functions",data:[{value:"\\sinh a"},{value:"\\cosh a"},{value:"\\tanh a"},{value:"\\coth a"},{value:"\\operatorname{sech} a"},{value:"\\operatorname{csch} a"}]},{name:"\u53CD\u53CC\u66F2\u51FD\u6570 Inverse hyperbolic functions",data:[{value:"\\sinh^{-1}"},{value:"a\\cosh^{-1} a"},{value:"\\tanh^{-1} a"},{value:"\\coth^{-1} a"},{value:"\\operatorname{sech}^{-1} a"},{value:"\\operatorname{csch}^{-1} a"}]}]},{name:"\u79EF\u5206\u8FD0\u7B97",value:"\\int_{a}^{b}",children:[{name:"\u79EF\u5206 Integral",data:[{value:"\\int"},{value:"\\int_{a}^{b}"},{value:"\\int\\limits_{a}^{b}"}]},{name:"\u53CC\u91CD\u79EF\u5206 Double integral",data:[{value:"\\iint"},{value:"\\iint_{a}^{b} "},{value:"\\iint\\limits_{a}^{b} "}]},{name:"\u4E09\u91CD\u79EF\u5206 Triple integral",data:[{value:"\\iiint"},{value:"\\iiint_{a}^{b}"},{value:"\\iiint\\limits_{a}^{b} "}]},{name:"\u66F2\u7EBF\u79EF\u5206 Closed line or path integral",data:[{value:"\\oint"},{value:"\\oint_{a}^{b} "}]}]},{name:"\u5927\u578B\u8FD0\u7B97",value:"\\sum_{a}^{b}",children:[{name:"\u6C42\u548C Summation",data:[{value:"\\sum"},{value:"\\sum_{a}^{b}"},{value:"{\\textstyle \\sum_{a}^{b}} "}]},{name:"\u4E58\u79EF\u4F59\u79EF Product and coproduct",data:[{value:"\\prod"},{value:"\\prod_{a}^{b}"},{value:"{\\textstyle \\prod_{a}^{b}}"},{value:"\\coprod"},{value:"\\coprod_{a}^{b}"},{value:"{\\textstyle \\coprod_{a}^{b}} "}]},{name:"\u5E76\u96C6\u4EA4\u96C6 Union and intersection",data:[{value:"\\bigcup"},{value:"\\bigcup_{a}^{b}"},{value:"{\\textstyle \\bigcup_{a}^{b}}"},{value:"\\bigcap"},{value:"\\bigcap_{a}^{b}"}]},{name:"\u6790\u53D6\u5408\u53D6 Disjunction and conjunction",data:[{value:"\\bigvee"},{value:"\\bigvee_{a}^{b}"},{value:"\\bigwedge"},{value:"\\bigwedge_{a}^{b}"}]}]},{name:"\u62EC\u53F7\u53D6\u6574",value:"\\left [ \\left ( \\right ) \\right ] ",children:[{name:"\u62EC\u53F7 Brackets",data:[{value:"\\left ( \\right )"},{value:"\\left [ \\right ]"},{value:"\\left \\langle \\right \\rangle "},{value:"\\left | \\right | "},{value:"\\left \\lfloor \\right \\rfloor "},{value:"\\left \\lceil \\right \\rceil "}]}]}],ve=[{name:"\u4EE3\u6570",value:"\\sqrt{a^2+b^2}",children:[{data:[{value:"\\left(x-1\\right)\\left(x+3\\right) "},{value:"\\sqrt{a^2+b^2}"},{value:"\\left ( \\frac{a}{b}\\right )^{n}= \\frac{a^{n}}{b^{n}}"},{value:"\\frac{a}{b}\\pm \\frac{c}{d}= \\frac{ad \\pm bc}{bd} "},{value:"\\frac{x^{2}}{a^{2}}-\\frac{y^{2}}{b^{2}}=1 "},{value:"\\frac{1}{\\sqrt{a}}=\\frac{\\sqrt{a}}{a},a\\ge 0\\frac{1}{\\sqrt{a}}=\\frac{\\sqrt{a}}{a},a\\ge 0 "},{value:"\\sqrt[n]{a^{n}}=\\left ( \\sqrt[n]{a}\\right )^{n} "},{value:"x ={-b \\pm \\sqrt{b^2-4ac}\\over 2a} "},{value:"y-y_{1}=k \\left( x-x_{1}\\right) "},{value:`\\left\\{\\begin{matrix} \r
|
|
|
x=a + r\\text{cos}\\theta \\ \r
|
|
|
y=b + r\\text{sin}\\theta \r
|
|
|
\\end{matrix}\\right. `},{value:`\\begin{array}{l} \r
|
|
|
\\text{\u5BF9\u4E8E\u65B9\u7A0B\u5F62\u5982\uFF1A}x^{3}-1=0 \\ \r
|
|
|
\\text{\u8BBE}\\text{:}\\omega =\\frac{-1+\\sqrt{3}i}{2} \\ \r
|
|
|
x_{1}=1,x_{2}= \\omega =\\frac{-1+\\sqrt{3}i}{2} \\ \r
|
|
|
x_{3}= \\omega ^{2}=\\frac{-1-\\sqrt{3}i}{2} \r
|
|
|
\\end{array} `},{value:`\\begin{array}{l} \r
|
|
|
a\\mathop{{x}}\\nolimits^{{2}}+bx+c=0 \\ \r
|
|
|
\\Delta =\\mathop{{b}}\\nolimits^{{2}}-4ac \\ \r
|
|
|
\\left\\{\\begin{matrix} \r
|
|
|
\\Delta \\gt 0\\text{\u65B9\u7A0B\u6709\u4E24\u4E2A\u4E0D\u76F8\u7B49\u7684\u5B9E\u6839} \\ \r
|
|
|
\\Delta = 0\\text{\u65B9\u7A0B\u6709\u4E24\u4E2A\u76F8\u7B49\u7684\u5B9E\u6839} \\ \r
|
|
|
\\Delta \\lt 0\\text{\u65B9\u7A0B\u65E0\u5B9E\u6839} \r
|
|
|
\\end{matrix}\\right. \r
|
|
|
\\end{array} `},{value:`\\begin{array}{l} \r
|
|
|
a\\mathop{{x}}\\nolimits^{{2}}+bx+c=0 \\ \r
|
|
|
\\Delta =\\mathop{{b}}\\nolimits^{{2}}-4ac \\ \r
|
|
|
\\mathop{{x}}\\nolimits_{{1,2}}=\\frac{{-b \\pm \r
|
|
|
\\sqrt{{\\mathop{{b}}\\nolimits^{{2}}-4ac}}}}{{2a}} \\ \r
|
|
|
\\mathop{{x}}\\nolimits_{{1}}+\\mathop{{x}}\\nolimits_{{2}}=-\\frac{{b}}{{a}} \\ \r
|
|
|
\\mathop{{x}}\\nolimits_{{1}}\\mathop{{x}}\\nolimits_{{2}}=\\frac{{c}}{{a}} \r
|
|
|
\\end{array} `}]}]},{name:"\u51E0\u4F55",value:"\\Delta A B C ",children:[{data:[{value:"\\Delta A B C "},{value:"a \\parallel c,b \\parallel c \\Rightarrow a \\parallel b "},{value:"l \\perp \\beta ,l \\subset \\alpha \\Rightarrow \\alpha \\perp \\beta"},{value:`\\left.\\begin{matrix} \r
|
|
|
a \\perp \\alpha \\ \r
|
|
|
b \\perp \\alpha \r
|
|
|
\\end{matrix}\\right\\}\\Rightarrow a \\parallel b`},{value:"P \\in \\alpha ,P \\in \\beta , \\alpha \\cap \\beta =l \\Rightarrow P \\in l "},{value:`\\alpha \\perp \\beta , \\alpha \\cap \\beta =l,a \\subset \\alpha ,a \\perp l \r
|
|
|
\\Rightarrow a \\perp \\beta `},{value:`\\left.\\begin{matrix} \r
|
|
|
a \\subset \\beta ,b \\subset \\beta ,a \\cap b=P \\ \r
|
|
|
a \\parallel \\partial ,b \\parallel \\partial \r
|
|
|
\\end{matrix}\\right\\}\\Rightarrow \\beta \\parallel \\alpha `},{value:"\\alpha \\parallel \\beta , \\gamma \\cap \\alpha =a, \\gamma \\cap \\beta =b \\Rightarrow a \\parallel b "},{value:"A \\in l,B \\in l,A \\in \\alpha ,B \\in \\alpha \\Rightarrow l \\subset \\alpha "},{value:`\\left.\\begin{matrix} \r
|
|
|
m \\subset \\alpha ,n \\subset \\alpha ,m \\cap n=P \\ \r
|
|
|
a \\perp m,a \\perp n \r
|
|
|
\\end{matrix}\\right\\}\\Rightarrow a \\perp \\alpha `},{value:`\\begin{array}{c} \r
|
|
|
\\text{\u76F4\u89D2\u4E09\u89D2\u5F62\u4E2D,\u76F4\u89D2\u8FB9\u957Fa,b,\u659C\u8FB9\u8FB9\u957Fc} \\ \r
|
|
|
a^{2}+b^{2}=c^{2} \r
|
|
|
\\end{array}`}]}]},{name:"\u4E0D\u7B49\u5F0F",value:"a > b",children:[{data:[{value:"a > b,b > c \\Rightarrow a > c "},{value:"a > b,c > d \\Rightarrow a+c > b+d "},{value:"a > b > 0,c > d > 0 \\Rightarrow ac bd "},{value:`\\begin{array}{c} \r
|
|
|
a \\gt b,c \\gt 0 \\Rightarrow ac \\gt bc \\ \r
|
|
|
a \\gt b,c \\lt 0 \\Rightarrow ac \\lt bc \r
|
|
|
\\end{array}`},{value:"\\left | a-b \\right | \\geqslant \\left | a \\right | -\\left | b \\right | "},{value:"-\\left | a \\right |\\leq a\\leqslant \\left | a \\right | "},{value:"\\left | a \\right |\\leqslant b \\Rightarrow -b \\leqslant a \\leqslant \\left | b \\right | "},{value:"\\left | a+b \\right | \\leqslant \\left | a \\right | + \\left | b \\right | "},{value:`\\begin{array}{c} \r
|
|
|
a \\gt b \\gt 0,n \\in N^{\\ast},n \\gt 1 \\ \r
|
|
|
\\Rightarrow a^{n}\\gt b^{n}, \\sqrt[n]{a}\\gt \\sqrt[n]{b} \r
|
|
|
\\end{array}`},{value:`\\left( \\sum_{k=1}^n a_k b_k \\right)^{\\!\\!2}\\leq \r
|
|
|
\\left( \\sum_{k=1}^n a_k^2 \\right) \\left( \\sum_{k=1}^n b_k^2 \\right) `},{value:`\\begin{array}{c} \r
|
|
|
a,b \\in R^{+} \\ \r
|
|
|
\\Rightarrow \\frac{a+b}{{2}}\\ge \\sqrt{ab} \\ \r
|
|
|
\\left( \\text{\u5F53\u4E14\u4EC5\u5F53}a=b\\text{\u65F6\u53D6\u201C}=\\text{\u201D\u53F7}\\right) \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
a,b \\in R \\ \r
|
|
|
\\Rightarrow a^{2}+b^{2}\\gt 2ab \\ \r
|
|
|
\\left( \\text{\u5F53\u4E14\u4EC5\u5F53}a=b\\text{\u65F6\u53D6\u201C}=\\text{\u201D\u53F7}\\right) \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
H_{n}=\\frac{n}{\\sum \\limits_{i=1}^{n}\\frac{1}{x_{i}}}= \\frac{n}{\\frac{1}{x_{1}}+ \\frac{1}{x_{2}}+ \\cdots + \\frac{1}{x_{n}}} \\ G_{n}=\\sqrt[n]{\\prod \\limits_{i=1}^{n}x_{i}}= \\sqrt[n]{x_{1}x_{2}\\cdots x_{n}} \\ A_{n}=\\frac{1}{n}\\sum \\limits_{i=1}^{n}x_{i}=\\frac{x_{1}+ x_{2}+ \\cdots + x_{n}}{n} \\ Q_{n}=\\sqrt{\\sum \\limits_{i=1}^{n}x_{i}^{2}}= \\sqrt{\\frac{x_{1}^{2}+ x_{2}^{2}+ \\cdots + x_{n}^{2}}{n}} \\ H_{n}\\leq G_{n}\\leq A_{n}\\leq Q_{n} \r
|
|
|
\\end{array}`}]}]},{name:"\u79EF\u5206",value:"\\frac{\\mathrm{d}\\partial}{\\partial x}",children:[{data:[{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}x^n=nx^{n-1} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}e^{ax}=a\\,e^{ax} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\ln(x)=\\frac{1}{x} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\sin x=\\cos x "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\cos x=-\\sin x "},{value:"\\int k\\mathrm{d}x = kx+C "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\tan x=\\sec^2 x "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\cot x=-\\csc^2 x "},{value:"\\int \\frac{1}{x}\\mathrm{d}x= \\ln \\left| x \\right| +C "},{value:"\\int \\frac{1}{\\sqrt{1-x^{2}}}\\mathrm{d}x= \\arcsin x +C "},{value:"\\int \\frac{1}{1+x^{2}}\\mathrm{d}x= \\arctan x +C "},{value:"\\int u \\frac{\\mathrm{d}v}{\\mathrm{d}x}\\,\\mathrm{d}x=uv-\\int \\frac{\\mathrm{d}u}{\\mathrm{d}x}v\\,\\mathrm{d}x "},{value:"f(x) = \\int_{-\\infty}^\\infty \\hat f(x)\\xi\\,e^{2 \\pi i \\xi x} \\,\\mathrm{d}\\xi "},{value:"\\int x^{\\mu}\\mathrm{d}x=\\frac{x^{\\mu +1}}{\\mu +1}+C, \\left({\\mu \\neq -1}\\right) "}]}]},{name:"\u4E09\u89D2",value:"e^{i \\theta}",children:[{name:"\u6C42\u548C Summation",data:[{value:"e^{i \\theta} "},{value:"\\left(\\frac{\\pi}{2}-\\theta \\right ) "},{value:"\\text{sin}^{2}\\frac{\\alpha}{2}=\\frac{1- \\text{cos}\\alpha}{2} "},{value:"\\text{cos}^{2}\\frac{\\alpha}{2}=\\frac{1+ \\text{cos}\\alpha}{2} "},{value:"\\text{tan}\\frac{\\alpha}{2}=\\frac{\\text{sin}\\alpha}{1+ \\text{cos}\\alpha} "},{value:"\\sin \\alpha + \\sin \\beta =2 \\sin \\frac{\\alpha + \\beta}{2}\\cos \\frac{\\alpha - \\beta}{2} "},{value:"\\sin \\alpha - \\sin \\beta =2 \\cos \\frac{\\alpha + \\beta}{2}\\sin \\frac{\\alpha - \\beta}{2} "},{value:"\\cos \\alpha + \\cos \\beta =2 \\cos \\frac{\\alpha + \\beta}{2}\\cos \\frac{\\alpha - \\beta}{2} "},{value:"\\cos \\alpha - \\cos \\beta =-2\\sin \\frac{\\alpha + \\beta}{2}\\sin \\frac{\\alpha - \\beta}{2} "},{value:"a^{2}=b^{2}+c^{2}-2bc\\cos A "},{value:"\\frac{\\sin A}{a}=\\frac{\\sin B}{b}=\\frac{\\sin C}{c}=\\frac{1}{2R} "},{value:"\\sin \\left ( \\frac{\\pi}{2}-\\alpha \\right ) = \\cos \\alpha "},{value:"\\sin \\left ( \\frac{\\pi}{2}+\\alpha \\right ) = \\cos \\alpha "}]}]},{name:"\u7EDF\u8BA1",value:"C_{r}^{n}",children:[{data:[{value:"C_{r}^{n} "},{value:"\\frac{n!}{r!(n-r)!} "},{value:"\\sum_{i=1}^{n}{X_i} "},{value:"\\sum_{i=1}^{n}{X_i^2} "},{value:"X_1, \\cdots,X_n "},{value:"\\frac{x-\\mu}{\\sigma} "},{value:"\\sum_{i=1}^{n}{(X_i - \\overline{X})^2} "},{value:`\\begin{array}{c} \r
|
|
|
\\text{\u82E5}P \\left( AB \\right) =P \\left( A \\right) P \\left( B \\right) \\\\ \r
|
|
|
\\text{\u5219}P \\left( A \\left| B\\right. \\right) =P \\left({B}\\right) \r
|
|
|
\\end{array}`},{value:"P(E) ={n \\choose k}p^k (1-p)^{n-k} "},{value:"P \\left( A \\right) = \\lim \\limits_{n \\to \\infty}f_{n}\\left ( A \\right ) "},{value:"P \\left( \\bigcup \\limits_{i=1}^{+ \\infty}A_{i}\\right) = \\prod \\limits_{i=1}^{+ \\infty}P{\\left( A_{i}\\right)} "},{value:`\\begin{array}{c} \r
|
|
|
P \\left( \\emptyset \\right) =0 \\\\ \r
|
|
|
P \\left( S \\right) =1 \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
\\forall A \\in S \\\\ \r
|
|
|
P \\left( A \\right) \\ge 0 \r
|
|
|
\\end{array}`},{value:"P \\left( \\bigcup \\limits_{i=1}^{n}A_{i}\\right) = \\prod \\limits_{i=1}^{n}P \\left( A_{i}\\right) "},{value:`\\begin{array}{c} \r
|
|
|
S= \\binom{N}{n},A_{k}=\\binom{M}{k}\\cdot \\binom{N-M}{n-k} \\\\ \r
|
|
|
P\\left ( A_{k}\\right ) = \\frac{\\binom{M}{k}\\cdot \\binom{N-M}{n-k}}{\\binom{N}{n}} \r
|
|
|
\\end{array}`},{value:`\\begin{array}{c} \r
|
|
|
P_{n}=n! \\\\ \r
|
|
|
A_{n}^{k}=\\frac{n!}{\\left( n-k \\left) !\\right. \\right.} \r
|
|
|
\\end{array}`}]}]}],ye=_e=>{ae.current.setValue(ae.current.getValue()+" "+_e.value+" ")},me=[{key:"1",label:"\u5FEB\u6377\u6A21\u677F",children:ne.createElement(ie.Z,{className:le.Z.lists,gutter:[10,10]},oe.map((_e,he)=>ne.createElement(Ce.Z,{flex:"110px",className:le.Z.item},ne.createElement("div",null,ne.createElement(te.Z,{value:`$$${_e.value}$$`}),_e.name),ne.createElement("div",{className:le.Z.children},_e.children.map((pe,ke)=>ne.createElement("div",{key:ke},ne.createElement("h1",null,pe.name),ne.createElement(ie.Z,{gutter:[10,10]},pe.data.map((Te,Ee)=>ne.createElement(Ce.Z,{key:Ee,onClick:()=>ye(Te),className:le.Z.diamond},ne.createElement(te.Z,{value:"`$$"+Te.value+"$$`"}))))))))))},{key:"2",label:"\u516C\u5F0F\u6A21\u677F",children:ne.createElement(ie.Z,{className:le.Z.lists,gutter:[10,10]},ve.map((_e,he)=>ne.createElement(Ce.Z,{flex:"110px",className:le.Z.item},ne.createElement("div",null,ne.createElement(te.Z,{value:"`$$"+_e.value+"$$`"}),_e.name),ne.createElement("div",{className:le.Z.children},_e.children.map((pe,ke)=>ne.createElement("div",{key:ke},pe.name&&ne.createElement("h1",null,pe.name),ne.createElement(ie.Z,{gutter:[10,10]},pe.data.map((Te,Ee)=>ne.createElement(Ce.Z,{key:Ee,onClick:()=>ye(Te),className:le.Z.diamond},ne.createElement(te.Z,{value:"`$$"+Te.value+"$$`"}))))))))))}],ge=()=>{var _e=document.createElement("div");_e.innerHTML=ae.current.getValue();var he=_e.innerText;return b&&b(he),he};return(0,ce.useImperativeHandle)(re,()=>({getData:ge})),ne.createElement("div",{className:le.Z.mathWrap},ne.createElement(ue.default,{defaultActiveKey:"1",items:me}),ne.createElement("math-field",{locale:"zh_cn",className:le.Z.mathField,placeholder:"\u8BF7\u6253\u5F00\u952E\u76D8\uFF0C\u8F93\u5165\u516C\u5F0F",ref:ae,style:{width:800,marginTop:30,fontSize:18}},x||""),z&&ne.createElement("div",{className:le.Z.button},ne.createElement(se.ZP,{size:"large",onClick:ge,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668")))});Mt.Z=E},57884:function(Xt,Mt,be){"use strict";var ce=be(59301),ie=be(93314),Ce=be(99571),ue=Object.defineProperty,se=Object.defineProperties,te=Object.getOwnPropertyDescriptors,le=Object.getOwnPropertySymbols,ee=Object.prototype.hasOwnProperty,ne=Object.prototype.propertyIsEnumerable,E=(re,ae,oe)=>ae in re?ue(re,ae,{enumerable:!0,configurable:!0,writable:!0,value:oe}):re[ae]=oe,b=(re,ae)=>{for(var oe in ae||(ae={}))ee.call(ae,oe)&&E(re,oe,ae[oe]);if(le)for(var oe of le(ae))ne.call(ae,oe)&&E(re,oe,ae[oe]);return re},z=(re,ae)=>se(re,te(ae));const x=({img:re,buttonProps:ae={},styles:oe={},customText:ve,ButtonText:ye,ButtonClick:me,Buttonclass:ge,ButtonTwo:_e,imgStyles:he,loading:pe=!1,className:ke=""})=>ce.createElement("section",{className:`tc animated fadeIn ${ke}`,style:b({color:"#999",margin:"100px auto",visibility:pe?"hidden":"visible"},oe)},ce.createElement("img",{src:re||ie,style:z(b({},he),{pointerEvents:"none",userSelect:"none"})}),ce.createElement("p",{className:"mt20 font14"},ve||"\u6682\u65F6\u8FD8\u6CA1\u6709\u76F8\u5173\u6570\u636E\u54E6!"),ye&&ce.createElement(Ce.ZP,b({className:ge,onClick:me},ae),ye),_e&&_e);Mt.Z=x},41550:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ge}});var ce=be(59301),ie={wrp:"wrp___dq7YK",bgBlack:"bgBlack___ARIUV",monaco:"monaco___VnZC3",darkBlue:"darkBlue___UprA9",close:"close___LKoWu",embed:"embed___hvpEJ"},Ce=be(99571),ue=be(70557),se=be(51124),te=be(25399),le=be(49661),ee=be(72664),ne=be(57884),E=be(90524),b=be(14794),z=be(59301),x=Object.defineProperty,re=Object.getOwnPropertySymbols,ae=Object.prototype.hasOwnProperty,oe=Object.prototype.propertyIsEnumerable,ve=(_e,he,pe)=>he in _e?x(_e,he,{enumerable:!0,configurable:!0,writable:!0,value:pe}):_e[he]=pe,ye=(_e,he)=>{for(var pe in he||(he={}))ae.call(he,pe)&&ve(_e,pe,he[pe]);if(re)for(var pe of re(he))oe.call(he,pe)&&ve(_e,pe,he[pe]);return _e},me=(_e,he,pe)=>new Promise((ke,Te)=>{var Ee=Pe=>{try{je(pe.next(Pe))}catch(Qe){Te(Qe)}},Oe=Pe=>{try{je(pe.throw(Pe))}catch(Qe){Te(Qe)}},je=Pe=>Pe.done?ke(Pe.value):Promise.resolve(Pe.value).then(Ee,Oe);je((pe=pe.apply(_e,he)).next())}),ge=({editOffice:_e="view",data:he,issaver:pe,onSaver:ke,theme:Te,type:Ee,filename:Oe,monacoEditor:je,className:Pe,style:Qe,close:Xe,onClose:ot,hasMask:He,disabledDownload:rt,onImgDimensions:Ye,showNodata:ut,recordInfo:Ge})=>{const[ze,Ve]=(0,ce.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),[$e,nt]=(0,ce.useState)(""),[et,pt]=(0,ce.useState)(),ct=window.ENV==="build"?"/react/build":"",Ot=location.host.startsWith("localhost")?E.Z.PROXY_SERVER:E.Z.API_SERVER,Rt=10*(1024*1024),xt=(0,ce.useRef)();he!=null&&he.startsWith("/api")&&Ee!=="txt"&&(he=E.Z.API_SERVER+he);const gt=Be=>Be.substring(Be.lastIndexOf("/")+1).split(".").pop();Oe&&je&&(je.filename=Oe),(0,ce.useEffect)(()=>{var Be,Ke;const Ne=(Ke=(Be=document.cookie)==null?void 0:Be.replace(/\s/g,""))==null?void 0:Ke.split(";");Ne==null||Ne.map(De=>{let we=De.split("=");we[0]==="_educoder_session"&&nt(we[1])})},[]),(0,ce.useEffect)(()=>{Ee==="office"&&(he.indexOf("bigfilescdn.")>-1||he.indexOf("bigfiles1")>-1?pt({url:he,fileType:gt(he),model:he.indexOf("model=edit")?"edit":"view"}):We())},[Ee,he]);function _t(Be){return me(this,null,function*(){Be.data.type==="pdfdata"&&(ke(Be.data.data),window.removeEventListener("message",_t,!1)),console.log("mess---:",Be.data)})}const We=()=>me(void 0,null,function*(){console.log("data:",he);let Be=he;he.startsWith("http")||(Be=location.origin+Be);let Ke=new URL(Be).pathname.split("/").pop();const Ne=yield(0,ee.gJ)({attachment_id:Ke});Ne.url=Ot+Ne.url,pt(Ne)}),Ae=()=>{if(he.startsWith("http")||he.startsWith("blob:")){Se();return}(0,le.Sv)(Oe||"educoder",he,Oe)},Se=()=>{Ge&&(0,b.fc)({id:Ge==null?void 0:Ge.id,watch_type:1,course_id:Ge==null?void 0:Ge.course_id}),(0,le.Nd)(Oe||"educoder",decodeURIComponent(he))};return z.createElement("div",{style:ye({},Qe||{}),className:`${He&&ie.bgBlack} ${Ee?ie.wrp:"hide"}`},Xe&&z.createElement("div",{className:ie.close,ref:xt},!!Ye&&z.createElement(te.Z,{title:"\u70B9\u51FB\u5BF9\u56FE\u7247\u8FDB\u884C\u6279\u6CE8",getPopupContainer:()=>xt.current},z.createElement("span",{onClick:()=>{ot(),Ye()}},z.createElement("i",{className:"icon-yulanpizhu"}))),!rt&&z.createElement(te.Z,{title:"\u70B9\u51FB\u4E0B\u8F7D\u6B64\u6587\u4EF6",getPopupContainer:()=>xt.current},z.createElement("span",{onClick:Se},z.createElement("i",{className:"icon-quxiaozhiding"}))),pe&&z.createElement(te.Z,{title:"\u4FDD\u5B58pdf\u5E76\u9000\u51FA",getPopupContainer:()=>xt.current},z.createElement("span",{className:"",onClick:()=>{const Be=document.getElementById("pdfiframe");window.addEventListener("message",_t,!1),setTimeout(()=>{Be.contentWindow.postMessage("getData","*")},300)}},z.createElement("i",{className:"icon-baocun"}))),z.createElement(te.Z,{title:"\u5173\u95ED",getPopupContainer:()=>xt.current},z.createElement("span",{className:"",onClick:()=>{ot()}},z.createElement("i",{className:"icon-guanbi1"})))),z.createElement("div",{className:`${ie[Pe]} ${Pe} ${ie.monaco} ${Ee==="txt"?"show":"hide"}`},Ee==="txt"&&z.createElement(z.Fragment,null,z.createElement(se.ZP,ye({},je)))),Ee==="audio"&&z.createElement("audio",{src:`${(he==null?void 0:he.indexOf("http://"))>-1||(he==null?void 0:he.indexOf("https://"))>-1?"":"data:audio/mp3;base64,"}${he}`,autoPlay:!0}),Ee==="video"&&z.createElement(z.Fragment,null,(he==null?void 0:he.indexOf("http"))>-1?z.createElement("video",{controls:!0,src:`${he}`,autoPlay:!0}):z.createElement("video",{controls:!0,src:`data:video/mp4;base64,${he}`,autoPlay:!0})),Ee==="office"&&et&&z.createElement("iframe",{src:`${ct}/office.html?key=${et.key}&url=${btoa(et.url)}&callbackUrl=${Ot+(et.callbackUrl||"")}&fileType=${et.fileType}&title=${et.title||""}&model=${_e}&officeServer=${E.Z.ONLYOFFICE}&disabledDownload=${!!rt}`}),Ee==="html"&&z.createElement("iframe",{src:he+"&disposition=inline"}),Ee==="pdf"&&z.createElement("iframe",{id:"pdfiframe",src:`${ct}/js/pdfview/index.html?filename=${Oe||"educoder.pdf"}&url=${encodeURIComponent(he)}&disabledDownload=${!!rt}&model=${_e}`}),Ee==="image"&&z.createElement("img",{src:`${(he==null?void 0:he.indexOf("http://"))>-1||(he==null?void 0:he.indexOf("https://"))>-1?"":"data:image/png;base64,"}${he}`}),(Ee==="other"||Ee==="download")&&z.createElement(z.Fragment,null,ut?z.createElement(ne.Z,{customText:"\u5F53\u524D\u6587\u4EF6\u4E0D\u652F\u6301\u9884\u89C8\uFF0C\u53EF\u70B9\u51FB\u4E0B\u8F7D\u67E5\u770B",ButtonTwo:z.createElement(Ce.ZP,{icon:z.createElement("i",{className:"iconfont icon-xiazai4 font14"}),type:"primary",size:"middle",onClick:Ae,disabled:rt},"\u4E0B\u8F7D")}):z.createElement(Ce.ZP,{type:"primary",size:"middle",onClick:Ae,disabled:rt},z.createElement(ue.Z,null),"\u70B9\u51FB\u4E0B\u8F7D")),Ee==="flowChart"&&z.createElement("div",{className:"embed"},z.createElement("iframe",{src:`/drawio/src/main/webapp/viewer.html?id=${he||""}&gapi=0&od=0&db=0&gh=0&gl=0`,width:"100%",height:"100%",frameBorder:"0"})))}},38394:function(Xt,Mt,be){"use strict";be.d(Mt,{z:function(){return je},Z:function(){return Pe}});var ce=be(59301),ie=be(88831),Ce=be(90290),ue=be(64018),se=be(68535),te=be(90524),le=be(49661),ee=be(15342),ne=be(77736),E=be(99571),b=be(1012),z=be(41550),x=be(59301),ae=({html:Qe})=>{const Xe=(0,ce.useRef)(null),ot=(0,ce.useRef)(null),He=`.markdown-body p {
|
|
|
margin: 0 0 16px 0 !important;
|
|
|
line-height: 28px;
|
|
|
white-space: pre-wrap;
|
|
|
}
|
|
|
|
|
|
ol,
|
|
|
ul,
|
|
|
li {
|
|
|
list-style-type: none
|
|
|
}
|
|
|
|
|
|
ol,
|
|
|
ul,
|
|
|
dl {
|
|
|
margin-bottom: 0px;
|
|
|
}
|
|
|
|
|
|
.markdown-body {
|
|
|
-ms-text-size-adjust: 100%;
|
|
|
-webkit-text-size-adjust: 100%;
|
|
|
color: #333;
|
|
|
overflow: hidden;
|
|
|
font-family: "Microsoft YaHei", Helvetica, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", "Monaco", monospace, Tahoma, STXihei, "\u534E\u6587\u7EC6\u9ED1", STHeiti, "Helvetica Neue", "Droid Sans", "wenquanyi micro hei", FreeSans, Arimo, Arial, SimSun, "\u5B8B\u4F53", Heiti, "\u9ED1\u4F53", sans-serif;
|
|
|
word-break: break-word;
|
|
|
font-size: 16px;
|
|
|
line-height: 1.6;
|
|
|
white-space: normal;
|
|
|
word-wrap: break-word;
|
|
|
position: relative;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul>li {
|
|
|
list-style-type: disc;
|
|
|
}
|
|
|
|
|
|
.markdown-body ol>li {
|
|
|
list-style-type: decimal;
|
|
|
}
|
|
|
|
|
|
.markdown-body a {
|
|
|
background: transparent;
|
|
|
}
|
|
|
|
|
|
.markdown-body a:active,
|
|
|
.markdown-body a:hover {
|
|
|
outline: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body strong {
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 {
|
|
|
font-size: 2em;
|
|
|
margin: 0.67em 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body img {
|
|
|
border: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body hr {
|
|
|
-moz-box-sizing: content-box;
|
|
|
box-sizing: content-box;
|
|
|
height: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre {
|
|
|
overflow: auto;
|
|
|
}
|
|
|
|
|
|
.markdown-body code,
|
|
|
.markdown-body kbd,
|
|
|
.markdown-body pre {
|
|
|
font-family: "Meiryo UI", "YaHei Consolas Hybrid", Consolas, "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace;
|
|
|
font-size: 1em;
|
|
|
}
|
|
|
|
|
|
.markdown-body input {
|
|
|
color: inherit;
|
|
|
font: inherit;
|
|
|
margin: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body html input[disabled] {
|
|
|
cursor: default;
|
|
|
}
|
|
|
|
|
|
.markdown-body input {
|
|
|
line-height: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body input[type="checkbox"] {
|
|
|
-moz-box-sizing: border-box;
|
|
|
box-sizing: border-box;
|
|
|
padding: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body table {
|
|
|
border-collapse: collapse;
|
|
|
border-spacing: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body td,
|
|
|
.markdown-body th {
|
|
|
padding: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body * {
|
|
|
-moz-box-sizing: border-box;
|
|
|
box-sizing: border-box;
|
|
|
}
|
|
|
|
|
|
.markdown-body input {
|
|
|
font: 13px/1.4 Helvetica, arial, freesans, clean, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
|
|
|
}
|
|
|
|
|
|
.markdown-body a {
|
|
|
color: #4183c4;
|
|
|
text-decoration: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body a:hover,
|
|
|
.markdown-body a:active {
|
|
|
text-decoration: underline;
|
|
|
}
|
|
|
|
|
|
.markdown-body hr {
|
|
|
height: 0;
|
|
|
margin: 15px 0;
|
|
|
overflow: hidden;
|
|
|
background: transparent;
|
|
|
border: 0;
|
|
|
border-bottom: 1px solid #ddd;
|
|
|
}
|
|
|
|
|
|
.markdown-body hr:before {
|
|
|
display: table;
|
|
|
content: "";
|
|
|
}
|
|
|
|
|
|
.markdown-body hr:after {
|
|
|
display: table;
|
|
|
clear: both;
|
|
|
content: "";
|
|
|
}
|
|
|
|
|
|
.markdown-body h1,
|
|
|
.markdown-body h2,
|
|
|
.markdown-body h3,
|
|
|
.markdown-body h4,
|
|
|
.markdown-body h5,
|
|
|
.markdown-body h6 {
|
|
|
margin-top: 15px;
|
|
|
margin-bottom: 15px;
|
|
|
line-height: 1.1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 {
|
|
|
font-size: 30px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h2 {
|
|
|
font-size: 21px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h3 {
|
|
|
font-size: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h4 {
|
|
|
font-size: 14px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h5 {
|
|
|
font-size: 12px;
|
|
|
}
|
|
|
|
|
|
.markdown-body h6 {
|
|
|
font-size: 11px;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote {
|
|
|
margin: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol {
|
|
|
padding: 0;
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
|
|
|
ul.linenums,
|
|
|
ol.linenums {
|
|
|
padding: 16px 0 0 56px !important;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol {
|
|
|
padding-left: 2em;
|
|
|
}
|
|
|
|
|
|
|
|
|
.markdown-body ol ol,
|
|
|
.markdown-body ul ol {
|
|
|
list-style-type: lower-roman;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul ul ol,
|
|
|
.markdown-body ul ol ol,
|
|
|
.markdown-body ol ul ol,
|
|
|
.markdown-body ol ol ol {
|
|
|
list-style-type: lower-alpha;
|
|
|
}
|
|
|
|
|
|
.markdown-body dd {
|
|
|
margin-left: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body code {
|
|
|
font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
|
font-size: 12px;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0;
|
|
|
font: 12px Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
|
}
|
|
|
|
|
|
.markdown-body .octicon {
|
|
|
font: normal normal 16px octicons-anchor;
|
|
|
line-height: 1;
|
|
|
display: inline-block;
|
|
|
text-decoration: none;
|
|
|
-webkit-font-smoothing: antialiased;
|
|
|
-moz-osx-font-smoothing: grayscale;
|
|
|
-webkit-user-select: none;
|
|
|
-moz-user-select: none;
|
|
|
-ms-user-select: none;
|
|
|
user-select: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body .octicon-link:before {
|
|
|
content: '\f05c';
|
|
|
}
|
|
|
|
|
|
.markdown-body>*:first-child {
|
|
|
margin-top: 0 !important;
|
|
|
}
|
|
|
|
|
|
.markdown-body>*:last-child {
|
|
|
margin-bottom: 0 !important;
|
|
|
}
|
|
|
|
|
|
.markdown-body .anchor {
|
|
|
position: absolute;
|
|
|
top: 0;
|
|
|
left: 0;
|
|
|
display: block;
|
|
|
padding-right: 6px;
|
|
|
padding-left: 30px;
|
|
|
margin-left: -30px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .anchor:focus {
|
|
|
outline: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1,
|
|
|
.markdown-body h2,
|
|
|
.markdown-body h3,
|
|
|
.markdown-body h4,
|
|
|
.markdown-body h5,
|
|
|
.markdown-body h6 {
|
|
|
position: relative;
|
|
|
margin-top: 1em;
|
|
|
margin-bottom: 16px;
|
|
|
font-weight: bold;
|
|
|
line-height: 1.4;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 .octicon-link,
|
|
|
.markdown-body h2 .octicon-link,
|
|
|
.markdown-body h3 .octicon-link,
|
|
|
.markdown-body h4 .octicon-link,
|
|
|
.markdown-body h5 .octicon-link,
|
|
|
.markdown-body h6 .octicon-link {
|
|
|
display: none;
|
|
|
color: #000;
|
|
|
vertical-align: middle;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1:hover .anchor,
|
|
|
.markdown-body h2:hover .anchor,
|
|
|
.markdown-body h3:hover .anchor,
|
|
|
.markdown-body h4:hover .anchor,
|
|
|
.markdown-body h5:hover .anchor,
|
|
|
.markdown-body h6:hover .anchor {
|
|
|
padding-left: 8px;
|
|
|
margin-left: -30px;
|
|
|
text-decoration: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1:hover .anchor .octicon-link,
|
|
|
.markdown-body h2:hover .anchor .octicon-link,
|
|
|
.markdown-body h3:hover .anchor .octicon-link,
|
|
|
.markdown-body h4:hover .anchor .octicon-link,
|
|
|
.markdown-body h5:hover .anchor .octicon-link,
|
|
|
.markdown-body h6:hover .anchor .octicon-link {
|
|
|
display: inline-block;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 {
|
|
|
padding-bottom: 0.3em;
|
|
|
font-size: 2.25em;
|
|
|
line-height: 1.2;
|
|
|
border-bottom: 1px solid #eee;
|
|
|
}
|
|
|
|
|
|
.markdown-body h1 .anchor {
|
|
|
line-height: 1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h2 {
|
|
|
padding-bottom: 0.3em;
|
|
|
font-size: 1.75em;
|
|
|
line-height: 1.225;
|
|
|
border-bottom: 1px solid #eee;
|
|
|
}
|
|
|
|
|
|
.markdown-body h2 .anchor {
|
|
|
line-height: 1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h3 {
|
|
|
font-size: 1.5em;
|
|
|
line-height: 1.43;
|
|
|
}
|
|
|
|
|
|
.markdown-body h3 .anchor {
|
|
|
line-height: 1.2;
|
|
|
}
|
|
|
|
|
|
.markdown-body h4 {
|
|
|
font-size: 1.25em;
|
|
|
}
|
|
|
|
|
|
.markdown-body h4 .anchor {
|
|
|
line-height: 1.2;
|
|
|
}
|
|
|
|
|
|
.markdown-body h5 {
|
|
|
font-size: 1em;
|
|
|
}
|
|
|
|
|
|
.markdown-body h5 .anchor {
|
|
|
line-height: 1.1;
|
|
|
}
|
|
|
|
|
|
.markdown-body h6 {
|
|
|
font-size: 1em;
|
|
|
color: #777;
|
|
|
}
|
|
|
|
|
|
.markdown-body h6 .anchor {
|
|
|
line-height: 1.1;
|
|
|
}
|
|
|
|
|
|
.markdown-body p,
|
|
|
.markdown-body blockquote,
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol,
|
|
|
.markdown-body dl,
|
|
|
.markdown-body table,
|
|
|
.markdown-body pre {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body ul ul,
|
|
|
.markdown-body ul ol,
|
|
|
.markdown-body ol ol,
|
|
|
.markdown-body ol ul {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body li>p {
|
|
|
margin-top: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body dl {
|
|
|
padding: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body dl dt {
|
|
|
padding: 0;
|
|
|
margin-top: 16px;
|
|
|
font-size: 1em;
|
|
|
font-style: italic;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body dl dd {
|
|
|
padding: 0 16px;
|
|
|
margin-bottom: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote {
|
|
|
padding: 0 15px;
|
|
|
color: #777;
|
|
|
border-left: 4px solid #ddd;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote> :first-child {
|
|
|
margin-top: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body blockquote> :last-child {
|
|
|
margin-bottom: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body table {
|
|
|
display: block;
|
|
|
width: 100%;
|
|
|
overflow: auto;
|
|
|
word-break: normal;
|
|
|
word-break: keep-all;
|
|
|
}
|
|
|
|
|
|
.markdown-body table th {
|
|
|
font-weight: bold;
|
|
|
text-align: revert;
|
|
|
}
|
|
|
|
|
|
.markdown-body table th,
|
|
|
.markdown-body table td {
|
|
|
padding: 6px 13px;
|
|
|
border: 1px solid #ddd;
|
|
|
}
|
|
|
|
|
|
.markdown-body table tr {
|
|
|
background-color: #fff;
|
|
|
border-top: 1px solid #ccc;
|
|
|
}
|
|
|
|
|
|
.markdown-body table tr:nth-child(2n) {
|
|
|
background-color: #f8f8f8;
|
|
|
}
|
|
|
|
|
|
.markdown-body img {
|
|
|
max-width: 100%;
|
|
|
-moz-box-sizing: border-box;
|
|
|
box-sizing: border-box;
|
|
|
}
|
|
|
|
|
|
.markdown-body code {
|
|
|
padding: 0;
|
|
|
padding-top: 0.2em;
|
|
|
padding-bottom: 0.2em;
|
|
|
margin: 0;
|
|
|
font-size: 85%;
|
|
|
background-color: rgba(0, 0, 0, 0.04);
|
|
|
border-radius: 3px;
|
|
|
}
|
|
|
|
|
|
.markdown-body code:has(.katex) {
|
|
|
background-color: transparent;
|
|
|
}
|
|
|
|
|
|
.markdown-body code:before,
|
|
|
.markdown-body code:after {
|
|
|
letter-spacing: -0.2em;
|
|
|
content: "\\00a0";
|
|
|
}
|
|
|
|
|
|
.markdown-body pre>code {
|
|
|
padding: 0;
|
|
|
margin: 0;
|
|
|
font-size: 100%;
|
|
|
word-break: normal;
|
|
|
white-space: pre;
|
|
|
background: transparent;
|
|
|
border: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body .highlight {
|
|
|
margin-bottom: 16px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .highlight pre,
|
|
|
.markdown-body pre {
|
|
|
padding: 16px;
|
|
|
overflow: auto;
|
|
|
font-size: 85%;
|
|
|
line-height: 1.45;
|
|
|
background-color: #f7f7f7;
|
|
|
border-radius: 3px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .highlight pre {
|
|
|
margin-bottom: 0;
|
|
|
word-break: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre {
|
|
|
word-wrap: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre code {
|
|
|
display: inline;
|
|
|
max-width: initial;
|
|
|
padding: 0;
|
|
|
margin: 0;
|
|
|
overflow: initial;
|
|
|
line-height: inherit;
|
|
|
word-wrap: normal;
|
|
|
background-color: transparent;
|
|
|
border: 0;
|
|
|
}
|
|
|
|
|
|
.markdown-body pre code:before,
|
|
|
.markdown-body pre code:after {
|
|
|
content: normal;
|
|
|
}
|
|
|
|
|
|
.markdown-body kbd {
|
|
|
display: inline-block;
|
|
|
padding: 3px 5px;
|
|
|
font-size: 11px;
|
|
|
line-height: 10px;
|
|
|
color: #555;
|
|
|
vertical-align: middle;
|
|
|
background-color: #fcfcfc;
|
|
|
border: solid 1px #ccc;
|
|
|
border-bottom-color: #bbb;
|
|
|
border-radius: 3px;
|
|
|
box-shadow: inset 0 -1px 0 #bbb;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-c {
|
|
|
color: #969896;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-c1,
|
|
|
.markdown-body .pl-mdh,
|
|
|
.markdown-body .pl-mm,
|
|
|
.markdown-body .pl-mp,
|
|
|
.markdown-body .pl-mr,
|
|
|
.markdown-body .pl-s1 .pl-v,
|
|
|
.markdown-body .pl-s3,
|
|
|
.markdown-body .pl-sc,
|
|
|
.markdown-body .pl-sv {
|
|
|
color: #0086b3;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-e,
|
|
|
.markdown-body .pl-en {
|
|
|
color: #795da3;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-s1 .pl-s2,
|
|
|
.markdown-body .pl-smi,
|
|
|
.markdown-body .pl-smp,
|
|
|
.markdown-body .pl-stj,
|
|
|
.markdown-body .pl-vo,
|
|
|
.markdown-body .pl-vpf {
|
|
|
color: #333;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-ent {
|
|
|
color: #63a35c;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-k,
|
|
|
.markdown-body .pl-s,
|
|
|
.markdown-body .pl-st {
|
|
|
color: #a71d5d;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-pds,
|
|
|
.markdown-body .pl-s1,
|
|
|
.markdown-body .pl-s1 .pl-pse .pl-s2,
|
|
|
.markdown-body .pl-sr,
|
|
|
.markdown-body .pl-sr .pl-cce,
|
|
|
.markdown-body .pl-sr .pl-sra,
|
|
|
.markdown-body .pl-sr .pl-sre,
|
|
|
.markdown-body .pl-src {
|
|
|
color: #df5000;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mo,
|
|
|
.markdown-body .pl-v {
|
|
|
color: #1d3e81;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-id {
|
|
|
color: #b52a1d;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-ii {
|
|
|
background-color: #b52a1d;
|
|
|
color: #f8f8f8;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-sr .pl-cce {
|
|
|
color: #63a35c;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-ml {
|
|
|
color: #693a17;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mh,
|
|
|
.markdown-body .pl-mh .pl-en,
|
|
|
.markdown-body .pl-ms {
|
|
|
color: #1d3e81;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mq {
|
|
|
color: #008080;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mi {
|
|
|
color: #333;
|
|
|
font-style: italic;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mb {
|
|
|
color: #333;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-md,
|
|
|
.markdown-body .pl-mdhf {
|
|
|
background-color: #ffecec;
|
|
|
color: #bd2c00;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mdht,
|
|
|
.markdown-body .pl-mi1 {
|
|
|
background-color: #eaffea;
|
|
|
color: #55a532;
|
|
|
}
|
|
|
|
|
|
.markdown-body .pl-mdr {
|
|
|
color: #795da3;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
|
.markdown-body kbd {
|
|
|
display: inline-block;
|
|
|
padding: 3px 5px;
|
|
|
font: 11px Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
|
line-height: 10px;
|
|
|
color: #555;
|
|
|
vertical-align: middle;
|
|
|
background-color: #fcfcfc;
|
|
|
border: solid 1px #ccc;
|
|
|
border-bottom-color: #bbb;
|
|
|
border-radius: 3px;
|
|
|
box-shadow: inset 0 -1px 0 #bbb;
|
|
|
}
|
|
|
|
|
|
.markdown-body .task-list-item {
|
|
|
list-style-type: none;
|
|
|
}
|
|
|
|
|
|
.markdown-body .task-list-item+.task-list-item {
|
|
|
margin-top: 3px;
|
|
|
}
|
|
|
|
|
|
.markdown-body .task-list-item input {
|
|
|
float: left;
|
|
|
margin: 0.3em 0 0.25em -1.6em;
|
|
|
vertical-align: middle;
|
|
|
}
|
|
|
|
|
|
.markdown-body :checked+.radio-label {
|
|
|
z-index: 1;
|
|
|
position: relative;
|
|
|
border-color: #4183c4;
|
|
|
}
|
|
|
|
|
|
|
|
|
/*! Pretty printing styles. Used with prettify.js. */
|
|
|
/* SPAN elements with the classes below are added by prettyprint. */
|
|
|
.pln {
|
|
|
color: #000
|
|
|
}
|
|
|
|
|
|
/* plain text */
|
|
|
|
|
|
@media screen {
|
|
|
.str {
|
|
|
color: #080
|
|
|
}
|
|
|
|
|
|
/* string content */
|
|
|
.kwd {
|
|
|
color: #008
|
|
|
}
|
|
|
|
|
|
/* a keyword */
|
|
|
.com {
|
|
|
color: #800
|
|
|
}
|
|
|
|
|
|
/* a comment */
|
|
|
.typ {
|
|
|
color: #606
|
|
|
}
|
|
|
|
|
|
/* a type name */
|
|
|
.lit {
|
|
|
color: #066
|
|
|
}
|
|
|
|
|
|
/* a literal value */
|
|
|
/* punctuation, lisp open bracket, lisp close bracket */
|
|
|
.pun,
|
|
|
.opn,
|
|
|
.clo {
|
|
|
color: #660
|
|
|
}
|
|
|
|
|
|
.tag {
|
|
|
color: #008
|
|
|
}
|
|
|
|
|
|
/* a markup tag name */
|
|
|
.atn {
|
|
|
color: #606
|
|
|
}
|
|
|
|
|
|
/* a markup attribute name */
|
|
|
.atv {
|
|
|
color: #080
|
|
|
}
|
|
|
|
|
|
/* a markup attribute value */
|
|
|
.dec,
|
|
|
.var {
|
|
|
color: #606
|
|
|
}
|
|
|
|
|
|
/* a declaration; a variable name */
|
|
|
.fun {
|
|
|
color: red
|
|
|
}
|
|
|
|
|
|
/* a function name */
|
|
|
}
|
|
|
|
|
|
/* Use higher contrast and text-weight for printable form. */
|
|
|
@media print,
|
|
|
projection {
|
|
|
.str {
|
|
|
color: #060
|
|
|
}
|
|
|
|
|
|
.kwd {
|
|
|
color: #006;
|
|
|
font-weight: bold
|
|
|
}
|
|
|
|
|
|
.com {
|
|
|
color: #600;
|
|
|
font-style: italic
|
|
|
}
|
|
|
|
|
|
.typ {
|
|
|
color: #404;
|
|
|
font-weight: bold
|
|
|
}
|
|
|
|
|
|
.lit {
|
|
|
color: #044
|
|
|
}
|
|
|
|
|
|
.pun,
|
|
|
.opn,
|
|
|
.clo {
|
|
|
color: #440
|
|
|
}
|
|
|
|
|
|
.tag {
|
|
|
color: #006;
|
|
|
font-weight: bold
|
|
|
}
|
|
|
|
|
|
.atn {
|
|
|
color: #404
|
|
|
}
|
|
|
|
|
|
.atv {
|
|
|
color: #060
|
|
|
}
|
|
|
}
|
|
|
|
|
|
/* Put a border around prettyprinted code snippets. */
|
|
|
pre.prettyprint {
|
|
|
padding: 2px;
|
|
|
/* border: 1px solid #888 */
|
|
|
}
|
|
|
|
|
|
/* Specify class=linenums on a pre to get line numbering */
|
|
|
ol.linenums {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 0
|
|
|
}
|
|
|
|
|
|
/* IE indents via margin-left */
|
|
|
li.L0,
|
|
|
li.L1,
|
|
|
li.L2,
|
|
|
li.L3,
|
|
|
li.L5,
|
|
|
li.L6,
|
|
|
li.L7,
|
|
|
li.L8 {
|
|
|
list-style-type: none
|
|
|
}
|
|
|
|
|
|
/* Alternate shading for lines */
|
|
|
li.L1,
|
|
|
li.L3,
|
|
|
li.L5,
|
|
|
li.L7,
|
|
|
li.L9 {
|
|
|
background: #eee
|
|
|
}
|
|
|
|
|
|
.markdown-body p,
|
|
|
.markdown-body blockquote,
|
|
|
.markdown-body ul,
|
|
|
.markdown-body ol,
|
|
|
.markdown-body dl,
|
|
|
.markdown-body table,
|
|
|
.markdown-body pre {
|
|
|
margin-top: 0;
|
|
|
margin-bottom: 16px;
|
|
|
}`;return(0,ce.useEffect)(()=>{const rt=Xe.current.attachShadow({mode:"open"});ot.current=document.createElement("div"),ot.current.className="markdown-body",ot.current.innerHTML=Qe,rt.appendChild(ot.current);const Ye=document.createElement("style");return Ye.textContent=He,rt.appendChild(Ye),()=>{rt.innerHTML=""}},[]),(0,ce.useEffect)(()=>{ot.current&&(ot.current.innerHTML=Qe)},[Qe]),x.createElement("div",{ref:Xe})};function oe(Qe){const Xe=["onabort","onanimationend","onanimationiteration","onanimationstart","onauxclick","onblur","oncancel","oncanplay","oncanplaythrough","onchange","onclick","onclose","oncontextmenu","oncopy","oncut","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onfocus","onformdata","ongotpointercapture","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onlostpointercapture","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onpaste","onpause","onplay","onplaying","onpointercancel","onpointerdown","onpointerenter","onpointerleave","onpointermove","onpointerout","onpointerover","onpointerup","onprogress","onratechange","onreset","onresize","onscroll","onsecuritypolicyviolation","onseeked","onseeking","onselect","onslotchange","onstalled","onsubmit","onsuspend","ontimeupdate","ontoggle","ontouchcancel","ontouchend","ontouchmove","ontouchstart","ontransitionend","onvolumechange","onwaiting","onwheel"],ot=new RegExp(`\\b(${Xe.join("|")})\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s>]*)`,"gi");return Qe.replace(ot,"").trim()}var ve={mdBody:"mdBody___raKXb",button:"button___Ch5Pc",previewFlowChart:"previewFlowChart___vY1dq"},ye=Object.defineProperty,me=Object.getOwnPropertySymbols,ge=Object.prototype.hasOwnProperty,_e=Object.prototype.propertyIsEnumerable,he=(Qe,Xe,ot)=>Xe in Qe?ye(Qe,Xe,{enumerable:!0,configurable:!0,writable:!0,value:ot}):Qe[Xe]=ot,pe=(Qe,Xe)=>{for(var ot in Xe||(Xe={}))ge.call(Xe,ot)&&he(Qe,ot,Xe[ot]);if(me)for(var ot of me(Xe))_e.call(Xe,ot)&&he(Qe,ot,Xe[ot]);return Qe};const ke="@\u2581\u2581@",Te="@\u2581@",Ee=/<pre[^>]*>/g;function Oe(Qe){let Xe=document.createElement("div");return Xe.innerHTML=Qe,Xe.childNodes.length===0?"":Xe.childNodes[0].nodeValue}const je=(Qe,Xe)=>{Qe=Qe||"";const ot=/(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?\)|(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,He=/\"(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,rt=/\(\s+(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,Ye=/(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g;return Xe?Qe.replaceAll("https://www.educoder.net","").replaceAll("https://www-cdn.educoder.net","").replaceAll("//api/attachments","/api/attachments").replace(ot,(ut,Ge,ze,Ve,$e,nt,et)=>{const pt=Ge||Ve||nt,ct=ze||$e||et||"?";return te.Z.API_SERVER+"/api/attachments/"+pt+ct+"&t="+(0,le.Jn)(pt,Date.now())+(ut.indexOf(")")>-1?")":"&")}).replaceAll('src="(','src="').replaceAll("src='(",'src="'):(Qe=Qe.replace(Ye,(ut,Ge,ze,Ve,$e,nt,et)=>{const pt=Ge||Ve||nt,ct=ze||$e||et||"?";return te.Z.API_SERVER+"/attachments/download/"+pt+ct+"&t="+(0,le.Jn)(pt,Date.now())+(ut.indexOf(")")>-1?")":"&")}).replace(ot,(ut,Ge,ze,Ve,$e,nt,et)=>{const pt=Ge||Ve||nt,ct=ze||$e||et||"?";return te.Z.API_SERVER+"/api/attachments/"+pt+ct+"&t="+(0,le.Jn)(pt,Date.now())+(ut.indexOf(")")>-1?")":"&")}).replace(He,(ut,Ge,ze,Ve,$e)=>{const nt=Ge||Ve,et=ze||$e||"";return'"'+te.Z.API_SERVER+"/api/attachments/"+nt+et+nt+et+"&t="+(0,le.Jn)(nt,Date.now())}).replace(rt,(ut,Ge,ze,Ve,$e)=>{const nt=Ge||Ve,et=ze||$e||"";return"("+te.Z.API_SERVER+"/files/uploads/"+nt+et+nt+et+"&t="+(0,le.Jn)(nt,Date.now())}).replaceAll('src="(','src="').replaceAll("src='(",'src="').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,`
|
|
|
`),Qe)};var Pe=({value:Qe="",edit:Xe=!1,className:ot,showTextOnly:He,showLines:rt,style:Ye={},stylesPrev:ut={},highlightKeywords:Ge,showProgramFill:ze,isProgramFill:Ve,disabledFill:$e=!1,programFillValue:nt,openEditor:et=()=>{},onFillChange:pt=dt=>{},onFillBlur:ct=()=>{},onFillFocus:Ot=()=>{}})=>{let dt=oe(String(Qe||""));const Rt=(0,ce.useRef)(),xt=(0,ce.useRef)(),[gt,_t]=(0,ce.useState)(""),[We,Ae]=(0,ce.useState)("office"),[Se,Be]=(0,ce.useState)([]),Ke=(0,ce.useRef)("a"+(0,b.Z)()),Ne={},De=yt=>/<style[\s\S]*?>/i.test(yt||""),we=(yt,Yt,Lt)=>{const Kt=document.createElement(yt===Te?"input":"textarea");Kt.style.width="100%",Kt.style.height=yt===Te?"40px":"151px",Kt.rows=5,Kt.spellcheck=!1,Kt.name="edu-program-fill",Kt.placeholder="\u8BF7\u8F93\u5165",Kt.dataset.id=Yt;const sn=Object.keys(Ne).length;return Ne[sn]=Kt,`<span class="edu-program-fill-wrap ${yt===Te?"":"show"}" style="width:${yt===Te?"600px":"100%"}" title=${Lt||""}><span>${Kt.outerHTML}<span class="edu-program-fill-score" style="margin:0 6px"></span></span></span>`};function Le(yt){return yt=yt.replace(/!\[.*?\]\(.*?\)/g,""),yt=yt.replace(/\[.*?\]\(.*?\)/g,""),yt=yt.replace(new RegExp("<iframe.*?<\\/iframe>","gs"),""),yt=yt.replace(/<embed.*?>/g,""),yt=yt.replace(/<img.*?>/g,""),yt=yt.replace(new RegExp("<video.*?>.*?<\\/video>","gs"),""),yt=yt.replace(new RegExp("<audio.*?>.*?<\\/audio>","gs"),""),yt=yt.replace(new RegExp("<style.*?>.*?<\\/style>","gs"),""),yt=yt.replace(new RegExp("<script.*?>.*?<\\/script>","gs"),""),yt}const Ue=yt=>!He&&De(dt)?yt:yt.replace(/<style.*?>([\s\S]+?)<\/style>/gim,function(Yt,Lt){let Kt=Lt.replace(/(\n|\r)/g,"").split("}"),sn=[];return Kt.map(wn=>{wn!=""&&sn.push(`.${Ke.current} ${wn}`)}),`<style>${sn.join("}")}</style>`}),Me=(0,ce.useMemo)(()=>{try{const Kt=/\(\s+\/api\/attachments\/|\(\/api\/attachments\//g,sn=/\"\/api\/attachments\/|\"\/attachments\/download\//g,wn=/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g,Vt=/\(\/attachments\/download\//g;dt=dt.replace(Vt,"("+te.Z.API_SERVER+"/attachments/download/").replace(Kt,"("+te.Z.API_SERVER+"/api/attachments/").replace(sn,'"'+te.Z.API_SERVER+"/api/attachments/").replace(wn,'"'+te.Z.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,`
|
|
|
`),Rt.current.style.display="none"}catch(Kt){}if(ze){let Kt=-1;return dt=dt.replaceAll("<","<").replaceAll(">",">").replace(/(@▁▁@|@▁@)/g,function(sn,wn,Vt){var Rn;return++Kt,we(sn,Kt,(Rn=nt==null?void 0:nt[Kt])==null?void 0:Rn.value.replaceAll("<","<").replaceAll(">",">"))}),`<pre style="background:#fff;padding:4px">${Ue(dt||"")}</pre>`}let yt=Ue(dt);yt=(0,Ce.ZP)(yt);const Yt=(0,Ce.ez)();dt.match(/\[TOC\]/)&&(yt=yt.replace("<p>[TOC]</p>",(0,Ce.Qv)()),(0,Ce.Iy)()),yt=yt.replace(/(__special_katext_id_\d+__)/g,(Kt,sn)=>{const{type:wn,expression:Vt}=Yt[sn];return(0,ee.renderToString)(Oe(Vt)||"",{displayMode:wn==="block",throwOnError:!1,output:"html"})}),yt=yt.replace(/▁/g,"\u2581\u2581\u2581\u2581\u2581"),(0,Ce.AL)();const Lt=document.createElement("div");if(Lt.innerHTML=yt,He)return Lt.innerText;if(Ge){const Kt=Ge.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return Nt(Lt,Kt),Lt.innerHTML}return setTimeout(()=>Pt(),500),Lt.innerHTML},[dt,Ge]);(0,ce.useEffect)(()=>{Ct.current&&Ct.current.querySelectorAll(["input","textarea"]).forEach(Yt=>{Yt.oninput=Re,Yt.onblur=tt,Yt.onfocus=lt})},[Se]),(0,ce.useEffect)(()=>{var yt,Yt,Lt,Kt,sn;if(nt!=null&&nt.length)try{const wn=Ct.current.querySelectorAll(".edu-program-fill-score"),Vt=Ct.current.querySelectorAll('[name="edu-program-fill"]');for(const[Rn,Gn]of Vt.entries())Gn.value=((yt=nt==null?void 0:nt[Rn])==null?void 0:yt.value)||"",((Yt=nt==null?void 0:nt[Rn])==null?void 0:Yt.type)==="warning"?Gn.className="program-fill-warning":((Lt=nt==null?void 0:nt[Rn])==null?void 0:Lt.type)==="success"?Gn.className="program-fill-success":Gn.className="";for(const[Rn,Gn]of wn.entries())Gn.innerHTML=(Kt=nt==null?void 0:nt[Rn])!=null&&Kt.score?`${(sn=nt==null?void 0:nt[Rn])==null?void 0:sn.score}\u5206`:"";Be(nt)}catch(wn){console.log(wn,"error")}},[nt]);const Re=yt=>{Se[yt.target.dataset.id]=Se[yt.target.dataset.id]||{},Se[yt.target.dataset.id].value=yt.target.value,Be([...Se]),pt(Se,yt.target.dataset.id)},tt=yt=>{Se[yt.target.dataset.id]=Se[yt.target.dataset.id]||{},Se[yt.target.dataset.id].value=yt.target.value,Be([...Se]),ct(Se,yt.target.dataset.id)},lt=yt=>{Se[yt.target.dataset.id]=Se[yt.target.dataset.id]||{},Se[yt.target.dataset.id].value=yt.target.value,Be([...Se]),Ot(Se,yt.target.dataset.id)};function Nt(yt,Yt){return yt.childNodes.forEach(Lt=>{var Kt;if(Lt.childNodes.length>0)Nt(Lt,Yt);else if(Lt.nodeName!=="IMG")if(Lt.innerHTML)Lt.innerHTML=(Kt=Lt.innerHTML)==null?void 0:Kt.replace(new RegExp(Yt,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>');else{const sn=document.createElement("span");sn.innerHTML=Lt.textContent.replace(new RegExp(Yt,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>'),Lt.replaceWith(sn)}})}const Ct=(0,ce.useRef)();Ce.jb.WebkitLineClamp=rt,rt&&(Ye=pe(pe({},Ye),Ce.jb));function vt(yt){let Yt=yt.target;if(Yt.tagName.toUpperCase()==="A"){let Lt=Yt.getAttribute("href");if(Lt.indexOf("office")>-1)yt.preventDefault(),_t(Lt),Ae("office");else if(Lt.indexOf("application/pdf")>-1)yt.preventDefault(),_t(Lt),Ae("pdf");else if(Lt.indexOf("text/html")>-1)yt.preventDefault(),_t(Lt),Ae("html");else if(Lt.startsWith("#")){yt.preventDefault();let Kt=document.getElementById(Lt.replace("#",""));Kt&&Kt.scrollIntoView(!0)}}}const Pt=()=>{var yt;const Yt=(yt=Ct.current)==null?void 0:yt.querySelectorAll("video");Yt==null||Yt.forEach(Lt=>{if(Lt.oncontextmenu=()=>!1,Lt.src.indexOf(".m3u8")>-1&&!Lt.canPlayType("application/vnd.apple.mpegurl")){if(se.ZP.isSupported()){var Kt=new se.ZP;Kt.loadSource(Lt.src),Kt.attachMedia(Lt)}}})};(0,ce.useEffect)(()=>{if(Ct.current&&Me&&Me.match(Ee)&&window.PR.prettyPrint(),Ct.current)return Ct.current.addEventListener("click",vt),()=>{var yt;(yt=Ct.current)==null||yt.removeEventListener("click",vt),(0,Ce.AL)(),(0,Ce.Iy)()}},[Me,Ct.current,vt]);const Ht=yt=>{yt.target.nodeName==="IMG"&&yt.target.className.indexOf("draw-flowchart")>-1?(Rt.current.style.zIndex=1,Rt.current.style.display="flex",Rt.current.style.width=yt.target.clientWidth+"px",Rt.current.style.height=yt.target.clientHeight+"px",Rt.current.style.top=yt.target.offsetTop+"px",Rt.current.style.left=yt.target.offsetLeft+"px",yt.target.id&&(xt.current=yt.target.id)):Rt.current.style.display="none"},jt=()=>{Rt.current.style.display="none"};return(0,ce.useEffect)(()=>{var yt;const Yt=Lt=>{Lt.preventDefault(),Lt.clipboardData.setData("text",window.getSelection().toString())};return(yt=Ct.current)==null||yt.addEventListener("copy",Yt),()=>{var Lt;(Lt=Ct.current)==null||Lt.removeEventListener("copy",Yt)}},[Ct.current]),ce.createElement("div",{style:{position:"relative"},onMouseLeave:jt},He&&ce.createElement("div",{ref:Ct,className:`${ve.mdBody} `},Me),!He&&!De(Me)&&ce.createElement("div",{ref:Ct,style:pe({},Ye),onMouseOver:Ht,className:`${ot||""} ${$e?"disabled-fill":""} markdown-body ${ve.mdBody} ${Ke.current}`,dangerouslySetInnerHTML:{__html:Me}}),!He&&De(Me)&&ce.createElement(ae,{html:Me}),ce.createElement("div",{ref:Rt,className:`${ve.button} ${Xe?"":ve.previewFlowChart}`},ce.createElement(ne.Z,null,ce.createElement(E.ZP,{onClick:()=>{Xe?et(xt.current):(_t(xt.current),Ae("flowChart"))}},Xe?"\u7F16\u8F91":"\u9884\u89C8"))),ce.createElement(z.Z,{close:!0,data:gt,type:gt!=null&>.length?We:"",style:pe({},ut),onClose:()=>_t("")}))}},766:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ue}});var ce=be(76560),ie={ldsRing:"ldsRing___mpBZC",idsRingWrapper:"idsRingWrapper___Of9_n",ldsring:"ldsring___o0w2t"},Ce=be(59301),ue=({message:se,className:te,children:le,style:ee={}})=>Ce.createElement("div",{className:`custom-spinner ${ie.idsRingWrapper} ${te}`},Ce.createElement("div",{className:ie.ldsRing},Ce.createElement("div",null),Ce.createElement("div",null),Ce.createElement("div",null),Ce.createElement("div",null)),se?Ce.createElement("p",{style:ee},se):null,le,Ce.createElement(ce.Outlet,null))},72015:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ue}});var ce=be(59301),ie=be(33796),Ce=be(59301),ue=({defaultX:se="40%",leftChild:te,rightChild:le,className:ee,hideResize:ne=!1})=>{const[E,b]=(0,ce.useState)(se),z=(0,ce.useRef)();function x(){z.current=!0}(0,ce.useEffect)(()=>{function oe(ye){z.current&&(ie.Z.publish("resize-move-bar",ye),b(ye.pageX))}function ve(){z.current=!1}return window.addEventListener("mousemove",oe),window.addEventListener("mouseup",ve),()=>{window.removeEventListener("mousemove",oe),window.removeEventListener("mouseup",ve)}},[]);const re=typeof E=="number"&&E!==.01?`${E}px`:se,ae=`calc(100% - ${ne?"0px":"4px"} - ${re})`;return Ce.createElement("div",{className:`split-panel-container ${ee}`},Ce.createElement("section",{style:{width:re,display:E===.01?"none":""}},te),Ce.createElement("section",{className:"resize-x-bar",onMouseDown:x},Ce.createElement("a",{className:"btn-resize"},Ce.createElement("svg",{width:"16",height:"13",viewBox:"0 0 16 13"},Ce.createElement("path",{d:"M12.245 7.53H5.647v1.882h6.598v2.823L16 8.471l-3.755-3.765V7.53zM10.353 4.706H3.755v2.823L0 3.765 3.755 0v2.824h6.598v1.882z"})))),Ce.createElement("section",{style:{width:ae}},le))}},46685:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return te}});var ce=be(59301),ie={flex_box_center:"flex_box_center___Gc4dd",flex_space_between:"flex_space_between___K2f1v",flex_box_vertical_center:"flex_box_vertical_center___pupRp",flex_box_center_end:"flex_box_center_end___UDLRC",flex_box_column:"flex_box_column___a5uDo",result:"result___gu5zt",title:"title___xrnx2",left:"left___IAxp9",leftNode:"leftNode___HL8fG",right:"right___ZXYmw",rightNode:"rightNode___jYL5_"},Ce=be(92310),ue=be.n(Ce),te=({className:le,style:ee={},leftNode:ne,leftTitle:E="\u81EA\u6D4B\u8F93\u5165",rightNode:b,rightTitle:z="\u8FD0\u884C\u7ED3\u679C"})=>ce.createElement("div",{className:ue()(ie.result,le),style:ee},ce.createElement("div",{className:ie.left},ce.createElement("div",{className:ie.title},ce.createElement("i",{style:{color:"#08CF76"},className:"iconfont iconfont icon-zidingyiceshiyongli font14 mr5"}),ce.createElement("span",null,E)),ce.createElement("div",{className:ie.leftNode},ne)),ce.createElement("div",{className:ie.right},ce.createElement("div",{className:ie.title},ce.createElement("i",{style:{color:"#00DFFF"},className:"iconfont iconfont icon-daimazhihangjieguo font14 mr5"}),ce.createElement("span",null,z)),ce.createElement("div",{className:ie.rightNode},b)))},38273:function(Xt,Mt,be){"use strict";var ce=be(59301);const ie=ue=>String(ue).length===1?`0${ue}`:ue,Ce=({className:ue="",onChange:se,defaultValue:te=0})=>{const[le,ee]=(0,ce.useState)(te);(0,ce.useEffect)(()=>{const z=setTimeout(()=>{ee(le+1e3)},1e3);return se(le+1e3),()=>{clearInterval(z)}},[le]);const ne=parseInt(le/(60*6e4))||"00",E=parseInt(le%(60*6e4)/6e4)||"00",b=parseInt(le%6e4/1e3)||"00";return ce.createElement("div",{className:ue},ie(ne),":",ie(E),":",ie(b))};Mt.Z=Ce},93152:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ae}});var ce=be(59301),ie=be(6767),Ce=be(75727),ue=be(60513),se=be(68535),te=be(34055),le=be(56102),ee=be(2610),ne={watermark:"watermark___hNYlv",videovideo:"videovideo___ovOkV",animate__loop:"animate__loop___mvL6s",upDown:"upDown___SlgHv",container:"container___g1WYG","video-container":"video-container___XPkWR","video-controls":"video-controls___to0Zq",hide:"hide___NA3DV","video-progress":"video-progress___gqHsd",seek:"seek___iZHBm","seek-tooltip":"seek-tooltip___uWyXx","bottom-controls":"bottom-controls___uoIBm","left-controls":"left-controls___mBEx4","right-controls":"right-controls___e9L6r",rateOverlay:"rateOverlay___HHBWe",controlText:"controlText___M_BWR","volume-controls":"volume-controls___fa3mE","fullscreen-button":"fullscreen-button___ur0es","fullscreen-button1":"fullscreen-button1___rfaXm","pip-button":"pip-button___GFO8W","playback-animation":"playback-animation___ndURq",volume:"volume___OTmpP",hidden:"hidden___o7GkT"},E=(oe,ve,ye)=>new Promise((me,ge)=>{var _e=ke=>{try{pe(ye.next(ke))}catch(Te){ge(Te)}},he=ke=>{try{pe(ye.throw(ke))}catch(Te){ge(Te)}},pe=ke=>ke.done?me(ke.value):Promise.resolve(ke.value).then(_e,he);pe((ye=ye.apply(oe,ve)).next())});function b(oe){if(isNaN(oe))return{minutes:"00",seconds:"00"};const ve=new Date(oe*1e3).toISOString().substr(11,8);return{hour:ve.substr(0,2),minutes:ve.substr(3,2),seconds:ve.substr(6,2)}}Object.defineProperty(HTMLMediaElement.prototype,"playing",{get:function(){return this.currentTime>0&&!this.paused&&!this.ended&&this.readyState>2}});function z(oe,ve){return oe-ve}function x(oe){oe.sort(z);let ve=0;for(let ye=0;ye<oe.length-1;ye++){let me=Math.abs(oe[ye+1]-oe[ye]);me<21&&(ve+=me)}return ve}const re=/(android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini)/i;var ae=(0,ce.forwardRef)(({allow_skip:oe,src:ve,toLog:ye,videoId:me,logWatchHistory:ge,courseId:_e=null,startTime:he,handlePause:pe=()=>{},handlePlay:ke=()=>{},handlePlayEnded:Te=()=>{},autoPlay:Ee=!1,onPlayEnded:Oe=()=>{},isShowWaterMark:je=!0},Pe)=>{var Qe;ve=ve==null?void 0:ve.replace("http://","https://");const ot=((Qe=ve==null?void 0:ve.split("."))==null?void 0:Qe.pop())==="flv",He=(0,ce.useRef)(),rt=(0,ce.useRef)(),Ye=(0,ce.useRef)(),ut=(0,ce.useRef)(),Ge=(0,ce.useRef)(),ze=(0,ce.useRef)(),Ve=(0,ce.useRef)(),$e=(0,ce.useRef)(),nt=(0,ce.useRef)(),et=(0,ce.useRef)(),pt=(0,ce.useRef)(),ct=(0,ce.useRef)(),Ot=(0,ce.useRef)(),dt=(0,ce.useRef)(),Rt=navigator.userAgent.toLowerCase().match(re),xt=Rt?Rt[0]:"pc",gt=(0,ce.useRef)(!1),_t=(0,te.eY)();let We=0,Ae=0,Se=0,Be=null,Ke=!1,Ne=20,De=1,we=!1,Le=!1,Ue=[];(0,ce.useImperativeHandle)(Pe,()=>({getLastUpdatedTime:()=>He.current.currentTime,getDuration:()=>He.current.duration})),ie.ZP.config({maxCount:1,getContainer:()=>Ye.current});const Me=(0,ce.useCallback)((Pt,Ht=!1)=>{let jt={point:He.current.currentTime};Be?(jt.log_id=Be,jt.watch_duration=x(Ue),jt.total_duration=Ae):(_e?(jt.video_id=parseInt(me,10),jt.course_id=_e):jt.video_id=me,jt.duration=We,jt.device=xt),Ht&&(jt.ed="1");function yt(){return E(this,null,function*(){we=!0,Be=yield ge==null?void 0:ge(jt),we=!1,Pt&&Pt()})}yt()},[me,_e]);(0,ce.useEffect)(()=>{He.current&&(ut.current.style.display="none",Ge.current.style.display="block"),ie.ZP.destroy();let Pt=null;return ue.Z.isSupported&&ot&&ve&&(ve==null?void 0:ve.indexOf(".m3u8"))<0?(Pt=ue.Z.createPlayer({type:"flv",volume:.8,cors:!0,url:ve,muted:!1}),He.current&&(Pt.attachMediaElement(He.current),Pt.load())):He.current.setAttribute("src",ve),tt(),()=>{Pt&&(Pt.unload(),Pt.pause(),Pt.destroy(),Pt=null)}},[He,ot,ve]);function Re(){He.current.paused?(ut.current.style.display="none",Ge.current.style.display="block"):(ut.current.style.display="block",Ge.current.style.display="none")}function tt(){pt.current.style.display="none",Ot.current.style.display="none",ct.current.style.display="none",He.current.muted||He.current.volume===0?pt.current.style.display="block":He.current.volume>0&&He.current.volume<=.5?Ot.current.style.display="block":ct.current.style.display="block"}(0,ce.useEffect)(()=>{const Pt=document.getElementById("play"),Ht=document.querySelectorAll(".playback-icons use");function jt(){ke(),he&&!gt.current&&(He.current.currentTime=he),gt.current=!0,Ue.push(He.current.currentTime),Ke||(Ke=!0,ye&&Me())}function yt(){return E(this,null,function*(){Re(),Ue.push(He.current.currentTime),ye&&Me(()=>{Be=null,Se=0,Ke=!1,we=!1,Le=!1,Ue=[],Ae=0,De=1},!0),Oe()})}function Yt(){ze.current.value=Math.round(He.current.currentTime),Ve.current.value=Math.round(He.current.currentTime)}function Lt(){const zn=b(Math.round(He.current.currentTime));nt.current.innerText=`${zn.hour>0?zn.hour+":":""}${zn.minutes}:${zn.seconds}`,nt.current.setAttribute("datetime",`${zn.hour>0?" "+zn.hour+" ":""}${zn.minutes}m ${zn.seconds}s`)}function Kt(){var zn,Bn,ir,Kn,Nn,yn,Hn;const dr=Math.round((zn=He.current)==null?void 0:zn.duration);(ir=(Bn=ze.current)==null?void 0:Bn.setAttribute)==null||ir.call(Bn,"max",dr),(Nn=(Kn=Ve.current)==null?void 0:Kn.setAttribute)==null||Nn.call(Kn,"max",dr);const Mn=b(dr);$e.current&&($e.current.innerText=`${Mn.hour>0?Mn.hour+":":""}${Mn.minutes}:${Mn.seconds}`,(Hn=(yn=$e.current).setAttribute)==null||Hn.call(yn,"datetime",`${Mn.hour>0?" "+Mn.hour+" ":""}${Mn.minutes}m ${Mn.seconds}s`))}function sn(){try{const zn=Math.round(He.current.duration);ze.current.setAttribute("max",zn),Ve.current.setAttribute("max",zn);const Bn=b(zn);$e.current.innerText=`${Bn.hour>0?Bn.hour+":":""}${Bn.minutes}:${Bn.seconds}`,$e.current.setAttribute("datetime",`${Bn.hour>0?" "+Bn.hour+" ":""}${Bn.minutes}m ${Bn.seconds}s`),Yt(),Lt();const{width:ir,height:Kn,x:Nn,y:yn}=rt.current.getBoundingClientRect();if(Nn<0||yn<0,!Le){let Hn=He.current.currentTime,dr=Hn-Se;Math.abs(dr)<10?(Ae+=Math.abs(dr),Se=Hn,we||Ae-De*Ne>=0&&(De++,Ue.push(Se),ye&&Me())):(Se=Hn,ye&&Me())}}catch(zn){console.log("videoplaying:",zn)}}function wn(){Le=!0}function Vt(){He.current.playing&&Ue.push(He.current.currentTime,Se),Se=He.current.currentTime,Le=!1}function Rn(){We=He.current.duration,We<=20&&(Ne=We/3),He.current.addEventListener("play",jt)}function Gn(zn){zn.preventDefault(),(0,ee.vp)()?(He.current.style.width="100%",He.current.style.height="100%"):He.current.style.cssText=""}function Zn(){pe()}function tr(zn){if(!oe){ie.ZP.warning("\u8BE5\u89C6\u9891\u7981\u6B62\u5FEB\u8FDB/\u540E\u9000\u64AD\u653E");return}const Bn=zn.target.dataset.seek?zn.target.dataset.seek:zn.target.value;He.current.currentTime=Bn,Ve.current.value=Bn,ze.current.value=Bn}function hr(zn){const Bn=Math.round(zn.offsetX/zn.target.clientWidth*parseInt(zn.target.getAttribute("max"),10));ze.current.setAttribute("data-seek",Bn);const ir=b(Bn);et.current.textContent=`${ir.hour>0?ir.hour+":":""}${ir.minutes}:${ir.seconds}`;const Kn=He.current.getBoundingClientRect();et.current.style.left=`${zn.pageX-Kn.left}px`}function ur(zn){switch(zn.code){case"Space":zn.preventDefault(),Ct();break;case"ArrowRight":if(zn.preventDefault(),!oe){ie.ZP.warning("\u8BE5\u89C6\u9891\u7981\u6B62\u5FEB\u8FDB/\u540E\u9000\u64AD\u653E");break}if(He.current.currentTime>=He.current.duration)break;He.current.currentTime=parseInt(He.current.currentTime)+5,Yt();break;case"ArrowLeft":if(zn.preventDefault(),!oe){ie.ZP.warning("\u8BE5\u89C6\u9891\u7981\u6B62\u5FEB\u8FDB/\u540E\u9000\u64AD\u653E");break}if(He.current.currentTime===0)break;He.current.currentTime=parseInt(He.current.currentTime)-5,Yt();break;case"ArrowUp":zn.preventDefault(),He.current.volume<1&&(He.current.volume=(parseInt(He.current.volume*10)+1)/10);break;case"ArrowDown":zn.preventDefault(),He.current.volume>0&&(He.current.volume=(parseInt(He.current.volume*10)-1)/10);break}}return Ye.current.addEventListener((0,ee.gH)(),Gn),He.current.addEventListener("canplay",Rn),He.current.addEventListener("ended",yt),He.current.addEventListener("seeking",wn),He.current.addEventListener("seeked",Vt),He.current.addEventListener("loadedmetadata",Kt),ze.current.addEventListener("mousemove",hr),ze.current.addEventListener("input",tr),He.current.addEventListener("timeupdate",sn),He.current.addEventListener("pause",Zn),He.current.addEventListener("volumechange",tt),document.addEventListener("keydown",ur),()=>{var zn,Bn,ir,Kn,Nn,yn,Hn,dr,Mn,Cn,$n,Jt;(zn=He.current)==null||zn.removeEventListener("canplay",Rn),(Bn=He.current)==null||Bn.removeEventListener("play",jt),(ir=He.current)==null||ir.removeEventListener("ended",yt),(Kn=He.current)==null||Kn.removeEventListener("seeking",wn),(Nn=He.current)==null||Nn.removeEventListener("seeked",Vt),(yn=ze.current)==null||yn.removeEventListener("mousemove",hr),(Hn=ze.current)==null||Hn.removeEventListener("input",tr),(dr=He.current)==null||dr.removeEventListener("timeupdate",sn),(Mn=He.current)==null||Mn.removeEventListener("pause",Zn),(Cn=He.current)==null||Cn.removeEventListener("loadedmetadata",Kt),($n=He.current)==null||$n.removeEventListener("volumechange",tt),document.removeEventListener("keydown",ur),(Jt=He.current)!=null&&Jt.playing&&(Ue.push(Se,He.current.currentTime),ye&&Me())}},[He,ve]),(0,ce.useEffect)(()=>{if(He.current.onended=()=>{Te(He)},He.current.oncontextmenu=()=>!1,(ve==null?void 0:ve.indexOf(".m3u8"))>-1){if(He.current.canPlayType("application/vnd.apple.mpegurl"))He.current.src=ve;else if(se.ZP.isSupported()){var Pt=new se.ZP;Pt.loadSource(ve),Pt.attachMedia(He.current)}}},[ve]);const[lt,Nt]=(0,ce.useState)(1),Ct=()=>{He.current.paused||He.current.ended?He.current.play():He.current.pause(),Re()};function vt(){He.current.muted=!He.current.muted,He.current.muted?(dt.current.setAttribute("data-volume",volume.value),dt.current.value=0):dt.current.value=dt.current.dataset.volume}return ce.createElement("div",{style:{position:"relative"},ref:Ye},ce.createElement("div",{ref:rt,className:`${ne.watermark} animated_alternate animate__animated_10s animate__infinite animate__stepstart ${ne.animate__loop}`},je&&_t?_t.login:" "),ce.createElement("div",{className:ne.container},ce.createElement("div",{className:ne["video-container"],id:"video-container"},ce.createElement("div",{className:ne["playback-animation"],id:"playback-animation"},ce.createElement("svg",{className:ne["playback-icons"]},ce.createElement("use",{className:"hidden",href:"#play-icon"}),ce.createElement("use",{href:"#pause"}))),ce.createElement("video",{className:ne.video,id:"video",preload:"auto",disablePictureInPicture:!0,ref:He,autoPlay:Ee}),ce.createElement("div",{className:`${ne["video-controls"]} `,id:"video-controls"},ce.createElement("div",{className:ne["bottom-controls"]},ce.createElement("div",{className:ne["left-controls"]},ce.createElement("button",{"data-title":"\u64AD\u653E/\u6682\u505C",id:"play",onClick:Ct},ce.createElement("svg",{className:ne["playback-icons"]},ce.createElement("use",{ref:Ge,href:"#play-icon"}),ce.createElement("use",{ref:ut,style:{display:"none"},href:"#pause"}))),ce.createElement("div",{className:ne.time},ce.createElement("time",{id:"time-elapsed",ref:nt},"00:00"),ce.createElement("span",null," / "),ce.createElement("time",{id:"duration",ref:$e},"00:00"))),ce.createElement("div",{className:ne["right-controls"]},oe&&ce.createElement(Ce.Z,{placement:"top",overlayClassName:ne.rateOverlay,getPopupContainer:Pt=>Pt.parentNode,menu:{items:[{key:"1",label:ce.createElement("span",{onClick:()=>{Nt(1),He.current.playbackRate=1}},"1.0x")},{key:"2",label:ce.createElement("span",{onClick:()=>{Nt(1.5),He.current.playbackRate=1.5}},"1.5x")},{key:"3",label:ce.createElement("span",{onClick:()=>{Nt(2),He.current.playbackRate=2}},"2.0x")}]}},ce.createElement("div",{className:`${ne.controlText} mr5`},"\u500D\u901F")),ce.createElement(le.CopyToClipboard,{text:ve,onCopy:()=>ie.ZP.success("\u590D\u5236\u6210\u529F")},ce.createElement("button",{"data-title":"\u590D\u5236\u94FE\u63A5"},ce.createElement("i",{className:"icon-lianjie2 iconfont",style:{fontSize:"12px",color:"white"}}))),ce.createElement("div",{className:ne["volume-controls"]},ce.createElement("button",{"data-title":"\u5F00\u542F/\u5173\u95ED\u58F0\u97F3",className:ne["volume-button"],id:"volume-button",onClick:vt},ce.createElement("i",{ref:pt,className:"icon-a-bianzu8 iconfont",style:{fontSize:"14px",color:"white"}}),ce.createElement("i",{ref:Ot,className:"icon-shengyinkaibeifen iconfont",style:{fontSize:"14px",color:"white"}}),ce.createElement("i",{ref:ct,className:"icon-shengyinkai iconfont",style:{fontSize:"14px",color:"white"}})),ce.createElement("input",{className:ne.volume,id:"volume",value:"1","data-mute":"0.5",type:"range",max:"1",min:"0",step:"0.01",ref:dt,style:{display:"none"},onClick:tt})),ce.createElement("button",{"data-title":"\u5168\u5C4F/\u9000\u51FA\u5168\u5C4F",className:ne["fullscreen-button"],onClick:()=>{(0,ee.vp)()?(0,ee.BU)():(0,ee.Dj)(Ye.current)}},ce.createElement("i",{className:"icon-fangda1 iconfont",style:{fontSize:"12px",color:"white"}})))),ce.createElement("div",{className:ne["video-progress"]},ce.createElement("progress",{ref:Ve,value:"0",min:"0"}),ce.createElement("input",{className:ne.seek,ref:ze,value:"0",min:"0",type:"range",step:"1"}),ce.createElement("div",{className:ne["seek-tooltip"],ref:et,id:"seek-tooltip"},"00:00"))))),ce.createElement("svg",{style:{display:"none"}},ce.createElement("defs",null,ce.createElement("symbol",{id:"pause",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M14.016 5.016h3.984v13.969h-3.984v-13.969zM6 18.984v-13.969h3.984v13.969h-3.984z"})),ce.createElement("symbol",{id:"play-icon",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M8.016 5.016l10.969 6.984-10.969 6.984v-13.969z"})),ce.createElement("symbol",{id:"volume-high",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M14.016 3.234q3.047 0.656 5.016 3.117t1.969 5.648-1.969 5.648-5.016 3.117v-2.063q2.203-0.656 3.586-2.484t1.383-4.219-1.383-4.219-3.586-2.484v-2.063zM16.5 12q0 2.813-2.484 4.031v-8.063q1.031 0.516 1.758 1.688t0.727 2.344zM3 9h3.984l5.016-5.016v16.031l-5.016-5.016h-3.984v-6z"})),ce.createElement("symbol",{id:"volume-low",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M5.016 9h3.984l5.016-5.016v16.031l-5.016-5.016h-3.984v-6zM18.516 12q0 2.766-2.531 4.031v-8.063q1.031 0.516 1.781 1.711t0.75 2.32z"})),ce.createElement("symbol",{id:"volume-mute",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M12 3.984v4.219l-2.109-2.109zM4.266 3l16.734 16.734-1.266 1.266-2.063-2.063q-1.547 1.313-3.656 1.828v-2.063q1.172-0.328 2.25-1.172l-4.266-4.266v6.75l-5.016-5.016h-3.984v-6h4.734l-4.734-4.734zM18.984 12q0-2.391-1.383-4.219t-3.586-2.484v-2.063q3.047 0.656 5.016 3.117t1.969 5.648q0 2.203-1.031 4.172l-1.5-1.547q0.516-1.266 0.516-2.625zM16.5 12q0 0.422-0.047 0.609l-2.438-2.438v-2.203q1.031 0.516 1.758 1.688t0.727 2.344z"})),ce.createElement("symbol",{id:"fullscreen",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M14.016 5.016h4.969v4.969h-1.969v-3h-3v-1.969zM17.016 17.016v-3h1.969v4.969h-4.969v-1.969h3zM5.016 9.984v-4.969h4.969v1.969h-3v3h-1.969zM6.984 14.016v3h3v1.969h-4.969v-4.969h1.969z"})),ce.createElement("symbol",{id:"fullscreen-exit",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M15.984 8.016h3v1.969h-4.969v-4.969h1.969v3zM14.016 18.984v-4.969h4.969v1.969h-3v3h-1.969zM8.016 8.016v-3h1.969v4.969h-4.969v-1.969h3zM5.016 15.984v-1.969h4.969v4.969h-1.969v-3h-3z"})),ce.createElement("symbol",{id:"pip",viewBox:"0 0 24 24"},ce.createElement("path",{d:"M21 19.031v-14.063h-18v14.063h18zM23.016 18.984q0 0.797-0.609 1.406t-1.406 0.609h-18q-0.797 0-1.406-0.609t-0.609-1.406v-14.016q0-0.797 0.609-1.383t1.406-0.586h18q0.797 0 1.406 0.586t0.609 1.383v14.016zM18.984 11.016v6h-7.969v-6h7.969z"})))))})},39479:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ue}});var ce=be(59301),ie=be(33796),Ce=be(90083),ue=()=>{const[se,te]=(0,ce.useState)(""),[le,ee]=(0,ce.useState)(0);let[ne,E]=(0,ce.useState)(),[b,z]=(0,ce.useState)();const[x,re]=(0,ce.useState)(!1),ae=(0,ce.useRef)("");(0,ce.useEffect)(()=>ie.Z.subscribe("preview-image",Ee=>{te(Ee),console.log(pe.current)}),[]),(0,ce.useEffect)(()=>(document.addEventListener("keydown",oe),()=>{document.removeEventListener("keydown",oe)}),[]),(0,ce.useEffect)(()=>{ae.current=se},[se]);function oe(Te){console.log("e====",Te),Te.keyCode==27&&ae.current&&ve()}function ve(){document.body.style.overflow="auto",E(void 0),z(void 0),ee(0),te("")}function ye(){ee(le+90)}function me(){ne=pe.current.width*1.1,b=pe.current.height*1.1,z(b),E(ne)}function ge(){ne=pe.current.width/1.1,b=pe.current.height/1.1,z(b),E(ne)}const _e=(0,ce.useRef)(),he=(0,ce.useRef)(),pe=(0,ce.useRef)(),ke=Te=>{(Te.nativeEvent.target===_e.current||Te.nativeEvent.target===he.current)&&ve()};return ce.createElement(ce.Fragment,null,se?ce.createElement("div",null,ce.createElement("div",{className:"preview-wrp-group",ref:he},ce.createElement(Ce.Z,{className:"image-preview",src:se,style:{display:"none"},preview:{visible:!0,src:se,onVisibleChange:Te=>{te("")}},alt:"\u9884\u89C8\u5927\u56FE"}))):null)}},44905:function(Xt,Mt,be){"use strict";be.d(Mt,{h:function(){return _e}});var ce=be(59301),ie=be(82326),Ce=be(28284),ue=be(99571),se=be(89780),te=be.n(se),le=be(66543),ee=be(59598),ne=Object.defineProperty,E=Object.defineProperties,b=Object.getOwnPropertyDescriptors,z=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,re=Object.prototype.propertyIsEnumerable,ae=(he,pe,ke)=>pe in he?ne(he,pe,{enumerable:!0,configurable:!0,writable:!0,value:ke}):he[pe]=ke,oe=(he,pe)=>{for(var ke in pe||(pe={}))x.call(pe,ke)&&ae(he,ke,pe[ke]);if(z)for(var ke of z(pe))re.call(pe,ke)&&ae(he,ke,pe[ke]);return he},ve=(he,pe)=>E(he,b(pe));const ye=ie.default.Option,me={labelCol:{span:4},wrapperCol:{span:20}},ge={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"]};Mt.Z=({callback:he,onCancel:pe})=>{const[ke,Te]=(0,ce.useState)("python");function Ee(je){Te(ge[je][1])}function Oe(je){he(je)}return ce.createElement(Ce.default,ve(oe({},me),{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:Oe,style:{width:500}}),ce.createElement(Ce.default.Item,{label:"\u4EE3\u7801\u8BED\u8A00",name:"language"},ce.createElement(ie.default,{getPopupContainer:je=>je.parentNode,onChange:Ee},Object.keys(ge).map(je=>ce.createElement(ye,{key:je,value:je},ge[je][0])))),ce.createElement(Ce.default.Item,{label:"\u4EE3\u7801\u5185\u5BB9",name:"content",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u4EE3\u7801\u5185\u5BB9"}]},ce.createElement(_e,{mode:ke})),ce.createElement("div",{className:"flex-container flex-end"},ce.createElement(ue.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),ce.createElement(ue.ZP,{type:"ghost",onClick:pe},"\u53D6\u6D88")))};function _e({value:he,onChange:pe,mode:ke,options:Te={}}){const Ee=(0,ce.useRef)(),[Oe,je]=(0,ce.useState)();return(0,ce.useEffect)(()=>{if(Oe){let Pe=function(Qe){const Xe=Qe.getValue();pe&&pe(Xe)};return Oe.on("change",Pe),()=>{Oe.off("change",Pe)}}},[Oe,pe]),(0,ce.useEffect)(()=>{Oe&&Oe.setOption("mode",ke)},[Oe,ke]),(0,ce.useEffect)(()=>{Oe&&(he!==Oe.getValue()||he==="")&&setTimeout(()=>{Oe.setValue(he||"")},300)},[Oe,he]),(0,ce.useEffect)(()=>{if(Ee.current&&!Oe){const Pe=te().fromTextArea(Ee.current,oe({mode:ke,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},Te));je(Pe)}},[Ee.current,Oe]),ce.createElement("div",{className:"my-codemirror-container"},ce.createElement("textarea",{ref:Ee}))}},2978:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return dr}});var ce=be(59301),ie=be(76560),Ce=be(89780),ue=be.n(Ce),se=be(76374),te=be(66543),le=be(6313),ee=be(25717),ne=be(99498),E=be(25419),b=be(67549),z=be(38394),x=({value:Mn="",className:Cn,showTextOnly:$n,showLines:Jt,style:Ie={}})=>{const Ze=(0,ce.useMemo)(()=>"",[Mn]);return ce.createElement(ce.Fragment,null,ce.createElement("div",{dangerouslySetInnerHTML:{__html:Ze}}))},re=Object.defineProperty,ae=Object.defineProperties,oe=Object.getOwnPropertyDescriptors,ve=Object.getOwnPropertySymbols,ye=Object.prototype.hasOwnProperty,me=Object.prototype.propertyIsEnumerable,ge=(Mn,Cn,$n)=>Cn in Mn?re(Mn,Cn,{enumerable:!0,configurable:!0,writable:!0,value:$n}):Mn[Cn]=$n,_e=(Mn,Cn)=>{for(var $n in Cn||(Cn={}))ye.call(Cn,$n)&&ge(Mn,$n,Cn[$n]);if(ve)for(var $n of ve(Cn))me.call(Cn,$n)&&ge(Mn,$n,Cn[$n]);return Mn},he=(Mn,Cn)=>ae(Mn,oe(Cn));let pe=[{title:"\u7C97\u4F53",icon:"md-iconfont icon-bold",actionName:"bold"},{title:"\u659C\u4F53",icon:"md-iconfont icon-italic",actionName:"italic"},"|",{title:"\u65E0\u5E8F\u5217\u8868",icon:"md-iconfont icon-unorder-list",actionName:"list-ul"},{title:"\u6709\u5E8F\u5217\u8868",icon:"md-iconfont icon-order-list",actionName:"list-ol"},"|",{title:"\u884C\u5185\u4EE3\u7801",icon:"md-iconfont icon-code",actionName:"code"},{title:"\u4EE3\u7801\u5757\uFF08\u591A\u8BED\u8A00\u98CE\u683C\uFF09",icon:"md-iconfont icon-file-code",actionName:"code-block"},{title:"\u94FE\u63A5",icon:"md-iconfont icon-link",actionName:"link"},"|",{title:"\u884C\u5185\u516C\u5F0F",icon:"md-iconfont icon-sum",actionName:"inline-latex"},{title:"\u6570\u5B66\u516C\u5F0F",icon:"iconfont icon-shuxuetuxiang2",actionName:"maths-latex"},{title:"\u591A\u884C\u516C\u5F0F",icon:"md-iconfont icon-formula",actionName:"latex"},"|",{title:"\u6DFB\u52A0\u56FE\u7247",icon:"md-iconfont icon-picture",actionName:"upload-image"},{title:"\u63D2\u5165\u753B\u56FE",icon:"iconfont icon-sheji",actionName:"draw-image"},{title:"\u63D2\u5165\u6D41\u7A0B\u56FE",icon:"iconfont icon-liucheng",actionName:"add-flowchart"},{title:"\u8868\u683C",icon:"md-iconfont icon-table",actionName:"add-table"},"|",{title:"\u6362\u884C",icon:"md-iconfont icon-minus",actionName:"line-break"},{title:"\u6E05\u7A7A",icon:"md-iconfont icon-eraser",actionName:"eraser"}];function ke({onActionCallback:Mn,title:Cn,icon:$n,actionName:Jt,className:Ie="",children:Ze}){function qe(){Mn(Jt)}return ce.createElement("a",{title:Cn,className:Ie,onClick:qe},ce.createElement("i",{className:`${$n}`}),Ze)}var Te=({watch:Mn,showNullButton:Cn,showNullProgramButton:$n,onActionCallback:Jt,fullScreen:Ie,insertTemp:Ze,hidetoolBar:qe,extraUse:st})=>{const mt=[...pe,{title:`${Mn?"\u5173\u95ED\u5B9E\u65F6\u9884\u89C8":"\u5F00\u542F\u5B9E\u65F6\u9884\u89C8"}`,icon:`${Mn?"md-iconfont icon-eye-slash":"md-iconfont icon-eye"}`,actionName:"trigger-watch"}];return ce.createElement("ul",{className:"markdown-toolbar-container"},!qe&&mt.map((Bt,kt)=>ce.createElement("li",{key:kt},Bt.actionName?ce.createElement(ke,he(_e({},Bt),{onActionCallback:Jt})):ce.createElement("span",{className:"v-line"}))),Cn?ce.createElement("li",null,ce.createElement(ke,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-null-ch",onActionCallback:Jt},ce.createElement("span",{className:"fill-tip"},"\u70B9\u51FB\u63D2\u5165\b\u586B\u7A7A\u9879"))):null,$n?ce.createElement(ce.Fragment,null,ce.createElement("li",null,ce.createElement(ke,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-signal",onActionCallback:Jt},ce.createElement("span",{className:"fill-tip"},"\u6DFB\u52A0\u5355\u884C\u586B\u7A7A\u9879"))),ce.createElement("li",null,ce.createElement(ke,{icon:"md-iconfont icon-uniE900 insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-multiple",onActionCallback:Jt},ce.createElement("span",{className:"fill-tip"},"\u6DFB\u52A0\u591A\u884C\u586B\u7A7A\u9879")))):null,Ze&&ce.createElement("li",null,ce.createElement(ke,{icon:"md-iconfont icon-edit",className:"btn-null",title:"\u63D2\u5165\u6A21\u677F",actionName:`inster-template-${Ze}`,onActionCallback:Jt},ce.createElement("span",{className:"fill-tip"},"\u63D2\u5165\u6A21\u677F"))),st&&ce.createElement("li",null,st),ce.createElement("li",{className:"btn-full-screen"},ce.createElement(ke,{icon:`${Ie?"md-iconfont icon-shrink":"md-iconfont icon-enlarge"}`,title:Ie?"\u5173\u95ED\u5168\u5C4F":"\u5F00\u542F\u5168\u5C4F",actionName:"trigger-full-screen",onActionCallback:Jt})))},Ee=be(75790),Oe=be(28284),je=be(37568),Pe=be(99571),Qe=Object.defineProperty,Xe=Object.defineProperties,ot=Object.getOwnPropertyDescriptors,He=Object.getOwnPropertySymbols,rt=Object.prototype.hasOwnProperty,Ye=Object.prototype.propertyIsEnumerable,ut=(Mn,Cn,$n)=>Cn in Mn?Qe(Mn,Cn,{enumerable:!0,configurable:!0,writable:!0,value:$n}):Mn[Cn]=$n,Ge=(Mn,Cn)=>{for(var $n in Cn||(Cn={}))rt.call(Cn,$n)&&ut(Mn,$n,Cn[$n]);if(He)for(var $n of He(Cn))Ye.call(Cn,$n)&&ut(Mn,$n,Cn[$n]);return Mn},ze=(Mn,Cn)=>Xe(Mn,ot(Cn));const Ve={labelCol:{span:4},wrapperCol:{span:20}};var $e=({callback:Mn,onCancel:Cn})=>{function $n(Jt){Mn(Jt)}return ce.createElement(Oe.default,ze(Ge({},Ve),{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:$n,style:{width:500}}),ce.createElement(Oe.default.Item,{label:"\u94FE\u63A5\u5730\u5740",name:"link",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740"}]},ce.createElement(je.default,null)),ce.createElement(Oe.default.Item,{label:"\u94FE\u63A5\u6807\u9898",name:"title",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u6807\u9898"}]},ce.createElement(je.default,null)),ce.createElement("div",{className:"flex-container flex-end"},ce.createElement(Pe.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),ce.createElement(Pe.ZP,{type:"ghost",onClick:Cn},"\u53D6\u6D88")))},nt=be(44905),et=be(45596),pt=be(62957),ct=be(77019),Ot=be(6077),dt=be(59301),Rt=({callback:Mn,onCancel:Cn})=>{const $n=document.createElement("canvas"),Jt=$n.getContext("2d");$n.width=1e3,$n.height=800,Jt.fillStyle="#ffffff",Jt.fillRect(0,0,$n.width,$n.height);const Ie=$n.toDataURL("image/png");return dt.createElement(pt.default,{open:!0,width:"100vw",style:{height:"100vh",top:0},footer:null,title:null,closable:!1},dt.createElement(ct.Z,{style:{height:"100vh"}},dt.createElement(Ot.Z,{fullWidth:!0,noAssociationId:!0,showFullTools:!0,data:{src:Ie,visible:!0,title:String(Date.now())},onOk:Ze=>{Mn({src:Ze.url})},onClose:Cn})))},xt=be(30641),gt=be(5269),_t=be(6767),We={myPaletteDiv:"myPaletteDiv___Xjz2I",flowChartWrp:"flowChartWrp____f45r",maxH60:"maxH60___Pd4Re",drawerWrap:"drawerWrap___MfDw8"},Ae=be(59301),Be=(0,ce.forwardRef)(({onCancel:Mn,editImgId:Cn,callback:$n},Jt)=>{let Ie=(0,ce.useRef)(),Ze=(0,ce.useRef)(),qe=(0,ce.useRef)(),st=(0,ce.useRef)(!1);const mt=(0,ce.useRef)(!1);console.log("ref:",Jt);const[Bt,kt]=(0,ce.useState)(0),[Ft,qt]=(0,ce.useState)("100vh");return(0,ce.useEffect)(()=>{kt(1)},[]),(0,ce.useImperativeHandle)(Jt,()=>({setHeight:qt})),Ae.createElement("div",{ref:mt,className:"body-overflow-initial"},Ae.createElement(xt.Z,{width:"100vw",height:Ft,footer:null,closable:!0,placement:"bottom",open:!!Bt,destroyOnClose:!0,maskClosable:!1,mask:!1,rootClassName:`zIndex-9999 ${We.drawerWrap}`,onClose:()=>{window.saveDrawData(En=>{$n({src:`/api/attachments/${En}`,id:En})})},title:Ae.createElement(ct.Z,{align:"middle"},Ae.createElement(gt.Z,{flex:1},"\u63D2\u5165\u6D41\u7A0B\u56FE"),Ae.createElement(gt.Z,{onClick:()=>{qt(Ft==="60px"?"100vh":"60px")}},Ae.createElement("span",{className:"current c-blue",style:{fontWeight:400}},"\u5C55\u5F00/\u6536\u8D77")),Ae.createElement(gt.Z,{onClick:()=>{window.saveDrawData(En=>{if(En===null){_t.ZP.warning({content:"\u5185\u5BB9\u4E3A\u7A7A\uFF0C\u8BF7\u5148\u7ED8\u5236\u6D41\u7A0B\u56FE",key:"saveFlowChart"});return}_t.ZP.success({content:"\u4FDD\u5B58\u6210\u529F",key:"saveFlowChart",style:{zIndex:999999999}}),$n({src:`/api/attachments/${En}`,id:En,disabledClose:!0})})}},Ae.createElement(Pe.ZP,{type:"primary",className:"ml20"},"\u4FDD\u5B58")))},Ae.createElement("iframe",{src:`/drawio/src/main/webapp/?id=${Cn||""}&gapi=0&od=0&db=0&gh=0&gl=0&local=0`,width:"100%",height:"100%",frameBorder:"0",ref:Ze})))}),Ke=be(90524),Ne=be(47889),De=be(71051);const we=Ne.ZP.Group,Le={margin:"0 8px"};var Ue=({callback:Mn,onCancel:Cn})=>{function $n(Jt){Mn(Jt)}return ce.createElement(Oe.default,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:$n},ce.createElement("div",{className:"flex-container",style:{alignItems:"baseline"}},ce.createElement("span",{style:Le},"\u5355\u5143\u683C\u6570\uFF1A"),ce.createElement("span",{style:Le},"\u884C\u6570"),ce.createElement(Oe.default.Item,{name:"row",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u884C\u6570"}]},ce.createElement(De.Z,null)),ce.createElement("span",{style:Le},"\u5217\u6570"),ce.createElement(Oe.default.Item,{name:"col",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5217\u6570"}]},ce.createElement(De.Z,null))),ce.createElement("div",{className:"flex-container",style:{marginTop:12,alignItems:"baseline"}},ce.createElement("span",{style:Le},"\u5BF9\u9F50\u65B9\u5F0F\uFF1A"),ce.createElement(Oe.default.Item,{name:"align"},ce.createElement(we,null,ce.createElement(Ne.ZP,{value:"default"},ce.createElement("i",{className:"fa fa-align-justify"})),ce.createElement(Ne.ZP,{value:"left"},ce.createElement("i",{className:"fa fa-align-left"})),ce.createElement(Ne.ZP,{value:"center"},ce.createElement("i",{className:"fa fa-align-center"})),ce.createElement(Ne.ZP,{value:"right"},ce.createElement("i",{className:"fa fa-align-right"}))))),ce.createElement("div",{className:"flex-container flex-end"},ce.createElement(Pe.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),ce.createElement(Pe.ZP,{type:"ghost",onClick:Cn},"\u53D6\u6D88")))},Me=be(71411),Re=be(11081),tt=be.n(Re),Nt=(0,ce.forwardRef)(({use3d:Mn,width:Cn,height:$n,callback:Jt,showSaveButton:Ie},Ze)=>{const qe=(0,ce.useRef)(),st=(0,ce.useRef)(),[mt,Bt]=(0,ce.useState)(!1),kt=(0,ce.useRef)({id:qe,appName:"graphing",width:Cn||1e3,height:$n||600,showToolBar:!0,showMenuBar:!0,allowStyleBar:!0,showAlgebraInput:!0,enableLabelDrags:!1,enableShiftDragZoom:!0,showToolBarHelp:!1,errorDialogsActive:!0,showTutorialLink:!0,showLogging:!0,useBrowserForJS:!1});(0,ce.useEffect)(()=>{st.current=new(tt())(kt.current,!0),window.onload=function(){st.current.inject("applet_container")}},[]);const Ft=()=>{var qt=window.ggbApplet.getPNGBase64(1,!0,72);return Jt&&Jt(qt),qt};return(0,ce.useEffect)(()=>{kt.current.appName=mt?"3D":"graphing",st.current.inject("applet_container")},[mt]),(0,ce.useEffect)(()=>{Bt(Mn)},[Mn]),(0,ce.useImperativeHandle)(Ze,()=>({getImgData:Ft})),ce.createElement(ce.Fragment,null,ce.createElement("div",{style:{width:"100%",height:"100%"},id:"applet_container",ref:qe}),ce.createElement(ct.Z,{align:"middle"},ce.createElement(gt.Z,{flex:1},ce.createElement(Me.Z,{size:"default",checkedChildren:"\u5173\u95ED3D\u56FE\u50CF",unCheckedChildren:"\u5F00\u542F3D\u56FE\u50CF",checked:mt,onChange:qt=>Bt(qt)})),ce.createElement(gt.Z,null,ce.createElement(Pe.ZP,{size:"large",onClick:Ft,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668"))))}),Ct=be(88615);const vt="link",Pt="upload-image",Ht="add-flowchart",jt="draw-image",yt="add-flowchart",Yt="code-block",Lt="add-table",Kt="------------",sn={default:Kt,left:`:${Kt}`,center:`:${Kt}:`,right:`${Kt}:`};var wn=be(17904),Vt=be(49661);function Rn(){}let Gn=0;const Zn=1e4,tr="\u2581",hr="@\u2581\u2581@",ur="@\u2581@",zn=`
|
|
|
**\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`,Bn=["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"];function ir(Mn){return/^\d+$/.test(Mn)?`${Mn}px`:Mn}const Nn=navigator.platform.toUpperCase().indexOf("MAC")>=0?"Cmd":"Ctrl",yn={[Nn+"-B"]:"bold",[Nn+"-I"]:"italic"},Hn={[vt]:"\u6DFB\u52A0\u94FE\u63A5",[Yt]:"\u6DFB\u52A0\u4EE3\u7801\u5757",[Pt]:"\u6DFB\u52A0\u56FE\u7247",[jt]:"\u6DFB\u52A0\u753B\u56FE",[Ht]:"\u63D2\u5165\u6D41\u7A0B\u56FE",[Lt]:"\u6DFB\u52A0\u8868\u683C","maths-latex":"\u6570\u5B66\u56FE\u50CF","inline-latex":"LATEX\u516C\u5F0F"};var dr=({defaultValue:Mn="",onChange:Cn,width:$n="100%",height:Jt=400,miniToolbar:Ie=!1,isFocus:Ze=!1,watch:qe,insertTemp:st,mode:mt="markdown",id:Bt="markdown-editor-id",showResizeBar:kt=!1,noStorage:Ft=!1,showNullButton:qt=!1,showNullProgramButton:En=!1,hidetoolBar:Yn=!1,fullScreen:At=!1,onBlur:St,onCMBeforeChange:an,onFullScreen:Wt,className:Et="",disablePaste:zt=!1,disabled:tn=!1,disabledFill:nn=!1,placeholder:gn="",values:Sn="",extraUse:Tn})=>{const[Tt,jn]=(0,ce.useState)(null),[bn,Fn]=(0,ce.useState)(Mn),[Un,rr]=(0,ce.useState)(qe),[pr,Rr]=(0,ce.useState)(At),[wr,Lr]=(0,ce.useState)(""),[Vr,xr]=(0,ce.useState)(0),[Ir,jr]=(0,ce.useState)(Jt),[ti,di]=(0,ce.useState)(!1),[wi,xi]=(0,ce.useState)(0),[ai,Di]=(0,ce.useState)(0),_i=(0,ce.useRef)(),or=(0,ce.useRef)(),br=(0,ce.useRef)(),Ar=(0,ce.useRef)(),qr=(0,ce.useRef)(),$r=(0,ce.useRef)(),bi=(0,ie.useDispatch)();(0,ce.useEffect)(()=>{const ln=window.scrollY||window.pageYOffset;Fn(Sn),Tt==null||Tt.setValue(Sn),window.scrollTo(0,ln)},[Sn]),(0,ce.useEffect)(()=>{Wt==null||Wt(pr)},[pr]),(0,ce.useEffect)(()=>{if(_i.current){let ln=function(vn,Ln){var Jn;if(zt){Ln.preventDefault();return}const Xn=Ln.clipboardData;if(Xn){const gr=Xn.types.toString(),nr=Xn.items;if(gr==="Files"||Xn.types.indexOf("Files")>-1){if(Ln.preventDefault(),mt=="stex")return;try{let Cr=nr[1];((Jn=nr[0])==null?void 0:Jn.kind)==="file"&&(Cr=nr[0]);const Tr=Cr.getAsFile(),Gr=Tr.name.split(".").pop();(0,et.I)(Tr,Or=>{var Kr,ni,Wr;Or.id?((Kr=Tr==null?void 0:Tr.type)==null?void 0:Kr.indexOf("image"))>-1?fn.replaceSelection(`<img width="100%" src="/api/attachments/${Or.id}?type=${Or.content_type})" alt="" />`):((ni=Tr==null?void 0:Tr.type)==null?void 0:ni.indexOf("video"))>-1?fn.replaceSelection(`<video width="100%" controls src="/api/attachments/${Or.id}"></video>`):((Wr=Tr==null?void 0:Tr.type)==null?void 0:Wr.indexOf("pdf"))>-1?fn.replaceSelection(`<a href="/api/attachments/${Or.id}?type=${Tr.type}&disposition=inline" target="_blank">${Tr.name}</a>`):Bn.includes(Gr)?fn.replaceSelection(`<a href="/api/attachments/${Or.id}?type=office&disposition=inline" target="_blank">${Tr.name}</a>`):fn.replaceSelection(`[${Tr.name}](/api/attachments/${Or.id}?type=${Or.content_type})`):(Or==null?void 0:Or.status)===401&&(document.location.href="/user/login")})}catch(Cr){_t.ZP.warning("\u8BF7\u4F7F\u7528chrome\u6D4F\u89C8\u5668\u7C98\u8D34")}return!0}else return!0}return!0};const fn=ue().fromTextArea(_i.current,{mode:mt,lineNumbers:!Ie,lineWrapping:!0,value:Mn,autoCloseTags:!0,autoCloseBrackets:!0});return fn.on("keyup",function(vn,Ln){Ln.keyCode===8&&(vn.getValue()==""?fn.setOption("placeholder",gn):fn.setOption("placeholder",null))}),fn.on("keydown",function(vn,Ln){if(Ln.keyCode===8){var Jn=Dt(vn);Jn&&Ln.preventDefault()}}),Ze&&fn.focus(),fn.on("paste",ln),tn&&fn.on("beforeChange",function(vn,Ln){(Ln.origin==="paste"||Ln.origin==="+input")&&Ln.cancel()}),jn(fn),()=>{fn.off("paste",ln)}}},[]);const Wi=(0,ce.useCallback)(()=>{if(or.current)try{}catch(ln){console.log(ln,"---- to set md editor body height")}},[Ir,or,pr]);(0,ce.useEffect)(()=>{function ln(){let fn=new se.Z(vn=>{for(let Ln of vn)(Ln.target.offsetHeight>0||Ln.target.offsetWidth>0)&&(Wi(),Tt.setSize("100%","100%"),Tt.refresh())});return fn.observe(_i.current.parentElement),fn}if(Tt){const fn=ln();return()=>{var vn,Ln;(vn=_i.current)!=null&&vn.parentElement&&fn.unobserve((Ln=_i.current)==null?void 0:Ln.parentElement)}}},[Tt,Wi]),(0,ce.useEffect)(()=>{if(Tt){let ln=[];for(const[fn,vn]of Object.entries(yn)){let Ln={[fn]:()=>{$t(vn)}};ln.push(Ln),Tt.addKeyMap(Ln)}return()=>{for(let fn of ln)Tt.removeKeyMap(fn)}}},[Tt]),(0,ce.useEffect)(()=>{At!==pr&&Rr(At)},[At]),(0,wn.Z)(()=>{if(!Ft&&Vr>0){let ln=new Date().getTime(),fn=window.sessionStorage.getItem(Bt);ln>=Vr+Zn&&(!fn||fn!==bn)&&(window.sessionStorage.setItem(Bt,bn),di(!0))}},Zn),(0,ce.useEffect)(()=>{rr(qe)},[Tt,qe]),(0,ce.useEffect)(()=>{Tt&&Ze&&Tt.focus()},[Tt,Ze]),(0,ce.useEffect)(()=>{if(Un&&Tt){let ln=function(vn){let Ln=vn.target;if(Ar.current){let Jn=Ln.scrollTop/Ln.scrollHeight;Ar.current.scrollTop=Ar.current.scrollHeight*Jn}};const fn=Tt.getScrollerElement();return fn.addEventListener("scroll",ln),()=>{fn.removeEventListener("scroll",ln)}}},[Tt,Un]),(0,ce.useEffect)(()=>{if(Tt&&an){let ln=function(fn,vn){an(fn,vn)};return Tt.on("beforeChange",ln),()=>{Tt.off("beforeChange",ln)}}},[Tt,an]),(0,ce.useEffect)(()=>{if(Tt&&St){let ln=function(){St(Tt.getValue())};return Tt.on("blur",ln),()=>{Tt.off("blur",ln)}}},[Tt,St]);function Dt(ln,fn){var vn=ln.getDoc(),Ln=vn.getCursor(),Jn=vn.getLine(Ln.line),Xn=Jn.charAt(Ln.ch-1),gr=Jn.lastIndexOf("@\u2581@",Ln.ch),nr=Jn.lastIndexOf("@\u2581\u2581@",Ln.ch),Cr=gr>nr?gr:nr,Tr=gr>nr?3:4;if(hr.indexOf(Xn)===-1)return null;if(console.log("change1:",fn,ln,Jn,Ln,Cr,gr,nr,Xn),Cr>=0&&Ln.ch-Cr<5){var Gr=Cr+Tr;return vn.replaceRange("",{line:Ln.line,ch:Cr},{line:Ln.line,ch:Gr}),{line:Ln.line,ch:Gr}}return null}(0,ce.useEffect)(()=>{if(Tt){let ln=function(fn,vn){const Ln=fn.getValue();Fn(Ln),xr(new Date().getTime()),fn.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),Cn&&(En?Cn(Ln,Gt(Ln)):Cn(Ln))};return Tt.on("change",ln),()=>{Tt.off("change",ln)}}},[Tt,Cn]),(0,ce.useEffect)(()=>{if(Tt)if(Mn==null)Tt.setValue(""),Fn("");else{const ln=window.scrollY||window.pageYOffset;Mn!==Tt.getValue()&&(Tt.setValue(Mn),Fn(Mn),Tt.setCursor(tn?1:Tt.lineCount(),0),window.scrollTo(0,ln))}},[Tt,Mn]);const $t=(0,ce.useCallback)(ln=>{const fn=Tt.getCursor(),vn=Tt.getSelection();let Ln=vn.split(`
|
|
|
`);switch(ln){case"bold":return Tt.replaceSelection("**"+vn+"**"),vn===""&&Tt.setCursor(fn.line,fn.ch+2),Tt.focus();case"italic":return Tt.replaceSelection("*"+vn+"*"),vn===""&&Tt.setCursor(fn.line,fn.ch+1),Tt.focus();case"code":return Tt.replaceSelection("`"+vn+"`"),vn===""&&Tt.setCursor(fn.line,fn.ch+1),Tt.focus();case"inline-latex":return(0,Vt.Ye)(bi)?void 0:(Lr("inline-latex"),Tt.focus());case"latex":return Tt.replaceSelection("```latex\n"+vn+"\n```"),Tt.setCursor(fn.line+1,vn.length+1),Tt.focus();case"line-break":return Tt.replaceSelection(`<br/>
|
|
|
`),Tt.focus();case"list-ul":return vn===""?Tt.replaceSelection("- "+vn):Tt.replaceSelection(Ln.map(Jn=>Jn===""?"":`- ${Jn}`).join(`
|
|
|
`)),Tt.focus();case"list-ol":return vn===""?Tt.replaceSelection("1. "+vn):Tt.replaceSelection(Ln.map((Jn,Xn)=>Jn===""?"":`${Xn+1}. ${Jn}`).join(`
|
|
|
`)),Tt.focus();case"add-null-ch":return vn===""&&Tt.setCursor(fn.line,fn.ch),Tt.replaceSelection(tr),Tt.focus();case"add-signal":return vn===""&&Tt.setCursor(fn.line,fn.ch),Tt.replaceSelection(ur),Tt.focus();case"add-multiple":return vn===""&&Tt.setCursor(fn.line,fn.ch),Tt.replaceSelection(hr),Tt.focus();case"inster-template-1":return vn===""&&Tt.setCursor(fn.line,fn.ch),Tt.replaceSelection(zn),Tt.focus();case"eraser":return Tt.setValue(""),Tt.focus();case"trigger-watch":return rr(!Un),Tt.focus();case"trigger-full-screen":return Rr(!pr),Tt.focus();case vt:Lr(vt);return;case Yt:Lr(Yt);return;case Pt:Lr(Pt);return;case jt:Lr(jt);return;case"maths-latex":if((0,Vt.Ye)(bi))return;Lr("maths-latex");return;case Ht:qr.current="",sessionStorage.removeItem("file_id"),Lr(Ht);return;case Lt:Lr(Lt);return;default:throw new Error}},[Tt,Un,pr]),Zt=(0,ce.useCallback)((ln,fn)=>{var vn,Ln,Jn,Xn,gr,nr;ln!=null&&ln.disabledClose||Lr("");const{src:Cr,alt:Tr,id:Gr}=ln||{};switch(wr){case vt:const{title:ei,link:Dr}=ln;return Tt.replaceSelection(`[${ei}](${Dr})`),Tt.focus();case Yt:const{language:ar,content:fr}=ln;return Tt.replaceSelection(["```"+ar,fr,"```"].join(`
|
|
|
`)),Tt.focus();case"maths-latex":for(var Or=atob(ln),Kr=new Uint8Array(Or.length),ni=0;ni<Or.length;ni++)Kr[ni]=Or.charCodeAt(ni);var Wr=new Blob([Kr],{type:"image/png"});(0,et.I)(Wr,Hi=>{Hi.id?Tt.replaceSelection(``):(Hi==null?void 0:Hi.status)===401&&(document.location.href="/user/login")});break;case"inline-latex":if((0,Vt.Ye)(bi))return;Tt.replaceSelection("`$$"+ln+"$$`");break;case yt:if(!Gr)return;Tt.getValue().indexOf(Cr)===-1?Tt.replaceSelection(`<center><img id="${Gr}" width="80%" src="${Cr}" class="draw-flowchart" alt="${Tr||""}" /></center>`):document.getElementById(Gr).src=Ke.Z.API_SERVER+Cr+"?t="+Date.now();break;case Pt:case jt:const cr=fn,Yr=(Jn=(Ln=(vn=cr==null?void 0:cr.name)==null?void 0:vn.split("."))==null?void 0:Ln.pop)==null?void 0:Jn.call(Ln);return((Xn=cr==null?void 0:cr.type)==null?void 0:Xn.indexOf("image"))>-1||!(cr!=null&&cr.type)?cr!=null&&cr.align||cr!=null&&cr.width?Tt.replaceSelection(`<p style="text-align:${cr.align||"initial"}"><img width="${cr.width?cr.width+"%":"initial"}" src="${Cr}" alt="${Tr||""}" /></p>`):Tt.replaceSelection(`<img width="100%" src="${Cr}" alt="${Tr||""}" />`):((gr=cr==null?void 0:cr.type)==null?void 0:gr.indexOf("video"))>-1?Tt.replaceSelection(`<video width="100%" controls src="${Cr}"></video>`):((nr=cr==null?void 0:cr.type)==null?void 0:nr.indexOf("pdf"))>-1?Tt.replaceSelection(`<a href="${Cr}?type=${cr.type}&disposition=inline" target="_blank">${cr.name}</a>`):Bn.includes(Yr)?Tt.replaceSelection(`<a href="${Cr}?type=office&disposition=inline" target="_blank">${cr.name}</a>`):Tt.replaceSelection(`[${cr.name}](${Cr})`),Tt.focus();case Lt:const{row:Xr,col:Jr,align:hi}=ln;let ao=`
|
|
|
`;for(let Hi=0;Hi<Xr;Hi++){let Lo=[],po=[];for(let Ri=0;Ri<Jr;Ri++)Hi===1&&po.push(sn[hi]),Lo.push(" ");Hi===1&&(ao+=`| ${po.join(" | ")} |
|
|
|
`),ao+=`| ${Lo.join(Jr===1?"":" | ")} |
|
|
|
`}return Tt.replaceSelection(ao+`
|
|
|
`),Tt.focus();default:throw new Error}},[Tt,wr]),en=(0,ce.useMemo)(()=>{switch(wr){case vt:return ce.createElement($e,{callback:Zt,onCancel:on});case Yt:return ce.createElement(nt.Z,{callback:Zt,onCancel:on});case Pt:return ce.createElement(et.Z,{callback:Zt,onCancel:on});case Ht:return ce.createElement(Be,{editImgId:qr.current,callback:Zt,onCancel:on});case Lt:return ce.createElement(Ue,{callback:Zt,onCancel:on});case"maths-latex":return ce.createElement(Nt,{showSaveButton:!0,callback:Zt});case"inline-latex":return ce.createElement(Ct.Z,{showSaveButton:!0,callback:Zt});default:return null}},[wr]);function on(){Lr("")}(0,ce.useEffect)(()=>{if(br.current){let ln=function(gr){Jn=!0,Xn=gr.pageY},fn=function(){Jn=!1},vn=function(gr){if(Jn){let nr=gr.pageY-Xn;nr<0&&(nr=0),nr>300&&(nr=300);let Cr=Jt+nr+"px";jr(Cr)}},Ln=br.current,Jn=!1,Xn=0;return Ln.addEventListener("mousedown",ln),document.addEventListener("mousemove",vn),document.addEventListener("mouseup",fn),()=>{Ln.removeEventListener("mousedown",ln),document.removeEventListener("mousemove",vn),document.removeEventListener("mouseup",fn)}}},[Tt,br]),(0,ce.useEffect)(()=>{jr(Jt)},[Jt]);const hn=ir($n),Pn=ir(Ir),kn={width:hn,height:Pn},_n=(0,ce.useMemo)(()=>{if(Vr){let ln=new Date(Vr),fn=ln.getHours(),vn=ln.getMinutes(),Ln=ln.getSeconds();return fn=fn<10?"0"+fn:fn,vn=vn<10?"0"+vn:vn,Ln=Ln<10?"0"+Ln:Ln,`${fn}:${vn}:${Ln}`}return 0},[Vr]),Gt=ln=>{const fn=[];if(En){let vn=-1;ln=ln.replace(/(@▁▁@|@▁@)/g,function(Ln,Jn,Xn){fn.push({multiLine:Ln!==ur})})}return fn};function cn(){window.sessionStorage.removeItem(Bt),di(!1),xr(0)}function dn(){di(!1),xr(0),Tt.setValue(window.sessionStorage.getItem(Bt))}(0,ce.useEffect)(()=>{Hn[wr]&&wr!==jt&&wr!==Ht&&setTimeout(()=>{const ln=document.getElementsByClassName("markdown-popup-form")[0],fn=window.innerWidth/2-ln.offsetWidth/2,vn=window.innerHeight/2-ln.offsetHeight/2;xi(fn),Di(vn)},0)},[wr]);const un=ln=>{ln.preventDefault();const fn=ln.clientX-wi,vn=ln.clientY-ai;document.body.onmousemove=Ln=>{let Jn=Ln.clientX-fn,Xn=Ln.clientY-vn;const gr=document.getElementsByClassName("markdown-popup-form")[0],nr=window.innerWidth-gr.offsetWidth,Cr=window.innerHeight-gr.offsetHeight;Jn=Math.max(0,Math.min(Jn,nr)),Xn=Math.max(0,Math.min(Xn,Cr)),mn(Ln.clientX,Ln.clientY,fn,vn)&&(xi(Jn),Di(Xn))},document.body.onmouseup=function(){document.body.onmousemove=null}},mn=(ln,fn,vn,Ln)=>{const Jn=document.body.clientHeight,Xn=document.body.clientWidth;return ln<20&&vn>ln||ln>Xn-20&&vn<ln||fn<20&&Ln>fn||fn>Jn-20&&Ln<fn?(document.body.onmousemove=null,document.body.onmouseup=null,!1):!0};return ce.createElement(ce.Fragment,null,ce.createElement("div",{className:"markdown-editor-wrapper",ref:or},ce.createElement("div",{className:`markdown-editor-container ${Et} ${Un?"on-preview":""} ${Ie?"mini":""} ${pr?"full-screen":""}`,style:kn},ce.createElement(Te,{insertTemp:st,watch:Un,fullScreen:pr,showNullButton:qt,showNullProgramButton:En,onActionCallback:$t,hidetoolBar:Yn,extraUse:Tn}),ce.createElement("div",{className:"markdown-editor-body"},ce.createElement("div",{className:"codemirror-container"},ce.createElement("textarea",{ref:_i,placeholder:gn})),Un?ce.createElement("div",{ref:Ar,className:"preview-container"},mt==="stex"&&ce.createElement(x,{value:bn}),mt!=="stex"&&ce.createElement(z.Z,{edit:!0,disabledFill:nn,showProgramFill:En,value:bn,openEditor:ln=>{var fn;qr.current=ln,(fn=$r.current)==null||fn.setHeight("100vh"),setTimeout(()=>{Lr("add-flowchart")},150)}})):null))),kt?ce.createElement("a",{ref:br,className:"editor-resize"}):null,wr===jt&&ce.createElement(Rt,{callback:Zt,onCancel:on}),wr===Ht&&ce.createElement(Be,{ref:$r,editImgId:qr.current,callback:Zt,onCancel:on}),ce.createElement(Ee.Z,null,Hn[wr]&&wr!==jt&&wr!==Ht?ce.createElement(pt.default,{maskClosable:!1,centered:!0,style:{position:"absolute",left:wi,top:ai},title:ce.createElement("div",{style:{cursor:"move"},onMouseDown:un},Hn[wr]),open:!0,onCancel:on,footer:null,destroyOnClose:!0,width:wr===Ht?"1200px":null,height:wr===Ht?"80vh":null,className:"markdown-popup-form"},en):null))}},45596:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return pe},I:function(){return Te}});var ce=be(28284),ie=be(6767),Ce=be(37568),ue=be(77736),se=be(71051),te=be(47889),le=be(99571),ee=be(67303),ne=be(59301),E=be(59301),b=Object.defineProperty,z=Object.defineProperties,x=Object.getOwnPropertyDescriptors,re=Object.getOwnPropertySymbols,ae=Object.prototype.hasOwnProperty,oe=Object.prototype.propertyIsEnumerable,ve=(Ee,Oe,je)=>Oe in Ee?b(Ee,Oe,{enumerable:!0,configurable:!0,writable:!0,value:je}):Ee[Oe]=je,ye=(Ee,Oe)=>{for(var je in Oe||(Oe={}))ae.call(Oe,je)&&ve(Ee,je,Oe[je]);if(re)for(var je of re(Oe))oe.call(Oe,je)&&ve(Ee,je,Oe[je]);return Ee},me=(Ee,Oe)=>z(Ee,x(Oe));const{useForm:ge}=ce.default,_e={width:280,marginRight:10},he={labelCol:{span:5},wrapperCol:{span:19}};var pe=({callback:Ee,onCancel:Oe})=>{const[je]=ge();let Pe=(0,ne.useRef)();function Qe(He){Pe.current.width=je.getFieldValue("width"),Pe.current.align=je.getFieldValue("align"),Ee(He,Pe.current)}function Xe(He,rt){if(He.status===-1){ie.ZP.error(He.message);return}je.setFieldsValue({src:`/api/attachments/${He.id}`,type:rt.type})}function ot(He){let rt=He.target.files[0];Pe.current=rt,Te(rt,Xe)}return E.createElement(ce.default,me(ye({form:je},he),{className:"upload-image-panel",onFinish:Qe,style:{width:470,overflow:"hidden"}}),E.createElement(ce.default.Item,{label:"\u56FE\u7247\u5730\u5740",required:!0},E.createElement("div",{className:"flex-container"},E.createElement(ce.default.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u56FE\u7247\u5730\u5740"}]},E.createElement(Ce.default,{style:_e})),E.createElement(ke,{onFileChange:ot}))),E.createElement(ce.default.Item,{label:"\u56FE\u7247\u63CF\u8FF0",name:"alt"},E.createElement(Ce.default,{style:{width:264}})),E.createElement(ce.default.Item,{label:"\u56FE\u7247\u5BBD\u5EA6",name:"width"},E.createElement(ue.Z,null,E.createElement(ce.default.Item,{name:"width",style:{margin:0}},E.createElement(se.Z,{style:{width:264}})),E.createElement("span",{className:"ml8"},"%"))),E.createElement(ce.default.Item,{label:"\u5BF9\u9F50\u65B9\u5F0F",name:"align"},E.createElement(te.ZP.Group,{name:"align",defaultValue:1,options:[{value:"left",label:"\u5DE6\u5BF9\u9F50"},{value:"center",label:"\u5C45\u4E2D\u5BF9\u9F50"},{value:"right",label:"\u53F3\u5BF9\u9F50"}]})),E.createElement("aside",null,E.createElement(ce.default.Item,{style:{textAlign:"right",position:"relative",right:-98}},E.createElement(le.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),E.createElement(le.ZP,{type:"default",onClick:Oe},"\u53D6\u6D88"))))};function ke({onFileChange:Ee}){return E.createElement("label",{className:"upload-button",style:{cursor:"pointer"}},"\u672C\u5730\u4E0A\u4F20",E.createElement("input",{type:"file",onChange:Ee}))}function Te(Ee,Oe){if(!Ee)throw new String("\u6CA1\u6709\u6587\u4EF6");let je=new FormData;je.append("editormd-image-file",Ee),je.append("file_param_name","editormd-image-file"),je.append("byxhr","true");var Pe=new window.XMLHttpRequest;Pe.withCredentials=!0,Pe.addEventListener("load",function(Qe){Oe(JSON.parse(Qe.target.responseText),Ee)},!1),Pe.addEventListener("error",function(Qe){console.error(Qe)},!1),Pe.open("POST",`${ee.KI}/api/attachments.json`),Pe.send(je)}},75790:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return Ce}});var ce=be(59301),ie=be(4676);class Ce extends ce.Component{constructor(se){super(se);const te=window.document;this.node=te.createElement("div"),te.body.appendChild(this.node)}render(){const{children:se}=this.props;return(0,ie.createPortal)(se,this.node)}componentWillUnmount(){window.document.body.removeChild(this.node)}}},51124:function(Xt,Mt,be){"use strict";be.d(Mt,{SV:function(){return Rt},ZP:function(){return dt}});var ce=be(59301),ie=be(76374);const Ce={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"]},ue={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"]},se={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","friend","gcnew","generic","goto","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:"system",content:'system("$0")'},{label:"main",content:["int main () {"," $0","}"].join(`
|
|
|
`)},{label:"if",content:["if () {"," $0","}"].join(`
|
|
|
`)},{label:"for",content:["for(int j=0 ; j<10; j++){"," $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 <cstdio>",content:["#include <cstdio>"].join(`
|
|
|
`)},{label:"include <cstring>",content:["#include <cstring>"].join(`
|
|
|
`)},{label:"include <sstream>",content:["#include <sstream>"].join(`
|
|
|
`)},{label:"include <fstream>",content:["#include <fstream>"].join(`
|
|
|
`)},{label:"include <map>",content:["#include <map>"].join(`
|
|
|
`)},{label:"include <string>",content:["#include <string>"].join(`
|
|
|
`)},{label:"include <cmath>",content:["#include <cmath>"].join(`
|
|
|
`)}]},te={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(`
|
|
|
`)}]},le={keywords:["asInstanceOf","catch","class","classOf","def","do","else","extends","finally","for","foreach","forSome","if","import","isInstanceOf","macro","match","new","object","package","return","throw","trait","try","type","until","val","var","while","with","yield","given","enum","then"],quickKey:[{label:"println",content:["println($0)"].join(`
|
|
|
`)}]};var ee=be(53184),ne=be.n(ee),E=(xt,gt,_t)=>new Promise((We,Ae)=>{var Se=Ne=>{try{Ke(_t.next(Ne))}catch(De){Ae(De)}},Be=Ne=>{try{Ke(_t.throw(Ne))}catch(De){Ae(De)}},Ke=Ne=>Ne.done?We(Ne.value):Promise.resolve(Ne.value).then(Se,Be);Ke((_t=_t.apply(xt,gt)).next())});const b={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"]}},z=(xt,gt,_t,We)=>{const Ae=gt.getValueInRange({startLineNumber:1,startColumn:1,endLineNumber:_t.lineNumber,endColumn:_t.column});return Array.from(new Set(Ae.match(/\b\w{2,}\b/g)||[])).map(Be=>({label:Be,kind:xt.languages.CompletionItemKind.Text,insertText:Be,range:We}))},x=(xt,gt,_t,We)=>{xt.languages.registerCompletionItemProvider(gt,{provideCompletionItems(Ae,Se){const Be=Ae.getWordUntilPosition(Se),Ke={startLineNumber:Se.lineNumber,endLineNumber:Se.lineNumber,startColumn:Be.startColumn,endColumn:Be.endColumn},Ne=Ae.getLineContent(Se.lineNumber).substring(Be.startColumn-2,Be.endColumn);return{suggestions:[...z(xt,Ae,Se,Ke),..._t.map(we=>({label:we,kind:xt.languages.CompletionItemKind.Keyword,documentation:we,insertText:we,insertTextRules:xt.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:Ke})),...We.map(we=>({label:we.label,kind:xt.languages.CompletionItemKind.Snippet,documentation:we.content,insertText:Ne.startsWith("#")?we.content.replace(/#/,""):we.content,insertTextRules:xt.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:Ke}))]}}})};var re=xt=>{b.languages.forEach(gt=>{xt.languages.registerDocumentFormattingEditProvider(gt,{provideDocumentFormattingEdits(_t){return E(this,null,function*(){const We=ne()(_t.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});return[{range:_t.getFullModelRange(),text:We}]})}})}),x(xt,"java",ue.keywords,ue.quickKey),x(xt,"cpp",se.keywords,se.quickKey),x(xt,"c",Ce.keywords,[]),x(xt,"python",te.keywords,te.quickKey),x(xt,"scala",le.keywords,le.quickKey)};const ae="\u8BE5\u4EFB\u52A1\u5173\u5361\u8BBE\u7F6E\u4E86\u7981\u6B62\u590D\u5236\u7C98\u8D34\uFF0C\u8BF7\u624B\u52A8\u8F93\u5165\u4EE3\u7801\u3002";var oe=Object.defineProperty,ve=(xt,gt,_t)=>gt in xt?oe(xt,gt,{enumerable:!0,configurable:!0,writable:!0,value:_t}):xt[gt]=_t,ye=(xt,gt,_t)=>ve(xt,typeof gt!="symbol"?gt+"":gt,_t);const me=class hu{constructor(gt,_t,We){this.placeholder=gt,this.editor=_t,this.monaco=We,_t.onDidChangeModelContent(()=>this.onDidChangeModelContent()),this.onDidChangeModelContent()}onDidChangeModelContent(){this.editor.getValue()===""?this.editor.addContentWidget(this):this.editor.removeContentWidget(this)}getId(){return hu.ID}getDomNode(){return this.domNode||(this.domNode=document.createElement("div"),this.domNode.style.width="max-content",this.domNode.textContent=this.placeholder,this.domNode.style.fontStyle="initial",this.domNode.style.color="#D7D7D7",this.domNode.style.pointerEvents="none",this.editor.applyFontInfo(this.domNode)),this.domNode}getPosition(){return{position:{lineNumber:1,column:1},preference:[this.monaco.editor.ContentWidgetPositionPreference.EXACT]}}dispose(){this.editor.removeContentWidget(this)}};ye(me,"ID","editor.widget.placeholderHint");var _e=me,he=be(96236),pe=be(6767),ke=be(25399),Te=be(89392),Ee=be(33796),Oe=be(56102),je=Object.defineProperty,Pe=Object.defineProperties,Qe=Object.getOwnPropertyDescriptors,Xe=Object.getOwnPropertySymbols,ot=Object.prototype.hasOwnProperty,He=Object.prototype.propertyIsEnumerable,rt=(xt,gt,_t)=>gt in xt?je(xt,gt,{enumerable:!0,configurable:!0,writable:!0,value:_t}):xt[gt]=_t,Ye=(xt,gt)=>{for(var _t in gt||(gt={}))ot.call(gt,_t)&&rt(xt,_t,gt[_t]);if(Xe)for(var _t of Xe(gt))He.call(gt,_t)&&rt(xt,_t,gt[_t]);return xt},ut=(xt,gt)=>Pe(xt,Qe(gt)),Ge=(xt,gt)=>{var _t={};for(var We in xt)ot.call(xt,We)&>.indexOf(We)<0&&(_t[We]=xt[We]);if(xt!=null&&Xe)for(var We of Xe(xt))gt.indexOf(We)<0&&He.call(xt,We)&&(_t[We]=xt[We]);return _t},ze=(xt,gt,_t)=>new Promise((We,Ae)=>{var Se=Ne=>{try{Ke(_t.next(Ne))}catch(De){Ae(De)}},Be=Ne=>{try{Ke(_t.throw(Ne))}catch(De){Ae(De)}},Ke=Ne=>Ne.done?We(Ne.value):Promise.resolve(Ne.value).then(Se,Be);Ke((_t=_t.apply(xt,gt)).next())});function Ve(xt){return/^\d+$/.test(xt)?`${xt}px`:xt}function $e(){}let nt=!1;const et={"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",Scala:"scale",solidity:"sol"};function pt(xt=[]){let gt=xt;if(Array.isArray(xt)){for(let _t=0;_t<xt.length;_t++){let We=et[xt[_t]];if(We)return We}return gt[0]}return et[gt]||gt}let ct=null;const Ot=()=>ze(void 0,null,function*(){try{yield navigator.clipboard.writeText(" "),console.log("\u5185\u5BB9\u5DF2\u81EA\u52A8\u590D\u5236\u5230\u526A\u8D34\u677F:")}catch(xt){console.error("\u81EA\u52A8\u590D\u5236\u5931\u8D25:",xt)}});var dt=xt=>{var gt=xt,{width:_t="100%",height:We="100%",value:Ae,language:Se="javascript",style:Be={},options:Ke={},overrideServices:Ne={},theme:De="vs-dark",onEditBlur:we,isCopy:Le=!1,onSave:Ue,autoHeight:Me=!1,forbidCopy:Re=!1,onChange:tt=$e,editorDidMount:lt=$e,onFocus:Nt=$e,onBreakPoint:Ct=$e,breakPointValue:vt=[],filename:Pt="educoder.txt",errorLine:Ht,errorContent:jt="",highlightLine:yt,openBreakPoint:Yt=!1,placeholder:Lt="",showMiniMap:Kt=!0}=gt,sn=Ge(gt,["width","height","value","language","style","options","overrideServices","theme","onEditBlur","isCopy","onSave","autoHeight","forbidCopy","onChange","editorDidMount","onFocus","onBreakPoint","breakPointValue","filename","errorLine","errorContent","highlightLine","openBreakPoint","placeholder","showMiniMap"]);const wn=(0,ce.useRef)(),Vt=(0,ce.useRef)({}),Rn=(0,ce.useRef)(),Gn=(0,ce.useRef)(),Zn=(0,ce.useRef)([]),tr=(0,ce.useRef)(!1),hr=(0,ce.useRef)(),ur=(0,ce.useRef)(),zn=(0,ce.useRef)(!1),[Bn,ir]=(0,ce.useState)(!1);function Kn(){let kt;return wn.current&&(kt=new ie.Z(Ft=>{for(let qt of Ft)(qt.target.offsetHeight>0||qt.target.offsetWidth>0)&&Vt.current.instance.layout()}),kt.observe(wn.current)),kt}function Nn(){pe.ZP.warning({content:decodeURIComponent(ae),key:"monaco-editor-tip"})}const yn=()=>{let kt=Vt.current.instance;if(Ae!=null&&kt&&Bn){const Ft=kt.getModel();Ft&&Ae!==Ft.getValue()&&(nt=!0,Ft.setValue(Ae),kt.layout(),nt=!1)}};(0,ce.useEffect)(()=>{const kt=Ee.Z.subscribe("formatDocument",Ft=>{var qt;let En=Vt.current.instance;(qt=En==null?void 0:En.getAction)==null||qt.call(En,"editor.action.formatDocument").run()});return window.updateMonacoValue=Ft=>{tt(Ft)},kt},[]),(0,ce.useEffect)(()=>{var kt;let Ft=Vt.current.instance;Gn.current&&clearTimeout(Gn.current),Gn.current=setTimeout(()=>{yn()},500),Ae&&(Ae!=null&&Ae.length)&&((kt=Ft==null?void 0:Ft.updateOptions)==null||kt.call(Ft,{lineNumbersMinChars:Math.max(Math.floor(Math.log10(Ae.split(/\r\n|\r|\n/g).length))+3,5)}))},[Ae,Bn,Vt.current]),(0,ce.useEffect)(()=>{if(Ht&&Vt.current&&Vt.current.instance){let Ft=Vt.current.instance;Ft.changeViewZones(function(qt){var En=document.createElement("div");En.style.padding="10px 20px",En.style.width="calc(100% - 20px)",En.className="my-error-line-wrp",En.innerHTML=jt,qt.addZone({afterLineNumber:Ht||11,heightInLines:3,domNode:En})});var kt={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}};Ft.addOverlayWidget(kt),Ft.revealPositionInCenter({lineNumber:20,column:1})}},[Ht,Vt.current,Bn]);const Hn=(kt="",Ft)=>{if(!kt||kt.trim()==="")return!0;const En=Vt.current.instance.getModel().getLineTokens(Ft);let Yn=!1;for(let At=0;At<2;At++)En.getStandardTokenType(At)===1&&(Yn=!0);return Yn};(0,ce.useEffect)(()=>{var kt;const Ft=(kt=Vt.current)==null?void 0:kt.instance;if(Ft&&Bn&&Re){const qt=Ft.onDidBlurEditorWidget(()=>{zn.current=!1}),En=Ft.onDidFocusEditorText(()=>{zn.current=!0});return()=>{qt.dispose(),En.dispose()}}},[Vt.current,Bn,Re]),(0,ce.useEffect)(()=>{var kt;if((kt=Vt.current)!=null&&kt.instance&&Bn&&Yt){let Ft=Vt.current.instance,qt=Ft.getModel();if(!qt)return;(()=>{var Sn;let Tn=[],Tt=[];const jn=qt.getAllDecorations();for(let Fn of jn)Fn.options.className==="highlighted-line"&&(Tn.push((Sn=Fn==null?void 0:Fn.range)==null?void 0:Sn.startLineNumber),Tt.push(Fn==null?void 0:Fn.id));if(yt===Tn[0])return;qt.deltaDecorations(Tt,[]);const bn=qt.getLineCount();yt&&yt<=bn&&(Ft.deltaDecorations([],[{range:new ct.Range(yt,1,yt,qt.getLineMaxColumn(yt)),options:{isWholeLine:!0,className:"highlighted-line"}}]),Ft.revealLineInCenter(yt))})();const Yn=(Sn=!1)=>{var Tn;let Tt=[],jn=[];const bn=qt.getAllDecorations();for(let Fn of bn)Fn.options.linesDecorationsClassName==="breakpoints-select"&&(Tt.push((Tn=Fn==null?void 0:Fn.range)==null?void 0:Tn.startLineNumber),jn.push(Fn==null?void 0:Fn.id));if(Sn)return{lines:Tt,ids:jn};Ct(Tt)},At=Sn=>ze(void 0,null,function*(){let Tn={range:new ct.Range(Sn,1,Sn,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}};yield qt.deltaDecorations([],[Tn]),Yn()}),St=Sn=>ze(void 0,null,function*(){let Tn=[];const Tt=Ft.getLineDecorations(Sn);for(let jn of Tt)jn.options.linesDecorationsClassName==="breakpoints-select"&&Tn.push(jn.id);yield qt.deltaDecorations(Tn,[]),Yn()}),an=Sn=>{let Tn=Ft.getLineDecorations(Sn);for(let Tt of Tn)if(Tt.options.linesDecorationsClassName==="breakpoints-select")return!0;return!1};if(!(0,Te.isEqual)(vt,Yn(!0).lines)){qt.deltaDecorations(Yn(!0).ids,[]);const Sn=vt.map(Tn=>({range:new ct.Range(Tn,1,Tn,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}}));qt.deltaDecorations([],Sn)}const Wt=Ft.onDidChangeModelContent(Sn=>{let Tn=Ft.getPosition();if(Tn){let Tt=Tn.lineNumber;clearTimeout(ur.current),ur.current=setTimeout(()=>{Hn(qt.getLineContent(Tt),Tt)?St(Tt):an(Tt)?(St(Tt),At(Tt)):Yn()},100)}}),Et=Ft.onMouseDown(Sn=>{var Tn,Tt,jn;if(Sn.target.detail&&((jn=(Tt=(Tn=Sn.target)==null?void 0:Tn.element)==null?void 0:Tt.className)!=null&&jn.includes("line-numbers"))){let bn=Sn.target.position.lineNumber;if(Hn(qt.getLineContent(bn),bn))return;an(bn)?St(bn):At(bn)}}),zt=Sn=>{let Tn={range:new ct.Range(Sn,1,Sn,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-fake"}};Zn.current=Ft.deltaDecorations(Zn.current,[Tn])},tn=()=>{Zn.current=Ft.deltaDecorations(Zn.current,[])},nn=Ft.onMouseMove(Sn=>{var Tn,Tt,jn;if(tn(),Sn.target.detail&&((jn=(Tt=(Tn=Sn.target)==null?void 0:Tn.element)==null?void 0:Tt.className)!=null&&jn.includes("line-numbers"))){let bn=Sn.target.position.lineNumber;if(Hn(qt.getLineContent(bn),bn))return;zt(bn)}}),gn=Ft.onMouseLeave(()=>{tn()});return()=>{Wt.dispose(),Et.dispose(),nn.dispose(),gn.dispose()}}},[Vt.current,Bn,vt,yt,Yt,Se]),(0,ce.useEffect)(()=>{var kt;(kt=Vt.current)!=null&&kt.instance&&Yt&&Vt.current.instance.setPosition({lineNumber:0,column:0})},[yt]);function dr(){let kt=Vt.current.instance;if(kt){const Ft=kt.getSelection(),qt=Vt.current.pastePos||{},En=new ct.Range(qt.startLineNumber||Ft.endLineNumber,qt.startColumn||Ft.endColumn,qt.endLineNumber||Ft.endLineNumber,qt.endColumn||Ft.endColumn);setTimeout(()=>{kt.executeEdits("",[{range:En,text:""}])},300)}}function Mn(kt){(window.navigator.platform.match("Mac")?kt.metaKey:kt.ctrlKey)&&kt.keyCode==83&&(kt.preventDefault(),Ue())}const Cn=()=>{if(Me&&Vt.current.instance){const kt=Vt.current.instance.getContentHeight();mt(kt<We?We:kt)}else mt(We)};function $n(kt){var Ft=document.createEvent("MouseEvents");Ft.initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),kt.dispatchEvent(Ft)}const Jt=kt=>{if(!zn.current)return;const{keyCode:Ft,ctrlKey:qt,metaKey:En,target:Yn,type:At}=kt;return(At==="paste"||(Ft===67||Ft===86)&&(En||qt))&&Yn.nodeName==="TEXTAREA"&&(Nn(),kt.preventDefault()),!1};function Ie(kt,Ft){var qt=window.URL||window.webkitURL||window,En=new Blob([Ft]),Yn=document.createElementNS("http://www.w3.org/1999/xhtml","a");Yn.href=qt.createObjectURL(En),Yn.download=kt,$n(Yn)}(0,ce.useEffect)(()=>{Cn()},[Cn]),(0,ce.useEffect)(()=>{wn.current&&!Bn&&Promise.all([be.e(8909),be.e(5028)]).then(be.bind(be,71448)).then(kt=>{try{ct=kt,Vt.current.instance=ct.editor.create(wn.current,{value:Ae,language:pt(Se),theme:De,requireConfig:{"vs/nls":{availableLanguages:{"*":"zh-cn"}}},wordWrap:!0,autoIndent:!0,contextmenu:!0,formatOnType:!0,minimap:{enabled:Kt||!1}},Ne);const Ft=Vt.current.instance;let Yn=[...he.BH._menuItems].find(Wt=>Wt[0]._debugName=="EditorContext")[1],At=["editor.action.clipboardCopyWithSyntaxHighlightingAction","editor.action.quickCommand","editor.action.clipboardCopyAction","editor.action.clipboardPasteAction","editor.action.clipboardCutAction"],St=(Wt,Et)=>{var zt,tn;let nn=Wt._first;do Et.includes((tn=(zt=nn.element)==null?void 0:zt.command)==null?void 0:tn.id)&&Wt._remove(nn);while(nn=nn.next)};if(lt(Ft,ct),setTimeout(()=>{Cn(),Vt.current.instance.addAction({id:"d123123",label:"Download File",contextMenuGroupId:"9_cutcopypaste",run:()=>{Ie(Pt||"educoder.txt",Ft.getValue())}})},500),Vt.current.subscription=Ft.onDidChangeModelContent(Wt=>{tr.current?clearTimeout(hr.current):(Cn(),tt(Ft.getValue(),Wt)),hr.current=setTimeout(()=>{tr.current=!1},500)}),window.Monaco||re(ct,pt(Se)),Re&&(St(Yn,At),wn.current.classList.add("noCopyPaste"),window.removeEventListener("keydown",Jt),window.removeEventListener("paste",Jt),window.addEventListener("keydown",Jt),window.addEventListener("paste",Jt)),window.Monaco=ct,we&&Ft.onDidBlurEditorWidget(()=>{we(Ft.getValue())}),Nt&&Ft.onDidFocusEditorText(()=>{Re&&Ot(),Nt(Ft.getValue())}),Re){Ot();try{Ft.onDidPaste(Wt=>{const Et=Ft.getSelection(),zt=Vt.current.pastePos||{},tn=new ct.Range(zt.startLineNumber||Et.endLineNumber,zt.startColumn||Et.endColumn,zt.endLineNumber||Et.endLineNumber,zt.endColumn||Et.endColumn);Ft.executeEdits("",[{range:Wt.range,text:""}])})}catch(Wt){}}let an=Kn();return Lt&&typeof Lt=="string"&&new _e(Lt,Ft,ct),ir(!0),()=>{const Wt=Vt.current.instance;Wt.dispose();const Et=Wt.getModel();Et&&Et.dispose(),Vt.current.subscription&&Vt.current.subscription.dispose(),an.unobserve(wn.current)}}catch(Ft){}})},[]),(0,ce.useEffect)(()=>{if(Vt.current.instance&&Bn)return document.addEventListener("keydown",Mn,!1),()=>{document.removeEventListener("keydown",Mn)}},[Ue,Bn]),(0,ce.useEffect)(()=>{let kt=Vt.current.instance;if(kt&&Bn){let Ft=pt(Se);ct.editor.setModelLanguage(kt.getModel(),Ft)}},[Se,Bn]),(0,ce.useEffect)(()=>{Vt.current.instance&&Bn&&ct.editor.setTheme(De)},[De,Bn]),(0,ce.useEffect)(()=>{let kt=Vt.current.instance;Rn.current=Ke,kt&&Bn&&(kt.updateOptions(Ye({},Ke)),setTimeout(()=>{kt.getModel().updateOptions(Ye({},Ke))},200))},[JSON.stringify(Ke),Bn]),(0,ce.useEffect)(()=>{let kt=Vt.current.instance;kt&&Bn&&kt.layout()},[_t,We,Bn]);const[Ze,qe]=(0,ce.useState)(Ve(_t)),[st,mt]=(0,ce.useState)(Ve(We)),Bt=ut(Ye({},Be),{width:Ze,height:st,position:"relative"});return ce.createElement("div",{className:"my-monaco-editor",ref:wn,style:Bt},Le&&ce.createElement(Oe.CopyToClipboard,{text:Ae,onCopy:()=>pe.ZP.success("\u590D\u5236\u6210\u529F")},ce.createElement(ke.Z,{title:"\u590D\u5236\u4EE3\u7801"},ce.createElement("div",{style:{position:"absolute",top:0,right:10,cursor:"pointer",zIndex:10,color:"#165DFF"}},ce.createElement("i",{className:"iconfont icon-fuzhi8",style:{fontSize:14}})," \u590D\u5236\u4EE3\u7801"))))};function Rt({width:xt="100%",height:gt="100%",original:_t,modified:We,language:Ae,options:Se={}}){const Be=(0,ce.useRef)(),[Ke,Ne]=(0,ce.useState)(null);function De(Me){let Re;return Be.current&&(Re=new ie.Z(tt=>{for(let lt of tt)(lt.target.offsetHeight>0||lt.target.offsetWidth>0)&&Me.layout()}),Re.observe(Be.current)),Re}(0,ce.useEffect)(()=>(Be.current&&Promise.all([be.e(8909),be.e(9404)]).then(be.bind(be,2550)).then(Me=>{ct=Me;const Re=ct.editor.createDiffEditor(Be.current,ut(Ye({enableSplitViewResizing:!1,scrollBeyondLastLine:!1,roundedSelection:!1,renderIndicators:!1,useShadows:!1,horizontal:"hidden",lineNumbers:"off",wordWrap:"off",ignoreTrimWhitespace:!1,"semanticHighlighting.enabled":!0,followsCaret:!0,ignoreCharChanges:!0,minimap:{enabled:!1},readOnly:!0},Se),{wordWrap:!0}));Ne(Re);let tt=De(Re);return()=>{Re.dispose();const lt=Re.getModel();lt&<.dispose(),tt.unobserve(Be.current)}}),()=>{window.removeEventListener("keydown",checkPaste),window.removeEventListener("paste",checkPaste)}),[]),(0,ce.useEffect)(()=>{Ke&&Ke.setModel({original:ct.editor.createModel(_t,Ae),modified:ct.editor.createModel(We,Ae)})},[_t,We,Ae,Ke]);const we=Ve(xt),Le=Ve(gt),Ue={width:we,height:Le};return ce.createElement("div",{className:"my-diff-editor",ref:Be,style:Ue})}},64536:function(Xt,Mt,be){"use strict";var ce=be(45298),ie=be(82326),Ce=be(71411),ue=be(59301);const se=ie.default.Option;Mt.Z=({isTheoretical:te,onFontSizeChange:le,cmFontSize:ee,cmCodeMode:ne,autoFormat:E,onCodeModeChange:b,onTabToSpace:z,onAutoFormat:x,formatDocument:re,className:ae="",tabToSpace:oe,children:ve,code_editor:ye,challenge:me,shixun_environment_id:ge,shixun_environments:_e})=>{var he;const pe={1:"\u7B80\u5355",2:"\u4E2D\u7B49",3:"\u56F0\u96BE"},ke=(he=_e==null?void 0:_e.find(Te=>Te.shixun_environment_id===ge))==null?void 0:he.program_language;return console.log("----",ke,_e,ge,ye),ue.createElement("div",{className:`tpi-code-setting ${ae}`},ue.createElement("h3",null,"\u4EE3\u7801\u683C\u5F0F"),ue.createElement("section",null,ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u663E\u793A\u6A21\u5F0F"),ue.createElement(ie.default,{bordered:!1,size:"small",value:ne,onChange:b},ue.createElement(se,{value:"vs"},"\u767D\u8272\u80CC\u666F"),ue.createElement(se,{value:"vs-dark"},"\u9ED1\u8272\u80CC\u666F"))),!te&&ue.createElement(ue.Fragment,null,ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u5B57\u4F53\u5927\u5C0F"),ue.createElement(ie.default,{bordered:!1,size:"small",value:ee,onChange:le},ue.createElement(se,{value:12},"12px"),ue.createElement(se,{value:14},"14px"),ue.createElement(se,{value:16},"16px"),ue.createElement(se,{value:18},"18px"),ue.createElement(se,{value:20},"20px"),ue.createElement(se,{value:22},"22px"))),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"Tab\u8F6C\u6362"),ue.createElement(Ce.Z,{checked:oe,onChange:z})),ue.createElement("div",{className:"file-item",onClick:re},ue.createElement("b",{style:{cursor:"pointer"}},"\u683C\u5F0F\u5316\u4EE3\u7801")))),!te&&ue.createElement(ue.Fragment,null,ue.createElement("h3",null,"\u5FEB\u6377\u952E"),ue.createElement("section",null,ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u4FDD\u5B58\u4EE3\u7801"),ue.createElement("span",null,"Ctrl + S")),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u5524\u51FA\u5FEB\u6377\u952E\u5217\u8868"),ue.createElement("span",null,"F1 / Alt + F1")),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u5DE6\u53F3\u7F29\u8FDB"),ue.createElement("span",null,"Ctrl + ]/[")),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u8DF3\u5230\u5339\u914D\u7684\u62EC\u53F7"),ue.createElement("span",null,"Ctrl + Shift + \\")),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u8F6C\u5230\u884C\u9996"),ue.createElement("span",null,"Home")),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u8F6C\u5230\u884C\u5C3E"),ue.createElement("span",null,"End"))),ve),!te&&ue.createElement(ue.Fragment,null,ue.createElement("h3",null,"\u5FEB\u6377\u952E"),ue.createElement("section",null,ke&&ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u7F16\u7A0B\u8BED\u8A00"),ue.createElement("span",null,ke)),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u5B9E\u8BAD\u96BE\u6613\u5EA6"),ue.createElement("span",null,pe[me==null?void 0:me.difficulty])),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u5B9E\u9A8C\u73AF\u5883"),ue.createElement("span",null,ye==null?void 0:ye.name)),ue.createElement("div",{className:"file-item"},ue.createElement("b",null,"\u5B9E\u9A8C\u5BB9\u5668\u7F51\u7EDC"),ue.createElement("span",null,ye!=null&&ye.close_internet?"\u5173\u95ED\u5916\u7F51":"\u5F00\u542F\u5916\u7F51")))))}},17904:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ie}});var ce=be(59301);function ie(Ce,ue){const se=(0,ce.useRef)();(0,ce.useEffect)(()=>{se.current=Ce}),(0,ce.useEffect)(()=>{function te(){se.current()}if(ue!==null){let le=setInterval(te,ue);return()=>clearInterval(le)}},[ue])}},40148:function(Xt,Mt,be){"use strict";be.d(Mt,{Im:function(){return Oe},ZP:function(){return He},gZ:function(){return Xe}});var ce=be(59301),ie=be(37568),Ce=be(99571),ue=be(84105),se=be(87395),te=be(49162),le=be(24334),ee=be(766),ne=be(38394),E=be(49661),b=be(46685),z=be(34376),x=be(92310),re=be.n(x),ae=be(59301),oe=Object.defineProperty,ve=Object.defineProperties,ye=Object.getOwnPropertyDescriptors,me=Object.getOwnPropertySymbols,ge=Object.prototype.hasOwnProperty,_e=Object.prototype.propertyIsEnumerable,he=(rt,Ye,ut)=>Ye in rt?oe(rt,Ye,{enumerable:!0,configurable:!0,writable:!0,value:ut}):rt[Ye]=ut,pe=(rt,Ye)=>{for(var ut in Ye||(Ye={}))ge.call(Ye,ut)&&he(rt,ut,Ye[ut]);if(me)for(var ut of me(Ye))_e.call(Ye,ut)&&he(rt,ut,Ye[ut]);return rt},ke=(rt,Ye)=>ve(rt,ye(Ye));const{TextArea:Te}=ie.default,Ee={visible:!1,tabIndex:"0"},Oe={[te.h.HIDE_COMPILE_STATUS]:"\u6682\u4E0D\u652F\u6301\u67E5\u770B",[te.h.NOMATCH]:"\u6D4B\u8BD5\u7528\u4F8B\u7ED3\u679C\u4E0D\u5339\u914D",[te.h.OK]:"\u8C03\u8BD5\u901A\u8FC7",2:"\u8C03\u8BD5\u8D85\u65F6",3:"\u8C03\u8BD5pod\u5931\u8D25",4:"\u7F16\u8BD1\u5931\u8D25",5:"\u6267\u884C\u5931\u8D25"};var je=(rt=>(rt[rt.SET_VISIBLE=0]="SET_VISIBLE",rt[rt.SET_TABINDEX=1]="SET_TABINDEX",rt))(je||{});function Pe(rt,Ye){switch(Ye.type){case 0:return ke(pe({},rt),{visible:Ye.payload});case 1:return ke(pe({},rt),{tabIndex:Ye.payload});default:throw new Error}}function Qe({value:rt,className:Ye}){const[ut,Ge]=(0,ce.useState)(!1),ze=(0,ce.useRef)(),Ve=(0,ce.useRef)();return(0,ce.useEffect)(()=>{ut&&(Ve.current.reset(),Ve.current.write((0,E.pp)(rt||"")))},[rt,ut]),(0,ce.useEffect)(()=>{var $e,nt,et,pt;if(ze.current){Ve.current=new z.Terminal({fontSize:14,disableStdin:!0}),Ve.current.open(ze.current);const ct=ze.current.offsetWidth-14,Ot=((pt=(et=(nt=($e=Ve.current)==null?void 0:$e._core)==null?void 0:nt._renderService)==null?void 0:et.dimensions)==null?void 0:pt.actualCellWidth)||9.5,dt=Math.ceil(ct/Ot);Ve.current.resize(dt,8),Ge(!0)}},[]),ae.createElement("div",{ref:ze,className:re()("XtermText-valueRef",Ye)})}function Xe(rt){const{status:Ye,error_msg:ut,output:Ge,input:ze,expected_output:Ve,is_file:$e,input_file_url:nt,output_file_url:et,expected_output_file_url:pt}=rt;let ct=null;const Ot={minHeight:150,marginBottom:10,paddingLeft:24,background:"#070f19",color:"#fff"};switch(Ye){case te.h.NOMATCH:ct=ae.createElement(ae.Fragment,null,ae.createElement("p",{className:"c-red"},"\u5B9E\u9645\u8F93\u5165\uFF1A"),!$e&&ae.createElement(Qe,{className:"mb10",value:ze}),$e&&ae.createElement("div",{style:Ot},ae.createElement("a",{onClick:()=>(0,E.LR)(nt,ze)},ze)),ae.createElement("p",{className:"c-red"},"\u5B9E\u9645\u8F93\u51FA\uFF1A"),!$e&&ae.createElement(Qe,{className:"mb10",value:Ge&&le.Base64.decode(Ge)||""}),$e&&ae.createElement("div",{style:Ot},ae.createElement("a",{onClick:()=>(0,E.LR)(et,Ge)},Ge)),ae.createElement("p",{className:"c-red"},"\u9884\u671F\u8F93\u51FA\uFF1A"),!$e&&ae.createElement(Qe,{className:"mb10",value:Ve&&le.Base64.decode(Ve)||""}),$e&&ae.createElement("div",{style:Ot},ae.createElement("a",{onClick:()=>(0,E.LR)(pt,Ve)},Ve)));break;case te.h.EXECUTEFAILURE:ct=ae.createElement(ae.Fragment,null,ae.createElement("p",null,"\u6700\u540E\u6267\u884C\u7684\u8F93\u5165\uFF1A"),!$e&&ae.createElement(ne.Z,{value:ze,style:Ot}),$e&&ae.createElement("div",{style:Ot},ae.createElement("a",{onClick:()=>(0,E.LR)(nt,ze)},ze)),ae.createElement("p",null,"\u6267\u884C\u51FA\u9519\u4FE1\u606F\uFF1A"),ae.createElement("pre",{className:"error"},le.Base64.decode(ut)));break;case te.h.COMPILEFAILURE:ct=ae.createElement(ae.Fragment,null,ae.createElement("p",null,"\u6700\u540E\u6267\u884C\u7684\u8F93\u5165\uFF1A"),!$e&&ae.createElement(ne.Z,{value:ze,style:Ot}),$e&&ae.createElement("div",{style:Ot},ae.createElement("a",{onClick:()=>(0,E.LR)(nt,ze)},ze)),ae.createElement("p",null,"\u6267\u884C\u51FA\u9519\u4FE1\u606F\uFF1A"),ae.createElement("pre",{className:"error"},le.Base64.decode(ut)));break;case te.h.PODFAILURE:ct=ae.createElement("p",null,"\u521B\u5EFApod\u5931\u8D25\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5");break;case te.h.TIMEOUT:ct=ae.createElement("p",null,"\u8BC4\u6D4B\u8D85\u65F6\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5");break}return ae.createElement(ae.Fragment,null," ",ct," ")}function ot(rt){const{status:Ye,error_msg:ut,execute_time:Ge,output:ze,input:Ve,expected_output:$e,is_file:nt,input_file_url:et,output_file_url:pt,expected_output_file_url:ct}=rt;let Ot=null;switch(Ye){case te.h.OK:Ot=ae.createElement(ae.Fragment,null,ae.createElement("p",null,"\u6267\u884C\u7528\u65F6\uFF1A",Ge,"\u79D2"),ae.createElement("p",null,"\u6267\u884C\u7ED3\u679C\uFF1A"),ae.createElement("pre",null,le.Base64.decode(ze)));break;case te.h.NOMATCH:Ot=ae.createElement(ae.Fragment,null,ae.createElement("p",null,"\u8F93\u5165\uFF1A",ae.createElement("pre",null,Ve)),ae.createElement("p",null,"\u8F93\u51FA\uFF1A",ze&&le.Base64.decode(ze)),ae.createElement("p",null,"\u9884\u671F\u8F93\u51FA\uFF1A",$e&&le.Base64.decode($e)));break;case te.h.EXECUTEFAILURE:Ot=ae.createElement(ae.Fragment,null,ae.createElement("p",null,"\u6700\u540E\u6267\u884C\u7684\u8F93\u5165\uFF1A",ae.createElement("pre",null,Ve)),ae.createElement("p",null,"\u6267\u884C\u51FA\u9519\u4FE1\u606F\uFF1A"),ae.createElement("pre",{className:"error"},le.Base64.decode(ut)));break;case te.h.COMPILEFAILURE:Ot=ae.createElement(ae.Fragment,null,ae.createElement("p",null,"\u6700\u540E\u6267\u884C\u7684\u8F93\u5165\uFF1A",ae.createElement("pre",null,Ve)),ae.createElement("p",null,"\u6267\u884C\u51FA\u9519\u4FE1\u606F\uFF1A"),ae.createElement("pre",{className:"error"},le.Base64.decode(ut)));break;case te.h.PODFAILURE:Ot=ae.createElement("p",null,"\u521B\u5EFApod\u5931\u8D25\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5");break;case te.h.TIMEOUT:Ot=ae.createElement("p",null,"\u8BC4\u6D4B\u8D85\u65F6\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5");break}return ae.createElement(ae.Fragment,null," ",Ot," ")}var He=({id:rt,is_file:Ye,input:ut,debuging:Ge,submitting:ze,executingMessage:Ve,debugResult:$e,onChangeInput:nt,onDebugCode:et,onSubmitCode:pt})=>{const[ct,Ot]=(0,ce.useReducer)(Pe,Ee),{visible:dt,tabIndex:Rt}=ct;(0,ce.useEffect)(()=>{Ot({type:0,payload:!1})},[rt]);function xt(Ae){let Se=Ae.target.id;Ot({type:1,payload:Se})}function gt(){Ot({type:0,payload:!dt})}const _t=(0,ce.useMemo)(()=>{if($e){const{status:Ae}=$e;return ae.createElement(ae.Fragment,null,ot($e))}return null},[$e]);function We(){Ot({type:0,payload:!0}),Ot({type:1,payload:"1"}),et()}return ae.createElement("div",{className:"test-case-panel"},ae.createElement("div",{className:`test-case-panel-body ${dt?"active":""}`},ae.createElement("ul",{className:"s-navs"},ae.createElement("li",null,ae.createElement("a",{className:"active"},"\u8C03\u8BD5\u4EE3\u7801\u7ED3\u679C"))),ae.createElement(b.Z,{leftTitle:"\u81EA\u5B9A\u4E49\u6D4B\u8BD5\u7528\u4F8B",rightTitle:"\u4EE3\u7801\u6267\u884C\u7ED3\u679C",style:{height:240},leftNode:ae.createElement(Te,{placeholder:"\u8BF7\u8F93\u5165\u81EA\u6D4B\u7528\u4F8B\uFF08\u5982\u679C\u672A\u586B\u5199\uFF0C\u9996\u6B21\u81EA\u6D4B\u8FD0\u884C\u65F6\uFF0C\u7CFB\u7EDF\u4F1A\u81EA\u52A8\u586B\u5145\u7B2C\u4E00\u4E2A\u975E\u9690\u85CF\u7684\u6587\u672C\u7C7B\u578B\u7684\u6D4B\u8BD5\u7528\u4F8B\uFF09",value:Ye?"":ut,onChange:nt}),rightNode:Ge?ae.createElement(ee.Z,{message:"\u4EE3\u7801\u6267\u884C\u4E2D..."}):$e?_t:ae.createElement("p",{style:{color:"#536879"}},"\u8BF7\u586B\u5199\u6D4B\u8BD5\u7528\u4F8B\u7684\u8F93\u5165\u503C\uFF0C\u70B9\u51FB\u201C\u8C03\u8BD5\u4EE3\u7801\u201D")})),ae.createElement("a",{className:`btn-collapse ${dt?"up":""}`,onClick:gt},dt?ae.createElement(ue.Z,null):ae.createElement(se.Z,null)),ae.createElement("footer",{className:"footer"},ae.createElement("span",{style:{visibility:"hidden"}},"\u63A7\u5236\u53F0"),ae.createElement("div",{className:"flex-container"},ae.createElement(Ce.ZP,{id:"oj-prev",className:"btn-blue",type:"ghost"},"\u4E0A\u4E00\u9898"),ae.createElement(Ce.ZP,{id:"oj-next",className:"btn-blue",type:"ghost"},"\u4E0B\u4E00\u9898"),ae.createElement(Ce.ZP,{className:"btn-green",type:"ghost",loading:Ge,onClick:We},"\u8C03\u8BD5\u4EE3\u7801"),ae.createElement(Ce.ZP,{type:"primary",className:"custom-ant-disabled",loading:ze,disabled:ze,onClick:()=>{Ot({type:0,payload:!1}),pt()}},"\u8BC4\u6D4B\u5E76\u63D0\u4EA4"))))}},63342:function(Xt,Mt,be){"use strict";be.r(Mt),be.d(Mt,{default:function(){return ll}});var ce=be(59301),ie=be(10906),Ce=be(76618),ue=be(76560),se=be(11938),te=be(6767),le=be(62957),ee=be(29787),ne=be(82326),E=be(59205),b=be(72015),z=be(90524),x=be(87169),re=be(30641),ae=be(51124),oe=be(75790),ve=be(89613),ye=be(64536),me=be(59301),ge=Object.defineProperty,_e=Object.defineProperties,he=Object.getOwnPropertyDescriptors,pe=Object.getOwnPropertySymbols,ke=Object.prototype.hasOwnProperty,Te=Object.prototype.propertyIsEnumerable,Ee=(ft,bt,wt)=>bt in ft?ge(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Oe=(ft,bt)=>{for(var wt in bt||(bt={}))ke.call(bt,wt)&&Ee(ft,wt,bt[wt]);if(pe)for(var wt of pe(bt))Te.call(bt,wt)&&Ee(ft,wt,bt[wt]);return ft},je=(ft,bt)=>_e(ft,he(bt));const Pe={theme:(0,ve.G)("cmCodeMode","vs-dark"),fontSize:(0,ve.G)("cmFontSize",14),showEditorSetting:!1,tabToSpace:(0,ve.G)("cmTabToSpace",!0)};var Qe=(ft=>(ft[ft.set_font_size=0]="set_font_size",ft[ft.set_theme=1]="set_theme",ft[ft.on_tab_to_space=2]="on_tab_to_space",ft[ft.set_show_editor_setting=3]="set_show_editor_setting",ft))(Qe||{});function Xe(ft,bt){switch(bt.type){case 3:return je(Oe({},ft),{showEditorSetting:bt.payload});case 1:return je(Oe({},ft),{theme:bt.payload});case 0:return je(Oe({},ft),{fontSize:bt.payload});case 2:return je(Oe({},ft),{tabToSpace:bt.payload});default:throw new Error}}var ot=({isLoading:ft,value:bt,onChange:wt,language:Vn,onUpdateCode:In,ActionBarRender:pn=An=>me.createElement(He,{onShowCodeSetting:An})})=>{const[An,xn]=(0,ce.useReducer)(Xe,Pe),{theme:On,fontSize:qn,showEditorSetting:ci,tabToSpace:Pr}=An,gi=(0,ce.useRef)(),kr=(0,ce.useRef)(),yi={onFontSizeChange:ki=>{xn({type:0,payload:ki}),(0,ve.t)("cmFontSize",ki)},tabToSpace:Pr,cmFontSize:qn,className:"oj",cmCodeMode:On,onTabToSpace:ki=>{xn({type:2,payload:ki}),(0,ve.t)("cmTabToSpace",ki)},onCodeModeChange:ki=>{xn({type:1,payload:ki}),(0,ve.t)("cmCodeMode",ki)}};function Br(){xn({type:3,payload:!1})}function zi(){xn({type:3,payload:!0})}const ri={value:bt,language:Vn,theme:On,height:"calc(100% - 56px)",options:{fontSize:qn,insertSpaces:Pr},onChange:ki=>{wt(ki),kr.current=ki,clearTimeout(gi.current),gi.current=setTimeout(()=>{In(kr.current)},1e4)},onEditBlur:ki=>{kr.current&&In(kr.current)}};return me.createElement(ce.Fragment,null,me.createElement("div",{className:"code-panel-container"},pn(zi),!ft&&me.createElement(ae.ZP,Oe({},ri))),me.createElement(oe.Z,null,me.createElement(re.Z,{rootClassName:"oj",title:null,placement:"right",closable:!1,open:ci,onClose:Br},me.createElement(ye.Z,Oe({},yi)))))};function He({onShowCodeSetting:ft}){return me.createElement("div",{className:"action-bar"},me.createElement("span",null,"\u5B66\u5458\u521D\u59CB\u4EE3\u7801\u6587\u4EF6"),me.createElement("a",{onClick:ft},me.createElement("i",{className:"iconfont icon-shezhi"})))}var rt=be(24334),Ye=be(12085),ut=be(40148),Ge=be(37568),ze=be(28284),Ve=be(99571);const{TextArea:$e}=Ge.default,nt=5e3;var et=({callback:ft,onCancel:bt,notes:wt})=>{function Vn(In){ft(In)}return ce.createElement(ze.default,{className:"note-form-panel",onFinish:Vn,initialValues:{notes:wt}},ce.createElement(ze.default.Item,{name:"notes",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u7B14\u8BB0\u5185\u5BB9"},{max:nt,message:`\u7B14\u8BB0\u6700\u5927\u5B57\u6570\u4E3A${nt}`}]},ce.createElement($e,{placeholder:"\u8BF7\u8F93\u5165\u7B14\u8BB0\u5185\u5BB9",rows:5})),ce.createElement(ze.default.Item,{style:{textAlign:"right"}},ce.createElement(Ve.ZP,{type:"ghost",onClick:bt,style:{marginRight:10}}," \u53D6\u6D88 "),ce.createElement(Ve.ZP,{type:"primary",htmlType:"submit"}," \u63D0\u4EA4 ")))},pt={"left-panel":"left-panel___fP6Y3","tab-panel-body":"tab-panel-body___aLOJQ",b1:"b1___ELpwD","oj-mr":"oj-mr___SIQSw","oj-width-input":"oj-width-input___tR_Si","s-navs":"s-navs___iVrSH","bg-white":"bg-white___S0kiU",active:"active___D332c"},ct={pagination:"pagination___npPu7",info:"info___aRH6C"},Ot=be(54172),dt=be(13747),Rt=be(58617),xt=be(81953),gt=be(49162),_t=be(49661),We=be(57309),Ae=be.n(We);const{Column:Se}=Ot.default;var Be=({submitResult:ft,submitting:bt,submitRecords:wt,page:Vn,onPageChange:In,topicId:pn})=>{const{status:An,id:xn,input:On,output:qn,expected_output:ci,is_file:Pr,input_file_url:gi,output_file_url:kr,expected_output_file_url:yi,error_msg:Br}=ft||{},{records:zi,records_count:ri}=wt||{},ki=(0,ue.useParams)();function Zi(){Pr?navigator.clipboard.writeText(rt.Base64.decode(Br)).then(()=>{te.ZP.success("\u590D\u5236\u9519\u8BEF\u4FE1\u606F\u6210\u529F")}):navigator.clipboard.writeText(rt.Base64.decode(qn)).then(()=>{te.ZP.success("\u590D\u5236\u9519\u8BEF\u4FE1\u606F\u6210\u529F")})}return ce.createElement(ee.Z,{spinning:bt,tip:"\u8BC4\u6D4B\u4E2D...",indicator:ce.createElement(Rt.Z,{style:{fontSize:24},spin:!0})},xn?ce.createElement(ce.Fragment,null,ce.createElement("ul",{className:ct.info},ce.createElement("li",null,"\u6267\u884C\u7ED3\u679C\uFF1A",ce.createElement("span",{className:An===gt.h.OK?"c-green":"c-red"},ut.Im[An])),ce.createElement("li",{className:ct.error},ce.createElement("a",{onClick:Zi},"\u590D\u5236\u9519\u8BEF\u4FE1\u606F ",ce.createElement(xt.Z,null)," ")),ce.createElement("li",null,ce.createElement(ue.Link,{to:`/problems/${pn}/record-detail/${xn}?backId=${ki==null?void 0:ki.save_identifier}`},"\u663E\u793A\u8BE6\u60C5 > "))),An!==gt.h.OK?ce.createElement(ce.Fragment,null,ce.createElement("p",{className:"c-red"},"\u5B9E\u9645\u8F93\u5165\uFF1A"),ce.createElement("pre",null,!Pr&&On,Pr&&ce.createElement("a",{style:{fontSize:"16px"},onClick:()=>(0,_t.LR)(gi,On)},On)),ce.createElement("p",{className:"c-red"},"\u5B9E\u9645\u8F93\u51FA\uFF1A"),ce.createElement("pre",null,(An===4||An===5)&&rt.Base64.decode(Br),An!=4&&An!=5&&(Pr?ce.createElement("a",{style:{fontSize:"16px"},onClick:()=>(0,_t.LR)(kr,qn)},qn):rt.Base64.decode(qn))),ce.createElement("p",{className:"c-red"},"\u9884\u671F\u8F93\u51FA\uFF1A"),ce.createElement("pre",null,!Pr&&rt.Base64.decode(ci),Pr&&ce.createElement("a",{style:{fontSize:"16px"},onClick:()=>(0,_t.LR)(yi,ci)},ci))):null):null,(zi==null?void 0:zi.length)>0?ce.createElement(Ot.default,{dataSource:zi,rowKey:"id",pagination:!1},ce.createElement(Se,{title:"\u63D0\u4EA4\u65F6\u95F4",dataIndex:"created_at",key:"created_at",render:(ii,Ti)=>ce.createElement("span",null," ",Ae()(ii).format("YYYY-MM-DD HH:mm:ss"))}),ce.createElement(Se,{title:"\u63D0\u4EA4\u7ED3\u679C",dataIndex:"status",key:"status",render:(ii,Ti)=>{var er;return ce.createElement(ue.Link,{className:ii===0?"c-green":"c-red",to:`/problems/${pn}/record-detail/${Ti.id}?backId=${ki==null?void 0:ki.save_identifier}`},(er=ut.Im[ii])==null?void 0:er.replace("\u8C03\u8BD5","\u8BC4\u6D4B"))}}),ce.createElement(Se,{title:"\u6267\u884C\u7528\u65F6 (S)",dataIndex:"execute_time",key:"execute_time"}),ce.createElement(Se,{title:"\u5185\u5B58\u6D88\u8017\uFF08MB\uFF09",dataIndex:"execute_memory",key:"execute_memory"}),ce.createElement(Se,{title:"\u8BED\u8A00",dataIndex:"language",key:"language"})):null,ri>15?ce.createElement(dt.Z,{className:ct.pagination,current:Vn,pageSize:15,total:ri,onChange:In}):null)},Ke=be(57884),Ne=be(96599),De=be(77736),we={desc:"desc___X8_hx",info:"info___C1DPv","commit-info":"commit-info____9yQm"},Le=be(38394),Ue=be(59301);const Me={1:{name:"\u7B80\u5355",color:"#52c41a"},2:{name:"\u9002\u4E2D",color:"#faad14"},3:{name:"\u56F0\u96BE",color:"#f5222d"}};var Re=({hack:ft,onTriggerPraise:bt,toDiscuss:wt})=>{const{language:Vn,difficulty:In,time_limit:pn,username:An,user_path:xn,user_praise:On,comments_count:qn,praises_count:ci,description:Pr,pass_count:gi,submit_count:kr}=ft,yi=(0,ue.useLocation)();console.log(ft.language,"language");const Br=Me[In];return Ue.createElement(Ue.Fragment,null,Ue.createElement("ul",{className:we.info},Ue.createElement("li",null,"\u96BE\u5EA6\uFF1A",Ue.createElement(Ne.default,{color:Br==null?void 0:Br.color},Br==null?void 0:Br.name)),Ue.createElement("li",null,"\u5355\u4E2A\u6D4B\u8BD5\u96C6\u8BC4\u6D4B\u65F6\u957F\u9650\u5236\uFF1A",Ue.createElement("b",null,pn,"\u79D2"))),Ue.createElement(Le.Z,{value:Pr,className:we.desc}),Ue.createElement("ul",{className:we["commit-info"]},Ue.createElement("li",null,Ue.createElement(De.Z,{size:4},Ue.createElement("span",null,"\u901A\u8FC7\u6B21\u6570")," ",Ue.createElement("b",null,gi))),Ue.createElement("li",null,Ue.createElement(De.Z,{size:4},Ue.createElement("span",null,"\u63D0\u4EA4\u6B21\u6570")," ",Ue.createElement("b",null,kr))," "),Ue.createElement("li",{style:{flex:"1 0 0"}}),Ue.createElement("li",null,Ue.createElement(De.Z,{size:4},Ue.createElement("i",{className:"iconfont icon-huifu1",onClick:wt})," ",Ue.createElement("b",null,qn))," ")))},tt=be(33796),lt=Object.defineProperty,Nt=Object.getOwnPropertySymbols,Ct=Object.prototype.hasOwnProperty,vt=Object.prototype.propertyIsEnumerable,Pt=(ft,bt,wt)=>bt in ft?lt(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Ht=(ft,bt)=>{for(var wt in bt||(bt={}))Ct.call(bt,wt)&&Pt(ft,wt,bt[wt]);if(Nt)for(var wt of Nt(bt))vt.call(bt,wt)&&Pt(ft,wt,bt[wt]);return ft};const jt=ft=>React.createElement("svg",Ht({width:40,height:40,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u5C55\u5F00\u9898\u76EE"),React.createElement("defs",null,React.createElement("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"100%",id:"show_svg__a"},React.createElement("stop",{stopColor:"#EEF7FF",offset:"0%"}),React.createElement("stop",{stopColor:"#C1E2FF",offset:"100%"}))),React.createElement("g",{fill:"none",fillRule:"evenodd"},React.createElement("rect",{fill:"url(#show_svg__a)",width:40,height:40,rx:8}),React.createElement("g",{fillRule:"nonzero"},React.createElement("path",{d:"M16.057 20.784H8.238A1.22 1.22 0 0 0 7 21.974v6.811a1.22 1.22 0 0 0 1.238 1.19h7.819a1.213 1.213 0 0 0 1.238-1.19v-6.811a1.213 1.213 0 0 0-.376-.847 1.203 1.203 0 0 0-.862-.332v-.01Zm-1.25 6.769H9.423V23.12h5.384v4.433Z",fill:"#4CACFF"}),React.createElement("path",{d:"M16.057 10.005a1.22 1.22 0 0 1 1.238 1.189v6.812a1.213 1.213 0 0 1-.376.846c-.232.222-.542.34-.862.332H8.238A1.213 1.213 0 0 1 7 18.005v-6.811a1.22 1.22 0 0 1 1.238-1.19Zm-1.239 2.41H9.434v4.401h5.384v-4.4Z",fill:"#94CDFF"}),React.createElement("path",{d:"M20.418 12.632h11.189a1.213 1.213 0 0 0 1.238-1.179 1.224 1.224 0 0 0-.371-.857 1.214 1.214 0 0 0-.867-.343H20.418a1.203 1.203 0 0 0-.866.336c-.233.223-.367.53-.372.854.005.323.14.63.372.854.232.223.544.344.866.335ZM31.575 16.027h-11.19a1.183 1.183 0 0 0-1.119.557c-.237.384-.237.87 0 1.254.238.384.672.6 1.12.557h11.189c.448.043.882-.173 1.119-.557.237-.384.237-.87 0-1.254a1.183 1.183 0 0 0-1.12-.557ZM31.575 21.595h-11.19a1.183 1.183 0 0 0-1.119.557c-.237.384-.237.87 0 1.254.238.384.672.6 1.12.557h11.189c.448.043.882-.173 1.119-.557.237-.384.237-.87 0-1.254a1.183 1.183 0 0 0-1.12-.557ZM31.575 27.163h-11.19a1.183 1.183 0 0 0-1.119.557c-.237.384-.237.87 0 1.254.238.384.672.6 1.12.557h11.189c.448.043.882-.173 1.119-.557.237-.384.237-.87 0-1.254a1.183 1.183 0 0 0-1.12-.557Z",fill:"#1890FF"}))));var yt="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDAiIGhlaWdodD0iNDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGRlZnM+PGxpbmVhckdyYWRpZW50IHgxPSIwJSIgeTE9IjAlIiB4Mj0iMTAwJSIgeTI9IjEwMCUiIGlkPSJhIj48c3RvcCBzdG9wLWNvbG9yPSIjRUVGN0ZGIiBvZmZzZXQ9IjAlIi8+PHN0b3Agc3RvcC1jb2xvcj0iI0MxRTJGRiIgb2Zmc2V0PSIxMDAlIi8+PC9saW5lYXJHcmFkaWVudD48L2RlZnM+PGcgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIj48cmVjdCBmaWxsPSJ1cmwoI2EpIiB3aWR0aD0iNDAiIGhlaWdodD0iNDAiIHJ4PSI4Ii8+PGcgZmlsbC1ydWxlPSJub256ZXJvIj48cGF0aCBkPSJNMTYuMDU3IDIwLjc4NEg4LjIzOEExLjIyIDEuMjIgMCAwIDAgNyAyMS45NzR2Ni44MTFhMS4yMiAxLjIyIDAgMCAwIDEuMjM4IDEuMTloNy44MTlhMS4yMTMgMS4yMTMgMCAwIDAgMS4yMzgtMS4xOXYtNi44MTFhMS4yMTMgMS4yMTMgMCAwIDAtLjM3Ni0uODQ3IDEuMjAzIDEuMjAzIDAgMCAwLS44NjItLjMzMnYtLjAxWm0tMS4yNSA2Ljc2OUg5LjQyM1YyMy4xMmg1LjM4NHY0LjQzM1oiIGZpbGw9IiM0Q0FDRkYiLz48cGF0aCBkPSJNMTYuMDU3IDEwLjAwNWExLjIyIDEuMjIgMCAwIDEgMS4yMzggMS4xODl2Ni44MTJhMS4yMTMgMS4yMTMgMCAwIDEtLjM3Ni44NDZjLS4yMzIuMjIyLS41NDIuMzQtLjg2Mi4zMzJIOC4yMzhBMS4yMTMgMS4yMTMgMCAwIDEgNyAxOC4wMDV2LTYuODExYTEuMjIgMS4yMiAwIDAgMSAxLjIzOC0xLjE5Wm0tMS4yMzkgMi40MUg5LjQzNHY0LjQwMWg1LjM4NHYtNC40WiIgZmlsbD0iIzk0Q0RGRiIvPjxwYXRoIGQ9Ik0yMC40MTggMTIuNjMyaDExLjE4OWExLjIxMyAxLjIxMyAwIDAgMCAxLjIzOC0xLjE3OSAxLjIyNCAxLjIyNCAwIDAgMC0uMzcxLS44NTcgMS4yMTQgMS4yMTQgMCAwIDAtLjg2Ny0uMzQzSDIwLjQxOGExLjIwMyAxLjIwMyAwIDAgMC0uODY2LjMzNmMtLjIzMy4yMjMtLjM2Ny41My0uMzcyLjg1NC4wMDUuMzIzLjE0LjYzLjM3Mi44NTQuMjMyLjIyMy41NDQuMzQ0Ljg2Ni4zMzVaTTMxLjU3NSAxNi4wMjdoLTExLjE5YTEuMTgzIDEuMTgzIDAgMCAwLTEuMTE5LjU1N2MtLjIzNy4zODQtLjIzNy44NyAwIDEuMjU0LjIzOC4zODQuNjcyLjYgMS4xMi41NTdoMTEuMTg5Yy40NDguMDQzLjg4Mi0uMTczIDEuMTE5LS41NTcuMjM3LS4zODQuMjM3LS44NyAwLTEuMjU0YTEuMTgzIDEuMTgzIDAgMCAwLTEuMTItLjU1N1pNMzEuNTc1IDIxLjU5NWgtMTEuMTlhMS4xODMgMS4xODMgMCAwIDAtMS4xMTkuNTU3Yy0uMjM3LjM4NC0uMjM3Ljg3IDAgMS4yNTQuMjM4LjM4NC42NzIuNiAxLjEyLjU1N2gxMS4xODljLjQ0OC4wNDMuODgyLS4xNzMgMS4xMTktLjU1Ny4yMzctLjM4NC4yMzctLjg3IDAtMS4yNTRhMS4xODMgMS4xODMgMCAwIDAtMS4xMi0uNTU3Wk0zMS41NzUgMjcuMTYzaC0xMS4xOWExLjE4MyAxLjE4MyAwIDAgMC0xLjExOS41NTdjLS4yMzcuMzg0LS4yMzcuODcgMCAxLjI1NC4yMzguMzg0LjY3Mi42IDEuMTIuNTU3aDExLjE4OWMuNDQ4LjA0My44ODItLjE3MyAxLjExOS0uNTU3LjIzNy0uMzg0LjIzNy0uODcgMC0xLjI1NGExLjE4MyAxLjE4MyAwIDAgMC0xLjEyLS41NTdaIiBmaWxsPSIjMTg5MEZGIi8+PC9nPjwvZz48L3N2Zz4=",Yt=be(82093);function Lt(ft){return(0,Yt.U2)("comments.json",ft)}function Kt(ft){return(0,Yt.v_)(`/discusses/${ft}/plus.json`,{container_type:"Discuss",type:1})}function sn(ft){return(0,Yt.v_)("comments/reply.json",ft)}function wn(ft){return(0,Yt.v_)("comments.json",ft)}function Vt(ft){return(0,Yt.v_)(`comments/${ft==null?void 0:ft.id}/hidden.json`,ft)}function Rn(ft){return(0,Yt.IV)(`comments/${ft==null?void 0:ft.id}.json`)}var Gn=be(46541),Zn=be(34055);function tr({author:ft}){return ce.createElement("a",{href:`/users/${ft.login}`,target:"_blank"},ce.createElement("img",{alt:"\u7528\u6237\u5934\u50CF",height:"50",style:{borderRadius:"50%"},src:`${z.Z.IMG_SERVER}/images/${ft.image_url}`,width:"50"}))}function hr({data:ft,index:bt,parentDiscussIndex:wt,user:Vn,onSetActionType:In}){const{author:pn,can_delete:An,content:xn,id:On,time:qn}=ft;function ci(){In({id:On,index:bt,type:"delete-discuss",parentDiscussIndex:wt,message:"\u786E\u5B9A\u8981\u5220\u9664\u8BE5\u6761\u56DE\u590D\u5417"})}const Pr=Vn.admin||An||pn.user_id===Vn.user_id;return ce.createElement("div",{className:"discuss-item-container second-discuss "},ce.createElement(tr,{author:pn}),ce.createElement("section",null,ce.createElement("div",{className:"discuss-info"},ce.createElement("a",{href:`/users/${pn.login}`,target:"_blank"},pn.name),ce.createElement("span",{className:"grey"},qn),ce.createElement("div",{className:"btn-group",style:{marginBottom:0}},Pr?ce.createElement("a",{onClick:ci,title:"\u5220\u9664"},ce.createElement("i",{className:"iconfont icon-shanchu"})):null)),ce.createElement(Le.Z,{className:"discuss-content",value:xn})))}var ur=({user:ft,data:bt,index:wt,onPlusDiscuss:Vn,onSetActionType:In,activeDiscussIndex:pn,onReplyDiscuss:An,onSetActiveDiscussIndex:xn})=>{const{content:On,children:qn,hidden:ci,id:Pr,praise_count:gi,time:kr,user_praise:yi,can_delete:Br,author:zi}=bt;console.log(Br&&(!qn||qn.length==0),"children22");function ri(){xn(Pr)}function ki(){Vn(Pr,!yi,wt)}function Zi(){In({id:Pr,index:wt,type:"delete-discuss",message:"\u786E\u5B9A\u8981\u5220\u9664\u8BE5\u6761\u56DE\u590D\u5417"})}function ii(){In({id:Pr,index:wt,params:{hidden:ci?"0":"1"},type:"hidden-discuss",message:ci?"\u786E\u5B9A\u8981\u53D6\u6D88\u9690\u85CF\u8BE5\u6761\u56DE\u590D\u5417":"\u786E\u5B9A\u8981\u9690\u85CF\u8BE5\u6761\u56DE\u590D\u5417"})}const Ti=ft.admin||ft.user_id===zi.user_id;return ce.createElement("div",{className:"discuss-item-container",key:Pr},ce.createElement(tr,{author:zi}),ce.createElement("section",null,ce.createElement("div",{className:"discuss-info"},ce.createElement("a",{href:`/users/${zi.login}`,target:"_blank"}," ",zi.name," "),ce.createElement("span",{className:"grey"},kr)),ce.createElement(Le.Z,{className:"discuss-content",value:On}),qn&&qn.length>0?ce.createElement("div",{className:"reply-discuss-container"},qn.map((er,Bi)=>ce.createElement(hr,{key:er.id,data:er,index:Bi,user:ft,onSetActionType:In,parentDiscussIndex:wt}))):null,ce.createElement("div",{className:"btn-group"},(0,Zn.Ny)()?ce.createElement("a",{onClick:ii,title:ci?"\u53D6\u6D88\u9690\u85CF":"\u9690\u85CF\u8BC4\u8BBA"},ce.createElement("i",{className:ci?"iconfont icon-yincangbiyan":"fa fa-eye"})):null,Br&&(!qn||qn.length==0)?ce.createElement("a",{onClick:Zi,title:"\u5220\u9664"},ce.createElement("i",{className:"iconfont icon-shanchu"})):null,ce.createElement("a",{onClick:ri,title:"\u56DE\u590D"}," ",ce.createElement("i",{className:"iconfont icon-huifu1"})," "),ce.createElement("a",{onClick:ki,className:yi?"c-orange":""},ce.createElement("i",{className:yi?"iconfont icon-dianzan mr3":"iconfont icon-dianzan-xian mr3 "}),ce.createElement("span",null,gi||""))),ce.createElement(Gn.Z,{id:Pr,activeDiscussIndex:pn,onReplyDiscuss:An})))},zn=be(39479),Bn=be(2978),ir=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())}),Kn=({user_praise:ft,praise_count:bt,praisePlus:wt,onCreateDiscuss:Vn,discuss_count:In})=>{const[pn,An]=(0,ce.useState)(!1),[xn,On]=(0,ce.useState)("");function qn(kr){On(kr)}function ci(){An(!0)}function Pr(){An(!1)}function gi(){return ir(this,null,function*(){Vn(xn),On(""),An(!1)})}return ce.createElement("div",{className:`dis-input-editor-container ${pn?"active":""} `},ce.createElement("div",{className:pn?"text-area hide":"text-area"},ce.createElement("input",{placeholder:"\u8BF4\u70B9\u4EC0\u4E48",onClick:ci}),ce.createElement("a",{style:{alignItems:"center"}}," ",ce.createElement("i",{className:"iconfont icon-huifu1"})," \xA0 \xA0",In," "),ce.createElement("a",{className:"c-light-black",onClick:wt,style:{alignItems:"center"},title:ft?"\u53D6\u6D88\u70B9\u8D5E":"\u70B9\u8D5E"},ce.createElement("i",{className:`mr3 ${ft?"iconfont icon-dianzan c-orange":"iconfont icon-dianzan-xian"} `}),bt?ce.createElement("span",null,bt):"")),pn?ce.createElement("div",{className:"input-mask",onClick:Pr}):null,ce.createElement("div",{className:pn?"md-container":"md-container hide"},ce.createElement(Bn.Z,{id:"discuss-input-editor",miniToolbar:!0,watch:!1,noStorage:!0,defaultValue:xn,height:240,onChange:qn}),ce.createElement("div",{className:"tip-container",onClick:Pr},ce.createElement("a",{className:"btn-send",onClick:gi}," \u53D1\u9001 "))))},Nn=Object.defineProperty,yn=Object.defineProperties,Hn=Object.getOwnPropertyDescriptors,dr=Object.getOwnPropertySymbols,Mn=Object.prototype.hasOwnProperty,Cn=Object.prototype.propertyIsEnumerable,$n=(ft,bt,wt)=>bt in ft?Nn(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Jt=(ft,bt)=>{for(var wt in bt||(bt={}))Mn.call(bt,wt)&&$n(ft,wt,bt[wt]);if(dr)for(var wt of dr(bt))Cn.call(bt,wt)&&$n(ft,wt,bt[wt]);return ft},Ie=(ft,bt)=>yn(ft,Hn(bt)),Ze=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())});const qe={loading:!1,page:1,data:[],count:0,actionType:null,activeDiscussIndex:null};var st=(ft=>(ft[ft.GET_DISCUSSES=0]="GET_DISCUSSES",ft[ft.TOP_OR_DOWN_DISCUSS=1]="TOP_OR_DOWN_DISCUSS",ft[ft.ACTIVE_DISCUSS_INDEX=2]="ACTIVE_DISCUSS_INDEX",ft[ft.PLUS_DISCUSS=3]="PLUS_DISCUSS",ft[ft.SET_ACTION_TYPE=4]="SET_ACTION_TYPE",ft[ft.SET_PAGE=5]="SET_PAGE",ft[ft.SHOW_DISCUSSES_LOADING=6]="SHOW_DISCUSSES_LOADING",ft))(st||{});function mt(ft,bt){switch(bt.type){case 6:return Ie(Jt({},ft),{loading:!0});case 0:return Jt(Jt({},ft),bt.payload);case 1:return Jt(Jt({},ft),bt.payload);case 4:return Jt(Jt({},ft),bt.payload);case 3:return Jt(Jt({},ft),bt.payload);case 5:return Jt(Jt({},ft),bt.payload);case 2:return Jt(Jt({},ft),bt.payload);default:throw new Error}}var Bt=({user:ft,identifier:bt,hack:wt,onTriggerPraise:Vn,setDiscussTotal:In})=>{const[pn,An]=(0,ce.useReducer)(mt,qe),{loading:xn,page:On,data:qn,count:ci,actionType:Pr,activeDiscussIndex:gi}=pn;console.log("---",pn);const kr=(0,ce.useCallback)(()=>Ze(void 0,null,function*(){An({type:6});const er=yield Lt({container_type:"Practice",container_identifier:bt,limit:10,page:On}),{comments:Bi,disscuss_count:Si}=er;An({type:0,payload:{data:Bi,count:Si,loading:!1}}),In(Si)}),[On,bt]);(0,ce.useEffect)(()=>{kr()},[bt,On]);function yi(er){An({type:5,payload:{page:er}})}function Br(er){An({type:4,payload:{actionType:er}})}function zi(er){An(gi===er?{type:2,payload:{activeDiscussIndex:null}}:{type:2,payload:{activeDiscussIndex:er}})}function ri(er,Bi,Si){return Ze(this,null,function*(){try{const Mi=yield Kt(er);qn[Si].user_praise=Bi,qn[Si].praise_count=Mi.praise_count,An({type:3,payload:{data:[...qn]}})}catch(Mi){console.log(Mi)}})}function ki(){return Ze(this,null,function*(){const{id:er,params:Bi,type:Si,index:Mi,parentDiscussIndex:No}=Pr;Si==="hidden-discuss"&&(console.log(Bi,"params"),yield Vt(Jt({id:er,container_type:"Practice",container_identifier:bt},Bi)),No?qn[No].children[Mi].hidden=Bi.hidden==1:qn[Mi].hidden=Bi.hidden==1,An({type:4,payload:{actionType:null,data:[...qn]}})),Si==="delete-discuss"&&(yield Rn({id:er,container_type:"Practice",container_identifier:bt}),An({type:4,payload:{actionType:null}}),yield kr())})}function Zi(){An({type:4,payload:{actionType:null}})}function ii(er,Bi){return Ze(this,null,function*(){try{yield sn({container_type:"Practice",container_identifier:bt,comments:{content:Bi,parent_id:er}}),kr()}catch(Si){console.log(Si)}})}function Ti(er){return Ze(this,null,function*(){An({type:6}),yield wn({comments:{content:er},container_type:"Practice",container_identifier:bt}),kr()})}return ce.createElement(ce.Fragment,null,ce.createElement("div",{className:"discuss-panel"},qn.length===0?ce.createElement(Ke.Z,null):ce.createElement(ee.Z,{spinning:xn},qn.map((er,Bi)=>ce.createElement(ur,{onReplyDiscuss:ii,onPlusDiscuss:ri,onSetActiveDiscussIndex:zi,onSetActionType:Br,data:er,index:Bi,user:ft,activeDiscussIndex:gi}))),ci>10?ce.createElement("div",{className:"pagination-container mt10 mb10"},ce.createElement(dt.Z,{showQuickJumper:!0,onChange:yi,current:On,total:ci,showTotal:er=>ce.createElement("span",{style:{color:"#656F87"}},"\u5171",ce.createElement("span",{className:"c-light-primary"},er),"\u6761\u6570\u636E")})):null),ce.createElement(Kn,{user_praise:wt.user_praise,praise_count:wt.praises_count,praisePlus:Vn,discuss_count:wt.comments_count,onCreateDiscuss:Ti}),ce.createElement(oe.Z,null,ce.createElement(le.default,{centered:!0,title:"\u63D0\u793A",open:!!Pr,onOk:ki,onCancel:Zi},ce.createElement("p",null,Pr?Pr.message:"")),ce.createElement(zn.Z,null)))},kt={flex_box_center:"flex_box_center___tosr6",flex_space_between:"flex_space_between___cQaTP",flex_box_vertical_center:"flex_box_vertical_center___uovxL",flex_box_center_end:"flex_box_center_end___b4gLY",flex_box_column:"flex_box_column___Umjm_",wrap:"wrap___sgoJE",head:"head___b9a9v",sort:"sort___L2Zw8",btn:"btn___khuE4",listWarp:"listWarp___zZj6C",pagination:"pagination___XlROP",fixedRight:"fixedRight___MuAXo","oj-width-input":"oj-width-input___RsZb6"},Ft={flex_box_center:"flex_box_center___EahWI",flex_space_between:"flex_space_between___zopS4",flex_box_vertical_center:"flex_box_vertical_center___w03mz",flex_box_center_end:"flex_box_center_end___lr0Fp",flex_box_column:"flex_box_column___KFHVi",active:"active___BczOO",line:"line___VC_Ry",list:"list___n9ABd",left:"left___LVHqw",mask:"mask___fP13z",right:"right___iLe52",name:"name___Oz_7h",title:"title___2Sess",a:"a___t7rIW",b:"b___Kb_45",des:"des___CjMBM",tag:"tag___V0PVb"},qt=Object.defineProperty,En=Object.getOwnPropertySymbols,Yn=Object.prototype.hasOwnProperty,At=Object.prototype.propertyIsEnumerable,St=(ft,bt,wt)=>bt in ft?qt(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,an=(ft,bt)=>{for(var wt in bt||(bt={}))Yn.call(bt,wt)&&St(ft,wt,bt[wt]);if(En)for(var wt of En(bt))At.call(bt,wt)&&St(ft,wt,bt[wt]);return ft};const Wt=ft=>React.createElement("svg",an({width:12,height:10,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u89C2\u770B"),React.createElement("path",{d:"M11 0a1 1 0 0 1 1 1v8a1 1 0 0 1-1 1H1a1 1 0 0 1-1-1V1a1 1 0 0 1 1-1h10ZM4.4 2.4a.4.4 0 0 0-.4.4v4.4a.4.4 0 0 0 .64.32l2.72-2.04a.6.6 0 0 0 0-.96L4.64 2.48a.4.4 0 0 0-.24-.08Z",fill:"#FFF",fillRule:"evenodd"}));var Et="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iMTAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTExIDBhMSAxIDAgMCAxIDEgMXY4YTEgMSAwIDAgMS0xIDFIMWExIDEgMCAwIDEtMS0xVjFhMSAxIDAgMCAxIDEtMWgxMFpNNC40IDIuNGEuNC40IDAgMCAwLS40LjR2NC40YS40LjQgMCAwIDAgLjY0LjMybDIuNzItMi4wNGEuNi42IDAgMCAwIDAtLjk2TDQuNjQgMi40OGEuNC40IDAgMCAwLS4yNC0uMDhaIiBmaWxsPSIjRkZGIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiLz48L3N2Zz4=",zt=Object.defineProperty,tn=Object.getOwnPropertySymbols,nn=Object.prototype.hasOwnProperty,gn=Object.prototype.propertyIsEnumerable,Sn=(ft,bt,wt)=>bt in ft?zt(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Tn=(ft,bt)=>{for(var wt in bt||(bt={}))nn.call(bt,wt)&&Sn(ft,wt,bt[wt]);if(tn)for(var wt of tn(bt))gn.call(bt,wt)&&Sn(ft,wt,bt[wt]);return ft};const Tt=ft=>React.createElement("svg",Tn({width:16,height:14,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u70B9\u8D5E1"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{d:"M2.593 13.356V5.694c0-.31-.231-.561-.516-.561H.976c-.532 0-.962.468-.962 1.047v6.69c0 .579.43 1.047.962 1.047h1.101c.285 0 .516-.251.516-.561Z",fill:"#999"}),React.createElement("path",{d:"M3.335 13.512V5.53c0-.184.136-.346.333-.391.695-.16 2.289-.735 2.967-2.694C7.048.73 7.495-.08 8.823.017c1.328.097 1.417 1.263 1.417 1.618v2.752s-.107.42.34.453c.45.033 3.947 0 3.947 0s1.919-.029 1.309 2.122c-.53 1.871-1.58 4.882-1.846 5.635a1.606 1.606 0 0 1-.235.438c-.257.338-.796.88-1.62.88H3.782c-.247.002-.447-.179-.447-.403Z",fill:"#CCC"})));var jn="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNMi41OTMgMTMuMzU2VjUuNjk0YzAtLjMxLS4yMzEtLjU2MS0uNTE2LS41NjFILjk3NmMtLjUzMiAwLS45NjIuNDY4LS45NjIgMS4wNDd2Ni42OWMwIC41NzkuNDMgMS4wNDcuOTYyIDEuMDQ3aDEuMTAxYy4yODUgMCAuNTE2LS4yNTEuNTE2LS41NjFaIiBmaWxsPSIjOTk5Ii8+PHBhdGggZD0iTTMuMzM1IDEzLjUxMlY1LjUzYzAtLjE4NC4xMzYtLjM0Ni4zMzMtLjM5MS42OTUtLjE2IDIuMjg5LS43MzUgMi45NjctMi42OTRDNy4wNDguNzMgNy40OTUtLjA4IDguODIzLjAxN2MxLjMyOC4wOTcgMS40MTcgMS4yNjMgMS40MTcgMS42MTh2Mi43NTJzLS4xMDcuNDIuMzQuNDUzYy40NS4wMzMgMy45NDcgMCAzLjk0NyAwczEuOTE5LS4wMjkgMS4zMDkgMi4xMjJjLS41MyAxLjg3MS0xLjU4IDQuODgyLTEuODQ2IDUuNjM1YTEuNjA2IDEuNjA2IDAgMCAxLS4yMzUuNDM4Yy0uMjU3LjMzOC0uNzk2Ljg4LTEuNjIuODhIMy43ODJjLS4yNDcuMDAyLS40NDctLjE3OS0uNDQ3LS40MDNaIiBmaWxsPSIjQ0NDIi8+PC9nPjwvc3ZnPg==",bn=Object.defineProperty,Fn=Object.getOwnPropertySymbols,Un=Object.prototype.hasOwnProperty,rr=Object.prototype.propertyIsEnumerable,pr=(ft,bt,wt)=>bt in ft?bn(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Rr=(ft,bt)=>{for(var wt in bt||(bt={}))Un.call(bt,wt)&&pr(ft,wt,bt[wt]);if(Fn)for(var wt of Fn(bt))rr.call(bt,wt)&&pr(ft,wt,bt[wt]);return ft};const wr=ft=>React.createElement("svg",Rr({width:16,height:14,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u70B9\u8D5E2"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{d:"M2.593 13.356V5.694c0-.31-.231-.561-.516-.561H.976c-.532 0-.962.468-.962 1.047v6.69c0 .579.43 1.047.962 1.047h1.101c.285 0 .516-.251.516-.561Z",fill:"#0152d9"}),React.createElement("path",{d:"M3.335 13.512V5.53c0-.184.136-.346.333-.391.695-.16 2.289-.735 2.967-2.694C7.048.73 7.495-.08 8.823.017c1.328.097 1.417 1.263 1.417 1.618v2.752s-.107.42.34.453c.45.033 3.947 0 3.947 0s1.919-.029 1.309 2.122c-.53 1.871-1.58 4.882-1.846 5.635a1.606 1.606 0 0 1-.235.438c-.257.338-.796.88-1.62.88H3.782c-.247.002-.447-.179-.447-.403Z",fill:"#B6D0FC"})));var Lr="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNMi41OTMgMTMuMzU2VjUuNjk0YzAtLjMxLS4yMzEtLjU2MS0uNTE2LS41NjFILjk3NmMtLjUzMiAwLS45NjIuNDY4LS45NjIgMS4wNDd2Ni42OWMwIC41NzkuNDMgMS4wNDcuOTYyIDEuMDQ3aDEuMTAxYy4yODUgMCAuNTE2LS4yNTEuNTE2LS41NjFaIiBmaWxsPSIjMDE1MmQ5Ii8+PHBhdGggZD0iTTMuMzM1IDEzLjUxMlY1LjUzYzAtLjE4NC4xMzYtLjM0Ni4zMzMtLjM5MS42OTUtLjE2IDIuMjg5LS43MzUgMi45NjctMi42OTRDNy4wNDguNzMgNy40OTUtLjA4IDguODIzLjAxN2MxLjMyOC4wOTcgMS40MTcgMS4yNjMgMS40MTcgMS42MTh2Mi43NTJzLS4xMDcuNDIuMzQuNDUzYy40NS4wMzMgMy45NDcgMCAzLjk0NyAwczEuOTE5LS4wMjkgMS4zMDkgMi4xMjJjLS41MyAxLjg3MS0xLjU4IDQuODgyLTEuODQ2IDUuNjM1YTEuNjA2IDEuNjA2IDAgMCAxLS4yMzUuNDM4Yy0uMjU3LjMzOC0uNzk2Ljg4LTEuNjIuODhIMy43ODJjLS4yNDcuMDAyLS40NDctLjE3OS0uNDQ3LS40MDNaIiBmaWxsPSIjQjZEMEZDIi8+PC9nPjwvc3ZnPg==",Vr=Object.defineProperty,xr=Object.getOwnPropertySymbols,Ir=Object.prototype.hasOwnProperty,jr=Object.prototype.propertyIsEnumerable,ti=(ft,bt,wt)=>bt in ft?Vr(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,di=(ft,bt)=>{for(var wt in bt||(bt={}))Ir.call(bt,wt)&&ti(ft,wt,bt[wt]);if(xr)for(var wt of xr(bt))jr.call(bt,wt)&&ti(ft,wt,bt[wt]);return ft};const wi=ft=>React.createElement("svg",di({width:16,height:14,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u8BC4\u8BBA1"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{d:"M4.717.01h8.84c1.571 0 2.357.777 2.357 2.332v5.25c0 1.556-.786 2.334-2.357 2.334h-8.84c-1.572 0-2.357-.778-2.357-2.334v-5.25C2.36.787 3.145.01 4.717.01Z",fill:"#999"}),React.createElement("path",{d:"M2.36 2.342h8.84a2.37 2.37 0 0 1 1.666.684c.442.437.69 1.03.69 1.65v5.25c0 1.288-1.055 2.333-2.357 2.333H7.94l-1.16 1.153-1.167-1.153H2.36a2.37 2.37 0 0 1-1.667-.683 2.321 2.321 0 0 1-.69-1.65v-5.25c0-.62.248-1.213.69-1.65a2.37 2.37 0 0 1 1.667-.684Z",fill:"#B6D0FC"}),React.createElement("path",{d:"M2.36 2.926h8.84c1.301 0 2.357 1.044 2.357 2.333v5.25c0 .619-.249 1.212-.69 1.65a2.37 2.37 0 0 1-1.668.683H7.94l-1.16 1.154-1.167-1.154H2.36a2.37 2.37 0 0 1-1.667-.683 2.321 2.321 0 0 1-.69-1.65V5.26c0-.619.248-1.212.69-1.65a2.37 2.37 0 0 1 1.667-.683Z",fill:"#CCC"}),React.createElement("path",{d:"M3.538 5.842h6.483c.393 0 .589.195.589.584 0 .389-.196.583-.59.583H3.539c-.393 0-.59-.194-.59-.583 0-.39.197-.584.59-.584ZM3.538 8.76h4.715c.393 0 .59.194.59.582 0 .39-.197.584-.59.584H3.538c-.393 0-.59-.195-.59-.584 0-.388.197-.583.59-.583Z",fill:"#FFF"})));var xi="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNNC43MTcuMDFoOC44NGMxLjU3MSAwIDIuMzU3Ljc3NyAyLjM1NyAyLjMzMnY1LjI1YzAgMS41NTYtLjc4NiAyLjMzNC0yLjM1NyAyLjMzNGgtOC44NGMtMS41NzIgMC0yLjM1Ny0uNzc4LTIuMzU3LTIuMzM0di01LjI1QzIuMzYuNzg3IDMuMTQ1LjAxIDQuNzE3LjAxWiIgZmlsbD0iIzk5OSIvPjxwYXRoIGQ9Ik0yLjM2IDIuMzQyaDguODRhMi4zNyAyLjM3IDAgMCAxIDEuNjY2LjY4NGMuNDQyLjQzNy42OSAxLjAzLjY5IDEuNjV2NS4yNWMwIDEuMjg4LTEuMDU1IDIuMzMzLTIuMzU3IDIuMzMzSDcuOTRsLTEuMTYgMS4xNTMtMS4xNjctMS4xNTNIMi4zNmEyLjM3IDIuMzcgMCAwIDEtMS42NjctLjY4MyAyLjMyMSAyLjMyMSAwIDAgMS0uNjktMS42NXYtNS4yNWMwLS42Mi4yNDgtMS4yMTMuNjktMS42NWEyLjM3IDIuMzcgMCAwIDEgMS42NjctLjY4NFoiIGZpbGw9IiNCNkQwRkMiLz48cGF0aCBkPSJNMi4zNiAyLjkyNmg4Ljg0YzEuMzAxIDAgMi4zNTcgMS4wNDQgMi4zNTcgMi4zMzN2NS4yNWMwIC42MTktLjI0OSAxLjIxMi0uNjkgMS42NWEyLjM3IDIuMzcgMCAwIDEtMS42NjguNjgzSDcuOTRsLTEuMTYgMS4xNTQtMS4xNjctMS4xNTRIMi4zNmEyLjM3IDIuMzcgMCAwIDEtMS42NjctLjY4MyAyLjMyMSAyLjMyMSAwIDAgMS0uNjktMS42NVY1LjI2YzAtLjYxOS4yNDgtMS4yMTIuNjktMS42NWEyLjM3IDIuMzcgMCAwIDEgMS42NjctLjY4M1oiIGZpbGw9IiNDQ0MiLz48cGF0aCBkPSJNMy41MzggNS44NDJoNi40ODNjLjM5MyAwIC41ODkuMTk1LjU4OS41ODQgMCAuMzg5LS4xOTYuNTgzLS41OS41ODNIMy41MzljLS4zOTMgMC0uNTktLjE5NC0uNTktLjU4MyAwLS4zOS4xOTctLjU4NC41OS0uNTg0Wk0zLjUzOCA4Ljc2aDQuNzE1Yy4zOTMgMCAuNTkuMTk0LjU5LjU4MiAwIC4zOS0uMTk3LjU4NC0uNTkuNTg0SDMuNTM4Yy0uMzkzIDAtLjU5LS4xOTUtLjU5LS41ODQgMC0uMzg4LjE5Ny0uNTgzLjU5LS41ODNaIiBmaWxsPSIjRkZGIi8+PC9nPjwvc3ZnPg==",ai=Object.defineProperty,Di=Object.getOwnPropertySymbols,_i=Object.prototype.hasOwnProperty,or=Object.prototype.propertyIsEnumerable,br=(ft,bt,wt)=>bt in ft?ai(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Ar=(ft,bt)=>{for(var wt in bt||(bt={}))_i.call(bt,wt)&&br(ft,wt,bt[wt]);if(Di)for(var wt of Di(bt))or.call(bt,wt)&&br(ft,wt,bt[wt]);return ft};const qr=ft=>React.createElement("svg",Ar({width:16,height:12,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u67E5\u770B1"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{d:"M7.965 11.961C2.593 11.961 0 6.926 0 5.981 0 5.035 2.623 0 7.965 0s7.965 4.984 7.965 5.98c0 .997-2.593 5.981-7.965 5.981Zm0-2.208c1.296 0 2.494-.72 3.142-1.886a3.902 3.902 0 0 0 0-3.773c-.648-1.167-1.846-1.886-3.142-1.886-2.004 0-3.629 1.69-3.629 3.773s1.625 3.772 3.629 3.772Z",fill:"#CCC"}),React.createElement("path",{d:"M7.965 8.28c-1.222 0-2.213-1.029-2.213-2.3 0-1.27.991-2.3 2.213-2.3s2.212 1.03 2.212 2.3c0 1.271-.99 2.3-2.212 2.3Z",fill:"#999"})));var $r="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNNy45NjUgMTEuOTYxQzIuNTkzIDExLjk2MSAwIDYuOTI2IDAgNS45ODEgMCA1LjAzNSAyLjYyMyAwIDcuOTY1IDBzNy45NjUgNC45ODQgNy45NjUgNS45OGMwIC45OTctMi41OTMgNS45ODEtNy45NjUgNS45ODFabTAtMi4yMDhjMS4yOTYgMCAyLjQ5NC0uNzIgMy4xNDItMS44ODZhMy45MDIgMy45MDIgMCAwIDAgMC0zLjc3M2MtLjY0OC0xLjE2Ny0xLjg0Ni0xLjg4Ni0zLjE0Mi0xLjg4Ni0yLjAwNCAwLTMuNjI5IDEuNjktMy42MjkgMy43NzNzMS42MjUgMy43NzIgMy42MjkgMy43NzJaIiBmaWxsPSIjQ0NDIi8+PHBhdGggZD0iTTcuOTY1IDguMjhjLTEuMjIyIDAtMi4yMTMtMS4wMjktMi4yMTMtMi4zIDAtMS4yNy45OTEtMi4zIDIuMjEzLTIuM3MyLjIxMiAxLjAzIDIuMjEyIDIuM2MwIDEuMjcxLS45OSAyLjMtMi4yMTIgMi4zWiIgZmlsbD0iIzk5OSIvPjwvZz48L3N2Zz4=",Wi=({style:ft={},onClick:bt,onAssist:wt,onHide:Vn,data:In,active:pn,showLine:An})=>ce.createElement(ce.Fragment,null,ce.createElement("div",{className:pn===(In==null?void 0:In.id)?`${Ft.list} ${Ft.active}`:Ft.list,style:ft,onClick:()=>bt(In)},(In==null?void 0:In.video)&&ce.createElement("div",{className:Ft.left},ce.createElement("img",{src:In==null?void 0:In.video_cover}),ce.createElement("div",null,ce.createElement("img",{src:Et}),ce.createElement("span",null,In==null?void 0:In.video_duration)),ce.createElement("div",{className:Ft.mask})),ce.createElement("div",{className:Ft.right},ce.createElement("div",{className:Ft.name},ce.createElement("img",{src:z.Z.IMG_SERVER+"/images/"+(In==null?void 0:In.image_url),width:30,height:30}),ce.createElement("div",{title:In==null?void 0:In.name,className:Ft.title},In==null?void 0:In.name),(In==null?void 0:In.is_authority)&&ce.createElement("div",{className:Ft.b},"\u5B98\u65B9"),(In==null?void 0:In.is_excellent)&&ce.createElement("div",{className:Ft.a},"\u7CBE\u9009")),ce.createElement("div",{className:Ft.des},ce.createElement(Le.Z,{showLines:2,showTextOnly:!0,value:(In==null?void 0:In.content)||"\u6682\u65E0\u5185\u5BB9"})),ce.createElement("div",{className:Ft.tag},ce.createElement("span",{className:"current",onClick:xn=>{xn.stopPropagation(),wt(In)}},ce.createElement("img",{src:In!=null&&In.user_liker?Lr:jn}),ce.createElement("span",{style:{color:In!=null&&In.user_liker?"#0152d9":"#656f87"}},In==null?void 0:In.praises_count)),ce.createElement("span",null,ce.createElement("img",{src:xi}),ce.createElement("span",null,In==null?void 0:In.discusses_count)),ce.createElement("span",null,ce.createElement("img",{src:$r}),ce.createElement("span",null,In==null?void 0:In.viewed_count)),(0,Zn.Ny)()&&ce.createElement("span",{className:"current",style:{color:"#0152d9",marginRight:0,userSelect:"none"},onClick:xn=>{xn.stopPropagation(),Vn(In)}},In!=null&&In.is_hidden?"\u53D6\u6D88\u9690\u85CF":"\u9690\u85CF")))),An&&ce.createElement("div",{className:Ft.line})),Dt={flex_box_center:"flex_box_center___C6sVF",flex_space_between:"flex_space_between___VEt8l",flex_box_vertical_center:"flex_box_vertical_center___qeD5F",flex_box_center_end:"flex_box_center_end___iYJd9",flex_box_column:"flex_box_column___iAKJf",listForm:"listForm___leDJL",scroll:"scroll___wtFaF",formWrap:"formWrap___p3W41",btns:"btns___Izl4q",main:"main___xTqlG",mainLoading:"mainLoading___QLa9s",tip:"tip___a0tbY",proWarp:"proWarp___BZhOt",pro:"pro___Yp1Rx",mainSucceed:"mainSucceed___HfaTf",del:"del___TXGhB"},$t=be(25399),Zt=be(12975),en=Object.defineProperty,on=Object.getOwnPropertySymbols,hn=Object.prototype.hasOwnProperty,Pn=Object.prototype.propertyIsEnumerable,kn=(ft,bt,wt)=>bt in ft?en(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,_n=(ft,bt)=>{for(var wt in bt||(bt={}))hn.call(bt,wt)&&kn(ft,wt,bt[wt]);if(on)for(var wt of on(bt))Pn.call(bt,wt)&&kn(ft,wt,bt[wt]);return ft};const Gt=ft=>React.createElement("svg",_n({width:32,height:30,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u4E0A\u4F20\u89C6\u9891"),React.createElement("path",{d:"M1.6 0C1.175 0 .768.17.468.474A1.63 1.63 0 0 0 0 1.622v3.243h3.237L7.378 0H1.6Zm7.876 0L5.338 4.865h5.9L15.371 0H9.476Zm7.998 0-4.137 4.865h5.896L23.372 0h-5.898Zm8 0-4.138 4.865h6.66V1.622a1.629 1.629 0 0 0-.467-1.148A1.585 1.585 0 0 0 26.397 0h-.924ZM0 6.487v17.837c0 .43.167.844.468 1.148.3.305.707.475 1.132.474h18.61a6.515 6.515 0 0 1 1.652-6.218 6.31 6.31 0 0 1 6.134-1.675V6.487H0Zm11.998 5.675 6.4 4.056-6.4 4.055v-8.11Zm14.399 6.487c-3.092.002-5.597 2.544-5.595 5.678.001 3.134 2.508 5.674 5.6 5.673C29.494 30 32 27.458 32 24.324c0-1.506-.59-2.95-1.641-4.014a5.561 5.561 0 0 0-3.962-1.661Zm0 2.027c.22.003.428.1.574.266.663.6 1.327 1.352 1.99 2.002a.8.8 0 0 1 0 1.14.788.788 0 0 1-1.125 0l-.638-.646v3.724a.814.814 0 0 1-.392.724.79.79 0 0 1-.815 0 .814.814 0 0 1-.392-.724v-3.724l-.637.646a.79.79 0 0 1-.773.215.803.803 0 0 1-.567-.575.816.816 0 0 1 .212-.783c.651-.664 1.333-1.388 1.99-2.002a.778.778 0 0 1 .575-.266l-.002.003Z",fill:"#0152d9",fillRule:"nonzero"}));var cn="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEuNiAwQzEuMTc1IDAgLjc2OC4xNy40NjguNDc0QTEuNjMgMS42MyAwIDAgMCAwIDEuNjIydjMuMjQzaDMuMjM3TDcuMzc4IDBIMS42Wm03Ljg3NiAwTDUuMzM4IDQuODY1aDUuOUwxNS4zNzEgMEg5LjQ3NlptNy45OTggMC00LjEzNyA0Ljg2NWg1Ljg5NkwyMy4zNzIgMGgtNS44OThabTggMC00LjEzOCA0Ljg2NWg2LjY2VjEuNjIyYTEuNjI5IDEuNjI5IDAgMCAwLS40NjctMS4xNDhBMS41ODUgMS41ODUgMCAwIDAgMjYuMzk3IDBoLS45MjRaTTAgNi40ODd2MTcuODM3YzAgLjQzLjE2Ny44NDQuNDY4IDEuMTQ4LjMuMzA1LjcwNy40NzUgMS4xMzIuNDc0aDE4LjYxYTYuNTE1IDYuNTE1IDAgMCAxIDEuNjUyLTYuMjE4IDYuMzEgNi4zMSAwIDAgMSA2LjEzNC0xLjY3NVY2LjQ4N0gwWm0xMS45OTggNS42NzUgNi40IDQuMDU2LTYuNCA0LjA1NXYtOC4xMVptMTQuMzk5IDYuNDg3Yy0zLjA5Mi4wMDItNS41OTcgMi41NDQtNS41OTUgNS42NzguMDAxIDMuMTM0IDIuNTA4IDUuNjc0IDUuNiA1LjY3M0MyOS40OTQgMzAgMzIgMjcuNDU4IDMyIDI0LjMyNGMwLTEuNTA2LS41OS0yLjk1LTEuNjQxLTQuMDE0YTUuNTYxIDUuNTYxIDAgMCAwLTMuOTYyLTEuNjYxWm0wIDIuMDI3Yy4yMi4wMDMuNDI4LjEuNTc0LjI2Ni42NjMuNiAxLjMyNyAxLjM1MiAxLjk5IDIuMDAyYS44LjggMCAwIDEgMCAxLjE0Ljc4OC43ODggMCAwIDEtMS4xMjUgMGwtLjYzOC0uNjQ2djMuNzI0YS44MTQuODE0IDAgMCAxLS4zOTIuNzI0Ljc5Ljc5IDAgMCAxLS44MTUgMCAuODE0LjgxNCAwIDAgMS0uMzkyLS43MjR2LTMuNzI0bC0uNjM3LjY0NmEuNzkuNzkgMCAwIDEtLjc3My4yMTUuODAzLjgwMyAwIDAgMS0uNTY3LS41NzUuODE2LjgxNiAwIDAgMSAuMjEyLS43ODNjLjY1MS0uNjY0IDEuMzMzLTEuMzg4IDEuOTktMi4wMDJhLjc3OC43NzggMCAwIDEgLjU3NS0uMjY2bC0uMDAyLjAwM1oiIGZpbGw9IiMwMTUyZDkiIGZpbGwtcnVsZT0ibm9uemVybyIvPjwvc3ZnPg==",dn=Object.defineProperty,un=Object.getOwnPropertySymbols,mn=Object.prototype.hasOwnProperty,ln=Object.prototype.propertyIsEnumerable,fn=(ft,bt,wt)=>bt in ft?dn(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,vn=(ft,bt)=>{for(var wt in bt||(bt={}))mn.call(bt,wt)&&fn(ft,wt,bt[wt]);if(un)for(var wt of un(bt))ln.call(bt,wt)&&fn(ft,wt,bt[wt]);return ft};const Ln=ft=>React.createElement("svg",vn({width:30,height:30,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u4E0A\u4F20\u6210\u529F"),React.createElement("path",{d:"M15 0c8.285 0 15 6.717 15 15 0 8.285-6.715 15-15 15-8.283 0-15-6.715-15-15C0 6.717 6.717 0 15 0Zm10.041 7.5v.01a47.934 47.934 0 0 0-11.232 9.386l-4.372-3.3v-.002L7.5 15.08l7.553 7.42A44.625 44.625 0 0 1 25.5 8.55l-.459-1.05Z",fill:"#44D7B6",fillRule:"nonzero"}));var Jn="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMzAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTE1IDBjOC4yODUgMCAxNSA2LjcxNyAxNSAxNSAwIDguMjg1LTYuNzE1IDE1LTE1IDE1LTguMjgzIDAtMTUtNi43MTUtMTUtMTVDMCA2LjcxNyA2LjcxNyAwIDE1IDBabTEwLjA0MSA3LjV2LjAxYTQ3LjkzNCA0Ny45MzQgMCAwIDAtMTEuMjMyIDkuMzg2bC00LjM3Mi0zLjN2LS4wMDJMNy41IDE1LjA4bDcuNTUzIDcuNDJBNDQuNjI1IDQ0LjYyNSAwIDAgMSAyNS41IDguNTVsLS40NTktMS4wNVoiIGZpbGw9IiM0NEQ3QjYiIGZpbGwtcnVsZT0ibm9uemVybyIvPjwvc3ZnPg==",Xn=Object.defineProperty,gr=Object.getOwnPropertySymbols,nr=Object.prototype.hasOwnProperty,Cr=Object.prototype.propertyIsEnumerable,Tr=(ft,bt,wt)=>bt in ft?Xn(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Gr=(ft,bt)=>{for(var wt in bt||(bt={}))nr.call(bt,wt)&&Tr(ft,wt,bt[wt]);if(gr)for(var wt of gr(bt))Cr.call(bt,wt)&&Tr(ft,wt,bt[wt]);return ft};const Or=ft=>React.createElement("svg",Gr({xmlns:"http://www.w3.org/2000/svg",width:20,height:20},ft),React.createElement("path",{fill:"#AFBACB",d:"M9.99.02C4.482.02.02 4.482.02 9.99c0 5.506 4.463 9.97 9.97 9.97 5.506 0 9.97-4.464 9.97-9.97 0-5.507-4.464-9.97-9.97-9.97Zm1.636 13.69c-.744 1.19-1.488 2.083-2.827 2.083-.893-.149-1.19-.744-1.042-1.488l1.637-5.506c0-.149 0-.298-.149-.298-.148 0-.446 0-.595.298l-1.042 1.19v-.744c.745-1.19 1.935-2.083 2.828-2.083.744.149 1.19.744 1.042 1.488L9.84 14.305c0 .149 0 .298.148.298.15 0 .447-.15.596-.298l1.041-1.34v.745Zm-.297-7.292c-.596 0-1.19-.446-1.19-1.19 0-.745.446-1.191 1.19-1.191.595 0 1.19.446 1.19 1.19 0 .745-.595 1.191-1.19 1.191Z"}));var Kr="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCI+PHBhdGggZmlsbD0iI0FGQkFDQiIgZD0iTTkuOTkuMDJDNC40ODIuMDIuMDIgNC40ODIuMDIgOS45OWMwIDUuNTA2IDQuNDYzIDkuOTcgOS45NyA5Ljk3IDUuNTA2IDAgOS45Ny00LjQ2NCA5Ljk3LTkuOTcgMC01LjUwNy00LjQ2NC05Ljk3LTkuOTctOS45N1ptMS42MzYgMTMuNjljLS43NDQgMS4xOS0xLjQ4OCAyLjA4My0yLjgyNyAyLjA4My0uODkzLS4xNDktMS4xOS0uNzQ0LTEuMDQyLTEuNDg4bDEuNjM3LTUuNTA2YzAtLjE0OSAwLS4yOTgtLjE0OS0uMjk4LS4xNDggMC0uNDQ2IDAtLjU5NS4yOThsLTEuMDQyIDEuMTl2LS43NDRjLjc0NS0xLjE5IDEuOTM1LTIuMDgzIDIuODI4LTIuMDgzLjc0NC4xNDkgMS4xOS43NDQgMS4wNDIgMS40ODhMOS44NCAxNC4zMDVjMCAuMTQ5IDAgLjI5OC4xNDguMjk4LjE1IDAgLjQ0Ny0uMTUuNTk2LS4yOThsMS4wNDEtMS4zNHYuNzQ1Wm0tLjI5Ny03LjI5MmMtLjU5NiAwLTEuMTktLjQ0Ni0xLjE5LTEuMTkgMC0uNzQ1LjQ0Ni0xLjE5MSAxLjE5LTEuMTkxLjU5NSAwIDEuMTkuNDQ2IDEuMTkgMS4xOSAwIC43NDUtLjU5NSAxLjE5MS0xLjE5IDEuMTkxWiIvPjwvc3ZnPg==",ni=Object.defineProperty,Wr=Object.getOwnPropertySymbols,ei=Object.prototype.hasOwnProperty,Dr=Object.prototype.propertyIsEnumerable,ar=(ft,bt,wt)=>bt in ft?ni(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,fr=(ft,bt)=>{for(var wt in bt||(bt={}))ei.call(bt,wt)&&ar(ft,wt,bt[wt]);if(Wr)for(var wt of Wr(bt))Dr.call(bt,wt)&&ar(ft,wt,bt[wt]);return ft},cr=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())});const Yr=(ft,bt)=>{var wt,Vn,In;const{uploadInfo:pn={}}=bt.payload;switch(bt.type){case"addVideo":return{videoList:[...ft.videoList,{name:pn.file.name,size:pn.file.size,type:pn.file.type,fileHash:pn.fileHash,state:pn.state,video_id:pn.videoId,attachment_id:"",article_id:-1,loaded:0,title:""}]};case"removeVideo":return{videoList:ft.videoList.filter(An=>An.name!==bt.payload.name)};case"replaceVideo":return{videoList:bt.payload};case"removeAll":return[];case"updateProgress":return{videoList:ft.videoList.map(An=>An.name===bt.payload.uploadInfo.file.name?fr(fr({},An),{loaded:bt.payload.progressPercent,video_id:pn.videoId,fileHash:pn.fileHash}):An)};case"updateTitle":return{videoList:(wt=ft.videoList)==null?void 0:wt.map(An=>An.name===bt.payload.item.name?fr(fr({},An),{title:bt.payload.title}):An)};case"updateImg":return{videoList:(Vn=ft.videoList)==null?void 0:Vn.map(An=>An.name===bt.payload.item.name?fr(fr({},An),{attachment_id:bt.payload.attachment_id}):An)};case"updateImg":return{videoList:(In=ft.videoList)==null?void 0:In.map(An=>An.name===bt.payload.item.name?fr(fr({},An),{attachment_id:bt.payload.attachment_id}):An)};default:return[]}};var Jr=({onClose:ft,onOk:bt,identifier:wt,active:Vn})=>{var In,pn;const[An]=ze.default.useForm(),[xn,On]=(0,ce.useState)({}),[qn,ci]=(0,ce.useState)(!1),[Pr,gi]=(0,ce.useState)(!1),[kr,yi]=(0,ce.useReducer)(Yr,{videoList:[]}),Br=(0,Zn.eY)(),zi=(0,ue.useParams)(),ri=(0,ce.useRef)();(0,ce.useEffect)(()=>{Vn&&ki()},[Vn]);const ki=()=>cr(void 0,null,function*(){var Fr,mi,Mr,qo,so,oa,os,aa,ga,oi;const Ai=yield(0,E.M3)(wt,{active:Vn});if((Ai==null?void 0:Ai.status)===0){const oo={name:(Fr=Ai==null?void 0:Ai.data)==null?void 0:Fr.name,content:(mi=Ai==null?void 0:Ai.data)==null?void 0:mi.content};An.setFieldsValue(oo),On(oo),(qo=(Mr=Ai==null?void 0:Ai.data)==null?void 0:Mr.videos)!=null&&qo[0]&&yi({type:"replaceVideo",payload:[{video_id:(os=(oa=(so=Ai==null?void 0:Ai.data)==null?void 0:so.videos)==null?void 0:oa[0])==null?void 0:os.video_id,name:(oi=(ga=(aa=Ai==null?void 0:Ai.data)==null?void 0:aa.videos)==null?void 0:ga[0])==null?void 0:oi.title,loaded:100}]})}}),Zi=(Fr,mi)=>{On(fr({},mi))},ii=Fr=>cr(void 0,null,function*(){const mi={videos:kr.videoList,articles:Fr};gi(!0);let Mr;Vn?(mi.active=Vn,Mr=yield(0,E.gu)(wt,mi)):Mr=yield(0,E.bx)(wt,mi),(Mr==null?void 0:Mr.status)===0&&(console.log(Vn||(Mr==null?void 0:Mr.id),44),bt(Vn||(Mr==null?void 0:Mr.id))),gi(!1)}),Ti=()=>{const Fr=document.getElementById("fileUpload");Fr.value=""},er=Fr=>{var mi='{"Vod":{}}';if(ci(!0),ri.current){ri.current.addFile(Fr,null,null,null,mi);return}(0,Zt.o)(Br==null?void 0:Br.login,"",{create:!ri,addFileSuccess:Mr=>{yi({type:"addVideo",payload:{uploadInfo:Mr}})},onUploadProgress:(Mr,qo,so)=>{const oa=Math.ceil(so*100);yi({type:"updateProgress",payload:{uploadInfo:Mr,progressPercent:oa}}),Ti()},onUploadFailed:Mr=>{te.ZP.info("\u89C6\u9891\u4E91\u670D\u52A1\u51FA\u73B0\u5F02\u5E38\uFF0C\u8BF7\u91CD\u65B0\u4E0A\u4F20\u3002")},onUploadEnd:Mr=>{ci(!1)},onUploadSucceed:Mr=>{ci(!1)},onUploadError:Mr=>{ci(!1)},gotUploader:Mr=>{Mr.addFile(Fr,null,null,null,mi),ri.current=Mr}})},Bi=Fr=>{var mi;const qo=Fr.target.files[0];if(!qo){Ti();return}let so=qo.name.toLowerCase();if(so&&so.indexOf(".avi")==-1&&so.indexOf(".flv")==-1&&so.indexOf(".f4v")==-1&&so.indexOf(".m4v")==-1&&so.indexOf(".mov")==-1&&so.indexOf(".mp4")==-1&&so.indexOf(".rmvb")==-1&&so.indexOf(".swf")==-1&&so.indexOf(".webm")==-1&&so.indexOf(".wmv")==-1){te.ZP.info("\u4E0D\u652F\u6301\u7684\u89C6\u9891\u683C\u5F0F"),Ti();return}if(qo.size>1024*1024*1024){te.ZP.info("\u89C6\u9891\u5927\u5C0F\u8D85\u8FC71024M"),Ti();return}if((mi=kr.videoList)!=null&&mi.find(oa=>oa.name===qo.name)){te.ZP.info("\u4F60\u4E0D\u80FD\u4E0A\u4F20\u540C\u4E00\u4E2A\u89C6\u9891\u6587\u4EF6\u540D\u79F0\uFF0C\u8BF7\u91CD\u65B0\u9009\u62E9\u3002"),Ti();return}er(qo)},Si=(Fr,mi)=>{le.default.confirm({title:"\u63D0\u793A",centered:!0,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",content:ce.createElement("div",{className:"tc"},"\u60A8\u786E\u8BA4\u8981",mi?"\u5220\u9664":"\u53D6\u6D88\u4E0A\u4F20","\u8BE5\u89C6\u9891\u5417\uFF1F"),onOk:()=>{Ti(),yi({type:"removeVideo",payload:{name:Fr}})}})},Mi=()=>ce.createElement("label",{htmlFor:"fileUpload",className:Dt.main},ce.createElement("img",{src:cn,alt:""}),ce.createElement("span",null,"\u4E0A\u4F20\u89C6\u9891")),No=Fr=>ce.createElement("div",{className:Dt.mainLoading},ce.createElement("div",{className:Dt.proWarp},ce.createElement("div",{className:Dt.pro},ce.createElement("div",{style:{width:Fr}})),ce.createElement("span",null,Fr||0,"%")),ce.createElement("aside",null,"\u4E0A\u4F20\u4E2D"),ce.createElement("div",{className:Dt.tip},ce.createElement($t.Z,{getPopupContainer:mi=>mi.parentNode,title:ce.createElement("div",null,ce.createElement("div",null,"1\u3001\u4E0A\u4F20\u89C6\u9891\uFF0C\u5373\u8868\u793A\u60A8\u5DF2\u540C\u610F",ce.createElement("a",{className:"current c-light-primary",target:"_blank",href:"/users/innov/videos/protocol"},"\u4E0A\u4F20\u5185\u5BB9\u534F\u8BAE"),"\uFF0C\u4E0D\u5F97\u4E0A\u4F20\u672A\u7ECF\u4ED6\u4EBA\u6388\u6743\u7684\u4F5C\u54C1\uFF1B"),ce.createElement("div",null,"2\u3001\u4E0D\u652F\u6301\u65AD\u70B9\u7EED\u4F20\uFF0C\u6587\u4EF6\u5927\u5C0F\u8BF7\u52FF\u8D85\u8FC71G\uFF1B"),ce.createElement("div",null,"3\u3001\u652F\u6301\u6587\u4EF6\u683C\u5F0F\uFF1Aavi\u3001flv\u3001f4v\u3001m4v\u3001mov\u3001mp4\u3001rmvb\u3001swf\u3001webm\u3001wmv\uFF1B"))},ce.createElement("img",{src:Kr,alt:""})))),mr=Fr=>ce.createElement("div",{className:Dt.mainSucceed},ce.createElement("img",{src:Jn,alt:""}),ce.createElement("span",null,"\u4E0A\u4F20\u6210\u529F"),ce.createElement("div",{className:Dt.tip},ce.createElement($t.Z,{getPopupContainer:mi=>mi.parentNode,title:ce.createElement("div",null,ce.createElement("div",null,"1\u3001\u4E0A\u4F20\u89C6\u9891\uFF0C\u5373\u8868\u793A\u60A8\u5DF2\u540C\u610F",ce.createElement("a",{className:"current c-light-primary",target:"_blank",href:"/users/innov/videos/protocol"},"\u4E0A\u4F20\u5185\u5BB9\u534F\u8BAE"),"\uFF0C\u4E0D\u5F97\u4E0A\u4F20\u672A\u7ECF\u4ED6\u4EBA\u6388\u6743\u7684\u4F5C\u54C1\uFF1B"),ce.createElement("div",null,"2\u3001\u4E0D\u652F\u6301\u65AD\u70B9\u7EED\u4F20\uFF0C\u6587\u4EF6\u5927\u5C0F\u8BF7\u52FF\u8D85\u8FC71G\uFF1B"),ce.createElement("div",null,"3\u3001\u652F\u6301\u6587\u4EF6\u683C\u5F0F\uFF1Aavi\u3001flv\u3001f4v\u3001m4v\u3001mov\u3001mp4\u3001rmvb\u3001swf\u3001webm\u3001wmv\uFF1B"))},ce.createElement("img",{src:Kr,alt:""}))),ce.createElement("div",{className:Dt.del,onClick:()=>Si(Fr.name,Fr.loaded==100)},ce.createElement("i",{className:"iconfont icon-shanchu7 mr5"}),"\u5220\u9664\u89C6\u9891")),Gi=()=>{var Fr;return ce.createElement(ce.Fragment,null,(Fr=kr.videoList)==null?void 0:Fr.map((mi,Mr)=>ce.createElement(ce.Fragment,{key:Mr},mi.loaded==100?mr(mi):No(mi.loaded))))},li=()=>{le.default.confirm({centered:!0,width:500,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u6CE8\u610F",icon:null,className:"custom-modal-divider",content:"\u60A8\u6B63\u5728\u7F16\u5199\u9898\u89E3\uFF0C\u70B9\u51FB\u5173\u95ED\u540E\uFF0C\u60A8\u7684\u9898\u89E3\u5185\u5BB9\u5C06\u4E0D\u4F1A\u8FDB\u884C\u4FDD\u5B58\u3002",onOk:ft})},Sr=(In=kr.videoList)==null?void 0:In.length;return ce.createElement("div",{className:Dt.listForm},ce.createElement("header",null,Vn?"\u7F16\u8F91":"\u53D1\u5E03","\u9898\u89E3"),ce.createElement("section",{className:Dt.scroll,id:"sss"},ce.createElement("div",{className:Dt.formWrap}," ",ce.createElement(ze.default,{form:An,scrollToFirstError:!0,layout:"vertical",onValuesChange:Zi,onFinish:ii},ce.createElement(ze.default.Item,{name:"name",label:"\u6807\u9898:",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u540D\u79F0"},{max:60,message:"\u8BF7\u8F93\u5165\u540D\u79F0\uFF0C\u6700\u5927\u9650\u523660\u4E2A\u5B57\u7B26"},{whitespace:!0,message:"\u8BF7\u52FF\u8F93\u5165\u7A7A\u683C"}]},ce.createElement(Ge.default,{bordered:!1,placeholder:"\u8BF7\u8F93\u5165\u540D\u79F0\uFF0C\u6700\u5927\u9650\u523660\u4E2A\u5B57\u7B26",suffix:`${((pn=xn.name)==null?void 0:pn.length)||0}/60`})),ce.createElement(ze.default.Item,{name:"content",label:"\u5185\u5BB9:"},ce.createElement(Bn.Z,{defaultValue:xn.content||"",watch:!0})))),ce.createElement("div",{className:Dt.upload},Sr?Gi():Mi(),ce.createElement("input",{type:"file",id:"fileUpload",style:{display:"none"},onChange:Bi,accept:".mkv, .flv, .f4v, .rmvb, .swf, video/mp4,video/x-m4v,video/flv,video/f4v,video/rmvb,video/swf,video/*"}))),ce.createElement("div",{className:Dt.btns},ce.createElement(Ve.ZP,{onClick:li,type:"primary",ghost:!0},"\u5173\u95ED"),ce.createElement(Ve.ZP,{loading:Pr,disabled:qn,onClick:()=>An.submit(),type:"primary"},"\u53D1\u5E03\u9898\u89E3")))},hi={flex_box_center:"flex_box_center___Udvu8",flex_space_between:"flex_space_between___WNLp1",flex_box_vertical_center:"flex_box_vertical_center___ecch5",flex_box_center_end:"flex_box_center_end___cu_DJ",flex_box_column:"flex_box_column___zF2CU",listDetails:"listDetails___HpDwH",head:"head___wipEz",name:"name___qdH8S",title:"title___B0yUa",a:"a___LB6ZS",b:"b___yvOON",tag:"tag___bRCso",btn:"btn___akBxg",scroll:"scroll___JKC_q",video:"video___nEr4F",html:"html___GDNSx",g:"g___LSOhO",btns:"btns___Ci727"},ao=be(458),Hi=Object.defineProperty,Lo=Object.getOwnPropertySymbols,po=Object.prototype.hasOwnProperty,Ri=Object.prototype.propertyIsEnumerable,Ii=(ft,bt,wt)=>bt in ft?Hi(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Pi=(ft,bt)=>{for(var wt in bt||(bt={}))po.call(bt,wt)&&Ii(ft,wt,bt[wt]);if(Lo)for(var wt of Lo(bt))Ri.call(bt,wt)&&Ii(ft,wt,bt[wt]);return ft};const mo=ft=>React.createElement("svg",Pi({xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:15,height:16},ft),React.createElement("defs",null,React.createElement("path",{id:"jx_svg__a",d:"M6.385.257c.616-.343 1.616-.342 2.23 0l5.27 2.94C14.501 3.538 15 4.38 15 5.071v5.856c0 .692-.501 1.533-1.115 1.876l-5.27 2.939c-.616.343-1.616.342-2.23 0l-5.27-2.94C.499 12.462 0 11.622 0 10.929V5.072C0 4.38.501 3.54 1.115 3.196Zm1.423 3.817c-.169-.341-.446-.341-.615 0L6.38 5.717c-.169.341-.616.665-.994.72l-1.82.264c-.378.055-.464.317-.19.583l1.317 1.278c.273.266.444.79.38 1.165l-.31 1.806c-.066.376.158.538.496.36l1.628-.853c.338-.177.89-.177 1.23 0l1.627.853c.337.177.561.015.497-.36l-.31-1.806c-.065-.375.105-.899.379-1.165l1.316-1.278c.274-.266.188-.529-.19-.583l-1.819-.264c-.377-.054-.825-.378-.994-.72Z"})),React.createElement("g",{fill:"none",fillRule:"evenodd"},React.createElement("mask",{id:"jx_svg__b",fill:"#fff"},React.createElement("use",{xlinkHref:"#jx_svg__a"})),React.createElement("use",{fill:"#8DC9FF",fillRule:"nonzero",xlinkHref:"#jx_svg__a"}),React.createElement("circle",{cx:-1.5,cy:-3.5,r:16.5,fill:"#C1E2FF",fillRule:"nonzero",mask:"url(#jx_svg__b)"}),React.createElement("circle",{cx:-2.5,cy:-4.5,r:12.5,fill:"#EEF7FF",fillRule:"nonzero",mask:"url(#jx_svg__b)"})));var Fi="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMTUiIGhlaWdodD0iMTYiPjxkZWZzPjxwYXRoIGlkPSJhIiBkPSJNNi4zODUuMjU3Yy42MTYtLjM0MyAxLjYxNi0uMzQyIDIuMjMgMGw1LjI3IDIuOTRDMTQuNTAxIDMuNTM4IDE1IDQuMzggMTUgNS4wNzF2NS44NTZjMCAuNjkyLS41MDEgMS41MzMtMS4xMTUgMS44NzZsLTUuMjcgMi45MzljLS42MTYuMzQzLTEuNjE2LjM0Mi0yLjIzIDBsLTUuMjctMi45NEMuNDk5IDEyLjQ2MiAwIDExLjYyMiAwIDEwLjkyOVY1LjA3MkMwIDQuMzguNTAxIDMuNTQgMS4xMTUgMy4xOTZabTEuNDIzIDMuODE3Yy0uMTY5LS4zNDEtLjQ0Ni0uMzQxLS42MTUgMEw2LjM4IDUuNzE3Yy0uMTY5LjM0MS0uNjE2LjY2NS0uOTk0LjcybC0xLjgyLjI2NGMtLjM3OC4wNTUtLjQ2NC4zMTctLjE5LjU4M2wxLjMxNyAxLjI3OGMuMjczLjI2Ni40NDQuNzkuMzggMS4xNjVsLS4zMSAxLjgwNmMtLjA2Ni4zNzYuMTU4LjUzOC40OTYuMzZsMS42MjgtLjg1M2MuMzM4LS4xNzcuODktLjE3NyAxLjIzIDBsMS42MjcuODUzYy4zMzcuMTc3LjU2MS4wMTUuNDk3LS4zNmwtLjMxLTEuODA2Yy0uMDY1LS4zNzUuMTA1LS44OTkuMzc5LTEuMTY1bDEuMzE2LTEuMjc4Yy4yNzQtLjI2Ni4xODgtLjUyOS0uMTktLjU4M2wtMS44MTktLjI2NGMtLjM3Ny0uMDU0LS44MjUtLjM3OC0uOTk0LS43MloiLz48L2RlZnM+PGcgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIj48bWFzayBpZD0iYiIgZmlsbD0iI2ZmZiI+PHVzZSB4bGluazpocmVmPSIjYSIvPjwvbWFzaz48dXNlIGZpbGw9IiM4REM5RkYiIGZpbGwtcnVsZT0ibm9uemVybyIgeGxpbms6aHJlZj0iI2EiLz48Y2lyY2xlIGN4PSItMS41IiBjeT0iLTMuNSIgcj0iMTYuNSIgZmlsbD0iI0MxRTJGRiIgZmlsbC1ydWxlPSJub256ZXJvIiBtYXNrPSJ1cmwoI2IpIi8+PGNpcmNsZSBjeD0iLTIuNSIgY3k9Ii00LjUiIHI9IjEyLjUiIGZpbGw9IiNFRUY3RkYiIGZpbGwtcnVsZT0ibm9uemVybyIgbWFzaz0idXJsKCNiKSIvPjwvZz48L3N2Zz4=",Ki=Object.defineProperty,ji=Object.getOwnPropertySymbols,yr=Object.prototype.hasOwnProperty,zr=Object.prototype.propertyIsEnumerable,Ur=(ft,bt,wt)=>bt in ft?Ki(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Zr=(ft,bt)=>{for(var wt in bt||(bt={}))yr.call(bt,wt)&&Ur(ft,wt,bt[wt]);if(ji)for(var wt of ji(bt))zr.call(bt,wt)&&Ur(ft,wt,bt[wt]);return ft};const Ci=ft=>React.createElement("svg",Zr({xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:16,height:16},ft),React.createElement("defs",null,React.createElement("path",{id:"gf_svg__a",d:"m8 0 1.857 1.073h2.146l1.071 1.854L14.931 4v2.144L16 8l-1.069 1.857V12l-1.858 1.072-1.071 1.856H9.857L8 16l-1.855-1.073H4l-1.072-1.856L1.072 12V9.857L0 8l1.072-1.856V4l1.857-1.073 1.072-1.854h2.145L8 0Zm2.91 6.385H4.796V12h1.246v-.451h4.026v.435h1.247V9.196H6.043v-.515h4.866V6.385Zm-.84 3.681v.613H6.042v-.613h4.026ZM9.705 7.24v.588H6.043v-.588h3.663ZM8.615 4l-1.48.137c.055.133.12.284.192.453l.076.175H4v1.426h1.195v-.483h5.61v.483H12V4.765H8.883c-.078-.23-.148-.43-.21-.602L8.616 4Z"})),React.createElement("g",{fill:"none",fillRule:"evenodd"},React.createElement("mask",{id:"gf_svg__b",fill:"#fff"},React.createElement("use",{xlinkHref:"#gf_svg__a"})),React.createElement("use",{fill:"#8DC9FF",fillRule:"nonzero",xlinkHref:"#gf_svg__a"}),React.createElement("circle",{cx:.5,cy:-3.5,r:16.5,fill:"#C1E2FF",fillRule:"nonzero",mask:"url(#gf_svg__b)"}),React.createElement("circle",{cx:-.5,cy:-4.5,r:12.5,fill:"#EEF7FF",fillRule:"nonzero",mask:"url(#gf_svg__b)"})));var Oi="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMTYiIGhlaWdodD0iMTYiPjxkZWZzPjxwYXRoIGlkPSJhIiBkPSJtOCAwIDEuODU3IDEuMDczaDIuMTQ2bDEuMDcxIDEuODU0TDE0LjkzMSA0djIuMTQ0TDE2IDhsLTEuMDY5IDEuODU3VjEybC0xLjg1OCAxLjA3Mi0xLjA3MSAxLjg1Nkg5Ljg1N0w4IDE2bC0xLjg1NS0xLjA3M0g0bC0xLjA3Mi0xLjg1NkwxLjA3MiAxMlY5Ljg1N0wwIDhsMS4wNzItMS44NTZWNGwxLjg1Ny0xLjA3MyAxLjA3Mi0xLjg1NGgyLjE0NUw4IDBabTIuOTEgNi4zODVINC43OTZWMTJoMS4yNDZ2LS40NTFoNC4wMjZ2LjQzNWgxLjI0N1Y5LjE5Nkg2LjA0M3YtLjUxNWg0Ljg2NlY2LjM4NVptLS44NCAzLjY4MXYuNjEzSDYuMDQydi0uNjEzaDQuMDI2Wk05LjcwNSA3LjI0di41ODhINi4wNDN2LS41ODhoMy42NjNaTTguNjE1IDRsLTEuNDguMTM3Yy4wNTUuMTMzLjEyLjI4NC4xOTIuNDUzbC4wNzYuMTc1SDR2MS40MjZoMS4xOTV2LS40ODNoNS42MXYuNDgzSDEyVjQuNzY1SDguODgzYy0uMDc4LS4yMy0uMTQ4LS40My0uMjEtLjYwMkw4LjYxNiA0WiIvPjwvZGVmcz48ZyBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxtYXNrIGlkPSJiIiBmaWxsPSIjZmZmIj48dXNlIHhsaW5rOmhyZWY9IiNhIi8+PC9tYXNrPjx1c2UgZmlsbD0iIzhEQzlGRiIgZmlsbC1ydWxlPSJub256ZXJvIiB4bGluazpocmVmPSIjYSIvPjxjaXJjbGUgY3g9Ii41IiBjeT0iLTMuNSIgcj0iMTYuNSIgZmlsbD0iI0MxRTJGRiIgZmlsbC1ydWxlPSJub256ZXJvIiBtYXNrPSJ1cmwoI2IpIi8+PGNpcmNsZSBjeD0iLS41IiBjeT0iLTQuNSIgcj0iMTIuNSIgZmlsbD0iI0VFRjdGRiIgZmlsbC1ydWxlPSJub256ZXJvIiBtYXNrPSJ1cmwoI2IpIi8+PC9nPjwvc3ZnPg==",Ao=Object.defineProperty,Xi=Object.getOwnPropertySymbols,qi=Object.prototype.hasOwnProperty,ui=Object.prototype.propertyIsEnumerable,no=(ft,bt,wt)=>bt in ft?Ao(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,Io=(ft,bt)=>{for(var wt in bt||(bt={}))qi.call(bt,wt)&&no(ft,wt,bt[wt]);if(Xi)for(var wt of Xi(bt))ui.call(bt,wt)&&no(ft,wt,bt[wt]);return ft};const Ui=ft=>React.createElement("svg",Io({width:22,height:20,xmlns:"http://www.w3.org/2000/svg"},ft),React.createElement("title",null,"\u5927\u70B9\u8D5E"),React.createElement("g",{fillRule:"nonzero",fill:"none"},React.createElement("path",{d:"M3.566 19.08V8.134c0-.443-.318-.802-.71-.802H1.34c-.73 0-1.322.67-1.322 1.496v9.558c0 .827.593 1.496 1.322 1.496h1.515c.392 0 .71-.36.71-.802Z",fill:"#A3D3FF"}),React.createElement("path",{d:"M4.585 19.303V7.9c0-.263.188-.495.459-.559.955-.229 3.147-1.049 4.08-3.848.567-2.451 1.182-3.607 3.008-3.469 1.826.139 1.948 1.804 1.948 2.312v3.93s-.148.602.468.649c.617.046 5.426 0 5.426 0s2.639-.042 1.8 3.031c-.73 2.673-2.173 6.974-2.537 8.05a2.324 2.324 0 0 1-.324.626c-.353.483-1.094 1.258-2.228 1.258H5.201c-.341.002-.616-.257-.616-.577Z",fill:"#FFF"})));var Ho="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMjAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgZmlsbC1ydWxlPSJub256ZXJvIiBmaWxsPSJub25lIj48cGF0aCBkPSJNMy41NjYgMTkuMDhWOC4xMzRjMC0uNDQzLS4zMTgtLjgwMi0uNzEtLjgwMkgxLjM0Yy0uNzMgMC0xLjMyMi42Ny0xLjMyMiAxLjQ5NnY5LjU1OGMwIC44MjcuNTkzIDEuNDk2IDEuMzIyIDEuNDk2aDEuNTE1Yy4zOTIgMCAuNzEtLjM2LjcxLS44MDJaIiBmaWxsPSIjQTNEM0ZGIi8+PHBhdGggZD0iTTQuNTg1IDE5LjMwM1Y3LjljMC0uMjYzLjE4OC0uNDk1LjQ1OS0uNTU5Ljk1NS0uMjI5IDMuMTQ3LTEuMDQ5IDQuMDgtMy44NDguNTY3LTIuNDUxIDEuMTgyLTMuNjA3IDMuMDA4LTMuNDY5IDEuODI2LjEzOSAxLjk0OCAxLjgwNCAxLjk0OCAyLjMxMnYzLjkzcy0uMTQ4LjYwMi40NjguNjQ5Yy42MTcuMDQ2IDUuNDI2IDAgNS40MjYgMHMyLjYzOS0uMDQyIDEuOCAzLjAzMWMtLjczIDIuNjczLTIuMTczIDYuOTc0LTIuNTM3IDguMDVhMi4zMjQgMi4zMjQgMCAwIDEtLjMyNC42MjZjLS4zNTMuNDgzLTEuMDk0IDEuMjU4LTIuMjI4IDEuMjU4SDUuMjAxYy0uMzQxLjAwMi0uNjE2LS4yNTctLjYxNi0uNTc3WiIgZmlsbD0iI0ZGRiIvPjwvZz48L3N2Zz4=",xo={flex_box_center:"flex_box_center___Fl60v",flex_space_between:"flex_space_between___bECvI",flex_box_vertical_center:"flex_box_vertical_center___NasnL",flex_box_center_end:"flex_box_center_end___llsAF",flex_box_column:"flex_box_column___KaTPF",discuss:"discuss___fk6PE",reply:"reply___pOmly",pagination:"pagination___qEsHX"},Oo=be(77019),Vi=be(5269),Wo={flex_box_center:"flex_box_center___qGmgZ",flex_space_between:"flex_space_between___PeDhE",flex_box_vertical_center:"flex_box_vertical_center___avs2o",flex_box_center_end:"flex_box_center_end___bpXQB",flex_box_column:"flex_box_column___bc5wd",discussItem:"discussItem___zcesj",wrap:"wrap___ezVW4",list:"list___EEOWp",btns:"btns___Niwl7",secondLevelDiscuss:"secondLevelDiscuss___TXG1b",line:"line___ejh2a",thirdlyLevelDiscuss:"thirdlyLevelDiscuss___HRI5Q"},za=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())});const Yo=({id:ft,cb:bt})=>{const[wt,Vn]=(0,ce.useState)("");return ce.createElement("aside",{className:"mt10"},ce.createElement(Bn.Z,{defaultValue:wt,id:"writeForumsReviewId",onChange:In=>{Vn(In)},placeholder:"\u6211\u8981\u56DE\u590D...",height:240}),ce.createElement(Oo.Z,null,ce.createElement(Vi.Z,{flex:"1"}),ce.createElement(Vi.Z,null,ce.createElement(Ve.ZP,{type:"primary",size:"middle",onClick:()=>za(void 0,null,function*(){wt===""?te.ZP.error("\u8BF7\u8F93\u5165\u5185\u5BB9"):bt(ft,wt)})},"\u53D1\u9001"))))},la=({data:ft})=>{var bt;return ce.createElement("div",{className:Wo.thirdlyLevelDiscuss},ce.createElement("span",{className:"c-grey-333"},ce.createElement("span",{className:"font 14 c-light-primary"},(bt=ft==null?void 0:ft.author)==null?void 0:bt.name),"@",ce.createElement("span",{className:"font 14 c-light-primary"},ft==null?void 0:ft.parent_name),":"),ce.createElement(Le.Z,{value:ft==null?void 0:ft.content}))},Zo=({data:ft,onReplyDiscuss:bt,thirdlyReply:wt,setThirdlyReply:Vn})=>{var In,pn,An,xn;const On=(0,Zn.eY)();return console.log(On,"user"),ce.createElement("div",{className:Wo.list},ce.createElement("img",{src:z.Z.IMG_SERVER+"/images/"+((In=ft==null?void 0:ft.author)==null?void 0:In.image_url)}),ce.createElement("div",{className:Wo.wrap},ce.createElement("div",{className:"font14",style:{marginBottom:6}},ce.createElement("span",{className:"c-grey-333"},(pn=ft==null?void 0:ft.author)==null?void 0:pn.name),(On==null?void 0:On.login)!==((An=ft==null?void 0:ft.author)==null?void 0:An.login)&&ce.createElement("span",{onClick:()=>Vn(ft==null?void 0:ft.id),className:"c-grey-999 current",style:{float:"right"}},ce.createElement("i",{className:"iconfont icon-huifu3 mr3 font12"}),ce.createElement("span",null,"\u56DE\u590D"))),ce.createElement(Le.Z,{value:ft==null?void 0:ft.content}),(xn=ft==null?void 0:ft.children)==null?void 0:xn.map(qn=>ce.createElement(la,{key:qn.id,data:qn})),wt===(ft==null?void 0:ft.id)&&ce.createElement("div",null,ce.createElement(Yo,{id:ft==null?void 0:ft.id,cb:bt}),ce.createElement("div",{style:{textAlign:"end",paddingTop:20},onClick:()=>Vn(null),className:"c-light-primary current"},ce.createElement("i",{style:{transform:"scale(0.7)",display:"inline-block"},className:"iconfont icon-shouqi font12"}),"\u6536\u8D77\u56DE\u590D")),ce.createElement("div",{className:Wo.line})))};var qa=({data:ft,onReplyDiscuss:bt,secondReply:wt,setSecondReply:Vn,thirdlyReply:In,setThirdlyReply:pn,onPlusDiscuss:An})=>{var xn,On,qn,ci;const[Pr,gi]=(0,ce.useState)(!1);return console.log(ft,"data"),ce.createElement("div",{className:Wo.discussItem},ce.createElement("div",{className:Wo.list},ce.createElement("img",{src:z.Z.IMG_SERVER+"/images/"+((xn=ft==null?void 0:ft.author)==null?void 0:xn.image_url)}),ce.createElement("div",{className:Wo.wrap},ce.createElement("div",{className:"font14",style:{marginBottom:6}},ce.createElement("span",{className:"c-grey-333 mr30"},(On=ft==null?void 0:ft.author)==null?void 0:On.name),ce.createElement("span",{className:"c-grey-999"},ft==null?void 0:ft.time)),ce.createElement(Le.Z,{value:ft==null?void 0:ft.content}),ce.createElement("div",{className:Wo.btns},ce.createElement("div",{onClick:()=>An(ft==null?void 0:ft.id),className:ft!=null&&ft.user_praise?"c-light-primary":"c-grey-999"},ce.createElement("i",{className:"iconfont icon-xiaodianzan2 mr3"}),ce.createElement("span",null,ft==null?void 0:ft.praise_count)),ce.createElement("div",{onClick:()=>{var kr;((kr=ft==null?void 0:ft.children)==null?void 0:kr.length)!==0&&(Vn(null),gi(!Pr))},style:{color:Pr?"#0152d9":"#999999"}},ce.createElement("i",{className:"iconfont icon-xiaopinglun2 mr3"}),ce.createElement("span",null,Pr?"\u6536\u8D77\u8BC4\u8BBA":(qn=ft==null?void 0:ft.children)==null?void 0:qn.length)),ce.createElement("div",{onClick:()=>{gi(!1),Vn(wt===(ft==null?void 0:ft.id)?null:ft==null?void 0:ft.id)},style:{color:wt===(ft==null?void 0:ft.id)?"#0152d9":"#999999"}},ce.createElement("i",{className:"iconfont icon-huifu3 mr3"}),ce.createElement("span",null,wt===(ft==null?void 0:ft.id)?"\u6536\u8D77\u56DE\u590D":"\u56DE\u590D"))),wt===(ft==null?void 0:ft.id)&&ce.createElement(Yo,{id:ft==null?void 0:ft.id,cb:(kr,yi)=>{bt(kr,yi),gi(!0)}}),Pr&&ce.createElement("div",{className:Wo.secondLevelDiscuss},(ci=ft==null?void 0:ft.children)==null?void 0:ci.map(kr=>ce.createElement(Zo,{thirdlyReply:In,setThirdlyReply:pn,key:kr.id,data:kr,onReplyDiscuss:bt}))))))},ba=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())}),Ma=({identifier:ft,active:bt,onOk:wt})=>{const[Vn,In]=(0,ce.useState)(""),[pn,An]=(0,ce.useState)(1),[xn,On]=(0,ce.useState)([]),[qn,ci]=(0,ce.useState)(0),[Pr,gi]=(0,ce.useState)(null),[kr,yi]=(0,ce.useState)(null);(0,ce.useEffect)(()=>{Br(1),An(1)},[bt]);const Br=ii=>ba(void 0,null,function*(){const Ti=yield Lt({container_type:"QuestionSolutionArticle",container_identifier:bt,limit:5,page:ii});Ti!=null&&Ti.comments&&(On((Ti==null?void 0:Ti.comments)||[]),An(ii),ci(Ti==null?void 0:Ti.disscuss_count))}),zi=()=>ba(void 0,null,function*(){if(Vn===""){te.ZP.error("\u8BF7\u8F93\u5165\u5185\u5BB9");return}const ii=yield wn({comments:{content:Vn},container_type:"QuestionSolutionArticle",container_identifier:bt});ii!=null&&ii.discuss&&(In(""),Br(pn),wt())}),ri=(ii,Ti,er)=>ba(void 0,null,function*(){const Bi=yield sn({container_type:"QuestionSolutionArticle",container_identifier:bt,comments:{content:Ti,parent_id:ii}});gi(null),yi(null),Br(pn)}),ki=ii=>ba(void 0,null,function*(){const Ti=yield Kt(ii);Br(pn)}),Zi=ii=>{An(ii),Br(ii)};return ce.createElement("div",{className:xo.discuss},ce.createElement("aside",{className:xo.reply,style:{borderWidth:qn?1:0}},ce.createElement(Bn.Z,{defaultValue:Vn,id:"writeForumsReviewId",onChange:ii=>{In(ii)},placeholder:"\u6211\u8981\u56DE\u590D...",height:240}),ce.createElement(Oo.Z,null,ce.createElement(Vi.Z,{flex:"1"}),ce.createElement(Vi.Z,null,ce.createElement(Ve.ZP,{type:"primary",size:"middle",onClick:()=>zi()},"\u53D1\u9001")))),xn==null?void 0:xn.map(ii=>ce.createElement(qa,{secondReply:Pr,setSecondReply:gi,thirdlyReply:kr,setThirdlyReply:yi,key:ii.id,data:ii,onReplyDiscuss:ri,onPlusDiscuss:ki})),ce.createElement(dt.Z,{className:xo.pagination,showTotal:ii=>ce.createElement("span",{style:{color:"#656F87"}},"\u5171",ce.createElement("span",{className:"c-light-primary"},ii),"\u6761\u6570\u636E"),current:pn,onChange:Zi,total:qn,showSizeChanger:!1,showQuickJumper:!0,hideOnSinglePage:!0,pageSize:5}))},Ha=be(93152),Ra=Object.defineProperty,pa=Object.getOwnPropertySymbols,Wa=Object.prototype.hasOwnProperty,Ja=Object.prototype.propertyIsEnumerable,Sa=(ft,bt,wt)=>bt in ft?Ra(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,wa=(ft,bt)=>{for(var wt in bt||(bt={}))Wa.call(bt,wt)&&Sa(ft,wt,bt[wt]);if(pa)for(var wt of pa(bt))Ja.call(bt,wt)&&Sa(ft,wt,bt[wt]);return ft},ua=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())}),Ji=({active:ft,identifier:bt,onAssist:wt,onEdit:Vn,onArticlesSkip:In,onClose:pn,onOk:An,onDelete:xn,detailsIndex:On,btnShowStatus:qn})=>{var ci,Pr,gi,kr,yi,Br,zi,ri,ki,Zi;const[ii,Ti]=(0,ce.useState)(!0),[er,Bi]=(0,ce.useState)({});(0,ce.useEffect)(()=>{ft&&Si()},[ft,On]);const Si=(li=!0)=>ua(void 0,null,function*(){li&&Ti(!0);const Sr=yield(0,E.wO)(bt,{active:ft});(Sr==null?void 0:Sr.status)===0&&Bi((Sr==null?void 0:Sr.data)||{}),Ti(!1)}),Mi=li=>ua(void 0,null,function*(){const Sr=yield(0,E.qe)(bt,wa({active:ft},li));(Sr==null?void 0:Sr.status)===0&&(Si(!1),An())}),No=li=>ua(void 0,null,function*(){(yield(0,E.Rg)(bt,{active:li==null?void 0:li.id})).status===0&&(Si(!1),An())}),mr=li=>{le.default.confirm({centered:!0,width:500,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u63D0\u793A",icon:null,className:"custom-modal-divider",content:"\u786E\u8BA4\u8981\u5220\u9664\u8BE5\u9898\u89E3\u5417?",onOk:()=>xn(li)})},Gi=()=>{Si(!1),An()};return ce.createElement("div",{className:hi.listDetails},ce.createElement(ao.Z,{className:"pt20 pl20 pr20",loading:ii,active:!0,paragraph:{rows:5}},ce.createElement("div",{className:hi.head},ce.createElement("div",{className:hi.name},ce.createElement("div",{title:er==null?void 0:er.name,className:hi.title},er==null?void 0:er.name),(er==null?void 0:er.is_authority)&&ce.createElement("div",{className:hi.b},"\u5B98\u65B9"),(er==null?void 0:er.is_excellent)&&ce.createElement("div",{className:hi.a},"\u7CBE\u9009")),ce.createElement("div",{className:hi.tag},ce.createElement("img",{src:z.Z.IMG_SERVER+"/images/"+(er==null?void 0:er.image_url)}),ce.createElement("div",{className:"c-grey-333 ml5 mr20 font14"},er==null?void 0:er.username),ce.createElement("div",{style:{display:"inline-block",marginBottom:-2},className:"c-grey-999 mr20 font12"},"\u53D1\u5E03\u4E8E",Ae()(er==null?void 0:er.created_at).format("YYYY-MM-DD")),ce.createElement("span",null,ce.createElement("img",{src:jn}),ce.createElement("span",null,er==null?void 0:er.praises_count)),ce.createElement("span",null,ce.createElement("img",{src:xi}),ce.createElement("span",null,er==null?void 0:er.discusses_count)),ce.createElement("span",null,ce.createElement("img",{src:$r}),ce.createElement("span",null,er==null?void 0:er.viewed_count)),ce.createElement("div",{className:hi.btn},((0,Zn.Ny)()||(er==null?void 0:er.is_self))&&ce.createElement(ce.Fragment,null,ce.createElement(Ve.ZP,{onClick:()=>mr(er),type:"primary",ghost:!0},"\u5220\u9664"),ce.createElement(Ve.ZP,{onClick:()=>Vn(er),type:"primary",ghost:!0},"\u7F16\u8F91")),(0,Zn.Ny)()&&ce.createElement(Ve.ZP,{onClick:()=>Mi({is_authority:!(er!=null&&er.is_authority)}),type:"primary"},ce.createElement("img",{src:Oi}),er!=null&&er.is_authority?"\u53D6\u6D88":"\u8BBE\u4E3A","\u5B98\u65B9"),(0,Zn.Ny)()&&ce.createElement(Ve.ZP,{onClick:()=>Mi({is_excellent:!(er!=null&&er.is_excellent)}),type:"primary"},ce.createElement("img",{src:Fi}),er!=null&&er.is_excellent?"\u53D6\u6D88":"\u8BBE\u4E3A","\u7CBE\u9009")))),ce.createElement("div",{className:hi.scroll},((Pr=(ci=er==null?void 0:er.videos)==null?void 0:ci[0])==null?void 0:Pr.id)&&ce.createElement("div",{className:hi.video},ce.createElement(ee.Z,{tip:"\u6B63\u5728\u8F6C\u7801\uFF0C\u8BF7\u7A0D\u7B49...",spinning:!((kr=(gi=er==null?void 0:er.videos)==null?void 0:gi[0])!=null&&kr.transcoded)},ce.createElement(Ha.Z,{poster:(Br=(yi=er==null?void 0:er.videos)==null?void 0:yi[0])==null?void 0:Br.cover_url,src:((ri=(zi=er==null?void 0:er.videos)==null?void 0:zi[0])==null?void 0:ri.play_url)||"",videoId:(Zi=(ki=er==null?void 0:er.videos)==null?void 0:ki[0])==null?void 0:Zi.id,logWatchHistory:()=>{}}))),ce.createElement(Le.Z,{className:hi.html,value:(er==null?void 0:er.content)||""}),ce.createElement("div",{onClick:()=>No(er),className:hi.g},ce.createElement("img",{className:"mr10",src:(er!=null&&er.user_liker,Ho)}),ce.createElement("span",null,er==null?void 0:er.praises_count)),ce.createElement(Ma,{onOk:Gi,active:ft,identifier:bt})),ce.createElement("div",{className:hi.btns},ce.createElement(Ve.ZP,{onClick:()=>pn(),type:"primary",ghost:!0},"\u5173\u95ED"),qn[0]&&ce.createElement(Ve.ZP,{onClick:li=>In(li,"prev"),style:{marginLeft:20},type:"primary"},"\u4E0A\u4E00\u9898\u89E3"),qn[1]&&ce.createElement(Ve.ZP,{onClick:li=>In(li,"next"),style:{marginLeft:20},type:"primary"},"\u4E0B\u4E00\u9898\u89E3"))))},vi=Object.defineProperty,si=Object.getOwnPropertySymbols,ro=Object.prototype.hasOwnProperty,Qi=Object.prototype.propertyIsEnumerable,io=(ft,bt,wt)=>bt in ft?vi(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,co=(ft,bt)=>{for(var wt in bt||(bt={}))ro.call(bt,wt)&&io(ft,wt,bt[wt]);if(si)for(var wt of si(bt))Qi.call(bt,wt)&&io(ft,wt,bt[wt]);return ft};const na=ft=>React.createElement("svg",co({xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:16,height:16},ft),React.createElement("defs",null,React.createElement("path",{id:"a_svg__a",d:"M13.727 0C14.983 0 16 .895 16 2v12c0 1.105-1.017 2-2.273 2H2.273C1.017 16 0 15.105 0 14V2C0 .895 1.017 0 2.273 0h11.454ZM7.464 11H2.955c-.266 0-.513.19-.646.5s-.133.69 0 1c.133.31.38.5.646.5h4.509c.411 0 .745-.448.745-1s-.334-1-.745-1Zm4-3.5H2.955c-.411 0-.745.448-.745 1s.334 1 .745 1h8.509c.412 0 .746-.448.746-1s-.334-1-.746-1ZM3.71 2.75a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3Z"})),React.createElement("g",{fill:"none",fillRule:"evenodd"},React.createElement("mask",{id:"a_svg__b",fill:"#fff"},React.createElement("use",{xlinkHref:"#a_svg__a"})),React.createElement("use",{fill:"#7DC1FF",fillRule:"nonzero",xlinkHref:"#a_svg__a"}),React.createElement("circle",{cx:1.5,cy:.5,r:16.5,fill:"#A3D3FF",fillRule:"nonzero",mask:"url(#a_svg__b)"}),React.createElement("ellipse",{cx:1.5,cy:-.5,fill:"#C1E2FF",fillRule:"nonzero",mask:"url(#a_svg__b)",rx:12.5,ry:12}),React.createElement("ellipse",{cx:-2.5,cy:-4,fill:"#EEF7FF",fillRule:"nonzero",mask:"url(#a_svg__b)",rx:12.5,ry:12})));var Go="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMTYiIGhlaWdodD0iMTYiPjxkZWZzPjxwYXRoIGlkPSJhIiBkPSJNMTMuNzI3IDBDMTQuOTgzIDAgMTYgLjg5NSAxNiAydjEyYzAgMS4xMDUtMS4wMTcgMi0yLjI3MyAySDIuMjczQzEuMDE3IDE2IDAgMTUuMTA1IDAgMTRWMkMwIC44OTUgMS4wMTcgMCAyLjI3MyAwaDExLjQ1NFpNNy40NjQgMTFIMi45NTVjLS4yNjYgMC0uNTEzLjE5LS42NDYuNXMtLjEzMy42OSAwIDFjLjEzMy4zMS4zOC41LjY0Ni41aDQuNTA5Yy40MTEgMCAuNzQ1LS40NDguNzQ1LTFzLS4zMzQtMS0uNzQ1LTFabTQtMy41SDIuOTU1Yy0uNDExIDAtLjc0NS40NDgtLjc0NSAxcy4zMzQgMSAuNzQ1IDFoOC41MDljLjQxMiAwIC43NDYtLjQ0OC43NDYtMXMtLjMzNC0xLS43NDYtMVpNMy43MSAyLjc1YTEuNSAxLjUgMCAxIDAgMCAzIDEuNSAxLjUgMCAwIDAgMC0zWiIvPjwvZGVmcz48ZyBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxtYXNrIGlkPSJiIiBmaWxsPSIjZmZmIj48dXNlIHhsaW5rOmhyZWY9IiNhIi8+PC9tYXNrPjx1c2UgZmlsbD0iIzdEQzFGRiIgZmlsbC1ydWxlPSJub256ZXJvIiB4bGluazpocmVmPSIjYSIvPjxjaXJjbGUgY3g9IjEuNSIgY3k9Ii41IiByPSIxNi41IiBmaWxsPSIjQTNEM0ZGIiBmaWxsLXJ1bGU9Im5vbnplcm8iIG1hc2s9InVybCgjYikiLz48ZWxsaXBzZSBjeD0iMS41IiBjeT0iLS41IiBmaWxsPSIjQzFFMkZGIiBmaWxsLXJ1bGU9Im5vbnplcm8iIG1hc2s9InVybCgjYikiIHJ4PSIxMi41IiByeT0iMTIiLz48ZWxsaXBzZSBjeD0iLTIuNSIgY3k9Ii00IiBmaWxsPSIjRUVGN0ZGIiBmaWxsLXJ1bGU9Im5vbnplcm8iIG1hc2s9InVybCgjYikiIHJ4PSIxMi41IiByeT0iMTIiLz48L2c+PC9zdmc+",ca=be(59477),$i=be(89489),go=Object.defineProperty,Fo=Object.defineProperties,Xo=Object.getOwnPropertyDescriptors,Ia=Object.getOwnPropertySymbols,ds=Object.prototype.hasOwnProperty,fs=Object.prototype.propertyIsEnumerable,da=(ft,bt,wt)=>bt in ft?go(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,yo=(ft,bt)=>{for(var wt in bt||(bt={}))ds.call(bt,wt)&&da(ft,wt,bt[wt]);if(Ia)for(var wt of Ia(bt))fs.call(bt,wt)&&da(ft,wt,bt[wt]);return ft},Co=(ft,bt)=>Fo(ft,Xo(bt)),Eo=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())}),Qa=({identifier:ft,tabStatus:bt,setFilterListTotal:wt,setListStatus:Vn})=>{const In={page:1,limit:10,total:0,search:"",save_search:"",sort_by:"updated_at",sort_direction:null};let[pn,An]=(0,ce.useState)(yo({},In));const[xn,On]=(0,ce.useState)(!1),[qn,ci]=(0,ce.useState)(0),[Pr,gi]=(0,ce.useState)(1),[kr,yi]=(0,ce.useState)(null),[Br,zi]=(0,ce.useState)([]),[ri,ki]=(0,ce.useState)([!0,!0]),[Zi,ii]=(0,ce.useState)(0),Ti=(0,ce.useRef)(null);(0,ce.useEffect)(()=>{Fr()},[bt]),(0,ce.useEffect)(()=>{er()},[kr]),(0,ce.useEffect)(()=>{Si(yo({},In)),Fr()},[ft]),(0,ce.useEffect)(()=>(window.addEventListener("resize",Bi),Vn(Zi),()=>{window.removeEventListener("resize",Bi)}),[Zi]);const er=()=>Eo(void 0,null,function*(){if(!kr){ki([!0,!0]);return}const oi=[!0,!0],Ai=Br==null?void 0:Br.findIndex(oo=>oo.id===kr);Ai===0&&pn.page===1&&(oi[0]=!1),(pn.page-1)*pn.limit+(Ai+1)===pn.total&&(oi[1]=!1),ki(oi)}),Bi=()=>{var oi;if(Zi){const Ai=window.innerWidth-((oi=Ti.current)==null?void 0:oi.clientWidth);ci(Ai)}},Si=oi=>Eo(void 0,null,function*(){var Ai,oo,Ba;On(!0);const jo=yield(0,E.WH)(ft,oi);return(jo==null?void 0:jo.status)===0&&(zi(((Ai=jo==null?void 0:jo.data)==null?void 0:Ai.articles)||[]),An(Co(yo({},oi),{total:(oo=jo==null?void 0:jo.data)==null?void 0:oo.articles_count})),wt((Ba=jo==null?void 0:jo.data)==null?void 0:Ba.articles_count)),On(!1),jo}),Mi=()=>{(pn==null?void 0:pn.sort_direction)===null?pn.sort_direction="asc":(pn==null?void 0:pn.sort_direction)==="asc"?pn.sort_direction="desc":(pn==null?void 0:pn.sort_direction)==="desc"&&(pn.sort_direction=null),pn.page=1,Fr(),An(yo({},pn)),Si(pn)},No=()=>{pn.page=1,pn.search=pn==null?void 0:pn.save_search,Fr(),An(yo({},pn)),Si(pn)},mr=()=>{var oi;const Ai=document.getElementsByClassName("btn-resize");Ai[0].style.visibility="hidden";const oo=window.innerWidth-((oi=Ti.current)==null?void 0:oi.clientWidth);ci(oo)},Gi=()=>{mr(),ii(1)},li=oi=>{mr(),yi(oi==null?void 0:oi.id),ii(3)},Sr=oi=>{mr(),yi(oi==null?void 0:oi.id),ii(2)},Fr=()=>{const oi=document.getElementsByClassName("btn-resize");oi[0].style.visibility="visible",ci(0),ii(0),yi(null)},mi=oi=>{ii(3),yi(oi),pn.page=1,An(yo({},pn)),Si(pn)},Mr=oi=>{ii(3),yi(oi),An(yo({},pn)),Si(pn)},qo=oi=>{An(yo({},pn)),Si(pn)},so=oi=>Eo(void 0,null,function*(){(yield(0,E.Rg)(ft,{active:oi==null?void 0:oi.id})).status===0&&(Si(pn),gi(Pr+1))}),oa=oi=>Eo(void 0,null,function*(){(yield(0,E.rL)(ft,{active:oi==null?void 0:oi.id})).status===0&&(Si(pn),gi(Pr+1))}),os=oi=>Eo(void 0,null,function*(){(yield(0,E.de)(ft,{active:oi==null?void 0:oi.id})).status===0&&(Fr(),Si(pn))}),aa=oi=>{pn.page=oi,An(yo({},pn)),Si(pn)},ga=(oi,Ai)=>Eo(void 0,null,function*(){var oo,Ba,jo,Cs;const Jo=Br==null?void 0:Br.findIndex(lo=>lo.id===kr);if(console.log(Jo,Ai,22),Ai==="prev"){if(Jo===void 0){te.ZP.warning("\u4E0A\u4E00\u9898\u89E3\u4E0D\u5B58\u5728");return}if(Jo===0){if(pn.page===1){te.ZP.warning("\u4E0A\u4E00\u9898\u89E3\u4E0D\u5B58\u5728");return}if(pn.page!==1){pn.page=pn.page-1,An(yo({},pn));const lo=yield Si(pn);if((lo==null?void 0:lo.status)===0){const Fa=(jo=lo==null?void 0:lo.data)==null?void 0:jo.articles[((Ba=(oo=lo==null?void 0:lo.data)==null?void 0:oo.articles)==null?void 0:Ba.length)-1];yi(Fa==null?void 0:Fa.id),console.log(oi.target,555)}}}else{const lo=Br[Jo-1];yi(lo==null?void 0:lo.id)}}if(Ai==="next"){if(Jo===void 0){te.ZP.warning("\u4E0B\u4E00\u9898\u89E3\u4E0D\u5B58\u5728");return}if((pn.page-1)*pn.limit+(Jo+1)===pn.total){te.ZP.warning("\u4E0B\u4E00\u9898\u89E3\u4E0D\u5B58\u5728");return}if(Jo+1===pn.limit){pn.page=pn.page+1,An(yo({},pn));const lo=yield Si(pn);if((lo==null?void 0:lo.status)===0){const Fa=(Cs=lo==null?void 0:lo.data)==null?void 0:Cs.articles[0];yi(Fa==null?void 0:Fa.id)}}else{const lo=Br[Jo+1];yi(lo==null?void 0:lo.id)}}});return ce.createElement("div",{className:kt.wrap,ref:Ti},ce.createElement("div",{className:kt.head},ce.createElement("div",{className:kt.sort,onClick:Mi},ce.createElement("span",null,"\u6700\u65B0"),ce.createElement("aside",null,ce.createElement(ca.Z,{style:{color:(pn==null?void 0:pn.sort_direction)==="asc"?"#0152d9":"#bfbfbf"}}),ce.createElement($i.Z,{style:{color:(pn==null?void 0:pn.sort_direction)==="desc"?"#0152d9":"#bfbfbf"}}))),ce.createElement(Ge.default.Search,{value:pn.save_search,className:kt["oj-width-input"],placeholder:"\u641C\u7D22\u9898\u89E3",onChange:oi=>{pn.save_search=oi.target.value,An(yo({},pn))},onSearch:No}),ce.createElement("div",{onClick:Gi,className:kt.btn},ce.createElement("img",{src:Go}),"\u5199\u9898\u89E3")),ce.createElement("div",{className:kt.listWarp},ce.createElement(ee.Z,{spinning:xn,className:"mt20"},Br==null?void 0:Br.map((oi,Ai)=>{let oo=!0;return Ai+1===Br.length&&Ai!==0&&(oo=!1),ce.createElement(Wi,{active:kr,key:oi.id,data:oi,showLine:oo,onClick:li,onAssist:so,onHide:oa})}),(Br==null?void 0:Br.length)===0&&ce.createElement(Ke.Z,{customText:"\u6682\u65F6\u8FD8\u6CA1\u6709\u76F8\u5173\u6570\u636E\u54E6!"}))),ce.createElement(dt.Z,{className:kt.pagination,showTotal:oi=>ce.createElement("span",{style:{color:"#656F87"}},"\u5171",ce.createElement("span",{className:"c-light-primary"},oi),"\u6761\u6570\u636E"),total:pn.total,showSizeChanger:!1,current:pn==null?void 0:pn.page,onChange:aa,hideOnSinglePage:!0,showQuickJumper:!0}),Zi>0&&ce.createElement("div",{className:kt.fixedRight,style:{width:qn}},Zi===1&&ce.createElement(Jr,{identifier:ft,onClose:Fr,onOk:mi}),Zi===2&&ce.createElement(Jr,{active:kr,identifier:ft,onClose:Fr,onOk:Mr}),Zi===3&&ce.createElement(Ji,{btnShowStatus:ri,onArticlesSkip:ga,detailsIndex:Pr,active:kr,identifier:ft,onClose:Fr,onOk:qo,onEdit:Sr,onAssist:so,onDelete:os})))},xa={flex_box_center:"flex_box_center___BbEkt",flex_space_between:"flex_space_between___v3cDl",flex_box_vertical_center:"flex_box_vertical_center___wUFLn",flex_box_center_end:"flex_box_center_end___Tdr08",flex_box_column:"flex_box_column___fYHlj",wrap:"wrap___UAZFM",head:"head___Nl6hk",title:"title___Ir573",content:"content___xUewa",list:"list___oi2ig",footer:"footer___V3bwQ"},_s=Object.defineProperty,Oa=Object.defineProperties,bs=Object.getOwnPropertyDescriptors,$a=Object.getOwnPropertySymbols,Ca=Object.prototype.hasOwnProperty,Ss=Object.prototype.propertyIsEnumerable,es=(ft,bt,wt)=>bt in ft?_s(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,ra=(ft,bt)=>{for(var wt in bt||(bt={}))Ca.call(bt,wt)&&es(ft,wt,bt[wt]);if($a)for(var wt of $a(bt))Ss.call(bt,wt)&&es(ft,wt,bt[wt]);return ft},Za=(ft,bt)=>Oa(ft,bs(bt)),Ea=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())}),ts=({visible:ft,onVisible:bt,value:wt,onChange:Vn,setIndex:In})=>{var pn;const An={page:1,per_page:30,total:0,tag_discipline_id:[],search:"",save_search:"",difficulty:null};let[xn,On]=(0,ce.useState)(An);const[qn,ci]=(0,ce.useState)([]),[Pr,gi]=(0,ce.useState)([]),[kr,yi]=(0,ce.useState)(!1),Br=(0,ce.useRef)([]),zi=(0,ce.useRef)(null),ri=(0,ue.useParams)();(0,ce.useEffect)(()=>(ri!=null&&ri.id&&(zi.current=setInterval(()=>{ki(30)},3e4)),()=>{clearInterval(zi.current)}),[]);const ki=mr=>Ea(void 0,null,function*(){const Gi=yield(0,E.uc)(ri==null?void 0:ri.id,{practice_time:mr})});(0,ce.useEffect)(()=>{Si(xn),er()},[]),(0,ce.useEffect)(()=>(window.addEventListener("click",ii),()=>{window.removeEventListener("click",ii)}),[ri==null?void 0:ri.save_identifier,ft]),(0,ce.useEffect)(()=>{const mr=Br.current.findIndex(mi=>mi.identifier===(ri==null?void 0:ri.save_identifier)),Gi=Br.current[mr-1],li=Br.current[mr+1],Sr=document.getElementById("oj-prev"),Fr=document.getElementById("oj-next");Gi?Sr.style.display="block":Sr.style.display="none",li?Fr.style.display="block":Fr.style.display="none"},[ri==null?void 0:ri.save_identifier,Br.current]);const Zi=(mr,Gi)=>{if(mr.id===Gi)return mr;for(let li=0,Sr=mr;Sr=Sr.parentNode;li++){if(Sr.id===Gi)return Sr;if(Sr==document.documentElement)return!1}},ii=mr=>Ea(void 0,null,function*(){!Zi(mr.target,"oj-drawer")&&ft&&bt(!1);const Gi=Br.current.findIndex(Fr=>Fr.identifier===(ri==null?void 0:ri.save_identifier)),li=Br.current[Gi-1],Sr=Br.current[Gi+1];if(mr.target.id==="oj-prev"){if(!li||Gi===-1){te.ZP.warning("\u4E0A\u4E00\u9898\u4E0D\u5B58\u5728");return}mr.target.style.pointerEvents="none",mr.target.style.cursor="not-allowed",yield Mi(li==null?void 0:li.identifier),In("0"),setTimeout(()=>{mr.target.style.pointerEvents="auto",mr.target.style.cursor="pointer"},400)}if(mr.target.id==="oj-next"||mr.target.id==="oj-modal-next"){if(!Sr||Gi===-1){te.ZP.warning("\u4E0B\u4E00\u9898\u4E0D\u5B58\u5728");return}mr.target.style.pointerEvents="none",mr.target.style.cursor="not-allowed",yield Mi(Sr==null?void 0:Sr.identifier),In("0"),setTimeout(()=>{mr.target.style.pointerEvents="auto",mr.target.style.cursor="pointer"},400)}});(0,ce.useEffect)(()=>{Vn(ri==null?void 0:ri.save_identifier);const mr=Pr.findIndex(Gi=>Gi.some(li=>li.identifier===(ri==null?void 0:ri.save_identifier)));On(mr===-1?Za(ra({},xn),{page:1}):Za(ra({},xn),{page:mr+1}))},[ri==null?void 0:ri.save_identifier,Pr]);const Ti=mr=>{xn.page=1,xn.tag_discipline_id=mr,On(ra({},xn)),Si(xn)},er=()=>Ea(void 0,null,function*(){const mr=yield(0,Yt.ZP)("/api/tag_disciplines.json",{method:"get",params:{target:"practice",position:"index"}});ci(mr.tag_disciplines||[])}),Bi=mr=>{xn.page=1,xn.difficulty=typeof mr=="number"?mr:null,On(ra({},xn)),Si(xn)},Si=mr=>Ea(void 0,null,function*(){var Gi,li;yi(!0);const Sr=yield(0,E.KC)(mr);if(Sr!=null&&Sr.practices_list){for(var Fr=(Gi=Sr==null?void 0:Sr.practices_list)==null?void 0:Gi.length,mi=[],Mr=0;Mr<Fr;Mr+=xn==null?void 0:xn.per_page)mi.push((li=Sr==null?void 0:Sr.practices_list)==null?void 0:li.slice(Mr,Mr+(xn==null?void 0:xn.per_page)));On(Za(ra({},xn),{total:Sr==null?void 0:Sr.practices_count})),Br.current=(Sr==null?void 0:Sr.practices_list)||[],gi(mi)}yi(!1)}),Mi=(mr,Gi)=>Ea(void 0,null,function*(){const li=yield(0,Yt.ZP)(`/api/practices/${mr}/start`,{method:"get"});(li==null?void 0:li.status)===0&&ue.history.push(`/problems/${li==null?void 0:li.identifier}/oj/${mr}`)}),No=mr=>{xn.page=mr,On(ra({},xn))};return ce.createElement("div",{className:xa.wrap,id:"oj-drawer",style:{left:ft?0:-700}},ce.createElement("div",{className:xa.head},ce.createElement("div",{className:xa.title},"\u9898\u76EE\u5217\u8868"),ce.createElement(Ge.default.Search,{value:xn==null?void 0:xn.save_search,placeholder:"\u8BF7\u8F93\u5165\u9898\u76EE\u540D\u79F0\u641C\u7D22",style:{width:180,marginLeft:"auto",marginRight:10},onChange:mr=>{xn.save_search=mr.target.value,On(ra({},xn))},onSearch:()=>{xn.page=1,xn.search=xn.save_search,On(ra({},xn)),Si(xn)}}),ce.createElement(ne.default,{value:xn==null?void 0:xn.tag_discipline_id,style:{width:210},mode:"multiple",placeholder:"\u9009\u62E9\u77E5\u8BC6\u70B9",showSearch:!1,showArrow:!0,getPopupContainer:mr=>mr.parentNode,maxTagTextLength:2,maxTagCount:2,onChange:Ti},qn.map(mr=>ce.createElement(ne.default.Option,{key:mr.id,value:mr.id},mr.name))),ce.createElement(ne.default,{style:{width:70,marginLeft:10},allowClear:!0,placeholder:"\u96BE\u5EA6",getPopupContainer:mr=>mr.parentNode,value:xn==null?void 0:xn.difficulty,onChange:Bi},ce.createElement(ne.default.Option,{value:1},"\u7B80\u5355"),ce.createElement(ne.default.Option,{value:2},"\u9002\u4E2D"),ce.createElement(ne.default.Option,{value:3},"\u56F0\u96BE"))),ce.createElement("div",{className:xa.content},ce.createElement(ee.Z,{spinning:kr},(pn=Pr==null?void 0:Pr[xn.page-1])==null?void 0:pn.map(mr=>ce.createElement("div",{key:mr.identifier,className:xa.list,onClick:Gi=>Mi(mr.identifier,Gi)},ce.createElement("i",{style:{visibility:wt===mr.identifier?"visible":"hidden"},className:"iconfont icon-wancheng1 c-green-29b"}),ce.createElement("span",{style:{fontWeight:wt===mr.identifier?"bold":400,color:wt===mr.identifier?"#ffffff":"#bac4cd"},title:mr==null?void 0:mr.name},mr.name),(mr==null?void 0:mr.difficulty)===1&&ce.createElement("b",{style:{color:"#2FA34F"}},"\u7B80\u5355"),(mr==null?void 0:mr.difficulty)===2&&ce.createElement("b",{style:{color:"#0152d9"}},"\u9002\u4E2D"),(mr==null?void 0:mr.difficulty)===3&&ce.createElement("b",{style:{color:"#FA6400"}},"\u56F0\u96BE"))))),ce.createElement("div",{className:xa.footer},ce.createElement(dt.Z,{showTotal:mr=>ce.createElement("span",{style:{color:"#656F87"}},"\u5171",ce.createElement("span",{className:"c-light-primary"},mr),"\u6761\u6570\u636E"),total:xn.total,pageSize:xn==null?void 0:xn.per_page,current:xn==null?void 0:xn.page,showSizeChanger:!1,onChange:No,showQuickJumper:!0,hideOnSinglePage:!0})))},hs=({hack:ft,onTriggerPraise:bt,topicId:wt,page:Vn,onPageChange:In,user:pn,submitRecords:An,submitting:xn,submitResult:On})=>{const[qn]=(0,ue.useSearchParams)(),ci=(0,ue.useLocation)(),[Pr,gi]=(0,ce.useState)(qn.get("tab")||"0"),[kr,yi]=(0,ce.useState)(0),[Br,zi]=(0,ce.useState)(0),[ri,ki]=(0,ce.useState)(0),[Zi,ii]=(0,ce.useState)(),[Ti,er]=(0,ce.useState)(!1);function Bi(Mi){const No=Mi.target.id;if(Pr==="3"&&No!==Pr&&(Br===1||Br===2)){le.default.confirm({centered:!0,width:500,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u6CE8\u610F",icon:null,className:"custom-modal-divider",content:"\u60A8\u6B63\u5728\u7F16\u5199\u9898\u89E3\uFF0C\u70B9\u51FB\u5173\u95ED\u540E\uFF0C\u60A8\u7684\u9898\u89E3\u5185\u5BB9\u5C06\u4E0D\u4F1A\u8FDB\u884C\u4FDD\u5B58\u3002",onOk:()=>{gi(No)}});return}gi(No)}(0,ce.useEffect)(()=>tt.Z.subscribe("to-commit-info",()=>{gi("1")}),[]);function Si(){gi("2")}return ce.createElement("div",{className:pt["left-panel"]},ce.createElement("ul",{className:`${pt["s-navs"]} ${pt["bg-white"]} ${pt.b1}`},ce.createElement("li",{className:"mr40 current"},ce.createElement("img",{onClick:()=>er(!0),src:yt})),ce.createElement("li",{className:pt["oj-mr"]},ce.createElement("a",{className:Pr==="0"?pt.active:"",id:"0",onClick:Bi},"\u4EFB\u52A1\u63CF\u8FF0")),ce.createElement("li",{className:pt["oj-mr"]},ce.createElement("a",{className:Pr==="3"?pt.active:"",id:"3",onClick:Bi},"\u9898\u89E3",ri?`(${ri})`:"")),ce.createElement("li",{className:pt["oj-mr"]},ce.createElement("a",{className:Pr==="2"?pt.active:"",id:"2",onClick:Bi},"\u8BC4\u8BBA",kr?`(${kr})`:"")),ce.createElement("li",null,ce.createElement("a",{className:Pr==="1"?pt.active:"",id:"1",onClick:Bi},"\u63D0\u4EA4\u8BB0\u5F55"))),ce.createElement("div",{className:`${pt["tab-panel-body"]} ${Pr==="0"?"":"hide"}`,style:{padding:"0 0 0 16px"}},ce.createElement(Re,{hack:ft,onTriggerPraise:bt,toDiscuss:Si})),ce.createElement("div",{className:`${pt["tab-panel-body"]} ${Pr==="1"?"":"hide"}`},An!=null&&An.records_count?ce.createElement(Be,{page:Vn,onPageChange:In,topicId:wt,submitting:xn,submitRecords:An,submitResult:On}):ce.createElement(Ke.Z,null)),ce.createElement("div",{className:`${pt["tab-panel-body"]} ${Pr==="2"?"":"hide"}`,style:{padding:0}},ce.createElement(Bt,{setDiscussTotal:yi,user:pn,identifier:ft.identifier,hack:ft,onTriggerPraise:bt})),ce.createElement("div",{className:`${pt["tab-panel-body"]} ${Pr==="3"?"":"hide"}`,style:{padding:0}},ce.createElement(Qa,{setListStatus:zi,setFilterListTotal:ki,tabStatus:Pr,identifier:ft.identifier})),ce.createElement(ts,{visible:Ti,setIndex:gi,onVisible:Mi=>er(Mi),value:Zi,onChange:Mi=>ii(Mi)}))},ka=be(38273),ps=be(62522),ms=be(60515),ws=be(88977),ns=be(89392),rs=be.n(ns),La=be(56102),Nr=be(59301),xs=Object.defineProperty,Pa=Object.defineProperties,vs=Object.getOwnPropertyDescriptors,ia=Object.getOwnPropertySymbols,is=Object.prototype.hasOwnProperty,ma=Object.prototype.propertyIsEnumerable,pi=(ft,bt,wt)=>bt in ft?xs(ft,bt,{enumerable:!0,configurable:!0,writable:!0,value:wt}):ft[bt]=wt,_r=(ft,bt)=>{for(var wt in bt||(bt={}))is.call(bt,wt)&&pi(ft,wt,bt[wt]);if(ia)for(var wt of ia(bt))ma.call(bt,wt)&&pi(ft,wt,bt[wt]);return ft},Ei=(ft,bt)=>Pa(ft,vs(bt)),bo=(ft,bt)=>{var wt={};for(var Vn in ft)is.call(ft,Vn)&&bt.indexOf(Vn)<0&&(wt[Vn]=ft[Vn]);if(ft!=null&&ia)for(var Vn of ia(ft))bt.indexOf(Vn)<0&&ma.call(ft,Vn)&&(wt[Vn]=ft[Vn]);return wt},Ni=(ft,bt,wt)=>new Promise((Vn,In)=>{var pn=On=>{try{xn(wt.next(On))}catch(qn){In(qn)}},An=On=>{try{xn(wt.throw(On))}catch(qn){In(qn)}},xn=On=>On.done?Vn(On.value):Promise.resolve(On.value).then(pn,An);xn((wt=wt.apply(ft,bt)).next())});const{Countdown:Na}=se.default,va={Java:"java",C:"c",Python:"py","C++":"c"};var Aa=(ft=>(ft[ft.SET_LOADING=0]="SET_LOADING",ft[ft.GET_DATA=1]="GET_DATA",ft[ft.GET_SUBMIT_RECORDS=2]="GET_SUBMIT_RECORDS",ft[ft.SET_DATA=3]="SET_DATA",ft[ft.SET_DEBUGING=4]="SET_DEBUGING",ft[ft.SET_SUBMITING=5]="SET_SUBMITING",ft[ft.SET_EXECUTE_MESSAGE=6]="SET_EXECUTE_MESSAGE",ft[ft.SET_EXECUTE_RESULT=7]="SET_EXECUTE_RESULT",ft[ft.SET_SUBMIT_RESULT=8]="SET_SUBMIT_RESULT",ft[ft.SET_SHOW_NOTE=9]="SET_SHOW_NOTE",ft[ft.SET_PAGE=10]="SET_PAGE",ft[ft.GET_LANGUAGE=11]="GET_LANGUAGE",ft[ft.GET_DRAWER=12]="GET_DRAWER",ft))(Aa||{});function Po(){return new Date().getTime()}const fa={loading:!0,data:void 0,showNote:!1,debugResult:void 0,submitResult:void 0,debuging:!1,submitting:!1,submitRecords:void 0,submitRecordPage:1,executingMessage:"",languageValue:"",languageList:[],drawerData:[]};function sl(ft,bt){switch(bt.type){case 1:return _r(_r({},ft),bt.payload);case 3:return Ei(_r({},ft),{data:bt.payload});case 0:return Ei(_r({},ft),{loading:bt.payload});case 11:return Ei(_r({},ft),{languageList:bt.payload});case 12:return Ei(_r({},ft),{drawerData:bt.payload});case 9:return Ei(_r({},ft),{showNote:bt.payload});case 4:return Ei(_r({},ft),{debuging:bt.payload});case 5:return Ei(_r({},ft),{submitting:bt.payload});case 2:return Ei(_r({},ft),{submitRecords:bt.payload});case 10:return Ei(_r({},ft),{submitRecordPage:bt.payload});case 6:return Ei(_r({},ft),{executingMessage:bt.payload});case 7:return _r(_r({},ft),bt.payload);case 8:return _r(_r({},ft),bt.payload);default:throw new Error}}var ll=({children:ft})=>{var bt,wt,Vn,In;const[pn,An]=(0,ce.useReducer)(sl,fa),{id:xn}=(0,ue.useParams)(),On=(0,ue.useLocation)(),[qn]=(0,ue.useSearchParams)(),{languageValue:ci,languageList:Pr,loading:gi,data:kr,debugResult:yi,submitResult:Br,submitRecords:zi,submitRecordPage:ri,showNote:ki,debuging:Zi,submitting:ii,executingMessage:Ti}=pn,[er,Bi]=(0,ce.useState)("#FFF"),[Si,Mi]=(0,ce.useState)(null),[No,mr]=(0,ce.useState)({}),[Gi,li]=(0,ce.useState)(!1),Sr=(0,ce.useRef)(null),Fr=(0,ce.useRef)(null),mi=kr==null?void 0:kr.user,Mr=kr==null?void 0:kr.hack;(0,ce.useEffect)(()=>((0,ue.getDvaApp)()._store.dispatch({type:"globalSetting/headerFooterToggle",payload:!1}),(0,ue.getDvaApp)()._store.dispatch({type:"globalSetting/onlyShowBackTopToggle",payload:!0}),()=>{(0,ue.getDvaApp)()._store.dispatch({type:"globalSetting/headerFooterToggle",payload:!0}),(0,ue.getDvaApp)()._store.dispatch({type:"globalSetting/onlyShowBackTopToggle",payload:!1})}),[]),(0,ce.useEffect)(()=>{setTimeout(()=>{document.title="\u5728\u7EBF\u5237\u9898"},400)}),(0,ce.useEffect)(()=>{var fi;if(Gi){const eo=document.getElementById("oj-next"),Do=document.getElementById("oj-modal-next");((fi=eo==null?void 0:eo.style)==null?void 0:fi.display)==="none"?Do.style.display="none":Do.style.display="block"}},[Gi]),(0,ce.useEffect)(()=>{function fi(){return Ni(this,null,function*(){var eo,Do,ya;const fo=yield(0,E.fu)(xn);if(fo.status===401)document.location.href="/user/login";else{fo.hack=fo.practice,fo.hack.code=rt.Base64.decode((eo=fo==null?void 0:fo.hack)==null?void 0:eo.code);const _a=`${mi==null?void 0:mi.login}-language`;localStorage.getItem(_a)&&(fo.hack.language=localStorage.getItem(_a)),Fr.current=rs().cloneDeep(fo),Fr.current.language=(Do=fo==null?void 0:fo.hack)==null?void 0:Do.language,An({type:1,payload:{loading:!1,data:fo}}),An({type:8,payload:{languageValue:(ya=fo==null?void 0:fo.hack)==null?void 0:ya.language}})}})}xn&&fi()},[xn]),(0,ce.useEffect)(()=>{An({type:8,payload:{debugResult:void 0}}),oa(),li(!1)},[xn]),(0,ce.useEffect)(()=>{clearTimeout(Sr.current)},[xn]),(0,ce.useEffect)(()=>{so()},[xn,ri]);const qo=()=>{window.parent.postMessage("backExercise","*")};function so(){return Ni(this,null,function*(){try{const fi=yield(0,E.zO)(xn,{limit:15,page:ri});An({type:2,payload:fi})}catch(fi){console.log(fi)}})}function oa(){return Ni(this,null,function*(){try{const fi=yield(0,E.dd)(xn);An({type:11,payload:fi==null?void 0:fi.data})}catch(fi){console.log(fi)}})}function os(fi){An({type:10,payload:fi})}function aa(fi){return Ni(this,null,function*(){var eo,Do,ya;const fo=((ya=(Do=(eo=window==null?void 0:window.location)==null?void 0:eo.pathname)==null?void 0:Do.split("/"))==null?void 0:ya[2])||xn;return yield(0,E.n4)(fo,fi||{code:rt.Base64.encode(Mr.code),language:ci})})}function ga(){return Ni(this,null,function*(){var fi;if(!Mr.code||((fi=Mr.code)==null?void 0:fi.trim())===""){te.ZP.warning({key:"emptyContent",content:"\u4EE3\u7801\u4E0D\u80FD\u4E3A\u7A7A\uFF0C\u8BF7\u5148\u7F16\u5199\u4EE3\u7801\u540E\uFF0C\u518D\u8FDB\u884C\u8BC4\u6D4B\uFF01"});return}if(!ii){An({type:5,payload:!0});try{if(tt.Z.publish("to-commit-info"),(yield aa()).status===0){let Ka=function(){return Ni(this,null,function*(){const{status:Va,data:ja}=yield(0,E.rX)(xn,"submit"),as=Po()-ha>(fo*_a+3)*1e3;if(Va!==0&&!as&&setTimeout(Ka,1e3),as){le.default.error({centered:!0,okText:"\u77E5\u9053\u5566",title:"\u8BC4\u6D4B\u4EE3\u7801\u8D85\u65F6"}),An({type:5,payload:!1});return}if(Va===0){ja.status===2&&le.default.error({centered:!0,okText:"\u77E5\u9053\u5566",title:"\u8BC4\u6D4B\u4EE3\u7801\u8D85\u65F6"});const hl=yield(0,E.zO)(xn,{limit:15,page:ri});An({type:8,payload:Ei(_r({},pn),{submitResult:ja,submitting:!1,submitRecords:hl})}),(ja==null?void 0:ja.status)===0&&li(!0)}})},Do={};if((yield(0,E.bM)(xn,Do)).status===-1&&qn.get("exercisesId")){window.parent.location.href=`/classrooms/${qn.get("coursesId")}/exercise/${qn.get("exercisesId")}/detail`;return}const{time_limit:fo,test_case_size:_a}=Mr,ha=Po();Ka()}}catch(eo){An({type:5,payload:!1})}}})}function oi(){return Ni(this,null,function*(){var fi;if(!Mr.code||((fi=Mr.code)==null?void 0:fi.trim())===""){te.ZP.warning({key:"emptyContent",content:"\u4EE3\u7801\u4E0D\u80FD\u4E3A\u7A7A\uFF0C\u8BF7\u5148\u7F16\u5199\u4EE3\u7801\u540E\uFF0C\u518D\u8FDB\u884C\u8BC4\u6D4B\uFF01"});return}pn.debuging=!0,An({type:4,payload:!0});try{if((yield aa()).status===0){let ha=function(){return Ni(this,null,function*(){const{status:Ka,message:Va,data:ja}=yield(0,E.rX)(xn,"debug"),as=Po()-_a>(Do+3)*1e3;if(Ka!==0&&!as&&(An({type:6,payload:Va}),setTimeout(ha,1e3)),as){le.default.error({centered:!0,okText:"\u77E5\u9053\u5566",content:"\u8C03\u8BD5\u4EE3\u7801\u8D85\u65F6"}),An({type:4,payload:!1});return}Ka===0&&(An({type:4,payload:!1}),ja.status===2&&le.default.error({centered:!0,okText:"\u77E5\u9053\u5566",content:"\u8C03\u8BD5\u4EE3\u7801\u8D85\u65F6"}),An({type:7,payload:Ei(_r({},pn),{debugResult:ja,debuging:!1})}))})};const{time_limit:Do}=Mr;let ya={input:encodeURIComponent(kr.test_case.input)};if((yield(0,E.MU)(xn,ya)).status===-1&&qn.get("exercisesId")){window.parent.location.href=`/classrooms/${qn.get("coursesId")}/exercise/${qn.get("exercisesId")}/detail`;return}const _a=Po();ha()}else An({type:4,payload:!1})}catch(eo){console.log(eo)}finally{}})}function Ai(fi){var eo;clearTimeout(Sr.current),Sr.current=setTimeout(()=>{var Do;aa({code:rt.Base64.encode(fi),language:(Do=Fr==null?void 0:Fr.current)==null?void 0:Do.language})},2e3),An({type:3,payload:Ei(_r({},Fr==null?void 0:Fr.current),{hack:Ei(_r({},(eo=Fr==null?void 0:Fr.current)==null?void 0:eo.hack),{code:fi})})})}function oo(fi){let eo=fi.target.value;An({type:3,payload:Ei(_r({},kr),{test_case:{input:eo}})})}const Ba=fi=>Ni(void 0,null,function*(){var eo;if(An({type:0,payload:!0}),(yield aa()).status===0){An({type:8,payload:{languageValue:fi}}),Fr.current.language=fi;const ya=`${mi==null?void 0:mi.login}-language`;localStorage.setItem(ya,fi);const fo=yield(0,E.dd)(xn);if(fo.status===0){const _a=(eo=fo==null?void 0:fo.data)==null?void 0:eo.find(ha=>ha.language===fi);Ai(rt.Base64.decode(_a.code))}}setTimeout(()=>{An({type:0,payload:!1})},300)});function jo(){return Ni(this,null,function*(){try{const fi=yield(0,E.H7)(xn,{language:ci});fi.status===401?ue.history.replace("/login",{from:On.pathname}):(Ai(rt.Base64.decode(fi.code)),oa())}catch(fi){console.log(fi)}})}function Cs(){le.default.confirm({centered:!0,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u63D0\u793A",content:Nr.createElement("p",null,"\u521D\u59CB\u4EE3\u7801\u6709\u4FEE\u6539\uFF0C\u66F4\u65B0\u540E\u5C06\u8986\u76D6\u73B0\u6709\u4EE3\u7801\u54E6~ ",Nr.createElement("br",null),"\u8BF7\u5C06\u60A8\u7F16\u8F91\u7684\u4EE3\u7801\u4FDD\u5B58\u81F3\u672C\u5730\uFF0C\u4EE5\u9632\u4E22\u5931"),onOk(){return Ni(this,null,function*(){const fi=yield(0,E.fi)(xn,{language:ci});fi.status===401?ue.history.replace("/login",{from:On.pathname}):Ai(rt.Base64.decode(fi.code))})}})}function Jo(){An({type:9,payload:!0})}function lo(){An({type:9,payload:!1})}function Fa(fi){return Ni(this,null,function*(){yield(0,E.MK)(xn,fi),An({type:1,payload:{showNote:!1,data:Ei(_r({},kr),{hack:Ei(_r({},Mr),{notes:fi.notes})})}})})}const dl={input:(bt=kr==null?void 0:kr.test_case)==null?void 0:bt.input,is_file:(wt=kr==null?void 0:kr.test_case)==null?void 0:wt.is_file,language:((Vn=Fr.current)==null?void 0:Vn.language)||(Mr==null?void 0:Mr.language),code:Mr==null?void 0:Mr.code,title:"main."+va[Mr==null?void 0:Mr.language],modify_code:Mr==null?void 0:Mr.modify_code,notes:Mr==null?void 0:Mr.notes,debugResult:yi,debuging:Zi,submitting:ii,executingMessage:Ti,id:xn,languageValue:ci,languageList:Pr,onChangeLanguage:Ba,onCancelNote:lo,onAddNote:Fa,showNote:ki,onShowNote:Jo,onSubmitCode:ga,onChangeCode:Ai,onChangeInput:oo,onDebugCode:oi,onResetCode:jo,onSyncCode:Cs,onUpdateCode:aa};function Xs(){return Ni(this,null,function*(){const{praise_count:fi}=yield(0,E.vl)(Mr.id,{container_type:"Hack",type:1});let eo=Ei(_r({},kr),{hack:Ei(_r({},Mr),{praises_count:fi,user_praise:!Mr.user_praise})});An({type:3,payload:eo})})}const fl={topicId:xn,submitResult:Br,submitRecords:zi,submitting:ii,page:ri,onPageChange:os,hack:Mr,user:kr==null?void 0:kr.user,onTriggerPraise:Xs};return console.log(kr,Fr==null?void 0:Fr.current,"data--------"),Nr.createElement(Nr.Fragment,null,Nr.createElement(ee.Z,{className:"oj-custom-large-spin",size:"large",spinning:gi},kr?Nr.createElement("div",{className:"oj-custom-warp"},Nr.createElement("header",{className:Ye.Z.header,style:{minWidth:1200}},Nr.createElement("div",null,Nr.createElement("img",{src:`${z.Z.IMG_SERVER}/images/${mi.image_url}`,alt:"user",width:30}),Nr.createElement("span",null,mi.name)),Nr.createElement("h2",{className:"flex-wrp flex_box_column flex_box_center"},Nr.createElement("div",null,Mr.name),Nr.createElement(ka.Z,{onChange:fi=>{},className:"font12 c-grey-999"})),Nr.createElement(La.CopyToClipboard,{text:`${(In=window.location)==null?void 0:In.origin}/problems/${Mr.identifier}/share`,onCopy:()=>te.ZP.success("\u590D\u5236\u9898\u76EE\u94FE\u63A5\u6210\u529F")},Nr.createElement("span",{className:Ye.Z.btn_back,style:{marginRight:10,cursor:"pointer"}}," ",Nr.createElement("i",{className:"iconfont icon-fenxiang1 font14 mr5"}),"\u5206\u4EAB\u9898\u76EE")),Mr.edit_privilege?Nr.createElement(ue.Link,{className:Ye.Z.btn_back,to:`/problems/${Mr.identifier}/ojedit`,style:{marginRight:10}}," ",Nr.createElement(ie.Z,null)," \u7F16\u8F91"):null,Nr.createElement(ue.Link,{className:Ye.Z.btn_back,onClick:()=>{},to:"/problems"}," ",Nr.createElement(Ce.Z,null),"\u9000\u51FA")),Nr.createElement(b.Z,{hideResize:!0,className:"my-problems oj-problems",leftChild:Nr.createElement(hs,_r({},fl)),rightChild:Nr.createElement(cl,_r({},dl))})):null),Nr.createElement(le.default,{centered:!0,closable:!1,width:680,footer:null,open:Gi,className:"oj-modal"},Nr.createElement("section",{className:"oj-modal-content"},Nr.createElement("div",{className:"oj-modal-head"},Nr.createElement("img",{src:ps,alt:""}),Nr.createElement("i",{onClick:()=>li(!1),className:"iconfont icon-guanbi1"})),Nr.createElement("aside",null,Nr.createElement("img",{className:"mr30",src:ws.Z}),"\u8FD0\u884C\u65F6\u95F4:\xA0",Nr.createElement("span",{style:{color:"#75d6ba",marginRight:100}},Br==null?void 0:Br.execute_time,"s"),"\u4F18\u4E8E",Nr.createElement("span",{style:{color:"#f3b087",margin:"0 5px"}},(Br==null?void 0:Br.time_better_than)||100,"%"),"\u7684\u7528\u6237"),Nr.createElement("aside",{className:"mb50"},Nr.createElement("img",{src:ms.Z,className:"mr30"}),Nr.createElement("span",{className:"oj-modal-tt"},Nr.createElement("span",null,Nr.createElement("span",null,"\u5360\u7528\u5185\u5B58:\xA0"),Nr.createElement("span",{className:"c-light-primary"},Br==null?void 0:Br.execute_memory,"mb")),Nr.createElement("span",null,Nr.createElement("span",null))),"\u4F18\u4E8E",Nr.createElement("span",{style:{color:"#f3b087",margin:"0 5px"}},(Br==null?void 0:Br.memory_better_than)||100,"%"),"\u7684\u7528\u6237"),Nr.createElement("div",{id:"oj-modal-next",className:"oj-modal-btn"},"\u8FDB\u5165\u4E0B\u4E00\u9898"))))};function ul({languageValue:ft,languageList:bt,onChangeLanguage:wt,title:Vn,modify_code:In,onSyncCode:pn,onShowCodeSetting:An,onResetCode:xn}){const On=(0,ue.useLocation)(),qn=()=>{le.default.confirm({title:"\u6062\u590D\u521D\u59CB\u4EE3\u7801",icon:Nr.createElement(x.Z,null),content:"\u4F60\u5728\u672C\u6587\u4EF6\u4E2D\u4FEE\u6539\u7684\u5185\u5BB9\u5C06\u4E22\u5931\uFF0C\u662F\u5426\u786E\u5B9A\u91CD\u65B0\u52A0\u8F7D\u521D\u59CB\u4EE3\u7801\uFF1F",centered:!0,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",onOk:xn})};return Nr.createElement("div",{className:"action-bar"},Nr.createElement(ne.default,{className:"oj-select",value:ft,style:{width:100},placeholder:"\u9009\u62E9\u8BED\u8A00",onChange:wt},bt==null?void 0:bt.map(ci=>Nr.createElement(ne.default.Option,{key:ci.language,value:ci.language},ci.language))),Nr.createElement("span",null),Nr.createElement("a",{title:"\u6062\u590D\u521D\u59CB\u4EE3\u7801",onClick:qn},Nr.createElement("i",{className:"iconfont icon-zhongzhi font-20 "})),Nr.createElement("a",{onClick:An},Nr.createElement("i",{className:"iconfont icon-shezhi"})))}function cl(ft){var bt=ft,{id:wt,input:Vn,is_file:In,showNote:pn,onShowNote:An,notes:xn,onCancelNote:On,onAddNote:qn,debugResult:ci,language:Pr,debuging:gi,submitting:kr,executingMessage:yi,code:Br,onSubmitCode:zi,onDebugCode:ri,onChangeCode:ki,onChangeInput:Zi,onUpdateCode:ii}=bt,Ti=bo(bt,["id","input","is_file","showNote","onShowNote","notes","onCancelNote","onAddNote","debugResult","language","debuging","submitting","executingMessage","code","onSubmitCode","onDebugCode","onChangeCode","onChangeInput","onUpdateCode"]);function er(Si){return Nr.createElement(ul,Ei(_r({},Ti),{onShowCodeSetting:Si}))}const Bi={id:wt,input:Vn,debugResult:ci,debuging:gi,is_file:In,submitting:kr,executingMessage:yi,onDebugCode:ri,onChangeCode:ki,onSubmitCode:zi,onChangeInput:Zi};return Nr.createElement("div",{className:"right-panel"},Nr.createElement(ot,{onUpdateCode:()=>{},language:Pr,value:Br,onChange:ki,ActionBarRender:er}),Nr.createElement("div",{className:`note-form-area ${pn?"active":""}`},Nr.createElement(et,{onCancel:On,notes:xn,callback:qn})),Nr.createElement(ut.ZP,_r({},Bi)))}},49162:function(Xt,Mt,be){"use strict";be.d(Mt,{h:function(){return ce}});var ce=(ie=>(ie[ie.NOMATCH=-1]="NOMATCH",ie[ie.OK=0]="OK",ie[ie.TIMEOUT=2]="TIMEOUT",ie[ie.PODFAILURE=3]="PODFAILURE",ie[ie.COMPILEFAILURE=4]="COMPILEFAILURE",ie[ie.EXECUTEFAILURE=5]="EXECUTEFAILURE",ie[ie.HIDE_COMPILE_STATUS=11]="HIDE_COMPILE_STATUS",ie))(ce||{})},59205:function(Xt,Mt,be){"use strict";be.d(Mt,{H7:function(){return ne},KC:function(){return re},M3:function(){return ye},MK:function(){return ee},MU:function(){return ue},Rg:function(){return _e},WH:function(){return ae},X6:function(){return te},bM:function(){return Ce},bx:function(){return oe},dd:function(){return z},de:function(){return pe},fi:function(){return E},fu:function(){return ie},gu:function(){return ve},n4:function(){return b},qe:function(){return ge},rL:function(){return he},rX:function(){return le},uc:function(){return ke},vl:function(){return x},wO:function(){return me},zO:function(){return se}});var ce=be(82093);function ie(Te){return(0,ce.U2)(`mypractices/${Te}.json`,{hidePopLogin:!0})}function Ce(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/code_submit.json`,Ee)}function ue(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/code_debug.json`,Ee)}function se(Te,Ee){return Ee.language&&(Ee.language=encodeURIComponent(Ee.language)),(0,ce.U2)(`mypractices/${Te}/submit_records.json`,Ee)}function te(Te){return(0,ce.U2)("mypractices/record_detail.json",{id:Te})}function le(Te,Ee){return(0,ce.U2)(`mypractices/${Te}/result.json`,{mode:Ee})}function ee(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/add_notes.json`,Ee)}function ne(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/restore_initial_code.json`,Ee)}function E(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/sync_code.json`,Ee)}function b(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/update_code.json`,Ee)}function z(Te){return(0,ce.v_)(`mypractices/${Te}/initial_codes.json`)}function x(Te,Ee){return(0,ce.v_)(`discusses/${Te}/plus.json`,Ee)}function re(Te){return(0,ce.U2)("practices/practices_list.json",Te)}function ae(Te,Ee){return(0,ce.U2)(`practices/${Te}/question_solution_articles`,Ee)}function oe(Te,Ee){return(0,ce.v_)(`practices/${Te}/question_solution_articles`,Ee)}function ve(Te,Ee){return(0,ce.gz)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}`,Ee)}function ye(Te,Ee){return(0,ce.U2)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}/edit`,Ee)}function me(Te,Ee){return(0,ce.U2)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}`,Ee)}function ge(Te,Ee){return(0,ce.v_)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}/set_authority_or_excellent`,Ee)}function _e(Te,Ee){return(0,ce.v_)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}/praise_or_treads`,Ee)}function he(Te,Ee){return(0,ce.v_)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}/hide`)}function pe(Te,Ee){return(0,ce.IV)(`practices/${Te}/question_solution_articles/${Ee==null?void 0:Ee.active}`,Ee)}function ke(Te,Ee){return(0,ce.v_)(`mypractices/${Te}/update_practice_time_sum`,Ee)}},46541:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return x}});var ce=be(59301),ie=be(6767),Ce=be(25399),ue=be(29787),se=be(77019),te=be(5269),le=be(13747),ee=be(99571),ne=be(2978),E=be(82093),b=be(38394),z=(ae,oe,ve)=>new Promise((ye,me)=>{var ge=pe=>{try{he(ve.next(pe))}catch(ke){me(ke)}},_e=pe=>{try{he(ve.throw(pe))}catch(ke){me(ke)}},he=pe=>pe.done?ye(pe.value):Promise.resolve(pe.value).then(ge,_e);he((ve=ve.apply(ae,oe)).next())}),x=({id:ae,activeDiscussIndex:oe,onReplyDiscuss:ve,adminOrOperator:ye})=>{const[me,ge]=(0,ce.useState)(""),[_e,he]=(0,ce.useState)(!1);function pe(Te){ge(Te)}function ke(){if(!me){ie.ZP.info("\u56DE\u590D\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A!");return}ve(ae,me),ge("")}return(0,ce.useEffect)(()=>{oe!=ae&&he(!1)},[oe]),ce.createElement("div",{key:ae,className:"discuss-item-editor",style:{display:oe===ae?"block":"none",width:"100%"}},ce.createElement(ne.Z,{miniToolbar:!0,startInit:oe===ae,defaultValue:me,id:ae,noStorage:!0,watch:!1,height:155,placeholder:"\u6211\u8981\u56DE\u590D",showResizeBar:!0,onChange:pe,extraUse:ye&&ce.createElement(Ce.Z,{color:"#fff",open:_e,destroyTooltipOnHide:!0,title:re({id:ae,isOpen:_e,activeDiscussIndex:oe,onChange:pe,setIsOpen:he}),overlayStyle:{maxWidth:600}},ce.createElement("a",{title:_e?"\u5173\u95ED\u63A8\u8350":"\u6253\u5F00\u63A8\u8350",onClick:()=>he(!_e)},ce.createElement("i",{className:"iconfont icon-dianzan11"})))}),ce.createElement("a",{onClick:ke,className:"btn-send"},"\u53D1\u9001"))};const re=ae=>{const[oe,ve]=(0,ce.useState)(!1),[ye,me]=(0,ce.useState)([]),[ge,_e]=(0,ce.useState)(1);(0,ce.useEffect)(()=>{ae!=null&&ae.isOpen?he():(_e(1),me([]))},[ae==null?void 0:ae.isOpen]);const he=()=>z(void 0,null,function*(){ve(!0);const pe=yield(0,E.ZP)(`/api/discusses/${ae==null?void 0:ae.id}/recommend_answer.json`,{method:"get"});(pe==null?void 0:pe.status)==0&&me(pe==null?void 0:pe.answer),ve(!1)});return ce.createElement(ue.Z,{spinning:oe},ce.createElement("div",{style:{color:"#000"}},ce.createElement(b.Z,{className:"font14",style:{maxHeight:500,overflow:"auto"},value:(ye==null?void 0:ye[ge-1])||""}),ce.createElement(se.Z,{justify:"end",align:"middle"},ce.createElement(te.Z,null,ce.createElement(le.Z,{simple:!0,current:ge,pageSize:1,total:(ye==null?void 0:ye.length)||0,onChange:pe=>{_e(pe)}})),ce.createElement(te.Z,null,ce.createElement(ee.ZP,{onClick:()=>z(void 0,null,function*(){ae==null||ae.onChange(ye==null?void 0:ye[ge-1]),ae==null||ae.setIsOpen(!1)})},"\u586B\u5165\u6587\u672C\u6846")))))}},12975:function(Xt,Mt,be){"use strict";be.d(Mt,{o:function(){return ne}});var ce=be(82093),ie=be(93125),Ce=be.n(ie);let ue="",se,te="";function le(E){ee(E)}function ee(E){se=new(Ce()).Vod({timeout:6e4,partSize:1048576,parallel:5,retryCount:3,retryDuration:2,region:"ap-southeast-1",userId:0x6803cbd867207,enableUploadProgress:!1,addFileSuccess:function(b){console.log("addFileSuccess: "+b.file.name),E.addFileSuccess&&E.addFileSuccess(b),se.startUpload()},onUploadstarted:function(b){const z=b.file.name;if(b.videoId){var re=`/api/users/${ue}/video_auths.json`;(0,ce.ZP)(re,{method:"put",body:{video_id:b.videoId,title:z,file_name:z,virtual_classroom_id:te}}).then(ae=>{if(ae.status==-1){E.onUploadError&&E.onUploadError(b);return}const oe=ae.data;var ve=oe.UploadAuth,ye=oe.UploadAddress,me=oe.VideoId;se.setUploadAuthAndAddress(b,ve,ye)}).catch(ae=>{se.deleteFile(se._curIndex),se.nextUpload(),console.log(ae)})}else{var x=`/api/users/${ue}/video_auths.json`;const ae="";(0,ce.ZP)(x,{method:"Post",body:{title:ae+z,file_name:ae+z,virtual_classroom_id:te}}).then(oe=>{if(oe){const ge=oe.data;var ve=ge.UploadAuth,ye=ge.UploadAddress,me=ge.VideoId;se.setUploadAuthAndAddress(b,ve,ye,me)}}).catch(oe=>{se.deleteFile(se._curIndex),se.nextUpload(),console.log(oe)}),console.log("\u6587\u4EF6\u5F00\u59CB\u4E0A\u4F20...")}},onUploadSucceed:function(b){E.onUploadSucceed&&E.onUploadSucceed(b),console.log("\u6587\u4EF6\u4E0A\u4F20\u6210\u529F!")},onUploadFailed:function(b,z,x){E.onUploadFailed&&E.onUploadFailed(b),console.log("\u6587\u4EF6\u4E0A\u4F20\u5931\u8D25!")},onUploadCanceled:function(b,z,x){console.log("\u6587\u4EF6\u4E0A\u4F20\u5DF2\u6682\u505C!")},onUploadProgress:function(b,z,x){E.onUploadProgress&&E.onUploadProgress(b,z,x);var re=Math.ceil(x*100);console.log("\u6587\u4EF6\u4E0A\u4F20\u4E2D...")},onUploadTokenExpired:function(b){console.log("\u6587\u4EF6\u4E0A\u4F20\u8D85\u65F6!");var z=`/api/users/${ue}/video_auths.json`;(0,ce.ZP)(z,{method:"put",body:{video_id:b.videoId}}).then(x=>{var ae=x.data.UploadAuth;se.resumeUploadWithAuth(ae)}).catch(x=>{console.log(x)})},onUploadEnd:function(b){E.onUploadEnd&&E.onUploadEnd(b),console.log("onUploadEnd: uploaded all the files")}}),E.gotUploader&&E.gotUploader(se)}function ne(E,b,z){E&&(ue=E),b&&(te=b),le(z)}},2610:function(Xt,Mt,be){"use strict";be.d(Mt,{BU:function(){return ie},Dj:function(){return ce},gH:function(){return Ce},vp:function(){return ue}});function ce(se){try{se.mozRequestFullScreen?se.mozRequestFullScreen():se.webkitRequestFullScreen&&se.webkitRequestFullScreen()}catch(te){console.log(te,":e")}}function ie(){window.top.document.webkitExitFullscreen?window.top.document.webkitExitFullscreen():document.exitFullscreen?window.top.document.exitFullscreen():document.msExitFullscreen?window.top.document.msExitFullscreen():document.mozCancelFullScreen&&window.top.document.mozCancelFullScreen()}const Ce=()=>{if(document.webkitExitFullscreen)return"webkitfullscreenchange";if(document.exitFullscreen)return"fullscreenchange";if(document.msExitFullscreen)return"msfullscreenchange";if(document.mozCancelFullScreen)return"mozfullscreenchange"};function ue(){var se=window.top.document.fullscreenElement||window.top.document.mozFullscreenElement||window.top.document.webkitFullscreenElement,te=document.fullscreenEnabled||document.mozFullscreenEnabled||document.webkitFullscreenEnabled;return console.log("fullscreenElement",se),window.isFullScreen?window.isFullScreen:se!=null}},90290:function(Xt,Mt,be){"use strict";be.d(Mt,{AL:function(){return _e},Iy:function(){return b},Qv:function(){return re},ez:function(){return ge},jb:function(){return z}});var ce=be(32834),ie=be.n(ce),Ce=be(11690),ue=be.n(Ce);let se=1;function te(Ee,Oe){const je=Ee.match(/^(\s+)(?:```)/);if(je===null)return Oe;const Pe=je[1];return Oe.split(`
|
|
|
`).map(Qe=>{const Xe=Qe.match(/^\s+/);if(Xe===null)return Qe;const[ot]=Xe;return ot.length>=Pe.length?Qe.slice(Pe.length):Qe}).join(`
|
|
|
`)}let le=[],ee=["<ul>"];const ne=new(ie()).Renderer,E=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function b(){le.length=0,ee=["<ul>"]}const z={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function x(Ee,Oe,je,Pe){if(Oe>=Ee.length||Ee[Oe].level<=je)return Oe;var Qe=Ee[Oe];Pe.push("<li><a href='#"+se+Qe.anchor+"'>"+Qe.text+"</a>"),Oe++;var Xe=[];return Oe=x(Ee,Oe,Qe.level,Xe),Xe.length>0&&(Pe.push("<ul>"),Xe.forEach(function(ot){Pe.push(ot)}),Pe.push("</ul>")),Pe.push("</li>"),Oe=x(Ee,Oe,je,Pe),Oe}function re(){return x(le,0,0,ee),ee.push("</ul>"),ee.join("")}const ae={heading(Ee){const Oe=E.exec(Ee);if(se+=1,Oe)return{type:"heading",raw:Oe[0],depth:Oe[1].length,text:Oe[2]}},fences(Ee){const Oe=this.rules.block.fences.exec(Ee);if(Oe){const je=Oe[0];let Pe=te(je,Oe[3]||"");const Qe=Oe[2]?Oe[2].trim():Oe[2];if(["latex","katex","math"].indexOf(Qe)>=0){const Xe=ye(),ot=Pe;Pe=Xe,me[Xe]={type:"block",expression:ot}}return{type:"code",raw:je,lang:Qe,text:Pe}}}},oe=/(?:\${2})([^\n`]+?)(?:\${2})/gi;let ve=0;const ye=()=>`__special_katext_id_${ve++}__`;let me={};function ge(){return me}function _e(){ve=0,me={}}function he(Ee){return Ee=Ee.replace(oe,(Oe,je)=>{const Pe=ye();return me[Pe]={type:"inline",expression:je},Pe}),Ee}const pe=ne.listitem;ne.listitem=function(Ee){return pe(he(Ee))};const ke=ne.paragraph;ne.paragraph=function(Ee){return ke(he(Ee))};const Te=ne.tablecell;ne.tablecell=function(Ee,Oe){return Te(he(Ee),Oe)},ne.code=function(Ee,Oe,je){const Pe=(Oe||"").match(/\S*/)[0];return Pe?["latex","katex","math"].indexOf(Pe)>=0?`<p class='editormd-tex'>${Ee}</p>`:`<pre class="prettyprint linenums"><code class="language-${Oe}">${je?Ee:(0,Ce.escape)(Ee,!0)}</code></pre>
|
|
|
`:'<pre class="prettyprint linenums"><code>'+(je?Ee:(0,Ce.escape)(Ee,!0))+"</code></pre>"},ne.heading=function(Ee,Oe,je){let Pe=this.options.headerPrefix+je.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return le.push({anchor:Pe,level:Oe,text:Ee}),"<h"+Oe+' id="'+se+Pe+'">'+Ee+"</h"+Oe+">"},ie().setOptions({silent:!0,gfm:!0,pedantic:!1}),ie().use({tokenizer:ae,renderer:ne}),Mt.ZP=ie()},89613:function(Xt,Mt,be){"use strict";be.d(Mt,{G:function(){return se},t:function(){return ue}});var ce=be(7062),ie=be.n(ce);const Ce=null;function ue(te,le){let ee=ie().get("__ec");ee||(ee={}),ee[te]=le,ie().set("__ec",ee)}function se(te,le){let ee=ie().get("__ec");return ee?ee[te]===void 0?le:ee[te]:le}},60513:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return $n}});class ce{static install(){Object.setPrototypeOf=Object.setPrototypeOf||function(Ie,Ze){return Ie.__proto__=Ze,Ie},Object.assign=Object.assign||function(Ie){if(Ie==null)throw new TypeError("Cannot convert undefined or null to object");let Ze=Object(Ie);for(let qe=1;qe<arguments.length;qe++){let st=arguments[qe];if(st!=null)for(let mt in st)st.hasOwnProperty(mt)&&(Ze[mt]=st[mt])}return Ze},typeof self.Promise!="function"&&be(3867).polyfill()}}ce.install();var ie=ce,Ce=be(86204),ue=be.n(Ce);class se{static e(Ie,Ze){(!Ie||se.FORCE_GLOBAL_TAG)&&(Ie=se.GLOBAL_TAG);let qe=`[${Ie}] > ${Ze}`;se.ENABLE_CALLBACK&&se.emitter.emit("log","error",qe),se.ENABLE_ERROR&&(console.error?console.error(qe):console.warn?console.warn(qe):console.log(qe))}static i(Ie,Ze){(!Ie||se.FORCE_GLOBAL_TAG)&&(Ie=se.GLOBAL_TAG);let qe=`[${Ie}] > ${Ze}`;se.ENABLE_CALLBACK&&se.emitter.emit("log","info",qe),se.ENABLE_INFO&&(console.info?console.info(qe):console.log(qe))}static w(Ie,Ze){(!Ie||se.FORCE_GLOBAL_TAG)&&(Ie=se.GLOBAL_TAG);let qe=`[${Ie}] > ${Ze}`;se.ENABLE_CALLBACK&&se.emitter.emit("log","warn",qe),se.ENABLE_WARN&&(console.warn?console.warn(qe):console.log(qe))}static d(Ie,Ze){(!Ie||se.FORCE_GLOBAL_TAG)&&(Ie=se.GLOBAL_TAG);let qe=`[${Ie}] > ${Ze}`;se.ENABLE_CALLBACK&&se.emitter.emit("log","debug",qe),se.ENABLE_DEBUG&&(console.debug?console.debug(qe):console.log(qe))}static v(Ie,Ze){(!Ie||se.FORCE_GLOBAL_TAG)&&(Ie=se.GLOBAL_TAG);let qe=`[${Ie}] > ${Ze}`;se.ENABLE_CALLBACK&&se.emitter.emit("log","verbose",qe),se.ENABLE_VERBOSE&&console.log(qe)}}se.GLOBAL_TAG="flv.js",se.FORCE_GLOBAL_TAG=!1,se.ENABLE_ERROR=!0,se.ENABLE_INFO=!0,se.ENABLE_WARN=!0,se.ENABLE_DEBUG=!0,se.ENABLE_VERBOSE=!0,se.ENABLE_CALLBACK=!1,se.emitter=new(ue());var te=se;class le{constructor(){this._firstCheckpoint=0,this._lastCheckpoint=0,this._intervalBytes=0,this._totalBytes=0,this._lastSecondBytes=0,self.performance&&self.performance.now?this._now=self.performance.now.bind(self.performance):this._now=Date.now}reset(){this._firstCheckpoint=this._lastCheckpoint=0,this._totalBytes=this._intervalBytes=0,this._lastSecondBytes=0}addBytes(Ie){this._firstCheckpoint===0?(this._firstCheckpoint=this._now(),this._lastCheckpoint=this._firstCheckpoint,this._intervalBytes+=Ie,this._totalBytes+=Ie):this._now()-this._lastCheckpoint<1e3?(this._intervalBytes+=Ie,this._totalBytes+=Ie):(this._lastSecondBytes=this._intervalBytes,this._intervalBytes=Ie,this._totalBytes+=Ie,this._lastCheckpoint=this._now())}get currentKBps(){this.addBytes(0);let Ie=(this._now()-this._lastCheckpoint)/1e3;return Ie==0&&(Ie=1),this._intervalBytes/Ie/1024}get lastSecondKBps(){return this.addBytes(0),this._lastSecondBytes!==0?this._lastSecondBytes/1024:this._now()-this._lastCheckpoint>=500?this.currentKBps:0}get averageKBps(){let Ie=(this._now()-this._firstCheckpoint)/1e3;return this._totalBytes/Ie/1024}}var ee=le;class ne{constructor(Ie){this._message=Ie}get name(){return"RuntimeException"}get message(){return this._message}toString(){return this.name+": "+this.message}}class E extends ne{constructor(Ie){super(Ie)}get name(){return"IllegalStateException"}}class b extends ne{constructor(Ie){super(Ie)}get name(){return"InvalidArgumentException"}}class z extends ne{constructor(Ie){super(Ie)}get name(){return"NotImplementedException"}}const x={kIdle:0,kConnecting:1,kBuffering:2,kError:3,kComplete:4},re={OK:"OK",EXCEPTION:"Exception",HTTP_STATUS_CODE_INVALID:"HttpStatusCodeInvalid",CONNECTING_TIMEOUT:"ConnectingTimeout",EARLY_EOF:"EarlyEof",UNRECOVERABLE_EARLY_EOF:"UnrecoverableEarlyEof"};class ae{constructor(Ie){this._type=Ie||"undefined",this._status=x.kIdle,this._needStash=!1,this._onContentLengthKnown=null,this._onURLRedirect=null,this._onDataArrival=null,this._onError=null,this._onComplete=null}destroy(){this._status=x.kIdle,this._onContentLengthKnown=null,this._onURLRedirect=null,this._onDataArrival=null,this._onError=null,this._onComplete=null}isWorking(){return this._status===x.kConnecting||this._status===x.kBuffering}get type(){return this._type}get status(){return this._status}get needStashBuffer(){return this._needStash}get onContentLengthKnown(){return this._onContentLengthKnown}set onContentLengthKnown(Ie){this._onContentLengthKnown=Ie}get onURLRedirect(){return this._onURLRedirect}set onURLRedirect(Ie){this._onURLRedirect=Ie}get onDataArrival(){return this._onDataArrival}set onDataArrival(Ie){this._onDataArrival=Ie}get onError(){return this._onError}set onError(Ie){this._onError=Ie}get onComplete(){return this._onComplete}set onComplete(Ie){this._onComplete=Ie}open(Ie,Ze){throw new z("Unimplemented abstract function!")}abort(){throw new z("Unimplemented abstract function!")}}let oe={};function ve(){let Jt=self.navigator.userAgent.toLowerCase(),Ie=/(edge)\/([\w.]+)/.exec(Jt)||/(opr)[\/]([\w.]+)/.exec(Jt)||/(chrome)[ \/]([\w.]+)/.exec(Jt)||/(iemobile)[\/]([\w.]+)/.exec(Jt)||/(version)(applewebkit)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(Jt)||/(webkit)[ \/]([\w.]+).*(version)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(Jt)||/(webkit)[ \/]([\w.]+)/.exec(Jt)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(Jt)||/(msie) ([\w.]+)/.exec(Jt)||Jt.indexOf("trident")>=0&&/(rv)(?::| )([\w.]+)/.exec(Jt)||Jt.indexOf("compatible")<0&&/(firefox)[ \/]([\w.]+)/.exec(Jt)||[],Ze=/(ipad)/.exec(Jt)||/(ipod)/.exec(Jt)||/(windows phone)/.exec(Jt)||/(iphone)/.exec(Jt)||/(kindle)/.exec(Jt)||/(android)/.exec(Jt)||/(windows)/.exec(Jt)||/(mac)/.exec(Jt)||/(linux)/.exec(Jt)||/(cros)/.exec(Jt)||[],qe={browser:Ie[5]||Ie[3]||Ie[1]||"",version:Ie[2]||Ie[4]||"0",majorVersion:Ie[4]||Ie[2]||"0",platform:Ze[0]||""},st={};if(qe.browser){st[qe.browser]=!0;let mt=qe.majorVersion.split(".");st.version={major:parseInt(qe.majorVersion,10),string:qe.version},mt.length>1&&(st.version.minor=parseInt(mt[1],10)),mt.length>2&&(st.version.build=parseInt(mt[2],10))}if(qe.platform&&(st[qe.platform]=!0),(st.chrome||st.opr||st.safari)&&(st.webkit=!0),st.rv||st.iemobile){st.rv&&delete st.rv;let mt="msie";qe.browser=mt,st[mt]=!0}if(st.edge){delete st.edge;let mt="msedge";qe.browser=mt,st[mt]=!0}if(st.opr){let mt="opera";qe.browser=mt,st[mt]=!0}if(st.safari&&st.android){let mt="android";qe.browser=mt,st[mt]=!0}st.name=qe.browser,st.platform=qe.platform;for(let mt in oe)oe.hasOwnProperty(mt)&&delete oe[mt];Object.assign(oe,st)}ve();var ye=oe;class me extends ae{static isSupported(){try{let Ie=ye.msedge&&ye.version.minor>=15048,Ze=ye.msedge?Ie:!0;return self.fetch&&self.ReadableStream&&Ze}catch(Ie){return!1}}constructor(Ie,Ze){super("fetch-stream-loader"),this.TAG="FetchStreamLoader",this._seekHandler=Ie,this._config=Ze,this._needStash=!0,this._requestAbort=!1,this._contentLength=null,this._receivedLength=0}destroy(){this.isWorking()&&this.abort(),super.destroy()}open(Ie,Ze){this._dataSource=Ie,this._range=Ze;let qe=Ie.url;this._config.reuseRedirectedURL&&Ie.redirectedURL!=null&&(qe=Ie.redirectedURL);let st=this._seekHandler.getConfig(qe,Ze),mt=new self.Headers;if(typeof st.headers=="object"){let kt=st.headers;for(let Ft in kt)kt.hasOwnProperty(Ft)&&mt.append(Ft,kt[Ft])}let Bt={method:"GET",headers:mt,mode:"cors",cache:"default",referrerPolicy:"no-referrer-when-downgrade"};if(typeof this._config.headers=="object")for(let kt in this._config.headers)mt.append(kt,this._config.headers[kt]);Ie.cors===!1&&(Bt.mode="same-origin"),Ie.withCredentials&&(Bt.credentials="include"),Ie.referrerPolicy&&(Bt.referrerPolicy=Ie.referrerPolicy),this._status=x.kConnecting,self.fetch(st.url,Bt).then(kt=>{if(this._requestAbort){this._requestAbort=!1,this._status=x.kIdle;return}if(kt.ok&&kt.status>=200&&kt.status<=299){if(kt.url!==st.url&&this._onURLRedirect){let qt=this._seekHandler.removeURLParameters(kt.url);this._onURLRedirect(qt)}let Ft=kt.headers.get("Content-Length");return Ft!=null&&(this._contentLength=parseInt(Ft),this._contentLength!==0&&this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength)),this._pump.call(this,kt.body.getReader())}else if(this._status=x.kError,this._onError)this._onError(re.HTTP_STATUS_CODE_INVALID,{code:kt.status,msg:kt.statusText});else throw new ne("FetchStreamLoader: Http code invalid, "+kt.status+" "+kt.statusText)}).catch(kt=>{if(this._status=x.kError,this._onError)this._onError(re.EXCEPTION,{code:-1,msg:kt.message});else throw kt})}abort(){this._requestAbort=!0}_pump(Ie){return Ie.read().then(Ze=>{if(Ze.done)if(this._contentLength!==null&&this._receivedLength<this._contentLength){this._status=x.kError;let qe=re.EARLY_EOF,st={code:-1,msg:"Fetch stream meet Early-EOF"};if(this._onError)this._onError(qe,st);else throw new ne(st.msg)}else this._status=x.kComplete,this._onComplete&&this._onComplete(this._range.from,this._range.from+this._receivedLength-1);else{if(this._requestAbort===!0)return this._requestAbort=!1,this._status=x.kComplete,Ie.cancel();this._status=x.kBuffering;let qe=Ze.value.buffer,st=this._range.from+this._receivedLength;this._receivedLength+=qe.byteLength,this._onDataArrival&&this._onDataArrival(qe,st,this._receivedLength),this._pump(Ie)}}).catch(Ze=>{if(Ze.code===11&&ye.msedge)return;this._status=x.kError;let qe=0,st=null;if((Ze.code===19||Ze.message==="network error")&&(this._contentLength===null||this._contentLength!==null&&this._receivedLength<this._contentLength)?(qe=re.EARLY_EOF,st={code:Ze.code,msg:"Fetch stream meet Early-EOF"}):(qe=re.EXCEPTION,st={code:Ze.code,msg:Ze.message}),this._onError)this._onError(qe,st);else throw new ne(st.msg)})}}var ge=me;class _e extends ae{static isSupported(){try{let Ie=new XMLHttpRequest;return Ie.open("GET","https://example.com",!0),Ie.responseType="moz-chunked-arraybuffer",Ie.responseType==="moz-chunked-arraybuffer"}catch(Ie){return te.w("MozChunkedLoader",Ie.message),!1}}constructor(Ie,Ze){super("xhr-moz-chunked-loader"),this.TAG="MozChunkedLoader",this._seekHandler=Ie,this._config=Ze,this._needStash=!0,this._xhr=null,this._requestAbort=!1,this._contentLength=null,this._receivedLength=0}destroy(){this.isWorking()&&this.abort(),this._xhr&&(this._xhr.onreadystatechange=null,this._xhr.onprogress=null,this._xhr.onloadend=null,this._xhr.onerror=null,this._xhr=null),super.destroy()}open(Ie,Ze){this._dataSource=Ie,this._range=Ze;let qe=Ie.url;this._config.reuseRedirectedURL&&Ie.redirectedURL!=null&&(qe=Ie.redirectedURL);let st=this._seekHandler.getConfig(qe,Ze);this._requestURL=st.url;let mt=this._xhr=new XMLHttpRequest;if(mt.open("GET",st.url,!0),mt.responseType="moz-chunked-arraybuffer",mt.onreadystatechange=this._onReadyStateChange.bind(this),mt.onprogress=this._onProgress.bind(this),mt.onloadend=this._onLoadEnd.bind(this),mt.onerror=this._onXhrError.bind(this),Ie.withCredentials&&(mt.withCredentials=!0),typeof st.headers=="object"){let Bt=st.headers;for(let kt in Bt)Bt.hasOwnProperty(kt)&&mt.setRequestHeader(kt,Bt[kt])}if(typeof this._config.headers=="object"){let Bt=this._config.headers;for(let kt in Bt)Bt.hasOwnProperty(kt)&&mt.setRequestHeader(kt,Bt[kt])}this._status=x.kConnecting,mt.send()}abort(){this._requestAbort=!0,this._xhr&&this._xhr.abort(),this._status=x.kComplete}_onReadyStateChange(Ie){let Ze=Ie.target;if(Ze.readyState===2){if(Ze.responseURL!=null&&Ze.responseURL!==this._requestURL&&this._onURLRedirect){let qe=this._seekHandler.removeURLParameters(Ze.responseURL);this._onURLRedirect(qe)}if(Ze.status!==0&&(Ze.status<200||Ze.status>299))if(this._status=x.kError,this._onError)this._onError(re.HTTP_STATUS_CODE_INVALID,{code:Ze.status,msg:Ze.statusText});else throw new ne("MozChunkedLoader: Http code invalid, "+Ze.status+" "+Ze.statusText);else this._status=x.kBuffering}}_onProgress(Ie){if(this._status===x.kError)return;this._contentLength===null&&Ie.total!==null&&Ie.total!==0&&(this._contentLength=Ie.total,this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength));let Ze=Ie.target.response,qe=this._range.from+this._receivedLength;this._receivedLength+=Ze.byteLength,this._onDataArrival&&this._onDataArrival(Ze,qe,this._receivedLength)}_onLoadEnd(Ie){if(this._requestAbort===!0){this._requestAbort=!1;return}else if(this._status===x.kError)return;this._status=x.kComplete,this._onComplete&&this._onComplete(this._range.from,this._range.from+this._receivedLength-1)}_onXhrError(Ie){this._status=x.kError;let Ze=0,qe=null;if(this._contentLength&&Ie.loaded<this._contentLength?(Ze=re.EARLY_EOF,qe={code:-1,msg:"Moz-Chunked stream meet Early-Eof"}):(Ze=re.EXCEPTION,qe={code:-1,msg:Ie.constructor.name+" "+Ie.type}),this._onError)this._onError(Ze,qe);else throw new ne(qe.msg)}}var he=_e;class pe extends null{static isSupported(){try{if(typeof self.MSStream=="undefined"||typeof self.MSStreamReader=="undefined")return!1;let Ie=new XMLHttpRequest;return Ie.open("GET","https://example.com",!0),Ie.responseType="ms-stream",Ie.responseType==="ms-stream"}catch(Ie){return Log.w("MSStreamLoader",Ie.message),!1}}constructor(Ie,Ze){super("xhr-msstream-loader"),this.TAG="MSStreamLoader",this._seekHandler=Ie,this._config=Ze,this._needStash=!0,this._xhr=null,this._reader=null,this._totalRange=null,this._currentRange=null,this._currentRequestURL=null,this._currentRedirectedURL=null,this._contentLength=null,this._receivedLength=0,this._bufferLimit=16*1024*1024,this._lastTimeBufferSize=0,this._isReconnecting=!1}destroy(){this.isWorking()&&this.abort(),this._reader&&(this._reader.onprogress=null,this._reader.onload=null,this._reader.onerror=null,this._reader=null),this._xhr&&(this._xhr.onreadystatechange=null,this._xhr=null),super.destroy()}open(Ie,Ze){this._internalOpen(Ie,Ze,!1)}_internalOpen(Ie,Ze,qe){this._dataSource=Ie,qe?this._currentRange=Ze:this._totalRange=Ze;let st=Ie.url;this._config.reuseRedirectedURL&&(this._currentRedirectedURL!=null?st=this._currentRedirectedURL:Ie.redirectedURL!=null&&(st=Ie.redirectedURL));let mt=this._seekHandler.getConfig(st,Ze);this._currentRequestURL=mt.url;let Bt=this._reader=new self.MSStreamReader;Bt.onprogress=this._msrOnProgress.bind(this),Bt.onload=this._msrOnLoad.bind(this),Bt.onerror=this._msrOnError.bind(this);let kt=this._xhr=new XMLHttpRequest;if(kt.open("GET",mt.url,!0),kt.responseType="ms-stream",kt.onreadystatechange=this._xhrOnReadyStateChange.bind(this),kt.onerror=this._xhrOnError.bind(this),Ie.withCredentials&&(kt.withCredentials=!0),typeof mt.headers=="object"){let Ft=mt.headers;for(let qt in Ft)Ft.hasOwnProperty(qt)&&kt.setRequestHeader(qt,Ft[qt])}if(typeof this._config.headers=="object"){let Ft=this._config.headers;for(let qt in Ft)Ft.hasOwnProperty(qt)&&kt.setRequestHeader(qt,Ft[qt])}this._isReconnecting?this._isReconnecting=!1:this._status=LoaderStatus.kConnecting,kt.send()}abort(){this._internalAbort(),this._status=LoaderStatus.kComplete}_internalAbort(){this._reader&&(this._reader.readyState===1&&this._reader.abort(),this._reader.onprogress=null,this._reader.onload=null,this._reader.onerror=null,this._reader=null),this._xhr&&(this._xhr.abort(),this._xhr.onreadystatechange=null,this._xhr=null)}_xhrOnReadyStateChange(Ie){let Ze=Ie.target;if(Ze.readyState===2)if(Ze.status>=200&&Ze.status<=299){if(this._status=LoaderStatus.kBuffering,Ze.responseURL!=null){let st=this._seekHandler.removeURLParameters(Ze.responseURL);Ze.responseURL!==this._currentRequestURL&&st!==this._currentRedirectedURL&&(this._currentRedirectedURL=st,this._onURLRedirect&&this._onURLRedirect(st))}let qe=Ze.getResponseHeader("Content-Length");if(qe!=null&&this._contentLength==null){let st=parseInt(qe);st>0&&(this._contentLength=st,this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength))}}else if(this._status=LoaderStatus.kError,this._onError)this._onError(LoaderErrors.HTTP_STATUS_CODE_INVALID,{code:Ze.status,msg:Ze.statusText});else throw new RuntimeException("MSStreamLoader: Http code invalid, "+Ze.status+" "+Ze.statusText);else if(Ze.readyState===3&&Ze.status>=200&&Ze.status<=299){this._status=LoaderStatus.kBuffering;let qe=Ze.response;this._reader.readAsArrayBuffer(qe)}}_xhrOnError(Ie){this._status=LoaderStatus.kError;let Ze=LoaderErrors.EXCEPTION,qe={code:-1,msg:Ie.constructor.name+" "+Ie.type};if(this._onError)this._onError(Ze,qe);else throw new RuntimeException(qe.msg)}_msrOnProgress(Ie){let qe=Ie.target.result;if(qe==null){this._doReconnectIfNeeded();return}let st=qe.slice(this._lastTimeBufferSize);this._lastTimeBufferSize=qe.byteLength;let mt=this._totalRange.from+this._receivedLength;this._receivedLength+=st.byteLength,this._onDataArrival&&this._onDataArrival(st,mt,this._receivedLength),qe.byteLength>=this._bufferLimit&&(Log.v(this.TAG,`MSStream buffer exceeded max size near ${mt+st.byteLength}, reconnecting...`),this._doReconnectIfNeeded())}_doReconnectIfNeeded(){if(this._contentLength==null||this._receivedLength<this._contentLength){this._isReconnecting=!0,this._lastTimeBufferSize=0,this._internalAbort();let Ie={from:this._totalRange.from+this._receivedLength,to:-1};this._internalOpen(this._dataSource,Ie,!0)}}_msrOnLoad(Ie){this._status=LoaderStatus.kComplete,this._onComplete&&this._onComplete(this._totalRange.from,this._totalRange.from+this._receivedLength-1)}_msrOnError(Ie){this._status=LoaderStatus.kError;let Ze=0,qe=null;if(this._contentLength&&this._receivedLength<this._contentLength?(Ze=LoaderErrors.EARLY_EOF,qe={code:-1,msg:"MSStream meet Early-Eof"}):(Ze=LoaderErrors.EARLY_EOF,qe={code:-1,msg:Ie.constructor.name+" "+Ie.type}),this._onError)this._onError(Ze,qe);else throw new RuntimeException(qe.msg)}}var ke=null;class Te extends ae{static isSupported(){try{let Ie=new XMLHttpRequest;return Ie.open("GET","https://example.com",!0),Ie.responseType="arraybuffer",Ie.responseType==="arraybuffer"}catch(Ie){return te.w("RangeLoader",Ie.message),!1}}constructor(Ie,Ze){super("xhr-range-loader"),this.TAG="RangeLoader",this._seekHandler=Ie,this._config=Ze,this._needStash=!1,this._chunkSizeKBList=[128,256,384,512,768,1024,1536,2048,3072,4096,5120,6144,7168,8192],this._currentChunkSizeKB=384,this._currentSpeedNormalized=0,this._zeroSpeedChunkCount=0,this._xhr=null,this._speedSampler=new ee,this._requestAbort=!1,this._waitForTotalLength=!1,this._totalLengthReceived=!1,this._currentRequestURL=null,this._currentRedirectedURL=null,this._currentRequestRange=null,this._totalLength=null,this._contentLength=null,this._receivedLength=0,this._lastTimeLoaded=0}destroy(){this.isWorking()&&this.abort(),this._xhr&&(this._xhr.onreadystatechange=null,this._xhr.onprogress=null,this._xhr.onload=null,this._xhr.onerror=null,this._xhr=null),super.destroy()}get currentSpeed(){return this._speedSampler.lastSecondKBps}open(Ie,Ze){this._dataSource=Ie,this._range=Ze,this._status=x.kConnecting;let qe=!1;this._dataSource.filesize!=null&&this._dataSource.filesize!==0&&(qe=!0,this._totalLength=this._dataSource.filesize),!this._totalLengthReceived&&!qe?(this._waitForTotalLength=!0,this._internalOpen(this._dataSource,{from:0,to:-1})):this._openSubRange()}_openSubRange(){let Ie=this._currentChunkSizeKB*1024,Ze=this._range.from+this._receivedLength,qe=Ze+Ie;this._contentLength!=null&&qe-this._range.from>=this._contentLength&&(qe=this._range.from+this._contentLength-1),this._currentRequestRange={from:Ze,to:qe},this._internalOpen(this._dataSource,this._currentRequestRange)}_internalOpen(Ie,Ze){this._lastTimeLoaded=0;let qe=Ie.url;this._config.reuseRedirectedURL&&(this._currentRedirectedURL!=null?qe=this._currentRedirectedURL:Ie.redirectedURL!=null&&(qe=Ie.redirectedURL));let st=this._seekHandler.getConfig(qe,Ze);this._currentRequestURL=st.url;let mt=this._xhr=new XMLHttpRequest;if(mt.open("GET",st.url,!0),mt.responseType="arraybuffer",mt.onreadystatechange=this._onReadyStateChange.bind(this),mt.onprogress=this._onProgress.bind(this),mt.onload=this._onLoad.bind(this),mt.onerror=this._onXhrError.bind(this),Ie.withCredentials&&(mt.withCredentials=!0),typeof st.headers=="object"){let Bt=st.headers;for(let kt in Bt)Bt.hasOwnProperty(kt)&&mt.setRequestHeader(kt,Bt[kt])}if(typeof this._config.headers=="object"){let Bt=this._config.headers;for(let kt in Bt)Bt.hasOwnProperty(kt)&&mt.setRequestHeader(kt,Bt[kt])}mt.send()}abort(){this._requestAbort=!0,this._internalAbort(),this._status=x.kComplete}_internalAbort(){this._xhr&&(this._xhr.onreadystatechange=null,this._xhr.onprogress=null,this._xhr.onload=null,this._xhr.onerror=null,this._xhr.abort(),this._xhr=null)}_onReadyStateChange(Ie){let Ze=Ie.target;if(Ze.readyState===2){if(Ze.responseURL!=null){let qe=this._seekHandler.removeURLParameters(Ze.responseURL);Ze.responseURL!==this._currentRequestURL&&qe!==this._currentRedirectedURL&&(this._currentRedirectedURL=qe,this._onURLRedirect&&this._onURLRedirect(qe))}if(Ze.status>=200&&Ze.status<=299){if(this._waitForTotalLength)return;this._status=x.kBuffering}else if(this._status=x.kError,this._onError)this._onError(re.HTTP_STATUS_CODE_INVALID,{code:Ze.status,msg:Ze.statusText});else throw new ne("RangeLoader: Http code invalid, "+Ze.status+" "+Ze.statusText)}}_onProgress(Ie){if(this._status===x.kError)return;if(this._contentLength===null){let qe=!1;if(this._waitForTotalLength){this._waitForTotalLength=!1,this._totalLengthReceived=!0,qe=!0;let st=Ie.total;this._internalAbort(),st!=null&st!==0&&(this._totalLength=st)}if(this._range.to===-1?this._contentLength=this._totalLength-this._range.from:this._contentLength=this._range.to-this._range.from+1,qe){this._openSubRange();return}this._onContentLengthKnown&&this._onContentLengthKnown(this._contentLength)}let Ze=Ie.loaded-this._lastTimeLoaded;this._lastTimeLoaded=Ie.loaded,this._speedSampler.addBytes(Ze)}_normalizeSpeed(Ie){let Ze=this._chunkSizeKBList,qe=Ze.length-1,st=0,mt=0,Bt=qe;if(Ie<Ze[0])return Ze[0];for(;mt<=Bt;){if(st=mt+Math.floor((Bt-mt)/2),st===qe||Ie>=Ze[st]&&Ie<Ze[st+1])return Ze[st];Ze[st]<Ie?mt=st+1:Bt=st-1}}_onLoad(Ie){if(this._status===x.kError)return;if(this._waitForTotalLength){this._waitForTotalLength=!1;return}this._lastTimeLoaded=0;let Ze=this._speedSampler.lastSecondKBps;if(Ze===0&&(this._zeroSpeedChunkCount++,this._zeroSpeedChunkCount>=3&&(Ze=this._speedSampler.currentKBps)),Ze!==0){let Bt=this._normalizeSpeed(Ze);this._currentSpeedNormalized!==Bt&&(this._currentSpeedNormalized=Bt,this._currentChunkSizeKB=Bt)}let qe=Ie.target.response,st=this._range.from+this._receivedLength;this._receivedLength+=qe.byteLength;let mt=!1;this._contentLength!=null&&this._receivedLength<this._contentLength?this._openSubRange():mt=!0,this._onDataArrival&&this._onDataArrival(qe,st,this._receivedLength),mt&&(this._status=x.kComplete,this._onComplete&&this._onComplete(this._range.from,this._range.from+this._receivedLength-1))}_onXhrError(Ie){this._status=x.kError;let Ze=0,qe=null;if(this._contentLength&&this._receivedLength>0&&this._receivedLength<this._contentLength?(Ze=re.EARLY_EOF,qe={code:-1,msg:"RangeLoader meet Early-Eof"}):(Ze=re.EXCEPTION,qe={code:-1,msg:Ie.constructor.name+" "+Ie.type}),this._onError)this._onError(Ze,qe);else throw new ne(qe.msg)}}var Ee=Te;class Oe extends ae{static isSupported(){try{return typeof self.WebSocket!="undefined"}catch(Ie){return!1}}constructor(){super("websocket-loader"),this.TAG="WebSocketLoader",this._needStash=!0,this._ws=null,this._requestAbort=!1,this._receivedLength=0}destroy(){this._ws&&this.abort(),super.destroy()}open(Ie){try{let Ze=this._ws=new self.WebSocket(Ie.url);Ze.binaryType="arraybuffer",Ze.onopen=this._onWebSocketOpen.bind(this),Ze.onclose=this._onWebSocketClose.bind(this),Ze.onmessage=this._onWebSocketMessage.bind(this),Ze.onerror=this._onWebSocketError.bind(this),this._status=x.kConnecting}catch(Ze){this._status=x.kError;let qe={code:Ze.code,msg:Ze.message};if(this._onError)this._onError(re.EXCEPTION,qe);else throw new ne(qe.msg)}}abort(){let Ie=this._ws;Ie&&(Ie.readyState===0||Ie.readyState===1)&&(this._requestAbort=!0,Ie.close()),this._ws=null,this._status=x.kComplete}_onWebSocketOpen(Ie){this._status=x.kBuffering}_onWebSocketClose(Ie){if(this._requestAbort===!0){this._requestAbort=!1;return}this._status=x.kComplete,this._onComplete&&this._onComplete(0,this._receivedLength-1)}_onWebSocketMessage(Ie){if(Ie.data instanceof ArrayBuffer)this._dispatchArrayBuffer(Ie.data);else if(Ie.data instanceof Blob){let Ze=new FileReader;Ze.onload=()=>{this._dispatchArrayBuffer(Ze.result)},Ze.readAsArrayBuffer(Ie.data)}else{this._status=x.kError;let Ze={code:-1,msg:"Unsupported WebSocket message type: "+Ie.data.constructor.name};if(this._onError)this._onError(re.EXCEPTION,Ze);else throw new ne(Ze.msg)}}_dispatchArrayBuffer(Ie){let Ze=Ie,qe=this._receivedLength;this._receivedLength+=Ze.byteLength,this._onDataArrival&&this._onDataArrival(Ze,qe,this._receivedLength)}_onWebSocketError(Ie){this._status=x.kError;let Ze={code:Ie.code,msg:Ie.message};if(this._onError)this._onError(re.EXCEPTION,Ze);else throw new ne(Ze.msg)}}var je=Oe;class Pe{constructor(Ie){this._zeroStart=Ie||!1}getConfig(Ie,Ze){let qe={};if(Ze.from!==0||Ze.to!==-1){let st;Ze.to!==-1?st=`bytes=${Ze.from.toString()}-${Ze.to.toString()}`:st=`bytes=${Ze.from.toString()}-`,qe.Range=st}else this._zeroStart&&(qe.Range="bytes=0-");return{url:Ie,headers:qe}}removeURLParameters(Ie){return Ie}}var Qe=Pe;class Xe{constructor(Ie,Ze){this._startName=Ie,this._endName=Ze}getConfig(Ie,Ze){let qe=Ie;if(Ze.from!==0||Ze.to!==-1){let st=!0;qe.indexOf("?")===-1&&(qe+="?",st=!1),st&&(qe+="&"),qe+=`${this._startName}=${Ze.from.toString()}`,Ze.to!==-1&&(qe+=`&${this._endName}=${Ze.to.toString()}`)}return{url:qe,headers:{}}}removeURLParameters(Ie){let Ze=Ie.split("?")[0],qe,st=Ie.indexOf("?");st!==-1&&(qe=Ie.substring(st+1));let mt="";if(qe!=null&&qe.length>0){let Bt=qe.split("&");for(let kt=0;kt<Bt.length;kt++){let Ft=Bt[kt].split("="),qt=kt>0;Ft[0]!==this._startName&&Ft[0]!==this._endName&&(qt&&(mt+="&"),mt+=Bt[kt])}}return mt.length===0?Ze:Ze+"?"+mt}}var ot=Xe;class He{constructor(Ie,Ze,qe){this.TAG="IOController",this._config=Ze,this._extraData=qe,this._stashInitialSize=1024*384,Ze.stashInitialSize!=null&&Ze.stashInitialSize>0&&(this._stashInitialSize=Ze.stashInitialSize),this._stashUsed=0,this._stashSize=this._stashInitialSize,this._bufferSize=1024*1024*3,this._stashBuffer=new ArrayBuffer(this._bufferSize),this._stashByteStart=0,this._enableStash=!0,Ze.enableStashBuffer===!1&&(this._enableStash=!1),this._loader=null,this._loaderClass=null,this._seekHandler=null,this._dataSource=Ie,this._isWebSocketURL=/wss?:\/\/(.+?)/.test(Ie.url),this._refTotalLength=Ie.filesize?Ie.filesize:null,this._totalLength=this._refTotalLength,this._fullRequestFlag=!1,this._currentRange=null,this._redirectedURL=null,this._speedNormalized=0,this._speedSampler=new ee,this._speedNormalizeList=[64,128,256,384,512,768,1024,1536,2048,3072,4096],this._isEarlyEofReconnecting=!1,this._paused=!1,this._resumeFrom=0,this._onDataArrival=null,this._onSeeked=null,this._onError=null,this._onComplete=null,this._onRedirect=null,this._onRecoveredEarlyEof=null,this._selectSeekHandler(),this._selectLoader(),this._createLoader()}destroy(){this._loader.isWorking()&&this._loader.abort(),this._loader.destroy(),this._loader=null,this._loaderClass=null,this._dataSource=null,this._stashBuffer=null,this._stashUsed=this._stashSize=this._bufferSize=this._stashByteStart=0,this._currentRange=null,this._speedSampler=null,this._isEarlyEofReconnecting=!1,this._onDataArrival=null,this._onSeeked=null,this._onError=null,this._onComplete=null,this._onRedirect=null,this._onRecoveredEarlyEof=null,this._extraData=null}isWorking(){return this._loader&&this._loader.isWorking()&&!this._paused}isPaused(){return this._paused}get status(){return this._loader.status}get extraData(){return this._extraData}set extraData(Ie){this._extraData=Ie}get onDataArrival(){return this._onDataArrival}set onDataArrival(Ie){this._onDataArrival=Ie}get onSeeked(){return this._onSeeked}set onSeeked(Ie){this._onSeeked=Ie}get onError(){return this._onError}set onError(Ie){this._onError=Ie}get onComplete(){return this._onComplete}set onComplete(Ie){this._onComplete=Ie}get onRedirect(){return this._onRedirect}set onRedirect(Ie){this._onRedirect=Ie}get onRecoveredEarlyEof(){return this._onRecoveredEarlyEof}set onRecoveredEarlyEof(Ie){this._onRecoveredEarlyEof=Ie}get currentURL(){return this._dataSource.url}get hasRedirect(){return this._redirectedURL!=null||this._dataSource.redirectedURL!=null}get currentRedirectedURL(){return this._redirectedURL||this._dataSource.redirectedURL}get currentSpeed(){return this._loaderClass===Ee?this._loader.currentSpeed:this._speedSampler.lastSecondKBps}get loaderType(){return this._loader.type}_selectSeekHandler(){let Ie=this._config;if(Ie.seekType==="range")this._seekHandler=new Qe(this._config.rangeLoadZeroStart);else if(Ie.seekType==="param"){let Ze=Ie.seekParamStart||"bstart",qe=Ie.seekParamEnd||"bend";this._seekHandler=new ot(Ze,qe)}else if(Ie.seekType==="custom"){if(typeof Ie.customSeekHandler!="function")throw new b("Custom seekType specified in config but invalid customSeekHandler!");this._seekHandler=new Ie.customSeekHandler}else throw new b(`Invalid seekType in config: ${Ie.seekType}`)}_selectLoader(){if(this._config.customLoader!=null)this._loaderClass=this._config.customLoader;else if(this._isWebSocketURL)this._loaderClass=je;else if(ge.isSupported())this._loaderClass=ge;else if(he.isSupported())this._loaderClass=he;else if(Ee.isSupported())this._loaderClass=Ee;else throw new ne("Your browser doesn't support xhr with arraybuffer responseType!")}_createLoader(){this._loader=new this._loaderClass(this._seekHandler,this._config),this._loader.needStashBuffer===!1&&(this._enableStash=!1),this._loader.onContentLengthKnown=this._onContentLengthKnown.bind(this),this._loader.onURLRedirect=this._onURLRedirect.bind(this),this._loader.onDataArrival=this._onLoaderChunkArrival.bind(this),this._loader.onComplete=this._onLoaderComplete.bind(this),this._loader.onError=this._onLoaderError.bind(this)}open(Ie){this._currentRange={from:0,to:-1},Ie&&(this._currentRange.from=Ie),this._speedSampler.reset(),Ie||(this._fullRequestFlag=!0),this._loader.open(this._dataSource,Object.assign({},this._currentRange))}abort(){this._loader.abort(),this._paused&&(this._paused=!1,this._resumeFrom=0)}pause(){this.isWorking()&&(this._loader.abort(),this._stashUsed!==0?(this._resumeFrom=this._stashByteStart,this._currentRange.to=this._stashByteStart-1):this._resumeFrom=this._currentRange.to+1,this._stashUsed=0,this._stashByteStart=0,this._paused=!0)}resume(){if(this._paused){this._paused=!1;let Ie=this._resumeFrom;this._resumeFrom=0,this._internalSeek(Ie,!0)}}seek(Ie){this._paused=!1,this._stashUsed=0,this._stashByteStart=0,this._internalSeek(Ie,!0)}_internalSeek(Ie,Ze){this._loader.isWorking()&&this._loader.abort(),this._flushStashBuffer(Ze),this._loader.destroy(),this._loader=null;let qe={from:Ie,to:-1};this._currentRange={from:qe.from,to:-1},this._speedSampler.reset(),this._stashSize=this._stashInitialSize,this._createLoader(),this._loader.open(this._dataSource,qe),this._onSeeked&&this._onSeeked()}updateUrl(Ie){if(!Ie||typeof Ie!="string"||Ie.length===0)throw new b("Url must be a non-empty string!");this._dataSource.url=Ie}_expandBuffer(Ie){let Ze=this._stashSize;for(;Ze+1024*1024*1<Ie;)Ze*=2;if(Ze+=1024*1024*1,Ze===this._bufferSize)return;let qe=new ArrayBuffer(Ze);if(this._stashUsed>0){let st=new Uint8Array(this._stashBuffer,0,this._stashUsed);new Uint8Array(qe,0,Ze).set(st,0)}this._stashBuffer=qe,this._bufferSize=Ze}_normalizeSpeed(Ie){let Ze=this._speedNormalizeList,qe=Ze.length-1,st=0,mt=0,Bt=qe;if(Ie<Ze[0])return Ze[0];for(;mt<=Bt;){if(st=mt+Math.floor((Bt-mt)/2),st===qe||Ie>=Ze[st]&&Ie<Ze[st+1])return Ze[st];Ze[st]<Ie?mt=st+1:Bt=st-1}}_adjustStashSize(Ie){let Ze=0;this._config.isLive||Ie<512?Ze=Ie:Ie>=512&&Ie<=1024?Ze=Math.floor(Ie*1.5):Ze=Ie*2,Ze>8192&&(Ze=8192);let qe=Ze*1024+1024*1024*1;this._bufferSize<qe&&this._expandBuffer(qe),this._stashSize=Ze*1024}_dispatchChunks(Ie,Ze){return this._currentRange.to=Ze+Ie.byteLength-1,this._onDataArrival(Ie,Ze)}_onURLRedirect(Ie){this._redirectedURL=Ie,this._onRedirect&&this._onRedirect(Ie)}_onContentLengthKnown(Ie){Ie&&this._fullRequestFlag&&(this._totalLength=Ie,this._fullRequestFlag=!1)}_onLoaderChunkArrival(Ie,Ze,qe){if(!this._onDataArrival)throw new E("IOController: No existing consumer (onDataArrival) callback!");if(this._paused)return;this._isEarlyEofReconnecting&&(this._isEarlyEofReconnecting=!1,this._onRecoveredEarlyEof&&this._onRecoveredEarlyEof()),this._speedSampler.addBytes(Ie.byteLength);let st=this._speedSampler.lastSecondKBps;if(st!==0){let mt=this._normalizeSpeed(st);this._speedNormalized!==mt&&(this._speedNormalized=mt,this._adjustStashSize(mt))}if(this._enableStash)if(this._stashUsed===0&&this._stashByteStart===0&&(this._stashByteStart=Ze),this._stashUsed+Ie.byteLength<=this._stashSize)new Uint8Array(this._stashBuffer,0,this._stashSize).set(new Uint8Array(Ie),this._stashUsed),this._stashUsed+=Ie.byteLength;else{let mt=new Uint8Array(this._stashBuffer,0,this._bufferSize);if(this._stashUsed>0){let Bt=this._stashBuffer.slice(0,this._stashUsed),kt=this._dispatchChunks(Bt,this._stashByteStart);if(kt<Bt.byteLength){if(kt>0){let Ft=new Uint8Array(Bt,kt);mt.set(Ft,0),this._stashUsed=Ft.byteLength,this._stashByteStart+=kt}}else this._stashUsed=0,this._stashByteStart+=kt;this._stashUsed+Ie.byteLength>this._bufferSize&&(this._expandBuffer(this._stashUsed+Ie.byteLength),mt=new Uint8Array(this._stashBuffer,0,this._bufferSize)),mt.set(new Uint8Array(Ie),this._stashUsed),this._stashUsed+=Ie.byteLength}else{let Bt=this._dispatchChunks(Ie,Ze);if(Bt<Ie.byteLength){let kt=Ie.byteLength-Bt;kt>this._bufferSize&&(this._expandBuffer(kt),mt=new Uint8Array(this._stashBuffer,0,this._bufferSize)),mt.set(new Uint8Array(Ie,Bt),0),this._stashUsed+=kt,this._stashByteStart=Ze+Bt}}}else if(this._stashUsed===0){let mt=this._dispatchChunks(Ie,Ze);if(mt<Ie.byteLength){let Bt=Ie.byteLength-mt;Bt>this._bufferSize&&this._expandBuffer(Bt),new Uint8Array(this._stashBuffer,0,this._bufferSize).set(new Uint8Array(Ie,mt),0),this._stashUsed+=Bt,this._stashByteStart=Ze+mt}}else{this._stashUsed+Ie.byteLength>this._bufferSize&&this._expandBuffer(this._stashUsed+Ie.byteLength);let mt=new Uint8Array(this._stashBuffer,0,this._bufferSize);mt.set(new Uint8Array(Ie),this._stashUsed),this._stashUsed+=Ie.byteLength;let Bt=this._dispatchChunks(this._stashBuffer.slice(0,this._stashUsed),this._stashByteStart);if(Bt<this._stashUsed&&Bt>0){let kt=new Uint8Array(this._stashBuffer,Bt);mt.set(kt,0)}this._stashUsed-=Bt,this._stashByteStart+=Bt}}_flushStashBuffer(Ie){if(this._stashUsed>0){let Ze=this._stashBuffer.slice(0,this._stashUsed),qe=this._dispatchChunks(Ze,this._stashByteStart),st=Ze.byteLength-qe;if(qe<Ze.byteLength)if(Ie)te.w(this.TAG,`${st} bytes unconsumed data remain when flush buffer, dropped`);else{if(qe>0){let mt=new Uint8Array(this._stashBuffer,0,this._bufferSize),Bt=new Uint8Array(Ze,qe);mt.set(Bt,0),this._stashUsed=Bt.byteLength,this._stashByteStart+=qe}return 0}return this._stashUsed=0,this._stashByteStart=0,st}return 0}_onLoaderComplete(Ie,Ze){this._flushStashBuffer(!0),this._onComplete&&this._onComplete(this._extraData)}_onLoaderError(Ie,Ze){switch(te.e(this.TAG,`Loader error, code = ${Ze.code}, msg = ${Ze.msg}`),this._flushStashBuffer(!1),this._isEarlyEofReconnecting&&(this._isEarlyEofReconnecting=!1,Ie=re.UNRECOVERABLE_EARLY_EOF),Ie){case re.EARLY_EOF:{if(!this._config.isLive&&this._totalLength){let qe=this._currentRange.to+1;qe<this._totalLength&&(te.w(this.TAG,"Connection lost, trying reconnect..."),this._isEarlyEofReconnecting=!0,this._internalSeek(qe,!1));return}Ie=re.UNRECOVERABLE_EARLY_EOF;break}case re.UNRECOVERABLE_EARLY_EOF:case re.CONNECTING_TIMEOUT:case re.HTTP_STATUS_CODE_INVALID:case re.EXCEPTION:break}if(this._onError)this._onError(Ie,Ze);else throw new ne("IOException: "+Ze.msg)}}var rt=He;const Ye={enableWorker:!1,enableStashBuffer:!0,stashInitialSize:void 0,isLive:!1,lazyLoad:!0,lazyLoadMaxDuration:3*60,lazyLoadRecoverDuration:30,deferLoadAfterSourceOpen:!0,autoCleanupMaxBackwardDuration:3*60,autoCleanupMinBackwardDuration:2*60,statisticsInfoReportInterval:600,fixAudioTimestampGap:!0,accurateSeek:!1,seekType:"range",seekParamStart:"bstart",seekParamEnd:"bend",rangeLoadZeroStart:!1,customSeekHandler:void 0,reuseRedirectedURL:!1,headers:void 0,customLoader:void 0};function ut(){return Object.assign({},Ye)}class Ge{static supportMSEH264Playback(){return window.MediaSource&&window.MediaSource.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"')}static supportNetworkStreamIO(){let Ie=new rt({},ut()),Ze=Ie.loaderType;return Ie.destroy(),Ze=="fetch-stream-loader"||Ze=="xhr-moz-chunked-loader"}static getNetworkLoaderTypeName(){let Ie=new rt({},ut()),Ze=Ie.loaderType;return Ie.destroy(),Ze}static supportNativeMediaPlayback(Ie){Ge.videoElement==null&&(Ge.videoElement=window.document.createElement("video"));let Ze=Ge.videoElement.canPlayType(Ie);return Ze==="probably"||Ze=="maybe"}static getFeatureList(){let Ie={mseFlvPlayback:!1,mseLiveFlvPlayback:!1,networkStreamIO:!1,networkLoaderName:"",nativeMP4H264Playback:!1,nativeWebmVP8Playback:!1,nativeWebmVP9Playback:!1};return Ie.mseFlvPlayback=Ge.supportMSEH264Playback(),Ie.networkStreamIO=Ge.supportNetworkStreamIO(),Ie.networkLoaderName=Ge.getNetworkLoaderTypeName(),Ie.mseLiveFlvPlayback=Ie.mseFlvPlayback&&Ie.networkStreamIO,Ie.nativeMP4H264Playback=Ge.supportNativeMediaPlayback('video/mp4; codecs="avc1.42001E, mp4a.40.2"'),Ie.nativeWebmVP8Playback=Ge.supportNativeMediaPlayback('video/webm; codecs="vp8.0, vorbis"'),Ie.nativeWebmVP9Playback=Ge.supportNativeMediaPlayback('video/webm; codecs="vp9"'),Ie}}var ze=Ge,$e={ERROR:"error",LOADING_COMPLETE:"loading_complete",RECOVERED_EARLY_EOF:"recovered_early_eof",MEDIA_INFO:"media_info",METADATA_ARRIVED:"metadata_arrived",SCRIPTDATA_ARRIVED:"scriptdata_arrived",STATISTICS_INFO:"statistics_info"};class nt{static get forceGlobalTag(){return te.FORCE_GLOBAL_TAG}static set forceGlobalTag(Ie){te.FORCE_GLOBAL_TAG=Ie,nt._notifyChange()}static get globalTag(){return te.GLOBAL_TAG}static set globalTag(Ie){te.GLOBAL_TAG=Ie,nt._notifyChange()}static get enableAll(){return te.ENABLE_VERBOSE&&te.ENABLE_DEBUG&&te.ENABLE_INFO&&te.ENABLE_WARN&&te.ENABLE_ERROR}static set enableAll(Ie){te.ENABLE_VERBOSE=Ie,te.ENABLE_DEBUG=Ie,te.ENABLE_INFO=Ie,te.ENABLE_WARN=Ie,te.ENABLE_ERROR=Ie,nt._notifyChange()}static get enableDebug(){return te.ENABLE_DEBUG}static set enableDebug(Ie){te.ENABLE_DEBUG=Ie,nt._notifyChange()}static get enableVerbose(){return te.ENABLE_VERBOSE}static set enableVerbose(Ie){te.ENABLE_VERBOSE=Ie,nt._notifyChange()}static get enableInfo(){return te.ENABLE_INFO}static set enableInfo(Ie){te.ENABLE_INFO=Ie,nt._notifyChange()}static get enableWarn(){return te.ENABLE_WARN}static set enableWarn(Ie){te.ENABLE_WARN=Ie,nt._notifyChange()}static get enableError(){return te.ENABLE_ERROR}static set enableError(Ie){te.ENABLE_ERROR=Ie,nt._notifyChange()}static getConfig(){return{globalTag:te.GLOBAL_TAG,forceGlobalTag:te.FORCE_GLOBAL_TAG,enableVerbose:te.ENABLE_VERBOSE,enableDebug:te.ENABLE_DEBUG,enableInfo:te.ENABLE_INFO,enableWarn:te.ENABLE_WARN,enableError:te.ENABLE_ERROR,enableCallback:te.ENABLE_CALLBACK}}static applyConfig(Ie){te.GLOBAL_TAG=Ie.globalTag,te.FORCE_GLOBAL_TAG=Ie.forceGlobalTag,te.ENABLE_VERBOSE=Ie.enableVerbose,te.ENABLE_DEBUG=Ie.enableDebug,te.ENABLE_INFO=Ie.enableInfo,te.ENABLE_WARN=Ie.enableWarn,te.ENABLE_ERROR=Ie.enableError,te.ENABLE_CALLBACK=Ie.enableCallback}static _notifyChange(){let Ie=nt.emitter;if(Ie.listenerCount("change")>0){let Ze=nt.getConfig();Ie.emit("change",Ze)}}static registerListener(Ie){nt.emitter.addListener("change",Ie)}static removeListener(Ie){nt.emitter.removeListener("change",Ie)}static addLogListener(Ie){te.emitter.addListener("log",Ie),te.emitter.listenerCount("log")>0&&(te.ENABLE_CALLBACK=!0,nt._notifyChange())}static removeLogListener(Ie){te.emitter.removeListener("log",Ie),te.emitter.listenerCount("log")===0&&(te.ENABLE_CALLBACK=!1,nt._notifyChange())}}nt.emitter=new(ue());var et=nt;class pt{constructor(){this.mimeType=null,this.duration=null,this.hasAudio=null,this.hasVideo=null,this.audioCodec=null,this.videoCodec=null,this.audioDataRate=null,this.videoDataRate=null,this.audioSampleRate=null,this.audioChannelCount=null,this.width=null,this.height=null,this.fps=null,this.profile=null,this.level=null,this.refFrames=null,this.chromaFormat=null,this.sarNum=null,this.sarDen=null,this.metadata=null,this.segments=null,this.segmentCount=null,this.hasKeyframesIndex=null,this.keyframesIndex=null}isComplete(){let Ie=this.hasAudio===!1||this.hasAudio===!0&&this.audioCodec!=null&&this.audioSampleRate!=null&&this.audioChannelCount!=null,Ze=this.hasVideo===!1||this.hasVideo===!0&&this.videoCodec!=null&&this.width!=null&&this.height!=null&&this.fps!=null&&this.profile!=null&&this.level!=null&&this.refFrames!=null&&this.chromaFormat!=null&&this.sarNum!=null&&this.sarDen!=null;return this.mimeType!=null&&this.duration!=null&&this.metadata!=null&&this.hasKeyframesIndex!=null&&Ie&&Ze}isSeekable(){return this.hasKeyframesIndex===!0}getNearestKeyframe(Ie){if(this.keyframesIndex==null)return null;let Ze=this.keyframesIndex,qe=this._search(Ze.times,Ie);return{index:qe,milliseconds:Ze.times[qe],fileposition:Ze.filepositions[qe]}}_search(Ie,Ze){let qe=0,st=Ie.length-1,mt=0,Bt=0,kt=st;for(Ze<Ie[0]&&(qe=0,Bt=kt+1);Bt<=kt;)if(mt=Bt+Math.floor((kt-Bt)/2),mt===st||Ze>=Ie[mt]&&Ze<Ie[mt+1]){qe=mt;break}else Ie[mt]<Ze?Bt=mt+1:kt=mt-1;return qe}}var ct=pt;function Ot(Jt,Ie,Ze){let qe=Jt;if(Ie+Ze<qe.length){for(;Ze--;)if((qe[++Ie]&192)!==128)return!1;return!0}else return!1}function dt(Jt){let Ie=[],Ze=Jt,qe=0,st=Jt.length;for(;qe<st;){if(Ze[qe]<128){Ie.push(String.fromCharCode(Ze[qe])),++qe;continue}else if(!(Ze[qe]<192)){if(Ze[qe]<224){if(Ot(Ze,qe,1)){let mt=(Ze[qe]&31)<<6|Ze[qe+1]&63;if(mt>=128){Ie.push(String.fromCharCode(mt&65535)),qe+=2;continue}}}else if(Ze[qe]<240){if(Ot(Ze,qe,2)){let mt=(Ze[qe]&15)<<12|(Ze[qe+1]&63)<<6|Ze[qe+2]&63;if(mt>=2048&&(mt&63488)!==55296){Ie.push(String.fromCharCode(mt&65535)),qe+=3;continue}}}else if(Ze[qe]<248&&Ot(Ze,qe,3)){let mt=(Ze[qe]&7)<<18|(Ze[qe+1]&63)<<12|(Ze[qe+2]&63)<<6|Ze[qe+3]&63;if(mt>65536&&mt<1114112){mt-=65536,Ie.push(String.fromCharCode(mt>>>10|55296)),Ie.push(String.fromCharCode(mt&1023|56320)),qe+=4;continue}}}Ie.push("\uFFFD"),++qe}return Ie.join("")}var Rt=dt;let xt=function(){let Jt=new ArrayBuffer(2);return new DataView(Jt).setInt16(0,256,!0),new Int16Array(Jt)[0]===256}();class gt{static parseScriptData(Ie,Ze,qe){let st={};try{let mt=gt.parseValue(Ie,Ze,qe),Bt=gt.parseValue(Ie,Ze+mt.size,qe-mt.size);st[mt.data]=Bt.data}catch(mt){te.e("AMF",mt.toString())}return st}static parseObject(Ie,Ze,qe){if(qe<3)throw new E("Data not enough when parse ScriptDataObject");let st=gt.parseString(Ie,Ze,qe),mt=gt.parseValue(Ie,Ze+st.size,qe-st.size),Bt=mt.objectEnd;return{data:{name:st.data,value:mt.data},size:st.size+mt.size,objectEnd:Bt}}static parseVariable(Ie,Ze,qe){return gt.parseObject(Ie,Ze,qe)}static parseString(Ie,Ze,qe){if(qe<2)throw new E("Data not enough when parse String");let mt=new DataView(Ie,Ze,qe).getUint16(0,!xt),Bt;return mt>0?Bt=Rt(new Uint8Array(Ie,Ze+2,mt)):Bt="",{data:Bt,size:2+mt}}static parseLongString(Ie,Ze,qe){if(qe<4)throw new E("Data not enough when parse LongString");let mt=new DataView(Ie,Ze,qe).getUint32(0,!xt),Bt;return mt>0?Bt=Rt(new Uint8Array(Ie,Ze+4,mt)):Bt="",{data:Bt,size:4+mt}}static parseDate(Ie,Ze,qe){if(qe<10)throw new E("Data size invalid when parse Date");let st=new DataView(Ie,Ze,qe),mt=st.getFloat64(0,!xt),Bt=st.getInt16(8,!xt);return mt+=Bt*60*1e3,{data:new Date(mt),size:10}}static parseValue(Ie,Ze,qe){if(qe<1)throw new E("Data not enough when parse Value");let st=new DataView(Ie,Ze,qe),mt=1,Bt=st.getUint8(0),kt,Ft=!1;try{switch(Bt){case 0:kt=st.getFloat64(1,!xt),mt+=8;break;case 1:{kt=!!st.getUint8(1),mt+=1;break}case 2:{let qt=gt.parseString(Ie,Ze+1,qe-1);kt=qt.data,mt+=qt.size;break}case 3:{kt={};let qt=0;for((st.getUint32(qe-4,!xt)&16777215)===9&&(qt=3);mt<qe-4;){let En=gt.parseObject(Ie,Ze+mt,qe-mt-qt);if(En.objectEnd)break;kt[En.data.name]=En.data.value,mt+=En.size}mt<=qe-3&&(st.getUint32(mt-1,!xt)&16777215)===9&&(mt+=3);break}case 8:{kt={},mt+=4;let qt=0;for((st.getUint32(qe-4,!xt)&16777215)===9&&(qt=3);mt<qe-8;){let En=gt.parseVariable(Ie,Ze+mt,qe-mt-qt);if(En.objectEnd)break;kt[En.data.name]=En.data.value,mt+=En.size}mt<=qe-3&&(st.getUint32(mt-1,!xt)&16777215)===9&&(mt+=3);break}case 9:kt=void 0,mt=1,Ft=!0;break;case 10:{kt=[];let qt=st.getUint32(1,!xt);mt+=4;for(let En=0;En<qt;En++){let Yn=gt.parseValue(Ie,Ze+mt,qe-mt);kt.push(Yn.data),mt+=Yn.size}break}case 11:{let qt=gt.parseDate(Ie,Ze+1,qe-1);kt=qt.data,mt+=qt.size;break}case 12:{let qt=gt.parseString(Ie,Ze+1,qe-1);kt=qt.data,mt+=qt.size;break}default:mt=qe,te.w("AMF","Unsupported AMF value type "+Bt)}}catch(qt){te.e("AMF",qt.toString())}return{data:kt,size:mt,objectEnd:Ft}}}var _t=gt;class We{constructor(Ie){this.TAG="ExpGolomb",this._buffer=Ie,this._buffer_index=0,this._total_bytes=Ie.byteLength,this._total_bits=Ie.byteLength*8,this._current_word=0,this._current_word_bits_left=0}destroy(){this._buffer=null}_fillCurrentWord(){let Ie=this._total_bytes-this._buffer_index;if(Ie<=0)throw new E("ExpGolomb: _fillCurrentWord() but no bytes available");let Ze=Math.min(4,Ie),qe=new Uint8Array(4);qe.set(this._buffer.subarray(this._buffer_index,this._buffer_index+Ze)),this._current_word=new DataView(qe.buffer).getUint32(0,!1),this._buffer_index+=Ze,this._current_word_bits_left=Ze*8}readBits(Ie){if(Ie>32)throw new b("ExpGolomb: readBits() bits exceeded max 32bits!");if(Ie<=this._current_word_bits_left){let Bt=this._current_word>>>32-Ie;return this._current_word<<=Ie,this._current_word_bits_left-=Ie,Bt}let Ze=this._current_word_bits_left?this._current_word:0;Ze=Ze>>>32-this._current_word_bits_left;let qe=Ie-this._current_word_bits_left;this._fillCurrentWord();let st=Math.min(qe,this._current_word_bits_left),mt=this._current_word>>>32-st;return this._current_word<<=st,this._current_word_bits_left-=st,Ze=Ze<<st|mt,Ze}readBool(){return this.readBits(1)===1}readByte(){return this.readBits(8)}_skipLeadingZero(){let Ie;for(Ie=0;Ie<this._current_word_bits_left;Ie++)if(this._current_word&2147483648>>>Ie)return this._current_word<<=Ie,this._current_word_bits_left-=Ie,Ie;return this._fillCurrentWord(),Ie+this._skipLeadingZero()}readUEG(){let Ie=this._skipLeadingZero();return this.readBits(Ie+1)-1}readSEG(){let Ie=this.readUEG();return Ie&1?Ie+1>>>1:-1*(Ie>>>1)}}var Ae=We;class Se{static _ebsp2rbsp(Ie){let Ze=Ie,qe=Ze.byteLength,st=new Uint8Array(qe),mt=0;for(let Bt=0;Bt<qe;Bt++)Bt>=2&&Ze[Bt]===3&&Ze[Bt-1]===0&&Ze[Bt-2]===0||(st[mt]=Ze[Bt],mt++);return new Uint8Array(st.buffer,0,mt)}static parseSPS(Ie){let Ze=Se._ebsp2rbsp(Ie),qe=new Ae(Ze);qe.readByte();let st=qe.readByte();qe.readByte();let mt=qe.readByte();qe.readUEG();let Bt=Se.getProfileString(st),kt=Se.getLevelString(mt),Ft=1,qt=420,En=[0,420,422,444],Yn=8;if((st===100||st===110||st===122||st===244||st===44||st===83||st===86||st===118||st===128||st===138||st===144)&&(Ft=qe.readUEG(),Ft===3&&qe.readBits(1),Ft<=3&&(qt=En[Ft]),Yn=qe.readUEG()+8,qe.readUEG(),qe.readBits(1),qe.readBool())){let Ir=Ft!==3?8:12;for(let jr=0;jr<Ir;jr++)qe.readBool()&&(jr<6?Se._skipScalingList(qe,16):Se._skipScalingList(qe,64))}qe.readUEG();let At=qe.readUEG();if(At===0)qe.readUEG();else if(At===1){qe.readBits(1),qe.readSEG(),qe.readSEG();let Ir=qe.readUEG();for(let jr=0;jr<Ir;jr++)qe.readSEG()}let St=qe.readUEG();qe.readBits(1);let an=qe.readUEG(),Wt=qe.readUEG(),Et=qe.readBits(1);Et===0&&qe.readBits(1),qe.readBits(1);let zt=0,tn=0,nn=0,gn=0;qe.readBool()&&(zt=qe.readUEG(),tn=qe.readUEG(),nn=qe.readUEG(),gn=qe.readUEG());let Tn=1,Tt=1,jn=0,bn=!0,Fn=0,Un=0;if(qe.readBool()){if(qe.readBool()){let Ir=qe.readByte(),jr=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],ti=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1];Ir>0&&Ir<16?(Tn=jr[Ir-1],Tt=ti[Ir-1]):Ir===255&&(Tn=qe.readByte()<<8|qe.readByte(),Tt=qe.readByte()<<8|qe.readByte())}if(qe.readBool()&&qe.readBool(),qe.readBool()&&(qe.readBits(4),qe.readBool()&&qe.readBits(24)),qe.readBool()&&(qe.readUEG(),qe.readUEG()),qe.readBool()){let Ir=qe.readBits(32),jr=qe.readBits(32);bn=qe.readBool(),Fn=jr,Un=Ir*2,jn=Fn/Un}}let pr=1;(Tn!==1||Tt!==1)&&(pr=Tn/Tt);let Rr=0,wr=0;if(Ft===0)Rr=1,wr=2-Et;else{let Ir=Ft===3?1:2,jr=Ft===1?2:1;Rr=Ir,wr=jr*(2-Et)}let Lr=(an+1)*16,Vr=(2-Et)*((Wt+1)*16);Lr-=(zt+tn)*Rr,Vr-=(nn+gn)*wr;let xr=Math.ceil(Lr*pr);return qe.destroy(),qe=null,{profile_string:Bt,level_string:kt,bit_depth:Yn,ref_frames:St,chroma_format:qt,chroma_format_string:Se.getChromaFormatString(qt),frame_rate:{fixed:bn,fps:jn,fps_den:Un,fps_num:Fn},sar_ratio:{width:Tn,height:Tt},codec_size:{width:Lr,height:Vr},present_size:{width:xr,height:Vr}}}static _skipScalingList(Ie,Ze){let qe=8,st=8,mt=0;for(let Bt=0;Bt<Ze;Bt++)st!==0&&(mt=Ie.readSEG(),st=(qe+mt+256)%256),qe=st===0?qe:st}static getProfileString(Ie){switch(Ie){case 66:return"Baseline";case 77:return"Main";case 88:return"Extended";case 100:return"High";case 110:return"High10";case 122:return"High422";case 244:return"High444";default:return"Unknown"}}static getLevelString(Ie){return(Ie/10).toFixed(1)}static getChromaFormatString(Ie){switch(Ie){case 420:return"4:2:0";case 422:return"4:2:2";case 444:return"4:4:4";default:return"Unknown"}}}var Be=Se,Ne={OK:"OK",FORMAT_ERROR:"FormatError",FORMAT_UNSUPPORTED:"FormatUnsupported",CODEC_UNSUPPORTED:"CodecUnsupported"};function De(Jt){return Jt>>>8&255|(Jt&255)<<8}function we(Jt){return(Jt&4278190080)>>>24|(Jt&16711680)>>>8|(Jt&65280)<<8|(Jt&255)<<24}function Le(Jt,Ie){return Jt[Ie]<<24|Jt[Ie+1]<<16|Jt[Ie+2]<<8|Jt[Ie+3]}class Ue{constructor(Ie,Ze){this.TAG="FLVDemuxer",this._config=Ze,this._onError=null,this._onMediaInfo=null,this._onMetaDataArrived=null,this._onScriptDataArrived=null,this._onTrackMetadata=null,this._onDataAvailable=null,this._dataOffset=Ie.dataOffset,this._firstParse=!0,this._dispatch=!1,this._hasAudio=Ie.hasAudioTrack,this._hasVideo=Ie.hasVideoTrack,this._hasAudioFlagOverrided=!1,this._hasVideoFlagOverrided=!1,this._audioInitialMetadataDispatched=!1,this._videoInitialMetadataDispatched=!1,this._mediaInfo=new ct,this._mediaInfo.hasAudio=this._hasAudio,this._mediaInfo.hasVideo=this._hasVideo,this._metadata=null,this._audioMetadata=null,this._videoMetadata=null,this._naluLengthSize=4,this._timestampBase=0,this._timescale=1e3,this._duration=0,this._durationOverrided=!1,this._referenceFrameRate={fixed:!0,fps:23.976,fps_num:23976,fps_den:1e3},this._flvSoundRateTable=[5500,11025,22050,44100,48e3],this._mpegSamplingRates=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],this._mpegAudioV10SampleRateTable=[44100,48e3,32e3,0],this._mpegAudioV20SampleRateTable=[22050,24e3,16e3,0],this._mpegAudioV25SampleRateTable=[11025,12e3,8e3,0],this._mpegAudioL1BitRateTable=[0,32,64,96,128,160,192,224,256,288,320,352,384,416,448,-1],this._mpegAudioL2BitRateTable=[0,32,48,56,64,80,96,112,128,160,192,224,256,320,384,-1],this._mpegAudioL3BitRateTable=[0,32,40,48,56,64,80,96,112,128,160,192,224,256,320,-1],this._videoTrack={type:"video",id:1,sequenceNumber:0,samples:[],length:0},this._audioTrack={type:"audio",id:2,sequenceNumber:0,samples:[],length:0},this._littleEndian=function(){let qe=new ArrayBuffer(2);return new DataView(qe).setInt16(0,256,!0),new Int16Array(qe)[0]===256}()}destroy(){this._mediaInfo=null,this._metadata=null,this._audioMetadata=null,this._videoMetadata=null,this._videoTrack=null,this._audioTrack=null,this._onError=null,this._onMediaInfo=null,this._onMetaDataArrived=null,this._onScriptDataArrived=null,this._onTrackMetadata=null,this._onDataAvailable=null}static probe(Ie){let Ze=new Uint8Array(Ie),qe={match:!1};if(Ze[0]!==70||Ze[1]!==76||Ze[2]!==86||Ze[3]!==1)return qe;let st=(Ze[4]&4)>>>2!==0,mt=(Ze[4]&1)!==0,Bt=Le(Ze,5);return Bt<9?qe:{match:!0,consumed:Bt,dataOffset:Bt,hasAudioTrack:st,hasVideoTrack:mt}}bindDataSource(Ie){return Ie.onDataArrival=this.parseChunks.bind(this),this}get onTrackMetadata(){return this._onTrackMetadata}set onTrackMetadata(Ie){this._onTrackMetadata=Ie}get onMediaInfo(){return this._onMediaInfo}set onMediaInfo(Ie){this._onMediaInfo=Ie}get onMetaDataArrived(){return this._onMetaDataArrived}set onMetaDataArrived(Ie){this._onMetaDataArrived=Ie}get onScriptDataArrived(){return this._onScriptDataArrived}set onScriptDataArrived(Ie){this._onScriptDataArrived=Ie}get onError(){return this._onError}set onError(Ie){this._onError=Ie}get onDataAvailable(){return this._onDataAvailable}set onDataAvailable(Ie){this._onDataAvailable=Ie}get timestampBase(){return this._timestampBase}set timestampBase(Ie){this._timestampBase=Ie}get overridedDuration(){return this._duration}set overridedDuration(Ie){this._durationOverrided=!0,this._duration=Ie,this._mediaInfo.duration=Ie}set overridedHasAudio(Ie){this._hasAudioFlagOverrided=!0,this._hasAudio=Ie,this._mediaInfo.hasAudio=Ie}set overridedHasVideo(Ie){this._hasVideoFlagOverrided=!0,this._hasVideo=Ie,this._mediaInfo.hasVideo=Ie}resetMediaInfo(){this._mediaInfo=new ct}_isInitialMetadataDispatched(){return this._hasAudio&&this._hasVideo?this._audioInitialMetadataDispatched&&this._videoInitialMetadataDispatched:this._hasAudio&&!this._hasVideo?this._audioInitialMetadataDispatched:!this._hasAudio&&this._hasVideo?this._videoInitialMetadataDispatched:!1}parseChunks(Ie,Ze){if(!this._onError||!this._onMediaInfo||!this._onTrackMetadata||!this._onDataAvailable)throw new E("Flv: onError & onMediaInfo & onTrackMetadata & onDataAvailable callback must be specified");let qe=0,st=this._littleEndian;if(Ze===0)if(Ie.byteLength>13)qe=Ue.probe(Ie).dataOffset;else return 0;for(this._firstParse&&(this._firstParse=!1,Ze+qe!==this._dataOffset&&te.w(this.TAG,"First time parsing but chunk byteStart invalid!"),new DataView(Ie,qe).getUint32(0,!st)!==0&&te.w(this.TAG,"PrevTagSize0 !== 0 !!!"),qe+=4);qe<Ie.byteLength;){this._dispatch=!0;let mt=new DataView(Ie,qe);if(qe+11+4>Ie.byteLength)break;let Bt=mt.getUint8(0),kt=mt.getUint32(0,!st)&16777215;if(qe+11+kt+4>Ie.byteLength)break;if(Bt!==8&&Bt!==9&&Bt!==18){te.w(this.TAG,`Unsupported tag type ${Bt}, skipped`),qe+=11+kt+4;continue}let Ft=mt.getUint8(4),qt=mt.getUint8(5),En=mt.getUint8(6),Yn=mt.getUint8(7),At=En|qt<<8|Ft<<16|Yn<<24;(mt.getUint32(7,!st)&16777215)!==0&&te.w(this.TAG,"Meet tag which has StreamID != 0!");let an=qe+11;switch(Bt){case 8:this._parseAudioData(Ie,an,kt,At);break;case 9:this._parseVideoData(Ie,an,kt,At,Ze+qe);break;case 18:this._parseScriptData(Ie,an,kt);break}let Wt=mt.getUint32(11+kt,!st);Wt!==11+kt&&te.w(this.TAG,`Invalid PrevTagSize ${Wt}`),qe+=11+kt+4}return this._isInitialMetadataDispatched()&&this._dispatch&&(this._audioTrack.length||this._videoTrack.length)&&this._onDataAvailable(this._audioTrack,this._videoTrack),qe}_parseScriptData(Ie,Ze,qe){let st=_t.parseScriptData(Ie,Ze,qe);if(st.hasOwnProperty("onMetaData")){if(st.onMetaData==null||typeof st.onMetaData!="object"){te.w(this.TAG,"Invalid onMetaData structure!");return}this._metadata&&te.w(this.TAG,"Found another onMetaData tag!"),this._metadata=st;let mt=this._metadata.onMetaData;if(this._onMetaDataArrived&&this._onMetaDataArrived(Object.assign({},mt)),typeof mt.hasAudio=="boolean"&&this._hasAudioFlagOverrided===!1&&(this._hasAudio=mt.hasAudio,this._mediaInfo.hasAudio=this._hasAudio),typeof mt.hasVideo=="boolean"&&this._hasVideoFlagOverrided===!1&&(this._hasVideo=mt.hasVideo,this._mediaInfo.hasVideo=this._hasVideo),typeof mt.audiodatarate=="number"&&(this._mediaInfo.audioDataRate=mt.audiodatarate),typeof mt.videodatarate=="number"&&(this._mediaInfo.videoDataRate=mt.videodatarate),typeof mt.width=="number"&&(this._mediaInfo.width=mt.width),typeof mt.height=="number"&&(this._mediaInfo.height=mt.height),typeof mt.duration=="number"){if(!this._durationOverrided){let Bt=Math.floor(mt.duration*this._timescale);this._duration=Bt,this._mediaInfo.duration=Bt}}else this._mediaInfo.duration=0;if(typeof mt.framerate=="number"){let Bt=Math.floor(mt.framerate*1e3);if(Bt>0){let kt=Bt/1e3;this._referenceFrameRate.fixed=!0,this._referenceFrameRate.fps=kt,this._referenceFrameRate.fps_num=Bt,this._referenceFrameRate.fps_den=1e3,this._mediaInfo.fps=kt}}if(typeof mt.keyframes=="object"){this._mediaInfo.hasKeyframesIndex=!0;let Bt=mt.keyframes;this._mediaInfo.keyframesIndex=this._parseKeyframesIndex(Bt),mt.keyframes=null}else this._mediaInfo.hasKeyframesIndex=!1;this._dispatch=!1,this._mediaInfo.metadata=mt,te.v(this.TAG,"Parsed onMetaData"),this._mediaInfo.isComplete()&&this._onMediaInfo(this._mediaInfo)}Object.keys(st).length>0&&this._onScriptDataArrived&&this._onScriptDataArrived(Object.assign({},st))}_parseKeyframesIndex(Ie){let Ze=[],qe=[];for(let st=1;st<Ie.times.length;st++){let mt=this._timestampBase+Math.floor(Ie.times[st]*1e3);Ze.push(mt),qe.push(Ie.filepositions[st])}return{times:Ze,filepositions:qe}}_parseAudioData(Ie,Ze,qe,st){if(qe<=1){te.w(this.TAG,"Flv: Invalid audio packet, missing SoundData payload!");return}if(this._hasAudioFlagOverrided===!0&&this._hasAudio===!1)return;let mt=this._littleEndian,kt=new DataView(Ie,Ze,qe).getUint8(0),Ft=kt>>>4;if(Ft!==2&&Ft!==10){this._onError(Ne.CODEC_UNSUPPORTED,"Flv: Unsupported audio codec idx: "+Ft);return}let qt=0,En=(kt&12)>>>2;if(En>=0&&En<=4)qt=this._flvSoundRateTable[En];else{this._onError(Ne.FORMAT_ERROR,"Flv: Invalid audio sample rate idx: "+En);return}let Yn=(kt&2)>>>1,At=kt&1,St=this._audioMetadata,an=this._audioTrack;if(St||(this._hasAudio===!1&&this._hasAudioFlagOverrided===!1&&(this._hasAudio=!0,this._mediaInfo.hasAudio=!0),St=this._audioMetadata={},St.type="audio",St.id=an.id,St.timescale=this._timescale,St.duration=this._duration,St.audioSampleRate=qt,St.channelCount=At===0?1:2),Ft===10){let Wt=this._parseAACAudioData(Ie,Ze+1,qe-1);if(Wt==null)return;if(Wt.packetType===0){St.config&&te.w(this.TAG,"Found another AudioSpecificConfig!");let Et=Wt.data;St.audioSampleRate=Et.samplingRate,St.channelCount=Et.channelCount,St.codec=Et.codec,St.originalCodec=Et.originalCodec,St.config=Et.config,St.refSampleDuration=1024/St.audioSampleRate*St.timescale,te.v(this.TAG,"Parsed AudioSpecificConfig"),this._isInitialMetadataDispatched()?this._dispatch&&(this._audioTrack.length||this._videoTrack.length)&&this._onDataAvailable(this._audioTrack,this._videoTrack):this._audioInitialMetadataDispatched=!0,this._dispatch=!1,this._onTrackMetadata("audio",St);let zt=this._mediaInfo;zt.audioCodec=St.originalCodec,zt.audioSampleRate=St.audioSampleRate,zt.audioChannelCount=St.channelCount,zt.hasVideo?zt.videoCodec!=null&&(zt.mimeType='video/x-flv; codecs="'+zt.videoCodec+","+zt.audioCodec+'"'):zt.mimeType='video/x-flv; codecs="'+zt.audioCodec+'"',zt.isComplete()&&this._onMediaInfo(zt)}else if(Wt.packetType===1){let Et=this._timestampBase+st,zt={unit:Wt.data,length:Wt.data.byteLength,dts:Et,pts:Et};an.samples.push(zt),an.length+=Wt.data.length}else te.e(this.TAG,`Flv: Unsupported AAC data type ${Wt.packetType}`)}else if(Ft===2){if(!St.codec){let tn=this._parseMP3AudioData(Ie,Ze+1,qe-1,!0);if(tn==null)return;St.audioSampleRate=tn.samplingRate,St.channelCount=tn.channelCount,St.codec=tn.codec,St.originalCodec=tn.originalCodec,St.refSampleDuration=1152/St.audioSampleRate*St.timescale,te.v(this.TAG,"Parsed MPEG Audio Frame Header"),this._audioInitialMetadataDispatched=!0,this._onTrackMetadata("audio",St);let nn=this._mediaInfo;nn.audioCodec=St.codec,nn.audioSampleRate=St.audioSampleRate,nn.audioChannelCount=St.channelCount,nn.audioDataRate=tn.bitRate,nn.hasVideo?nn.videoCodec!=null&&(nn.mimeType='video/x-flv; codecs="'+nn.videoCodec+","+nn.audioCodec+'"'):nn.mimeType='video/x-flv; codecs="'+nn.audioCodec+'"',nn.isComplete()&&this._onMediaInfo(nn)}let Wt=this._parseMP3AudioData(Ie,Ze+1,qe-1,!1);if(Wt==null)return;let Et=this._timestampBase+st,zt={unit:Wt,length:Wt.byteLength,dts:Et,pts:Et};an.samples.push(zt),an.length+=Wt.length}}_parseAACAudioData(Ie,Ze,qe){if(qe<=1){te.w(this.TAG,"Flv: Invalid AAC packet, missing AACPacketType or/and Data!");return}let st={},mt=new Uint8Array(Ie,Ze,qe);return st.packetType=mt[0],mt[0]===0?st.data=this._parseAACAudioSpecificConfig(Ie,Ze+1,qe-1):st.data=mt.subarray(1),st}_parseAACAudioSpecificConfig(Ie,Ze,qe){let st=new Uint8Array(Ie,Ze,qe),mt=null,Bt=0,kt=0,Ft=null,qt=0,En=null;if(Bt=kt=st[0]>>>3,qt=(st[0]&7)<<1|st[1]>>>7,qt<0||qt>=this._mpegSamplingRates.length){this._onError(Ne.FORMAT_ERROR,"Flv: AAC invalid sampling frequency index!");return}let Yn=this._mpegSamplingRates[qt],At=(st[1]&120)>>>3;if(At<0||At>=8){this._onError(Ne.FORMAT_ERROR,"Flv: AAC invalid channel configuration");return}Bt===5&&(En=(st[1]&7)<<1|st[2]>>>7,Ft=(st[2]&124)>>>2);let St=self.navigator.userAgent.toLowerCase();return St.indexOf("firefox")!==-1?qt>=6?(Bt=5,mt=new Array(4),En=qt-3):(Bt=2,mt=new Array(2),En=qt):St.indexOf("android")!==-1?(Bt=2,mt=new Array(2),En=qt):(Bt=5,En=qt,mt=new Array(4),qt>=6?En=qt-3:At===1&&(Bt=2,mt=new Array(2),En=qt)),mt[0]=Bt<<3,mt[0]|=(qt&15)>>>1,mt[1]=(qt&15)<<7,mt[1]|=(At&15)<<3,Bt===5&&(mt[1]|=(En&15)>>>1,mt[2]=(En&1)<<7,mt[2]|=8,mt[3]=0),{config:mt,samplingRate:Yn,channelCount:At,codec:"mp4a.40."+Bt,originalCodec:"mp4a.40."+kt}}_parseMP3AudioData(Ie,Ze,qe,st){if(qe<4){te.w(this.TAG,"Flv: Invalid MP3 packet, header missing!");return}let mt=this._littleEndian,Bt=new Uint8Array(Ie,Ze,qe),kt=null;if(st){if(Bt[0]!==255)return;let Ft=Bt[1]>>>3&3,qt=(Bt[1]&6)>>1,En=(Bt[2]&240)>>>4,Yn=(Bt[2]&12)>>>2,St=(Bt[3]>>>6&3)!==3?2:1,an=0,Wt=0,Et=34,zt="mp3";switch(Ft){case 0:an=this._mpegAudioV25SampleRateTable[Yn];break;case 2:an=this._mpegAudioV20SampleRateTable[Yn];break;case 3:an=this._mpegAudioV10SampleRateTable[Yn];break}switch(qt){case 1:Et=34,En<this._mpegAudioL3BitRateTable.length&&(Wt=this._mpegAudioL3BitRateTable[En]);break;case 2:Et=33,En<this._mpegAudioL2BitRateTable.length&&(Wt=this._mpegAudioL2BitRateTable[En]);break;case 3:Et=32,En<this._mpegAudioL1BitRateTable.length&&(Wt=this._mpegAudioL1BitRateTable[En]);break}kt={bitRate:Wt,samplingRate:an,channelCount:St,codec:zt,originalCodec:zt}}else kt=Bt;return kt}_parseVideoData(Ie,Ze,qe,st,mt){if(qe<=1){te.w(this.TAG,"Flv: Invalid video packet, missing VideoData payload!");return}if(this._hasVideoFlagOverrided===!0&&this._hasVideo===!1)return;let Bt=new Uint8Array(Ie,Ze,qe)[0],kt=(Bt&240)>>>4,Ft=Bt&15;if(Ft!==7){this._onError(Ne.CODEC_UNSUPPORTED,`Flv: Unsupported codec in video frame: ${Ft}`);return}this._parseAVCVideoPacket(Ie,Ze+1,qe-1,st,mt,kt)}_parseAVCVideoPacket(Ie,Ze,qe,st,mt,Bt){if(qe<4){te.w(this.TAG,"Flv: Invalid AVC packet, missing AVCPacketType or/and CompositionTime");return}let kt=this._littleEndian,Ft=new DataView(Ie,Ze,qe),qt=Ft.getUint8(0),Yn=(Ft.getUint32(0,!kt)&16777215)<<8>>8;if(qt===0)this._parseAVCDecoderConfigurationRecord(Ie,Ze+4,qe-4);else if(qt===1)this._parseAVCVideoData(Ie,Ze+4,qe-4,st,mt,Bt,Yn);else if(qt!==2){this._onError(Ne.FORMAT_ERROR,`Flv: Invalid video packet type ${qt}`);return}}_parseAVCDecoderConfigurationRecord(Ie,Ze,qe){if(qe<7){te.w(this.TAG,"Flv: Invalid AVCDecoderConfigurationRecord, lack of data!");return}let st=this._videoMetadata,mt=this._videoTrack,Bt=this._littleEndian,kt=new DataView(Ie,Ze,qe);st?typeof st.avcc!="undefined"&&te.w(this.TAG,"Found another AVCDecoderConfigurationRecord!"):(this._hasVideo===!1&&this._hasVideoFlagOverrided===!1&&(this._hasVideo=!0,this._mediaInfo.hasVideo=!0),st=this._videoMetadata={},st.type="video",st.id=mt.id,st.timescale=this._timescale,st.duration=this._duration);let Ft=kt.getUint8(0),qt=kt.getUint8(1),En=kt.getUint8(2),Yn=kt.getUint8(3);if(Ft!==1||qt===0){this._onError(Ne.FORMAT_ERROR,"Flv: Invalid AVCDecoderConfigurationRecord");return}if(this._naluLengthSize=(kt.getUint8(4)&3)+1,this._naluLengthSize!==3&&this._naluLengthSize!==4){this._onError(Ne.FORMAT_ERROR,`Flv: Strange NaluLengthSizeMinusOne: ${this._naluLengthSize-1}`);return}let At=kt.getUint8(5)&31;if(At===0){this._onError(Ne.FORMAT_ERROR,"Flv: Invalid AVCDecoderConfigurationRecord: No SPS");return}else At>1&&te.w(this.TAG,`Flv: Strange AVCDecoderConfigurationRecord: SPS Count = ${At}`);let St=6;for(let Wt=0;Wt<At;Wt++){let Et=kt.getUint16(St,!Bt);if(St+=2,Et===0)continue;let zt=new Uint8Array(Ie,Ze+St,Et);St+=Et;let tn=Be.parseSPS(zt);if(Wt!==0)continue;st.codecWidth=tn.codec_size.width,st.codecHeight=tn.codec_size.height,st.presentWidth=tn.present_size.width,st.presentHeight=tn.present_size.height,st.profile=tn.profile_string,st.level=tn.level_string,st.bitDepth=tn.bit_depth,st.chromaFormat=tn.chroma_format,st.sarRatio=tn.sar_ratio,st.frameRate=tn.frame_rate,(tn.frame_rate.fixed===!1||tn.frame_rate.fps_num===0||tn.frame_rate.fps_den===0)&&(st.frameRate=this._referenceFrameRate);let nn=st.frameRate.fps_den,gn=st.frameRate.fps_num;st.refSampleDuration=st.timescale*(nn/gn);let Sn=zt.subarray(1,4),Tn="avc1.";for(let jn=0;jn<3;jn++){let bn=Sn[jn].toString(16);bn.length<2&&(bn="0"+bn),Tn+=bn}st.codec=Tn;let Tt=this._mediaInfo;Tt.width=st.codecWidth,Tt.height=st.codecHeight,Tt.fps=st.frameRate.fps,Tt.profile=st.profile,Tt.level=st.level,Tt.refFrames=tn.ref_frames,Tt.chromaFormat=tn.chroma_format_string,Tt.sarNum=st.sarRatio.width,Tt.sarDen=st.sarRatio.height,Tt.videoCodec=Tn,Tt.hasAudio?Tt.audioCodec!=null&&(Tt.mimeType='video/x-flv; codecs="'+Tt.videoCodec+","+Tt.audioCodec+'"'):Tt.mimeType='video/x-flv; codecs="'+Tt.videoCodec+'"',Tt.isComplete()&&this._onMediaInfo(Tt)}let an=kt.getUint8(St);if(an===0){this._onError(Ne.FORMAT_ERROR,"Flv: Invalid AVCDecoderConfigurationRecord: No PPS");return}else an>1&&te.w(this.TAG,`Flv: Strange AVCDecoderConfigurationRecord: PPS Count = ${an}`);St++;for(let Wt=0;Wt<an;Wt++){let Et=kt.getUint16(St,!Bt);St+=2,Et!==0&&(St+=Et)}st.avcc=new Uint8Array(qe),st.avcc.set(new Uint8Array(Ie,Ze,qe),0),te.v(this.TAG,"Parsed AVCDecoderConfigurationRecord"),this._isInitialMetadataDispatched()?this._dispatch&&(this._audioTrack.length||this._videoTrack.length)&&this._onDataAvailable(this._audioTrack,this._videoTrack):this._videoInitialMetadataDispatched=!0,this._dispatch=!1,this._onTrackMetadata("video",st)}_parseAVCVideoData(Ie,Ze,qe,st,mt,Bt,kt){let Ft=this._littleEndian,qt=new DataView(Ie,Ze,qe),En=[],Yn=0,At=0;const St=this._naluLengthSize;let an=this._timestampBase+st,Wt=Bt===1;for(;At<qe;){if(At+4>=qe){te.w(this.TAG,`Malformed Nalu near timestamp ${an}, offset = ${At}, dataSize = ${qe}`);break}let Et=qt.getUint32(At,!Ft);if(St===3&&(Et>>>=8),Et>qe-St){te.w(this.TAG,`Malformed Nalus near timestamp ${an}, NaluSize > DataSize!`);return}let zt=qt.getUint8(At+St)&31;zt===5&&(Wt=!0);let tn=new Uint8Array(Ie,Ze+At,St+Et),nn={type:zt,data:tn};En.push(nn),Yn+=tn.byteLength,At+=St+Et}if(En.length){let Et=this._videoTrack,zt={units:En,length:Yn,isKeyframe:Wt,dts:an,cts:kt,pts:an+kt};Wt&&(zt.fileposition=mt),Et.samples.push(zt),Et.length+=Yn}}}var Me=Ue;class Re{static init(){Re.types={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],sdtp:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[],smhd:[],".mp3":[]};for(let Ze in Re.types)Re.types.hasOwnProperty(Ze)&&(Re.types[Ze]=[Ze.charCodeAt(0),Ze.charCodeAt(1),Ze.charCodeAt(2),Ze.charCodeAt(3)]);let Ie=Re.constants={};Ie.FTYP=new Uint8Array([105,115,111,109,0,0,0,1,105,115,111,109,97,118,99,49]),Ie.STSD_PREFIX=new Uint8Array([0,0,0,0,0,0,0,1]),Ie.STTS=new Uint8Array([0,0,0,0,0,0,0,0]),Ie.STSC=Ie.STCO=Ie.STTS,Ie.STSZ=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),Ie.HDLR_VIDEO=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]),Ie.HDLR_AUDIO=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]),Ie.DREF=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),Ie.SMHD=new Uint8Array([0,0,0,0,0,0,0,0]),Ie.VMHD=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}static box(Ie){let Ze=8,qe=null,st=Array.prototype.slice.call(arguments,1),mt=st.length;for(let kt=0;kt<mt;kt++)Ze+=st[kt].byteLength;qe=new Uint8Array(Ze),qe[0]=Ze>>>24&255,qe[1]=Ze>>>16&255,qe[2]=Ze>>>8&255,qe[3]=Ze&255,qe.set(Ie,4);let Bt=8;for(let kt=0;kt<mt;kt++)qe.set(st[kt],Bt),Bt+=st[kt].byteLength;return qe}static generateInitSegment(Ie){let Ze=Re.box(Re.types.ftyp,Re.constants.FTYP),qe=Re.moov(Ie),st=new Uint8Array(Ze.byteLength+qe.byteLength);return st.set(Ze,0),st.set(qe,Ze.byteLength),st}static moov(Ie){let Ze=Re.mvhd(Ie.timescale,Ie.duration),qe=Re.trak(Ie),st=Re.mvex(Ie);return Re.box(Re.types.moov,Ze,qe,st)}static mvhd(Ie,Ze){return Re.box(Re.types.mvhd,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,Ie>>>24&255,Ie>>>16&255,Ie>>>8&255,Ie&255,Ze>>>24&255,Ze>>>16&255,Ze>>>8&255,Ze&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]))}static trak(Ie){return Re.box(Re.types.trak,Re.tkhd(Ie),Re.mdia(Ie))}static tkhd(Ie){let Ze=Ie.id,qe=Ie.duration,st=Ie.presentWidth,mt=Ie.presentHeight;return Re.box(Re.types.tkhd,new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,Ze>>>24&255,Ze>>>16&255,Ze>>>8&255,Ze&255,0,0,0,0,qe>>>24&255,qe>>>16&255,qe>>>8&255,qe&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,st>>>8&255,st&255,0,0,mt>>>8&255,mt&255,0,0]))}static mdia(Ie){return Re.box(Re.types.mdia,Re.mdhd(Ie),Re.hdlr(Ie),Re.minf(Ie))}static mdhd(Ie){let Ze=Ie.timescale,qe=Ie.duration;return Re.box(Re.types.mdhd,new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,Ze>>>24&255,Ze>>>16&255,Ze>>>8&255,Ze&255,qe>>>24&255,qe>>>16&255,qe>>>8&255,qe&255,85,196,0,0]))}static hdlr(Ie){let Ze=null;return Ie.type==="audio"?Ze=Re.constants.HDLR_AUDIO:Ze=Re.constants.HDLR_VIDEO,Re.box(Re.types.hdlr,Ze)}static minf(Ie){let Ze=null;return Ie.type==="audio"?Ze=Re.box(Re.types.smhd,Re.constants.SMHD):Ze=Re.box(Re.types.vmhd,Re.constants.VMHD),Re.box(Re.types.minf,Ze,Re.dinf(),Re.stbl(Ie))}static dinf(){return Re.box(Re.types.dinf,Re.box(Re.types.dref,Re.constants.DREF))}static stbl(Ie){return Re.box(Re.types.stbl,Re.stsd(Ie),Re.box(Re.types.stts,Re.constants.STTS),Re.box(Re.types.stsc,Re.constants.STSC),Re.box(Re.types.stsz,Re.constants.STSZ),Re.box(Re.types.stco,Re.constants.STCO))}static stsd(Ie){return Ie.type==="audio"?Ie.codec==="mp3"?Re.box(Re.types.stsd,Re.constants.STSD_PREFIX,Re.mp3(Ie)):Re.box(Re.types.stsd,Re.constants.STSD_PREFIX,Re.mp4a(Ie)):Re.box(Re.types.stsd,Re.constants.STSD_PREFIX,Re.avc1(Ie))}static mp3(Ie){let Ze=Ie.channelCount,qe=Ie.audioSampleRate,st=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,Ze,0,16,0,0,0,0,qe>>>8&255,qe&255,0,0]);return Re.box(Re.types[".mp3"],st)}static mp4a(Ie){let Ze=Ie.channelCount,qe=Ie.audioSampleRate,st=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,Ze,0,16,0,0,0,0,qe>>>8&255,qe&255,0,0]);return Re.box(Re.types.mp4a,st,Re.esds(Ie))}static esds(Ie){let Ze=Ie.config||[],qe=Ze.length,st=new Uint8Array([0,0,0,0,3,23+qe,0,1,0,4,15+qe,64,21,0,0,0,0,0,0,0,0,0,0,0,5].concat([qe]).concat(Ze).concat([6,1,2]));return Re.box(Re.types.esds,st)}static avc1(Ie){let Ze=Ie.avcc,qe=Ie.codecWidth,st=Ie.codecHeight,mt=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,qe>>>8&255,qe&255,st>>>8&255,st&255,0,72,0,0,0,72,0,0,0,0,0,0,0,1,10,120,113,113,47,102,108,118,46,106,115,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,24,255,255]);return Re.box(Re.types.avc1,mt,Re.box(Re.types.avcC,Ze))}static mvex(Ie){return Re.box(Re.types.mvex,Re.trex(Ie))}static trex(Ie){let Ze=Ie.id,qe=new Uint8Array([0,0,0,0,Ze>>>24&255,Ze>>>16&255,Ze>>>8&255,Ze&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return Re.box(Re.types.trex,qe)}static moof(Ie,Ze){return Re.box(Re.types.moof,Re.mfhd(Ie.sequenceNumber),Re.traf(Ie,Ze))}static mfhd(Ie){let Ze=new Uint8Array([0,0,0,0,Ie>>>24&255,Ie>>>16&255,Ie>>>8&255,Ie&255]);return Re.box(Re.types.mfhd,Ze)}static traf(Ie,Ze){let qe=Ie.id,st=Re.box(Re.types.tfhd,new Uint8Array([0,0,0,0,qe>>>24&255,qe>>>16&255,qe>>>8&255,qe&255])),mt=Re.box(Re.types.tfdt,new Uint8Array([0,0,0,0,Ze>>>24&255,Ze>>>16&255,Ze>>>8&255,Ze&255])),Bt=Re.sdtp(Ie),kt=Re.trun(Ie,Bt.byteLength+16+16+8+16+8+8);return Re.box(Re.types.traf,st,mt,kt,Bt)}static sdtp(Ie){let Ze=Ie.samples||[],qe=Ze.length,st=new Uint8Array(4+qe);for(let mt=0;mt<qe;mt++){let Bt=Ze[mt].flags;st[mt+4]=Bt.isLeading<<6|Bt.dependsOn<<4|Bt.isDependedOn<<2|Bt.hasRedundancy}return Re.box(Re.types.sdtp,st)}static trun(Ie,Ze){let qe=Ie.samples||[],st=qe.length,mt=12+16*st,Bt=new Uint8Array(mt);Ze+=8+mt,Bt.set([0,0,15,1,st>>>24&255,st>>>16&255,st>>>8&255,st&255,Ze>>>24&255,Ze>>>16&255,Ze>>>8&255,Ze&255],0);for(let kt=0;kt<st;kt++){let Ft=qe[kt].duration,qt=qe[kt].size,En=qe[kt].flags,Yn=qe[kt].cts;Bt.set([Ft>>>24&255,Ft>>>16&255,Ft>>>8&255,Ft&255,qt>>>24&255,qt>>>16&255,qt>>>8&255,qt&255,En.isLeading<<2|En.dependsOn,En.isDependedOn<<6|En.hasRedundancy<<4|En.isNonSync,0,0,Yn>>>24&255,Yn>>>16&255,Yn>>>8&255,Yn&255],12+16*kt)}return Re.box(Re.types.trun,Bt)}static mdat(Ie){return Re.box(Re.types.mdat,Ie)}}Re.init();var tt=Re;class lt{static getSilentFrame(Ie,Ze){if(Ie==="mp4a.40.2"){if(Ze===1)return new Uint8Array([0,200,0,128,35,128]);if(Ze===2)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(Ze===3)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(Ze===4)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(Ze===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(Ze===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])}else{if(Ze===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(Ze===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(Ze===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])}return null}}var Nt=lt;class Ct{constructor(Ie,Ze,qe,st,mt){this.dts=Ie,this.pts=Ze,this.duration=qe,this.originalDts=st,this.isSyncPoint=mt,this.fileposition=null}}class vt{constructor(){this.beginDts=0,this.endDts=0,this.beginPts=0,this.endPts=0,this.originalBeginDts=0,this.originalEndDts=0,this.syncPoints=[],this.firstSample=null,this.lastSample=null}appendSyncPoint(Ie){Ie.isSyncPoint=!0,this.syncPoints.push(Ie)}}class Pt{constructor(){this._list=[]}clear(){this._list=[]}appendArray(Ie){let Ze=this._list;Ie.length!==0&&(Ze.length>0&&Ie[0].originalDts<Ze[Ze.length-1].originalDts&&this.clear(),Array.prototype.push.apply(Ze,Ie))}getLastSyncPointBeforeDts(Ie){if(this._list.length==0)return null;let Ze=this._list,qe=0,st=Ze.length-1,mt=0,Bt=0,kt=st;for(Ie<Ze[0].dts&&(qe=0,Bt=kt+1);Bt<=kt;)if(mt=Bt+Math.floor((kt-Bt)/2),mt===st||Ie>=Ze[mt].dts&&Ie<Ze[mt+1].dts){qe=mt;break}else Ze[mt].dts<Ie?Bt=mt+1:kt=mt-1;return this._list[qe]}}class Ht{constructor(Ie){this._type=Ie,this._list=[],this._lastAppendLocation=-1}get type(){return this._type}get length(){return this._list.length}isEmpty(){return this._list.length===0}clear(){this._list=[],this._lastAppendLocation=-1}_searchNearestSegmentBefore(Ie){let Ze=this._list;if(Ze.length===0)return-2;let qe=Ze.length-1,st=0,mt=0,Bt=qe,kt=0;if(Ie<Ze[0].originalBeginDts)return kt=-1,kt;for(;mt<=Bt;)if(st=mt+Math.floor((Bt-mt)/2),st===qe||Ie>Ze[st].lastSample.originalDts&&Ie<Ze[st+1].originalBeginDts){kt=st;break}else Ze[st].originalBeginDts<Ie?mt=st+1:Bt=st-1;return kt}_searchNearestSegmentAfter(Ie){return this._searchNearestSegmentBefore(Ie)+1}append(Ie){let Ze=this._list,qe=Ie,st=this._lastAppendLocation,mt=0;st!==-1&&st<Ze.length&&qe.originalBeginDts>=Ze[st].lastSample.originalDts&&(st===Ze.length-1||st<Ze.length-1&&qe.originalBeginDts<Ze[st+1].originalBeginDts)?mt=st+1:Ze.length>0&&(mt=this._searchNearestSegmentBefore(qe.originalBeginDts)+1),this._lastAppendLocation=mt,this._list.splice(mt,0,qe)}getLastSegmentBefore(Ie){let Ze=this._searchNearestSegmentBefore(Ie);return Ze>=0?this._list[Ze]:null}getLastSampleBefore(Ie){let Ze=this.getLastSegmentBefore(Ie);return Ze!=null?Ze.lastSample:null}getLastSyncPointBefore(Ie){let Ze=this._searchNearestSegmentBefore(Ie),qe=this._list[Ze].syncPoints;for(;qe.length===0&&Ze>0;)Ze--,qe=this._list[Ze].syncPoints;return qe.length>0?qe[qe.length-1]:null}}class jt{constructor(Ie){this.TAG="MP4Remuxer",this._config=Ie,this._isLive=Ie.isLive===!0,this._dtsBase=-1,this._dtsBaseInited=!1,this._audioDtsBase=1/0,this._videoDtsBase=1/0,this._audioNextDts=void 0,this._videoNextDts=void 0,this._audioStashedLastSample=null,this._videoStashedLastSample=null,this._audioMeta=null,this._videoMeta=null,this._audioSegmentInfoList=new Ht("audio"),this._videoSegmentInfoList=new Ht("video"),this._onInitSegment=null,this._onMediaSegment=null,this._forceFirstIDR=!!(ye.chrome&&(ye.version.major<50||ye.version.major===50&&ye.version.build<2661)),this._fillSilentAfterSeek=ye.msedge||ye.msie,this._mp3UseMpegAudio=!ye.firefox,this._fillAudioTimestampGap=this._config.fixAudioTimestampGap}destroy(){this._dtsBase=-1,this._dtsBaseInited=!1,this._audioMeta=null,this._videoMeta=null,this._audioSegmentInfoList.clear(),this._audioSegmentInfoList=null,this._videoSegmentInfoList.clear(),this._videoSegmentInfoList=null,this._onInitSegment=null,this._onMediaSegment=null}bindDataSource(Ie){return Ie.onDataAvailable=this.remux.bind(this),Ie.onTrackMetadata=this._onTrackMetadataReceived.bind(this),this}get onInitSegment(){return this._onInitSegment}set onInitSegment(Ie){this._onInitSegment=Ie}get onMediaSegment(){return this._onMediaSegment}set onMediaSegment(Ie){this._onMediaSegment=Ie}insertDiscontinuity(){this._audioNextDts=this._videoNextDts=void 0}seek(Ie){this._audioStashedLastSample=null,this._videoStashedLastSample=null,this._videoSegmentInfoList.clear(),this._audioSegmentInfoList.clear()}remux(Ie,Ze){if(!this._onMediaSegment)throw new E("MP4Remuxer: onMediaSegment callback must be specificed!");this._dtsBaseInited||this._calculateDtsBase(Ie,Ze),this._remuxVideo(Ze),this._remuxAudio(Ie)}_onTrackMetadataReceived(Ie,Ze){let qe=null,st="mp4",mt=Ze.codec;if(Ie==="audio")this._audioMeta=Ze,Ze.codec==="mp3"&&this._mp3UseMpegAudio?(st="mpeg",mt="",qe=new Uint8Array):qe=tt.generateInitSegment(Ze);else if(Ie==="video")this._videoMeta=Ze,qe=tt.generateInitSegment(Ze);else return;if(!this._onInitSegment)throw new E("MP4Remuxer: onInitSegment callback must be specified!");this._onInitSegment(Ie,{type:Ie,data:qe.buffer,codec:mt,container:`${Ie}/${st}`,mediaDuration:Ze.duration})}_calculateDtsBase(Ie,Ze){this._dtsBaseInited||(Ie.samples&&Ie.samples.length&&(this._audioDtsBase=Ie.samples[0].dts),Ze.samples&&Ze.samples.length&&(this._videoDtsBase=Ze.samples[0].dts),this._dtsBase=Math.min(this._audioDtsBase,this._videoDtsBase),this._dtsBaseInited=!0)}flushStashedSamples(){let Ie=this._videoStashedLastSample,Ze=this._audioStashedLastSample,qe={type:"video",id:1,sequenceNumber:0,samples:[],length:0};Ie!=null&&(qe.samples.push(Ie),qe.length=Ie.length);let st={type:"audio",id:2,sequenceNumber:0,samples:[],length:0};Ze!=null&&(st.samples.push(Ze),st.length=Ze.length),this._videoStashedLastSample=null,this._audioStashedLastSample=null,this._remuxVideo(qe,!0),this._remuxAudio(st,!0)}_remuxAudio(Ie,Ze){if(this._audioMeta==null)return;let qe=Ie,st=qe.samples,mt,Bt=-1,kt=-1,Ft=-1,qt=this._audioMeta.refSampleDuration,En=this._audioMeta.codec==="mp3"&&this._mp3UseMpegAudio,Yn=this._dtsBaseInited&&this._audioNextDts===void 0,At=!1;if(!st||st.length===0||st.length===1&&!Ze)return;let St=0,an=null,Wt=0;En?(St=0,Wt=qe.length):(St=8,Wt=8+qe.length);let Et=null;if(st.length>1&&(Et=st.pop(),Wt-=Et.length),this._audioStashedLastSample!=null){let Tt=this._audioStashedLastSample;this._audioStashedLastSample=null,st.unshift(Tt),Wt+=Tt.length}Et!=null&&(this._audioStashedLastSample=Et);let zt=st[0].dts-this._dtsBase;if(this._audioNextDts)mt=zt-this._audioNextDts;else if(this._audioSegmentInfoList.isEmpty())mt=0,this._fillSilentAfterSeek&&!this._videoSegmentInfoList.isEmpty()&&this._audioMeta.originalCodec!=="mp3"&&(At=!0);else{let Tt=this._audioSegmentInfoList.getLastSampleBefore(zt);if(Tt!=null){let jn=zt-(Tt.originalDts+Tt.duration);jn<=3&&(jn=0);let bn=Tt.dts+Tt.duration+jn;mt=zt-bn}else mt=0}if(At){let Tt=zt-mt,jn=this._videoSegmentInfoList.getLastSegmentBefore(zt);if(jn!=null&&jn.beginDts<Tt){let bn=Nt.getSilentFrame(this._audioMeta.originalCodec,this._audioMeta.channelCount);if(bn){let Fn=jn.beginDts,Un=Tt-jn.beginDts;te.v(this.TAG,`InsertPrefixSilentAudio: dts: ${Fn}, duration: ${Un}`),st.unshift({unit:bn,dts:Fn,pts:Fn}),Wt+=bn.byteLength}}else At=!1}let tn=[];for(let Tt=0;Tt<st.length;Tt++){let jn=st[Tt],bn=jn.unit,Fn=jn.dts-this._dtsBase,Un=Fn-mt;Bt===-1&&(Bt=Un);let rr=0;Tt!==st.length-1?rr=st[Tt+1].dts-this._dtsBase-mt-Un:Et!=null?rr=Et.dts-this._dtsBase-mt-Un:tn.length>=1?rr=tn[tn.length-1].duration:rr=Math.floor(qt);let pr=!1,Rr=null;if(rr>qt*1.5&&this._audioMeta.codec!=="mp3"&&this._fillAudioTimestampGap&&!ye.safari){pr=!0;let wr=Math.abs(rr-qt),Lr=Math.ceil(wr/qt),Vr=Un+qt;te.w(this.TAG,`Large audio timestamp gap detected, may cause AV sync to drift. Silent frames will be generated to avoid unsync.
|
|
|
dts: ${Un+rr} ms, expected: ${Un+Math.round(qt)} ms, delta: ${Math.round(wr)} ms, generate: ${Lr} frames`);let xr=Nt.getSilentFrame(this._audioMeta.originalCodec,this._audioMeta.channelCount);xr==null&&(te.w(this.TAG,`Unable to generate silent frame for ${this._audioMeta.originalCodec} with ${this._audioMeta.channelCount} channels, repeat last frame`),xr=bn),Rr=[];for(let jr=0;jr<Lr;jr++){let ti=Math.round(Vr);if(Rr.length>0){let wi=Rr[Rr.length-1];wi.duration=ti-wi.dts}let di={dts:ti,pts:ti,cts:0,unit:xr,size:xr.byteLength,duration:0,originalDts:Fn,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0}};Rr.push(di),Wt+=di.size,Vr+=qt}let Ir=Rr[Rr.length-1];Ir.duration=Un+rr-Ir.dts,rr=Math.round(qt)}tn.push({dts:Un,pts:Un,cts:0,unit:jn.unit,size:jn.unit.byteLength,duration:rr,originalDts:Fn,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0}}),pr&&tn.push.apply(tn,Rr)}En?an=new Uint8Array(Wt):(an=new Uint8Array(Wt),an[0]=Wt>>>24&255,an[1]=Wt>>>16&255,an[2]=Wt>>>8&255,an[3]=Wt&255,an.set(tt.types.mdat,4));for(let Tt=0;Tt<tn.length;Tt++){let jn=tn[Tt].unit;an.set(jn,St),St+=jn.byteLength}let nn=tn[tn.length-1];kt=nn.dts+nn.duration,this._audioNextDts=kt;let gn=new vt;gn.beginDts=Bt,gn.endDts=kt,gn.beginPts=Bt,gn.endPts=kt,gn.originalBeginDts=tn[0].originalDts,gn.originalEndDts=nn.originalDts+nn.duration,gn.firstSample=new Ct(tn[0].dts,tn[0].pts,tn[0].duration,tn[0].originalDts,!1),gn.lastSample=new Ct(nn.dts,nn.pts,nn.duration,nn.originalDts,!1),this._isLive||this._audioSegmentInfoList.append(gn),qe.samples=tn,qe.sequenceNumber++;let Sn=null;En?Sn=new Uint8Array:Sn=tt.moof(qe,Bt),qe.samples=[],qe.length=0;let Tn={type:"audio",data:this._mergeBoxes(Sn,an).buffer,sampleCount:tn.length,info:gn};En&&Yn&&(Tn.timestampOffset=Bt),this._onMediaSegment("audio",Tn)}_remuxVideo(Ie,Ze){if(this._videoMeta==null)return;let qe=Ie,st=qe.samples,mt,Bt=-1,kt=-1,Ft=-1,qt=-1;if(!st||st.length===0||st.length===1&&!Ze)return;let En=8,Yn=null,At=8+Ie.length,St=null;if(st.length>1&&(St=st.pop(),At-=St.length),this._videoStashedLastSample!=null){let nn=this._videoStashedLastSample;this._videoStashedLastSample=null,st.unshift(nn),At+=nn.length}St!=null&&(this._videoStashedLastSample=St);let an=st[0].dts-this._dtsBase;if(this._videoNextDts)mt=an-this._videoNextDts;else if(this._videoSegmentInfoList.isEmpty())mt=0;else{let nn=this._videoSegmentInfoList.getLastSampleBefore(an);if(nn!=null){let gn=an-(nn.originalDts+nn.duration);gn<=3&&(gn=0);let Sn=nn.dts+nn.duration+gn;mt=an-Sn}else mt=0}let Wt=new vt,Et=[];for(let nn=0;nn<st.length;nn++){let gn=st[nn],Sn=gn.dts-this._dtsBase,Tn=gn.isKeyframe,Tt=Sn-mt,jn=gn.cts,bn=Tt+jn;Bt===-1&&(Bt=Tt,Ft=bn);let Fn=0;if(nn!==st.length-1?Fn=st[nn+1].dts-this._dtsBase-mt-Tt:St!=null?Fn=St.dts-this._dtsBase-mt-Tt:Et.length>=1?Fn=Et[Et.length-1].duration:Fn=Math.floor(this._videoMeta.refSampleDuration),Tn){let Un=new Ct(Tt,bn,Fn,gn.dts,!0);Un.fileposition=gn.fileposition,Wt.appendSyncPoint(Un)}Et.push({dts:Tt,pts:bn,cts:jn,units:gn.units,size:gn.length,isKeyframe:Tn,duration:Fn,originalDts:Sn,flags:{isLeading:0,dependsOn:Tn?2:1,isDependedOn:Tn?1:0,hasRedundancy:0,isNonSync:Tn?0:1}})}Yn=new Uint8Array(At),Yn[0]=At>>>24&255,Yn[1]=At>>>16&255,Yn[2]=At>>>8&255,Yn[3]=At&255,Yn.set(tt.types.mdat,4);for(let nn=0;nn<Et.length;nn++){let gn=Et[nn].units;for(;gn.length;){let Tn=gn.shift().data;Yn.set(Tn,En),En+=Tn.byteLength}}let zt=Et[Et.length-1];if(kt=zt.dts+zt.duration,qt=zt.pts+zt.duration,this._videoNextDts=kt,Wt.beginDts=Bt,Wt.endDts=kt,Wt.beginPts=Ft,Wt.endPts=qt,Wt.originalBeginDts=Et[0].originalDts,Wt.originalEndDts=zt.originalDts+zt.duration,Wt.firstSample=new Ct(Et[0].dts,Et[0].pts,Et[0].duration,Et[0].originalDts,Et[0].isKeyframe),Wt.lastSample=new Ct(zt.dts,zt.pts,zt.duration,zt.originalDts,zt.isKeyframe),this._isLive||this._videoSegmentInfoList.append(Wt),qe.samples=Et,qe.sequenceNumber++,this._forceFirstIDR){let nn=Et[0].flags;nn.dependsOn=2,nn.isNonSync=0}let tn=tt.moof(qe,Bt);qe.samples=[],qe.length=0,this._onMediaSegment("video",{type:"video",data:this._mergeBoxes(tn,Yn).buffer,sampleCount:Et.length,info:Wt})}_mergeBoxes(Ie,Ze){let qe=new Uint8Array(Ie.byteLength+Ze.byteLength);return qe.set(Ie,0),qe.set(Ze,Ie.byteLength),qe}}var yt=jt,Lt={IO_ERROR:"io_error",DEMUX_ERROR:"demux_error",INIT_SEGMENT:"init_segment",MEDIA_SEGMENT:"media_segment",LOADING_COMPLETE:"loading_complete",RECOVERED_EARLY_EOF:"recovered_early_eof",MEDIA_INFO:"media_info",METADATA_ARRIVED:"metadata_arrived",SCRIPTDATA_ARRIVED:"scriptdata_arrived",STATISTICS_INFO:"statistics_info",RECOMMEND_SEEKPOINT:"recommend_seekpoint"};class Kt{constructor(Ie,Ze){this.TAG="TransmuxingController",this._emitter=new(ue()),this._config=Ze,Ie.segments||(Ie.segments=[{duration:Ie.duration,filesize:Ie.filesize,url:Ie.url}]),typeof Ie.cors!="boolean"&&(Ie.cors=!0),typeof Ie.withCredentials!="boolean"&&(Ie.withCredentials=!1),this._mediaDataSource=Ie,this._currentSegmentIndex=0;let qe=0;this._mediaDataSource.segments.forEach(st=>{st.timestampBase=qe,qe+=st.duration,st.cors=Ie.cors,st.withCredentials=Ie.withCredentials,Ze.referrerPolicy&&(st.referrerPolicy=Ze.referrerPolicy)}),!isNaN(qe)&&this._mediaDataSource.duration!==qe&&(this._mediaDataSource.duration=qe),this._mediaInfo=null,this._demuxer=null,this._remuxer=null,this._ioctl=null,this._pendingSeekTime=null,this._pendingResolveSeekPoint=null,this._statisticsReporter=null}destroy(){this._mediaInfo=null,this._mediaDataSource=null,this._statisticsReporter&&this._disableStatisticsReporter(),this._ioctl&&(this._ioctl.destroy(),this._ioctl=null),this._demuxer&&(this._demuxer.destroy(),this._demuxer=null),this._remuxer&&(this._remuxer.destroy(),this._remuxer=null),this._emitter.removeAllListeners(),this._emitter=null}on(Ie,Ze){this._emitter.addListener(Ie,Ze)}off(Ie,Ze){this._emitter.removeListener(Ie,Ze)}start(){this._loadSegment(0),this._enableStatisticsReporter()}_loadSegment(Ie,Ze){this._currentSegmentIndex=Ie;let qe=this._mediaDataSource.segments[Ie],st=this._ioctl=new rt(qe,this._config,Ie);st.onError=this._onIOException.bind(this),st.onSeeked=this._onIOSeeked.bind(this),st.onComplete=this._onIOComplete.bind(this),st.onRedirect=this._onIORedirect.bind(this),st.onRecoveredEarlyEof=this._onIORecoveredEarlyEof.bind(this),Ze?this._demuxer.bindDataSource(this._ioctl):st.onDataArrival=this._onInitChunkArrival.bind(this),st.open(Ze)}stop(){this._internalAbort(),this._disableStatisticsReporter()}_internalAbort(){this._ioctl&&(this._ioctl.destroy(),this._ioctl=null)}pause(){this._ioctl&&this._ioctl.isWorking()&&(this._ioctl.pause(),this._disableStatisticsReporter())}resume(){this._ioctl&&this._ioctl.isPaused()&&(this._ioctl.resume(),this._enableStatisticsReporter())}seek(Ie){if(this._mediaInfo==null||!this._mediaInfo.isSeekable())return;let Ze=this._searchSegmentIndexContains(Ie);if(Ze===this._currentSegmentIndex){let qe=this._mediaInfo.segments[Ze];if(qe==null)this._pendingSeekTime=Ie;else{let st=qe.getNearestKeyframe(Ie);this._remuxer.seek(st.milliseconds),this._ioctl.seek(st.fileposition),this._pendingResolveSeekPoint=st.milliseconds}}else{let qe=this._mediaInfo.segments[Ze];if(qe==null)this._pendingSeekTime=Ie,this._internalAbort(),this._remuxer.seek(),this._remuxer.insertDiscontinuity(),this._loadSegment(Ze);else{let st=qe.getNearestKeyframe(Ie);this._internalAbort(),this._remuxer.seek(Ie),this._remuxer.insertDiscontinuity(),this._demuxer.resetMediaInfo(),this._demuxer.timestampBase=this._mediaDataSource.segments[Ze].timestampBase,this._loadSegment(Ze,st.fileposition),this._pendingResolveSeekPoint=st.milliseconds,this._reportSegmentMediaInfo(Ze)}}this._enableStatisticsReporter()}_searchSegmentIndexContains(Ie){let Ze=this._mediaDataSource.segments,qe=Ze.length-1;for(let st=0;st<Ze.length;st++)if(Ie<Ze[st].timestampBase){qe=st-1;break}return qe}_onInitChunkArrival(Ie,Ze){let qe=null,st=0;if(Ze>0)this._demuxer.bindDataSource(this._ioctl),this._demuxer.timestampBase=this._mediaDataSource.segments[this._currentSegmentIndex].timestampBase,st=this._demuxer.parseChunks(Ie,Ze);else if((qe=Me.probe(Ie)).match){this._demuxer=new Me(qe,this._config),this._remuxer||(this._remuxer=new yt(this._config));let mt=this._mediaDataSource;mt.duration!=null&&!isNaN(mt.duration)&&(this._demuxer.overridedDuration=mt.duration),typeof mt.hasAudio=="boolean"&&(this._demuxer.overridedHasAudio=mt.hasAudio),typeof mt.hasVideo=="boolean"&&(this._demuxer.overridedHasVideo=mt.hasVideo),this._demuxer.timestampBase=mt.segments[this._currentSegmentIndex].timestampBase,this._demuxer.onError=this._onDemuxException.bind(this),this._demuxer.onMediaInfo=this._onMediaInfo.bind(this),this._demuxer.onMetaDataArrived=this._onMetaDataArrived.bind(this),this._demuxer.onScriptDataArrived=this._onScriptDataArrived.bind(this),this._remuxer.bindDataSource(this._demuxer.bindDataSource(this._ioctl)),this._remuxer.onInitSegment=this._onRemuxerInitSegmentArrival.bind(this),this._remuxer.onMediaSegment=this._onRemuxerMediaSegmentArrival.bind(this),st=this._demuxer.parseChunks(Ie,Ze)}else qe=null,te.e(this.TAG,"Non-FLV, Unsupported media type!"),Promise.resolve().then(()=>{this._internalAbort()}),this._emitter.emit(Lt.DEMUX_ERROR,Ne.FORMAT_UNSUPPORTED,"Non-FLV, Unsupported media type"),st=0;return st}_onMediaInfo(Ie){this._mediaInfo==null&&(this._mediaInfo=Object.assign({},Ie),this._mediaInfo.keyframesIndex=null,this._mediaInfo.segments=[],this._mediaInfo.segmentCount=this._mediaDataSource.segments.length,Object.setPrototypeOf(this._mediaInfo,ct.prototype));let Ze=Object.assign({},Ie);Object.setPrototypeOf(Ze,ct.prototype),this._mediaInfo.segments[this._currentSegmentIndex]=Ze,this._reportSegmentMediaInfo(this._currentSegmentIndex),this._pendingSeekTime!=null&&Promise.resolve().then(()=>{let qe=this._pendingSeekTime;this._pendingSeekTime=null,this.seek(qe)})}_onMetaDataArrived(Ie){this._emitter.emit(Lt.METADATA_ARRIVED,Ie)}_onScriptDataArrived(Ie){this._emitter.emit(Lt.SCRIPTDATA_ARRIVED,Ie)}_onIOSeeked(){this._remuxer.insertDiscontinuity()}_onIOComplete(Ie){let qe=Ie+1;qe<this._mediaDataSource.segments.length?(this._internalAbort(),this._remuxer.flushStashedSamples(),this._loadSegment(qe)):(this._remuxer.flushStashedSamples(),this._emitter.emit(Lt.LOADING_COMPLETE),this._disableStatisticsReporter())}_onIORedirect(Ie){let Ze=this._ioctl.extraData;this._mediaDataSource.segments[Ze].redirectedURL=Ie}_onIORecoveredEarlyEof(){this._emitter.emit(Lt.RECOVERED_EARLY_EOF)}_onIOException(Ie,Ze){te.e(this.TAG,`IOException: type = ${Ie}, code = ${Ze.code}, msg = ${Ze.msg}`),this._emitter.emit(Lt.IO_ERROR,Ie,Ze),this._disableStatisticsReporter()}_onDemuxException(Ie,Ze){te.e(this.TAG,`DemuxException: type = ${Ie}, info = ${Ze}`),this._emitter.emit(Lt.DEMUX_ERROR,Ie,Ze)}_onRemuxerInitSegmentArrival(Ie,Ze){this._emitter.emit(Lt.INIT_SEGMENT,Ie,Ze)}_onRemuxerMediaSegmentArrival(Ie,Ze){if(this._pendingSeekTime==null&&(this._emitter.emit(Lt.MEDIA_SEGMENT,Ie,Ze),this._pendingResolveSeekPoint!=null&&Ie==="video")){let qe=Ze.info.syncPoints,st=this._pendingResolveSeekPoint;this._pendingResolveSeekPoint=null,ye.safari&&qe.length>0&&qe[0].originalDts===st&&(st=qe[0].pts),this._emitter.emit(Lt.RECOMMEND_SEEKPOINT,st)}}_enableStatisticsReporter(){this._statisticsReporter==null&&(this._statisticsReporter=self.setInterval(this._reportStatisticsInfo.bind(this),this._config.statisticsInfoReportInterval))}_disableStatisticsReporter(){this._statisticsReporter&&(self.clearInterval(this._statisticsReporter),this._statisticsReporter=null)}_reportSegmentMediaInfo(Ie){let Ze=this._mediaInfo.segments[Ie],qe=Object.assign({},Ze);qe.duration=this._mediaInfo.duration,qe.segmentCount=this._mediaInfo.segmentCount,delete qe.segments,delete qe.keyframesIndex,this._emitter.emit(Lt.MEDIA_INFO,qe)}_reportStatisticsInfo(){let Ie={};Ie.url=this._ioctl.currentURL,Ie.hasRedirect=this._ioctl.hasRedirect,Ie.hasRedirect&&(Ie.redirectedURL=this._ioctl.currentRedirectedURL),Ie.speed=this._ioctl.currentSpeed,Ie.loaderType=this._ioctl.loaderType,Ie.currentSegmentIndex=this._currentSegmentIndex,Ie.totalSegmentCount=this._mediaDataSource.segments.length,this._emitter.emit(Lt.STATISTICS_INFO,Ie)}}var sn=Kt,Vt=function(Jt){let Ie="TransmuxingWorker",Ze=null,qe=Wt.bind(this);ie.install(),Jt.addEventListener("message",function(Et){switch(Et.data.cmd){case"init":Ze=new sn(Et.data.param[0],Et.data.param[1]),Ze.on(Lt.IO_ERROR,At.bind(this)),Ze.on(Lt.DEMUX_ERROR,St.bind(this)),Ze.on(Lt.INIT_SEGMENT,st.bind(this)),Ze.on(Lt.MEDIA_SEGMENT,mt.bind(this)),Ze.on(Lt.LOADING_COMPLETE,Bt.bind(this)),Ze.on(Lt.RECOVERED_EARLY_EOF,kt.bind(this)),Ze.on(Lt.MEDIA_INFO,Ft.bind(this)),Ze.on(Lt.METADATA_ARRIVED,qt.bind(this)),Ze.on(Lt.SCRIPTDATA_ARRIVED,En.bind(this)),Ze.on(Lt.STATISTICS_INFO,Yn.bind(this)),Ze.on(Lt.RECOMMEND_SEEKPOINT,an.bind(this));break;case"destroy":Ze&&(Ze.destroy(),Ze=null),Jt.postMessage({msg:"destroyed"});break;case"start":Ze.start();break;case"stop":Ze.stop();break;case"seek":Ze.seek(Et.data.param);break;case"pause":Ze.pause();break;case"resume":Ze.resume();break;case"logging_config":{let zt=Et.data.param;et.applyConfig(zt),zt.enableCallback===!0?et.addLogListener(qe):et.removeLogListener(qe);break}}});function st(Et,zt){let tn={msg:Lt.INIT_SEGMENT,data:{type:Et,data:zt}};Jt.postMessage(tn,[zt.data])}function mt(Et,zt){let tn={msg:Lt.MEDIA_SEGMENT,data:{type:Et,data:zt}};Jt.postMessage(tn,[zt.data])}function Bt(){let Et={msg:Lt.LOADING_COMPLETE};Jt.postMessage(Et)}function kt(){let Et={msg:Lt.RECOVERED_EARLY_EOF};Jt.postMessage(Et)}function Ft(Et){let zt={msg:Lt.MEDIA_INFO,data:Et};Jt.postMessage(zt)}function qt(Et){let zt={msg:Lt.METADATA_ARRIVED,data:Et};Jt.postMessage(zt)}function En(Et){let zt={msg:Lt.SCRIPTDATA_ARRIVED,data:Et};Jt.postMessage(zt)}function Yn(Et){let zt={msg:Lt.STATISTICS_INFO,data:Et};Jt.postMessage(zt)}function At(Et,zt){Jt.postMessage({msg:Lt.IO_ERROR,data:{type:Et,info:zt}})}function St(Et,zt){Jt.postMessage({msg:Lt.DEMUX_ERROR,data:{type:Et,info:zt}})}function an(Et){Jt.postMessage({msg:Lt.RECOMMEND_SEEKPOINT,data:Et})}function Wt(Et,zt){Jt.postMessage({msg:"logcat_callback",data:{type:Et,logcat:zt}})}};class Rn{constructor(Ie,Ze){if(this.TAG="Transmuxer",this._emitter=new(ue()),Ze.enableWorker&&typeof Worker!="undefined")try{let qe=be(82059);this._worker=qe(Vt),this._workerDestroying=!1,this._worker.addEventListener("message",this._onWorkerMessage.bind(this)),this._worker.postMessage({cmd:"init",param:[Ie,Ze]}),this.e={onLoggingConfigChanged:this._onLoggingConfigChanged.bind(this)},et.registerListener(this.e.onLoggingConfigChanged),this._worker.postMessage({cmd:"logging_config",param:et.getConfig()})}catch(qe){te.e(this.TAG,"Error while initialize transmuxing worker, fallback to inline transmuxing"),this._worker=null,this._controller=new sn(Ie,Ze)}else this._controller=new sn(Ie,Ze);if(this._controller){let qe=this._controller;qe.on(Lt.IO_ERROR,this._onIOError.bind(this)),qe.on(Lt.DEMUX_ERROR,this._onDemuxError.bind(this)),qe.on(Lt.INIT_SEGMENT,this._onInitSegment.bind(this)),qe.on(Lt.MEDIA_SEGMENT,this._onMediaSegment.bind(this)),qe.on(Lt.LOADING_COMPLETE,this._onLoadingComplete.bind(this)),qe.on(Lt.RECOVERED_EARLY_EOF,this._onRecoveredEarlyEof.bind(this)),qe.on(Lt.MEDIA_INFO,this._onMediaInfo.bind(this)),qe.on(Lt.METADATA_ARRIVED,this._onMetaDataArrived.bind(this)),qe.on(Lt.SCRIPTDATA_ARRIVED,this._onScriptDataArrived.bind(this)),qe.on(Lt.STATISTICS_INFO,this._onStatisticsInfo.bind(this)),qe.on(Lt.RECOMMEND_SEEKPOINT,this._onRecommendSeekpoint.bind(this))}}destroy(){this._worker?this._workerDestroying||(this._workerDestroying=!0,this._worker.postMessage({cmd:"destroy"}),et.removeListener(this.e.onLoggingConfigChanged),this.e=null):(this._controller.destroy(),this._controller=null),this._emitter.removeAllListeners(),this._emitter=null}on(Ie,Ze){this._emitter.addListener(Ie,Ze)}off(Ie,Ze){this._emitter.removeListener(Ie,Ze)}hasWorker(){return this._worker!=null}open(){this._worker?this._worker.postMessage({cmd:"start"}):this._controller.start()}close(){this._worker?this._worker.postMessage({cmd:"stop"}):this._controller.stop()}seek(Ie){this._worker?this._worker.postMessage({cmd:"seek",param:Ie}):this._controller.seek(Ie)}pause(){this._worker?this._worker.postMessage({cmd:"pause"}):this._controller.pause()}resume(){this._worker?this._worker.postMessage({cmd:"resume"}):this._controller.resume()}_onInitSegment(Ie,Ze){Promise.resolve().then(()=>{this._emitter.emit(Lt.INIT_SEGMENT,Ie,Ze)})}_onMediaSegment(Ie,Ze){Promise.resolve().then(()=>{this._emitter.emit(Lt.MEDIA_SEGMENT,Ie,Ze)})}_onLoadingComplete(){Promise.resolve().then(()=>{this._emitter.emit(Lt.LOADING_COMPLETE)})}_onRecoveredEarlyEof(){Promise.resolve().then(()=>{this._emitter.emit(Lt.RECOVERED_EARLY_EOF)})}_onMediaInfo(Ie){Promise.resolve().then(()=>{this._emitter.emit(Lt.MEDIA_INFO,Ie)})}_onMetaDataArrived(Ie){Promise.resolve().then(()=>{this._emitter.emit(Lt.METADATA_ARRIVED,Ie)})}_onScriptDataArrived(Ie){Promise.resolve().then(()=>{this._emitter.emit(Lt.SCRIPTDATA_ARRIVED,Ie)})}_onStatisticsInfo(Ie){Promise.resolve().then(()=>{this._emitter.emit(Lt.STATISTICS_INFO,Ie)})}_onIOError(Ie,Ze){Promise.resolve().then(()=>{this._emitter.emit(Lt.IO_ERROR,Ie,Ze)})}_onDemuxError(Ie,Ze){Promise.resolve().then(()=>{this._emitter.emit(Lt.DEMUX_ERROR,Ie,Ze)})}_onRecommendSeekpoint(Ie){Promise.resolve().then(()=>{this._emitter.emit(Lt.RECOMMEND_SEEKPOINT,Ie)})}_onLoggingConfigChanged(Ie){this._worker&&this._worker.postMessage({cmd:"logging_config",param:Ie})}_onWorkerMessage(Ie){let Ze=Ie.data,qe=Ze.data;if(Ze.msg==="destroyed"||this._workerDestroying){this._workerDestroying=!1,this._worker.terminate(),this._worker=null;return}switch(Ze.msg){case Lt.INIT_SEGMENT:case Lt.MEDIA_SEGMENT:this._emitter.emit(Ze.msg,qe.type,qe.data);break;case Lt.LOADING_COMPLETE:case Lt.RECOVERED_EARLY_EOF:this._emitter.emit(Ze.msg);break;case Lt.MEDIA_INFO:Object.setPrototypeOf(qe,ct.prototype),this._emitter.emit(Ze.msg,qe);break;case Lt.METADATA_ARRIVED:case Lt.SCRIPTDATA_ARRIVED:case Lt.STATISTICS_INFO:this._emitter.emit(Ze.msg,qe);break;case Lt.IO_ERROR:case Lt.DEMUX_ERROR:this._emitter.emit(Ze.msg,qe.type,qe.info);break;case Lt.RECOMMEND_SEEKPOINT:this._emitter.emit(Ze.msg,qe);break;case"logcat_callback":te.emitter.emit("log",qe.type,qe.logcat);break;default:break}}}var Gn=Rn,tr={ERROR:"error",SOURCE_OPEN:"source_open",UPDATE_END:"update_end",BUFFER_FULL:"buffer_full"};class hr{constructor(Ie){this.TAG="MSEController",this._config=Ie,this._emitter=new(ue()),this._config.isLive&&this._config.autoCleanupSourceBuffer==null&&(this._config.autoCleanupSourceBuffer=!0),this.e={onSourceOpen:this._onSourceOpen.bind(this),onSourceEnded:this._onSourceEnded.bind(this),onSourceClose:this._onSourceClose.bind(this),onSourceBufferError:this._onSourceBufferError.bind(this),onSourceBufferUpdateEnd:this._onSourceBufferUpdateEnd.bind(this)},this._mediaSource=null,this._mediaSourceObjectURL=null,this._mediaElement=null,this._isBufferFull=!1,this._hasPendingEos=!1,this._requireSetMediaDuration=!1,this._pendingMediaDuration=0,this._pendingSourceBufferInit=[],this._mimeTypes={video:null,audio:null},this._sourceBuffers={video:null,audio:null},this._lastInitSegments={video:null,audio:null},this._pendingSegments={video:[],audio:[]},this._pendingRemoveRanges={video:[],audio:[]},this._idrList=new Pt}destroy(){(this._mediaElement||this._mediaSource)&&this.detachMediaElement(),this.e=null,this._emitter.removeAllListeners(),this._emitter=null}on(Ie,Ze){this._emitter.addListener(Ie,Ze)}off(Ie,Ze){this._emitter.removeListener(Ie,Ze)}attachMediaElement(Ie){if(this._mediaSource)throw new E("MediaSource has been attached to an HTMLMediaElement!");let Ze=this._mediaSource=new window.MediaSource;Ze.addEventListener("sourceopen",this.e.onSourceOpen),Ze.addEventListener("sourceended",this.e.onSourceEnded),Ze.addEventListener("sourceclose",this.e.onSourceClose),this._mediaElement=Ie,this._mediaSourceObjectURL=window.URL.createObjectURL(this._mediaSource),Ie.src=this._mediaSourceObjectURL}detachMediaElement(){if(this._mediaSource){let Ie=this._mediaSource;for(let Ze in this._sourceBuffers){let qe=this._pendingSegments[Ze];qe.splice(0,qe.length),this._pendingSegments[Ze]=null,this._pendingRemoveRanges[Ze]=null,this._lastInitSegments[Ze]=null;let st=this._sourceBuffers[Ze];if(st){if(Ie.readyState!=="closed"){try{Ie.removeSourceBuffer(st)}catch(mt){te.e(this.TAG,mt.message)}st.removeEventListener("error",this.e.onSourceBufferError),st.removeEventListener("updateend",this.e.onSourceBufferUpdateEnd)}this._mimeTypes[Ze]=null,this._sourceBuffers[Ze]=null}}if(Ie.readyState==="open")try{Ie.endOfStream()}catch(Ze){te.e(this.TAG,Ze.message)}Ie.removeEventListener("sourceopen",this.e.onSourceOpen),Ie.removeEventListener("sourceended",this.e.onSourceEnded),Ie.removeEventListener("sourceclose",this.e.onSourceClose),this._pendingSourceBufferInit=[],this._isBufferFull=!1,this._idrList.clear(),this._mediaSource=null}this._mediaElement&&(this._mediaElement.src="",this._mediaElement.removeAttribute("src"),this._mediaElement=null),this._mediaSourceObjectURL&&(window.URL.revokeObjectURL(this._mediaSourceObjectURL),this._mediaSourceObjectURL=null)}appendInitSegment(Ie,Ze){if(!this._mediaSource||this._mediaSource.readyState!=="open"){this._pendingSourceBufferInit.push(Ie),this._pendingSegments[Ie.type].push(Ie);return}let qe=Ie,st=`${qe.container}`;qe.codec&&qe.codec.length>0&&(st+=`;codecs=${qe.codec}`);let mt=!1;if(te.v(this.TAG,"Received Initialization Segment, mimeType: "+st),this._lastInitSegments[qe.type]=qe,st!==this._mimeTypes[qe.type]){if(this._mimeTypes[qe.type])te.v(this.TAG,`Notice: ${qe.type} mimeType changed, origin: ${this._mimeTypes[qe.type]}, target: ${st}`);else{mt=!0;try{let Bt=this._sourceBuffers[qe.type]=this._mediaSource.addSourceBuffer(st);Bt.addEventListener("error",this.e.onSourceBufferError),Bt.addEventListener("updateend",this.e.onSourceBufferUpdateEnd)}catch(Bt){te.e(this.TAG,Bt.message),this._emitter.emit(tr.ERROR,{code:Bt.code,msg:Bt.message});return}}this._mimeTypes[qe.type]=st}Ze||this._pendingSegments[qe.type].push(qe),mt||this._sourceBuffers[qe.type]&&!this._sourceBuffers[qe.type].updating&&this._doAppendSegments(),ye.safari&&qe.container==="audio/mpeg"&&qe.mediaDuration>0&&(this._requireSetMediaDuration=!0,this._pendingMediaDuration=qe.mediaDuration/1e3,this._updateMediaSourceDuration())}appendMediaSegment(Ie){let Ze=Ie;this._pendingSegments[Ze.type].push(Ze),this._config.autoCleanupSourceBuffer&&this._needCleanupSourceBuffer()&&this._doCleanupSourceBuffer();let qe=this._sourceBuffers[Ze.type];qe&&!qe.updating&&!this._hasPendingRemoveRanges()&&this._doAppendSegments()}seek(Ie){for(let Ze in this._sourceBuffers){if(!this._sourceBuffers[Ze])continue;let qe=this._sourceBuffers[Ze];if(this._mediaSource.readyState==="open")try{qe.abort()}catch(mt){te.e(this.TAG,mt.message)}this._idrList.clear();let st=this._pendingSegments[Ze];if(st.splice(0,st.length),this._mediaSource.readyState!=="closed"){for(let mt=0;mt<qe.buffered.length;mt++){let Bt=qe.buffered.start(mt),kt=qe.buffered.end(mt);this._pendingRemoveRanges[Ze].push({start:Bt,end:kt})}if(qe.updating||this._doRemoveRanges(),ye.safari){let mt=this._lastInitSegments[Ze];mt&&(this._pendingSegments[Ze].push(mt),qe.updating||this._doAppendSegments())}}}}endOfStream(){let Ie=this._mediaSource,Ze=this._sourceBuffers;if(!Ie||Ie.readyState!=="open"){Ie&&Ie.readyState==="closed"&&this._hasPendingSegments()&&(this._hasPendingEos=!0);return}Ze.video&&Ze.video.updating||Ze.audio&&Ze.audio.updating?this._hasPendingEos=!0:(this._hasPendingEos=!1,Ie.endOfStream())}getNearestKeyframe(Ie){return this._idrList.getLastSyncPointBeforeDts(Ie)}_needCleanupSourceBuffer(){if(!this._config.autoCleanupSourceBuffer)return!1;let Ie=this._mediaElement.currentTime;for(let Ze in this._sourceBuffers){let qe=this._sourceBuffers[Ze];if(qe){let st=qe.buffered;if(st.length>=1&&Ie-st.start(0)>=this._config.autoCleanupMaxBackwardDuration)return!0}}return!1}_doCleanupSourceBuffer(){let Ie=this._mediaElement.currentTime;for(let Ze in this._sourceBuffers){let qe=this._sourceBuffers[Ze];if(qe){let st=qe.buffered,mt=!1;for(let Bt=0;Bt<st.length;Bt++){let kt=st.start(Bt),Ft=st.end(Bt);if(kt<=Ie&&Ie<Ft+3){if(Ie-kt>=this._config.autoCleanupMaxBackwardDuration){mt=!0;let qt=Ie-this._config.autoCleanupMinBackwardDuration;this._pendingRemoveRanges[Ze].push({start:kt,end:qt})}}else Ft<Ie&&(mt=!0,this._pendingRemoveRanges[Ze].push({start:kt,end:Ft}))}mt&&!qe.updating&&this._doRemoveRanges()}}}_updateMediaSourceDuration(){let Ie=this._sourceBuffers;if(this._mediaElement.readyState===0||this._mediaSource.readyState!=="open"||Ie.video&&Ie.video.updating||Ie.audio&&Ie.audio.updating)return;let Ze=this._mediaSource.duration,qe=this._pendingMediaDuration;qe>0&&(isNaN(Ze)||qe>Ze)&&(te.v(this.TAG,`Update MediaSource duration from ${Ze} to ${qe}`),this._mediaSource.duration=qe),this._requireSetMediaDuration=!1,this._pendingMediaDuration=0}_doRemoveRanges(){for(let Ie in this._pendingRemoveRanges){if(!this._sourceBuffers[Ie]||this._sourceBuffers[Ie].updating)continue;let Ze=this._sourceBuffers[Ie],qe=this._pendingRemoveRanges[Ie];for(;qe.length&&!Ze.updating;){let st=qe.shift();Ze.remove(st.start,st.end)}}}_doAppendSegments(){let Ie=this._pendingSegments;for(let Ze in Ie)if(!(!this._sourceBuffers[Ze]||this._sourceBuffers[Ze].updating)&&Ie[Ze].length>0){let qe=Ie[Ze].shift();if(qe.timestampOffset){let st=this._sourceBuffers[Ze].timestampOffset,mt=qe.timestampOffset/1e3;Math.abs(st-mt)>.1&&(te.v(this.TAG,`Update MPEG audio timestampOffset from ${st} to ${mt}`),this._sourceBuffers[Ze].timestampOffset=mt),delete qe.timestampOffset}if(!qe.data||qe.data.byteLength===0)continue;try{this._sourceBuffers[Ze].appendBuffer(qe.data),this._isBufferFull=!1,Ze==="video"&&qe.hasOwnProperty("info")&&this._idrList.appendArray(qe.info.syncPoints)}catch(st){this._pendingSegments[Ze].unshift(qe),st.code===22?(this._isBufferFull||this._emitter.emit(tr.BUFFER_FULL),this._isBufferFull=!0):(te.e(this.TAG,st.message),this._emitter.emit(tr.ERROR,{code:st.code,msg:st.message}))}}}_onSourceOpen(){if(te.v(this.TAG,"MediaSource onSourceOpen"),this._mediaSource.removeEventListener("sourceopen",this.e.onSourceOpen),this._pendingSourceBufferInit.length>0){let Ie=this._pendingSourceBufferInit;for(;Ie.length;){let Ze=Ie.shift();this.appendInitSegment(Ze,!0)}}this._hasPendingSegments()&&this._doAppendSegments(),this._emitter.emit(tr.SOURCE_OPEN)}_onSourceEnded(){te.v(this.TAG,"MediaSource onSourceEnded")}_onSourceClose(){te.v(this.TAG,"MediaSource onSourceClose"),this._mediaSource&&this.e!=null&&(this._mediaSource.removeEventListener("sourceopen",this.e.onSourceOpen),this._mediaSource.removeEventListener("sourceended",this.e.onSourceEnded),this._mediaSource.removeEventListener("sourceclose",this.e.onSourceClose))}_hasPendingSegments(){let Ie=this._pendingSegments;return Ie.video.length>0||Ie.audio.length>0}_hasPendingRemoveRanges(){let Ie=this._pendingRemoveRanges;return Ie.video.length>0||Ie.audio.length>0}_onSourceBufferUpdateEnd(){this._requireSetMediaDuration?this._updateMediaSourceDuration():this._hasPendingRemoveRanges()?this._doRemoveRanges():this._hasPendingSegments()?this._doAppendSegments():this._hasPendingEos&&this.endOfStream(),this._emitter.emit(tr.UPDATE_END)}_onSourceBufferError(Ie){te.e(this.TAG,`SourceBuffer Error: ${Ie}`)}}var ur=hr;const zn={NETWORK_ERROR:"NetworkError",MEDIA_ERROR:"MediaError",OTHER_ERROR:"OtherError"},Bn={NETWORK_EXCEPTION:re.EXCEPTION,NETWORK_STATUS_CODE_INVALID:re.HTTP_STATUS_CODE_INVALID,NETWORK_TIMEOUT:re.CONNECTING_TIMEOUT,NETWORK_UNRECOVERABLE_EARLY_EOF:re.UNRECOVERABLE_EARLY_EOF,MEDIA_MSE_ERROR:"MediaMSEError",MEDIA_FORMAT_ERROR:Ne.FORMAT_ERROR,MEDIA_FORMAT_UNSUPPORTED:Ne.FORMAT_UNSUPPORTED,MEDIA_CODEC_UNSUPPORTED:Ne.CODEC_UNSUPPORTED};class ir{constructor(Ie,Ze){if(this.TAG="FlvPlayer",this._type="FlvPlayer",this._emitter=new(ue()),this._config=ut(),typeof Ze=="object"&&Object.assign(this._config,Ze),Ie.type.toLowerCase()!=="flv")throw new b("FlvPlayer requires an flv MediaDataSource input!");Ie.isLive===!0&&(this._config.isLive=!0),this.e={onvLoadedMetadata:this._onvLoadedMetadata.bind(this),onvSeeking:this._onvSeeking.bind(this),onvCanPlay:this._onvCanPlay.bind(this),onvStalled:this._onvStalled.bind(this),onvProgress:this._onvProgress.bind(this)},self.performance&&self.performance.now?this._now=self.performance.now.bind(self.performance):this._now=Date.now,this._pendingSeekTime=null,this._requestSetTime=!1,this._seekpointRecord=null,this._progressChecker=null,this._mediaDataSource=Ie,this._mediaElement=null,this._msectl=null,this._transmuxer=null,this._mseSourceOpened=!1,this._hasPendingLoad=!1,this._receivedCanPlay=!1,this._mediaInfo=null,this._statisticsInfo=null;let qe=ye.chrome&&(ye.version.major<50||ye.version.major===50&&ye.version.build<2661);this._alwaysSeekKeyframe=!!(qe||ye.msedge||ye.msie),this._alwaysSeekKeyframe&&(this._config.accurateSeek=!1)}destroy(){this._progressChecker!=null&&(window.clearInterval(this._progressChecker),this._progressChecker=null),this._transmuxer&&this.unload(),this._mediaElement&&this.detachMediaElement(),this.e=null,this._mediaDataSource=null,this._emitter.removeAllListeners(),this._emitter=null}on(Ie,Ze){Ie===$e.MEDIA_INFO?this._mediaInfo!=null&&Promise.resolve().then(()=>{this._emitter.emit($e.MEDIA_INFO,this.mediaInfo)}):Ie===$e.STATISTICS_INFO&&this._statisticsInfo!=null&&Promise.resolve().then(()=>{this._emitter.emit($e.STATISTICS_INFO,this.statisticsInfo)}),this._emitter.addListener(Ie,Ze)}off(Ie,Ze){this._emitter.removeListener(Ie,Ze)}attachMediaElement(Ie){if(this._mediaElement=Ie,Ie.addEventListener("loadedmetadata",this.e.onvLoadedMetadata),Ie.addEventListener("seeking",this.e.onvSeeking),Ie.addEventListener("canplay",this.e.onvCanPlay),Ie.addEventListener("stalled",this.e.onvStalled),Ie.addEventListener("progress",this.e.onvProgress),this._msectl=new ur(this._config),this._msectl.on(tr.UPDATE_END,this._onmseUpdateEnd.bind(this)),this._msectl.on(tr.BUFFER_FULL,this._onmseBufferFull.bind(this)),this._msectl.on(tr.SOURCE_OPEN,()=>{this._mseSourceOpened=!0,this._hasPendingLoad&&(this._hasPendingLoad=!1,this.load())}),this._msectl.on(tr.ERROR,Ze=>{this._emitter.emit($e.ERROR,zn.MEDIA_ERROR,Bn.MEDIA_MSE_ERROR,Ze)}),this._msectl.attachMediaElement(Ie),this._pendingSeekTime!=null)try{Ie.currentTime=this._pendingSeekTime,this._pendingSeekTime=null}catch(Ze){}}detachMediaElement(){this._mediaElement&&(this._msectl.detachMediaElement(),this._mediaElement.removeEventListener("loadedmetadata",this.e.onvLoadedMetadata),this._mediaElement.removeEventListener("seeking",this.e.onvSeeking),this._mediaElement.removeEventListener("canplay",this.e.onvCanPlay),this._mediaElement.removeEventListener("stalled",this.e.onvStalled),this._mediaElement.removeEventListener("progress",this.e.onvProgress),this._mediaElement=null),this._msectl&&(this._msectl.destroy(),this._msectl=null)}load(){if(!this._mediaElement)throw new E("HTMLMediaElement must be attached before load()!");if(this._transmuxer)throw new E("FlvPlayer.load() has been called, please call unload() first!");if(!this._hasPendingLoad){if(this._config.deferLoadAfterSourceOpen&&this._mseSourceOpened===!1){this._hasPendingLoad=!0;return}this._mediaElement.readyState>0&&(this._requestSetTime=!0,this._mediaElement.currentTime=0),this._transmuxer=new Gn(this._mediaDataSource,this._config),this._transmuxer.on(Lt.INIT_SEGMENT,(Ie,Ze)=>{this._msectl.appendInitSegment(Ze)}),this._transmuxer.on(Lt.MEDIA_SEGMENT,(Ie,Ze)=>{if(this._msectl.appendMediaSegment(Ze),this._config.lazyLoad&&!this._config.isLive){let qe=this._mediaElement.currentTime;Ze.info.endDts>=(qe+this._config.lazyLoadMaxDuration)*1e3&&this._progressChecker==null&&(te.v(this.TAG,"Maximum buffering duration exceeded, suspend transmuxing task"),this._suspendTransmuxer())}}),this._transmuxer.on(Lt.LOADING_COMPLETE,()=>{this._msectl.endOfStream(),this._emitter.emit($e.LOADING_COMPLETE)}),this._transmuxer.on(Lt.RECOVERED_EARLY_EOF,()=>{this._emitter.emit($e.RECOVERED_EARLY_EOF)}),this._transmuxer.on(Lt.IO_ERROR,(Ie,Ze)=>{this._emitter.emit($e.ERROR,zn.NETWORK_ERROR,Ie,Ze)}),this._transmuxer.on(Lt.DEMUX_ERROR,(Ie,Ze)=>{this._emitter.emit($e.ERROR,zn.MEDIA_ERROR,Ie,{code:-1,msg:Ze})}),this._transmuxer.on(Lt.MEDIA_INFO,Ie=>{this._mediaInfo=Ie,this._emitter.emit($e.MEDIA_INFO,Object.assign({},Ie))}),this._transmuxer.on(Lt.METADATA_ARRIVED,Ie=>{this._emitter.emit($e.METADATA_ARRIVED,Ie)}),this._transmuxer.on(Lt.SCRIPTDATA_ARRIVED,Ie=>{this._emitter.emit($e.SCRIPTDATA_ARRIVED,Ie)}),this._transmuxer.on(Lt.STATISTICS_INFO,Ie=>{this._statisticsInfo=this._fillStatisticsInfo(Ie),this._emitter.emit($e.STATISTICS_INFO,Object.assign({},this._statisticsInfo))}),this._transmuxer.on(Lt.RECOMMEND_SEEKPOINT,Ie=>{this._mediaElement&&!this._config.accurateSeek&&(this._requestSetTime=!0,this._mediaElement.currentTime=Ie/1e3)}),this._transmuxer.open()}}unload(){this._mediaElement&&this._mediaElement.pause(),this._msectl&&this._msectl.seek(0),this._transmuxer&&(this._transmuxer.close(),this._transmuxer.destroy(),this._transmuxer=null)}play(){return this._mediaElement.play()}pause(){this._mediaElement.pause()}get type(){return this._type}get buffered(){return this._mediaElement.buffered}get duration(){return this._mediaElement.duration}get volume(){return this._mediaElement.volume}set volume(Ie){this._mediaElement.volume=Ie}get muted(){return this._mediaElement.muted}set muted(Ie){this._mediaElement.muted=Ie}get currentTime(){return this._mediaElement?this._mediaElement.currentTime:0}set currentTime(Ie){this._mediaElement?this._internalSeek(Ie):this._pendingSeekTime=Ie}get mediaInfo(){return Object.assign({},this._mediaInfo)}get statisticsInfo(){return this._statisticsInfo==null&&(this._statisticsInfo={}),this._statisticsInfo=this._fillStatisticsInfo(this._statisticsInfo),Object.assign({},this._statisticsInfo)}_fillStatisticsInfo(Ie){if(Ie.playerType=this._type,!(this._mediaElement instanceof HTMLVideoElement))return Ie;let Ze=!0,qe=0,st=0;if(this._mediaElement.getVideoPlaybackQuality){let mt=this._mediaElement.getVideoPlaybackQuality();qe=mt.totalVideoFrames,st=mt.droppedVideoFrames}else this._mediaElement.webkitDecodedFrameCount!=null?(qe=this._mediaElement.webkitDecodedFrameCount,st=this._mediaElement.webkitDroppedFrameCount):Ze=!1;return Ze&&(Ie.decodedFrames=qe,Ie.droppedFrames=st),Ie}_onmseUpdateEnd(){if(!this._config.lazyLoad||this._config.isLive)return;let Ie=this._mediaElement.buffered,Ze=this._mediaElement.currentTime,qe=0,st=0;for(let mt=0;mt<Ie.length;mt++){let Bt=Ie.start(mt),kt=Ie.end(mt);if(Bt<=Ze&&Ze<kt){qe=Bt,st=kt;break}}st>=Ze+this._config.lazyLoadMaxDuration&&this._progressChecker==null&&(te.v(this.TAG,"Maximum buffering duration exceeded, suspend transmuxing task"),this._suspendTransmuxer())}_onmseBufferFull(){te.v(this.TAG,"MSE SourceBuffer is full, suspend transmuxing task"),this._progressChecker==null&&this._suspendTransmuxer()}_suspendTransmuxer(){this._transmuxer&&(this._transmuxer.pause(),this._progressChecker==null&&(this._progressChecker=window.setInterval(this._checkProgressAndResume.bind(this),1e3)))}_checkProgressAndResume(){let Ie=this._mediaElement.currentTime,Ze=this._mediaElement.buffered,qe=!1;for(let st=0;st<Ze.length;st++){let mt=Ze.start(st),Bt=Ze.end(st);if(Ie>=mt&&Ie<Bt){Ie>=Bt-this._config.lazyLoadRecoverDuration&&(qe=!0);break}}qe&&(window.clearInterval(this._progressChecker),this._progressChecker=null,qe&&(te.v(this.TAG,"Continue loading from paused position"),this._transmuxer.resume()))}_isTimepointBuffered(Ie){let Ze=this._mediaElement.buffered;for(let qe=0;qe<Ze.length;qe++){let st=Ze.start(qe),mt=Ze.end(qe);if(Ie>=st&&Ie<mt)return!0}return!1}_internalSeek(Ie){let Ze=this._isTimepointBuffered(Ie),qe=!1,st=0;if(Ie<1&&this._mediaElement.buffered.length>0){let mt=this._mediaElement.buffered.start(0);(mt<1&&Ie<mt||ye.safari)&&(qe=!0,st=ye.safari?.1:mt)}if(qe)this._requestSetTime=!0,this._mediaElement.currentTime=st;else if(Ze){if(!this._alwaysSeekKeyframe)this._requestSetTime=!0,this._mediaElement.currentTime=Ie;else{let mt=this._msectl.getNearestKeyframe(Math.floor(Ie*1e3));this._requestSetTime=!0,mt!=null?this._mediaElement.currentTime=mt.dts/1e3:this._mediaElement.currentTime=Ie}this._progressChecker!=null&&this._checkProgressAndResume()}else this._progressChecker!=null&&(window.clearInterval(this._progressChecker),this._progressChecker=null),this._msectl.seek(Ie),this._transmuxer.seek(Math.floor(Ie*1e3)),this._config.accurateSeek&&(this._requestSetTime=!0,this._mediaElement.currentTime=Ie)}_checkAndApplyUnbufferedSeekpoint(){if(this._seekpointRecord)if(this._seekpointRecord.recordTime<=this._now()-100){let Ie=this._mediaElement.currentTime;this._seekpointRecord=null,this._isTimepointBuffered(Ie)||(this._progressChecker!=null&&(window.clearTimeout(this._progressChecker),this._progressChecker=null),this._msectl.seek(Ie),this._transmuxer.seek(Math.floor(Ie*1e3)),this._config.accurateSeek&&(this._requestSetTime=!0,this._mediaElement.currentTime=Ie))}else window.setTimeout(this._checkAndApplyUnbufferedSeekpoint.bind(this),50)}_checkAndResumeStuckPlayback(Ie){let Ze=this._mediaElement;if(Ie||!this._receivedCanPlay||Ze.readyState<2){let qe=Ze.buffered;qe.length>0&&Ze.currentTime<qe.start(0)&&(te.w(this.TAG,`Playback seems stuck at ${Ze.currentTime}, seek to ${qe.start(0)}`),this._requestSetTime=!0,this._mediaElement.currentTime=qe.start(0),this._mediaElement.removeEventListener("progress",this.e.onvProgress))}else this._mediaElement.removeEventListener("progress",this.e.onvProgress)}_onvLoadedMetadata(Ie){this._pendingSeekTime!=null&&(this._mediaElement.currentTime=this._pendingSeekTime,this._pendingSeekTime=null)}_onvSeeking(Ie){let Ze=this._mediaElement.currentTime,qe=this._mediaElement.buffered;if(this._requestSetTime){this._requestSetTime=!1;return}if(Ze<1&&qe.length>0){let st=qe.start(0);if(st<1&&Ze<st||ye.safari){this._requestSetTime=!0,this._mediaElement.currentTime=ye.safari?.1:st;return}}if(this._isTimepointBuffered(Ze)){if(this._alwaysSeekKeyframe){let st=this._msectl.getNearestKeyframe(Math.floor(Ze*1e3));st!=null&&(this._requestSetTime=!0,this._mediaElement.currentTime=st.dts/1e3)}this._progressChecker!=null&&this._checkProgressAndResume();return}this._seekpointRecord={seekPoint:Ze,recordTime:this._now()},window.setTimeout(this._checkAndApplyUnbufferedSeekpoint.bind(this),50)}_onvCanPlay(Ie){this._receivedCanPlay=!0,this._mediaElement.removeEventListener("canplay",this.e.onvCanPlay)}_onvStalled(Ie){this._checkAndResumeStuckPlayback(!0)}_onvProgress(Ie){this._checkAndResumeStuckPlayback()}}var Kn=ir;class Nn{constructor(Ie,Ze){if(this.TAG="NativePlayer",this._type="NativePlayer",this._emitter=new(ue()),this._config=ut(),typeof Ze=="object"&&Object.assign(this._config,Ze),Ie.type.toLowerCase()==="flv")throw new b("NativePlayer does't support flv MediaDataSource input!");if(Ie.hasOwnProperty("segments"))throw new b(`NativePlayer(${Ie.type}) doesn't support multipart playback!`);this.e={onvLoadedMetadata:this._onvLoadedMetadata.bind(this)},this._pendingSeekTime=null,this._statisticsReporter=null,this._mediaDataSource=Ie,this._mediaElement=null}destroy(){this._mediaElement&&(this.unload(),this.detachMediaElement()),this.e=null,this._mediaDataSource=null,this._emitter.removeAllListeners(),this._emitter=null}on(Ie,Ze){Ie===$e.MEDIA_INFO?this._mediaElement!=null&&this._mediaElement.readyState!==0&&Promise.resolve().then(()=>{this._emitter.emit($e.MEDIA_INFO,this.mediaInfo)}):Ie===$e.STATISTICS_INFO&&this._mediaElement!=null&&this._mediaElement.readyState!==0&&Promise.resolve().then(()=>{this._emitter.emit($e.STATISTICS_INFO,this.statisticsInfo)}),this._emitter.addListener(Ie,Ze)}off(Ie,Ze){this._emitter.removeListener(Ie,Ze)}attachMediaElement(Ie){if(this._mediaElement=Ie,Ie.addEventListener("loadedmetadata",this.e.onvLoadedMetadata),this._pendingSeekTime!=null)try{Ie.currentTime=this._pendingSeekTime,this._pendingSeekTime=null}catch(Ze){}}detachMediaElement(){this._mediaElement&&(this._mediaElement.src="",this._mediaElement.removeAttribute("src"),this._mediaElement.removeEventListener("loadedmetadata",this.e.onvLoadedMetadata),this._mediaElement=null),this._statisticsReporter!=null&&(window.clearInterval(this._statisticsReporter),this._statisticsReporter=null)}load(){if(!this._mediaElement)throw new E("HTMLMediaElement must be attached before load()!");this._mediaElement.src=this._mediaDataSource.url,this._mediaElement.readyState>0&&(this._mediaElement.currentTime=0),this._mediaElement.preload="auto",this._mediaElement.load(),this._statisticsReporter=window.setInterval(this._reportStatisticsInfo.bind(this),this._config.statisticsInfoReportInterval)}unload(){this._mediaElement&&(this._mediaElement.src="",this._mediaElement.removeAttribute("src")),this._statisticsReporter!=null&&(window.clearInterval(this._statisticsReporter),this._statisticsReporter=null)}play(){return this._mediaElement.play()}pause(){this._mediaElement.pause()}get type(){return this._type}get buffered(){return this._mediaElement.buffered}get duration(){return this._mediaElement.duration}get volume(){return this._mediaElement.volume}set volume(Ie){this._mediaElement.volume=Ie}get muted(){return this._mediaElement.muted}set muted(Ie){this._mediaElement.muted=Ie}get currentTime(){return this._mediaElement?this._mediaElement.currentTime:0}set currentTime(Ie){this._mediaElement?this._mediaElement.currentTime=Ie:this._pendingSeekTime=Ie}get mediaInfo(){let Ze={mimeType:(this._mediaElement instanceof HTMLAudioElement?"audio/":"video/")+this._mediaDataSource.type};return this._mediaElement&&(Ze.duration=Math.floor(this._mediaElement.duration*1e3),this._mediaElement instanceof HTMLVideoElement&&(Ze.width=this._mediaElement.videoWidth,Ze.height=this._mediaElement.videoHeight)),Ze}get statisticsInfo(){let Ie={playerType:this._type,url:this._mediaDataSource.url};if(!(this._mediaElement instanceof HTMLVideoElement))return Ie;let Ze=!0,qe=0,st=0;if(this._mediaElement.getVideoPlaybackQuality){let mt=this._mediaElement.getVideoPlaybackQuality();qe=mt.totalVideoFrames,st=mt.droppedVideoFrames}else this._mediaElement.webkitDecodedFrameCount!=null?(qe=this._mediaElement.webkitDecodedFrameCount,st=this._mediaElement.webkitDroppedFrameCount):Ze=!1;return Ze&&(Ie.decodedFrames=qe,Ie.droppedFrames=st),Ie}_onvLoadedMetadata(Ie){this._pendingSeekTime!=null&&(this._mediaElement.currentTime=this._pendingSeekTime,this._pendingSeekTime=null),this._emitter.emit($e.MEDIA_INFO,this.mediaInfo)}_reportStatisticsInfo(){this._emitter.emit($e.STATISTICS_INFO,this.statisticsInfo)}}var yn=Nn;ie.install();function Hn(Jt,Ie){let Ze=Jt;if(Ze==null||typeof Ze!="object")throw new b("MediaDataSource must be an javascript object!");if(!Ze.hasOwnProperty("type"))throw new b("MediaDataSource must has type field to indicate video file type!");switch(Ze.type){case"flv":return new Kn(Ze,Ie);default:return new yn(Ze,Ie)}}function dr(){return ze.supportMSEH264Playback()}function Mn(){return ze.getFeatureList()}let Cn={};Cn.createPlayer=Hn,Cn.isSupported=dr,Cn.getFeatureList=Mn,Cn.BaseLoader=ae,Cn.LoaderStatus=x,Cn.LoaderErrors=re,Cn.Events=$e,Cn.ErrorTypes=zn,Cn.ErrorDetails=Bn,Cn.FlvPlayer=Kn,Cn.NativePlayer=yn,Cn.LoggingControl=et,Object.defineProperty(Cn,"version",{enumerable:!0,get:function(){return"__VERSION__"}});var $n=Cn},93125:function(Xt,Mt,be){(function(ce){if(1)window.OSS=ce(),Xt.exports=ce();else var ie})(function(){var ce;return function(){function ie(Ce,ue,se){function te(ne,E){if(!ue[ne]){if(!Ce[ne]){var b=void 0;if(!E&&b)return require(ne,!0);if(le)return le(ne,!0);var z=new Error("Cannot find module '"+ne+"'");throw z.code="MODULE_NOT_FOUND",z}var x=ue[ne]={exports:{}};Ce[ne][0].call(x.exports,function(re){return te(Ce[ne][1][re]||re)},x,x.exports,ie,Ce,ue,se)}return ue[ne].exports}for(var le=void 0,ee=0;ee<se.length;ee++)te(se[ee]);return te}return ie}()({1:[function(ie,Ce,ue){"use strict";var se=ie("./browser/client");se.Buffer=ie("buffer").Buffer,se.co=ie("co"),se.urllib=ie("../shims/xhr"),se.version=ie("./browser/version").version,Ce.exports=se},{"../shims/xhr":244,"./browser/client":2,"./browser/version":5,buffer:38,co:41}],2:[function(ie,Ce,ue){(function(se,te){"use strict";function le(ze){return ze&&ze.__esModule?ze:{default:ze}}function ee(ze,Ve){return ze[Ve]||ze[Ve.toLowerCase()]}function ne(ze,Ve){var $e=Ee.parse(ze);if(!$e.protocol){var nt=Ve?"https://":"http://";$e=Ee.parse(nt+ze)}if($e.protocol!=="http:"&&$e.protocol!=="https:")throw new Error("Endpoint protocol must be http or https.");return $e}function E(ze,Ve,$e){var nt=$e?"https://":"http://",et=Ve?"-internal.aliyuncs.com":".aliyuncs.com";return ze.substr(0,14)==="vpc100-oss-cn-"&&(et=".aliyuncs.com"),Ee.parse(nt+ze+et)}function b(){return document&&document.location&&document.location.protocol==="https:"}function z(ze,Ve){if(!(this instanceof z))return new z(ze,Ve);ze&&ze.inited?this.options=ze:this.options=z.initOptions(ze),this.options.cancelFlag=!1,this.options.urllib?this.urllib=this.options.urllib:(this.urllib=Qe,this.agent=this.options.agent||ut),this.ctx=Ve,this.userAgent=this._getUserAgent(),this.options.amendTimeSkewed=0}var x=ie("babel-runtime/regenerator"),re=le(x),ae=ie("babel-runtime/core-js/object/keys"),oe=le(ae),ve=ie("debug")("ali-oss"),ye=ie("./../../shims/crypto/crypto.js"),me=ie("path"),ge=ie("copy-to"),_e=ie("mime"),he=ie("xml2js"),pe=ie("humanize-ms"),ke=ie("agentkeepalive"),Te=ie("merge-descriptors"),Ee=ie("url"),Oe=ie("is-type-of"),je=ie("platform"),Pe=ie("utility"),Qe=ie("urllib"),Xe=ie("./version"),ot=ie("dateformat"),He=ie("bowser"),rt=ie("../common/signUtils"),Ye=ie("../common/utils"),ut=new ke;Ce.exports=z,z.initOptions=function(ze){if(!ze||!ze.accessKeyId||!ze.accessKeySecret)throw new Error("require accessKeyId, accessKeySecret");var Ve=b(),$e={region:"oss-cn-hangzhou",internal:!1,secure:Ve,bucket:null,endpoint:null,cname:!1};if((0,oe.default)(ze).forEach(function(nt){ze[nt]!==void 0&&($e[nt]=ze[nt])}),$e.accessKeyId=$e.accessKeyId.trim(),$e.accessKeySecret=$e.accessKeySecret.trim(),$e.timeout&&($e.timeout=pe($e.timeout)),$e.endpoint)$e.endpoint=ne($e.endpoint,$e.secure);else{if(!$e.region)throw new Error("require options.endpoint or options.region");$e.endpoint=E($e.region,$e.internal,$e.secure)}return $e.inited=!0,$e};var Ge=z.prototype;Te(Ge,ie("./object")),Te(Ge,ie("./managed_upload")),Te(Ge,ie("../common/multipart")),Te(Ge,ie("../common/thunkpool.js")),z.Wrapper=ie("./wrapper"),Ge.signature=function(ze){return ve("authorization stringToSign: %s",ze),rt.computeSignature(this.options.accessKeySecret,ze)},Ge.authorization=function(ze,Ve,$e,nt){var et=rt.buildCanonicalString(ze.toUpperCase(),Ve,{headers:nt,parameters:$e});return rt.authorization(this.options.accessKeyId,this.options.accessKeySecret,et)},Ge.createRequest=function(ze){var Ve={"x-oss-date":ot(+new Date+this.options.amendTimeSkewed,"UTC:ddd, dd mmm yyyy HH:MM:ss 'GMT'"),"x-oss-user-agent":this.userAgent};this.options.stsToken&&(Ve["x-oss-security-token"]=this.options.stsToken),ge(ze.headers).to(Ve),ee(Ve,"Content-Type")||(ze.mime===_e.default_type&&(ze.mime=""),ze.mime&&ze.mime.indexOf("/")>0?Ve["Content-Type"]=ze.mime:Ve["Content-Type"]=_e.getType(ze.mime||me.extname(ze.object||""))||"application/octet-stream"),ze.content&&(Ve["Content-Md5"]=ye.createHash("md5").update(new te(ze.content,"utf8")).digest("base64"),Ve["Content-Length"]||(Ve["Content-Length"]=ze.content.length));var $e=this._getResource(ze);Ve.authorization=this.authorization(ze.method,$e,ze.subres,Ve);var nt=this._getReqUrl(ze);ve("request %s %s, with headers %j, !!stream: %s",ze.method,nt,Ve,!!ze.stream);var et=ze.timeout||this.options.timeout;return{url:nt,params:{agent:this.agent,method:ze.method,content:ze.content,stream:ze.stream,headers:Ve,timeout:et,writeStream:ze.writeStream,customResponse:ze.customResponse,ctx:ze.ctx||this.ctx}}},Ge.request=re.default.mark(function ze(Ve){var $e,nt,et,pt;return re.default.wrap(function(ct){for(;;)switch(ct.prev=ct.next){case 0:return $e=this.createRequest(Ve),nt=void 0,et=void 0,ct.prev=3,ct.next=6,this.urllib.request($e.url,$e.params);case 6:nt=ct.sent,ve("response %s %s, got %s, headers: %j",Ve.method,$e.url,nt.status,nt.headers),ct.next=13;break;case 10:ct.prev=10,ct.t0=ct.catch(3),et=ct.t0;case 13:if(pt=void 0,!nt||!Ve.successStatuses||Ve.successStatuses.indexOf(nt.status)!==-1){ct.next=26;break}return ct.next=17,this.requestError(nt);case 17:if(pt=ct.sent,pt.code!=="RequestTimeTooSkewed"){ct.next=23;break}return this.options.amendTimeSkewed=+new Date(pt.serverTime)-new Date,ct.next=22,this.request(Ve);case 22:return ct.abrupt("return",ct.sent);case 23:pt.params=Ve,ct.next=30;break;case 26:if(!et){ct.next=30;break}return ct.next=29,this.requestError(et);case 29:pt=ct.sent;case 30:if(!pt){ct.next=32;break}throw pt;case 32:if(!Ve.xmlResponse){ct.next=36;break}return ct.next=35,this.parseXML(nt.data);case 35:nt.data=ct.sent;case 36:return ct.abrupt("return",nt);case 37:case"end":return ct.stop()}},ze,this,[[3,10]])}),Ge._getResource=function(ze){var Ve="/";return ze.bucket&&(Ve+=ze.bucket+"/"),ze.object&&(Ve+=ze.object),Ve},Ge._isIP=function(ze){return Ye._isIP(ze)},Ge._escape=function(ze){return Pe.encodeURIComponent(ze).replace(/%2F/g,"/")},Ge._getReqUrl=function(ze){var Ve={};ge(this.options.endpoint).to(Ve);var $e=this._isIP(Ve.hostname),nt=this.options.cname;!ze.bucket||nt||$e||(Ve.host=ze.bucket+"."+Ve.host);var et="/";ze.bucket&&$e&&(et+=ze.bucket+"/"),ze.object&&(et+=this._escape(ze.object).replace(/\+/g,"%2B")),Ve.pathname=et;var pt={};if(ze.query&&Te(pt,ze.query),ze.subres){var ct={};Oe.string(ze.subres)?ct[ze.subres]="":Oe.array(ze.subres)?ze.subres.forEach(function(Ot){ct[Ot]=""}):ct=ze.subres,Te(pt,ct)}return Ve.query=pt,Ee.format(Ve)},Ge._getUserAgent=function(){var ze=se&&se.browser?"js":"nodejs",Ve="aliyun-sdk-"+ze+"/"+Xe.version,$e=je.description;return!$e&&se&&($e="Node.js "+se.version.slice(1)+" on "+se.platform+" "+se.arch),this._checkUserAgent(Ve+" "+$e)},Ge._checkUserAgent=function(ze){return ze.replace(/\u03b1/,"alpha").replace(/\u03b2/,"beta")},Ge.checkBrowserAndVersion=function(ze,Ve){return He.name===ze&&He.version.split(".")[0]===Ve},Ge.parseXML=function(ze){return function(Ve){te.isBuffer(ze)&&(ze=ze.toString()),he.parseString(ze,{explicitRoot:!1,explicitArray:!1},Ve)}},Ge.requestError=re.default.mark(function ze(Ve){var $e,nt,et,pt;return re.default.wrap(function(ct){for(;;)switch(ct.prev=ct.next){case 0:if($e=null,Ve.data&&Ve.data.length){ct.next=5;break}Ve.status===-1||Ve.status===-2?($e=new Error(Ve.message),$e.name=Ve.name,$e.status=Ve.status,$e.code=Ve.name):(Ve.status===404?($e=new Error("Object not exists"),$e.name="NoSuchKeyError",$e.status=404,$e.code="NoSuchKey"):Ve.status===412?($e=new Error("Pre condition failed"),$e.name="PreconditionFailedError",$e.status=412,$e.code="PreconditionFailed"):($e=new Error("Unknow error, status: "+Ve.status),$e.name="UnknowError",$e.status=Ve.status),$e.requestId=Ve.headers["x-oss-request-id"],$e.host=""),ct.next=30;break;case 5:return nt=String(Ve.data),ve("request response error data: %s",nt),et=void 0,ct.prev=8,ct.next=11,this.parseXML(nt)||{};case 11:et=ct.sent,ct.next=21;break;case 14:return ct.prev=14,ct.t0=ct.catch(8),ve(nt),ct.t0.message+=`
|
|
|
raw xml: `+nt,ct.t0.status=Ve.status,ct.t0.requestId=Ve.headers["x-oss-request-id"],ct.abrupt("return",ct.t0);case 21:pt=et.Message||"unknow request error, status: "+Ve.status,et.Condition&&(pt+=" (condition: "+et.Condition+")"),$e=new Error(pt),$e.name=et.Code?et.Code+"Error":"UnknowError",$e.status=Ve.status,$e.code=et.Code,$e.requestId=et.RequestId,$e.hostId=et.HostId,$e.serverTime=et.ServerTime;case 30:return ve("generate error %j",$e),ct.abrupt("return",$e);case 32:case"end":return ct.stop()}},ze,this,[[8,14]])})}).call(this,ie("_process"),ie("buffer").Buffer)},{"../common/multipart":8,"../common/signUtils":9,"../common/thunkpool.js":10,"../common/utils":11,"./../../shims/crypto/crypto.js":237,"./managed_upload":3,"./object":4,"./version":5,"./wrapper":6,_process:173,agentkeepalive:12,"babel-runtime/core-js/object/keys":23,"babel-runtime/regenerator":33,bowser:35,buffer:38,"copy-to":43,dateformat:154,debug:155,"humanize-ms":160,"is-type-of":165,"merge-descriptors":168,mime:242,path:170,platform:171,url:203,urllib:244,utility:243,xml2js:213}],3:[function(ie,Ce,ue){(function(se){"use strict";function te(ge){return ge&&ge.__esModule?ge:{default:ge}}function le(ge,_e){if(!(this instanceof le))return new le(ge,_e);me.call(this,_e),this.file=ge,this.reader=new FileReader,this.start=0,this.finish=!1,this.fileBuffer=null}var ee=ie("babel-runtime/core-js/array/from"),ne=te(ee),E=ie("babel-runtime/regenerator"),b=te(E),z=ie("is-type-of"),x=ie("util"),re=ie("path"),ae=ie("mime"),oe=ie("copy-to"),ve=ue;ve.multipartUpload=b.default.mark(function ge(_e,he,pe){var ke,Te,Ee,Oe,je,Pe,Qe,Xe,ot;return b.default.wrap(function(He){for(;;)switch(He.prev=He.next){case 0:if(this.resetCancelFlag(),pe=pe||{},!pe.checkpoint||!pe.checkpoint.uploadId){He.next=6;break}return He.next=5,this._resumeMultipart(pe.checkpoint,pe);case 5:return He.abrupt("return",He.sent);case 6:return ke=102400,pe.mime||(z.file(he)?pe.mime=ae.getType(re.extname(he.name)):z.blob(he)?pe.mime=he.type:pe.mime=ae.getType(re.extname(he))),pe.headers=pe.headers||{},this._convertMetaToHeaders(pe.meta,pe.headers),He.next=12,this._getFileSize(he);case 12:if(!((Te=He.sent)<ke)){He.next=25;break}return Ee=this._createStream(he,0,Te),pe.contentLength=Te,He.next=18,this.putStream(_e,Ee,pe);case 18:if(Oe=He.sent,!pe||!pe.progress){He.next=22;break}return He.next=22,pe.progress(1);case 22:return je={res:Oe.res,bucket:this.options.bucket,name:_e,etag:Oe.res.headers.etag},(pe.headers&&pe.headers["x-oss-callback"]||pe.callback)&&(je.data=Oe.data),He.abrupt("return",je);case 25:if(!(pe.partSize&&pe.partSize<ke)){He.next=27;break}throw new Error("partSize must not be smaller than "+ke);case 27:return He.next=29,this.initMultipartUpload(_e,pe);case 29:if(Pe=He.sent,Qe=Pe.uploadId,Xe=this._getPartSize(Te,pe.partSize),ot={file:he,name:_e,fileSize:Te,partSize:Xe,uploadId:Qe,doneParts:[]},!pe||!pe.progress){He.next=36;break}return He.next=36,pe.progress(0,ot,Pe.res);case 36:return He.next=38,this._resumeMultipart(ot,pe);case 38:return He.abrupt("return",He.sent);case 39:case"end":return He.stop()}},ge,this)}),ve._resumeMultipart=b.default.mark(function ge(_e,he){var pe,ke,Te,Ee,Oe,je,Pe,Qe,Xe,ot,He,rt,Ye,ut,Ge,ze,Ve,$e,nt,et,pt;return b.default.wrap(function(ct){for(;;)switch(ct.prev=ct.next){case 0:if(!this.isCancel()){ct.next=2;break}throw this._makeCancelEvent();case 2:if(pe=_e.file,ke=_e.fileSize,Te=_e.partSize,Ee=_e.uploadId,Oe=_e.doneParts,je=_e.name,Pe=[],Oe.length>0&&oe(Oe).to(Pe),Qe=this._divideParts(ke,Te),Xe=Qe.length,ot=!1,He=b.default.mark(function Ot(dt,Rt){var xt,gt,_t;return b.default.wrap(function(We){for(;;)switch(We.prev=We.next){case 0:if(dt.isCancel()){We.next=21;break}return We.prev=1,xt=Qe[Rt-1],gt={stream:dt._createStream(pe,xt.start,xt.end),size:xt.end-xt.start},We.next=6,dt._uploadPart(je,Ee,Rt,gt);case 6:if(_t=We.sent,dt.isCancel()||ot){We.next=13;break}if(_e.doneParts.push({number:Rt,etag:_t.res.headers.etag}),Pe.push({number:Rt,etag:_t.res.headers.etag}),!he||!he.progress){We.next=13;break}return We.next=13,he.progress(Oe.length/Xe,_e,_t.res);case 13:We.next=21;break;case 15:if(We.prev=15,We.t0=We.catch(1),dt.isCancel()){We.next=21;break}throw dt.cancel(),We.t0.partNum=Rt,We.t0;case 21:case"end":return We.stop()}},Ot,this,[[1,15]])}),rt=(0,ne.default)(new Array(Xe),function(Ot,dt){return dt+1}),Ye=Pe.map(function(Ot){return Ot.number}),ut=rt.filter(function(Ot){return Ye.indexOf(Ot)<0}),Ge=5,ze=he.parallel||Ge,!this.checkBrowserAndVersion("Internet Explorer","10")&&ze!==1){ct.next=26;break}Ve=0;case 16:if(!(Ve<ut.length)){ct.next=24;break}if(!this.isCancel()){ct.next=19;break}throw this._makeCancelEvent();case 19:return ct.next=21,He(this,ut[Ve]);case 21:Ve++,ct.next=16;break;case 24:ct.next=40;break;case 26:for($e=[],nt=0;nt<ut.length;nt++)$e.push(He(this,ut[nt]));return ct.next=30,this._thunkPool($e,ze);case 30:if(et=ct.sent,ot=!0,!(et&&et.length>0)){ct.next=37;break}throw this.resetCancelFlag(),pt=et[0],pt.message="Failed to upload some parts with error: "+pt.toString()+" part_num: "+pt.partNum,pt;case 37:if(!this.isCancel()){ct.next=40;break}throw $e=null,this._makeCancelEvent();case 40:return ct.next=42,this.completeMultipartUpload(je,Ee,Pe,he);case 42:return ct.abrupt("return",ct.sent);case 43:case"end":return ct.stop()}},ge,this)}),z.file=function(ge){return typeof File!="undefined"&&ge instanceof File},z.blob=function(ge){return typeof Blob!="undefined"&&ge instanceof Blob},ve._getFileSize=b.default.mark(function ge(_e){var he;return b.default.wrap(function(pe){for(;;)switch(pe.prev=pe.next){case 0:if(!z.buffer(_e)){pe.next=4;break}return pe.abrupt("return",_e.length);case 4:if(!z.blob(_e)&&!z.file(_e)){pe.next=6;break}return pe.abrupt("return",_e.size);case 6:if(!z.string(_e)){pe.next=11;break}return pe.next=9,this._statFile(_e);case 9:return he=pe.sent,pe.abrupt("return",he.size);case 11:throw new Error("_getFileSize requires Buffer/File/String.");case 12:case"end":return pe.stop()}},ge,this)});var ye=ie("stream"),me=ye.Readable;x.inherits(le,me),le.prototype.readFileAndPush=function(ge){if(this.fileBuffer)for(var _e=!0;_e&&this.fileBuffer&&this.start<this.fileBuffer.length;){var he=this.start,pe=he+ge;pe=pe>this.fileBuffer.length?this.fileBuffer.length:pe,this.start=pe,_e=this.push(this.fileBuffer.slice(he,pe))}},le.prototype._read=function(ge){if(this.file&&this.start>=this.file.size||this.fileBuffer&&this.start>=this.fileBuffer.length||this.finish||this.start===0&&!this.file)return this.finish||(this.fileBuffer=null,this.finish=!0),void this.push(null);ge=ge||16384;var _e=this;this.reader.onload=function(he){_e.fileBuffer=new se(new Uint8Array(he.target.result)),_e.file=null,_e.readFileAndPush(ge)},this.start===0?this.reader.readAsArrayBuffer(this.file):this.readFileAndPush(ge)},ve._createStream=function(ge,_e,he){if(z.blob(ge)||z.file(ge))return new le(ge.slice(_e,he));throw new Error("_createStream requires File/String.")},ve._getPartSize=function(ge,_e){return _e?Math.max(Math.ceil(ge/1e4),_e):1048576},ve._divideParts=function(ge,_e){for(var he=Math.ceil(ge/_e),pe=[],ke=0;ke<he;ke++){var Te=_e*ke,Ee=Math.min(Te+_e,ge);pe.push({start:Te,end:Ee})}return pe},ve._makeCancelEvent=function(){return{status:0,name:"cancel"}}}).call(this,ie("buffer").Buffer)},{"babel-runtime/core-js/array/from":16,"babel-runtime/regenerator":33,buffer:38,"copy-to":43,"is-type-of":165,mime:242,path:170,stream:195,util:207}],4:[function(ie,Ce,ue){"use strict";function se(_e){return _e&&_e.__esModule?_e:{default:_e}}var te=ie("babel-runtime/core-js/object/keys"),le=se(te),ee=ie("babel-runtime/regenerator"),ne=se(ee),E=ie("debug")("ali-oss:object"),b=ie("utility"),z=ie("fs"),x=ie("is-type-of"),re=ie("url"),ae=ie("copy-to"),oe=ie("path"),ve=ie("mime"),ye=ie("../common/callback"),me=ie("../common/signUtils"),ge=ue;ge.append=ne.default.mark(function _e(he,pe,ke){var Te;return ne.default.wrap(function(Ee){for(;;)switch(Ee.prev=Ee.next){case 0:return ke=ke||{},ke.position===void 0&&(ke.position="0"),ke.subres={append:"",position:ke.position},ke.method="POST",Ee.next=6,this.put(he,pe,ke);case 6:return Te=Ee.sent,Te.nextAppendPosition=Te.res.headers["x-oss-next-append-position"],Ee.abrupt("return",Te);case 9:case"end":return Ee.stop()}},_e,this)}),ge.put=ne.default.mark(function _e(he,pe,ke){var Te,Ee,Oe,je,Pe,Qe;return ne.default.wrap(function(Xe){for(;;)switch(Xe.prev=Xe.next){case 0:if(Te=void 0,ke=ke||{},!x.buffer(pe)){Xe.next=6;break}Te=pe,Xe.next=18;break;case 6:if(!x.blob(pe)&&!x.file(pe)){Xe.next=17;break}return ke.mime||(x.file(pe)?ke.mime=ve.getType(oe.extname(pe.name)):ke.mime=pe.type),Ee=this._createStream(pe,0,pe.size),Xe.next=11,this._getFileSize(pe);case 11:return ke.contentLength=Xe.sent,Xe.next=14,this.putStream(he,Ee,ke);case 14:return Xe.abrupt("return",Xe.sent);case 17:throw new TypeError("Must provide Buffer/Blob for put.");case 18:return ke.headers=ke.headers||{},this._convertMetaToHeaders(ke.meta,ke.headers),Oe=ke.method||"PUT",je=this._objectRequestParams(Oe,he,ke),ye.encodeCallback(je,ke),je.mime=ke.mime,je.content=Te,je.successStatuses=[200],Xe.next=28,this.request(je);case 28:return Pe=Xe.sent,Qe={name:he,url:this._objectUrl(he),res:Pe.res},je.headers&&je.headers["x-oss-callback"]&&(Qe.data=JSON.parse(Pe.data.toString())),Xe.abrupt("return",Qe);case 32:case"end":return Xe.stop()}},_e,this)}),ge.putStream=ne.default.mark(function _e(he,pe,ke){var Te,Ee,Oe,je;return ne.default.wrap(function(Pe){for(;;)switch(Pe.prev=Pe.next){case 0:return ke=ke||{},ke.headers=ke.headers||{},ke.contentLength?ke.headers["Content-Length"]=ke.contentLength:ke.headers["Transfer-Encoding"]="chunked",this._convertMetaToHeaders(ke.meta,ke.headers),Te=ke.method||"PUT",Ee=this._objectRequestParams(Te,he,ke),ye.encodeCallback(Ee,ke),Ee.mime=ke.mime,Ee.stream=pe,Ee.successStatuses=[200],Pe.next=12,this.request(Ee);case 12:return Oe=Pe.sent,je={name:he,url:this._objectUrl(he),res:Oe.res},Ee.headers&&Ee.headers["x-oss-callback"]&&(je.data=JSON.parse(Oe.data.toString())),Pe.abrupt("return",je);case 16:case"end":return Pe.stop()}},_e,this)}),ge.head=ne.default.mark(function _e(he,pe){var ke,Te,Ee;return ne.default.wrap(function(Oe){for(;;)switch(Oe.prev=Oe.next){case 0:return ke=this._objectRequestParams("HEAD",he,pe),ke.successStatuses=[200,304],Oe.next=4,this.request(ke);case 4:return Te=Oe.sent,Ee={meta:null,res:Te.res,status:Te.status},Te.status===200&&(0,le.default)(Te.headers).forEach(function(je){je.indexOf("x-oss-meta-")===0&&(Ee.meta||(Ee.meta={}),Ee.meta[je.substring(11)]=Te.headers[je])}),Oe.abrupt("return",Ee);case 8:case"end":return Oe.stop()}},_e,this)}),ge.get=ne.default.mark(function _e(he,pe,ke){var Te,Ee,Oe,je;return ne.default.wrap(function(Pe){for(;;)switch(Pe.prev=Pe.next){case 0:return Te=null,Ee=!1,x.writableStream(pe)?Te=pe:x.string(pe)?(Te=z.createWriteStream(pe),Ee=!0):ke=pe,ke=ke||{},ke.process&&(ke.subres=ke.subres||{},ke.subres["x-oss-process"]=ke.process),Oe=void 0,Pe.prev=6,je=this._objectRequestParams("GET",he,ke),je.writeStream=Te,je.successStatuses=[200,206,304],Pe.next=12,this.request(je);case 12:Oe=Pe.sent,Ee&&Te.destroy(),Pe.next=24;break;case 16:if(Pe.prev=16,Pe.t0=Pe.catch(6),!Ee){Pe.next=23;break}return Te.destroy(),E("get error: %s, delete the exists file %s",Pe.t0,pe),Pe.next=23,this._deleteFileSafe(pe);case 23:throw Pe.t0;case 24:return Pe.abrupt("return",{res:Oe.res,content:Oe.data});case 25:case"end":return Pe.stop()}},_e,this,[[6,16]])}),ge.getStream=ne.default.mark(function _e(he,pe){var ke,Te;return ne.default.wrap(function(Ee){for(;;)switch(Ee.prev=Ee.next){case 0:return pe=pe||{},ke=this._objectRequestParams("GET",he,pe),ke.customResponse=!0,ke.successStatuses=[200,206,304],Ee.next=6,this.request(ke);case 6:return Te=Ee.sent,Ee.abrupt("return",{stream:Te.res,res:{status:Te.status,headers:Te.headers}});case 8:case"end":return Ee.stop()}},_e,this)}),ge.delete=ne.default.mark(function _e(he,pe){var ke,Te;return ne.default.wrap(function(Ee){for(;;)switch(Ee.prev=Ee.next){case 0:return ke=this._objectRequestParams("DELETE",he,pe),ke.successStatuses=[204],Ee.next=4,this.request(ke);case 4:return Te=Ee.sent,Ee.abrupt("return",{res:Te.res});case 6:case"end":return Ee.stop()}},_e,this)}),ge.deleteMulti=ne.default.mark(function _e(he,pe){var ke,Te,Ee,Oe,je,Pe;return ne.default.wrap(function(Qe){for(;;)switch(Qe.prev=Qe.next){case 0:for(pe=pe||{},ke=`<?xml version="1.0" encoding="UTF-8"?>
|
|
|
<Delete>
|
|
|
`,pe.quiet?ke+=` <Quiet>true</Quiet>
|
|
|
`:ke+=` <Quiet>false</Quiet>
|
|
|
`,Te=0;Te<he.length;Te++)ke+=" <Object><Key>"+b.escape(this._objectName(he[Te]))+`</Key></Object>
|
|
|
`;return ke+="</Delete>",E("delete multi objects: %s",ke),pe.subres="delete",Ee=this._objectRequestParams("POST","",pe),Ee.mime="xml",Ee.content=ke,Ee.xmlResponse=!0,Ee.successStatuses=[200],Qe.next=14,this.request(Ee);case 14:return Oe=Qe.sent,je=Oe.data,Pe=je&&je.Deleted||null,Pe&&(Array.isArray(Pe)||(Pe=[Pe]),Pe=Pe.map(function(Xe){return Xe.Key})),Qe.abrupt("return",{res:Oe.res,deleted:Pe});case 19:case"end":return Qe.stop()}},_e,this)}),ge.copy=ne.default.mark(function _e(he,pe,ke){var Te,Ee,Oe;return ne.default.wrap(function(je){for(;;)switch(je.prev=je.next){case 0:return ke=ke||{},ke.headers=ke.headers||{},(0,le.default)(ke.headers).forEach(function(Pe){ke.headers["x-oss-copy-source-"+Pe.toLowerCase()]=ke.headers[Pe]}),ke.meta&&(ke.headers["x-oss-metadata-directive"]="REPLACE"),this._convertMetaToHeaders(ke.meta,ke.headers),pe=pe[0]!=="/"?"/"+this.options.bucket+"/"+encodeURIComponent(pe):"/"+encodeURIComponent(pe.slice(1)),ke.headers["x-oss-copy-source"]=pe,Te=this._objectRequestParams("PUT",he,ke),Te.xmlResponse=!0,Te.successStatuses=[200,304],je.next=12,this.request(Te);case 12:return Ee=je.sent,Oe=Ee.data,Oe&&(Oe={etag:Oe.ETag,lastModified:Oe.LastModified}),je.abrupt("return",{data:Oe,res:Ee.res});case 16:case"end":return je.stop()}},_e,this)}),ge.putMeta=ne.default.mark(function _e(he,pe,ke){return ne.default.wrap(function(Te){for(;;)switch(Te.prev=Te.next){case 0:return Te.next=2,this.copy(he,he,{meta:pe||{},timeout:ke&&ke.timeout,ctx:ke&&ke.ctx});case 2:return Te.abrupt("return",Te.sent);case 3:case"end":return Te.stop()}},_e,this)}),ge.list=ne.default.mark(function _e(he,pe){var ke,Te,Ee,Oe,je;return ne.default.wrap(function(Pe){for(;;)switch(Pe.prev=Pe.next){case 0:return ke=this._objectRequestParams("GET","",pe),ke.query=he,ke.xmlResponse=!0,ke.successStatuses=[200],Pe.next=6,this.request(ke);case 6:return Te=Pe.sent,Ee=Te.data.Contents,Oe=this,Ee&&(Array.isArray(Ee)||(Ee=[Ee]),Ee=Ee.map(function(Qe){return{name:Qe.Key,url:Oe._objectUrl(Qe.Key),lastModified:Qe.LastModified,etag:Qe.ETag,type:Qe.Type,size:Number(Qe.Size),storageClass:Qe.StorageClass,owner:{id:Qe.Owner.ID,displayName:Qe.Owner.DisplayName}}})),je=Te.data.CommonPrefixes||null,je&&(Array.isArray(je)||(je=[je]),je=je.map(function(Qe){return Qe.Prefix})),Pe.abrupt("return",{res:Te.res,objects:Ee,prefixes:je,nextMarker:Te.data.NextMarker||null,isTruncated:Te.data.IsTruncated==="true"});case 13:case"end":return Pe.stop()}},_e,this)}),ge.putACL=ne.default.mark(function _e(he,pe,ke){var Te,Ee;return ne.default.wrap(function(Oe){for(;;)switch(Oe.prev=Oe.next){case 0:return ke=ke||{},ke.subres="acl",ke.headers=ke.headers||{},ke.headers["x-oss-object-acl"]=pe,he=this._objectName(he),Te=this._objectRequestParams("PUT",he,ke),Te.successStatuses=[200],Oe.next=9,this.request(Te);case 9:return Ee=Oe.sent,Oe.abrupt("return",{res:Ee.res});case 11:case"end":return Oe.stop()}},_e,this)}),ge.getACL=ne.default.mark(function _e(he,pe){var ke,Te;return ne.default.wrap(function(Ee){for(;;)switch(Ee.prev=Ee.next){case 0:return pe=pe||{},pe.subres="acl",he=this._objectName(he),ke=this._objectRequestParams("GET",he,pe),ke.successStatuses=[200],ke.xmlResponse=!0,Ee.next=8,this.request(ke);case 8:return Te=Ee.sent,Ee.abrupt("return",{acl:Te.data.AccessControlList.Grant,owner:{id:Te.data.Owner.ID,displayName:Te.data.Owner.DisplayName},res:Te.res});case 10:case"end":return Ee.stop()}},_e,this)}),ge.restore=ne.default.mark(function _e(he,pe){var ke,Te;return ne.default.wrap(function(Ee){for(;;)switch(Ee.prev=Ee.next){case 0:return pe=pe||{},pe.subres="restore",ke=this._objectRequestParams("POST",he,pe),ke.successStatuses=[202],Ee.next=6,this.request(ke);case 6:return Te=Ee.sent,Ee.abrupt("return",{res:Te.res});case 8:case"end":return Ee.stop()}},_e,this)}),ge.signatureUrl=function(_e,he){he=he||{},_e=this._objectName(_e),he.method=he.method||"GET";var pe=b.timestamp()+(he.expires||1800),ke={bucket:this.options.bucket,object:_e},Te=this._getResource(ke);this.options.stsToken&&(he["security-token"]=this.options.stsToken);var Ee=me._signatureForURL(this.options.accessKeySecret,he,Te,pe),Oe=re.parse(this._getReqUrl(ke));return Oe.query={OSSAccessKeyId:this.options.accessKeyId,Expires:pe,Signature:Ee.Signature},ae(Ee.subResource).to(Oe.query),Oe.format()},ge.getObjectUrl=function(_e,he){return he?he[he.length-1]!=="/"&&(he+="/"):he=this.options.endpoint.format(),he+this._escape(this._objectName(_e))},ge._objectUrl=function(_e){return this._getReqUrl({bucket:this.options.bucket,object:_e})},ge.generateObjectUrl=function(_e,he){if(he)he[he.length-1]!=="/"&&(he+="/");else{he=this.options.endpoint.format();var pe=re.parse(he),ke=this.options.bucket;pe.hostname=ke+"."+pe.hostname,pe.host=ke+"."+pe.host,he=pe.format()}return he+this._escape(this._objectName(_e))},ge._objectRequestParams=function(_e,he,pe){if(!this.options.bucket)throw new Error("Please create a bucket first");pe=pe||{},he=this._objectName(he);var ke={object:he,bucket:this.options.bucket,method:_e,subres:pe&&pe.subres,timeout:pe&&pe.timeout,ctx:pe&&pe.ctx};return pe.headers&&(ke.headers={},ae(pe.headers).to(ke.headers)),ke},ge._objectName=function(_e){return _e.replace(/^\/+/,"")},ge._statFile=function(_e){return function(he){z.stat(_e,he)}},ge._convertMetaToHeaders=function(_e,he){_e&&(0,le.default)(_e).forEach(function(pe){he["x-oss-meta-"+pe]=_e[pe]})},ge._deleteFileSafe=function(_e){return function(he){z.exists(_e,function(pe){pe?z.unlink(_e,function(ke){ke&&E("unlink %j error: %s",_e,ke),he()}):he()})}}},{"../common/callback":7,"../common/signUtils":9,"babel-runtime/core-js/object/keys":23,"babel-runtime/regenerator":33,"copy-to":43,debug:155,fs:36,"is-type-of":165,mime:242,path:170,url:203,utility:243}],5:[function(ie,Ce,ue){"use strict";ue.version="5.3.1"},{}],6:[function(ie,Ce,ue){"use strict";function se(oe){return oe&&oe.__esModule?oe:{default:oe}}function te(oe){return oe&&typeof oe.next=="function"&&typeof oe.throw=="function"}function le(oe){if(!oe)return!1;var ve=oe.constructor;return!!ve&&(ve.name==="GeneratorFunction"||ve.displayName==="GeneratorFunction"||te(ve.prototype)||te(oe.prototype))}function ee(oe,ve){var ye=new oe(ve),me=(0,x.default)(ye),ge=(0,x.default)((0,b.default)(ye));me.concat(ge).forEach(function(_e){le(ye[_e])?this[_e]=re.wrap(ye[_e]).bind(ye):this[_e]=ye[_e]},this)}function ne(oe){if(!(this instanceof ne))return new ne(oe);ee.call(this,ae,oe)}var E=ie("babel-runtime/core-js/object/get-prototype-of"),b=se(E),z=ie("babel-runtime/core-js/object/keys"),x=se(z),re=ie("co"),ae=ie("./client");Ce.exports=ne,ne.STS=function oe(ve){if(!(this instanceof oe))return new oe(ve);ee.call(this,ae.STS,ve)}},{"./client":2,"babel-runtime/core-js/object/get-prototype-of":22,"babel-runtime/core-js/object/keys":23,co:41}],7:[function(ie,Ce,ue){(function(se){"use strict";function te(b){return b&&b.__esModule?b:{default:b}}var le=ie("babel-runtime/core-js/object/keys"),ee=te(le),ne=ie("babel-runtime/core-js/json/stringify"),E=te(ne);ue.encodeCallback=function(b,z){if(b.headers=b.headers||{},!Object.prototype.hasOwnProperty.call(b.headers,"x-oss-callback")&&z.callback){var x={callbackUrl:encodeURI(z.callback.url),callbackBody:z.callback.body};z.callback.host&&(x.callbackHost=z.callback.host),z.callback.contentType&&(x.callbackBodyType=z.callback.contentType);var re=new se((0,E.default)(x)).toString("base64");if(b.headers["x-oss-callback"]=re,z.callback.customValue){var ae={};(0,ee.default)(z.callback.customValue).forEach(function(oe){ae["x:"+oe]=z.callback.customValue[oe]}),b.headers["x-oss-callback-var"]=new se((0,E.default)(ae)).toString("base64")}}}}).call(this,ie("buffer").Buffer)},{"babel-runtime/core-js/json/stringify":17,"babel-runtime/core-js/object/keys":23,buffer:38}],8:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/regenerator"),te=function(E){return E&&E.__esModule?E:{default:E}}(se),le=ie("copy-to"),ee=ie("./callback"),ne=ue;ne.listUploads=te.default.mark(function E(b,z){var x,re,ae,oe;return te.default.wrap(function(ve){for(;;)switch(ve.prev=ve.next){case 0:return z=z||{},x={},le(z).to(x),x.subres="uploads",re=this._objectRequestParams("GET","",x),re.query=b,re.xmlResponse=!0,re.successStatuses=[200],ve.next=10,this.request(re);case 10:return ae=ve.sent,oe=ae.data.Upload||[],Array.isArray(oe)||(oe=[oe]),oe=oe.map(function(ye){return{name:ye.Key,uploadId:ye.UploadId,initiated:ye.Initiated}}),ve.abrupt("return",{res:ae.res,uploads:oe,bucket:ae.data.Bucket,nextKeyMarker:ae.data.NextKeyMarker,nextUploadIdMarker:ae.data.NextUploadIdMarker,isTruncated:ae.data.IsTruncated==="true"});case 15:case"end":return ve.stop()}},E,this)}),ne.listParts=te.default.mark(function E(b,z,x,re){var ae,oe,ve;return te.default.wrap(function(ye){for(;;)switch(ye.prev=ye.next){case 0:return re=re||{},ae={},le(re).to(ae),ae.subres={uploadId:z},oe=this._objectRequestParams("GET",b,ae),oe.query=x,oe.xmlResponse=!0,oe.successStatuses=[200],ye.next=10,this.request(oe);case 10:return ve=ye.sent,ye.abrupt("return",{res:ve.res,uploadId:ve.data.UploadId,bucket:ve.data.Bucket,name:ve.data.Key,partNumberMarker:ve.data.PartNumberMarker,nextPartNumberMarker:ve.data.NextPartNumberMarker,maxParts:ve.data.MaxParts,isTruncated:ve.data.IsTruncated,parts:ve.data.Part||[]});case 12:case"end":return ye.stop()}},E,this)}),ne.abortMultipartUpload=te.default.mark(function E(b,z,x){var re,ae,oe;return te.default.wrap(function(ve){for(;;)switch(ve.prev=ve.next){case 0:return this.cancel(),x=x||{},re={},le(x).to(re),re.subres={uploadId:z},ae=this._objectRequestParams("DELETE",b,re),ae.successStatuses=[204],ve.next=9,this.request(ae);case 9:return oe=ve.sent,ve.abrupt("return",{res:oe.res});case 11:case"end":return ve.stop()}},E,this)}),ne.initMultipartUpload=te.default.mark(function E(b,z){var x,re,ae;return te.default.wrap(function(oe){for(;;)switch(oe.prev=oe.next){case 0:return z=z||{},x={},le(z).to(x),x.headers=x.headers||{},this._convertMetaToHeaders(z.meta,x.headers),x.subres="uploads",re=this._objectRequestParams("POST",b,x),re.mime=z.mime,re.xmlResponse=!0,re.successStatuses=[200],oe.next=12,this.request(re);case 12:return ae=oe.sent,oe.abrupt("return",{res:ae.res,bucket:ae.data.Bucket,name:ae.data.Key,uploadId:ae.data.UploadId});case 14:case"end":return oe.stop()}},E,this)}),ne.uploadPart=te.default.mark(function E(b,z,x,re,ae,oe,ve){var ye;return te.default.wrap(function(me){for(;;)switch(me.prev=me.next){case 0:return ye={stream:this._createStream(re,ae,oe),size:oe-ae},me.next=3,this._uploadPart(b,z,x,ye,ve);case 3:return me.abrupt("return",me.sent);case 4:case"end":return me.stop()}},E,this)}),ne.completeMultipartUpload=te.default.mark(function E(b,z,x,re){var ae,oe,ve,ye,me,ge,_e,he;return te.default.wrap(function(pe){for(;;)switch(pe.prev=pe.next){case 0:for(ae=x.concat().sort(function(ke,Te){return ke.number-Te.number}).filter(function(ke,Te,Ee){return!Te||ke.number!==Ee[Te-1].number}),oe=`<?xml version="1.0" encoding="UTF-8"?>
|
|
|
<CompleteMultipartUpload>
|
|
|
`,ve=0;ve<ae.length;ve++)ye=ae[ve],oe+=`<Part>
|
|
|
`,oe+="<PartNumber>"+ye.number+`</PartNumber>
|
|
|
`,oe+="<ETag>"+ye.etag+`</ETag>
|
|
|
`,oe+=`</Part>
|
|
|
`;return oe+="</CompleteMultipartUpload>",re=re||{},me={},le(re).to(me),me.subres={uploadId:z},ge=this._objectRequestParams("POST",b,me),ee.encodeCallback(ge,me),ge.mime="xml",ge.content=oe,ge.headers&&ge.headers["x-oss-callback"]||(ge.xmlResponse=!0),ge.successStatuses=[200],pe.next=16,this.request(ge);case 16:return _e=pe.sent,he={res:_e.res,bucket:ge.bucket,name:b,etag:_e.res.headers.etag},ge.headers&&ge.headers["x-oss-callback"]&&(he.data=JSON.parse(_e.data.toString())),pe.abrupt("return",he);case 20:case"end":return pe.stop()}},E,this)}),ne._uploadPart=te.default.mark(function E(b,z,x,re,ae){var oe,ve,ye;return te.default.wrap(function(me){for(;;)switch(me.prev=me.next){case 0:return ae=ae||{},oe={},le(ae).to(oe),oe.headers={"Content-Length":re.size},oe.subres={partNumber:x,uploadId:z},ve=this._objectRequestParams("PUT",b,oe),ve.mime=oe.mime,ve.stream=re.stream,ve.successStatuses=[200],me.next=11,this.request(ve);case 11:return ye=me.sent,re.stream=null,ve.stream=null,me.abrupt("return",{name:b,etag:ye.res.headers.etag,res:ye.res});case 15:case"end":return me.stop()}},E,this)})},{"./callback":7,"babel-runtime/regenerator":33,"copy-to":43}],9:[function(ie,Ce,ue){(function(se){"use strict";function te(x){return x&&x.__esModule?x:{default:x}}var le=ie("babel-runtime/core-js/json/stringify"),ee=te(le),ne=ie("babel-runtime/core-js/object/keys"),E=te(ne),b=ie("./../../shims/crypto/crypto.js"),z=ie("is-type-of");ue.buildCanonicalizedResource=function(x,re){var ae=""+x,oe="?";if(z.string(re)&&re.trim()!=="")ae+=oe+re;else if(z.array(re))re.sort(),ae+=oe+re.join("&");else if(re){var ve=function(me,ge){return me[0]>ge[0]?1:me[0]<ge[0]?-1:0},ye=function(me){ae+=oe+me,re[me]&&(ae+="="+re[me]),oe="&"};(0,E.default)(re).sort(ve).forEach(ye)}return ae},ue.buildCanonicalString=function(x,re,ae,oe){ae=ae||{};var ve=ae.headers||{},ye=[],me={},ge=[x.toUpperCase(),ve["Content-Md5"]||"",ve["Content-Type"]||ve["Content-Type".toLowerCase()],oe||ve["x-oss-date"]];return(0,E.default)(ve).forEach(function(_e){var he=_e.toLowerCase();he.indexOf("x-oss-")===0&&(me[he]=String(ve[_e]).trim())}),(0,E.default)(me).sort().forEach(function(_e){ye.push(_e+":"+me[_e])}),ge=ge.concat(ye),ge.push(this.buildCanonicalizedResource(re,ae.parameters)),ge.join(`
|
|
|
`)},ue.computeSignature=function(x,re){return b.createHmac("sha1",x).update(new se(re,"utf8")).digest("base64")},ue.authorization=function(x,re,ae){return"OSS "+x+":"+this.computeSignature(re,ae)},ue._signatureForURL=function(x,re,ae,oe){var ve={},ye={};if(re.process&&(ye["x-oss-process"]=re.process),re.response&&(0,E.default)(re.response).forEach(function(he){var pe="response-"+he.toLowerCase();ye[pe]=re.response[he]}),(0,E.default)(re).forEach(function(he){var pe=he.toLowerCase(),ke=re[he];pe.indexOf("x-oss-")===0?ve[pe]=ke:pe.indexOf("content-md5")===0||pe.indexOf("content-type")===0?ve[he]=ke:pe!=="expires"&&pe!=="response"&&pe!=="process"&&pe!=="method"&&(ye[pe]=ke)}),Object.prototype.hasOwnProperty.call(re,"security-token")&&(ye["security-token"]=re["security-token"]),Object.prototype.hasOwnProperty.call(re,"callback")){var me={callbackUrl:encodeURI(re.callback.url),callbackBody:re.callback.body};if(re.callback.host&&(me.callbackHost=re.callback.host),re.callback.contentType&&(me.callbackBodyType=re.callback.contentType),ye.callback=new se((0,ee.default)(me)).toString("base64"),re.callback.customValue){var ge={};(0,E.default)(re.callback.customValue).forEach(function(he){ge["x:"+he]=re.callback.customValue[he]}),ye["callback-var"]=new se((0,ee.default)(ge)).toString("base64")}}var _e=this.buildCanonicalString(re.method,ae,{headers:ve,parameters:ye},oe.toString());return{Signature:this.computeSignature(x,_e),subResource:ye}}}).call(this,ie("buffer").Buffer)},{"./../../shims/crypto/crypto.js":237,"babel-runtime/core-js/json/stringify":17,"babel-runtime/core-js/object/keys":23,buffer:38,"is-type-of":165}],10:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/regenerator"),te=function(b){return b&&b.__esModule?b:{default:b}}(se),le=ie("co"),ee=ie("co-priority-queue"),ne=ie("any-promise"),E=ue;E._thunkPool=function(b,z){function x(ye,me){++oe===ye.length&&me(ve)}function re(ye,me){function ge(){var Ee;return te.default.wrap(function(Oe){for(;;)switch(Oe.prev=Oe.next){case 0:Ee=void 0;case 1:if(ae.isCancel()){Oe.next=9;break}return Oe.next=4,pe.next();case 4:return Ee=Oe.sent,Oe.next=7,Ee();case 7:Oe.next=1;break;case 9:ke+=1,ke===ye&&(pe.fns=[],pe.buffer=[],me(ve));case 11:case"end":return Oe.stop()}},he,this)}function _e(Ee){console.error(Ee.stack)}for(var he=te.default.mark(ge),pe=new ee,ke=0,Te=0;Te<ye;Te++)le(ge).catch(_e);return function(Ee,Oe){return function(je){pe.push(te.default.mark(function Pe(){return te.default.wrap(function(Qe){for(;;)switch(Qe.prev=Qe.next){case 0:return Qe.prev=0,Qe.t0=je,Qe.next=4,Ee;case 4:Qe.t1=Qe.sent,(0,Qe.t0)(null,Qe.t1),Qe.next=11;break;case 8:Qe.prev=8,Qe.t2=Qe.catch(0),je(Qe.t2);case 11:case"end":return Qe.stop()}},Pe,this,[[0,8]])}),Oe)}}}var ae=this,oe=0,ve=[];return new ne(function(ye){function me(ke){return te.default.wrap(function(Te){for(;;)switch(Te.prev=Te.next){case 0:return Te.next=2,he(b[ke]);case 2:x(b,ye);case 3:case"end":return Te.stop()}},_e,this)}function ge(ke){ve.push(ke),x(b,ye)}for(var _e=te.default.mark(me),he=new re(z,ye),pe=0;pe<b.length;pe++)le(me(pe)).catch(ge)})},E.cancel=function(){this.options.cancelFlag=!0},E.isCancel=function(){return this.options.cancelFlag},E.resetCancelFlag=function(){this.options.cancelFlag=!1}},{"any-promise":13,"babel-runtime/regenerator":33,co:41,"co-priority-queue":40}],11:[function(ie,Ce,ue){"use strict";ue._isIP=function(se){var te=/^(25[0-5]|2[0-4]\d|[0-1]?\d?\d)(\.(25[0-5]|2[0-4]\d|[0-1]?\d?\d)){3}$/,le=/^\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 te.test(se)||le.test(se)}},{}],12:[function(ie,Ce,ue){function se(){}Ce.exports=se,Ce.exports.HttpsAgent=se},{}],13:[function(ie,Ce,ue){Ce.exports=ie("./register")().Promise},{"./register":15}],14:[function(ie,Ce,ue){"use strict";var se=null;Ce.exports=function(te,le){return function(ee,ne){ee=ee||null,ne=ne||{};var E=ne.global!==!1;if(se===null&&E&&(se=te["@@any-promise/REGISTRATION"]||null),se!==null&&ee!==null&&se.implementation!==ee)throw new Error('any-promise already defined as "'+se.implementation+'". You can only register an implementation before the first call to require("any-promise") and an implementation cannot be changed');return se===null&&(se=ee!==null&&ne.Promise!==void 0?{Promise:ne.Promise,implementation:ee}:le(ee),E&&(te["@@any-promise/REGISTRATION"]=se)),se}}},{}],15:[function(ie,Ce,ue){"use strict";function se(){if(window.Promise===void 0)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"}}Ce.exports=ie("./loader")(window,se)},{"./loader":14}],16:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/array/from"),__esModule:!0}},{"core-js/library/fn/array/from":44}],17:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/json/stringify"),__esModule:!0}},{"core-js/library/fn/json/stringify":45}],18:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/object/assign"),__esModule:!0}},{"core-js/library/fn/object/assign":46}],19:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/object/create"),__esModule:!0}},{"core-js/library/fn/object/create":47}],20:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/object/define-property"),__esModule:!0}},{"core-js/library/fn/object/define-property":48}],21:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/object/get-own-property-names"),__esModule:!0}},{"core-js/library/fn/object/get-own-property-names":49}],22:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/object/get-prototype-of"),__esModule:!0}},{"core-js/library/fn/object/get-prototype-of":50}],23:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/object/keys"),__esModule:!0}},{"core-js/library/fn/object/keys":51}],24:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/promise"),__esModule:!0}},{"core-js/library/fn/promise":52}],25:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/set-immediate"),__esModule:!0}},{"core-js/library/fn/set-immediate":53}],26:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/string/from-code-point"),__esModule:!0}},{"core-js/library/fn/string/from-code-point":54}],27:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/symbol"),__esModule:!0}},{"core-js/library/fn/symbol":56}],28:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/symbol/has-instance"),__esModule:!0}},{"core-js/library/fn/symbol/has-instance":55}],29:[function(ie,Ce,ue){Ce.exports={default:ie("core-js/library/fn/symbol/iterator"),__esModule:!0}},{"core-js/library/fn/symbol/iterator":57}],30:[function(ie,Ce,ue){"use strict";ue.__esModule=!0,ue.default=function(se,te){if(!(se instanceof te))throw new TypeError("Cannot call a class as a function")}},{}],31:[function(ie,Ce,ue){"use strict";ue.__esModule=!0;var se=ie("../core-js/object/define-property"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);ue.default=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),(0,te.default)(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}()},{"../core-js/object/define-property":20}],32:[function(ie,Ce,ue){"use strict";function se(b){return b&&b.__esModule?b:{default:b}}ue.__esModule=!0;var te=ie("../core-js/symbol/iterator"),le=se(te),ee=ie("../core-js/symbol"),ne=se(ee),E=typeof ne.default=="function"&&typeof le.default=="symbol"?function(b){return typeof b}:function(b){return b&&typeof ne.default=="function"&&b.constructor===ne.default&&b!==ne.default.prototype?"symbol":typeof b};ue.default=typeof ne.default=="function"&&E(le.default)==="symbol"?function(b){return b===void 0?"undefined":E(b)}:function(b){return b&&typeof ne.default=="function"&&b.constructor===ne.default&&b!==ne.default.prototype?"symbol":b===void 0?"undefined":E(b)}},{"../core-js/symbol":27,"../core-js/symbol/iterator":29}],33:[function(ie,Ce,ue){Ce.exports=ie("regenerator-runtime")},{"regenerator-runtime":191}],34:[function(ie,Ce,ue){"use strict";function se(ye){var me=ye.length;if(me%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var ge=ye.indexOf("=");return ge===-1&&(ge=me),[ge,ge===me?0:4-ge%4]}function te(ye){var me=se(ye),ge=me[0],_e=me[1];return 3*(ge+_e)/4-_e}function le(ye,me,ge){return 3*(me+ge)/4-ge}function ee(ye){for(var me,ge=se(ye),_e=ge[0],he=ge[1],pe=new re(le(ye,_e,he)),ke=0,Te=he>0?_e-4:_e,Ee=0;Ee<Te;Ee+=4)me=x[ye.charCodeAt(Ee)]<<18|x[ye.charCodeAt(Ee+1)]<<12|x[ye.charCodeAt(Ee+2)]<<6|x[ye.charCodeAt(Ee+3)],pe[ke++]=me>>16&255,pe[ke++]=me>>8&255,pe[ke++]=255&me;return he===2&&(me=x[ye.charCodeAt(Ee)]<<2|x[ye.charCodeAt(Ee+1)]>>4,pe[ke++]=255&me),he===1&&(me=x[ye.charCodeAt(Ee)]<<10|x[ye.charCodeAt(Ee+1)]<<4|x[ye.charCodeAt(Ee+2)]>>2,pe[ke++]=me>>8&255,pe[ke++]=255&me),pe}function ne(ye){return z[ye>>18&63]+z[ye>>12&63]+z[ye>>6&63]+z[63&ye]}function E(ye,me,ge){for(var _e,he=[],pe=me;pe<ge;pe+=3)_e=(ye[pe]<<16&16711680)+(ye[pe+1]<<8&65280)+(255&ye[pe+2]),he.push(ne(_e));return he.join("")}function b(ye){for(var me,ge=ye.length,_e=ge%3,he=[],pe=0,ke=ge-_e;pe<ke;pe+=16383)he.push(E(ye,pe,pe+16383>ke?ke:pe+16383));return _e===1?(me=ye[ge-1],he.push(z[me>>2]+z[me<<4&63]+"==")):_e===2&&(me=(ye[ge-2]<<8)+ye[ge-1],he.push(z[me>>10]+z[me>>4&63]+z[me<<2&63]+"=")),he.join("")}ue.byteLength=te,ue.toByteArray=ee,ue.fromByteArray=b;for(var z=[],x=[],re=typeof Uint8Array!="undefined"?Uint8Array:Array,ae="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",oe=0,ve=ae.length;oe<ve;++oe)z[oe]=ae[oe],x[ae.charCodeAt(oe)]=oe;x[45]=62,x[95]=63},{}],35:[function(ie,Ce,ue){(function(se,te,le){Ce!==void 0&&Ce.exports?Ce.exports=le():typeof ce=="function"&&ce.amd?ce("bowser",le):se.bowser=le()})(this,0,function(){function se(x){function re(ze){var Ve=x.match(ze);return Ve&&Ve.length>1&&Ve[1]||""}function ae(ze){var Ve=x.match(ze);return Ve&&Ve.length>1&&Ve[2]||""}var oe,ve=re(/(ipod|iphone|ipad)/i).toLowerCase(),ye=/like android/i.test(x),me=!ye&&/android/i.test(x),ge=/nexus\s*[0-6]\s*/i.test(x),_e=!ge&&/nexus\s*[0-9]+/i.test(x),he=/CrOS/.test(x),pe=/silk/i.test(x),ke=/sailfish/i.test(x),Te=/tizen/i.test(x),Ee=/(web|hpw)os/i.test(x),Oe=/windows phone/i.test(x),je=(/SamsungBrowser/i.test(x),!Oe&&/windows/i.test(x)),Pe=!ve&&!pe&&/macintosh/i.test(x),Qe=!me&&!ke&&!Te&&!Ee&&/linux/i.test(x),Xe=ae(/edg([ea]|ios)\/(\d+(\.\d+)?)/i),ot=re(/version\/(\d+(\.\d+)?)/i),He=/tablet/i.test(x)&&!/tablet pc/i.test(x),rt=!He&&/[^-]mobi/i.test(x),Ye=/xbox/i.test(x);/opera/i.test(x)?oe={name:"Opera",opera:b,version:ot||re(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)}:/opr\/|opios/i.test(x)?oe={name:"Opera",opera:b,version:re(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||ot}:/SamsungBrowser/i.test(x)?oe={name:"Samsung Internet for Android",samsungBrowser:b,version:ot||re(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)}:/coast/i.test(x)?oe={name:"Opera Coast",coast:b,version:ot||re(/(?:coast)[\s\/](\d+(\.\d+)?)/i)}:/yabrowser/i.test(x)?oe={name:"Yandex Browser",yandexbrowser:b,version:ot||re(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)}:/ucbrowser/i.test(x)?oe={name:"UC Browser",ucbrowser:b,version:re(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)}:/mxios/i.test(x)?oe={name:"Maxthon",maxthon:b,version:re(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)}:/epiphany/i.test(x)?oe={name:"Epiphany",epiphany:b,version:re(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)}:/puffin/i.test(x)?oe={name:"Puffin",puffin:b,version:re(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)}:/sleipnir/i.test(x)?oe={name:"Sleipnir",sleipnir:b,version:re(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)}:/k-meleon/i.test(x)?oe={name:"K-Meleon",kMeleon:b,version:re(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)}:Oe?(oe={name:"Windows Phone",osname:"Windows Phone",windowsphone:b},Xe?(oe.msedge=b,oe.version=Xe):(oe.msie=b,oe.version=re(/iemobile\/(\d+(\.\d+)?)/i))):/msie|trident/i.test(x)?oe={name:"Internet Explorer",msie:b,version:re(/(?:msie |rv:)(\d+(\.\d+)?)/i)}:he?oe={name:"Chrome",osname:"Chrome OS",chromeos:b,chromeBook:b,chrome:b,version:re(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:/edg([ea]|ios)/i.test(x)?oe={name:"Microsoft Edge",msedge:b,version:Xe}:/vivaldi/i.test(x)?oe={name:"Vivaldi",vivaldi:b,version:re(/vivaldi\/(\d+(\.\d+)?)/i)||ot}:ke?oe={name:"Sailfish",osname:"Sailfish OS",sailfish:b,version:re(/sailfish\s?browser\/(\d+(\.\d+)?)/i)}:/seamonkey\//i.test(x)?oe={name:"SeaMonkey",seamonkey:b,version:re(/seamonkey\/(\d+(\.\d+)?)/i)}:/firefox|iceweasel|fxios/i.test(x)?(oe={name:"Firefox",firefox:b,version:re(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(x)&&(oe.firefoxos=b,oe.osname="Firefox OS")):pe?oe={name:"Amazon Silk",silk:b,version:re(/silk\/(\d+(\.\d+)?)/i)}:/phantom/i.test(x)?oe={name:"PhantomJS",phantom:b,version:re(/phantomjs\/(\d+(\.\d+)?)/i)}:/slimerjs/i.test(x)?oe={name:"SlimerJS",slimer:b,version:re(/slimerjs\/(\d+(\.\d+)?)/i)}:/blackberry|\bbb\d+/i.test(x)||/rim\stablet/i.test(x)?oe={name:"BlackBerry",osname:"BlackBerry OS",blackberry:b,version:ot||re(/blackberry[\d]+\/(\d+(\.\d+)?)/i)}:Ee?(oe={name:"WebOS",osname:"WebOS",webos:b,version:ot||re(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(x)&&(oe.touchpad=b)):/bada/i.test(x)?oe={name:"Bada",osname:"Bada",bada:b,version:re(/dolfin\/(\d+(\.\d+)?)/i)}:Te?oe={name:"Tizen",osname:"Tizen",tizen:b,version:re(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||ot}:/qupzilla/i.test(x)?oe={name:"QupZilla",qupzilla:b,version:re(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||ot}:/chromium/i.test(x)?oe={name:"Chromium",chromium:b,version:re(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||ot}:/chrome|crios|crmo/i.test(x)?oe={name:"Chrome",chrome:b,version:re(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)}:me?oe={name:"Android",version:ot}:/safari|applewebkit/i.test(x)?(oe={name:"Safari",safari:b},ot&&(oe.version=ot)):ve?(oe={name:ve=="iphone"?"iPhone":ve=="ipad"?"iPad":"iPod"},ot&&(oe.version=ot)):oe=/googlebot/i.test(x)?{name:"Googlebot",googlebot:b,version:re(/googlebot\/(\d+(\.\d+))/i)||ot}:{name:re(/^(.*)\/(.*) /),version:ae(/^(.*)\/(.*) /)},!oe.msedge&&/(apple)?webkit/i.test(x)?(/(apple)?webkit\/537\.36/i.test(x)?(oe.name=oe.name||"Blink",oe.blink=b):(oe.name=oe.name||"Webkit",oe.webkit=b),!oe.version&&ot&&(oe.version=ot)):!oe.opera&&/gecko\//i.test(x)&&(oe.name=oe.name||"Gecko",oe.gecko=b,oe.version=oe.version||re(/gecko\/(\d+(\.\d+)?)/i)),oe.windowsphone||!me&&!oe.silk?!oe.windowsphone&&ve?(oe[ve]=b,oe.ios=b,oe.osname="iOS"):Pe?(oe.mac=b,oe.osname="macOS"):Ye?(oe.xbox=b,oe.osname="Xbox"):je?(oe.windows=b,oe.osname="Windows"):Qe&&(oe.linux=b,oe.osname="Linux"):(oe.android=b,oe.osname="Android");var ut="";oe.windows?ut=function(ze){switch(ze){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}}(re(/Windows ((NT|XP)( \d\d?.\d)?)/i)):oe.windowsphone?ut=re(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i):oe.mac?(ut=re(/Mac OS X (\d+([_\.\s]\d+)*)/i),ut=ut.replace(/[_\s]/g,".")):ve?(ut=re(/os (\d+([_\s]\d+)*) like mac os x/i),ut=ut.replace(/[_\s]/g,".")):me?ut=re(/android[ \/-](\d+(\.\d+)*)/i):oe.webos?ut=re(/(?:web|hpw)os\/(\d+(\.\d+)*)/i):oe.blackberry?ut=re(/rim\stablet\sos\s(\d+(\.\d+)*)/i):oe.bada?ut=re(/bada\/(\d+(\.\d+)*)/i):oe.tizen&&(ut=re(/tizen[\/\s](\d+(\.\d+)*)/i)),ut&&(oe.osversion=ut);var Ge=!oe.windows&&ut.split(".")[0];return He||_e||ve=="ipad"||me&&(Ge==3||Ge>=4&&!rt)||oe.silk?oe.tablet=b:(rt||ve=="iphone"||ve=="ipod"||me||ge||oe.blackberry||oe.webos||oe.bada)&&(oe.mobile=b),oe.msedge||oe.msie&&oe.version>=10||oe.yandexbrowser&&oe.version>=15||oe.vivaldi&&oe.version>=1||oe.chrome&&oe.version>=20||oe.samsungBrowser&&oe.version>=4||oe.firefox&&oe.version>=20||oe.safari&&oe.version>=6||oe.opera&&oe.version>=10||oe.ios&&oe.osversion&&oe.osversion.split(".")[0]>=6||oe.blackberry&&oe.version>=10.1||oe.chromium&&oe.version>=20?oe.a=b:oe.msie&&oe.version<10||oe.chrome&&oe.version<20||oe.firefox&&oe.version<20||oe.safari&&oe.version<6||oe.opera&&oe.version<10||oe.ios&&oe.osversion&&oe.osversion.split(".")[0]<6||oe.chromium&&oe.version<20?oe.c=b:oe.x=b,oe}function te(x){return x.split(".").length}function le(x,re){var ae,oe=[];if(Array.prototype.map)return Array.prototype.map.call(x,re);for(ae=0;ae<x.length;ae++)oe.push(re(x[ae]));return oe}function ee(x){for(var re=Math.max(te(x[0]),te(x[1])),ae=le(x,function(oe){var ve=re-te(oe);return oe+=new Array(ve+1).join(".0"),le(oe.split("."),function(ye){return new Array(20-ye.length).join("0")+ye}).reverse()});--re>=0;){if(ae[0][re]>ae[1][re])return 1;if(ae[0][re]!==ae[1][re])return-1;if(re===0)return 0}}function ne(x,re,ae){var oe=z;typeof re=="string"&&(ae=re,re=void 0),re===void 0&&(re=!1),ae&&(oe=se(ae));var ve=""+oe.version;for(var ye in x)if(x.hasOwnProperty(ye)&&oe[ye]){if(typeof x[ye]!="string")throw new Error("Browser version in the minVersion map should be a string: "+ye+": "+String(x));return ee([ve,x[ye]])<0}return re}function E(x,re,ae){return!ne(x,re,ae)}var b=!0,z=se(typeof navigator!="undefined"&&navigator.userAgent||"");return z.test=function(x){for(var re=0;re<x.length;++re){var ae=x[re];if(typeof ae=="string"&&ae in z)return!0}return!1},z.isUnsupportedBrowser=ne,z.compareVersions=ee,z.check=E,z._detect=se,z.detect=se,z})},{}],36:[function(ie,Ce,ue){},{}],37:[function(ie,Ce,ue){function se(z){if(z&&!E(z))throw new Error("Unknown encoding: "+z)}function te(z){return z.toString(this.encoding)}function le(z){this.charReceived=z.length%2,this.charLength=this.charReceived?2:0}function ee(z){this.charReceived=z.length%3,this.charLength=this.charReceived?3:0}var ne=ie("buffer").Buffer,E=ne.isEncoding||function(z){switch(z&&z.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}},b=ue.StringDecoder=function(z){switch(this.encoding=(z||"utf8").toLowerCase().replace(/[-_]/,""),se(z),this.encoding){case"utf8":this.surrogateSize=3;break;case"ucs2":case"utf16le":this.surrogateSize=2,this.detectIncompleteChar=le;break;case"base64":this.surrogateSize=3,this.detectIncompleteChar=ee;break;default:return void(this.write=te)}this.charBuffer=new ne(6),this.charReceived=0,this.charLength=0};b.prototype.write=function(z){for(var x="";this.charLength;){var re=z.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:z.length;if(z.copy(this.charBuffer,this.charReceived,0,re),this.charReceived+=re,this.charReceived<this.charLength)return"";z=z.slice(re,z.length),x=this.charBuffer.slice(0,this.charLength).toString(this.encoding);var oe=x.charCodeAt(x.length-1);if(!(oe>=55296&&oe<=56319)){if(this.charReceived=this.charLength=0,z.length===0)return x;break}this.charLength+=this.surrogateSize,x=""}this.detectIncompleteChar(z);var ae=z.length;this.charLength&&(z.copy(this.charBuffer,0,z.length-this.charReceived,ae),ae-=this.charReceived),x+=z.toString(this.encoding,0,ae);var ae=x.length-1,oe=x.charCodeAt(ae);if(oe>=55296&&oe<=56319){var ve=this.surrogateSize;return this.charLength+=ve,this.charReceived+=ve,this.charBuffer.copy(this.charBuffer,ve,0,ve),z.copy(this.charBuffer,0,0,ve),x.substring(0,ae)}return x},b.prototype.detectIncompleteChar=function(z){for(var x=z.length>=3?3:z.length;x>0;x--){var re=z[z.length-x];if(x==1&&re>>5==6){this.charLength=2;break}if(x<=2&&re>>4==14){this.charLength=3;break}if(x<=3&&re>>3==30){this.charLength=4;break}}this.charReceived=x},b.prototype.end=function(z){var x="";if(z&&z.length&&(x=this.write(z)),this.charReceived){var re=this.charReceived,ae=this.charBuffer,oe=this.encoding;x+=ae.slice(0,re).toString(oe)}return x}},{buffer:38}],38:[function(ie,Ce,ue){(function(se){"use strict";function te(){return ee.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function le(we,Le){if(te()<Le)throw new RangeError("Invalid typed array length");return ee.TYPED_ARRAY_SUPPORT?(we=new Uint8Array(Le),we.__proto__=ee.prototype):(we===null&&(we=new ee(Le)),we.length=Le),we}function ee(we,Le,Ue){if(!(ee.TYPED_ARRAY_SUPPORT||this instanceof ee))return new ee(we,Le,Ue);if(typeof we=="number"){if(typeof Le=="string")throw new Error("If encoding is specified then the first argument must be a string");return z(this,we)}return ne(this,we,Le,Ue)}function ne(we,Le,Ue,Me){if(typeof Le=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer!="undefined"&&Le instanceof ArrayBuffer?ae(we,Le,Ue,Me):typeof Le=="string"?x(we,Le,Ue):oe(we,Le)}function E(we){if(typeof we!="number")throw new TypeError('"size" argument must be a number');if(we<0)throw new RangeError('"size" argument must not be negative')}function b(we,Le,Ue,Me){return E(Le),Le<=0?le(we,Le):Ue!==void 0?typeof Me=="string"?le(we,Le).fill(Ue,Me):le(we,Le).fill(Ue):le(we,Le)}function z(we,Le){if(E(Le),we=le(we,Le<0?0:0|ve(Le)),!ee.TYPED_ARRAY_SUPPORT)for(var Ue=0;Ue<Le;++Ue)we[Ue]=0;return we}function x(we,Le,Ue){if(typeof Ue=="string"&&Ue!==""||(Ue="utf8"),!ee.isEncoding(Ue))throw new TypeError('"encoding" must be a valid string encoding');var Me=0|me(Le,Ue);we=le(we,Me);var Re=we.write(Le,Ue);return Re!==Me&&(we=we.slice(0,Re)),we}function re(we,Le){var Ue=Le.length<0?0:0|ve(Le.length);we=le(we,Ue);for(var Me=0;Me<Ue;Me+=1)we[Me]=255&Le[Me];return we}function ae(we,Le,Ue,Me){if(Le.byteLength,Ue<0||Le.byteLength<Ue)throw new RangeError("'offset' is out of bounds");if(Le.byteLength<Ue+(Me||0))throw new RangeError("'length' is out of bounds");return Le=Ue===void 0&&Me===void 0?new Uint8Array(Le):Me===void 0?new Uint8Array(Le,Ue):new Uint8Array(Le,Ue,Me),ee.TYPED_ARRAY_SUPPORT?(we=Le,we.__proto__=ee.prototype):we=re(we,Le),we}function oe(we,Le){if(ee.isBuffer(Le)){var Ue=0|ve(Le.length);return we=le(we,Ue),we.length===0||Le.copy(we,0,0,Ue),we}if(Le){if(typeof ArrayBuffer!="undefined"&&Le.buffer instanceof ArrayBuffer||"length"in Le)return typeof Le.length!="number"||Ae(Le.length)?le(we,0):re(we,Le);if(Le.type==="Buffer"&&Ke(Le.data))return re(we,Le.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function ve(we){if(we>=te())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+te().toString(16)+" bytes");return 0|we}function ye(we){return+we!=we&&(we=0),ee.alloc(+we)}function me(we,Le){if(ee.isBuffer(we))return we.length;if(typeof ArrayBuffer!="undefined"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(we)||we instanceof ArrayBuffer))return we.byteLength;typeof we!="string"&&(we=""+we);var Ue=we.length;if(Ue===0)return 0;for(var Me=!1;;)switch(Le){case"ascii":case"latin1":case"binary":return Ue;case"utf8":case"utf-8":case void 0:return Rt(we).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*Ue;case"hex":return Ue>>>1;case"base64":return _t(we).length;default:if(Me)return Rt(we).length;Le=(""+Le).toLowerCase(),Me=!0}}function ge(we,Le,Ue){var Me=!1;if((Le===void 0||Le<0)&&(Le=0),Le>this.length||((Ue===void 0||Ue>this.length)&&(Ue=this.length),Ue<=0)||(Ue>>>=0,Le>>>=0,Ue<=Le))return"";for(we||(we="utf8");;)switch(we){case"hex":return Ye(this,Le,Ue);case"utf8":case"utf-8":return Xe(this,Le,Ue);case"ascii":return He(this,Le,Ue);case"latin1":case"binary":return rt(this,Le,Ue);case"base64":return Qe(this,Le,Ue);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ut(this,Le,Ue);default:if(Me)throw new TypeError("Unknown encoding: "+we);we=(we+"").toLowerCase(),Me=!0}}function _e(we,Le,Ue){var Me=we[Le];we[Le]=we[Ue],we[Ue]=Me}function he(we,Le,Ue,Me,Re){if(we.length===0)return-1;if(typeof Ue=="string"?(Me=Ue,Ue=0):Ue>2147483647?Ue=2147483647:Ue<-2147483648&&(Ue=-2147483648),Ue=+Ue,isNaN(Ue)&&(Ue=Re?0:we.length-1),Ue<0&&(Ue=we.length+Ue),Ue>=we.length){if(Re)return-1;Ue=we.length-1}else if(Ue<0){if(!Re)return-1;Ue=0}if(typeof Le=="string"&&(Le=ee.from(Le,Me)),ee.isBuffer(Le))return Le.length===0?-1:pe(we,Le,Ue,Me,Re);if(typeof Le=="number")return Le&=255,ee.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?Re?Uint8Array.prototype.indexOf.call(we,Le,Ue):Uint8Array.prototype.lastIndexOf.call(we,Le,Ue):pe(we,[Le],Ue,Me,Re);throw new TypeError("val must be string, number or Buffer")}function pe(we,Le,Ue,Me,Re){function tt(yt,Yt){return lt===1?yt[Yt]:yt.readUInt16BE(Yt*lt)}var lt=1,Nt=we.length,Ct=Le.length;if(Me!==void 0&&((Me=String(Me).toLowerCase())==="ucs2"||Me==="ucs-2"||Me==="utf16le"||Me==="utf-16le")){if(we.length<2||Le.length<2)return-1;lt=2,Nt/=2,Ct/=2,Ue/=2}var vt;if(Re){var Pt=-1;for(vt=Ue;vt<Nt;vt++)if(tt(we,vt)===tt(Le,Pt===-1?0:vt-Pt)){if(Pt===-1&&(Pt=vt),vt-Pt+1===Ct)return Pt*lt}else Pt!==-1&&(vt-=vt-Pt),Pt=-1}else for(Ue+Ct>Nt&&(Ue=Nt-Ct),vt=Ue;vt>=0;vt--){for(var Ht=!0,jt=0;jt<Ct;jt++)if(tt(we,vt+jt)!==tt(Le,jt)){Ht=!1;break}if(Ht)return vt}return-1}function ke(we,Le,Ue,Me){Ue=Number(Ue)||0;var Re=we.length-Ue;Me?(Me=Number(Me))>Re&&(Me=Re):Me=Re;var tt=Le.length;if(tt%2!=0)throw new TypeError("Invalid hex string");Me>tt/2&&(Me=tt/2);for(var lt=0;lt<Me;++lt){var Nt=parseInt(Le.substr(2*lt,2),16);if(isNaN(Nt))return lt;we[Ue+lt]=Nt}return lt}function Te(we,Le,Ue,Me){return We(Rt(Le,we.length-Ue),we,Ue,Me)}function Ee(we,Le,Ue,Me){return We(xt(Le),we,Ue,Me)}function Oe(we,Le,Ue,Me){return Ee(we,Le,Ue,Me)}function je(we,Le,Ue,Me){return We(_t(Le),we,Ue,Me)}function Pe(we,Le,Ue,Me){return We(gt(Le,we.length-Ue),we,Ue,Me)}function Qe(we,Le,Ue){return Le===0&&Ue===we.length?Se.fromByteArray(we):Se.fromByteArray(we.slice(Le,Ue))}function Xe(we,Le,Ue){Ue=Math.min(we.length,Ue);for(var Me=[],Re=Le;Re<Ue;){var tt=we[Re],lt=null,Nt=tt>239?4:tt>223?3:tt>191?2:1;if(Re+Nt<=Ue){var Ct,vt,Pt,Ht;switch(Nt){case 1:tt<128&&(lt=tt);break;case 2:Ct=we[Re+1],(192&Ct)==128&&(Ht=(31&tt)<<6|63&Ct)>127&&(lt=Ht);break;case 3:Ct=we[Re+1],vt=we[Re+2],(192&Ct)==128&&(192&vt)==128&&(Ht=(15&tt)<<12|(63&Ct)<<6|63&vt)>2047&&(Ht<55296||Ht>57343)&&(lt=Ht);break;case 4:Ct=we[Re+1],vt=we[Re+2],Pt=we[Re+3],(192&Ct)==128&&(192&vt)==128&&(192&Pt)==128&&(Ht=(15&tt)<<18|(63&Ct)<<12|(63&vt)<<6|63&Pt)>65535&&Ht<1114112&&(lt=Ht)}}lt===null?(lt=65533,Nt=1):lt>65535&&(lt-=65536,Me.push(lt>>>10&1023|55296),lt=56320|1023<),Me.push(lt),Re+=Nt}return ot(Me)}function ot(we){var Le=we.length;if(Le<=Ne)return String.fromCharCode.apply(String,we);for(var Ue="",Me=0;Me<Le;)Ue+=String.fromCharCode.apply(String,we.slice(Me,Me+=Ne));return Ue}function He(we,Le,Ue){var Me="";Ue=Math.min(we.length,Ue);for(var Re=Le;Re<Ue;++Re)Me+=String.fromCharCode(127&we[Re]);return Me}function rt(we,Le,Ue){var Me="";Ue=Math.min(we.length,Ue);for(var Re=Le;Re<Ue;++Re)Me+=String.fromCharCode(we[Re]);return Me}function Ye(we,Le,Ue){var Me=we.length;(!Le||Le<0)&&(Le=0),(!Ue||Ue<0||Ue>Me)&&(Ue=Me);for(var Re="",tt=Le;tt<Ue;++tt)Re+=dt(we[tt]);return Re}function ut(we,Le,Ue){for(var Me=we.slice(Le,Ue),Re="",tt=0;tt<Me.length;tt+=2)Re+=String.fromCharCode(Me[tt]+256*Me[tt+1]);return Re}function Ge(we,Le,Ue){if(we%1!=0||we<0)throw new RangeError("offset is not uint");if(we+Le>Ue)throw new RangeError("Trying to access beyond buffer length")}function ze(we,Le,Ue,Me,Re,tt){if(!ee.isBuffer(we))throw new TypeError('"buffer" argument must be a Buffer instance');if(Le>Re||Le<tt)throw new RangeError('"value" argument is out of bounds');if(Ue+Me>we.length)throw new RangeError("Index out of range")}function Ve(we,Le,Ue,Me){Le<0&&(Le=65535+Le+1);for(var Re=0,tt=Math.min(we.length-Ue,2);Re<tt;++Re)we[Ue+Re]=(Le&255<<8*(Me?Re:1-Re))>>>8*(Me?Re:1-Re)}function $e(we,Le,Ue,Me){Le<0&&(Le=4294967295+Le+1);for(var Re=0,tt=Math.min(we.length-Ue,4);Re<tt;++Re)we[Ue+Re]=Le>>>8*(Me?Re:3-Re)&255}function nt(we,Le,Ue,Me,Re,tt){if(Ue+Me>we.length)throw new RangeError("Index out of range");if(Ue<0)throw new RangeError("Index out of range")}function et(we,Le,Ue,Me,Re){return Re||nt(we,Le,Ue,4,34028234663852886e22,-34028234663852886e22),Be.write(we,Le,Ue,Me,23,4),Ue+4}function pt(we,Le,Ue,Me,Re){return Re||nt(we,Le,Ue,8,17976931348623157e292,-17976931348623157e292),Be.write(we,Le,Ue,Me,52,8),Ue+8}function ct(we){if(we=Ot(we).replace(De,""),we.length<2)return"";for(;we.length%4!=0;)we+="=";return we}function Ot(we){return we.trim?we.trim():we.replace(/^\s+|\s+$/g,"")}function dt(we){return we<16?"0"+we.toString(16):we.toString(16)}function Rt(we,Le){Le=Le||1/0;for(var Ue,Me=we.length,Re=null,tt=[],lt=0;lt<Me;++lt){if((Ue=we.charCodeAt(lt))>55295&&Ue<57344){if(!Re){if(Ue>56319){(Le-=3)>-1&&tt.push(239,191,189);continue}if(lt+1===Me){(Le-=3)>-1&&tt.push(239,191,189);continue}Re=Ue;continue}if(Ue<56320){(Le-=3)>-1&&tt.push(239,191,189),Re=Ue;continue}Ue=65536+(Re-55296<<10|Ue-56320)}else Re&&(Le-=3)>-1&&tt.push(239,191,189);if(Re=null,Ue<128){if((Le-=1)<0)break;tt.push(Ue)}else if(Ue<2048){if((Le-=2)<0)break;tt.push(Ue>>6|192,63&Ue|128)}else if(Ue<65536){if((Le-=3)<0)break;tt.push(Ue>>12|224,Ue>>6&63|128,63&Ue|128)}else{if(!(Ue<1114112))throw new Error("Invalid code point");if((Le-=4)<0)break;tt.push(Ue>>18|240,Ue>>12&63|128,Ue>>6&63|128,63&Ue|128)}}return tt}function xt(we){for(var Le=[],Ue=0;Ue<we.length;++Ue)Le.push(255&we.charCodeAt(Ue));return Le}function gt(we,Le){for(var Ue,Me,Re,tt=[],lt=0;lt<we.length&&!((Le-=2)<0);++lt)Ue=we.charCodeAt(lt),Me=Ue>>8,Re=Ue%256,tt.push(Re),tt.push(Me);return tt}function _t(we){return Se.toByteArray(ct(we))}function We(we,Le,Ue,Me){for(var Re=0;Re<Me&&!(Re+Ue>=Le.length||Re>=we.length);++Re)Le[Re+Ue]=we[Re];return Re}function Ae(we){return we!==we}var Se=ie("base64-js"),Be=ie("ieee754"),Ke=ie("isarray");ue.Buffer=ee,ue.SlowBuffer=ye,ue.INSPECT_MAX_BYTES=50,ee.TYPED_ARRAY_SUPPORT=se.TYPED_ARRAY_SUPPORT!==void 0?se.TYPED_ARRAY_SUPPORT:function(){try{var we=new Uint8Array(1);return we.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},we.foo()===42&&typeof we.subarray=="function"&&we.subarray(1,1).byteLength===0}catch(Le){return!1}}(),ue.kMaxLength=te(),ee.poolSize=8192,ee._augment=function(we){return we.__proto__=ee.prototype,we},ee.from=function(we,Le,Ue){return ne(null,we,Le,Ue)},ee.TYPED_ARRAY_SUPPORT&&(ee.prototype.__proto__=Uint8Array.prototype,ee.__proto__=Uint8Array,typeof Symbol!="undefined"&&Symbol.species&&ee[Symbol.species]===ee&&Object.defineProperty(ee,Symbol.species,{value:null,configurable:!0})),ee.alloc=function(we,Le,Ue){return b(null,we,Le,Ue)},ee.allocUnsafe=function(we){return z(null,we)},ee.allocUnsafeSlow=function(we){return z(null,we)},ee.isBuffer=function(we){return!(we==null||!we._isBuffer)},ee.compare=function(we,Le){if(!ee.isBuffer(we)||!ee.isBuffer(Le))throw new TypeError("Arguments must be Buffers");if(we===Le)return 0;for(var Ue=we.length,Me=Le.length,Re=0,tt=Math.min(Ue,Me);Re<tt;++Re)if(we[Re]!==Le[Re]){Ue=we[Re],Me=Le[Re];break}return Ue<Me?-1:Me<Ue?1:0},ee.isEncoding=function(we){switch(String(we).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}},ee.concat=function(we,Le){if(!Ke(we))throw new TypeError('"list" argument must be an Array of Buffers');if(we.length===0)return ee.alloc(0);var Ue;if(Le===void 0)for(Le=0,Ue=0;Ue<we.length;++Ue)Le+=we[Ue].length;var Me=ee.allocUnsafe(Le),Re=0;for(Ue=0;Ue<we.length;++Ue){var tt=we[Ue];if(!ee.isBuffer(tt))throw new TypeError('"list" argument must be an Array of Buffers');tt.copy(Me,Re),Re+=tt.length}return Me},ee.byteLength=me,ee.prototype._isBuffer=!0,ee.prototype.swap16=function(){var we=this.length;if(we%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var Le=0;Le<we;Le+=2)_e(this,Le,Le+1);return this},ee.prototype.swap32=function(){var we=this.length;if(we%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var Le=0;Le<we;Le+=4)_e(this,Le,Le+3),_e(this,Le+1,Le+2);return this},ee.prototype.swap64=function(){var we=this.length;if(we%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var Le=0;Le<we;Le+=8)_e(this,Le,Le+7),_e(this,Le+1,Le+6),_e(this,Le+2,Le+5),_e(this,Le+3,Le+4);return this},ee.prototype.toString=function(){var we=0|this.length;return we===0?"":arguments.length===0?Xe(this,0,we):ge.apply(this,arguments)},ee.prototype.equals=function(we){if(!ee.isBuffer(we))throw new TypeError("Argument must be a Buffer");return this===we||ee.compare(this,we)===0},ee.prototype.inspect=function(){var we="",Le=ue.INSPECT_MAX_BYTES;return this.length>0&&(we=this.toString("hex",0,Le).match(/.{2}/g).join(" "),this.length>Le&&(we+=" ... ")),"<Buffer "+we+">"},ee.prototype.compare=function(we,Le,Ue,Me,Re){if(!ee.isBuffer(we))throw new TypeError("Argument must be a Buffer");if(Le===void 0&&(Le=0),Ue===void 0&&(Ue=we?we.length:0),Me===void 0&&(Me=0),Re===void 0&&(Re=this.length),Le<0||Ue>we.length||Me<0||Re>this.length)throw new RangeError("out of range index");if(Me>=Re&&Le>=Ue)return 0;if(Me>=Re)return-1;if(Le>=Ue)return 1;if(Le>>>=0,Ue>>>=0,Me>>>=0,Re>>>=0,this===we)return 0;for(var tt=Re-Me,lt=Ue-Le,Nt=Math.min(tt,lt),Ct=this.slice(Me,Re),vt=we.slice(Le,Ue),Pt=0;Pt<Nt;++Pt)if(Ct[Pt]!==vt[Pt]){tt=Ct[Pt],lt=vt[Pt];break}return tt<lt?-1:lt<tt?1:0},ee.prototype.includes=function(we,Le,Ue){return this.indexOf(we,Le,Ue)!==-1},ee.prototype.indexOf=function(we,Le,Ue){return he(this,we,Le,Ue,!0)},ee.prototype.lastIndexOf=function(we,Le,Ue){return he(this,we,Le,Ue,!1)},ee.prototype.write=function(we,Le,Ue,Me){if(Le===void 0)Me="utf8",Ue=this.length,Le=0;else if(Ue===void 0&&typeof Le=="string")Me=Le,Ue=this.length,Le=0;else{if(!isFinite(Le))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");Le|=0,isFinite(Ue)?(Ue|=0,Me===void 0&&(Me="utf8")):(Me=Ue,Ue=void 0)}var Re=this.length-Le;if((Ue===void 0||Ue>Re)&&(Ue=Re),we.length>0&&(Ue<0||Le<0)||Le>this.length)throw new RangeError("Attempt to write outside buffer bounds");Me||(Me="utf8");for(var tt=!1;;)switch(Me){case"hex":return ke(this,we,Le,Ue);case"utf8":case"utf-8":return Te(this,we,Le,Ue);case"ascii":return Ee(this,we,Le,Ue);case"latin1":case"binary":return Oe(this,we,Le,Ue);case"base64":return je(this,we,Le,Ue);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Pe(this,we,Le,Ue);default:if(tt)throw new TypeError("Unknown encoding: "+Me);Me=(""+Me).toLowerCase(),tt=!0}},ee.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var Ne=4096;ee.prototype.slice=function(we,Le){var Ue=this.length;we=~~we,Le=Le===void 0?Ue:~~Le,we<0?(we+=Ue)<0&&(we=0):we>Ue&&(we=Ue),Le<0?(Le+=Ue)<0&&(Le=0):Le>Ue&&(Le=Ue),Le<we&&(Le=we);var Me;if(ee.TYPED_ARRAY_SUPPORT)Me=this.subarray(we,Le),Me.__proto__=ee.prototype;else{var Re=Le-we;Me=new ee(Re,void 0);for(var tt=0;tt<Re;++tt)Me[tt]=this[tt+we]}return Me},ee.prototype.readUIntLE=function(we,Le,Ue){we|=0,Le|=0,Ue||Ge(we,Le,this.length);for(var Me=this[we],Re=1,tt=0;++tt<Le&&(Re*=256);)Me+=this[we+tt]*Re;return Me},ee.prototype.readUIntBE=function(we,Le,Ue){we|=0,Le|=0,Ue||Ge(we,Le,this.length);for(var Me=this[we+--Le],Re=1;Le>0&&(Re*=256);)Me+=this[we+--Le]*Re;return Me},ee.prototype.readUInt8=function(we,Le){return Le||Ge(we,1,this.length),this[we]},ee.prototype.readUInt16LE=function(we,Le){return Le||Ge(we,2,this.length),this[we]|this[we+1]<<8},ee.prototype.readUInt16BE=function(we,Le){return Le||Ge(we,2,this.length),this[we]<<8|this[we+1]},ee.prototype.readUInt32LE=function(we,Le){return Le||Ge(we,4,this.length),(this[we]|this[we+1]<<8|this[we+2]<<16)+16777216*this[we+3]},ee.prototype.readUInt32BE=function(we,Le){return Le||Ge(we,4,this.length),16777216*this[we]+(this[we+1]<<16|this[we+2]<<8|this[we+3])},ee.prototype.readIntLE=function(we,Le,Ue){we|=0,Le|=0,Ue||Ge(we,Le,this.length);for(var Me=this[we],Re=1,tt=0;++tt<Le&&(Re*=256);)Me+=this[we+tt]*Re;return Re*=128,Me>=Re&&(Me-=Math.pow(2,8*Le)),Me},ee.prototype.readIntBE=function(we,Le,Ue){we|=0,Le|=0,Ue||Ge(we,Le,this.length);for(var Me=Le,Re=1,tt=this[we+--Me];Me>0&&(Re*=256);)tt+=this[we+--Me]*Re;return Re*=128,tt>=Re&&(tt-=Math.pow(2,8*Le)),tt},ee.prototype.readInt8=function(we,Le){return Le||Ge(we,1,this.length),128&this[we]?-1*(255-this[we]+1):this[we]},ee.prototype.readInt16LE=function(we,Le){Le||Ge(we,2,this.length);var Ue=this[we]|this[we+1]<<8;return 32768&Ue?4294901760|Ue:Ue},ee.prototype.readInt16BE=function(we,Le){Le||Ge(we,2,this.length);var Ue=this[we+1]|this[we]<<8;return 32768&Ue?4294901760|Ue:Ue},ee.prototype.readInt32LE=function(we,Le){return Le||Ge(we,4,this.length),this[we]|this[we+1]<<8|this[we+2]<<16|this[we+3]<<24},ee.prototype.readInt32BE=function(we,Le){return Le||Ge(we,4,this.length),this[we]<<24|this[we+1]<<16|this[we+2]<<8|this[we+3]},ee.prototype.readFloatLE=function(we,Le){return Le||Ge(we,4,this.length),Be.read(this,we,!0,23,4)},ee.prototype.readFloatBE=function(we,Le){return Le||Ge(we,4,this.length),Be.read(this,we,!1,23,4)},ee.prototype.readDoubleLE=function(we,Le){return Le||Ge(we,8,this.length),Be.read(this,we,!0,52,8)},ee.prototype.readDoubleBE=function(we,Le){return Le||Ge(we,8,this.length),Be.read(this,we,!1,52,8)},ee.prototype.writeUIntLE=function(we,Le,Ue,Me){we=+we,Le|=0,Ue|=0,!Me&&ze(this,we,Le,Ue,Math.pow(2,8*Ue)-1,0);var Re=1,tt=0;for(this[Le]=255&we;++tt<Ue&&(Re*=256);)this[Le+tt]=we/Re&255;return Le+Ue},ee.prototype.writeUIntBE=function(we,Le,Ue,Me){we=+we,Le|=0,Ue|=0,!Me&&ze(this,we,Le,Ue,Math.pow(2,8*Ue)-1,0);var Re=Ue-1,tt=1;for(this[Le+Re]=255&we;--Re>=0&&(tt*=256);)this[Le+Re]=we/tt&255;return Le+Ue},ee.prototype.writeUInt8=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,1,255,0),ee.TYPED_ARRAY_SUPPORT||(we=Math.floor(we)),this[Le]=255&we,Le+1},ee.prototype.writeUInt16LE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,2,65535,0),ee.TYPED_ARRAY_SUPPORT?(this[Le]=255&we,this[Le+1]=we>>>8):Ve(this,we,Le,!0),Le+2},ee.prototype.writeUInt16BE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,2,65535,0),ee.TYPED_ARRAY_SUPPORT?(this[Le]=we>>>8,this[Le+1]=255&we):Ve(this,we,Le,!1),Le+2},ee.prototype.writeUInt32LE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,4,4294967295,0),ee.TYPED_ARRAY_SUPPORT?(this[Le+3]=we>>>24,this[Le+2]=we>>>16,this[Le+1]=we>>>8,this[Le]=255&we):$e(this,we,Le,!0),Le+4},ee.prototype.writeUInt32BE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,4,4294967295,0),ee.TYPED_ARRAY_SUPPORT?(this[Le]=we>>>24,this[Le+1]=we>>>16,this[Le+2]=we>>>8,this[Le+3]=255&we):$e(this,we,Le,!1),Le+4},ee.prototype.writeIntLE=function(we,Le,Ue,Me){if(we=+we,Le|=0,!Me){var Re=Math.pow(2,8*Ue-1);ze(this,we,Le,Ue,Re-1,-Re)}var tt=0,lt=1,Nt=0;for(this[Le]=255&we;++tt<Ue&&(lt*=256);)we<0&&Nt===0&&this[Le+tt-1]!==0&&(Nt=1),this[Le+tt]=(we/lt>>0)-Nt&255;return Le+Ue},ee.prototype.writeIntBE=function(we,Le,Ue,Me){if(we=+we,Le|=0,!Me){var Re=Math.pow(2,8*Ue-1);ze(this,we,Le,Ue,Re-1,-Re)}var tt=Ue-1,lt=1,Nt=0;for(this[Le+tt]=255&we;--tt>=0&&(lt*=256);)we<0&&Nt===0&&this[Le+tt+1]!==0&&(Nt=1),this[Le+tt]=(we/lt>>0)-Nt&255;return Le+Ue},ee.prototype.writeInt8=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,1,127,-128),ee.TYPED_ARRAY_SUPPORT||(we=Math.floor(we)),we<0&&(we=255+we+1),this[Le]=255&we,Le+1},ee.prototype.writeInt16LE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,2,32767,-32768),ee.TYPED_ARRAY_SUPPORT?(this[Le]=255&we,this[Le+1]=we>>>8):Ve(this,we,Le,!0),Le+2},ee.prototype.writeInt16BE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,2,32767,-32768),ee.TYPED_ARRAY_SUPPORT?(this[Le]=we>>>8,this[Le+1]=255&we):Ve(this,we,Le,!1),Le+2},ee.prototype.writeInt32LE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,4,2147483647,-2147483648),ee.TYPED_ARRAY_SUPPORT?(this[Le]=255&we,this[Le+1]=we>>>8,this[Le+2]=we>>>16,this[Le+3]=we>>>24):$e(this,we,Le,!0),Le+4},ee.prototype.writeInt32BE=function(we,Le,Ue){return we=+we,Le|=0,Ue||ze(this,we,Le,4,2147483647,-2147483648),we<0&&(we=4294967295+we+1),ee.TYPED_ARRAY_SUPPORT?(this[Le]=we>>>24,this[Le+1]=we>>>16,this[Le+2]=we>>>8,this[Le+3]=255&we):$e(this,we,Le,!1),Le+4},ee.prototype.writeFloatLE=function(we,Le,Ue){return et(this,we,Le,!0,Ue)},ee.prototype.writeFloatBE=function(we,Le,Ue){return et(this,we,Le,!1,Ue)},ee.prototype.writeDoubleLE=function(we,Le,Ue){return pt(this,we,Le,!0,Ue)},ee.prototype.writeDoubleBE=function(we,Le,Ue){return pt(this,we,Le,!1,Ue)},ee.prototype.copy=function(we,Le,Ue,Me){if(Ue||(Ue=0),Me||Me===0||(Me=this.length),Le>=we.length&&(Le=we.length),Le||(Le=0),Me>0&&Me<Ue&&(Me=Ue),Me===Ue||we.length===0||this.length===0)return 0;if(Le<0)throw new RangeError("targetStart out of bounds");if(Ue<0||Ue>=this.length)throw new RangeError("sourceStart out of bounds");if(Me<0)throw new RangeError("sourceEnd out of bounds");Me>this.length&&(Me=this.length),we.length-Le<Me-Ue&&(Me=we.length-Le+Ue);var Re,tt=Me-Ue;if(this===we&&Ue<Le&&Le<Me)for(Re=tt-1;Re>=0;--Re)we[Re+Le]=this[Re+Ue];else if(tt<1e3||!ee.TYPED_ARRAY_SUPPORT)for(Re=0;Re<tt;++Re)we[Re+Le]=this[Re+Ue];else Uint8Array.prototype.set.call(we,this.subarray(Ue,Ue+tt),Le);return tt},ee.prototype.fill=function(we,Le,Ue,Me){if(typeof we=="string"){if(typeof Le=="string"?(Me=Le,Le=0,Ue=this.length):typeof Ue=="string"&&(Me=Ue,Ue=this.length),we.length===1){var Re=we.charCodeAt(0);Re<256&&(we=Re)}if(Me!==void 0&&typeof Me!="string")throw new TypeError("encoding must be a string");if(typeof Me=="string"&&!ee.isEncoding(Me))throw new TypeError("Unknown encoding: "+Me)}else typeof we=="number"&&(we&=255);if(Le<0||this.length<Le||this.length<Ue)throw new RangeError("Out of range index");if(Ue<=Le)return this;Le>>>=0,Ue=Ue===void 0?this.length:Ue>>>0,we||(we=0);var tt;if(typeof we=="number")for(tt=Le;tt<Ue;++tt)this[tt]=we;else{var lt=ee.isBuffer(we)?we:Rt(new ee(we,Me).toString()),Nt=lt.length;for(tt=0;tt<Ue-Le;++tt)this[tt+Le]=lt[tt%Nt]}return this};var De=/[^+\/0-9A-Za-z-_]/g}).call(this,typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"base64-js":34,ieee754:161,isarray:166}],39:[function(ie,Ce,ue){Ce.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"}},{}],40:[function(ie,Ce,ue){"use strict";var se=function(){this.buffer=[],this.fns=[]};se.prototype.push=function(le,ee){if(this.fns.length)return this.fns.shift()(null,le);var ne={data:le,priority:ee},E=te(this.buffer,ne,function(b){return b.priority});this.buffer.splice(E,0,ne)},se.prototype.next=function(){var le=this;return function(ee){if(le.buffer.length)return ee(null,le.buffer.pop().data);le.fns.push(ee)}};var te=function(le,ee,ne){ee=ne(ee);for(var E=0,b=le?le.length:E;E<b;){var z=E+b>>>1;ne(le[z])<ee?E=z+1:b=z}return E};Ce.exports=se},{}],41:[function(ie,Ce,ue){function se(ae){var oe=this,ve=re.call(arguments,1);return new Promise(function(ye,me){function ge(pe){var ke;try{ke=ae.next(pe)}catch(Te){return me(Te)}he(ke)}function _e(pe){var ke;try{ke=ae.throw(pe)}catch(Te){return me(Te)}he(ke)}function he(pe){if(pe.done)return ye(pe.value);var ke=te.call(oe,pe.value);return ke&&E(ke)?ke.then(ge,_e):_e(new TypeError('You may only yield a function, promise, generator, array, or object, but the following object was passed: "'+String(pe.value)+'"'))}if(typeof ae=="function"&&(ae=ae.apply(oe,ve)),!ae||typeof ae.next!="function")return ye(ae);ge()})}function te(ae){return ae&&(E(ae)?ae:z(ae)||b(ae)?se.call(this,ae):typeof ae=="function"?le.call(this,ae):Array.isArray(ae)?ee.call(this,ae):x(ae)?ne.call(this,ae):ae)}function le(ae){var oe=this;return new Promise(function(ve,ye){ae.call(oe,function(me,ge){if(me)return ye(me);arguments.length>2&&(ge=re.call(arguments,1)),ve(ge)})})}function ee(ae){return Promise.all(ae.map(te,this))}function ne(ae){for(var oe=new ae.constructor,ve=Object.keys(ae),ye=[],me=0;me<ve.length;me++){var ge=ve[me],_e=te.call(this,ae[ge]);_e&&E(_e)?function(he,pe){oe[pe]=void 0,ye.push(he.then(function(ke){oe[pe]=ke}))}(_e,ge):oe[ge]=ae[ge]}return Promise.all(ye).then(function(){return oe})}function E(ae){return typeof ae.then=="function"}function b(ae){return typeof ae.next=="function"&&typeof ae.throw=="function"}function z(ae){var oe=ae.constructor;return!!oe&&(oe.name==="GeneratorFunction"||oe.displayName==="GeneratorFunction"||b(oe.prototype))}function x(ae){return Object==ae.constructor}var re=Array.prototype.slice;Ce.exports=se.default=se.co=se,se.wrap=function(ae){function oe(){return se.call(this,ae.apply(this,arguments))}return oe.__generatorFunction__=ae,oe}},{}],42:[function(ie,Ce,ue){Ce.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}},{}],43:[function(ie,Ce,ue){"use strict";function se(ee,ne){if(!(this instanceof se))return new se(ee,ne);this.src=ee,this._withAccess=ne}function te(ee,ne){return ee[ne]===void 0&&ee.__lookupGetter__(ne)===void 0&&ee.__lookupSetter__(ne)===void 0}var le=Array.prototype.slice;Ce.exports=se,se.prototype.withAccess=function(ee){return this._withAccess=ee!==!1,this},se.prototype.pick=function(ee){return Array.isArray(ee)||(ee=le.call(arguments)),ee.length&&(this.keys=ee),this},se.prototype.to=function(ee){if(ee=ee||{},!this.src)return ee;var ne=this.keys||Object.keys(this.src);if(!this._withAccess){for(var E=0;E<ne.length;E++)b=ne[E],ee[b]===void 0&&(ee[b]=this.src[b]);return ee}for(var E=0;E<ne.length;E++){var b=ne[E];if(te(ee,b)){var z=this.src.__lookupGetter__(b),x=this.src.__lookupSetter__(b);z&&ee.__defineGetter__(b,z),x&&ee.__defineSetter__(b,x),z||x||(ee[b]=this.src[b])}}return ee},se.prototype.toCover=function(ee){for(var ne=this.keys||Object.keys(this.src),E=0;E<ne.length;E++){var b=ne[E];delete ee[b];var z=this.src.__lookupGetter__(b),x=this.src.__lookupSetter__(b);z&&ee.__defineGetter__(b,z),x&&ee.__defineSetter__(b,x),z||x||(ee[b]=this.src[b])}},se.prototype.override=se.prototype.toCover,se.prototype.and=function(ee){var ne={};return this.to(ne),this.src=ee,this.to(ne),this.src=ne,this}},{}],44:[function(ie,Ce,ue){ie("../../modules/es6.string.iterator"),ie("../../modules/es6.array.from"),Ce.exports=ie("../../modules/_core").Array.from},{"../../modules/_core":65,"../../modules/es6.array.from":133,"../../modules/es6.string.iterator":145}],45:[function(ie,Ce,ue){var se=ie("../../modules/_core"),te=se.JSON||(se.JSON={stringify:JSON.stringify});Ce.exports=function(le){return te.stringify.apply(te,arguments)}},{"../../modules/_core":65}],46:[function(ie,Ce,ue){ie("../../modules/es6.object.assign"),Ce.exports=ie("../../modules/_core").Object.assign},{"../../modules/_core":65,"../../modules/es6.object.assign":136}],47:[function(ie,Ce,ue){ie("../../modules/es6.object.create");var se=ie("../../modules/_core").Object;Ce.exports=function(te,le){return se.create(te,le)}},{"../../modules/_core":65,"../../modules/es6.object.create":137}],48:[function(ie,Ce,ue){ie("../../modules/es6.object.define-property");var se=ie("../../modules/_core").Object;Ce.exports=function(te,le,ee){return se.defineProperty(te,le,ee)}},{"../../modules/_core":65,"../../modules/es6.object.define-property":138}],49:[function(ie,Ce,ue){ie("../../modules/es6.object.get-own-property-names");var se=ie("../../modules/_core").Object;Ce.exports=function(te){return se.getOwnPropertyNames(te)}},{"../../modules/_core":65,"../../modules/es6.object.get-own-property-names":139}],50:[function(ie,Ce,ue){ie("../../modules/es6.object.get-prototype-of"),Ce.exports=ie("../../modules/_core").Object.getPrototypeOf},{"../../modules/_core":65,"../../modules/es6.object.get-prototype-of":140}],51:[function(ie,Ce,ue){ie("../../modules/es6.object.keys"),Ce.exports=ie("../../modules/_core").Object.keys},{"../../modules/_core":65,"../../modules/es6.object.keys":141}],52:[function(ie,Ce,ue){ie("../modules/es6.object.to-string"),ie("../modules/es6.string.iterator"),ie("../modules/web.dom.iterable"),ie("../modules/es6.promise"),ie("../modules/es7.promise.finally"),ie("../modules/es7.promise.try"),Ce.exports=ie("../modules/_core").Promise},{"../modules/_core":65,"../modules/es6.object.to-string":142,"../modules/es6.promise":143,"../modules/es6.string.iterator":145,"../modules/es7.promise.finally":147,"../modules/es7.promise.try":148,"../modules/web.dom.iterable":151}],53:[function(ie,Ce,ue){ie("../modules/web.immediate"),Ce.exports=ie("../modules/_core").setImmediate},{"../modules/_core":65,"../modules/web.immediate":152}],54:[function(ie,Ce,ue){ie("../../modules/es6.string.from-code-point"),Ce.exports=ie("../../modules/_core").String.fromCodePoint},{"../../modules/_core":65,"../../modules/es6.string.from-code-point":144}],55:[function(ie,Ce,ue){ie("../../modules/es6.function.has-instance"),Ce.exports=ie("../../modules/_wks-ext").f("hasInstance")},{"../../modules/_wks-ext":130,"../../modules/es6.function.has-instance":135}],56:[function(ie,Ce,ue){ie("../../modules/es6.symbol"),ie("../../modules/es6.object.to-string"),ie("../../modules/es7.symbol.async-iterator"),ie("../../modules/es7.symbol.observable"),Ce.exports=ie("../../modules/_core").Symbol},{"../../modules/_core":65,"../../modules/es6.object.to-string":142,"../../modules/es6.symbol":146,"../../modules/es7.symbol.async-iterator":149,"../../modules/es7.symbol.observable":150}],57:[function(ie,Ce,ue){ie("../../modules/es6.string.iterator"),ie("../../modules/web.dom.iterable"),Ce.exports=ie("../../modules/_wks-ext").f("iterator")},{"../../modules/_wks-ext":130,"../../modules/es6.string.iterator":145,"../../modules/web.dom.iterable":151}],58:[function(ie,Ce,ue){Ce.exports=function(se){if(typeof se!="function")throw TypeError(se+" is not a function!");return se}},{}],59:[function(ie,Ce,ue){Ce.exports=function(){}},{}],60:[function(ie,Ce,ue){Ce.exports=function(se,te,le,ee){if(!(se instanceof te)||ee!==void 0&&ee in se)throw TypeError(le+": incorrect invocation!");return se}},{}],61:[function(ie,Ce,ue){var se=ie("./_is-object");Ce.exports=function(te){if(!se(te))throw TypeError(te+" is not an object!");return te}},{"./_is-object":85}],62:[function(ie,Ce,ue){var se=ie("./_to-iobject"),te=ie("./_to-length"),le=ie("./_to-absolute-index");Ce.exports=function(ee){return function(ne,E,b){var z,x=se(ne),re=te(x.length),ae=le(b,re);if(ee&&E!=E){for(;re>ae;)if((z=x[ae++])!=z)return!0}else for(;re>ae;ae++)if((ee||ae in x)&&x[ae]===E)return ee||ae||0;return!ee&&-1}}},{"./_to-absolute-index":121,"./_to-iobject":123,"./_to-length":124}],63:[function(ie,Ce,ue){var se=ie("./_cof"),te=ie("./_wks")("toStringTag"),le=se(function(){return arguments}())=="Arguments",ee=function(ne,E){try{return ne[E]}catch(b){}};Ce.exports=function(ne){var E,b,z;return ne===void 0?"Undefined":ne===null?"Null":typeof(b=ee(E=Object(ne),te))=="string"?b:le?se(E):(z=se(E))=="Object"&&typeof E.callee=="function"?"Arguments":z}},{"./_cof":64,"./_wks":131}],64:[function(ie,Ce,ue){var se={}.toString;Ce.exports=function(te){return se.call(te).slice(8,-1)}},{}],65:[function(ie,Ce,ue){var se=Ce.exports={version:"2.5.7"};typeof __e=="number"&&(__e=se)},{}],66:[function(ie,Ce,ue){"use strict";var se=ie("./_object-dp"),te=ie("./_property-desc");Ce.exports=function(le,ee,ne){ee in le?se.f(le,ee,te(0,ne)):le[ee]=ne}},{"./_object-dp":98,"./_property-desc":111}],67:[function(ie,Ce,ue){var se=ie("./_a-function");Ce.exports=function(te,le,ee){if(se(te),le===void 0)return te;switch(ee){case 1:return function(ne){return te.call(le,ne)};case 2:return function(ne,E){return te.call(le,ne,E)};case 3:return function(ne,E,b){return te.call(le,ne,E,b)}}return function(){return te.apply(le,arguments)}}},{"./_a-function":58}],68:[function(ie,Ce,ue){Ce.exports=function(se){if(se==null)throw TypeError("Can't call method on "+se);return se}},{}],69:[function(ie,Ce,ue){Ce.exports=!ie("./_fails")(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})},{"./_fails":74}],70:[function(ie,Ce,ue){var se=ie("./_is-object"),te=ie("./_global").document,le=se(te)&&se(te.createElement);Ce.exports=function(ee){return le?te.createElement(ee):{}}},{"./_global":76,"./_is-object":85}],71:[function(ie,Ce,ue){Ce.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},{}],72:[function(ie,Ce,ue){var se=ie("./_object-keys"),te=ie("./_object-gops"),le=ie("./_object-pie");Ce.exports=function(ee){var ne=se(ee),E=te.f;if(E)for(var b,z=E(ee),x=le.f,re=0;z.length>re;)x.call(ee,b=z[re++])&&ne.push(b);return ne}},{"./_object-gops":103,"./_object-keys":106,"./_object-pie":107}],73:[function(ie,Ce,ue){var se=ie("./_global"),te=ie("./_core"),le=ie("./_ctx"),ee=ie("./_hide"),ne=ie("./_has"),E=function(b,z,x){var re,ae,oe,ve=b&E.F,ye=b&E.G,me=b&E.S,ge=b&E.P,_e=b&E.B,he=b&E.W,pe=ye?te:te[z]||(te[z]={}),ke=pe.prototype,Te=ye?se:me?se[z]:(se[z]||{}).prototype;ye&&(x=z);for(re in x)(ae=!ve&&Te&&Te[re]!==void 0)&&ne(pe,re)||(oe=ae?Te[re]:x[re],pe[re]=ye&&typeof Te[re]!="function"?x[re]:_e&&ae?le(oe,se):he&&Te[re]==oe?function(Ee){var Oe=function(je,Pe,Qe){if(this instanceof Ee){switch(arguments.length){case 0:return new Ee;case 1:return new Ee(je);case 2:return new Ee(je,Pe)}return new Ee(je,Pe,Qe)}return Ee.apply(this,arguments)};return Oe.prototype=Ee.prototype,Oe}(oe):ge&&typeof oe=="function"?le(Function.call,oe):oe,ge&&((pe.virtual||(pe.virtual={}))[re]=oe,b&E.R&&ke&&!ke[re]&&ee(ke,re,oe)))};E.F=1,E.G=2,E.S=4,E.P=8,E.B=16,E.W=32,E.U=64,E.R=128,Ce.exports=E},{"./_core":65,"./_ctx":67,"./_global":76,"./_has":77,"./_hide":78}],74:[function(ie,Ce,ue){Ce.exports=function(se){try{return!!se()}catch(te){return!0}}},{}],75:[function(ie,Ce,x){var se=ie("./_ctx"),te=ie("./_iter-call"),le=ie("./_is-array-iter"),ee=ie("./_an-object"),ne=ie("./_to-length"),E=ie("./core.get-iterator-method"),b={},z={},x=Ce.exports=function(re,ae,oe,ve,ye){var me,ge,_e,he,pe=ye?function(){return re}:E(re),ke=se(oe,ve,ae?2:1),Te=0;if(typeof pe!="function")throw TypeError(re+" is not iterable!");if(le(pe)){for(me=ne(re.length);me>Te;Te++)if((he=ae?ke(ee(ge=re[Te])[0],ge[1]):ke(re[Te]))===b||he===z)return he}else for(_e=pe.call(re);!(ge=_e.next()).done;)if((he=te(_e,ke,ge.value,ae))===b||he===z)return he};x.BREAK=b,x.RETURN=z},{"./_an-object":61,"./_ctx":67,"./_is-array-iter":83,"./_iter-call":86,"./_to-length":124,"./core.get-iterator-method":132}],76:[function(ie,Ce,ue){var se=Ce.exports=typeof window!="undefined"&&window.Math==Math?window:typeof self!="undefined"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=se)},{}],77:[function(ie,Ce,ue){var se={}.hasOwnProperty;Ce.exports=function(te,le){return se.call(te,le)}},{}],78:[function(ie,Ce,ue){var se=ie("./_object-dp"),te=ie("./_property-desc");Ce.exports=ie("./_descriptors")?function(le,ee,ne){return se.f(le,ee,te(1,ne))}:function(le,ee,ne){return le[ee]=ne,le}},{"./_descriptors":69,"./_object-dp":98,"./_property-desc":111}],79:[function(ie,Ce,ue){var se=ie("./_global").document;Ce.exports=se&&se.documentElement},{"./_global":76}],80:[function(ie,Ce,ue){Ce.exports=!ie("./_descriptors")&&!ie("./_fails")(function(){return Object.defineProperty(ie("./_dom-create")("div"),"a",{get:function(){return 7}}).a!=7})},{"./_descriptors":69,"./_dom-create":70,"./_fails":74}],81:[function(ie,Ce,ue){Ce.exports=function(se,te,le){var ee=le===void 0;switch(te.length){case 0:return ee?se():se.call(le);case 1:return ee?se(te[0]):se.call(le,te[0]);case 2:return ee?se(te[0],te[1]):se.call(le,te[0],te[1]);case 3:return ee?se(te[0],te[1],te[2]):se.call(le,te[0],te[1],te[2]);case 4:return ee?se(te[0],te[1],te[2],te[3]):se.call(le,te[0],te[1],te[2],te[3])}return se.apply(le,te)}},{}],82:[function(ie,Ce,ue){var se=ie("./_cof");Ce.exports=Object("z").propertyIsEnumerable(0)?Object:function(te){return se(te)=="String"?te.split(""):Object(te)}},{"./_cof":64}],83:[function(ie,Ce,ue){var se=ie("./_iterators"),te=ie("./_wks")("iterator"),le=Array.prototype;Ce.exports=function(ee){return ee!==void 0&&(se.Array===ee||le[te]===ee)}},{"./_iterators":91,"./_wks":131}],84:[function(ie,Ce,ue){var se=ie("./_cof");Ce.exports=Array.isArray||function(te){return se(te)=="Array"}},{"./_cof":64}],85:[function(ie,Ce,ue){Ce.exports=function(se){return typeof se=="object"?se!==null:typeof se=="function"}},{}],86:[function(ie,Ce,ue){var se=ie("./_an-object");Ce.exports=function(te,le,ee,ne){try{return ne?le(se(ee)[0],ee[1]):le(ee)}catch(b){var E=te.return;throw E!==void 0&&se(E.call(te)),b}}},{"./_an-object":61}],87:[function(ie,Ce,ue){"use strict";var se=ie("./_object-create"),te=ie("./_property-desc"),le=ie("./_set-to-string-tag"),ee={};ie("./_hide")(ee,ie("./_wks")("iterator"),function(){return this}),Ce.exports=function(ne,E,b){ne.prototype=se(ee,{next:te(1,b)}),le(ne,E+" Iterator")}},{"./_hide":78,"./_object-create":97,"./_property-desc":111,"./_set-to-string-tag":115,"./_wks":131}],88:[function(ie,Ce,ue){"use strict";var se=ie("./_library"),te=ie("./_export"),le=ie("./_redefine"),ee=ie("./_hide"),ne=ie("./_iterators"),E=ie("./_iter-create"),b=ie("./_set-to-string-tag"),z=ie("./_object-gpo"),x=ie("./_wks")("iterator"),re=!([].keys&&"next"in[].keys()),ae=function(){return this};Ce.exports=function(oe,ve,ye,me,ge,_e,he){E(ye,ve,me);var pe,ke,Te,Ee=function(Ye){if(!re&&Ye in Qe)return Qe[Ye];switch(Ye){case"keys":case"values":return function(){return new ye(this,Ye)}}return function(){return new ye(this,Ye)}},Oe=ve+" Iterator",je=ge=="values",Pe=!1,Qe=oe.prototype,Xe=Qe[x]||Qe["@@iterator"]||ge&&Qe[ge],ot=Xe||Ee(ge),He=ge?je?Ee("entries"):ot:void 0,rt=ve=="Array"&&Qe.entries||Xe;if(rt&&(Te=z(rt.call(new oe)))!==Object.prototype&&Te.next&&(b(Te,Oe,!0),se||typeof Te[x]=="function"||ee(Te,x,ae)),je&&Xe&&Xe.name!=="values"&&(Pe=!0,ot=function(){return Xe.call(this)}),se&&!he||!re&&!Pe&&Qe[x]||ee(Qe,x,ot),ne[ve]=ot,ne[Oe]=ae,ge)if(pe={values:je?ot:Ee("values"),keys:_e?ot:Ee("keys"),entries:He},he)for(ke in pe)ke in Qe||le(Qe,ke,pe[ke]);else te(te.P+te.F*(re||Pe),ve,pe);return pe}},{"./_export":73,"./_hide":78,"./_iter-create":87,"./_iterators":91,"./_library":92,"./_object-gpo":104,"./_redefine":113,"./_set-to-string-tag":115,"./_wks":131}],89:[function(ie,Ce,ue){var se=ie("./_wks")("iterator"),te=!1;try{var le=[7][se]();le.return=function(){te=!0},Array.from(le,function(){throw 2})}catch(ee){}Ce.exports=function(ee,ne){if(!ne&&!te)return!1;var E=!1;try{var b=[7],z=b[se]();z.next=function(){return{done:E=!0}},b[se]=function(){return z},ee(b)}catch(x){}return E}},{"./_wks":131}],90:[function(ie,Ce,ue){Ce.exports=function(se,te){return{value:te,done:!!se}}},{}],91:[function(ie,Ce,ue){Ce.exports={}},{}],92:[function(ie,Ce,ue){Ce.exports=!0},{}],93:[function(ie,Ce,ue){var se=ie("./_uid")("meta"),te=ie("./_is-object"),le=ie("./_has"),ee=ie("./_object-dp").f,ne=0,E=Object.isExtensible||function(){return!0},b=!ie("./_fails")(function(){return E(Object.preventExtensions({}))}),z=function(ve){ee(ve,se,{value:{i:"O"+ ++ne,w:{}}})},x=function(ve,ye){if(!te(ve))return typeof ve=="symbol"?ve:(typeof ve=="string"?"S":"P")+ve;if(!le(ve,se)){if(!E(ve))return"F";if(!ye)return"E";z(ve)}return ve[se].i},re=function(ve,ye){if(!le(ve,se)){if(!E(ve))return!0;if(!ye)return!1;z(ve)}return ve[se].w},ae=function(ve){return b&&oe.NEED&&E(ve)&&!le(ve,se)&&z(ve),ve},oe=Ce.exports={KEY:se,NEED:!1,fastKey:x,getWeak:re,onFreeze:ae}},{"./_fails":74,"./_has":77,"./_is-object":85,"./_object-dp":98,"./_uid":127}],94:[function(ie,Ce,ue){var se=ie("./_global"),te=ie("./_task").set,le=se.MutationObserver||se.WebKitMutationObserver,ee=se.process,ne=se.Promise,E=ie("./_cof")(ee)=="process";Ce.exports=function(){var b,z,x,re=function(){var ye,me;for(E&&(ye=ee.domain)&&ye.exit();b;){me=b.fn,b=b.next;try{me()}catch(ge){throw b?x():z=void 0,ge}}z=void 0,ye&&ye.enter()};if(E)x=function(){ee.nextTick(re)};else if(!le||se.navigator&&se.navigator.standalone)if(ne&&ne.resolve){var ae=ne.resolve(void 0);x=function(){ae.then(re)}}else x=function(){te.call(se,re)};else{var oe=!0,ve=document.createTextNode("");new le(re).observe(ve,{characterData:!0}),x=function(){ve.data=oe=!oe}}return function(ye){var me={fn:ye,next:void 0};z&&(z.next=me),b||(b=me,x()),z=me}}},{"./_cof":64,"./_global":76,"./_task":120}],95:[function(ie,Ce,ue){"use strict";function se(le){var ee,ne;this.promise=new le(function(E,b){if(ee!==void 0||ne!==void 0)throw TypeError("Bad Promise constructor");ee=E,ne=b}),this.resolve=te(ee),this.reject=te(ne)}var te=ie("./_a-function");Ce.exports.f=function(le){return new se(le)}},{"./_a-function":58}],96:[function(ie,Ce,ue){"use strict";var se=ie("./_object-keys"),te=ie("./_object-gops"),le=ie("./_object-pie"),ee=ie("./_to-object"),ne=ie("./_iobject"),E=Object.assign;Ce.exports=!E||ie("./_fails")(function(){var b={},z={},x=Symbol(),re="abcdefghijklmnopqrst";return b[x]=7,re.split("").forEach(function(ae){z[ae]=ae}),E({},b)[x]!=7||Object.keys(E({},z)).join("")!=re})?function(b,z){for(var x=ee(b),re=arguments.length,ae=1,oe=te.f,ve=le.f;re>ae;)for(var ye,me=ne(arguments[ae++]),ge=oe?se(me).concat(oe(me)):se(me),_e=ge.length,he=0;_e>he;)ve.call(me,ye=ge[he++])&&(x[ye]=me[ye]);return x}:E},{"./_fails":74,"./_iobject":82,"./_object-gops":103,"./_object-keys":106,"./_object-pie":107,"./_to-object":125}],97:[function(ie,Ce,ue){var se=ie("./_an-object"),te=ie("./_object-dps"),le=ie("./_enum-bug-keys"),ee=ie("./_shared-key")("IE_PROTO"),ne=function(){},E=function(){var b,z=ie("./_dom-create")("iframe"),x=le.length;for(z.style.display="none",ie("./_html").appendChild(z),z.src="javascript:",b=z.contentWindow.document,b.open(),b.write("<script>document.F=Object<\/script>"),b.close(),E=b.F;x--;)delete E.prototype[le[x]];return E()};Ce.exports=Object.create||function(b,z){var x;return b!==null?(ne.prototype=se(b),x=new ne,ne.prototype=null,x[ee]=b):x=E(),z===void 0?x:te(x,z)}},{"./_an-object":61,"./_dom-create":70,"./_enum-bug-keys":71,"./_html":79,"./_object-dps":99,"./_shared-key":116}],98:[function(ie,Ce,ue){var se=ie("./_an-object"),te=ie("./_ie8-dom-define"),le=ie("./_to-primitive"),ee=Object.defineProperty;ue.f=ie("./_descriptors")?Object.defineProperty:function(ne,E,b){if(se(ne),E=le(E,!0),se(b),te)try{return ee(ne,E,b)}catch(z){}if("get"in b||"set"in b)throw TypeError("Accessors not supported!");return"value"in b&&(ne[E]=b.value),ne}},{"./_an-object":61,"./_descriptors":69,"./_ie8-dom-define":80,"./_to-primitive":126}],99:[function(ie,Ce,ue){var se=ie("./_object-dp"),te=ie("./_an-object"),le=ie("./_object-keys");Ce.exports=ie("./_descriptors")?Object.defineProperties:function(ee,ne){te(ee);for(var E,b=le(ne),z=b.length,x=0;z>x;)se.f(ee,E=b[x++],ne[E]);return ee}},{"./_an-object":61,"./_descriptors":69,"./_object-dp":98,"./_object-keys":106}],100:[function(ie,Ce,ue){var se=ie("./_object-pie"),te=ie("./_property-desc"),le=ie("./_to-iobject"),ee=ie("./_to-primitive"),ne=ie("./_has"),E=ie("./_ie8-dom-define"),b=Object.getOwnPropertyDescriptor;ue.f=ie("./_descriptors")?b:function(z,x){if(z=le(z),x=ee(x,!0),E)try{return b(z,x)}catch(re){}if(ne(z,x))return te(!se.f.call(z,x),z[x])}},{"./_descriptors":69,"./_has":77,"./_ie8-dom-define":80,"./_object-pie":107,"./_property-desc":111,"./_to-iobject":123,"./_to-primitive":126}],101:[function(ie,Ce,ue){var se=ie("./_to-iobject"),te=ie("./_object-gopn").f,le={}.toString,ee=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],ne=function(E){try{return te(E)}catch(b){return ee.slice()}};Ce.exports.f=function(E){return ee&&le.call(E)=="[object Window]"?ne(E):te(se(E))}},{"./_object-gopn":102,"./_to-iobject":123}],102:[function(ie,Ce,ue){var se=ie("./_object-keys-internal"),te=ie("./_enum-bug-keys").concat("length","prototype");ue.f=Object.getOwnPropertyNames||function(le){return se(le,te)}},{"./_enum-bug-keys":71,"./_object-keys-internal":105}],103:[function(ie,Ce,ue){ue.f=Object.getOwnPropertySymbols},{}],104:[function(ie,Ce,ue){var se=ie("./_has"),te=ie("./_to-object"),le=ie("./_shared-key")("IE_PROTO"),ee=Object.prototype;Ce.exports=Object.getPrototypeOf||function(ne){return ne=te(ne),se(ne,le)?ne[le]:typeof ne.constructor=="function"&&ne instanceof ne.constructor?ne.constructor.prototype:ne instanceof Object?ee:null}},{"./_has":77,"./_shared-key":116,"./_to-object":125}],105:[function(ie,Ce,ue){var se=ie("./_has"),te=ie("./_to-iobject"),le=ie("./_array-includes")(!1),ee=ie("./_shared-key")("IE_PROTO");Ce.exports=function(ne,E){var b,z=te(ne),x=0,re=[];for(b in z)b!=ee&&se(z,b)&&re.push(b);for(;E.length>x;)se(z,b=E[x++])&&(~le(re,b)||re.push(b));return re}},{"./_array-includes":62,"./_has":77,"./_shared-key":116,"./_to-iobject":123}],106:[function(ie,Ce,ue){var se=ie("./_object-keys-internal"),te=ie("./_enum-bug-keys");Ce.exports=Object.keys||function(le){return se(le,te)}},{"./_enum-bug-keys":71,"./_object-keys-internal":105}],107:[function(ie,Ce,ue){ue.f={}.propertyIsEnumerable},{}],108:[function(ie,Ce,ue){var se=ie("./_export"),te=ie("./_core"),le=ie("./_fails");Ce.exports=function(ee,ne){var E=(te.Object||{})[ee]||Object[ee],b={};b[ee]=ne(E),se(se.S+se.F*le(function(){E(1)}),"Object",b)}},{"./_core":65,"./_export":73,"./_fails":74}],109:[function(ie,Ce,ue){Ce.exports=function(se){try{return{e:!1,v:se()}}catch(te){return{e:!0,v:te}}}},{}],110:[function(ie,Ce,ue){var se=ie("./_an-object"),te=ie("./_is-object"),le=ie("./_new-promise-capability");Ce.exports=function(ee,ne){if(se(ee),te(ne)&&ne.constructor===ee)return ne;var E=le.f(ee);return(0,E.resolve)(ne),E.promise}},{"./_an-object":61,"./_is-object":85,"./_new-promise-capability":95}],111:[function(ie,Ce,ue){Ce.exports=function(se,te){return{enumerable:!(1&se),configurable:!(2&se),writable:!(4&se),value:te}}},{}],112:[function(ie,Ce,ue){var se=ie("./_hide");Ce.exports=function(te,le,ee){for(var ne in le)ee&&te[ne]?te[ne]=le[ne]:se(te,ne,le[ne]);return te}},{"./_hide":78}],113:[function(ie,Ce,ue){Ce.exports=ie("./_hide")},{"./_hide":78}],114:[function(ie,Ce,ue){"use strict";var se=ie("./_global"),te=ie("./_core"),le=ie("./_object-dp"),ee=ie("./_descriptors"),ne=ie("./_wks")("species");Ce.exports=function(E){var b=typeof te[E]=="function"?te[E]:se[E];ee&&b&&!b[ne]&&le.f(b,ne,{configurable:!0,get:function(){return this}})}},{"./_core":65,"./_descriptors":69,"./_global":76,"./_object-dp":98,"./_wks":131}],115:[function(ie,Ce,ue){var se=ie("./_object-dp").f,te=ie("./_has"),le=ie("./_wks")("toStringTag");Ce.exports=function(ee,ne,E){ee&&!te(ee=E?ee:ee.prototype,le)&&se(ee,le,{configurable:!0,value:ne})}},{"./_has":77,"./_object-dp":98,"./_wks":131}],116:[function(ie,Ce,ue){var se=ie("./_shared")("keys"),te=ie("./_uid");Ce.exports=function(le){return se[le]||(se[le]=te(le))}},{"./_shared":117,"./_uid":127}],117:[function(ie,Ce,ue){var se=ie("./_core"),te=ie("./_global"),le=te["__core-js_shared__"]||(te["__core-js_shared__"]={});(Ce.exports=function(ee,ne){return le[ee]||(le[ee]=ne!==void 0?ne:{})})("versions",[]).push({version:se.version,mode:ie("./_library")?"pure":"global",copyright:"\u6F0F 2018 Denis Pushkarev (zloirock.ru)"})},{"./_core":65,"./_global":76,"./_library":92}],118:[function(ie,Ce,ue){var se=ie("./_an-object"),te=ie("./_a-function"),le=ie("./_wks")("species");Ce.exports=function(ee,ne){var E,b=se(ee).constructor;return b===void 0||(E=se(b)[le])==null?ne:te(E)}},{"./_a-function":58,"./_an-object":61,"./_wks":131}],119:[function(ie,Ce,ue){var se=ie("./_to-integer"),te=ie("./_defined");Ce.exports=function(le){return function(ee,ne){var E,b,z=String(te(ee)),x=se(ne),re=z.length;return x<0||x>=re?le?"":void 0:(E=z.charCodeAt(x),E<55296||E>56319||x+1===re||(b=z.charCodeAt(x+1))<56320||b>57343?le?z.charAt(x):E:le?z.slice(x,x+2):b-56320+(E-55296<<10)+65536)}}},{"./_defined":68,"./_to-integer":122}],120:[function(ie,Ce,ue){var se,te,le,ee=ie("./_ctx"),ne=ie("./_invoke"),E=ie("./_html"),b=ie("./_dom-create"),z=ie("./_global"),x=z.process,re=z.setImmediate,ae=z.clearImmediate,oe=z.MessageChannel,ve=z.Dispatch,ye=0,me={},ge=function(){var he=+this;if(me.hasOwnProperty(he)){var pe=me[he];delete me[he],pe()}},_e=function(he){ge.call(he.data)};re&&ae||(re=function(he){for(var pe=[],ke=1;arguments.length>ke;)pe.push(arguments[ke++]);return me[++ye]=function(){ne(typeof he=="function"?he:Function(he),pe)},se(ye),ye},ae=function(he){delete me[he]},ie("./_cof")(x)=="process"?se=function(he){x.nextTick(ee(ge,he,1))}:ve&&ve.now?se=function(he){ve.now(ee(ge,he,1))}:oe?(te=new oe,le=te.port2,te.port1.onmessage=_e,se=ee(le.postMessage,le,1)):z.addEventListener&&typeof postMessage=="function"&&!z.importScripts?(se=function(he){z.postMessage(he+"","*")},z.addEventListener("message",_e,!1)):se="onreadystatechange"in b("script")?function(he){E.appendChild(b("script")).onreadystatechange=function(){E.removeChild(this),ge.call(he)}}:function(he){setTimeout(ee(ge,he,1),0)}),Ce.exports={set:re,clear:ae}},{"./_cof":64,"./_ctx":67,"./_dom-create":70,"./_global":76,"./_html":79,"./_invoke":81}],121:[function(ie,Ce,ue){var se=ie("./_to-integer"),te=Math.max,le=Math.min;Ce.exports=function(ee,ne){return ee=se(ee),ee<0?te(ee+ne,0):le(ee,ne)}},{"./_to-integer":122}],122:[function(ie,Ce,ue){var se=Math.ceil,te=Math.floor;Ce.exports=function(le){return isNaN(le=+le)?0:(le>0?te:se)(le)}},{}],123:[function(ie,Ce,ue){var se=ie("./_iobject"),te=ie("./_defined");Ce.exports=function(le){return se(te(le))}},{"./_defined":68,"./_iobject":82}],124:[function(ie,Ce,ue){var se=ie("./_to-integer"),te=Math.min;Ce.exports=function(le){return le>0?te(se(le),9007199254740991):0}},{"./_to-integer":122}],125:[function(ie,Ce,ue){var se=ie("./_defined");Ce.exports=function(te){return Object(se(te))}},{"./_defined":68}],126:[function(ie,Ce,ue){var se=ie("./_is-object");Ce.exports=function(te,le){if(!se(te))return te;var ee,ne;if(le&&typeof(ee=te.toString)=="function"&&!se(ne=ee.call(te))||typeof(ee=te.valueOf)=="function"&&!se(ne=ee.call(te))||!le&&typeof(ee=te.toString)=="function"&&!se(ne=ee.call(te)))return ne;throw TypeError("Can't convert object to primitive value")}},{"./_is-object":85}],127:[function(ie,Ce,ue){var se=0,te=Math.random();Ce.exports=function(le){return"Symbol(".concat(le===void 0?"":le,")_",(++se+te).toString(36))}},{}],128:[function(ie,Ce,ue){var se=ie("./_global"),te=se.navigator;Ce.exports=te&&te.userAgent||""},{"./_global":76}],129:[function(ie,Ce,ue){var se=ie("./_global"),te=ie("./_core"),le=ie("./_library"),ee=ie("./_wks-ext"),ne=ie("./_object-dp").f;Ce.exports=function(E){var b=te.Symbol||(te.Symbol=le?{}:se.Symbol||{});E.charAt(0)=="_"||E in b||ne(b,E,{value:ee.f(E)})}},{"./_core":65,"./_global":76,"./_library":92,"./_object-dp":98,"./_wks-ext":130}],130:[function(ie,Ce,ue){ue.f=ie("./_wks")},{"./_wks":131}],131:[function(ie,Ce,ue){var se=ie("./_shared")("wks"),te=ie("./_uid"),le=ie("./_global").Symbol,ee=typeof le=="function";(Ce.exports=function(ne){return se[ne]||(se[ne]=ee&&le[ne]||(ee?le:te)("Symbol."+ne))}).store=se},{"./_global":76,"./_shared":117,"./_uid":127}],132:[function(ie,Ce,ue){var se=ie("./_classof"),te=ie("./_wks")("iterator"),le=ie("./_iterators");Ce.exports=ie("./_core").getIteratorMethod=function(ee){if(ee!=null)return ee[te]||ee["@@iterator"]||le[se(ee)]}},{"./_classof":63,"./_core":65,"./_iterators":91,"./_wks":131}],133:[function(ie,Ce,ue){"use strict";var se=ie("./_ctx"),te=ie("./_export"),le=ie("./_to-object"),ee=ie("./_iter-call"),ne=ie("./_is-array-iter"),E=ie("./_to-length"),b=ie("./_create-property"),z=ie("./core.get-iterator-method");te(te.S+te.F*!ie("./_iter-detect")(function(x){Array.from(x)}),"Array",{from:function(x){var re,ae,oe,ve,ye=le(x),me=typeof this=="function"?this:Array,ge=arguments.length,_e=ge>1?arguments[1]:void 0,he=_e!==void 0,pe=0,ke=z(ye);if(he&&(_e=se(_e,ge>2?arguments[2]:void 0,2)),ke==null||me==Array&&ne(ke))for(re=E(ye.length),ae=new me(re);re>pe;pe++)b(ae,pe,he?_e(ye[pe],pe):ye[pe]);else for(ve=ke.call(ye),ae=new me;!(oe=ve.next()).done;pe++)b(ae,pe,he?ee(ve,_e,[oe.value,pe],!0):oe.value);return ae.length=pe,ae}})},{"./_create-property":66,"./_ctx":67,"./_export":73,"./_is-array-iter":83,"./_iter-call":86,"./_iter-detect":89,"./_to-length":124,"./_to-object":125,"./core.get-iterator-method":132}],134:[function(ie,Ce,ue){"use strict";var se=ie("./_add-to-unscopables"),te=ie("./_iter-step"),le=ie("./_iterators"),ee=ie("./_to-iobject");Ce.exports=ie("./_iter-define")(Array,"Array",function(ne,E){this._t=ee(ne),this._i=0,this._k=E},function(){var ne=this._t,E=this._k,b=this._i++;return!ne||b>=ne.length?(this._t=void 0,te(1)):E=="keys"?te(0,b):E=="values"?te(0,ne[b]):te(0,[b,ne[b]])},"values"),le.Arguments=le.Array,se("keys"),se("values"),se("entries")},{"./_add-to-unscopables":59,"./_iter-define":88,"./_iter-step":90,"./_iterators":91,"./_to-iobject":123}],135:[function(ie,Ce,ue){"use strict";var se=ie("./_is-object"),te=ie("./_object-gpo"),le=ie("./_wks")("hasInstance"),ee=Function.prototype;le in ee||ie("./_object-dp").f(ee,le,{value:function(ne){if(typeof this!="function"||!se(ne))return!1;if(!se(this.prototype))return ne instanceof this;for(;ne=te(ne);)if(this.prototype===ne)return!0;return!1}})},{"./_is-object":85,"./_object-dp":98,"./_object-gpo":104,"./_wks":131}],136:[function(ie,Ce,ue){var se=ie("./_export");se(se.S+se.F,"Object",{assign:ie("./_object-assign")})},{"./_export":73,"./_object-assign":96}],137:[function(ie,Ce,ue){var se=ie("./_export");se(se.S,"Object",{create:ie("./_object-create")})},{"./_export":73,"./_object-create":97}],138:[function(ie,Ce,ue){var se=ie("./_export");se(se.S+se.F*!ie("./_descriptors"),"Object",{defineProperty:ie("./_object-dp").f})},{"./_descriptors":69,"./_export":73,"./_object-dp":98}],139:[function(ie,Ce,ue){ie("./_object-sap")("getOwnPropertyNames",function(){return ie("./_object-gopn-ext").f})},{"./_object-gopn-ext":101,"./_object-sap":108}],140:[function(ie,Ce,ue){var se=ie("./_to-object"),te=ie("./_object-gpo");ie("./_object-sap")("getPrototypeOf",function(){return function(le){return te(se(le))}})},{"./_object-gpo":104,"./_object-sap":108,"./_to-object":125}],141:[function(ie,Ce,ue){var se=ie("./_to-object"),te=ie("./_object-keys");ie("./_object-sap")("keys",function(){return function(le){return te(se(le))}})},{"./_object-keys":106,"./_object-sap":108,"./_to-object":125}],142:[function(ie,Ce,ue){arguments[4][36][0].apply(ue,arguments)},{dup:36}],143:[function(ie,Ce,ue){"use strict";var se,te,le,ee,ne=ie("./_library"),E=ie("./_global"),b=ie("./_ctx"),z=ie("./_classof"),x=ie("./_export"),re=ie("./_is-object"),ae=ie("./_a-function"),oe=ie("./_an-instance"),ve=ie("./_for-of"),ye=ie("./_species-constructor"),me=ie("./_task").set,ge=ie("./_microtask")(),_e=ie("./_new-promise-capability"),he=ie("./_perform"),pe=ie("./_user-agent"),ke=ie("./_promise-resolve"),Te=E.TypeError,Ee=E.process,Oe=Ee&&Ee.versions,je=Oe&&Oe.v8||"",Pe=E.Promise,Qe=z(Ee)=="process",Xe=function(){},ot=te=_e.f,He=!!function(){try{var nt=Pe.resolve(1),et=(nt.constructor={})[ie("./_wks")("species")]=function(pt){pt(Xe,Xe)};return(Qe||typeof PromiseRejectionEvent=="function")&&nt.then(Xe)instanceof et&&je.indexOf("6.6")!==0&&pe.indexOf("Chrome/66")===-1}catch(pt){}}(),rt=function(nt){var et;return!(!re(nt)||typeof(et=nt.then)!="function")&&et},Ye=function(nt,et){if(!nt._n){nt._n=!0;var pt=nt._c;ge(function(){for(var ct=nt._v,Ot=nt._s==1,dt=0;pt.length>dt;)(function(Rt){var xt,gt,_t,We=Ot?Rt.ok:Rt.fail,Ae=Rt.resolve,Se=Rt.reject,Be=Rt.domain;try{We?(Ot||(nt._h==2&&ze(nt),nt._h=1),We===!0?xt=ct:(Be&&Be.enter(),xt=We(ct),Be&&(Be.exit(),_t=!0)),xt===Rt.promise?Se(Te("Promise-chain cycle")):(gt=rt(xt))?gt.call(xt,Ae,Se):Ae(xt)):Se(ct)}catch(Ke){Be&&!_t&&Be.exit(),Se(Ke)}})(pt[dt++]);nt._c=[],nt._n=!1,et&&!nt._h&&ut(nt)})}},ut=function(nt){me.call(E,function(){var et,pt,ct,Ot=nt._v,dt=Ge(nt);if(dt&&(et=he(function(){Qe?Ee.emit("unhandledRejection",Ot,nt):(pt=E.onunhandledrejection)?pt({promise:nt,reason:Ot}):(ct=E.console)&&ct.error&&ct.error("Unhandled promise rejection",Ot)}),nt._h=Qe||Ge(nt)?2:1),nt._a=void 0,dt&&et.e)throw et.v})},Ge=function(nt){return nt._h!==1&&(nt._a||nt._c).length===0},ze=function(nt){me.call(E,function(){var et;Qe?Ee.emit("rejectionHandled",nt):(et=E.onrejectionhandled)&&et({promise:nt,reason:nt._v})})},Ve=function(nt){var et=this;et._d||(et._d=!0,et=et._w||et,et._v=nt,et._s=2,et._a||(et._a=et._c.slice()),Ye(et,!0))},$e=function(nt){var et,pt=this;if(!pt._d){pt._d=!0,pt=pt._w||pt;try{if(pt===nt)throw Te("Promise can't be resolved itself");(et=rt(nt))?ge(function(){var ct={_w:pt,_d:!1};try{et.call(nt,b($e,ct,1),b(Ve,ct,1))}catch(Ot){Ve.call(ct,Ot)}}):(pt._v=nt,pt._s=1,Ye(pt,!1))}catch(ct){Ve.call({_w:pt,_d:!1},ct)}}};He||(Pe=function(nt){oe(this,Pe,"Promise","_h"),ae(nt),se.call(this);try{nt(b($e,this,1),b(Ve,this,1))}catch(et){Ve.call(this,et)}},se=function(nt){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},se.prototype=ie("./_redefine-all")(Pe.prototype,{then:function(nt,et){var pt=ot(ye(this,Pe));return pt.ok=typeof nt!="function"||nt,pt.fail=typeof et=="function"&&et,pt.domain=Qe?Ee.domain:void 0,this._c.push(pt),this._a&&this._a.push(pt),this._s&&Ye(this,!1),pt.promise},catch:function(nt){return this.then(void 0,nt)}}),le=function(){var nt=new se;this.promise=nt,this.resolve=b($e,nt,1),this.reject=b(Ve,nt,1)},_e.f=ot=function(nt){return nt===Pe||nt===ee?new le(nt):te(nt)}),x(x.G+x.W+x.F*!He,{Promise:Pe}),ie("./_set-to-string-tag")(Pe,"Promise"),ie("./_set-species")("Promise"),ee=ie("./_core").Promise,x(x.S+x.F*!He,"Promise",{reject:function(nt){var et=ot(this);return(0,et.reject)(nt),et.promise}}),x(x.S+x.F*(ne||!He),"Promise",{resolve:function(nt){return ke(ne&&this===ee?Pe:this,nt)}}),x(x.S+x.F*!(He&&ie("./_iter-detect")(function(nt){Pe.all(nt).catch(Xe)})),"Promise",{all:function(nt){var et=this,pt=ot(et),ct=pt.resolve,Ot=pt.reject,dt=he(function(){var Rt=[],xt=0,gt=1;ve(nt,!1,function(_t){var We=xt++,Ae=!1;Rt.push(void 0),gt++,et.resolve(_t).then(function(Se){Ae||(Ae=!0,Rt[We]=Se,--gt||ct(Rt))},Ot)}),--gt||ct(Rt)});return dt.e&&Ot(dt.v),pt.promise},race:function(nt){var et=this,pt=ot(et),ct=pt.reject,Ot=he(function(){ve(nt,!1,function(dt){et.resolve(dt).then(pt.resolve,ct)})});return Ot.e&&ct(Ot.v),pt.promise}})},{"./_a-function":58,"./_an-instance":60,"./_classof":63,"./_core":65,"./_ctx":67,"./_export":73,"./_for-of":75,"./_global":76,"./_is-object":85,"./_iter-detect":89,"./_library":92,"./_microtask":94,"./_new-promise-capability":95,"./_perform":109,"./_promise-resolve":110,"./_redefine-all":112,"./_set-species":114,"./_set-to-string-tag":115,"./_species-constructor":118,"./_task":120,"./_user-agent":128,"./_wks":131}],144:[function(ie,Ce,ue){var se=ie("./_export"),te=ie("./_to-absolute-index"),le=String.fromCharCode,ee=String.fromCodePoint;se(se.S+se.F*(!!ee&&ee.length!=1),"String",{fromCodePoint:function(ne){for(var E,b=[],z=arguments.length,x=0;z>x;){if(E=+arguments[x++],te(E,1114111)!==E)throw RangeError(E+" is not a valid code point");b.push(E<65536?le(E):le(55296+((E-=65536)>>10),E%1024+56320))}return b.join("")}})},{"./_export":73,"./_to-absolute-index":121}],145:[function(ie,Ce,ue){"use strict";var se=ie("./_string-at")(!0);ie("./_iter-define")(String,"String",function(te){this._t=String(te),this._i=0},function(){var te,le=this._t,ee=this._i;return ee>=le.length?{value:void 0,done:!0}:(te=se(le,ee),this._i+=te.length,{value:te,done:!1})})},{"./_iter-define":88,"./_string-at":119}],146:[function(ie,Ce,ue){"use strict";var se=ie("./_global"),te=ie("./_has"),le=ie("./_descriptors"),ee=ie("./_export"),ne=ie("./_redefine"),E=ie("./_meta").KEY,b=ie("./_fails"),z=ie("./_shared"),x=ie("./_set-to-string-tag"),re=ie("./_uid"),ae=ie("./_wks"),oe=ie("./_wks-ext"),ve=ie("./_wks-define"),ye=ie("./_enum-keys"),me=ie("./_is-array"),ge=ie("./_an-object"),_e=ie("./_is-object"),he=ie("./_to-iobject"),pe=ie("./_to-primitive"),ke=ie("./_property-desc"),Te=ie("./_object-create"),Ee=ie("./_object-gopn-ext"),Oe=ie("./_object-gopd"),je=ie("./_object-dp"),Pe=ie("./_object-keys"),Qe=Oe.f,Xe=je.f,ot=Ee.f,He=se.Symbol,rt=se.JSON,Ye=rt&&rt.stringify,ut=ae("_hidden"),Ge=ae("toPrimitive"),ze={}.propertyIsEnumerable,Ve=z("symbol-registry"),$e=z("symbols"),nt=z("op-symbols"),et=Object.prototype,pt=typeof He=="function",ct=se.QObject,Ot=!ct||!ct.prototype||!ct.prototype.findChild,dt=le&&b(function(){return Te(Xe({},"a",{get:function(){return Xe(this,"a",{value:7}).a}})).a!=7})?function(Ue,Me,Re){var tt=Qe(et,Me);tt&&delete et[Me],Xe(Ue,Me,Re),tt&&Ue!==et&&Xe(et,Me,tt)}:Xe,Rt=function(Ue){var Me=$e[Ue]=Te(He.prototype);return Me._k=Ue,Me},xt=pt&&typeof He.iterator=="symbol"?function(Ue){return typeof Ue=="symbol"}:function(Ue){return Ue instanceof He},gt=function(Ue,Me,Re){return Ue===et&>(nt,Me,Re),ge(Ue),Me=pe(Me,!0),ge(Re),te($e,Me)?(Re.enumerable?(te(Ue,ut)&&Ue[ut][Me]&&(Ue[ut][Me]=!1),Re=Te(Re,{enumerable:ke(0,!1)})):(te(Ue,ut)||Xe(Ue,ut,ke(1,{})),Ue[ut][Me]=!0),dt(Ue,Me,Re)):Xe(Ue,Me,Re)},_t=function(Ue,Me){ge(Ue);for(var Re,tt=ye(Me=he(Me)),lt=0,Nt=tt.length;Nt>lt;)gt(Ue,Re=tt[lt++],Me[Re]);return Ue},We=function(Ue,Me){return Me===void 0?Te(Ue):_t(Te(Ue),Me)},Ae=function(Ue){var Me=ze.call(this,Ue=pe(Ue,!0));return!(this===et&&te($e,Ue)&&!te(nt,Ue))&&(!(Me||!te(this,Ue)||!te($e,Ue)||te(this,ut)&&this[ut][Ue])||Me)},Se=function(Ue,Me){if(Ue=he(Ue),Me=pe(Me,!0),Ue!==et||!te($e,Me)||te(nt,Me)){var Re=Qe(Ue,Me);return!Re||!te($e,Me)||te(Ue,ut)&&Ue[ut][Me]||(Re.enumerable=!0),Re}},Be=function(Ue){for(var Me,Re=ot(he(Ue)),tt=[],lt=0;Re.length>lt;)te($e,Me=Re[lt++])||Me==ut||Me==E||tt.push(Me);return tt},Ke=function(Ue){for(var Me,Re=Ue===et,tt=ot(Re?nt:he(Ue)),lt=[],Nt=0;tt.length>Nt;)!te($e,Me=tt[Nt++])||Re&&!te(et,Me)||lt.push($e[Me]);return lt};pt||(He=function(){if(this instanceof He)throw TypeError("Symbol is not a constructor!");var Ue=re(arguments.length>0?arguments[0]:void 0),Me=function(Re){this===et&&Me.call(nt,Re),te(this,ut)&&te(this[ut],Ue)&&(this[ut][Ue]=!1),dt(this,Ue,ke(1,Re))};return le&&Ot&&dt(et,Ue,{configurable:!0,set:Me}),Rt(Ue)},ne(He.prototype,"toString",function(){return this._k}),Oe.f=Se,je.f=gt,ie("./_object-gopn").f=Ee.f=Be,ie("./_object-pie").f=Ae,ie("./_object-gops").f=Ke,le&&!ie("./_library")&&ne(et,"propertyIsEnumerable",Ae,!0),oe.f=function(Ue){return Rt(ae(Ue))}),ee(ee.G+ee.W+ee.F*!pt,{Symbol:He});for(var Ne="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),De=0;Ne.length>De;)ae(Ne[De++]);for(var we=Pe(ae.store),Le=0;we.length>Le;)ve(we[Le++]);ee(ee.S+ee.F*!pt,"Symbol",{for:function(Ue){return te(Ve,Ue+="")?Ve[Ue]:Ve[Ue]=He(Ue)},keyFor:function(Ue){if(!xt(Ue))throw TypeError(Ue+" is not a symbol!");for(var Me in Ve)if(Ve[Me]===Ue)return Me},useSetter:function(){Ot=!0},useSimple:function(){Ot=!1}}),ee(ee.S+ee.F*!pt,"Object",{create:We,defineProperty:gt,defineProperties:_t,getOwnPropertyDescriptor:Se,getOwnPropertyNames:Be,getOwnPropertySymbols:Ke}),rt&&ee(ee.S+ee.F*(!pt||b(function(){var Ue=He();return Ye([Ue])!="[null]"||Ye({a:Ue})!="{}"||Ye(Object(Ue))!="{}"})),"JSON",{stringify:function(Ue){for(var Me,Re,tt=[Ue],lt=1;arguments.length>lt;)tt.push(arguments[lt++]);if(Re=Me=tt[1],(_e(Me)||Ue!==void 0)&&!xt(Ue))return me(Me)||(Me=function(Nt,Ct){if(typeof Re=="function"&&(Ct=Re.call(this,Nt,Ct)),!xt(Ct))return Ct}),tt[1]=Me,Ye.apply(rt,tt)}}),He.prototype[Ge]||ie("./_hide")(He.prototype,Ge,He.prototype.valueOf),x(He,"Symbol"),x(Math,"Math",!0),x(se.JSON,"JSON",!0)},{"./_an-object":61,"./_descriptors":69,"./_enum-keys":72,"./_export":73,"./_fails":74,"./_global":76,"./_has":77,"./_hide":78,"./_is-array":84,"./_is-object":85,"./_library":92,"./_meta":93,"./_object-create":97,"./_object-dp":98,"./_object-gopd":100,"./_object-gopn":102,"./_object-gopn-ext":101,"./_object-gops":103,"./_object-keys":106,"./_object-pie":107,"./_property-desc":111,"./_redefine":113,"./_set-to-string-tag":115,"./_shared":117,"./_to-iobject":123,"./_to-primitive":126,"./_uid":127,"./_wks":131,"./_wks-define":129,"./_wks-ext":130}],147:[function(ie,Ce,ue){"use strict";var se=ie("./_export"),te=ie("./_core"),le=ie("./_global"),ee=ie("./_species-constructor"),ne=ie("./_promise-resolve");se(se.P+se.R,"Promise",{finally:function(E){var b=ee(this,te.Promise||le.Promise),z=typeof E=="function";return this.then(z?function(x){return ne(b,E()).then(function(){return x})}:E,z?function(x){return ne(b,E()).then(function(){throw x})}:E)}})},{"./_core":65,"./_export":73,"./_global":76,"./_promise-resolve":110,"./_species-constructor":118}],148:[function(ie,Ce,ue){"use strict";var se=ie("./_export"),te=ie("./_new-promise-capability"),le=ie("./_perform");se(se.S,"Promise",{try:function(ee){var ne=te.f(this),E=le(ee);return(E.e?ne.reject:ne.resolve)(E.v),ne.promise}})},{"./_export":73,"./_new-promise-capability":95,"./_perform":109}],149:[function(ie,Ce,ue){ie("./_wks-define")("asyncIterator")},{"./_wks-define":129}],150:[function(ie,Ce,ue){ie("./_wks-define")("observable")},{"./_wks-define":129}],151:[function(ie,Ce,ue){ie("./es6.array.iterator");for(var se=ie("./_global"),te=ie("./_hide"),le=ie("./_iterators"),ee=ie("./_wks")("toStringTag"),ne="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(","),E=0;E<ne.length;E++){var b=ne[E],z=se[b],x=z&&z.prototype;x&&!x[ee]&&te(x,ee,b),le[b]=le.Array}},{"./_global":76,"./_hide":78,"./_iterators":91,"./_wks":131,"./es6.array.iterator":134}],152:[function(ie,Ce,ue){var se=ie("./_export"),te=ie("./_task");se(se.G+se.B,{setImmediate:te.set,clearImmediate:te.clear})},{"./_export":73,"./_task":120}],153:[function(ie,Ce,ue){(function(se){"use strict";function te(pe){return Array.isArray?Array.isArray(pe):ge(pe)==="[object Array]"}function le(pe){return typeof pe=="boolean"}function ee(pe){return pe===null}function ne(pe){return pe==null}function E(pe){return typeof pe=="number"}function b(pe){return typeof pe=="string"}function z(pe){return(pe===void 0?"undefined":(0,he.default)(pe))==="symbol"}function x(pe){return pe===void 0}function re(pe){return ge(pe)==="[object RegExp]"}function ae(pe){return(pe===void 0?"undefined":(0,he.default)(pe))==="object"&&pe!==null}function oe(pe){return ge(pe)==="[object Date]"}function ve(pe){return ge(pe)==="[object Error]"||pe instanceof Error}function ye(pe){return typeof pe=="function"}function me(pe){return pe===null||typeof pe=="boolean"||typeof pe=="number"||typeof pe=="string"||(pe===void 0?"undefined":(0,he.default)(pe))==="symbol"||pe===void 0}function ge(pe){return Object.prototype.toString.call(pe)}var _e=ie("babel-runtime/helpers/typeof"),he=function(pe){return pe&&pe.__esModule?pe:{default:pe}}(_e);ue.isArray=te,ue.isBoolean=le,ue.isNull=ee,ue.isNullOrUndefined=ne,ue.isNumber=E,ue.isString=b,ue.isSymbol=z,ue.isUndefined=x,ue.isRegExp=re,ue.isObject=ae,ue.isDate=oe,ue.isError=ve,ue.isFunction=ye,ue.isPrimitive=me,ue.isBuffer=se.isBuffer}).call(this,{isBuffer:ie("../../is-buffer/index.js")})},{"../../is-buffer/index.js":163,"babel-runtime/helpers/typeof":32}],154:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/helpers/typeof"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(le){function ee(x,re){for(x=String(x),re=re||2;x.length<re;)x="0"+x;return x}function ne(x){var re=new Date(x.getFullYear(),x.getMonth(),x.getDate());re.setDate(re.getDate()-(re.getDay()+6)%7+3);var ae=new Date(re.getFullYear(),0,4);ae.setDate(ae.getDate()-(ae.getDay()+6)%7+3);var oe=re.getTimezoneOffset()-ae.getTimezoneOffset();re.setHours(re.getHours()-oe);var ve=(re-ae)/6048e5;return 1+Math.floor(ve)}function E(x){var re=x.getDay();return re===0&&(re=7),re}function b(x){return x===null?"null":x===void 0?"undefined":(x===void 0?"undefined":(0,te.default)(x))!=="object"?x===void 0?"undefined":(0,te.default)(x):Array.isArray(x)?"array":{}.toString.call(x).slice(8,-1).toLowerCase()}var z=function(){var x=/d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZWN]|'[^']*'|'[^']*'/g,re=/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,ae=/[^-+\dA-Z]/g;return function(oe,ve,ye,me){if(arguments.length!==1||b(oe)!=="string"||/\d/.test(oe)||(ve=oe,oe=void 0),oe=oe||new Date,oe instanceof Date||(oe=new Date(oe)),isNaN(oe))throw TypeError("Invalid date");ve=String(z.masks[ve]||ve||z.masks.default);var ge=ve.slice(0,4);ge!=="UTC:"&&ge!=="GMT:"||(ve=ve.slice(4),ye=!0,ge==="GMT:"&&(me=!0));var _e=ye?"getUTC":"get",he=oe[_e+"Date"](),pe=oe[_e+"Day"](),ke=oe[_e+"Month"](),Te=oe[_e+"FullYear"](),Ee=oe[_e+"Hours"](),Oe=oe[_e+"Minutes"](),je=oe[_e+"Seconds"](),Pe=oe[_e+"Milliseconds"](),Qe=ye?0:oe.getTimezoneOffset(),Xe=ne(oe),ot=E(oe),He={d:he,dd:ee(he),ddd:z.i18n.dayNames[pe],dddd:z.i18n.dayNames[pe+7],m:ke+1,mm:ee(ke+1),mmm:z.i18n.monthNames[ke],mmmm:z.i18n.monthNames[ke+12],yy:String(Te).slice(2),yyyy:Te,h:Ee%12||12,hh:ee(Ee%12||12),H:Ee,HH:ee(Ee),M:Oe,MM:ee(Oe),s:je,ss:ee(je),l:ee(Pe,3),L:ee(Math.round(Pe/10)),t:Ee<12?"a":"p",tt:Ee<12?"am":"pm",T:Ee<12?"A":"P",TT:Ee<12?"AM":"PM",Z:me?"GMT":ye?"UTC":(String(oe).match(re)||[""]).pop().replace(ae,""),o:(Qe>0?"-":"+")+ee(100*Math.floor(Math.abs(Qe)/60)+Math.abs(Qe)%60,4),S:["th","st","nd","rd"][he%10>3?0:(he%100-he%10!=10)*he%10],W:Xe,N:ot};return ve.replace(x,function(rt){return rt in He?He[rt]:rt.slice(1,rt.length-1)})}}();z.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"},z.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"]},typeof ce=="function"&&ce.amd?ce(function(){return z}):(ue===void 0?"undefined":(0,te.default)(ue))==="object"?Ce.exports=z:le.dateFormat=z})(void 0)},{"babel-runtime/helpers/typeof":32}],155:[function(ie,Ce,ue){(function(se){function te(){return!(typeof window=="undefined"||!window.process||window.process.type!=="renderer")||typeof document!="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function le(b){var z=this.useColors;if(b[0]=(z?"%c":"")+this.namespace+(z?" %c":" ")+b[0]+(z?"%c ":" ")+"+"+ue.humanize(this.diff),z){var x="color: "+this.color;b.splice(1,0,x,"color: inherit");var re=0,ae=0;b[0].replace(/%[a-zA-Z%]/g,function(oe){oe!=="%%"&&(re++,oe==="%c"&&(ae=re))}),b.splice(ae,0,x)}}function ee(){return typeof console=="object"&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function ne(b){try{b==null?ue.storage.removeItem("debug"):ue.storage.debug=b}catch(z){}}function E(){var b;try{b=ue.storage.debug}catch(z){}return!b&&se!==void 0&&"env"in se&&(b=se.env.DEBUG),b}ue=Ce.exports=ie("./debug"),ue.log=ee,ue.formatArgs=le,ue.save=ne,ue.load=E,ue.useColors=te,ue.storage=typeof chrome!="undefined"&&chrome.storage!==void 0?chrome.storage.local:function(){try{return window.localStorage}catch(b){}}(),ue.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],ue.formatters.j=function(b){try{return JSON.stringify(b)}catch(z){return"[UnexpectedJSONParseError]: "+z.message}},ue.enable(E())}).call(this,ie("_process"))},{"./debug":156,_process:173}],156:[function(ie,Ce,ue){function se(z){var x,re=0;for(x in z)re=(re<<5)-re+z.charCodeAt(x),re|=0;return ue.colors[Math.abs(re)%ue.colors.length]}function te(z){function x(){if(x.enabled){var re=x,ae=+new Date,oe=ae-(b||ae);re.diff=oe,re.prev=b,re.curr=ae,b=ae;for(var ve=new Array(arguments.length),ye=0;ye<ve.length;ye++)ve[ye]=arguments[ye];ve[0]=ue.coerce(ve[0]),typeof ve[0]!="string"&&ve.unshift("%O");var me=0;ve[0]=ve[0].replace(/%([a-zA-Z%])/g,function(ge,_e){if(ge==="%%")return ge;me++;var he=ue.formatters[_e];if(typeof he=="function"){var pe=ve[me];ge=he.call(re,pe),ve.splice(me,1),me--}return ge}),ue.formatArgs.call(re,ve),(x.log||ue.log||console.log.bind(console)).apply(re,ve)}}return x.namespace=z,x.enabled=ue.enabled(z),x.useColors=ue.useColors(),x.color=se(z),typeof ue.init=="function"&&ue.init(x),x}function le(z){ue.save(z),ue.names=[],ue.skips=[];for(var x=(typeof z=="string"?z:"").split(/[\s,]+/),re=x.length,ae=0;ae<re;ae++)x[ae]&&(z=x[ae].replace(/\*/g,".*?"),z[0]==="-"?ue.skips.push(new RegExp("^"+z.substr(1)+"$")):ue.names.push(new RegExp("^"+z+"$")))}function ee(){ue.enable("")}function ne(z){var x,re;for(x=0,re=ue.skips.length;x<re;x++)if(ue.skips[x].test(z))return!1;for(x=0,re=ue.names.length;x<re;x++)if(ue.names[x].test(z))return!0;return!1}function E(z){return z instanceof Error?z.stack||z.message:z}ue=Ce.exports=te.debug=te.default=te,ue.coerce=E,ue.disable=ee,ue.enable=le,ue.enabled=ne,ue.humanize=ie("ms"),ue.names=[],ue.skips=[],ue.formatters={};var b},{ms:169}],157:[function(ie,Ce,ue){"use strict";function se(le){var ee=""+le,ne=te.exec(ee);if(!ne)return ee;var E,b="",z=0,x=0;for(z=ne.index;z<ee.length;z++){switch(ee.charCodeAt(z)){case 34:E=""";break;case 38:E="&";break;case 39:E="'";break;case 60:E="<";break;case 62:E=">";break;default:continue}x!==z&&(b+=ee.substring(x,z)),x=z+1,b+=E}return x!==z?b+ee.substring(x,z):b}var te=/["'&<>]/;Ce.exports=se},{}],158:[function(ie,Ce,ue){function se(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function te(E){return typeof E=="function"}function le(E){return typeof E=="number"}function ee(E){return typeof E=="object"&&E!==null}function ne(E){return E===void 0}Ce.exports=se,se.EventEmitter=se,se.prototype._events=void 0,se.prototype._maxListeners=void 0,se.defaultMaxListeners=10,se.prototype.setMaxListeners=function(E){if(!le(E)||E<0||isNaN(E))throw TypeError("n must be a positive number");return this._maxListeners=E,this},se.prototype.emit=function(E){var b,z,x,re,ae,oe;if(this._events||(this._events={}),E==="error"&&(!this._events.error||ee(this._events.error)&&!this._events.error.length)){if((b=arguments[1])instanceof Error)throw b;var ve=new Error('Uncaught, unspecified "error" event. ('+b+")");throw ve.context=b,ve}if(z=this._events[E],ne(z))return!1;if(te(z))switch(arguments.length){case 1:z.call(this);break;case 2:z.call(this,arguments[1]);break;case 3:z.call(this,arguments[1],arguments[2]);break;default:re=Array.prototype.slice.call(arguments,1),z.apply(this,re)}else if(ee(z))for(re=Array.prototype.slice.call(arguments,1),oe=z.slice(),x=oe.length,ae=0;ae<x;ae++)oe[ae].apply(this,re);return!0},se.prototype.addListener=function(E,b){var z;if(!te(b))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",E,te(b.listener)?b.listener:b),this._events[E]?ee(this._events[E])?this._events[E].push(b):this._events[E]=[this._events[E],b]:this._events[E]=b,ee(this._events[E])&&!this._events[E].warned&&(z=ne(this._maxListeners)?se.defaultMaxListeners:this._maxListeners)&&z>0&&this._events[E].length>z&&(this._events[E].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[E].length),typeof console.trace=="function"&&console.trace()),this},se.prototype.on=se.prototype.addListener,se.prototype.once=function(E,b){function z(){this.removeListener(E,z),x||(x=!0,b.apply(this,arguments))}if(!te(b))throw TypeError("listener must be a function");var x=!1;return z.listener=b,this.on(E,z),this},se.prototype.removeListener=function(E,b){var z,x,re,ae;if(!te(b))throw TypeError("listener must be a function");if(!this._events||!this._events[E])return this;if(z=this._events[E],re=z.length,x=-1,z===b||te(z.listener)&&z.listener===b)delete this._events[E],this._events.removeListener&&this.emit("removeListener",E,b);else if(ee(z)){for(ae=re;ae-- >0;)if(z[ae]===b||z[ae].listener&&z[ae].listener===b){x=ae;break}if(x<0)return this;z.length===1?(z.length=0,delete this._events[E]):z.splice(x,1),this._events.removeListener&&this.emit("removeListener",E,b)}return this},se.prototype.removeAllListeners=function(E){var b,z;if(!this._events)return this;if(!this._events.removeListener)return arguments.length===0?this._events={}:this._events[E]&&delete this._events[E],this;if(arguments.length===0){for(b in this._events)b!=="removeListener"&&this.removeAllListeners(b);return this.removeAllListeners("removeListener"),this._events={},this}if(z=this._events[E],te(z))this.removeListener(E,z);else if(z)for(;z.length;)this.removeListener(E,z[z.length-1]);return delete this._events[E],this},se.prototype.listeners=function(E){return this._events&&this._events[E]?te(this._events[E])?[this._events[E]]:this._events[E].slice():[]},se.prototype.listenerCount=function(E){if(this._events){var b=this._events[E];if(te(b))return 1;if(b)return b.length}return 0},se.listenerCount=function(E,b){return E.listenerCount(b)}},{}],159:[function(ie,Ce,ue){var se=ie("http"),te=Ce.exports;for(var le in se)se.hasOwnProperty(le)&&(te[le]=se[le]);te.request=function(ee,ne){return ee||(ee={}),ee.scheme="https",ee.protocol="https:",se.request.call(this,ee,ne)}},{http:196}],160:[function(ie,Ce,ue){"use strict";var se=ie("util"),te=ie("ms");Ce.exports=function(le){if(typeof le=="number")return le;var ee=te(le);if(ee===void 0){var ne=new Error(se.format("humanize-ms(%j) result undefined",le));console.warn(ne.stack)}return ee}},{ms:169,util:207}],161:[function(ie,Ce,ue){ue.read=function(se,te,le,ee,ne){var E,b,z=8*ne-ee-1,x=(1<<z)-1,re=x>>1,ae=-7,oe=le?ne-1:0,ve=le?-1:1,ye=se[te+oe];for(oe+=ve,E=ye&(1<<-ae)-1,ye>>=-ae,ae+=z;ae>0;E=256*E+se[te+oe],oe+=ve,ae-=8);for(b=E&(1<<-ae)-1,E>>=-ae,ae+=ee;ae>0;b=256*b+se[te+oe],oe+=ve,ae-=8);if(E===0)E=1-re;else{if(E===x)return b?NaN:1/0*(ye?-1:1);b+=Math.pow(2,ee),E-=re}return(ye?-1:1)*b*Math.pow(2,E-ee)},ue.write=function(se,te,le,ee,ne,E){var b,z,x,re=8*E-ne-1,ae=(1<<re)-1,oe=ae>>1,ve=ne===23?Math.pow(2,-24)-Math.pow(2,-77):0,ye=ee?0:E-1,me=ee?1:-1,ge=te<0||te===0&&1/te<0?1:0;for(te=Math.abs(te),isNaN(te)||te===1/0?(z=isNaN(te)?1:0,b=ae):(b=Math.floor(Math.log(te)/Math.LN2),te*(x=Math.pow(2,-b))<1&&(b--,x*=2),te+=b+oe>=1?ve/x:ve*Math.pow(2,1-oe),te*x>=2&&(b++,x/=2),b+oe>=ae?(z=0,b=ae):b+oe>=1?(z=(te*x-1)*Math.pow(2,ne),b+=oe):(z=te*Math.pow(2,oe-1)*Math.pow(2,ne),b=0));ne>=8;se[le+ye]=255&z,ye+=me,z/=256,ne-=8);for(b=b<<ne|z,re+=ne;re>0;se[le+ye]=255&b,ye+=me,b/=256,re-=8);se[le+ye-me]|=128*ge}},{}],162:[function(ie,Ce,ue){typeof Object.create=="function"?Ce.exports=function(se,te){se.super_=te,se.prototype=Object.create(te.prototype,{constructor:{value:se,enumerable:!1,writable:!0,configurable:!0}})}:Ce.exports=function(se,te){se.super_=te;var le=function(){};le.prototype=te.prototype,se.prototype=new le,se.prototype.constructor=se}},{}],163:[function(ie,Ce,ue){function se(le){return!!le.constructor&&typeof le.constructor.isBuffer=="function"&&le.constructor.isBuffer(le)}function te(le){return typeof le.readFloatLE=="function"&&typeof le.slice=="function"&&se(le.slice(0,0))}Ce.exports=function(le){return le!=null&&(se(le)||te(le)||!!le._isBuffer)}},{}],164:[function(ie,Ce,ue){(function(se){function te(ne){return ee.call(ne).replace(/^[^{]*{\s*/,"").replace(/\s*}[^}]*$/,"")}function le(ne){return typeof ne=="function"&&(/^class(\s|\{\}$)/.test(ee.call(ne))||/^.*classCallCheck\(/.test(te(ne)))}var ee=Function.prototype.toString;ue!==void 0?(Ce!==void 0&&Ce.exports&&(ue=Ce.exports=le),ue.isClass=le):typeof ce=="function"&&ce.amd?ce([],function(){return le}):se.isClass=le})(this)},{}],165:[function(ie,Ce,ue){"use strict";function se(E){var b=E.slice(2);return b=b[0].toLowerCase()+b.slice(1)}var te=ie("core-util-is"),le=ie("isstream"),ee=ie("is-class");Object.keys(te).map(function(E){ue[se(E)]=te[E]}),ue.stream=le,ue.readableStream=le.isReadable,ue.writableStream=le.isWritable,ue.duplexStream=le.isDuplex,ue.class=ee,ue.finite=function(E){return Number.isFinite(E)},ue.NaN=function(E){return Number.isNaN(E)},ue.generator=function(E){return E&&typeof E.next=="function"&&typeof E.throw=="function"},ue.generatorFunction=function(E){return E&&E.constructor&&E.constructor.name==="GeneratorFunction"},ue.asyncFunction=function(E){return E&&E.constructor&&E.constructor.name==="AsyncFunction"},ue.promise=function(E){return E&&typeof E.then=="function"};var ne=Math.pow(2,31);ue.int=function(E){return te.isNumber(E)&&E%1==0},ue.int32=function(E){return ue.int(E)&&E<ne&&E>=-ne},ue.long=function(E){return ue.int(E)&&(E>=ne||E<-ne)},ue.Long=function(E){return ue.object(E)&&ue.number(E.high)&&ue.number(E.low)},ue.double=function(E){return te.isNumber(E)&&!isNaN(E)&&E%1!=0},ue.date=function(E){return E instanceof Date},ue.regExp=function(E){return E instanceof RegExp},ue.regexp=ue.regExp,ue.error=function(E){return E instanceof Error},ue.array=function(E){return Array.isArray(E)}},{"core-util-is":153,"is-class":164,isstream:167}],166:[function(ie,Ce,ue){var se={}.toString;Ce.exports=Array.isArray||function(te){return se.call(te)=="[object Array]"}},{}],167:[function(ie,Ce,ue){function se(E){return E instanceof ne.Stream}function te(E){return se(E)&&typeof E._read=="function"&&typeof E._readableState=="object"}function le(E){return se(E)&&typeof E._write=="function"&&typeof E._writableState=="object"}function ee(E){return te(E)&&le(E)}var ne=ie("stream");Ce.exports=se,Ce.exports.isReadable=te,Ce.exports.isWritable=le,Ce.exports.isDuplex=ee},{stream:195}],168:[function(ie,Ce,ue){"use strict";function se(le,ee,ne){if(!le)throw new TypeError("argument dest is required");if(!ee)throw new TypeError("argument src is required");return ne===void 0&&(ne=!0),Object.getOwnPropertyNames(ee).forEach(function(E){if(ne||!te.call(le,E)){var b=Object.getOwnPropertyDescriptor(ee,E);Object.defineProperty(le,E,b)}}),le}Ce.exports=se;var te=Object.prototype.hasOwnProperty},{}],169:[function(ie,Ce,ue){function se(re){if(re=String(re),!(re.length>100)){var ae=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(re);if(ae){var oe=parseFloat(ae[1]);switch((ae[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return oe*x;case"days":case"day":case"d":return oe*z;case"hours":case"hour":case"hrs":case"hr":case"h":return oe*b;case"minutes":case"minute":case"mins":case"min":case"m":return oe*E;case"seconds":case"second":case"secs":case"sec":case"s":return oe*ne;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return oe;default:return}}}}function te(re){return re>=z?Math.round(re/z)+"d":re>=b?Math.round(re/b)+"h":re>=E?Math.round(re/E)+"m":re>=ne?Math.round(re/ne)+"s":re+"ms"}function le(re){return ee(re,z,"day")||ee(re,b,"hour")||ee(re,E,"minute")||ee(re,ne,"second")||re+" ms"}function ee(re,ae,oe){if(!(re<ae))return re<1.5*ae?Math.floor(re/ae)+" "+oe:Math.ceil(re/ae)+" "+oe+"s"}var ne=1e3,E=60*ne,b=60*E,z=24*b,x=365.25*z;Ce.exports=function(re,ae){ae=ae||{};var oe=typeof re;if(oe==="string"&&re.length>0)return se(re);if(oe==="number"&&isNaN(re)===!1)return ae.long?le(re):te(re);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(re))}},{}],170:[function(ie,Ce,ue){(function(se){function te(E,b){for(var z=0,x=E.length-1;x>=0;x--){var re=E[x];re==="."?E.splice(x,1):re===".."?(E.splice(x,1),z++):z&&(E.splice(x,1),z--)}if(b)for(;z--;z)E.unshift("..");return E}function le(E){typeof E!="string"&&(E+="");var b,z=0,x=-1,re=!0;for(b=E.length-1;b>=0;--b)if(E.charCodeAt(b)===47){if(!re){z=b+1;break}}else x===-1&&(re=!1,x=b+1);return x===-1?"":E.slice(z,x)}function ee(E,b){if(E.filter)return E.filter(b);for(var z=[],x=0;x<E.length;x++)b(E[x],x,E)&&z.push(E[x]);return z}ue.resolve=function(){for(var E="",b=!1,z=arguments.length-1;z>=-1&&!b;z--){var x=z>=0?arguments[z]:se.cwd();if(typeof x!="string")throw new TypeError("Arguments to path.resolve must be strings");x&&(E=x+"/"+E,b=x.charAt(0)==="/")}return E=te(ee(E.split("/"),function(re){return!!re}),!b).join("/"),(b?"/":"")+E||"."},ue.normalize=function(E){var b=ue.isAbsolute(E),z=ne(E,-1)==="/";return E=te(ee(E.split("/"),function(x){return!!x}),!b).join("/"),E||b||(E="."),E&&z&&(E+="/"),(b?"/":"")+E},ue.isAbsolute=function(E){return E.charAt(0)==="/"},ue.join=function(){var E=Array.prototype.slice.call(arguments,0);return ue.normalize(ee(E,function(b,z){if(typeof b!="string")throw new TypeError("Arguments to path.join must be strings");return b}).join("/"))},ue.relative=function(E,b){function z(me){for(var ge=0;ge<me.length&&me[ge]==="";ge++);for(var _e=me.length-1;_e>=0&&me[_e]==="";_e--);return ge>_e?[]:me.slice(ge,_e-ge+1)}E=ue.resolve(E).substr(1),b=ue.resolve(b).substr(1);for(var x=z(E.split("/")),re=z(b.split("/")),ae=Math.min(x.length,re.length),oe=ae,ve=0;ve<ae;ve++)if(x[ve]!==re[ve]){oe=ve;break}for(var ye=[],ve=oe;ve<x.length;ve++)ye.push("..");return ye=ye.concat(re.slice(oe)),ye.join("/")},ue.sep="/",ue.delimiter=":",ue.dirname=function(E){if(typeof E!="string"&&(E+=""),E.length===0)return".";for(var b=E.charCodeAt(0),z=b===47,x=-1,re=!0,ae=E.length-1;ae>=1;--ae)if((b=E.charCodeAt(ae))===47){if(!re){x=ae;break}}else re=!1;return x===-1?z?"/":".":z&&x===1?"/":E.slice(0,x)},ue.basename=function(E,b){var z=le(E);return b&&z.substr(-1*b.length)===b&&(z=z.substr(0,z.length-b.length)),z},ue.extname=function(E){typeof E!="string"&&(E+="");for(var b=-1,z=0,x=-1,re=!0,ae=0,oe=E.length-1;oe>=0;--oe){var ve=E.charCodeAt(oe);if(ve!==47)x===-1&&(re=!1,x=oe+1),ve===46?b===-1?b=oe:ae!==1&&(ae=1):b!==-1&&(ae=-1);else if(!re){z=oe+1;break}}return b===-1||x===-1||ae===0||ae===1&&b===x-1&&b===z+1?"":E.slice(b,x)};var ne=function(E,b,z){return E.substr(b,z)}}).call(this,ie("_process"))},{_process:173}],171:[function(ie,Ce,ue){(function(se){(function(){"use strict";function te(je){return je=String(je),je.charAt(0).toUpperCase()+je.slice(1)}function le(je,Pe,Qe){var Xe={"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 Pe&&Qe&&/^Win/i.test(je)&&!/^Windows Phone /i.test(je)&&(Xe=Xe[/[\d.]+$/.exec(je)])&&(je="Windows "+Xe),je=String(je),Pe&&Qe&&(je=je.replace(RegExp(Pe,"i"),Qe)),je=ne(je.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])}function ee(je,Pe){var Qe=-1,Xe=je?je.length:0;if(typeof Xe=="number"&&Xe>-1&&Xe<=he)for(;++Qe<Xe;)Pe(je[Qe],Qe,je);else E(je,Pe)}function ne(je){return je=ae(je),/^(?:webOS|i(?:OS|P))/.test(je)?je:te(je)}function E(je,Pe){for(var Qe in je)Te.call(je,Qe)&&Pe(je[Qe],Qe,je)}function b(je){return je==null?te(je):Ee.call(je).slice(8,-1)}function z(je,Pe){var Qe=je!=null?typeof je[Pe]:"number";return!(/^(?:boolean|number|string|undefined)$/.test(Qe)||Qe=="object"&&!je[Pe])}function x(je){return String(je).replace(/([ -])(?!$)/g,"$1?")}function re(je,Pe){var Qe=null;return ee(je,function(Xe,ot){Qe=Pe(Qe,Xe,ot,je)}),Qe}function ae(je){return String(je).replace(/^ +| +$/g,"")}function oe(je){function Pe(Ue){return re(Ue,function(Me,Re){var tt=Re.pattern||x(Re);return!Me&&(Me=RegExp("\\b"+tt+" *\\d+[.\\w_]*","i").exec(je)||RegExp("\\b"+tt+" *\\w+-[\\w]*","i").exec(je)||RegExp("\\b"+tt+"(?:; *(?:[a-z]+[_-])?[a-z]+\\d+|[^ ();-]*)","i").exec(je))&&((Me=String(Re.label&&!RegExp(tt,"i").test(Re.label)?Re.label:Me).split("/"))[1]&&!/[\d.]+/.test(Me[0])&&(Me[0]+=" "+Me[1]),Re=Re.label||Re,Me=ne(Me[0].replace(RegExp(tt,"i"),Re).replace(RegExp("; *(?:"+Re+"[_-])?","i")," ").replace(RegExp("("+Re+")[-_.]?(\\w)","i"),"$1 $2"))),Me})}function Qe(){return this.description||""}var Xe=ye,ot=je&&typeof je=="object"&&b(je)!="String";ot&&(Xe=je,je=null);var He=Xe.navigator||{},rt=He.userAgent||"";je||(je=rt);var Ye,ut,Ge=ot?!!He.likeChrome:/\bChrome\b/.test(je)&&!/internal|\n/i.test(Ee.toString()),ze=ot?"Object":"ScriptBridgingProxyObject",Ve=ot?"Object":"Environment",$e=ot&&Xe.java?"JavaPackage":b(Xe.java),nt=ot?"Object":"RuntimeObject",et=/\bJava/.test($e)&&Xe.java,pt=et&&b(Xe.environment)==Ve,ct=et?"a":"\u4F2A",Ot=et?"b":"\u5C3E",dt=Xe.document||{},Rt=Xe.operamini||Xe.opera,xt=pe.test(xt=ot&&Rt?Rt["[[Class]]"]:b(Rt))?xt:Rt=null,gt=je,_t=[],We=null,Ae=je==rt,Se=Ae&&Rt&&typeof Rt.version=="function"&&Rt.version(),Be=function(Ue){return re(Ue,function(Me,Re){return Me||RegExp("\\b"+(Re.pattern||x(Re))+"\\b","i").exec(je)&&(Re.label||Re)})}([{label:"EdgeHTML",pattern:"Edge"},"Trident",{label:"WebKit",pattern:"AppleWebKit"},"iCab","Presto","NetFront","Tasman","KHTML","Gecko"]),Ke=function(Ue){return re(Ue,function(Me,Re){return Me||RegExp("\\b"+(Re.pattern||x(Re))+"\\b","i").exec(je)&&(Re.label||Re)})}(["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"]),Ne=Pe([{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"]),De=function(Ue){return re(Ue,function(Me,Re,tt){return Me||(Re[Ne]||Re[/^[a-z]+(?: +[a-z]+\b)*/i.exec(Ne)]||RegExp("\\b"+x(tt)+"(?:\\b|\\w*\\d)","i").exec(je))&&tt})}({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}}),we=function(Ue){return re(Ue,function(Me,Re){var tt=Re.pattern||x(Re);return!Me&&(Me=RegExp("\\b"+tt+"(?:/[\\d.]+|[ \\w.]*)","i").exec(je))&&(Me=le(Me,tt,Re.label||Re)),Me})}(["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 "]);if(Be&&(Be=[Be]),De&&!Ne&&(Ne=Pe([De])),(Ye=/\bGoogle TV\b/.exec(Ne))&&(Ne=Ye[0]),/\bSimulator\b/i.test(je)&&(Ne=(Ne?Ne+" ":"")+"Simulator"),Ke=="Opera Mini"&&/\bOPiOS\b/.test(je)&&_t.push("running in Turbo/Uncompressed mode"),Ke=="IE"&&/\blike iPhone OS\b/.test(je)?(Ye=oe(je.replace(/like iPhone OS/,"")),De=Ye.manufacturer,Ne=Ye.product):/^iP/.test(Ne)?(Ke||(Ke="Safari"),we="iOS"+((Ye=/ OS ([\d_]+)/i.exec(je))?" "+Ye[1].replace(/_/g,"."):"")):Ke!="Konqueror"||/buntu/i.test(we)?De&&De!="Google"&&(/Chrome/.test(Ke)&&!/\bMobile Safari\b/i.test(je)||/\bVita\b/.test(Ne))||/\bAndroid\b/.test(we)&&/^Chrome/.test(Ke)&&/\bVersion\//i.test(je)?(Ke="Android Browser",we=/\bAndroid\b/.test(we)?we:"Android"):Ke=="Silk"?(/\bMobi/i.test(je)||(we="Android",_t.unshift("desktop mode")),/Accelerated *= *true/i.test(je)&&_t.unshift("accelerated")):Ke=="PaleMoon"&&(Ye=/\bFirefox\/([\d.]+)\b/.exec(je))?_t.push("identifying as Firefox "+Ye[1]):Ke=="Firefox"&&(Ye=/\b(Mobile|Tablet|TV)\b/i.exec(je))?(we||(we="Firefox OS"),Ne||(Ne=Ye[1])):!Ke||(Ye=!/\bMinefield\b/i.test(je)&&/\b(?:Firefox|Safari)\b/.exec(Ke))?(Ke&&!Ne&&/[\/,]|^[^(]+?\)/.test(je.slice(je.indexOf(Ye+"/")+8))&&(Ke=null),(Ye=Ne||De||we)&&(Ne||De||/\b(?:Android|Symbian OS|Tablet OS|webOS)\b/.test(we))&&(Ke=/[a-z]+(?: Hat)?/i.exec(/\bAndroid\b/.test(we)?we:Ye)+" Browser")):Ke=="Electron"&&(Ye=(/\bChrome\/([\d.]+)\b/.exec(je)||0)[1])&&_t.push("Chromium "+Ye):we="Kubuntu",Se||(Se=function(Ue){return re(Ue,function(Me,Re){return Me||(RegExp(Re+"(?:-[\\d.]+/|(?: for [\\w-]+)?[ /-])([\\d.]+[^ ();/_-]*)","i").exec(je)||0)[1]||null})}(["(?:Cloud9|CriOS|CrMo|Edge|FxiOS|IEMobile|Iron|Opera ?Mini|OPiOS|OPR|Raven|SamsungBrowser|Silk(?!/[\\d.]+$))","Version",x(Ke),"(?:Firefox|Minefield|NetFront)"])),(Ye=Be=="iCab"&&parseFloat(Se)>3&&"WebKit"||/\bOpera\b/.test(Ke)&&(/\bOPR\b/.test(je)?"Blink":"Presto")||/\b(?:Midori|Nook|Safari)\b/i.test(je)&&!/^(?:Trident|EdgeHTML)$/.test(Be)&&"WebKit"||!Be&&/\bMSIE\b/i.test(je)&&(we=="Mac OS"?"Tasman":"Trident")||Be=="WebKit"&&/\bPlayStation\b(?! Vita\b)/i.test(Ke)&&"NetFront")&&(Be=[Ye]),Ke=="IE"&&(Ye=(/; *(?:XBLWP|ZuneWP)(\d+)/i.exec(je)||0)[1])?(Ke+=" Mobile",we="Windows Phone "+(/\+$/.test(Ye)?Ye:Ye+".x"),_t.unshift("desktop mode")):/\bWPDesktop\b/i.test(je)?(Ke="IE Mobile",we="Windows Phone 8.x",_t.unshift("desktop mode"),Se||(Se=(/\brv:([\d.]+)/.exec(je)||0)[1])):Ke!="IE"&&Be=="Trident"&&(Ye=/\brv:([\d.]+)/.exec(je))&&(Ke&&_t.push("identifying as "+Ke+(Se?" "+Se:"")),Ke="IE",Se=Ye[1]),Ae){if(z(Xe,"global"))if(et&&(Ye=et.lang.System,gt=Ye.getProperty("os.arch"),we=we||Ye.getProperty("os.name")+" "+Ye.getProperty("os.version")),pt){try{Se=Xe.require("ringo/engine").version.join("."),Ke="RingoJS"}catch(Ue){(Ye=Xe.system)&&Ye.global.system==Xe.system&&(Ke="Narwhal",we||(we=Ye[0].os||null))}Ke||(Ke="Rhino")}else typeof Xe.process=="object"&&!Xe.process.browser&&(Ye=Xe.process)&&(typeof Ye.versions=="object"&&(typeof Ye.versions.electron=="string"?(_t.push("Node "+Ye.versions.node),Ke="Electron",Se=Ye.versions.electron):typeof Ye.versions.nw=="string"&&(_t.push("Chromium "+Se,"Node "+Ye.versions.node),Ke="NW.js",Se=Ye.versions.nw)),Ke||(Ke="Node.js",gt=Ye.arch,we=Ye.platform,Se=/[\d.]+/.exec(Ye.version),Se=Se?Se[0]:null));else b(Ye=Xe.runtime)==ze?(Ke="Adobe AIR",we=Ye.flash.system.Capabilities.os):b(Ye=Xe.phantom)==nt?(Ke="PhantomJS",Se=(Ye=Ye.version||null)&&Ye.major+"."+Ye.minor+"."+Ye.patch):typeof dt.documentMode=="number"&&(Ye=/\bTrident\/(\d+)/i.exec(je))?(Se=[Se,dt.documentMode],(Ye=+Ye[1]+4)!=Se[1]&&(_t.push("IE "+Se[1]+" mode"),Be&&(Be[1]=""),Se[1]=Ye),Se=Ke=="IE"?String(Se[1].toFixed(1)):Se[0]):typeof dt.documentMode=="number"&&/^(?:Chrome|Firefox)\b/.test(Ke)&&(_t.push("masking as "+Ke+" "+Se),Ke="IE",Se="11.0",Be=["Trident"],we="Windows");we=we&&ne(we)}if(Se&&(Ye=/(?:[ab]|dp|pre|[ab]\d+pre)(?:\d+\+?)?$/i.exec(Se)||/(?:alpha|beta)(?: ?\d)?/i.exec(je+";"+(Ae&&He.appMinorVersion))||/\bMinefield\b/i.test(je)&&"a")&&(We=/b/i.test(Ye)?"beta":"alpha",Se=Se.replace(RegExp(Ye+"\\+?$"),"")+(We=="beta"?Ot:ct)+(/\d+\+?/.exec(Ye)||"")),Ke=="Fennec"||Ke=="Firefox"&&/\b(?:Android|Firefox OS)\b/.test(we))Ke="Firefox Mobile";else if(Ke=="Maxthon"&&Se)Se=Se.replace(/\.[\d.]+/,".x");else if(/\bXbox\b/i.test(Ne))Ne=="Xbox 360"&&(we=null),Ne=="Xbox 360"&&/\bIEMobile\b/.test(je)&&_t.unshift("mobile mode");else if(!/^(?:Chrome|IE|Opera)$/.test(Ke)&&(!Ke||Ne||/Browser|Mobi/.test(Ke))||we!="Windows CE"&&!/Mobi/i.test(je))if(Ke=="IE"&&Ae)try{Xe.external===null&&_t.unshift("platform preview")}catch(Ue){_t.unshift("embedded")}else(/\bBlackBerry\b/.test(Ne)||/\bBB10\b/.test(je))&&(Ye=(RegExp(Ne.replace(/ +/g," *")+"/([.\\d]+)","i").exec(je)||0)[1]||Se)?(Ye=[Ye,/BB10/.test(je)],we=(Ye[1]?(Ne=null,De="BlackBerry"):"Device Software")+" "+Ye[0],Se=null):this!=E&&Ne!="Wii"&&(Ae&&Rt||/Opera/.test(Ke)&&/\b(?:MSIE|Firefox)\b/i.test(je)||Ke=="Firefox"&&/\bOS X (?:\d+\.){2,}/.test(we)||Ke=="IE"&&(we&&!/^Win/.test(we)&&Se>5.5||/\bWindows XP\b/.test(we)&&Se>8||Se==8&&!/\bTrident\b/.test(je)))&&!pe.test(Ye=oe.call(E,je.replace(pe,"")+";"))&&Ye.name&&(Ye="ing as "+Ye.name+((Ye=Ye.version)?" "+Ye:""),pe.test(Ke)?(/\bIE\b/.test(Ye)&&we=="Mac OS"&&(we=null),Ye="identify"+Ye):(Ye="mask"+Ye,Ke=xt?ne(xt.replace(/([a-z])([A-Z])/g,"$1 $2")):"Opera",/\bIE\b/.test(Ye)&&(we=null),Ae||(Se=null)),Be=["Presto"],_t.push(Ye));else Ke+=" Mobile";(Ye=(/\bAppleWebKit\/([\d.]+\+?)/i.exec(je)||0)[1])&&(Ye=[parseFloat(Ye.replace(/\.(\d)$/,".0$1")),Ye],Ke=="Safari"&&Ye[1].slice(-1)=="+"?(Ke="WebKit Nightly",We="alpha",Se=Ye[1].slice(0,-1)):Se!=Ye[1]&&Se!=(Ye[2]=(/\bSafari\/([\d.]+\+?)/i.exec(je)||0)[1])||(Se=null),Ye[1]=(/\bChrome\/([\d.]+)/i.exec(je)||0)[1],Ye[0]==537.36&&Ye[2]==537.36&&parseFloat(Ye[1])>=28&&Be=="WebKit"&&(Be=["Blink"]),Ae&&(Ge||Ye[1])?(Be&&(Be[1]="like Chrome"),Ye=Ye[1]||(Ye=Ye[0],Ye<530?1:Ye<532?2:Ye<532.05?3:Ye<533?4:Ye<534.03?5:Ye<534.07?6:Ye<534.1?7:Ye<534.13?8:Ye<534.16?9:Ye<534.24?10:Ye<534.3?11:Ye<535.01?12:Ye<535.02?"13+":Ye<535.07?15:Ye<535.11?16:Ye<535.19?17:Ye<536.05?18:Ye<536.1?19:Ye<537.01?20:Ye<537.11?"21+":Ye<537.13?23:Ye<537.18?24:Ye<537.24?25:Ye<537.36?26:Be!="Blink"?"27":"28")):(Be&&(Be[1]="like Safari"),Ye=Ye[0],Ye=Ye<400?1:Ye<500?2:Ye<526?3:Ye<533?4:Ye<534?"4+":Ye<535?5:Ye<537?6:Ye<538?7:Ye<601?8:"8"),Be&&(Be[1]+=" "+(Ye+=typeof Ye=="number"?".x":/[.+]/.test(Ye)?"":"+")),Ke=="Safari"&&(!Se||parseInt(Se)>45)&&(Se=Ye)),Ke=="Opera"&&(Ye=/\bzbov|zvav$/.exec(we))?(Ke+=" ",_t.unshift("desktop mode"),Ye=="zvav"?(Ke+="Mini",Se=null):Ke+="Mobile",we=we.replace(RegExp(" *"+Ye+"$"),"")):Ke=="Safari"&&/\bChrome\b/.exec(Be&&Be[1])&&(_t.unshift("desktop mode"),Ke="Chrome Mobile",Se=null,/\bOS X\b/.test(we)?(De="Apple",we="iOS 4.3+"):we=null),Se&&Se.indexOf(Ye=/[\d.]+$/.exec(we))==0&&je.indexOf("/"+Ye+"-")>-1&&(we=ae(we.replace(Ye,""))),Be&&!/\b(?:Avant|Nook)\b/.test(Ke)&&(/Browser|Lunascape|Maxthon/.test(Ke)||Ke!="Safari"&&/^iOS/.test(we)&&/\bSafari\b/.test(Be[1])||/^(?:Adobe|Arora|Breach|Midori|Opera|Phantom|Rekonq|Rock|Samsung Internet|Sleipnir|Web)/.test(Ke)&&Be[1])&&(Ye=Be[Be.length-1])&&_t.push(Ye),_t.length&&(_t=["("+_t.join("; ")+")"]),De&&Ne&&Ne.indexOf(De)<0&&_t.push("on "+De),Ne&&_t.push((/^on /.test(_t[_t.length-1])?"":"on ")+Ne),we&&(Ye=/ ([\d.+]+)$/.exec(we),ut=Ye&&we.charAt(we.length-Ye[0].length-1)=="/",we={architecture:32,family:Ye&&!ut?we.replace(Ye[0],""):we,version:Ye?Ye[1]:null,toString:function(){var Ue=this.version;return this.family+(Ue&&!ut?" "+Ue:"")+(this.architecture==64?" 64-bit":"")}}),(Ye=/\b(?:AMD|IA|Win|WOW|x86_|x)64\b/i.exec(gt))&&!/\bi686\b/i.test(gt)?(we&&(we.architecture=64,we.family=we.family.replace(RegExp(" *"+Ye),"")),Ke&&(/\bWOW64\b/i.test(je)||Ae&&/\w(?:86|32)$/.test(He.cpuClass||He.platform)&&!/\bWin64; x64\b/i.test(je))&&_t.unshift("32-bit")):we&&/^OS X/.test(we.family)&&Ke=="Chrome"&&parseFloat(Se)>=39&&(we.architecture=64),je||(je=null);var Le={};return Le.description=je,Le.layout=Be&&Be[0],Le.manufacturer=De,Le.name=Ke,Le.prerelease=We,Le.product=Ne,Le.ua=je,Le.version=Ke&&Se,Le.os=we||{architecture:null,family:null,version:null,toString:function(){return"null"}},Le.parse=oe,Le.toString=Qe,Le.version&&_t.unshift(Se),Le.name&&_t.unshift(Ke),we&&Ke&&(we!=String(we).split(" ")[0]||we!=Ke.split(" ")[0]&&!Ne)&&_t.push(Ne?"("+we+")":"on "+we),_t.length&&(Le.description=_t.join(" ")),Le}var ve={function:!0,object:!0},ye=ve[typeof window]&&window||this,me=ve[typeof ue]&&ue,ge=ve[typeof Ce]&&Ce&&!Ce.nodeType&&Ce,_e=me&&ge&&typeof se=="object"&&se;!_e||_e.global!==_e&&_e.window!==_e&&_e.self!==_e||(ye=_e);var he=Math.pow(2,53)-1,pe=/\bOpera/,ke=Object.prototype,Te=ke.hasOwnProperty,Ee=ke.toString,Oe=oe();typeof ce=="function"&&typeof ce.amd=="object"&&ce.amd?(ye.platform=Oe,ce(function(){return Oe})):me&&ge?E(Oe,function(je,Pe){me[Pe]=je}):ye.platform=Oe}).call(this)}).call(this,typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],172:[function(ie,Ce,ue){(function(se){"use strict";function te(le,ee,ne,E){if(typeof le!="function")throw new TypeError('"callback" argument must be a function');var b,z,x=arguments.length;switch(x){case 0:case 1:return se.nextTick(le);case 2:return se.nextTick(function(){le.call(null,ee)});case 3:return se.nextTick(function(){le.call(null,ee,ne)});case 4:return se.nextTick(function(){le.call(null,ee,ne,E)});default:for(b=new Array(x-1),z=0;z<b.length;)b[z++]=arguments[z];return se.nextTick(function(){le.apply(null,b)})}}!se.version||se.version.indexOf("v0.")===0||se.version.indexOf("v1.")===0&&se.version.indexOf("v1.8.")!==0?Ce.exports={nextTick:te}:Ce.exports=se}).call(this,ie("_process"))},{_process:173}],173:[function(ie,Ce,ue){function se(){throw new Error("setTimeout has not been defined")}function te(){throw new Error("clearTimeout has not been defined")}function le(ge){if(x===setTimeout)return setTimeout(ge,0);if((x===se||!x)&&setTimeout)return x=setTimeout,setTimeout(ge,0);try{return x(ge,0)}catch(_e){try{return x.call(null,ge,0)}catch(he){return x.call(this,ge,0)}}}function ee(ge){if(re===clearTimeout)return clearTimeout(ge);if((re===te||!re)&&clearTimeout)return re=clearTimeout,clearTimeout(ge);try{return re(ge)}catch(_e){try{return re.call(null,ge)}catch(he){return re.call(this,ge)}}}function ne(){ye&&oe&&(ye=!1,oe.length?ve=oe.concat(ve):me=-1,ve.length&&E())}function E(){if(!ye){var ge=le(ne);ye=!0;for(var _e=ve.length;_e;){for(oe=ve,ve=[];++me<_e;)oe&&oe[me].run();me=-1,_e=ve.length}oe=null,ye=!1,ee(ge)}}function b(ge,_e){this.fun=ge,this.array=_e}function z(){}var x,re,ae=Ce.exports={};(function(){try{x=typeof setTimeout=="function"?setTimeout:se}catch(ge){x=se}try{re=typeof clearTimeout=="function"?clearTimeout:te}catch(ge){re=te}})();var oe,ve=[],ye=!1,me=-1;ae.nextTick=function(ge){var _e=new Array(arguments.length-1);if(arguments.length>1)for(var he=1;he<arguments.length;he++)_e[he-1]=arguments[he];ve.push(new b(ge,_e)),ve.length!==1||ye||le(E)},b.prototype.run=function(){this.fun.apply(null,this.array)},ae.title="browser",ae.browser=!0,ae.env={},ae.argv=[],ae.version="",ae.versions={},ae.on=z,ae.addListener=z,ae.once=z,ae.off=z,ae.removeListener=z,ae.removeAllListeners=z,ae.emit=z,ae.prependListener=z,ae.prependOnceListener=z,ae.listeners=function(ge){return[]},ae.binding=function(ge){throw new Error("process.binding is not supported")},ae.cwd=function(){return"/"},ae.chdir=function(ge){throw new Error("process.chdir is not supported")},ae.umask=function(){return 0}},{}],174:[function(ie,Ce,ue){(function(se){(function(te){function le($e){throw new RangeError(ut[$e])}function ee($e,nt){for(var et=$e.length,pt=[];et--;)pt[et]=nt($e[et]);return pt}function ne($e,nt){var et=$e.split("@"),pt="";return et.length>1&&(pt=et[0]+"@",$e=et[1]),$e=$e.replace(Ye,"."),pt+ee($e.split("."),nt).join(".")}function E($e){for(var nt,et,pt=[],ct=0,Ot=$e.length;ct<Ot;)nt=$e.charCodeAt(ct++),nt>=55296&&nt<=56319&&ct<Ot?(et=$e.charCodeAt(ct++),(64512&et)==56320?pt.push(((1023&nt)<<10)+(1023&et)+65536):(pt.push(nt),ct--)):pt.push(nt);return pt}function b($e){return ee($e,function(nt){var et="";return nt>65535&&(nt-=65536,et+=Ve(nt>>>10&1023|55296),nt=56320|1023&nt),et+=Ve(nt)}).join("")}function z($e){return $e-48<10?$e-22:$e-65<26?$e-65:$e-97<26?$e-97:Te}function x($e,nt){return $e+22+75*($e<26)-((nt!=0)<<5)}function re($e,nt,et){var pt=0;for($e=et?ze($e/Pe):$e>>1,$e+=ze($e/nt);$e>Ge*Oe>>1;pt+=Te)$e=ze($e/Ge);return ze(pt+(Ge+1)*$e/($e+je))}function ae($e){var nt,et,pt,ct,Ot,dt,Rt,xt,gt,_t,We=[],Ae=$e.length,Se=0,Be=Xe,Ke=Qe;for(et=$e.lastIndexOf(ot),et<0&&(et=0),pt=0;pt<et;++pt)$e.charCodeAt(pt)>=128&&le("not-basic"),We.push($e.charCodeAt(pt));for(ct=et>0?et+1:0;ct<Ae;){for(Ot=Se,dt=1,Rt=Te;ct>=Ae&&le("invalid-input"),xt=z($e.charCodeAt(ct++)),(xt>=Te||xt>ze((ke-Se)/dt))&&le("overflow"),Se+=xt*dt,gt=Rt<=Ke?Ee:Rt>=Ke+Oe?Oe:Rt-Ke,!(xt<gt);Rt+=Te)_t=Te-gt,dt>ze(ke/_t)&&le("overflow"),dt*=_t;nt=We.length+1,Ke=re(Se-Ot,nt,Ot==0),ze(Se/nt)>ke-Be&&le("overflow"),Be+=ze(Se/nt),Se%=nt,We.splice(Se++,0,Be)}return b(We)}function oe($e){var nt,et,pt,ct,Ot,dt,Rt,xt,gt,_t,We,Ae,Se,Be,Ke,Ne=[];for($e=E($e),Ae=$e.length,nt=Xe,et=0,Ot=Qe,dt=0;dt<Ae;++dt)(We=$e[dt])<128&&Ne.push(Ve(We));for(pt=ct=Ne.length,ct&&Ne.push(ot);pt<Ae;){for(Rt=ke,dt=0;dt<Ae;++dt)(We=$e[dt])>=nt&&We<Rt&&(Rt=We);for(Se=pt+1,Rt-nt>ze((ke-et)/Se)&&le("overflow"),et+=(Rt-nt)*Se,nt=Rt,dt=0;dt<Ae;++dt)if(We=$e[dt],We<nt&&++et>ke&&le("overflow"),We==nt){for(xt=et,gt=Te;_t=gt<=Ot?Ee:gt>=Ot+Oe?Oe:gt-Ot,!(xt<_t);gt+=Te)Ke=xt-_t,Be=Te-_t,Ne.push(Ve(x(_t+Ke%Be,0))),xt=ze(Ke/Be);Ne.push(Ve(x(xt,0))),Ot=re(et,Se,pt==ct),et=0,++pt}++et,++nt}return Ne.join("")}function ve($e){return ne($e,function(nt){return He.test(nt)?ae(nt.slice(4).toLowerCase()):nt})}function ye($e){return ne($e,function(nt){return rt.test(nt)?"xn--"+oe(nt):nt})}var me=typeof ue=="object"&&ue&&!ue.nodeType&&ue,ge=typeof Ce=="object"&&Ce&&!Ce.nodeType&&Ce,_e=typeof se=="object"&&se;_e.global!==_e&&_e.window!==_e&&_e.self!==_e||(te=_e);var he,pe,ke=2147483647,Te=36,Ee=1,Oe=26,je=38,Pe=700,Qe=72,Xe=128,ot="-",He=/^xn--/,rt=/[^\x20-\x7E]/,Ye=/[\x2E\u3002\uFF0E\uFF61]/g,ut={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},Ge=Te-Ee,ze=Math.floor,Ve=String.fromCharCode;if(he={version:"1.4.1",ucs2:{decode:E,encode:b},decode:ae,encode:oe,toASCII:ye,toUnicode:ve},typeof ce=="function"&&typeof ce.amd=="object"&&ce.amd)ce("punycode",function(){return he});else if(me&&ge)if(Ce.exports==me)ge.exports=he;else for(pe in he)he.hasOwnProperty(pe)&&(me[pe]=he[pe]);else te.punycode=he})(this)}).call(this,typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],175:[function(ie,Ce,ue){"use strict";function se(le,ee){return Object.prototype.hasOwnProperty.call(le,ee)}Ce.exports=function(le,ee,ne,E){ee=ee||"&",ne=ne||"=";var b={};if(typeof le!="string"||le.length===0)return b;var z=/\+/g;le=le.split(ee);var x=1e3;E&&typeof E.maxKeys=="number"&&(x=E.maxKeys);var re=le.length;x>0&&re>x&&(re=x);for(var ae=0;ae<re;++ae){var oe,ve,ye,me,ge=le[ae].replace(z,"%20"),_e=ge.indexOf(ne);_e>=0?(oe=ge.substr(0,_e),ve=ge.substr(_e+1)):(oe=ge,ve=""),ye=decodeURIComponent(oe),me=decodeURIComponent(ve),se(b,ye)?te(b[ye])?b[ye].push(me):b[ye]=[b[ye],me]:b[ye]=me}return b};var te=Array.isArray||function(le){return Object.prototype.toString.call(le)==="[object Array]"}},{}],176:[function(ie,Ce,ue){"use strict";function se(ne,E){if(ne.map)return ne.map(E);for(var b=[],z=0;z<ne.length;z++)b.push(E(ne[z],z));return b}var te=function(ne){switch(typeof ne){case"string":return ne;case"boolean":return ne?"true":"false";case"number":return isFinite(ne)?ne:"";default:return""}};Ce.exports=function(ne,E,b,z){return E=E||"&",b=b||"=",ne===null&&(ne=void 0),typeof ne=="object"?se(ee(ne),function(x){var re=encodeURIComponent(te(x))+b;return le(ne[x])?se(ne[x],function(ae){return re+encodeURIComponent(te(ae))}).join(E):re+encodeURIComponent(te(ne[x]))}).join(E):z?encodeURIComponent(te(z))+b+encodeURIComponent(te(ne)):""};var le=Array.isArray||function(ne){return Object.prototype.toString.call(ne)==="[object Array]"},ee=Object.keys||function(ne){var E=[];for(var b in ne)Object.prototype.hasOwnProperty.call(ne,b)&&E.push(b);return E}},{}],177:[function(ie,Ce,ue){"use strict";ue.decode=ue.parse=ie("./decode"),ue.encode=ue.stringify=ie("./encode")},{"./decode":175,"./encode":176}],178:[function(ie,Ce,ue){Ce.exports=ie("./lib/_stream_duplex.js")},{"./lib/_stream_duplex.js":179}],179:[function(ie,Ce,ue){"use strict";function se(ye){if(!(this instanceof se))return new se(ye);x.call(this,ye),re.call(this,ye),ye&&ye.readable===!1&&(this.readable=!1),ye&&ye.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,ye&&ye.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",te)}function te(){this.allowHalfOpen||this._writableState.ended||E.nextTick(le,this)}function le(ye){ye.end()}var ee=ie("babel-runtime/core-js/object/keys"),ne=function(ye){return ye&&ye.__esModule?ye:{default:ye}}(ee),E=ie("process-nextick-args"),b=ne.default||function(ye){var me=[];for(var ge in ye)me.push(ge);return me};Ce.exports=se;var z=ie("core-util-is");z.inherits=ie("inherits");var x=ie("./_stream_readable"),re=ie("./_stream_writable");z.inherits(se,x);for(var ae=b(re.prototype),oe=0;oe<ae.length;oe++){var ve=ae[oe];se.prototype[ve]||(se.prototype[ve]=re.prototype[ve])}Object.defineProperty(se.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(se.prototype,"destroyed",{get:function(){return this._readableState!==void 0&&this._writableState!==void 0&&this._readableState.destroyed&&this._writableState.destroyed},set:function(ye){this._readableState!==void 0&&this._writableState!==void 0&&(this._readableState.destroyed=ye,this._writableState.destroyed=ye)}}),se.prototype._destroy=function(ye,me){this.push(null),this.end(),E.nextTick(me,ye)}},{"./_stream_readable":181,"./_stream_writable":183,"babel-runtime/core-js/object/keys":23,"core-util-is":153,inherits:162,"process-nextick-args":172}],180:[function(ie,Ce,ue){"use strict";function se(ee){if(!(this instanceof se))return new se(ee);te.call(this,ee)}Ce.exports=se;var te=ie("./_stream_transform"),le=ie("core-util-is");le.inherits=ie("inherits"),le.inherits(se,te),se.prototype._transform=function(ee,ne,E){E(null,ee)}},{"./_stream_transform":182,"core-util-is":153,inherits:162}],181:[function(ie,Ce,ue){(function(se,te){"use strict";function le(Ae){return et.from(Ae)}function ee(Ae){return et.isBuffer(Ae)||Ae instanceof pt}function ne(Ae,Se,Be){if(typeof Ae.prependListener=="function")return Ae.prependListener(Se,Be);Ae._events&&Ae._events[Se]?Ve(Ae._events[Se])?Ae._events[Se].unshift(Be):Ae._events[Se]=[Be,Ae._events[Se]]:Ae.on(Se,Be)}function E(Ae,Se){ze=ze||ie("./_stream_duplex"),Ae=Ae||{};var Be=Se instanceof ze;this.objectMode=!!Ae.objectMode,Be&&(this.objectMode=this.objectMode||!!Ae.readableObjectMode);var Ke=Ae.highWaterMark,Ne=Ae.readableHighWaterMark,De=this.objectMode?16:16384;this.highWaterMark=Ke||Ke===0?Ke:Be&&(Ne||Ne===0)?Ne:De,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new xt,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=Ae.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,Ae.encoding&&(Rt||(Rt=ie("string_decoder/").StringDecoder),this.decoder=new Rt(Ae.encoding),this.encoding=Ae.encoding)}function b(Ae){if(ze=ze||ie("./_stream_duplex"),!(this instanceof b))return new b(Ae);this._readableState=new E(Ae,this),this.readable=!0,Ae&&(typeof Ae.read=="function"&&(this._read=Ae.read),typeof Ae.destroy=="function"&&(this._destroy=Ae.destroy)),nt.call(this)}function z(Ae,Se,Be,Ke,Ne){var De=Ae._readableState;if(Se===null)De.reading=!1,ye(Ae,De);else{var we;Ne||(we=re(De,Se)),we?Ae.emit("error",we):De.objectMode||Se&&Se.length>0?(typeof Se=="string"||De.objectMode||(0,ut.default)(Se)===et.prototype||(Se=le(Se)),Ke?De.endEmitted?Ae.emit("error",new Error("stream.unshift() after end event")):x(Ae,De,Se,!0):De.ended?Ae.emit("error",new Error("stream.push() after EOF")):(De.reading=!1,De.decoder&&!Be?(Se=De.decoder.write(Se),De.objectMode||Se.length!==0?x(Ae,De,Se,!1):_e(Ae,De)):x(Ae,De,Se,!1))):Ke||(De.reading=!1)}return ae(De)}function x(Ae,Se,Be,Ke){Se.flowing&&Se.length===0&&!Se.sync?(Ae.emit("data",Be),Ae.read(0)):(Se.length+=Se.objectMode?1:Be.length,Ke?Se.buffer.unshift(Be):Se.buffer.push(Be),Se.needReadable&&me(Ae)),_e(Ae,Se)}function re(Ae,Se){var Be;return ee(Se)||typeof Se=="string"||Se===void 0||Ae.objectMode||(Be=new TypeError("Invalid non-string/buffer chunk")),Be}function ae(Ae){return!Ae.ended&&(Ae.needReadable||Ae.length<Ae.highWaterMark||Ae.length===0)}function oe(Ae){return Ae>=We?Ae=We:(Ae--,Ae|=Ae>>>1,Ae|=Ae>>>2,Ae|=Ae>>>4,Ae|=Ae>>>8,Ae|=Ae>>>16,Ae++),Ae}function ve(Ae,Se){return Ae<=0||Se.length===0&&Se.ended?0:Se.objectMode?1:Ae!==Ae?Se.flowing&&Se.length?Se.buffer.head.data.length:Se.length:(Ae>Se.highWaterMark&&(Se.highWaterMark=oe(Ae)),Ae<=Se.length?Ae:Se.ended?Se.length:(Se.needReadable=!0,0))}function ye(Ae,Se){if(!Se.ended){if(Se.decoder){var Be=Se.decoder.end();Be&&Be.length&&(Se.buffer.push(Be),Se.length+=Se.objectMode?1:Be.length)}Se.ended=!0,me(Ae)}}function me(Ae){var Se=Ae._readableState;Se.needReadable=!1,Se.emittedReadable||(dt("emitReadable",Se.flowing),Se.emittedReadable=!0,Se.sync?Ge.nextTick(ge,Ae):ge(Ae))}function ge(Ae){dt("emit readable"),Ae.emit("readable"),Oe(Ae)}function _e(Ae,Se){Se.readingMore||(Se.readingMore=!0,Ge.nextTick(he,Ae,Se))}function he(Ae,Se){for(var Be=Se.length;!Se.reading&&!Se.flowing&&!Se.ended&&Se.length<Se.highWaterMark&&(dt("maybeReadMore read 0"),Ae.read(0),Be!==Se.length);)Be=Se.length;Se.readingMore=!1}function pe(Ae){return function(){var Se=Ae._readableState;dt("pipeOnDrain",Se.awaitDrain),Se.awaitDrain&&Se.awaitDrain--,Se.awaitDrain===0&&$e(Ae,"data")&&(Se.flowing=!0,Oe(Ae))}}function ke(Ae){dt("readable nexttick read 0"),Ae.read(0)}function Te(Ae,Se){Se.resumeScheduled||(Se.resumeScheduled=!0,Ge.nextTick(Ee,Ae,Se))}function Ee(Ae,Se){Se.reading||(dt("resume read 0"),Ae.read(0)),Se.resumeScheduled=!1,Se.awaitDrain=0,Ae.emit("resume"),Oe(Ae),Se.flowing&&!Se.reading&&Ae.read(0)}function Oe(Ae){var Se=Ae._readableState;for(dt("flow",Se.flowing);Se.flowing&&Ae.read()!==null;);}function je(Ae,Se){if(Se.length===0)return null;var Be;return Se.objectMode?Be=Se.buffer.shift():!Ae||Ae>=Se.length?(Be=Se.decoder?Se.buffer.join(""):Se.buffer.length===1?Se.buffer.head.data:Se.buffer.concat(Se.length),Se.buffer.clear()):Be=Pe(Ae,Se.buffer,Se.decoder),Be}function Pe(Ae,Se,Be){var Ke;return Ae<Se.head.data.length?(Ke=Se.head.data.slice(0,Ae),Se.head.data=Se.head.data.slice(Ae)):Ke=Ae===Se.head.data.length?Se.shift():Be?Qe(Ae,Se):Xe(Ae,Se),Ke}function Qe(Ae,Se){var Be=Se.head,Ke=1,Ne=Be.data;for(Ae-=Ne.length;Be=Be.next;){var De=Be.data,we=Ae>De.length?De.length:Ae;if(we===De.length?Ne+=De:Ne+=De.slice(0,Ae),(Ae-=we)===0){we===De.length?(++Ke,Be.next?Se.head=Be.next:Se.head=Se.tail=null):(Se.head=Be,Be.data=De.slice(we));break}++Ke}return Se.length-=Ke,Ne}function Xe(Ae,Se){var Be=et.allocUnsafe(Ae),Ke=Se.head,Ne=1;for(Ke.data.copy(Be),Ae-=Ke.data.length;Ke=Ke.next;){var De=Ke.data,we=Ae>De.length?De.length:Ae;if(De.copy(Be,Be.length-Ae,0,we),(Ae-=we)===0){we===De.length?(++Ne,Ke.next?Se.head=Ke.next:Se.head=Se.tail=null):(Se.head=Ke,Ke.data=De.slice(we));break}++Ne}return Se.length-=Ne,Be}function ot(Ae){var Se=Ae._readableState;if(Se.length>0)throw new Error('"endReadable()" called on non-empty stream');Se.endEmitted||(Se.ended=!0,Ge.nextTick(He,Se,Ae))}function He(Ae,Se){Ae.endEmitted||Ae.length!==0||(Ae.endEmitted=!0,Se.readable=!1,Se.emit("end"))}function rt(Ae,Se){for(var Be=0,Ke=Ae.length;Be<Ke;Be++)if(Ae[Be]===Se)return Be;return-1}var Ye=ie("babel-runtime/core-js/object/get-prototype-of"),ut=function(Ae){return Ae&&Ae.__esModule?Ae:{default:Ae}}(Ye),Ge=ie("process-nextick-args");Ce.exports=b;var ze,Ve=ie("isarray");b.ReadableState=E;var $e=(ie("events").EventEmitter,function(Ae,Se){return Ae.listeners(Se).length}),nt=ie("./internal/streams/stream"),et=ie("safe-buffer").Buffer,pt=te.Uint8Array||function(){},ct=ie("core-util-is");ct.inherits=ie("inherits");var Ot=ie("util"),dt=void 0;dt=Ot&&Ot.debuglog?Ot.debuglog("stream"):function(){};var Rt,xt=ie("./internal/streams/BufferList"),gt=ie("./internal/streams/destroy");ct.inherits(b,nt);var _t=["error","close","destroy","pause","resume"];Object.defineProperty(b.prototype,"destroyed",{get:function(){return this._readableState!==void 0&&this._readableState.destroyed},set:function(Ae){this._readableState&&(this._readableState.destroyed=Ae)}}),b.prototype.destroy=gt.destroy,b.prototype._undestroy=gt.undestroy,b.prototype._destroy=function(Ae,Se){this.push(null),Se(Ae)},b.prototype.push=function(Ae,Se){var Be,Ke=this._readableState;return Ke.objectMode?Be=!0:typeof Ae=="string"&&(Se=Se||Ke.defaultEncoding,Se!==Ke.encoding&&(Ae=et.from(Ae,Se),Se=""),Be=!0),z(this,Ae,Se,!1,Be)},b.prototype.unshift=function(Ae){return z(this,Ae,null,!0,!1)},b.prototype.isPaused=function(){return this._readableState.flowing===!1},b.prototype.setEncoding=function(Ae){return Rt||(Rt=ie("string_decoder/").StringDecoder),this._readableState.decoder=new Rt(Ae),this._readableState.encoding=Ae,this};var We=8388608;b.prototype.read=function(Ae){dt("read",Ae),Ae=parseInt(Ae,10);var Se=this._readableState,Be=Ae;if(Ae!==0&&(Se.emittedReadable=!1),Ae===0&&Se.needReadable&&(Se.length>=Se.highWaterMark||Se.ended))return dt("read: emitReadable",Se.length,Se.ended),Se.length===0&&Se.ended?ot(this):me(this),null;if((Ae=ve(Ae,Se))===0&&Se.ended)return Se.length===0&&ot(this),null;var Ke=Se.needReadable;dt("need readable",Ke),(Se.length===0||Se.length-Ae<Se.highWaterMark)&&(Ke=!0,dt("length less than watermark",Ke)),Se.ended||Se.reading?(Ke=!1,dt("reading or ended",Ke)):Ke&&(dt("do read"),Se.reading=!0,Se.sync=!0,Se.length===0&&(Se.needReadable=!0),this._read(Se.highWaterMark),Se.sync=!1,Se.reading||(Ae=ve(Be,Se)));var Ne;return Ne=Ae>0?je(Ae,Se):null,Ne===null?(Se.needReadable=!0,Ae=0):Se.length-=Ae,Se.length===0&&(Se.ended||(Se.needReadable=!0),Be!==Ae&&Se.ended&&ot(this)),Ne!==null&&this.emit("data",Ne),Ne},b.prototype._read=function(Ae){this.emit("error",new Error("_read() is not implemented"))},b.prototype.pipe=function(Ae,Se){function Be(Ht,jt){dt("onunpipe"),Ht===Re&&jt&&jt.hasUnpiped===!1&&(jt.hasUnpiped=!0,Ne())}function Ke(){dt("onend"),Ae.end()}function Ne(){dt("cleanup"),Ae.removeListener("close",Le),Ae.removeListener("finish",Ue),Ae.removeListener("drain",Ct),Ae.removeListener("error",we),Ae.removeListener("unpipe",Be),Re.removeListener("end",Ke),Re.removeListener("end",Me),Re.removeListener("data",De),vt=!0,!tt.awaitDrain||Ae._writableState&&!Ae._writableState.needDrain||Ct()}function De(Ht){dt("ondata"),Pt=!1,Ae.write(Ht)!==!1||Pt||((tt.pipesCount===1&&tt.pipes===Ae||tt.pipesCount>1&&rt(tt.pipes,Ae)!==-1)&&!vt&&(dt("false write response, pause",Re._readableState.awaitDrain),Re._readableState.awaitDrain++,Pt=!0),Re.pause())}function we(Ht){dt("onerror",Ht),Me(),Ae.removeListener("error",we),$e(Ae,"error")===0&&Ae.emit("error",Ht)}function Le(){Ae.removeListener("finish",Ue),Me()}function Ue(){dt("onfinish"),Ae.removeListener("close",Le),Me()}function Me(){dt("unpipe"),Re.unpipe(Ae)}var Re=this,tt=this._readableState;switch(tt.pipesCount){case 0:tt.pipes=Ae;break;case 1:tt.pipes=[tt.pipes,Ae];break;default:tt.pipes.push(Ae)}tt.pipesCount+=1,dt("pipe count=%d opts=%j",tt.pipesCount,Se);var lt=(!Se||Se.end!==!1)&&Ae!==se.stdout&&Ae!==se.stderr,Nt=lt?Ke:Me;tt.endEmitted?Ge.nextTick(Nt):Re.once("end",Nt),Ae.on("unpipe",Be);var Ct=pe(Re);Ae.on("drain",Ct);var vt=!1,Pt=!1;return Re.on("data",De),ne(Ae,"error",we),Ae.once("close",Le),Ae.once("finish",Ue),Ae.emit("pipe",Re),tt.flowing||(dt("pipe resume"),Re.resume()),Ae},b.prototype.unpipe=function(Ae){var Se=this._readableState,Be={hasUnpiped:!1};if(Se.pipesCount===0)return this;if(Se.pipesCount===1)return Ae&&Ae!==Se.pipes?this:(Ae||(Ae=Se.pipes),Se.pipes=null,Se.pipesCount=0,Se.flowing=!1,Ae&&Ae.emit("unpipe",this,Be),this);if(!Ae){var Ke=Se.pipes,Ne=Se.pipesCount;Se.pipes=null,Se.pipesCount=0,Se.flowing=!1;for(var De=0;De<Ne;De++)Ke[De].emit("unpipe",this,Be);return this}var we=rt(Se.pipes,Ae);return we===-1?this:(Se.pipes.splice(we,1),Se.pipesCount-=1,Se.pipesCount===1&&(Se.pipes=Se.pipes[0]),Ae.emit("unpipe",this,Be),this)},b.prototype.on=function(Ae,Se){var Be=nt.prototype.on.call(this,Ae,Se);if(Ae==="data")this._readableState.flowing!==!1&&this.resume();else if(Ae==="readable"){var Ke=this._readableState;Ke.endEmitted||Ke.readableListening||(Ke.readableListening=Ke.needReadable=!0,Ke.emittedReadable=!1,Ke.reading?Ke.length&&me(this):Ge.nextTick(ke,this))}return Be},b.prototype.addListener=b.prototype.on,b.prototype.resume=function(){var Ae=this._readableState;return Ae.flowing||(dt("resume"),Ae.flowing=!0,Te(this,Ae)),this},b.prototype.pause=function(){return dt("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(dt("pause"),this._readableState.flowing=!1,this.emit("pause")),this},b.prototype.wrap=function(Ae){var Se=this,Be=this._readableState,Ke=!1;Ae.on("end",function(){if(dt("wrapped end"),Be.decoder&&!Be.ended){var we=Be.decoder.end();we&&we.length&&Se.push(we)}Se.push(null)}),Ae.on("data",function(we){dt("wrapped data"),Be.decoder&&(we=Be.decoder.write(we)),(!Be.objectMode||we!=null)&&(Be.objectMode||we&&we.length)&&(Se.push(we)||(Ke=!0,Ae.pause()))});for(var Ne in Ae)this[Ne]===void 0&&typeof Ae[Ne]=="function"&&(this[Ne]=function(we){return function(){return Ae[we].apply(Ae,arguments)}}(Ne));for(var De=0;De<_t.length;De++)Ae.on(_t[De],this.emit.bind(this,_t[De]));return this._read=function(we){dt("wrapped _read",we),Ke&&(Ke=!1,Ae.resume())},this},Object.defineProperty(b.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),b._fromList=je}).call(this,ie("_process"),typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./_stream_duplex":179,"./internal/streams/BufferList":184,"./internal/streams/destroy":185,"./internal/streams/stream":186,_process:173,"babel-runtime/core-js/object/get-prototype-of":22,"core-util-is":153,events:158,inherits:162,isarray:166,"process-nextick-args":172,"safe-buffer":193,"string_decoder/":200,util:36}],182:[function(ie,Ce,ue){"use strict";function se(b,z){var x=this._transformState;x.transforming=!1;var re=x.writecb;if(!re)return this.emit("error",new Error("write callback called multiple times"));x.writechunk=null,x.writecb=null,z!=null&&this.push(z),re(b);var ae=this._readableState;ae.reading=!1,(ae.needReadable||ae.length<ae.highWaterMark)&&this._read(ae.highWaterMark)}function te(b){if(!(this instanceof te))return new te(b);ne.call(this,b),this._transformState={afterTransform:se.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,b&&(typeof b.transform=="function"&&(this._transform=b.transform),typeof b.flush=="function"&&(this._flush=b.flush)),this.on("prefinish",le)}function le(){var b=this;typeof this._flush=="function"?this._flush(function(z,x){ee(b,z,x)}):ee(this,null,null)}function ee(b,z,x){if(z)return b.emit("error",z);if(x!=null&&b.push(x),b._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(b._transformState.transforming)throw new Error("Calling transform done when still transforming");return b.push(null)}Ce.exports=te;var ne=ie("./_stream_duplex"),E=ie("core-util-is");E.inherits=ie("inherits"),E.inherits(te,ne),te.prototype.push=function(b,z){return this._transformState.needTransform=!1,ne.prototype.push.call(this,b,z)},te.prototype._transform=function(b,z,x){throw new Error("_transform() is not implemented")},te.prototype._write=function(b,z,x){var re=this._transformState;if(re.writecb=x,re.writechunk=b,re.writeencoding=z,!re.transforming){var ae=this._readableState;(re.needTransform||ae.needReadable||ae.length<ae.highWaterMark)&&this._read(ae.highWaterMark)}},te.prototype._read=function(b){var z=this._transformState;z.writechunk!==null&&z.writecb&&!z.transforming?(z.transforming=!0,this._transform(z.writechunk,z.writeencoding,z.afterTransform)):z.needTransform=!0},te.prototype._destroy=function(b,z){var x=this;ne.prototype._destroy.call(this,b,function(re){z(re),x.emit("close")})}},{"./_stream_duplex":179,"core-util-is":153,inherits:162}],183:[function(ie,Ce,ue){(function(se,te){"use strict";function le(gt){return gt&>.__esModule?gt:{default:gt}}function ee(gt){var _t=this;this.next=null,this.entry=null,this.finish=function(){Qe(_t,gt)}}function ne(gt){return Ot.from(gt)}function E(gt){return Ot.isBuffer(gt)||gt instanceof dt}function b(){}function z(gt,_t){$e=$e||ie("./_stream_duplex"),gt=gt||{};var We=_t instanceof $e;this.objectMode=!!gt.objectMode,We&&(this.objectMode=this.objectMode||!!gt.writableObjectMode);var Ae=gt.highWaterMark,Se=gt.writableHighWaterMark,Be=this.objectMode?16:16384;this.highWaterMark=Ae||Ae===0?Ae:We&&(Se||Se===0)?Se:Be,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 Ke=gt.decodeStrings===!1;this.decodeStrings=!Ke,this.defaultEncoding=gt.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(Ne){_e(_t,Ne)},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 ee(this)}function x(gt){if($e=$e||ie("./_stream_duplex"),!(xt.call(x,this)||this instanceof $e))return new x(gt);this._writableState=new z(gt,this),this.writable=!0,gt&&(typeof gt.write=="function"&&(this._write=gt.write),typeof gt.writev=="function"&&(this._writev=gt.writev),typeof gt.destroy=="function"&&(this._destroy=gt.destroy),typeof gt.final=="function"&&(this._final=gt.final)),ct.call(this)}function re(gt,_t){var We=new Error("write after end");gt.emit("error",We),Ve.nextTick(_t,We)}function ae(gt,_t,We,Ae){var Se=!0,Be=!1;return We===null?Be=new TypeError("May not write null values to stream"):typeof We=="string"||We===void 0||_t.objectMode||(Be=new TypeError("Invalid non-string/buffer chunk")),Be&&(gt.emit("error",Be),Ve.nextTick(Ae,Be),Se=!1),Se}function oe(gt,_t,We){return gt.objectMode||gt.decodeStrings===!1||typeof _t!="string"||(_t=Ot.from(_t,We)),_t}function ve(gt,_t,We,Ae,Se,Be){if(!We){var Ke=oe(_t,Ae,Se);Ae!==Ke&&(We=!0,Se="buffer",Ae=Ke)}var Ne=_t.objectMode?1:Ae.length;_t.length+=Ne;var De=_t.length<_t.highWaterMark;if(De||(_t.needDrain=!0),_t.writing||_t.corked){var we=_t.lastBufferedRequest;_t.lastBufferedRequest={chunk:Ae,encoding:Se,isBuf:We,callback:Be,next:null},we?we.next=_t.lastBufferedRequest:_t.bufferedRequest=_t.lastBufferedRequest,_t.bufferedRequestCount+=1}else ye(gt,_t,!1,Ne,Ae,Se,Be);return De}function ye(gt,_t,We,Ae,Se,Be,Ke){_t.writelen=Ae,_t.writecb=Ke,_t.writing=!0,_t.sync=!0,We?gt._writev(Se,_t.onwrite):gt._write(Se,Be,_t.onwrite),_t.sync=!1}function me(gt,_t,We,Ae,Se){--_t.pendingcb,We?(Ve.nextTick(Se,Ae),Ve.nextTick(je,gt,_t),gt._writableState.errorEmitted=!0,gt.emit("error",Ae)):(Se(Ae),gt._writableState.errorEmitted=!0,gt.emit("error",Ae),je(gt,_t))}function ge(gt){gt.writing=!1,gt.writecb=null,gt.length-=gt.writelen,gt.writelen=0}function _e(gt,_t){var We=gt._writableState,Ae=We.sync,Se=We.writecb;if(ge(We),_t)me(gt,We,Ae,_t,Se);else{var Be=Te(We);Be||We.corked||We.bufferProcessing||!We.bufferedRequest||ke(gt,We),Ae?nt(he,gt,We,Be,Se):he(gt,We,Be,Se)}}function he(gt,_t,We,Ae){We||pe(gt,_t),_t.pendingcb--,Ae(),je(gt,_t)}function pe(gt,_t){_t.length===0&&_t.needDrain&&(_t.needDrain=!1,gt.emit("drain"))}function ke(gt,_t){_t.bufferProcessing=!0;var We=_t.bufferedRequest;if(gt._writev&&We&&We.next){var Ae=_t.bufferedRequestCount,Se=new Array(Ae),Be=_t.corkedRequestsFree;Be.entry=We;for(var Ke=0,Ne=!0;We;)Se[Ke]=We,We.isBuf||(Ne=!1),We=We.next,Ke+=1;Se.allBuffers=Ne,ye(gt,_t,!0,_t.length,Se,"",Be.finish),_t.pendingcb++,_t.lastBufferedRequest=null,Be.next?(_t.corkedRequestsFree=Be.next,Be.next=null):_t.corkedRequestsFree=new ee(_t),_t.bufferedRequestCount=0}else{for(;We;){var De=We.chunk,we=We.encoding,Le=We.callback;if(ye(gt,_t,!1,_t.objectMode?1:De.length,De,we,Le),We=We.next,_t.bufferedRequestCount--,_t.writing)break}We===null&&(_t.lastBufferedRequest=null)}_t.bufferedRequest=We,_t.bufferProcessing=!1}function Te(gt){return gt.ending&>.length===0&>.bufferedRequest===null&&!gt.finished&&!gt.writing}function Ee(gt,_t){gt._final(function(We){_t.pendingcb--,We&>.emit("error",We),_t.prefinished=!0,gt.emit("prefinish"),je(gt,_t)})}function Oe(gt,_t){_t.prefinished||_t.finalCalled||(typeof gt._final=="function"?(_t.pendingcb++,_t.finalCalled=!0,Ve.nextTick(Ee,gt,_t)):(_t.prefinished=!0,gt.emit("prefinish")))}function je(gt,_t){var We=Te(_t);return We&&(Oe(gt,_t),_t.pendingcb===0&&(_t.finished=!0,gt.emit("finish"))),We}function Pe(gt,_t,We){_t.ending=!0,je(gt,_t),We&&(_t.finished?Ve.nextTick(We):gt.once("finish",We)),_t.ended=!0,gt.writable=!1}function Qe(gt,_t,We){var Ae=gt.entry;for(gt.entry=null;Ae;){var Se=Ae.callback;_t.pendingcb--,Se(We),Ae=Ae.next}_t.corkedRequestsFree?_t.corkedRequestsFree.next=gt:_t.corkedRequestsFree=gt}var Xe=ie("babel-runtime/core-js/object/define-property"),ot=le(Xe),He=ie("babel-runtime/core-js/symbol/has-instance"),rt=le(He),Ye=ie("babel-runtime/core-js/symbol"),ut=le(Ye),Ge=ie("babel-runtime/core-js/set-immediate"),ze=le(Ge),Ve=ie("process-nextick-args");Ce.exports=x;var $e,nt=!se.browser&&["v0.10","v0.9."].indexOf(se.version.slice(0,5))>-1?ze.default:Ve.nextTick;x.WritableState=z;var et=ie("core-util-is");et.inherits=ie("inherits");var pt={deprecate:ie("util-deprecate")},ct=ie("./internal/streams/stream"),Ot=ie("safe-buffer").Buffer,dt=te.Uint8Array||function(){},Rt=ie("./internal/streams/destroy");et.inherits(x,ct),z.prototype.getBuffer=function(){for(var gt=this.bufferedRequest,_t=[];gt;)_t.push(gt),gt=gt.next;return _t},function(){try{Object.defineProperty(z.prototype,"buffer",{get:pt.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(gt){}}();var xt;typeof ut.default=="function"&&rt.default&&typeof Function.prototype[rt.default]=="function"?(xt=Function.prototype[rt.default],(0,ot.default)(x,rt.default,{value:function(gt){return!!xt.call(this,gt)||this===x&>&>._writableState instanceof z}})):xt=function(gt){return gt instanceof this},x.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},x.prototype.write=function(gt,_t,We){var Ae=this._writableState,Se=!1,Be=!Ae.objectMode&&E(gt);return Be&&!Ot.isBuffer(gt)&&(gt=ne(gt)),typeof _t=="function"&&(We=_t,_t=null),Be?_t="buffer":_t||(_t=Ae.defaultEncoding),typeof We!="function"&&(We=b),Ae.ended?re(this,We):(Be||ae(this,Ae,gt,We))&&(Ae.pendingcb++,Se=ve(this,Ae,Be,gt,_t,We)),Se},x.prototype.cork=function(){this._writableState.corked++},x.prototype.uncork=function(){var gt=this._writableState;gt.corked&&(gt.corked--,gt.writing||gt.corked||gt.finished||gt.bufferProcessing||!gt.bufferedRequest||ke(this,gt))},x.prototype.setDefaultEncoding=function(gt){if(typeof gt=="string"&&(gt=gt.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((gt+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+gt);return this._writableState.defaultEncoding=gt,this},Object.defineProperty(x.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),x.prototype._write=function(gt,_t,We){We(new Error("_write() is not implemented"))},x.prototype._writev=null,x.prototype.end=function(gt,_t,We){var Ae=this._writableState;typeof gt=="function"?(We=gt,gt=null,_t=null):typeof _t=="function"&&(We=_t,_t=null),gt!=null&&this.write(gt,_t),Ae.corked&&(Ae.corked=1,this.uncork()),Ae.ending||Ae.finished||Pe(this,Ae,We)},Object.defineProperty(x.prototype,"destroyed",{get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(gt){this._writableState&&(this._writableState.destroyed=gt)}}),x.prototype.destroy=Rt.destroy,x.prototype._undestroy=Rt.undestroy,x.prototype._destroy=function(gt,_t){this.end(),_t(gt)}}).call(this,ie("_process"),typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./_stream_duplex":179,"./internal/streams/destroy":185,"./internal/streams/stream":186,_process:173,"babel-runtime/core-js/object/define-property":20,"babel-runtime/core-js/set-immediate":25,"babel-runtime/core-js/symbol":27,"babel-runtime/core-js/symbol/has-instance":28,"core-util-is":153,inherits:162,"process-nextick-args":172,"safe-buffer":193,"util-deprecate":205}],184:[function(ie,Ce,ue){"use strict";function se(ne,E){if(!(ne instanceof E))throw new TypeError("Cannot call a class as a function")}function te(ne,E,b){ne.copy(E,b)}var le=ie("safe-buffer").Buffer,ee=ie("util");Ce.exports=function(){function ne(){se(this,ne),this.head=null,this.tail=null,this.length=0}return ne.prototype.push=function(E){var b={data:E,next:null};this.length>0?this.tail.next=b:this.head=b,this.tail=b,++this.length},ne.prototype.unshift=function(E){var b={data:E,next:this.head};this.length===0&&(this.tail=b),this.head=b,++this.length},ne.prototype.shift=function(){if(this.length!==0){var E=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,E}},ne.prototype.clear=function(){this.head=this.tail=null,this.length=0},ne.prototype.join=function(E){if(this.length===0)return"";for(var b=this.head,z=""+b.data;b=b.next;)z+=E+b.data;return z},ne.prototype.concat=function(E){if(this.length===0)return le.alloc(0);if(this.length===1)return this.head.data;for(var b=le.allocUnsafe(E>>>0),z=this.head,x=0;z;)te(z.data,b,x),x+=z.data.length,z=z.next;return b},ne}(),ee&&ee.inspect&&ee.inspect.custom&&(Ce.exports.prototype[ee.inspect.custom]=function(){var ne=ee.inspect({length:this.length});return this.constructor.name+" "+ne})},{"safe-buffer":193,util:36}],185:[function(ie,Ce,ue){"use strict";function se(ne,E){var b=this,z=this._readableState&&this._readableState.destroyed,x=this._writableState&&this._writableState.destroyed;return z||x?(E?E(ne):!ne||this._writableState&&this._writableState.errorEmitted||ee.nextTick(le,this,ne),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(ne||null,function(re){!E&&re?(ee.nextTick(le,b,re),b._writableState&&(b._writableState.errorEmitted=!0)):E&&E(re)}),this)}function te(){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 le(ne,E){ne.emit("error",E)}var ee=ie("process-nextick-args");Ce.exports={destroy:se,undestroy:te}},{"process-nextick-args":172}],186:[function(ie,Ce,ue){"use strict";Ce.exports=ie("events").EventEmitter},{events:158}],187:[function(ie,Ce,ue){Ce.exports=ie("./readable").PassThrough},{"./readable":188}],188:[function(ie,Ce,ue){ue=Ce.exports=ie("./lib/_stream_readable.js"),ue.Stream=ue,ue.Readable=ue,ue.Writable=ie("./lib/_stream_writable.js"),ue.Duplex=ie("./lib/_stream_duplex.js"),ue.Transform=ie("./lib/_stream_transform.js"),ue.PassThrough=ie("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":179,"./lib/_stream_passthrough.js":180,"./lib/_stream_readable.js":181,"./lib/_stream_transform.js":182,"./lib/_stream_writable.js":183}],189:[function(ie,Ce,ue){Ce.exports=ie("./readable").Transform},{"./readable":188}],190:[function(ie,Ce,ue){Ce.exports=ie("./lib/_stream_writable.js")},{"./lib/_stream_writable.js":183}],191:[function(ie,Ce,ue){var se=function(){return this}()||Function("return this")(),te=se.regeneratorRuntime&&Object.getOwnPropertyNames(se).indexOf("regeneratorRuntime")>=0,le=te&&se.regeneratorRuntime;if(se.regeneratorRuntime=void 0,Ce.exports=ie("./runtime"),te)se.regeneratorRuntime=le;else try{delete se.regeneratorRuntime}catch(ee){se.regeneratorRuntime=void 0}},{"./runtime":192}],192:[function(ie,Ce,ue){(function(se){"use strict";function te(ze,Ve,$e,nt){var et=Ve&&Ve.prototype instanceof ee?Ve:ee,pt=Object.create(et.prototype),ct=new ve(nt||[]);return pt._invoke=x(ze,$e,ct),pt}function le(ze,Ve,$e){try{return{type:"normal",arg:ze.call(Ve,$e)}}catch(nt){return{type:"throw",arg:nt}}}function ee(){}function ne(){}function E(){}function b(ze){["next","throw","return"].forEach(function(Ve){ze[Ve]=function($e){return this._invoke(Ve,$e)}})}function z(ze){function Ve(et,pt,ct,Ot){var dt=le(ze[et],ze,pt);if(dt.type!=="throw"){var Rt=dt.arg,xt=Rt.value;return xt&&typeof xt=="object"&&he.call(xt,"__await")?Promise.resolve(xt.__await).then(function(gt){Ve("next",gt,ct,Ot)},function(gt){Ve("throw",gt,ct,Ot)}):Promise.resolve(xt).then(function(gt){Rt.value=gt,ct(Rt)},Ot)}Ot(dt.arg)}function $e(et,pt){function ct(){return new Promise(function(Ot,dt){Ve(et,pt,Ot,dt)})}return nt=nt?nt.then(ct,ct):ct()}var nt;this._invoke=$e}function x(ze,Ve,$e){var nt=Pe;return function(et,pt){if(nt===Xe)throw new Error("Generator is already running");if(nt===ot){if(et==="throw")throw pt;return me()}for($e.method=et,$e.arg=pt;;){var ct=$e.delegate;if(ct){var Ot=re(ct,$e);if(Ot){if(Ot===He)continue;return Ot}}if($e.method==="next")$e.sent=$e._sent=$e.arg;else if($e.method==="throw"){if(nt===Pe)throw nt=ot,$e.arg;$e.dispatchException($e.arg)}else $e.method==="return"&&$e.abrupt("return",$e.arg);nt=Xe;var dt=le(ze,Ve,$e);if(dt.type==="normal"){if(nt=$e.done?ot:Qe,dt.arg===He)continue;return{value:dt.arg,done:$e.done}}dt.type==="throw"&&(nt=ot,$e.method="throw",$e.arg=dt.arg)}}}function re(ze,Ve){var $e=ze.iterator[Ve.method];if($e===ge){if(Ve.delegate=null,Ve.method==="throw"){if(ze.iterator.return&&(Ve.method="return",Ve.arg=ge,re(ze,Ve),Ve.method==="throw"))return He;Ve.method="throw",Ve.arg=new TypeError("The iterator does not provide a 'throw' method")}return He}var nt=le($e,ze.iterator,Ve.arg);if(nt.type==="throw")return Ve.method="throw",Ve.arg=nt.arg,Ve.delegate=null,He;var et=nt.arg;return et?et.done?(Ve[ze.resultName]=et.value,Ve.next=ze.nextLoc,Ve.method!=="return"&&(Ve.method="next",Ve.arg=ge),Ve.delegate=null,He):et:(Ve.method="throw",Ve.arg=new TypeError("iterator result is not an object"),Ve.delegate=null,He)}function ae(ze){var Ve={tryLoc:ze[0]};1 in ze&&(Ve.catchLoc=ze[1]),2 in ze&&(Ve.finallyLoc=ze[2],Ve.afterLoc=ze[3]),this.tryEntries.push(Ve)}function oe(ze){var Ve=ze.completion||{};Ve.type="normal",delete Ve.arg,ze.completion=Ve}function ve(ze){this.tryEntries=[{tryLoc:"root"}],ze.forEach(ae,this),this.reset(!0)}function ye(ze){if(ze){var Ve=ze[ke];if(Ve)return Ve.call(ze);if(typeof ze.next=="function")return ze;if(!isNaN(ze.length)){var $e=-1,nt=function et(){for(;++$e<ze.length;)if(he.call(ze,$e))return et.value=ze[$e],et.done=!1,et;return et.value=ge,et.done=!0,et};return nt.next=nt}}return{next:me}}function me(){return{value:ge,done:!0}}var ge,_e=Object.prototype,he=_e.hasOwnProperty,pe=typeof Symbol=="function"?Symbol:{},ke=pe.iterator||"@@iterator",Te=pe.asyncIterator||"@@asyncIterator",Ee=pe.toStringTag||"@@toStringTag",Oe=typeof Ce=="object",je=se.regeneratorRuntime;if(je)return void(Oe&&(Ce.exports=je));je=se.regeneratorRuntime=Oe?Ce.exports:{},je.wrap=te;var Pe="suspendedStart",Qe="suspendedYield",Xe="executing",ot="completed",He={},rt={};rt[ke]=function(){return this};var Ye=Object.getPrototypeOf,ut=Ye&&Ye(Ye(ye([])));ut&&ut!==_e&&he.call(ut,ke)&&(rt=ut);var Ge=E.prototype=ee.prototype=Object.create(rt);ne.prototype=Ge.constructor=E,E.constructor=ne,E[Ee]=ne.displayName="GeneratorFunction",je.isGeneratorFunction=function(ze){var Ve=typeof ze=="function"&&ze.constructor;return!!Ve&&(Ve===ne||(Ve.displayName||Ve.name)==="GeneratorFunction")},je.mark=function(ze){return Object.setPrototypeOf?Object.setPrototypeOf(ze,E):(ze.__proto__=E,Ee in ze||(ze[Ee]="GeneratorFunction")),ze.prototype=Object.create(Ge),ze},je.awrap=function(ze){return{__await:ze}},b(z.prototype),z.prototype[Te]=function(){return this},je.AsyncIterator=z,je.async=function(ze,Ve,$e,nt){var et=new z(te(ze,Ve,$e,nt));return je.isGeneratorFunction(Ve)?et:et.next().then(function(pt){return pt.done?pt.value:et.next()})},b(Ge),Ge[Ee]="Generator",Ge[ke]=function(){return this},Ge.toString=function(){return"[object Generator]"},je.keys=function(ze){var Ve=[];for(var $e in ze)Ve.push($e);return Ve.reverse(),function nt(){for(;Ve.length;){var et=Ve.pop();if(et in ze)return nt.value=et,nt.done=!1,nt}return nt.done=!0,nt}},je.values=ye,ve.prototype={constructor:ve,reset:function(ze){if(this.prev=0,this.next=0,this.sent=this._sent=ge,this.done=!1,this.delegate=null,this.method="next",this.arg=ge,this.tryEntries.forEach(oe),!ze)for(var Ve in this)Ve.charAt(0)==="t"&&he.call(this,Ve)&&!isNaN(+Ve.slice(1))&&(this[Ve]=ge)},stop:function(){this.done=!0;var ze=this.tryEntries[0],Ve=ze.completion;if(Ve.type==="throw")throw Ve.arg;return this.rval},dispatchException:function(ze){function Ve(dt,Rt){return pt.type="throw",pt.arg=ze,$e.next=dt,Rt&&($e.method="next",$e.arg=ge),!!Rt}if(this.done)throw ze;for(var $e=this,nt=this.tryEntries.length-1;nt>=0;--nt){var et=this.tryEntries[nt],pt=et.completion;if(et.tryLoc==="root")return Ve("end");if(et.tryLoc<=this.prev){var ct=he.call(et,"catchLoc"),Ot=he.call(et,"finallyLoc");if(ct&&Ot){if(this.prev<et.catchLoc)return Ve(et.catchLoc,!0);if(this.prev<et.finallyLoc)return Ve(et.finallyLoc)}else if(ct){if(this.prev<et.catchLoc)return Ve(et.catchLoc,!0)}else{if(!Ot)throw new Error("try statement without catch or finally");if(this.prev<et.finallyLoc)return Ve(et.finallyLoc)}}}},abrupt:function(ze,Ve){for(var $e=this.tryEntries.length-1;$e>=0;--$e){var nt=this.tryEntries[$e];if(nt.tryLoc<=this.prev&&he.call(nt,"finallyLoc")&&this.prev<nt.finallyLoc){var et=nt;break}}et&&(ze==="break"||ze==="continue")&&et.tryLoc<=Ve&&Ve<=et.finallyLoc&&(et=null);var pt=et?et.completion:{};return pt.type=ze,pt.arg=Ve,et?(this.method="next",this.next=et.finallyLoc,He):this.complete(pt)},complete:function(ze,Ve){if(ze.type==="throw")throw ze.arg;return ze.type==="break"||ze.type==="continue"?this.next=ze.arg:ze.type==="return"?(this.rval=this.arg=ze.arg,this.method="return",this.next="end"):ze.type==="normal"&&Ve&&(this.next=Ve),He},finish:function(ze){for(var Ve=this.tryEntries.length-1;Ve>=0;--Ve){var $e=this.tryEntries[Ve];if($e.finallyLoc===ze)return this.complete($e.completion,$e.afterLoc),oe($e),He}},catch:function(ze){for(var Ve=this.tryEntries.length-1;Ve>=0;--Ve){var $e=this.tryEntries[Ve];if($e.tryLoc===ze){var nt=$e.completion;if(nt.type==="throw"){var et=nt.arg;oe($e)}return et}}throw new Error("illegal catch attempt")},delegateYield:function(ze,Ve,$e){return this.delegate={iterator:ye(ze),resultName:Ve,nextLoc:$e},this.method==="next"&&(this.arg=ge),He}}})(function(){return this}()||Function("return this")())},{}],193:[function(ie,Ce,ue){function se(ne,E){for(var b in ne)E[b]=ne[b]}function te(ne,E,b){return ee(ne,E,b)}var le=ie("buffer"),ee=le.Buffer;ee.from&&ee.alloc&&ee.allocUnsafe&&ee.allocUnsafeSlow?Ce.exports=le:(se(le,ue),ue.Buffer=te),se(ee,te),te.from=function(ne,E,b){if(typeof ne=="number")throw new TypeError("Argument must not be a number");return ee(ne,E,b)},te.alloc=function(ne,E,b){if(typeof ne!="number")throw new TypeError("Argument must be a number");var z=ee(ne);return E!==void 0?typeof b=="string"?z.fill(E,b):z.fill(E):z.fill(0),z},te.allocUnsafe=function(ne){if(typeof ne!="number")throw new TypeError("Argument must be a number");return ee(ne)},te.allocUnsafeSlow=function(ne){if(typeof ne!="number")throw new TypeError("Argument must be a number");return le.SlowBuffer(ne)}},{buffer:38}],194:[function(ie,Ce,ue){(function(se){"use strict";function te(me){return me&&me.__esModule?me:{default:me}}var le=ie("babel-runtime/core-js/string/from-code-point"),ee=te(le),ne=ie("babel-runtime/core-js/json/stringify"),E=te(ne),b=ie("babel-runtime/helpers/typeof"),z=te(b),x=ie("babel-runtime/core-js/object/define-property"),re=te(x),ae=ie("babel-runtime/core-js/object/keys"),oe=te(ae),ve=ie("babel-runtime/core-js/object/create"),ye=te(ve);(function(me){function ge(Me,Re){if(!(this instanceof ge))return new ge(Me,Re);var tt=this;he(tt),tt.q=tt.c="",tt.bufferCheckPosition=me.MAX_BUFFER_LENGTH,tt.opt=Re||{},tt.opt.lowercase=tt.opt.lowercase||tt.opt.lowercasetags,tt.looseCase=tt.opt.lowercase?"toLowerCase":"toUpperCase",tt.tags=[],tt.closed=tt.closedRoot=tt.sawRoot=!1,tt.tag=tt.error=null,tt.strict=!!Me,tt.noscript=!(!Me&&!tt.opt.noscript),tt.state=Le.BEGIN,tt.strictEntities=tt.opt.strictEntities,tt.ENTITIES=tt.strictEntities?(0,ye.default)(me.XML_ENTITIES):(0,ye.default)(me.ENTITIES),tt.attribList=[],tt.opt.xmlns&&(tt.ns=(0,ye.default)(Be)),tt.trackPosition=tt.opt.position!==!1,tt.trackPosition&&(tt.position=tt.line=tt.column=0),Xe(tt,"onready")}function _e(Me){for(var Re=Math.max(me.MAX_BUFFER_LENGTH,10),tt=0,lt=0,Nt=Rt.length;lt<Nt;lt++){var Ct=Me[Rt[lt]].length;if(Ct>Re)switch(Rt[lt]){case"textNode":He(Me);break;case"cdata":ot(Me,"oncdata",Me.cdata),Me.cdata="";break;case"script":ot(Me,"onscript",Me.script),Me.script="";break;default:Ye(Me,"Max buffer length exceeded: "+Rt[lt])}tt=Math.max(tt,Ct)}var vt=me.MAX_BUFFER_LENGTH-tt;Me.bufferCheckPosition=vt+Me.position}function he(Me){for(var Re=0,tt=Rt.length;Re<tt;Re++)Me[Rt[Re]]=""}function pe(Me){He(Me),Me.cdata!==""&&(ot(Me,"oncdata",Me.cdata),Me.cdata=""),Me.script!==""&&(ot(Me,"onscript",Me.script),Me.script="")}function ke(Me,Re){return new Te(Me,Re)}function Te(Me,Re){if(!(this instanceof Te))return new Te(Me,Re);xt.apply(this),this._parser=new ge(Me,Re),this.writable=!0,this.readable=!0;var tt=this;this._parser.onend=function(){tt.emit("end")},this._parser.onerror=function(lt){tt.emit("error",lt),tt._parser.error=null},this._decoder=null,gt.forEach(function(lt){(0,re.default)(tt,"on"+lt,{get:function(){return tt._parser["on"+lt]},set:function(Nt){if(!Nt)return tt.removeAllListeners(lt),tt._parser["on"+lt]=Nt,Nt;tt.on(lt,Nt)},enumerable:!0,configurable:!1})})}function Ee(Me){return Me===" "||Me===`
|
|
|
`||Me==="\r"||Me===" "}function Oe(Me){return Me==='"'||Me==="'"}function je(Me){return Me===">"||Ee(Me)}function Pe(Me,Re){return Me.test(Re)}function Qe(Me,Re){return!Pe(Me,Re)}function Xe(Me,Re,tt){Me[Re]&&Me[Re](tt)}function ot(Me,Re,tt){Me.textNode&&He(Me),Xe(Me,Re,tt)}function He(Me){Me.textNode=rt(Me.opt,Me.textNode),Me.textNode&&Xe(Me,"ontext",Me.textNode),Me.textNode=""}function rt(Me,Re){return Me.trim&&(Re=Re.trim()),Me.normalize&&(Re=Re.replace(/\s+/g," ")),Re}function Ye(Me,Re){return He(Me),Me.trackPosition&&(Re+=`
|
|
|
Line: `+Me.line+`
|
|
|
Column: `+Me.column+`
|
|
|
Char: `+Me.c),Re=new Error(Re),Me.error=Re,Xe(Me,"onerror",Re),Me}function ut(Me){return Me.sawRoot&&!Me.closedRoot&&Ge(Me,"Unclosed root tag"),Me.state!==Le.BEGIN&&Me.state!==Le.BEGIN_WHITESPACE&&Me.state!==Le.TEXT&&Ye(Me,"Unexpected end"),He(Me),Me.c="",Me.closed=!0,Xe(Me,"onend"),ge.call(Me,Me.strict,Me.opt),Me}function Ge(Me,Re){if((Me===void 0?"undefined":(0,z.default)(Me))!=="object"||!(Me instanceof ge))throw new Error("bad call to strictFail");Me.strict&&Ye(Me,Re)}function ze(Me){Me.strict||(Me.tagName=Me.tagName[Me.looseCase]());var Re=Me.tags[Me.tags.length-1]||Me,tt=Me.tag={name:Me.tagName,attributes:{}};Me.opt.xmlns&&(tt.ns=Re.ns),Me.attribList.length=0,ot(Me,"onopentagstart",tt)}function Ve(Me,Re){var tt=Me.indexOf(":"),lt=tt<0?["",Me]:Me.split(":"),Nt=lt[0],Ct=lt[1];return Re&&Me==="xmlns"&&(Nt="xmlns",Ct=""),{prefix:Nt,local:Ct}}function $e(Me){if(Me.strict||(Me.attribName=Me.attribName[Me.looseCase]()),Me.attribList.indexOf(Me.attribName)!==-1||Me.tag.attributes.hasOwnProperty(Me.attribName))return void(Me.attribName=Me.attribValue="");if(Me.opt.xmlns){var Re=Ve(Me.attribName,!0),tt=Re.prefix,lt=Re.local;if(tt==="xmlns")if(lt==="xml"&&Me.attribValue!==Ae)Ge(Me,"xml: prefix must be bound to "+Ae+`
|
|
|
Actual: `+Me.attribValue);else if(lt==="xmlns"&&Me.attribValue!==Se)Ge(Me,"xmlns: prefix must be bound to "+Se+`
|
|
|
Actual: `+Me.attribValue);else{var Nt=Me.tag,Ct=Me.tags[Me.tags.length-1]||Me;Nt.ns===Ct.ns&&(Nt.ns=(0,ye.default)(Ct.ns)),Nt.ns[lt]=Me.attribValue}Me.attribList.push([Me.attribName,Me.attribValue])}else Me.tag.attributes[Me.attribName]=Me.attribValue,ot(Me,"onattribute",{name:Me.attribName,value:Me.attribValue});Me.attribName=Me.attribValue=""}function nt(Me,Re){if(Me.opt.xmlns){var tt=Me.tag,lt=Ve(Me.tagName);tt.prefix=lt.prefix,tt.local=lt.local,tt.uri=tt.ns[lt.prefix]||"",tt.prefix&&!tt.uri&&(Ge(Me,"Unbound namespace prefix: "+(0,E.default)(Me.tagName)),tt.uri=lt.prefix);var Nt=Me.tags[Me.tags.length-1]||Me;tt.ns&&Nt.ns!==tt.ns&&(0,oe.default)(tt.ns).forEach(function(wn){ot(Me,"onopennamespace",{prefix:wn,uri:tt.ns[wn]})});for(var Ct=0,vt=Me.attribList.length;Ct<vt;Ct++){var Pt=Me.attribList[Ct],Ht=Pt[0],jt=Pt[1],yt=Ve(Ht,!0),Yt=yt.prefix,Lt=yt.local,Kt=Yt===""?"":tt.ns[Yt]||"",sn={name:Ht,value:jt,prefix:Yt,local:Lt,uri:Kt};Yt&&Yt!=="xmlns"&&!Kt&&(Ge(Me,"Unbound namespace prefix: "+(0,E.default)(Yt)),sn.uri=Yt),Me.tag.attributes[Ht]=sn,ot(Me,"onattribute",sn)}Me.attribList.length=0}Me.tag.isSelfClosing=!!Re,Me.sawRoot=!0,Me.tags.push(Me.tag),ot(Me,"onopentag",Me.tag),Re||(Me.noscript||Me.tagName.toLowerCase()!=="script"?Me.state=Le.TEXT:Me.state=Le.SCRIPT,Me.tag=null,Me.tagName=""),Me.attribName=Me.attribValue="",Me.attribList.length=0}function et(Me){if(!Me.tagName)return Ge(Me,"Weird empty close tag."),Me.textNode+="</>",void(Me.state=Le.TEXT);if(Me.script){if(Me.tagName!=="script")return Me.script+="</"+Me.tagName+">",Me.tagName="",void(Me.state=Le.SCRIPT);ot(Me,"onscript",Me.script),Me.script=""}var Re=Me.tags.length,tt=Me.tagName;Me.strict||(tt=tt[Me.looseCase]());for(var lt=tt;Re--&&Me.tags[Re].name!==lt;)Ge(Me,"Unexpected close tag");if(Re<0)return Ge(Me,"Unmatched closing tag: "+Me.tagName),Me.textNode+="</"+Me.tagName+">",void(Me.state=Le.TEXT);Me.tagName=tt;for(var Nt=Me.tags.length;Nt-- >Re;){var Ct=Me.tag=Me.tags.pop();Me.tagName=Me.tag.name,ot(Me,"onclosetag",Me.tagName);var vt={};for(var Pt in Ct.ns)vt[Pt]=Ct.ns[Pt];var Ht=Me.tags[Me.tags.length-1]||Me;Me.opt.xmlns&&Ct.ns!==Ht.ns&&(0,oe.default)(Ct.ns).forEach(function(jt){var yt=Ct.ns[jt];ot(Me,"onclosenamespace",{prefix:jt,uri:yt})})}Re===0&&(Me.closedRoot=!0),Me.tagName=Me.attribValue=Me.attribName="",Me.attribList.length=0,Me.state=Le.TEXT}function pt(Me){var Re,tt=Me.entity,lt=tt.toLowerCase(),Nt="";return Me.ENTITIES[tt]?Me.ENTITIES[tt]:Me.ENTITIES[lt]?Me.ENTITIES[lt]:(tt=lt,tt.charAt(0)==="#"&&(tt.charAt(1)==="x"?(tt=tt.slice(2),Re=parseInt(tt,16),Nt=Re.toString(16)):(tt=tt.slice(1),Re=parseInt(tt,10),Nt=Re.toString(10))),tt=tt.replace(/^0+/,""),isNaN(Re)||Nt.toLowerCase()!==tt?(Ge(Me,"Invalid character entity"),"&"+Me.entity+";"):(0,ee.default)(Re))}function ct(Me,Re){Re==="<"?(Me.state=Le.OPEN_WAKA,Me.startTagPosition=Me.position):Ee(Re)||(Ge(Me,"Non-whitespace before first tag."),Me.textNode=Re,Me.state=Le.TEXT)}function Ot(Me,Re){var tt="";return Re<Me.length&&(tt=Me.charAt(Re)),tt}function dt(Me){var Re=this;if(this.error)throw this.error;if(Re.closed)return Ye(Re,"Cannot write after close. Assign an onready handler.");if(Me===null)return ut(Re);(Me===void 0?"undefined":(0,z.default)(Me))==="object"&&(Me=Me.toString());for(var tt=0,lt="";lt=Ot(Me,tt++),Re.c=lt,!!lt;)switch(Re.trackPosition&&(Re.position++,lt===`
|
|
|
`?(Re.line++,Re.column=0):Re.column++),Re.state){case Le.BEGIN:if(Re.state=Le.BEGIN_WHITESPACE,lt==="\uFEFF")continue;ct(Re,lt);continue;case Le.BEGIN_WHITESPACE:ct(Re,lt);continue;case Le.TEXT:if(Re.sawRoot&&!Re.closedRoot){for(var Nt=tt-1;lt&<!=="<"&<!=="&";)(lt=Ot(Me,tt++))&&Re.trackPosition&&(Re.position++,lt===`
|
|
|
`?(Re.line++,Re.column=0):Re.column++);Re.textNode+=Me.substring(Nt,tt-1)}lt!=="<"||Re.sawRoot&&Re.closedRoot&&!Re.strict?(Ee(lt)||Re.sawRoot&&!Re.closedRoot||Ge(Re,"Text data outside of root node."),lt==="&"?Re.state=Le.TEXT_ENTITY:Re.textNode+=lt):(Re.state=Le.OPEN_WAKA,Re.startTagPosition=Re.position);continue;case Le.SCRIPT:lt==="<"?Re.state=Le.SCRIPT_ENDING:Re.script+=lt;continue;case Le.SCRIPT_ENDING:lt==="/"?Re.state=Le.CLOSE_TAG:(Re.script+="<"+lt,Re.state=Le.SCRIPT);continue;case Le.OPEN_WAKA:if(lt==="!")Re.state=Le.SGML_DECL,Re.sgmlDecl="";else if(!Ee(lt))if(Pe(Ke,lt))Re.state=Le.OPEN_TAG,Re.tagName=lt;else if(lt==="/")Re.state=Le.CLOSE_TAG,Re.tagName="";else if(lt==="?")Re.state=Le.PROC_INST,Re.procInstName=Re.procInstBody="";else{if(Ge(Re,"Unencoded <"),Re.startTagPosition+1<Re.position){var Ct=Re.position-Re.startTagPosition;lt=new Array(Ct).join(" ")+lt}Re.textNode+="<"+lt,Re.state=Le.TEXT}continue;case Le.SGML_DECL:(Re.sgmlDecl+lt).toUpperCase()===_t?(ot(Re,"onopencdata"),Re.state=Le.CDATA,Re.sgmlDecl="",Re.cdata=""):Re.sgmlDecl+lt==="--"?(Re.state=Le.COMMENT,Re.comment="",Re.sgmlDecl=""):(Re.sgmlDecl+lt).toUpperCase()===We?(Re.state=Le.DOCTYPE,(Re.doctype||Re.sawRoot)&&Ge(Re,"Inappropriately located doctype declaration"),Re.doctype="",Re.sgmlDecl=""):lt===">"?(ot(Re,"onsgmldeclaration",Re.sgmlDecl),Re.sgmlDecl="",Re.state=Le.TEXT):(Oe(lt)&&(Re.state=Le.SGML_DECL_QUOTED),Re.sgmlDecl+=lt);continue;case Le.SGML_DECL_QUOTED:lt===Re.q&&(Re.state=Le.SGML_DECL,Re.q=""),Re.sgmlDecl+=lt;continue;case Le.DOCTYPE:lt===">"?(Re.state=Le.TEXT,ot(Re,"ondoctype",Re.doctype),Re.doctype=!0):(Re.doctype+=lt,lt==="["?Re.state=Le.DOCTYPE_DTD:Oe(lt)&&(Re.state=Le.DOCTYPE_QUOTED,Re.q=lt));continue;case Le.DOCTYPE_QUOTED:Re.doctype+=lt,lt===Re.q&&(Re.q="",Re.state=Le.DOCTYPE);continue;case Le.DOCTYPE_DTD:Re.doctype+=lt,lt==="]"?Re.state=Le.DOCTYPE:Oe(lt)&&(Re.state=Le.DOCTYPE_DTD_QUOTED,Re.q=lt);continue;case Le.DOCTYPE_DTD_QUOTED:Re.doctype+=lt,lt===Re.q&&(Re.state=Le.DOCTYPE_DTD,Re.q="");continue;case Le.COMMENT:lt==="-"?Re.state=Le.COMMENT_ENDING:Re.comment+=lt;continue;case Le.COMMENT_ENDING:lt==="-"?(Re.state=Le.COMMENT_ENDED,Re.comment=rt(Re.opt,Re.comment),Re.comment&&ot(Re,"oncomment",Re.comment),Re.comment=""):(Re.comment+="-"+lt,Re.state=Le.COMMENT);continue;case Le.COMMENT_ENDED:lt!==">"?(Ge(Re,"Malformed comment"),Re.comment+="--"+lt,Re.state=Le.COMMENT):Re.state=Le.TEXT;continue;case Le.CDATA:lt==="]"?Re.state=Le.CDATA_ENDING:Re.cdata+=lt;continue;case Le.CDATA_ENDING:lt==="]"?Re.state=Le.CDATA_ENDING_2:(Re.cdata+="]"+lt,Re.state=Le.CDATA);continue;case Le.CDATA_ENDING_2:lt===">"?(Re.cdata&&ot(Re,"oncdata",Re.cdata),ot(Re,"onclosecdata"),Re.cdata="",Re.state=Le.TEXT):lt==="]"?Re.cdata+="]":(Re.cdata+="]]"+lt,Re.state=Le.CDATA);continue;case Le.PROC_INST:lt==="?"?Re.state=Le.PROC_INST_ENDING:Ee(lt)?Re.state=Le.PROC_INST_BODY:Re.procInstName+=lt;continue;case Le.PROC_INST_BODY:if(!Re.procInstBody&&Ee(lt))continue;lt==="?"?Re.state=Le.PROC_INST_ENDING:Re.procInstBody+=lt;continue;case Le.PROC_INST_ENDING:lt===">"?(ot(Re,"onprocessinginstruction",{name:Re.procInstName,body:Re.procInstBody}),Re.procInstName=Re.procInstBody="",Re.state=Le.TEXT):(Re.procInstBody+="?"+lt,Re.state=Le.PROC_INST_BODY);continue;case Le.OPEN_TAG:Pe(Ne,lt)?Re.tagName+=lt:(ze(Re),lt===">"?nt(Re):lt==="/"?Re.state=Le.OPEN_TAG_SLASH:(Ee(lt)||Ge(Re,"Invalid character in tag name"),Re.state=Le.ATTRIB));continue;case Le.OPEN_TAG_SLASH:lt===">"?(nt(Re,!0),et(Re)):(Ge(Re,"Forward-slash in opening tag not followed by >"),Re.state=Le.ATTRIB);continue;case Le.ATTRIB:if(Ee(lt))continue;lt===">"?nt(Re):lt==="/"?Re.state=Le.OPEN_TAG_SLASH:Pe(Ke,lt)?(Re.attribName=lt,Re.attribValue="",Re.state=Le.ATTRIB_NAME):Ge(Re,"Invalid attribute name");continue;case Le.ATTRIB_NAME:lt==="="?Re.state=Le.ATTRIB_VALUE:lt===">"?(Ge(Re,"Attribute without value"),Re.attribValue=Re.attribName,$e(Re),nt(Re)):Ee(lt)?Re.state=Le.ATTRIB_NAME_SAW_WHITE:Pe(Ne,lt)?Re.attribName+=lt:Ge(Re,"Invalid attribute name");continue;case Le.ATTRIB_NAME_SAW_WHITE:if(lt==="=")Re.state=Le.ATTRIB_VALUE;else{if(Ee(lt))continue;Ge(Re,"Attribute without value"),Re.tag.attributes[Re.attribName]="",Re.attribValue="",ot(Re,"onattribute",{name:Re.attribName,value:""}),Re.attribName="",lt===">"?nt(Re):Pe(Ke,lt)?(Re.attribName=lt,Re.state=Le.ATTRIB_NAME):(Ge(Re,"Invalid attribute name"),Re.state=Le.ATTRIB)}continue;case Le.ATTRIB_VALUE:if(Ee(lt))continue;Oe(lt)?(Re.q=lt,Re.state=Le.ATTRIB_VALUE_QUOTED):(Ge(Re,"Unquoted attribute value"),Re.state=Le.ATTRIB_VALUE_UNQUOTED,Re.attribValue=lt);continue;case Le.ATTRIB_VALUE_QUOTED:if(lt!==Re.q){lt==="&"?Re.state=Le.ATTRIB_VALUE_ENTITY_Q:Re.attribValue+=lt;continue}$e(Re),Re.q="",Re.state=Le.ATTRIB_VALUE_CLOSED;continue;case Le.ATTRIB_VALUE_CLOSED:Ee(lt)?Re.state=Le.ATTRIB:lt===">"?nt(Re):lt==="/"?Re.state=Le.OPEN_TAG_SLASH:Pe(Ke,lt)?(Ge(Re,"No whitespace between attributes"),Re.attribName=lt,Re.attribValue="",Re.state=Le.ATTRIB_NAME):Ge(Re,"Invalid attribute name");continue;case Le.ATTRIB_VALUE_UNQUOTED:if(!je(lt)){lt==="&"?Re.state=Le.ATTRIB_VALUE_ENTITY_U:Re.attribValue+=lt;continue}$e(Re),lt===">"?nt(Re):Re.state=Le.ATTRIB;continue;case Le.CLOSE_TAG:if(Re.tagName)lt===">"?et(Re):Pe(Ne,lt)?Re.tagName+=lt:Re.script?(Re.script+="</"+Re.tagName,Re.tagName="",Re.state=Le.SCRIPT):(Ee(lt)||Ge(Re,"Invalid tagname in closing tag"),Re.state=Le.CLOSE_TAG_SAW_WHITE);else{if(Ee(lt))continue;Qe(Ke,lt)?Re.script?(Re.script+="</"+lt,Re.state=Le.SCRIPT):Ge(Re,"Invalid tagname in closing tag."):Re.tagName=lt}continue;case Le.CLOSE_TAG_SAW_WHITE:if(Ee(lt))continue;lt===">"?et(Re):Ge(Re,"Invalid characters in closing tag");continue;case Le.TEXT_ENTITY:case Le.ATTRIB_VALUE_ENTITY_Q:case Le.ATTRIB_VALUE_ENTITY_U:var vt,Pt;switch(Re.state){case Le.TEXT_ENTITY:vt=Le.TEXT,Pt="textNode";break;case Le.ATTRIB_VALUE_ENTITY_Q:vt=Le.ATTRIB_VALUE_QUOTED,Pt="attribValue";break;case Le.ATTRIB_VALUE_ENTITY_U:vt=Le.ATTRIB_VALUE_UNQUOTED,Pt="attribValue"}lt===";"?(Re[Pt]+=pt(Re),Re.entity="",Re.state=vt):Pe(Re.entity.length?we:De,lt)?Re.entity+=lt:(Ge(Re,"Invalid character in entity name"),Re[Pt]+="&"+Re.entity+lt,Re.entity="",Re.state=vt);continue;default:throw new Error(Re,"Unknown state: "+Re.state)}return Re.position>=Re.bufferCheckPosition&&_e(Re),Re}me.parser=function(Me,Re){return new ge(Me,Re)},me.SAXParser=ge,me.SAXStream=Te,me.createStream=ke,me.MAX_BUFFER_LENGTH=65536;var Rt=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];me.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"],ye.default||(Object.create=function(Me){function Re(){}return Re.prototype=Me,new Re}),oe.default||(Object.keys=function(Me){var Re=[];for(var tt in Me)Me.hasOwnProperty(tt)&&Re.push(tt);return Re}),ge.prototype={end:function(){ut(this)},write:dt,resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){pe(this)}};var xt;try{xt=ie("stream").Stream}catch(Me){xt=function(){}}var gt=me.EVENTS.filter(function(Me){return Me!=="error"&&Me!=="end"});Te.prototype=(0,ye.default)(xt.prototype,{constructor:{value:Te}}),Te.prototype.write=function(Me){if(typeof se=="function"&&typeof se.isBuffer=="function"&&se.isBuffer(Me)){if(!this._decoder){var Re=ie("string_decoder").StringDecoder;this._decoder=new Re("utf8")}Me=this._decoder.write(Me)}return this._parser.write(Me.toString()),this.emit("data",Me),!0},Te.prototype.end=function(Me){return Me&&Me.length&&this.write(Me),this._parser.end(),!0},Te.prototype.on=function(Me,Re){var tt=this;return tt._parser["on"+Me]||gt.indexOf(Me)===-1||(tt._parser["on"+Me]=function(){var lt=arguments.length===1?[arguments[0]]:Array.apply(null,arguments);lt.splice(0,0,Me),tt.emit.apply(tt,lt)}),xt.prototype.on.call(tt,Me,Re)};var _t="[CDATA[",We="DOCTYPE",Ae="http://www.w3.org/XML/1998/namespace",Se="http://www.w3.org/2000/xmlns/",Be={xml:Ae,xmlns:Se},Ke=/[:_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]/,Ne=/[:_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-]/,De=/[#:_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]/,we=/[#:_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-]/,Le=0;me.STATE={BEGIN:Le++,BEGIN_WHITESPACE:Le++,TEXT:Le++,TEXT_ENTITY:Le++,OPEN_WAKA:Le++,SGML_DECL:Le++,SGML_DECL_QUOTED:Le++,DOCTYPE:Le++,DOCTYPE_QUOTED:Le++,DOCTYPE_DTD:Le++,DOCTYPE_DTD_QUOTED:Le++,COMMENT_STARTING:Le++,COMMENT:Le++,COMMENT_ENDING:Le++,COMMENT_ENDED:Le++,CDATA:Le++,CDATA_ENDING:Le++,CDATA_ENDING_2:Le++,PROC_INST:Le++,PROC_INST_BODY:Le++,PROC_INST_ENDING:Le++,OPEN_TAG:Le++,OPEN_TAG_SLASH:Le++,ATTRIB:Le++,ATTRIB_NAME:Le++,ATTRIB_NAME_SAW_WHITE:Le++,ATTRIB_VALUE:Le++,ATTRIB_VALUE_QUOTED:Le++,ATTRIB_VALUE_CLOSED:Le++,ATTRIB_VALUE_UNQUOTED:Le++,ATTRIB_VALUE_ENTITY_Q:Le++,ATTRIB_VALUE_ENTITY_U:Le++,CLOSE_TAG:Le++,CLOSE_TAG_SAW_WHITE:Le++,SCRIPT:Le++,SCRIPT_ENDING:Le++},me.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},me.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,oe.default)(me.ENTITIES).forEach(function(Me){var Re=me.ENTITIES[Me],tt=typeof Re=="number"?String.fromCharCode(Re):Re;me.ENTITIES[Me]=tt});for(var Ue in me.STATE)me.STATE[me.STATE[Ue]]=Ue;Le=me.STATE,ee.default||function(){var Me=String.fromCharCode,Re=Math.floor,tt=function(){var lt,Nt,Ct=[],vt=-1,Pt=arguments.length;if(!Pt)return"";for(var Ht="";++vt<Pt;){var jt=Number(arguments[vt]);if(!isFinite(jt)||jt<0||jt>1114111||Re(jt)!==jt)throw RangeError("Invalid code point: "+jt);jt<=65535?Ct.push(jt):(jt-=65536,lt=55296+(jt>>10),Nt=jt%1024+56320,Ct.push(lt,Nt)),(vt+1===Pt||Ct.length>16384)&&(Ht+=Me.apply(null,Ct),Ct.length=0)}return Ht};re.default?Object.defineProperty(String,"fromCodePoint",{value:tt,configurable:!0,writable:!0}):String.fromCodePoint=tt}()})(ue===void 0?(void 0).sax={}:ue)}).call(this,ie("buffer").Buffer)},{"babel-runtime/core-js/json/stringify":17,"babel-runtime/core-js/object/create":19,"babel-runtime/core-js/object/define-property":20,"babel-runtime/core-js/object/keys":23,"babel-runtime/core-js/string/from-code-point":26,"babel-runtime/helpers/typeof":32,buffer:38,stream:195,string_decoder:37}],195:[function(ie,Ce,ue){function se(){te.call(this)}Ce.exports=se;var te=ie("events").EventEmitter;ie("inherits")(se,te),se.Readable=ie("readable-stream/readable.js"),se.Writable=ie("readable-stream/writable.js"),se.Duplex=ie("readable-stream/duplex.js"),se.Transform=ie("readable-stream/transform.js"),se.PassThrough=ie("readable-stream/passthrough.js"),se.Stream=se,se.prototype.pipe=function(le,ee){function ne(ve){le.writable&&le.write(ve)===!1&&ae.pause&&ae.pause()}function E(){ae.readable&&ae.resume&&ae.resume()}function b(){oe||(oe=!0,le.end())}function z(){oe||(oe=!0,typeof le.destroy=="function"&&le.destroy())}function x(ve){if(re(),te.listenerCount(this,"error")===0)throw ve}function re(){ae.removeListener("data",ne),le.removeListener("drain",E),ae.removeListener("end",b),ae.removeListener("close",z),ae.removeListener("error",x),le.removeListener("error",x),ae.removeListener("end",re),ae.removeListener("close",re),le.removeListener("close",re)}var ae=this;ae.on("data",ne),le.on("drain",E),le._isStdio||ee&&ee.end===!1||(ae.on("end",b),ae.on("close",z));var oe=!1;return ae.on("error",x),le.on("error",x),ae.on("end",re),ae.on("close",re),le.on("close",re),le.emit("pipe",ae),le}},{events:158,inherits:162,"readable-stream/duplex.js":178,"readable-stream/passthrough.js":187,"readable-stream/readable.js":188,"readable-stream/transform.js":189,"readable-stream/writable.js":190}],196:[function(ie,Ce,ue){(function(se){var te=ie("./lib/request"),le=ie("./lib/response"),ee=ie("xtend"),ne=ie("builtin-status-codes"),E=ie("url"),b=ue;b.request=function(z,x){z=typeof z=="string"?E.parse(z):ee(z);var re=se.location.protocol.search(/^https?:$/)===-1?"http:":"",ae=z.protocol||re,oe=z.hostname||z.host,ve=z.port,ye=z.path||"/";oe&&oe.indexOf(":")!==-1&&(oe="["+oe+"]"),z.url=(oe?ae+"//"+oe:"")+(ve?":"+ve:"")+ye,z.method=(z.method||"GET").toUpperCase(),z.headers=z.headers||{};var me=new te(z);return x&&me.on("response",x),me},b.get=function(z,x){var re=b.request(z,x);return re.end(),re},b.ClientRequest=te,b.IncomingMessage=le.IncomingMessage,b.Agent=function(){},b.Agent.defaultMaxSockets=4,b.globalAgent=new b.Agent,b.STATUS_CODES=ne,b.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 be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./lib/request":198,"./lib/response":199,"builtin-status-codes":39,url:203,xtend:236}],197:[function(ie,Ce,ue){(function(se){"use strict";function te(){if(ne!==void 0)return ne;if(se.XMLHttpRequest){ne=new se.XMLHttpRequest;try{ne.open("GET",se.XDomainRequest?"/":"https://example.com")}catch(z){ne=null}}else ne=null;return ne}function le(z){var x=te();if(!x)return!1;try{return x.responseType=z,x.responseType===z}catch(re){}return!1}function ee(z){return typeof z=="function"}ue.fetch=ee(se.fetch)&&ee(se.ReadableStream),ue.writableStream=ee(se.WritableStream),ue.abortController=ee(se.AbortController),ue.blobConstructor=!1;try{new Blob([new ArrayBuffer(1)]),ue.blobConstructor=!0}catch(z){}var ne,E=se.ArrayBuffer!==void 0,b=E&&ee(se.ArrayBuffer.prototype.slice);ue.arraybuffer=ue.fetch||E&&le("arraybuffer"),ue.msstream=!ue.fetch&&b&&le("ms-stream"),ue.mozchunkedarraybuffer=!ue.fetch&&E&&le("moz-chunked-arraybuffer"),ue.overrideMimeType=ue.fetch||!!te()&&ee(te().overrideMimeType),ue.vbArray=ee(se.VBArray),ne=null}).call(this,typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],198:[function(ie,Ce,ue){(function(se,te,le){"use strict";function ee(_e,he){return z.fetch&&he?"fetch":z.mozchunkedarraybuffer?"moz-chunked-arraybuffer":z.msstream?"ms-stream":z.arraybuffer&&_e?"arraybuffer":z.vbArray&&_e?"text:vbarray":"text"}function ne(_e){try{var he=_e.status;return he!==null&&he!==0}catch(pe){return!1}}var E=ie("babel-runtime/core-js/object/keys"),b=function(_e){return _e&&_e.__esModule?_e:{default:_e}}(E),z=ie("./capability"),x=ie("inherits"),re=ie("./response"),ae=ie("readable-stream"),oe=ie("to-arraybuffer"),ve=re.IncomingMessage,ye=re.readyStates,me=Ce.exports=function(_e){var he=this;ae.Writable.call(he),he._opts=_e,he._body=[],he._headers={},_e.auth&&he.setHeader("Authorization","Basic "+new le(_e.auth).toString("base64")),(0,b.default)(_e.headers).forEach(function(Te){he.setHeader(Te,_e.headers[Te])});var pe,ke=!0;if(_e.mode==="disable-fetch"||"requestTimeout"in _e&&!z.abortController)ke=!1,pe=!0;else if(_e.mode==="prefer-streaming")pe=!1;else if(_e.mode==="allow-wrong-content-type")pe=!z.overrideMimeType;else{if(_e.mode&&_e.mode!=="default"&&_e.mode!=="prefer-fast")throw new Error("Invalid value for opts.mode");pe=!0}he._mode=ee(pe,ke),he._fetchTimer=null,he.on("finish",function(){he._onFinish()})};x(me,ae.Writable),me.prototype.setHeader=function(_e,he){var pe=this,ke=_e.toLowerCase();ge.indexOf(ke)===-1&&(pe._headers[ke]={name:_e,value:he})},me.prototype.getHeader=function(_e){var he=this._headers[_e.toLowerCase()];return he?he.value:null},me.prototype.removeHeader=function(_e){delete this._headers[_e.toLowerCase()]},me.prototype._onFinish=function(){var _e=this;if(!_e._destroyed){var he=_e._opts,pe=_e._headers,ke=null;he.method!=="GET"&&he.method!=="HEAD"&&(ke=z.arraybuffer?oe(le.concat(_e._body)):z.blobConstructor?new te.Blob(_e._body.map(function(Pe){return oe(Pe)}),{type:(pe["content-type"]||{}).value||""}):le.concat(_e._body).toString());var Te=[];if((0,b.default)(pe).forEach(function(Pe){var Qe=pe[Pe].name,Xe=pe[Pe].value;Array.isArray(Xe)?Xe.forEach(function(ot){Te.push([Qe,ot])}):Te.push([Qe,Xe])}),_e._mode==="fetch"){var Ee=null;if(z.abortController){var Oe=new AbortController;Ee=Oe.signal,_e._fetchAbortController=Oe,"requestTimeout"in he&&he.requestTimeout!==0&&(_e._fetchTimer=te.setTimeout(function(){_e.emit("requestTimeout"),_e._fetchAbortController&&_e._fetchAbortController.abort()},he.requestTimeout))}te.fetch(_e._opts.url,{method:_e._opts.method,headers:Te,body:ke||void 0,mode:"cors",credentials:he.withCredentials?"include":"same-origin",signal:Ee}).then(function(Pe){_e._fetchResponse=Pe,_e._connect()},function(Pe){te.clearTimeout(_e._fetchTimer),_e._destroyed||_e.emit("error",Pe)})}else{var je=_e._xhr=new te.XMLHttpRequest;try{je.open(_e._opts.method,_e._opts.url,!0)}catch(Pe){return void se.nextTick(function(){_e.emit("error",Pe)})}"responseType"in je&&(je.responseType=_e._mode.split(":")[0]),"withCredentials"in je&&(je.withCredentials=!!he.withCredentials),_e._mode==="text"&&"overrideMimeType"in je&&je.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in he&&(je.timeout=he.requestTimeout,je.ontimeout=function(){_e.emit("requestTimeout")}),Te.forEach(function(Pe){je.setRequestHeader(Pe[0],Pe[1])}),_e._response=null,je.onreadystatechange=function(){switch(je.readyState){case ye.LOADING:case ye.DONE:_e._onXHRProgress()}},_e._mode==="moz-chunked-arraybuffer"&&(je.onprogress=function(){_e._onXHRProgress()}),je.onerror=function(){_e._destroyed||_e.emit("error",new Error("XHR error"))};try{je.send(ke)}catch(Pe){return void se.nextTick(function(){_e.emit("error",Pe)})}}}},me.prototype._onXHRProgress=function(){var _e=this;ne(_e._xhr)&&!_e._destroyed&&(_e._response||_e._connect(),_e._response._onXHRProgress())},me.prototype._connect=function(){var _e=this;_e._destroyed||(_e._response=new ve(_e._xhr,_e._fetchResponse,_e._mode,_e._fetchTimer),_e._response.on("error",function(he){_e.emit("error",he)}),_e.emit("response",_e._response))},me.prototype._write=function(_e,he,pe){this._body.push(_e),pe()},me.prototype.abort=me.prototype.destroy=function(){var _e=this;_e._destroyed=!0,te.clearTimeout(_e._fetchTimer),_e._response&&(_e._response._destroyed=!0),_e._xhr?_e._xhr.abort():_e._fetchAbortController&&_e._fetchAbortController.abort()},me.prototype.end=function(_e,he,pe){var ke=this;typeof _e=="function"&&(pe=_e,_e=void 0),ae.Writable.prototype.end.call(ke,_e,he,pe)},me.prototype.flushHeaders=function(){},me.prototype.setTimeout=function(){},me.prototype.setNoDelay=function(){},me.prototype.setSocketKeepAlive=function(){};var ge=["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,ie("_process"),typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{},ie("buffer").Buffer)},{"./capability":197,"./response":199,_process:173,"babel-runtime/core-js/object/keys":23,buffer:38,inherits:162,"readable-stream":188,"to-arraybuffer":202}],199:[function(ie,Ce,ue){(function(se,te,le){"use strict";var ee=ie("babel-runtime/core-js/promise"),ne=function(ae){return ae&&ae.__esModule?ae:{default:ae}}(ee),E=ie("./capability"),b=ie("inherits"),z=ie("readable-stream"),x=ue.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},re=ue.IncomingMessage=function(ae,oe,ve,ye){var me=this;if(z.Readable.call(me),me._mode=ve,me.headers={},me.rawHeaders=[],me.trailers={},me.rawTrailers=[],me.on("end",function(){se.nextTick(function(){me.emit("close")})}),ve==="fetch"){if(me._fetchResponse=oe,me.url=oe.url,me.statusCode=oe.status,me.statusMessage=oe.statusText,oe.headers.forEach(function(ke,Te){me.headers[Te.toLowerCase()]=ke,me.rawHeaders.push(Te,ke)}),E.writableStream){var ge=new WritableStream({write:function(ke){return new ne.default(function(Te,Ee){me._destroyed?Ee():me.push(new le(ke))?Te():me._resumeFetch=Te})},close:function(){te.clearTimeout(ye),me._destroyed||me.push(null)},abort:function(ke){me._destroyed||me.emit("error",ke)}});try{return void oe.body.pipeTo(ge).catch(function(ke){te.clearTimeout(ye),me._destroyed||me.emit("error",ke)})}catch(ke){}}var _e=oe.body.getReader();(function ke(){_e.read().then(function(Te){if(!me._destroyed){if(Te.done)return te.clearTimeout(ye),void me.push(null);me.push(new le(Te.value)),ke()}}).catch(function(Te){te.clearTimeout(ye),me._destroyed||me.emit("error",Te)})})()}else if(me._xhr=ae,me._pos=0,me.url=ae.responseURL,me.statusCode=ae.status,me.statusMessage=ae.statusText,ae.getAllResponseHeaders().split(/\r?\n/).forEach(function(ke){var Te=ke.match(/^([^:]+):\s*(.*)/);if(Te){var Ee=Te[1].toLowerCase();Ee==="set-cookie"?(me.headers[Ee]===void 0&&(me.headers[Ee]=[]),me.headers[Ee].push(Te[2])):me.headers[Ee]!==void 0?me.headers[Ee]+=", "+Te[2]:me.headers[Ee]=Te[2],me.rawHeaders.push(Te[1],Te[2])}}),me._charset="x-user-defined",!E.overrideMimeType){var he=me.rawHeaders["mime-type"];if(he){var pe=he.match(/;\s*charset=([^;])(;|$)/);pe&&(me._charset=pe[1].toLowerCase())}me._charset||(me._charset="utf-8")}};b(re,z.Readable),re.prototype._read=function(){var ae=this,oe=ae._resumeFetch;oe&&(ae._resumeFetch=null,oe())},re.prototype._onXHRProgress=function(){var ae=this,oe=ae._xhr,ve=null;switch(ae._mode){case"text:vbarray":if(oe.readyState!==x.DONE)break;try{ve=new te.VBArray(oe.responseBody).toArray()}catch(he){}if(ve!==null){ae.push(new le(ve));break}case"text":try{ve=oe.responseText}catch(he){ae._mode="text:vbarray";break}if(ve.length>ae._pos){var ye=ve.substr(ae._pos);if(ae._charset==="x-user-defined"){for(var me=new le(ye.length),ge=0;ge<ye.length;ge++)me[ge]=255&ye.charCodeAt(ge);ae.push(me)}else ae.push(ye,ae._charset);ae._pos=ve.length}break;case"arraybuffer":if(oe.readyState!==x.DONE||!oe.response)break;ve=oe.response,ae.push(new le(new Uint8Array(ve)));break;case"moz-chunked-arraybuffer":if(ve=oe.response,oe.readyState!==x.LOADING||!ve)break;ae.push(new le(new Uint8Array(ve)));break;case"ms-stream":if(ve=oe.response,oe.readyState!==x.LOADING)break;var _e=new te.MSStreamReader;_e.onprogress=function(){_e.result.byteLength>ae._pos&&(ae.push(new le(new Uint8Array(_e.result.slice(ae._pos)))),ae._pos=_e.result.byteLength)},_e.onload=function(){ae.push(null)},_e.readAsArrayBuffer(ve)}ae._xhr.readyState===x.DONE&&ae._mode!=="ms-stream"&&ae.push(null)}}).call(this,ie("_process"),typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{},ie("buffer").Buffer)},{"./capability":197,_process:173,"babel-runtime/core-js/promise":24,buffer:38,inherits:162,"readable-stream":188}],200:[function(ie,Ce,ue){"use strict";function se(he){if(!he)return"utf8";for(var pe;;)switch(he){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 he;default:if(pe)return;he=(""+he).toLowerCase(),pe=!0}}function te(he){var pe=se(he);if(typeof pe!="string"&&(ge.isEncoding===_e||!_e(he)))throw new Error("Unknown encoding: "+he);return pe||he}function le(he){this.encoding=te(he);var pe;switch(this.encoding){case"utf16le":this.text=re,this.end=ae,pe=4;break;case"utf8":this.fillLast=b,pe=4;break;case"base64":this.text=oe,this.end=ve,pe=3;break;default:return this.write=ye,void(this.end=me)}this.lastNeed=0,this.lastTotal=0,this.lastChar=ge.allocUnsafe(pe)}function ee(he){return he<=127?0:he>>5==6?2:he>>4==14?3:he>>3==30?4:he>>6==2?-1:-2}function ne(he,pe,ke){var Te=pe.length-1;if(Te<ke)return 0;var Ee=ee(pe[Te]);return Ee>=0?(Ee>0&&(he.lastNeed=Ee-1),Ee):--Te<ke||Ee===-2?0:(Ee=ee(pe[Te]))>=0?(Ee>0&&(he.lastNeed=Ee-2),Ee):--Te<ke||Ee===-2?0:(Ee=ee(pe[Te]),Ee>=0?(Ee>0&&(Ee===2?Ee=0:he.lastNeed=Ee-3),Ee):0)}function E(he,pe,ke){if((192&pe[0])!=128)return he.lastNeed=0,"\u951F\uFFFD";if(he.lastNeed>1&&pe.length>1){if((192&pe[1])!=128)return he.lastNeed=1,"\u951F\uFFFD";if(he.lastNeed>2&&pe.length>2&&(192&pe[2])!=128)return he.lastNeed=2,"\u951F\uFFFD"}}function b(he){var pe=this.lastTotal-this.lastNeed,ke=E(this,he,pe);return ke!==void 0?ke:this.lastNeed<=he.length?(he.copy(this.lastChar,pe,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(he.copy(this.lastChar,pe,0,he.length),void(this.lastNeed-=he.length))}function z(he,pe){var ke=ne(this,he,pe);if(!this.lastNeed)return he.toString("utf8",pe);this.lastTotal=ke;var Te=he.length-(ke-this.lastNeed);return he.copy(this.lastChar,0,Te),he.toString("utf8",pe,Te)}function x(he){var pe=he&&he.length?this.write(he):"";return this.lastNeed?pe+"\u951F\uFFFD":pe}function re(he,pe){if((he.length-pe)%2==0){var ke=he.toString("utf16le",pe);if(ke){var Te=ke.charCodeAt(ke.length-1);if(Te>=55296&&Te<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=he[he.length-2],this.lastChar[1]=he[he.length-1],ke.slice(0,-1)}return ke}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=he[he.length-1],he.toString("utf16le",pe,he.length-1)}function ae(he){var pe=he&&he.length?this.write(he):"";if(this.lastNeed){var ke=this.lastTotal-this.lastNeed;return pe+this.lastChar.toString("utf16le",0,ke)}return pe}function oe(he,pe){var ke=(he.length-pe)%3;return ke===0?he.toString("base64",pe):(this.lastNeed=3-ke,this.lastTotal=3,ke===1?this.lastChar[0]=he[he.length-1]:(this.lastChar[0]=he[he.length-2],this.lastChar[1]=he[he.length-1]),he.toString("base64",pe,he.length-ke))}function ve(he){var pe=he&&he.length?this.write(he):"";return this.lastNeed?pe+this.lastChar.toString("base64",0,3-this.lastNeed):pe}function ye(he){return he.toString(this.encoding)}function me(he){return he&&he.length?this.write(he):""}var ge=ie("safe-buffer").Buffer,_e=ge.isEncoding||function(he){switch((he=""+he)&&he.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}};ue.StringDecoder=le,le.prototype.write=function(he){if(he.length===0)return"";var pe,ke;if(this.lastNeed){if((pe=this.fillLast(he))===void 0)return"";ke=this.lastNeed,this.lastNeed=0}else ke=0;return ke<he.length?pe?pe+this.text(he,ke):this.text(he,ke):pe||""},le.prototype.end=x,le.prototype.text=z,le.prototype.fillLast=function(he){if(this.lastNeed<=he.length)return he.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);he.copy(this.lastChar,this.lastTotal-this.lastNeed,0,he.length),this.lastNeed-=he.length}},{"safe-buffer":193}],201:[function(ie,Ce,ue){(function(se,te){function le(x,re){this._id=x,this._clearFn=re}var ee=ie("process/browser.js").nextTick,ne=Function.prototype.apply,E=Array.prototype.slice,b={},z=0;ue.setTimeout=function(){return new le(ne.call(setTimeout,window,arguments),clearTimeout)},ue.setInterval=function(){return new le(ne.call(setInterval,window,arguments),clearInterval)},ue.clearTimeout=ue.clearInterval=function(x){x.close()},le.prototype.unref=le.prototype.ref=function(){},le.prototype.close=function(){this._clearFn.call(window,this._id)},ue.enroll=function(x,re){clearTimeout(x._idleTimeoutId),x._idleTimeout=re},ue.unenroll=function(x){clearTimeout(x._idleTimeoutId),x._idleTimeout=-1},ue._unrefActive=ue.active=function(x){clearTimeout(x._idleTimeoutId);var re=x._idleTimeout;re>=0&&(x._idleTimeoutId=setTimeout(function(){x._onTimeout&&x._onTimeout()},re))},ue.setImmediate=typeof se=="function"?se:function(x){var re=z++,ae=!(arguments.length<2)&&E.call(arguments,1);return b[re]=!0,ee(function(){b[re]&&(ae?x.apply(null,ae):x.call(null),ue.clearImmediate(re))}),re},ue.clearImmediate=typeof te=="function"?te:function(x){delete b[x]}}).call(this,ie("timers").setImmediate,ie("timers").clearImmediate)},{"process/browser.js":173,timers:201}],202:[function(ie,Ce,ue){var se=ie("buffer").Buffer;Ce.exports=function(te){if(te instanceof Uint8Array){if(te.byteOffset===0&&te.byteLength===te.buffer.byteLength)return te.buffer;if(typeof te.buffer.slice=="function")return te.buffer.slice(te.byteOffset,te.byteOffset+te.byteLength)}if(se.isBuffer(te)){for(var le=new Uint8Array(te.length),ee=te.length,ne=0;ne<ee;ne++)le[ne]=te[ne];return le.buffer}throw new Error("Argument must be a Buffer")}},{buffer:38}],203:[function(ie,Ce,ue){"use strict";function se(){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}function te(Ee,Oe,je){if(Ee&&b.isObject(Ee)&&Ee instanceof se)return Ee;var Pe=new se;return Pe.parse(Ee,Oe,je),Pe}function le(Ee){return b.isString(Ee)&&(Ee=te(Ee)),Ee instanceof se?Ee.format():se.prototype.format.call(Ee)}function ee(Ee,Oe){return te(Ee,!1,!0).resolve(Oe)}function ne(Ee,Oe){return Ee?te(Ee,!1,!0).resolveObject(Oe):Oe}var E=ie("punycode"),b=ie("./util");ue.parse=te,ue.resolve=ee,ue.resolveObject=ne,ue.format=le,ue.Url=se;var z=/^([a-z0-9.+-]+:)/i,x=/:[0-9]*$/,re=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,ae=["<",">",'"',"`"," ","\r",`
|
|
|
`," "],oe=["{","}","|","\\","^","`"].concat(ae),ve=["'"].concat(oe),ye=["%","/","?",";","#"].concat(ve),me=["/","?","#"],ge=/^[+a-z0-9A-Z_-]{0,63}$/,_e=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,he={javascript:!0,"javascript:":!0},pe={javascript:!0,"javascript:":!0},ke={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},Te=ie("querystring");se.prototype.parse=function(Ee,Oe,je){if(!b.isString(Ee))throw new TypeError("Parameter 'url' must be a string, not "+typeof Ee);var Pe=Ee.indexOf("?"),Qe=Pe!==-1&&Pe<Ee.indexOf("#")?"?":"#",Xe=Ee.split(Qe),ot=/\\/g;Xe[0]=Xe[0].replace(ot,"/"),Ee=Xe.join(Qe);var He=Ee;if(He=He.trim(),!je&&Ee.split("#").length===1){var rt=re.exec(He);if(rt)return this.path=He,this.href=He,this.pathname=rt[1],rt[2]?(this.search=rt[2],this.query=Oe?Te.parse(this.search.substr(1)):this.search.substr(1)):Oe&&(this.search="",this.query={}),this}var Ye=z.exec(He);if(Ye){Ye=Ye[0];var ut=Ye.toLowerCase();this.protocol=ut,He=He.substr(Ye.length)}if(je||Ye||He.match(/^\/\/[^@\/]+@[^@\/]+/)){var Ge=He.substr(0,2)==="//";!Ge||Ye&&pe[Ye]||(He=He.substr(2),this.slashes=!0)}if(!pe[Ye]&&(Ge||Ye&&!ke[Ye])){for(var ze=-1,Ve=0;Ve<me.length;Ve++){var $e=He.indexOf(me[Ve]);$e!==-1&&(ze===-1||$e<ze)&&(ze=$e)}var nt,et;et=ze===-1?He.lastIndexOf("@"):He.lastIndexOf("@",ze),et!==-1&&(nt=He.slice(0,et),He=He.slice(et+1),this.auth=decodeURIComponent(nt)),ze=-1;for(var Ve=0;Ve<ye.length;Ve++){var $e=He.indexOf(ye[Ve]);$e!==-1&&(ze===-1||$e<ze)&&(ze=$e)}ze===-1&&(ze=He.length),this.host=He.slice(0,ze),He=He.slice(ze),this.parseHost(),this.hostname=this.hostname||"";var pt=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!pt)for(var ct=this.hostname.split(/\./),Ve=0,Ot=ct.length;Ve<Ot;Ve++){var dt=ct[Ve];if(dt&&!dt.match(ge)){for(var Rt="",xt=0,gt=dt.length;xt<gt;xt++)dt.charCodeAt(xt)>127?Rt+="x":Rt+=dt[xt];if(!Rt.match(ge)){var _t=ct.slice(0,Ve),We=ct.slice(Ve+1),Ae=dt.match(_e);Ae&&(_t.push(Ae[1]),We.unshift(Ae[2])),We.length&&(He="/"+We.join(".")+He),this.hostname=_t.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),pt||(this.hostname=E.toASCII(this.hostname));var Se=this.port?":"+this.port:"",Be=this.hostname||"";this.host=Be+Se,this.href+=this.host,pt&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),He[0]!=="/"&&(He="/"+He))}if(!he[ut])for(var Ve=0,Ot=ve.length;Ve<Ot;Ve++){var Ke=ve[Ve];if(He.indexOf(Ke)!==-1){var Ne=encodeURIComponent(Ke);Ne===Ke&&(Ne=escape(Ke)),He=He.split(Ke).join(Ne)}}var De=He.indexOf("#");De!==-1&&(this.hash=He.substr(De),He=He.slice(0,De));var we=He.indexOf("?");if(we!==-1?(this.search=He.substr(we),this.query=He.substr(we+1),Oe&&(this.query=Te.parse(this.query)),He=He.slice(0,we)):Oe&&(this.search="",this.query={}),He&&(this.pathname=He),ke[ut]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var Se=this.pathname||"",Le=this.search||"";this.path=Se+Le}return this.href=this.format(),this},se.prototype.format=function(){var Ee=this.auth||"";Ee&&(Ee=encodeURIComponent(Ee),Ee=Ee.replace(/%3A/i,":"),Ee+="@");var Oe=this.protocol||"",je=this.pathname||"",Pe=this.hash||"",Qe=!1,Xe="";this.host?Qe=Ee+this.host:this.hostname&&(Qe=Ee+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(Qe+=":"+this.port)),this.query&&b.isObject(this.query)&&Object.keys(this.query).length&&(Xe=Te.stringify(this.query));var ot=this.search||Xe&&"?"+Xe||"";return Oe&&Oe.substr(-1)!==":"&&(Oe+=":"),this.slashes||(!Oe||ke[Oe])&&Qe!==!1?(Qe="//"+(Qe||""),je&&je.charAt(0)!=="/"&&(je="/"+je)):Qe||(Qe=""),Pe&&Pe.charAt(0)!=="#"&&(Pe="#"+Pe),ot&&ot.charAt(0)!=="?"&&(ot="?"+ot),je=je.replace(/[?#]/g,function(He){return encodeURIComponent(He)}),ot=ot.replace("#","%23"),Oe+Qe+je+ot+Pe},se.prototype.resolve=function(Ee){return this.resolveObject(te(Ee,!1,!0)).format()},se.prototype.resolveObject=function(Ee){if(b.isString(Ee)){var Oe=new se;Oe.parse(Ee,!1,!0),Ee=Oe}for(var je=new se,Pe=Object.keys(this),Qe=0;Qe<Pe.length;Qe++){var Xe=Pe[Qe];je[Xe]=this[Xe]}if(je.hash=Ee.hash,Ee.href==="")return je.href=je.format(),je;if(Ee.slashes&&!Ee.protocol){for(var ot=Object.keys(Ee),He=0;He<ot.length;He++){var rt=ot[He];rt!=="protocol"&&(je[rt]=Ee[rt])}return ke[je.protocol]&&je.hostname&&!je.pathname&&(je.path=je.pathname="/"),je.href=je.format(),je}if(Ee.protocol&&Ee.protocol!==je.protocol){if(!ke[Ee.protocol]){for(var Ye=Object.keys(Ee),ut=0;ut<Ye.length;ut++){var Ge=Ye[ut];je[Ge]=Ee[Ge]}return je.href=je.format(),je}if(je.protocol=Ee.protocol,Ee.host||pe[Ee.protocol])je.pathname=Ee.pathname;else{for(var Ot=(Ee.pathname||"").split("/");Ot.length&&!(Ee.host=Ot.shift()););Ee.host||(Ee.host=""),Ee.hostname||(Ee.hostname=""),Ot[0]!==""&&Ot.unshift(""),Ot.length<2&&Ot.unshift(""),je.pathname=Ot.join("/")}if(je.search=Ee.search,je.query=Ee.query,je.host=Ee.host||"",je.auth=Ee.auth,je.hostname=Ee.hostname||Ee.host,je.port=Ee.port,je.pathname||je.search){var ze=je.pathname||"",Ve=je.search||"";je.path=ze+Ve}return je.slashes=je.slashes||Ee.slashes,je.href=je.format(),je}var $e=je.pathname&&je.pathname.charAt(0)==="/",nt=Ee.host||Ee.pathname&&Ee.pathname.charAt(0)==="/",et=nt||$e||je.host&&Ee.pathname,pt=et,ct=je.pathname&&je.pathname.split("/")||[],Ot=Ee.pathname&&Ee.pathname.split("/")||[],dt=je.protocol&&!ke[je.protocol];if(dt&&(je.hostname="",je.port=null,je.host&&(ct[0]===""?ct[0]=je.host:ct.unshift(je.host)),je.host="",Ee.protocol&&(Ee.hostname=null,Ee.port=null,Ee.host&&(Ot[0]===""?Ot[0]=Ee.host:Ot.unshift(Ee.host)),Ee.host=null),et=et&&(Ot[0]===""||ct[0]==="")),nt)je.host=Ee.host||Ee.host===""?Ee.host:je.host,je.hostname=Ee.hostname||Ee.hostname===""?Ee.hostname:je.hostname,je.search=Ee.search,je.query=Ee.query,ct=Ot;else if(Ot.length)ct||(ct=[]),ct.pop(),ct=ct.concat(Ot),je.search=Ee.search,je.query=Ee.query;else if(!b.isNullOrUndefined(Ee.search)){if(dt){je.hostname=je.host=ct.shift();var Rt=!!(je.host&&je.host.indexOf("@")>0)&&je.host.split("@");Rt&&(je.auth=Rt.shift(),je.host=je.hostname=Rt.shift())}return je.search=Ee.search,je.query=Ee.query,b.isNull(je.pathname)&&b.isNull(je.search)||(je.path=(je.pathname?je.pathname:"")+(je.search?je.search:"")),je.href=je.format(),je}if(!ct.length)return je.pathname=null,je.search?je.path="/"+je.search:je.path=null,je.href=je.format(),je;for(var xt=ct.slice(-1)[0],gt=(je.host||Ee.host||ct.length>1)&&(xt==="."||xt==="..")||xt==="",_t=0,We=ct.length;We>=0;We--)xt=ct[We],xt==="."?ct.splice(We,1):xt===".."?(ct.splice(We,1),_t++):_t&&(ct.splice(We,1),_t--);if(!et&&!pt)for(;_t--;_t)ct.unshift("..");!et||ct[0]===""||ct[0]&&ct[0].charAt(0)==="/"||ct.unshift(""),gt&&ct.join("/").substr(-1)!=="/"&&ct.push("");var Ae=ct[0]===""||ct[0]&&ct[0].charAt(0)==="/";if(dt){je.hostname=je.host=Ae?"":ct.length?ct.shift():"";var Rt=!!(je.host&&je.host.indexOf("@")>0)&&je.host.split("@");Rt&&(je.auth=Rt.shift(),je.host=je.hostname=Rt.shift())}return et=et||je.host&&ct.length,et&&!Ae&&ct.unshift(""),ct.length?je.pathname=ct.join("/"):(je.pathname=null,je.path=null),b.isNull(je.pathname)&&b.isNull(je.search)||(je.path=(je.pathname?je.pathname:"")+(je.search?je.search:"")),je.auth=Ee.auth||je.auth,je.slashes=je.slashes||Ee.slashes,je.href=je.format(),je},se.prototype.parseHost=function(){var Ee=this.host,Oe=x.exec(Ee);Oe&&(Oe=Oe[0],Oe!==":"&&(this.port=Oe.substr(1)),Ee=Ee.substr(0,Ee.length-Oe.length)),Ee&&(this.hostname=Ee)}},{"./util":204,punycode:174,querystring:177}],204:[function(ie,Ce,ue){"use strict";Ce.exports={isString:function(se){return typeof se=="string"},isObject:function(se){return typeof se=="object"&&se!==null},isNull:function(se){return se===null},isNullOrUndefined:function(se){return se==null}}},{}],205:[function(ie,Ce,ue){(function(se){function te(ee,ne){function E(){if(!b){if(le("throwDeprecation"))throw new Error(ne);le("traceDeprecation")?console.trace(ne):console.warn(ne),b=!0}return ee.apply(this,arguments)}if(le("noDeprecation"))return ee;var b=!1;return E}function le(ee){try{if(!se.localStorage)return!1}catch(E){return!1}var ne=se.localStorage[ee];return ne!=null&&String(ne).toLowerCase()==="true"}Ce.exports=te}).call(this,typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],206:[function(ie,Ce,ue){Ce.exports=function(se){return se&&typeof se=="object"&&typeof se.copy=="function"&&typeof se.fill=="function"&&typeof se.readUInt8=="function"}},{}],207:[function(ie,Ce,ue){(function(se,te){function le(Ve,$e){var nt={seen:[],stylize:ne};return arguments.length>=3&&(nt.depth=arguments[2]),arguments.length>=4&&(nt.colors=arguments[3]),ye($e)?nt.showHidden=$e:$e&&ue._extend(nt,$e),ke(nt.showHidden)&&(nt.showHidden=!1),ke(nt.depth)&&(nt.depth=2),ke(nt.colors)&&(nt.colors=!1),ke(nt.customInspect)&&(nt.customInspect=!0),nt.colors&&(nt.stylize=ee),b(nt,Ve,nt.depth)}function ee(Ve,$e){var nt=le.styles[$e];return nt?"\x1B["+le.colors[nt][0]+"m"+Ve+"\x1B["+le.colors[nt][1]+"m":Ve}function ne(Ve,$e){return Ve}function E(Ve){var $e={};return Ve.forEach(function(nt,et){$e[nt]=!0}),$e}function b(Ve,$e,nt){if(Ve.customInspect&&$e&&Pe($e.inspect)&&$e.inspect!==ue.inspect&&(!$e.constructor||$e.constructor.prototype!==$e)){var et=$e.inspect(nt,Ve);return he(et)||(et=b(Ve,et,nt)),et}var pt=z(Ve,$e);if(pt)return pt;var ct=Object.keys($e),Ot=E(ct);if(Ve.showHidden&&(ct=Object.getOwnPropertyNames($e)),je($e)&&(ct.indexOf("message")>=0||ct.indexOf("description")>=0))return x($e);if(ct.length===0){if(Pe($e)){var dt=$e.name?": "+$e.name:"";return Ve.stylize("[Function"+dt+"]","special")}if(Te($e))return Ve.stylize(RegExp.prototype.toString.call($e),"regexp");if(Oe($e))return Ve.stylize(Date.prototype.toString.call($e),"date");if(je($e))return x($e)}var Rt="",xt=!1,gt=["{","}"];if(ve($e)&&(xt=!0,gt=["[","]"]),Pe($e)&&(Rt=" [Function"+($e.name?": "+$e.name:"")+"]"),Te($e)&&(Rt=" "+RegExp.prototype.toString.call($e)),Oe($e)&&(Rt=" "+Date.prototype.toUTCString.call($e)),je($e)&&(Rt=" "+x($e)),ct.length===0&&(!xt||$e.length==0))return gt[0]+Rt+gt[1];if(nt<0)return Te($e)?Ve.stylize(RegExp.prototype.toString.call($e),"regexp"):Ve.stylize("[Object]","special");Ve.seen.push($e);var _t;return _t=xt?re(Ve,$e,nt,Ot,ct):ct.map(function(We){return ae(Ve,$e,nt,Ot,We,xt)}),Ve.seen.pop(),oe(_t,Rt,gt)}function z(Ve,$e){if(ke($e))return Ve.stylize("undefined","undefined");if(he($e)){var nt="'"+JSON.stringify($e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return Ve.stylize(nt,"string")}return _e($e)?Ve.stylize(""+$e,"number"):ye($e)?Ve.stylize(""+$e,"boolean"):me($e)?Ve.stylize("null","null"):void 0}function x(Ve){return"["+Error.prototype.toString.call(Ve)+"]"}function re(Ve,$e,nt,et,pt){for(var ct=[],Ot=0,dt=$e.length;Ot<dt;++Ot)rt($e,String(Ot))?ct.push(ae(Ve,$e,nt,et,String(Ot),!0)):ct.push("");return pt.forEach(function(Rt){Rt.match(/^\d+$/)||ct.push(ae(Ve,$e,nt,et,Rt,!0))}),ct}function ae(Ve,$e,nt,et,pt,ct){var Ot,dt,Rt;if(Rt=Object.getOwnPropertyDescriptor($e,pt)||{value:$e[pt]},Rt.get?dt=Rt.set?Ve.stylize("[Getter/Setter]","special"):Ve.stylize("[Getter]","special"):Rt.set&&(dt=Ve.stylize("[Setter]","special")),rt(et,pt)||(Ot="["+pt+"]"),dt||(Ve.seen.indexOf(Rt.value)<0?(dt=me(nt)?b(Ve,Rt.value,null):b(Ve,Rt.value,nt-1),dt.indexOf(`
|
|
|
`)>-1&&(dt=ct?dt.split(`
|
|
|
`).map(function(xt){return" "+xt}).join(`
|
|
|
`).substr(2):`
|
|
|
`+dt.split(`
|
|
|
`).map(function(xt){return" "+xt}).join(`
|
|
|
`))):dt=Ve.stylize("[Circular]","special")),ke(Ot)){if(ct&&pt.match(/^\d+$/))return dt;Ot=JSON.stringify(""+pt),Ot.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(Ot=Ot.substr(1,Ot.length-2),Ot=Ve.stylize(Ot,"name")):(Ot=Ot.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),Ot=Ve.stylize(Ot,"string"))}return Ot+": "+dt}function oe(Ve,$e,nt){var et=0;return Ve.reduce(function(pt,ct){return et++,ct.indexOf(`
|
|
|
`)>=0&&et++,pt+ct.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?nt[0]+($e===""?"":$e+`
|
|
|
`)+" "+Ve.join(`,
|
|
|
`)+" "+nt[1]:nt[0]+$e+" "+Ve.join(", ")+" "+nt[1]}function ve(Ve){return Array.isArray(Ve)}function ye(Ve){return typeof Ve=="boolean"}function me(Ve){return Ve===null}function ge(Ve){return Ve==null}function _e(Ve){return typeof Ve=="number"}function he(Ve){return typeof Ve=="string"}function pe(Ve){return typeof Ve=="symbol"}function ke(Ve){return Ve===void 0}function Te(Ve){return Ee(Ve)&&Xe(Ve)==="[object RegExp]"}function Ee(Ve){return typeof Ve=="object"&&Ve!==null}function Oe(Ve){return Ee(Ve)&&Xe(Ve)==="[object Date]"}function je(Ve){return Ee(Ve)&&(Xe(Ve)==="[object Error]"||Ve instanceof Error)}function Pe(Ve){return typeof Ve=="function"}function Qe(Ve){return Ve===null||typeof Ve=="boolean"||typeof Ve=="number"||typeof Ve=="string"||typeof Ve=="symbol"||Ve===void 0}function Xe(Ve){return Object.prototype.toString.call(Ve)}function ot(Ve){return Ve<10?"0"+Ve.toString(10):Ve.toString(10)}function He(){var Ve=new Date,$e=[ot(Ve.getHours()),ot(Ve.getMinutes()),ot(Ve.getSeconds())].join(":");return[Ve.getDate(),ze[Ve.getMonth()],$e].join(" ")}function rt(Ve,$e){return Object.prototype.hasOwnProperty.call(Ve,$e)}var Ye=/%[sdj%]/g;ue.format=function(Ve){if(!he(Ve)){for(var $e=[],nt=0;nt<arguments.length;nt++)$e.push(le(arguments[nt]));return $e.join(" ")}for(var nt=1,et=arguments,pt=et.length,ct=String(Ve).replace(Ye,function(Rt){if(Rt==="%%")return"%";if(nt>=pt)return Rt;switch(Rt){case"%s":return String(et[nt++]);case"%d":return Number(et[nt++]);case"%j":try{return JSON.stringify(et[nt++])}catch(xt){return"[Circular]"}default:return Rt}}),Ot=et[nt];nt<pt;Ot=et[++nt])me(Ot)||!Ee(Ot)?ct+=" "+Ot:ct+=" "+le(Ot);return ct},ue.deprecate=function(Ve,$e){function nt(){if(!et){if(se.throwDeprecation)throw new Error($e);se.traceDeprecation?console.trace($e):console.error($e),et=!0}return Ve.apply(this,arguments)}if(ke(te.process))return function(){return ue.deprecate(Ve,$e).apply(this,arguments)};if(se.noDeprecation===!0)return Ve;var et=!1;return nt};var ut,Ge={};ue.debuglog=function(Ve){if(ke(ut)&&(ut=se.env.NODE_DEBUG||""),Ve=Ve.toUpperCase(),!Ge[Ve])if(new RegExp("\\b"+Ve+"\\b","i").test(ut)){var $e=se.pid;Ge[Ve]=function(){var nt=ue.format.apply(ue,arguments);console.error("%s %d: %s",Ve,$e,nt)}}else Ge[Ve]=function(){};return Ge[Ve]},ue.inspect=le,le.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]},le.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},ue.isArray=ve,ue.isBoolean=ye,ue.isNull=me,ue.isNullOrUndefined=ge,ue.isNumber=_e,ue.isString=he,ue.isSymbol=pe,ue.isUndefined=ke,ue.isRegExp=Te,ue.isObject=Ee,ue.isDate=Oe,ue.isError=je,ue.isFunction=Pe,ue.isPrimitive=Qe,ue.isBuffer=ie("./support/isBuffer");var ze=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];ue.log=function(){console.log("%s - %s",He(),ue.format.apply(ue,arguments))},ue.inherits=ie("inherits"),ue._extend=function(Ve,$e){if(!$e||!Ee($e))return Ve;for(var nt=Object.keys($e),et=nt.length;et--;)Ve[nt[et]]=$e[nt[et]];return Ve}}).call(this,ie("_process"),typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./support/isBuffer":206,_process:173,inherits:162}],208:[function(ie,Ce,ue){"use strict";(function(){ue.stripBOM=function(se){return se[0]==="\uFEFF"?se.substring(1):se}}).call(void 0)},{}],209:[function(ie,Ce,ue){"use strict";function se(E){return E&&E.__esModule?E:{default:E}}var te=ie("babel-runtime/helpers/typeof"),le=se(te),ee=ie("babel-runtime/core-js/object/keys"),ne=se(ee);(function(){var E,b,z,x,re,ae={}.hasOwnProperty;E=ie("xmlbuilder"),b=ie("./defaults").defaults,x=function(oe){return typeof oe=="string"&&(oe.indexOf("&")>=0||oe.indexOf(">")>=0||oe.indexOf("<")>=0)},re=function(oe){return"<![CDATA["+z(oe)+"]]>"},z=function(oe){return oe.replace("]]>","]]]]><![CDATA[>")},ue.Builder=function(){function oe(ve){var ye,me,ge;this.options={},me=b[.2];for(ye in me)ae.call(me,ye)&&(ge=me[ye],this.options[ye]=ge);for(ye in ve)ae.call(ve,ye)&&(ge=ve[ye],this.options[ye]=ge)}return oe.prototype.buildObject=function(ve){var ye,me,ge,_e,he;return ye=this.options.attrkey,me=this.options.charkey,(0,ne.default)(ve).length===1&&this.options.rootName===b[.2].rootName?(he=(0,ne.default)(ve)[0],ve=ve[he]):he=this.options.rootName,ge=function(pe){return function(ke,Te){var Ee,Oe,je,Pe,Qe,Xe;if((Te===void 0?"undefined":(0,le.default)(Te))!=="object")pe.options.cdata&&x(Te)?ke.raw(re(Te)):ke.txt(Te);else if(Array.isArray(Te)){for(Pe in Te)if(ae.call(Te,Pe)){Oe=Te[Pe];for(Qe in Oe)je=Oe[Qe],ke=ge(ke.ele(Qe),je).up()}}else for(Qe in Te)if(ae.call(Te,Qe))if(Oe=Te[Qe],Qe===ye){if((Oe===void 0?"undefined":(0,le.default)(Oe))==="object")for(Ee in Oe)Xe=Oe[Ee],ke=ke.att(Ee,Xe)}else if(Qe===me)ke=pe.options.cdata&&x(Oe)?ke.raw(re(Oe)):ke.txt(Oe);else if(Array.isArray(Oe))for(Pe in Oe)ae.call(Oe,Pe)&&(je=Oe[Pe],ke=typeof je=="string"?pe.options.cdata&&x(je)?ke.ele(Qe).raw(re(je)).up():ke.ele(Qe,je).up():ge(ke.ele(Qe),je).up());else(Oe===void 0?"undefined":(0,le.default)(Oe))==="object"?ke=ge(ke.ele(Qe),Oe).up():typeof Oe=="string"&&pe.options.cdata&&x(Oe)?ke=ke.ele(Qe).raw(re(Oe)).up():(Oe==null&&(Oe=""),ke=ke.ele(Qe,Oe.toString()).up());return ke}}(this),_e=E.create(he,this.options.xmldec,this.options.doctype,{headless:this.options.headless,allowSurrogateChars:this.options.allowSurrogateChars}),ge(_e,ve).end(this.options.renderOpts)},oe}()}).call(void 0)},{"./defaults":210,"babel-runtime/core-js/object/keys":23,"babel-runtime/helpers/typeof":32,xmlbuilder:235}],210:[function(ie,Ce,ue){"use strict";(function(){ue.defaults={.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:""},.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)},{}],211:[function(ie,Ce,ue){"use strict";function se(z){return z&&z.__esModule?z:{default:z}}var te=ie("babel-runtime/core-js/object/get-own-property-names"),le=se(te),ee=ie("babel-runtime/core-js/object/keys"),ne=se(ee),E=ie("babel-runtime/helpers/typeof"),b=se(E);(function(){var z,x,re,ae,oe,ve,ye,me,ge=function(pe,ke){return function(){return pe.apply(ke,arguments)}},_e=function(pe,ke){function Te(){this.constructor=pe}for(var Ee in ke)he.call(ke,Ee)&&(pe[Ee]=ke[Ee]);return Te.prototype=ke.prototype,pe.prototype=new Te,pe.__super__=ke.prototype,pe},he={}.hasOwnProperty;ye=ie("sax"),re=ie("events"),z=ie("./bom"),ve=ie("./processors"),me=ie("timers").setImmediate,x=ie("./defaults").defaults,ae=function(pe){return(pe===void 0?"undefined":(0,b.default)(pe))==="object"&&pe!=null&&(0,ne.default)(pe).length===0},oe=function(pe,ke,Te){var Ee,Oe,je;for(Ee=0,Oe=pe.length;Ee<Oe;Ee++)je=pe[Ee],ke=je(ke,Te);return ke},ue.Parser=function(pe){function ke(Te){this.parseString=ge(this.parseString,this),this.reset=ge(this.reset,this),this.assignOrPush=ge(this.assignOrPush,this),this.processAsync=ge(this.processAsync,this);var Ee,Oe,je;if(!(this instanceof ue.Parser))return new ue.Parser(Te);this.options={},Oe=x[.2];for(Ee in Oe)he.call(Oe,Ee)&&(je=Oe[Ee],this.options[Ee]=je);for(Ee in Te)he.call(Te,Ee)&&(je=Te[Ee],this.options[Ee]=je);this.options.xmlns&&(this.options.xmlnskey=this.options.attrkey+"ns"),this.options.normalizeTags&&(this.options.tagNameProcessors||(this.options.tagNameProcessors=[]),this.options.tagNameProcessors.unshift(ve.normalize)),this.reset()}return _e(ke,pe),ke.prototype.processAsync=function(){var Te,Ee;try{return this.remaining.length<=this.options.chunkSize?(Te=this.remaining,this.remaining="",this.saxParser=this.saxParser.write(Te),this.saxParser.close()):(Te=this.remaining.substr(0,this.options.chunkSize),this.remaining=this.remaining.substr(this.options.chunkSize,this.remaining.length),this.saxParser=this.saxParser.write(Te),me(this.processAsync))}catch(Oe){if(Ee=Oe,!this.saxParser.errThrown)return this.saxParser.errThrown=!0,this.emit(Ee)}},ke.prototype.assignOrPush=function(Te,Ee,Oe){return Ee in Te?(Te[Ee]instanceof Array||(Te[Ee]=[Te[Ee]]),Te[Ee].push(Oe)):this.options.explicitArray?Te[Ee]=[Oe]:Te[Ee]=Oe},ke.prototype.reset=function(){var Te,Ee,Oe,je;return this.removeAllListeners(),this.saxParser=ye.parser(this.options.strict,{trim:!1,normalize:!1,xmlns:this.options.xmlns}),this.saxParser.errThrown=!1,this.saxParser.onerror=function(Pe){return function(Qe){if(Pe.saxParser.resume(),!Pe.saxParser.errThrown)return Pe.saxParser.errThrown=!0,Pe.emit("error",Qe)}}(this),this.saxParser.onend=function(Pe){return function(){if(!Pe.saxParser.ended)return Pe.saxParser.ended=!0,Pe.emit("end",Pe.resultObject)}}(this),this.saxParser.ended=!1,this.EXPLICIT_CHARKEY=this.options.explicitCharkey,this.resultObject=null,je=[],Te=this.options.attrkey,Ee=this.options.charkey,this.saxParser.onopentag=function(Pe){return function(Qe){var Xe,ot,He,rt,Ye;if(He={},He[Ee]="",!Pe.options.ignoreAttrs){Ye=Qe.attributes;for(Xe in Ye)he.call(Ye,Xe)&&(Te in He||Pe.options.mergeAttrs||(He[Te]={}),ot=Pe.options.attrValueProcessors?oe(Pe.options.attrValueProcessors,Qe.attributes[Xe],Xe):Qe.attributes[Xe],rt=Pe.options.attrNameProcessors?oe(Pe.options.attrNameProcessors,Xe):Xe,Pe.options.mergeAttrs?Pe.assignOrPush(He,rt,ot):He[Te][rt]=ot)}return He["#name"]=Pe.options.tagNameProcessors?oe(Pe.options.tagNameProcessors,Qe.name):Qe.name,Pe.options.xmlns&&(He[Pe.options.xmlnskey]={uri:Qe.uri,local:Qe.local}),je.push(He)}}(this),this.saxParser.onclosetag=function(Pe){return function(){var Qe,Xe,ot,He,rt,Ye,ut,Ge,ze,Ve;if(Ye=je.pop(),rt=Ye["#name"],Pe.options.explicitChildren&&Pe.options.preserveChildrenOrder||delete Ye["#name"],Ye.cdata===!0&&(Qe=Ye.cdata,delete Ye.cdata),ze=je[je.length-1],Ye[Ee].match(/^\s*$/)&&!Qe?(Xe=Ye[Ee],delete Ye[Ee]):(Pe.options.trim&&(Ye[Ee]=Ye[Ee].trim()),Pe.options.normalize&&(Ye[Ee]=Ye[Ee].replace(/\s{2,}/g," ").trim()),Ye[Ee]=Pe.options.valueProcessors?oe(Pe.options.valueProcessors,Ye[Ee],rt):Ye[Ee],(0,ne.default)(Ye).length===1&&Ee in Ye&&!Pe.EXPLICIT_CHARKEY&&(Ye=Ye[Ee])),ae(Ye)&&(Ye=Pe.options.emptyTag!==""?Pe.options.emptyTag:Xe),Pe.options.validator!=null&&(Ve="/"+function(){var $e,nt,et;for(et=[],$e=0,nt=je.length;$e<nt;$e++)He=je[$e],et.push(He["#name"]);return et}().concat(rt).join("/"),function(){var $e;try{Ye=Pe.options.validator(Ve,ze&&ze[rt],Ye)}catch(nt){return $e=nt,Pe.emit("error",$e)}}()),Pe.options.explicitChildren&&!Pe.options.mergeAttrs&&(Ye===void 0?"undefined":(0,b.default)(Ye))==="object")if(Pe.options.preserveChildrenOrder){if(ze){ze[Pe.options.childkey]=ze[Pe.options.childkey]||[],ut={};for(ot in Ye)he.call(Ye,ot)&&(ut[ot]=Ye[ot]);ze[Pe.options.childkey].push(ut),delete Ye["#name"],(0,ne.default)(Ye).length===1&&Ee in Ye&&!Pe.EXPLICIT_CHARKEY&&(Ye=Ye[Ee])}}else He={},Pe.options.attrkey in Ye&&(He[Pe.options.attrkey]=Ye[Pe.options.attrkey],delete Ye[Pe.options.attrkey]),!Pe.options.charsAsChildren&&Pe.options.charkey in Ye&&(He[Pe.options.charkey]=Ye[Pe.options.charkey],delete Ye[Pe.options.charkey]),(0,le.default)(Ye).length>0&&(He[Pe.options.childkey]=Ye),Ye=He;return je.length>0?Pe.assignOrPush(ze,rt,Ye):(Pe.options.explicitRoot&&(Ge=Ye,Ye={},Ye[rt]=Ge),Pe.resultObject=Ye,Pe.saxParser.ended=!0,Pe.emit("end",Pe.resultObject))}}(this),Oe=function(Pe){return function(Qe){var Xe,ot;if(ot=je[je.length-1])return ot[Ee]+=Qe,Pe.options.explicitChildren&&Pe.options.preserveChildrenOrder&&Pe.options.charsAsChildren&&(Pe.options.includeWhiteChars||Qe.replace(/\\n/g,"").trim()!=="")&&(ot[Pe.options.childkey]=ot[Pe.options.childkey]||[],Xe={"#name":"__text__"},Xe[Ee]=Qe,Pe.options.normalize&&(Xe[Ee]=Xe[Ee].replace(/\s{2,}/g," ").trim()),ot[Pe.options.childkey].push(Xe)),ot}}(this),this.saxParser.ontext=Oe,this.saxParser.oncdata=function(Pe){return function(Qe){var Xe;if(Xe=Oe(Qe))return Xe.cdata=!0}}()},ke.prototype.parseString=function(Te,Ee){var Oe;Ee!=null&&typeof Ee=="function"&&(this.on("end",function(je){return this.reset(),Ee(null,je)}),this.on("error",function(je){return this.reset(),Ee(je)}));try{return Te=Te.toString(),Te.trim()===""?(this.emit("end",null),!0):(Te=z.stripBOM(Te),this.options.async?(this.remaining=Te,me(this.processAsync),this.saxParser):this.saxParser.write(Te).close())}catch(je){if(Oe=je,!this.saxParser.errThrown&&!this.saxParser.ended)return this.emit("error",Oe),this.saxParser.errThrown=!0;if(this.saxParser.ended)throw Oe}},ke}(re.EventEmitter),ue.parseString=function(pe,ke,Te){var Ee,Oe,je;return Te!=null?(typeof Te=="function"&&(Ee=Te),(ke===void 0?"undefined":(0,b.default)(ke))==="object"&&(Oe=ke)):(typeof ke=="function"&&(Ee=ke),Oe={}),je=new ue.Parser(Oe),je.parseString(pe,Ee)}}).call(void 0)},{"./bom":208,"./defaults":210,"./processors":212,"babel-runtime/core-js/object/get-own-property-names":21,"babel-runtime/core-js/object/keys":23,"babel-runtime/helpers/typeof":32,events:158,sax:194,timers:201}],212:[function(ie,Ce,ue){"use strict";(function(){var se;se=new RegExp(/(?!xmlns)^.*:/),ue.normalize=function(te){return te.toLowerCase()},ue.firstCharLowerCase=function(te){return te.charAt(0).toLowerCase()+te.slice(1)},ue.stripPrefix=function(te){return te.replace(se,"")},ue.parseNumbers=function(te){return isNaN(te)||(te=te%1==0?parseInt(te,10):parseFloat(te)),te},ue.parseBooleans=function(te){return/^(?:true|false)$/i.test(te)&&(te=te.toLowerCase()==="true"),te}}).call(void 0)},{}],213:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne=function(b,z){function x(){this.constructor=b}for(var re in z)E.call(z,re)&&(b[re]=z[re]);return x.prototype=z.prototype,b.prototype=new x,b.__super__=z.prototype,b},E={}.hasOwnProperty;te=ie("./defaults"),se=ie("./builder"),le=ie("./parser"),ee=ie("./processors"),ue.defaults=te.defaults,ue.processors=ee,ue.ValidationError=function(b){function z(x){this.message=x}return ne(z,b),z}(Error),ue.Builder=se.Builder,ue.Parser=le.Parser,ue.parseString=le.parseString}).call(void 0)},{"./builder":209,"./defaults":210,"./parser":211,"./processors":212}],214:[function(ie,Ce,ue){"use strict";function se(z){return z&&z.__esModule?z:{default:z}}var te=ie("babel-runtime/core-js/object/get-prototype-of"),le=se(te),ee=ie("babel-runtime/helpers/typeof"),ne=se(ee),E=ie("babel-runtime/core-js/object/assign"),b=se(E);(function(){var z,x,re,ae,oe,ve,ye=[].slice,me={}.hasOwnProperty;z=function(){var ge,_e,he,pe,ke,Te;if(Te=arguments[0],ke=2<=arguments.length?ye.call(arguments,1):[],ae(b.default))b.default.apply(null,arguments);else for(ge=0,he=ke.length;ge<he;ge++)if((pe=ke[ge])!=null)for(_e in pe)me.call(pe,_e)&&(Te[_e]=pe[_e]);return Te},ae=function(ge){return!!ge&&Object.prototype.toString.call(ge)==="[object Function]"},oe=function(ge){var _e;return!!ge&&((_e=ge===void 0?"undefined":(0,ne.default)(ge))==="function"||_e==="object")},x=function(ge){return ae(Array.isArray)?Array.isArray(ge):Object.prototype.toString.call(ge)==="[object Array]"},re=function(ge){var _e;if(x(ge))return!ge.length;for(_e in ge)if(me.call(ge,_e))return!1;return!0},ve=function(ge){var _e,he;return oe(ge)&&(he=(0,le.default)(ge))&&(_e=he.constructor)&&typeof _e=="function"&&_e instanceof _e&&Function.prototype.toString.call(_e)===Function.prototype.toString.call(Object)},Ce.exports.assign=z,Ce.exports.isFunction=ae,Ce.exports.isObject=oe,Ce.exports.isArray=x,Ce.exports.isEmpty=re,Ce.exports.isPlainObject=ve}).call(void 0)},{"babel-runtime/core-js/object/assign":18,"babel-runtime/core-js/object/get-prototype-of":22,"babel-runtime/helpers/typeof":32}],215:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){Ce.exports=function(){function le(ee,ne,E){if(this.options=ee.options,this.stringify=ee.stringify,ne==null)throw new Error("Missing attribute name of element "+ee.name);if(E==null)throw new Error("Missing attribute value for attribute "+ne+" of element "+ee.name);this.name=this.stringify.attName(ne),this.value=this.stringify.attValue(E)}return le.prototype.clone=function(){return(0,te.default)(this)},le.prototype.toString=function(ee){return this.options.writer.set(ee).attribute(this)},le}()}).call(void 0)},{"babel-runtime/core-js/object/create":19}],216:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){var le,ee=function(E,b){function z(){this.constructor=E}for(var x in b)ne.call(b,x)&&(E[x]=b[x]);return z.prototype=b.prototype,E.prototype=new z,E.__super__=b.prototype,E},ne={}.hasOwnProperty;le=ie("./XMLNode"),Ce.exports=function(E){function b(z,x){if(b.__super__.constructor.call(this,z),x==null)throw new Error("Missing CDATA text");this.text=this.stringify.cdata(x)}return ee(b,E),b.prototype.clone=function(){return(0,te.default)(this)},b.prototype.toString=function(z){return this.options.writer.set(z).cdata(this)},b}(le)}).call(void 0)},{"./XMLNode":227,"babel-runtime/core-js/object/create":19}],217:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){var le,ee=function(E,b){function z(){this.constructor=E}for(var x in b)ne.call(b,x)&&(E[x]=b[x]);return z.prototype=b.prototype,E.prototype=new z,E.__super__=b.prototype,E},ne={}.hasOwnProperty;le=ie("./XMLNode"),Ce.exports=function(E){function b(z,x){if(b.__super__.constructor.call(this,z),x==null)throw new Error("Missing comment text");this.text=this.stringify.comment(x)}return ee(b,E),b.prototype.clone=function(){return(0,te.default)(this)},b.prototype.toString=function(z){return this.options.writer.set(z).comment(this)},b}(le)}).call(void 0)},{"./XMLNode":227,"babel-runtime/core-js/object/create":19}],218:[function(ie,Ce,ue){"use strict";(function(){var se,te=function(ee,ne){function E(){this.constructor=ee}for(var b in ne)le.call(ne,b)&&(ee[b]=ne[b]);return E.prototype=ne.prototype,ee.prototype=new E,ee.__super__=ne.prototype,ee},le={}.hasOwnProperty;se=ie("./XMLNode"),Ce.exports=function(ee){function ne(E,b,z,x,re,ae){if(ne.__super__.constructor.call(this,E),b==null)throw new Error("Missing DTD element name");if(z==null)throw new Error("Missing DTD attribute name");if(!x)throw new Error("Missing DTD attribute type");if(!re)throw new Error("Missing DTD attribute default");if(re.indexOf("#")!==0&&(re="#"+re),!re.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT");if(ae&&!re.match(/^(#FIXED|#DEFAULT)$/))throw new Error("Default value only applies to #FIXED or #DEFAULT");this.elementName=this.stringify.eleName(b),this.attributeName=this.stringify.attName(z),this.attributeType=this.stringify.dtdAttType(x),this.defaultValue=this.stringify.dtdAttDefault(ae),this.defaultValueType=re}return te(ne,ee),ne.prototype.toString=function(E){return this.options.writer.set(E).dtdAttList(this)},ne}(se)}).call(void 0)},{"./XMLNode":227}],219:[function(ie,Ce,ue){"use strict";(function(){var se,te=function(ee,ne){function E(){this.constructor=ee}for(var b in ne)le.call(ne,b)&&(ee[b]=ne[b]);return E.prototype=ne.prototype,ee.prototype=new E,ee.__super__=ne.prototype,ee},le={}.hasOwnProperty;se=ie("./XMLNode"),Ce.exports=function(ee){function ne(E,b,z){if(ne.__super__.constructor.call(this,E),b==null)throw new Error("Missing DTD element name");z||(z="(#PCDATA)"),Array.isArray(z)&&(z="("+z.join(",")+")"),this.name=this.stringify.eleName(b),this.value=this.stringify.dtdElementValue(z)}return te(ne,ee),ne.prototype.toString=function(E){return this.options.writer.set(E).dtdElement(this)},ne}(se)}).call(void 0)},{"./XMLNode":227}],220:[function(ie,Ce,ue){"use strict";(function(){var se,te,le=function(ne,E){function b(){this.constructor=ne}for(var z in E)ee.call(E,z)&&(ne[z]=E[z]);return b.prototype=E.prototype,ne.prototype=new b,ne.__super__=E.prototype,ne},ee={}.hasOwnProperty;te=ie("./Utility").isObject,se=ie("./XMLNode"),Ce.exports=function(ne){function E(b,z,x,re){if(E.__super__.constructor.call(this,b),x==null)throw new Error("Missing entity name");if(re==null)throw new Error("Missing entity value");if(this.pe=!!z,this.name=this.stringify.eleName(x),te(re)){if(!re.pubID&&!re.sysID)throw new Error("Public and/or system identifiers are required for an external entity");if(re.pubID&&!re.sysID)throw new Error("System identifier is required for a public external entity");if(re.pubID!=null&&(this.pubID=this.stringify.dtdPubID(re.pubID)),re.sysID!=null&&(this.sysID=this.stringify.dtdSysID(re.sysID)),re.nData!=null&&(this.nData=this.stringify.dtdNData(re.nData)),this.pe&&this.nData)throw new Error("Notation declaration is not allowed in a parameter entity")}else this.value=this.stringify.dtdEntityValue(re)}return le(E,ne),E.prototype.toString=function(b){return this.options.writer.set(b).dtdEntity(this)},E}(se)}).call(void 0)},{"./Utility":214,"./XMLNode":227}],221:[function(ie,Ce,ue){"use strict";(function(){var se,te=function(ee,ne){function E(){this.constructor=ee}for(var b in ne)le.call(ne,b)&&(ee[b]=ne[b]);return E.prototype=ne.prototype,ee.prototype=new E,ee.__super__=ne.prototype,ee},le={}.hasOwnProperty;se=ie("./XMLNode"),Ce.exports=function(ee){function ne(E,b,z){if(ne.__super__.constructor.call(this,E),b==null)throw new Error("Missing notation name");if(!z.pubID&&!z.sysID)throw new Error("Public or system identifiers are required for an external entity");this.name=this.stringify.eleName(b),z.pubID!=null&&(this.pubID=this.stringify.dtdPubID(z.pubID)),z.sysID!=null&&(this.sysID=this.stringify.dtdSysID(z.sysID))}return te(ne,ee),ne.prototype.toString=function(E){return this.options.writer.set(E).dtdNotation(this)},ne}(se)}).call(void 0)},{"./XMLNode":227}],222:[function(ie,Ce,ue){"use strict";(function(){var se,te,le=function(ne,E){function b(){this.constructor=ne}for(var z in E)ee.call(E,z)&&(ne[z]=E[z]);return b.prototype=E.prototype,ne.prototype=new b,ne.__super__=E.prototype,ne},ee={}.hasOwnProperty;te=ie("./Utility").isObject,se=ie("./XMLNode"),Ce.exports=function(ne){function E(b,z,x,re){var ae;E.__super__.constructor.call(this,b),te(z)&&(ae=z,z=ae.version,x=ae.encoding,re=ae.standalone),z||(z="1.0"),this.version=this.stringify.xmlVersion(z),x!=null&&(this.encoding=this.stringify.xmlEncoding(x)),re!=null&&(this.standalone=this.stringify.xmlStandalone(re))}return le(E,ne),E.prototype.toString=function(b){return this.options.writer.set(b).declaration(this)},E}(se)}).call(void 0)},{"./Utility":214,"./XMLNode":227}],223:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne,E,b=function(x,re){function ae(){this.constructor=x}for(var oe in re)z.call(re,oe)&&(x[oe]=re[oe]);return ae.prototype=re.prototype,x.prototype=new ae,x.__super__=re.prototype,x},z={}.hasOwnProperty;E=ie("./Utility").isObject,ne=ie("./XMLNode"),se=ie("./XMLDTDAttList"),le=ie("./XMLDTDEntity"),te=ie("./XMLDTDElement"),ee=ie("./XMLDTDNotation"),Ce.exports=function(x){function re(ae,oe,ve){var ye,me;re.__super__.constructor.call(this,ae),this.documentObject=ae,E(oe)&&(ye=oe,oe=ye.pubID,ve=ye.sysID),ve==null&&(me=[oe,ve],ve=me[0],oe=me[1]),oe!=null&&(this.pubID=this.stringify.dtdPubID(oe)),ve!=null&&(this.sysID=this.stringify.dtdSysID(ve))}return b(re,x),re.prototype.element=function(ae,oe){var ve;return ve=new te(this,ae,oe),this.children.push(ve),this},re.prototype.attList=function(ae,oe,ve,ye,me){var ge;return ge=new se(this,ae,oe,ve,ye,me),this.children.push(ge),this},re.prototype.entity=function(ae,oe){var ve;return ve=new le(this,!1,ae,oe),this.children.push(ve),this},re.prototype.pEntity=function(ae,oe){var ve;return ve=new le(this,!0,ae,oe),this.children.push(ve),this},re.prototype.notation=function(ae,oe){var ve;return ve=new ee(this,ae,oe),this.children.push(ve),this},re.prototype.toString=function(ae){return this.options.writer.set(ae).docType(this)},re.prototype.ele=function(ae,oe){return this.element(ae,oe)},re.prototype.att=function(ae,oe,ve,ye,me){return this.attList(ae,oe,ve,ye,me)},re.prototype.ent=function(ae,oe){return this.entity(ae,oe)},re.prototype.pent=function(ae,oe){return this.pEntity(ae,oe)},re.prototype.not=function(ae,oe){return this.notation(ae,oe)},re.prototype.up=function(){return this.root()||this.documentObject},re}(ne)}).call(void 0)},{"./Utility":214,"./XMLDTDAttList":218,"./XMLDTDElement":219,"./XMLDTDEntity":220,"./XMLDTDNotation":221,"./XMLNode":227}],224:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne=function(b,z){function x(){this.constructor=b}for(var re in z)E.call(z,re)&&(b[re]=z[re]);return x.prototype=z.prototype,b.prototype=new x,b.__super__=z.prototype,b},E={}.hasOwnProperty;ee=ie("./Utility").isPlainObject,se=ie("./XMLNode"),le=ie("./XMLStringifier"),te=ie("./XMLStringWriter"),Ce.exports=function(b){function z(x){z.__super__.constructor.call(this,null),x||(x={}),x.writer||(x.writer=new te),this.options=x,this.stringify=new le(x),this.isDocument=!0}return ne(z,b),z.prototype.end=function(x){var re;return x?ee(x)&&(re=x,x=this.options.writer.set(re)):x=this.options.writer,x.document(this)},z.prototype.toString=function(x){return this.options.writer.set(x).document(this)},z}(se)}).call(void 0)},{"./Utility":214,"./XMLNode":227,"./XMLStringWriter":231,"./XMLStringifier":232}],225:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne,E,b,z,x,re,ae,oe,ve,ye,me,ge,_e,he,pe,ke={}.hasOwnProperty;pe=ie("./Utility"),_e=pe.isObject,ge=pe.isFunction,he=pe.isPlainObject,re=ie("./XMLElement"),te=ie("./XMLCData"),le=ie("./XMLComment"),oe=ie("./XMLRaw"),me=ie("./XMLText"),ae=ie("./XMLProcessingInstruction"),z=ie("./XMLDeclaration"),x=ie("./XMLDocType"),ee=ie("./XMLDTDAttList"),E=ie("./XMLDTDEntity"),ne=ie("./XMLDTDElement"),b=ie("./XMLDTDNotation"),se=ie("./XMLAttribute"),ye=ie("./XMLStringifier"),ve=ie("./XMLStringWriter"),Ce.exports=function(){function Te(Ee,Oe,je){var Pe;Ee||(Ee={}),Ee.writer?he(Ee.writer)&&(Pe=Ee.writer,Ee.writer=new ve(Pe)):Ee.writer=new ve(Ee),this.options=Ee,this.writer=Ee.writer,this.stringify=new ye(Ee),this.onDataCallback=Oe||function(){},this.onEndCallback=je||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}return Te.prototype.node=function(Ee,Oe,je){var Pe;if(Ee==null)throw new Error("Missing node name");if(this.root&&this.currentLevel===-1)throw new Error("Document can only have one root node");return this.openCurrent(),Ee=Ee.valueOf(),Oe==null&&(Oe={}),Oe=Oe.valueOf(),_e(Oe)||(Pe=[Oe,je],je=Pe[0],Oe=Pe[1]),this.currentNode=new re(this,Ee,Oe),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,je!=null&&this.text(je),this},Te.prototype.element=function(Ee,Oe,je){return this.currentNode&&this.currentNode instanceof x?this.dtdElement.apply(this,arguments):this.node(Ee,Oe,je)},Te.prototype.attribute=function(Ee,Oe){var je,Pe;if(!this.currentNode||this.currentNode.children)throw new Error("att() can only be used immediately after an ele() call in callback mode");if(Ee!=null&&(Ee=Ee.valueOf()),_e(Ee))for(je in Ee)ke.call(Ee,je)&&(Pe=Ee[je],this.attribute(je,Pe));else ge(Oe)&&(Oe=Oe.apply()),this.options.skipNullAttributes&&Oe==null||(this.currentNode.attributes[Ee]=new se(this,Ee,Oe));return this},Te.prototype.text=function(Ee){var Oe;return this.openCurrent(),Oe=new me(this,Ee),this.onData(this.writer.text(Oe,this.currentLevel+1)),this},Te.prototype.cdata=function(Ee){var Oe;return this.openCurrent(),Oe=new te(this,Ee),this.onData(this.writer.cdata(Oe,this.currentLevel+1)),this},Te.prototype.comment=function(Ee){var Oe;return this.openCurrent(),Oe=new le(this,Ee),this.onData(this.writer.comment(Oe,this.currentLevel+1)),this},Te.prototype.raw=function(Ee){var Oe;return this.openCurrent(),Oe=new oe(this,Ee),this.onData(this.writer.raw(Oe,this.currentLevel+1)),this},Te.prototype.instruction=function(Ee,Oe){var je,Pe,Qe,Xe,ot;if(this.openCurrent(),Ee!=null&&(Ee=Ee.valueOf()),Oe!=null&&(Oe=Oe.valueOf()),Array.isArray(Ee))for(je=0,Xe=Ee.length;je<Xe;je++)Pe=Ee[je],this.instruction(Pe);else if(_e(Ee))for(Pe in Ee)ke.call(Ee,Pe)&&(Qe=Ee[Pe],this.instruction(Pe,Qe));else ge(Oe)&&(Oe=Oe.apply()),ot=new ae(this,Ee,Oe),this.onData(this.writer.processingInstruction(ot,this.currentLevel+1));return this},Te.prototype.declaration=function(Ee,Oe,je){var Pe;if(this.openCurrent(),this.documentStarted)throw new Error("declaration() must be the first node");return Pe=new z(this,Ee,Oe,je),this.onData(this.writer.declaration(Pe,this.currentLevel+1)),this},Te.prototype.doctype=function(Ee,Oe,je){if(this.openCurrent(),Ee==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 x(this,Oe,je),this.currentNode.rootNodeName=Ee,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this},Te.prototype.dtdElement=function(Ee,Oe){var je;return this.openCurrent(),je=new ne(this,Ee,Oe),this.onData(this.writer.dtdElement(je,this.currentLevel+1)),this},Te.prototype.attList=function(Ee,Oe,je,Pe,Qe){var Xe;return this.openCurrent(),Xe=new ee(this,Ee,Oe,je,Pe,Qe),this.onData(this.writer.dtdAttList(Xe,this.currentLevel+1)),this},Te.prototype.entity=function(Ee,Oe){var je;return this.openCurrent(),je=new E(this,!1,Ee,Oe),this.onData(this.writer.dtdEntity(je,this.currentLevel+1)),this},Te.prototype.pEntity=function(Ee,Oe){var je;return this.openCurrent(),je=new E(this,!0,Ee,Oe),this.onData(this.writer.dtdEntity(je,this.currentLevel+1)),this},Te.prototype.notation=function(Ee,Oe){var je;return this.openCurrent(),je=new b(this,Ee,Oe),this.onData(this.writer.dtdNotation(je,this.currentLevel+1)),this},Te.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},Te.prototype.end=function(){for(;this.currentLevel>=0;)this.up();return this.onEnd()},Te.prototype.openCurrent=function(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)},Te.prototype.openNode=function(Ee){if(!Ee.isOpen)return!this.root&&this.currentLevel===0&&Ee instanceof re&&(this.root=Ee),this.onData(this.writer.openNode(Ee,this.currentLevel)),Ee.isOpen=!0},Te.prototype.closeNode=function(Ee){if(!Ee.isClosed)return this.onData(this.writer.closeNode(Ee,this.currentLevel)),Ee.isClosed=!0},Te.prototype.onData=function(Ee){return this.documentStarted=!0,this.onDataCallback(Ee)},Te.prototype.onEnd=function(){return this.documentCompleted=!0,this.onEndCallback()},Te.prototype.ele=function(){return this.element.apply(this,arguments)},Te.prototype.nod=function(Ee,Oe,je){return this.node(Ee,Oe,je)},Te.prototype.txt=function(Ee){return this.text(Ee)},Te.prototype.dat=function(Ee){return this.cdata(Ee)},Te.prototype.com=function(Ee){return this.comment(Ee)},Te.prototype.ins=function(Ee,Oe){return this.instruction(Ee,Oe)},Te.prototype.dec=function(Ee,Oe,je){return this.declaration(Ee,Oe,je)},Te.prototype.dtd=function(Ee,Oe,je){return this.doctype(Ee,Oe,je)},Te.prototype.e=function(Ee,Oe,je){return this.element(Ee,Oe,je)},Te.prototype.n=function(Ee,Oe,je){return this.node(Ee,Oe,je)},Te.prototype.t=function(Ee){return this.text(Ee)},Te.prototype.d=function(Ee){return this.cdata(Ee)},Te.prototype.c=function(Ee){return this.comment(Ee)},Te.prototype.r=function(Ee){return this.raw(Ee)},Te.prototype.i=function(Ee,Oe){return this.instruction(Ee,Oe)},Te.prototype.att=function(){return this.currentNode&&this.currentNode instanceof x?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},Te.prototype.a=function(){return this.currentNode&&this.currentNode instanceof x?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},Te.prototype.ent=function(Ee,Oe){return this.entity(Ee,Oe)},Te.prototype.pent=function(Ee,Oe){return this.pEntity(Ee,Oe)},Te.prototype.not=function(Ee,Oe){return this.notation(Ee,Oe)},Te}()}).call(void 0)},{"./Utility":214,"./XMLAttribute":215,"./XMLCData":216,"./XMLComment":217,"./XMLDTDAttList":218,"./XMLDTDElement":219,"./XMLDTDEntity":220,"./XMLDTDNotation":221,"./XMLDeclaration":222,"./XMLDocType":223,"./XMLElement":226,"./XMLProcessingInstruction":228,"./XMLRaw":229,"./XMLStringWriter":231,"./XMLStringifier":232,"./XMLText":233}],226:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){var le,ee,ne,E,b,z=function(re,ae){function oe(){this.constructor=re}for(var ve in ae)x.call(ae,ve)&&(re[ve]=ae[ve]);return oe.prototype=ae.prototype,re.prototype=new oe,re.__super__=ae.prototype,re},x={}.hasOwnProperty;b=ie("./Utility"),E=b.isObject,ne=b.isFunction,ee=ie("./XMLNode"),le=ie("./XMLAttribute"),Ce.exports=function(re){function ae(oe,ve,ye){if(ae.__super__.constructor.call(this,oe),ve==null)throw new Error("Missing element name");this.name=this.stringify.eleName(ve),this.attributes={},ye!=null&&this.attribute(ye),oe.isDocument&&(this.isRoot=!0,this.documentObject=oe,oe.rootObject=this)}return z(ae,re),ae.prototype.clone=function(){var oe,ve,ye,me;ye=(0,te.default)(this),ye.isRoot&&(ye.documentObject=null),ye.attributes={},me=this.attributes;for(ve in me)x.call(me,ve)&&(oe=me[ve],ye.attributes[ve]=oe.clone());return ye.children=[],this.children.forEach(function(ge){var _e;return _e=ge.clone(),_e.parent=ye,ye.children.push(_e)}),ye},ae.prototype.attribute=function(oe,ve){var ye,me;if(oe!=null&&(oe=oe.valueOf()),E(oe))for(ye in oe)x.call(oe,ye)&&(me=oe[ye],this.attribute(ye,me));else ne(ve)&&(ve=ve.apply()),this.options.skipNullAttributes&&ve==null||(this.attributes[oe]=new le(this,oe,ve));return this},ae.prototype.removeAttribute=function(oe){var ve,ye,me;if(oe==null)throw new Error("Missing attribute name");if(oe=oe.valueOf(),Array.isArray(oe))for(ye=0,me=oe.length;ye<me;ye++)ve=oe[ye],delete this.attributes[ve];else delete this.attributes[oe];return this},ae.prototype.toString=function(oe){return this.options.writer.set(oe).element(this)},ae.prototype.att=function(oe,ve){return this.attribute(oe,ve)},ae.prototype.a=function(oe,ve){return this.attribute(oe,ve)},ae}(ee)}).call(void 0)},{"./Utility":214,"./XMLAttribute":215,"./XMLNode":227,"babel-runtime/core-js/object/create":19}],227:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne,E,b,z,x,re,ae,oe,ve={}.hasOwnProperty;oe=ie("./Utility"),ae=oe.isObject,re=oe.isFunction,x=oe.isEmpty,ne=null,se=null,te=null,le=null,ee=null,b=null,z=null,E=null,Ce.exports=function(){function ye(me){this.parent=me,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.children=[],ne||(ne=ie("./XMLElement"),se=ie("./XMLCData"),te=ie("./XMLComment"),le=ie("./XMLDeclaration"),ee=ie("./XMLDocType"),b=ie("./XMLRaw"),z=ie("./XMLText"),E=ie("./XMLProcessingInstruction"))}return ye.prototype.element=function(me,ge,_e){var he,pe,ke,Te,Ee,Oe,je,Pe,Qe,Xe;if(Oe=null,ge==null&&(ge={}),ge=ge.valueOf(),ae(ge)||(Qe=[ge,_e],_e=Qe[0],ge=Qe[1]),me!=null&&(me=me.valueOf()),Array.isArray(me))for(ke=0,je=me.length;ke<je;ke++)pe=me[ke],Oe=this.element(pe);else if(re(me))Oe=this.element(me.apply());else if(ae(me)){for(Ee in me)if(ve.call(me,Ee))if(Xe=me[Ee],re(Xe)&&(Xe=Xe.apply()),ae(Xe)&&x(Xe)&&(Xe=null),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&Ee.indexOf(this.stringify.convertAttKey)===0)Oe=this.attribute(Ee.substr(this.stringify.convertAttKey.length),Xe);else if(!this.options.separateArrayItems&&Array.isArray(Xe))for(Te=0,Pe=Xe.length;Te<Pe;Te++)pe=Xe[Te],he={},he[Ee]=pe,Oe=this.element(he);else ae(Xe)?(Oe=this.element(Ee),Oe.element(Xe)):Oe=this.element(Ee,Xe)}else Oe=!this.options.ignoreDecorators&&this.stringify.convertTextKey&&me.indexOf(this.stringify.convertTextKey)===0?this.text(_e):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&me.indexOf(this.stringify.convertCDataKey)===0?this.cdata(_e):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&me.indexOf(this.stringify.convertCommentKey)===0?this.comment(_e):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&me.indexOf(this.stringify.convertRawKey)===0?this.raw(_e):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&me.indexOf(this.stringify.convertPIKey)===0?this.instruction(me.substr(this.stringify.convertPIKey.length),_e):this.node(me,ge,_e);if(Oe==null)throw new Error("Could not create any elements with: "+me);return Oe},ye.prototype.insertBefore=function(me,ge,_e){var he,pe,ke;if(this.isRoot)throw new Error("Cannot insert elements at root level");return pe=this.parent.children.indexOf(this),ke=this.parent.children.splice(pe),he=this.parent.element(me,ge,_e),Array.prototype.push.apply(this.parent.children,ke),he},ye.prototype.insertAfter=function(me,ge,_e){var he,pe,ke;if(this.isRoot)throw new Error("Cannot insert elements at root level");return pe=this.parent.children.indexOf(this),ke=this.parent.children.splice(pe+1),he=this.parent.element(me,ge,_e),Array.prototype.push.apply(this.parent.children,ke),he},ye.prototype.remove=function(){var me;if(this.isRoot)throw new Error("Cannot remove the root element");return me=this.parent.children.indexOf(this),[].splice.apply(this.parent.children,[me,me-me+1].concat([])),this.parent},ye.prototype.node=function(me,ge,_e){var he,pe;return me!=null&&(me=me.valueOf()),ge||(ge={}),ge=ge.valueOf(),ae(ge)||(pe=[ge,_e],_e=pe[0],ge=pe[1]),he=new ne(this,me,ge),_e!=null&&he.text(_e),this.children.push(he),he},ye.prototype.text=function(me){var ge;return ge=new z(this,me),this.children.push(ge),this},ye.prototype.cdata=function(me){var ge;return ge=new se(this,me),this.children.push(ge),this},ye.prototype.comment=function(me){var ge;return ge=new te(this,me),this.children.push(ge),this},ye.prototype.commentBefore=function(me){var ge,_e;return ge=this.parent.children.indexOf(this),_e=this.parent.children.splice(ge),this.parent.comment(me),Array.prototype.push.apply(this.parent.children,_e),this},ye.prototype.commentAfter=function(me){var ge,_e;return ge=this.parent.children.indexOf(this),_e=this.parent.children.splice(ge+1),this.parent.comment(me),Array.prototype.push.apply(this.parent.children,_e),this},ye.prototype.raw=function(me){var ge;return ge=new b(this,me),this.children.push(ge),this},ye.prototype.instruction=function(me,ge){var _e,he,pe,ke,Te;if(me!=null&&(me=me.valueOf()),ge!=null&&(ge=ge.valueOf()),Array.isArray(me))for(ke=0,Te=me.length;ke<Te;ke++)_e=me[ke],this.instruction(_e);else if(ae(me))for(_e in me)ve.call(me,_e)&&(he=me[_e],this.instruction(_e,he));else re(ge)&&(ge=ge.apply()),pe=new E(this,me,ge),this.children.push(pe);return this},ye.prototype.instructionBefore=function(me,ge){var _e,he;return _e=this.parent.children.indexOf(this),he=this.parent.children.splice(_e),this.parent.instruction(me,ge),Array.prototype.push.apply(this.parent.children,he),this},ye.prototype.instructionAfter=function(me,ge){var _e,he;return _e=this.parent.children.indexOf(this),he=this.parent.children.splice(_e+1),this.parent.instruction(me,ge),Array.prototype.push.apply(this.parent.children,he),this},ye.prototype.declaration=function(me,ge,_e){var he,pe;return he=this.document(),pe=new le(he,me,ge,_e),he.children[0]instanceof le?he.children[0]=pe:he.children.unshift(pe),he.root()||he},ye.prototype.doctype=function(me,ge){var _e,he,pe,ke,Te,Ee,Oe,je,Pe,Qe;for(he=this.document(),pe=new ee(he,me,ge),Pe=he.children,ke=Te=0,Oe=Pe.length;Te<Oe;ke=++Te)if((_e=Pe[ke])instanceof ee)return he.children[ke]=pe,pe;for(Qe=he.children,ke=Ee=0,je=Qe.length;Ee<je;ke=++Ee)if(_e=Qe[ke],_e.isRoot)return he.children.splice(ke,0,pe),pe;return he.children.push(pe),pe},ye.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},ye.prototype.root=function(){var me;for(me=this;me;){if(me.isDocument)return me.rootObject;if(me.isRoot)return me;me=me.parent}},ye.prototype.document=function(){var me;for(me=this;me;){if(me.isDocument)return me;me=me.parent}},ye.prototype.end=function(me){return this.document().end(me)},ye.prototype.prev=function(){var me;if((me=this.parent.children.indexOf(this))<1)throw new Error("Already at the first node");return this.parent.children[me-1]},ye.prototype.next=function(){var me;if((me=this.parent.children.indexOf(this))===-1||me===this.parent.children.length-1)throw new Error("Already at the last node");return this.parent.children[me+1]},ye.prototype.importDocument=function(me){var ge;return ge=me.root().clone(),ge.parent=this,ge.isRoot=!1,this.children.push(ge),this},ye.prototype.ele=function(me,ge,_e){return this.element(me,ge,_e)},ye.prototype.nod=function(me,ge,_e){return this.node(me,ge,_e)},ye.prototype.txt=function(me){return this.text(me)},ye.prototype.dat=function(me){return this.cdata(me)},ye.prototype.com=function(me){return this.comment(me)},ye.prototype.ins=function(me,ge){return this.instruction(me,ge)},ye.prototype.doc=function(){return this.document()},ye.prototype.dec=function(me,ge,_e){return this.declaration(me,ge,_e)},ye.prototype.dtd=function(me,ge){return this.doctype(me,ge)},ye.prototype.e=function(me,ge,_e){return this.element(me,ge,_e)},ye.prototype.n=function(me,ge,_e){return this.node(me,ge,_e)},ye.prototype.t=function(me){return this.text(me)},ye.prototype.d=function(me){return this.cdata(me)},ye.prototype.c=function(me){return this.comment(me)},ye.prototype.r=function(me){return this.raw(me)},ye.prototype.i=function(me,ge){return this.instruction(me,ge)},ye.prototype.u=function(){return this.up()},ye.prototype.importXMLBuilder=function(me){return this.importDocument(me)},ye}()}).call(void 0)},{"./Utility":214,"./XMLCData":216,"./XMLComment":217,"./XMLDeclaration":222,"./XMLDocType":223,"./XMLElement":226,"./XMLProcessingInstruction":228,"./XMLRaw":229,"./XMLText":233}],228:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){var le,ee=function(E,b){function z(){this.constructor=E}for(var x in b)ne.call(b,x)&&(E[x]=b[x]);return z.prototype=b.prototype,E.prototype=new z,E.__super__=b.prototype,E},ne={}.hasOwnProperty;le=ie("./XMLNode"),Ce.exports=function(E){function b(z,x,re){if(b.__super__.constructor.call(this,z),x==null)throw new Error("Missing instruction target");this.target=this.stringify.insTarget(x),re&&(this.value=this.stringify.insValue(re))}return ee(b,E),b.prototype.clone=function(){return(0,te.default)(this)},b.prototype.toString=function(z){return this.options.writer.set(z).processingInstruction(this)},b}(le)}).call(void 0)},{"./XMLNode":227,"babel-runtime/core-js/object/create":19}],229:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){var le,ee=function(E,b){function z(){this.constructor=E}for(var x in b)ne.call(b,x)&&(E[x]=b[x]);return z.prototype=b.prototype,E.prototype=new z,E.__super__=b.prototype,E},ne={}.hasOwnProperty;le=ie("./XMLNode"),Ce.exports=function(E){function b(z,x){if(b.__super__.constructor.call(this,z),x==null)throw new Error("Missing raw text");this.value=this.stringify.raw(x)}return ee(b,E),b.prototype.clone=function(){return(0,te.default)(this)},b.prototype.toString=function(z){return this.options.writer.set(z).raw(this)},b}(le)}).call(void 0)},{"./XMLNode":227,"babel-runtime/core-js/object/create":19}],230:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne,E,b,z,x,re,ae,oe,ve,ye=function(ge,_e){function he(){this.constructor=ge}for(var pe in _e)me.call(_e,pe)&&(ge[pe]=_e[pe]);return he.prototype=_e.prototype,ge.prototype=new he,ge.__super__=_e.prototype,ge},me={}.hasOwnProperty;b=ie("./XMLDeclaration"),z=ie("./XMLDocType"),se=ie("./XMLCData"),te=ie("./XMLComment"),x=ie("./XMLElement"),ae=ie("./XMLRaw"),oe=ie("./XMLText"),re=ie("./XMLProcessingInstruction"),le=ie("./XMLDTDAttList"),ee=ie("./XMLDTDElement"),ne=ie("./XMLDTDEntity"),E=ie("./XMLDTDNotation"),ve=ie("./XMLWriterBase"),Ce.exports=function(ge){function _e(he,pe){_e.__super__.constructor.call(this,pe),this.stream=he}return ye(_e,ge),_e.prototype.document=function(he){var pe,ke,Te,Ee,Oe,je,Pe,Qe;for(je=he.children,ke=0,Ee=je.length;ke<Ee;ke++)pe=je[ke],pe.isLastRootNode=!1;for(he.children[he.children.length-1].isLastRootNode=!0,Pe=he.children,Qe=[],Te=0,Oe=Pe.length;Te<Oe;Te++)switch(pe=Pe[Te],!1){case!(pe instanceof b):Qe.push(this.declaration(pe));break;case!(pe instanceof z):Qe.push(this.docType(pe));break;case!(pe instanceof te):Qe.push(this.comment(pe));break;case!(pe instanceof re):Qe.push(this.processingInstruction(pe));break;default:Qe.push(this.element(pe))}return Qe},_e.prototype.attribute=function(he){return this.stream.write(" "+he.name+'="'+he.value+'"')},_e.prototype.cdata=function(he,pe){return this.stream.write(this.space(pe)+"<![CDATA["+he.text+"]]>"+this.endline(he))},_e.prototype.comment=function(he,pe){return this.stream.write(this.space(pe)+"<!-- "+he.text+" -->"+this.endline(he))},_e.prototype.declaration=function(he,pe){return this.stream.write(this.space(pe)),this.stream.write('<?xml version="'+he.version+'"'),he.encoding!=null&&this.stream.write(' encoding="'+he.encoding+'"'),he.standalone!=null&&this.stream.write(' standalone="'+he.standalone+'"'),this.stream.write(this.spacebeforeslash+"?>"),this.stream.write(this.endline(he))},_e.prototype.docType=function(he,pe){var ke,Te,Ee,Oe;if(pe||(pe=0),this.stream.write(this.space(pe)),this.stream.write("<!DOCTYPE "+he.root().name),he.pubID&&he.sysID?this.stream.write(' PUBLIC "'+he.pubID+'" "'+he.sysID+'"'):he.sysID&&this.stream.write(' SYSTEM "'+he.sysID+'"'),he.children.length>0){for(this.stream.write(" ["),this.stream.write(this.endline(he)),Oe=he.children,Te=0,Ee=Oe.length;Te<Ee;Te++)switch(ke=Oe[Te],!1){case!(ke instanceof le):this.dtdAttList(ke,pe+1);break;case!(ke instanceof ee):this.dtdElement(ke,pe+1);break;case!(ke instanceof ne):this.dtdEntity(ke,pe+1);break;case!(ke instanceof E):this.dtdNotation(ke,pe+1);break;case!(ke instanceof se):this.cdata(ke,pe+1);break;case!(ke instanceof te):this.comment(ke,pe+1);break;case!(ke instanceof re):this.processingInstruction(ke,pe+1);break;default:throw new Error("Unknown DTD node type: "+ke.constructor.name)}this.stream.write("]")}return this.stream.write(this.spacebeforeslash+">"),this.stream.write(this.endline(he))},_e.prototype.element=function(he,pe){var ke,Te,Ee,Oe,je,Pe,Qe,Xe;pe||(pe=0),Xe=this.space(pe),this.stream.write(Xe+"<"+he.name),Pe=he.attributes;for(je in Pe)me.call(Pe,je)&&(ke=Pe[je],this.attribute(ke));if(he.children.length===0||he.children.every(function(ot){return ot.value===""}))this.allowEmpty?this.stream.write("></"+he.name+">"):this.stream.write(this.spacebeforeslash+"/>");else if(this.pretty&&he.children.length===1&&he.children[0].value!=null)this.stream.write(">"),this.stream.write(he.children[0].value),this.stream.write("</"+he.name+">");else{for(this.stream.write(">"+this.newline),Qe=he.children,Ee=0,Oe=Qe.length;Ee<Oe;Ee++)switch(Te=Qe[Ee],!1){case!(Te instanceof se):this.cdata(Te,pe+1);break;case!(Te instanceof te):this.comment(Te,pe+1);break;case!(Te instanceof x):this.element(Te,pe+1);break;case!(Te instanceof ae):this.raw(Te,pe+1);break;case!(Te instanceof oe):this.text(Te,pe+1);break;case!(Te instanceof re):this.processingInstruction(Te,pe+1);break;default:throw new Error("Unknown XML node type: "+Te.constructor.name)}this.stream.write(Xe+"</"+he.name+">")}return this.stream.write(this.endline(he))},_e.prototype.processingInstruction=function(he,pe){return this.stream.write(this.space(pe)+"<?"+he.target),he.value&&this.stream.write(" "+he.value),this.stream.write(this.spacebeforeslash+"?>"+this.endline(he))},_e.prototype.raw=function(he,pe){return this.stream.write(this.space(pe)+he.value+this.endline(he))},_e.prototype.text=function(he,pe){return this.stream.write(this.space(pe)+he.value+this.endline(he))},_e.prototype.dtdAttList=function(he,pe){return this.stream.write(this.space(pe)+"<!ATTLIST "+he.elementName+" "+he.attributeName+" "+he.attributeType),he.defaultValueType!=="#DEFAULT"&&this.stream.write(" "+he.defaultValueType),he.defaultValue&&this.stream.write(' "'+he.defaultValue+'"'),this.stream.write(this.spacebeforeslash+">"+this.endline(he))},_e.prototype.dtdElement=function(he,pe){return this.stream.write(this.space(pe)+"<!ELEMENT "+he.name+" "+he.value),this.stream.write(this.spacebeforeslash+">"+this.endline(he))},_e.prototype.dtdEntity=function(he,pe){return this.stream.write(this.space(pe)+"<!ENTITY"),he.pe&&this.stream.write(" %"),this.stream.write(" "+he.name),he.value?this.stream.write(' "'+he.value+'"'):(he.pubID&&he.sysID?this.stream.write(' PUBLIC "'+he.pubID+'" "'+he.sysID+'"'):he.sysID&&this.stream.write(' SYSTEM "'+he.sysID+'"'),he.nData&&this.stream.write(" NDATA "+he.nData)),this.stream.write(this.spacebeforeslash+">"+this.endline(he))},_e.prototype.dtdNotation=function(he,pe){return this.stream.write(this.space(pe)+"<!NOTATION "+he.name),he.pubID&&he.sysID?this.stream.write(' PUBLIC "'+he.pubID+'" "'+he.sysID+'"'):he.pubID?this.stream.write(' PUBLIC "'+he.pubID+'"'):he.sysID&&this.stream.write(' SYSTEM "'+he.sysID+'"'),this.stream.write(this.spacebeforeslash+">"+this.endline(he))},_e.prototype.endline=function(he){return he.isLastRootNode?"":this.newline},_e}(ve)}).call(void 0)},{"./XMLCData":216,"./XMLComment":217,"./XMLDTDAttList":218,"./XMLDTDElement":219,"./XMLDTDEntity":220,"./XMLDTDNotation":221,"./XMLDeclaration":222,"./XMLDocType":223,"./XMLElement":226,"./XMLProcessingInstruction":228,"./XMLRaw":229,"./XMLText":233,"./XMLWriterBase":234}],231:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne,E,b,z,x,re,ae,oe,ve,ye=function(ge,_e){function he(){this.constructor=ge}for(var pe in _e)me.call(_e,pe)&&(ge[pe]=_e[pe]);return he.prototype=_e.prototype,ge.prototype=new he,ge.__super__=_e.prototype,ge},me={}.hasOwnProperty;b=ie("./XMLDeclaration"),z=ie("./XMLDocType"),se=ie("./XMLCData"),te=ie("./XMLComment"),x=ie("./XMLElement"),ae=ie("./XMLRaw"),oe=ie("./XMLText"),re=ie("./XMLProcessingInstruction"),le=ie("./XMLDTDAttList"),ee=ie("./XMLDTDElement"),ne=ie("./XMLDTDEntity"),E=ie("./XMLDTDNotation"),ve=ie("./XMLWriterBase"),Ce.exports=function(ge){function _e(he){_e.__super__.constructor.call(this,he)}return ye(_e,ge),_e.prototype.document=function(he){var pe,ke,Te,Ee,Oe;for(this.textispresent=!1,Ee="",Oe=he.children,ke=0,Te=Oe.length;ke<Te;ke++)pe=Oe[ke],Ee+=function(){switch(!1){case!(pe instanceof b):return this.declaration(pe);case!(pe instanceof z):return this.docType(pe);case!(pe instanceof te):return this.comment(pe);case!(pe instanceof re):return this.processingInstruction(pe);default:return this.element(pe,0)}}.call(this);return this.pretty&&Ee.slice(-this.newline.length)===this.newline&&(Ee=Ee.slice(0,-this.newline.length)),Ee},_e.prototype.attribute=function(he){return" "+he.name+'="'+he.value+'"'},_e.prototype.cdata=function(he,pe){return this.space(pe)+"<![CDATA["+he.text+"]]>"+this.newline},_e.prototype.comment=function(he,pe){return this.space(pe)+"<!-- "+he.text+" -->"+this.newline},_e.prototype.declaration=function(he,pe){var ke;return ke=this.space(pe),ke+='<?xml version="'+he.version+'"',he.encoding!=null&&(ke+=' encoding="'+he.encoding+'"'),he.standalone!=null&&(ke+=' standalone="'+he.standalone+'"'),ke+=this.spacebeforeslash+"?>",ke+=this.newline},_e.prototype.docType=function(he,pe){var ke,Te,Ee,Oe,je;if(pe||(pe=0),Oe=this.space(pe),Oe+="<!DOCTYPE "+he.root().name,he.pubID&&he.sysID?Oe+=' PUBLIC "'+he.pubID+'" "'+he.sysID+'"':he.sysID&&(Oe+=' SYSTEM "'+he.sysID+'"'),he.children.length>0){for(Oe+=" [",Oe+=this.newline,je=he.children,Te=0,Ee=je.length;Te<Ee;Te++)ke=je[Te],Oe+=function(){switch(!1){case!(ke instanceof le):return this.dtdAttList(ke,pe+1);case!(ke instanceof ee):return this.dtdElement(ke,pe+1);case!(ke instanceof ne):return this.dtdEntity(ke,pe+1);case!(ke instanceof E):return this.dtdNotation(ke,pe+1);case!(ke instanceof se):return this.cdata(ke,pe+1);case!(ke instanceof te):return this.comment(ke,pe+1);case!(ke instanceof re):return this.processingInstruction(ke,pe+1);default:throw new Error("Unknown DTD node type: "+ke.constructor.name)}}.call(this);Oe+="]"}return Oe+=this.spacebeforeslash+">",Oe+=this.newline},_e.prototype.element=function(he,pe){var ke,Te,Ee,Oe,je,Pe,Qe,Xe,ot,He,rt,Ye,ut;pe||(pe=0),ut=!1,this.textispresent?(this.newline="",this.pretty=!1):(this.newline=this.newlinedefault,this.pretty=this.prettydefault),Ye=this.space(pe),Xe="",Xe+=Ye+"<"+he.name,ot=he.attributes;for(Qe in ot)me.call(ot,Qe)&&(ke=ot[Qe],Xe+=this.attribute(ke));if(he.children.length===0||he.children.every(function(Ge){return Ge.value===""}))this.allowEmpty?Xe+="></"+he.name+">"+this.newline:Xe+=this.spacebeforeslash+"/>"+this.newline;else if(this.pretty&&he.children.length===1&&he.children[0].value!=null)Xe+=">",Xe+=he.children[0].value,Xe+="</"+he.name+">"+this.newline;else{if(this.dontprettytextnodes){for(He=he.children,Ee=0,je=He.length;Ee<je;Ee++)if(Te=He[Ee],Te.value!=null){this.textispresent++,ut=!0;break}}for(this.textispresent&&(this.newline="",this.pretty=!1,Ye=this.space(pe)),Xe+=">"+this.newline,rt=he.children,Oe=0,Pe=rt.length;Oe<Pe;Oe++)Te=rt[Oe],Xe+=function(){switch(!1){case!(Te instanceof se):return this.cdata(Te,pe+1);case!(Te instanceof te):return this.comment(Te,pe+1);case!(Te instanceof x):return this.element(Te,pe+1);case!(Te instanceof ae):return this.raw(Te,pe+1);case!(Te instanceof oe):return this.text(Te,pe+1);case!(Te instanceof re):return this.processingInstruction(Te,pe+1);default:throw new Error("Unknown XML node type: "+Te.constructor.name)}}.call(this);ut&&this.textispresent--,this.textispresent||(this.newline=this.newlinedefault,this.pretty=this.prettydefault),Xe+=Ye+"</"+he.name+">"+this.newline}return Xe},_e.prototype.processingInstruction=function(he,pe){var ke;return ke=this.space(pe)+"<?"+he.target,he.value&&(ke+=" "+he.value),ke+=this.spacebeforeslash+"?>"+this.newline},_e.prototype.raw=function(he,pe){return this.space(pe)+he.value+this.newline},_e.prototype.text=function(he,pe){return this.space(pe)+he.value+this.newline},_e.prototype.dtdAttList=function(he,pe){var ke;return ke=this.space(pe)+"<!ATTLIST "+he.elementName+" "+he.attributeName+" "+he.attributeType,he.defaultValueType!=="#DEFAULT"&&(ke+=" "+he.defaultValueType),he.defaultValue&&(ke+=' "'+he.defaultValue+'"'),ke+=this.spacebeforeslash+">"+this.newline},_e.prototype.dtdElement=function(he,pe){return this.space(pe)+"<!ELEMENT "+he.name+" "+he.value+this.spacebeforeslash+">"+this.newline},_e.prototype.dtdEntity=function(he,pe){var ke;return ke=this.space(pe)+"<!ENTITY",he.pe&&(ke+=" %"),ke+=" "+he.name,he.value?ke+=' "'+he.value+'"':(he.pubID&&he.sysID?ke+=' PUBLIC "'+he.pubID+'" "'+he.sysID+'"':he.sysID&&(ke+=' SYSTEM "'+he.sysID+'"'),he.nData&&(ke+=" NDATA "+he.nData)),ke+=this.spacebeforeslash+">"+this.newline},_e.prototype.dtdNotation=function(he,pe){var ke;return ke=this.space(pe)+"<!NOTATION "+he.name,he.pubID&&he.sysID?ke+=' PUBLIC "'+he.pubID+'" "'+he.sysID+'"':he.pubID?ke+=' PUBLIC "'+he.pubID+'"':he.sysID&&(ke+=' SYSTEM "'+he.sysID+'"'),ke+=this.spacebeforeslash+">"+this.newline},_e.prototype.openNode=function(he,pe){var ke,Te,Ee,Oe;if(pe||(pe=0),he instanceof x){Ee=this.space(pe)+"<"+he.name,Oe=he.attributes;for(Te in Oe)me.call(Oe,Te)&&(ke=Oe[Te],Ee+=this.attribute(ke));return Ee+=(he.children?">":"/>")+this.newline}return Ee=this.space(pe)+"<!DOCTYPE "+he.rootNodeName,he.pubID&&he.sysID?Ee+=' PUBLIC "'+he.pubID+'" "'+he.sysID+'"':he.sysID&&(Ee+=' SYSTEM "'+he.sysID+'"'),Ee+=(he.children?" [":">")+this.newline},_e.prototype.closeNode=function(he,pe){switch(pe||(pe=0),!1){case!(he instanceof x):return this.space(pe)+"</"+he.name+">"+this.newline;case!(he instanceof z):return this.space(pe)+"]>"+this.newline}},_e}(ve)}).call(void 0)},{"./XMLCData":216,"./XMLComment":217,"./XMLDTDAttList":218,"./XMLDTDElement":219,"./XMLDTDEntity":220,"./XMLDTDNotation":221,"./XMLDeclaration":222,"./XMLDocType":223,"./XMLElement":226,"./XMLProcessingInstruction":228,"./XMLRaw":229,"./XMLText":233,"./XMLWriterBase":234}],232:[function(ie,Ce,ue){"use strict";(function(){var se=function(le,ee){return function(){return le.apply(ee,arguments)}},te={}.hasOwnProperty;Ce.exports=function(){function le(ee){this.assertLegalChar=se(this.assertLegalChar,this);var ne,E,b;ee||(ee={}),this.noDoubleEncoding=ee.noDoubleEncoding,E=ee.stringify||{};for(ne in E)te.call(E,ne)&&(b=E[ne],this[ne]=b)}return le.prototype.eleName=function(ee){return ee=""+ee||"",this.assertLegalChar(ee)},le.prototype.eleText=function(ee){return ee=""+ee||"",this.assertLegalChar(this.elEscape(ee))},le.prototype.cdata=function(ee){return ee=""+ee||"",ee=ee.replace("]]>","]]]]><![CDATA[>"),this.assertLegalChar(ee)},le.prototype.comment=function(ee){if(ee=""+ee||"",ee.match(/--/))throw new Error("Comment text cannot contain double-hypen: "+ee);return this.assertLegalChar(ee)},le.prototype.raw=function(ee){return""+ee||""},le.prototype.attName=function(ee){return ee=""+ee||""},le.prototype.attValue=function(ee){return ee=""+ee||"",this.attEscape(ee)},le.prototype.insTarget=function(ee){return""+ee||""},le.prototype.insValue=function(ee){if(ee=""+ee||"",ee.match(/\?>/))throw new Error("Invalid processing instruction value: "+ee);return ee},le.prototype.xmlVersion=function(ee){if(ee=""+ee||"",!ee.match(/1\.[0-9]+/))throw new Error("Invalid version number: "+ee);return ee},le.prototype.xmlEncoding=function(ee){if(ee=""+ee||"",!ee.match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw new Error("Invalid encoding: "+ee);return ee},le.prototype.xmlStandalone=function(ee){return ee?"yes":"no"},le.prototype.dtdPubID=function(ee){return""+ee||""},le.prototype.dtdSysID=function(ee){return""+ee||""},le.prototype.dtdElementValue=function(ee){return""+ee||""},le.prototype.dtdAttType=function(ee){return""+ee||""},le.prototype.dtdAttDefault=function(ee){return ee!=null?""+ee||"":ee},le.prototype.dtdEntityValue=function(ee){return""+ee||""},le.prototype.dtdNData=function(ee){return""+ee||""},le.prototype.convertAttKey="@",le.prototype.convertPIKey="?",le.prototype.convertTextKey="#text",le.prototype.convertCDataKey="#cdata",le.prototype.convertCommentKey="#comment",le.prototype.convertRawKey="#raw",le.prototype.assertLegalChar=function(ee){var ne;if(ne=ee.match(/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/))throw new Error("Invalid character in string: "+ee+" at index "+ne.index);return ee},le.prototype.elEscape=function(ee){var ne;return ne=this.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,ee.replace(ne,"&").replace(/</g,"<").replace(/>/g,">").replace(/\r/g,"
")},le.prototype.attEscape=function(ee){var ne;return ne=this.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,ee.replace(ne,"&").replace(/</g,"<").replace(/"/g,""").replace(/\t/g,"	").replace(/\n/g,"
").replace(/\r/g,"
")},le}()}).call(void 0)},{}],233:[function(ie,Ce,ue){"use strict";var se=ie("babel-runtime/core-js/object/create"),te=function(le){return le&&le.__esModule?le:{default:le}}(se);(function(){var le,ee=function(E,b){function z(){this.constructor=E}for(var x in b)ne.call(b,x)&&(E[x]=b[x]);return z.prototype=b.prototype,E.prototype=new z,E.__super__=b.prototype,E},ne={}.hasOwnProperty;le=ie("./XMLNode"),Ce.exports=function(E){function b(z,x){if(b.__super__.constructor.call(this,z),x==null)throw new Error("Missing element text");this.value=this.stringify.eleText(x)}return ee(b,E),b.prototype.clone=function(){return(0,te.default)(this)},b.prototype.toString=function(z){return this.options.writer.set(z).text(this)},b}(le)}).call(void 0)},{"./XMLNode":227,"babel-runtime/core-js/object/create":19}],234:[function(ie,Ce,ue){"use strict";(function(){var se={}.hasOwnProperty;Ce.exports=function(){function te(le){var ee,ne,E,b,z,x,re,ae,oe;le||(le={}),this.pretty=le.pretty||!1,this.allowEmpty=(ne=le.allowEmpty)!=null&&ne,this.pretty?(this.indent=(E=le.indent)!=null?E:" ",this.newline=(b=le.newline)!=null?b:`
|
|
|
`,this.offset=(z=le.offset)!=null?z:0,this.dontprettytextnodes=(x=le.dontprettytextnodes)!=null?x:0):(this.indent="",this.newline="",this.offset=0,this.dontprettytextnodes=0),this.spacebeforeslash=(re=le.spacebeforeslash)!=null?re:"",this.spacebeforeslash===!0&&(this.spacebeforeslash=" "),this.newlinedefault=this.newline,this.prettydefault=this.pretty,ae=le.writer||{};for(ee in ae)se.call(ae,ee)&&(oe=ae[ee],this[ee]=oe)}return te.prototype.set=function(le){var ee,ne,E;le||(le={}),"pretty"in le&&(this.pretty=le.pretty),"allowEmpty"in le&&(this.allowEmpty=le.allowEmpty),this.pretty?(this.indent="indent"in le?le.indent:" ",this.newline="newline"in le?le.newline:`
|
|
|
`,this.offset="offset"in le?le.offset:0,this.dontprettytextnodes="dontprettytextnodes"in le?le.dontprettytextnodes:0):(this.indent="",this.newline="",this.offset=0,this.dontprettytextnodes=0),this.spacebeforeslash="spacebeforeslash"in le?le.spacebeforeslash:"",this.spacebeforeslash===!0&&(this.spacebeforeslash=" "),this.newlinedefault=this.newline,this.prettydefault=this.pretty,ne=le.writer||{};for(ee in ne)se.call(ne,ee)&&(E=ne[ee],this[ee]=E);return this},te.prototype.space=function(le){var ee;return this.pretty?(ee=(le||0)+this.offset+1,ee>0?new Array(ee).join(this.indent):""):""},te}()}).call(void 0)},{}],235:[function(ie,Ce,ue){"use strict";(function(){var se,te,le,ee,ne,E,b;b=ie("./Utility"),ne=b.assign,E=b.isFunction,se=ie("./XMLDocument"),te=ie("./XMLDocumentCB"),ee=ie("./XMLStringWriter"),le=ie("./XMLStreamWriter"),Ce.exports.create=function(z,x,re,ae){var oe,ve;if(z==null)throw new Error("Root element needs a name");return ae=ne({},x,re,ae),oe=new se(ae),ve=oe.element(z),ae.headless||(oe.declaration(ae),ae.pubID==null&&ae.sysID==null||oe.doctype(ae)),ve},Ce.exports.begin=function(z,x,re){var ae;return E(z)&&(ae=[z,x],x=ae[0],re=ae[1],z={}),x?new te(z,x,re):new se(z)},Ce.exports.stringWriter=function(z){return new ee(z)},Ce.exports.streamWriter=function(z,x){return new le(z,x)}}).call(void 0)},{"./Utility":214,"./XMLDocument":224,"./XMLDocumentCB":225,"./XMLStreamWriter":230,"./XMLStringWriter":231}],236:[function(ie,Ce,ue){function se(){for(var le={},ee=0;ee<arguments.length;ee++){var ne=arguments[ee];for(var E in ne)te.call(ne,E)&&(le[E]=ne[E])}return le}Ce.exports=se;var te=Object.prototype.hasOwnProperty},{}],237:[function(ie,Ce,ue){"use strict";function se(ae,oe,ve){ee.isBuffer(oe)||(oe=new ee(oe)),ee.isBuffer(ve)||(ve=new ee(ve)),oe.length>x?oe=ae(oe):oe.length<x&&(oe=ee.concat([oe,re],x));for(var ye=new ee(x),me=new ee(x),ge=0;ge<x;ge++)ye[ge]=54^oe[ge],me[ge]=92^oe[ge];var _e=ae(ee.concat([ye,ve]));return ae(ee.concat([me,_e]))}function te(ae,oe){ae=ae||"sha1";var ve=z[ae],ye=[],me=0;return ve||le("algorithm:",ae,"is not yet supported"),{update:function(ge){return ee.isBuffer(ge)||(ge=new ee(ge)),ye.push(ge),me+=ge.length,this},digest:function(ge){var _e=ee.concat(ye),he=oe?se(ve,oe,_e):ve(_e);return ye=null,ge?he.toString(ge):he}}}function le(){var ae=[].slice.call(arguments).join(" ");throw new Error([ae,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join(`
|
|
|
`))}var ee=ie("buffer").Buffer,ne=ie("./sha"),E=ie("./sha256"),b=ie("./md5"),z={sha1:ne,sha256:E,md5:b},x=64,re=new ee(x);re.fill(0),ue.createHash=function(ae){return te(ae)},ue.createHmac=function(ae,oe){return te(ae,oe)},function(ae,oe){for(var ve in ae)oe(ae[ve],ve)}(["createCredentials","createCipher","createCipheriv","createDecipher","createDecipheriv","createSign","createVerify","createDiffieHellman","pbkdf2"],function(ae){ue[ae]=function(){le("sorry,",ae,"is not implemented yet")}})},{"./md5":239,"./sha":240,"./sha256":241,buffer:38}],238:[function(ie,Ce,ue){"use strict";function se(z,x){if(z.length%ne!=0){var re=z.length+(ne-z.length%ne);z=ee.concat([z,E],re)}for(var ae=[],oe=x?z.readInt32BE:z.readInt32LE,ve=0;ve<z.length;ve+=ne)ae.push(oe.call(z,ve));return ae}function te(z,x,re){for(var ae=new ee(x),oe=re?ae.writeInt32BE:ae.writeInt32LE,ve=0;ve<z.length;ve++)oe.call(ae,z[ve],4*ve,!0);return ae}function le(z,x,re,ae){return ee.isBuffer(z)||(z=new ee(z)),te(x(se(z,ae),z.length*b),re,ae)}var ee=ie("buffer").Buffer,ne=4,E=new ee(ne);E.fill(0);var b=8;Ce.exports={hash:le}},{buffer:38}],239:[function(ie,Ce,ue){"use strict";function se(re,ae){re[ae>>5]|=128<<ae%32,re[14+(ae+64>>>9<<4)]=ae;for(var oe=1732584193,ve=-271733879,ye=-1732584194,me=271733878,ge=0;ge<re.length;ge+=16){var _e=oe,he=ve,pe=ye,ke=me;oe=le(oe,ve,ye,me,re[ge+0],7,-680876936),me=le(me,oe,ve,ye,re[ge+1],12,-389564586),ye=le(ye,me,oe,ve,re[ge+2],17,606105819),ve=le(ve,ye,me,oe,re[ge+3],22,-1044525330),oe=le(oe,ve,ye,me,re[ge+4],7,-176418897),me=le(me,oe,ve,ye,re[ge+5],12,1200080426),ye=le(ye,me,oe,ve,re[ge+6],17,-1473231341),ve=le(ve,ye,me,oe,re[ge+7],22,-45705983),oe=le(oe,ve,ye,me,re[ge+8],7,1770035416),me=le(me,oe,ve,ye,re[ge+9],12,-1958414417),ye=le(ye,me,oe,ve,re[ge+10],17,-42063),ve=le(ve,ye,me,oe,re[ge+11],22,-1990404162),oe=le(oe,ve,ye,me,re[ge+12],7,1804603682),me=le(me,oe,ve,ye,re[ge+13],12,-40341101),ye=le(ye,me,oe,ve,re[ge+14],17,-1502002290),ve=le(ve,ye,me,oe,re[ge+15],22,1236535329),oe=ee(oe,ve,ye,me,re[ge+1],5,-165796510),me=ee(me,oe,ve,ye,re[ge+6],9,-1069501632),ye=ee(ye,me,oe,ve,re[ge+11],14,643717713),ve=ee(ve,ye,me,oe,re[ge+0],20,-373897302),oe=ee(oe,ve,ye,me,re[ge+5],5,-701558691),me=ee(me,oe,ve,ye,re[ge+10],9,38016083),ye=ee(ye,me,oe,ve,re[ge+15],14,-660478335),ve=ee(ve,ye,me,oe,re[ge+4],20,-405537848),oe=ee(oe,ve,ye,me,re[ge+9],5,568446438),me=ee(me,oe,ve,ye,re[ge+14],9,-1019803690),ye=ee(ye,me,oe,ve,re[ge+3],14,-187363961),ve=ee(ve,ye,me,oe,re[ge+8],20,1163531501),oe=ee(oe,ve,ye,me,re[ge+13],5,-1444681467),me=ee(me,oe,ve,ye,re[ge+2],9,-51403784),ye=ee(ye,me,oe,ve,re[ge+7],14,1735328473),ve=ee(ve,ye,me,oe,re[ge+12],20,-1926607734),oe=ne(oe,ve,ye,me,re[ge+5],4,-378558),me=ne(me,oe,ve,ye,re[ge+8],11,-2022574463),ye=ne(ye,me,oe,ve,re[ge+11],16,1839030562),ve=ne(ve,ye,me,oe,re[ge+14],23,-35309556),oe=ne(oe,ve,ye,me,re[ge+1],4,-1530992060),me=ne(me,oe,ve,ye,re[ge+4],11,1272893353),ye=ne(ye,me,oe,ve,re[ge+7],16,-155497632),ve=ne(ve,ye,me,oe,re[ge+10],23,-1094730640),oe=ne(oe,ve,ye,me,re[ge+13],4,681279174),me=ne(me,oe,ve,ye,re[ge+0],11,-358537222),ye=ne(ye,me,oe,ve,re[ge+3],16,-722521979),ve=ne(ve,ye,me,oe,re[ge+6],23,76029189),oe=ne(oe,ve,ye,me,re[ge+9],4,-640364487),me=ne(me,oe,ve,ye,re[ge+12],11,-421815835),ye=ne(ye,me,oe,ve,re[ge+15],16,530742520),ve=ne(ve,ye,me,oe,re[ge+2],23,-995338651),oe=E(oe,ve,ye,me,re[ge+0],6,-198630844),me=E(me,oe,ve,ye,re[ge+7],10,1126891415),ye=E(ye,me,oe,ve,re[ge+14],15,-1416354905),ve=E(ve,ye,me,oe,re[ge+5],21,-57434055),oe=E(oe,ve,ye,me,re[ge+12],6,1700485571),me=E(me,oe,ve,ye,re[ge+3],10,-1894986606),ye=E(ye,me,oe,ve,re[ge+10],15,-1051523),ve=E(ve,ye,me,oe,re[ge+1],21,-2054922799),oe=E(oe,ve,ye,me,re[ge+8],6,1873313359),me=E(me,oe,ve,ye,re[ge+15],10,-30611744),ye=E(ye,me,oe,ve,re[ge+6],15,-1560198380),ve=E(ve,ye,me,oe,re[ge+13],21,1309151649),oe=E(oe,ve,ye,me,re[ge+4],6,-145523070),me=E(me,oe,ve,ye,re[ge+11],10,-1120210379),ye=E(ye,me,oe,ve,re[ge+2],15,718787259),ve=E(ve,ye,me,oe,re[ge+9],21,-343485551),oe=b(oe,_e),ve=b(ve,he),ye=b(ye,pe),me=b(me,ke)}return Array(oe,ve,ye,me)}function te(re,ae,oe,ve,ye,me){return b(z(b(b(ae,re),b(ve,me)),ye),oe)}function le(re,ae,oe,ve,ye,me,ge){return te(ae&oe|~ae&ve,re,ae,ye,me,ge)}function ee(re,ae,oe,ve,ye,me,ge){return te(ae&ve|oe&~ve,re,ae,ye,me,ge)}function ne(re,ae,oe,ve,ye,me,ge){return te(ae^oe^ve,re,ae,ye,me,ge)}function E(re,ae,oe,ve,ye,me,ge){return te(oe^(ae|~ve),re,ae,ye,me,ge)}function b(re,ae){var oe=(65535&re)+(65535&ae);return(re>>16)+(ae>>16)+(oe>>16)<<16|65535&oe}function z(re,ae){return re<<ae|re>>>32-ae}var x=ie("./helpers");Ce.exports=function(re){return x.hash(re,se,16)}},{"./helpers":238}],240:[function(ie,Ce,ue){"use strict";function se(b,z){b[z>>5]|=128<<24-z%32,b[15+(z+64>>9<<4)]=z;for(var x=Array(80),re=1732584193,ae=-271733879,oe=-1732584194,ve=271733878,ye=-1009589776,me=0;me<b.length;me+=16){for(var ge=re,_e=ae,he=oe,pe=ve,ke=ye,Te=0;Te<80;Te++){x[Te]=Te<16?b[me+Te]:ne(x[Te-3]^x[Te-8]^x[Te-14]^x[Te-16],1);var Ee=ee(ee(ne(re,5),te(Te,ae,oe,ve)),ee(ee(ye,x[Te]),le(Te)));ye=ve,ve=oe,oe=ne(ae,30),ae=re,re=Ee}re=ee(re,ge),ae=ee(ae,_e),oe=ee(oe,he),ve=ee(ve,pe),ye=ee(ye,ke)}return Array(re,ae,oe,ve,ye)}function te(b,z,x,re){return b<20?z&x|~z&re:b<40?z^x^re:b<60?z&x|z&re|x&re:z^x^re}function le(b){return b<20?1518500249:b<40?1859775393:b<60?-1894007588:-899497514}function ee(b,z){var x=(65535&b)+(65535&z);return(b>>16)+(z>>16)+(x>>16)<<16|65535&x}function ne(b,z){return b<<z|b>>>32-z}var E=ie("./helpers");Ce.exports=function(b){return E.hash(b,se,20,!0)}},{"./helpers":238}],241:[function(ie,Ce,ue){"use strict";var se=ie("./helpers"),te=function(oe,ve){var ye=(65535&oe)+(65535&ve);return(oe>>16)+(ve>>16)+(ye>>16)<<16|65535&ye},le=function(oe,ve){return oe>>>ve|oe<<32-ve},ee=function(oe,ve){return oe>>>ve},ne=function(oe,ve,ye){return oe&ve^~oe&ye},E=function(oe,ve,ye){return oe&ve^oe&ye^ve&ye},b=function(oe){return le(oe,2)^le(oe,13)^le(oe,22)},z=function(oe){return le(oe,6)^le(oe,11)^le(oe,25)},x=function(oe){return le(oe,7)^le(oe,18)^ee(oe,3)},re=function(oe){return le(oe,17)^le(oe,19)^ee(oe,10)},ae=function(oe,ve){var ye,me,ge,_e,he,pe,ke,Te,Ee,Oe,je,Pe,Qe=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298),Xe=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),ot=new Array(64);oe[ve>>5]|=128<<24-ve%32,oe[15+(ve+64>>9<<4)]=ve;for(var Ee=0;Ee<oe.length;Ee+=16){ye=Xe[0],me=Xe[1],ge=Xe[2],_e=Xe[3],he=Xe[4],pe=Xe[5],ke=Xe[6],Te=Xe[7];for(var Oe=0;Oe<64;Oe++)ot[Oe]=Oe<16?oe[Oe+Ee]:te(te(te(re(ot[Oe-2]),ot[Oe-7]),x(ot[Oe-15])),ot[Oe-16]),je=te(te(te(te(Te,z(he)),ne(he,pe,ke)),Qe[Oe]),ot[Oe]),Pe=te(b(ye),E(ye,me,ge)),Te=ke,ke=pe,pe=he,he=te(_e,je),_e=ge,ge=me,me=ye,ye=te(je,Pe);Xe[0]=te(ye,Xe[0]),Xe[1]=te(me,Xe[1]),Xe[2]=te(ge,Xe[2]),Xe[3]=te(_e,Xe[3]),Xe[4]=te(he,Xe[4]),Xe[5]=te(pe,Xe[5]),Xe[6]=te(ke,Xe[6]),Xe[7]=te(Te,Xe[7])}return Xe};Ce.exports=function(oe){return se.hash(oe,ae,32,!0)}},{"./helpers":238}],242:[function(ie,Ce,ue){(function(se){"use strict";function te(ae){return ae&&ae.__esModule?ae:{default:ae}}var le=ie("babel-runtime/core-js/object/create"),ee=te(le),ne=ie("babel-runtime/helpers/classCallCheck"),E=te(ne),b=ie("babel-runtime/helpers/createClass"),z=te(b),x=ie("babel-runtime/helpers/typeof"),re=te(x);(function(ae){if((ue===void 0?"undefined":(0,re.default)(ue))==="object"&&Ce!==void 0)Ce.exports=ae();else if(typeof ce=="function"&&ce.amd)ce([],ae);else{var oe;oe=typeof window!="undefined"?window:se!==void 0?se:typeof self!="undefined"?self:this,oe.mime=ae()}})(function(){return function ae(oe,ve,ye){function me(he,pe){if(!ve[he]){if(!oe[he]){var ke=typeof ie=="function"&&ie;if(!pe&&ke)return ke(he,!0);if(ge)return ge(he,!0);var Te=new Error("Cannot find module '"+he+"'");throw Te.code="MODULE_NOT_FOUND",Te}var Ee=ve[he]={exports:{}};oe[he][0].call(Ee.exports,function(Oe){var je=oe[he][1][Oe];return me(je||Oe)},Ee,Ee.exports,ae,oe,ve,ye)}return ve[he].exports}for(var ge=typeof ie=="function"&&ie,_e=0;_e<ye.length;_e++)me(ye[_e]);return me}({1:[function(ae,oe,ve){var ye=function(){function me(){(0,E.default)(this,me),this._types=(0,ee.default)(null),this._extensions=(0,ee.default)(null);for(var ge=0;ge<arguments.length;ge++)this.define(arguments[ge])}return(0,z.default)(me,[{key:"define",value:function(ge,_e){for(var he in ge){for(var pe=ge[he],ke=0;ke<pe.length;ke++){var Te=pe[ke];if(!_e&&Te in this._types)throw new Error('Attempt to change mapping for "'+Te+'" extension from "'+this._types[Te]+'" to "'+he+'". Pass `force=true` to allow this, otherwise remove "'+Te+'" from the list of extensions for "'+he+'".');this._types[Te]=he}!_e&&this._extensions[he]||(this._extensions[he]=pe[0])}}},{key:"getType",value:function(ge){ge=String(ge);var _e=ge.replace(/^.*[\/\\]/,"").toLowerCase(),he=_e.replace(/^.*\./,"").toLowerCase(),pe=_e.length<ge.length;return(he.length<_e.length-1||!pe)&&this._types[he]||null}},{key:"getExtension",value:function(ge){return(ge=/^\s*([^;\s]*)/.test(ge)&&RegExp.$1)&&this._extensions[ge.toLowerCase()]||null}}]),me}();oe.exports=ye},{}],2:[function(ae,oe,ve){var ye=ae("./Mime");oe.exports=new ye(ae("./types/standard"),ae("./types/other"))},{"./Mime":1,"./types/other":3,"./types/standard":4}],3:[function(ae,oe,ve){oe.exports={"application/prs.cww":["cww"],"application/vnd.3gpp.pic-bw-large":["plb"],"application/vnd.3gpp.pic-bw-small":["psb"],"application/vnd.3gpp.pic-bw-var":["pvb"],"application/vnd.3gpp2.tcap":["tcap"],"application/vnd.3m.post-it-notes":["pwn"],"application/vnd.accpac.simply.aso":["aso"],"application/vnd.accpac.simply.imp":["imp"],"application/vnd.acucobol":["acu"],"application/vnd.acucorp":["atc","acutc"],"application/vnd.adobe.air-application-installer-package+zip":["air"],"application/vnd.adobe.formscentral.fcdt":["fcdt"],"application/vnd.adobe.fxp":["fxp","fxpl"],"application/vnd.adobe.xdp+xml":["xdp"],"application/vnd.adobe.xfdf":["xfdf"],"application/vnd.ahead.space":["ahead"],"application/vnd.airzip.filesecure.azf":["azf"],"application/vnd.airzip.filesecure.azs":["azs"],"application/vnd.amazon.ebook":["azw"],"application/vnd.americandynamics.acc":["acc"],"application/vnd.amiga.ami":["ami"],"application/vnd.android.package-archive":["apk"],"application/vnd.anser-web-certificate-issue-initiation":["cii"],"application/vnd.anser-web-funds-transfer-initiation":["fti"],"application/vnd.antix.game-component":["atx"],"application/vnd.apple.installer+xml":["mpkg"],"application/vnd.apple.mpegurl":["m3u8"],"application/vnd.apple.pkpass":["pkpass"],"application/vnd.aristanetworks.swi":["swi"],"application/vnd.astraea-software.iota":["iota"],"application/vnd.audiograph":["aep"],"application/vnd.blueice.multipass":["mpm"],"application/vnd.bmi":["bmi"],"application/vnd.businessobjects":["rep"],"application/vnd.chemdraw+xml":["cdxml"],"application/vnd.chipnuts.karaoke-mmd":["mmd"],"application/vnd.cinderella":["cdy"],"application/vnd.claymore":["cla"],"application/vnd.cloanto.rp9":["rp9"],"application/vnd.clonk.c4group":["c4g","c4d","c4f","c4p","c4u"],"application/vnd.cluetrust.cartomobile-config":["c11amc"],"application/vnd.cluetrust.cartomobile-config-pkg":["c11amz"],"application/vnd.commonspace":["csp"],"application/vnd.contact.cmsg":["cdbcmsg"],"application/vnd.cosmocaller":["cmc"],"application/vnd.crick.clicker":["clkx"],"application/vnd.crick.clicker.keyboard":["clkk"],"application/vnd.crick.clicker.palette":["clkp"],"application/vnd.crick.clicker.template":["clkt"],"application/vnd.crick.clicker.wordbank":["clkw"],"application/vnd.criticaltools.wbs+xml":["wbs"],"application/vnd.ctc-posml":["pml"],"application/vnd.cups-ppd":["ppd"],"application/vnd.curl.car":["car"],"application/vnd.curl.pcurl":["pcurl"],"application/vnd.dart":["dart"],"application/vnd.data-vision.rdz":["rdz"],"application/vnd.dece.data":["uvf","uvvf","uvd","uvvd"],"application/vnd.dece.ttml+xml":["uvt","uvvt"],"application/vnd.dece.unspecified":["uvx","uvvx"],"application/vnd.dece.zip":["uvz","uvvz"],"application/vnd.denovo.fcselayout-link":["fe_launch"],"application/vnd.dna":["dna"],"application/vnd.dolby.mlp":["mlp"],"application/vnd.dpgraph":["dpg"],"application/vnd.dreamfactory":["dfac"],"application/vnd.ds-keypoint":["kpxx"],"application/vnd.dvb.ait":["ait"],"application/vnd.dvb.service":["svc"],"application/vnd.dynageo":["geo"],"application/vnd.ecowin.chart":["mag"],"application/vnd.enliven":["nml"],"application/vnd.epson.esf":["esf"],"application/vnd.epson.msf":["msf"],"application/vnd.epson.quickanime":["qam"],"application/vnd.epson.salt":["slt"],"application/vnd.epson.ssf":["ssf"],"application/vnd.eszigno3+xml":["es3","et3"],"application/vnd.ezpix-album":["ez2"],"application/vnd.ezpix-package":["ez3"],"application/vnd.fdf":["fdf"],"application/vnd.fdsn.mseed":["mseed"],"application/vnd.fdsn.seed":["seed","dataless"],"application/vnd.flographit":["gph"],"application/vnd.fluxtime.clip":["ftc"],"application/vnd.framemaker":["fm","frame","maker","book"],"application/vnd.frogans.fnc":["fnc"],"application/vnd.frogans.ltf":["ltf"],"application/vnd.fsc.weblaunch":["fsc"],"application/vnd.fujitsu.oasys":["oas"],"application/vnd.fujitsu.oasys2":["oa2"],"application/vnd.fujitsu.oasys3":["oa3"],"application/vnd.fujitsu.oasysgp":["fg5"],"application/vnd.fujitsu.oasysprs":["bh2"],"application/vnd.fujixerox.ddd":["ddd"],"application/vnd.fujixerox.docuworks":["xdw"],"application/vnd.fujixerox.docuworks.binder":["xbd"],"application/vnd.fuzzysheet":["fzs"],"application/vnd.genomatix.tuxedo":["txd"],"application/vnd.geogebra.file":["ggb"],"application/vnd.geogebra.tool":["ggt"],"application/vnd.geometry-explorer":["gex","gre"],"application/vnd.geonext":["gxt"],"application/vnd.geoplan":["g2w"],"application/vnd.geospace":["g3w"],"application/vnd.gmx":["gmx"],"application/vnd.google-apps.document":["gdoc"],"application/vnd.google-apps.presentation":["gslides"],"application/vnd.google-apps.spreadsheet":["gsheet"],"application/vnd.google-earth.kml+xml":["kml"],"application/vnd.google-earth.kmz":["kmz"],"application/vnd.grafeq":["gqf","gqs"],"application/vnd.groove-account":["gac"],"application/vnd.groove-help":["ghf"],"application/vnd.groove-identity-message":["gim"],"application/vnd.groove-injector":["grv"],"application/vnd.groove-tool-message":["gtm"],"application/vnd.groove-tool-template":["tpl"],"application/vnd.groove-vcard":["vcg"],"application/vnd.hal+xml":["hal"],"application/vnd.handheld-entertainment+xml":["zmm"],"application/vnd.hbci":["hbci"],"application/vnd.hhe.lesson-player":["les"],"application/vnd.hp-hpgl":["hpgl"],"application/vnd.hp-hpid":["hpid"],"application/vnd.hp-hps":["hps"],"application/vnd.hp-jlyt":["jlt"],"application/vnd.hp-pcl":["pcl"],"application/vnd.hp-pclxl":["pclxl"],"application/vnd.hydrostatix.sof-data":["sfd-hdstx"],"application/vnd.ibm.minipay":["mpy"],"application/vnd.ibm.modcap":["afp","listafp","list3820"],"application/vnd.ibm.rights-management":["irm"],"application/vnd.ibm.secure-container":["sc"],"application/vnd.iccprofile":["icc","icm"],"application/vnd.igloader":["igl"],"application/vnd.immervision-ivp":["ivp"],"application/vnd.immervision-ivu":["ivu"],"application/vnd.insors.igm":["igm"],"application/vnd.intercon.formnet":["xpw","xpx"],"application/vnd.intergeo":["i2g"],"application/vnd.intu.qbo":["qbo"],"application/vnd.intu.qfx":["qfx"],"application/vnd.ipunplugged.rcprofile":["rcprofile"],"application/vnd.irepository.package+xml":["irp"],"application/vnd.is-xpr":["xpr"],"application/vnd.isac.fcs":["fcs"],"application/vnd.jam":["jam"],"application/vnd.jcp.javame.midlet-rms":["rms"],"application/vnd.jisp":["jisp"],"application/vnd.joost.joda-archive":["joda"],"application/vnd.kahootz":["ktz","ktr"],"application/vnd.kde.karbon":["karbon"],"application/vnd.kde.kchart":["chrt"],"application/vnd.kde.kformula":["kfo"],"application/vnd.kde.kivio":["flw"],"application/vnd.kde.kontour":["kon"],"application/vnd.kde.kpresenter":["kpr","kpt"],"application/vnd.kde.kspread":["ksp"],"application/vnd.kde.kword":["kwd","kwt"],"application/vnd.kenameaapp":["htke"],"application/vnd.kidspiration":["kia"],"application/vnd.kinar":["kne","knp"],"application/vnd.koan":["skp","skd","skt","skm"],"application/vnd.kodak-descriptor":["sse"],"application/vnd.las.las+xml":["lasxml"],"application/vnd.llamagraphics.life-balance.desktop":["lbd"],"application/vnd.llamagraphics.life-balance.exchange+xml":["lbe"],"application/vnd.lotus-1-2-3":["123"],"application/vnd.lotus-approach":["apr"],"application/vnd.lotus-freelance":["pre"],"application/vnd.lotus-notes":["nsf"],"application/vnd.lotus-organizer":["org"],"application/vnd.lotus-screencam":["scm"],"application/vnd.lotus-wordpro":["lwp"],"application/vnd.macports.portpkg":["portpkg"],"application/vnd.mcd":["mcd"],"application/vnd.medcalcdata":["mc1"],"application/vnd.mediastation.cdkey":["cdkey"],"application/vnd.mfer":["mwf"],"application/vnd.mfmp":["mfm"],"application/vnd.micrografx.flo":["flo"],"application/vnd.micrografx.igx":["igx"],"application/vnd.mif":["mif"],"application/vnd.mobius.daf":["daf"],"application/vnd.mobius.dis":["dis"],"application/vnd.mobius.mbk":["mbk"],"application/vnd.mobius.mqy":["mqy"],"application/vnd.mobius.msl":["msl"],"application/vnd.mobius.plc":["plc"],"application/vnd.mobius.txf":["txf"],"application/vnd.mophun.application":["mpn"],"application/vnd.mophun.certificate":["mpc"],"application/vnd.mozilla.xul+xml":["xul"],"application/vnd.ms-artgalry":["cil"],"application/vnd.ms-cab-compressed":["cab"],"application/vnd.ms-excel":["xls","xlm","xla","xlc","xlt","xlw"],"application/vnd.ms-excel.addin.macroenabled.12":["xlam"],"application/vnd.ms-excel.sheet.binary.macroenabled.12":["xlsb"],"application/vnd.ms-excel.sheet.macroenabled.12":["xlsm"],"application/vnd.ms-excel.template.macroenabled.12":["xltm"],"application/vnd.ms-fontobject":["eot"],"application/vnd.ms-htmlhelp":["chm"],"application/vnd.ms-ims":["ims"],"application/vnd.ms-lrm":["lrm"],"application/vnd.ms-officetheme":["thmx"],"application/vnd.ms-outlook":["msg"],"application/vnd.ms-pki.seccat":["cat"],"application/vnd.ms-pki.stl":["stl"],"application/vnd.ms-powerpoint":["ppt","pps","pot"],"application/vnd.ms-powerpoint.addin.macroenabled.12":["ppam"],"application/vnd.ms-powerpoint.presentation.macroenabled.12":["pptm"],"application/vnd.ms-powerpoint.slide.macroenabled.12":["sldm"],"application/vnd.ms-powerpoint.slideshow.macroenabled.12":["ppsm"],"application/vnd.ms-powerpoint.template.macroenabled.12":["potm"],"application/vnd.ms-project":["mpp","mpt"],"application/vnd.ms-word.document.macroenabled.12":["docm"],"application/vnd.ms-word.template.macroenabled.12":["dotm"],"application/vnd.ms-works":["wps","wks","wcm","wdb"],"application/vnd.ms-wpl":["wpl"],"application/vnd.ms-xpsdocument":["xps"],"application/vnd.mseq":["mseq"],"application/vnd.musician":["mus"],"application/vnd.muvee.style":["msty"],"application/vnd.mynfc":["taglet"],"application/vnd.neurolanguage.nlu":["nlu"],"application/vnd.nitf":["ntf","nitf"],"application/vnd.noblenet-directory":["nnd"],"application/vnd.noblenet-sealer":["nns"],"application/vnd.noblenet-web":["nnw"],"application/vnd.nokia.n-gage.data":["ngdat"],"application/vnd.nokia.n-gage.symbian.install":["n-gage"],"application/vnd.nokia.radio-preset":["rpst"],"application/vnd.nokia.radio-presets":["rpss"],"application/vnd.novadigm.edm":["edm"],"application/vnd.novadigm.edx":["edx"],"application/vnd.novadigm.ext":["ext"],"application/vnd.oasis.opendocument.chart":["odc"],"application/vnd.oasis.opendocument.chart-template":["otc"],"application/vnd.oasis.opendocument.database":["odb"],"application/vnd.oasis.opendocument.formula":["odf"],"application/vnd.oasis.opendocument.formula-template":["odft"],"application/vnd.oasis.opendocument.graphics":["odg"],"application/vnd.oasis.opendocument.graphics-template":["otg"],"application/vnd.oasis.opendocument.image":["odi"],"application/vnd.oasis.opendocument.image-template":["oti"],"application/vnd.oasis.opendocument.presentation":["odp"],"application/vnd.oasis.opendocument.presentation-template":["otp"],"application/vnd.oasis.opendocument.spreadsheet":["ods"],"application/vnd.oasis.opendocument.spreadsheet-template":["ots"],"application/vnd.oasis.opendocument.text":["odt"],"application/vnd.oasis.opendocument.text-master":["odm"],"application/vnd.oasis.opendocument.text-template":["ott"],"application/vnd.oasis.opendocument.text-web":["oth"],"application/vnd.olpc-sugar":["xo"],"application/vnd.oma.dd2+xml":["dd2"],"application/vnd.openofficeorg.extension":["oxt"],"application/vnd.openxmlformats-officedocument.presentationml.presentation":["pptx"],"application/vnd.openxmlformats-officedocument.presentationml.slide":["sldx"],"application/vnd.openxmlformats-officedocument.presentationml.slideshow":["ppsx"],"application/vnd.openxmlformats-officedocument.presentationml.template":["potx"],"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":["xlsx"],"application/vnd.openxmlformats-officedocument.spreadsheetml.template":["xltx"],"application/vnd.openxmlformats-officedocument.wordprocessingml.document":["docx"],"application/vnd.openxmlformats-officedocument.wordprocessingml.template":["dotx"],"application/vnd.osgeo.mapguide.package":["mgp"],"application/vnd.osgi.dp":["dp"],"application/vnd.osgi.subsystem":["esa"],"application/vnd.palm":["pdb","pqa","oprc"],"application/vnd.pawaafile":["paw"],"application/vnd.pg.format":["str"],"application/vnd.pg.osasli":["ei6"],"application/vnd.picsel":["efif"],"application/vnd.pmi.widget":["wg"],"application/vnd.pocketlearn":["plf"],"application/vnd.powerbuilder6":["pbd"],"application/vnd.previewsystems.box":["box"],"application/vnd.proteus.magazine":["mgz"],"application/vnd.publishare-delta-tree":["qps"],"application/vnd.pvi.ptid1":["ptid"],"application/vnd.quark.quarkxpress":["qxd","qxt","qwd","qwt","qxl","qxb"],"application/vnd.realvnc.bed":["bed"],"application/vnd.recordare.musicxml":["mxl"],"application/vnd.recordare.musicxml+xml":["musicxml"],"application/vnd.rig.cryptonote":["cryptonote"],"application/vnd.rim.cod":["cod"],"application/vnd.rn-realmedia":["rm"],"application/vnd.rn-realmedia-vbr":["rmvb"],"application/vnd.route66.link66+xml":["link66"],"application/vnd.sailingtracker.track":["st"],"application/vnd.seemail":["see"],"application/vnd.sema":["sema"],"application/vnd.semd":["semd"],"application/vnd.semf":["semf"],"application/vnd.shana.informed.formdata":["ifm"],"application/vnd.shana.informed.formtemplate":["itp"],"application/vnd.shana.informed.interchange":["iif"],"application/vnd.shana.informed.package":["ipk"],"application/vnd.simtech-mindmapper":["twd","twds"],"application/vnd.smaf":["mmf"],"application/vnd.smart.teacher":["teacher"],"application/vnd.solent.sdkm+xml":["sdkm","sdkd"],"application/vnd.spotfire.dxp":["dxp"],"application/vnd.spotfire.sfs":["sfs"],"application/vnd.stardivision.calc":["sdc"],"application/vnd.stardivision.draw":["sda"],"application/vnd.stardivision.impress":["sdd"],"application/vnd.stardivision.math":["smf"],"application/vnd.stardivision.writer":["sdw","vor"],"application/vnd.stardivision.writer-global":["sgl"],"application/vnd.stepmania.package":["smzip"],"application/vnd.stepmania.stepchart":["sm"],"application/vnd.sun.wadl+xml":["wadl"],"application/vnd.sun.xml.calc":["sxc"],"application/vnd.sun.xml.calc.template":["stc"],"application/vnd.sun.xml.draw":["sxd"],"application/vnd.sun.xml.draw.template":["std"],"application/vnd.sun.xml.impress":["sxi"],"application/vnd.sun.xml.impress.template":["sti"],"application/vnd.sun.xml.math":["sxm"],"application/vnd.sun.xml.writer":["sxw"],"application/vnd.sun.xml.writer.global":["sxg"],"application/vnd.sun.xml.writer.template":["stw"],"application/vnd.sus-calendar":["sus","susp"],"application/vnd.svd":["svd"],"application/vnd.symbian.install":["sis","sisx"],"application/vnd.syncml+xml":["xsm"],"application/vnd.syncml.dm+wbxml":["bdm"],"application/vnd.syncml.dm+xml":["xdm"],"application/vnd.tao.intent-module-archive":["tao"],"application/vnd.tcpdump.pcap":["pcap","cap","dmp"],"application/vnd.tmobile-livetv":["tmo"],"application/vnd.trid.tpt":["tpt"],"application/vnd.triscape.mxs":["mxs"],"application/vnd.trueapp":["tra"],"application/vnd.ufdl":["ufd","ufdl"],"application/vnd.uiq.theme":["utz"],"application/vnd.umajin":["umj"],"application/vnd.unity":["unityweb"],"application/vnd.uoml+xml":["uoml"],"application/vnd.vcx":["vcx"],"application/vnd.visio":["vsd","vst","vss","vsw"],"application/vnd.visionary":["vis"],"application/vnd.vsf":["vsf"],"application/vnd.wap.wbxml":["wbxml"],"application/vnd.wap.wmlc":["wmlc"],"application/vnd.wap.wmlscriptc":["wmlsc"],"application/vnd.webturbo":["wtb"],"application/vnd.wolfram.player":["nbp"],"application/vnd.wordperfect":["wpd"],"application/vnd.wqd":["wqd"],"application/vnd.wt.stf":["stf"],"application/vnd.xara":["xar"],"application/vnd.xfdl":["xfdl"],"application/vnd.yamaha.hv-dic":["hvd"],"application/vnd.yamaha.hv-script":["hvs"],"application/vnd.yamaha.hv-voice":["hvp"],"application/vnd.yamaha.openscoreformat":["osf"],"application/vnd.yamaha.openscoreformat.osfpvg+xml":["osfpvg"],"application/vnd.yamaha.smaf-audio":["saf"],"application/vnd.yamaha.smaf-phrase":["spf"],"application/vnd.yellowriver-custom-menu":["cmp"],"application/vnd.zul":["zir","zirz"],"application/vnd.zzazz.deck+xml":["zaz"],"application/x-7z-compressed":["7z"],"application/x-abiword":["abw"],"application/x-ace-compressed":["ace"],"application/x-apple-diskimage":[],"application/x-arj":["arj"],"application/x-authorware-bin":["aab","x32","u32","vox"],"application/x-authorware-map":["aam"],"application/x-authorware-seg":["aas"],"application/x-bcpio":["bcpio"],"application/x-bdoc":[],"application/x-bittorrent":["torrent"],"application/x-blorb":["blb","blorb"],"application/x-bzip":["bz"],"application/x-bzip2":["bz2","boz"],"application/x-cbr":["cbr","cba","cbt","cbz","cb7"],"application/x-cdlink":["vcd"],"application/x-cfs-compressed":["cfs"],"application/x-chat":["chat"],"application/x-chess-pgn":["pgn"],"application/x-chrome-extension":["crx"],"application/x-cocoa":["cco"],"application/x-conference":["nsc"],"application/x-cpio":["cpio"],"application/x-csh":["csh"],"application/x-debian-package":["udeb"],"application/x-dgc-compressed":["dgc"],"application/x-director":["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"],"application/x-doom":["wad"],"application/x-dtbncx+xml":["ncx"],"application/x-dtbook+xml":["dtb"],"application/x-dtbresource+xml":["res"],"application/x-dvi":["dvi"],"application/x-envoy":["evy"],"application/x-eva":["eva"],"application/x-font-bdf":["bdf"],"application/x-font-ghostscript":["gsf"],"application/x-font-linux-psf":["psf"],"application/x-font-otf":[],"application/x-font-pcf":["pcf"],"application/x-font-snf":["snf"],"application/x-font-ttf":["ttf","ttc"],"application/x-font-type1":["pfa","pfb","pfm","afm"],"application/x-freearc":["arc"],"application/x-futuresplash":["spl"],"application/x-gca-compressed":["gca"],"application/x-glulx":["ulx"],"application/x-gnumeric":["gnumeric"],"application/x-gramps-xml":["gramps"],"application/x-gtar":["gtar"],"application/x-hdf":["hdf"],"application/x-httpd-php":["php"],"application/x-install-instructions":["install"],"application/x-iso9660-image":[],"application/x-java-archive-diff":["jardiff"],"application/x-java-jnlp-file":["jnlp"],"application/x-latex":["latex"],"application/x-lua-bytecode":["luac"],"application/x-lzh-compressed":["lzh","lha"],"application/x-makeself":["run"],"application/x-mie":["mie"],"application/x-mobipocket-ebook":["prc","mobi"],"application/x-ms-application":["application"],"application/x-ms-shortcut":["lnk"],"application/x-ms-wmd":["wmd"],"application/x-ms-wmz":["wmz"],"application/x-ms-xbap":["xbap"],"application/x-msaccess":["mdb"],"application/x-msbinder":["obd"],"application/x-mscardfile":["crd"],"application/x-msclip":["clp"],"application/x-msdos-program":[],"application/x-msdownload":["com","bat"],"application/x-msmediaview":["mvb","m13","m14"],"application/x-msmetafile":["wmf","emf","emz"],"application/x-msmoney":["mny"],"application/x-mspublisher":["pub"],"application/x-msschedule":["scd"],"application/x-msterminal":["trm"],"application/x-mswrite":["wri"],"application/x-netcdf":["nc","cdf"],"application/x-ns-proxy-autoconfig":["pac"],"application/x-nzb":["nzb"],"application/x-perl":["pl","pm"],"application/x-pilot":[],"application/x-pkcs12":["p12","pfx"],"application/x-pkcs7-certificates":["p7b","spc"],"application/x-pkcs7-certreqresp":["p7r"],"application/x-rar-compressed":["rar"],"application/x-redhat-package-manager":["rpm"],"application/x-research-info-systems":["ris"],"application/x-sea":["sea"],"application/x-sh":["sh"],"application/x-shar":["shar"],"application/x-shockwave-flash":["swf"],"application/x-silverlight-app":["xap"],"application/x-sql":["sql"],"application/x-stuffit":["sit"],"application/x-stuffitx":["sitx"],"application/x-subrip":["srt"],"application/x-sv4cpio":["sv4cpio"],"application/x-sv4crc":["sv4crc"],"application/x-t3vm-image":["t3"],"application/x-tads":["gam"],"application/x-tar":["tar"],"application/x-tcl":["tcl","tk"],"application/x-tex":["tex"],"application/x-tex-tfm":["tfm"],"application/x-texinfo":["texinfo","texi"],"application/x-tgif":["obj"],"application/x-ustar":["ustar"],"application/x-virtualbox-hdd":["hdd"],"application/x-virtualbox-ova":["ova"],"application/x-virtualbox-ovf":["ovf"],"application/x-virtualbox-vbox":["vbox"],"application/x-virtualbox-vbox-extpack":["vbox-extpack"],"application/x-virtualbox-vdi":["vdi"],"application/x-virtualbox-vhd":["vhd"],"application/x-virtualbox-vmdk":["vmdk"],"application/x-wais-source":["src"],"application/x-web-app-manifest+json":["webapp"],"application/x-x509-ca-cert":["der","crt","pem"],"application/x-xfig":["fig"],"application/x-xliff+xml":["xlf"],"application/x-xpinstall":["xpi"],"application/x-xz":["xz"],"application/x-zmachine":["z1","z2","z3","z4","z5","z6","z7","z8"],"audio/vnd.dece.audio":["uva","uvva"],"audio/vnd.digital-winds":["eol"],"audio/vnd.dra":["dra"],"audio/vnd.dts":["dts"],"audio/vnd.dts.hd":["dtshd"],"audio/vnd.lucent.voice":["lvp"],"audio/vnd.ms-playready.media.pya":["pya"],"audio/vnd.nuera.ecelp4800":["ecelp4800"],"audio/vnd.nuera.ecelp7470":["ecelp7470"],"audio/vnd.nuera.ecelp9600":["ecelp9600"],"audio/vnd.rip":["rip"],"audio/x-aac":["aac"],"audio/x-aiff":["aif","aiff","aifc"],"audio/x-caf":["caf"],"audio/x-flac":["flac"],"audio/x-m4a":[],"audio/x-matroska":["mka"],"audio/x-mpegurl":["m3u"],"audio/x-ms-wax":["wax"],"audio/x-ms-wma":["wma"],"audio/x-pn-realaudio":["ram","ra"],"audio/x-pn-realaudio-plugin":["rmp"],"audio/x-realaudio":[],"audio/x-wav":[],"chemical/x-cdx":["cdx"],"chemical/x-cif":["cif"],"chemical/x-cmdf":["cmdf"],"chemical/x-cml":["cml"],"chemical/x-csml":["csml"],"chemical/x-xyz":["xyz"],"image/prs.btif":["btif"],"image/vnd.adobe.photoshop":["psd"],"image/vnd.dece.graphic":["uvi","uvvi","uvg","uvvg"],"image/vnd.djvu":["djvu","djv"],"image/vnd.dvb.subtitle":[],"image/vnd.dwg":["dwg"],"image/vnd.dxf":["dxf"],"image/vnd.fastbidsheet":["fbs"],"image/vnd.fpx":["fpx"],"image/vnd.fst":["fst"],"image/vnd.fujixerox.edmics-mmr":["mmr"],"image/vnd.fujixerox.edmics-rlc":["rlc"],"image/vnd.ms-modi":["mdi"],"image/vnd.ms-photo":["wdp"],"image/vnd.net-fpx":["npx"],"image/vnd.wap.wbmp":["wbmp"],"image/vnd.xiff":["xif"],"image/x-3ds":["3ds"],"image/x-cmu-raster":["ras"],"image/x-cmx":["cmx"],"image/x-freehand":["fh","fhc","fh4","fh5","fh7"],"image/x-icon":["ico"],"image/x-jng":["jng"],"image/x-mrsid-image":["sid"],"image/x-ms-bmp":[],"image/x-pcx":["pcx"],"image/x-pict":["pic","pct"],"image/x-portable-anymap":["pnm"],"image/x-portable-bitmap":["pbm"],"image/x-portable-graymap":["pgm"],"image/x-portable-pixmap":["ppm"],"image/x-rgb":["rgb"],"image/x-tga":["tga"],"image/x-xbitmap":["xbm"],"image/x-xpixmap":["xpm"],"image/x-xwindowdump":["xwd"],"model/vnd.collada+xml":["dae"],"model/vnd.dwf":["dwf"],"model/vnd.gdl":["gdl"],"model/vnd.gtw":["gtw"],"model/vnd.mts":["mts"],"model/vnd.vtu":["vtu"],"text/prs.lines.tag":["dsc"],"text/vnd.curl":["curl"],"text/vnd.curl.dcurl":["dcurl"],"text/vnd.curl.mcurl":["mcurl"],"text/vnd.curl.scurl":["scurl"],"text/vnd.dvb.subtitle":["sub"],"text/vnd.fly":["fly"],"text/vnd.fmi.flexstor":["flx"],"text/vnd.graphviz":["gv"],"text/vnd.in3d.3dml":["3dml"],"text/vnd.in3d.spot":["spot"],"text/vnd.sun.j2me.app-descriptor":["jad"],"text/vnd.wap.wml":["wml"],"text/vnd.wap.wmlscript":["wmls"],"text/x-asm":["s","asm"],"text/x-c":["c","cc","cxx","cpp","h","hh","dic"],"text/x-component":["htc"],"text/x-fortran":["f","for","f77","f90"],"text/x-handlebars-template":["hbs"],"text/x-java-source":["java"],"text/x-lua":["lua"],"text/x-markdown":["mkd"],"text/x-nfo":["nfo"],"text/x-opml":["opml"],"text/x-org":[],"text/x-pascal":["p","pas"],"text/x-processing":["pde"],"text/x-sass":["sass"],"text/x-scss":["scss"],"text/x-setext":["etx"],"text/x-sfv":["sfv"],"text/x-suse-ymp":["ymp"],"text/x-uuencode":["uu"],"text/x-vcalendar":["vcs"],"text/x-vcard":["vcf"],"video/vnd.dece.hd":["uvh","uvvh"],"video/vnd.dece.mobile":["uvm","uvvm"],"video/vnd.dece.pd":["uvp","uvvp"],"video/vnd.dece.sd":["uvs","uvvs"],"video/vnd.dece.video":["uvv","uvvv"],"video/vnd.dvb.file":["dvb"],"video/vnd.fvt":["fvt"],"video/vnd.mpegurl":["mxu","m4u"],"video/vnd.ms-playready.media.pyv":["pyv"],"video/vnd.uvvu.mp4":["uvu","uvvu"],"video/vnd.vivo":["viv"],"video/x-f4v":["f4v"],"video/x-fli":["fli"],"video/x-flv":["flv"],"video/x-m4v":["m4v"],"video/x-matroska":["mkv","mk3d","mks"],"video/x-mng":["mng"],"video/x-ms-asf":["asf","asx"],"video/x-ms-vob":["vob"],"video/x-ms-wm":["wm"],"video/x-ms-wmv":["wmv"],"video/x-ms-wmx":["wmx"],"video/x-ms-wvx":["wvx"],"video/x-msvideo":["avi"],"video/x-sgi-movie":["movie"],"video/x-smv":["smv"],"x-conference/x-cooltalk":["ice"]}},{}],4:[function(ae,oe,ve){oe.exports={"application/andrew-inset":["ez"],"application/applixware":["aw"],"application/atom+xml":["atom"],"application/atomcat+xml":["atomcat"],"application/atomsvc+xml":["atomsvc"],"application/bdoc":["bdoc"],"application/ccxml+xml":["ccxml"],"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"],"application/emma+xml":["emma"],"application/epub+zip":["epub"],"application/exi":["exi"],"application/font-tdpfr":["pfr"],"application/font-woff":["woff"],"application/font-woff2":["woff2"],"application/geo+json":["geojson"],"application/gml+xml":["gml"],"application/gpx+xml":["gpx"],"application/gxf":["gxf"],"application/gzip":["gz"],"application/hyperstudio":["stk"],"application/inkml+xml":["ink","inkml"],"application/ipfix":["ipfix"],"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/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/mods+xml":["mods"],"application/mp21":["m21","mp21"],"application/mp4":["mp4s","m4p"],"application/msword":["doc","dot"],"application/mxf":["mxf"],"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/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/pskc+xml":["pskcxml"],"application/rdf+xml":["rdf"],"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/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/set-payment-initiation":["setpay"],"application/set-registration-initiation":["setreg"],"application/shf+xml":["shf"],"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/tei+xml":["tei","teicorpus"],"application/thraud+xml":["tfi"],"application/timestamped-data":["tsd"],"application/voicexml+xml":["vxml"],"application/widget":["wgt"],"application/winhlp":["hlp"],"application/wsdl+xml":["wsdl"],"application/wspolicy+xml":["wspolicy"],"application/xaml+xml":["xaml"],"application/xcap-diff+xml":["xdf"],"application/xenc+xml":["xenc"],"application/xhtml+xml":["xhtml","xht"],"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":[],"audio/adpcm":["adp"],"audio/basic":["au","snd"],"audio/midi":["mid","midi","kar","rmi"],"audio/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":[],"audio/webm":["weba"],"audio/xm":["xm"],"font/otf":["otf"],"image/apng":["apng"],"image/bmp":["bmp"],"image/cgm":["cgm"],"image/g3fax":["g3"],"image/gif":["gif"],"image/ief":["ief"],"image/jpeg":["jpeg","jpg","jpe"],"image/ktx":["ktx"],"image/png":["png"],"image/sgi":["sgi"],"image/svg+xml":["svg","svgz"],"image/tiff":["tiff","tif"],"image/webp":["webp"],"message/rfc822":["eml","mime"],"model/gltf+json":["gltf"],"model/gltf-binary":["glb"],"model/iges":["igs","iges"],"model/mesh":["msh","mesh","silo"],"model/vrml":["wrl","vrml"],"model/x3d+binary":["x3db","x3dbz"],"model/x3d+vrml":["x3dv","x3dvz"],"model/x3d+xml":["x3d","x3dz"],"text/cache-manifest":["appcache","manifest"],"text/calendar":["ics","ifb"],"text/coffeescript":["coffee","litcoffee"],"text/css":["css"],"text/csv":["csv"],"text/hjson":["hjson"],"text/html":["html","htm","shtml"],"text/jade":["jade"],"text/jsx":["jsx"],"text/less":["less"],"text/markdown":["markdown","md"],"text/mathml":["mml"],"text/n3":["n3"],"text/plain":["txt","text","conf","def","list","log","in","ini"],"text/richtext":["rtx"],"text/rtf":[],"text/sgml":["sgml","sgm"],"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":[],"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"]}},{}]},{},[2])(2)})}).call(this,typeof be.g!="undefined"?be.g:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"babel-runtime/core-js/object/create":19,"babel-runtime/helpers/classCallCheck":30,"babel-runtime/helpers/createClass":31,"babel-runtime/helpers/typeof":32}],243:[function(ie,Ce,ue){"use strict";ue.encodeURIComponent=function(se){try{return encodeURIComponent(se)}catch(te){return se}},ue.escape=ie("escape-html"),ue.timestamp=function(se){if(se){var te=se;return typeof te=="string"&&(te=Number(te)),String(se).length===10&&(te*=1e3),new Date(te)}return Math.round(Date.now()/1e3)}},{"escape-html":157}],244:[function(ie,Ce,ue){(function(se,te){"use strict";function le(Te){return Te&&Te.__esModule?Te:{default:Te}}function ee(Te,Ee){return Te===void 0?Ee:Te}function ne(Te,Ee){return function(Oe,je,Pe){if(Oe)return Ee(Oe);Te({data:je,status:Pe.statusCode,headers:Pe.headers,res:Pe})}}var E,b=ie("babel-runtime/core-js/json/stringify"),z=le(b),x=ie("babel-runtime/helpers/typeof"),re=le(x),ae=ie("util"),oe=ie("url"),ve=ie("http"),ye=ie("https"),me=ie("debug")("urllib"),ge=ie("humanize-ms"),_e=0,he=Math.pow(2,31)-10,pe=/^https?:\/\//i;ue.TIMEOUTS=[ge("300s"),ge("300s")];var ke=["json","text"];ue.request=function(Te,Ee,Oe){return arguments.length===2&&typeof Ee=="function"&&(Oe=Ee,Ee=null),typeof Oe=="function"?ue.requestWithCallback(Te,Ee,Oe):(E||(E=ie("any-promise")),new E(function(je,Pe){ue.requestWithCallback(Te,Ee,ne(je,Pe))}))},ue.requestWithCallback=function(Te,Ee,Oe){function je(){Ne&&(clearTimeout(Ne),Ne=null)}function Pe(){De&&(clearTimeout(De),De=null)}function Qe(yt,Yt,Lt){if(Pe(),!Oe)return console.warn("[urllib:warn] [%s] [%s] [worker:%s] %s %s callback twice!!!",Date(),Ge,se.pid,dt.method,Te),void(yt&&console.warn(`[urllib:warn] [%s] [%s] [worker:%s] %s: %s
|
|
|
stack: %s`,Date(),Ge,se.pid,yt.name,yt.message,yt.stack));var Kt=Oe;Oe=null;var sn={};if(Lt&&(Re=Lt.statusCode,sn=Lt.headers),Re===401&&sn["www-authenticate"]&&(!Ee.headers||!Ee.headers.Authorization)&&Ee.digestAuth){var wn=sn["www-authenticate"];if(wn.indexOf("Digest ")>=0)return me("Request#%d %s: got digest auth header WWW-Authenticate: %s",Ge,Te,wn),Ee.headers=Ee.headers||{},Ee.headers.Authorization=digestAuthHeader(dt.method,dt.path,wn,Ee.digestAuth),me("Request#%d %s: auth with digest header: %s",Ge,Te,Ee.headers.Authorization),Lt.headers["set-cookie"]&&(Ee.headers.Cookie=Lt.headers["set-cookie"].join(";")),ue.requestWithCallback(Te,Ee,Kt)}var Vt=Date.now()-$e;Ct&&(Ct.contentDownload=Vt),me("[%sms] done, %s bytes HTTP %s %s %s %s, keepAliveSocket: %s, timing: %j",Vt,Me,Re,dt.method,dt.host,dt.path,Ue,Ct);var Rn={status:Re,statusCode:Re,headers:sn,size:Me,aborted:tt,rt:Vt,keepAliveSocket:Ue,data:Yt,requestUrls:Ee.requestUrls,timing:Ct,remoteAddress:lt,remotePort:Nt};if(yt){var Gn="";ct&&typeof ct.getCurrentStatus=="function"&&(Gn=", agent status: "+(0,z.default)(ct.getCurrentStatus())),yt.message+=", "+dt.method+" "+Te+" "+Re+" (connected: "+Le+", keepalive socket: "+Ue+Gn+`)
|
|
|
headers: `+(0,z.default)(sn),yt.data=Yt,yt.path=dt.path,yt.status=Re,yt.headers=sn,yt.res=Rn}Kt(yt,Yt,Ee.streaming?Lt:Rn),Ee.emitter&&(ze.url=Te,ze.socket=jt&&jt.connection,ze.options=dt,ze.size=Be,Ee.emitter.emit("response",{requestId:Ge,error:yt,ctx:Ee.ctx,req:ze,res:Rn}))}function Xe(yt){var Yt=null;if(Ee.followRedirect&&statuses.redirect[yt.statusCode]){Ee._followRedirectCount=(Ee._followRedirectCount||0)+1;var Lt=yt.headers.location;if(Lt){if(!(Ee._followRedirectCount>Ee.maxRedirects)){var Kt=Ee.formatRedirectUrl?Ee.formatRedirectUrl(Te,Lt):oe.resolve(Te,Lt);me("Request#%d %s: `redirected` from %s to %s",Ge,dt.path,Te,Kt),Pe(),Ee.headers&&Ee.headers.Host&&pe.test(Lt)&&(Ee.headers.Host=null);var sn=Oe;return Oe=null,ue.requestWithCallback(Kt,Ee,sn),{redirect:!0,error:null}}Yt=new Error("Exceeded maxRedirects. Probably stuck in a redirect loop "+Te),Yt.name="MaxRedirectError"}else Yt=new Error("Got statusCode "+yt.statusCode+" but cannot resolve next location from headers"),Yt.name="FollowRedirectError"}return{redirect:!1,error:Yt}}function ot(yt,Yt,Lt){return Lt(null,Yt,yt.headers["content-encoding"])}function He(yt){if(Ct&&(Ct.waiting=Date.now()-$e),me("Request#%d %s `req response` event emit: status %d, headers: %j",Ge,Te,yt.statusCode,yt.headers),Ee.streaming){var Yt=Xe(yt);return Yt.redirect?void yt.resume():Yt.error?(yt.resume(),Qe(Yt.error,null,yt)):Qe(null,null,yt)}if(yt.on("close",function(){me("Request#%d %s: `res close` event emit, total size %d",Ge,Te,Me)}),yt.on("error",function(){me("Request#%d %s: `res error` event emit, total size %d",Ge,Te,Me)}),yt.on("aborted",function(){tt=!0,me("Request#%d %s: `res aborted` event emit, total size %d",Ge,Te,Me)}),vt){var Yt=Xe(yt);return Yt.redirect?void yt.resume():Yt.error?(yt.resume(),vt.end(),Qe(Yt.error,null,yt)):(Ee.consumeWriteStream===!1?yt.on("end",Qe.bind(null,null,null,yt)):isNode010||isNode012?first([[vt,"close"],[yt,"aborted"]],function(sn,wn,Vt){me("Request#%d %s: writeStream or res %s event emitted",Ge,Te,Vt),Qe(we||null,null,yt)}):vt.on("close",function(){me("Request#%d %s: writeStream close event emitted",Ge,Te),Qe(we||null,null,yt)}),yt.pipe(vt))}var Lt=[];yt.on("data",function(Kt){me("Request#%d %s: `res data` event emit, size %d",Ge,Te,Kt.length),Me+=Kt.length,Lt.push(Kt)}),yt.on("end",function(){var Kt=te.concat(Lt,Me);if(me("Request#%d %s: `res end` event emit, total size %d, _dumped: %s",Ge,Te,Me,yt._dumped),we)return Qe(we,Kt,yt);var sn=Xe(yt);if(sn.error)return Qe(sn.error,Kt,yt);sn.redirect||ot(yt,Kt,function(wn,Vt,Rn){if(wn)return Qe(wn,Kt,yt);if(!Rn&&ke.indexOf(Ee.dataType)>=0){try{Vt=decodeBodyByCharset(Vt,yt)}catch(Zn){return me("decodeBodyByCharset error: %s",Zn),Qe(null,Vt,yt)}if(Ee.dataType==="json")if(Me===0)Vt=null;else{var Gn=parseJSON(Vt,Ot);Gn.error?wn=Gn.error:Vt=Gn.data}}tt&&me("Request#%d %s: Remote socket was terminated before `response.end()` was called",Ge,Te),Qe(wn,Vt,yt)})})}function rt(){me("Response timer ticking, timeout: %d",Ht),De=setTimeout(function(){De=null;var yt="Response timeout for "+Ht+"ms";we=new Error(yt),we.name="ResponseTimeoutError",we.requestId=Ge,me("ResponseTimeout: Request#%d %s %s: %s, connected: %s",Ge,Te,we.name,yt,Le),Ye()},Ht)}function Ye(){me("Request#%d %s abort, connected: %s",Ge,Te,Le),jt.socket||(we.noSocket=!0,Qe(we)),jt.abort()}if(!Te||typeof Te!="string"&&(Te===void 0?"undefined":(0,re.default)(Te))!=="object"){var ut=ae.format("expect request url to be a string or a http request options, but got %j",Te);throw new Error(ut)}arguments.length===2&&typeof Ee=="function"&&(Oe=Ee,Ee=null),Ee=Ee||{},_e>=he&&(_e=0);var Ge=++_e;Ee.requestUrls=Ee.requestUrls||[];var ze={requestId:Ge,url:Te,args:Ee,ctx:Ee.ctx};Ee.emitter&&Ee.emitter.emit("request",ze),Ee.timeout=Ee.timeout||ue.TIMEOUTS,Ee.maxRedirects=Ee.maxRedirects||10,Ee.streaming=Ee.streaming||Ee.customResponse;var Ve,$e=Date.now();typeof Te=="string"?(pe.test(Te)||(Te="http://"+Te),Ve=oe.parse(Te)):Ve=Te;var nt=(Ee.type||Ee.method||Ve.method||"GET").toUpperCase(),et=Ve.port||80,pt=ve,ct=ee(Ee.agent,ue.agent),Ot=Ee.fixJSONCtlChars;Ve.protocol==="https:"&&(pt=ye,ct=ee(Ee.httpsAgent,ue.httpsAgent),Ve.port||(et=443));var dt={host:Ve.hostname||Ve.host||"localhost",path:Ve.path||"/",method:nt,port:et,agent:ct,headers:Ee.headers||{},lookup:Ee.lookup};Array.isArray(Ee.timeout)?dt.requestTimeout=Ee.timeout[Ee.timeout.length-1]:Ee.timeout!==void 0&&(dt.requestTimeout=Ee.timeout);for(var Rt=["pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","secureProtocol","secureOptions"],xt=0;xt<Rt.length;xt++){var gt=Rt[xt];Ee.hasOwnProperty(gt)&&(dt[gt]=Ee[gt])}dt.rejectUnauthorized!==!1||dt.hasOwnProperty("secureOptions")||(dt.secureOptions=ie("constants").SSL_OP_NO_TLSv1_2);var _t=Ee.auth||Ve.auth;_t&&(dt.auth=_t);var We=Ee.content||Ee.data,Ae=nt==="GET"||nt==="HEAD"||Ee.dataAsQueryString;if(!Ee.content&&We&&typeof We!="string"&&!te.isBuffer(We))if(Ae)We=Ee.nestedQuerystring?qs.stringify(We):querystring.stringify(We);else{var Se=dt.headers["Content-Type"]||dt.headers["content-type"];Se||(Se=Ee.contentType==="json"?"application/json":"application/x-www-form-urlencoded",dt.headers["Content-Type"]=Se),We=parseContentType(Se).type==="application/json"?(0,z.default)(We):Ee.nestedQuerystring?qs.stringify(We):querystring.stringify(We)}Ae&&We&&(dt.path+=(Ve.query?"&":"?")+We,We=null);var Be=0;if(We){var Ke=We.length;te.isBuffer(We)||(Ke=te.byteLength(We)),Be=dt.headers["Content-Length"]=Ke}Ee.dataType==="json"&&(dt.headers.Accept="application/json"),typeof Ee.beforeRequest=="function"&&Ee.beforeRequest(dt);var Ne=null,De=null,we=null,Le=!1,Ue=!1,Me=0,Re=-1,tt=!1,lt="",Nt="",Ct=null;Ee.timing&&(Ct={queuing:0,dnslookup:0,connected:0,requestSent:0,waiting:0,contentDownload:0}),dt.headers["User-Agent"]||dt.headers["user-agent"]||(dt.headers["User-Agent"]=navigator.userAgent),Ee.gzip&&(dt.headers["Accept-Encoding"]||dt.headers["accept-encoding"]||(dt.headers["Accept-Encoding"]="gzip"));var vt=Ee.writeStream;me("Request#%d %s %s with headers %j, options.path: %s",Ge,nt,Te,dt.headers,dt.path),Ee.requestUrls.push(Te);var Pt,Ht;Array.isArray(Ee.timeout)?(Pt=ge(Ee.timeout[0]),Ht=ge(Ee.timeout[1])):Pt=Ht=ge(Ee.timeout),me("ConnectTimeout: %d, ResponseTimeout: %d",Pt,Ht);var jt;try{jt=pt.request(dt,He)}catch(yt){return Qe(yt)}return typeof window=="undefined"?function(){me("Connect timer ticking, timeout: %d",Pt),Ne=setTimeout(function(){Ne=null,Re===-1&&(Re=-2);var yt="Connect timeout for "+Pt+"ms",Yt="ConnectionTimeoutError";jt.socket||(Yt="SocketAssignTimeoutError",yt+=", working sockets is full"),we=new Error(yt),we.name=Yt,we.requestId=Ge,me("ConnectTimeout: Request#%d %s %s: %s, connected: %s",Ge,Te,we.name,yt,Le),Ye()},Pt)}():jt.on("requestTimeout",function(){Re===-1&&(Re=-2);var yt="Connect timeout for "+Pt+"ms";we=new Error(yt),we.name="ConnectionTimeoutError",we.requestId=Ge,Ye()}),Ct&&jt.on("finish",function(){Ct.requestSent=Date.now()-$e}),jt.once("socket",function(yt){Ct&&(Ct.queuing=Date.now()-$e),isNode010&&yt.socket&&(yt=yt.socket);var Yt=yt.readyState;if(Yt==="opening")return yt.once("lookup",function(Lt,Kt,sn){me("Request#%d %s lookup: %s, %s, %s",Ge,Te,Lt,Kt,sn),Ct&&(Ct.dnslookup=Date.now()-$e),Kt&&(lt=Kt)}),void yt.once("connect",function(){Ct&&(Ct.connected=Date.now()-$e),je(),rt(),me("Request#%d %s new socket connected",Ge,Te),Le=!0,lt||(lt=yt.remoteAddress),Nt=yt.remotePort});me("Request#%d %s reuse socket connected, readyState: %s",Ge,Te,Yt),Le=!0,Ue=!0,lt||(lt=yt.remoteAddress),Nt=yt.remotePort,je(),rt()}),jt.on("error",function(yt){yt.name!=="Error"&&yt.name!=="TypeError"||(yt.name=Le?"ResponseError":"RequestError"),yt.message+=' (req "error")',me("Request#%d %s `req error` event emit, %s: %s",Ge,Te,yt.name,yt.message),Qe(we||yt)}),vt&&vt.once("error",function(yt){yt.message+=' (writeStream "error")',we=yt,me("Request#%d %s `writeStream error` event emit, %s: %s",Ge,Te,yt.name,yt.message),Ye()}),Ee.stream?(Ee.stream.pipe(jt),Ee.stream.once("error",function(yt){yt.message+=' (stream "error")',we=yt,me("Request#%d %s `readStream error` event emit, %s: %s",Ge,Te,yt.name,yt.message),Ye()})):jt.end(We),jt.requestId=Ge,jt}}).call(this,ie("_process"),ie("buffer").Buffer)},{_process:173,"any-promise":13,"babel-runtime/core-js/json/stringify":17,"babel-runtime/helpers/typeof":32,buffer:38,constants:42,debug:155,http:196,https:159,"humanize-ms":160,url:203,util:207}]},{},[1])(1)}),function(ce){function ie(ue){if(Ce[ue])return Ce[ue].exports;var se=Ce[ue]={i:ue,l:!1,exports:{}};return ce[ue].call(se.exports,se,se.exports,ie),se.l=!0,se.exports}var Ce={};ie.m=ce,ie.c=Ce,ie.d=function(ue,se,te){ie.o(ue,se)||Object.defineProperty(ue,se,{configurable:!1,enumerable:!0,get:te})},ie.n=function(ue){var se=ue&&ue.__esModule?function(){return ue.default}:function(){return ue};return ie.d(se,"a",se),se},ie.o=function(ue,se){return Object.prototype.hasOwnProperty.call(ue,se)},ie.p="",ie(ie.s=12)}([function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se()})(0,function(){var ue=ue||function(se,te){var le=Object.create||function(){function ye(){}return function(me){var ge;return ye.prototype=me,ge=new ye,ye.prototype=null,ge}}(),ee={},ne=ee.lib={},E=ne.Base=function(){return{extend:function(ye){var me=le(this);return ye&&me.mixIn(ye),me.hasOwnProperty("init")&&this.init!==me.init||(me.init=function(){me.$super.init.apply(this,arguments)}),me.init.prototype=me,me.$super=this,me},create:function(){var ye=this.extend();return ye.init.apply(ye,arguments),ye},init:function(){},mixIn:function(ye){for(var me in ye)ye.hasOwnProperty(me)&&(this[me]=ye[me]);ye.hasOwnProperty("toString")&&(this.toString=ye.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),b=ne.WordArray=E.extend({init:function(ye,me){ye=this.words=ye||[],this.sigBytes=me!=null?me:4*ye.length},toString:function(ye){return(ye||x).stringify(this)},concat:function(ye){var me=this.words,ge=ye.words,_e=this.sigBytes,he=ye.sigBytes;if(this.clamp(),_e%4)for(var pe=0;pe<he;pe++){var ke=ge[pe>>>2]>>>24-pe%4*8&255;me[_e+pe>>>2]|=ke<<24-(_e+pe)%4*8}else for(var pe=0;pe<he;pe+=4)me[_e+pe>>>2]=ge[pe>>>2];return this.sigBytes+=he,this},clamp:function(){var ye=this.words,me=this.sigBytes;ye[me>>>2]&=4294967295<<32-me%4*8,ye.length=se.ceil(me/4)},clone:function(){var ye=E.clone.call(this);return ye.words=this.words.slice(0),ye},random:function(ye){for(var me,ge=[],_e=0;_e<ye;_e+=4){var he=function(ke){var ke=ke,Te=987654321,Ee=4294967295;return function(){Te=36969*(65535&Te)+(Te>>16)&Ee,ke=18e3*(65535&ke)+(ke>>16)&Ee;var Oe=(Te<<16)+ke&Ee;return Oe/=4294967296,(Oe+=.5)*(se.random()>.5?1:-1)}}(4294967296*(me||se.random()));me=987654071*he(),ge.push(4294967296*he()|0)}return new b.init(ge,ye)}}),z=ee.enc={},x=z.Hex={stringify:function(ye){for(var me=ye.words,ge=ye.sigBytes,_e=[],he=0;he<ge;he++){var pe=me[he>>>2]>>>24-he%4*8&255;_e.push((pe>>>4).toString(16)),_e.push((15&pe).toString(16))}return _e.join("")},parse:function(ye){for(var me=ye.length,ge=[],_e=0;_e<me;_e+=2)ge[_e>>>3]|=parseInt(ye.substr(_e,2),16)<<24-_e%8*4;return new b.init(ge,me/2)}},re=z.Latin1={stringify:function(ye){for(var me=ye.words,ge=ye.sigBytes,_e=[],he=0;he<ge;he++){var pe=me[he>>>2]>>>24-he%4*8&255;_e.push(String.fromCharCode(pe))}return _e.join("")},parse:function(ye){for(var me=ye.length,ge=[],_e=0;_e<me;_e++)ge[_e>>>2]|=(255&ye.charCodeAt(_e))<<24-_e%4*8;return new b.init(ge,me)}},ae=z.Utf8={stringify:function(ye){try{return decodeURIComponent(escape(re.stringify(ye)))}catch(me){throw new Error("Malformed UTF-8 data")}},parse:function(ye){return re.parse(unescape(encodeURIComponent(ye)))}},oe=ne.BufferedBlockAlgorithm=E.extend({reset:function(){this._data=new b.init,this._nDataBytes=0},_append:function(ye){typeof ye=="string"&&(ye=ae.parse(ye)),this._data.concat(ye),this._nDataBytes+=ye.sigBytes},_process:function(ye){var me=this._data,ge=me.words,_e=me.sigBytes,he=this.blockSize,pe=4*he,ke=_e/pe;ke=ye?se.ceil(ke):se.max((0|ke)-this._minBufferSize,0);var Te=ke*he,Ee=se.min(4*Te,_e);if(Te){for(var Oe=0;Oe<Te;Oe+=he)this._doProcessBlock(ge,Oe);var je=ge.splice(0,Te);me.sigBytes-=Ee}return new b.init(je,Ee)},clone:function(){var ye=E.clone.call(this);return ye._data=this._data.clone(),ye},_minBufferSize:0}),ve=(ne.Hasher=oe.extend({cfg:E.extend(),init:function(ye){this.cfg=this.cfg.extend(ye),this.reset()},reset:function(){oe.reset.call(this),this._doReset()},update:function(ye){return this._append(ye),this._process(),this},finalize:function(ye){return ye&&this._append(ye),this._doFinalize()},blockSize:16,_createHelper:function(ye){return function(me,ge){return new ye.init(ge).finalize(me)}},_createHmacHelper:function(ye){return function(me,ge){return new ve.HMAC.init(ye,ge).finalize(me)}}}),ee.algo={});return ee}(Math);return ue})},function(ce,ie,Ce){"use strict";function ue(le,ee){if(!(le instanceof ee))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}(),te=function(){function le(){ue(this,le)}return se(le,null,[{key:"detectIEVersion",value:function(){for(var ee=4,ne=document.createElement("div"),E=ne.getElementsByTagName("i");ne.innerHTML="<!--[if gt IE "+ee+"]><i></i><![endif]-->",E[0];)ee++;return ee>4&&ee}},{key:"extend",value:function(ee,ne){for(var E in ne)Object.prototype.hasOwnProperty.call(ne,E)&&ne[E]&&(ee[E]=ne[E])}},{key:"isArray",value:function(ee){return Object.prototype.toString.call(arg)==="[object Array]"}},{key:"getFileType",value:function(ee){return ee=ee.toLowerCase(),/.mp4|.flv|.m3u8|.avi|.rm|.rmvb|.mpeg|.mpg|.mov|.wmv|.3gp|.asf|.dat|.dv|.f4v|.gif|.m2t|.m4v|.mj2|.mjpeg|.mpe|.mts|.ogg|.qt|.swf|.ts|.vob|.wmv|.webm/.test(ee)?"video":/.mp3|.wav|.ape|.cda|.au|.midi|.mac|.aac|.ac3|.acm|.amr|.caf|.flac|.m4a|.ra|.wma/.test(ee)?"audio":/.bmp|.jpg|.jpeg|.png/.test(ee)?"img":"other"}},{key:"isImage",value:function(ee){return ee=ee.toLowerCase(),!!/.jpg|.jpeg|.png/.test(ee)}},{key:"ISODateString",value:function(ee){function ne(E){return E<10?"0"+E:E}return ee.getUTCFullYear()+"-"+ne(ee.getUTCMonth()+1)+"-"+ne(ee.getUTCDate())+"T"+ne(ee.getUTCHours())+":"+ne(ee.getUTCMinutes())+":"+ne(ee.getUTCSeconds())+"Z"}},{key:"isIntNum",value:function(ee){return!!/^\d+$/.test(ee)}}]),le}();ie.default=te},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){return function(se){function te(ve,ye,me,ge,_e,he,pe){var ke=ve+(ye&me|~ye&ge)+_e+pe;return(ke<<he|ke>>>32-he)+ye}function le(ve,ye,me,ge,_e,he,pe){var ke=ve+(ye&ge|me&~ge)+_e+pe;return(ke<<he|ke>>>32-he)+ye}function ee(ve,ye,me,ge,_e,he,pe){var ke=ve+(ye^me^ge)+_e+pe;return(ke<<he|ke>>>32-he)+ye}function ne(ve,ye,me,ge,_e,he,pe){var ke=ve+(me^(ye|~ge))+_e+pe;return(ke<<he|ke>>>32-he)+ye}var E=ue,b=E.lib,z=b.WordArray,x=b.Hasher,re=E.algo,ae=[];(function(){for(var ve=0;ve<64;ve++)ae[ve]=4294967296*se.abs(se.sin(ve+1))|0})();var oe=re.MD5=x.extend({_doReset:function(){this._hash=new z.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(ve,ye){for(var me=0;me<16;me++){var ge=ye+me,_e=ve[ge];ve[ge]=16711935&(_e<<8|_e>>>24)|4278255360&(_e<<24|_e>>>8)}var he=this._hash.words,pe=ve[ye+0],ke=ve[ye+1],Te=ve[ye+2],Ee=ve[ye+3],Oe=ve[ye+4],je=ve[ye+5],Pe=ve[ye+6],Qe=ve[ye+7],Xe=ve[ye+8],ot=ve[ye+9],He=ve[ye+10],rt=ve[ye+11],Ye=ve[ye+12],ut=ve[ye+13],Ge=ve[ye+14],ze=ve[ye+15],Ve=he[0],$e=he[1],nt=he[2],et=he[3];Ve=te(Ve,$e,nt,et,pe,7,ae[0]),et=te(et,Ve,$e,nt,ke,12,ae[1]),nt=te(nt,et,Ve,$e,Te,17,ae[2]),$e=te($e,nt,et,Ve,Ee,22,ae[3]),Ve=te(Ve,$e,nt,et,Oe,7,ae[4]),et=te(et,Ve,$e,nt,je,12,ae[5]),nt=te(nt,et,Ve,$e,Pe,17,ae[6]),$e=te($e,nt,et,Ve,Qe,22,ae[7]),Ve=te(Ve,$e,nt,et,Xe,7,ae[8]),et=te(et,Ve,$e,nt,ot,12,ae[9]),nt=te(nt,et,Ve,$e,He,17,ae[10]),$e=te($e,nt,et,Ve,rt,22,ae[11]),Ve=te(Ve,$e,nt,et,Ye,7,ae[12]),et=te(et,Ve,$e,nt,ut,12,ae[13]),nt=te(nt,et,Ve,$e,Ge,17,ae[14]),$e=te($e,nt,et,Ve,ze,22,ae[15]),Ve=le(Ve,$e,nt,et,ke,5,ae[16]),et=le(et,Ve,$e,nt,Pe,9,ae[17]),nt=le(nt,et,Ve,$e,rt,14,ae[18]),$e=le($e,nt,et,Ve,pe,20,ae[19]),Ve=le(Ve,$e,nt,et,je,5,ae[20]),et=le(et,Ve,$e,nt,He,9,ae[21]),nt=le(nt,et,Ve,$e,ze,14,ae[22]),$e=le($e,nt,et,Ve,Oe,20,ae[23]),Ve=le(Ve,$e,nt,et,ot,5,ae[24]),et=le(et,Ve,$e,nt,Ge,9,ae[25]),nt=le(nt,et,Ve,$e,Ee,14,ae[26]),$e=le($e,nt,et,Ve,Xe,20,ae[27]),Ve=le(Ve,$e,nt,et,ut,5,ae[28]),et=le(et,Ve,$e,nt,Te,9,ae[29]),nt=le(nt,et,Ve,$e,Qe,14,ae[30]),$e=le($e,nt,et,Ve,Ye,20,ae[31]),Ve=ee(Ve,$e,nt,et,je,4,ae[32]),et=ee(et,Ve,$e,nt,Xe,11,ae[33]),nt=ee(nt,et,Ve,$e,rt,16,ae[34]),$e=ee($e,nt,et,Ve,Ge,23,ae[35]),Ve=ee(Ve,$e,nt,et,ke,4,ae[36]),et=ee(et,Ve,$e,nt,Oe,11,ae[37]),nt=ee(nt,et,Ve,$e,Qe,16,ae[38]),$e=ee($e,nt,et,Ve,He,23,ae[39]),Ve=ee(Ve,$e,nt,et,ut,4,ae[40]),et=ee(et,Ve,$e,nt,pe,11,ae[41]),nt=ee(nt,et,Ve,$e,Ee,16,ae[42]),$e=ee($e,nt,et,Ve,Pe,23,ae[43]),Ve=ee(Ve,$e,nt,et,ot,4,ae[44]),et=ee(et,Ve,$e,nt,Ye,11,ae[45]),nt=ee(nt,et,Ve,$e,ze,16,ae[46]),$e=ee($e,nt,et,Ve,Te,23,ae[47]),Ve=ne(Ve,$e,nt,et,pe,6,ae[48]),et=ne(et,Ve,$e,nt,Qe,10,ae[49]),nt=ne(nt,et,Ve,$e,Ge,15,ae[50]),$e=ne($e,nt,et,Ve,je,21,ae[51]),Ve=ne(Ve,$e,nt,et,Ye,6,ae[52]),et=ne(et,Ve,$e,nt,Ee,10,ae[53]),nt=ne(nt,et,Ve,$e,He,15,ae[54]),$e=ne($e,nt,et,Ve,ke,21,ae[55]),Ve=ne(Ve,$e,nt,et,Xe,6,ae[56]),et=ne(et,Ve,$e,nt,ze,10,ae[57]),nt=ne(nt,et,Ve,$e,Pe,15,ae[58]),$e=ne($e,nt,et,Ve,ut,21,ae[59]),Ve=ne(Ve,$e,nt,et,Oe,6,ae[60]),et=ne(et,Ve,$e,nt,rt,10,ae[61]),nt=ne(nt,et,Ve,$e,Te,15,ae[62]),$e=ne($e,nt,et,Ve,ot,21,ae[63]),he[0]=he[0]+Ve|0,he[1]=he[1]+$e|0,he[2]=he[2]+nt|0,he[3]=he[3]+et|0},_doFinalize:function(){var ve=this._data,ye=ve.words,me=8*this._nDataBytes,ge=8*ve.sigBytes;ye[ge>>>5]|=128<<24-ge%32;var _e=se.floor(me/4294967296),he=me;ye[15+(ge+64>>>9<<4)]=16711935&(_e<<8|_e>>>24)|4278255360&(_e<<24|_e>>>8),ye[14+(ge+64>>>9<<4)]=16711935&(he<<8|he>>>24)|4278255360&(he<<24|he>>>8),ve.sigBytes=4*(ye.length+1),this._process();for(var pe=this._hash,ke=pe.words,Te=0;Te<4;Te++){var Ee=ke[Te];ke[Te]=16711935&(Ee<<8|Ee>>>24)|4278255360&(Ee<<24|Ee>>>8)}return pe},clone:function(){var ve=x.clone.call(this);return ve._hash=this._hash.clone(),ve}});E.MD5=x._createHelper(oe),E.HmacMD5=x._createHmacHelper(oe)}(Math),ue.MD5})},function(ce,ie,Ce){"use strict";Object.defineProperty(ie,"__esModule",{value:!0}),ie.UPLOADSTATE={INIT:"init",UPLOADING:"uploading",COMPLETE:"complete",INTERRUPT:"interrupt"},ie.UPLOADSTEP={INIT:"init",PART:"part",COMPLETE:"complete"},ie.UPLOADDEFAULT={PARALLEL:5,PARTSIZE:1048576}},function(ce,ie,Ce){"use strict";function ue(oe){return oe&&oe.__esModule?oe:{default:oe}}function se(oe,ve){if(!(oe instanceof ve))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var te=function(){function oe(ve,ye){for(var me=0;me<ye.length;me++){var ge=ye[me];ge.enumerable=ge.enumerable||!1,ge.configurable=!0,"value"in ge&&(ge.writable=!0),Object.defineProperty(ve,ge.key,ge)}}return function(ve,ye,me){return ye&&oe(ve.prototype,ye),me&&oe(ve,me),ve}}(),le=Ce(5),ee=ue(le),ne=Ce(25),E=ue(ne),b=Ce(6),z=ue(b),x=Ce(7),re=ue(x),ae=function(){function oe(ve){se(this,oe);var ye=re.default.os.name,me=re.default.os.version||"",ge=re.default.browser.name,_e=re.default.browser.version||"",he=window.location.href,pe="";he&&(pe=re.default.getHost(he));var ke="pc";re.default.os.ipad?ke="pad":(re.default.os.iphone||re.default.os.android)&&(ke="phone"),this._ri=ee.default.create(),this.initParam={APIVersion:"0.6.0",lv:"1",av:z.default.version,pd:"upload",sm:"upload",md:"uploader",uuid:oe.getUuid(),os:ye,ov:me,et:ge,ev:_e,uat:navigator.userAgent,app_n:pe,tt:ke,dm:"h5",ut:""}}return te(oe,[{key:"log",value:function(ve,ye){ye&&ye.ri?(this._ri=ye.ri,delete ye.ri):this._ri=ee.default.create(),ye&&ye.ut&&(this.initParam.ut=ye.ut,delete ye.ut),this.initParam.t=new Date().getTime(),this.initParam.ll=ve=="20006"?"error":"info",this.initParam.ri=this._ri,this.initParam.e=ve;var me=[];if(ye)for(var ge in ye)me.push(ge+"="+ye[ge]);var _e=me.join("&");this.initParam.args=encodeURIComponent(_e==""?"0":_e);var he=[];for(var ge in this.initParam)he.push(ge+"="+this.initParam[ge]);var pe=he.join("&");AliyunUpload&&AliyunUpload.__logTestCallback__?AliyunUpload.__logTestCallback__(pe):new Image(0,0).src="https://videocloud.cn-hangzhou.log.aliyuncs.com/logstores/upload/track?"+pe}}],[{key:"getUuid",value:function(){var ve=E.default.get("p_h5_upload_u");return ve||(ve=ee.default.create(),E.default.set("p_h5_upload_u",ve,730)),ve}},{key:"getClientId",value:function(){return E.default.get("p_h5_upload_clientId")}},{key:"setClientId",value:function(ve){return ve||(ve=ee.default.create()),E.default.set("p_h5_upload_clientId",ve,730),ve}}]),oe}();ie.default=ae},function(ce,ie,Ce){"use strict";function ue(le,ee){if(!(le instanceof ee))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}(),te=function(){function le(){ue(this,le)}return se(le,null,[{key:"create",value:function(ee,ne){var E,b="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),z=[];if(ne=ne||b.length,ee)for(E=0;E<ee;E++)z[E]=b[0|Math.random()*ne];else{var x;for(z[8]=z[13]=z[18]=z[23]="-",z[14]="4",E=0;E<36;E++)z[E]||(x=0|16*Math.random(),z[E]=b[E==19?3&x|8:x])}return z.join("")}}]),le}();ie.default=te},function(ce,ie,Ce){"use strict";Object.defineProperty(ie,"__esModule",{value:!0});var ue={version:"1.5.0"};ie.default=ue},function(ce,ie,Ce){"use strict";function ue(b,z){if(!(b instanceof z))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function b(z,x){for(var re=0;re<x.length;re++){var ae=x[re];ae.enumerable=ae.enumerable||!1,ae.configurable=!0,"value"in ae&&(ae.writable=!0),Object.defineProperty(z,ae.key,ae)}}return function(z,x,re){return x&&b(z.prototype,x),re&&b(z,re),z}}(),te=function(b){var z=navigator.userAgent,x="other";if(b.ios)return"iOS";if(b.android)return"android";if(z.indexOf("Baiduspider")>-1)return"Baiduspider";if(z.indexOf("PlayStation")>-1)return"PS4";var re=navigator.platform=="Win32"||navigator.platform=="Windows"||z.indexOf("Windows")>-1,ae=navigator.platform=="Mac68K"||navigator.platform=="MacPPC"||navigator.platform=="Macintosh"||navigator.platform=="MacIntel";return ae&&(x="macOS"),navigator.platform=="X11"&&!re&&!ae&&(x="Unix"),String(navigator.platform).indexOf("Linux")>-1&&(x="Linux"),re?"windows":x},le=function(){var b=navigator.userAgent,z="";return(b.indexOf("Windows NT 5.0")>-1||b.indexOf("Windows 2000")>-1)&&(z="2000"),(b.indexOf("Windows NT 5.1")>-1||b.indexOf("Windows XP")>-1)&&(z="XP"),(b.indexOf("Windows NT 5.2")>-1||b.indexOf("Windows 2003")>-1)&&(z="2003"),(b.indexOf("Windows NT 6.0")>-1||b.indexOf("Windows Vista")>-1)&&(z="Vista"),(b.indexOf("Windows NT 6.1")>-1||b.indexOf("Windows 7")>-1)&&(z="7"),(b.indexOf("Windows NT 6.2")>-1||b.indexOf("Windows 8")>-1)&&(z="8"),(b.indexOf("Windows NT 6.3")>-1||b.indexOf("Windows 8.1")>-1)&&(z="8.1"),(b.indexOf("Windows NT 10")>-1||b.indexOf("Windows 10")>-1)&&(z="10"),z},ee=function(b){var z=navigator.userAgent.toLowerCase();return b.chrome?"Chrome":b.firefox?"Firefox":b.safari?"Safari":b.webview?"webview":b.ie?/edge/.test(z)?"Edge":"IE":/baiduspider/.test(z)?"Baiduspider":/ucweb/.test(z)||/UCBrowser/.test(z)?"UC":/opera/.test(z)?"Opera":/ucweb/.test(z)?"UC":/360se/.test(z)?"360\u6D4F\u89C8\u5668":/bidubrowser/.test(z)?"\u767E\u5EA6\u6D4F\u89C8\u5668":/metasr/.test(z)?"\u641C\u72D7\u6D4F\u89C8\u5668":/lbbrowser/.test(z)?"\u730E\u8C79\u6D4F\u89C8\u5668":/micromessenger/.test(z)?"\u5FAE\u4FE1\u5185\u7F6E\u6D4F\u89C8\u5668":/qqbrowser/.test(z)?"QQ\u6D4F\u89C8\u5668":/playstation/.test(z)?"PS4\u6D4F\u89C8\u5668":void 0},ne=function(){var b={},z={},x=navigator.userAgent,re=navigator.platform,ae=x.match(/Web[kK]it[\/]{0,1}([\d.]+)/),oe=x.match(/(Android);?[\s\/]+([\d.]+)?/),ve=!!x.match(/\(Macintosh\; Intel /),ye=x.match(/(iPad).*OS\s([\d_]+)/),me=x.match(/(iPod)(.*OS\s([\d_]+))?/),ge=!ye&&x.match(/(iPhone\sOS)\s([\d_]+)/),_e=x.match(/(webOS|hpwOS)[\s\/]([\d.]+)/),he=/Win\d{2}|Windows/.test(re),pe=x.match(/Windows Phone ([\d.]+)/),ke=_e&&x.match(/TouchPad/),Te=x.match(/Kindle\/([\d.]+)/),Ee=x.match(/Silk\/([\d._]+)/),Oe=x.match(/(BlackBerry).*Version\/([\d.]+)/),je=x.match(/(BB10).*Version\/([\d.]+)/),Pe=x.match(/(RIM\sTablet\sOS)\s([\d.]+)/),Qe=x.match(/PlayBook/),Xe=x.match(/Chrome\/([\d.]+)/)||x.match(/CriOS\/([\d.]+)/),ot=x.match(/Firefox\/([\d.]+)/),He=x.match(/\((?:Mobile|Tablet); rv:([\d.]+)\).*Firefox\/[\d.]+/),rt=x.match(/MSIE\s([\d.]+)/)||x.match(/Trident\/[\d](?=[^\?]+).*rv:([0-9.].)/),Ye=!Xe&&x.match(/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/),ut=Ye||x.match(/Version\/([\d.]+)([^S](Safari)|[^M]*(Mobile)[^S]*(Safari))/);if((z.webkit=!!ae)&&(z.version=ae[1]),oe&&(b.android=!0,b.version=oe[2]),ge&&!me&&(b.ios=b.iphone=!0,b.version=ge[2].replace(/_/g,".")),ye&&(b.ios=b.ipad=!0,b.version=ye[2].replace(/_/g,".")),me&&(b.ios=b.ipod=!0,b.version=me[3]?me[3].replace(/_/g,"."):null),pe&&(b.wp=!0,b.version=pe[1]),_e&&(b.webos=!0,b.version=_e[2]),ke&&(b.touchpad=!0),Oe&&(b.blackberry=!0,b.version=Oe[2]),je&&(b.bb10=!0,b.version=je[2]),Pe&&(b.rimtabletos=!0,b.version=Pe[2]),Qe&&(z.playbook=!0),Te&&(b.kindle=!0,b.version=Te[1]),Ee&&(z.silk=!0,z.version=Ee[1]),!Ee&&b.android&&x.match(/Kindle Fire/)&&(z.silk=!0),Xe&&(z.chrome=!0,z.version=Xe[1]),ot&&(z.firefox=!0,z.version=ot[1]),He&&(b.firefoxos=!0,b.version=He[1]),rt&&(z.ie=!0,z.version=rt[1]),ut&&(ve||b.ios||he||oe)&&(z.safari=!0,b.ios||(z.version=ut[1])),Ye&&(z.webview=!0),ve){var Ge=x.match(/[\d]*_[\d]*_[\d]*/);Ge&&Ge.length>0&&Ge[0]&&(b.version=Ge[0].replace(/_/g,"."))}return b.tablet=!!(ye||Qe||oe&&!x.match(/Mobile/)||ot&&x.match(/Tablet/)||rt&&!x.match(/Phone/)&&x.match(/Touch/)),b.phone=!(b.tablet||b.ipod||!(oe||ge||_e||Oe||je||Xe&&x.match(/Android/)||Xe&&x.match(/CriOS\/([\d.]+)/)||ot&&x.match(/Mobile/)||rt&&x.match(/Touch/))),b.pc=!b.tablet&&!b.phone,ve?b.name="macOS":he?(b.name="windows",b.version=le()):b.name=te(b),z.name=ee(z),{os:b,browser:z}}(),E=function(){function b(){ue(this,b)}return se(b,null,[{key:"getHost",value:function(z){var ae="";if(z===void 0||z==null||z=="")return"";var x=z.indexOf("//"),re=z;x>-1&&(re=z.substring(x+2));var ae=re,oe=re.split("/");return oe&&oe.length>0&&(ae=oe[0]),oe=ae.split(":"),oe&&oe.length>0&&(ae=oe[0]),ae}},{key:"os",get:function(){return ne.os}},{key:"browser",get:function(){var z=ne.browser;return z.name||(z.name=ee()),z}}]),b}();ie.default=E},function(ce,ie,Ce){"use strict";function ue(le,ee){if(!(le instanceof ee))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}(),te=function(){function le(){ue(this,le)}return se(le,null,[{key:"get",value:function(ee,ne,E,b,z){var x;E=E||function(){},typeof XMLHttpRequest=="undefined"&&(window.XMLHttpRequest=function(){try{return new window.ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(re){}try{return new window.ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(re){}try{return new window.ActiveXObject("Msxml2.XMLHTTP")}catch(re){}throw new Error("This browser does not support XMLHttpRequest.")}),x=new XMLHttpRequest,x.onreadystatechange=function(){x.readyState===4&&(x.status===200?ne(x.responseText):E(x.responseText))};try{b===void 0&&(b=!0),x.open("GET",ee,b),z&&(x.withCredentials=!0)}catch(re){return void E(re)}try{x.send()}catch(re){E(re)}}}]),le}();ie.default=te},function(ce,ie,Ce){"use strict";function ue(ne,E){if(!(ne instanceof E))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function ne(E,b){for(var z=0;z<b.length;z++){var x=b[z];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(E,x.key,x)}}return function(E,b,z){return b&&ne(E.prototype,b),z&&ne(E,z),E}}(),te=Ce(27),le=Ce(30),ee=(Ce(10),function(){function ne(){ue(this,ne)}return se(ne,null,[{key:"randomUUID",value:function(){for(var E=[],b="0123456789abcdef",z=0;z<36;z++)E[z]=b.substr(Math.floor(16*Math.random()),1);return E[14]="4",E[19]=b.substr(3&E[19]|8,1),E[8]=E[13]=E[18]=E[23]="-",E.join("")}},{key:"aliyunEncodeURI",value:function(E){var b=encodeURIComponent(E);return b=b.replace(/\+/g,"%20").replace(/\*/g,"%2A").replace(/%7E/g,"~").replace(/!/g,"%21").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/'/g,"%27")}},{key:"makeUTF8sort",value:function(E,b,z){if(!E)throw new Error("PrismPlayer Error: vid should not be null!");var x=[];for(var re in E)x.push(re);for(var ae=x.sort(),oe="",ve=ae.length,re=0;re<ve;re++){var ye=ne.aliyunEncodeURI(ae[re]),me=ne.aliyunEncodeURI(E[ae[re]]);oe==""?oe=ye+b+me:oe+=z+ye+b+me}return oe}},{key:"makeChangeSiga",value:function(E,b){if(!E)throw new Error("PrismPlayer Error: vid should not be null!");return le.stringify(te("GET&"+ne.aliyunEncodeURI("/")+"&"+ne.aliyunEncodeURI(ne.makeUTF8sort(E,"=","&")),b+"&"))}}]),ne}());ie.default=ee},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){return ue.enc.Utf8})},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){return ue.enc.Hex})},function(ce,ie,Ce){ce.exports=Ce(13)},function(ce,ie,Ce){"use strict";var ue,se,te=Ce(14),le=function(ne){return ne&&ne.__esModule?ne:{default:ne}}(te),ee={Vod:le.default};ue=[],(se=function(){return ee}.apply(ie,ue))!==void 0&&(ce.exports=se),window.AliyunUpload=ee,Xt.exports=AliyunUpload},function(ce,ie,Ce){"use strict";function ue(je){return je&&je.__esModule?je:{default:je}}function se(je,Pe){if(!(je instanceof Pe))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var te=function(){function je(Pe,Qe){for(var Xe=0;Xe<Qe.length;Xe++){var ot=Qe[Xe];ot.enumerable=ot.enumerable||!1,ot.configurable=!0,"value"in ot&&(ot.writable=!0),Object.defineProperty(Pe,ot.key,ot)}}return function(Pe,Qe,Xe){return Qe&&je(Pe.prototype,Qe),Xe&&je(Pe,Xe),Pe}}(),le=Ce(15),ee=Ce(3),ne=Ce(16),E=ue(ne),b=Ce(18),z=ue(b),x=Ce(24),re=ue(x),ae=Ce(4),oe=ue(ae),ve=Ce(1),ye=ue(ve),me=Ce(5),ge=ue(me),_e=Ce(26),he=ue(_e),pe=Ce(31),ke=ue(pe),Te=Ce(32),Ee=ue(Te),Oe=(Ce(2),function(){function je(Pe){se(this,je),this.options=Pe,this.options.partSize=this.options.partSize||ee.UPLOADDEFAULT.PARTSIZE,this.options.parallel=this.options.parallel||ee.UPLOADDEFAULT.PARALLEL,this.options.region=this.options.region||"cn-shanghai",this.options.cname=this.options.cname||!1,this.options.localCheckpoint=this.options.localCheckpoint||!1,this.options.enableUploadProgress===void 0&&(this.options.enableUploadProgress=!0),this._ossCreditor=new Object,this._state=le.VODSTATE.INIT,this._uploadList=[],this._curIndex=-1,this._ossUpload=null,this._log=new oe.default,this._retryCount=0,this._retryTotal=this.options.retryCount||3,this._retryDuration=this.options.retryDuration||2,this._state=le.VODSTATE.INIT,this._uploadWay="vod",this._onbeforeunload=!1,this._invalidUserId=!1,this._initEvent()}return te(je,[{key:"init",value:function(Pe,Qe,Xe,ot){return this._retryCount=0,!(Xe&&!ot||!Xe&&ot)&&!(Pe&&!Qe||!Pe&&Qe)&&(this._ossCreditor.accessKeyId=Pe,this._ossCreditor.accessKeySecret=Qe,this._ossCreditor.securityToken=Xe,this._ossCreditor.expireTime=ot,!0)}},{key:"addFile",value:function(Pe,Qe,Xe,ot,He,rt){if(!Pe)return!1;if(Pe.size==0)try{this.options.onUploadFailed({file:Pe},"EmptyFile","\u6587\u4EF6\u5927\u5C0F\u4E3A0\uFF0C\u4E0D\u80FD\u4E0A\u4F20")}catch(ze){console.log(ze)}for(var Ye=(this.options,0);Ye<this._uploadList.length;Ye++)if(this._uploadList[Ye].file==Pe)return!1;var ut=new Object;if(ut.file=Pe,ut._endpoint=Qe,ut._bucket=Xe,ut._object=ot,ut.state=le.UPLOADSTATE.INIT,ut.isImage=ye.default.isImage(Pe.name),!ut.isImage&&this.options.enableUploadProgress){var Ge=this;Ee.default.getMd5(Pe,function(ze){ut.fileHash=ze;var Ve=Ge._getCheckoutpoint(ut);Ge.options.localCheckpoint||Ve||Ge._getCheckoutpointFromCloud(ut,function($e){if($e.UploadPoint){var nt=JSON.parse($e.UploadPoint);nt.loaded!=1&&(ut.checkpoint=nt.checkpoint,ut.loaded=nt.loaded,ut.videoId=$e.VideoId,Ge._saveCheckoutpoint(ut,nt.checkpoint))}},function($e){try{if(($e=JSON.parse($e))&&$e.Code=="InvalidParameter"&&$e.Message.indexOf("UserId")>0){Ge._invalidUserId=!0;var nt=$e.Message+"\uFF0C\u6B63\u786E\u8D26\u53F7ID(userId)\u8BF7\u53C2\u8003\uFF1Ahttps://help.aliyun.com/knowledge_detail/37196.html";console.log(nt)}}catch(et){console.log(et)}})})}He&&(ut.videoInfo=He?JSON.parse(He).Vod:{},ut.userData=z.default.encode(He)),ut.ri=ge.default.create(),this._uploadList.push(ut),this._reportLog("20001",ut,{ql:this._uploadList.length});try{this.options.addFileSuccess&&this.options.addFileSuccess(ut)}catch(ze){console.log(ze)}return!0}},{key:"deleteFile",value:function(Pe){return!!this.cancelFile(Pe)&&(this._uploadList.splice(Pe,1),!0)}},{key:"cleanList",value:function(){this.stopUpload(),this._uploadList.length=0,this._curIndex=-1}},{key:"cancelFile",value:function(Pe){if(this.options,Pe<0||Pe>=this._uploadList.length)return!1;var Qe=this._uploadList[Pe];if(Pe==this._curIndex&&Qe.state==le.UPLOADSTATE.UPLOADING){Qe.state=le.UPLOADSTATE.CANCELED;var Xe=this._getCheckoutpoint(Qe);Xe&&Xe.checkpoint&&(Xe=Xe.checkpoint),Xe&&this._ossUpload.abort(Qe),this._removeCheckoutpoint(Qe),this.nextUpload()}else Qe.state!=le.UPLOADSTATE.SUCCESS&&(Qe.state=le.UPLOADSTATE.CANCELED);return this._reportLog("20008",Qe),!0}},{key:"resumeFile",value:function(Pe){if(this.options,Pe<0||Pe>=this._uploadList.length)return!1;var Qe=this._uploadList[Pe];return Qe.state==le.UPLOADSTATE.CANCELED&&(Qe.state=le.UPLOADSTATE.INIT,!0)}},{key:"listFiles",value:function(){return this._uploadList}},{key:"getCheckpoint",value:function(Pe){return this._getCheckoutpoint({file:Pe})}},{key:"startUpload",value:function(Pe){if(this._retryCount=0,this.options,this._state==le.VODSTATE.START||this._state==le.VODSTATE.EXPIRE)return void console.log("already started or expired");if(this._initState(),this._curIndex=this._findUploadIndex(),this._curIndex==-1)return void(this._state=le.VODSTATE.END);var Qe=this._uploadList[this._curIndex];this._ossUpload=null,this._upload(Qe),this._state=le.VODSTATE.START}},{key:"nextUpload",value:function(){var Pe=this.options;if(this._state==le.VODSTATE.START)if(this._curIndex=this._findUploadIndex(),this._curIndex!=-1){var Qe=this._uploadList[this._curIndex];this._ossUpload=null,this._upload(Qe)}else{this._state=le.VODSTATE.END;try{Pe.onUploadEnd&&Pe.onUploadEnd(Qe)}catch(Xe){console.log(Xe)}}}},{key:"clear",value:function(Pe){for(var Qe=this.options,Xe=0,ot=0;ot<this._uploadList.length;ot++)Qe.uploadList[ot].state==le.UPLOADSTATE.SUCCESS&&Xe++,this._uploadList[ot].state==Pe&&(Qe.uploadList.splice(ot,1),ot--);Qe.onClear&&Qe.onClear(Qe.uploadList.length,Xe)}},{key:"stopUpload",value:function(){if((this._state==le.VODSTATE.START||this._state==le.VODSTATE.FAILURE||this._curIndex==-1)&&this._curIndex!=-1){var Pe=this._uploadList[this._curIndex];this._state=le.VODSTATE.STOP,Pe.state=le.UPLOADSTATE.STOPED,this._changeState(Pe,le.UPLOADSTATE.STOPED),this._ossUpload.cancel()}}},{key:"resumeUploadWithAuth",value:function(Pe){var Qe=this;if(!Pe)return!1;var Xe=JSON.parse(z.default.decode(Pe));return!!(Xe.AccessKeyId&&Xe.AccessKeySecret&&Xe.SecurityToken&&Xe.Expiration)&&Qe.resumeUploadWithToken(Xe.AccessKeyId,Xe.AccessKeySecret,Xe.SecurityToken,Xe.Expiration)}},{key:"resumeUploadWithToken",value:function(Pe,Qe,Xe,ot){if(this.options,!(Pe&&Qe&&Xe&&ot)||this._state!=le.VODSTATE.EXPIRE||this._curIndex==-1)return!1;var He="";return this._uploadList.length>this._curIndex&&(He=this._uploadList[this._curIndex]),He&&(this.init(Pe,Qe,Xe,ot),this._state=le.VODSTATE.START,this._ossUpload=null,this._uploadCore(He,He.retry),He.retry=!1),!0}},{key:"resumeUploadWithSTSToken",value:function(Pe,Qe,Xe){if(this._curIndex==-1||this._state!=le.VODSTATE.EXPIRE)return!1;if(this._uploadList.length>this._curIndex){var ot=this._uploadList[this._curIndex];ot.object?this._refreshSTSTokenUpload(ot,Pe,Qe,Xe):this.setSTSToken(ot,Pe,Qe,Xe)}}},{key:"setSTSTokenDirectlyUpload",value:function(Pe,Qe,Xe,ot,He){if(!(Qe&&Xe&&ot&&He))return console.log("accessKeyId\u3001ccessKeySecret\u3001securityToken and expiration should not be empty."),!1;this._ut="oss";var rt=Pe;this.init(Qe,Xe,ot,He),rt.endpoint=rt._endpoint,rt.bucket=rt._bucket,rt.object=rt._object,this._ossUpload=null,this._uploadCore(rt,Pe.retry),Pe.retry=!1}},{key:"setSTSToken",value:function(Pe,Qe,Xe,ot){if(!Qe||!Xe||!ot)return console.log("accessKeyId\u3001ccessKeySecret\u3001securityToken should not be empty."),!1;this._ut="vod",this._uploadWay="sts";var He=Pe.videoInfo,rt={accessKeyId:Qe,securityToken:ot,accessKeySecret:Xe,fileName:Pe.file.name,title:He.Title,requestId:Pe.ri,region:this.options.region};He.ImageType&&(rt.imageType=He.ImageType),He.ImageExt&&(rt.imageExt=He.ImageExt),He.FileSize&&(rt.fileSize=He.FileSize),He.Description&&(rt.description=He.Description),He.CateId&&(rt.cateId=He.CateId),He.Tags&&(rt.tags=He.Tags),He.TemplateGroupId&&(rt.templateGroupId=He.TemplateGroupId),He.StorageLocation&&(rt.storageLocation=He.StorageLocation),He.CoverURL&&(rt.coverUrl=He.CoverURL),He.TransCodeMode&&(rt.transCodeMode=He.TransCodeMode),He.UserData&&(rt.userData=He.UserData);var Ye=this,ut="getUploadAuth";Pe.videoId?(rt.videoId=Pe.videoId,ut="refreshUploadAuth"):Pe.isImage&&(ut="getImageUploadAuth"),he.default[ut](rt,function(Ge){Pe.videoId=Ge.VideoId?Ge.VideoId:Pe.videoId,Ye.setUploadAuthAndAddress(Pe,Ge.UploadAuth,Ge.UploadAddress),Ye._state=le.VODSTATE.START},function(Ge){Ye._error(Pe,{name:Ge.Code,code:Ge.Code,message:Ge.Message,requestId:Ge.RequestId})})}},{key:"setUploadAuthAndAddress",value:function(Pe,Qe,Xe,ot){if(!Pe||!Qe||!Xe)return!1;var He=JSON.parse(z.default.decode(Qe));if(!(He.AccessKeyId&&He.AccessKeySecret&&He.SecurityToken&&He.Expiration))return console.error("uploadauth is invalid"),!1;var rt={},Ye=Pe;if(Xe){if(rt=JSON.parse(z.default.decode(Xe)),!rt.Endpoint||!rt.Bucket||!rt.FileName)return console.error("uploadAddress is invalid"),!1}else rt.Endpoint=Ye.endpoint,rt.Bucket=Ye.bucket,rt.FileName=Ye.object;this._ut="vod",this._uploadWay="vod",this.options.region=He.Region||this.options.region,this.init(He.AccessKeyId,He.AccessKeySecret,He.SecurityToken,He.Expiration),Ye.endpoint=Ye._endpoint?Ye._endpoint:rt.Endpoint,Ye.bucket=Ye._bucket?Ye._bucket:rt.Bucket,Ye.object=Ye._object?Ye._object:rt.FileName,Ye.region=this.options.region,ot&&(Ye.videoId=ot),this._ossUpload=null,this._uploadCore(Ye,Pe.retry),Pe.retry=!1}},{key:"_refreshSTSTokenUpload",value:function(Pe,Qe,Xe,ot){if(!Qe||!Xe||!ot)return console.log("accessKeyId\u3001ccessKeySecret\u3001securityToken should not be empty."),!1;var He={accessKeyId:Qe,securityToken:ot,accessKeySecret:Xe,videoId:Pe.object,requestId:Pe.ri,region:this.options.region},rt=this,Ye="refreshUploadAuth";Pe.isImage&&(Ye="getImageUploadAuth"),he.default[Ye](He,function(ut){rt.setUploadAuthAndAddress(Pe,ut.UploadAuth,UploadAddress),rt._state=le.VODSTATE.START},function(ut){rt._error(Pe,{name:ut.Code,code:ut.Code,message:ut.Message,requestId:ut.RequestId})})}},{key:"_upload",value:function(Pe){var Qe=arguments.length>1&&arguments[1]!==void 0&&arguments[1],Xe=this.options;if(Pe.retry=Qe,Xe.onUploadstarted&&!Qe)try{var ot=this._getCheckoutpoint(Pe);ot&&ot.state!=le.UPLOADSTATE.UPLOADING&&(Pe.checkpoint=ot,Pe.videoId=ot.videoId),Xe.onUploadstarted(Pe)}catch(He){console.log(He)}}},{key:"_uploadCore",value:function(Pe){if(arguments.length>1&&arguments[1]!==void 0&&arguments[1],!this._ossCreditor.accessKeyId||!this._ossCreditor.accessKeySecret||!this._ossCreditor.securityToken)throw new Error("AccessKeyId\u3001AccessKeySecret\u3001securityToken should not be null");if(Pe.state=le.UPLOADSTATE.UPLOADING,!this._ossUpload){Pe.endpoint=Pe.endpoint||"http://oss-cn-hangzhou.aliyuncs.com";var Qe=this;this._ossUpload=new E.default({bucket:Pe.bucket,endpoint:Pe.endpoint,AccessKeyId:this._ossCreditor.accessKeyId,AccessKeySecret:this._ossCreditor.accessKeySecret,SecurityToken:this._ossCreditor.securityToken,timeout:this.options.timeout,cname:this.options.cname},{onerror:function(Ge,ze){Qe._error.call(Qe,Ge,ze)},oncomplete:function(Ge,ze){Qe._complete.call(Qe,Ge,ze)},onprogress:function(Ge,ze,Ve){Qe._progress.call(Qe,Ge,ze,Ve)}})}var Xe=ye.default.getFileType(Pe.file.name),ot=this._getCheckoutpoint(Pe),He="",rt="";ot&&ot.checkpoint&&(rt=ot.state,He=ot.videoId,ot=ot.checkpoint),ot&&He==Pe.videoId&&rt!=le.UPLOADSTATE.UPLOADING&&(ot.file=Pe.file,Pe.checkpoint=ot,ot.uploadId);var Ye=this._adjustPartSize(Pe);this._reportLog("20002",Pe,{ft:Xe,fs:Pe.file.size,bu:Pe.bucket,ok:Pe.object,vid:Pe.videoId||"",fn:Pe.file.name,fw:null,fh:null,ps:Ye});var ut={headers:{"x-oss-notification":Pe.userData?Pe.userData:""},partSize:Ye,parallel:this.options.parallel};this._ossUpload.upload(Pe,ut)}},{key:"_findUploadIndex",value:function(){for(var Pe=-1,Qe=0;Qe<this._uploadList.length;Qe++)if(this._uploadList[Qe].state==le.UPLOADSTATE.INIT){Pe=Qe;break}return Pe}},{key:"_error",value:function(Pe,Qe){if(Qe.name=="cancel")try{this.options.onUploadCanceled(Pe,Qe)}catch(ot){console.log(ot)}else{if(Qe.message.indexOf("InvalidAccessKeyIdError")>0||Qe.name=="SignatureDoesNotMatchError"||Qe.code=="SecurityTokenExpired"||Qe.code=="InvalidSecurityToken.Expired"||Qe.code=="InvalidAccessKeyId"&&this._ossCreditor.securityToken){if(this.options.onUploadTokenExpired){this._state=le.VODSTATE.EXPIRE,Pe.state=le.UPLOADSTATE.FAIlURE;try{this.options.onUploadTokenExpired(Pe,Qe)}catch(ot){console.log(ot)}}return}if((Qe.name=="RequestTimeoutError"||Qe.name=="ConnectionTimeout"||Qe.name=="ConnectionTimeoutError")&&this._retryTotal>this._retryCount){var Xe=this;return setTimeout(function(){Xe._uploadCore(Pe,!0)},1e3*Xe._retryDuration),void this._retryCount++}Qe.name=="NoSuchUploadError"&&this._removeCheckoutpoint(Pe),this._handleError(Pe,Qe)}}},{key:"_handleError",value:function(Pe,Qe){var Xe=!(arguments.length>2&&arguments[2]!==void 0)||arguments[2],ot=le.UPLOADSTATE.FAIlURE;if(Pe.state!=le.UPLOADSTATE.CANCELED&&(Pe.state=le.UPLOADSTATE.FAIlURE,this._state=le.VODSTATE.FAILURE,this.options.onUploadFailed&&Qe&&Qe.code&&Qe.message))try{this.options.onUploadFailed(Pe,Qe.code,Qe.message)}catch(rt){console.log(rt)}if(Xe&&this._changeState(Pe,ot),this._reportLog("20006",Pe,{code:Qe.name,message:Qe.message,requestId:Qe.requestId,fs:Pe.file.size,bu:Pe.bucket,ok:Pe.object,fn:Pe.file.name}),this._reportLog("20004",Pe,{requestId:Qe.requestId,fs:Pe.file.size,bu:Pe.bucket,ok:Pe.object,fn:Pe.file.name}),Pe.ri=ge.default.create(),this._findUploadIndex()!=-1){var He=this;this._state=le.VODSTATE.START,setTimeout(function(){He.nextUpload()},100)}}},{key:"_complete",value:function(Pe,Qe){if(Pe.state=le.UPLOADSTATE.SUCCESS,this.options.onUploadSucceed)try{this.options.onUploadSucceed(Pe)}catch(He){console.log(He)}var Xe=0;Qe&&Qe.res&&Qe.res.headers&&(Xe=Qe.res.headers["x-oss-request-id"]),this._removeCheckoutpoint(Pe);var ot=this;setTimeout(function(){ot.nextUpload()},100),this._retryCount=0,this._reportLog("20003",Pe,{requestId:Xe})}},{key:"_progress",value:function(Pe,Qe,Xe){if(this.options.onUploadProgress)try{Pe.loaded=Qe.loaded,this.options.onUploadProgress(Pe,Qe.total,Qe.loaded)}catch(ze){console.log(ze)}var ot=Qe.checkpoint,He=0;ot&&(Pe.checkpoint=ot,this._saveCheckoutpoint(Pe,ot,le.UPLOADSTATE.UPLOADING),He=ot.uploadId),this._retryCount=0;var rt=this._getPortNumber(ot),Ye=0;if(Xe&&Xe.headers&&(Ye=Xe.headers["x-oss-request-id"]),Qe.loaded!=0&&this._reportLog("20007",Pe,{pn:rt,requestId:Ye}),Qe.loaded!=1&&this._reportLog("20005",Pe,{UploadId:He,pn:rt+1,pr:Pe.retry?1:0,fs:Pe.file.size,bu:Pe.bucket,ok:Pe.object,fn:Pe.file.name}),!this._invalidUserId&&!Pe.isImage&&this._ut=="vod"&&this.options.enableUploadProgress){var ut={file:Pe.file,checkpoint:Qe,userId:this.options.userId,videoId:Pe.videoId,region:this.options.region,fileHash:Pe.fileHash};try{var Ge=this;ke.default.upload(ut,function(){},function(ze){if((ze=JSON.parse(ze))&&ze.Code=="InvalidParameter"&&ze.Message.indexOf("UserId")>0){Ge._invalidUserId=!0;var Ve=ze.Message+"\uFF0C\u6B63\u786E\u8D26\u53F7ID(userId)\u8BF7\u53C2\u8003\uFF1Ahttps://help.aliyun.com/knowledge_detail/37196.html";console.log(Ve)}})}catch(ze){console.log(ze)}}}},{key:"_getPortNumber",value:function(Pe){if(Pe){var Qe=Pe.doneParts;if(Qe&&Qe.length>0)return Qe[Qe.length-1].number}return 0}},{key:"_removeCheckoutpoint",value:function(Pe){var Qe=this._getCheckoutpointKey(Pe);re.default.remove(Qe)}},{key:"_getCheckoutpoint",value:function(Pe){var Qe=this._getCheckoutpointKey(Pe),Xe=re.default.get(Qe);if(Xe)try{return JSON.parse(Xe)}catch(ot){}return""}},{key:"_saveCheckoutpoint",value:function(Pe,Qe,Xe){if(Qe){var ot=this._getCheckoutpointKey(Pe),He=Pe.file,rt={fileName:He.name,lastModified:He.lastModified,size:He.size,object:Pe.object,videoId:Pe.videoId,bucket:Pe.bucket,endpoint:Pe.endpoint,checkpoint:Qe,loaded:Pe.loaded,state:Xe};re.default.set(ot,JSON.stringify(rt))}}},{key:"_changeState",value:function(Pe,Qe){var Xe=this._getCheckoutpoint(Pe);Xe&&((this._onbeforeunload=!0)&&(Qe=le.UPLOADSTATE.STOPED),this._saveCheckoutpoint(Pe,Xe.checkpoint,Qe))}},{key:"_getCheckoutpointKey",value:function(Pe){return"upload_"+Pe.file.lastModified+"_"+Pe.file.name+"_"+Pe.file.size}},{key:"_getCheckoutpointFromCloud",value:function(Pe,Qe,Xe){var ot={userId:this.options.userId,uploadInfoList:[{FileName:Pe.file.name,FileSize:Pe.file.size,FileCreateTime:Pe.file.lastModified,FileHash:Pe.fileHash}],region:this.options.region};ke.default.get(ot,function(He){Qe(He)},Xe)}},{key:"_reportLog",value:function(Pe,Qe,Xe){Xe||(Xe={}),Xe.ri=Qe.ri,this._ut&&(Xe.ut=this._ut),this._log.log(Pe,Xe)}},{key:"_initEvent",value:function(){var Pe=this;window&&(window.onbeforeunload=function(Qe){if(Pe._onbeforeunload=!0,Pe._curIndex!=-1&&Pe._uploadList.length>Pe._curIndex){var Xe=Pe._uploadList[Pe._curIndex];Pe._changeState(Xe,le.UPLOADSTATE.STOPED)}})}},{key:"_initState",value:function(){for(var Pe=0;Pe<this._uploadList.length;Pe++){var Qe=this._uploadList[Pe];Qe.state!=le.UPLOADSTATE.FAIlURE&&Qe.state!=le.UPLOADSTATE.STOPED||(Qe.state=le.UPLOADSTATE.INIT)}this._state=le.VODSTATE.INIT}},{key:"_adjustPartSize",value:function(Pe){return Pe.file.size/this.options.partSize>1e4?Pe.file.size/9999:this.options.partSize}}]),je}());ie.default=Oe},function(ce,ie,Ce){"use strict";Object.defineProperty(ie,"__esModule",{value:!0}),ie.UPLOADSTATE={INIT:"Ready",UPLOADING:"Uploading",SUCCESS:"Success",FAIlURE:"Failure",CANCELED:"Canceled",STOPED:"Stoped"},ie.VODSTATE={INIT:"Init",START:"Start",STOP:"Stop",FAILURE:"Failure",EXPIRE:"Expire",END:"End"}},function(ce,ie,Ce){"use strict";function ue(b){return b&&b.__esModule?b:{default:b}}function se(b,z){if(!(b instanceof z))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var te=function(){function b(z,x){for(var re=0;re<x.length;re++){var ae=x[re];ae.enumerable=ae.enumerable||!1,ae.configurable=!0,"value"in ae&&(ae.writable=!0),Object.defineProperty(z,ae.key,ae)}}return function(z,x,re){return x&&b(z.prototype,x),re&&b(z,re),z}}(),le=Ce(3),ee=Ce(17),ne=(ue(ee),Ce(1)),E=(ue(ne),function(){function b(z,x){if(se(this,b),z){this._config=z,this.create(this._config),this._uploadInfo=null,this._callback={};var re=function(){};this._callback.onerror=x.onerror||re,this._callback.oncomplete=x.oncomplete||re,this._callback.onprogress=x.onprogress||re}}return te(b,[{key:"create",value:function(z){if(z.endpoint=z.endpoint||this._config.endpoint,z.bucket=z.bucket||this._config.bucket,!(z.AccessKeyId&&z.AccessKeySecret&&z.endpoint&&z.SecurityToken))throw new Error("AccessKeyId\u3001AccessKeySecret\u3001endpoint should not be null");var x={accessKeyId:z.AccessKeyId,accessKeySecret:z.AccessKeySecret,stsToken:z.SecurityToken,endpoint:z.endpoint||this._config.endpoint,bucket:z.bucket||this._config.bucket,secure:!0,cname:z.cname};z.timeout&&(x.timeout=z.timeout),this.oss=new OSS.Wrapper(x)}},{key:"abort",value:function(z){if(z.checkpoint){var x=z.checkpoint.uploadId;this.oss.abortMultipartUpload(z.object,x)}}},{key:"getVersion",value:function(){}},{key:"cancel",value:function(){this.oss.cancel&&this.oss.cancel()}},{key:"upload",value:function(z,x){this._uploadInfo=z;var re=this,ae=function(ve,ye,me){return function(ge){re._progress(ve,ye,me),ge()}},oe={parallel:x.parallel||this._config.parallel||le.UPLOADDEFAULT.PARALLEL,partSize:x.partSize||this._config.partSize||le.UPLOADDEFAULT.PARTSIZE,progress:ae};x.headers&&(oe.headers=x.headers),z.checkpoint&&(oe.checkpoint=z.checkpoint),z.bucket||(this.oss.options.bucket=z.bucket),z.endpoint||(this.oss.options.endpoint=z.endpoint),this.oss.multipartUpload(z.object,z.file,oe).then(function(ve,ye){re._complete(ve)}).catch(function(ve){re.oss.cancel&&(re.oss&&re.oss.isCancel()?console.log("oss is cancel as error"):re.oss.cancel()),re._error(ve)})}},{key:"header",value:function(z,x,re){this.oss.get(z.object).then(function(ae){x(ae)}).catch(function(ae){re(ae)})}},{key:"_progress",value:function(z,x,re){this._callback.onprogress(this._uploadInfo,{loaded:z,total:this._uploadInfo.file.size,checkpoint:x},re)}},{key:"_error",value:function(z){this._callback.onerror(this._uploadInfo,z)}},{key:"_complete",value:function(z){this._callback.oncomplete(this._uploadInfo,z)}}]),b}());ie.default=E},function(ce,ie,Ce){"use strict";function ue(le,ee){if(!(le instanceof ee))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}(),te=function(){function le(){ue(this,le)}return se(le,null,[{key:"format",value:function(ee){if(arguments.length<2)return null;for(var ne=arguments[1],E=1;E<arguments.length;E++){var b=new RegExp("\\{"+(E-1)+"\\}","gm");ne=ne.replace(b,arguments[E+1])}return{code:ee,message:ne}}},{key:"CODE",get:function(){return{SUCCESS:"Successful",EmptyValue:"InvalidParameter.EmptyValue",STSInvalid:"InvalidParameter.TokenInvalid",ReadFileError:"ReadFileError",FILEDUPLICATION:"FileDuplication",UploadALEADRYSTARTED:"UploadAlearyStarted"}}},{key:"MESSAGE",get:function(){return{SUCCESS:"Successful",EmptyValue:"\u53C2\u6570 {0} \u4E0D\u80FD\u4E3A\u7A7A\u3002",STSInvalid:"STS\u53C2\u6570\u975E\u6CD5\uFF0C accessKeyId\u3001accessKeySecret\u3001secretToken\u3001expireTime\u90FD\u4E0D\u80FD\u4E3A\u7A7A\u3002",ReadFileError:"\u8BFB\u53D6\u6587\u4EF6{0}{1}\u5931\u8D25.",FILEDUPLICATION:"\u6587\u4EF6\u91CD\u590D\u6DFB\u52A0 {0}",UploadALEADRYSTARTED:"\u91CD\u590D\u5F00\u59CB."}}}]),le}();ie.default=te},function(ce,ie,Ce){"use strict";(function(ue){function se(ee,ne){if(!(ee instanceof ne))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var te=function(){function ee(ne,E){for(var b=0;b<E.length;b++){var z=E[b];z.enumerable=z.enumerable||!1,z.configurable=!0,"value"in z&&(z.writable=!0),Object.defineProperty(ne,z.key,z)}}return function(ne,E,b){return E&&ee(ne.prototype,E),b&&ee(ne,b),ne}}(),le=function(){function ee(){se(this,ee)}return te(ee,null,[{key:"encode",value:function(ne){return new ue(ne).toString("base64")}},{key:"decode",value:function(ne){return new ue(ne,"base64").toString()}}]),ee}();ie.default=le}).call(ie,Ce(19).Buffer)},function(ce,ie,Ce){"use strict";(function(ue){function se(){return le.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function te(De,we){if(se()<we)throw new RangeError("Invalid typed array length");return le.TYPED_ARRAY_SUPPORT?(De=new Uint8Array(we),De.__proto__=le.prototype):(De===null&&(De=new le(we)),De.length=we),De}function le(De,we,Le){if(!(le.TYPED_ARRAY_SUPPORT||this instanceof le))return new le(De,we,Le);if(typeof De=="number"){if(typeof we=="string")throw new Error("If encoding is specified then the first argument must be a string");return b(this,De)}return ee(this,De,we,Le)}function ee(De,we,Le,Ue){if(typeof we=="number")throw new TypeError('"value" argument must not be a number');return typeof ArrayBuffer!="undefined"&&we instanceof ArrayBuffer?re(De,we,Le,Ue):typeof we=="string"?z(De,we,Le):ae(De,we)}function ne(De){if(typeof De!="number")throw new TypeError('"size" argument must be a number');if(De<0)throw new RangeError('"size" argument must not be negative')}function E(De,we,Le,Ue){return ne(we),we<=0?te(De,we):Le!==void 0?typeof Ue=="string"?te(De,we).fill(Le,Ue):te(De,we).fill(Le):te(De,we)}function b(De,we){if(ne(we),De=te(De,we<0?0:0|oe(we)),!le.TYPED_ARRAY_SUPPORT)for(var Le=0;Le<we;++Le)De[Le]=0;return De}function z(De,we,Le){if(typeof Le=="string"&&Le!==""||(Le="utf8"),!le.isEncoding(Le))throw new TypeError('"encoding" must be a valid string encoding');var Ue=0|ye(we,Le);De=te(De,Ue);var Me=De.write(we,Le);return Me!==Ue&&(De=De.slice(0,Me)),De}function x(De,we){var Le=we.length<0?0:0|oe(we.length);De=te(De,Le);for(var Ue=0;Ue<Le;Ue+=1)De[Ue]=255&we[Ue];return De}function re(De,we,Le,Ue){if(we.byteLength,Le<0||we.byteLength<Le)throw new RangeError("'offset' is out of bounds");if(we.byteLength<Le+(Ue||0))throw new RangeError("'length' is out of bounds");return we=Le===void 0&&Ue===void 0?new Uint8Array(we):Ue===void 0?new Uint8Array(we,Le):new Uint8Array(we,Le,Ue),le.TYPED_ARRAY_SUPPORT?(De=we,De.__proto__=le.prototype):De=x(De,we),De}function ae(De,we){if(le.isBuffer(we)){var Le=0|oe(we.length);return De=te(De,Le),De.length===0||we.copy(De,0,0,Le),De}if(we){if(typeof ArrayBuffer!="undefined"&&we.buffer instanceof ArrayBuffer||"length"in we)return typeof we.length!="number"||We(we.length)?te(De,0):x(De,we);if(we.type==="Buffer"&&Be(we.data))return x(De,we.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function oe(De){if(De>=se())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+se().toString(16)+" bytes");return 0|De}function ve(De){return+De!=De&&(De=0),le.alloc(+De)}function ye(De,we){if(le.isBuffer(De))return De.length;if(typeof ArrayBuffer!="undefined"&&typeof ArrayBuffer.isView=="function"&&(ArrayBuffer.isView(De)||De instanceof ArrayBuffer))return De.byteLength;typeof De!="string"&&(De=""+De);var Le=De.length;if(Le===0)return 0;for(var Ue=!1;;)switch(we){case"ascii":case"latin1":case"binary":return Le;case"utf8":case"utf-8":case void 0:return dt(De).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*Le;case"hex":return Le>>>1;case"base64":return gt(De).length;default:if(Ue)return dt(De).length;we=(""+we).toLowerCase(),Ue=!0}}function me(De,we,Le){var Ue=!1;if((we===void 0||we<0)&&(we=0),we>this.length||((Le===void 0||Le>this.length)&&(Le=this.length),Le<=0)||(Le>>>=0,we>>>=0,Le<=we))return"";for(De||(De="utf8");;)switch(De){case"hex":return rt(this,we,Le);case"utf8":case"utf-8":return Qe(this,we,Le);case"ascii":return ot(this,we,Le);case"latin1":case"binary":return He(this,we,Le);case"base64":return Pe(this,we,Le);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Ye(this,we,Le);default:if(Ue)throw new TypeError("Unknown encoding: "+De);De=(De+"").toLowerCase(),Ue=!0}}function ge(De,we,Le){var Ue=De[we];De[we]=De[Le],De[Le]=Ue}function _e(De,we,Le,Ue,Me){if(De.length===0)return-1;if(typeof Le=="string"?(Ue=Le,Le=0):Le>2147483647?Le=2147483647:Le<-2147483648&&(Le=-2147483648),Le=+Le,isNaN(Le)&&(Le=Me?0:De.length-1),Le<0&&(Le=De.length+Le),Le>=De.length){if(Me)return-1;Le=De.length-1}else if(Le<0){if(!Me)return-1;Le=0}if(typeof we=="string"&&(we=le.from(we,Ue)),le.isBuffer(we))return we.length===0?-1:he(De,we,Le,Ue,Me);if(typeof we=="number")return we&=255,le.TYPED_ARRAY_SUPPORT&&typeof Uint8Array.prototype.indexOf=="function"?Me?Uint8Array.prototype.indexOf.call(De,we,Le):Uint8Array.prototype.lastIndexOf.call(De,we,Le):he(De,[we],Le,Ue,Me);throw new TypeError("val must be string, number or Buffer")}function he(De,we,Le,Ue,Me){function Re(jt,yt){return tt===1?jt[yt]:jt.readUInt16BE(yt*tt)}var tt=1,lt=De.length,Nt=we.length;if(Ue!==void 0&&((Ue=String(Ue).toLowerCase())==="ucs2"||Ue==="ucs-2"||Ue==="utf16le"||Ue==="utf-16le")){if(De.length<2||we.length<2)return-1;tt=2,lt/=2,Nt/=2,Le/=2}var Ct;if(Me){var vt=-1;for(Ct=Le;Ct<lt;Ct++)if(Re(De,Ct)===Re(we,vt===-1?0:Ct-vt)){if(vt===-1&&(vt=Ct),Ct-vt+1===Nt)return vt*tt}else vt!==-1&&(Ct-=Ct-vt),vt=-1}else for(Le+Nt>lt&&(Le=lt-Nt),Ct=Le;Ct>=0;Ct--){for(var Pt=!0,Ht=0;Ht<Nt;Ht++)if(Re(De,Ct+Ht)!==Re(we,Ht)){Pt=!1;break}if(Pt)return Ct}return-1}function pe(De,we,Le,Ue){Le=Number(Le)||0;var Me=De.length-Le;Ue?(Ue=Number(Ue))>Me&&(Ue=Me):Ue=Me;var Re=we.length;if(Re%2!=0)throw new TypeError("Invalid hex string");Ue>Re/2&&(Ue=Re/2);for(var tt=0;tt<Ue;++tt){var lt=parseInt(we.substr(2*tt,2),16);if(isNaN(lt))return tt;De[Le+tt]=lt}return tt}function ke(De,we,Le,Ue){return _t(dt(we,De.length-Le),De,Le,Ue)}function Te(De,we,Le,Ue){return _t(Rt(we),De,Le,Ue)}function Ee(De,we,Le,Ue){return Te(De,we,Le,Ue)}function Oe(De,we,Le,Ue){return _t(gt(we),De,Le,Ue)}function je(De,we,Le,Ue){return _t(xt(we,De.length-Le),De,Le,Ue)}function Pe(De,we,Le){return we===0&&Le===De.length?Ae.fromByteArray(De):Ae.fromByteArray(De.slice(we,Le))}function Qe(De,we,Le){Le=Math.min(De.length,Le);for(var Ue=[],Me=we;Me<Le;){var Re=De[Me],tt=null,lt=Re>239?4:Re>223?3:Re>191?2:1;if(Me+lt<=Le){var Nt,Ct,vt,Pt;switch(lt){case 1:Re<128&&(tt=Re);break;case 2:Nt=De[Me+1],(192&Nt)==128&&(Pt=(31&Re)<<6|63&Nt)>127&&(tt=Pt);break;case 3:Nt=De[Me+1],Ct=De[Me+2],(192&Nt)==128&&(192&Ct)==128&&(Pt=(15&Re)<<12|(63&Nt)<<6|63&Ct)>2047&&(Pt<55296||Pt>57343)&&(tt=Pt);break;case 4:Nt=De[Me+1],Ct=De[Me+2],vt=De[Me+3],(192&Nt)==128&&(192&Ct)==128&&(192&vt)==128&&(Pt=(15&Re)<<18|(63&Nt)<<12|(63&Ct)<<6|63&vt)>65535&&Pt<1114112&&(tt=Pt)}}tt===null?(tt=65533,lt=1):tt>65535&&(tt-=65536,Ue.push(tt>>>10&1023|55296),tt=56320|1023&tt),Ue.push(tt),Me+=lt}return Xe(Ue)}function Xe(De){var we=De.length;if(we<=Ke)return String.fromCharCode.apply(String,De);for(var Le="",Ue=0;Ue<we;)Le+=String.fromCharCode.apply(String,De.slice(Ue,Ue+=Ke));return Le}function ot(De,we,Le){var Ue="";Le=Math.min(De.length,Le);for(var Me=we;Me<Le;++Me)Ue+=String.fromCharCode(127&De[Me]);return Ue}function He(De,we,Le){var Ue="";Le=Math.min(De.length,Le);for(var Me=we;Me<Le;++Me)Ue+=String.fromCharCode(De[Me]);return Ue}function rt(De,we,Le){var Ue=De.length;(!we||we<0)&&(we=0),(!Le||Le<0||Le>Ue)&&(Le=Ue);for(var Me="",Re=we;Re<Le;++Re)Me+=Ot(De[Re]);return Me}function Ye(De,we,Le){for(var Ue=De.slice(we,Le),Me="",Re=0;Re<Ue.length;Re+=2)Me+=String.fromCharCode(Ue[Re]+256*Ue[Re+1]);return Me}function ut(De,we,Le){if(De%1!=0||De<0)throw new RangeError("offset is not uint");if(De+we>Le)throw new RangeError("Trying to access beyond buffer length")}function Ge(De,we,Le,Ue,Me,Re){if(!le.isBuffer(De))throw new TypeError('"buffer" argument must be a Buffer instance');if(we>Me||we<Re)throw new RangeError('"value" argument is out of bounds');if(Le+Ue>De.length)throw new RangeError("Index out of range")}function ze(De,we,Le,Ue){we<0&&(we=65535+we+1);for(var Me=0,Re=Math.min(De.length-Le,2);Me<Re;++Me)De[Le+Me]=(we&255<<8*(Ue?Me:1-Me))>>>8*(Ue?Me:1-Me)}function Ve(De,we,Le,Ue){we<0&&(we=4294967295+we+1);for(var Me=0,Re=Math.min(De.length-Le,4);Me<Re;++Me)De[Le+Me]=we>>>8*(Ue?Me:3-Me)&255}function $e(De,we,Le,Ue,Me,Re){if(Le+Ue>De.length)throw new RangeError("Index out of range");if(Le<0)throw new RangeError("Index out of range")}function nt(De,we,Le,Ue,Me){return Me||$e(De,we,Le,4,34028234663852886e22,-34028234663852886e22),Se.write(De,we,Le,Ue,23,4),Le+4}function et(De,we,Le,Ue,Me){return Me||$e(De,we,Le,8,17976931348623157e292,-17976931348623157e292),Se.write(De,we,Le,Ue,52,8),Le+8}function pt(De){if(De=ct(De).replace(Ne,""),De.length<2)return"";for(;De.length%4!=0;)De+="=";return De}function ct(De){return De.trim?De.trim():De.replace(/^\s+|\s+$/g,"")}function Ot(De){return De<16?"0"+De.toString(16):De.toString(16)}function dt(De,we){we=we||1/0;for(var Le,Ue=De.length,Me=null,Re=[],tt=0;tt<Ue;++tt){if((Le=De.charCodeAt(tt))>55295&&Le<57344){if(!Me){if(Le>56319){(we-=3)>-1&&Re.push(239,191,189);continue}if(tt+1===Ue){(we-=3)>-1&&Re.push(239,191,189);continue}Me=Le;continue}if(Le<56320){(we-=3)>-1&&Re.push(239,191,189),Me=Le;continue}Le=65536+(Me-55296<<10|Le-56320)}else Me&&(we-=3)>-1&&Re.push(239,191,189);if(Me=null,Le<128){if((we-=1)<0)break;Re.push(Le)}else if(Le<2048){if((we-=2)<0)break;Re.push(Le>>6|192,63&Le|128)}else if(Le<65536){if((we-=3)<0)break;Re.push(Le>>12|224,Le>>6&63|128,63&Le|128)}else{if(!(Le<1114112))throw new Error("Invalid code point");if((we-=4)<0)break;Re.push(Le>>18|240,Le>>12&63|128,Le>>6&63|128,63&Le|128)}}return Re}function Rt(De){for(var we=[],Le=0;Le<De.length;++Le)we.push(255&De.charCodeAt(Le));return we}function xt(De,we){for(var Le,Ue,Me,Re=[],tt=0;tt<De.length&&!((we-=2)<0);++tt)Le=De.charCodeAt(tt),Ue=Le>>8,Me=Le%256,Re.push(Me),Re.push(Ue);return Re}function gt(De){return Ae.toByteArray(pt(De))}function _t(De,we,Le,Ue){for(var Me=0;Me<Ue&&!(Me+Le>=we.length||Me>=De.length);++Me)we[Me+Le]=De[Me];return Me}function We(De){return De!==De}var Ae=Ce(21),Se=Ce(22),Be=Ce(23);ie.Buffer=le,ie.SlowBuffer=ve,ie.INSPECT_MAX_BYTES=50,le.TYPED_ARRAY_SUPPORT=ue.TYPED_ARRAY_SUPPORT!==void 0?ue.TYPED_ARRAY_SUPPORT:function(){try{var De=new Uint8Array(1);return De.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},De.foo()===42&&typeof De.subarray=="function"&&De.subarray(1,1).byteLength===0}catch(we){return!1}}(),ie.kMaxLength=se(),le.poolSize=8192,le._augment=function(De){return De.__proto__=le.prototype,De},le.from=function(De,we,Le){return ee(null,De,we,Le)},le.TYPED_ARRAY_SUPPORT&&(le.prototype.__proto__=Uint8Array.prototype,le.__proto__=Uint8Array,typeof Symbol!="undefined"&&Symbol.species&&le[Symbol.species]===le&&Object.defineProperty(le,Symbol.species,{value:null,configurable:!0})),le.alloc=function(De,we,Le){return E(null,De,we,Le)},le.allocUnsafe=function(De){return b(null,De)},le.allocUnsafeSlow=function(De){return b(null,De)},le.isBuffer=function(De){return!(De==null||!De._isBuffer)},le.compare=function(De,we){if(!le.isBuffer(De)||!le.isBuffer(we))throw new TypeError("Arguments must be Buffers");if(De===we)return 0;for(var Le=De.length,Ue=we.length,Me=0,Re=Math.min(Le,Ue);Me<Re;++Me)if(De[Me]!==we[Me]){Le=De[Me],Ue=we[Me];break}return Le<Ue?-1:Ue<Le?1:0},le.isEncoding=function(De){switch(String(De).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}},le.concat=function(De,we){if(!Be(De))throw new TypeError('"list" argument must be an Array of Buffers');if(De.length===0)return le.alloc(0);var Le;if(we===void 0)for(we=0,Le=0;Le<De.length;++Le)we+=De[Le].length;var Ue=le.allocUnsafe(we),Me=0;for(Le=0;Le<De.length;++Le){var Re=De[Le];if(!le.isBuffer(Re))throw new TypeError('"list" argument must be an Array of Buffers');Re.copy(Ue,Me),Me+=Re.length}return Ue},le.byteLength=ye,le.prototype._isBuffer=!0,le.prototype.swap16=function(){var De=this.length;if(De%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var we=0;we<De;we+=2)ge(this,we,we+1);return this},le.prototype.swap32=function(){var De=this.length;if(De%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var we=0;we<De;we+=4)ge(this,we,we+3),ge(this,we+1,we+2);return this},le.prototype.swap64=function(){var De=this.length;if(De%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var we=0;we<De;we+=8)ge(this,we,we+7),ge(this,we+1,we+6),ge(this,we+2,we+5),ge(this,we+3,we+4);return this},le.prototype.toString=function(){var De=0|this.length;return De===0?"":arguments.length===0?Qe(this,0,De):me.apply(this,arguments)},le.prototype.equals=function(De){if(!le.isBuffer(De))throw new TypeError("Argument must be a Buffer");return this===De||le.compare(this,De)===0},le.prototype.inspect=function(){var De="",we=ie.INSPECT_MAX_BYTES;return this.length>0&&(De=this.toString("hex",0,we).match(/.{2}/g).join(" "),this.length>we&&(De+=" ... ")),"<Buffer "+De+">"},le.prototype.compare=function(De,we,Le,Ue,Me){if(!le.isBuffer(De))throw new TypeError("Argument must be a Buffer");if(we===void 0&&(we=0),Le===void 0&&(Le=De?De.length:0),Ue===void 0&&(Ue=0),Me===void 0&&(Me=this.length),we<0||Le>De.length||Ue<0||Me>this.length)throw new RangeError("out of range index");if(Ue>=Me&&we>=Le)return 0;if(Ue>=Me)return-1;if(we>=Le)return 1;if(we>>>=0,Le>>>=0,Ue>>>=0,Me>>>=0,this===De)return 0;for(var Re=Me-Ue,tt=Le-we,lt=Math.min(Re,tt),Nt=this.slice(Ue,Me),Ct=De.slice(we,Le),vt=0;vt<lt;++vt)if(Nt[vt]!==Ct[vt]){Re=Nt[vt],tt=Ct[vt];break}return Re<tt?-1:tt<Re?1:0},le.prototype.includes=function(De,we,Le){return this.indexOf(De,we,Le)!==-1},le.prototype.indexOf=function(De,we,Le){return _e(this,De,we,Le,!0)},le.prototype.lastIndexOf=function(De,we,Le){return _e(this,De,we,Le,!1)},le.prototype.write=function(De,we,Le,Ue){if(we===void 0)Ue="utf8",Le=this.length,we=0;else if(Le===void 0&&typeof we=="string")Ue=we,Le=this.length,we=0;else{if(!isFinite(we))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");we|=0,isFinite(Le)?(Le|=0,Ue===void 0&&(Ue="utf8")):(Ue=Le,Le=void 0)}var Me=this.length-we;if((Le===void 0||Le>Me)&&(Le=Me),De.length>0&&(Le<0||we<0)||we>this.length)throw new RangeError("Attempt to write outside buffer bounds");Ue||(Ue="utf8");for(var Re=!1;;)switch(Ue){case"hex":return pe(this,De,we,Le);case"utf8":case"utf-8":return ke(this,De,we,Le);case"ascii":return Te(this,De,we,Le);case"latin1":case"binary":return Ee(this,De,we,Le);case"base64":return Oe(this,De,we,Le);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return je(this,De,we,Le);default:if(Re)throw new TypeError("Unknown encoding: "+Ue);Ue=(""+Ue).toLowerCase(),Re=!0}},le.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var Ke=4096;le.prototype.slice=function(De,we){var Le=this.length;De=~~De,we=we===void 0?Le:~~we,De<0?(De+=Le)<0&&(De=0):De>Le&&(De=Le),we<0?(we+=Le)<0&&(we=0):we>Le&&(we=Le),we<De&&(we=De);var Ue;if(le.TYPED_ARRAY_SUPPORT)Ue=this.subarray(De,we),Ue.__proto__=le.prototype;else{var Me=we-De;Ue=new le(Me,void 0);for(var Re=0;Re<Me;++Re)Ue[Re]=this[Re+De]}return Ue},le.prototype.readUIntLE=function(De,we,Le){De|=0,we|=0,Le||ut(De,we,this.length);for(var Ue=this[De],Me=1,Re=0;++Re<we&&(Me*=256);)Ue+=this[De+Re]*Me;return Ue},le.prototype.readUIntBE=function(De,we,Le){De|=0,we|=0,Le||ut(De,we,this.length);for(var Ue=this[De+--we],Me=1;we>0&&(Me*=256);)Ue+=this[De+--we]*Me;return Ue},le.prototype.readUInt8=function(De,we){return we||ut(De,1,this.length),this[De]},le.prototype.readUInt16LE=function(De,we){return we||ut(De,2,this.length),this[De]|this[De+1]<<8},le.prototype.readUInt16BE=function(De,we){return we||ut(De,2,this.length),this[De]<<8|this[De+1]},le.prototype.readUInt32LE=function(De,we){return we||ut(De,4,this.length),(this[De]|this[De+1]<<8|this[De+2]<<16)+16777216*this[De+3]},le.prototype.readUInt32BE=function(De,we){return we||ut(De,4,this.length),16777216*this[De]+(this[De+1]<<16|this[De+2]<<8|this[De+3])},le.prototype.readIntLE=function(De,we,Le){De|=0,we|=0,Le||ut(De,we,this.length);for(var Ue=this[De],Me=1,Re=0;++Re<we&&(Me*=256);)Ue+=this[De+Re]*Me;return Me*=128,Ue>=Me&&(Ue-=Math.pow(2,8*we)),Ue},le.prototype.readIntBE=function(De,we,Le){De|=0,we|=0,Le||ut(De,we,this.length);for(var Ue=we,Me=1,Re=this[De+--Ue];Ue>0&&(Me*=256);)Re+=this[De+--Ue]*Me;return Me*=128,Re>=Me&&(Re-=Math.pow(2,8*we)),Re},le.prototype.readInt8=function(De,we){return we||ut(De,1,this.length),128&this[De]?-1*(255-this[De]+1):this[De]},le.prototype.readInt16LE=function(De,we){we||ut(De,2,this.length);var Le=this[De]|this[De+1]<<8;return 32768&Le?4294901760|Le:Le},le.prototype.readInt16BE=function(De,we){we||ut(De,2,this.length);var Le=this[De+1]|this[De]<<8;return 32768&Le?4294901760|Le:Le},le.prototype.readInt32LE=function(De,we){return we||ut(De,4,this.length),this[De]|this[De+1]<<8|this[De+2]<<16|this[De+3]<<24},le.prototype.readInt32BE=function(De,we){return we||ut(De,4,this.length),this[De]<<24|this[De+1]<<16|this[De+2]<<8|this[De+3]},le.prototype.readFloatLE=function(De,we){return we||ut(De,4,this.length),Se.read(this,De,!0,23,4)},le.prototype.readFloatBE=function(De,we){return we||ut(De,4,this.length),Se.read(this,De,!1,23,4)},le.prototype.readDoubleLE=function(De,we){return we||ut(De,8,this.length),Se.read(this,De,!0,52,8)},le.prototype.readDoubleBE=function(De,we){return we||ut(De,8,this.length),Se.read(this,De,!1,52,8)},le.prototype.writeUIntLE=function(De,we,Le,Ue){De=+De,we|=0,Le|=0,!Ue&&Ge(this,De,we,Le,Math.pow(2,8*Le)-1,0);var Me=1,Re=0;for(this[we]=255&De;++Re<Le&&(Me*=256);)this[we+Re]=De/Me&255;return we+Le},le.prototype.writeUIntBE=function(De,we,Le,Ue){De=+De,we|=0,Le|=0,!Ue&&Ge(this,De,we,Le,Math.pow(2,8*Le)-1,0);var Me=Le-1,Re=1;for(this[we+Me]=255&De;--Me>=0&&(Re*=256);)this[we+Me]=De/Re&255;return we+Le},le.prototype.writeUInt8=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,1,255,0),le.TYPED_ARRAY_SUPPORT||(De=Math.floor(De)),this[we]=255&De,we+1},le.prototype.writeUInt16LE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,2,65535,0),le.TYPED_ARRAY_SUPPORT?(this[we]=255&De,this[we+1]=De>>>8):ze(this,De,we,!0),we+2},le.prototype.writeUInt16BE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,2,65535,0),le.TYPED_ARRAY_SUPPORT?(this[we]=De>>>8,this[we+1]=255&De):ze(this,De,we,!1),we+2},le.prototype.writeUInt32LE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,4,4294967295,0),le.TYPED_ARRAY_SUPPORT?(this[we+3]=De>>>24,this[we+2]=De>>>16,this[we+1]=De>>>8,this[we]=255&De):Ve(this,De,we,!0),we+4},le.prototype.writeUInt32BE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,4,4294967295,0),le.TYPED_ARRAY_SUPPORT?(this[we]=De>>>24,this[we+1]=De>>>16,this[we+2]=De>>>8,this[we+3]=255&De):Ve(this,De,we,!1),we+4},le.prototype.writeIntLE=function(De,we,Le,Ue){if(De=+De,we|=0,!Ue){var Me=Math.pow(2,8*Le-1);Ge(this,De,we,Le,Me-1,-Me)}var Re=0,tt=1,lt=0;for(this[we]=255&De;++Re<Le&&(tt*=256);)De<0&<===0&&this[we+Re-1]!==0&&(lt=1),this[we+Re]=(De/tt>>0)-lt&255;return we+Le},le.prototype.writeIntBE=function(De,we,Le,Ue){if(De=+De,we|=0,!Ue){var Me=Math.pow(2,8*Le-1);Ge(this,De,we,Le,Me-1,-Me)}var Re=Le-1,tt=1,lt=0;for(this[we+Re]=255&De;--Re>=0&&(tt*=256);)De<0&<===0&&this[we+Re+1]!==0&&(lt=1),this[we+Re]=(De/tt>>0)-lt&255;return we+Le},le.prototype.writeInt8=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,1,127,-128),le.TYPED_ARRAY_SUPPORT||(De=Math.floor(De)),De<0&&(De=255+De+1),this[we]=255&De,we+1},le.prototype.writeInt16LE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,2,32767,-32768),le.TYPED_ARRAY_SUPPORT?(this[we]=255&De,this[we+1]=De>>>8):ze(this,De,we,!0),we+2},le.prototype.writeInt16BE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,2,32767,-32768),le.TYPED_ARRAY_SUPPORT?(this[we]=De>>>8,this[we+1]=255&De):ze(this,De,we,!1),we+2},le.prototype.writeInt32LE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,4,2147483647,-2147483648),le.TYPED_ARRAY_SUPPORT?(this[we]=255&De,this[we+1]=De>>>8,this[we+2]=De>>>16,this[we+3]=De>>>24):Ve(this,De,we,!0),we+4},le.prototype.writeInt32BE=function(De,we,Le){return De=+De,we|=0,Le||Ge(this,De,we,4,2147483647,-2147483648),De<0&&(De=4294967295+De+1),le.TYPED_ARRAY_SUPPORT?(this[we]=De>>>24,this[we+1]=De>>>16,this[we+2]=De>>>8,this[we+3]=255&De):Ve(this,De,we,!1),we+4},le.prototype.writeFloatLE=function(De,we,Le){return nt(this,De,we,!0,Le)},le.prototype.writeFloatBE=function(De,we,Le){return nt(this,De,we,!1,Le)},le.prototype.writeDoubleLE=function(De,we,Le){return et(this,De,we,!0,Le)},le.prototype.writeDoubleBE=function(De,we,Le){return et(this,De,we,!1,Le)},le.prototype.copy=function(De,we,Le,Ue){if(Le||(Le=0),Ue||Ue===0||(Ue=this.length),we>=De.length&&(we=De.length),we||(we=0),Ue>0&&Ue<Le&&(Ue=Le),Ue===Le||De.length===0||this.length===0)return 0;if(we<0)throw new RangeError("targetStart out of bounds");if(Le<0||Le>=this.length)throw new RangeError("sourceStart out of bounds");if(Ue<0)throw new RangeError("sourceEnd out of bounds");Ue>this.length&&(Ue=this.length),De.length-we<Ue-Le&&(Ue=De.length-we+Le);var Me,Re=Ue-Le;if(this===De&&Le<we&&we<Ue)for(Me=Re-1;Me>=0;--Me)De[Me+we]=this[Me+Le];else if(Re<1e3||!le.TYPED_ARRAY_SUPPORT)for(Me=0;Me<Re;++Me)De[Me+we]=this[Me+Le];else Uint8Array.prototype.set.call(De,this.subarray(Le,Le+Re),we);return Re},le.prototype.fill=function(De,we,Le,Ue){if(typeof De=="string"){if(typeof we=="string"?(Ue=we,we=0,Le=this.length):typeof Le=="string"&&(Ue=Le,Le=this.length),De.length===1){var Me=De.charCodeAt(0);Me<256&&(De=Me)}if(Ue!==void 0&&typeof Ue!="string")throw new TypeError("encoding must be a string");if(typeof Ue=="string"&&!le.isEncoding(Ue))throw new TypeError("Unknown encoding: "+Ue)}else typeof De=="number"&&(De&=255);if(we<0||this.length<we||this.length<Le)throw new RangeError("Out of range index");if(Le<=we)return this;we>>>=0,Le=Le===void 0?this.length:Le>>>0,De||(De=0);var Re;if(typeof De=="number")for(Re=we;Re<Le;++Re)this[Re]=De;else{var tt=le.isBuffer(De)?De:dt(new le(De,Ue).toString()),lt=tt.length;for(Re=0;Re<Le-we;++Re)this[Re+we]=tt[Re%lt]}return this};var Ne=/[^+\/0-9A-Za-z-_]/g}).call(ie,Ce(20))},function(ce,ie){var Ce;Ce=function(){return this}();try{Ce=Ce||Function("return this")()||(0,eval)("this")}catch(ue){typeof window=="object"&&(Ce=window)}ce.exports=Ce},function(ce,ie,Ce){"use strict";function ue(oe){var ve=oe.length;if(ve%4>0)throw new Error("Invalid string. Length must be a multiple of 4");return oe[ve-2]==="="?2:oe[ve-1]==="="?1:0}function se(oe){return 3*oe.length/4-ue(oe)}function te(oe){var ve,ye,me,ge,_e,he=oe.length;ge=ue(oe),_e=new z(3*he/4-ge),ye=ge>0?he-4:he;var pe=0;for(ve=0;ve<ye;ve+=4)me=b[oe.charCodeAt(ve)]<<18|b[oe.charCodeAt(ve+1)]<<12|b[oe.charCodeAt(ve+2)]<<6|b[oe.charCodeAt(ve+3)],_e[pe++]=me>>16&255,_e[pe++]=me>>8&255,_e[pe++]=255&me;return ge===2?(me=b[oe.charCodeAt(ve)]<<2|b[oe.charCodeAt(ve+1)]>>4,_e[pe++]=255&me):ge===1&&(me=b[oe.charCodeAt(ve)]<<10|b[oe.charCodeAt(ve+1)]<<4|b[oe.charCodeAt(ve+2)]>>2,_e[pe++]=me>>8&255,_e[pe++]=255&me),_e}function le(oe){return E[oe>>18&63]+E[oe>>12&63]+E[oe>>6&63]+E[63&oe]}function ee(oe,ve,ye){for(var me,ge=[],_e=ve;_e<ye;_e+=3)me=(oe[_e]<<16)+(oe[_e+1]<<8)+oe[_e+2],ge.push(le(me));return ge.join("")}function ne(oe){for(var ve,ye=oe.length,me=ye%3,ge="",_e=[],he=0,pe=ye-me;he<pe;he+=16383)_e.push(ee(oe,he,he+16383>pe?pe:he+16383));return me===1?(ve=oe[ye-1],ge+=E[ve>>2],ge+=E[ve<<4&63],ge+="=="):me===2&&(ve=(oe[ye-2]<<8)+oe[ye-1],ge+=E[ve>>10],ge+=E[ve>>4&63],ge+=E[ve<<2&63],ge+="="),_e.push(ge),_e.join("")}ie.byteLength=se,ie.toByteArray=te,ie.fromByteArray=ne;for(var E=[],b=[],z=typeof Uint8Array!="undefined"?Uint8Array:Array,x="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",re=0,ae=x.length;re<ae;++re)E[re]=x[re],b[x.charCodeAt(re)]=re;b[45]=62,b[95]=63},function(ce,ie){ie.read=function(Ce,ue,se,te,le){var ee,ne,E=8*le-te-1,b=(1<<E)-1,z=b>>1,x=-7,re=se?le-1:0,ae=se?-1:1,oe=Ce[ue+re];for(re+=ae,ee=oe&(1<<-x)-1,oe>>=-x,x+=E;x>0;ee=256*ee+Ce[ue+re],re+=ae,x-=8);for(ne=ee&(1<<-x)-1,ee>>=-x,x+=te;x>0;ne=256*ne+Ce[ue+re],re+=ae,x-=8);if(ee===0)ee=1-z;else{if(ee===b)return ne?NaN:1/0*(oe?-1:1);ne+=Math.pow(2,te),ee-=z}return(oe?-1:1)*ne*Math.pow(2,ee-te)},ie.write=function(Ce,ue,se,te,le,ee){var ne,E,b,z=8*ee-le-1,x=(1<<z)-1,re=x>>1,ae=le===23?Math.pow(2,-24)-Math.pow(2,-77):0,oe=te?0:ee-1,ve=te?1:-1,ye=ue<0||ue===0&&1/ue<0?1:0;for(ue=Math.abs(ue),isNaN(ue)||ue===1/0?(E=isNaN(ue)?1:0,ne=x):(ne=Math.floor(Math.log(ue)/Math.LN2),ue*(b=Math.pow(2,-ne))<1&&(ne--,b*=2),ue+=ne+re>=1?ae/b:ae*Math.pow(2,1-re),ue*b>=2&&(ne++,b/=2),ne+re>=x?(E=0,ne=x):ne+re>=1?(E=(ue*b-1)*Math.pow(2,le),ne+=re):(E=ue*Math.pow(2,re-1)*Math.pow(2,le),ne=0));le>=8;Ce[se+oe]=255&E,oe+=ve,E/=256,le-=8);for(ne=ne<<le|E,z+=le;z>0;Ce[se+oe]=255&ne,oe+=ve,ne/=256,z-=8);Ce[se+oe-ve]|=128*ye}},function(ce,ie){var Ce={}.toString;ce.exports=Array.isArray||function(ue){return Ce.call(ue)=="[object Array]"}},function(ce,ie,Ce){"use strict";function ue(le,ee){if(!(le instanceof ee))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}(),te=function(){function le(){ue(this,le)}return se(le,null,[{key:"set",value:function(ee,ne){try{window.localStorage&&localStorage.setItem(ee,ne)}catch(E){window[ee+"_localStorage"]=ne}}},{key:"get",value:function(ee){try{if(window.localStorage)return localStorage.getItem(ee)}catch(ne){return window[ee+"_localStorage"]}return""}},{key:"remove",value:function(ee){try{window.localStorage&&localStorage.removeItem(ee)}catch(ne){delete window[ee+"_localStorage"]}}}]),le}();ie.default=te},function(ce,ie,Ce){"use strict";function ue(le,ee){if(!(le instanceof ee))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function le(ee,ne){for(var E=0;E<ne.length;E++){var b=ne[E];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(ee,b.key,b)}}return function(ee,ne,E){return ne&&le(ee.prototype,ne),E&&le(ee,E),ee}}(),te=function(){function le(){ue(this,le)}return se(le,null,[{key:"get",value:function(ee){for(var ne=ee+"",E=document.cookie.split(";"),b=0;b<E.length;b++){var z=E[b].trim();if(z.indexOf(ne)==0)return unescape(z.substring(ne.length+1,z.length))}return""}},{key:"set",value:function(ee,ne,E){var b=new Date;b.setTime(b.getTime()+24*E*60*60*1e3);var z="expires="+b.toGMTString();document.cookie=ee+"="+escape(ne)+"; "+z}}]),le}();ie.default=te},function(ce,ie,Ce){"use strict";function ue(z){return z&&z.__esModule?z:{default:z}}function se(z,x){if(!(z instanceof x))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var te=function(){function z(x,re){for(var ae=0;ae<re.length;ae++){var oe=re[ae];oe.enumerable=oe.enumerable||!1,oe.configurable=!0,"value"in oe&&(oe.writable=!0),Object.defineProperty(x,oe.key,oe)}}return function(x,re,ae){return re&&z(x.prototype,re),ae&&z(x,ae),x}}(),le=Ce(8),ee=ue(le),ne=Ce(9),E=ue(ne),b=function(){function z(){se(this,z)}return te(z,null,[{key:"refreshUploadAuth",value:function(x,re,ae){var oe=(E.default.randomUUID(),E.default.randomUUID()),ve={AccessKeyId:x.accessKeyId,SecurityToken:x.securityToken,Action:"RefreshUploadVideo",VideoId:x.videoId,Version:"2017-03-21",Format:"JSON",SignatureMethod:"HMAC-SHA1",SignatureVersion:"1.0",SignatureNonce:oe,RequestId:x.requestId},ye=E.default.makeUTF8sort(ve,"=","&")+"&Signature="+E.default.aliyunEncodeURI(E.default.makeChangeSiga(ve,x.accessKeySecret)),me="https://vod."+x.region+".aliyuncs.com/?"+ye;ee.default.get(me,function(_e){var _e=JSON.parse(_e);re&&re(_e)},function(ge){if(ae){var _e=JSON.parse(ge);ae(_e)}})}},{key:"getUploadAuth",value:function(x,re,ae){var oe=(E.default.randomUUID(),E.default.randomUUID()),ve={AccessKeyId:x.accessKeyId,SecurityToken:x.securityToken,Action:"CreateUploadVideo",Title:x.title,FileName:x.fileName,Version:"2017-03-21",Format:"JSON",SignatureMethod:"HMAC-SHA1",SignatureVersion:"1.0",SignatureNonce:oe,RequestId:x.requestId};x.fileSize&&(ve.FileSize=x.fileSize),x.description&&(ve.Description=x.description),x.cateId&&(ve.CateId=x.cateId),x.tags&&(ve.Tags=x.tags),x.templateGroupId&&(ve.TemplateGroupId=x.templateGroupId),x.storageLocation&&(ve.StorageLocation=x.storageLocation),x.coverUrl&&(ve.CoverURL=x.coverUrl),x.transCodeMode&&(ve.TransCodeMode=x.transCodeMode),x.userData&&(ve.UserData=JSON.stringify(x.userData));var ye=E.default.makeUTF8sort(ve,"=","&")+"&Signature="+E.default.aliyunEncodeURI(E.default.makeChangeSiga(ve,x.accessKeySecret)),me="https://vod."+x.region+".aliyuncs.com/?"+ye;ee.default.get(me,function(ge){try{ge=JSON.parse(ge)}catch(_e){if(ae)return void ae({Code:"GetUploadAuthFailed",Message:"\u83B7\u53D6uploadauth\u5931\u8D25"})}re&&re(ge)},function(ge){if(ae){var _e={Code:"GetUploadAuthFailed",Message:"\u83B7\u53D6uploadauth\u5931\u8D25"};try{_e=JSON.parse(ge)}catch(he){}ae(_e)}})}},{key:"getImageUploadAuth",value:function(x,re,ae){var oe=(E.default.randomUUID(),E.default.randomUUID()),ve={AccessKeyId:x.accessKeyId,SecurityToken:x.securityToken,Action:"CreateUploadImage",ImageType:x.imageType?x.imageType:"default",Version:"2017-03-21",Format:"JSON",SignatureMethod:"HMAC-SHA1",SignatureVersion:"1.0",SignatureNonce:oe,RequestId:x.requestId};x.title&&(ve.Title=x.title),x.imageExt&&(ve.ImageExt=x.imageExt),x.tags&&(ve.Tags=x.tags),x.storageLocation&&(ve.StorageLocation=x.storageLocation);var ye=E.default.makeUTF8sort(ve,"=","&")+"&Signature="+E.default.aliyunEncodeURI(E.default.makeChangeSiga(ve,x.accessKeySecret)),me="https://vod."+x.region+".aliyuncs.com/?"+ye;ee.default.get(me,function(ge){ge=JSON.parse(ge),re&&re(ge)},function(ge){if(ae){var _e=JSON.parse(ge);ae(_e)}})}}]),z}();ie.default=b},function(ce,ie,Ce){(function(ue,se,te){ce.exports=ie=se(Ce(0),Ce(28),Ce(29))})(0,function(ue){return ue.HmacSHA1})},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){return function(){var se=ue,te=se.lib,le=te.WordArray,ee=te.Hasher,ne=se.algo,E=[],b=ne.SHA1=ee.extend({_doReset:function(){this._hash=new le.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(z,x){for(var re=this._hash.words,ae=re[0],oe=re[1],ve=re[2],ye=re[3],me=re[4],ge=0;ge<80;ge++){if(ge<16)E[ge]=0|z[x+ge];else{var _e=E[ge-3]^E[ge-8]^E[ge-14]^E[ge-16];E[ge]=_e<<1|_e>>>31}var he=(ae<<5|ae>>>27)+me+E[ge];he+=ge<20?1518500249+(oe&ve|~oe&ye):ge<40?1859775393+(oe^ve^ye):ge<60?(oe&ve|oe&ye|ve&ye)-1894007588:(oe^ve^ye)-899497514,me=ye,ye=ve,ve=oe<<30|oe>>>2,oe=ae,ae=he}re[0]=re[0]+ae|0,re[1]=re[1]+oe|0,re[2]=re[2]+ve|0,re[3]=re[3]+ye|0,re[4]=re[4]+me|0},_doFinalize:function(){var z=this._data,x=z.words,re=8*this._nDataBytes,ae=8*z.sigBytes;return x[ae>>>5]|=128<<24-ae%32,x[14+(ae+64>>>9<<4)]=Math.floor(re/4294967296),x[15+(ae+64>>>9<<4)]=re,z.sigBytes=4*x.length,this._process(),this._hash},clone:function(){var z=ee.clone.call(this);return z._hash=this._hash.clone(),z}});se.SHA1=ee._createHelper(b),se.HmacSHA1=ee._createHmacHelper(b)}(),ue.SHA1})},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){(function(){var se=ue,te=se.lib,le=te.Base,ee=se.enc,ne=ee.Utf8,E=se.algo;E.HMAC=le.extend({init:function(b,z){b=this._hasher=new b.init,typeof z=="string"&&(z=ne.parse(z));var x=b.blockSize,re=4*x;z.sigBytes>re&&(z=b.finalize(z)),z.clamp();for(var ae=this._oKey=z.clone(),oe=this._iKey=z.clone(),ve=ae.words,ye=oe.words,me=0;me<x;me++)ve[me]^=1549556828,ye[me]^=909522486;ae.sigBytes=oe.sigBytes=re,this.reset()},reset:function(){var b=this._hasher;b.reset(),b.update(this._iKey)},update:function(b){return this._hasher.update(b),this},finalize:function(b){var z=this._hasher,x=z.finalize(b);return z.reset(),z.finalize(this._oKey.clone().concat(x))}})})()})},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){return function(){function se(E,b,z){for(var x=[],re=0,ae=0;ae<b;ae++)if(ae%4){var oe=z[E.charCodeAt(ae-1)]<<ae%4*2,ve=z[E.charCodeAt(ae)]>>>6-ae%4*2;x[re>>>2]|=(oe|ve)<<24-re%4*8,re++}return ee.create(x,re)}var te=ue,le=te.lib,ee=le.WordArray,ne=te.enc;ne.Base64={stringify:function(E){var b=E.words,z=E.sigBytes,x=this._map;E.clamp();for(var re=[],ae=0;ae<z;ae+=3)for(var oe=b[ae>>>2]>>>24-ae%4*8&255,ve=b[ae+1>>>2]>>>24-(ae+1)%4*8&255,ye=b[ae+2>>>2]>>>24-(ae+2)%4*8&255,me=oe<<16|ve<<8|ye,ge=0;ge<4&&ae+.75*ge<z;ge++)re.push(x.charAt(me>>>6*(3-ge)&63));var _e=x.charAt(64);if(_e)for(;re.length%4;)re.push(_e);return re.join("")},parse:function(E){var b=E.length,z=this._map,x=this._reverseMap;if(!x){x=this._reverseMap=[];for(var re=0;re<z.length;re++)x[z.charCodeAt(re)]=re}var ae=z.charAt(64);if(ae){var oe=E.indexOf(ae);oe!==-1&&(b=oe)}return se(E,b,x)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),ue.enc.Base64})},function(ce,ie,Ce){"use strict";function ue(pe){return pe&&pe.__esModule?pe:{default:pe}}function se(pe,ke){if(!(pe instanceof ke))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var te=function(){function pe(ke,Te){for(var Ee=0;Ee<Te.length;Ee++){var Oe=Te[Ee];Oe.enumerable=Oe.enumerable||!1,Oe.configurable=!0,"value"in Oe&&(Oe.writable=!0),Object.defineProperty(ke,Oe.key,Oe)}}return function(ke,Te,Ee){return Te&&pe(ke.prototype,Te),Ee&&pe(ke,Ee),ke}}(),le=Ce(8),ee=ue(le),ne=Ce(7),E=ue(ne),b=Ce(4),z=ue(b),x=Ce(6),re=ue(x),ae=Ce(1),oe=ue(ae),ve=Ce(9),ye=ue(ve),me=Ce(2),ge=Ce(11),_e=Ce(10),he=function(){function pe(){se(this,pe)}return te(pe,null,[{key:"getAuthInfo",value:function(ke,Te,Ee){var Oe=ke+"|f#Ylm&^1TppeRhLg|"+Ee;return Te&&(Oe=ke+"|"+Te+"|f#Ylm&^1TppeRhLg|"+Ee),me(_e.parse(Oe)).toString(ge)}},{key:"upload",value:function(ke,Te,Ee){var Oe=oe.default.ISODateString(new Date),je=Math.floor(new Date().valueOf()/1e3),Pe=z.default.getClientId();Pe=z.default.setClientId(Pe);var Qe=pe.getAuthInfo(ke.userId,Pe,je),Xe=ye.default.randomUUID(),ot={Source:"WebSDK",BusinessType:"UploadVideo",Action:"ReportUploadProgress",TerminalType:"H5",DeviceModel:E.default.browser.name+(E.default.browser.version||""),AppVersion:re.default.version,AuthTimestamp:je,Timestamp:Oe,AuthInfo:Qe,FileName:ke.file.name,FileSize:ke.file.size,FileCreateTime:ke.file.lastModified,FileHash:ke.fileHash,UploadId:ke.checkpoint.checkpoint.uploadId,PartSize:ke.checkpoint.checkpoint.partSize,DonePartsCount:ke.checkpoint.checkpoint.doneParts.length,UploadPoint:JSON.stringify(ke.checkpoint),UploadRatio:ke.checkpoint.loaded,UserId:ke.userId,VideoId:ke.videoId,Version:"2017-03-21",Format:"JSON",SignatureMethod:"HMAC-SHA1",SignatureVersion:"1.0",SignatureNonce:Xe};Pe&&(ot.ClientId=Pe);var He=ye.default.makeUTF8sort(ot,"=","&")+"&Signature="+ye.default.aliyunEncodeURI(ye.default.makeChangeSiga(ot,ke.accessKeySecret)),rt="https://vod."+ke.region+".aliyuncs.com/?"+He;ee.default.get(rt,function(Ye){Te&&Te()},function(Ye){Ye&&(Ee(Ye),console.log(Ye))})}},{key:"get",value:function(ke,Te,Ee){var Oe=oe.default.ISODateString(new Date),je=Math.floor(new Date().valueOf()/1e3),Pe=z.default.getClientId(),Qe=pe.getAuthInfo(ke.userId,Pe,je),Xe=ye.default.randomUUID(),ot={Source:"WebSDK",BusinessType:"UploadVideo",Action:"GetUploadProgress",TerminalType:"H5",DeviceModel:E.default.browser.name+(E.default.browser.version||""),AppVersion:re.default.version,AuthTimestamp:je,Timestamp:Oe,AuthInfo:Qe,UserId:ke.userId,UploadInfoList:JSON.stringify(ke.uploadInfoList),Version:"2017-03-21",Format:"JSON",SignatureMethod:"HMAC-SHA1",SignatureVersion:"1.0",SignatureNonce:Xe};Pe&&(ot.ClientId=Pe);var He=ye.default.makeUTF8sort(ot,"=","&")+"&Signature="+ye.default.aliyunEncodeURI(ye.default.makeChangeSiga(ot,ke.accessKeySecret)),rt="https://vod."+ke.region+".aliyuncs.com/?"+He;ee.default.get(rt,function(Ye){var ut={},Ge=Pe;Ye=Ye?JSON.parse(Ye):{},Ye.UploadProgress&&Ye.UploadProgress.UploadProgressList&&Ye.UploadProgress.UploadProgressList.length>0&&(ut=Ye.UploadProgress.UploadProgressList[0],Ge=ut.ClientId),z.default.setClientId(Ge),Te&&Te(ut)},function(Ye){Ye&&(Ee(Ye),console.log(Ye))})}}]),pe}();ie.default=he},function(ce,ie,Ce){"use strict";function ue(ne,E){if(!(ne instanceof E))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(ie,"__esModule",{value:!0});var se=function(){function ne(E,b){for(var z=0;z<b.length;z++){var x=b[z];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(E,x.key,x)}}return function(E,b,z){return b&&ne(E.prototype,b),z&&ne(E,z),E}}(),te=Ce(2),le=Ce(33),ee=(Ce(11),function(){function ne(){ue(this,ne)}return se(ne,null,[{key:"getMd5",value:function(E,b,z){var x=new FileReader;x.onload=function(oe){try{if(oe&&oe.target){var ve=te(le.parse(oe.target.result)),ye=ve.toString();b(ye)}}catch(me){console.log(me)}},x.onerror=function(oe){console.log(oe),errorCallback(oe)};var re=File.prototype.slice||File.prototype.mozSlice||File.prototype.webkitSlice,ae=re.call(E,0,1024);x.readAsBinaryString(ae)}}]),ne}());ie.default=ee},function(ce,ie,Ce){(function(ue,se){ce.exports=ie=se(Ce(0))})(0,function(ue){return ue.enc.Latin1})}])},99498:function(Xt,Mt,be){(function(ce){ce(be(89780))})(function(ce){ce.defineOption("placeholder","",function(ee,ne,E){var b=E&&E!=ce.Init;if(ne&&!b)ee.on("blur",se),ee.on("change",te),ee.on("swapDoc",te),ce.on(ee.getInputField(),"compositionupdate",ee.state.placeholderCompose=function(){ue(ee)}),te(ee);else if(!ne&&b){ee.off("blur",se),ee.off("change",te),ee.off("swapDoc",te),ce.off(ee.getInputField(),"compositionupdate",ee.state.placeholderCompose),ie(ee);var z=ee.getWrapperElement();z.className=z.className.replace(" CodeMirror-empty","")}ne&&!ee.hasFocus()&&se(ee)});function ie(ee){ee.state.placeholder&&(ee.state.placeholder.parentNode.removeChild(ee.state.placeholder),ee.state.placeholder=null)}function Ce(ee){ie(ee);var ne=ee.state.placeholder=document.createElement("pre");ne.style.cssText="height: 0; overflow: visible",ne.style.direction=ee.getOption("direction"),ne.className="CodeMirror-placeholder CodeMirror-line-like";var E=ee.getOption("placeholder");typeof E=="string"&&(E=document.createTextNode(E)),ne.appendChild(E),ee.display.lineSpace.insertBefore(ne,ee.display.lineSpace.firstChild)}function ue(ee){setTimeout(function(){var ne=!1,E=ee.getInputField();E.nodeName=="TEXTAREA"?ne=!E.value:ee.lineCount()==1&&(ne=!/[^\u200b]/.test(E.querySelector(".CodeMirror-line").textContent)),ne?Ce(ee):ie(ee)},20)}function se(ee){le(ee)&&Ce(ee)}function te(ee){var ne=ee.getWrapperElement(),E=le(ee);ne.className=ne.className.replace(" CodeMirror-empty","")+(E?" CodeMirror-empty":""),E?Ce(ee):ie(ee)}function le(ee){return ee.lineCount()===1&&ee.getLine(0)===""}})},25717:function(Xt,Mt,be){(function(ce){ce(be(89780))})(function(ce){var ie={pairs:`()[]{}''""`,closeBefore:`)]}'":;>`,triples:"",explode:"[]{}"},Ce=ce.Pos;ce.defineOption("autoCloseBrackets",!1,function(ae,oe,ve){ve&&ve!=ce.Init&&(ae.removeKeyMap(se),ae.state.closeBrackets=null),oe&&(te(ue(oe,"pairs")),ae.state.closeBrackets=oe,ae.addKeyMap(se))});function ue(ae,oe){return oe=="pairs"&&typeof ae=="string"?ae:typeof ae=="object"&&ae[oe]!=null?ae[oe]:ie[oe]}var se={Backspace:ne,Enter:E};function te(ae){for(var oe=0;oe<ae.length;oe++){var ve=ae.charAt(oe),ye="'"+ve+"'";se[ye]||(se[ye]=le(ve))}}te(ie.pairs+"`");function le(ae){return function(oe){return z(oe,ae)}}function ee(ae){var oe=ae.state.closeBrackets;if(!oe||oe.override)return oe;var ve=ae.getModeAt(ae.getCursor());return ve.closeBrackets||oe}function ne(ae){var oe=ee(ae);if(!oe||ae.getOption("disableInput"))return ce.Pass;for(var ve=ue(oe,"pairs"),ye=ae.listSelections(),me=0;me<ye.length;me++){if(!ye[me].empty())return ce.Pass;var ge=x(ae,ye[me].head);if(!ge||ve.indexOf(ge)%2!=0)return ce.Pass}for(var me=ye.length-1;me>=0;me--){var _e=ye[me].head;ae.replaceRange("",Ce(_e.line,_e.ch-1),Ce(_e.line,_e.ch+1),"+delete")}}function E(ae){var oe=ee(ae),ve=oe&&ue(oe,"explode");if(!ve||ae.getOption("disableInput"))return ce.Pass;for(var ye=ae.listSelections(),me=0;me<ye.length;me++){if(!ye[me].empty())return ce.Pass;var ge=x(ae,ye[me].head);if(!ge||ve.indexOf(ge)%2!=0)return ce.Pass}ae.operation(function(){var _e=ae.lineSeparator()||`
|
|
|
`;ae.replaceSelection(_e+_e,null),ae.execCommand("goCharLeft"),ye=ae.listSelections();for(var he=0;he<ye.length;he++){var pe=ye[he].head.line;ae.indentLine(pe,null,!0),ae.indentLine(pe+1,null,!0)}})}function b(ae){var oe=ce.cmpPos(ae.anchor,ae.head)>0;return{anchor:new Ce(ae.anchor.line,ae.anchor.ch+(oe?-1:1)),head:new Ce(ae.head.line,ae.head.ch+(oe?1:-1))}}function z(ae,oe){var ve=ee(ae);if(!ve||ae.getOption("disableInput"))return ce.Pass;var ye=ue(ve,"pairs"),me=ye.indexOf(oe);if(me==-1)return ce.Pass;for(var ge=ue(ve,"closeBefore"),_e=ue(ve,"triples"),he=ye.charAt(me+1)==oe,pe=ae.listSelections(),ke=me%2==0,Te,Ee=0;Ee<pe.length;Ee++){var Oe=pe[Ee],je=Oe.head,Pe,Qe=ae.getRange(je,Ce(je.line,je.ch+1));if(ke&&!Oe.empty())Pe="surround";else if((he||!ke)&&Qe==oe)he&&re(ae,je)?Pe="both":_e.indexOf(oe)>=0&&ae.getRange(je,Ce(je.line,je.ch+3))==oe+oe+oe?Pe="skipThree":Pe="skip";else if(he&&je.ch>1&&_e.indexOf(oe)>=0&&ae.getRange(Ce(je.line,je.ch-2),je)==oe+oe){if(je.ch>2&&/\bstring/.test(ae.getTokenTypeAt(Ce(je.line,je.ch-2))))return ce.Pass;Pe="addFour"}else if(he){var Xe=je.ch==0?" ":ae.getRange(Ce(je.line,je.ch-1),je);if(!ce.isWordChar(Qe)&&Xe!=oe&&!ce.isWordChar(Xe))Pe="both";else return ce.Pass}else if(ke&&(Qe.length===0||/\s/.test(Qe)||ge.indexOf(Qe)>-1))Pe="both";else return ce.Pass;if(!Te)Te=Pe;else if(Te!=Pe)return ce.Pass}var ot=me%2?ye.charAt(me-1):oe,He=me%2?oe:ye.charAt(me+1);ae.operation(function(){if(Te=="skip")ae.execCommand("goCharRight");else if(Te=="skipThree")for(var rt=0;rt<3;rt++)ae.execCommand("goCharRight");else if(Te=="surround"){for(var Ye=ae.getSelections(),rt=0;rt<Ye.length;rt++)Ye[rt]=ot+Ye[rt]+He;ae.replaceSelections(Ye,"around"),Ye=ae.listSelections().slice();for(var rt=0;rt<Ye.length;rt++)Ye[rt]=b(Ye[rt]);ae.setSelections(Ye)}else Te=="both"?(ae.replaceSelection(ot+He,null),ae.triggerElectric(ot+He),ae.execCommand("goCharLeft")):Te=="addFour"&&(ae.replaceSelection(ot+ot+ot+ot,"before"),ae.execCommand("goCharRight"))})}function x(ae,oe){var ve=ae.getRange(Ce(oe.line,oe.ch-1),Ce(oe.line,oe.ch+1));return ve.length==2?ve:null}function re(ae,oe){var ve=ae.getTokenAt(Ce(oe.line,oe.ch+1));return/\bstring/.test(ve.type)&&ve.start==oe.ch&&(oe.ch==0||!/\bstring/.test(ae.getTokenTypeAt(oe)))}})},6313:function(Xt,Mt,be){(function(ce){ce(be(89780),be(52730))})(function(ce){ce.defineOption("autoCloseTags",!1,function(ne,E,b){if(b!=ce.Init&&b&&ne.removeKeyMap("autoCloseTags"),!!E){var z={name:"autoCloseTags"};(typeof E!="object"||E.whenClosing!==!1)&&(z["'/'"]=function(x){return te(x)}),(typeof E!="object"||E.whenOpening!==!1)&&(z["'>'"]=function(x){return ue(x)}),ne.addKeyMap(z)}});var ie=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],Ce=["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 ue(ne){if(ne.getOption("disableInput"))return ce.Pass;for(var E=ne.listSelections(),b=[],z=ne.getOption("autoCloseTags"),x=0;x<E.length;x++){if(!E[x].empty())return ce.Pass;var re=E[x].head,ae=ne.getTokenAt(re),oe=ce.innerMode(ne.getMode(),ae.state),ve=oe.state,ye=oe.mode.xmlCurrentTag&&oe.mode.xmlCurrentTag(ve),me=ye&&ye.name;if(!me)return ce.Pass;var ge=oe.mode.configuration=="html",_e=typeof z=="object"&&z.dontCloseTags||ge&&ie,he=typeof z=="object"&&z.indentTags||ge&&Ce;ae.end>re.ch&&(me=me.slice(0,me.length-ae.end+re.ch));var pe=me.toLowerCase();if(!me||ae.type=="string"&&(ae.end!=re.ch||!/[\"\']/.test(ae.string.charAt(ae.string.length-1))||ae.string.length==1)||ae.type=="tag"&&ye.close||ae.string.indexOf("/")==re.ch-ae.start-1||_e&&le(_e,pe)>-1||ee(ne,oe.mode.xmlCurrentContext&&oe.mode.xmlCurrentContext(ve)||[],me,re,!0))return ce.Pass;var ke=typeof z=="object"&&z.emptyTags;if(ke&&le(ke,me)>-1){b[x]={text:"/>",newPos:ce.Pos(re.line,re.ch+2)};continue}var Te=he&&le(he,pe)>-1;b[x]={indent:Te,text:">"+(Te?`
|
|
|
|
|
|
`:"")+"</"+me+">",newPos:Te?ce.Pos(re.line+1,0):ce.Pos(re.line,re.ch+1)}}for(var Ee=typeof z=="object"&&z.dontIndentOnAutoClose,x=E.length-1;x>=0;x--){var Oe=b[x];ne.replaceRange(Oe.text,E[x].head,E[x].anchor,"+insert");var je=ne.listSelections().slice(0);je[x]={head:Oe.newPos,anchor:Oe.newPos},ne.setSelections(je),!Ee&&Oe.indent&&(ne.indentLine(Oe.newPos.line,null,!0),ne.indentLine(Oe.newPos.line+1,null,!0))}}function se(ne,E){for(var b=ne.listSelections(),z=[],x=E?"/":"</",re=ne.getOption("autoCloseTags"),ae=typeof re=="object"&&re.dontIndentOnSlash,oe=0;oe<b.length;oe++){if(!b[oe].empty())return ce.Pass;var ve=b[oe].head,ye=ne.getTokenAt(ve),me=ce.innerMode(ne.getMode(),ye.state),ge=me.state;if(E&&(ye.type=="string"||ye.string.charAt(0)!="<"||ye.start!=ve.ch-1))return ce.Pass;var _e,he=me.mode.name!="xml"&&ne.getMode().name=="htmlmixed";if(he&&me.mode.name=="javascript")_e=x+"script";else if(he&&me.mode.name=="css")_e=x+"style";else{var pe=me.mode.xmlCurrentContext&&me.mode.xmlCurrentContext(ge);if(!pe||pe.length&&ee(ne,pe,pe[pe.length-1],ve))return ce.Pass;_e=x+pe[pe.length-1]}ne.getLine(ve.line).charAt(ye.end)!=">"&&(_e+=">"),z[oe]=_e}if(ne.replaceSelections(z),b=ne.listSelections(),!ae)for(var oe=0;oe<b.length;oe++)(oe==b.length-1||b[oe].head.line<b[oe+1].head.line)&&ne.indentLine(b[oe].head.line)}function te(ne){return ne.getOption("disableInput")?ce.Pass:se(ne,!0)}ce.commands.closeTag=function(ne){return se(ne)};function le(ne,E){if(ne.indexOf)return ne.indexOf(E);for(var b=0,z=ne.length;b<z;++b)if(ne[b]==E)return b;return-1}function ee(ne,E,b,z,x){if(!ce.scanForClosingTag)return!1;var re=Math.min(ne.lastLine()+1,z.line+500),ae=ce.scanForClosingTag(ne,z,null,re);if(!ae||ae.tag!=b)return!1;for(var oe=x?1:0,ve=E.length-1;ve>=0&&E[ve]==b;ve--)++oe;z=ae.to;for(var ve=1;ve<oe;ve++){var ye=ce.scanForClosingTag(ne,z,null,re);if(!ye||ye.tag!=b)return!1;z=ye.to}return!0}})},52730:function(Xt,Mt,be){(function(ce){ce(be(89780))})(function(ce){"use strict";var ie=ce.Pos;function Ce(ve,ye){return ve.line-ye.line||ve.ch-ye.ch}var ue="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",se=ue+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",te=new RegExp("<(/?)(["+ue+"]["+se+"]*)","g");function le(ve,ye,me,ge){this.line=ye,this.ch=me,this.cm=ve,this.text=ve.getLine(ye),this.min=ge?Math.max(ge.from,ve.firstLine()):ve.firstLine(),this.max=ge?Math.min(ge.to-1,ve.lastLine()):ve.lastLine()}function ee(ve,ye){var me=ve.cm.getTokenTypeAt(ie(ve.line,ye));return me&&/\btag\b/.test(me)}function ne(ve){if(!(ve.line>=ve.max))return ve.ch=0,ve.text=ve.cm.getLine(++ve.line),!0}function E(ve){if(!(ve.line<=ve.min))return ve.text=ve.cm.getLine(--ve.line),ve.ch=ve.text.length,!0}function b(ve){for(;;){var ye=ve.text.indexOf(">",ve.ch);if(ye==-1){if(ne(ve))continue;return}if(!ee(ve,ye+1)){ve.ch=ye+1;continue}var me=ve.text.lastIndexOf("/",ye),ge=me>-1&&!/\S/.test(ve.text.slice(me+1,ye));return ve.ch=ye+1,ge?"selfClose":"regular"}}function z(ve){for(;;){var ye=ve.ch?ve.text.lastIndexOf("<",ve.ch-1):-1;if(ye==-1){if(E(ve))continue;return}if(!ee(ve,ye+1)){ve.ch=ye;continue}te.lastIndex=ye,ve.ch=ye;var me=te.exec(ve.text);if(me&&me.index==ye)return me}}function x(ve){for(;;){te.lastIndex=ve.ch;var ye=te.exec(ve.text);if(!ye){if(ne(ve))continue;return}if(!ee(ve,ye.index+1)){ve.ch=ye.index+1;continue}return ve.ch=ye.index+ye[0].length,ye}}function re(ve){for(;;){var ye=ve.ch?ve.text.lastIndexOf(">",ve.ch-1):-1;if(ye==-1){if(E(ve))continue;return}if(!ee(ve,ye+1)){ve.ch=ye;continue}var me=ve.text.lastIndexOf("/",ye),ge=me>-1&&!/\S/.test(ve.text.slice(me+1,ye));return ve.ch=ye+1,ge?"selfClose":"regular"}}function ae(ve,ye){for(var me=[];;){var ge=x(ve),_e,he=ve.line,pe=ve.ch-(ge?ge[0].length:0);if(!ge||!(_e=b(ve)))return;if(_e!="selfClose")if(ge[1]){for(var ke=me.length-1;ke>=0;--ke)if(me[ke]==ge[2]){me.length=ke;break}if(ke<0&&(!ye||ye==ge[2]))return{tag:ge[2],from:ie(he,pe),to:ie(ve.line,ve.ch)}}else me.push(ge[2])}}function oe(ve,ye){for(var me=[];;){var ge=re(ve);if(!ge)return;if(ge=="selfClose"){z(ve);continue}var _e=ve.line,he=ve.ch,pe=z(ve);if(!pe)return;if(pe[1])me.push(pe[2]);else{for(var ke=me.length-1;ke>=0;--ke)if(me[ke]==pe[2]){me.length=ke;break}if(ke<0&&(!ye||ye==pe[2]))return{tag:pe[2],from:ie(ve.line,ve.ch),to:ie(_e,he)}}}}ce.registerHelper("fold","xml",function(ve,ye){for(var me=new le(ve,ye.line,0);;){var ge=x(me);if(!ge||me.line!=ye.line)return;var _e=b(me);if(!_e)return;if(!ge[1]&&_e!="selfClose"){var he=ie(me.line,me.ch),pe=ae(me,ge[2]);return pe&&Ce(pe.from,he)>0?{from:he,to:pe.from}:null}}}),ce.findMatchingTag=function(ve,ye,me){var ge=new le(ve,ye.line,ye.ch,me);if(!(ge.text.indexOf(">")==-1&&ge.text.indexOf("<")==-1)){var _e=b(ge),he=_e&&ie(ge.line,ge.ch),pe=_e&&z(ge);if(!(!_e||!pe||Ce(ge,ye)>0)){var ke={from:ie(ge.line,ge.ch),to:he,tag:pe[2]};return _e=="selfClose"?{open:ke,close:null,at:"open"}:pe[1]?{open:oe(ge,pe[2]),close:ke,at:"close"}:(ge=new le(ve,he.line,he.ch,me),{open:ke,close:ae(ge,pe[2]),at:"open"})}}},ce.findEnclosingTag=function(ve,ye,me,ge){for(var _e=new le(ve,ye.line,ye.ch,me);;){var he=oe(_e,ge);if(!he)break;var pe=new le(ve,ye.line,ye.ch,me),ke=ae(pe,he.tag);if(ke)return{open:he,close:ke}}},ce.scanForClosingTag=function(ve,ye,me,ge){var _e=new le(ve,ye.line,ye.ch,ge?{from:0,to:ge}:null);return ae(_e,me)}})},89780:function(Xt){(function(Mt,be){Xt.exports=be()})(this,function(){"use strict";var Mt=navigator.userAgent,be=navigator.platform,ce=/gecko\/\d/i.test(Mt),ie=/MSIE \d/.test(Mt),Ce=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Mt),ue=/Edge\/(\d+)/.exec(Mt),se=ie||Ce||ue,te=se&&(ie?document.documentMode||6:+(ue||Ce)[1]),le=!ue&&/WebKit\//.test(Mt),ee=le&&/Qt\/\d+\.\d+/.test(Mt),ne=!ue&&/Chrome\//.test(Mt),E=/Opera\//.test(Mt),b=/Apple Computer/.test(navigator.vendor),z=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(Mt),x=/PhantomJS/.test(Mt),re=!ue&&/AppleWebKit/.test(Mt)&&/Mobile\/\w+/.test(Mt),ae=/Android/.test(Mt),oe=re||ae||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(Mt),ve=re||/Mac/.test(be),ye=/\bCrOS\b/.test(Mt),me=/win/i.test(be),ge=E&&Mt.match(/Version\/(\d*\.\d*)/);ge&&(ge=Number(ge[1])),ge&&ge>=15&&(E=!1,le=!0);var _e=ve&&(ee||E&&(ge==null||ge<12.11)),he=ce||se&&te>=9;function pe(a){return new RegExp("(^|\\s)"+a+"(?:$|\\s)\\s*")}var ke=function(a,y){var fe=a.className,de=pe(y).exec(fe);if(de){var xe=fe.slice(de.index+de[0].length);a.className=fe.slice(0,de.index)+(xe?de[1]+xe:"")}};function Te(a){for(var y=a.childNodes.length;y>0;--y)a.removeChild(a.firstChild);return a}function Ee(a,y){return Te(a).appendChild(y)}function Oe(a,y,fe,de){var xe=document.createElement(a);if(fe&&(xe.className=fe),de&&(xe.style.cssText=de),typeof y=="string")xe.appendChild(document.createTextNode(y));else if(y)for(var Fe=0;Fe<y.length;++Fe)xe.appendChild(y[Fe]);return xe}function je(a,y,fe,de){var xe=Oe(a,y,fe,de);return xe.setAttribute("role","presentation"),xe}var Pe;document.createRange?Pe=function(a,y,fe,de){var xe=document.createRange();return xe.setEnd(de||a,fe),xe.setStart(a,y),xe}:Pe=function(a,y,fe){var de=document.body.createTextRange();try{de.moveToElementText(a.parentNode)}catch(xe){return de}return de.collapse(!0),de.moveEnd("character",fe),de.moveStart("character",y),de};function Qe(a,y){if(y.nodeType==3&&(y=y.parentNode),a.contains)return a.contains(y);do if(y.nodeType==11&&(y=y.host),y==a)return!0;while(y=y.parentNode)}function Xe(){var a;try{a=document.activeElement}catch(y){a=document.body||null}for(;a&&a.shadowRoot&&a.shadowRoot.activeElement;)a=a.shadowRoot.activeElement;return a}function ot(a,y){var fe=a.className;pe(y).test(fe)||(a.className+=(fe?" ":"")+y)}function He(a,y){for(var fe=a.split(" "),de=0;de<fe.length;de++)fe[de]&&!pe(fe[de]).test(y)&&(y+=" "+fe[de]);return y}var rt=function(a){a.select()};re?rt=function(a){a.selectionStart=0,a.selectionEnd=a.value.length}:se&&(rt=function(a){try{a.select()}catch(y){}});function Ye(a){var y=Array.prototype.slice.call(arguments,1);return function(){return a.apply(null,y)}}function ut(a,y,fe){y||(y={});for(var de in a)a.hasOwnProperty(de)&&(fe!==!1||!y.hasOwnProperty(de))&&(y[de]=a[de]);return y}function Ge(a,y,fe,de,xe){y==null&&(y=a.search(/[^\s\u00a0]/),y==-1&&(y=a.length));for(var Fe=de||0,Je=xe||0;;){var it=a.indexOf(" ",Fe);if(it<0||it>=y)return Je+(y-Fe);Je+=it-Fe,Je+=fe-Je%fe,Fe=it+1}}var ze=function(){this.id=null,this.f=null,this.time=0,this.handler=Ye(this.onTimeout,this)};ze.prototype.onTimeout=function(a){a.id=0,a.time<=+new Date?a.f():setTimeout(a.handler,a.time-+new Date)},ze.prototype.set=function(a,y){this.f=y;var fe=+new Date+a;(!this.id||fe<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,a),this.time=fe)};function Ve(a,y){for(var fe=0;fe<a.length;++fe)if(a[fe]==y)return fe;return-1}var $e=50,nt={toString:function(){return"CodeMirror.Pass"}},et={scroll:!1},pt={origin:"*mouse"},ct={origin:"+move"};function Ot(a,y,fe){for(var de=0,xe=0;;){var Fe=a.indexOf(" ",de);Fe==-1&&(Fe=a.length);var Je=Fe-de;if(Fe==a.length||xe+Je>=y)return de+Math.min(Je,y-xe);if(xe+=Fe-de,xe+=fe-xe%fe,de=Fe+1,xe>=y)return de}}var dt=[""];function Rt(a){for(;dt.length<=a;)dt.push(xt(dt)+" ");return dt[a]}function xt(a){return a[a.length-1]}function gt(a,y){for(var fe=[],de=0;de<a.length;de++)fe[de]=y(a[de],de);return fe}function _t(a,y,fe){for(var de=0,xe=fe(y);de<a.length&&fe(a[de])<=xe;)de++;a.splice(de,0,y)}function We(){}function Ae(a,y){var fe;return Object.create?fe=Object.create(a):(We.prototype=a,fe=new We),y&&ut(y,fe),fe}var Se=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function Be(a){return/\w/.test(a)||a>"\x80"&&(a.toUpperCase()!=a.toLowerCase()||Se.test(a))}function Ke(a,y){return y?y.source.indexOf("\\w")>-1&&Be(a)?!0:y.test(a):Be(a)}function Ne(a){for(var y in a)if(a.hasOwnProperty(y)&&a[y])return!1;return!0}var De=/[\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 we(a){return a.charCodeAt(0)>=768&&De.test(a)}function Le(a,y,fe){for(;(fe<0?y>0:y<a.length)&&we(a.charAt(y));)y+=fe;return y}function Ue(a,y,fe){for(var de=y>fe?-1:1;;){if(y==fe)return y;var xe=(y+fe)/2,Fe=de<0?Math.ceil(xe):Math.floor(xe);if(Fe==y)return a(Fe)?y:fe;a(Fe)?fe=Fe:y=Fe+de}}function Me(a,y,fe,de){if(!a)return de(y,fe,"ltr",0);for(var xe=!1,Fe=0;Fe<a.length;++Fe){var Je=a[Fe];(Je.from<fe&&Je.to>y||y==fe&&Je.to==y)&&(de(Math.max(Je.from,y),Math.min(Je.to,fe),Je.level==1?"rtl":"ltr",Fe),xe=!0)}xe||de(y,fe,"ltr")}var Re=null;function tt(a,y,fe){var de;Re=null;for(var xe=0;xe<a.length;++xe){var Fe=a[xe];if(Fe.from<y&&Fe.to>y)return xe;Fe.to==y&&(Fe.from!=Fe.to&&fe=="before"?de=xe:Re=xe),Fe.from==y&&(Fe.from!=Fe.to&&fe!="before"?de=xe:Re=xe)}return de!=null?de:Re}var lt=function(){var a="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",y="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function fe(ht){return ht<=247?a.charAt(ht):1424<=ht&&ht<=1524?"R":1536<=ht&&ht<=1785?y.charAt(ht-1536):1774<=ht&&ht<=2220?"r":8192<=ht&&ht<=8203?"w":ht==8204?"b":"L"}var de=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,xe=/[stwN]/,Fe=/[LRr]/,Je=/[Lb1n]/,it=/[1n]/;function at(ht,It,Ut){this.level=ht,this.from=It,this.to=Ut}return function(ht,It){var Ut=It=="ltr"?"L":"R";if(ht.length==0||It=="ltr"&&!de.test(ht))return!1;for(var rn=ht.length,Qt=[],Dn=0;Dn<rn;++Dn)Qt.push(fe(ht.charCodeAt(Dn)));for(var Wn=0,Qn=Ut;Wn<rn;++Wn){var sr=Qt[Wn];sr=="m"?Qt[Wn]=Qn:Qn=sr}for(var vr=0,lr=Ut;vr<rn;++vr){var Er=Qt[vr];Er=="1"&&lr=="r"?Qt[vr]="n":Fe.test(Er)&&(lr=Er,Er=="r"&&(Qt[vr]="R"))}for(var Qr=1,Hr=Qt[0];Qr<rn-1;++Qr){var Li=Qt[Qr];Li=="+"&&Hr=="1"&&Qt[Qr+1]=="1"?Qt[Qr]="1":Li==","&&Hr==Qt[Qr+1]&&(Hr=="1"||Hr=="n")&&(Qt[Qr]=Hr),Hr=Li}for(var to=0;to<rn;++to){var Mo=Qt[to];if(Mo==",")Qt[to]="N";else if(Mo=="%"){var ho=void 0;for(ho=to+1;ho<rn&&Qt[ho]=="%";++ho);for(var sa=to&&Qt[to-1]=="!"||ho<rn&&Qt[ho]=="1"?"1":"N",$o=to;$o<ho;++$o)Qt[$o]=sa;to=ho-1}}for(var So=0,ea=Ut;So<rn;++So){var Bo=Qt[So];ea=="L"&&Bo=="1"?Qt[So]="L":Fe.test(Bo)&&(ea=Bo)}for(var ko=0;ko<rn;++ko)if(xe.test(Qt[ko])){var wo=void 0;for(wo=ko+1;wo<rn&&xe.test(Qt[wo]);++wo);for(var vo=(ko?Qt[ko-1]:Ut)=="L",ta=(wo<rn?Qt[wo]:Ut)=="L",Is=vo==ta?vo?"L":"R":Ut,us=ko;us<wo;++us)Qt[us]=Is;ko=wo-1}for(var zo=[],Ua,Ro=0;Ro<rn;)if(Je.test(Qt[Ro])){var xl=Ro;for(++Ro;Ro<rn&&Je.test(Qt[Ro]);++Ro);zo.push(new at(0,xl,Ro))}else{var Xa=Ro,gs=zo.length,ys=It=="rtl"?1:0;for(++Ro;Ro<rn&&Qt[Ro]!="L";++Ro);for(var Vo=Xa;Vo<Ro;)if(it.test(Qt[Vo])){Xa<Vo&&(zo.splice(gs,0,new at(1,Xa,Vo)),gs+=ys);var Os=Vo;for(++Vo;Vo<Ro&&it.test(Qt[Vo]);++Vo);zo.splice(gs,0,new at(2,Os,Vo)),gs+=ys,Xa=Vo}else++Vo;Xa<Ro&&zo.splice(gs,0,new at(1,Xa,Ro))}return It=="ltr"&&(zo[0].level==1&&(Ua=ht.match(/^\s+/))&&(zo[0].from=Ua[0].length,zo.unshift(new at(0,0,Ua[0].length))),xt(zo).level==1&&(Ua=ht.match(/\s+$/))&&(xt(zo).to-=Ua[0].length,zo.push(new at(0,rn-Ua[0].length,rn)))),It=="rtl"?zo.reverse():zo}}();function Nt(a,y){var fe=a.order;return fe==null&&(fe=a.order=lt(a.text,y)),fe}var Ct=[],vt=function(a,y,fe){if(a.addEventListener)a.addEventListener(y,fe,!1);else if(a.attachEvent)a.attachEvent("on"+y,fe);else{var de=a._handlers||(a._handlers={});de[y]=(de[y]||Ct).concat(fe)}};function Pt(a,y){return a._handlers&&a._handlers[y]||Ct}function Ht(a,y,fe){if(a.removeEventListener)a.removeEventListener(y,fe,!1);else if(a.detachEvent)a.detachEvent("on"+y,fe);else{var de=a._handlers,xe=de&&de[y];if(xe){var Fe=Ve(xe,fe);Fe>-1&&(de[y]=xe.slice(0,Fe).concat(xe.slice(Fe+1)))}}}function jt(a,y){var fe=Pt(a,y);if(fe.length)for(var de=Array.prototype.slice.call(arguments,2),xe=0;xe<fe.length;++xe)fe[xe].apply(null,de)}function yt(a,y,fe){return typeof y=="string"&&(y={type:y,preventDefault:function(){this.defaultPrevented=!0}}),jt(a,fe||y.type,a,y),Vt(y)||y.codemirrorIgnore}function Yt(a){var y=a._handlers&&a._handlers.cursorActivity;if(y)for(var fe=a.curOp.cursorActivityHandlers||(a.curOp.cursorActivityHandlers=[]),de=0;de<y.length;++de)Ve(fe,y[de])==-1&&fe.push(y[de])}function Lt(a,y){return Pt(a,y).length>0}function Kt(a){a.prototype.on=function(y,fe){vt(this,y,fe)},a.prototype.off=function(y,fe){Ht(this,y,fe)}}function sn(a){a.preventDefault?a.preventDefault():a.returnValue=!1}function wn(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0}function Vt(a){return a.defaultPrevented!=null?a.defaultPrevented:a.returnValue==!1}function Rn(a){sn(a),wn(a)}function Gn(a){return a.target||a.srcElement}function Zn(a){var y=a.which;return y==null&&(a.button&1?y=1:a.button&2?y=3:a.button&4&&(y=2)),ve&&a.ctrlKey&&y==1&&(y=3),y}var tr=function(){if(se&&te<9)return!1;var a=Oe("div");return"draggable"in a||"dragDrop"in a}(),hr;function ur(a){if(hr==null){var y=Oe("span","\u200B");Ee(a,Oe("span",[y,document.createTextNode("x")])),a.firstChild.offsetHeight!=0&&(hr=y.offsetWidth<=1&&y.offsetHeight>2&&!(se&&te<8))}var fe=hr?Oe("span","\u200B"):Oe("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return fe.setAttribute("cm-text",""),fe}var zn;function Bn(a){if(zn!=null)return zn;var y=Ee(a,document.createTextNode("A\u062EA")),fe=Pe(y,0,1).getBoundingClientRect(),de=Pe(y,1,2).getBoundingClientRect();return Te(a),!fe||fe.left==fe.right?!1:zn=de.right-fe.right<3}var ir=`
|
|
|
|
|
|
b`.split(/\n/).length!=3?function(a){for(var y=0,fe=[],de=a.length;y<=de;){var xe=a.indexOf(`
|
|
|
`,y);xe==-1&&(xe=a.length);var Fe=a.slice(y,a.charAt(xe-1)=="\r"?xe-1:xe),Je=Fe.indexOf("\r");Je!=-1?(fe.push(Fe.slice(0,Je)),y+=Je+1):(fe.push(Fe),y=xe+1)}return fe}:function(a){return a.split(/\r\n?|\n/)},Kn=window.getSelection?function(a){try{return a.selectionStart!=a.selectionEnd}catch(y){return!1}}:function(a){var y;try{y=a.ownerDocument.selection.createRange()}catch(fe){}return!y||y.parentElement()!=a?!1:y.compareEndPoints("StartToEnd",y)!=0},Nn=function(){var a=Oe("div");return"oncopy"in a?!0:(a.setAttribute("oncopy","return;"),typeof a.oncopy=="function")}(),yn=null;function Hn(a){if(yn!=null)return yn;var y=Ee(a,Oe("span","x")),fe=y.getBoundingClientRect(),de=Pe(y,0,1).getBoundingClientRect();return yn=Math.abs(fe.left-de.left)>1}var dr={},Mn={};function Cn(a,y){arguments.length>2&&(y.dependencies=Array.prototype.slice.call(arguments,2)),dr[a]=y}function $n(a,y){Mn[a]=y}function Jt(a){if(typeof a=="string"&&Mn.hasOwnProperty(a))a=Mn[a];else if(a&&typeof a.name=="string"&&Mn.hasOwnProperty(a.name)){var y=Mn[a.name];typeof y=="string"&&(y={name:y}),a=Ae(y,a),a.name=y.name}else{if(typeof a=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(a))return Jt("application/xml");if(typeof a=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(a))return Jt("application/json")}return typeof a=="string"?{name:a}:a||{name:"null"}}function Ie(a,y){y=Jt(y);var fe=dr[y.name];if(!fe)return Ie(a,"text/plain");var de=fe(a,y);if(Ze.hasOwnProperty(y.name)){var xe=Ze[y.name];for(var Fe in xe)xe.hasOwnProperty(Fe)&&(de.hasOwnProperty(Fe)&&(de["_"+Fe]=de[Fe]),de[Fe]=xe[Fe])}if(de.name=y.name,y.helperType&&(de.helperType=y.helperType),y.modeProps)for(var Je in y.modeProps)de[Je]=y.modeProps[Je];return de}var Ze={};function qe(a,y){var fe=Ze.hasOwnProperty(a)?Ze[a]:Ze[a]={};ut(y,fe)}function st(a,y){if(y===!0)return y;if(a.copyState)return a.copyState(y);var fe={};for(var de in y){var xe=y[de];xe instanceof Array&&(xe=xe.concat([])),fe[de]=xe}return fe}function mt(a,y){for(var fe;a.innerMode&&(fe=a.innerMode(y),!(!fe||fe.mode==a));)y=fe.state,a=fe.mode;return fe||{mode:a,state:y}}function Bt(a,y,fe){return a.startState?a.startState(y,fe):!0}var kt=function(a,y,fe){this.pos=this.start=0,this.string=a,this.tabSize=y||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=fe};kt.prototype.eol=function(){return this.pos>=this.string.length},kt.prototype.sol=function(){return this.pos==this.lineStart},kt.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},kt.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},kt.prototype.eat=function(a){var y=this.string.charAt(this.pos),fe;if(typeof a=="string"?fe=y==a:fe=y&&(a.test?a.test(y):a(y)),fe)return++this.pos,y},kt.prototype.eatWhile=function(a){for(var y=this.pos;this.eat(a););return this.pos>y},kt.prototype.eatSpace=function(){for(var a=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>a},kt.prototype.skipToEnd=function(){this.pos=this.string.length},kt.prototype.skipTo=function(a){var y=this.string.indexOf(a,this.pos);if(y>-1)return this.pos=y,!0},kt.prototype.backUp=function(a){this.pos-=a},kt.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=Ge(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?Ge(this.string,this.lineStart,this.tabSize):0)},kt.prototype.indentation=function(){return Ge(this.string,null,this.tabSize)-(this.lineStart?Ge(this.string,this.lineStart,this.tabSize):0)},kt.prototype.match=function(a,y,fe){if(typeof a=="string"){var de=function(Je){return fe?Je.toLowerCase():Je},xe=this.string.substr(this.pos,a.length);if(de(xe)==de(a))return y!==!1&&(this.pos+=a.length),!0}else{var Fe=this.string.slice(this.pos).match(a);return Fe&&Fe.index>0?null:(Fe&&y!==!1&&(this.pos+=Fe[0].length),Fe)}},kt.prototype.current=function(){return this.string.slice(this.start,this.pos)},kt.prototype.hideFirstChars=function(a,y){this.lineStart+=a;try{return y()}finally{this.lineStart-=a}},kt.prototype.lookAhead=function(a){var y=this.lineOracle;return y&&y.lookAhead(a)},kt.prototype.baseToken=function(){var a=this.lineOracle;return a&&a.baseToken(this.pos)};function Ft(a,y){if(y-=a.first,y<0||y>=a.size)throw new Error("There is no line "+(y+a.first)+" in the document.");for(var fe=a;!fe.lines;)for(var de=0;;++de){var xe=fe.children[de],Fe=xe.chunkSize();if(y<Fe){fe=xe;break}y-=Fe}return fe.lines[y]}function qt(a,y,fe){var de=[],xe=y.line;return a.iter(y.line,fe.line+1,function(Fe){var Je=Fe.text;xe==fe.line&&(Je=Je.slice(0,fe.ch)),xe==y.line&&(Je=Je.slice(y.ch)),de.push(Je),++xe}),de}function En(a,y,fe){var de=[];return a.iter(y,fe,function(xe){de.push(xe.text)}),de}function Yn(a,y){var fe=y-a.height;if(fe)for(var de=a;de;de=de.parent)de.height+=fe}function At(a){if(a.parent==null)return null;for(var y=a.parent,fe=Ve(y.lines,a),de=y.parent;de;y=de,de=de.parent)for(var xe=0;de.children[xe]!=y;++xe)fe+=de.children[xe].chunkSize();return fe+y.first}function St(a,y){var fe=a.first;e:do{for(var de=0;de<a.children.length;++de){var xe=a.children[de],Fe=xe.height;if(y<Fe){a=xe;continue e}y-=Fe,fe+=xe.chunkSize()}return fe}while(!a.lines);for(var Je=0;Je<a.lines.length;++Je){var it=a.lines[Je],at=it.height;if(y<at)break;y-=at}return fe+Je}function an(a,y){return y>=a.first&&y<a.first+a.size}function Wt(a,y){return String(a.lineNumberFormatter(y+a.firstLineNumber))}function Et(a,y,fe){if(fe===void 0&&(fe=null),!(this instanceof Et))return new Et(a,y,fe);this.line=a,this.ch=y,this.sticky=fe}function zt(a,y){return a.line-y.line||a.ch-y.ch}function tn(a,y){return a.sticky==y.sticky&&zt(a,y)==0}function nn(a){return Et(a.line,a.ch)}function gn(a,y){return zt(a,y)<0?y:a}function Sn(a,y){return zt(a,y)<0?a:y}function Tn(a,y){return Math.max(a.first,Math.min(y,a.first+a.size-1))}function Tt(a,y){if(y.line<a.first)return Et(a.first,0);var fe=a.first+a.size-1;return y.line>fe?Et(fe,Ft(a,fe).text.length):jn(y,Ft(a,y.line).text.length)}function jn(a,y){var fe=a.ch;return fe==null||fe>y?Et(a.line,y):fe<0?Et(a.line,0):a}function bn(a,y){for(var fe=[],de=0;de<y.length;de++)fe[de]=Tt(a,y[de]);return fe}var Fn=function(a,y){this.state=a,this.lookAhead=y},Un=function(a,y,fe,de){this.state=y,this.doc=a,this.line=fe,this.maxLookAhead=de||0,this.baseTokens=null,this.baseTokenPos=1};Un.prototype.lookAhead=function(a){var y=this.doc.getLine(this.line+a);return y!=null&&a>this.maxLookAhead&&(this.maxLookAhead=a),y},Un.prototype.baseToken=function(a){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=a;)this.baseTokenPos+=2;var y=this.baseTokens[this.baseTokenPos+1];return{type:y&&y.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-a}},Un.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},Un.fromSaved=function(a,y,fe){return y instanceof Fn?new Un(a,st(a.mode,y.state),fe,y.lookAhead):new Un(a,st(a.mode,y),fe)},Un.prototype.save=function(a){var y=a!==!1?st(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new Fn(y,this.maxLookAhead):y};function rr(a,y,fe,de){var xe=[a.state.modeGen],Fe={};ti(a,y.text,a.doc.mode,fe,function(ht,It){return xe.push(ht,It)},Fe,de);for(var Je=fe.state,it=function(ht){fe.baseTokens=xe;var It=a.state.overlays[ht],Ut=1,rn=0;fe.state=!0,ti(a,y.text,It.mode,fe,function(Qt,Dn){for(var Wn=Ut;rn<Qt;){var Qn=xe[Ut];Qn>Qt&&xe.splice(Ut,1,Qt,xe[Ut+1],Qn),Ut+=2,rn=Math.min(Qt,Qn)}if(Dn)if(It.opaque)xe.splice(Wn,Ut-Wn,Qt,"overlay "+Dn),Ut=Wn+2;else for(;Wn<Ut;Wn+=2){var sr=xe[Wn+1];xe[Wn+1]=(sr?sr+" ":"")+"overlay "+Dn}},Fe),fe.state=Je,fe.baseTokens=null,fe.baseTokenPos=1},at=0;at<a.state.overlays.length;++at)it(at);return{styles:xe,classes:Fe.bgClass||Fe.textClass?Fe:null}}function pr(a,y,fe){if(!y.styles||y.styles[0]!=a.state.modeGen){var de=Rr(a,At(y)),xe=y.text.length>a.options.maxHighlightLength&&st(a.doc.mode,de.state),Fe=rr(a,y,de);xe&&(de.state=xe),y.stateAfter=de.save(!xe),y.styles=Fe.styles,Fe.classes?y.styleClasses=Fe.classes:y.styleClasses&&(y.styleClasses=null),fe===a.doc.highlightFrontier&&(a.doc.modeFrontier=Math.max(a.doc.modeFrontier,++a.doc.highlightFrontier))}return y.styles}function Rr(a,y,fe){var de=a.doc,xe=a.display;if(!de.mode.startState)return new Un(de,!0,y);var Fe=di(a,y,fe),Je=Fe>de.first&&Ft(de,Fe-1).stateAfter,it=Je?Un.fromSaved(de,Je,Fe):new Un(de,Bt(de.mode),Fe);return de.iter(Fe,y,function(at){wr(a,at.text,it);var ht=it.line;at.stateAfter=ht==y-1||ht%5==0||ht>=xe.viewFrom&&ht<xe.viewTo?it.save():null,it.nextLine()}),fe&&(de.modeFrontier=it.line),it}function wr(a,y,fe,de){var xe=a.doc.mode,Fe=new kt(y,a.options.tabSize,fe);for(Fe.start=Fe.pos=de||0,y==""&&Lr(xe,fe.state);!Fe.eol();)Vr(xe,Fe,fe.state),Fe.start=Fe.pos}function Lr(a,y){if(a.blankLine)return a.blankLine(y);if(a.innerMode){var fe=mt(a,y);if(fe.mode.blankLine)return fe.mode.blankLine(fe.state)}}function Vr(a,y,fe,de){for(var xe=0;xe<10;xe++){de&&(de[0]=mt(a,fe).mode);var Fe=a.token(y,fe);if(y.pos>y.start)return Fe}throw new Error("Mode "+a.name+" failed to advance stream.")}var xr=function(a,y,fe){this.start=a.start,this.end=a.pos,this.string=a.current(),this.type=y||null,this.state=fe};function Ir(a,y,fe,de){var xe=a.doc,Fe=xe.mode,Je;y=Tt(xe,y);var it=Ft(xe,y.line),at=Rr(a,y.line,fe),ht=new kt(it.text,a.options.tabSize,at),It;for(de&&(It=[]);(de||ht.pos<y.ch)&&!ht.eol();)ht.start=ht.pos,Je=Vr(Fe,ht,at.state),de&&It.push(new xr(ht,Je,st(xe.mode,at.state)));return de?It:new xr(ht,Je,at.state)}function jr(a,y){if(a)for(;;){var fe=a.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!fe)break;a=a.slice(0,fe.index)+a.slice(fe.index+fe[0].length);var de=fe[1]?"bgClass":"textClass";y[de]==null?y[de]=fe[2]:new RegExp("(?:^|\\s)"+fe[2]+"(?:$|\\s)").test(y[de])||(y[de]+=" "+fe[2])}return a}function ti(a,y,fe,de,xe,Fe,Je){var it=fe.flattenSpans;it==null&&(it=a.options.flattenSpans);var at=0,ht=null,It=new kt(y,a.options.tabSize,de),Ut,rn=a.options.addModeClass&&[null];for(y==""&&jr(Lr(fe,de.state),Fe);!It.eol();){if(It.pos>a.options.maxHighlightLength?(it=!1,Je&&wr(a,y,de,It.pos),It.pos=y.length,Ut=null):Ut=jr(Vr(fe,It,de.state,rn),Fe),rn){var Qt=rn[0].name;Qt&&(Ut="m-"+(Ut?Qt+" "+Ut:Qt))}if(!it||ht!=Ut){for(;at<It.start;)at=Math.min(It.start,at+5e3),xe(at,ht);ht=Ut}It.start=It.pos}for(;at<It.pos;){var Dn=Math.min(It.pos,at+5e3);xe(Dn,ht),at=Dn}}function di(a,y,fe){for(var de,xe,Fe=a.doc,Je=fe?-1:y-(a.doc.mode.innerMode?1e3:100),it=y;it>Je;--it){if(it<=Fe.first)return Fe.first;var at=Ft(Fe,it-1),ht=at.stateAfter;if(ht&&(!fe||it+(ht instanceof Fn?ht.lookAhead:0)<=Fe.modeFrontier))return it;var It=Ge(at.text,null,a.options.tabSize);(xe==null||de>It)&&(xe=it-1,de=It)}return xe}function wi(a,y){if(a.modeFrontier=Math.min(a.modeFrontier,y),!(a.highlightFrontier<y-10)){for(var fe=a.first,de=y-1;de>fe;de--){var xe=Ft(a,de).stateAfter;if(xe&&(!(xe instanceof Fn)||de+xe.lookAhead<y)){fe=de+1;break}}a.highlightFrontier=Math.min(a.highlightFrontier,fe)}}var xi=!1,ai=!1;function Di(){xi=!0}function _i(){ai=!0}function or(a,y,fe){this.marker=a,this.from=y,this.to=fe}function br(a,y){if(a)for(var fe=0;fe<a.length;++fe){var de=a[fe];if(de.marker==y)return de}}function Ar(a,y){for(var fe,de=0;de<a.length;++de)a[de]!=y&&(fe||(fe=[])).push(a[de]);return fe}function qr(a,y){a.markedSpans=a.markedSpans?a.markedSpans.concat([y]):[y],y.marker.attachLine(a)}function $r(a,y,fe){var de;if(a)for(var xe=0;xe<a.length;++xe){var Fe=a[xe],Je=Fe.marker,it=Fe.from==null||(Je.inclusiveLeft?Fe.from<=y:Fe.from<y);if(it||Fe.from==y&&Je.type=="bookmark"&&(!fe||!Fe.marker.insertLeft)){var at=Fe.to==null||(Je.inclusiveRight?Fe.to>=y:Fe.to>y);(de||(de=[])).push(new or(Je,Fe.from,at?null:Fe.to))}}return de}function bi(a,y,fe){var de;if(a)for(var xe=0;xe<a.length;++xe){var Fe=a[xe],Je=Fe.marker,it=Fe.to==null||(Je.inclusiveRight?Fe.to>=y:Fe.to>y);if(it||Fe.from==y&&Je.type=="bookmark"&&(!fe||Fe.marker.insertLeft)){var at=Fe.from==null||(Je.inclusiveLeft?Fe.from<=y:Fe.from<y);(de||(de=[])).push(new or(Je,at?null:Fe.from-y,Fe.to==null?null:Fe.to-y))}}return de}function Wi(a,y){if(y.full)return null;var fe=an(a,y.from.line)&&Ft(a,y.from.line).markedSpans,de=an(a,y.to.line)&&Ft(a,y.to.line).markedSpans;if(!fe&&!de)return null;var xe=y.from.ch,Fe=y.to.ch,Je=zt(y.from,y.to)==0,it=$r(fe,xe,Je),at=bi(de,Fe,Je),ht=y.text.length==1,It=xt(y.text).length+(ht?xe:0);if(it)for(var Ut=0;Ut<it.length;++Ut){var rn=it[Ut];if(rn.to==null){var Qt=br(at,rn.marker);Qt?ht&&(rn.to=Qt.to==null?null:Qt.to+It):rn.to=xe}}if(at)for(var Dn=0;Dn<at.length;++Dn){var Wn=at[Dn];if(Wn.to!=null&&(Wn.to+=It),Wn.from==null){var Qn=br(it,Wn.marker);Qn||(Wn.from=It,ht&&(it||(it=[])).push(Wn))}else Wn.from+=It,ht&&(it||(it=[])).push(Wn)}it&&(it=Dt(it)),at&&at!=it&&(at=Dt(at));var sr=[it];if(!ht){var vr=y.text.length-2,lr;if(vr>0&&it)for(var Er=0;Er<it.length;++Er)it[Er].to==null&&(lr||(lr=[])).push(new or(it[Er].marker,null,null));for(var Qr=0;Qr<vr;++Qr)sr.push(lr);sr.push(at)}return sr}function Dt(a){for(var y=0;y<a.length;++y){var fe=a[y];fe.from!=null&&fe.from==fe.to&&fe.marker.clearWhenEmpty!==!1&&a.splice(y--,1)}return a.length?a:null}function $t(a,y,fe){var de=null;if(a.iter(y.line,fe.line+1,function(Qt){if(Qt.markedSpans)for(var Dn=0;Dn<Qt.markedSpans.length;++Dn){var Wn=Qt.markedSpans[Dn].marker;Wn.readOnly&&(!de||Ve(de,Wn)==-1)&&(de||(de=[])).push(Wn)}}),!de)return null;for(var xe=[{from:y,to:fe}],Fe=0;Fe<de.length;++Fe)for(var Je=de[Fe],it=Je.find(0),at=0;at<xe.length;++at){var ht=xe[at];if(!(zt(ht.to,it.from)<0||zt(ht.from,it.to)>0)){var It=[at,1],Ut=zt(ht.from,it.from),rn=zt(ht.to,it.to);(Ut<0||!Je.inclusiveLeft&&!Ut)&&It.push({from:ht.from,to:it.from}),(rn>0||!Je.inclusiveRight&&!rn)&&It.push({from:it.to,to:ht.to}),xe.splice.apply(xe,It),at+=It.length-3}}return xe}function Zt(a){var y=a.markedSpans;if(y){for(var fe=0;fe<y.length;++fe)y[fe].marker.detachLine(a);a.markedSpans=null}}function en(a,y){if(y){for(var fe=0;fe<y.length;++fe)y[fe].marker.attachLine(a);a.markedSpans=y}}function on(a){return a.inclusiveLeft?-1:0}function hn(a){return a.inclusiveRight?1:0}function Pn(a,y){var fe=a.lines.length-y.lines.length;if(fe!=0)return fe;var de=a.find(),xe=y.find(),Fe=zt(de.from,xe.from)||on(a)-on(y);if(Fe)return-Fe;var Je=zt(de.to,xe.to)||hn(a)-hn(y);return Je||y.id-a.id}function kn(a,y){var fe=ai&&a.markedSpans,de;if(fe)for(var xe=void 0,Fe=0;Fe<fe.length;++Fe)xe=fe[Fe],xe.marker.collapsed&&(y?xe.from:xe.to)==null&&(!de||Pn(de,xe.marker)<0)&&(de=xe.marker);return de}function _n(a){return kn(a,!0)}function Gt(a){return kn(a,!1)}function cn(a,y){var fe=ai&&a.markedSpans,de;if(fe)for(var xe=0;xe<fe.length;++xe){var Fe=fe[xe];Fe.marker.collapsed&&(Fe.from==null||Fe.from<y)&&(Fe.to==null||Fe.to>y)&&(!de||Pn(de,Fe.marker)<0)&&(de=Fe.marker)}return de}function dn(a,y,fe,de,xe){var Fe=Ft(a,y),Je=ai&&Fe.markedSpans;if(Je)for(var it=0;it<Je.length;++it){var at=Je[it];if(at.marker.collapsed){var ht=at.marker.find(0),It=zt(ht.from,fe)||on(at.marker)-on(xe),Ut=zt(ht.to,de)||hn(at.marker)-hn(xe);if(!(It>=0&&Ut<=0||It<=0&&Ut>=0)&&(It<=0&&(at.marker.inclusiveRight&&xe.inclusiveLeft?zt(ht.to,fe)>=0:zt(ht.to,fe)>0)||It>=0&&(at.marker.inclusiveRight&&xe.inclusiveLeft?zt(ht.from,de)<=0:zt(ht.from,de)<0)))return!0}}}function un(a){for(var y;y=_n(a);)a=y.find(-1,!0).line;return a}function mn(a){for(var y;y=Gt(a);)a=y.find(1,!0).line;return a}function ln(a){for(var y,fe;y=Gt(a);)a=y.find(1,!0).line,(fe||(fe=[])).push(a);return fe}function fn(a,y){var fe=Ft(a,y),de=un(fe);return fe==de?y:At(de)}function vn(a,y){if(y>a.lastLine())return y;var fe=Ft(a,y),de;if(!Ln(a,fe))return y;for(;de=Gt(fe);)fe=de.find(1,!0).line;return At(fe)+1}function Ln(a,y){var fe=ai&&y.markedSpans;if(fe){for(var de=void 0,xe=0;xe<fe.length;++xe)if(de=fe[xe],!!de.marker.collapsed){if(de.from==null)return!0;if(!de.marker.widgetNode&&de.from==0&&de.marker.inclusiveLeft&&Jn(a,y,de))return!0}}}function Jn(a,y,fe){if(fe.to==null){var de=fe.marker.find(1,!0);return Jn(a,de.line,br(de.line.markedSpans,fe.marker))}if(fe.marker.inclusiveRight&&fe.to==y.text.length)return!0;for(var xe=void 0,Fe=0;Fe<y.markedSpans.length;++Fe)if(xe=y.markedSpans[Fe],xe.marker.collapsed&&!xe.marker.widgetNode&&xe.from==fe.to&&(xe.to==null||xe.to!=fe.from)&&(xe.marker.inclusiveLeft||fe.marker.inclusiveRight)&&Jn(a,y,xe))return!0}function Xn(a){a=un(a);for(var y=0,fe=a.parent,de=0;de<fe.lines.length;++de){var xe=fe.lines[de];if(xe==a)break;y+=xe.height}for(var Fe=fe.parent;Fe;fe=Fe,Fe=fe.parent)for(var Je=0;Je<Fe.children.length;++Je){var it=Fe.children[Je];if(it==fe)break;y+=it.height}return y}function gr(a){if(a.height==0)return 0;for(var y=a.text.length,fe,de=a;fe=_n(de);){var xe=fe.find(0,!0);de=xe.from.line,y+=xe.from.ch-xe.to.ch}for(de=a;fe=Gt(de);){var Fe=fe.find(0,!0);y-=de.text.length-Fe.from.ch,de=Fe.to.line,y+=de.text.length-Fe.to.ch}return y}function nr(a){var y=a.display,fe=a.doc;y.maxLine=Ft(fe,fe.first),y.maxLineLength=gr(y.maxLine),y.maxLineChanged=!0,fe.iter(function(de){var xe=gr(de);xe>y.maxLineLength&&(y.maxLineLength=xe,y.maxLine=de)})}var Cr=function(a,y,fe){this.text=a,en(this,y),this.height=fe?fe(this):1};Cr.prototype.lineNo=function(){return At(this)},Kt(Cr);function Tr(a,y,fe,de){a.text=y,a.stateAfter&&(a.stateAfter=null),a.styles&&(a.styles=null),a.order!=null&&(a.order=null),Zt(a),en(a,fe);var xe=de?de(a):1;xe!=a.height&&Yn(a,xe)}function Gr(a){a.parent=null,Zt(a)}var Or={},Kr={};function ni(a,y){if(!a||/^\s*$/.test(a))return null;var fe=y.addModeClass?Kr:Or;return fe[a]||(fe[a]=a.replace(/\S+/g,"cm-$&"))}function Wr(a,y){var fe=je("span",null,null,le?"padding-right: .1px":null),de={pre:je("pre",[fe],"CodeMirror-line"),content:fe,col:0,pos:0,cm:a,trailingSpace:!1,splitSpaces:a.getOption("lineWrapping")};y.measure={};for(var xe=0;xe<=(y.rest?y.rest.length:0);xe++){var Fe=xe?y.rest[xe-1]:y.line,Je=void 0;de.pos=0,de.addToken=Dr,Bn(a.display.measure)&&(Je=Nt(Fe,a.doc.direction))&&(de.addToken=fr(de.addToken,Je)),de.map=[];var it=y!=a.display.externalMeasured&&At(Fe);Yr(Fe,de,pr(a,Fe,it)),Fe.styleClasses&&(Fe.styleClasses.bgClass&&(de.bgClass=He(Fe.styleClasses.bgClass,de.bgClass||"")),Fe.styleClasses.textClass&&(de.textClass=He(Fe.styleClasses.textClass,de.textClass||""))),de.map.length==0&&de.map.push(0,0,de.content.appendChild(ur(a.display.measure))),xe==0?(y.measure.map=de.map,y.measure.cache={}):((y.measure.maps||(y.measure.maps=[])).push(de.map),(y.measure.caches||(y.measure.caches=[])).push({}))}if(le){var at=de.content.lastChild;(/\bcm-tab\b/.test(at.className)||at.querySelector&&at.querySelector(".cm-tab"))&&(de.content.className="cm-tab-wrap-hack")}return jt(a,"renderLine",a,y.line,de.pre),de.pre.className&&(de.textClass=He(de.pre.className,de.textClass||"")),de}function ei(a){var y=Oe("span","\u2022","cm-invalidchar");return y.title="\\u"+a.charCodeAt(0).toString(16),y.setAttribute("aria-label",y.title),y}function Dr(a,y,fe,de,xe,Fe,Je){if(y){var it=a.splitSpaces?ar(y,a.trailingSpace):y,at=a.cm.state.specialChars,ht=!1,It;if(!at.test(y))a.col+=y.length,It=document.createTextNode(it),a.map.push(a.pos,a.pos+y.length,It),se&&te<9&&(ht=!0),a.pos+=y.length;else{It=document.createDocumentFragment();for(var Ut=0;;){at.lastIndex=Ut;var rn=at.exec(y),Qt=rn?rn.index-Ut:y.length-Ut;if(Qt){var Dn=document.createTextNode(it.slice(Ut,Ut+Qt));se&&te<9?It.appendChild(Oe("span",[Dn])):It.appendChild(Dn),a.map.push(a.pos,a.pos+Qt,Dn),a.col+=Qt,a.pos+=Qt}if(!rn)break;Ut+=Qt+1;var Wn=void 0;if(rn[0]==" "){var Qn=a.cm.options.tabSize,sr=Qn-a.col%Qn;Wn=It.appendChild(Oe("span",Rt(sr),"cm-tab")),Wn.setAttribute("role","presentation"),Wn.setAttribute("cm-text"," "),a.col+=sr}else rn[0]=="\r"||rn[0]==`
|
|
|
`?(Wn=It.appendChild(Oe("span",rn[0]=="\r"?"\u240D":"\u2424","cm-invalidchar")),Wn.setAttribute("cm-text",rn[0]),a.col+=1):(Wn=a.cm.options.specialCharPlaceholder(rn[0]),Wn.setAttribute("cm-text",rn[0]),se&&te<9?It.appendChild(Oe("span",[Wn])):It.appendChild(Wn),a.col+=1);a.map.push(a.pos,a.pos+1,Wn),a.pos++}}if(a.trailingSpace=it.charCodeAt(y.length-1)==32,fe||de||xe||ht||Fe||Je){var vr=fe||"";de&&(vr+=de),xe&&(vr+=xe);var lr=Oe("span",[It],vr,Fe);if(Je)for(var Er in Je)Je.hasOwnProperty(Er)&&Er!="style"&&Er!="class"&&lr.setAttribute(Er,Je[Er]);return a.content.appendChild(lr)}a.content.appendChild(It)}}function ar(a,y){if(a.length>1&&!/ /.test(a))return a;for(var fe=y,de="",xe=0;xe<a.length;xe++){var Fe=a.charAt(xe);Fe==" "&&fe&&(xe==a.length-1||a.charCodeAt(xe+1)==32)&&(Fe="\xA0"),de+=Fe,fe=Fe==" "}return de}function fr(a,y){return function(fe,de,xe,Fe,Je,it,at){xe=xe?xe+" cm-force-border":"cm-force-border";for(var ht=fe.pos,It=ht+de.length;;){for(var Ut=void 0,rn=0;rn<y.length&&(Ut=y[rn],!(Ut.to>ht&&Ut.from<=ht));rn++);if(Ut.to>=It)return a(fe,de,xe,Fe,Je,it,at);a(fe,de.slice(0,Ut.to-ht),xe,Fe,null,it,at),Fe=null,de=de.slice(Ut.to-ht),ht=Ut.to}}}function cr(a,y,fe,de){var xe=!de&&fe.widgetNode;xe&&a.map.push(a.pos,a.pos+y,xe),!de&&a.cm.display.input.needsContentAttribute&&(xe||(xe=a.content.appendChild(document.createElement("span"))),xe.setAttribute("cm-marker",fe.id)),xe&&(a.cm.display.input.setUneditable(xe),a.content.appendChild(xe)),a.pos+=y,a.trailingSpace=!1}function Yr(a,y,fe){var de=a.markedSpans,xe=a.text,Fe=0;if(!de){for(var Je=1;Je<fe.length;Je+=2)y.addToken(y,xe.slice(Fe,Fe=fe[Je]),ni(fe[Je+1],y.cm.options));return}for(var it=xe.length,at=0,ht=1,It="",Ut,rn,Qt=0,Dn,Wn,Qn,sr,vr;;){if(Qt==at){Dn=Wn=Qn=rn="",vr=null,sr=null,Qt=1/0;for(var lr=[],Er=void 0,Qr=0;Qr<de.length;++Qr){var Hr=de[Qr],Li=Hr.marker;if(Li.type=="bookmark"&&Hr.from==at&&Li.widgetNode)lr.push(Li);else if(Hr.from<=at&&(Hr.to==null||Hr.to>at||Li.collapsed&&Hr.to==at&&Hr.from==at)){if(Hr.to!=null&&Hr.to!=at&&Qt>Hr.to&&(Qt=Hr.to,Wn=""),Li.className&&(Dn+=" "+Li.className),Li.css&&(rn=(rn?rn+";":"")+Li.css),Li.startStyle&&Hr.from==at&&(Qn+=" "+Li.startStyle),Li.endStyle&&Hr.to==Qt&&(Er||(Er=[])).push(Li.endStyle,Hr.to),Li.title&&((vr||(vr={})).title=Li.title),Li.attributes)for(var to in Li.attributes)(vr||(vr={}))[to]=Li.attributes[to];Li.collapsed&&(!sr||Pn(sr.marker,Li)<0)&&(sr=Hr)}else Hr.from>at&&Qt>Hr.from&&(Qt=Hr.from)}if(Er)for(var Mo=0;Mo<Er.length;Mo+=2)Er[Mo+1]==Qt&&(Wn+=" "+Er[Mo]);if(!sr||sr.from==at)for(var ho=0;ho<lr.length;++ho)cr(y,0,lr[ho]);if(sr&&(sr.from||0)==at){if(cr(y,(sr.to==null?it+1:sr.to)-at,sr.marker,sr.from==null),sr.to==null)return;sr.to==at&&(sr=!1)}}if(at>=it)break;for(var sa=Math.min(it,Qt);;){if(It){var $o=at+It.length;if(!sr){var So=$o>sa?It.slice(0,sa-at):It;y.addToken(y,So,Ut?Ut+Dn:Dn,Qn,at+So.length==Qt?Wn:"",rn,vr)}if($o>=sa){It=It.slice(sa-at),at=sa;break}at=$o,Qn=""}It=xe.slice(Fe,Fe=fe[ht++]),Ut=ni(fe[ht++],y.cm.options)}}}function Xr(a,y,fe){this.line=y,this.rest=ln(y),this.size=this.rest?At(xt(this.rest))-fe+1:1,this.node=this.text=null,this.hidden=Ln(a,y)}function Jr(a,y,fe){for(var de=[],xe,Fe=y;Fe<fe;Fe=xe){var Je=new Xr(a.doc,Ft(a.doc,Fe),Fe);xe=Fe+Je.size,de.push(Je)}return de}var hi=null;function ao(a){hi?hi.ops.push(a):a.ownsGroup=hi={ops:[a],delayedCallbacks:[]}}function Hi(a){var y=a.delayedCallbacks,fe=0;do{for(;fe<y.length;fe++)y[fe].call(null);for(var de=0;de<a.ops.length;de++){var xe=a.ops[de];if(xe.cursorActivityHandlers)for(;xe.cursorActivityCalled<xe.cursorActivityHandlers.length;)xe.cursorActivityHandlers[xe.cursorActivityCalled++].call(null,xe.cm)}}while(fe<y.length)}function Lo(a,y){var fe=a.ownsGroup;if(fe)try{Hi(fe)}finally{hi=null,y(fe)}}var po=null;function Ri(a,y){var fe=Pt(a,y);if(fe.length){var de=Array.prototype.slice.call(arguments,2),xe;hi?xe=hi.delayedCallbacks:po?xe=po:(xe=po=[],setTimeout(Ii,0));for(var Fe=function(it){xe.push(function(){return fe[it].apply(null,de)})},Je=0;Je<fe.length;++Je)Fe(Je)}}function Ii(){var a=po;po=null;for(var y=0;y<a.length;++y)a[y]()}function Pi(a,y,fe,de){for(var xe=0;xe<y.changes.length;xe++){var Fe=y.changes[xe];Fe=="text"?ji(a,y):Fe=="gutter"?zr(a,y,fe,de):Fe=="class"?yr(a,y):Fe=="widget"&&Ur(a,y,de)}y.changes=null}function mo(a){return a.node==a.text&&(a.node=Oe("div",null,null,"position: relative"),a.text.parentNode&&a.text.parentNode.replaceChild(a.node,a.text),a.node.appendChild(a.text),se&&te<8&&(a.node.style.zIndex=2)),a.node}function Fi(a,y){var fe=y.bgClass?y.bgClass+" "+(y.line.bgClass||""):y.line.bgClass;if(fe&&(fe+=" CodeMirror-linebackground"),y.background)fe?y.background.className=fe:(y.background.parentNode.removeChild(y.background),y.background=null);else if(fe){var de=mo(y);y.background=de.insertBefore(Oe("div",null,fe),de.firstChild),a.display.input.setUneditable(y.background)}}function Ki(a,y){var fe=a.display.externalMeasured;return fe&&fe.line==y.line?(a.display.externalMeasured=null,y.measure=fe.measure,fe.built):Wr(a,y)}function ji(a,y){var fe=y.text.className,de=Ki(a,y);y.text==y.node&&(y.node=de.pre),y.text.parentNode.replaceChild(de.pre,y.text),y.text=de.pre,de.bgClass!=y.bgClass||de.textClass!=y.textClass?(y.bgClass=de.bgClass,y.textClass=de.textClass,yr(a,y)):fe&&(y.text.className=fe)}function yr(a,y){Fi(a,y),y.line.wrapClass?mo(y).className=y.line.wrapClass:y.node!=y.text&&(y.node.className="");var fe=y.textClass?y.textClass+" "+(y.line.textClass||""):y.line.textClass;y.text.className=fe||""}function zr(a,y,fe,de){if(y.gutter&&(y.node.removeChild(y.gutter),y.gutter=null),y.gutterBackground&&(y.node.removeChild(y.gutterBackground),y.gutterBackground=null),y.line.gutterClass){var xe=mo(y);y.gutterBackground=Oe("div",null,"CodeMirror-gutter-background "+y.line.gutterClass,"left: "+(a.options.fixedGutter?de.fixedPos:-de.gutterTotalWidth)+"px; width: "+de.gutterTotalWidth+"px"),a.display.input.setUneditable(y.gutterBackground),xe.insertBefore(y.gutterBackground,y.text)}var Fe=y.line.gutterMarkers;if(a.options.lineNumbers||Fe){var Je=mo(y),it=y.gutter=Oe("div",null,"CodeMirror-gutter-wrapper","left: "+(a.options.fixedGutter?de.fixedPos:-de.gutterTotalWidth)+"px");if(a.display.input.setUneditable(it),Je.insertBefore(it,y.text),y.line.gutterClass&&(it.className+=" "+y.line.gutterClass),a.options.lineNumbers&&(!Fe||!Fe["CodeMirror-linenumbers"])&&(y.lineNumber=it.appendChild(Oe("div",Wt(a.options,fe),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+de.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+a.display.lineNumInnerWidth+"px"))),Fe)for(var at=0;at<a.display.gutterSpecs.length;++at){var ht=a.display.gutterSpecs[at].className,It=Fe.hasOwnProperty(ht)&&Fe[ht];It&&it.appendChild(Oe("div",[It],"CodeMirror-gutter-elt","left: "+de.gutterLeft[ht]+"px; width: "+de.gutterWidth[ht]+"px"))}}}function Ur(a,y,fe){y.alignable&&(y.alignable=null);for(var de=pe("CodeMirror-linewidget"),xe=y.node.firstChild,Fe=void 0;xe;xe=Fe)Fe=xe.nextSibling,de.test(xe.className)&&y.node.removeChild(xe);Ci(a,y,fe)}function Zr(a,y,fe,de){var xe=Ki(a,y);return y.text=y.node=xe.pre,xe.bgClass&&(y.bgClass=xe.bgClass),xe.textClass&&(y.textClass=xe.textClass),yr(a,y),zr(a,y,fe,de),Ci(a,y,de),y.node}function Ci(a,y,fe){if(Oi(a,y.line,y,fe,!0),y.rest)for(var de=0;de<y.rest.length;de++)Oi(a,y.rest[de],y,fe,!1)}function Oi(a,y,fe,de,xe){if(y.widgets)for(var Fe=mo(fe),Je=0,it=y.widgets;Je<it.length;++Je){var at=it[Je],ht=Oe("div",[at.node],"CodeMirror-linewidget"+(at.className?" "+at.className:""));at.handleMouseEvents||ht.setAttribute("cm-ignore-events","true"),Ao(at,ht,fe,de),a.display.input.setUneditable(ht),xe&&at.above?Fe.insertBefore(ht,fe.gutter||fe.text):Fe.appendChild(ht),Ri(at,"redraw")}}function Ao(a,y,fe,de){if(a.noHScroll){(fe.alignable||(fe.alignable=[])).push(y);var xe=de.wrapperWidth;y.style.left=de.fixedPos+"px",a.coverGutter||(xe-=de.gutterTotalWidth,y.style.paddingLeft=de.gutterTotalWidth+"px"),y.style.width=xe+"px"}a.coverGutter&&(y.style.zIndex=5,y.style.position="relative",a.noHScroll||(y.style.marginLeft=-de.gutterTotalWidth+"px"))}function Xi(a){if(a.height!=null)return a.height;var y=a.doc.cm;if(!y)return 0;if(!Qe(document.body,a.node)){var fe="position: relative;";a.coverGutter&&(fe+="margin-left: -"+y.display.gutters.offsetWidth+"px;"),a.noHScroll&&(fe+="width: "+y.display.wrapper.clientWidth+"px;"),Ee(y.display.measure,Oe("div",[a.node],null,fe))}return a.height=a.node.parentNode.offsetHeight}function qi(a,y){for(var fe=Gn(y);fe!=a.wrapper;fe=fe.parentNode)if(!fe||fe.nodeType==1&&fe.getAttribute("cm-ignore-events")=="true"||fe.parentNode==a.sizer&&fe!=a.mover)return!0}function ui(a){return a.lineSpace.offsetTop}function no(a){return a.mover.offsetHeight-a.lineSpace.offsetHeight}function Io(a){if(a.cachedPaddingH)return a.cachedPaddingH;var y=Ee(a.measure,Oe("pre","x","CodeMirror-line-like")),fe=window.getComputedStyle?window.getComputedStyle(y):y.currentStyle,de={left:parseInt(fe.paddingLeft),right:parseInt(fe.paddingRight)};return!isNaN(de.left)&&!isNaN(de.right)&&(a.cachedPaddingH=de),de}function Ui(a){return $e-a.display.nativeBarWidth}function Ho(a){return a.display.scroller.clientWidth-Ui(a)-a.display.barWidth}function xo(a){return a.display.scroller.clientHeight-Ui(a)-a.display.barHeight}function Oo(a,y,fe){var de=a.options.lineWrapping,xe=de&&Ho(a);if(!y.measure.heights||de&&y.measure.width!=xe){var Fe=y.measure.heights=[];if(de){y.measure.width=xe;for(var Je=y.text.firstChild.getClientRects(),it=0;it<Je.length-1;it++){var at=Je[it],ht=Je[it+1];Math.abs(at.bottom-ht.bottom)>2&&Fe.push((at.bottom+ht.top)/2-fe.top)}}Fe.push(fe.bottom-fe.top)}}function Vi(a,y,fe){if(a.line==y)return{map:a.measure.map,cache:a.measure.cache};for(var de=0;de<a.rest.length;de++)if(a.rest[de]==y)return{map:a.measure.maps[de],cache:a.measure.caches[de]};for(var xe=0;xe<a.rest.length;xe++)if(At(a.rest[xe])>fe)return{map:a.measure.maps[xe],cache:a.measure.caches[xe],before:!0}}function Wo(a,y){y=un(y);var fe=At(y),de=a.display.externalMeasured=new Xr(a.doc,y,fe);de.lineN=fe;var xe=de.built=Wr(a,de);return de.text=xe.pre,Ee(a.display.lineMeasure,xe.pre),de}function za(a,y,fe,de){return Zo(a,la(a,y),fe,de)}function Yo(a,y){if(y>=a.display.viewFrom&&y<a.display.viewTo)return a.display.view[yo(a,y)];var fe=a.display.externalMeasured;if(fe&&y>=fe.lineN&&y<fe.lineN+fe.size)return fe}function la(a,y){var fe=At(y),de=Yo(a,fe);de&&!de.text?de=null:de&&de.changes&&(Pi(a,de,fe,Xo(a)),a.curOp.forceUpdate=!0),de||(de=Wo(a,y));var xe=Vi(de,y,fe);return{line:y,view:de,rect:null,map:xe.map,cache:xe.cache,before:xe.before,hasHeights:!1}}function Zo(a,y,fe,de,xe){y.before&&(fe=-1);var Fe=fe+(de||""),Je;return y.cache.hasOwnProperty(Fe)?Je=y.cache[Fe]:(y.rect||(y.rect=y.view.text.getBoundingClientRect()),y.hasHeights||(Oo(a,y.view,y.rect),y.hasHeights=!0),Je=cs(a,y,fe,de),Je.bogus||(y.cache[Fe]=Je)),{left:Je.left,right:Je.right,top:xe?Je.rtop:Je.top,bottom:xe?Je.rbottom:Je.bottom}}var Da={left:0,right:0,top:0,bottom:0};function qa(a,y,fe){for(var de,xe,Fe,Je,it,at,ht=0;ht<a.length;ht+=3)if(it=a[ht],at=a[ht+1],y<it?(xe=0,Fe=1,Je="left"):y<at?(xe=y-it,Fe=xe+1):(ht==a.length-3||y==at&&a[ht+3]>y)&&(Fe=at-it,xe=Fe-1,y>=at&&(Je="right")),xe!=null){if(de=a[ht+2],it==at&&fe==(de.insertLeft?"left":"right")&&(Je=fe),fe=="left"&&xe==0)for(;ht&&a[ht-2]==a[ht-3]&&a[ht-1].insertLeft;)de=a[(ht-=3)+2],Je="left";if(fe=="right"&&xe==at-it)for(;ht<a.length-3&&a[ht+3]==a[ht+4]&&!a[ht+5].insertLeft;)de=a[(ht+=3)+2],Je="right";break}return{node:de,start:xe,end:Fe,collapse:Je,coverStart:it,coverEnd:at}}function ba(a,y){var fe=Da;if(y=="left")for(var de=0;de<a.length&&(fe=a[de]).left==fe.right;de++);else for(var xe=a.length-1;xe>=0&&(fe=a[xe]).left==fe.right;xe--);return fe}function cs(a,y,fe,de){var xe=qa(y.map,fe,de),Fe=xe.node,Je=xe.start,it=xe.end,at=xe.collapse,ht;if(Fe.nodeType==3){for(var It=0;It<4;It++){for(;Je&&we(y.line.text.charAt(xe.coverStart+Je));)--Je;for(;xe.coverStart+it<xe.coverEnd&&we(y.line.text.charAt(xe.coverStart+it));)++it;if(se&&te<9&&Je==0&&it==xe.coverEnd-xe.coverStart?ht=Fe.parentNode.getBoundingClientRect():ht=ba(Pe(Fe,Je,it).getClientRects(),de),ht.left||ht.right||Je==0)break;it=Je,Je=Je-1,at="right"}se&&te<11&&(ht=Ma(a.display.measure,ht))}else{Je>0&&(at=de="right");var Ut;a.options.lineWrapping&&(Ut=Fe.getClientRects()).length>1?ht=Ut[de=="right"?Ut.length-1:0]:ht=Fe.getBoundingClientRect()}if(se&&te<9&&!Je&&(!ht||!ht.left&&!ht.right)){var rn=Fe.parentNode.getClientRects()[0];rn?ht={left:rn.left,right:rn.left+Fo(a.display),top:rn.top,bottom:rn.bottom}:ht=Da}for(var Qt=ht.top-y.rect.top,Dn=ht.bottom-y.rect.top,Wn=(Qt+Dn)/2,Qn=y.view.measure.heights,sr=0;sr<Qn.length-1&&!(Wn<Qn[sr]);sr++);var vr=sr?Qn[sr-1]:0,lr=Qn[sr],Er={left:(at=="right"?ht.right:ht.left)-y.rect.left,right:(at=="left"?ht.left:ht.right)-y.rect.left,top:vr,bottom:lr};return!ht.left&&!ht.right&&(Er.bogus=!0),a.options.singleCursorHeightPerLine||(Er.rtop=Qt,Er.rbottom=Dn),Er}function Ma(a,y){if(!window.screen||screen.logicalXDPI==null||screen.logicalXDPI==screen.deviceXDPI||!Hn(a))return y;var fe=screen.logicalXDPI/screen.deviceXDPI,de=screen.logicalYDPI/screen.deviceYDPI;return{left:y.left*fe,right:y.right*fe,top:y.top*de,bottom:y.bottom*de}}function Ha(a){if(a.measure&&(a.measure.cache={},a.measure.heights=null,a.rest))for(var y=0;y<a.rest.length;y++)a.measure.caches[y]={}}function Ra(a){a.display.externalMeasure=null,Te(a.display.lineMeasure);for(var y=0;y<a.display.view.length;y++)Ha(a.display.view[y])}function pa(a){Ra(a),a.display.cachedCharWidth=a.display.cachedTextHeight=a.display.cachedPaddingH=null,a.options.lineWrapping||(a.display.maxLineChanged=!0),a.display.lineNumChars=null}function Wa(){return ne&&ae?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function Ja(){return ne&&ae?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function Sa(a){var y=0;if(a.widgets)for(var fe=0;fe<a.widgets.length;++fe)a.widgets[fe].above&&(y+=Xi(a.widgets[fe]));return y}function wa(a,y,fe,de,xe){if(!xe){var Fe=Sa(y);fe.top+=Fe,fe.bottom+=Fe}if(de=="line")return fe;de||(de="local");var Je=Xn(y);if(de=="local"?Je+=ui(a.display):Je-=a.display.viewOffset,de=="page"||de=="window"){var it=a.display.lineSpace.getBoundingClientRect();Je+=it.top+(de=="window"?0:Ja());var at=it.left+(de=="window"?0:Wa());fe.left+=at,fe.right+=at}return fe.top+=Je,fe.bottom+=Je,fe}function ua(a,y,fe){if(fe=="div")return y;var de=y.left,xe=y.top;if(fe=="page")de-=Wa(),xe-=Ja();else if(fe=="local"||!fe){var Fe=a.display.sizer.getBoundingClientRect();de+=Fe.left,xe+=Fe.top}var Je=a.display.lineSpace.getBoundingClientRect();return{left:de-Je.left,top:xe-Je.top}}function To(a,y,fe,de,xe){return de||(de=Ft(a.doc,y.line)),wa(a,de,za(a,de,y.ch,xe),fe)}function Ji(a,y,fe,de,xe,Fe){de=de||Ft(a.doc,y.line),xe||(xe=la(a,de));function Je(Dn,Wn){var Qn=Zo(a,xe,Dn,Wn?"right":"left",Fe);return Wn?Qn.left=Qn.right:Qn.right=Qn.left,wa(a,de,Qn,fe)}var it=Nt(de,a.doc.direction),at=y.ch,ht=y.sticky;if(at>=de.text.length?(at=de.text.length,ht="before"):at<=0&&(at=0,ht="after"),!it)return Je(ht=="before"?at-1:at,ht=="before");function It(Dn,Wn,Qn){var sr=it[Wn],vr=sr.level==1;return Je(Qn?Dn-1:Dn,vr!=Qn)}var Ut=tt(it,at,ht),rn=Re,Qt=It(at,Ut,ht=="before");return rn!=null&&(Qt.other=It(at,rn,ht!="before")),Qt}function vi(a,y){var fe=0;y=Tt(a.doc,y),a.options.lineWrapping||(fe=Fo(a.display)*y.ch);var de=Ft(a.doc,y.line),xe=Xn(de)+ui(a.display);return{left:fe,right:fe,top:xe,bottom:xe+de.height}}function si(a,y,fe,de,xe){var Fe=Et(a,y,fe);return Fe.xRel=xe,de&&(Fe.outside=de),Fe}function ro(a,y,fe){var de=a.doc;if(fe+=a.display.viewOffset,fe<0)return si(de.first,0,null,-1,-1);var xe=St(de,fe),Fe=de.first+de.size-1;if(xe>Fe)return si(de.first+de.size-1,Ft(de,Fe).text.length,null,1,1);y<0&&(y=0);for(var Je=Ft(de,xe);;){var it=na(a,Je,xe,y,fe),at=cn(Je,it.ch+(it.xRel>0||it.outside>0?1:0));if(!at)return it;var ht=at.find(1);if(ht.line==xe)return ht;Je=Ft(de,xe=ht.line)}}function Qi(a,y,fe,de){de-=Sa(y);var xe=y.text.length,Fe=Ue(function(Je){return Zo(a,fe,Je-1).bottom<=de},xe,0);return xe=Ue(function(Je){return Zo(a,fe,Je).top>de},Fe,xe),{begin:Fe,end:xe}}function io(a,y,fe,de){fe||(fe=la(a,y));var xe=wa(a,y,Zo(a,fe,de),"line").top;return Qi(a,y,fe,xe)}function co(a,y,fe,de){return a.bottom<=fe?!1:a.top>fe?!0:(de?a.left:a.right)>y}function na(a,y,fe,de,xe){xe-=Xn(y);var Fe=la(a,y),Je=Sa(y),it=0,at=y.text.length,ht=!0,It=Nt(y,a.doc.direction);if(It){var Ut=(a.options.lineWrapping?ca:Go)(a,y,fe,Fe,It,de,xe);ht=Ut.level!=1,it=ht?Ut.from:Ut.to-1,at=ht?Ut.to:Ut.from-1}var rn=null,Qt=null,Dn=Ue(function(Qr){var Hr=Zo(a,Fe,Qr);return Hr.top+=Je,Hr.bottom+=Je,co(Hr,de,xe,!1)?(Hr.top<=xe&&Hr.left<=de&&(rn=Qr,Qt=Hr),!0):!1},it,at),Wn,Qn,sr=!1;if(Qt){var vr=de-Qt.left<Qt.right-de,lr=vr==ht;Dn=rn+(lr?0:1),Qn=lr?"after":"before",Wn=vr?Qt.left:Qt.right}else{!ht&&(Dn==at||Dn==it)&&Dn++,Qn=Dn==0?"after":Dn==y.text.length?"before":Zo(a,Fe,Dn-(ht?1:0)).bottom+Je<=xe==ht?"after":"before";var Er=Ji(a,Et(fe,Dn,Qn),"line",y,Fe);Wn=Er.left,sr=xe<Er.top?-1:xe>=Er.bottom?1:0}return Dn=Le(y.text,Dn,1),si(fe,Dn,Qn,sr,de-Wn)}function Go(a,y,fe,de,xe,Fe,Je){var it=Ue(function(Ut){var rn=xe[Ut],Qt=rn.level!=1;return co(Ji(a,Et(fe,Qt?rn.to:rn.from,Qt?"before":"after"),"line",y,de),Fe,Je,!0)},0,xe.length-1),at=xe[it];if(it>0){var ht=at.level!=1,It=Ji(a,Et(fe,ht?at.from:at.to,ht?"after":"before"),"line",y,de);co(It,Fe,Je,!0)&&It.top>Je&&(at=xe[it-1])}return at}function ca(a,y,fe,de,xe,Fe,Je){var it=Qi(a,y,de,Je),at=it.begin,ht=it.end;/\s/.test(y.text.charAt(ht-1))&&ht--;for(var It=null,Ut=null,rn=0;rn<xe.length;rn++){var Qt=xe[rn];if(!(Qt.from>=ht||Qt.to<=at)){var Dn=Qt.level!=1,Wn=Zo(a,de,Dn?Math.min(ht,Qt.to)-1:Math.max(at,Qt.from)).right,Qn=Wn<Fe?Fe-Wn+1e9:Wn-Fe;(!It||Ut>Qn)&&(It=Qt,Ut=Qn)}}return It||(It=xe[xe.length-1]),It.from<at&&(It={from:at,to:It.to,level:It.level}),It.to>ht&&(It={from:It.from,to:ht,level:It.level}),It}var $i;function go(a){if(a.cachedTextHeight!=null)return a.cachedTextHeight;if($i==null){$i=Oe("pre",null,"CodeMirror-line-like");for(var y=0;y<49;++y)$i.appendChild(document.createTextNode("x")),$i.appendChild(Oe("br"));$i.appendChild(document.createTextNode("x"))}Ee(a.measure,$i);var fe=$i.offsetHeight/50;return fe>3&&(a.cachedTextHeight=fe),Te(a.measure),fe||1}function Fo(a){if(a.cachedCharWidth!=null)return a.cachedCharWidth;var y=Oe("span","xxxxxxxxxx"),fe=Oe("pre",[y],"CodeMirror-line-like");Ee(a.measure,fe);var de=y.getBoundingClientRect(),xe=(de.right-de.left)/10;return xe>2&&(a.cachedCharWidth=xe),xe||10}function Xo(a){for(var y=a.display,fe={},de={},xe=y.gutters.clientLeft,Fe=y.gutters.firstChild,Je=0;Fe;Fe=Fe.nextSibling,++Je){var it=a.display.gutterSpecs[Je].className;fe[it]=Fe.offsetLeft+Fe.clientLeft+xe,de[it]=Fe.clientWidth}return{fixedPos:Ia(y),gutterTotalWidth:y.gutters.offsetWidth,gutterLeft:fe,gutterWidth:de,wrapperWidth:y.wrapper.clientWidth}}function Ia(a){return a.scroller.getBoundingClientRect().left-a.sizer.getBoundingClientRect().left}function ds(a){var y=go(a.display),fe=a.options.lineWrapping,de=fe&&Math.max(5,a.display.scroller.clientWidth/Fo(a.display)-3);return function(xe){if(Ln(a.doc,xe))return 0;var Fe=0;if(xe.widgets)for(var Je=0;Je<xe.widgets.length;Je++)xe.widgets[Je].height&&(Fe+=xe.widgets[Je].height);return fe?Fe+(Math.ceil(xe.text.length/de)||1)*y:Fe+y}}function fs(a){var y=a.doc,fe=ds(a);y.iter(function(de){var xe=fe(de);xe!=de.height&&Yn(de,xe)})}function da(a,y,fe,de){var xe=a.display;if(!fe&&Gn(y).getAttribute("cm-not-content")=="true")return null;var Fe,Je,it=xe.lineSpace.getBoundingClientRect();try{Fe=y.clientX-it.left,Je=y.clientY-it.top}catch(Ut){return null}var at=ro(a,Fe,Je),ht;if(de&&at.xRel>0&&(ht=Ft(a.doc,at.line).text).length==at.ch){var It=Ge(ht,ht.length,a.options.tabSize)-ht.length;at=Et(at.line,Math.max(0,Math.round((Fe-Io(a.display).left)/Fo(a.display))-It))}return at}function yo(a,y){if(y>=a.display.viewTo||(y-=a.display.viewFrom,y<0))return null;for(var fe=a.display.view,de=0;de<fe.length;de++)if(y-=fe[de].size,y<0)return de}function Co(a,y,fe,de){y==null&&(y=a.doc.first),fe==null&&(fe=a.doc.first+a.doc.size),de||(de=0);var xe=a.display;if(de&&fe<xe.viewTo&&(xe.updateLineNumbers==null||xe.updateLineNumbers>y)&&(xe.updateLineNumbers=y),a.curOp.viewChanged=!0,y>=xe.viewTo)ai&&fn(a.doc,y)<xe.viewTo&&Ko(a);else if(fe<=xe.viewFrom)ai&&vn(a.doc,fe+de)>xe.viewFrom?Ko(a):(xe.viewFrom+=de,xe.viewTo+=de);else if(y<=xe.viewFrom&&fe>=xe.viewTo)Ko(a);else if(y<=xe.viewFrom){var Fe=Qa(a,fe,fe+de,1);Fe?(xe.view=xe.view.slice(Fe.index),xe.viewFrom=Fe.lineN,xe.viewTo+=de):Ko(a)}else if(fe>=xe.viewTo){var Je=Qa(a,y,y,-1);Je?(xe.view=xe.view.slice(0,Je.index),xe.viewTo=Je.lineN):Ko(a)}else{var it=Qa(a,y,y,-1),at=Qa(a,fe,fe+de,1);it&&at?(xe.view=xe.view.slice(0,it.index).concat(Jr(a,it.lineN,at.lineN)).concat(xe.view.slice(at.index)),xe.viewTo+=de):Ko(a)}var ht=xe.externalMeasured;ht&&(fe<ht.lineN?ht.lineN+=de:y<ht.lineN+ht.size&&(xe.externalMeasured=null))}function Eo(a,y,fe){a.curOp.viewChanged=!0;var de=a.display,xe=a.display.externalMeasured;if(xe&&y>=xe.lineN&&y<xe.lineN+xe.size&&(de.externalMeasured=null),!(y<de.viewFrom||y>=de.viewTo)){var Fe=de.view[yo(a,y)];if(Fe.node!=null){var Je=Fe.changes||(Fe.changes=[]);Ve(Je,fe)==-1&&Je.push(fe)}}}function Ko(a){a.display.viewFrom=a.display.viewTo=a.doc.first,a.display.view=[],a.display.viewOffset=0}function Qa(a,y,fe,de){var xe=yo(a,y),Fe,Je=a.display.view;if(!ai||fe==a.doc.first+a.doc.size)return{index:xe,lineN:fe};for(var it=a.display.viewFrom,at=0;at<xe;at++)it+=Je[at].size;if(it!=y){if(de>0){if(xe==Je.length-1)return null;Fe=it+Je[xe].size-y,xe++}else Fe=it-y;y+=Fe,fe+=Fe}for(;fn(a.doc,fe)!=fe;){if(xe==(de<0?0:Je.length-1))return null;fe+=de*Je[xe-(de<0?1:0)].size,xe+=de}return{index:xe,lineN:fe}}function xa(a,y,fe){var de=a.display,xe=de.view;xe.length==0||y>=de.viewTo||fe<=de.viewFrom?(de.view=Jr(a,y,fe),de.viewFrom=y):(de.viewFrom>y?de.view=Jr(a,y,de.viewFrom).concat(de.view):de.viewFrom<y&&(de.view=de.view.slice(yo(a,y))),de.viewFrom=y,de.viewTo<fe?de.view=de.view.concat(Jr(a,de.viewTo,fe)):de.viewTo>fe&&(de.view=de.view.slice(0,yo(a,fe)))),de.viewTo=fe}function _s(a){for(var y=a.display.view,fe=0,de=0;de<y.length;de++){var xe=y[de];!xe.hidden&&(!xe.node||xe.changes)&&++fe}return fe}function Oa(a){a.display.input.showSelection(a.display.input.prepareSelection())}function bs(a,y){y===void 0&&(y=!0);for(var fe=a.doc,de={},xe=de.cursors=document.createDocumentFragment(),Fe=de.selection=document.createDocumentFragment(),Je=0;Je<fe.sel.ranges.length;Je++)if(!(!y&&Je==fe.sel.primIndex)){var it=fe.sel.ranges[Je];if(!(it.from().line>=a.display.viewTo||it.to().line<a.display.viewFrom)){var at=it.empty();(at||a.options.showCursorWhenSelecting)&&$a(a,it.head,xe),at||Ss(a,it,Fe)}}return de}function $a(a,y,fe){var de=Ji(a,y,"div",null,null,!a.options.singleCursorHeightPerLine),xe=fe.appendChild(Oe("div","\xA0","CodeMirror-cursor"));if(xe.style.left=de.left+"px",xe.style.top=de.top+"px",xe.style.height=Math.max(0,de.bottom-de.top)*a.options.cursorHeight+"px",de.other){var Fe=fe.appendChild(Oe("div","\xA0","CodeMirror-cursor CodeMirror-secondarycursor"));Fe.style.display="",Fe.style.left=de.other.left+"px",Fe.style.top=de.other.top+"px",Fe.style.height=(de.other.bottom-de.other.top)*.85+"px"}}function Ca(a,y){return a.top-y.top||a.left-y.left}function Ss(a,y,fe){var de=a.display,xe=a.doc,Fe=document.createDocumentFragment(),Je=Io(a.display),it=Je.left,at=Math.max(de.sizerWidth,Ho(a)-de.sizer.offsetLeft)-Je.right,ht=xe.direction=="ltr";function It(lr,Er,Qr,Hr){Er<0&&(Er=0),Er=Math.round(Er),Hr=Math.round(Hr),Fe.appendChild(Oe("div",null,"CodeMirror-selected","position: absolute; left: "+lr+`px;
|
|
|
top: `+Er+"px; width: "+(Qr==null?at-lr:Qr)+`px;
|
|
|
height: `+(Hr-Er)+"px"))}function Ut(lr,Er,Qr){var Hr=Ft(xe,lr),Li=Hr.text.length,to,Mo;function ho(So,ea){return To(a,Et(lr,So),"div",Hr,ea)}function sa(So,ea,Bo){var ko=io(a,Hr,null,So),wo=ea=="ltr"==(Bo=="after")?"left":"right",vo=Bo=="after"?ko.begin:ko.end-(/\s/.test(Hr.text.charAt(ko.end-1))?2:1);return ho(vo,wo)[wo]}var $o=Nt(Hr,xe.direction);return Me($o,Er||0,Qr==null?Li:Qr,function(So,ea,Bo,ko){var wo=Bo=="ltr",vo=ho(So,wo?"left":"right"),ta=ho(ea-1,wo?"right":"left"),Is=Er==null&&So==0,us=Qr==null&&ea==Li,zo=ko==0,Ua=!$o||ko==$o.length-1;if(ta.top-vo.top<=3){var Ro=(ht?Is:us)&&zo,xl=(ht?us:Is)&&Ua,Xa=Ro?it:(wo?vo:ta).left,gs=xl?at:(wo?ta:vo).right;It(Xa,vo.top,gs-Xa,vo.bottom)}else{var ys,Vo,Os,Cl;wo?(ys=ht&&Is&&zo?it:vo.left,Vo=ht?at:sa(So,Bo,"before"),Os=ht?it:sa(ea,Bo,"after"),Cl=ht&&us&&Ua?at:ta.right):(ys=ht?sa(So,Bo,"before"):it,Vo=!ht&&Is&&zo?at:vo.right,Os=!ht&&us&&Ua?it:ta.left,Cl=ht?sa(ea,Bo,"after"):at),It(ys,vo.top,Vo-ys,vo.bottom),vo.bottom<ta.top&&It(it,vo.bottom,null,ta.top),It(Os,ta.top,Cl-Os,ta.bottom)}(!to||Ca(vo,to)<0)&&(to=vo),Ca(ta,to)<0&&(to=ta),(!Mo||Ca(vo,Mo)<0)&&(Mo=vo),Ca(ta,Mo)<0&&(Mo=ta)}),{start:to,end:Mo}}var rn=y.from(),Qt=y.to();if(rn.line==Qt.line)Ut(rn.line,rn.ch,Qt.ch);else{var Dn=Ft(xe,rn.line),Wn=Ft(xe,Qt.line),Qn=un(Dn)==un(Wn),sr=Ut(rn.line,rn.ch,Qn?Dn.text.length+1:null).end,vr=Ut(Qt.line,Qn?0:null,Qt.ch).start;Qn&&(sr.top<vr.top-2?(It(sr.right,sr.top,null,sr.bottom),It(it,vr.top,vr.left,vr.bottom)):It(sr.right,sr.top,vr.left-sr.right,sr.bottom)),sr.bottom<vr.top&&It(it,sr.bottom,null,vr.top)}fe.appendChild(Fe)}function es(a){if(a.state.focused){var y=a.display;clearInterval(y.blinker);var fe=!0;y.cursorDiv.style.visibility="",a.options.cursorBlinkRate>0?y.blinker=setInterval(function(){a.hasFocus()||Ga(a),y.cursorDiv.style.visibility=(fe=!fe)?"":"hidden"},a.options.cursorBlinkRate):a.options.cursorBlinkRate<0&&(y.cursorDiv.style.visibility="hidden")}}function ra(a){a.state.focused||(a.display.input.focus(),Ea(a))}function Za(a){a.state.delayingBlurEvent=!0,setTimeout(function(){a.state.delayingBlurEvent&&(a.state.delayingBlurEvent=!1,Ga(a))},100)}function Ea(a,y){a.state.delayingBlurEvent&&(a.state.delayingBlurEvent=!1),a.options.readOnly!="nocursor"&&(a.state.focused||(jt(a,"focus",a,y),a.state.focused=!0,ot(a.display.wrapper,"CodeMirror-focused"),!a.curOp&&a.display.selForContextMenu!=a.doc.sel&&(a.display.input.reset(),le&&setTimeout(function(){return a.display.input.reset(!0)},20)),a.display.input.receivedFocus()),es(a))}function Ga(a,y){a.state.delayingBlurEvent||(a.state.focused&&(jt(a,"blur",a,y),a.state.focused=!1,ke(a.display.wrapper,"CodeMirror-focused")),clearInterval(a.display.blinker),setTimeout(function(){a.state.focused||(a.display.shift=!1)},150))}function ts(a){for(var y=a.display,fe=y.lineDiv.offsetTop,de=0;de<y.view.length;de++){var xe=y.view[de],Fe=a.options.lineWrapping,Je=void 0,it=0;if(!xe.hidden){if(se&&te<8){var at=xe.node.offsetTop+xe.node.offsetHeight;Je=at-fe,fe=at}else{var ht=xe.node.getBoundingClientRect();Je=ht.bottom-ht.top,!Fe&&xe.text.firstChild&&(it=xe.text.firstChild.getBoundingClientRect().right-ht.left-1)}var It=xe.line.height-Je;if((It>.005||It<-.005)&&(Yn(xe.line,Je),hs(xe.line),xe.rest))for(var Ut=0;Ut<xe.rest.length;Ut++)hs(xe.rest[Ut]);if(it>a.display.sizerWidth){var rn=Math.ceil(it/Fo(a.display));rn>a.display.maxLineLength&&(a.display.maxLineLength=rn,a.display.maxLine=xe.line,a.display.maxLineChanged=!0)}}}}function hs(a){if(a.widgets)for(var y=0;y<a.widgets.length;++y){var fe=a.widgets[y],de=fe.node.parentNode;de&&(fe.height=de.offsetHeight)}}function ka(a,y,fe){var de=fe&&fe.top!=null?Math.max(0,fe.top):a.scroller.scrollTop;de=Math.floor(de-ui(a));var xe=fe&&fe.bottom!=null?fe.bottom:de+a.wrapper.clientHeight,Fe=St(y,de),Je=St(y,xe);if(fe&&fe.ensure){var it=fe.ensure.from.line,at=fe.ensure.to.line;it<Fe?(Fe=it,Je=St(y,Xn(Ft(y,it))+a.wrapper.clientHeight)):Math.min(at,y.lastLine())>=Je&&(Fe=St(y,Xn(Ft(y,at))-a.wrapper.clientHeight),Je=at)}return{from:Fe,to:Math.max(Je,Fe+1)}}function ps(a,y){if(!yt(a,"scrollCursorIntoView")){var fe=a.display,de=fe.sizer.getBoundingClientRect(),xe=null;if(y.top+de.top<0?xe=!0:y.bottom+de.top>(window.innerHeight||document.documentElement.clientHeight)&&(xe=!1),xe!=null&&!x){var Fe=Oe("div","\u200B",null,`position: absolute;
|
|
|
top: `+(y.top-fe.viewOffset-ui(a.display))+`px;
|
|
|
height: `+(y.bottom-y.top+Ui(a)+fe.barHeight)+`px;
|
|
|
left: `+y.left+"px; width: "+Math.max(2,y.right-y.left)+"px;");a.display.lineSpace.appendChild(Fe),Fe.scrollIntoView(xe),a.display.lineSpace.removeChild(Fe)}}}function ms(a,y,fe,de){de==null&&(de=0);var xe;!a.options.lineWrapping&&y==fe&&(y=y.ch?Et(y.line,y.sticky=="before"?y.ch-1:y.ch,"after"):y,fe=y.sticky=="before"?Et(y.line,y.ch+1,"before"):y);for(var Fe=0;Fe<5;Fe++){var Je=!1,it=Ji(a,y),at=!fe||fe==y?it:Ji(a,fe);xe={left:Math.min(it.left,at.left),top:Math.min(it.top,at.top)-de,right:Math.max(it.left,at.left),bottom:Math.max(it.bottom,at.bottom)+de};var ht=ns(a,xe),It=a.doc.scrollTop,Ut=a.doc.scrollLeft;if(ht.scrollTop!=null&&(ia(a,ht.scrollTop),Math.abs(a.doc.scrollTop-It)>1&&(Je=!0)),ht.scrollLeft!=null&&(ma(a,ht.scrollLeft),Math.abs(a.doc.scrollLeft-Ut)>1&&(Je=!0)),!Je)break}return xe}function ws(a,y){var fe=ns(a,y);fe.scrollTop!=null&&ia(a,fe.scrollTop),fe.scrollLeft!=null&&ma(a,fe.scrollLeft)}function ns(a,y){var fe=a.display,de=go(a.display);y.top<0&&(y.top=0);var xe=a.curOp&&a.curOp.scrollTop!=null?a.curOp.scrollTop:fe.scroller.scrollTop,Fe=xo(a),Je={};y.bottom-y.top>Fe&&(y.bottom=y.top+Fe);var it=a.doc.height+no(fe),at=y.top<de,ht=y.bottom>it-de;if(y.top<xe)Je.scrollTop=at?0:y.top;else if(y.bottom>xe+Fe){var It=Math.min(y.top,(ht?it:y.bottom)-Fe);It!=xe&&(Je.scrollTop=It)}var Ut=a.options.fixedGutter?0:fe.gutters.offsetWidth,rn=a.curOp&&a.curOp.scrollLeft!=null?a.curOp.scrollLeft:fe.scroller.scrollLeft-Ut,Qt=Ho(a)-fe.gutters.offsetWidth,Dn=y.right-y.left>Qt;return Dn&&(y.right=y.left+Qt),y.left<10?Je.scrollLeft=0:y.left<rn?Je.scrollLeft=Math.max(0,y.left+Ut-(Dn?0:10)):y.right>Qt+rn-3&&(Je.scrollLeft=y.right+(Dn?0:10)-Qt),Je}function rs(a,y){y!=null&&(Pa(a),a.curOp.scrollTop=(a.curOp.scrollTop==null?a.doc.scrollTop:a.curOp.scrollTop)+y)}function La(a){Pa(a);var y=a.getCursor();a.curOp.scrollToPos={from:y,to:y,margin:a.options.cursorScrollMargin}}function Nr(a,y,fe){(y!=null||fe!=null)&&Pa(a),y!=null&&(a.curOp.scrollLeft=y),fe!=null&&(a.curOp.scrollTop=fe)}function xs(a,y){Pa(a),a.curOp.scrollToPos=y}function Pa(a){var y=a.curOp.scrollToPos;if(y){a.curOp.scrollToPos=null;var fe=vi(a,y.from),de=vi(a,y.to);vs(a,fe,de,y.margin)}}function vs(a,y,fe,de){var xe=ns(a,{left:Math.min(y.left,fe.left),top:Math.min(y.top,fe.top)-de,right:Math.max(y.right,fe.right),bottom:Math.max(y.bottom,fe.bottom)+de});Nr(a,xe.scrollLeft,xe.scrollTop)}function ia(a,y){Math.abs(a.doc.scrollTop-y)<2||(ce||yi(a,{top:y}),is(a,y,!0),ce&&yi(a),An(a,100))}function is(a,y,fe){y=Math.max(0,Math.min(a.display.scroller.scrollHeight-a.display.scroller.clientHeight,y)),!(a.display.scroller.scrollTop==y&&!fe)&&(a.doc.scrollTop=y,a.display.scrollbars.setScrollTop(y),a.display.scroller.scrollTop!=y&&(a.display.scroller.scrollTop=y))}function ma(a,y,fe,de){y=Math.max(0,Math.min(y,a.display.scroller.scrollWidth-a.display.scroller.clientWidth)),!((fe?y==a.doc.scrollLeft:Math.abs(a.doc.scrollLeft-y)<2)&&!de)&&(a.doc.scrollLeft=y,ki(a),a.display.scroller.scrollLeft!=y&&(a.display.scroller.scrollLeft=y),a.display.scrollbars.setScrollLeft(y))}function pi(a){var y=a.display,fe=y.gutters.offsetWidth,de=Math.round(a.doc.height+no(a.display));return{clientHeight:y.scroller.clientHeight,viewHeight:y.wrapper.clientHeight,scrollWidth:y.scroller.scrollWidth,clientWidth:y.scroller.clientWidth,viewWidth:y.wrapper.clientWidth,barLeft:a.options.fixedGutter?fe:0,docHeight:de,scrollHeight:de+Ui(a)+y.barHeight,nativeBarWidth:y.nativeBarWidth,gutterWidth:fe}}var _r=function(a,y,fe){this.cm=fe;var de=this.vert=Oe("div",[Oe("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),xe=this.horiz=Oe("div",[Oe("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");de.tabIndex=xe.tabIndex=-1,a(de),a(xe),vt(de,"scroll",function(){de.clientHeight&&y(de.scrollTop,"vertical")}),vt(xe,"scroll",function(){xe.clientWidth&&y(xe.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,se&&te<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};_r.prototype.update=function(a){var y=a.scrollWidth>a.clientWidth+1,fe=a.scrollHeight>a.clientHeight+1,de=a.nativeBarWidth;if(fe){this.vert.style.display="block",this.vert.style.bottom=y?de+"px":"0";var xe=a.viewHeight-(y?de:0);this.vert.firstChild.style.height=Math.max(0,a.scrollHeight-a.clientHeight+xe)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(y){this.horiz.style.display="block",this.horiz.style.right=fe?de+"px":"0",this.horiz.style.left=a.barLeft+"px";var Fe=a.viewWidth-a.barLeft-(fe?de:0);this.horiz.firstChild.style.width=Math.max(0,a.scrollWidth-a.clientWidth+Fe)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&a.clientHeight>0&&(de==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:fe?de:0,bottom:y?de:0}},_r.prototype.setScrollLeft=function(a){this.horiz.scrollLeft!=a&&(this.horiz.scrollLeft=a),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},_r.prototype.setScrollTop=function(a){this.vert.scrollTop!=a&&(this.vert.scrollTop=a),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},_r.prototype.zeroWidthHack=function(){var a=ve&&!z?"12px":"18px";this.horiz.style.height=this.vert.style.width=a,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new ze,this.disableVert=new ze},_r.prototype.enableZeroWidthBar=function(a,y,fe){a.style.pointerEvents="auto";function de(){var xe=a.getBoundingClientRect(),Fe=fe=="vert"?document.elementFromPoint(xe.right-1,(xe.top+xe.bottom)/2):document.elementFromPoint((xe.right+xe.left)/2,xe.bottom-1);Fe!=a?a.style.pointerEvents="none":y.set(1e3,de)}y.set(1e3,de)},_r.prototype.clear=function(){var a=this.horiz.parentNode;a.removeChild(this.horiz),a.removeChild(this.vert)};var Ei=function(){};Ei.prototype.update=function(){return{bottom:0,right:0}},Ei.prototype.setScrollLeft=function(){},Ei.prototype.setScrollTop=function(){},Ei.prototype.clear=function(){};function bo(a,y){y||(y=pi(a));var fe=a.display.barWidth,de=a.display.barHeight;Ni(a,y);for(var xe=0;xe<4&&fe!=a.display.barWidth||de!=a.display.barHeight;xe++)fe!=a.display.barWidth&&a.options.lineWrapping&&ts(a),Ni(a,pi(a)),fe=a.display.barWidth,de=a.display.barHeight}function Ni(a,y){var fe=a.display,de=fe.scrollbars.update(y);fe.sizer.style.paddingRight=(fe.barWidth=de.right)+"px",fe.sizer.style.paddingBottom=(fe.barHeight=de.bottom)+"px",fe.heightForcer.style.borderBottom=de.bottom+"px solid transparent",de.right&&de.bottom?(fe.scrollbarFiller.style.display="block",fe.scrollbarFiller.style.height=de.bottom+"px",fe.scrollbarFiller.style.width=de.right+"px"):fe.scrollbarFiller.style.display="",de.bottom&&a.options.coverGutterNextToScrollbar&&a.options.fixedGutter?(fe.gutterFiller.style.display="block",fe.gutterFiller.style.height=de.bottom+"px",fe.gutterFiller.style.width=y.gutterWidth+"px"):fe.gutterFiller.style.display=""}var Na={native:_r,null:Ei};function va(a){a.display.scrollbars&&(a.display.scrollbars.clear(),a.display.scrollbars.addClass&&ke(a.display.wrapper,a.display.scrollbars.addClass)),a.display.scrollbars=new Na[a.options.scrollbarStyle](function(y){a.display.wrapper.insertBefore(y,a.display.scrollbarFiller),vt(y,"mousedown",function(){a.state.focused&&setTimeout(function(){return a.display.input.focus()},0)}),y.setAttribute("cm-not-content","true")},function(y,fe){fe=="horizontal"?ma(a,y):ia(a,y)},a),a.display.scrollbars.addClass&&ot(a.display.wrapper,a.display.scrollbars.addClass)}var Aa=0;function Po(a){a.curOp={cm:a,viewChanged:!1,startHeight:a.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:++Aa},ao(a.curOp)}function fa(a){var y=a.curOp;y&&Lo(y,function(fe){for(var de=0;de<fe.ops.length;de++)fe.ops[de].cm.curOp=null;sl(fe)})}function sl(a){for(var y=a.ops,fe=0;fe<y.length;fe++)ll(y[fe]);for(var de=0;de<y.length;de++)ul(y[de]);for(var xe=0;xe<y.length;xe++)cl(y[xe]);for(var Fe=0;Fe<y.length;Fe++)ft(y[Fe]);for(var Je=0;Je<y.length;Je++)bt(y[Je])}function ll(a){var y=a.cm,fe=y.display;qn(y),a.updateMaxLine&&nr(y),a.mustUpdate=a.viewChanged||a.forceUpdate||a.scrollTop!=null||a.scrollToPos&&(a.scrollToPos.from.line<fe.viewFrom||a.scrollToPos.to.line>=fe.viewTo)||fe.maxLineChanged&&y.options.lineWrapping,a.update=a.mustUpdate&&new On(y,a.mustUpdate&&{top:a.scrollTop,ensure:a.scrollToPos},a.forceUpdate)}function ul(a){a.updatedDisplay=a.mustUpdate&&gi(a.cm,a.update)}function cl(a){var y=a.cm,fe=y.display;a.updatedDisplay&&ts(y),a.barMeasure=pi(y),fe.maxLineChanged&&!y.options.lineWrapping&&(a.adjustWidthTo=za(y,fe.maxLine,fe.maxLine.text.length).left+3,y.display.sizerWidth=a.adjustWidthTo,a.barMeasure.scrollWidth=Math.max(fe.scroller.clientWidth,fe.sizer.offsetLeft+a.adjustWidthTo+Ui(y)+y.display.barWidth),a.maxScrollLeft=Math.max(0,fe.sizer.offsetLeft+a.adjustWidthTo-Ho(y))),(a.updatedDisplay||a.selectionChanged)&&(a.preparedSelection=fe.input.prepareSelection())}function ft(a){var y=a.cm;a.adjustWidthTo!=null&&(y.display.sizer.style.minWidth=a.adjustWidthTo+"px",a.maxScrollLeft<y.doc.scrollLeft&&ma(y,Math.min(y.display.scroller.scrollLeft,a.maxScrollLeft),!0),y.display.maxLineChanged=!1);var fe=a.focus&&a.focus==Xe();a.preparedSelection&&y.display.input.showSelection(a.preparedSelection,fe),(a.updatedDisplay||a.startHeight!=y.doc.height)&&bo(y,a.barMeasure),a.updatedDisplay&&ri(y,a.barMeasure),a.selectionChanged&&es(y),y.state.focused&&a.updateInput&&y.display.input.reset(a.typing),fe&&ra(a.cm)}function bt(a){var y=a.cm,fe=y.display,de=y.doc;if(a.updatedDisplay&&kr(y,a.update),fe.wheelStartX!=null&&(a.scrollTop!=null||a.scrollLeft!=null||a.scrollToPos)&&(fe.wheelStartX=fe.wheelStartY=null),a.scrollTop!=null&&is(y,a.scrollTop,a.forceScroll),a.scrollLeft!=null&&ma(y,a.scrollLeft,!0,!0),a.scrollToPos){var xe=ms(y,Tt(de,a.scrollToPos.from),Tt(de,a.scrollToPos.to),a.scrollToPos.margin);ps(y,xe)}var Fe=a.maybeHiddenMarkers,Je=a.maybeUnhiddenMarkers;if(Fe)for(var it=0;it<Fe.length;++it)Fe[it].lines.length||jt(Fe[it],"hide");if(Je)for(var at=0;at<Je.length;++at)Je[at].lines.length&&jt(Je[at],"unhide");fe.wrapper.offsetHeight&&(de.scrollTop=y.display.scroller.scrollTop),a.changeObjs&&jt(y,"changes",y,a.changeObjs),a.update&&a.update.finish()}function wt(a,y){if(a.curOp)return y();Po(a);try{return y()}finally{fa(a)}}function Vn(a,y){return function(){if(a.curOp)return y.apply(a,arguments);Po(a);try{return y.apply(a,arguments)}finally{fa(a)}}}function In(a){return function(){if(this.curOp)return a.apply(this,arguments);Po(this);try{return a.apply(this,arguments)}finally{fa(this)}}}function pn(a){return function(){var y=this.cm;if(!y||y.curOp)return a.apply(this,arguments);Po(y);try{return a.apply(this,arguments)}finally{fa(y)}}}function An(a,y){a.doc.highlightFrontier<a.display.viewTo&&a.state.highlight.set(y,Ye(xn,a))}function xn(a){var y=a.doc;if(!(y.highlightFrontier>=a.display.viewTo)){var fe=+new Date+a.options.workTime,de=Rr(a,y.highlightFrontier),xe=[];y.iter(de.line,Math.min(y.first+y.size,a.display.viewTo+500),function(Fe){if(de.line>=a.display.viewFrom){var Je=Fe.styles,it=Fe.text.length>a.options.maxHighlightLength?st(y.mode,de.state):null,at=rr(a,Fe,de,!0);it&&(de.state=it),Fe.styles=at.styles;var ht=Fe.styleClasses,It=at.classes;It?Fe.styleClasses=It:ht&&(Fe.styleClasses=null);for(var Ut=!Je||Je.length!=Fe.styles.length||ht!=It&&(!ht||!It||ht.bgClass!=It.bgClass||ht.textClass!=It.textClass),rn=0;!Ut&&rn<Je.length;++rn)Ut=Je[rn]!=Fe.styles[rn];Ut&&xe.push(de.line),Fe.stateAfter=de.save(),de.nextLine()}else Fe.text.length<=a.options.maxHighlightLength&&wr(a,Fe.text,de),Fe.stateAfter=de.line%5==0?de.save():null,de.nextLine();if(+new Date>fe)return An(a,a.options.workDelay),!0}),y.highlightFrontier=de.line,y.modeFrontier=Math.max(y.modeFrontier,de.line),xe.length&&wt(a,function(){for(var Fe=0;Fe<xe.length;Fe++)Eo(a,xe[Fe],"text")})}}var On=function(a,y,fe){var de=a.display;this.viewport=y,this.visible=ka(de,a.doc,y),this.editorIsHidden=!de.wrapper.offsetWidth,this.wrapperHeight=de.wrapper.clientHeight,this.wrapperWidth=de.wrapper.clientWidth,this.oldDisplayWidth=Ho(a),this.force=fe,this.dims=Xo(a),this.events=[]};On.prototype.signal=function(a,y){Lt(a,y)&&this.events.push(arguments)},On.prototype.finish=function(){for(var a=0;a<this.events.length;a++)jt.apply(null,this.events[a])};function qn(a){var y=a.display;!y.scrollbarsClipped&&y.scroller.offsetWidth&&(y.nativeBarWidth=y.scroller.offsetWidth-y.scroller.clientWidth,y.heightForcer.style.height=Ui(a)+"px",y.sizer.style.marginBottom=-y.nativeBarWidth+"px",y.sizer.style.borderRightWidth=Ui(a)+"px",y.scrollbarsClipped=!0)}function ci(a){if(a.hasFocus())return null;var y=Xe();if(!y||!Qe(a.display.lineDiv,y))return null;var fe={activeElt:y};if(window.getSelection){var de=window.getSelection();de.anchorNode&&de.extend&&Qe(a.display.lineDiv,de.anchorNode)&&(fe.anchorNode=de.anchorNode,fe.anchorOffset=de.anchorOffset,fe.focusNode=de.focusNode,fe.focusOffset=de.focusOffset)}return fe}function Pr(a){if(!(!a||!a.activeElt||a.activeElt==Xe())&&(a.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(a.activeElt.nodeName)&&a.anchorNode&&Qe(document.body,a.anchorNode)&&Qe(document.body,a.focusNode))){var y=window.getSelection(),fe=document.createRange();fe.setEnd(a.anchorNode,a.anchorOffset),fe.collapse(!1),y.removeAllRanges(),y.addRange(fe),y.extend(a.focusNode,a.focusOffset)}}function gi(a,y){var fe=a.display,de=a.doc;if(y.editorIsHidden)return Ko(a),!1;if(!y.force&&y.visible.from>=fe.viewFrom&&y.visible.to<=fe.viewTo&&(fe.updateLineNumbers==null||fe.updateLineNumbers>=fe.viewTo)&&fe.renderedView==fe.view&&_s(a)==0)return!1;Zi(a)&&(Ko(a),y.dims=Xo(a));var xe=de.first+de.size,Fe=Math.max(y.visible.from-a.options.viewportMargin,de.first),Je=Math.min(xe,y.visible.to+a.options.viewportMargin);fe.viewFrom<Fe&&Fe-fe.viewFrom<20&&(Fe=Math.max(de.first,fe.viewFrom)),fe.viewTo>Je&&fe.viewTo-Je<20&&(Je=Math.min(xe,fe.viewTo)),ai&&(Fe=fn(a.doc,Fe),Je=vn(a.doc,Je));var it=Fe!=fe.viewFrom||Je!=fe.viewTo||fe.lastWrapHeight!=y.wrapperHeight||fe.lastWrapWidth!=y.wrapperWidth;xa(a,Fe,Je),fe.viewOffset=Xn(Ft(a.doc,fe.viewFrom)),a.display.mover.style.top=fe.viewOffset+"px";var at=_s(a);if(!it&&at==0&&!y.force&&fe.renderedView==fe.view&&(fe.updateLineNumbers==null||fe.updateLineNumbers>=fe.viewTo))return!1;var ht=ci(a);return at>4&&(fe.lineDiv.style.display="none"),Br(a,fe.updateLineNumbers,y.dims),at>4&&(fe.lineDiv.style.display=""),fe.renderedView=fe.view,Pr(ht),Te(fe.cursorDiv),Te(fe.selectionDiv),fe.gutters.style.height=fe.sizer.style.minHeight=0,it&&(fe.lastWrapHeight=y.wrapperHeight,fe.lastWrapWidth=y.wrapperWidth,An(a,400)),fe.updateLineNumbers=null,!0}function kr(a,y){for(var fe=y.viewport,de=!0;;de=!1){if(!de||!a.options.lineWrapping||y.oldDisplayWidth==Ho(a)){if(fe&&fe.top!=null&&(fe={top:Math.min(a.doc.height+no(a.display)-xo(a),fe.top)}),y.visible=ka(a.display,a.doc,fe),y.visible.from>=a.display.viewFrom&&y.visible.to<=a.display.viewTo)break}else de&&(y.visible=ka(a.display,a.doc,fe));if(!gi(a,y))break;ts(a);var xe=pi(a);Oa(a),bo(a,xe),ri(a,xe),y.force=!1}y.signal(a,"update",a),(a.display.viewFrom!=a.display.reportedViewFrom||a.display.viewTo!=a.display.reportedViewTo)&&(y.signal(a,"viewportChange",a,a.display.viewFrom,a.display.viewTo),a.display.reportedViewFrom=a.display.viewFrom,a.display.reportedViewTo=a.display.viewTo)}function yi(a,y){var fe=new On(a,y);if(gi(a,fe)){ts(a),kr(a,fe);var de=pi(a);Oa(a),bo(a,de),ri(a,de),fe.finish()}}function Br(a,y,fe){var de=a.display,xe=a.options.lineNumbers,Fe=de.lineDiv,Je=Fe.firstChild;function it(Dn){var Wn=Dn.nextSibling;return le&&ve&&a.display.currentWheelTarget==Dn?Dn.style.display="none":Dn.parentNode.removeChild(Dn),Wn}for(var at=de.view,ht=de.viewFrom,It=0;It<at.length;It++){var Ut=at[It];if(!Ut.hidden)if(!Ut.node||Ut.node.parentNode!=Fe){var rn=Zr(a,Ut,ht,fe);Fe.insertBefore(rn,Je)}else{for(;Je!=Ut.node;)Je=it(Je);var Qt=xe&&y!=null&&y<=ht&&Ut.lineNumber;Ut.changes&&(Ve(Ut.changes,"gutter")>-1&&(Qt=!1),Pi(a,Ut,ht,fe)),Qt&&(Te(Ut.lineNumber),Ut.lineNumber.appendChild(document.createTextNode(Wt(a.options,ht)))),Je=Ut.node.nextSibling}ht+=Ut.size}for(;Je;)Je=it(Je)}function zi(a){var y=a.gutters.offsetWidth;a.sizer.style.marginLeft=y+"px"}function ri(a,y){a.display.sizer.style.minHeight=y.docHeight+"px",a.display.heightForcer.style.top=y.docHeight+"px",a.display.gutters.style.height=y.docHeight+a.display.barHeight+Ui(a)+"px"}function ki(a){var y=a.display,fe=y.view;if(!(!y.alignWidgets&&(!y.gutters.firstChild||!a.options.fixedGutter))){for(var de=Ia(y)-y.scroller.scrollLeft+a.doc.scrollLeft,xe=y.gutters.offsetWidth,Fe=de+"px",Je=0;Je<fe.length;Je++)if(!fe[Je].hidden){a.options.fixedGutter&&(fe[Je].gutter&&(fe[Je].gutter.style.left=Fe),fe[Je].gutterBackground&&(fe[Je].gutterBackground.style.left=Fe));var it=fe[Je].alignable;if(it)for(var at=0;at<it.length;at++)it[at].style.left=Fe}a.options.fixedGutter&&(y.gutters.style.left=de+xe+"px")}}function Zi(a){if(!a.options.lineNumbers)return!1;var y=a.doc,fe=Wt(a.options,y.first+y.size-1),de=a.display;if(fe.length!=de.lineNumChars){var xe=de.measure.appendChild(Oe("div",[Oe("div",fe)],"CodeMirror-linenumber CodeMirror-gutter-elt")),Fe=xe.firstChild.offsetWidth,Je=xe.offsetWidth-Fe;return de.lineGutter.style.width="",de.lineNumInnerWidth=Math.max(Fe,de.lineGutter.offsetWidth-Je)+1,de.lineNumWidth=de.lineNumInnerWidth+Je,de.lineNumChars=de.lineNumInnerWidth?fe.length:-1,de.lineGutter.style.width=de.lineNumWidth+"px",zi(a.display),!0}return!1}function ii(a,y){for(var fe=[],de=!1,xe=0;xe<a.length;xe++){var Fe=a[xe],Je=null;if(typeof Fe!="string"&&(Je=Fe.style,Fe=Fe.className),Fe=="CodeMirror-linenumbers")if(y)de=!0;else continue;fe.push({className:Fe,style:Je})}return y&&!de&&fe.push({className:"CodeMirror-linenumbers",style:null}),fe}function Ti(a){var y=a.gutters,fe=a.gutterSpecs;Te(y),a.lineGutter=null;for(var de=0;de<fe.length;++de){var xe=fe[de],Fe=xe.className,Je=xe.style,it=y.appendChild(Oe("div",null,"CodeMirror-gutter "+Fe));Je&&(it.style.cssText=Je),Fe=="CodeMirror-linenumbers"&&(a.lineGutter=it,it.style.width=(a.lineNumWidth||1)+"px")}y.style.display=fe.length?"":"none",zi(a)}function er(a){Ti(a.display),Co(a),ki(a)}function Bi(a,y,fe,de){var xe=this;this.input=fe,xe.scrollbarFiller=Oe("div",null,"CodeMirror-scrollbar-filler"),xe.scrollbarFiller.setAttribute("cm-not-content","true"),xe.gutterFiller=Oe("div",null,"CodeMirror-gutter-filler"),xe.gutterFiller.setAttribute("cm-not-content","true"),xe.lineDiv=je("div",null,"CodeMirror-code"),xe.selectionDiv=Oe("div",null,null,"position: relative; z-index: 1"),xe.cursorDiv=Oe("div",null,"CodeMirror-cursors"),xe.measure=Oe("div",null,"CodeMirror-measure"),xe.lineMeasure=Oe("div",null,"CodeMirror-measure"),xe.lineSpace=je("div",[xe.measure,xe.lineMeasure,xe.selectionDiv,xe.cursorDiv,xe.lineDiv],null,"position: relative; outline: none");var Fe=je("div",[xe.lineSpace],"CodeMirror-lines");xe.mover=Oe("div",[Fe],null,"position: relative"),xe.sizer=Oe("div",[xe.mover],"CodeMirror-sizer"),xe.sizerWidth=null,xe.heightForcer=Oe("div",null,null,"position: absolute; height: "+$e+"px; width: 1px;"),xe.gutters=Oe("div",null,"CodeMirror-gutters"),xe.lineGutter=null,xe.scroller=Oe("div",[xe.sizer,xe.heightForcer,xe.gutters],"CodeMirror-scroll"),xe.scroller.setAttribute("tabIndex","-1"),xe.wrapper=Oe("div",[xe.scrollbarFiller,xe.gutterFiller,xe.scroller],"CodeMirror"),se&&te<8&&(xe.gutters.style.zIndex=-1,xe.scroller.style.paddingRight=0),!le&&!(ce&&oe)&&(xe.scroller.draggable=!0),a&&(a.appendChild?a.appendChild(xe.wrapper):a(xe.wrapper)),xe.viewFrom=xe.viewTo=y.first,xe.reportedViewFrom=xe.reportedViewTo=y.first,xe.view=[],xe.renderedView=null,xe.externalMeasured=null,xe.viewOffset=0,xe.lastWrapHeight=xe.lastWrapWidth=0,xe.updateLineNumbers=null,xe.nativeBarWidth=xe.barHeight=xe.barWidth=0,xe.scrollbarsClipped=!1,xe.lineNumWidth=xe.lineNumInnerWidth=xe.lineNumChars=null,xe.alignWidgets=!1,xe.cachedCharWidth=xe.cachedTextHeight=xe.cachedPaddingH=null,xe.maxLine=null,xe.maxLineLength=0,xe.maxLineChanged=!1,xe.wheelDX=xe.wheelDY=xe.wheelStartX=xe.wheelStartY=null,xe.shift=!1,xe.selForContextMenu=null,xe.activeTouch=null,xe.gutterSpecs=ii(de.gutters,de.lineNumbers),Ti(xe),fe.init(xe)}var Si=0,Mi=null;se?Mi=-.53:ce?Mi=15:ne?Mi=-.7:b&&(Mi=-1/3);function No(a){var y=a.wheelDeltaX,fe=a.wheelDeltaY;return y==null&&a.detail&&a.axis==a.HORIZONTAL_AXIS&&(y=a.detail),fe==null&&a.detail&&a.axis==a.VERTICAL_AXIS?fe=a.detail:fe==null&&(fe=a.wheelDelta),{x:y,y:fe}}function mr(a){var y=No(a);return y.x*=Mi,y.y*=Mi,y}function Gi(a,y){var fe=No(y),de=fe.x,xe=fe.y,Fe=a.display,Je=Fe.scroller,it=Je.scrollWidth>Je.clientWidth,at=Je.scrollHeight>Je.clientHeight;if(de&&it||xe&&at){if(xe&&ve&&le){e:for(var ht=y.target,It=Fe.view;ht!=Je;ht=ht.parentNode)for(var Ut=0;Ut<It.length;Ut++)if(It[Ut].node==ht){a.display.currentWheelTarget=ht;break e}}if(de&&!ce&&!E&&Mi!=null){xe&&at&&ia(a,Math.max(0,Je.scrollTop+xe*Mi)),ma(a,Math.max(0,Je.scrollLeft+de*Mi)),(!xe||xe&&at)&&sn(y),Fe.wheelStartX=null;return}if(xe&&Mi!=null){var rn=xe*Mi,Qt=a.doc.scrollTop,Dn=Qt+Fe.wrapper.clientHeight;rn<0?Qt=Math.max(0,Qt+rn-50):Dn=Math.min(a.doc.height,Dn+rn+50),yi(a,{top:Qt,bottom:Dn})}Si<20&&(Fe.wheelStartX==null?(Fe.wheelStartX=Je.scrollLeft,Fe.wheelStartY=Je.scrollTop,Fe.wheelDX=de,Fe.wheelDY=xe,setTimeout(function(){if(Fe.wheelStartX!=null){var Wn=Je.scrollLeft-Fe.wheelStartX,Qn=Je.scrollTop-Fe.wheelStartY,sr=Qn&&Fe.wheelDY&&Qn/Fe.wheelDY||Wn&&Fe.wheelDX&&Wn/Fe.wheelDX;Fe.wheelStartX=Fe.wheelStartY=null,sr&&(Mi=(Mi*Si+sr)/(Si+1),++Si)}},200)):(Fe.wheelDX+=de,Fe.wheelDY+=xe))}}var li=function(a,y){this.ranges=a,this.primIndex=y};li.prototype.primary=function(){return this.ranges[this.primIndex]},li.prototype.equals=function(a){if(a==this)return!0;if(a.primIndex!=this.primIndex||a.ranges.length!=this.ranges.length)return!1;for(var y=0;y<this.ranges.length;y++){var fe=this.ranges[y],de=a.ranges[y];if(!tn(fe.anchor,de.anchor)||!tn(fe.head,de.head))return!1}return!0},li.prototype.deepCopy=function(){for(var a=[],y=0;y<this.ranges.length;y++)a[y]=new Sr(nn(this.ranges[y].anchor),nn(this.ranges[y].head));return new li(a,this.primIndex)},li.prototype.somethingSelected=function(){for(var a=0;a<this.ranges.length;a++)if(!this.ranges[a].empty())return!0;return!1},li.prototype.contains=function(a,y){y||(y=a);for(var fe=0;fe<this.ranges.length;fe++){var de=this.ranges[fe];if(zt(y,de.from())>=0&&zt(a,de.to())<=0)return fe}return-1};var Sr=function(a,y){this.anchor=a,this.head=y};Sr.prototype.from=function(){return Sn(this.anchor,this.head)},Sr.prototype.to=function(){return gn(this.anchor,this.head)},Sr.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function Fr(a,y,fe){var de=a&&a.options.selectionsMayTouch,xe=y[fe];y.sort(function(rn,Qt){return zt(rn.from(),Qt.from())}),fe=Ve(y,xe);for(var Fe=1;Fe<y.length;Fe++){var Je=y[Fe],it=y[Fe-1],at=zt(it.to(),Je.from());if(de&&!Je.empty()?at>0:at>=0){var ht=Sn(it.from(),Je.from()),It=gn(it.to(),Je.to()),Ut=it.empty()?Je.from()==Je.head:it.from()==it.head;Fe<=fe&&--fe,y.splice(--Fe,2,new Sr(Ut?It:ht,Ut?ht:It))}}return new li(y,fe)}function mi(a,y){return new li([new Sr(a,y||a)],0)}function Mr(a){return a.text?Et(a.from.line+a.text.length-1,xt(a.text).length+(a.text.length==1?a.from.ch:0)):a.to}function qo(a,y){if(zt(a,y.from)<0)return a;if(zt(a,y.to)<=0)return Mr(y);var fe=a.line+y.text.length-(y.to.line-y.from.line)-1,de=a.ch;return a.line==y.to.line&&(de+=Mr(y).ch-y.to.ch),Et(fe,de)}function so(a,y){for(var fe=[],de=0;de<a.sel.ranges.length;de++){var xe=a.sel.ranges[de];fe.push(new Sr(qo(xe.anchor,y),qo(xe.head,y)))}return Fr(a.cm,fe,a.sel.primIndex)}function oa(a,y,fe){return a.line==y.line?Et(fe.line,a.ch-y.ch+fe.ch):Et(fe.line+(a.line-y.line),a.ch)}function os(a,y,fe){for(var de=[],xe=Et(a.first,0),Fe=xe,Je=0;Je<y.length;Je++){var it=y[Je],at=oa(it.from,xe,Fe),ht=oa(Mr(it),xe,Fe);if(xe=it.to,Fe=ht,fe=="around"){var It=a.sel.ranges[Je],Ut=zt(It.head,It.anchor)<0;de[Je]=new Sr(Ut?ht:at,Ut?at:ht)}else de[Je]=new Sr(at,at)}return new li(de,a.sel.primIndex)}function aa(a){a.doc.mode=Ie(a.options,a.doc.modeOption),ga(a)}function ga(a){a.doc.iter(function(y){y.stateAfter&&(y.stateAfter=null),y.styles&&(y.styles=null)}),a.doc.modeFrontier=a.doc.highlightFrontier=a.doc.first,An(a,100),a.state.modeGen++,a.curOp&&Co(a)}function oi(a,y){return y.from.ch==0&&y.to.ch==0&&xt(y.text)==""&&(!a.cm||a.cm.options.wholeLineUpdateBefore)}function Ai(a,y,fe,de){function xe(vr){return fe?fe[vr]:null}function Fe(vr,lr,Er){Tr(vr,lr,Er,de),Ri(vr,"change",vr,y)}function Je(vr,lr){for(var Er=[],Qr=vr;Qr<lr;++Qr)Er.push(new Cr(ht[Qr],xe(Qr),de));return Er}var it=y.from,at=y.to,ht=y.text,It=Ft(a,it.line),Ut=Ft(a,at.line),rn=xt(ht),Qt=xe(ht.length-1),Dn=at.line-it.line;if(y.full)a.insert(0,Je(0,ht.length)),a.remove(ht.length,a.size-ht.length);else if(oi(a,y)){var Wn=Je(0,ht.length-1);Fe(Ut,Ut.text,Qt),Dn&&a.remove(it.line,Dn),Wn.length&&a.insert(it.line,Wn)}else if(It==Ut)if(ht.length==1)Fe(It,It.text.slice(0,it.ch)+rn+It.text.slice(at.ch),Qt);else{var Qn=Je(1,ht.length-1);Qn.push(new Cr(rn+It.text.slice(at.ch),Qt,de)),Fe(It,It.text.slice(0,it.ch)+ht[0],xe(0)),a.insert(it.line+1,Qn)}else if(ht.length==1)Fe(It,It.text.slice(0,it.ch)+ht[0]+Ut.text.slice(at.ch),xe(0)),a.remove(it.line+1,Dn);else{Fe(It,It.text.slice(0,it.ch)+ht[0],xe(0)),Fe(Ut,rn+Ut.text.slice(at.ch),Qt);var sr=Je(1,ht.length-1);Dn>1&&a.remove(it.line+1,Dn-1),a.insert(it.line+1,sr)}Ri(a,"change",a,y)}function oo(a,y,fe){function de(xe,Fe,Je){if(xe.linked)for(var it=0;it<xe.linked.length;++it){var at=xe.linked[it];if(at.doc!=Fe){var ht=Je&&at.sharedHist;fe&&!ht||(y(at.doc,ht),de(at.doc,xe,ht))}}}de(a,null,!0)}function Ba(a,y){if(y.cm)throw new Error("This document is already in use.");a.doc=y,y.cm=a,fs(a),aa(a),jo(a),a.options.lineWrapping||nr(a),a.options.mode=y.modeOption,Co(a)}function jo(a){(a.doc.direction=="rtl"?ot:ke)(a.display.lineDiv,"CodeMirror-rtl")}function Cs(a){wt(a,function(){jo(a),Co(a)})}function Jo(a){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=a||1}function lo(a,y){var fe={from:nn(y.from),to:Mr(y),text:qt(a,y.from,y.to)};return Do(a,fe,y.from.line,y.to.line+1),oo(a,function(de){return Do(de,fe,y.from.line,y.to.line+1)},!0),fe}function Fa(a){for(;a.length;){var y=xt(a);if(y.ranges)a.pop();else break}}function dl(a,y){if(y)return Fa(a.done),xt(a.done);if(a.done.length&&!xt(a.done).ranges)return xt(a.done);if(a.done.length>1&&!a.done[a.done.length-2].ranges)return a.done.pop(),xt(a.done)}function Xs(a,y,fe,de){var xe=a.history;xe.undone.length=0;var Fe=+new Date,Je,it;if((xe.lastOp==de||xe.lastOrigin==y.origin&&y.origin&&(y.origin.charAt(0)=="+"&&xe.lastModTime>Fe-(a.cm?a.cm.options.historyEventDelay:500)||y.origin.charAt(0)=="*"))&&(Je=dl(xe,xe.lastOp==de)))it=xt(Je.changes),zt(y.from,y.to)==0&&zt(y.from,it.to)==0?it.to=Mr(y):Je.changes.push(lo(a,y));else{var at=xt(xe.done);for((!at||!at.ranges)&&eo(a.sel,xe.done),Je={changes:[lo(a,y)],generation:xe.generation},xe.done.push(Je);xe.done.length>xe.undoDepth;)xe.done.shift(),xe.done[0].ranges||xe.done.shift()}xe.done.push(fe),xe.generation=++xe.maxGeneration,xe.lastModTime=xe.lastSelTime=Fe,xe.lastOp=xe.lastSelOp=de,xe.lastOrigin=xe.lastSelOrigin=y.origin,it||jt(a,"historyAdded")}function fl(a,y,fe,de){var xe=y.charAt(0);return xe=="*"||xe=="+"&&fe.ranges.length==de.ranges.length&&fe.somethingSelected()==de.somethingSelected()&&new Date-a.history.lastSelTime<=(a.cm?a.cm.options.historyEventDelay:500)}function fi(a,y,fe,de){var xe=a.history,Fe=de&&de.origin;fe==xe.lastSelOp||Fe&&xe.lastSelOrigin==Fe&&(xe.lastModTime==xe.lastSelTime&&xe.lastOrigin==Fe||fl(a,Fe,xt(xe.done),y))?xe.done[xe.done.length-1]=y:eo(y,xe.done),xe.lastSelTime=+new Date,xe.lastSelOrigin=Fe,xe.lastSelOp=fe,de&&de.clearRedo!==!1&&Fa(xe.undone)}function eo(a,y){var fe=xt(y);fe&&fe.ranges&&fe.equals(a)||y.push(a)}function Do(a,y,fe,de){var xe=y["spans_"+a.id],Fe=0;a.iter(Math.max(a.first,fe),Math.min(a.first+a.size,de),function(Je){Je.markedSpans&&((xe||(xe=y["spans_"+a.id]={}))[Fe]=Je.markedSpans),++Fe})}function ya(a){if(!a)return null;for(var y,fe=0;fe<a.length;++fe)a[fe].marker.explicitlyCleared?y||(y=a.slice(0,fe)):y&&y.push(a[fe]);return y?y.length?y:null:a}function fo(a,y){var fe=y["spans_"+a.id];if(!fe)return null;for(var de=[],xe=0;xe<y.text.length;++xe)de.push(ya(fe[xe]));return de}function _a(a,y){var fe=fo(a,y),de=Wi(a,y);if(!fe)return de;if(!de)return fe;for(var xe=0;xe<fe.length;++xe){var Fe=fe[xe],Je=de[xe];if(Fe&&Je)e:for(var it=0;it<Je.length;++it){for(var at=Je[it],ht=0;ht<Fe.length;++ht)if(Fe[ht].marker==at.marker)continue e;Fe.push(at)}else Je&&(fe[xe]=Je)}return fe}function ha(a,y,fe){for(var de=[],xe=0;xe<a.length;++xe){var Fe=a[xe];if(Fe.ranges){de.push(fe?li.prototype.deepCopy.call(Fe):Fe);continue}var Je=Fe.changes,it=[];de.push({changes:it});for(var at=0;at<Je.length;++at){var ht=Je[at],It=void 0;if(it.push({from:ht.from,to:ht.to,text:ht.text}),y)for(var Ut in ht)(It=Ut.match(/^spans_(\d+)$/))&&Ve(y,Number(It[1]))>-1&&(xt(it)[Ut]=ht[Ut],delete ht[Ut])}}return de}function Ka(a,y,fe,de){if(de){var xe=a.anchor;if(fe){var Fe=zt(y,xe)<0;Fe!=zt(fe,xe)<0?(xe=y,y=fe):Fe!=zt(y,fe)<0&&(y=fe)}return new Sr(xe,y)}else return new Sr(fe||y,y)}function Va(a,y,fe,de,xe){xe==null&&(xe=a.cm&&(a.cm.display.shift||a.extend)),Uo(a,new li([Ka(a.sel.primary(),y,fe,xe)],0),de)}function ja(a,y,fe){for(var de=[],xe=a.cm&&(a.cm.display.shift||a.extend),Fe=0;Fe<a.sel.ranges.length;Fe++)de[Fe]=Ka(a.sel.ranges[Fe],y[Fe],null,xe);var Je=Fr(a.cm,de,a.sel.primIndex);Uo(a,Je,fe)}function Ps(a,y,fe,de){var xe=a.sel.ranges.slice(0);xe[y]=fe,Uo(a,Fr(a.cm,xe,a.sel.primIndex),de)}function as(a,y,fe,de){Uo(a,mi(y,fe),de)}function hl(a,y,fe){var de={ranges:y.ranges,update:function(xe){this.ranges=[];for(var Fe=0;Fe<xe.length;Fe++)this.ranges[Fe]=new Sr(Tt(a,xe[Fe].anchor),Tt(a,xe[Fe].head))},origin:fe&&fe.origin};return jt(a,"beforeSelectionChange",a,de),a.cm&&jt(a.cm,"beforeSelectionChange",a.cm,de),de.ranges!=y.ranges?Fr(a.cm,de.ranges,de.ranges.length-1):y}function El(a,y,fe){var de=a.history.done,xe=xt(de);xe&&xe.ranges?(de[de.length-1]=y,Js(a,y,fe)):Uo(a,y,fe)}function Uo(a,y,fe){Js(a,y,fe),fi(a,a.sel,a.cm?a.cm.curOp.id:NaN,fe)}function Js(a,y,fe){(Lt(a,"beforeSelectionChange")||a.cm&&Lt(a.cm,"beforeSelectionChange"))&&(y=hl(a,y,fe));var de=fe&&fe.bias||(zt(y.primary().head,a.sel.primary().head)<0?-1:1);kl(a,Al(a,y,de,!0)),!(fe&&fe.scroll===!1)&&a.cm&&La(a.cm)}function kl(a,y){y.equals(a.sel)||(a.sel=y,a.cm&&(a.cm.curOp.updateInput=1,a.cm.curOp.selectionChanged=!0,Yt(a.cm)),Ri(a,"cursorActivity",a))}function Ll(a){kl(a,Al(a,a.sel,null,!1))}function Al(a,y,fe,de){for(var xe,Fe=0;Fe<y.ranges.length;Fe++){var Je=y.ranges[Fe],it=y.ranges.length==a.sel.ranges.length&&a.sel.ranges[Fe],at=Qs(a,Je.anchor,it&&it.anchor,fe,de),ht=Qs(a,Je.head,it&&it.head,fe,de);(xe||at!=Je.anchor||ht!=Je.head)&&(xe||(xe=y.ranges.slice(0,Fe)),xe[Fe]=new Sr(at,ht))}return xe?Fr(a.cm,xe,y.primIndex):y}function Es(a,y,fe,de,xe){var Fe=Ft(a,y.line);if(Fe.markedSpans)for(var Je=0;Je<Fe.markedSpans.length;++Je){var it=Fe.markedSpans[Je],at=it.marker,ht="selectLeft"in at?!at.selectLeft:at.inclusiveLeft,It="selectRight"in at?!at.selectRight:at.inclusiveRight;if((it.from==null||(ht?it.from<=y.ch:it.from<y.ch))&&(it.to==null||(It?it.to>=y.ch:it.to>y.ch))){if(xe&&(jt(at,"beforeCursorEnter"),at.explicitlyCleared))if(Fe.markedSpans){--Je;continue}else break;if(!at.atomic)continue;if(fe){var Ut=at.find(de<0?1:-1),rn=void 0;if((de<0?It:ht)&&(Ut=Tl(a,Ut,-de,Ut&&Ut.line==y.line?Fe:null)),Ut&&Ut.line==y.line&&(rn=zt(Ut,fe))&&(de<0?rn<0:rn>0))return Es(a,Ut,y,de,xe)}var Qt=at.find(de<0?-1:1);return(de<0?ht:It)&&(Qt=Tl(a,Qt,de,Qt.line==y.line?Fe:null)),Qt?Es(a,Qt,y,de,xe):null}}return y}function Qs(a,y,fe,de,xe){var Fe=de||1,Je=Es(a,y,fe,Fe,xe)||!xe&&Es(a,y,fe,Fe,!0)||Es(a,y,fe,-Fe,xe)||!xe&&Es(a,y,fe,-Fe,!0);return Je||(a.cantEdit=!0,Et(a.first,0))}function Tl(a,y,fe,de){return fe<0&&y.ch==0?y.line>a.first?Tt(a,Et(y.line-1)):null:fe>0&&y.ch==(de||Ft(a,y.line)).text.length?y.line<a.first+a.size-1?Et(y.line+1,0):null:new Et(y.line,y.ch+fe)}function Dl(a){a.setSelection(Et(a.firstLine(),0),Et(a.lastLine()),et)}function Ml(a,y,fe){var de={canceled:!1,from:y.from,to:y.to,text:y.text,origin:y.origin,cancel:function(){return de.canceled=!0}};return fe&&(de.update=function(xe,Fe,Je,it){xe&&(de.from=Tt(a,xe)),Fe&&(de.to=Tt(a,Fe)),Je&&(de.text=Je),it!==void 0&&(de.origin=it)}),jt(a,"beforeChange",a,de),a.cm&&jt(a.cm,"beforeChange",a.cm,de),de.canceled?(a.cm&&(a.cm.curOp.updateInput=2),null):{from:de.from,to:de.to,text:de.text,origin:de.origin}}function ks(a,y,fe){if(a.cm){if(!a.cm.curOp)return Vn(a.cm,ks)(a,y,fe);if(a.cm.state.suppressEdits)return}if(!((Lt(a,"beforeChange")||a.cm&&Lt(a.cm,"beforeChange"))&&(y=Ml(a,y,!0),!y))){var de=xi&&!fe&&$t(a,y.from,y.to);if(de)for(var xe=de.length-1;xe>=0;--xe)Rl(a,{from:de[xe].from,to:de[xe].to,text:xe?[""]:y.text,origin:y.origin});else Rl(a,y)}}function Rl(a,y){if(!(y.text.length==1&&y.text[0]==""&&zt(y.from,y.to)==0)){var fe=so(a,y);Xs(a,y,fe,a.cm?a.cm.curOp.id:NaN),Ns(a,y,fe,Wi(a,y));var de=[];oo(a,function(xe,Fe){!Fe&&Ve(de,xe.history)==-1&&(Nl(xe.history,y),de.push(xe.history)),Ns(xe,y,null,Wi(xe,y))})}}function $s(a,y,fe){var de=a.cm&&a.cm.state.suppressEdits;if(!(de&&!fe)){for(var xe=a.history,Fe,Je=a.sel,it=y=="undo"?xe.done:xe.undone,at=y=="undo"?xe.undone:xe.done,ht=0;ht<it.length&&(Fe=it[ht],!(fe?Fe.ranges&&!Fe.equals(a.sel):!Fe.ranges));ht++);if(ht!=it.length){for(xe.lastOrigin=xe.lastSelOrigin=null;;)if(Fe=it.pop(),Fe.ranges){if(eo(Fe,at),fe&&!Fe.equals(a.sel)){Uo(a,Fe,{clearRedo:!1});return}Je=Fe}else if(de){it.push(Fe);return}else break;var It=[];eo(Je,at),at.push({changes:It,generation:xe.generation}),xe.generation=Fe.generation||++xe.maxGeneration;for(var Ut=Lt(a,"beforeChange")||a.cm&&Lt(a.cm,"beforeChange"),rn=function(Wn){var Qn=Fe.changes[Wn];if(Qn.origin=y,Ut&&!Ml(a,Qn,!1))return it.length=0,{};It.push(lo(a,Qn));var sr=Wn?so(a,Qn):xt(it);Ns(a,Qn,sr,_a(a,Qn)),!Wn&&a.cm&&a.cm.scrollIntoView({from:Qn.from,to:Mr(Qn)});var vr=[];oo(a,function(lr,Er){!Er&&Ve(vr,lr.history)==-1&&(Nl(lr.history,Qn),vr.push(lr.history)),Ns(lr,Qn,null,_a(lr,Qn))})},Qt=Fe.changes.length-1;Qt>=0;--Qt){var Dn=rn(Qt);if(Dn)return Dn.v}}}}function Il(a,y){if(y!=0&&(a.first+=y,a.sel=new li(gt(a.sel.ranges,function(xe){return new Sr(Et(xe.anchor.line+y,xe.anchor.ch),Et(xe.head.line+y,xe.head.ch))}),a.sel.primIndex),a.cm)){Co(a.cm,a.first,a.first-y,y);for(var fe=a.cm.display,de=fe.viewFrom;de<fe.viewTo;de++)Eo(a.cm,de,"gutter")}}function Ns(a,y,fe,de){if(a.cm&&!a.cm.curOp)return Vn(a.cm,Ns)(a,y,fe,de);if(y.to.line<a.first){Il(a,y.text.length-1-(y.to.line-y.from.line));return}if(!(y.from.line>a.lastLine())){if(y.from.line<a.first){var xe=y.text.length-1-(a.first-y.from.line);Il(a,xe),y={from:Et(a.first,0),to:Et(y.to.line+xe,y.to.ch),text:[xt(y.text)],origin:y.origin}}var Fe=a.lastLine();y.to.line>Fe&&(y={from:y.from,to:Et(Fe,Ft(a,Fe).text.length),text:[y.text[0]],origin:y.origin}),y.removed=qt(a,y.from,y.to),fe||(fe=so(a,y)),a.cm?pu(a.cm,y,de):Ai(a,y,de),Js(a,fe,et),a.cantEdit&&Qs(a,Et(a.firstLine(),0))&&(a.cantEdit=!1)}}function pu(a,y,fe){var de=a.doc,xe=a.display,Fe=y.from,Je=y.to,it=!1,at=Fe.line;a.options.lineWrapping||(at=At(un(Ft(de,Fe.line))),de.iter(at,Je.line+1,function(Qt){if(Qt==xe.maxLine)return it=!0,!0})),de.sel.contains(y.from,y.to)>-1&&Yt(a),Ai(de,y,fe,ds(a)),a.options.lineWrapping||(de.iter(at,Fe.line+y.text.length,function(Qt){var Dn=gr(Qt);Dn>xe.maxLineLength&&(xe.maxLine=Qt,xe.maxLineLength=Dn,xe.maxLineChanged=!0,it=!1)}),it&&(a.curOp.updateMaxLine=!0)),wi(de,Fe.line),An(a,400);var ht=y.text.length-(Je.line-Fe.line)-1;y.full?Co(a):Fe.line==Je.line&&y.text.length==1&&!oi(a.doc,y)?Eo(a,Fe.line,"text"):Co(a,Fe.line,Je.line+1,ht);var It=Lt(a,"changes"),Ut=Lt(a,"change");if(Ut||It){var rn={from:Fe,to:Je,text:y.text,removed:y.removed,origin:y.origin};Ut&&Ri(a,"change",a,rn),It&&(a.curOp.changeObjs||(a.curOp.changeObjs=[])).push(rn)}a.display.selForContextMenu=null}function Ls(a,y,fe,de,xe){var Fe;de||(de=fe),zt(de,fe)<0&&(Fe=[de,fe],fe=Fe[0],de=Fe[1]),typeof y=="string"&&(y=a.splitLines(y)),ks(a,{from:fe,to:de,text:y,origin:xe})}function Ol(a,y,fe,de){fe<a.line?a.line+=de:y<a.line&&(a.line=y,a.ch=0)}function Pl(a,y,fe,de){for(var xe=0;xe<a.length;++xe){var Fe=a[xe],Je=!0;if(Fe.ranges){Fe.copied||(Fe=a[xe]=Fe.deepCopy(),Fe.copied=!0);for(var it=0;it<Fe.ranges.length;it++)Ol(Fe.ranges[it].anchor,y,fe,de),Ol(Fe.ranges[it].head,y,fe,de);continue}for(var at=0;at<Fe.changes.length;++at){var ht=Fe.changes[at];if(fe<ht.from.line)ht.from=Et(ht.from.line+de,ht.from.ch),ht.to=Et(ht.to.line+de,ht.to.ch);else if(y<=ht.to.line){Je=!1;break}}Je||(a.splice(0,xe+1),xe=0)}}function Nl(a,y){var fe=y.from.line,de=y.to.line,xe=y.text.length-(de-fe)-1;Pl(a.done,fe,de,xe),Pl(a.undone,fe,de,xe)}function Bs(a,y,fe,de){var xe=y,Fe=y;return typeof y=="number"?Fe=Ft(a,Tn(a,y)):xe=At(y),xe==null?null:(de(Fe,xe)&&a.cm&&Eo(a.cm,xe,fe),Fe)}function Fs(a){this.lines=a,this.parent=null;for(var y=0,fe=0;fe<a.length;++fe)a[fe].parent=this,y+=a[fe].height;this.height=y}Fs.prototype={chunkSize:function(){return this.lines.length},removeInner:function(a,y){for(var fe=a,de=a+y;fe<de;++fe){var xe=this.lines[fe];this.height-=xe.height,Gr(xe),Ri(xe,"delete")}this.lines.splice(a,y)},collapse:function(a){a.push.apply(a,this.lines)},insertInner:function(a,y,fe){this.height+=fe,this.lines=this.lines.slice(0,a).concat(y).concat(this.lines.slice(a));for(var de=0;de<y.length;++de)y[de].parent=this},iterN:function(a,y,fe){for(var de=a+y;a<de;++a)if(fe(this.lines[a]))return!0}};function js(a){this.children=a;for(var y=0,fe=0,de=0;de<a.length;++de){var xe=a[de];y+=xe.chunkSize(),fe+=xe.height,xe.parent=this}this.size=y,this.height=fe,this.parent=null}js.prototype={chunkSize:function(){return this.size},removeInner:function(a,y){this.size-=y;for(var fe=0;fe<this.children.length;++fe){var de=this.children[fe],xe=de.chunkSize();if(a<xe){var Fe=Math.min(y,xe-a),Je=de.height;if(de.removeInner(a,Fe),this.height-=Je-de.height,xe==Fe&&(this.children.splice(fe--,1),de.parent=null),(y-=Fe)==0)break;a=0}else a-=xe}if(this.size-y<25&&(this.children.length>1||!(this.children[0]instanceof Fs))){var it=[];this.collapse(it),this.children=[new Fs(it)],this.children[0].parent=this}},collapse:function(a){for(var y=0;y<this.children.length;++y)this.children[y].collapse(a)},insertInner:function(a,y,fe){this.size+=y.length,this.height+=fe;for(var de=0;de<this.children.length;++de){var xe=this.children[de],Fe=xe.chunkSize();if(a<=Fe){if(xe.insertInner(a,y,fe),xe.lines&&xe.lines.length>50){for(var Je=xe.lines.length%25+25,it=Je;it<xe.lines.length;){var at=new Fs(xe.lines.slice(it,it+=25));xe.height-=at.height,this.children.splice(++de,0,at),at.parent=this}xe.lines=xe.lines.slice(0,Je),this.maybeSpill()}break}a-=Fe}},maybeSpill:function(){if(!(this.children.length<=10)){var a=this;do{var y=a.children.splice(a.children.length-5,5),fe=new js(y);if(a.parent){a.size-=fe.size,a.height-=fe.height;var xe=Ve(a.parent.children,a);a.parent.children.splice(xe+1,0,fe)}else{var de=new js(a.children);de.parent=a,a.children=[de,fe],a=de}fe.parent=a.parent}while(a.children.length>10);a.parent.maybeSpill()}},iterN:function(a,y,fe){for(var de=0;de<this.children.length;++de){var xe=this.children[de],Fe=xe.chunkSize();if(a<Fe){var Je=Math.min(y,Fe-a);if(xe.iterN(a,Je,fe))return!0;if((y-=Je)==0)break;a=0}else a-=Fe}}};var Us=function(a,y,fe){if(fe)for(var de in fe)fe.hasOwnProperty(de)&&(this[de]=fe[de]);this.doc=a,this.node=y};Us.prototype.clear=function(){var a=this.doc.cm,y=this.line.widgets,fe=this.line,de=At(fe);if(!(de==null||!y)){for(var xe=0;xe<y.length;++xe)y[xe]==this&&y.splice(xe--,1);y.length||(fe.widgets=null);var Fe=Xi(this);Yn(fe,Math.max(0,fe.height-Fe)),a&&(wt(a,function(){Bl(a,fe,-Fe),Eo(a,de,"widget")}),Ri(a,"lineWidgetCleared",a,this,de))}},Us.prototype.changed=function(){var a=this,y=this.height,fe=this.doc.cm,de=this.line;this.height=null;var xe=Xi(this)-y;xe&&(Ln(this.doc,de)||Yn(de,de.height+xe),fe&&wt(fe,function(){fe.curOp.forceUpdate=!0,Bl(fe,de,xe),Ri(fe,"lineWidgetChanged",fe,a,At(de))}))},Kt(Us);function Bl(a,y,fe){Xn(y)<(a.curOp&&a.curOp.scrollTop||a.doc.scrollTop)&&rs(a,fe)}function mu(a,y,fe,de){var xe=new Us(a,fe,de),Fe=a.cm;return Fe&&xe.noHScroll&&(Fe.display.alignWidgets=!0),Bs(a,y,"widget",function(Je){var it=Je.widgets||(Je.widgets=[]);if(xe.insertAt==null?it.push(xe):it.splice(Math.min(it.length-1,Math.max(0,xe.insertAt)),0,xe),xe.line=Je,Fe&&!Ln(a,Je)){var at=Xn(Je)<a.scrollTop;Yn(Je,Je.height+Xi(xe)),at&&rs(Fe,xe.height),Fe.curOp.forceUpdate=!0}return!0}),Fe&&Ri(Fe,"lineWidgetAdded",Fe,xe,typeof y=="number"?y:At(y)),xe}var Fl=0,ss=function(a,y){this.lines=[],this.type=y,this.doc=a,this.id=++Fl};ss.prototype.clear=function(){if(!this.explicitlyCleared){var a=this.doc.cm,y=a&&!a.curOp;if(y&&Po(a),Lt(this,"clear")){var fe=this.find();fe&&Ri(this,"clear",fe.from,fe.to)}for(var de=null,xe=null,Fe=0;Fe<this.lines.length;++Fe){var Je=this.lines[Fe],it=br(Je.markedSpans,this);a&&!this.collapsed?Eo(a,At(Je),"text"):a&&(it.to!=null&&(xe=At(Je)),it.from!=null&&(de=At(Je))),Je.markedSpans=Ar(Je.markedSpans,it),it.from==null&&this.collapsed&&!Ln(this.doc,Je)&&a&&Yn(Je,go(a.display))}if(a&&this.collapsed&&!a.options.lineWrapping)for(var at=0;at<this.lines.length;++at){var ht=un(this.lines[at]),It=gr(ht);It>a.display.maxLineLength&&(a.display.maxLine=ht,a.display.maxLineLength=It,a.display.maxLineChanged=!0)}de!=null&&a&&this.collapsed&&Co(a,de,xe+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,a&&Ll(a.doc)),a&&Ri(a,"markerCleared",a,this,de,xe),y&&fa(a),this.parent&&this.parent.clear()}},ss.prototype.find=function(a,y){a==null&&this.type=="bookmark"&&(a=1);for(var fe,de,xe=0;xe<this.lines.length;++xe){var Fe=this.lines[xe],Je=br(Fe.markedSpans,this);if(Je.from!=null&&(fe=Et(y?Fe:At(Fe),Je.from),a==-1))return fe;if(Je.to!=null&&(de=Et(y?Fe:At(Fe),Je.to),a==1))return de}return fe&&{from:fe,to:de}},ss.prototype.changed=function(){var a=this,y=this.find(-1,!0),fe=this,de=this.doc.cm;!y||!de||wt(de,function(){var xe=y.line,Fe=At(y.line),Je=Yo(de,Fe);if(Je&&(Ha(Je),de.curOp.selectionChanged=de.curOp.forceUpdate=!0),de.curOp.updateMaxLine=!0,!Ln(fe.doc,xe)&&fe.height!=null){var it=fe.height;fe.height=null;var at=Xi(fe)-it;at&&Yn(xe,xe.height+at)}Ri(de,"markerChanged",de,a)})},ss.prototype.attachLine=function(a){if(!this.lines.length&&this.doc.cm){var y=this.doc.cm.curOp;(!y.maybeHiddenMarkers||Ve(y.maybeHiddenMarkers,this)==-1)&&(y.maybeUnhiddenMarkers||(y.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(a)},ss.prototype.detachLine=function(a){if(this.lines.splice(Ve(this.lines,a),1),!this.lines.length&&this.doc.cm){var y=this.doc.cm.curOp;(y.maybeHiddenMarkers||(y.maybeHiddenMarkers=[])).push(this)}},Kt(ss);function As(a,y,fe,de,xe){if(de&&de.shared)return vu(a,y,fe,de,xe);if(a.cm&&!a.cm.curOp)return Vn(a.cm,As)(a,y,fe,de,xe);var Fe=new ss(a,xe),Je=zt(y,fe);if(de&&ut(de,Fe,!1),Je>0||Je==0&&Fe.clearWhenEmpty!==!1)return Fe;if(Fe.replacedWith&&(Fe.collapsed=!0,Fe.widgetNode=je("span",[Fe.replacedWith],"CodeMirror-widget"),de.handleMouseEvents||Fe.widgetNode.setAttribute("cm-ignore-events","true"),de.insertLeft&&(Fe.widgetNode.insertLeft=!0)),Fe.collapsed){if(dn(a,y.line,y,fe,Fe)||y.line!=fe.line&&dn(a,fe.line,y,fe,Fe))throw new Error("Inserting collapsed marker partially overlapping an existing one");_i()}Fe.addToHistory&&Xs(a,{from:y,to:fe,origin:"markText"},a.sel,NaN);var it=y.line,at=a.cm,ht;if(a.iter(it,fe.line+1,function(Ut){at&&Fe.collapsed&&!at.options.lineWrapping&&un(Ut)==at.display.maxLine&&(ht=!0),Fe.collapsed&&it!=y.line&&Yn(Ut,0),qr(Ut,new or(Fe,it==y.line?y.ch:null,it==fe.line?fe.ch:null)),++it}),Fe.collapsed&&a.iter(y.line,fe.line+1,function(Ut){Ln(a,Ut)&&Yn(Ut,0)}),Fe.clearOnEnter&&vt(Fe,"beforeCursorEnter",function(){return Fe.clear()}),Fe.readOnly&&(Di(),(a.history.done.length||a.history.undone.length)&&a.clearHistory()),Fe.collapsed&&(Fe.id=++Fl,Fe.atomic=!0),at){if(ht&&(at.curOp.updateMaxLine=!0),Fe.collapsed)Co(at,y.line,fe.line+1);else if(Fe.className||Fe.startStyle||Fe.endStyle||Fe.css||Fe.attributes||Fe.title)for(var It=y.line;It<=fe.line;It++)Eo(at,It,"text");Fe.atomic&&Ll(at.doc),Ri(at,"markerAdded",at,Fe)}return Fe}var zs=function(a,y){this.markers=a,this.primary=y;for(var fe=0;fe<a.length;++fe)a[fe].parent=this};zs.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var a=0;a<this.markers.length;++a)this.markers[a].clear();Ri(this,"clear")}},zs.prototype.find=function(a,y){return this.primary.find(a,y)},Kt(zs);function vu(a,y,fe,de,xe){de=ut(de),de.shared=!1;var Fe=[As(a,y,fe,de,xe)],Je=Fe[0],it=de.widgetNode;return oo(a,function(at){it&&(de.widgetNode=it.cloneNode(!0)),Fe.push(As(at,Tt(at,y),Tt(at,fe),de,xe));for(var ht=0;ht<at.linked.length;++ht)if(at.linked[ht].isParent)return;Je=xt(Fe)}),new zs(Fe,Je)}function jl(a){return a.findMarks(Et(a.first,0),a.clipPos(Et(a.lastLine())),function(y){return y.parent})}function gu(a,y){for(var fe=0;fe<y.length;fe++){var de=y[fe],xe=de.find(),Fe=a.clipPos(xe.from),Je=a.clipPos(xe.to);if(zt(Fe,Je)){var it=As(a,Fe,Je,de.primary,de.primary.type);de.markers.push(it),it.parent=de}}}function yu(a){for(var y=function(de){var xe=a[de],Fe=[xe.primary.doc];oo(xe.primary.doc,function(at){return Fe.push(at)});for(var Je=0;Je<xe.markers.length;Je++){var it=xe.markers[Je];Ve(Fe,it.doc)==-1&&(it.parent=null,xe.markers.splice(Je--,1))}},fe=0;fe<a.length;fe++)y(fe)}var _u=0,Qo=function(a,y,fe,de,xe){if(!(this instanceof Qo))return new Qo(a,y,fe,de,xe);fe==null&&(fe=0),js.call(this,[new Fs([new Cr("",null)])]),this.first=fe,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=fe;var Fe=Et(fe,0);this.sel=mi(Fe),this.history=new Jo(null),this.id=++_u,this.modeOption=y,this.lineSep=de,this.direction=xe=="rtl"?"rtl":"ltr",this.extend=!1,typeof a=="string"&&(a=this.splitLines(a)),Ai(this,{from:Fe,to:Fe,text:a}),Uo(this,mi(Fe),et)};Qo.prototype=Ae(js.prototype,{constructor:Qo,iter:function(a,y,fe){fe?this.iterN(a-this.first,y-a,fe):this.iterN(this.first,this.first+this.size,a)},insert:function(a,y){for(var fe=0,de=0;de<y.length;++de)fe+=y[de].height;this.insertInner(a-this.first,y,fe)},remove:function(a,y){this.removeInner(a-this.first,y)},getValue:function(a){var y=En(this,this.first,this.first+this.size);return a===!1?y:y.join(a||this.lineSeparator())},setValue:pn(function(a){var y=Et(this.first,0),fe=this.first+this.size-1;ks(this,{from:y,to:Et(fe,Ft(this,fe).text.length),text:this.splitLines(a),origin:"setValue",full:!0},!0),this.cm&&Nr(this.cm,0,0),Uo(this,mi(y),et)}),replaceRange:function(a,y,fe,de){y=Tt(this,y),fe=fe?Tt(this,fe):y,Ls(this,a,y,fe,de)},getRange:function(a,y,fe){var de=qt(this,Tt(this,a),Tt(this,y));return fe===!1?de:de.join(fe||this.lineSeparator())},getLine:function(a){var y=this.getLineHandle(a);return y&&y.text},getLineHandle:function(a){if(an(this,a))return Ft(this,a)},getLineNumber:function(a){return At(a)},getLineHandleVisualStart:function(a){return typeof a=="number"&&(a=Ft(this,a)),un(a)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(a){return Tt(this,a)},getCursor:function(a){var y=this.sel.primary(),fe;return a==null||a=="head"?fe=y.head:a=="anchor"?fe=y.anchor:a=="end"||a=="to"||a===!1?fe=y.to():fe=y.from(),fe},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:pn(function(a,y,fe){as(this,Tt(this,typeof a=="number"?Et(a,y||0):a),null,fe)}),setSelection:pn(function(a,y,fe){as(this,Tt(this,a),Tt(this,y||a),fe)}),extendSelection:pn(function(a,y,fe){Va(this,Tt(this,a),y&&Tt(this,y),fe)}),extendSelections:pn(function(a,y){ja(this,bn(this,a),y)}),extendSelectionsBy:pn(function(a,y){var fe=gt(this.sel.ranges,a);ja(this,bn(this,fe),y)}),setSelections:pn(function(a,y,fe){if(a.length){for(var de=[],xe=0;xe<a.length;xe++)de[xe]=new Sr(Tt(this,a[xe].anchor),Tt(this,a[xe].head));y==null&&(y=Math.min(a.length-1,this.sel.primIndex)),Uo(this,Fr(this.cm,de,y),fe)}}),addSelection:pn(function(a,y,fe){var de=this.sel.ranges.slice(0);de.push(new Sr(Tt(this,a),Tt(this,y||a))),Uo(this,Fr(this.cm,de,de.length-1),fe)}),getSelection:function(a){for(var y=this.sel.ranges,fe,de=0;de<y.length;de++){var xe=qt(this,y[de].from(),y[de].to());fe=fe?fe.concat(xe):xe}return a===!1?fe:fe.join(a||this.lineSeparator())},getSelections:function(a){for(var y=[],fe=this.sel.ranges,de=0;de<fe.length;de++){var xe=qt(this,fe[de].from(),fe[de].to());a!==!1&&(xe=xe.join(a||this.lineSeparator())),y[de]=xe}return y},replaceSelection:function(a,y,fe){for(var de=[],xe=0;xe<this.sel.ranges.length;xe++)de[xe]=a;this.replaceSelections(de,y,fe||"+input")},replaceSelections:pn(function(a,y,fe){for(var de=[],xe=this.sel,Fe=0;Fe<xe.ranges.length;Fe++){var Je=xe.ranges[Fe];de[Fe]={from:Je.from(),to:Je.to(),text:this.splitLines(a[Fe]),origin:fe}}for(var it=y&&y!="end"&&os(this,de,y),at=de.length-1;at>=0;at--)ks(this,de[at]);it?El(this,it):this.cm&&La(this.cm)}),undo:pn(function(){$s(this,"undo")}),redo:pn(function(){$s(this,"redo")}),undoSelection:pn(function(){$s(this,"undo",!0)}),redoSelection:pn(function(){$s(this,"redo",!0)}),setExtending:function(a){this.extend=a},getExtending:function(){return this.extend},historySize:function(){for(var a=this.history,y=0,fe=0,de=0;de<a.done.length;de++)a.done[de].ranges||++y;for(var xe=0;xe<a.undone.length;xe++)a.undone[xe].ranges||++fe;return{undo:y,redo:fe}},clearHistory:function(){var a=this;this.history=new Jo(this.history.maxGeneration),oo(this,function(y){return y.history=a.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(a){return a&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(a){return this.history.generation==(a||this.cleanGeneration)},getHistory:function(){return{done:ha(this.history.done),undone:ha(this.history.undone)}},setHistory:function(a){var y=this.history=new Jo(this.history.maxGeneration);y.done=ha(a.done.slice(0),null,!0),y.undone=ha(a.undone.slice(0),null,!0)},setGutterMarker:pn(function(a,y,fe){return Bs(this,a,"gutter",function(de){var xe=de.gutterMarkers||(de.gutterMarkers={});return xe[y]=fe,!fe&&Ne(xe)&&(de.gutterMarkers=null),!0})}),clearGutter:pn(function(a){var y=this;this.iter(function(fe){fe.gutterMarkers&&fe.gutterMarkers[a]&&Bs(y,fe,"gutter",function(){return fe.gutterMarkers[a]=null,Ne(fe.gutterMarkers)&&(fe.gutterMarkers=null),!0})})}),lineInfo:function(a){var y;if(typeof a=="number"){if(!an(this,a)||(y=a,a=Ft(this,a),!a))return null}else if(y=At(a),y==null)return null;return{line:y,handle:a,text:a.text,gutterMarkers:a.gutterMarkers,textClass:a.textClass,bgClass:a.bgClass,wrapClass:a.wrapClass,widgets:a.widgets}},addLineClass:pn(function(a,y,fe){return Bs(this,a,y=="gutter"?"gutter":"class",function(de){var xe=y=="text"?"textClass":y=="background"?"bgClass":y=="gutter"?"gutterClass":"wrapClass";if(!de[xe])de[xe]=fe;else{if(pe(fe).test(de[xe]))return!1;de[xe]+=" "+fe}return!0})}),removeLineClass:pn(function(a,y,fe){return Bs(this,a,y=="gutter"?"gutter":"class",function(de){var xe=y=="text"?"textClass":y=="background"?"bgClass":y=="gutter"?"gutterClass":"wrapClass",Fe=de[xe];if(Fe)if(fe==null)de[xe]=null;else{var Je=Fe.match(pe(fe));if(!Je)return!1;var it=Je.index+Je[0].length;de[xe]=Fe.slice(0,Je.index)+(!Je.index||it==Fe.length?"":" ")+Fe.slice(it)||null}else return!1;return!0})}),addLineWidget:pn(function(a,y,fe){return mu(this,a,y,fe)}),removeLineWidget:function(a){a.clear()},markText:function(a,y,fe){return As(this,Tt(this,a),Tt(this,y),fe,fe&&fe.type||"range")},setBookmark:function(a,y){var fe={replacedWith:y&&(y.nodeType==null?y.widget:y),insertLeft:y&&y.insertLeft,clearWhenEmpty:!1,shared:y&&y.shared,handleMouseEvents:y&&y.handleMouseEvents};return a=Tt(this,a),As(this,a,a,fe,"bookmark")},findMarksAt:function(a){a=Tt(this,a);var y=[],fe=Ft(this,a.line).markedSpans;if(fe)for(var de=0;de<fe.length;++de){var xe=fe[de];(xe.from==null||xe.from<=a.ch)&&(xe.to==null||xe.to>=a.ch)&&y.push(xe.marker.parent||xe.marker)}return y},findMarks:function(a,y,fe){a=Tt(this,a),y=Tt(this,y);var de=[],xe=a.line;return this.iter(a.line,y.line+1,function(Fe){var Je=Fe.markedSpans;if(Je)for(var it=0;it<Je.length;it++){var at=Je[it];!(at.to!=null&&xe==a.line&&a.ch>=at.to||at.from==null&&xe!=a.line||at.from!=null&&xe==y.line&&at.from>=y.ch)&&(!fe||fe(at.marker))&&de.push(at.marker.parent||at.marker)}++xe}),de},getAllMarks:function(){var a=[];return this.iter(function(y){var fe=y.markedSpans;if(fe)for(var de=0;de<fe.length;++de)fe[de].from!=null&&a.push(fe[de].marker)}),a},posFromIndex:function(a){var y,fe=this.first,de=this.lineSeparator().length;return this.iter(function(xe){var Fe=xe.text.length+de;if(Fe>a)return y=a,!0;a-=Fe,++fe}),Tt(this,Et(fe,y))},indexFromPos:function(a){a=Tt(this,a);var y=a.ch;if(a.line<this.first||a.ch<0)return 0;var fe=this.lineSeparator().length;return this.iter(this.first,a.line,function(de){y+=de.text.length+fe}),y},copy:function(a){var y=new Qo(En(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return y.scrollTop=this.scrollTop,y.scrollLeft=this.scrollLeft,y.sel=this.sel,y.extend=!1,a&&(y.history.undoDepth=this.history.undoDepth,y.setHistory(this.getHistory())),y},linkedDoc:function(a){a||(a={});var y=this.first,fe=this.first+this.size;a.from!=null&&a.from>y&&(y=a.from),a.to!=null&&a.to<fe&&(fe=a.to);var de=new Qo(En(this,y,fe),a.mode||this.modeOption,y,this.lineSep,this.direction);return a.sharedHist&&(de.history=this.history),(this.linked||(this.linked=[])).push({doc:de,sharedHist:a.sharedHist}),de.linked=[{doc:this,isParent:!0,sharedHist:a.sharedHist}],gu(de,jl(this)),de},unlinkDoc:function(a){if(a instanceof uo&&(a=a.doc),this.linked)for(var y=0;y<this.linked.length;++y){var fe=this.linked[y];if(fe.doc==a){this.linked.splice(y,1),a.unlinkDoc(this),yu(jl(this));break}}if(a.history==this.history){var de=[a.id];oo(a,function(xe){return de.push(xe.id)},!0),a.history=new Jo(null),a.history.done=ha(this.history.done,de),a.history.undone=ha(this.history.undone,de)}},iterLinkedDocs:function(a){oo(this,a)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(a){return this.lineSep?a.split(this.lineSep):ir(a)},lineSeparator:function(){return this.lineSep||`
|
|
|
`},setDirection:pn(function(a){a!="rtl"&&(a="ltr"),a!=this.direction&&(this.direction=a,this.iter(function(y){return y.order=null}),this.cm&&Cs(this.cm))})}),Qo.prototype.eachLine=Qo.prototype.iter;var Ul=0;function bu(a){var y=this;if(zl(y),!(yt(y,a)||qi(y.display,a))){sn(a),se&&(Ul=+new Date);var fe=da(y,a,!0),de=a.dataTransfer.files;if(!(!fe||y.isReadOnly()))if(de&&de.length&&window.FileReader&&window.File)for(var xe=de.length,Fe=Array(xe),Je=0,it=function(){++Je==xe&&Vn(y,function(){fe=Tt(y.doc,fe);var Qt={from:fe,to:fe,text:y.doc.splitLines(Fe.filter(function(Dn){return Dn!=null}).join(y.doc.lineSeparator())),origin:"paste"};ks(y.doc,Qt),El(y.doc,mi(Tt(y.doc,fe),Tt(y.doc,Mr(Qt))))})()},at=function(Qt,Dn){if(y.options.allowDropFileTypes&&Ve(y.options.allowDropFileTypes,Qt.type)==-1){it();return}var Wn=new FileReader;Wn.onerror=function(){return it()},Wn.onload=function(){var Qn=Wn.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(Qn)){it();return}Fe[Dn]=Qn,it()},Wn.readAsText(Qt)},ht=0;ht<de.length;ht++)at(de[ht],ht);else{if(y.state.draggingText&&y.doc.sel.contains(fe)>-1){y.state.draggingText(a),setTimeout(function(){return y.display.input.focus()},20);return}try{var It=a.dataTransfer.getData("Text");if(It){var Ut;if(y.state.draggingText&&!y.state.draggingText.copy&&(Ut=y.listSelections()),Js(y.doc,mi(fe,fe)),Ut)for(var rn=0;rn<Ut.length;++rn)Ls(y.doc,"",Ut[rn].anchor,Ut[rn].head,"drag");y.replaceSelection(It,"around","paste"),y.display.input.focus()}}catch(Qt){}}}}function Su(a,y){if(se&&(!a.state.draggingText||+new Date-Ul<100)){Rn(y);return}if(!(yt(a,y)||qi(a.display,y))&&(y.dataTransfer.setData("Text",a.getSelection()),y.dataTransfer.effectAllowed="copyMove",y.dataTransfer.setDragImage&&!b)){var fe=Oe("img",null,null,"position: fixed; left: 0; top: 0;");fe.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",E&&(fe.width=fe.height=1,a.display.wrapper.appendChild(fe),fe._top=fe.offsetTop),y.dataTransfer.setDragImage(fe,0,0),E&&fe.parentNode.removeChild(fe)}}function wu(a,y){var fe=da(a,y);if(fe){var de=document.createDocumentFragment();$a(a,fe,de),a.display.dragCursor||(a.display.dragCursor=Oe("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),a.display.lineSpace.insertBefore(a.display.dragCursor,a.display.cursorDiv)),Ee(a.display.dragCursor,de)}}function zl(a){a.display.dragCursor&&(a.display.lineSpace.removeChild(a.display.dragCursor),a.display.dragCursor=null)}function Hl(a){if(document.getElementsByClassName){for(var y=document.getElementsByClassName("CodeMirror"),fe=[],de=0;de<y.length;de++){var xe=y[de].CodeMirror;xe&&fe.push(xe)}fe.length&&fe[0].operation(function(){for(var Fe=0;Fe<fe.length;Fe++)a(fe[Fe])})}}var Wl=!1;function xu(){Wl||(Cu(),Wl=!0)}function Cu(){var a;vt(window,"resize",function(){a==null&&(a=setTimeout(function(){a=null,Hl(Eu)},100))}),vt(window,"blur",function(){return Hl(Ga)})}function Eu(a){var y=a.display;y.cachedCharWidth=y.cachedTextHeight=y.cachedPaddingH=null,y.scrollbarsClipped=!1,a.setSize()}for(var ls={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"},Hs=0;Hs<10;Hs++)ls[Hs+48]=ls[Hs+96]=String(Hs);for(var el=65;el<=90;el++)ls[el]=String.fromCharCode(el);for(var Ws=1;Ws<=12;Ws++)ls[Ws+111]=ls[Ws+63235]="F"+Ws;var Ya={};Ya.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"},Ya.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"},Ya.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"},Ya.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"]},Ya.default=ve?Ya.macDefault:Ya.pcDefault;function ku(a){var y=a.split(/-(?!$)/);a=y[y.length-1];for(var fe,de,xe,Fe,Je=0;Je<y.length-1;Je++){var it=y[Je];if(/^(cmd|meta|m)$/i.test(it))Fe=!0;else if(/^a(lt)?$/i.test(it))fe=!0;else if(/^(c|ctrl|control)$/i.test(it))de=!0;else if(/^s(hift)?$/i.test(it))xe=!0;else throw new Error("Unrecognized modifier name: "+it)}return fe&&(a="Alt-"+a),de&&(a="Ctrl-"+a),Fe&&(a="Cmd-"+a),xe&&(a="Shift-"+a),a}function Lu(a){var y={};for(var fe in a)if(a.hasOwnProperty(fe)){var de=a[fe];if(/^(name|fallthrough|(de|at)tach)$/.test(fe))continue;if(de=="..."){delete a[fe];continue}for(var xe=gt(fe.split(" "),ku),Fe=0;Fe<xe.length;Fe++){var Je=void 0,it=void 0;Fe==xe.length-1?(it=xe.join(" "),Je=de):(it=xe.slice(0,Fe+1).join(" "),Je="...");var at=y[it];if(!at)y[it]=Je;else if(at!=Je)throw new Error("Inconsistent bindings for "+it)}delete a[fe]}for(var ht in y)a[ht]=y[ht];return a}function Ts(a,y,fe,de){y=tl(y);var xe=y.call?y.call(a,de):y[a];if(xe===!1)return"nothing";if(xe==="...")return"multi";if(xe!=null&&fe(xe))return"handled";if(y.fallthrough){if(Object.prototype.toString.call(y.fallthrough)!="[object Array]")return Ts(a,y.fallthrough,fe,de);for(var Fe=0;Fe<y.fallthrough.length;Fe++){var Je=Ts(a,y.fallthrough[Fe],fe,de);if(Je)return Je}}}function Zl(a){var y=typeof a=="string"?a:ls[a.keyCode];return y=="Ctrl"||y=="Alt"||y=="Shift"||y=="Mod"}function Gl(a,y,fe){var de=a;return y.altKey&&de!="Alt"&&(a="Alt-"+a),(_e?y.metaKey:y.ctrlKey)&&de!="Ctrl"&&(a="Ctrl-"+a),(_e?y.ctrlKey:y.metaKey)&&de!="Mod"&&(a="Cmd-"+a),!fe&&y.shiftKey&&de!="Shift"&&(a="Shift-"+a),a}function Kl(a,y){if(E&&a.keyCode==34&&a.char)return!1;var fe=ls[a.keyCode];return fe==null||a.altGraphKey?!1:(a.keyCode==3&&a.code&&(fe=a.code),Gl(fe,a,y))}function tl(a){return typeof a=="string"?Ya[a]:a}function Ds(a,y){for(var fe=a.doc.sel.ranges,de=[],xe=0;xe<fe.length;xe++){for(var Fe=y(fe[xe]);de.length&&zt(Fe.from,xt(de).to)<=0;){var Je=de.pop();if(zt(Je.from,Fe.from)<0){Fe.from=Je.from;break}}de.push(Fe)}wt(a,function(){for(var it=de.length-1;it>=0;it--)Ls(a.doc,"",de[it].from,de[it].to,"+delete");La(a)})}function pl(a,y,fe){var de=Le(a.text,y+fe,fe);return de<0||de>a.text.length?null:de}function ml(a,y,fe){var de=pl(a,y.ch,fe);return de==null?null:new Et(y.line,de,fe<0?"after":"before")}function vl(a,y,fe,de,xe){if(a){y.doc.direction=="rtl"&&(xe=-xe);var Fe=Nt(fe,y.doc.direction);if(Fe){var Je=xe<0?xt(Fe):Fe[0],it=xe<0==(Je.level==1),at=it?"after":"before",ht;if(Je.level>0||y.doc.direction=="rtl"){var It=la(y,fe);ht=xe<0?fe.text.length-1:0;var Ut=Zo(y,It,ht).top;ht=Ue(function(rn){return Zo(y,It,rn).top==Ut},xe<0==(Je.level==1)?Je.from:Je.to-1,ht),at=="before"&&(ht=pl(fe,ht,1))}else ht=xe<0?Je.to:Je.from;return new Et(de,ht,at)}}return new Et(de,xe<0?fe.text.length:0,xe<0?"before":"after")}function Au(a,y,fe,de){var xe=Nt(y,a.doc.direction);if(!xe)return ml(y,fe,de);fe.ch>=y.text.length?(fe.ch=y.text.length,fe.sticky="before"):fe.ch<=0&&(fe.ch=0,fe.sticky="after");var Fe=tt(xe,fe.ch,fe.sticky),Je=xe[Fe];if(a.doc.direction=="ltr"&&Je.level%2==0&&(de>0?Je.to>fe.ch:Je.from<fe.ch))return ml(y,fe,de);var it=function(sr,vr){return pl(y,sr instanceof Et?sr.ch:sr,vr)},at,ht=function(sr){return a.options.lineWrapping?(at=at||la(a,y),io(a,y,at,sr)):{begin:0,end:y.text.length}},It=ht(fe.sticky=="before"?it(fe,-1):fe.ch);if(a.doc.direction=="rtl"||Je.level==1){var Ut=Je.level==1==de<0,rn=it(fe,Ut?1:-1);if(rn!=null&&(Ut?rn<=Je.to&&rn<=It.end:rn>=Je.from&&rn>=It.begin)){var Qt=Ut?"before":"after";return new Et(fe.line,rn,Qt)}}var Dn=function(sr,vr,lr){for(var Er=function(to,Mo){return Mo?new Et(fe.line,it(to,1),"before"):new Et(fe.line,to,"after")};sr>=0&&sr<xe.length;sr+=vr){var Qr=xe[sr],Hr=vr>0==(Qr.level!=1),Li=Hr?lr.begin:it(lr.end,-1);if(Qr.from<=Li&&Li<Qr.to||(Li=Hr?Qr.from:it(Qr.to,-1),lr.begin<=Li&&Li<lr.end))return Er(Li,Hr)}},Wn=Dn(Fe+de,de,It);if(Wn)return Wn;var Qn=de>0?It.end:it(It.begin,-1);return Qn!=null&&!(de>0&&Qn==y.text.length)&&(Wn=Dn(de>0?0:xe.length-1,de,ht(Qn)),Wn)?Wn:null}var Zs={selectAll:Dl,singleSelection:function(a){return a.setSelection(a.getCursor("anchor"),a.getCursor("head"),et)},killLine:function(a){return Ds(a,function(y){if(y.empty()){var fe=Ft(a.doc,y.head.line).text.length;return y.head.ch==fe&&y.head.line<a.lastLine()?{from:y.head,to:Et(y.head.line+1,0)}:{from:y.head,to:Et(y.head.line,fe)}}else return{from:y.from(),to:y.to()}})},deleteLine:function(a){return Ds(a,function(y){return{from:Et(y.from().line,0),to:Tt(a.doc,Et(y.to().line+1,0))}})},delLineLeft:function(a){return Ds(a,function(y){return{from:Et(y.from().line,0),to:y.from()}})},delWrappedLineLeft:function(a){return Ds(a,function(y){var fe=a.charCoords(y.head,"div").top+5,de=a.coordsChar({left:0,top:fe},"div");return{from:de,to:y.from()}})},delWrappedLineRight:function(a){return Ds(a,function(y){var fe=a.charCoords(y.head,"div").top+5,de=a.coordsChar({left:a.display.lineDiv.offsetWidth+100,top:fe},"div");return{from:y.from(),to:de}})},undo:function(a){return a.undo()},redo:function(a){return a.redo()},undoSelection:function(a){return a.undoSelection()},redoSelection:function(a){return a.redoSelection()},goDocStart:function(a){return a.extendSelection(Et(a.firstLine(),0))},goDocEnd:function(a){return a.extendSelection(Et(a.lastLine()))},goLineStart:function(a){return a.extendSelectionsBy(function(y){return Vl(a,y.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(a){return a.extendSelectionsBy(function(y){return Yl(a,y.head)},{origin:"+move",bias:1})},goLineEnd:function(a){return a.extendSelectionsBy(function(y){return Tu(a,y.head.line)},{origin:"+move",bias:-1})},goLineRight:function(a){return a.extendSelectionsBy(function(y){var fe=a.cursorCoords(y.head,"div").top+5;return a.coordsChar({left:a.display.lineDiv.offsetWidth+100,top:fe},"div")},ct)},goLineLeft:function(a){return a.extendSelectionsBy(function(y){var fe=a.cursorCoords(y.head,"div").top+5;return a.coordsChar({left:0,top:fe},"div")},ct)},goLineLeftSmart:function(a){return a.extendSelectionsBy(function(y){var fe=a.cursorCoords(y.head,"div").top+5,de=a.coordsChar({left:0,top:fe},"div");return de.ch<a.getLine(de.line).search(/\S/)?Yl(a,y.head):de},ct)},goLineUp:function(a){return a.moveV(-1,"line")},goLineDown:function(a){return a.moveV(1,"line")},goPageUp:function(a){return a.moveV(-1,"page")},goPageDown:function(a){return a.moveV(1,"page")},goCharLeft:function(a){return a.moveH(-1,"char")},goCharRight:function(a){return a.moveH(1,"char")},goColumnLeft:function(a){return a.moveH(-1,"column")},goColumnRight:function(a){return a.moveH(1,"column")},goWordLeft:function(a){return a.moveH(-1,"word")},goGroupRight:function(a){return a.moveH(1,"group")},goGroupLeft:function(a){return a.moveH(-1,"group")},goWordRight:function(a){return a.moveH(1,"word")},delCharBefore:function(a){return a.deleteH(-1,"codepoint")},delCharAfter:function(a){return a.deleteH(1,"char")},delWordBefore:function(a){return a.deleteH(-1,"word")},delWordAfter:function(a){return a.deleteH(1,"word")},delGroupBefore:function(a){return a.deleteH(-1,"group")},delGroupAfter:function(a){return a.deleteH(1,"group")},indentAuto:function(a){return a.indentSelection("smart")},indentMore:function(a){return a.indentSelection("add")},indentLess:function(a){return a.indentSelection("subtract")},insertTab:function(a){return a.replaceSelection(" ")},insertSoftTab:function(a){for(var y=[],fe=a.listSelections(),de=a.options.tabSize,xe=0;xe<fe.length;xe++){var Fe=fe[xe].from(),Je=Ge(a.getLine(Fe.line),Fe.ch,de);y.push(Rt(de-Je%de))}a.replaceSelections(y)},defaultTab:function(a){a.somethingSelected()?a.indentSelection("add"):a.execCommand("insertTab")},transposeChars:function(a){return wt(a,function(){for(var y=a.listSelections(),fe=[],de=0;de<y.length;de++)if(y[de].empty()){var xe=y[de].head,Fe=Ft(a.doc,xe.line).text;if(Fe){if(xe.ch==Fe.length&&(xe=new Et(xe.line,xe.ch-1)),xe.ch>0)xe=new Et(xe.line,xe.ch+1),a.replaceRange(Fe.charAt(xe.ch-1)+Fe.charAt(xe.ch-2),Et(xe.line,xe.ch-2),xe,"+transpose");else if(xe.line>a.doc.first){var Je=Ft(a.doc,xe.line-1).text;Je&&(xe=new Et(xe.line,1),a.replaceRange(Fe.charAt(0)+a.doc.lineSeparator()+Je.charAt(Je.length-1),Et(xe.line-1,Je.length-1),xe,"+transpose"))}}fe.push(new Sr(xe,xe))}a.setSelections(fe)})},newlineAndIndent:function(a){return wt(a,function(){for(var y=a.listSelections(),fe=y.length-1;fe>=0;fe--)a.replaceRange(a.doc.lineSeparator(),y[fe].anchor,y[fe].head,"+input");y=a.listSelections();for(var de=0;de<y.length;de++)a.indentLine(y[de].from().line,null,!0);La(a)})},openLine:function(a){return a.replaceSelection(`
|
|
|
`,"start")},toggleOverwrite:function(a){return a.toggleOverwrite()}};function Vl(a,y){var fe=Ft(a.doc,y),de=un(fe);return de!=fe&&(y=At(de)),vl(!0,a,de,y,1)}function Tu(a,y){var fe=Ft(a.doc,y),de=mn(fe);return de!=fe&&(y=At(de)),vl(!0,a,fe,y,-1)}function Yl(a,y){var fe=Vl(a,y.line),de=Ft(a.doc,fe.line),xe=Nt(de,a.doc.direction);if(!xe||xe[0].level==0){var Fe=Math.max(fe.ch,de.text.search(/\S/)),Je=y.line==fe.line&&y.ch<=Fe&&y.ch;return Et(fe.line,Je?0:Fe,fe.sticky)}return fe}function nl(a,y,fe){if(typeof y=="string"&&(y=Zs[y],!y))return!1;a.display.input.ensurePolled();var de=a.display.shift,xe=!1;try{a.isReadOnly()&&(a.state.suppressEdits=!0),fe&&(a.display.shift=!1),xe=y(a)!=nt}finally{a.display.shift=de,a.state.suppressEdits=!1}return xe}function Du(a,y,fe){for(var de=0;de<a.state.keyMaps.length;de++){var xe=Ts(y,a.state.keyMaps[de],fe,a);if(xe)return xe}return a.options.extraKeys&&Ts(y,a.options.extraKeys,fe,a)||Ts(y,a.options.keyMap,fe,a)}var Mu=new ze;function Gs(a,y,fe,de){var xe=a.state.keySeq;if(xe){if(Zl(y))return"handled";if(/\'$/.test(y)?a.state.keySeq=null:Mu.set(50,function(){a.state.keySeq==xe&&(a.state.keySeq=null,a.display.input.reset())}),Xl(a,xe+" "+y,fe,de))return!0}return Xl(a,y,fe,de)}function Xl(a,y,fe,de){var xe=Du(a,y,de);return xe=="multi"&&(a.state.keySeq=y),xe=="handled"&&Ri(a,"keyHandled",a,y,fe),(xe=="handled"||xe=="multi")&&(sn(fe),es(a)),!!xe}function ql(a,y){var fe=Kl(y,!0);return fe?y.shiftKey&&!a.state.keySeq?Gs(a,"Shift-"+fe,y,function(de){return nl(a,de,!0)})||Gs(a,fe,y,function(de){if(typeof de=="string"?/^go[A-Z]/.test(de):de.motion)return nl(a,de)}):Gs(a,fe,y,function(de){return nl(a,de)}):!1}function Ru(a,y,fe){return Gs(a,"'"+fe+"'",y,function(de){return nl(a,de,!0)})}var gl=null;function Jl(a){var y=this;if(!(a.target&&a.target!=y.display.input.getField())&&(y.curOp.focus=Xe(),!yt(y,a))){se&&te<11&&a.keyCode==27&&(a.returnValue=!1);var fe=a.keyCode;y.display.shift=fe==16||a.shiftKey;var de=ql(y,a);E&&(gl=de?fe:null,!de&&fe==88&&!Nn&&(ve?a.metaKey:a.ctrlKey)&&y.replaceSelection("",null,"cut")),ce&&!ve&&!de&&fe==46&&a.shiftKey&&!a.ctrlKey&&document.execCommand&&document.execCommand("cut"),fe==18&&!/\bCodeMirror-crosshair\b/.test(y.display.lineDiv.className)&&Iu(y)}}function Iu(a){var y=a.display.lineDiv;ot(y,"CodeMirror-crosshair");function fe(de){(de.keyCode==18||!de.altKey)&&(ke(y,"CodeMirror-crosshair"),Ht(document,"keyup",fe),Ht(document,"mouseover",fe))}vt(document,"keyup",fe),vt(document,"mouseover",fe)}function Ql(a){a.keyCode==16&&(this.doc.sel.shift=!1),yt(this,a)}function $l(a){var y=this;if(!(a.target&&a.target!=y.display.input.getField())&&!(qi(y.display,a)||yt(y,a)||a.ctrlKey&&!a.altKey||ve&&a.metaKey)){var fe=a.keyCode,de=a.charCode;if(E&&fe==gl){gl=null,sn(a);return}if(!(E&&(!a.which||a.which<10)&&ql(y,a))){var xe=String.fromCharCode(de==null?fe:de);xe!="\b"&&(Ru(y,a,xe)||y.display.input.onKeyPress(a))}}}var Ou=400,yl=function(a,y,fe){this.time=a,this.pos=y,this.button=fe};yl.prototype.compare=function(a,y,fe){return this.time+Ou>a&&zt(y,this.pos)==0&&fe==this.button};var Ks,Vs;function Pu(a,y){var fe=+new Date;return Vs&&Vs.compare(fe,a,y)?(Ks=Vs=null,"triple"):Ks&&Ks.compare(fe,a,y)?(Vs=new yl(fe,a,y),Ks=null,"double"):(Ks=new yl(fe,a,y),Vs=null,"single")}function eu(a){var y=this,fe=y.display;if(!(yt(y,a)||fe.activeTouch&&fe.input.supportsTouch())){if(fe.input.ensurePolled(),fe.shift=a.shiftKey,qi(fe,a)){le||(fe.scroller.draggable=!1,setTimeout(function(){return fe.scroller.draggable=!0},100));return}if(!_l(y,a)){var de=da(y,a),xe=Zn(a),Fe=de?Pu(de,xe):"single";window.focus(),xe==1&&y.state.selectingText&&y.state.selectingText(a),!(de&&Nu(y,xe,de,Fe,a))&&(xe==1?de?Fu(y,de,Fe,a):Gn(a)==fe.scroller&&sn(a):xe==2?(de&&Va(y.doc,de),setTimeout(function(){return fe.input.focus()},20)):xe==3&&(he?y.display.input.onContextMenu(a):Za(y)))}}}function Nu(a,y,fe,de,xe){var Fe="Click";return de=="double"?Fe="Double"+Fe:de=="triple"&&(Fe="Triple"+Fe),Fe=(y==1?"Left":y==2?"Middle":"Right")+Fe,Gs(a,Gl(Fe,xe),xe,function(Je){if(typeof Je=="string"&&(Je=Zs[Je]),!Je)return!1;var it=!1;try{a.isReadOnly()&&(a.state.suppressEdits=!0),it=Je(a,fe)!=nt}finally{a.state.suppressEdits=!1}return it})}function Bu(a,y,fe){var de=a.getOption("configureMouse"),xe=de?de(a,y,fe):{};if(xe.unit==null){var Fe=ye?fe.shiftKey&&fe.metaKey:fe.altKey;xe.unit=Fe?"rectangle":y=="single"?"char":y=="double"?"word":"line"}return(xe.extend==null||a.doc.extend)&&(xe.extend=a.doc.extend||fe.shiftKey),xe.addNew==null&&(xe.addNew=ve?fe.metaKey:fe.ctrlKey),xe.moveOnDrag==null&&(xe.moveOnDrag=!(ve?fe.altKey:fe.ctrlKey)),xe}function Fu(a,y,fe,de){se?setTimeout(Ye(ra,a),0):a.curOp.focus=Xe();var xe=Bu(a,fe,de),Fe=a.doc.sel,Je;a.options.dragDrop&&tr&&!a.isReadOnly()&&fe=="single"&&(Je=Fe.contains(y))>-1&&(zt((Je=Fe.ranges[Je]).from(),y)<0||y.xRel>0)&&(zt(Je.to(),y)>0||y.xRel<0)?ju(a,de,y,xe):Uu(a,de,y,xe)}function ju(a,y,fe,de){var xe=a.display,Fe=!1,Je=Vn(a,function(ht){le&&(xe.scroller.draggable=!1),a.state.draggingText=!1,Ht(xe.wrapper.ownerDocument,"mouseup",Je),Ht(xe.wrapper.ownerDocument,"mousemove",it),Ht(xe.scroller,"dragstart",at),Ht(xe.scroller,"drop",Je),Fe||(sn(ht),de.addNew||Va(a.doc,fe,null,null,de.extend),le&&!b||se&&te==9?setTimeout(function(){xe.wrapper.ownerDocument.body.focus({preventScroll:!0}),xe.input.focus()},20):xe.input.focus())}),it=function(ht){Fe=Fe||Math.abs(y.clientX-ht.clientX)+Math.abs(y.clientY-ht.clientY)>=10},at=function(){return Fe=!0};le&&(xe.scroller.draggable=!0),a.state.draggingText=Je,Je.copy=!de.moveOnDrag,xe.scroller.dragDrop&&xe.scroller.dragDrop(),vt(xe.wrapper.ownerDocument,"mouseup",Je),vt(xe.wrapper.ownerDocument,"mousemove",it),vt(xe.scroller,"dragstart",at),vt(xe.scroller,"drop",Je),Za(a),setTimeout(function(){return xe.input.focus()},20)}function tu(a,y,fe){if(fe=="char")return new Sr(y,y);if(fe=="word")return a.findWordAt(y);if(fe=="line")return new Sr(Et(y.line,0),Tt(a.doc,Et(y.line+1,0)));var de=fe(a,y);return new Sr(de.from,de.to)}function Uu(a,y,fe,de){var xe=a.display,Fe=a.doc;sn(y);var Je,it,at=Fe.sel,ht=at.ranges;if(de.addNew&&!de.extend?(it=Fe.sel.contains(fe),it>-1?Je=ht[it]:Je=new Sr(fe,fe)):(Je=Fe.sel.primary(),it=Fe.sel.primIndex),de.unit=="rectangle")de.addNew||(Je=new Sr(fe,fe)),fe=da(a,y,!0,!0),it=-1;else{var It=tu(a,fe,de.unit);de.extend?Je=Ka(Je,It.anchor,It.head,de.extend):Je=It}de.addNew?it==-1?(it=ht.length,Uo(Fe,Fr(a,ht.concat([Je]),it),{scroll:!1,origin:"*mouse"})):ht.length>1&&ht[it].empty()&&de.unit=="char"&&!de.extend?(Uo(Fe,Fr(a,ht.slice(0,it).concat(ht.slice(it+1)),0),{scroll:!1,origin:"*mouse"}),at=Fe.sel):Ps(Fe,it,Je,pt):(it=0,Uo(Fe,new li([Je],0),pt),at=Fe.sel);var Ut=fe;function rn(lr){if(zt(Ut,lr)!=0)if(Ut=lr,de.unit=="rectangle"){for(var Er=[],Qr=a.options.tabSize,Hr=Ge(Ft(Fe,fe.line).text,fe.ch,Qr),Li=Ge(Ft(Fe,lr.line).text,lr.ch,Qr),to=Math.min(Hr,Li),Mo=Math.max(Hr,Li),ho=Math.min(fe.line,lr.line),sa=Math.min(a.lastLine(),Math.max(fe.line,lr.line));ho<=sa;ho++){var $o=Ft(Fe,ho).text,So=Ot($o,to,Qr);to==Mo?Er.push(new Sr(Et(ho,So),Et(ho,So))):$o.length>So&&Er.push(new Sr(Et(ho,So),Et(ho,Ot($o,Mo,Qr))))}Er.length||Er.push(new Sr(fe,fe)),Uo(Fe,Fr(a,at.ranges.slice(0,it).concat(Er),it),{origin:"*mouse",scroll:!1}),a.scrollIntoView(lr)}else{var ea=Je,Bo=tu(a,lr,de.unit),ko=ea.anchor,wo;zt(Bo.anchor,ko)>0?(wo=Bo.head,ko=Sn(ea.from(),Bo.anchor)):(wo=Bo.anchor,ko=gn(ea.to(),Bo.head));var vo=at.ranges.slice(0);vo[it]=zu(a,new Sr(Tt(Fe,ko),wo)),Uo(Fe,Fr(a,vo,it),pt)}}var Qt=xe.wrapper.getBoundingClientRect(),Dn=0;function Wn(lr){var Er=++Dn,Qr=da(a,lr,!0,de.unit=="rectangle");if(Qr)if(zt(Qr,Ut)!=0){a.curOp.focus=Xe(),rn(Qr);var Hr=ka(xe,Fe);(Qr.line>=Hr.to||Qr.line<Hr.from)&&setTimeout(Vn(a,function(){Dn==Er&&Wn(lr)}),150)}else{var Li=lr.clientY<Qt.top?-20:lr.clientY>Qt.bottom?20:0;Li&&setTimeout(Vn(a,function(){Dn==Er&&(xe.scroller.scrollTop+=Li,Wn(lr))}),50)}}function Qn(lr){a.state.selectingText=!1,Dn=1/0,lr&&(sn(lr),xe.input.focus()),Ht(xe.wrapper.ownerDocument,"mousemove",sr),Ht(xe.wrapper.ownerDocument,"mouseup",vr),Fe.history.lastSelOrigin=null}var sr=Vn(a,function(lr){lr.buttons===0||!Zn(lr)?Qn(lr):Wn(lr)}),vr=Vn(a,Qn);a.state.selectingText=vr,vt(xe.wrapper.ownerDocument,"mousemove",sr),vt(xe.wrapper.ownerDocument,"mouseup",vr)}function zu(a,y){var fe=y.anchor,de=y.head,xe=Ft(a.doc,fe.line);if(zt(fe,de)==0&&fe.sticky==de.sticky)return y;var Fe=Nt(xe);if(!Fe)return y;var Je=tt(Fe,fe.ch,fe.sticky),it=Fe[Je];if(it.from!=fe.ch&&it.to!=fe.ch)return y;var at=Je+(it.from==fe.ch==(it.level!=1)?0:1);if(at==0||at==Fe.length)return y;var ht;if(de.line!=fe.line)ht=(de.line-fe.line)*(a.doc.direction=="ltr"?1:-1)>0;else{var It=tt(Fe,de.ch,de.sticky),Ut=It-Je||(de.ch-fe.ch)*(it.level==1?-1:1);It==at-1||It==at?ht=Ut<0:ht=Ut>0}var rn=Fe[at+(ht?-1:0)],Qt=ht==(rn.level==1),Dn=Qt?rn.from:rn.to,Wn=Qt?"after":"before";return fe.ch==Dn&&fe.sticky==Wn?y:new Sr(new Et(fe.line,Dn,Wn),de)}function nu(a,y,fe,de){var xe,Fe;if(y.touches)xe=y.touches[0].clientX,Fe=y.touches[0].clientY;else try{xe=y.clientX,Fe=y.clientY}catch(rn){return!1}if(xe>=Math.floor(a.display.gutters.getBoundingClientRect().right))return!1;de&&sn(y);var Je=a.display,it=Je.lineDiv.getBoundingClientRect();if(Fe>it.bottom||!Lt(a,fe))return Vt(y);Fe-=it.top-Je.viewOffset;for(var at=0;at<a.display.gutterSpecs.length;++at){var ht=Je.gutters.childNodes[at];if(ht&&ht.getBoundingClientRect().right>=xe){var It=St(a.doc,Fe),Ut=a.display.gutterSpecs[at];return jt(a,fe,a,It,Ut.className,y),Vt(y)}}}function _l(a,y){return nu(a,y,"gutterClick",!0)}function ru(a,y){qi(a.display,y)||Hu(a,y)||yt(a,y,"contextmenu")||he||a.display.input.onContextMenu(y)}function Hu(a,y){return Lt(a,"gutterContextMenu")?nu(a,y,"gutterContextMenu",!1):!1}function iu(a){a.display.wrapper.className=a.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+a.options.theme.replace(/(^|\s)\s*/g," cm-s-"),pa(a)}var Ms={toString:function(){return"CodeMirror.Init"}},ou={},rl={};function Wu(a){var y=a.optionHandlers;function fe(de,xe,Fe,Je){a.defaults[de]=xe,Fe&&(y[de]=Je?function(it,at,ht){ht!=Ms&&Fe(it,at,ht)}:Fe)}a.defineOption=fe,a.Init=Ms,fe("value","",function(de,xe){return de.setValue(xe)},!0),fe("mode",null,function(de,xe){de.doc.modeOption=xe,aa(de)},!0),fe("indentUnit",2,aa,!0),fe("indentWithTabs",!1),fe("smartIndent",!0),fe("tabSize",4,function(de){ga(de),pa(de),Co(de)},!0),fe("lineSeparator",null,function(de,xe){if(de.doc.lineSep=xe,!!xe){var Fe=[],Je=de.doc.first;de.doc.iter(function(at){for(var ht=0;;){var It=at.text.indexOf(xe,ht);if(It==-1)break;ht=It+xe.length,Fe.push(Et(Je,It))}Je++});for(var it=Fe.length-1;it>=0;it--)Ls(de.doc,xe,Fe[it],Et(Fe[it].line,Fe[it].ch+xe.length))}}),fe("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,function(de,xe,Fe){de.state.specialChars=new RegExp(xe.source+(xe.test(" ")?"":"| "),"g"),Fe!=Ms&&de.refresh()}),fe("specialCharPlaceholder",ei,function(de){return de.refresh()},!0),fe("electricChars",!0),fe("inputStyle",oe?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),fe("spellcheck",!1,function(de,xe){return de.getInputField().spellcheck=xe},!0),fe("autocorrect",!1,function(de,xe){return de.getInputField().autocorrect=xe},!0),fe("autocapitalize",!1,function(de,xe){return de.getInputField().autocapitalize=xe},!0),fe("rtlMoveVisually",!me),fe("wholeLineUpdateBefore",!0),fe("theme","default",function(de){iu(de),er(de)},!0),fe("keyMap","default",function(de,xe,Fe){var Je=tl(xe),it=Fe!=Ms&&tl(Fe);it&&it.detach&&it.detach(de,Je),Je.attach&&Je.attach(de,it||null)}),fe("extraKeys",null),fe("configureMouse",null),fe("lineWrapping",!1,Gu,!0),fe("gutters",[],function(de,xe){de.display.gutterSpecs=ii(xe,de.options.lineNumbers),er(de)},!0),fe("fixedGutter",!0,function(de,xe){de.display.gutters.style.left=xe?Ia(de.display)+"px":"0",de.refresh()},!0),fe("coverGutterNextToScrollbar",!1,function(de){return bo(de)},!0),fe("scrollbarStyle","native",function(de){va(de),bo(de),de.display.scrollbars.setScrollTop(de.doc.scrollTop),de.display.scrollbars.setScrollLeft(de.doc.scrollLeft)},!0),fe("lineNumbers",!1,function(de,xe){de.display.gutterSpecs=ii(de.options.gutters,xe),er(de)},!0),fe("firstLineNumber",1,er,!0),fe("lineNumberFormatter",function(de){return de},er,!0),fe("showCursorWhenSelecting",!1,Oa,!0),fe("resetSelectionOnContextMenu",!0),fe("lineWiseCopyCut",!0),fe("pasteLinesPerSelection",!0),fe("selectionsMayTouch",!1),fe("readOnly",!1,function(de,xe){xe=="nocursor"&&(Ga(de),de.display.input.blur()),de.display.input.readOnlyChanged(xe)}),fe("screenReaderLabel",null,function(de,xe){xe=xe===""?null:xe,de.display.input.screenReaderLabelChanged(xe)}),fe("disableInput",!1,function(de,xe){xe||de.display.input.reset()},!0),fe("dragDrop",!0,Zu),fe("allowDropFileTypes",null),fe("cursorBlinkRate",530),fe("cursorScrollMargin",0),fe("cursorHeight",1,Oa,!0),fe("singleCursorHeightPerLine",!0,Oa,!0),fe("workTime",100),fe("workDelay",100),fe("flattenSpans",!0,ga,!0),fe("addModeClass",!1,ga,!0),fe("pollInterval",100),fe("undoDepth",200,function(de,xe){return de.doc.history.undoDepth=xe}),fe("historyEventDelay",1250),fe("viewportMargin",10,function(de){return de.refresh()},!0),fe("maxHighlightLength",1e4,ga,!0),fe("moveInputWithCursor",!0,function(de,xe){xe||de.display.input.resetPosition()}),fe("tabindex",null,function(de,xe){return de.display.input.getField().tabIndex=xe||""}),fe("autofocus",null),fe("direction","ltr",function(de,xe){return de.doc.setDirection(xe)},!0),fe("phrases",null)}function Zu(a,y,fe){var de=fe&&fe!=Ms;if(!y!=!de){var xe=a.display.dragFunctions,Fe=y?vt:Ht;Fe(a.display.scroller,"dragstart",xe.start),Fe(a.display.scroller,"dragenter",xe.enter),Fe(a.display.scroller,"dragover",xe.over),Fe(a.display.scroller,"dragleave",xe.leave),Fe(a.display.scroller,"drop",xe.drop)}}function Gu(a){a.options.lineWrapping?(ot(a.display.wrapper,"CodeMirror-wrap"),a.display.sizer.style.minWidth="",a.display.sizerWidth=null):(ke(a.display.wrapper,"CodeMirror-wrap"),nr(a)),fs(a),Co(a),pa(a),setTimeout(function(){return bo(a)},100)}function uo(a,y){var fe=this;if(!(this instanceof uo))return new uo(a,y);this.options=y=y?ut(y):{},ut(ou,y,!1);var de=y.value;typeof de=="string"?de=new Qo(de,y.mode,null,y.lineSeparator,y.direction):y.mode&&(de.modeOption=y.mode),this.doc=de;var xe=new uo.inputStyles[y.inputStyle](this),Fe=this.display=new Bi(a,de,xe,y);Fe.wrapper.CodeMirror=this,iu(this),y.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),va(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 ze,keySeq:null,specialChars:null},y.autofocus&&!oe&&Fe.input.focus(),se&&te<11&&setTimeout(function(){return fe.display.input.reset(!0)},20),Ku(this),xu(),Po(this),this.curOp.forceUpdate=!0,Ba(this,de),y.autofocus&&!oe||this.hasFocus()?setTimeout(function(){fe.hasFocus()&&!fe.state.focused&&Ea(fe)},20):Ga(this);for(var Je in rl)rl.hasOwnProperty(Je)&&rl[Je](this,y[Je],Ms);Zi(this),y.finishInit&&y.finishInit(this);for(var it=0;it<bl.length;++it)bl[it](this);fa(this),le&&y.lineWrapping&&getComputedStyle(Fe.lineDiv).textRendering=="optimizelegibility"&&(Fe.lineDiv.style.textRendering="auto")}uo.defaults=ou,uo.optionHandlers=rl;function Ku(a){var y=a.display;vt(y.scroller,"mousedown",Vn(a,eu)),se&&te<11?vt(y.scroller,"dblclick",Vn(a,function(at){if(!yt(a,at)){var ht=da(a,at);if(!(!ht||_l(a,at)||qi(a.display,at))){sn(at);var It=a.findWordAt(ht);Va(a.doc,It.anchor,It.head)}}})):vt(y.scroller,"dblclick",function(at){return yt(a,at)||sn(at)}),vt(y.scroller,"contextmenu",function(at){return ru(a,at)}),vt(y.input.getField(),"contextmenu",function(at){y.scroller.contains(at.target)||ru(a,at)});var fe,de={end:0};function xe(){y.activeTouch&&(fe=setTimeout(function(){return y.activeTouch=null},1e3),de=y.activeTouch,de.end=+new Date)}function Fe(at){if(at.touches.length!=1)return!1;var ht=at.touches[0];return ht.radiusX<=1&&ht.radiusY<=1}function Je(at,ht){if(ht.left==null)return!0;var It=ht.left-at.left,Ut=ht.top-at.top;return It*It+Ut*Ut>20*20}vt(y.scroller,"touchstart",function(at){if(!yt(a,at)&&!Fe(at)&&!_l(a,at)){y.input.ensurePolled(),clearTimeout(fe);var ht=+new Date;y.activeTouch={start:ht,moved:!1,prev:ht-de.end<=300?de:null},at.touches.length==1&&(y.activeTouch.left=at.touches[0].pageX,y.activeTouch.top=at.touches[0].pageY)}}),vt(y.scroller,"touchmove",function(){y.activeTouch&&(y.activeTouch.moved=!0)}),vt(y.scroller,"touchend",function(at){var ht=y.activeTouch;if(ht&&!qi(y,at)&&ht.left!=null&&!ht.moved&&new Date-ht.start<300){var It=a.coordsChar(y.activeTouch,"page"),Ut;!ht.prev||Je(ht,ht.prev)?Ut=new Sr(It,It):!ht.prev.prev||Je(ht,ht.prev.prev)?Ut=a.findWordAt(It):Ut=new Sr(Et(It.line,0),Tt(a.doc,Et(It.line+1,0))),a.setSelection(Ut.anchor,Ut.head),a.focus(),sn(at)}xe()}),vt(y.scroller,"touchcancel",xe),vt(y.scroller,"scroll",function(){y.scroller.clientHeight&&(ia(a,y.scroller.scrollTop),ma(a,y.scroller.scrollLeft,!0),jt(a,"scroll",a))}),vt(y.scroller,"mousewheel",function(at){return Gi(a,at)}),vt(y.scroller,"DOMMouseScroll",function(at){return Gi(a,at)}),vt(y.wrapper,"scroll",function(){return y.wrapper.scrollTop=y.wrapper.scrollLeft=0}),y.dragFunctions={enter:function(at){yt(a,at)||Rn(at)},over:function(at){yt(a,at)||(wu(a,at),Rn(at))},start:function(at){return Su(a,at)},drop:Vn(a,bu),leave:function(at){yt(a,at)||zl(a)}};var it=y.input.getField();vt(it,"keyup",function(at){return Ql.call(a,at)}),vt(it,"keydown",Vn(a,Jl)),vt(it,"keypress",Vn(a,$l)),vt(it,"focus",function(at){return Ea(a,at)}),vt(it,"blur",function(at){return Ga(a,at)})}var bl=[];uo.defineInitHook=function(a){return bl.push(a)};function Ys(a,y,fe,de){var xe=a.doc,Fe;fe==null&&(fe="add"),fe=="smart"&&(xe.mode.indent?Fe=Rr(a,y).state:fe="prev");var Je=a.options.tabSize,it=Ft(xe,y),at=Ge(it.text,null,Je);it.stateAfter&&(it.stateAfter=null);var ht=it.text.match(/^\s*/)[0],It;if(!de&&!/\S/.test(it.text))It=0,fe="not";else if(fe=="smart"&&(It=xe.mode.indent(Fe,it.text.slice(ht.length),it.text),It==nt||It>150)){if(!de)return;fe="prev"}fe=="prev"?y>xe.first?It=Ge(Ft(xe,y-1).text,null,Je):It=0:fe=="add"?It=at+a.options.indentUnit:fe=="subtract"?It=at-a.options.indentUnit:typeof fe=="number"&&(It=at+fe),It=Math.max(0,It);var Ut="",rn=0;if(a.options.indentWithTabs)for(var Qt=Math.floor(It/Je);Qt;--Qt)rn+=Je,Ut+=" ";if(rn<It&&(Ut+=Rt(It-rn)),Ut!=ht)return Ls(xe,Ut,Et(y,0),Et(y,ht.length),"+input"),it.stateAfter=null,!0;for(var Dn=0;Dn<xe.sel.ranges.length;Dn++){var Wn=xe.sel.ranges[Dn];if(Wn.head.line==y&&Wn.head.ch<ht.length){var Qn=Et(y,ht.length);Ps(xe,Dn,new Sr(Qn,Qn));break}}}var Ta=null;function il(a){Ta=a}function Sl(a,y,fe,de,xe){var Fe=a.doc;a.display.shift=!1,de||(de=Fe.sel);var Je=+new Date-200,it=xe=="paste"||a.state.pasteIncoming>Je,at=ir(y),ht=null;if(it&&de.ranges.length>1)if(Ta&&Ta.text.join(`
|
|
|
`)==y){if(de.ranges.length%Ta.text.length==0){ht=[];for(var It=0;It<Ta.text.length;It++)ht.push(Fe.splitLines(Ta.text[It]))}}else at.length==de.ranges.length&&a.options.pasteLinesPerSelection&&(ht=gt(at,function(sr){return[sr]}));for(var Ut=a.curOp.updateInput,rn=de.ranges.length-1;rn>=0;rn--){var Qt=de.ranges[rn],Dn=Qt.from(),Wn=Qt.to();Qt.empty()&&(fe&&fe>0?Dn=Et(Dn.line,Dn.ch-fe):a.state.overwrite&&!it?Wn=Et(Wn.line,Math.min(Ft(Fe,Wn.line).text.length,Wn.ch+xt(at).length)):it&&Ta&&Ta.lineWise&&Ta.text.join(`
|
|
|
`)==at.join(`
|
|
|
`)&&(Dn=Wn=Et(Dn.line,0)));var Qn={from:Dn,to:Wn,text:ht?ht[rn%ht.length]:at,origin:xe||(it?"paste":a.state.cutIncoming>Je?"cut":"+input")};ks(a.doc,Qn),Ri(a,"inputRead",a,Qn)}y&&!it&&su(a,y),La(a),a.curOp.updateInput<2&&(a.curOp.updateInput=Ut),a.curOp.typing=!0,a.state.pasteIncoming=a.state.cutIncoming=-1}function au(a,y){var fe=a.clipboardData&&a.clipboardData.getData("Text");if(fe)return a.preventDefault(),!y.isReadOnly()&&!y.options.disableInput&&wt(y,function(){return Sl(y,fe,0,null,"paste")}),!0}function su(a,y){if(!(!a.options.electricChars||!a.options.smartIndent))for(var fe=a.doc.sel,de=fe.ranges.length-1;de>=0;de--){var xe=fe.ranges[de];if(!(xe.head.ch>100||de&&fe.ranges[de-1].head.line==xe.head.line)){var Fe=a.getModeAt(xe.head),Je=!1;if(Fe.electricChars){for(var it=0;it<Fe.electricChars.length;it++)if(y.indexOf(Fe.electricChars.charAt(it))>-1){Je=Ys(a,xe.head.line,"smart");break}}else Fe.electricInput&&Fe.electricInput.test(Ft(a.doc,xe.head.line).text.slice(0,xe.head.ch))&&(Je=Ys(a,xe.head.line,"smart"));Je&&Ri(a,"electricInput",a,xe.head.line)}}}function lu(a){for(var y=[],fe=[],de=0;de<a.doc.sel.ranges.length;de++){var xe=a.doc.sel.ranges[de].head.line,Fe={anchor:Et(xe,0),head:Et(xe+1,0)};fe.push(Fe),y.push(a.getRange(Fe.anchor,Fe.head))}return{text:y,ranges:fe}}function uu(a,y,fe,de){a.setAttribute("autocorrect",fe?"":"off"),a.setAttribute("autocapitalize",de?"":"off"),a.setAttribute("spellcheck",!!y)}function cu(){var a=Oe("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),y=Oe("div",[a],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return le?a.style.width="1000px":a.setAttribute("wrap","off"),re&&(a.style.border="1px solid black"),uu(a),y}function Vu(a){var y=a.optionHandlers,fe=a.helpers={};a.prototype={constructor:a,focus:function(){window.focus(),this.display.input.focus()},setOption:function(de,xe){var Fe=this.options,Je=Fe[de];Fe[de]==xe&&de!="mode"||(Fe[de]=xe,y.hasOwnProperty(de)&&Vn(this,y[de])(this,xe,Je),jt(this,"optionChange",this,de))},getOption:function(de){return this.options[de]},getDoc:function(){return this.doc},addKeyMap:function(de,xe){this.state.keyMaps[xe?"push":"unshift"](tl(de))},removeKeyMap:function(de){for(var xe=this.state.keyMaps,Fe=0;Fe<xe.length;++Fe)if(xe[Fe]==de||xe[Fe].name==de)return xe.splice(Fe,1),!0},addOverlay:In(function(de,xe){var Fe=de.token?de:a.getMode(this.options,de);if(Fe.startState)throw new Error("Overlays may not be stateful.");_t(this.state.overlays,{mode:Fe,modeSpec:de,opaque:xe&&xe.opaque,priority:xe&&xe.priority||0},function(Je){return Je.priority}),this.state.modeGen++,Co(this)}),removeOverlay:In(function(de){for(var xe=this.state.overlays,Fe=0;Fe<xe.length;++Fe){var Je=xe[Fe].modeSpec;if(Je==de||typeof de=="string"&&Je.name==de){xe.splice(Fe,1),this.state.modeGen++,Co(this);return}}}),indentLine:In(function(de,xe,Fe){typeof xe!="string"&&typeof xe!="number"&&(xe==null?xe=this.options.smartIndent?"smart":"prev":xe=xe?"add":"subtract"),an(this.doc,de)&&Ys(this,de,xe,Fe)}),indentSelection:In(function(de){for(var xe=this.doc.sel.ranges,Fe=-1,Je=0;Je<xe.length;Je++){var it=xe[Je];if(it.empty())it.head.line>Fe&&(Ys(this,it.head.line,de,!0),Fe=it.head.line,Je==this.doc.sel.primIndex&&La(this));else{var at=it.from(),ht=it.to(),It=Math.max(Fe,at.line);Fe=Math.min(this.lastLine(),ht.line-(ht.ch?0:1))+1;for(var Ut=It;Ut<Fe;++Ut)Ys(this,Ut,de);var rn=this.doc.sel.ranges;at.ch==0&&xe.length==rn.length&&rn[Je].from().ch>0&&Ps(this.doc,Je,new Sr(at,rn[Je].to()),et)}}}),getTokenAt:function(de,xe){return Ir(this,de,xe)},getLineTokens:function(de,xe){return Ir(this,Et(de),xe,!0)},getTokenTypeAt:function(de){de=Tt(this.doc,de);var xe=pr(this,Ft(this.doc,de.line)),Fe=0,Je=(xe.length-1)/2,it=de.ch,at;if(it==0)at=xe[2];else for(;;){var ht=Fe+Je>>1;if((ht?xe[ht*2-1]:0)>=it)Je=ht;else if(xe[ht*2+1]<it)Fe=ht+1;else{at=xe[ht*2+2];break}}var It=at?at.indexOf("overlay "):-1;return It<0?at:It==0?null:at.slice(0,It-1)},getModeAt:function(de){var xe=this.doc.mode;return xe.innerMode?a.innerMode(xe,this.getTokenAt(de).state).mode:xe},getHelper:function(de,xe){return this.getHelpers(de,xe)[0]},getHelpers:function(de,xe){var Fe=[];if(!fe.hasOwnProperty(xe))return Fe;var Je=fe[xe],it=this.getModeAt(de);if(typeof it[xe]=="string")Je[it[xe]]&&Fe.push(Je[it[xe]]);else if(it[xe])for(var at=0;at<it[xe].length;at++){var ht=Je[it[xe][at]];ht&&Fe.push(ht)}else it.helperType&&Je[it.helperType]?Fe.push(Je[it.helperType]):Je[it.name]&&Fe.push(Je[it.name]);for(var It=0;It<Je._global.length;It++){var Ut=Je._global[It];Ut.pred(it,this)&&Ve(Fe,Ut.val)==-1&&Fe.push(Ut.val)}return Fe},getStateAfter:function(de,xe){var Fe=this.doc;return de=Tn(Fe,de==null?Fe.first+Fe.size-1:de),Rr(this,de+1,xe).state},cursorCoords:function(de,xe){var Fe,Je=this.doc.sel.primary();return de==null?Fe=Je.head:typeof de=="object"?Fe=Tt(this.doc,de):Fe=de?Je.from():Je.to(),Ji(this,Fe,xe||"page")},charCoords:function(de,xe){return To(this,Tt(this.doc,de),xe||"page")},coordsChar:function(de,xe){return de=ua(this,de,xe||"page"),ro(this,de.left,de.top)},lineAtHeight:function(de,xe){return de=ua(this,{top:de,left:0},xe||"page").top,St(this.doc,de+this.display.viewOffset)},heightAtLine:function(de,xe,Fe){var Je=!1,it;if(typeof de=="number"){var at=this.doc.first+this.doc.size-1;de<this.doc.first?de=this.doc.first:de>at&&(de=at,Je=!0),it=Ft(this.doc,de)}else it=de;return wa(this,it,{top:0,left:0},xe||"page",Fe||Je).top+(Je?this.doc.height-Xn(it):0)},defaultTextHeight:function(){return go(this.display)},defaultCharWidth:function(){return Fo(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(de,xe,Fe,Je,it){var at=this.display;de=Ji(this,Tt(this.doc,de));var ht=de.bottom,It=de.left;if(xe.style.position="absolute",xe.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(xe),at.sizer.appendChild(xe),Je=="over")ht=de.top;else if(Je=="above"||Je=="near"){var Ut=Math.max(at.wrapper.clientHeight,this.doc.height),rn=Math.max(at.sizer.clientWidth,at.lineSpace.clientWidth);(Je=="above"||de.bottom+xe.offsetHeight>Ut)&&de.top>xe.offsetHeight?ht=de.top-xe.offsetHeight:de.bottom+xe.offsetHeight<=Ut&&(ht=de.bottom),It+xe.offsetWidth>rn&&(It=rn-xe.offsetWidth)}xe.style.top=ht+"px",xe.style.left=xe.style.right="",it=="right"?(It=at.sizer.clientWidth-xe.offsetWidth,xe.style.right="0px"):(it=="left"?It=0:it=="middle"&&(It=(at.sizer.clientWidth-xe.offsetWidth)/2),xe.style.left=It+"px"),Fe&&ws(this,{left:It,top:ht,right:It+xe.offsetWidth,bottom:ht+xe.offsetHeight})},triggerOnKeyDown:In(Jl),triggerOnKeyPress:In($l),triggerOnKeyUp:Ql,triggerOnMouseDown:In(eu),execCommand:function(de){if(Zs.hasOwnProperty(de))return Zs[de].call(null,this)},triggerElectric:In(function(de){su(this,de)}),findPosH:function(de,xe,Fe,Je){var it=1;xe<0&&(it=-1,xe=-xe);for(var at=Tt(this.doc,de),ht=0;ht<xe&&(at=wl(this.doc,at,it,Fe,Je),!at.hitSide);++ht);return at},moveH:In(function(de,xe){var Fe=this;this.extendSelectionsBy(function(Je){return Fe.display.shift||Fe.doc.extend||Je.empty()?wl(Fe.doc,Je.head,de,xe,Fe.options.rtlMoveVisually):de<0?Je.from():Je.to()},ct)}),deleteH:In(function(de,xe){var Fe=this.doc.sel,Je=this.doc;Fe.somethingSelected()?Je.replaceSelection("",null,"+delete"):Ds(this,function(it){var at=wl(Je,it.head,de,xe,!1);return de<0?{from:at,to:it.head}:{from:it.head,to:at}})}),findPosV:function(de,xe,Fe,Je){var it=1,at=Je;xe<0&&(it=-1,xe=-xe);for(var ht=Tt(this.doc,de),It=0;It<xe;++It){var Ut=Ji(this,ht,"div");if(at==null?at=Ut.left:Ut.left=at,ht=du(this,Ut,it,Fe),ht.hitSide)break}return ht},moveV:In(function(de,xe){var Fe=this,Je=this.doc,it=[],at=!this.display.shift&&!Je.extend&&Je.sel.somethingSelected();if(Je.extendSelectionsBy(function(It){if(at)return de<0?It.from():It.to();var Ut=Ji(Fe,It.head,"div");It.goalColumn!=null&&(Ut.left=It.goalColumn),it.push(Ut.left);var rn=du(Fe,Ut,de,xe);return xe=="page"&&It==Je.sel.primary()&&rs(Fe,To(Fe,rn,"div").top-Ut.top),rn},ct),it.length)for(var ht=0;ht<Je.sel.ranges.length;ht++)Je.sel.ranges[ht].goalColumn=it[ht]}),findWordAt:function(de){var xe=this.doc,Fe=Ft(xe,de.line).text,Je=de.ch,it=de.ch;if(Fe){var at=this.getHelper(de,"wordChars");(de.sticky=="before"||it==Fe.length)&&Je?--Je:++it;for(var ht=Fe.charAt(Je),It=Ke(ht,at)?function(Ut){return Ke(Ut,at)}:/\s/.test(ht)?function(Ut){return/\s/.test(Ut)}:function(Ut){return!/\s/.test(Ut)&&!Ke(Ut)};Je>0&&It(Fe.charAt(Je-1));)--Je;for(;it<Fe.length&&It(Fe.charAt(it));)++it}return new Sr(Et(de.line,Je),Et(de.line,it))},toggleOverwrite:function(de){de!=null&&de==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?ot(this.display.cursorDiv,"CodeMirror-overwrite"):ke(this.display.cursorDiv,"CodeMirror-overwrite"),jt(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==Xe()},isReadOnly:function(){return!!(this.options.readOnly||this.doc.cantEdit)},scrollTo:In(function(de,xe){Nr(this,de,xe)}),getScrollInfo:function(){var de=this.display.scroller;return{left:de.scrollLeft,top:de.scrollTop,height:de.scrollHeight-Ui(this)-this.display.barHeight,width:de.scrollWidth-Ui(this)-this.display.barWidth,clientHeight:xo(this),clientWidth:Ho(this)}},scrollIntoView:In(function(de,xe){de==null?(de={from:this.doc.sel.primary().head,to:null},xe==null&&(xe=this.options.cursorScrollMargin)):typeof de=="number"?de={from:Et(de,0),to:null}:de.from==null&&(de={from:de,to:null}),de.to||(de.to=de.from),de.margin=xe||0,de.from.line!=null?xs(this,de):vs(this,de.from,de.to,de.margin)}),setSize:In(function(de,xe){var Fe=this,Je=function(at){return typeof at=="number"||/^\d+$/.test(String(at))?at+"px":at};de!=null&&(this.display.wrapper.style.width=Je(de)),xe!=null&&(this.display.wrapper.style.height=Je(xe)),this.options.lineWrapping&&Ra(this);var it=this.display.viewFrom;this.doc.iter(it,this.display.viewTo,function(at){if(at.widgets){for(var ht=0;ht<at.widgets.length;ht++)if(at.widgets[ht].noHScroll){Eo(Fe,it,"widget");break}}++it}),this.curOp.forceUpdate=!0,jt(this,"refresh",this)}),operation:function(de){return wt(this,de)},startOperation:function(){return Po(this)},endOperation:function(){return fa(this)},refresh:In(function(){var de=this.display.cachedTextHeight;Co(this),this.curOp.forceUpdate=!0,pa(this),Nr(this,this.doc.scrollLeft,this.doc.scrollTop),zi(this.display),(de==null||Math.abs(de-go(this.display))>.5||this.options.lineWrapping)&&fs(this),jt(this,"refresh",this)}),swapDoc:In(function(de){var xe=this.doc;return xe.cm=null,this.state.selectingText&&this.state.selectingText(),Ba(this,de),pa(this),this.display.input.reset(),Nr(this,de.scrollLeft,de.scrollTop),this.curOp.forceScroll=!0,Ri(this,"swapDoc",this,xe),xe}),phrase:function(de){var xe=this.options.phrases;return xe&&Object.prototype.hasOwnProperty.call(xe,de)?xe[de]:de},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}},Kt(a),a.registerHelper=function(de,xe,Fe){fe.hasOwnProperty(de)||(fe[de]=a[de]={_global:[]}),fe[de][xe]=Fe},a.registerGlobalHelper=function(de,xe,Fe,Je){a.registerHelper(de,xe,Je),fe[de]._global.push({pred:Fe,val:Je})}}function wl(a,y,fe,de,xe){var Fe=y,Je=fe,it=Ft(a,y.line),at=xe&&a.direction=="rtl"?-fe:fe;function ht(){var vr=y.line+at;return vr<a.first||vr>=a.first+a.size?!1:(y=new Et(vr,y.ch,y.sticky),it=Ft(a,vr))}function It(vr){var lr;if(de=="codepoint"){var Er=it.text.charCodeAt(y.ch+(de>0?0:-1));isNaN(Er)?lr=null:lr=new Et(y.line,Math.max(0,Math.min(it.text.length,y.ch+fe*(Er>=55296&&Er<56320?2:1))),-fe)}else xe?lr=Au(a.cm,it,y,fe):lr=ml(it,y,fe);if(lr==null)if(!vr&&ht())y=vl(xe,a.cm,it,y.line,at);else return!1;else y=lr;return!0}if(de=="char"||de=="codepoint")It();else if(de=="column")It(!0);else if(de=="word"||de=="group")for(var Ut=null,rn=de=="group",Qt=a.cm&&a.cm.getHelper(y,"wordChars"),Dn=!0;!(fe<0&&!It(!Dn));Dn=!1){var Wn=it.text.charAt(y.ch)||`
|
|
|
`,Qn=Ke(Wn,Qt)?"w":rn&&Wn==`
|
|
|
`?"n":!rn||/\s/.test(Wn)?null:"p";if(rn&&!Dn&&!Qn&&(Qn="s"),Ut&&Ut!=Qn){fe<0&&(fe=1,It(),y.sticky="after");break}if(Qn&&(Ut=Qn),fe>0&&!It(!Dn))break}var sr=Qs(a,y,Fe,Je,!0);return tn(Fe,sr)&&(sr.hitSide=!0),sr}function du(a,y,fe,de){var xe=a.doc,Fe=y.left,Je;if(de=="page"){var it=Math.min(a.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),at=Math.max(it-.5*go(a.display),3);Je=(fe>0?y.bottom:y.top)+fe*at}else de=="line"&&(Je=fe>0?y.bottom+3:y.top-3);for(var ht;ht=ro(a,Fe,Je),!!ht.outside;){if(fe<0?Je<=0:Je>=xe.height){ht.hitSide=!0;break}Je+=fe*5}return ht}var Yi=function(a){this.cm=a,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new ze,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};Yi.prototype.init=function(a){var y=this,fe=this,de=fe.cm,xe=fe.div=a.lineDiv;uu(xe,de.options.spellcheck,de.options.autocorrect,de.options.autocapitalize);function Fe(it){for(var at=it.target;at;at=at.parentNode){if(at==xe)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(at.className))break}return!1}vt(xe,"paste",function(it){!Fe(it)||yt(de,it)||au(it,de)||te<=11&&setTimeout(Vn(de,function(){return y.updateFromDOM()}),20)}),vt(xe,"compositionstart",function(it){y.composing={data:it.data,done:!1}}),vt(xe,"compositionupdate",function(it){y.composing||(y.composing={data:it.data,done:!1})}),vt(xe,"compositionend",function(it){y.composing&&(it.data!=y.composing.data&&y.readFromDOMSoon(),y.composing.done=!0)}),vt(xe,"touchstart",function(){return fe.forceCompositionEnd()}),vt(xe,"input",function(){y.composing||y.readFromDOMSoon()});function Je(it){if(!(!Fe(it)||yt(de,it))){if(de.somethingSelected())il({lineWise:!1,text:de.getSelections()}),it.type=="cut"&&de.replaceSelection("",null,"cut");else if(de.options.lineWiseCopyCut){var at=lu(de);il({lineWise:!0,text:at.text}),it.type=="cut"&&de.operation(function(){de.setSelections(at.ranges,0,et),de.replaceSelection("",null,"cut")})}else return;if(it.clipboardData){it.clipboardData.clearData();var ht=Ta.text.join(`
|
|
|
`);if(it.clipboardData.setData("Text",ht),it.clipboardData.getData("Text")==ht){it.preventDefault();return}}var It=cu(),Ut=It.firstChild;de.display.lineSpace.insertBefore(It,de.display.lineSpace.firstChild),Ut.value=Ta.text.join(`
|
|
|
`);var rn=document.activeElement;rt(Ut),setTimeout(function(){de.display.lineSpace.removeChild(It),rn.focus(),rn==xe&&fe.showPrimarySelection()},50)}}vt(xe,"copy",Je),vt(xe,"cut",Je)},Yi.prototype.screenReaderLabelChanged=function(a){a?this.div.setAttribute("aria-label",a):this.div.removeAttribute("aria-label")},Yi.prototype.prepareSelection=function(){var a=bs(this.cm,!1);return a.focus=document.activeElement==this.div,a},Yi.prototype.showSelection=function(a,y){!a||!this.cm.display.view.length||((a.focus||y)&&this.showPrimarySelection(),this.showMultipleSelections(a))},Yi.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Yi.prototype.showPrimarySelection=function(){var a=this.getSelection(),y=this.cm,fe=y.doc.sel.primary(),de=fe.from(),xe=fe.to();if(y.display.viewTo==y.display.viewFrom||de.line>=y.display.viewTo||xe.line<y.display.viewFrom){a.removeAllRanges();return}var Fe=ol(y,a.anchorNode,a.anchorOffset),Je=ol(y,a.focusNode,a.focusOffset);if(!(Fe&&!Fe.bad&&Je&&!Je.bad&&zt(Sn(Fe,Je),de)==0&&zt(gn(Fe,Je),xe)==0)){var it=y.display.view,at=de.line>=y.display.viewFrom&&fu(y,de)||{node:it[0].measure.map[2],offset:0},ht=xe.line<y.display.viewTo&&fu(y,xe);if(!ht){var It=it[it.length-1].measure,Ut=It.maps?It.maps[It.maps.length-1]:It.map;ht={node:Ut[Ut.length-1],offset:Ut[Ut.length-2]-Ut[Ut.length-3]}}if(!at||!ht){a.removeAllRanges();return}var rn=a.rangeCount&&a.getRangeAt(0),Qt;try{Qt=Pe(at.node,at.offset,ht.offset,ht.node)}catch(Dn){}Qt&&(!ce&&y.state.focused?(a.collapse(at.node,at.offset),Qt.collapsed||(a.removeAllRanges(),a.addRange(Qt))):(a.removeAllRanges(),a.addRange(Qt)),rn&&a.anchorNode==null?a.addRange(rn):ce&&this.startGracePeriod()),this.rememberSelection()}},Yi.prototype.startGracePeriod=function(){var a=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){a.gracePeriod=!1,a.selectionChanged()&&a.cm.operation(function(){return a.cm.curOp.selectionChanged=!0})},20)},Yi.prototype.showMultipleSelections=function(a){Ee(this.cm.display.cursorDiv,a.cursors),Ee(this.cm.display.selectionDiv,a.selection)},Yi.prototype.rememberSelection=function(){var a=this.getSelection();this.lastAnchorNode=a.anchorNode,this.lastAnchorOffset=a.anchorOffset,this.lastFocusNode=a.focusNode,this.lastFocusOffset=a.focusOffset},Yi.prototype.selectionInEditor=function(){var a=this.getSelection();if(!a.rangeCount)return!1;var y=a.getRangeAt(0).commonAncestorContainer;return Qe(this.div,y)},Yi.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||document.activeElement!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},Yi.prototype.blur=function(){this.div.blur()},Yi.prototype.getField=function(){return this.div},Yi.prototype.supportsTouch=function(){return!0},Yi.prototype.receivedFocus=function(){var a=this;this.selectionInEditor()?this.pollSelection():wt(this.cm,function(){return a.cm.curOp.selectionChanged=!0});function y(){a.cm.state.focused&&(a.pollSelection(),a.polling.set(a.cm.options.pollInterval,y))}this.polling.set(this.cm.options.pollInterval,y)},Yi.prototype.selectionChanged=function(){var a=this.getSelection();return a.anchorNode!=this.lastAnchorNode||a.anchorOffset!=this.lastAnchorOffset||a.focusNode!=this.lastFocusNode||a.focusOffset!=this.lastFocusOffset},Yi.prototype.pollSelection=function(){if(!(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())){var a=this.getSelection(),y=this.cm;if(ae&&ne&&this.cm.display.gutterSpecs.length&&Yu(a.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(!this.composing){this.rememberSelection();var fe=ol(y,a.anchorNode,a.anchorOffset),de=ol(y,a.focusNode,a.focusOffset);fe&&de&&wt(y,function(){Uo(y.doc,mi(fe,de),et),(fe.bad||de.bad)&&(y.curOp.selectionChanged=!0)})}}},Yi.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var a=this.cm,y=a.display,fe=a.doc.sel.primary(),de=fe.from(),xe=fe.to();if(de.ch==0&&de.line>a.firstLine()&&(de=Et(de.line-1,Ft(a.doc,de.line-1).length)),xe.ch==Ft(a.doc,xe.line).text.length&&xe.line<a.lastLine()&&(xe=Et(xe.line+1,0)),de.line<y.viewFrom||xe.line>y.viewTo-1)return!1;var Fe,Je,it;de.line==y.viewFrom||(Fe=yo(a,de.line))==0?(Je=At(y.view[0].line),it=y.view[0].node):(Je=At(y.view[Fe].line),it=y.view[Fe-1].node.nextSibling);var at=yo(a,xe.line),ht,It;if(at==y.view.length-1?(ht=y.viewTo-1,It=y.lineDiv.lastChild):(ht=At(y.view[at+1].line)-1,It=y.view[at+1].node.previousSibling),!it)return!1;for(var Ut=a.doc.splitLines(Xu(a,it,It,Je,ht)),rn=qt(a.doc,Et(Je,0),Et(ht,Ft(a.doc,ht).text.length));Ut.length>1&&rn.length>1;)if(xt(Ut)==xt(rn))Ut.pop(),rn.pop(),ht--;else if(Ut[0]==rn[0])Ut.shift(),rn.shift(),Je++;else break;for(var Qt=0,Dn=0,Wn=Ut[0],Qn=rn[0],sr=Math.min(Wn.length,Qn.length);Qt<sr&&Wn.charCodeAt(Qt)==Qn.charCodeAt(Qt);)++Qt;for(var vr=xt(Ut),lr=xt(rn),Er=Math.min(vr.length-(Ut.length==1?Qt:0),lr.length-(rn.length==1?Qt:0));Dn<Er&&vr.charCodeAt(vr.length-Dn-1)==lr.charCodeAt(lr.length-Dn-1);)++Dn;if(Ut.length==1&&rn.length==1&&Je==de.line)for(;Qt&&Qt>de.ch&&vr.charCodeAt(vr.length-Dn-1)==lr.charCodeAt(lr.length-Dn-1);)Qt--,Dn++;Ut[Ut.length-1]=vr.slice(0,vr.length-Dn).replace(/^\u200b+/,""),Ut[0]=Ut[0].slice(Qt).replace(/\u200b+$/,"");var Qr=Et(Je,Qt),Hr=Et(ht,rn.length?xt(rn).length-Dn:0);if(Ut.length>1||Ut[0]||zt(Qr,Hr))return Ls(a.doc,Ut,Qr,Hr,"+input"),!0},Yi.prototype.ensurePolled=function(){this.forceCompositionEnd()},Yi.prototype.reset=function(){this.forceCompositionEnd()},Yi.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Yi.prototype.readFromDOMSoon=function(){var a=this;this.readDOMTimeout==null&&(this.readDOMTimeout=setTimeout(function(){if(a.readDOMTimeout=null,a.composing)if(a.composing.done)a.composing=null;else return;a.updateFromDOM()},80))},Yi.prototype.updateFromDOM=function(){var a=this;(this.cm.isReadOnly()||!this.pollContent())&&wt(this.cm,function(){return Co(a.cm)})},Yi.prototype.setUneditable=function(a){a.contentEditable="false"},Yi.prototype.onKeyPress=function(a){a.charCode==0||this.composing||(a.preventDefault(),this.cm.isReadOnly()||Vn(this.cm,Sl)(this.cm,String.fromCharCode(a.charCode==null?a.keyCode:a.charCode),0))},Yi.prototype.readOnlyChanged=function(a){this.div.contentEditable=String(a!="nocursor")},Yi.prototype.onContextMenu=function(){},Yi.prototype.resetPosition=function(){},Yi.prototype.needsContentAttribute=!0;function fu(a,y){var fe=Yo(a,y.line);if(!fe||fe.hidden)return null;var de=Ft(a.doc,y.line),xe=Vi(fe,de,y.line),Fe=Nt(de,a.doc.direction),Je="left";if(Fe){var it=tt(Fe,y.ch);Je=it%2?"right":"left"}var at=qa(xe.map,y.ch,Je);return at.offset=at.collapse=="right"?at.end:at.start,at}function Yu(a){for(var y=a;y;y=y.parentNode)if(/CodeMirror-gutter-wrapper/.test(y.className))return!0;return!1}function Rs(a,y){return y&&(a.bad=!0),a}function Xu(a,y,fe,de,xe){var Fe="",Je=!1,it=a.doc.lineSeparator(),at=!1;function ht(Qt){return function(Dn){return Dn.id==Qt}}function It(){Je&&(Fe+=it,at&&(Fe+=it),Je=at=!1)}function Ut(Qt){Qt&&(It(),Fe+=Qt)}function rn(Qt){if(Qt.nodeType==1){var Dn=Qt.getAttribute("cm-text");if(Dn){Ut(Dn);return}var Wn=Qt.getAttribute("cm-marker"),Qn;if(Wn){var sr=a.findMarks(Et(de,0),Et(xe+1,0),ht(+Wn));sr.length&&(Qn=sr[0].find(0))&&Ut(qt(a.doc,Qn.from,Qn.to).join(it));return}if(Qt.getAttribute("contenteditable")=="false")return;var vr=/^(pre|div|p|li|table|br)$/i.test(Qt.nodeName);if(!/^br$/i.test(Qt.nodeName)&&Qt.textContent.length==0)return;vr&&It();for(var lr=0;lr<Qt.childNodes.length;lr++)rn(Qt.childNodes[lr]);/^(pre|p)$/i.test(Qt.nodeName)&&(at=!0),vr&&(Je=!0)}else Qt.nodeType==3&&Ut(Qt.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;rn(y),y!=fe;)y=y.nextSibling,at=!1;return Fe}function ol(a,y,fe){var de;if(y==a.display.lineDiv){if(de=a.display.lineDiv.childNodes[fe],!de)return Rs(a.clipPos(Et(a.display.viewTo-1)),!0);y=null,fe=0}else for(de=y;;de=de.parentNode){if(!de||de==a.display.lineDiv)return null;if(de.parentNode&&de.parentNode==a.display.lineDiv)break}for(var xe=0;xe<a.display.view.length;xe++){var Fe=a.display.view[xe];if(Fe.node==de)return qu(Fe,y,fe)}}function qu(a,y,fe){var de=a.text.firstChild,xe=!1;if(!y||!Qe(de,y))return Rs(Et(At(a.line),0),!0);if(y==de&&(xe=!0,y=de.childNodes[fe],fe=0,!y)){var Fe=a.rest?xt(a.rest):a.line;return Rs(Et(At(Fe),Fe.text.length),xe)}var Je=y.nodeType==3?y:null,it=y;for(!Je&&y.childNodes.length==1&&y.firstChild.nodeType==3&&(Je=y.firstChild,fe&&(fe=Je.nodeValue.length));it.parentNode!=de;)it=it.parentNode;var at=a.measure,ht=at.maps;function It(Qn,sr,vr){for(var lr=-1;lr<(ht?ht.length:0);lr++)for(var Er=lr<0?at.map:ht[lr],Qr=0;Qr<Er.length;Qr+=3){var Hr=Er[Qr+2];if(Hr==Qn||Hr==sr){var Li=At(lr<0?a.line:a.rest[lr]),to=Er[Qr]+vr;return(vr<0||Hr!=Qn)&&(to=Er[Qr+(vr?1:0)]),Et(Li,to)}}}var Ut=It(Je,it,fe);if(Ut)return Rs(Ut,xe);for(var rn=it.nextSibling,Qt=Je?Je.nodeValue.length-fe:0;rn;rn=rn.nextSibling){if(Ut=It(rn,rn.firstChild,0),Ut)return Rs(Et(Ut.line,Ut.ch-Qt),xe);Qt+=rn.textContent.length}for(var Dn=it.previousSibling,Wn=fe;Dn;Dn=Dn.previousSibling){if(Ut=It(Dn,Dn.firstChild,-1),Ut)return Rs(Et(Ut.line,Ut.ch+Wn),xe);Wn+=Dn.textContent.length}}var _o=function(a){this.cm=a,this.prevInput="",this.pollingFast=!1,this.polling=new ze,this.hasSelection=!1,this.composing=null};_o.prototype.init=function(a){var y=this,fe=this,de=this.cm;this.createField(a);var xe=this.textarea;a.wrapper.insertBefore(this.wrapper,a.wrapper.firstChild),re&&(xe.style.width="0px"),vt(xe,"input",function(){se&&te>=9&&y.hasSelection&&(y.hasSelection=null),fe.poll()}),vt(xe,"paste",function(Je){yt(de,Je)||au(Je,de)||(de.state.pasteIncoming=+new Date,fe.fastPoll())});function Fe(Je){if(!yt(de,Je)){if(de.somethingSelected())il({lineWise:!1,text:de.getSelections()});else if(de.options.lineWiseCopyCut){var it=lu(de);il({lineWise:!0,text:it.text}),Je.type=="cut"?de.setSelections(it.ranges,null,et):(fe.prevInput="",xe.value=it.text.join(`
|
|
|
`),rt(xe))}else return;Je.type=="cut"&&(de.state.cutIncoming=+new Date)}}vt(xe,"cut",Fe),vt(xe,"copy",Fe),vt(a.scroller,"paste",function(Je){if(!(qi(a,Je)||yt(de,Je))){if(!xe.dispatchEvent){de.state.pasteIncoming=+new Date,fe.focus();return}var it=new Event("paste");it.clipboardData=Je.clipboardData,xe.dispatchEvent(it)}}),vt(a.lineSpace,"selectstart",function(Je){qi(a,Je)||sn(Je)}),vt(xe,"compositionstart",function(){var Je=de.getCursor("from");fe.composing&&fe.composing.range.clear(),fe.composing={start:Je,range:de.markText(Je,de.getCursor("to"),{className:"CodeMirror-composing"})}}),vt(xe,"compositionend",function(){fe.composing&&(fe.poll(),fe.composing.range.clear(),fe.composing=null)})},_o.prototype.createField=function(a){this.wrapper=cu(),this.textarea=this.wrapper.firstChild},_o.prototype.screenReaderLabelChanged=function(a){a?this.textarea.setAttribute("aria-label",a):this.textarea.removeAttribute("aria-label")},_o.prototype.prepareSelection=function(){var a=this.cm,y=a.display,fe=a.doc,de=bs(a);if(a.options.moveInputWithCursor){var xe=Ji(a,fe.sel.primary().head,"div"),Fe=y.wrapper.getBoundingClientRect(),Je=y.lineDiv.getBoundingClientRect();de.teTop=Math.max(0,Math.min(y.wrapper.clientHeight-10,xe.top+Je.top-Fe.top)),de.teLeft=Math.max(0,Math.min(y.wrapper.clientWidth-10,xe.left+Je.left-Fe.left))}return de},_o.prototype.showSelection=function(a){var y=this.cm,fe=y.display;Ee(fe.cursorDiv,a.cursors),Ee(fe.selectionDiv,a.selection),a.teTop!=null&&(this.wrapper.style.top=a.teTop+"px",this.wrapper.style.left=a.teLeft+"px")},_o.prototype.reset=function(a){if(!(this.contextMenuPending||this.composing)){var y=this.cm;if(y.somethingSelected()){this.prevInput="";var fe=y.getSelection();this.textarea.value=fe,y.state.focused&&rt(this.textarea),se&&te>=9&&(this.hasSelection=fe)}else a||(this.prevInput=this.textarea.value="",se&&te>=9&&(this.hasSelection=null))}},_o.prototype.getField=function(){return this.textarea},_o.prototype.supportsTouch=function(){return!1},_o.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!oe||Xe()!=this.textarea))try{this.textarea.focus()}catch(a){}},_o.prototype.blur=function(){this.textarea.blur()},_o.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},_o.prototype.receivedFocus=function(){this.slowPoll()},_o.prototype.slowPoll=function(){var a=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){a.poll(),a.cm.state.focused&&a.slowPoll()})},_o.prototype.fastPoll=function(){var a=!1,y=this;y.pollingFast=!0;function fe(){var de=y.poll();!de&&!a?(a=!0,y.polling.set(60,fe)):(y.pollingFast=!1,y.slowPoll())}y.polling.set(20,fe)},_o.prototype.poll=function(){var a=this,y=this.cm,fe=this.textarea,de=this.prevInput;if(this.contextMenuPending||!y.state.focused||Kn(fe)&&!de&&!this.composing||y.isReadOnly()||y.options.disableInput||y.state.keySeq)return!1;var xe=fe.value;if(xe==de&&!y.somethingSelected())return!1;if(se&&te>=9&&this.hasSelection===xe||ve&&/[\uf700-\uf7ff]/.test(xe))return y.display.input.reset(),!1;if(y.doc.sel==y.display.selForContextMenu){var Fe=xe.charCodeAt(0);if(Fe==8203&&!de&&(de="\u200B"),Fe==8666)return this.reset(),this.cm.execCommand("undo")}for(var Je=0,it=Math.min(de.length,xe.length);Je<it&&de.charCodeAt(Je)==xe.charCodeAt(Je);)++Je;return wt(y,function(){Sl(y,xe.slice(Je),de.length-Je,null,a.composing?"*compose":null),xe.length>1e3||xe.indexOf(`
|
|
|
`)>-1?fe.value=a.prevInput="":a.prevInput=xe,a.composing&&(a.composing.range.clear(),a.composing.range=y.markText(a.composing.start,y.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},_o.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},_o.prototype.onKeyPress=function(){se&&te>=9&&(this.hasSelection=null),this.fastPoll()},_o.prototype.onContextMenu=function(a){var y=this,fe=y.cm,de=fe.display,xe=y.textarea;y.contextMenuPending&&y.contextMenuPending();var Fe=da(fe,a),Je=de.scroller.scrollTop;if(!Fe||E)return;var it=fe.options.resetSelectionOnContextMenu;it&&fe.doc.sel.contains(Fe)==-1&&Vn(fe,Uo)(fe.doc,mi(Fe),et);var at=xe.style.cssText,ht=y.wrapper.style.cssText,It=y.wrapper.offsetParent.getBoundingClientRect();y.wrapper.style.cssText="position: static",xe.style.cssText=`position: absolute; width: 30px; height: 30px;
|
|
|
top: `+(a.clientY-It.top-5)+"px; left: "+(a.clientX-It.left-5)+`px;
|
|
|
z-index: 1000; background: `+(se?"rgba(255, 255, 255, .05)":"transparent")+`;
|
|
|
outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var Ut;le&&(Ut=window.scrollY),de.input.focus(),le&&window.scrollTo(null,Ut),de.input.reset(),fe.somethingSelected()||(xe.value=y.prevInput=" "),y.contextMenuPending=Qt,de.selForContextMenu=fe.doc.sel,clearTimeout(de.detectingSelectAll);function rn(){if(xe.selectionStart!=null){var Wn=fe.somethingSelected(),Qn="\u200B"+(Wn?xe.value:"");xe.value="\u21DA",xe.value=Qn,y.prevInput=Wn?"":"\u200B",xe.selectionStart=1,xe.selectionEnd=Qn.length,de.selForContextMenu=fe.doc.sel}}function Qt(){if(y.contextMenuPending==Qt&&(y.contextMenuPending=!1,y.wrapper.style.cssText=ht,xe.style.cssText=at,se&&te<9&&de.scrollbars.setScrollTop(de.scroller.scrollTop=Je),xe.selectionStart!=null)){(!se||se&&te<9)&&rn();var Wn=0,Qn=function(){de.selForContextMenu==fe.doc.sel&&xe.selectionStart==0&&xe.selectionEnd>0&&y.prevInput=="\u200B"?Vn(fe,Dl)(fe):Wn++<10?de.detectingSelectAll=setTimeout(Qn,500):(de.selForContextMenu=null,de.input.reset())};de.detectingSelectAll=setTimeout(Qn,200)}}if(se&&te>=9&&rn(),he){Rn(a);var Dn=function(){Ht(window,"mouseup",Dn),setTimeout(Qt,20)};vt(window,"mouseup",Dn)}else setTimeout(Qt,50)},_o.prototype.readOnlyChanged=function(a){a||this.reset(),this.textarea.disabled=a=="nocursor",this.textarea.readOnly=!!a},_o.prototype.setUneditable=function(){},_o.prototype.needsContentAttribute=!1;function Ju(a,y){if(y=y?ut(y):{},y.value=a.value,!y.tabindex&&a.tabIndex&&(y.tabindex=a.tabIndex),!y.placeholder&&a.placeholder&&(y.placeholder=a.placeholder),y.autofocus==null){var fe=Xe();y.autofocus=fe==a||a.getAttribute("autofocus")!=null&&fe==document.body}function de(){a.value=it.getValue()}var xe;if(a.form&&(vt(a.form,"submit",de),!y.leaveSubmitMethodAlone)){var Fe=a.form;xe=Fe.submit;try{var Je=Fe.submit=function(){de(),Fe.submit=xe,Fe.submit(),Fe.submit=Je}}catch(at){}}y.finishInit=function(at){at.save=de,at.getTextArea=function(){return a},at.toTextArea=function(){at.toTextArea=isNaN,de(),a.parentNode.removeChild(at.getWrapperElement()),a.style.display="",a.form&&(Ht(a.form,"submit",de),!y.leaveSubmitMethodAlone&&typeof a.form.submit=="function"&&(a.form.submit=xe))}},a.style.display="none";var it=uo(function(at){return a.parentNode.insertBefore(at,a.nextSibling)},y);return it}function Qu(a){a.off=Ht,a.on=vt,a.wheelEventPixels=mr,a.Doc=Qo,a.splitLines=ir,a.countColumn=Ge,a.findColumn=Ot,a.isWordChar=Be,a.Pass=nt,a.signal=jt,a.Line=Cr,a.changeEnd=Mr,a.scrollbarModel=Na,a.Pos=Et,a.cmpPos=zt,a.modes=dr,a.mimeModes=Mn,a.resolveMode=Jt,a.getMode=Ie,a.modeExtensions=Ze,a.extendMode=qe,a.copyState=st,a.startState=Bt,a.innerMode=mt,a.commands=Zs,a.keyMap=Ya,a.keyName=Kl,a.isModifierKey=Zl,a.lookupKey=Ts,a.normalizeKeyMap=Lu,a.StringStream=kt,a.SharedTextMarker=zs,a.TextMarker=ss,a.LineWidget=Us,a.e_preventDefault=sn,a.e_stopPropagation=wn,a.e_stop=Rn,a.addClass=ot,a.contains=Qe,a.rmClass=ke,a.keyNames=ls}Wu(uo),Vu(uo);var $u="iter insert remove copy getEditor constructor".split(" ");for(var al in Qo.prototype)Qo.prototype.hasOwnProperty(al)&&Ve($u,al)<0&&(uo.prototype[al]=function(a){return function(){return a.apply(this.doc,arguments)}}(Qo.prototype[al]));return Kt(Qo),uo.inputStyles={textarea:_o,contenteditable:Yi},uo.defineMode=function(a){!uo.defaults.mode&&a!="null"&&(uo.defaults.mode=a),Cn.apply(this,arguments)},uo.defineMIME=$n,uo.defineMode("null",function(){return{token:function(a){return a.skipToEnd()}}}),uo.defineMIME("text/plain","null"),uo.defineExtension=function(a,y){uo.prototype[a]=y},uo.defineDocExtension=function(a,y){Qo.prototype[a]=y},uo.fromTextArea=Ju,Qu(uo),uo.version="5.58.2",uo})},25419:function(Xt,Mt,be){(function(ce){ce(be(89780),be(15525),be(98101))})(function(ce){"use strict";ce.defineMode("markdown",function(ie,Ce){var ue=ce.getMode(ie,"text/html"),se=ue.name=="null";function te(Ge){if(ce.findModeByName){var ze=ce.findModeByName(Ge);ze&&(Ge=ze.mime||ze.mimes[0])}var Ve=ce.getMode(ie,Ge);return Ve.name=="null"?null:Ve}Ce.highlightFormatting===void 0&&(Ce.highlightFormatting=!1),Ce.maxBlockquoteDepth===void 0&&(Ce.maxBlockquoteDepth=0),Ce.taskLists===void 0&&(Ce.taskLists=!1),Ce.strikethrough===void 0&&(Ce.strikethrough=!1),Ce.emoji===void 0&&(Ce.emoji=!1),Ce.fencedCodeBlockHighlighting===void 0&&(Ce.fencedCodeBlockHighlighting=!0),Ce.fencedCodeBlockDefaultMode===void 0&&(Ce.fencedCodeBlockDefaultMode="text/plain"),Ce.xml===void 0&&(Ce.xml=!0),Ce.tokenTypeOverrides===void 0&&(Ce.tokenTypeOverrides={});var le={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 ee in le)le.hasOwnProperty(ee)&&Ce.tokenTypeOverrides[ee]&&(le[ee]=Ce.tokenTypeOverrides[ee]);var ne=/^([*\-_])(?:\s*\1){2,}\s*$/,E=/^(?:[*\-+]|^[0-9]+([.)]))\s+/,b=/^\[(x| )\](?=\s)/i,z=Ce.allowAtxHeaderWithoutSpace?/^(#+)/:/^(#+)(?: |$)/,x=/^ {0,3}(?:\={1,}|-{2,})\s*$/,re=/^[^#!\[\]*_\\<>` "'(~:]+/,ae=/^(~~~+|```+)[ \t]*([\w\/+#-]*)[^\n`]*$/,oe=/^\s*\[[^\]]+?\]:.*$/,ve=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\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]/,ye=" ";function me(Ge,ze,Ve){return ze.f=ze.inline=Ve,Ve(Ge,ze)}function ge(Ge,ze,Ve){return ze.f=ze.block=Ve,Ve(Ge,ze)}function _e(Ge){return!Ge||!/\S/.test(Ge.string)}function he(Ge){if(Ge.linkTitle=!1,Ge.linkHref=!1,Ge.linkText=!1,Ge.em=!1,Ge.strong=!1,Ge.strikethrough=!1,Ge.quote=0,Ge.indentedCode=!1,Ge.f==ke){var ze=se;if(!ze){var Ve=ce.innerMode(ue,Ge.htmlState);ze=Ve.mode.name=="xml"&&Ve.state.tagStart===null&&!Ve.state.context&&Ve.state.tokenize.isInText}ze&&(Ge.f=je,Ge.block=pe,Ge.htmlState=null)}return Ge.trailingSpace=0,Ge.trailingSpaceNewLine=!1,Ge.prevLine=Ge.thisLine,Ge.thisLine={stream:null},null}function pe(Ge,ze){var Ve=Ge.column()===ze.indentation,$e=_e(ze.prevLine.stream),nt=ze.indentedCode,et=ze.prevLine.hr,pt=ze.list!==!1,ct=(ze.listStack[ze.listStack.length-1]||0)+3;ze.indentedCode=!1;var Ot=ze.indentation;if(ze.indentationDiff===null&&(ze.indentationDiff=ze.indentation,pt)){for(ze.list=null;Ot<ze.listStack[ze.listStack.length-1];)ze.listStack.pop(),ze.listStack.length?ze.indentation=ze.listStack[ze.listStack.length-1]:ze.list=!1;ze.list!==!1&&(ze.indentationDiff=Ot-ze.listStack[ze.listStack.length-1])}var dt=!$e&&!et&&!ze.prevLine.header&&(!pt||!nt)&&!ze.prevLine.fencedCodeEnd,Rt=(ze.list===!1||et||$e)&&ze.indentation<=ct&&Ge.match(ne),xt=null;if(ze.indentationDiff>=4&&(nt||ze.prevLine.fencedCodeEnd||ze.prevLine.header||$e))return Ge.skipToEnd(),ze.indentedCode=!0,le.code;if(Ge.eatSpace())return null;if(Ve&&ze.indentation<=ct&&(xt=Ge.match(z))&&xt[1].length<=6)return ze.quote=0,ze.header=xt[1].length,ze.thisLine.header=!0,Ce.highlightFormatting&&(ze.formatting="header"),ze.f=ze.inline,Ee(ze);if(ze.indentation<=ct&&Ge.eat(">"))return ze.quote=Ve?1:ze.quote+1,Ce.highlightFormatting&&(ze.formatting="quote"),Ge.eatSpace(),Ee(ze);if(!Rt&&!ze.setext&&Ve&&ze.indentation<=ct&&(xt=Ge.match(E))){var gt=xt[1]?"ol":"ul";return ze.indentation=Ot+Ge.current().length,ze.list=!0,ze.quote=0,ze.listStack.push(ze.indentation),ze.em=!1,ze.strong=!1,ze.code=!1,ze.strikethrough=!1,Ce.taskLists&&Ge.match(b,!1)&&(ze.taskList=!0),ze.f=ze.inline,Ce.highlightFormatting&&(ze.formatting=["list","list-"+gt]),Ee(ze)}else{if(Ve&&ze.indentation<=ct&&(xt=Ge.match(ae,!0)))return ze.quote=0,ze.fencedEndRE=new RegExp(xt[1]+"+ *$"),ze.localMode=Ce.fencedCodeBlockHighlighting&&te(xt[2]||Ce.fencedCodeBlockDefaultMode),ze.localMode&&(ze.localState=ce.startState(ze.localMode)),ze.f=ze.block=Te,Ce.highlightFormatting&&(ze.formatting="code-block"),ze.code=-1,Ee(ze);if(ze.setext||(!dt||!pt)&&!ze.quote&&ze.list===!1&&!ze.code&&!Rt&&!oe.test(Ge.string)&&(xt=Ge.lookAhead(1))&&(xt=xt.match(x)))return ze.setext?(ze.header=ze.setext,ze.setext=0,Ge.skipToEnd(),Ce.highlightFormatting&&(ze.formatting="header")):(ze.header=xt[0].charAt(0)=="="?1:2,ze.setext=ze.header),ze.thisLine.header=!0,ze.f=ze.inline,Ee(ze);if(Rt)return Ge.skipToEnd(),ze.hr=!0,ze.thisLine.hr=!0,le.hr;if(Ge.peek()==="[")return me(Ge,ze,He)}return me(Ge,ze,ze.inline)}function ke(Ge,ze){var Ve=ue.token(Ge,ze.htmlState);if(!se){var $e=ce.innerMode(ue,ze.htmlState);($e.mode.name=="xml"&&$e.state.tagStart===null&&!$e.state.context&&$e.state.tokenize.isInText||ze.md_inside&&Ge.current().indexOf(">")>-1)&&(ze.f=je,ze.block=pe,ze.htmlState=null)}return Ve}function Te(Ge,ze){var Ve=ze.listStack[ze.listStack.length-1]||0,$e=ze.indentation<Ve,nt=Ve+3;if(ze.fencedEndRE&&ze.indentation<=nt&&($e||Ge.match(ze.fencedEndRE))){Ce.highlightFormatting&&(ze.formatting="code-block");var et;return $e||(et=Ee(ze)),ze.localMode=ze.localState=null,ze.block=pe,ze.f=je,ze.fencedEndRE=null,ze.code=0,ze.thisLine.fencedCodeEnd=!0,$e?ge(Ge,ze,ze.block):et}else return ze.localMode?ze.localMode.token(Ge,ze.localState):(Ge.skipToEnd(),le.code)}function Ee(Ge){var ze=[];if(Ge.formatting){ze.push(le.formatting),typeof Ge.formatting=="string"&&(Ge.formatting=[Ge.formatting]);for(var Ve=0;Ve<Ge.formatting.length;Ve++)ze.push(le.formatting+"-"+Ge.formatting[Ve]),Ge.formatting[Ve]==="header"&&ze.push(le.formatting+"-"+Ge.formatting[Ve]+"-"+Ge.header),Ge.formatting[Ve]==="quote"&&(!Ce.maxBlockquoteDepth||Ce.maxBlockquoteDepth>=Ge.quote?ze.push(le.formatting+"-"+Ge.formatting[Ve]+"-"+Ge.quote):ze.push("error"))}if(Ge.taskOpen)return ze.push("meta"),ze.length?ze.join(" "):null;if(Ge.taskClosed)return ze.push("property"),ze.length?ze.join(" "):null;if(Ge.linkHref?ze.push(le.linkHref,"url"):(Ge.strong&&ze.push(le.strong),Ge.em&&ze.push(le.em),Ge.strikethrough&&ze.push(le.strikethrough),Ge.emoji&&ze.push(le.emoji),Ge.linkText&&ze.push(le.linkText),Ge.code&&ze.push(le.code),Ge.image&&ze.push(le.image),Ge.imageAltText&&ze.push(le.imageAltText,"link"),Ge.imageMarker&&ze.push(le.imageMarker)),Ge.header&&ze.push(le.header,le.header+"-"+Ge.header),Ge.quote&&(ze.push(le.quote),!Ce.maxBlockquoteDepth||Ce.maxBlockquoteDepth>=Ge.quote?ze.push(le.quote+"-"+Ge.quote):ze.push(le.quote+"-"+Ce.maxBlockquoteDepth)),Ge.list!==!1){var $e=(Ge.listStack.length-1)%3;$e?$e===1?ze.push(le.list2):ze.push(le.list3):ze.push(le.list1)}return Ge.trailingSpaceNewLine?ze.push("trailing-space-new-line"):Ge.trailingSpace&&ze.push("trailing-space-"+(Ge.trailingSpace%2?"a":"b")),ze.length?ze.join(" "):null}function Oe(Ge,ze){if(Ge.match(re,!0))return Ee(ze)}function je(Ge,ze){var Ve=ze.text(Ge,ze);if(typeof Ve!="undefined")return Ve;if(ze.list)return ze.list=null,Ee(ze);if(ze.taskList){var $e=Ge.match(b,!0)[1]===" ";return $e?ze.taskOpen=!0:ze.taskClosed=!0,Ce.highlightFormatting&&(ze.formatting="task"),ze.taskList=!1,Ee(ze)}if(ze.taskOpen=!1,ze.taskClosed=!1,ze.header&&Ge.match(/^#+$/,!0))return Ce.highlightFormatting&&(ze.formatting="header"),Ee(ze);var nt=Ge.next();if(ze.linkTitle){ze.linkTitle=!1;var et=nt;nt==="("&&(et=")"),et=(et+"").replace(/([.?*+^\[\]\\(){}|-])/g,"\\$1");var pt="^\\s*(?:[^"+et+"\\\\]+|\\\\\\\\|\\\\.)"+et;if(Ge.match(new RegExp(pt),!0))return le.linkHref}if(nt==="`"){var ct=ze.formatting;Ce.highlightFormatting&&(ze.formatting="code"),Ge.eatWhile("`");var Ot=Ge.current().length;if(ze.code==0&&(!ze.quote||Ot==1))return ze.code=Ot,Ee(ze);if(Ot==ze.code){var dt=Ee(ze);return ze.code=0,dt}else return ze.formatting=ct,Ee(ze)}else if(ze.code)return Ee(ze);if(nt==="\\"&&(Ge.next(),Ce.highlightFormatting)){var Rt=Ee(ze),xt=le.formatting+"-escape";return Rt?Rt+" "+xt:xt}if(nt==="!"&&Ge.match(/\[[^\]]*\] ?(?:\(|\[)/,!1))return ze.imageMarker=!0,ze.image=!0,Ce.highlightFormatting&&(ze.formatting="image"),Ee(ze);if(nt==="["&&ze.imageMarker&&Ge.match(/[^\]]*\](\(.*?\)| ?\[.*?\])/,!1))return ze.imageMarker=!1,ze.imageAltText=!0,Ce.highlightFormatting&&(ze.formatting="image"),Ee(ze);if(nt==="]"&&ze.imageAltText){Ce.highlightFormatting&&(ze.formatting="image");var Rt=Ee(ze);return ze.imageAltText=!1,ze.image=!1,ze.inline=ze.f=Qe,Rt}if(nt==="["&&!ze.image)return ze.linkText&&Ge.match(/^.*?\]/)||(ze.linkText=!0,Ce.highlightFormatting&&(ze.formatting="link")),Ee(ze);if(nt==="]"&&ze.linkText){Ce.highlightFormatting&&(ze.formatting="link");var Rt=Ee(ze);return ze.linkText=!1,ze.inline=ze.f=Ge.match(/\(.*?\)| ?\[.*?\]/,!1)?Qe:je,Rt}if(nt==="<"&&Ge.match(/^(https?|ftps?):\/\/(?:[^\\>]|\\.)+>/,!1)){ze.f=ze.inline=Pe,Ce.highlightFormatting&&(ze.formatting="link");var Rt=Ee(ze);return Rt?Rt+=" ":Rt="",Rt+le.linkInline}if(nt==="<"&&Ge.match(/^[^> \\]+@(?:[^\\>]|\\.)+>/,!1)){ze.f=ze.inline=Pe,Ce.highlightFormatting&&(ze.formatting="link");var Rt=Ee(ze);return Rt?Rt+=" ":Rt="",Rt+le.linkEmail}if(Ce.xml&&nt==="<"&&Ge.match(/^(!--|\?|!\[CDATA\[|[a-z][a-z0-9-]*(?:\s+[a-z_:.\-]+(?:\s*=\s*[^>]+)?)*\s*(?:>|$))/i,!1)){var gt=Ge.string.indexOf(">",Ge.pos);if(gt!=-1){var _t=Ge.string.substring(Ge.start,gt);/markdown\s*=\s*('|"){0,1}1('|"){0,1}/.test(_t)&&(ze.md_inside=!0)}return Ge.backUp(1),ze.htmlState=ce.startState(ue),ge(Ge,ze,ke)}if(Ce.xml&&nt==="<"&&Ge.match(/^\/\w*?>/))return ze.md_inside=!1,"tag";if(nt==="*"||nt==="_"){for(var We=1,Ae=Ge.pos==1?" ":Ge.string.charAt(Ge.pos-2);We<3&&Ge.eat(nt);)We++;var Se=Ge.peek()||" ",Be=!/\s/.test(Se)&&(!ve.test(Se)||/\s/.test(Ae)||ve.test(Ae)),Ke=!/\s/.test(Ae)&&(!ve.test(Ae)||/\s/.test(Se)||ve.test(Se)),Ne=null,De=null;if(We%2&&(!ze.em&&Be&&(nt==="*"||!Ke||ve.test(Ae))?Ne=!0:ze.em==nt&&Ke&&(nt==="*"||!Be||ve.test(Se))&&(Ne=!1)),We>1&&(!ze.strong&&Be&&(nt==="*"||!Ke||ve.test(Ae))?De=!0:ze.strong==nt&&Ke&&(nt==="*"||!Be||ve.test(Se))&&(De=!1)),De!=null||Ne!=null){Ce.highlightFormatting&&(ze.formatting=Ne==null?"strong":De==null?"em":"strong em"),Ne===!0&&(ze.em=nt),De===!0&&(ze.strong=nt);var dt=Ee(ze);return Ne===!1&&(ze.em=!1),De===!1&&(ze.strong=!1),dt}}else if(nt===" "&&(Ge.eat("*")||Ge.eat("_"))){if(Ge.peek()===" ")return Ee(ze);Ge.backUp(1)}if(Ce.strikethrough){if(nt==="~"&&Ge.eatWhile(nt)){if(ze.strikethrough){Ce.highlightFormatting&&(ze.formatting="strikethrough");var dt=Ee(ze);return ze.strikethrough=!1,dt}else if(Ge.match(/^[^\s]/,!1))return ze.strikethrough=!0,Ce.highlightFormatting&&(ze.formatting="strikethrough"),Ee(ze)}else if(nt===" "&&Ge.match(/^~~/,!0)){if(Ge.peek()===" ")return Ee(ze);Ge.backUp(2)}}if(Ce.emoji&&nt===":"&&Ge.match(/^(?:[a-z_\d+][a-z_\d+-]*|\-[a-z_\d+][a-z_\d+-]*):/)){ze.emoji=!0,Ce.highlightFormatting&&(ze.formatting="emoji");var we=Ee(ze);return ze.emoji=!1,we}return nt===" "&&(Ge.match(/^ +$/,!1)?ze.trailingSpace++:ze.trailingSpace&&(ze.trailingSpaceNewLine=!0)),Ee(ze)}function Pe(Ge,ze){var Ve=Ge.next();if(Ve===">"){ze.f=ze.inline=je,Ce.highlightFormatting&&(ze.formatting="link");var $e=Ee(ze);return $e?$e+=" ":$e="",$e+le.linkInline}return Ge.match(/^[^>]+/,!0),le.linkInline}function Qe(Ge,ze){if(Ge.eatSpace())return null;var Ve=Ge.next();return Ve==="("||Ve==="["?(ze.f=ze.inline=ot(Ve==="("?")":"]"),Ce.highlightFormatting&&(ze.formatting="link-string"),ze.linkHref=!0,Ee(ze)):"error"}var Xe={")":/^(?:[^\\\(\)]|\\.|\((?:[^\\\(\)]|\\.)*\))*?(?=\))/,"]":/^(?:[^\\\[\]]|\\.|\[(?:[^\\\[\]]|\\.)*\])*?(?=\])/};function ot(Ge){return function(ze,Ve){var $e=ze.next();if($e===Ge){Ve.f=Ve.inline=je,Ce.highlightFormatting&&(Ve.formatting="link-string");var nt=Ee(Ve);return Ve.linkHref=!1,nt}return ze.match(Xe[Ge]),Ve.linkHref=!0,Ee(Ve)}}function He(Ge,ze){return Ge.match(/^([^\]\\]|\\.)*\]:/,!1)?(ze.f=rt,Ge.next(),Ce.highlightFormatting&&(ze.formatting="link"),ze.linkText=!0,Ee(ze)):me(Ge,ze,je)}function rt(Ge,ze){if(Ge.match(/^\]:/,!0)){ze.f=ze.inline=Ye,Ce.highlightFormatting&&(ze.formatting="link");var Ve=Ee(ze);return ze.linkText=!1,Ve}return Ge.match(/^([^\]\\]|\\.)+/,!0),le.linkText}function Ye(Ge,ze){return Ge.eatSpace()?null:(Ge.match(/^[^\s]+/,!0),Ge.peek()===void 0?ze.linkTitle=!0:Ge.match(/^(?:\s+(?:"(?:[^"\\]|\\\\|\\.)+"|'(?:[^'\\]|\\\\|\\.)+'|\((?:[^)\\]|\\\\|\\.)+\)))?/,!0),ze.f=ze.inline=je,le.linkHref+" url")}var ut={startState:function(){return{f:pe,prevLine:{stream:null},thisLine:{stream:null},block:pe,htmlState:null,indentation:0,inline:je,text:Oe,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(Ge){return{f:Ge.f,prevLine:Ge.prevLine,thisLine:Ge.thisLine,block:Ge.block,htmlState:Ge.htmlState&&ce.copyState(ue,Ge.htmlState),indentation:Ge.indentation,localMode:Ge.localMode,localState:Ge.localMode?ce.copyState(Ge.localMode,Ge.localState):null,inline:Ge.inline,text:Ge.text,formatting:!1,linkText:Ge.linkText,linkTitle:Ge.linkTitle,linkHref:Ge.linkHref,code:Ge.code,em:Ge.em,strong:Ge.strong,strikethrough:Ge.strikethrough,emoji:Ge.emoji,header:Ge.header,setext:Ge.setext,hr:Ge.hr,taskList:Ge.taskList,list:Ge.list,listStack:Ge.listStack.slice(0),quote:Ge.quote,indentedCode:Ge.indentedCode,trailingSpace:Ge.trailingSpace,trailingSpaceNewLine:Ge.trailingSpaceNewLine,md_inside:Ge.md_inside,fencedEndRE:Ge.fencedEndRE}},token:function(Ge,ze){if(ze.formatting=!1,Ge!=ze.thisLine.stream){if(ze.header=0,ze.hr=!1,Ge.match(/^\s*$/,!0))return he(ze),null;if(ze.prevLine=ze.thisLine,ze.thisLine={stream:Ge},ze.taskList=!1,ze.trailingSpace=0,ze.trailingSpaceNewLine=!1,!ze.localState&&(ze.f=ze.block,ze.f!=ke)){var Ve=Ge.match(/^\s*/,!0)[0].replace(/\t/g,ye).length;if(ze.indentation=Ve,ze.indentationDiff=null,Ve>0)return null}}return ze.f(Ge,ze)},innerMode:function(Ge){return Ge.block==ke?{state:Ge.htmlState,mode:ue}:Ge.localState?{state:Ge.localState,mode:Ge.localMode}:{state:Ge,mode:ut}},indent:function(Ge,ze,Ve){return Ge.block==ke&&ue.indent?ue.indent(Ge.htmlState,ze,Ve):Ge.localState&&Ge.localMode.indent?Ge.localMode.indent(Ge.localState,ze,Ve):ce.Pass},blankLine:he,getType:Ee,blockCommentStart:"<!--",blockCommentEnd:"-->",closeBrackets:"()[]{}''\"\"``",fold:"markdown"};return ut},"xml"),ce.defineMIME("text/markdown","markdown"),ce.defineMIME("text/x-markdown","markdown")})},98101:function(Xt,Mt,be){(function(ce){ce(be(89780))})(function(ce){"use strict";ce.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 ie=0;ie<ce.modeInfo.length;ie++){var Ce=ce.modeInfo[ie];Ce.mimes&&(Ce.mime=Ce.mimes[0])}ce.findModeByMIME=function(ue){ue=ue.toLowerCase();for(var se=0;se<ce.modeInfo.length;se++){var te=ce.modeInfo[se];if(te.mime==ue)return te;if(te.mimes){for(var le=0;le<te.mimes.length;le++)if(te.mimes[le]==ue)return te}}if(/\+xml$/.test(ue))return ce.findModeByMIME("application/xml");if(/\+json$/.test(ue))return ce.findModeByMIME("application/json")},ce.findModeByExtension=function(ue){ue=ue.toLowerCase();for(var se=0;se<ce.modeInfo.length;se++){var te=ce.modeInfo[se];if(te.ext){for(var le=0;le<te.ext.length;le++)if(te.ext[le]==ue)return te}}},ce.findModeByFileName=function(ue){for(var se=0;se<ce.modeInfo.length;se++){var te=ce.modeInfo[se];if(te.file&&te.file.test(ue))return te}var le=ue.lastIndexOf("."),ee=le>-1&&ue.substring(le+1,ue.length);if(ee)return ce.findModeByExtension(ee)},ce.findModeByName=function(ue){ue=ue.toLowerCase();for(var se=0;se<ce.modeInfo.length;se++){var te=ce.modeInfo[se];if(te.name.toLowerCase()==ue)return te;if(te.alias){for(var le=0;le<te.alias.length;le++)if(te.alias[le].toLowerCase()==ue)return te}}}})},67549:function(Xt,Mt,be){(function(ce){ce(be(89780))})(function(ce){"use strict";ce.defineMode("stex",function(ie,Ce){"use strict";function ue(re,ae){re.cmdState.push(ae)}function se(re){return re.cmdState.length>0?re.cmdState[re.cmdState.length-1]:null}function te(re){var ae=re.cmdState.pop();ae&&ae.closeBracket()}function le(re){for(var ae=re.cmdState,oe=ae.length-1;oe>=0;oe--){var ve=ae[oe];if(ve.name!="DEFAULT")return ve}return{styleIdentifier:function(){return null}}}function ee(re,ae,oe){return function(){this.name=re,this.bracketNo=0,this.style=ae,this.styles=oe,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var ne={};ne.importmodule=ee("importmodule","tag",["string","builtin"]),ne.documentclass=ee("documentclass","tag",["","atom"]),ne.usepackage=ee("usepackage","tag",["atom"]),ne.begin=ee("begin","tag",["atom"]),ne.end=ee("end","tag",["atom"]),ne.label=ee("label","tag",["atom"]),ne.ref=ee("ref","tag",["atom"]),ne.eqref=ee("eqref","tag",["atom"]),ne.cite=ee("cite","tag",["atom"]),ne.bibitem=ee("bibitem","tag",["atom"]),ne.Bibitem=ee("Bibitem","tag",["atom"]),ne.RBibitem=ee("RBibitem","tag",["atom"]),ne.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}};function E(re,ae){re.f=ae}function b(re,ae){var oe;if(re.match(/^\\[a-zA-Z@]+/)){var ve=re.current().slice(1);return oe=ne.hasOwnProperty(ve)?ne[ve]:ne.DEFAULT,oe=new oe,ue(ae,oe),E(ae,x),oe.style}if(re.match(/^\\[$&%#{}_]/)||re.match(/^\\[,;!\/\\]/))return"tag";if(re.match("\\["))return E(ae,function(me,ge){return z(me,ge,"\\]")}),"keyword";if(re.match("\\("))return E(ae,function(me,ge){return z(me,ge,"\\)")}),"keyword";if(re.match("$$"))return E(ae,function(me,ge){return z(me,ge,"$$")}),"keyword";if(re.match("$"))return E(ae,function(me,ge){return z(me,ge,"$")}),"keyword";var ye=re.next();if(ye=="%")return re.skipToEnd(),"comment";if(ye=="}"||ye=="]"){if(oe=se(ae),oe)oe.closeBracket(ye),E(ae,x);else return"error";return"bracket"}else return ye=="{"||ye=="["?(oe=ne.DEFAULT,oe=new oe,ue(ae,oe),"bracket"):/\d/.test(ye)?(re.eatWhile(/[\w.%]/),"atom"):(re.eatWhile(/[\w\-_]/),oe=le(ae),oe.name=="begin"&&(oe.argument=re.current()),oe.styleIdentifier())}function z(re,ae,oe){if(re.eatSpace())return null;if(oe&&re.match(oe))return E(ae,b),"keyword";if(re.match(/^\\[a-zA-Z@]+/))return"tag";if(re.match(/^[a-zA-Z]+/))return"variable-2";if(re.match(/^\\[$&%#{}_]/)||re.match(/^\\[,;!\/]/)||re.match(/^[\^_&]/))return"tag";if(re.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(re.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var ve=re.next();return ve=="{"||ve=="}"||ve=="["||ve=="]"||ve=="("||ve==")"?"bracket":ve=="%"?(re.skipToEnd(),"comment"):"error"}function x(re,ae){var oe=re.peek(),ve;return oe=="{"||oe=="["?(ve=se(ae),ve.openBracket(oe),re.eat(oe),E(ae,b),"bracket"):/[ \t\r]/.test(oe)?(re.eat(oe),null):(E(ae,b),te(ae),b(re,ae))}return{startState:function(){var re=Ce.inMathMode?function(ae,oe){return z(ae,oe)}:b;return{cmdState:[],f:re}},copyState:function(re){return{cmdState:re.cmdState.slice(),f:re.f}},token:function(re,ae){return ae.f(re,ae)},blankLine:function(re){re.f=b,re.cmdState.length=0},lineComment:"%"}}),ce.defineMIME("text/x-stex","stex"),ce.defineMIME("text/x-latex","stex")})},15525:function(Xt,Mt,be){(function(ce){ce(be(89780))})(function(ce){"use strict";var ie={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},Ce={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};ce.defineMode("xml",function(ue,se){var te=ue.indentUnit,le={},ee=se.htmlMode?ie:Ce;for(var ne in ee)le[ne]=ee[ne];for(var ne in se)le[ne]=se[ne];var E,b;function z(Pe,Qe){function Xe(rt){return Qe.tokenize=rt,rt(Pe,Qe)}var ot=Pe.next();if(ot=="<")return Pe.eat("!")?Pe.eat("[")?Pe.match("CDATA[")?Xe(ae("atom","]]>")):null:Pe.match("--")?Xe(ae("comment","-->")):Pe.match("DOCTYPE",!0,!0)?(Pe.eatWhile(/[\w\._\-]/),Xe(oe(1))):null:Pe.eat("?")?(Pe.eatWhile(/[\w\._\-]/),Qe.tokenize=ae("meta","?>"),"meta"):(E=Pe.eat("/")?"closeTag":"openTag",Qe.tokenize=x,"tag bracket");if(ot=="&"){var He;return Pe.eat("#")?Pe.eat("x")?He=Pe.eatWhile(/[a-fA-F\d]/)&&Pe.eat(";"):He=Pe.eatWhile(/[\d]/)&&Pe.eat(";"):He=Pe.eatWhile(/[\w\.\-:]/)&&Pe.eat(";"),He?"atom":"error"}else return Pe.eatWhile(/[^&<]/),null}z.isInText=!0;function x(Pe,Qe){var Xe=Pe.next();if(Xe==">"||Xe=="/"&&Pe.eat(">"))return Qe.tokenize=z,E=Xe==">"?"endTag":"selfcloseTag","tag bracket";if(Xe=="=")return E="equals",null;if(Xe=="<"){Qe.tokenize=z,Qe.state=ge,Qe.tagName=Qe.tagStart=null;var ot=Qe.tokenize(Pe,Qe);return ot?ot+" tag error":"tag error"}else return/[\'\"]/.test(Xe)?(Qe.tokenize=re(Xe),Qe.stringStartCol=Pe.column(),Qe.tokenize(Pe,Qe)):(Pe.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function re(Pe){var Qe=function(Xe,ot){for(;!Xe.eol();)if(Xe.next()==Pe){ot.tokenize=x;break}return"string"};return Qe.isInAttribute=!0,Qe}function ae(Pe,Qe){return function(Xe,ot){for(;!Xe.eol();){if(Xe.match(Qe)){ot.tokenize=z;break}Xe.next()}return Pe}}function oe(Pe){return function(Qe,Xe){for(var ot;(ot=Qe.next())!=null;){if(ot=="<")return Xe.tokenize=oe(Pe+1),Xe.tokenize(Qe,Xe);if(ot==">")if(Pe==1){Xe.tokenize=z;break}else return Xe.tokenize=oe(Pe-1),Xe.tokenize(Qe,Xe)}return"meta"}}function ve(Pe,Qe,Xe){this.prev=Pe.context,this.tagName=Qe,this.indent=Pe.indented,this.startOfLine=Xe,(le.doNotIndent.hasOwnProperty(Qe)||Pe.context&&Pe.context.noIndent)&&(this.noIndent=!0)}function ye(Pe){Pe.context&&(Pe.context=Pe.context.prev)}function me(Pe,Qe){for(var Xe;;){if(!Pe.context||(Xe=Pe.context.tagName,!le.contextGrabbers.hasOwnProperty(Xe)||!le.contextGrabbers[Xe].hasOwnProperty(Qe)))return;ye(Pe)}}function ge(Pe,Qe,Xe){return Pe=="openTag"?(Xe.tagStart=Qe.column(),_e):Pe=="closeTag"?he:ge}function _e(Pe,Qe,Xe){return Pe=="word"?(Xe.tagName=Qe.current(),b="tag",Te):le.allowMissingTagName&&Pe=="endTag"?(b="tag bracket",Te(Pe,Qe,Xe)):(b="error",_e)}function he(Pe,Qe,Xe){if(Pe=="word"){var ot=Qe.current();return Xe.context&&Xe.context.tagName!=ot&&le.implicitlyClosed.hasOwnProperty(Xe.context.tagName)&&ye(Xe),Xe.context&&Xe.context.tagName==ot||le.matchClosing===!1?(b="tag",pe):(b="tag error",ke)}else return le.allowMissingTagName&&Pe=="endTag"?(b="tag bracket",pe(Pe,Qe,Xe)):(b="error",ke)}function pe(Pe,Qe,Xe){return Pe!="endTag"?(b="error",pe):(ye(Xe),ge)}function ke(Pe,Qe,Xe){return b="error",pe(Pe,Qe,Xe)}function Te(Pe,Qe,Xe){if(Pe=="word")return b="attribute",Ee;if(Pe=="endTag"||Pe=="selfcloseTag"){var ot=Xe.tagName,He=Xe.tagStart;return Xe.tagName=Xe.tagStart=null,Pe=="selfcloseTag"||le.autoSelfClosers.hasOwnProperty(ot)?me(Xe,ot):(me(Xe,ot),Xe.context=new ve(Xe,ot,He==Xe.indented)),ge}return b="error",Te}function Ee(Pe,Qe,Xe){return Pe=="equals"?Oe:(le.allowMissing||(b="error"),Te(Pe,Qe,Xe))}function Oe(Pe,Qe,Xe){return Pe=="string"?je:Pe=="word"&&le.allowUnquoted?(b="string",Te):(b="error",Te(Pe,Qe,Xe))}function je(Pe,Qe,Xe){return Pe=="string"?je:Te(Pe,Qe,Xe)}return{startState:function(Pe){var Qe={tokenize:z,state:ge,indented:Pe||0,tagName:null,tagStart:null,context:null};return Pe!=null&&(Qe.baseIndent=Pe),Qe},token:function(Pe,Qe){if(!Qe.tagName&&Pe.sol()&&(Qe.indented=Pe.indentation()),Pe.eatSpace())return null;E=null;var Xe=Qe.tokenize(Pe,Qe);return(Xe||E)&&Xe!="comment"&&(b=null,Qe.state=Qe.state(E||Xe,Pe,Qe),b&&(Xe=b=="error"?Xe+" error":b)),Xe},indent:function(Pe,Qe,Xe){var ot=Pe.context;if(Pe.tokenize.isInAttribute)return Pe.tagStart==Pe.indented?Pe.stringStartCol+1:Pe.indented+te;if(ot&&ot.noIndent)return ce.Pass;if(Pe.tokenize!=x&&Pe.tokenize!=z)return Xe?Xe.match(/^(\s*)/)[0].length:0;if(Pe.tagName)return le.multilineTagIndentPastTag!==!1?Pe.tagStart+Pe.tagName.length+2:Pe.tagStart+te*(le.multilineTagIndentFactor||1);if(le.alignCDATA&&/<!\[CDATA\[/.test(Qe))return 0;var He=Qe&&/^<(\/)?([\w_:\.-]*)/.exec(Qe);if(He&&He[1])for(;ot;)if(ot.tagName==He[2]){ot=ot.prev;break}else if(le.implicitlyClosed.hasOwnProperty(ot.tagName))ot=ot.prev;else break;else if(He)for(;ot;){var rt=le.contextGrabbers[ot.tagName];if(rt&&rt.hasOwnProperty(He[2]))ot=ot.prev;else break}for(;ot&&ot.prev&&!ot.startOfLine;)ot=ot.prev;return ot?ot.indent+te:Pe.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"<!--",blockCommentEnd:"-->",configuration:le.htmlMode?"html":"xml",helperType:le.htmlMode?"html":"xml",skipAttribute:function(Pe){Pe.state==Oe&&(Pe.state=Te)},xmlCurrentTag:function(Pe){return Pe.tagName?{name:Pe.tagName,close:Pe.type=="closeTag"}:null},xmlCurrentContext:function(Pe){for(var Qe=[],Xe=Pe.context;Xe;Xe=Xe.prev)Xe.tagName&&Qe.push(Xe.tagName);return Qe.reverse()}}}),ce.defineMIME("text/xml","xml"),ce.defineMIME("application/xml","xml"),ce.mimeModes.hasOwnProperty("text/html")||ce.defineMIME("text/html",{name:"xml",htmlMode:!0})})},3867:function(Xt,Mt,be){var ce=be(97671);(function(ie,Ce){Xt.exports=Ce()})(this,function(){"use strict";function ie(Le){var Ue=typeof Le;return Le!==null&&(Ue==="object"||Ue==="function")}function Ce(Le){return typeof Le=="function"}var ue=void 0;Array.isArray?ue=Array.isArray:ue=function(Le){return Object.prototype.toString.call(Le)==="[object Array]"};var se=ue,te=0,le=void 0,ee=void 0,ne=function(Ue,Me){he[te]=Ue,he[te+1]=Me,te+=2,te===2&&(ee?ee(pe):Te())};function E(Le){ee=Le}function b(Le){ne=Le}var z=typeof window!="undefined"?window:void 0,x=z||{},re=x.MutationObserver||x.WebKitMutationObserver,ae=typeof self=="undefined"&&typeof ce!="undefined"&&{}.toString.call(ce)==="[object process]",oe=typeof Uint8ClampedArray!="undefined"&&typeof importScripts!="undefined"&&typeof MessageChannel!="undefined";function ve(){return function(){return ce.nextTick(pe)}}function ye(){return typeof le!="undefined"?function(){le(pe)}:_e()}function me(){var Le=0,Ue=new re(pe),Me=document.createTextNode("");return Ue.observe(Me,{characterData:!0}),function(){Me.data=Le=++Le%2}}function ge(){var Le=new MessageChannel;return Le.port1.onmessage=pe,function(){return Le.port2.postMessage(0)}}function _e(){var Le=setTimeout;return function(){return Le(pe,1)}}var he=new Array(1e3);function pe(){for(var Le=0;Le<te;Le+=2){var Ue=he[Le],Me=he[Le+1];Ue(Me),he[Le]=void 0,he[Le+1]=void 0}te=0}function ke(){try{var Le=Function("return this")().require("vertx");return le=Le.runOnLoop||Le.runOnContext,ye()}catch(Ue){return _e()}}var Te=void 0;ae?Te=ve():re?Te=me():oe?Te=ge():z===void 0?Te=ke():Te=_e();function Ee(Le,Ue){var Me=this,Re=new this.constructor(Pe);Re[je]===void 0&>(Re);var tt=Me._state;if(tt){var lt=arguments[tt-1];ne(function(){return Ot(tt,Re,lt,Me._result)})}else pt(Me,Re,Le,Ue);return Re}function Oe(Le){var Ue=this;if(Le&&typeof Le=="object"&&Le.constructor===Ue)return Le;var Me=new Ue(Pe);return Ve(Me,Le),Me}var je=Math.random().toString(36).substring(2);function Pe(){}var Qe=void 0,Xe=1,ot=2;function He(){return new TypeError("You cannot resolve a promise with itself")}function rt(){return new TypeError("A promises callback cannot return that same promise.")}function Ye(Le,Ue,Me,Re){try{Le.call(Ue,Me,Re)}catch(tt){return tt}}function ut(Le,Ue,Me){ne(function(Re){var tt=!1,lt=Ye(Me,Ue,function(Nt){tt||(tt=!0,Ue!==Nt?Ve(Re,Nt):nt(Re,Nt))},function(Nt){tt||(tt=!0,et(Re,Nt))},"Settle: "+(Re._label||" unknown promise"));!tt&<&&(tt=!0,et(Re,lt))},Le)}function Ge(Le,Ue){Ue._state===Xe?nt(Le,Ue._result):Ue._state===ot?et(Le,Ue._result):pt(Ue,void 0,function(Me){return Ve(Le,Me)},function(Me){return et(Le,Me)})}function ze(Le,Ue,Me){Ue.constructor===Le.constructor&&Me===Ee&&Ue.constructor.resolve===Oe?Ge(Le,Ue):Me===void 0?nt(Le,Ue):Ce(Me)?ut(Le,Ue,Me):nt(Le,Ue)}function Ve(Le,Ue){if(Le===Ue)et(Le,He());else if(ie(Ue)){var Me=void 0;try{Me=Ue.then}catch(Re){et(Le,Re);return}ze(Le,Ue,Me)}else nt(Le,Ue)}function $e(Le){Le._onerror&&Le._onerror(Le._result),ct(Le)}function nt(Le,Ue){Le._state===Qe&&(Le._result=Ue,Le._state=Xe,Le._subscribers.length!==0&&ne(ct,Le))}function et(Le,Ue){Le._state===Qe&&(Le._state=ot,Le._result=Ue,ne($e,Le))}function pt(Le,Ue,Me,Re){var tt=Le._subscribers,lt=tt.length;Le._onerror=null,tt[lt]=Ue,tt[lt+Xe]=Me,tt[lt+ot]=Re,lt===0&&Le._state&&ne(ct,Le)}function ct(Le){var Ue=Le._subscribers,Me=Le._state;if(Ue.length!==0){for(var Re=void 0,tt=void 0,lt=Le._result,Nt=0;Nt<Ue.length;Nt+=3)Re=Ue[Nt],tt=Ue[Nt+Me],Re?Ot(Me,Re,tt,lt):tt(lt);Le._subscribers.length=0}}function Ot(Le,Ue,Me,Re){var tt=Ce(Me),lt=void 0,Nt=void 0,Ct=!0;if(tt){try{lt=Me(Re)}catch(vt){Ct=!1,Nt=vt}if(Ue===lt){et(Ue,rt());return}}else lt=Re;Ue._state!==Qe||(tt&&Ct?Ve(Ue,lt):Ct===!1?et(Ue,Nt):Le===Xe?nt(Ue,lt):Le===ot&&et(Ue,lt))}function dt(Le,Ue){try{Ue(function(Re){Ve(Le,Re)},function(Re){et(Le,Re)})}catch(Me){et(Le,Me)}}var Rt=0;function xt(){return Rt++}function gt(Le){Le[je]=Rt++,Le._state=void 0,Le._result=void 0,Le._subscribers=[]}function _t(){return new Error("Array Methods must be provided an Array")}var We=function(){function Le(Ue,Me){this._instanceConstructor=Ue,this.promise=new Ue(Pe),this.promise[je]||gt(this.promise),se(Me)?(this.length=Me.length,this._remaining=Me.length,this._result=new Array(this.length),this.length===0?nt(this.promise,this._result):(this.length=this.length||0,this._enumerate(Me),this._remaining===0&&nt(this.promise,this._result))):et(this.promise,_t())}return Le.prototype._enumerate=function(Me){for(var Re=0;this._state===Qe&&Re<Me.length;Re++)this._eachEntry(Me[Re],Re)},Le.prototype._eachEntry=function(Me,Re){var tt=this._instanceConstructor,lt=tt.resolve;if(lt===Oe){var Nt=void 0,Ct=void 0,vt=!1;try{Nt=Me.then}catch(Ht){vt=!0,Ct=Ht}if(Nt===Ee&&Me._state!==Qe)this._settledAt(Me._state,Re,Me._result);else if(typeof Nt!="function")this._remaining--,this._result[Re]=Me;else if(tt===De){var Pt=new tt(Pe);vt?et(Pt,Ct):ze(Pt,Me,Nt),this._willSettleAt(Pt,Re)}else this._willSettleAt(new tt(function(Ht){return Ht(Me)}),Re)}else this._willSettleAt(lt(Me),Re)},Le.prototype._settledAt=function(Me,Re,tt){var lt=this.promise;lt._state===Qe&&(this._remaining--,Me===ot?et(lt,tt):this._result[Re]=tt),this._remaining===0&&nt(lt,this._result)},Le.prototype._willSettleAt=function(Me,Re){var tt=this;pt(Me,void 0,function(lt){return tt._settledAt(Xe,Re,lt)},function(lt){return tt._settledAt(ot,Re,lt)})},Le}();function Ae(Le){return new We(this,Le).promise}function Se(Le){var Ue=this;return se(Le)?new Ue(function(Me,Re){for(var tt=Le.length,lt=0;lt<tt;lt++)Ue.resolve(Le[lt]).then(Me,Re)}):new Ue(function(Me,Re){return Re(new TypeError("You must pass an array to race."))})}function Be(Le){var Ue=this,Me=new Ue(Pe);return et(Me,Le),Me}function Ke(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function Ne(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}var De=function(){function Le(Ue){this[je]=xt(),this._result=this._state=void 0,this._subscribers=[],Pe!==Ue&&(typeof Ue!="function"&&Ke(),this instanceof Le?dt(this,Ue):Ne())}return Le.prototype.catch=function(Me){return this.then(null,Me)},Le.prototype.finally=function(Me){var Re=this,tt=Re.constructor;return Ce(Me)?Re.then(function(lt){return tt.resolve(Me()).then(function(){return lt})},function(lt){return tt.resolve(Me()).then(function(){throw lt})}):Re.then(Me,Me)},Le}();De.prototype.then=Ee,De.all=Ae,De.race=Se,De.resolve=Oe,De.reject=Be,De._setScheduler=E,De._setAsap=b,De._asap=ne;function we(){var Le=void 0;if(typeof be.g!="undefined")Le=be.g;else if(typeof self!="undefined")Le=self;else try{Le=Function("return this")()}catch(Re){throw new Error("polyfill failed because global object is unavailable in this environment")}var Ue=Le.Promise;if(Ue){var Me=null;try{Me=Object.prototype.toString.call(Ue.resolve())}catch(Re){}if(Me==="[object Promise]"&&!Ue.cast)return}Le.Promise=De}return De.polyfill=we,De.Promise=De,De})},86204:function(Xt){"use strict";var Mt=typeof Reflect=="object"?Reflect:null,be=Mt&&typeof Mt.apply=="function"?Mt.apply:function(ge,_e,he){return Function.prototype.apply.call(ge,_e,he)},ce;Mt&&typeof Mt.ownKeys=="function"?ce=Mt.ownKeys:Object.getOwnPropertySymbols?ce=function(ge){return Object.getOwnPropertyNames(ge).concat(Object.getOwnPropertySymbols(ge))}:ce=function(ge){return Object.getOwnPropertyNames(ge)};function ie(me){console&&console.warn&&console.warn(me)}var Ce=Number.isNaN||function(ge){return ge!==ge};function ue(){ue.init.call(this)}Xt.exports=ue,Xt.exports.once=oe,ue.EventEmitter=ue,ue.prototype._events=void 0,ue.prototype._eventsCount=0,ue.prototype._maxListeners=void 0;var se=10;function te(me){if(typeof me!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof me)}Object.defineProperty(ue,"defaultMaxListeners",{enumerable:!0,get:function(){return se},set:function(me){if(typeof me!="number"||me<0||Ce(me))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+me+".");se=me}}),ue.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},ue.prototype.setMaxListeners=function(ge){if(typeof ge!="number"||ge<0||Ce(ge))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+ge+".");return this._maxListeners=ge,this};function le(me){return me._maxListeners===void 0?ue.defaultMaxListeners:me._maxListeners}ue.prototype.getMaxListeners=function(){return le(this)},ue.prototype.emit=function(ge){for(var _e=[],he=1;he<arguments.length;he++)_e.push(arguments[he]);var pe=ge==="error",ke=this._events;if(ke!==void 0)pe=pe&&ke.error===void 0;else if(!pe)return!1;if(pe){var Te;if(_e.length>0&&(Te=_e[0]),Te instanceof Error)throw Te;var Ee=new Error("Unhandled error."+(Te?" ("+Te.message+")":""));throw Ee.context=Te,Ee}var Oe=ke[ge];if(Oe===void 0)return!1;if(typeof Oe=="function")be(Oe,this,_e);else for(var je=Oe.length,Pe=x(Oe,je),he=0;he<je;++he)be(Pe[he],this,_e);return!0};function ee(me,ge,_e,he){var pe,ke,Te;if(te(_e),ke=me._events,ke===void 0?(ke=me._events=Object.create(null),me._eventsCount=0):(ke.newListener!==void 0&&(me.emit("newListener",ge,_e.listener?_e.listener:_e),ke=me._events),Te=ke[ge]),Te===void 0)Te=ke[ge]=_e,++me._eventsCount;else if(typeof Te=="function"?Te=ke[ge]=he?[_e,Te]:[Te,_e]:he?Te.unshift(_e):Te.push(_e),pe=le(me),pe>0&&Te.length>pe&&!Te.warned){Te.warned=!0;var Ee=new Error("Possible EventEmitter memory leak detected. "+Te.length+" "+String(ge)+" listeners added. Use emitter.setMaxListeners() to increase limit");Ee.name="MaxListenersExceededWarning",Ee.emitter=me,Ee.type=ge,Ee.count=Te.length,ie(Ee)}return me}ue.prototype.addListener=function(ge,_e){return ee(this,ge,_e,!1)},ue.prototype.on=ue.prototype.addListener,ue.prototype.prependListener=function(ge,_e){return ee(this,ge,_e,!0)};function ne(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function E(me,ge,_e){var he={fired:!1,wrapFn:void 0,target:me,type:ge,listener:_e},pe=ne.bind(he);return pe.listener=_e,he.wrapFn=pe,pe}ue.prototype.once=function(ge,_e){return te(_e),this.on(ge,E(this,ge,_e)),this},ue.prototype.prependOnceListener=function(ge,_e){return te(_e),this.prependListener(ge,E(this,ge,_e)),this},ue.prototype.removeListener=function(ge,_e){var he,pe,ke,Te,Ee;if(te(_e),pe=this._events,pe===void 0)return this;if(he=pe[ge],he===void 0)return this;if(he===_e||he.listener===_e)--this._eventsCount===0?this._events=Object.create(null):(delete pe[ge],pe.removeListener&&this.emit("removeListener",ge,he.listener||_e));else if(typeof he!="function"){for(ke=-1,Te=he.length-1;Te>=0;Te--)if(he[Te]===_e||he[Te].listener===_e){Ee=he[Te].listener,ke=Te;break}if(ke<0)return this;ke===0?he.shift():re(he,ke),he.length===1&&(pe[ge]=he[0]),pe.removeListener!==void 0&&this.emit("removeListener",ge,Ee||_e)}return this},ue.prototype.off=ue.prototype.removeListener,ue.prototype.removeAllListeners=function(ge){var _e,he,pe;if(he=this._events,he===void 0)return this;if(he.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):he[ge]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete he[ge]),this;if(arguments.length===0){var ke=Object.keys(he),Te;for(pe=0;pe<ke.length;++pe)Te=ke[pe],Te!=="removeListener"&&this.removeAllListeners(Te);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(_e=he[ge],typeof _e=="function")this.removeListener(ge,_e);else if(_e!==void 0)for(pe=_e.length-1;pe>=0;pe--)this.removeListener(ge,_e[pe]);return this};function b(me,ge,_e){var he=me._events;if(he===void 0)return[];var pe=he[ge];return pe===void 0?[]:typeof pe=="function"?_e?[pe.listener||pe]:[pe]:_e?ae(pe):x(pe,pe.length)}ue.prototype.listeners=function(ge){return b(this,ge,!0)},ue.prototype.rawListeners=function(ge){return b(this,ge,!1)},ue.listenerCount=function(me,ge){return typeof me.listenerCount=="function"?me.listenerCount(ge):z.call(me,ge)},ue.prototype.listenerCount=z;function z(me){var ge=this._events;if(ge!==void 0){var _e=ge[me];if(typeof _e=="function")return 1;if(_e!==void 0)return _e.length}return 0}ue.prototype.eventNames=function(){return this._eventsCount>0?ce(this._events):[]};function x(me,ge){for(var _e=new Array(ge),he=0;he<ge;++he)_e[he]=me[he];return _e}function re(me,ge){for(;ge+1<me.length;ge++)me[ge]=me[ge+1];me.pop()}function ae(me){for(var ge=new Array(me.length),_e=0;_e<ge.length;++_e)ge[_e]=me[_e].listener||me[_e];return ge}function oe(me,ge){return new Promise(function(_e,he){function pe(Te){me.removeListener(ge,ke),he(Te)}function ke(){typeof me.removeListener=="function"&&me.removeListener("error",pe),_e([].slice.call(arguments))}ye(me,ge,ke,{once:!0}),ge!=="error"&&ve(me,pe,{once:!0})})}function ve(me,ge,_e){typeof me.on=="function"&&ye(me,"error",ge,_e)}function ye(me,ge,_e,he){if(typeof me.on=="function")he.once?me.once(ge,_e):me.on(ge,_e);else if(typeof me.addEventListener=="function")me.addEventListener(ge,function pe(ke){he.once&&me.removeEventListener(ge,pe),_e(ke)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof me)}},24334:function(Xt,Mt,be){var ce,ie;(function(Ce,ue){Xt.exports=ue(Ce)})(typeof self!="undefined"?self:typeof window!="undefined"?window:typeof be.g!="undefined"?be.g:this,function(Ce){"use strict";Ce=Ce||{};var ue=Ce.Base64,se="2.6.4",te="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",le=function(Xe){for(var ot={},He=0,rt=Xe.length;He<rt;He++)ot[Xe.charAt(He)]=He;return ot}(te),ee=String.fromCharCode,ne=function(Xe){if(Xe.length<2){var ot=Xe.charCodeAt(0);return ot<128?Xe:ot<2048?ee(192|ot>>>6)+ee(128|ot&63):ee(224|ot>>>12&15)+ee(128|ot>>>6&63)+ee(128|ot&63)}else{var ot=65536+(Xe.charCodeAt(0)-55296)*1024+(Xe.charCodeAt(1)-56320);return ee(240|ot>>>18&7)+ee(128|ot>>>12&63)+ee(128|ot>>>6&63)+ee(128|ot&63)}},E=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,b=function(Xe){return Xe.replace(E,ne)},z=function(Xe){var ot=[0,2,1][Xe.length%3],He=Xe.charCodeAt(0)<<16|(Xe.length>1?Xe.charCodeAt(1):0)<<8|(Xe.length>2?Xe.charCodeAt(2):0),rt=[te.charAt(He>>>18),te.charAt(He>>>12&63),ot>=2?"=":te.charAt(He>>>6&63),ot>=1?"=":te.charAt(He&63)];return rt.join("")},x=Ce.btoa&&typeof Ce.btoa=="function"?function(Xe){return Ce.btoa(Xe)}:function(Xe){if(Xe.match(/[^\x00-\xFF]/))throw new RangeError("The string contains invalid characters.");return Xe.replace(/[\s\S]{1,3}/g,z)},re=function(Xe){return x(b(String(Xe)))},ae=function(Xe){return Xe.replace(/[+\/]/g,function(ot){return ot=="+"?"-":"_"}).replace(/=/g,"")},oe=function(Xe,ot){return ot?ae(re(Xe)):re(Xe)},ve=function(Xe){return oe(Xe,!0)},ye;Ce.Uint8Array&&(ye=function(Xe,ot){for(var He="",rt=0,Ye=Xe.length;rt<Ye;rt+=3){var ut=Xe[rt],Ge=Xe[rt+1],ze=Xe[rt+2],Ve=ut<<16|Ge<<8|ze;He+=te.charAt(Ve>>>18)+te.charAt(Ve>>>12&63)+(typeof Ge!="undefined"?te.charAt(Ve>>>6&63):"=")+(typeof ze!="undefined"?te.charAt(Ve&63):"=")}return ot?ae(He):He});var me=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,ge=function(Xe){switch(Xe.length){case 4:var ot=(7&Xe.charCodeAt(0))<<18|(63&Xe.charCodeAt(1))<<12|(63&Xe.charCodeAt(2))<<6|63&Xe.charCodeAt(3),He=ot-65536;return ee((He>>>10)+55296)+ee((He&1023)+56320);case 3:return ee((15&Xe.charCodeAt(0))<<12|(63&Xe.charCodeAt(1))<<6|63&Xe.charCodeAt(2));default:return ee((31&Xe.charCodeAt(0))<<6|63&Xe.charCodeAt(1))}},_e=function(Xe){return Xe.replace(me,ge)},he=function(Xe){var ot=Xe.length,He=ot%4,rt=(ot>0?le[Xe.charAt(0)]<<18:0)|(ot>1?le[Xe.charAt(1)]<<12:0)|(ot>2?le[Xe.charAt(2)]<<6:0)|(ot>3?le[Xe.charAt(3)]:0),Ye=[ee(rt>>>16),ee(rt>>>8&255),ee(rt&255)];return Ye.length-=[0,0,2,1][He],Ye.join("")},pe=Ce.atob&&typeof Ce.atob=="function"?function(Xe){return Ce.atob(Xe)}:function(Xe){return Xe.replace(/\S{1,4}/g,he)},ke=function(Xe){return pe(String(Xe).replace(/[^A-Za-z0-9\+\/]/g,""))},Te=function(Xe){return _e(pe(Xe))},Ee=function(Xe){return String(Xe).replace(/[-_]/g,function(ot){return ot=="-"?"+":"/"}).replace(/[^A-Za-z0-9\+\/]/g,"")},Oe=function(Xe){return Te(Ee(Xe))},je;Ce.Uint8Array&&(je=function(Xe){return Uint8Array.from(ke(Ee(Xe)),function(ot){return ot.charCodeAt(0)})});var Pe=function(){var Xe=Ce.Base64;return Ce.Base64=ue,Xe};if(Ce.Base64={VERSION:se,atob:ke,btoa:x,fromBase64:Oe,toBase64:oe,utob:b,encode:oe,encodeURI:ve,btou:_e,decode:Oe,noConflict:Pe,fromUint8Array:ye,toUint8Array:je},typeof Object.defineProperty=="function"){var Qe=function(Xe){return{value:Xe,enumerable:!1,writable:!0,configurable:!0}};Ce.Base64.extendString=function(){Object.defineProperty(String.prototype,"fromBase64",Qe(function(){return Oe(this)})),Object.defineProperty(String.prototype,"toBase64",Qe(function(Xe){return oe(this,Xe)})),Object.defineProperty(String.prototype,"toBase64URI",Qe(function(){return oe(this,!0)}))}}return Ce.Meteor&&(Base64=Ce.Base64),Xt.exports?Xt.exports.Base64=Ce.Base64:(ce=[],ie=function(){return Ce.Base64}.apply(Mt,ce),ie!==void 0&&(Xt.exports=ie)),{Base64:Ce.Base64}})},2859:function(Xt,Mt,be){"use strict";be.d(Mt,{hP:function(){return _t}});var ce=function(We,Ae){return(ce=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Se,Be){Se.__proto__=Be}||function(Se,Be){for(var Ke in Be)Object.prototype.hasOwnProperty.call(Be,Ke)&&(Se[Ke]=Be[Ke])})(We,Ae)};function ie(We,Ae){function Se(){this.constructor=We}ce(We,Ae),We.prototype=Ae===null?Object.create(Ae):(Se.prototype=Ae.prototype,new Se)}function Ce(We,Ae,Se,Be){return new(Se||(Se=Promise))(function(Ke,Ne){function De(Ue){try{Le(Be.next(Ue))}catch(Me){Ne(Me)}}function we(Ue){try{Le(Be.throw(Ue))}catch(Me){Ne(Me)}}function Le(Ue){var Me;Ue.done?Ke(Ue.value):(Me=Ue.value,Me instanceof Se?Me:new Se(function(Re){Re(Me)})).then(De,we)}Le((Be=Be.apply(We,Ae||[])).next())})}function ue(We,Ae){var Se,Be,Ke,Ne,De={label:0,sent:function(){if(1&Ke[0])throw Ke[1];return Ke[1]},trys:[],ops:[]};return Ne={next:we(0),throw:we(1),return:we(2)},typeof Symbol=="function"&&(Ne[Symbol.iterator]=function(){return this}),Ne;function we(Le){return function(Ue){return function(Me){if(Se)throw new TypeError("Generator is already executing.");for(;De;)try{if(Se=1,Be&&(Ke=2&Me[0]?Be.return:Me[0]?Be.throw||((Ke=Be.return)&&Ke.call(Be),0):Be.next)&&!(Ke=Ke.call(Be,Me[1])).done)return Ke;switch(Be=0,Ke&&(Me=[2&Me[0],Ke.value]),Me[0]){case 0:case 1:Ke=Me;break;case 4:return De.label++,{value:Me[1],done:!1};case 5:De.label++,Be=Me[1],Me=[0];continue;case 7:Me=De.ops.pop(),De.trys.pop();continue;default:if(Ke=De.trys,!((Ke=Ke.length>0&&Ke[Ke.length-1])||Me[0]!==6&&Me[0]!==2)){De=0;continue}if(Me[0]===3&&(!Ke||Me[1]>Ke[0]&&Me[1]<Ke[3])){De.label=Me[1];break}if(Me[0]===6&&De.label<Ke[1]){De.label=Ke[1],Ke=Me;break}if(Ke&&De.label<Ke[2]){De.label=Ke[2],De.ops.push(Me);break}Ke[2]&&De.ops.pop(),De.trys.pop();continue}Me=Ae.call(We,De)}catch(Re){Me=[6,Re],Be=0}finally{Se=Ke=0}if(5&Me[0])throw Me[1];return{value:Me[0]?Me[1]:void 0,done:!0}}([Le,Ue])}}}function se(){for(var We=0,Ae=0,Se=arguments.length;Ae<Se;Ae++)We+=arguments[Ae].length;var Be=Array(We),Ke=0;for(Ae=0;Ae<Se;Ae++)for(var Ne=arguments[Ae],De=0,we=Ne.length;De<we;De++,Ke++)Be[Ke]=Ne[De];return Be}var te=function(){function We(){}return We.createDefs=function(){return document.createElementNS("http://www.w3.org/2000/svg","defs")},We.setAttributes=function(Ae,Se){for(var Be=0,Ke=Se;Be<Ke.length;Be++){var Ne=Ke[Be],De=Ne[0],we=Ne[1];Ae.setAttribute(De,we)}},We.createRect=function(Ae,Se,Be){var Ke=document.createElementNS("http://www.w3.org/2000/svg","rect");return Ke.setAttribute("width",Ae.toString()),Ke.setAttribute("height",Se.toString()),Be&&We.setAttributes(Ke,Be),Ke},We.createLine=function(Ae,Se,Be,Ke,Ne){var De=document.createElementNS("http://www.w3.org/2000/svg","line");return De.setAttribute("x1",Ae.toString()),De.setAttribute("y1",Se.toString()),De.setAttribute("x2",Be.toString()),De.setAttribute("y2",Ke.toString()),Ne&&We.setAttributes(De,Ne),De},We.createPolygon=function(Ae,Se){var Be=document.createElementNS("http://www.w3.org/2000/svg","polygon");return Be.setAttribute("points",Ae),Se&&We.setAttributes(Be,Se),Be},We.createCircle=function(Ae,Se){var Be=document.createElementNS("http://www.w3.org/2000/svg","circle");return Be.setAttribute("cx",(Ae/2).toString()),Be.setAttribute("cy",(Ae/2).toString()),Be.setAttribute("r",Ae.toString()),Se&&We.setAttributes(Be,Se),Be},We.createEllipse=function(Ae,Se,Be){var Ke=document.createElementNS("http://www.w3.org/2000/svg","ellipse");return Ke.setAttribute("cx",(Ae/2).toString()),Ke.setAttribute("cy",(Se/2).toString()),Ke.setAttribute("rx",(Ae/2).toString()),Ke.setAttribute("ry",(Se/2).toString()),Be&&We.setAttributes(Ke,Be),Ke},We.createGroup=function(Ae){var Se=document.createElementNS("http://www.w3.org/2000/svg","g");return Ae&&We.setAttributes(Se,Ae),Se},We.createTransform=function(){return document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGTransform()},We.createMarker=function(Ae,Se,Be,Ke,Ne,De,we){var Le=document.createElementNS("http://www.w3.org/2000/svg","marker");return We.setAttributes(Le,[["id",Ae],["orient",Se],["markerWidth",Be.toString()],["markerHeight",Ke.toString()],["refX",Ne.toString()],["refY",De.toString()]]),Le.appendChild(we),Le},We.createText=function(Ae){var Se=document.createElementNS("http://www.w3.org/2000/svg","text");return Se.setAttribute("x","0"),Se.setAttribute("y","0"),Ae&&We.setAttributes(Se,Ae),Se},We.createTSpan=function(Ae,Se){var Be=document.createElementNS("http://www.w3.org/2000/svg","tspan");return Be.textContent=Ae,Se&&We.setAttributes(Be,Se),Be},We.createImage=function(Ae){var Se=document.createElementNS("http://www.w3.org/2000/svg","image");return Ae&&We.setAttributes(Se,Ae),Se},We.createPoint=function(Ae,Se){var Be=document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGPoint();return Be.x=Ae,Be.y=Se,Be},We.createPath=function(Ae,Se){var Be=document.createElementNS("http://www.w3.org/2000/svg","path");return Be.setAttribute("d",Ae),Se&&We.setAttributes(Be,Se),Be},We}(),le=function(){function We(){}return We.addKey=function(Ae){We.key=Ae},Object.defineProperty(We,"isLicensed",{get:function(){return!!We.key&&new RegExp(/^MJS2-[A-Z][0-9]{3}-[A-Z][0-9]{3}-[0-9]{4}$/,"i").test(We.key)},enumerable:!1,configurable:!0}),We}(),ee=function(){function We(){this.naturalSize=!1,this.imageType="image/png",this.markersOnly=!1}return We.prototype.rasterize=function(Ae,Se,Be){var Ke=this;return new Promise(function(Ne){var De=Be!==void 0?Be:document.createElement("canvas");Ae===null&&(Ke.markersOnly=!0,Ke.naturalSize=!1);var we=document.createElementNS("http://www.w3.org/2000/svg","svg");we.setAttribute("xmlns","http://www.w3.org/2000/svg"),we.setAttribute("width",Se.width.baseVal.valueAsString),we.setAttribute("height",Se.height.baseVal.valueAsString),we.setAttribute("viewBox","0 0 "+Se.viewBox.baseVal.width.toString()+" "+Se.viewBox.baseVal.height.toString()),we.innerHTML=Se.innerHTML,Ke.naturalSize===!0?(we.width.baseVal.value=Ae.naturalWidth,we.height.baseVal.value=Ae.naturalHeight):Ke.width!==void 0&&Ke.height!==void 0&&(we.width.baseVal.value=Ke.width,we.height.baseVal.value=Ke.height),De.width=we.width.baseVal.value,De.height=we.height.baseVal.value;var Le=we.outerHTML,Ue=De.getContext("2d");Ke.markersOnly!==!0&&Ue.drawImage(Ae,0,0,De.width,De.height);var Me=window.URL,Re=new Image(De.width,De.height);Re.setAttribute("crossOrigin","anonymous");var tt=new Blob([Le],{type:"image/svg+xml"}),lt=Me.createObjectURL(tt);Re.onload=function(){Ue.drawImage(Re,0,0),Me.revokeObjectURL(lt);var Nt=De.toDataURL(Ke.imageType,Ke.imageQuality);Ne(Nt)},Re.src=lt})},We}(),ne=function(){},E=function(){function We(Ae){this._classNamePrefixBase="__markerjs2_",this.classes=[],this.rules=[],this.settings=this.defaultSettings,this._classNamePrefix=this._classNamePrefixBase+"_"+Ae+"_"}return Object.defineProperty(We.prototype,"classNamePrefixBase",{get:function(){return this._classNamePrefixBase},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"classNamePrefix",{get:function(){return this._classNamePrefix},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"defaultSettings",{get:function(){return{canvasBackgroundColor:"#ffffff",toolbarBackgroundColor:"#111111",toolbarBackgroundHoverColor:"#333333",toolbarColor:"#eeeeee",toolbarHeight:40,toolboxColor:"#eeeeee",toolboxAccentColor:"#3080c3",undoButtonVisible:!0,redoButtonVisible:!1,zoomButtonVisible:!1,zoomOutButtonVisible:!1,clearButtonVisible:!1,resultButtonBlockVisible:!0,logoPosition:"left"}},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"fadeInAnimationClassName",{get:function(){return this.classNamePrefix+"fade_in"},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"fadeOutAnimationClassName",{get:function(){return this.classNamePrefix+"fade_out"},enumerable:!1,configurable:!0}),We.prototype.addClass=function(Ae){return this.styleSheet===void 0&&this.addStyleSheet(),Ae.name=""+this.classNamePrefix+Ae.localName,this.classes.push(Ae),this.styleSheet.sheet.insertRule("."+Ae.name+" {"+Ae.style+"}",this.styleSheet.sheet.cssRules.length),Ae},We.prototype.addRule=function(Ae){this.styleSheet===void 0&&this.addStyleSheet(),this.rules.push(Ae),this.styleSheet.sheet.insertRule(Ae.selector+" {"+Ae.style+"}",this.styleSheet.sheet.cssRules.length)},We.prototype.addStyleSheet=function(){var Ae;this.styleSheet=document.createElement("style"),((Ae=this.styleSheetRoot)!==null&&Ae!==void 0?Ae:document.head).appendChild(this.styleSheet),this.addRule(new b("."+this.classNamePrefix+" h3","font-family: sans-serif")),this.addRule(new b("@keyframes "+this.classNamePrefix+"_fade_in_animation_frames",`
|
|
|
from {
|
|
|
opacity: 0;
|
|
|
}
|
|
|
to {
|
|
|
opacity: 1;
|
|
|
}
|
|
|
`)),this.addRule(new b("@keyframes "+this.classNamePrefix+"_fade_out_animation_frames",`
|
|
|
from {
|
|
|
opacity: 1;
|
|
|
}
|
|
|
to {
|
|
|
opacity: 0;
|
|
|
}
|
|
|
`)),this.addClass(new z("fade_in",`
|
|
|
animation-duration: 0.3s;
|
|
|
animation-name: `+this.classNamePrefix+`_fade_in_animation_frames;
|
|
|
`)),this.addClass(new z("fade_out",`
|
|
|
animation-duration: 0.3s;
|
|
|
animation-name: `+this.classNamePrefix+`_fade_out_animation_frames;
|
|
|
`))},We.prototype.removeStyleSheet=function(){var Ae;this.styleSheet&&(((Ae=this.styleSheetRoot)!==null&&Ae!==void 0?Ae:document.head).removeChild(this.styleSheet),this.styleSheet=void 0)},We}(),b=function(We,Ae){this.selector=We,this.style=Ae},z=function(We,Ae){this.localName=We,this.style=Ae},x=function(){function We(Ae,Se,Be,Ke,Ne){this.buttons=[],this.markerButtons=[],this.buttonClickListeners=[],this.markerjsContainer=Ae,this.displayMode=Se,this.markerItems=Be,this.uiStyleSettings=Ke,this.styles=Ne,this.addStyles(),this.adjustLayout=this.adjustLayout.bind(this),this.overflowButtonClicked=this.overflowButtonClicked.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this)}return We.prototype.show=function(Ae){var Se=this;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=Ae,this.uiContainer.className=this.toolbarStyleClass.name+" "+this.styles.fadeInAnimationClassName+" "+(this.uiStyleSettings.toolbarStyleColorsClassName?this.uiStyleSettings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name);var Be=document.createElement("div");Be.className=this.toolbarBlockStyleClass.name,Be.style.whiteSpace="nowrap",this.uiContainer.appendChild(Be),this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M10.07 14.27a.997.997 0 011.33.48l2.3 4.99 1.8-.85-2.31-4.98c-.24-.5-.02-1.1.48-1.33l.28-.08 2.3-.45L8 5.12V15.9l1.82-1.47.25-.16m3.57 7.7a.99.99 0 01-1.33-.47l-2.18-4.74-2.51 2.02c-.17.14-.38.22-.62.22a1 1 0 01-1-1V3a1 1 0 011-1c.24 0 .47.09.64.23l.01-.01 11.49 9.64a1.001 1.001 0 01-.44 1.75l-3.16.62 2.2 4.73c.26.5.02 1.09-.48 1.32l-3.62 1.69z"/></svg>',"select"),this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M9 3v1H4v2h1v13a2 2 0 002 2h10a2 2 0 002-2V6h1V4h-5V3H9M7 6h10v13H7V6m2 2v9h2V8H9m4 0v9h2V8h-2z"/></svg>',"delete"),this.uiStyleSettings.clearButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M19.36 2.72l1.42 1.42-5.72 5.71c1.07 1.54 1.22 3.39.32 4.59L9.06 8.12c1.2-.9 3.05-.75 4.59.32l5.71-5.72M5.93 17.57c-2.01-2.01-3.24-4.41-3.58-6.65l4.88-2.09 7.44 7.44-2.09 4.88c-2.24-.34-4.64-1.57-6.65-3.58z"/></svg>',"clear"),this.uiStyleSettings.undoButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M12.5 8c-2.65 0-5.05 1-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"/></svg>',"undo"),this.uiStyleSettings.redoButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M18.4 10.6C16.55 9 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16a8.002 8.002 0 017.6-5.5c1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"/></svg>',"redo"),this.uiStyleSettings.zoomButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M15.5 14l5 5-1.5 1.5-5-5v-.79l-.27-.28A6.471 6.471 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3 6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.57 4.23l.28.27h.79m-6 0C12 14 14 12 14 9.5S12 5 9.5 5 5 7 5 9.5 7 14 9.5 14m2.5-4h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></svg>',"zoom"),this.uiStyleSettings.zoomButtonVisible&&this.uiStyleSettings.zoomOutButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M15.5 14h-.79l-.28-.27A6.471 6.471 0 0016 9.5 6.5 6.5 0 009.5 3 6.5 6.5 0 003 9.5 6.5 6.5 0 009.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 5 1.5-1.5-5-5m-6 0C7 14 5 12 5 9.5S7 5 9.5 5 14 7 14 9.5 12 14 9.5 14M7 9h5v1H7V9z"/></svg>',"zoom-out"),this.uiStyleSettings.notesButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M18.13 12l1.26-1.26c.44-.44 1-.68 1.61-.74V9l-6-6H5c-1.11 0-2 .89-2 2v14a2 2 0 002 2h6v-1.87l.13-.13H5V5h7v7h6.13M14 4.5l5.5 5.5H14V4.5m5.13 9.33l2.04 2.04L15.04 22H13v-2.04l6.13-6.13m3.72.36l-.98.98-2.04-2.04.98-.98c.19-.2.52-.2.72 0l1.32 1.32c.2.2.2.53 0 .72z"/></svg>',"notes"),this.markerButtonBlock=document.createElement("div"),this.markerButtonBlock.className=this.toolbarBlockStyleClass.name,this.markerButtonBlock.style.flexGrow="2",this.markerButtonBlock.style.textAlign="center",this.uiContainer.appendChild(this.markerButtonBlock),this.markerButtonOverflowBlock=document.createElement("div"),this.markerButtonOverflowBlock.className=this.toolbarOverflowBlockStyleClass.name+" "+(this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName?this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName:this.toolbarOverflowBlockStyleColorsClass.name),this.markerButtonOverflowBlock.style.display="none",this.uiContainer.appendChild(this.markerButtonOverflowBlock),this.markerItems&&(this.markerItems.forEach(function(Ne){var De=document.createElement("div");De.className=""+Se.toolbarButtonStyleClass.name,De.setAttribute("data-type-name",Ne.typeName),De.innerHTML=Ne.icon,De.addEventListener("click",function(){Se.markerToolbarButtonClicked(De,Ne)}),Se.buttons.push(De),Se.markerButtons.push(De)}),this.overflowButton=document.createElement("div"),this.overflowButton.className=this.toolbarButtonStyleClass.name+" "+(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name),this.overflowButton.innerHTML='<svg viewBox="0 0 24 24"><path d="M12 16a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2z"/></svg>',this.overflowButton.addEventListener("click",this.overflowButtonClicked),this.markerButtonBlock.appendChild(this.overflowButton));var Ke=document.createElement("div");Ke.className=this.toolbarBlockStyleClass.name,Ke.style.whiteSpace="nowrap",Ke.style.display=this.uiStyleSettings.resultButtonBlockVisible!==!1?"":"none",this.uiContainer.appendChild(Ke),this.addActionButton(Ke,'<svg viewBox="0 0 24 24"><path d="M9 20.42l-6.21-6.21 2.83-2.83L9 14.77l9.88-9.89 2.83 2.83L9 20.42z"/></svg>',"render"),this.addActionButton(Ke,'<svg viewBox="0 0 24 24"><path d="M20 6.91L17.09 4 12 9.09 6.91 4 4 6.91 9.09 12 4 17.09 6.91 20 12 14.91 17.09 20 20 17.09 14.91 12 20 6.91z"/></svg>',"close"),this.markerjsContainer.appendChild(this.uiContainer),this.setSelectMode(),this.setCurrentMarker(),this.adjustLayout()},We.prototype.addButtonClickListener=function(Ae){this.buttonClickListeners.push(Ae)},We.prototype.removeButtonClickListener=function(Ae){this.buttonClickListeners.indexOf(Ae)>-1&&this.buttonClickListeners.splice(this.buttonClickListeners.indexOf(Ae),1)},We.prototype.setSelectMode=function(){this.resetButtonStyles(),this.setActiveButton(this.buttons[0])},We.prototype.adjustLayout=function(){if(this.markerButtons&&this.markerButtons.length>0){var Ae=Math.floor(this.markerButtonBlock.clientWidth/this.uiStyleSettings.toolbarHeight)-1;this.markerButtonBlock.innerHTML="",this.markerButtonOverflowBlock.innerHTML="";for(var Se=0;Se<this.markerButtons.length;Se++)Se<Ae||Se===Ae&&this.markerButtons.length-1===Ae?this.markerButtonBlock.appendChild(this.markerButtons[Se]):(Se===Ae&&this.markerButtonBlock.appendChild(this.overflowButton),this.markerButtonOverflowBlock.appendChild(this.markerButtons[Se]))}},We.prototype.overflowButtonClicked=function(){this.markerButtonOverflowBlock.style.display!=="none"?(this.markerButtonOverflowBlock.className=this.markerButtonOverflowBlock.className.replace(this.styles.fadeInAnimationClassName,""),this.markerButtonOverflowBlock.style.display="none"):(this.markerButtonOverflowBlock.className+=" "+this.styles.fadeInAnimationClassName,this.markerButtonOverflowBlock.style.top=this.uiContainer.offsetTop+this.overflowButton.offsetHeight+"px",this.markerButtonOverflowBlock.style.right=this.uiContainer.offsetWidth-this.overflowButton.offsetLeft-this.overflowButton.offsetWidth+2*this.uiContainer.offsetLeft+"px",this.markerButtonOverflowBlock.style.display="inline-block")},We.prototype.resetButtonStyles=function(){var Ae=this;this.buttons.forEach(function(Se){Se.className=Se.className.replace(Ae.uiStyleSettings.toolbarButtonStyleColorsClassName?Ae.uiStyleSettings.toolbarButtonStyleColorsClassName:Ae.toolbarButtonStyleColorsClass.name,"").trim(),Se.className=Se.className.replace(Ae.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?Ae.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:Ae.toolbarActiveButtonStyleColorsClass.name,"").trim(),Se.className+=" "+(Ae.uiStyleSettings.toolbarButtonStyleColorsClassName?Ae.uiStyleSettings.toolbarButtonStyleColorsClassName:Ae.toolbarButtonStyleColorsClass.name)})},We.prototype.addActionButton=function(Ae,Se,Be){var Ke=this,Ne=document.createElement("div");switch(Ne.className=""+this.toolbarButtonStyleClass.name,Ne.innerHTML=Se,Ne.setAttribute("data-action",Be),Ne.addEventListener("click",function(){Ke.actionToolbarButtonClicked(Ne,Be)}),Be){case"select":Ne.style.fill=this.uiStyleSettings.selectButtonColor;break;case"delete":case"clear":Ne.style.fill=this.uiStyleSettings.deleteButtonColor;break;case"undo":case"redo":Ne.style.fill=this.uiStyleSettings.selectButtonColor;break;case"render":Ne.style.fill=this.uiStyleSettings.okButtonColor;break;case"close":Ne.style.fill=this.uiStyleSettings.closeButtonColor}Ae.appendChild(Ne),this.buttons.push(Ne)},We.prototype.addStyles=function(){this.toolbarStyleClass=this.styles.addClass(new z("toolbar",`
|
|
|
width: 100%;
|
|
|
flex-shrink: 0;
|
|
|
display: flex;
|
|
|
flex-direction: row;
|
|
|
justify-content: space-between;
|
|
|
height: `+this.uiStyleSettings.toolbarHeight+`px;
|
|
|
box-sizing: content-box;
|
|
|
`+(this.displayMode==="inline"?"border-top-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
`+(this.displayMode==="inline"?"border-top-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
overflow: hidden;
|
|
|
`)),this.toolbarStyleColorsClass=this.styles.addClass(new z("toolbar_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
|
|
|
box-shadow: 0px 3px rgba(33, 33, 33, 0.1);
|
|
|
`)),this.toolbarBlockStyleClass=this.styles.addClass(new z("toolbar-block",`
|
|
|
display: inline-block;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolbarOverflowBlockStyleClass=this.styles.addClass(new z("toolbar-overflow-block",`
|
|
|
position: absolute;
|
|
|
top: `+this.uiStyleSettings.toolbarHeight+`px;
|
|
|
max-width: `+2*this.uiStyleSettings.toolbarHeight+`px;
|
|
|
z-index: 10;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolbarOverflowBlockStyleColorsClass=this.styles.addClass(new z("toolbar-overflow-block_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
|
|
|
`));var Ae=this.uiStyleSettings.toolbarHeight/4;this.toolbarButtonStyleClass=this.styles.addClass(new z("toolbar_button",`
|
|
|
display: inline-block;
|
|
|
width: `+(this.uiStyleSettings.toolbarHeight-2*Ae)+`px;
|
|
|
height: `+(this.uiStyleSettings.toolbarHeight-2*Ae)+`px;
|
|
|
padding: `+Ae+`px;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolbarButtonStyleColorsClass=this.styles.addClass(new z("toolbar_button_colors",`
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
`)),this.toolbarActiveButtonStyleColorsClass=this.styles.addClass(new z("toolbar_active_button",`
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
|
|
|
`)),this.styles.addRule(new b("."+this.toolbarButtonStyleClass.name+" svg",`
|
|
|
height: `+this.uiStyleSettings.toolbarHeight/2+`px;
|
|
|
`)),this.styles.addRule(new b("."+this.toolbarButtonStyleColorsClass.name+":hover",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
|
|
|
`))},We.prototype.markerToolbarButtonClicked=function(Ae,Se){this.setActiveButton(Ae),this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(Be){return Be("marker",Se)}),this.markerButtonOverflowBlock.style.display="none"},We.prototype.actionToolbarButtonClicked=function(Ae,Se){this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(Be){return Be("action",Se)}),this.markerButtonOverflowBlock.style.display="none",this.setActiveButton(this.buttons[0])},We.prototype.setActiveButton=function(Ae){this.resetButtonStyles(),Ae.className=Ae.className.replace(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,"").trim(),Ae.className+=" "+(this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name)},We.prototype.setActiveMarkerButton=function(Ae){var Se=this.markerButtons.find(function(Be){return Be.getAttribute("data-type-name")===Ae});Se&&this.setActiveButton(Se)},We.prototype.setCurrentMarker=function(Ae){var Se=this;this.currentMarker=Ae,this.buttons.filter(function(Be){return/delete|notes/.test(Be.getAttribute("data-action"))}).forEach(function(Be){Se.currentMarker===void 0?(Be.style.fillOpacity="0.4",Be.style.pointerEvents="none"):(Be.style.fillOpacity="1",Be.style.pointerEvents="all")})},We}(),re=function(){function We(Ae,Se,Be,Ke){this.panels=[],this.panelButtons=[],this.markerjsContainer=Ae,this.displayMode=Se,this.uiStyleSettings=Be,this.styles=Ke,this.panelButtonClick=this.panelButtonClick.bind(this),this.addStyles()}return We.prototype.addStyles=function(){var Ae;this.toolboxStyleClass=this.styles.addClass(new z("toolbox",`
|
|
|
width: 100%;
|
|
|
flex-shrink: 0;
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
|
font-family: sans-serif;
|
|
|
`+(this.displayMode==="popup"?"height:"+2.5*this.uiStyleSettings.toolbarHeight+"px;":"")+`
|
|
|
box-sizing: content-box;
|
|
|
`+(this.displayMode==="popup"?"background-color: "+this.uiStyleSettings.canvasBackgroundColor+";":"")+`
|
|
|
`+(this.displayMode==="inline"?"border-bottom-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
`+(this.displayMode==="inline"?"border-bottom-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
|
|
|
overflow: hidden;
|
|
|
`)),this.toolboxStyleColorsClass=this.styles.addClass(new z("toolbox_colors",`
|
|
|
color: `+this.uiStyleSettings.toolboxColor+`;
|
|
|
`));var Se=this.uiStyleSettings.toolbarHeight/4;this.toolboxButtonRowStyleClass=this.styles.addClass(new z("toolbox-button-row",`
|
|
|
display: flex;
|
|
|
cursor: default;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolboxButtonRowStyleColorsClass=this.styles.addClass(new z("toolbox-button-row_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
|
|
|
`)),this.toolboxPanelRowStyleClass=this.styles.addClass(new z("toolbox-panel-row",`
|
|
|
display: flex;
|
|
|
`+(this.displayMode==="inline"?"position: absolute;":"")+`
|
|
|
`+(this.displayMode==="inline"?"bottom: "+this.uiStyleSettings.toolbarHeight+"px;":"")+`
|
|
|
cursor: default;
|
|
|
height: `+1.5*this.uiStyleSettings.toolbarHeight+`px;
|
|
|
`+(this.displayMode==="inline"?"width: 100%;":"")+`
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolboxPanelRowStyleColorsClass=this.styles.addClass(new z("toolbox-panel-row_colors",`
|
|
|
background-color: `+((Ae=this.uiStyleSettings.toolboxBackgroundColor)!==null&&Ae!==void 0?Ae:this.uiStyleSettings.toolbarBackgroundHoverColor)+`;
|
|
|
`)),this.toolboxButtonStyleClass=this.styles.addClass(new z("toolbox_button",`
|
|
|
display: inline-block;
|
|
|
width: `+(this.uiStyleSettings.toolbarHeight-2*Se)+`px;
|
|
|
height: `+(this.uiStyleSettings.toolbarHeight-2*Se)+`px;
|
|
|
padding: `+Se+`px;
|
|
|
box-sizing: content-box;
|
|
|
`)),this.toolboxButtonStyleColorsClass=this.styles.addClass(new z("toolbox-button_colors",`
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
`)),this.toolboxActiveButtonStyleColorsClass=this.styles.addClass(new z("toolbox-active-button_colors",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`;
|
|
|
fill: `+this.uiStyleSettings.toolbarColor+`;
|
|
|
`)),this.styles.addRule(new b("."+this.toolboxButtonStyleColorsClass.name+":hover",`
|
|
|
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
|
|
|
`)),this.styles.addRule(new b("."+this.toolboxButtonStyleClass.name+" svg",`
|
|
|
height: `+this.uiStyleSettings.toolbarHeight/2+`px;
|
|
|
`))},We.prototype.show=function(Ae){var Se;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=Ae,this.uiContainer.className=this.toolboxStyleClass.name+" "+((Se=this.uiStyleSettings.toolboxStyleColorsClassName)!==null&&Se!==void 0?Se:this.toolboxStyleColorsClass.name),this.markerjsContainer.appendChild(this.uiContainer)},We.prototype.setPanelButtons=function(Ae){var Se,Be,Ke=this;this.panels=Ae,this.uiContainer!==void 0&&(this.uiContainer.innerHTML="",this.panelRow=document.createElement("div"),this.panelRow.className=this.toolboxPanelRowStyleClass.name+" "+((Se=this.uiStyleSettings.toolboxPanelRowStyleColorsClassName)!==null&&Se!==void 0?Se:this.toolboxPanelRowStyleColorsClass.name),this.uiContainer.appendChild(this.panelRow),this.buttonRow=document.createElement("div"),this.buttonRow.className=this.toolboxButtonRowStyleClass.name+" "+((Be=this.uiStyleSettings.toolboxButtonRowStyleColorsClassName)!==null&&Be!==void 0?Be:this.toolboxButtonRowStyleColorsClass.name)+" ",this.uiContainer.appendChild(this.buttonRow),this.panelButtons.splice(0),this.panels.forEach(function(Ne){var De;Ne.uiStyleSettings=Ke.uiStyleSettings;var we=document.createElement("div");we.className=Ke.toolboxButtonStyleClass.name+" "+((De=Ke.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&De!==void 0?De:Ke.toolboxButtonStyleColorsClass.name),we.innerHTML=Ne.icon,we.title=Ne.title,we.addEventListener("click",function(){Ke.panelButtonClick(Ne)}),Ke.panelButtons.push(we),Ke.buttonRow.appendChild(we)}),this.displayMode==="inline"?this.panelRow.style.display="none":this.panelRow.style.visibility="hidden")},We.prototype.panelButtonClick=function(Ae){var Se=this,Be=-1;if(Ae!==this.activePanel){Be=this.panels.indexOf(Ae),this.panelRow.innerHTML="";var Ke=Ae.getUi();Ke.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.panelRow.appendChild(Ke),this.panelRow.style.display="flex",this.panelRow.style.visibility="visible",this.panelRow.className=this.panelRow.className.replace(this.styles.fadeOutAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeInAnimationClassName,this.activePanel=Ae}else this.activePanel=void 0,this.panelRow.className=this.panelRow.className.replace(this.styles.fadeInAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeOutAnimationClassName,setTimeout(function(){Se.displayMode==="inline"?Se.panelRow.style.display="none":Se.panelRow.style.visibility="hidden"},200);this.panelButtons.forEach(function(Ne,De){var we,Le;Ne.className=Se.toolboxButtonStyleClass.name+" "+(De===Be?""+((we=Se.uiStyleSettings.toolboxActiveButtonStyleColorsClassName)!==null&&we!==void 0?we:Se.toolboxActiveButtonStyleColorsClass.name):""+((Le=Se.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&Le!==void 0?Le:Se.toolboxButtonStyleColorsClass.name))})},We}(),ae=function(We,Ae){this.title=We,this.icon=Ae},oe=function(We){function Ae(Se,Be,Ke,Ne){var De=We.call(this,Se,Ne||'<svg viewBox="0 0 24 24"><path d="M17.5 12a1.5 1.5 0 01-1.5-1.5A1.5 1.5 0 0117.5 9a1.5 1.5 0 011.5 1.5 1.5 1.5 0 01-1.5 1.5m-3-4A1.5 1.5 0 0113 6.5 1.5 1.5 0 0114.5 5 1.5 1.5 0 0116 6.5 1.5 1.5 0 0114.5 8m-5 0A1.5 1.5 0 018 6.5 1.5 1.5 0 019.5 5 1.5 1.5 0 0111 6.5 1.5 1.5 0 019.5 8m-3 4A1.5 1.5 0 015 10.5 1.5 1.5 0 016.5 9 1.5 1.5 0 018 10.5 1.5 1.5 0 016.5 12M12 3a9 9 0 00-9 9 9 9 0 009 9 1.5 1.5 0 001.5-1.5c0-.39-.15-.74-.39-1-.23-.27-.38-.62-.38-1a1.5 1.5 0 011.5-1.5H16a5 5 0 005-5c0-4.42-4.03-8-9-8z"/></svg>')||this;return De.colors=[],De.addTransparent=!1,De.colorBoxes=[],De.colors=Be,De.currentColor=Ke,De.setCurrentColor=De.setCurrentColor.bind(De),De.getColorBox=De.getColorBox.bind(De),De}return ie(Ae,We),Ae.prototype.getUi=function(){var Se=this,Be=document.createElement("div");return Be.style.overflow="hidden",Be.style.whiteSpace="nowrap",this.colors.forEach(function(Ke){var Ne=Se.getColorBox(Ke);Be.appendChild(Ne),Se.colorBoxes.push(Ne)}),Be},Ae.prototype.getColorBox=function(Se){var Be=this,Ke=this.uiStyleSettings.toolbarHeight/4,Ne=this.uiStyleSettings.toolbarHeight-Ke,De=document.createElement("div");De.style.display="inline-block",De.style.boxSizing="content-box",De.style.width=Ne-2+"px",De.style.height=Ne-2+"px",De.style.padding="1px",De.style.marginRight="2px",De.style.marginBottom="2px",De.style.borderWidth="2px",De.style.borderStyle="solid",De.style.borderRadius=(Ne+2)/2+"px",De.style.borderColor=Se===this.currentColor?this.uiStyleSettings.toolboxAccentColor:"transparent",De.addEventListener("click",function(){Be.setCurrentColor(Se,De)});var we=document.createElement("div");return we.style.display="inline-block",we.style.width=Ne-2+"px",we.style.height=Ne-2+"px",we.style.backgroundColor=Se,we.style.borderRadius=Ne/2+"px",Se==="transparent"&&(we.style.fill=this.uiStyleSettings.toolboxAccentColor,we.innerHTML=`<svg viewBox="0 0 24 24">
|
|
|
<path d="M2,5.27L3.28,4L20,20.72L18.73,22L15.65,18.92C14.5,19.3 13.28,19.5 12,19.5C7,19.5 2.73,16.39 1,12C1.69,10.24 2.79,8.69 4.19,7.46L2,5.27M12,9A3,3 0 0,1 15,12C15,12.35 14.94,12.69 14.83,13L11,9.17C11.31,9.06 11.65,9 12,9M12,4.5C17,4.5 21.27,7.61 23,12C22.18,14.08 20.79,15.88 19,17.19L17.58,15.76C18.94,14.82 20.06,13.54 20.82,12C19.17,8.64 15.76,6.5 12,6.5C10.91,6.5 9.84,6.68 8.84,7L7.3,5.47C8.74,4.85 10.33,4.5 12,4.5M3.18,12C4.83,15.36 8.24,17.5 12,17.5C12.69,17.5 13.37,17.43 14,17.29L11.72,15C10.29,14.85 9.15,13.71 9,12.28L5.6,8.87C4.61,9.72 3.78,10.78 3.18,12Z" />
|
|
|
</svg>`),De.appendChild(we),De},Ae.prototype.setCurrentColor=function(Se,Be){var Ke=this;this.currentColor=Se,this.colorBoxes.forEach(function(Ne){Ne.style.borderColor=Ne===Be?Ke.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onColorChanged&&this.onColorChanged(Se)},Ae}(ae),ve=function(){function We(Ae,Se,Be){this._state="new",this._isSelected=!1,this._container=Ae,this._overlayContainer=Se,this.globalSettings=Be,this.stateChanged=this.stateChanged.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this)}return Object.defineProperty(We.prototype,"typeName",{get:function(){return Object.getPrototypeOf(this).constructor.typeName},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"container",{get:function(){return this._container},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"overlayContainer",{get:function(){return this._overlayContainer},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"toolboxPanels",{get:function(){return[]},enumerable:!1,configurable:!0}),We.prototype.ownsTarget=function(Ae){return!1},Object.defineProperty(We.prototype,"isSelected",{get:function(){return this._isSelected},enumerable:!1,configurable:!0}),We.prototype.select=function(){this.container.style.cursor="move",this._isSelected=!0,this.manipulationStartState=this.getState()},We.prototype.deselect=function(){this.container.style.cursor="default",this._isSelected=!1,this.stateChanged()},We.prototype.pointerDown=function(Ae,Se){},We.prototype.dblClick=function(Ae,Se){},We.prototype.manipulate=function(Ae){},We.prototype.pointerUp=function(Ae){this.stateChanged()},We.prototype.dispose=function(){},We.prototype.addMarkerVisualToContainer=function(Ae){this.container.childNodes.length>0?this.container.insertBefore(Ae,this.container.childNodes[0]):this.container.appendChild(Ae)},We.prototype.getState=function(){return{typeName:We.typeName,state:this.state,notes:this.notes}},We.prototype.restoreState=function(Ae){this._state=Ae.state,this.notes=Ae.notes},We.prototype.scale=function(Ae,Se){},We.prototype.colorChanged=function(Ae){this.onColorChanged&&this.onColorChanged(Ae),this.stateChanged()},We.prototype.fillColorChanged=function(Ae){this.onFillColorChanged&&this.onFillColorChanged(Ae),this.stateChanged()},We.prototype.stateChanged=function(){if(this.onStateChanged&&this.state!=="creating"&&this.state!=="new"){var Ae=this.getState();this.manipulationStartState!==void 0&&(this.manipulationStartState.state="select"),Ae.state="select",JSON.stringify(this.manipulationStartState)!=JSON.stringify(Ae)&&this.onStateChanged(this)}},We.typeName="MarkerBase",We}(),ye=function(){function We(){this.findGripByVisual=this.findGripByVisual.bind(this)}return We.prototype.findGripByVisual=function(Ae){return this.topLeft.ownsTarget(Ae)?this.topLeft:this.topCenter.ownsTarget(Ae)?this.topCenter:this.topRight.ownsTarget(Ae)?this.topRight:this.centerLeft.ownsTarget(Ae)?this.centerLeft:this.centerRight.ownsTarget(Ae)?this.centerRight:this.bottomLeft.ownsTarget(Ae)?this.bottomLeft:this.bottomCenter.ownsTarget(Ae)?this.bottomCenter:this.bottomRight.ownsTarget(Ae)?this.bottomRight:void 0},We}(),me=function(){function We(){this.GRIP_SIZE=10,this.visual=te.createGroup(),this.visual.appendChild(te.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(te.createCircle(this.GRIP_SIZE,[["fill","#cccccc"],["fill-opacity","0.7"],["stroke","#333333"],["stroke-width","2"],["stroke-opacity","0.7"]]))}return We.prototype.ownsTarget=function(Ae){return Ae===this.visual||Ae===this.visual.childNodes[0]||Ae===this.visual.childNodes[1]},We}(),ge=function(){function We(){}return We.toITransformMatrix=function(Ae){return{a:Ae.a,b:Ae.b,c:Ae.c,d:Ae.d,e:Ae.e,f:Ae.f}},We.toSVGMatrix=function(Ae,Se){return Ae.a=Se.a,Ae.b=Se.b,Ae.c=Se.c,Ae.d=Se.d,Ae.e=Se.e,Ae.f=Se.f,Ae},We}(),_e=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.left=0,Ne.top=0,Ne.width=0,Ne.height=0,Ne.defaultSize={x:50,y:20},Ne.offsetX=0,Ne.offsetY=0,Ne.rotationAngle=0,Ne.CB_DISTANCE=10,Ne._suppressMarkerCreateEvent=!1,Ne.container.transform.baseVal.appendItem(te.createTransform()),Ne.setupControlBox(),Ne}return ie(Ae,We),Object.defineProperty(Ae.prototype,"centerX",{get:function(){return this.left+this.width/2},enumerable:!1,configurable:!0}),Object.defineProperty(Ae.prototype,"centerY",{get:function(){return this.top+this.height/2},enumerable:!1,configurable:!0}),Object.defineProperty(Ae.prototype,"visual",{get:function(){return this._visual},set:function(Se){this._visual=Se;var Be=te.createTransform();this._visual.transform.baseVal.appendItem(Be)},enumerable:!1,configurable:!0}),Ae.prototype.ownsTarget=function(Se){return!!We.prototype.ownsTarget.call(this,Se)||!!(this.controlGrips.findGripByVisual(Se)!==void 0||this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(Se))},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.state==="new"&&(this.left=Se.x,this.top=Se.y),this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.manipulationStartWidth=this.width,this.manipulationStartHeight=this.height;var Ke=this.unrotatePoint(Se);if(this.manipulationStartX=Ke.x,this.manipulationStartY=Ke.y,this.offsetX=Ke.x-this.left,this.offsetY=Ke.y-this.top,this.state!=="new")if(this.select(),this.activeGrip=this.controlGrips.findGripByVisual(Be),this.activeGrip!==void 0)this._state="resize";else if(this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(Be)){this.activeGrip=this.rotatorGrip;var Ne=this.rotatePoint({x:this.centerX,y:this.centerY});this.left=Ne.x-this.width/2,this.top=Ne.y-this.height/2,this.moveVisual({x:this.left,y:this.top});var De=this.container.transform.baseVal.getItem(0);De.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(De,0),this.adjustControlBox(),this._state="rotate"}else this._state="move"},Ae.prototype.pointerUp=function(Se){var Be=this.state;We.prototype.pointerUp.call(this,Se),this.state==="creating"&&this.width<10&&this.height<10?(this.width=this.defaultSize.x,this.height=this.defaultSize.y):this.manipulate(Se),this._state="select",Be==="creating"&&this.onMarkerCreated&&this._suppressMarkerCreateEvent===!1&&this.onMarkerCreated(this)},Ae.prototype.moveVisual=function(Se){this.visual.style.transform="translate("+Se.x+"px, "+Se.y+"px)"},Ae.prototype.manipulate=function(Se){var Be=this.unrotatePoint(Se);this.state==="creating"?this.resize(Se):this.state==="move"?(this.left=this.manipulationStartLeft+(Be.x-this.manipulationStartLeft)-this.offsetX,this.top=this.manipulationStartTop+(Be.y-this.manipulationStartTop)-this.offsetY,this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()):this.state==="resize"?this.resize(Be):this.state==="rotate"&&this.rotate(Se)},Ae.prototype.resize=function(Se){var Be=this.manipulationStartLeft,Ke=this.manipulationStartWidth,Ne=this.manipulationStartTop,De=this.manipulationStartHeight;switch(this.activeGrip){case this.controlGrips.bottomLeft:case this.controlGrips.centerLeft:case this.controlGrips.topLeft:Be=this.manipulationStartLeft+Se.x-this.manipulationStartX,Ke=this.manipulationStartWidth+this.manipulationStartLeft-Be;break;case this.controlGrips.bottomRight:case this.controlGrips.centerRight:case this.controlGrips.topRight:case void 0:Ke=this.manipulationStartWidth+Se.x-this.manipulationStartX}switch(this.activeGrip){case this.controlGrips.topCenter:case this.controlGrips.topLeft:case this.controlGrips.topRight:Ne=this.manipulationStartTop+Se.y-this.manipulationStartY,De=this.manipulationStartHeight+this.manipulationStartTop-Ne;break;case this.controlGrips.bottomCenter:case this.controlGrips.bottomLeft:case this.controlGrips.bottomRight:case void 0:De=this.manipulationStartHeight+Se.y-this.manipulationStartY}Ke>=0?(this.left=Be,this.width=Ke):(this.left=Be+Ke,this.width=-Ke),De>=0?(this.top=Ne,this.height=De):(this.top=Ne+De,this.height=-De),this.setSize()},Ae.prototype.setSize=function(){this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()},Ae.prototype.rotate=function(Se){if(Math.abs(Se.x-this.centerX)>.1){var Be=Math.sign(Se.x-this.centerX);this.rotationAngle=180*Math.atan((Se.y-this.centerY)/(Se.x-this.centerX))/Math.PI+90*Be,this.applyRotation()}},Ae.prototype.applyRotation=function(){var Se=this.container.transform.baseVal.getItem(0);Se.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(Se,0)},Ae.prototype.rotatePoint=function(Se){if(this.rotationAngle===0)return Se;var Be=this.container.getCTM(),Ke=te.createPoint(Se.x,Se.y);return{x:(Ke=Ke.matrixTransform(Be)).x,y:Ke.y}},Ae.prototype.unrotatePoint=function(Se){if(this.rotationAngle===0)return Se;var Be=this.container.getCTM();Be=Be.inverse();var Ke=te.createPoint(Se.x,Se.y);return{x:(Ke=Ke.matrixTransform(Be)).x,y:Ke.y}},Ae.prototype.select=function(){We.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},Ae.prototype.deselect=function(){We.prototype.deselect.call(this),this.controlBox.style.display="none"},Ae.prototype.setupControlBox=function(){this.controlBox=te.createGroup();var Se=te.createTransform();Se.setTranslate(-this.CB_DISTANCE/2,-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.appendItem(Se),this.container.appendChild(this.controlBox),this.controlRect=te.createRect(this.width+this.CB_DISTANCE,this.height+this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"],["fill","transparent"],["pointer-events","none"]]),this.controlBox.appendChild(this.controlRect),this.globalSettings.disableRotation!==!0&&(this.rotatorGripLine=te.createLine((this.width+2*this.CB_DISTANCE)/2,this.top-this.CB_DISTANCE,(this.width+2*this.CB_DISTANCE)/2,this.top-3*this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.appendChild(this.rotatorGripLine)),this.controlGrips=new ye,this.addControlGrips(),this.controlBox.style.display="none"},Ae.prototype.adjustControlBox=function(){var Se=this.controlBox.transform.baseVal.getItem(0);Se.setTranslate(this.left-this.CB_DISTANCE/2,this.top-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.replaceItem(Se,0),this.controlRect.setAttribute("width",(this.width+this.CB_DISTANCE).toString()),this.controlRect.setAttribute("height",(this.height+this.CB_DISTANCE).toString()),this.rotatorGripLine!==void 0&&(this.rotatorGripLine.setAttribute("x1",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y1",(-this.CB_DISTANCE/2).toString()),this.rotatorGripLine.setAttribute("x2",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y2",(3*-this.CB_DISTANCE).toString())),this.positionGrips()},Ae.prototype.addControlGrips=function(){this.controlGrips.topLeft=this.createGrip(),this.controlGrips.topCenter=this.createGrip(),this.controlGrips.topRight=this.createGrip(),this.controlGrips.centerLeft=this.createGrip(),this.controlGrips.centerRight=this.createGrip(),this.controlGrips.bottomLeft=this.createGrip(),this.controlGrips.bottomCenter=this.createGrip(),this.controlGrips.bottomRight=this.createGrip(),this.globalSettings.disableRotation!==!0&&(this.rotatorGrip=this.createGrip()),this.positionGrips()},Ae.prototype.createGrip=function(){var Se=new me;return Se.visual.transform.baseVal.appendItem(te.createTransform()),this.controlBox.appendChild(Se.visual),Se},Ae.prototype.positionGrips=function(){var Se=this.controlGrips.topLeft.GRIP_SIZE,Be=-Se/2,Ke=Be,Ne=(this.width+this.CB_DISTANCE)/2-Se/2,De=(this.height+this.CB_DISTANCE)/2-Se/2,we=this.height+this.CB_DISTANCE-Se/2,Le=this.width+this.CB_DISTANCE-Se/2;this.positionGrip(this.controlGrips.topLeft.visual,Be,Ke),this.positionGrip(this.controlGrips.topCenter.visual,Ne,Ke),this.positionGrip(this.controlGrips.topRight.visual,Le,Ke),this.positionGrip(this.controlGrips.centerLeft.visual,Be,De),this.positionGrip(this.controlGrips.centerRight.visual,Le,De),this.positionGrip(this.controlGrips.bottomLeft.visual,Be,we),this.positionGrip(this.controlGrips.bottomCenter.visual,Ne,we),this.positionGrip(this.controlGrips.bottomRight.visual,Le,we),this.rotatorGrip!==void 0&&this.positionGrip(this.rotatorGrip.visual,Ne,Ke-3*this.CB_DISTANCE)},Ae.prototype.positionGrip=function(Se,Be,Ke){var Ne=Se.transform.baseVal.getItem(0);Ne.setTranslate(Be,Ke),Se.transform.baseVal.replaceItem(Ne,0)},Ae.prototype.hideControlBox=function(){this.controlBox.style.display="none"},Ae.prototype.showControlBox=function(){this.controlBox.style.display=""},Ae.prototype.getState=function(){return Object.assign({left:this.left,top:this.top,width:this.width,height:this.height,rotationAngle:this.rotationAngle,visualTransformMatrix:ge.toITransformMatrix(this.visual.transform.baseVal.getItem(0).matrix),containerTransformMatrix:ge.toITransformMatrix(this.container.transform.baseVal.getItem(0).matrix)},We.prototype.getState.call(this))},Ae.prototype.restoreState=function(Se){We.prototype.restoreState.call(this,Se);var Be=Se;this.left=Be.left,this.top=Be.top,this.width=Be.width,this.height=Be.height,this.rotationAngle=Be.rotationAngle,this.visual.transform.baseVal.getItem(0).setMatrix(ge.toSVGMatrix(this.visual.transform.baseVal.getItem(0).matrix,Be.visualTransformMatrix)),this.container.transform.baseVal.getItem(0).setMatrix(ge.toSVGMatrix(this.container.transform.baseVal.getItem(0).matrix,Be.containerTransformMatrix))},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be);var Ke=this.rotatePoint({x:this.left,y:this.top}),Ne=this.unrotatePoint({x:Ke.x*Se,y:Ke.y*Be});this.left=Ne.x,this.top=Ne.y,this.width=this.width*Se,this.height=this.height*Be,this.adjustControlBox()},Ae}(ve),he=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.fillColor="transparent",Ne.strokeColor="transparent",Ne.strokeWidth=0,Ne.strokeDasharray="",Ne.opacity=1,Ne.setStrokeColor=Ne.setStrokeColor.bind(Ne),Ne.setFillColor=Ne.setFillColor.bind(Ne),Ne.setStrokeWidth=Ne.setStrokeWidth.bind(Ne),Ne.setStrokeDasharray=Ne.setStrokeDasharray.bind(Ne),Ne.createVisual=Ne.createVisual.bind(Ne),Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.visual)},Ae.prototype.createVisual=function(){this.visual=te.createRect(1,1,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.state==="new"&&(this.createVisual(),this.moveVisual(Se),this._state="creating")},Ae.prototype.manipulate=function(Se){We.prototype.manipulate.call(this,Se)},Ae.prototype.resize=function(Se){We.prototype.resize.call(this,Se),this.setSize()},Ae.prototype.setSize=function(){We.prototype.setSize.call(this),te.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]])},Ae.prototype.pointerUp=function(Se){We.prototype.pointerUp.call(this,Se),this.setSize()},Ae.prototype.setStrokeColor=function(Se){this.strokeColor=Se,this.visual&&te.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(Se),this.stateChanged()},Ae.prototype.setFillColor=function(Se){this.fillColor=Se,this.visual&&te.setAttributes(this.visual,[["fill",this.fillColor]]),this.stateChanged()},Ae.prototype.setStrokeWidth=function(Se){this.strokeWidth=Se,this.visual&&te.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},Ae.prototype.setStrokeDasharray=function(Se){this.strokeDasharray=Se,this.visual&&te.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Ae.prototype.getState=function(){return Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},We.prototype.getState.call(this))},Ae.prototype.restoreState=function(Se){var Be=Se;this.fillColor=Be.fillColor,this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.opacity=Be.opacity,this.createVisual(),We.prototype.restoreState.call(this,Se),this.setSize()},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.setSize()},Ae.title="Rectangle marker",Ae}(_e),pe=function(We){function Ae(Se,Be,Ke,Ne){var De=We.call(this,Se,Ne||'<svg viewBox="0 0 24 24"><path d="M3 17h18v-2H3v2m0 3h18v-1H3v1m0-7h18v-3H3v3m0-9v4h18V4H3z"/></svg>')||this;return De.widths=[],De.widthBoxes=[],De.widths=Be,De.currentWidth=Ke,De.setCurrentWidth=De.setCurrentWidth.bind(De),De}return ie(Ae,We),Ae.prototype.getUi=function(){var Se=this,Be=document.createElement("div");return Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2",this.widths.forEach(function(Ke){var Ne=document.createElement("div");Ne.style.display="flex",Ne.style.flexGrow="2",Ne.style.alignItems="center",Ne.style.justifyContent="space-between",Ne.style.padding="5px",Ne.style.borderWidth="2px",Ne.style.borderStyle="solid",Ne.style.borderColor=Ke===Se.currentWidth?Se.uiStyleSettings.toolboxAccentColor:"transparent",Ne.addEventListener("click",function(){Se.setCurrentWidth(Ke,Ne)}),Be.appendChild(Ne);var De=document.createElement("div");De.innerText=Ke.toString(),De.style.marginRight="5px",Ne.appendChild(De);var we=document.createElement("div");we.style.minHeight="20px",we.style.flexGrow="2",we.style.display="flex",we.style.alignItems="center";var Le=document.createElement("hr");Le.style.minWidth="20px",Le.style.border="0px",Le.style.borderTop=Ke+"px solid "+Se.uiStyleSettings.toolboxColor,Le.style.flexGrow="2",we.appendChild(Le),Ne.appendChild(we),Se.widthBoxes.push(Ne)}),Be},Ae.prototype.setCurrentWidth=function(Se,Be){var Ke=this;this.currentWidth=Se,this.widthBoxes.forEach(function(Ne){Ne.style.borderColor=Ne===Be?Ke.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onWidthChanged&&this.onWidthChanged(this.currentWidth)},Ae}(ae),ke=function(We){function Ae(Se,Be,Ke,Ne){var De=We.call(this,Se,Ne||'<svg viewBox="0 0 24 24"><path d="M3 16h5v-2H3v2m6.5 0h5v-2h-5v2m6.5 0h5v-2h-5v2M3 20h2v-2H3v2m4 0h2v-2H7v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2M3 12h8v-2H3v2m10 0h8v-2h-8v2M3 4v4h18V4H3z"/></svg>')||this;return De.styles=[],De.styleBoxes=[],De.styles=Be,De.currentStyle=Ke,De.setCurrentStyle=De.setCurrentStyle.bind(De),De}return ie(Ae,We),Ae.prototype.getUi=function(){var Se=this,Be=document.createElement("div");return Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2",this.styles.forEach(function(Ke){var Ne=document.createElement("div");Ne.style.display="flex",Ne.style.alignItems="center",Ne.style.justifyContent="space-between",Ne.style.padding="5px",Ne.style.borderWidth="2px",Ne.style.borderStyle="solid",Ne.style.overflow="hidden",Ne.style.maxWidth=100/Se.styles.length-5+"%",Ne.style.borderColor=Ke===Se.currentStyle?Se.uiStyleSettings.toolboxAccentColor:"transparent",Ne.addEventListener("click",function(){Se.setCurrentStyle(Ke,Ne)}),Be.appendChild(Ne);var De=document.createElement("div");De.style.minHeight="20px",De.style.flexGrow="2",De.style.overflow="hidden";var we=`<svg width="100" height="20">
|
|
|
<line x1="0" y1="10" x2="100" y2="10" stroke="`+Se.uiStyleSettings.toolboxColor+'" stroke-width="3" '+(Ke!==""?'stroke-dasharray="'+Ke+'"':"")+` />
|
|
|
</svg>`;De.innerHTML=we,Ne.appendChild(De),Se.styleBoxes.push(Ne)}),Be},Ae.prototype.setCurrentStyle=function(Se,Be){var Ke=this;this.currentStyle=Se,this.styleBoxes.forEach(function(Ne){Ne.style.borderColor=Ne===Be?Ke.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onStyleChanged&&this.onStyleChanged(this.currentStyle)},Ae}(ae),Te=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.strokeColor=Ke.defaultColor,Ne.strokeWidth=Ke.defaultStrokeWidth,Ne.strokeDasharray=Ke.defaultStrokeDasharray,Ne.strokePanel=new oe("Line color",Ke.defaultColorSet,Ke.defaultColor),Ne.strokePanel.onColorChanged=Ne.setStrokeColor,Ne.strokeWidthPanel=new pe("Line width",Ke.defaultStrokeWidths,Ke.defaultStrokeWidth),Ne.strokeWidthPanel.onWidthChanged=Ne.setStrokeWidth,Ne.strokeStylePanel=new ke("Line style",Ke.defaultStrokeDasharrays,Ke.defaultStrokeDasharray),Ne.strokeStylePanel.onStyleChanged=Ne.setStrokeDasharray,Ne}return ie(Ae,We),Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=We.prototype.getState.call(this);return Se.typeName=Ae.typeName,Se},Ae.typeName="FrameMarker",Ae.title="Frame marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4m14 11H6V8h12v9z"/></svg>',Ae}(he),Ee=function(){this.defaultColorSet=["#EF4444","#10B981","#2563EB","#FFFF00","#7C3AED","#F472B6","#000000","#FFFFFF"],this.defaultColor=this.defaultColorSet[0],this.defaultFillColor=this.defaultColorSet[0],this.defaultStrokeColor=this.defaultColorSet[7],this.defaultHighlightColor=this.defaultColorSet[3],this.defaultStrokeWidth=3,this.defaultStrokeDasharray="",this.defaultHighlightOpacity=.5,this.defaultFontFamily="Helvetica, Arial, sans-serif",this.defaultStrokeWidths=[1,2,3,5,10],this.defaultStrokeDasharrays=["","3","12 3","9 6 3 6"],this.defaultOpacitySteps=[.1,.25,.5,.75,1],this.displayMode="inline",this.defaultFontFamilies=['Times, "Times New Roman", serif',"Helvetica, Arial, sans-serif",'Courier, "Courier New", monospace',"cursive","fantasy"],this.popupMargin=30,this.newFreehandMarkerOnPointerUp=!1,this.defaultColorsFollowCurrentColors=!1,this.freehandPixelRatio=1,this.disableRotation=!1,this.defaultCaptionFontSize="1rem",this.defaultCaptionText="Text"},Oe=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.x1=0,Ne.y1=0,Ne.x2=0,Ne.y2=0,Ne.defaultLength=50,Ne.manipulationStartX=0,Ne.manipulationStartY=0,Ne.manipulationStartX1=0,Ne.manipulationStartY1=0,Ne.manipulationStartX2=0,Ne.manipulationStartY2=0,Ne.setupControlBox(),Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!!We.prototype.ownsTarget.call(this,Se)||!(!this.grip1.ownsTarget(Se)&&!this.grip2.ownsTarget(Se))},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.manipulationStartX=Se.x,this.manipulationStartY=Se.y,this.state==="new"&&(this.x1=Se.x,this.y1=Se.y,this.x2=Se.x,this.y2=Se.y),this.manipulationStartX1=this.x1,this.manipulationStartY1=this.y1,this.manipulationStartX2=this.x2,this.manipulationStartY2=this.y2,this.state!=="new"&&(this.select(),this.grip1.ownsTarget(Be)?this.activeGrip=this.grip1:this.grip2.ownsTarget(Be)?this.activeGrip=this.grip2:this.activeGrip=void 0,this.activeGrip?this._state="resize":this._state="move")},Ae.prototype.pointerUp=function(Se){var Be=this.state;We.prototype.pointerUp.call(this,Se),this.state==="creating"&&Math.abs(this.x1-this.x2)<10&&Math.abs(this.y1-this.y2)<10?(this.x2=this.x1+this.defaultLength,this.adjustVisual(),this.adjustControlBox()):this.manipulate(Se),this._state="select",Be==="creating"&&this.onMarkerCreated&&this.onMarkerCreated(this)},Ae.prototype.adjustVisual=function(){},Ae.prototype.manipulate=function(Se){this.state==="creating"?this.resize(Se):this.state==="move"?(this.x1=this.manipulationStartX1+Se.x-this.manipulationStartX,this.y1=this.manipulationStartY1+Se.y-this.manipulationStartY,this.x2=this.manipulationStartX2+Se.x-this.manipulationStartX,this.y2=this.manipulationStartY2+Se.y-this.manipulationStartY,this.adjustVisual(),this.adjustControlBox()):this.state==="resize"&&this.resize(Se)},Ae.prototype.resize=function(Se){switch(this.activeGrip){case this.grip1:this.x1=Se.x,this.y1=Se.y;break;case this.grip2:case void 0:this.x2=Se.x,this.y2=Se.y}this.adjustVisual(),this.adjustControlBox()},Ae.prototype.select=function(){We.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},Ae.prototype.deselect=function(){We.prototype.deselect.call(this),this.controlBox.style.display="none"},Ae.prototype.setupControlBox=function(){this.controlBox=te.createGroup(),this.container.appendChild(this.controlBox),this.addControlGrips(),this.controlBox.style.display="none"},Ae.prototype.adjustControlBox=function(){this.positionGrips()},Ae.prototype.addControlGrips=function(){this.grip1=this.createGrip(),this.grip2=this.createGrip(),this.positionGrips()},Ae.prototype.createGrip=function(){var Se=new me;return Se.visual.transform.baseVal.appendItem(te.createTransform()),this.controlBox.appendChild(Se.visual),Se},Ae.prototype.positionGrips=function(){var Se=this.grip1.GRIP_SIZE;this.positionGrip(this.grip1.visual,this.x1-Se/2,this.y1-Se/2),this.positionGrip(this.grip2.visual,this.x2-Se/2,this.y2-Se/2)},Ae.prototype.positionGrip=function(Se,Be,Ke){var Ne=Se.transform.baseVal.getItem(0);Ne.setTranslate(Be,Ke),Se.transform.baseVal.replaceItem(Ne,0)},Ae.prototype.getState=function(){return Object.assign({x1:this.x1,y1:this.y1,x2:this.x2,y2:this.y2},We.prototype.getState.call(this))},Ae.prototype.restoreState=function(Se){We.prototype.restoreState.call(this,Se);var Be=Se;this.x1=Be.x1,this.y1=Be.y1,this.x2=Be.x2,this.y2=Be.y2},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.x1=this.x1*Se,this.y1=this.y1*Be,this.x2=this.x2*Se,this.y2=this.y2*Be,this.adjustVisual(),this.adjustControlBox()},Ae}(ve),je=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.strokeColor="transparent",Ne.strokeWidth=0,Ne.strokeDasharray="",Ne.setStrokeColor=Ne.setStrokeColor.bind(Ne),Ne.setStrokeWidth=Ne.setStrokeWidth.bind(Ne),Ne.setStrokeDasharray=Ne.setStrokeDasharray.bind(Ne),Ne.strokeColor=Ke.defaultColor,Ne.strokeWidth=Ke.defaultStrokeWidth,Ne.strokeDasharray=Ke.defaultStrokeDasharray,Ne.strokePanel=new oe("Line color",Ke.defaultColorSet,Ke.defaultColor),Ne.strokePanel.onColorChanged=Ne.setStrokeColor,Ne.strokeWidthPanel=new pe("Line width",Ke.defaultStrokeWidths,Ke.defaultStrokeWidth),Ne.strokeWidthPanel.onWidthChanged=Ne.setStrokeWidth,Ne.strokeStylePanel=new ke("Line style",Ke.defaultStrokeDasharrays,Ke.defaultStrokeDasharray),Ne.strokeStylePanel.onStyleChanged=Ne.setStrokeDasharray,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.visual&&Se!==this.selectorLine&&Se!==this.visibleLine)},Ae.prototype.createVisual=function(){this.visual=te.createGroup(),this.selectorLine=te.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()]]),this.visibleLine=te.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.visual.appendChild(this.selectorLine),this.visual.appendChild(this.visibleLine),this.addMarkerVisualToContainer(this.visual)},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.state==="new"&&(this.createVisual(),this.adjustVisual(),this._state="creating")},Ae.prototype.adjustVisual=function(){this.selectorLine&&this.visibleLine&&(this.selectorLine.setAttribute("x1",this.x1.toString()),this.selectorLine.setAttribute("y1",this.y1.toString()),this.selectorLine.setAttribute("x2",this.x2.toString()),this.selectorLine.setAttribute("y2",this.y2.toString()),this.visibleLine.setAttribute("x1",this.x1.toString()),this.visibleLine.setAttribute("y1",this.y1.toString()),this.visibleLine.setAttribute("x2",this.x2.toString()),this.visibleLine.setAttribute("y2",this.y2.toString()),te.setAttributes(this.visibleLine,[["stroke",this.strokeColor]]),te.setAttributes(this.visibleLine,[["stroke-width",this.strokeWidth.toString()]]),te.setAttributes(this.visibleLine,[["stroke-dasharray",this.strokeDasharray.toString()]]))},Ae.prototype.setStrokeColor=function(Se){this.strokeColor=Se,this.adjustVisual(),this.colorChanged(Se)},Ae.prototype.setStrokeWidth=function(Se){this.strokeWidth=Se,this.adjustVisual()},Ae.prototype.setStrokeDasharray=function(Se){this.strokeDasharray=Se,this.adjustVisual(),this.stateChanged()},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){We.prototype.restoreState.call(this,Se);var Be=Se;this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.createVisual(),this.adjustVisual()},Ae.typeName="LineMarker",Ae.title="Line marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M19 13H5v-2h14v2z"/></svg>',Ae}(Oe),Pe=function(We){function Ae(Se,Be,Ke,Ne){var De=We.call(this,Se,Ne||'<svg viewBox="0 0 24 24"><path d="M17 8h3v12h1v1h-4v-1h1v-3h-4l-1.5 3H14v1h-4v-1h1l6-12m1 1l-3.5 7H18V9M5 3h5c1.11 0 2 .89 2 2v11H9v-5H6v5H3V5c0-1.11.89-2 2-2m1 2v4h3V5H6z"/></svg>')||this;return De.fonts=[],De.fontBoxes=[],De.fonts=Be,De.currentFont=Ke,De.setCurrentFont=De.setCurrentFont.bind(De),De}return ie(Ae,We),Ae.prototype.getUi=function(){var Se=this,Be=document.createElement("div");return Be.style.overflow="hidden",Be.style.flexGrow="2",this.fonts.forEach(function(Ke){var Ne=document.createElement("div");Ne.style.display="inline-block",Ne.style.alignItems="center",Ne.style.justifyContent="space-between",Ne.style.padding="5px",Ne.style.borderWidth="2px",Ne.style.borderStyle="solid",Ne.style.overflow="hidden",Ne.style.maxWidth=100/Se.fonts.length-5+"%",Ne.style.borderColor=Ke===Se.currentFont?Se.uiStyleSettings.toolboxAccentColor:"transparent",Ne.addEventListener("click",function(){Se.setCurrentFont(Ke,Ne)}),Be.appendChild(Ne);var De=document.createElement("div");De.style.display="flex",De.style.minHeight="20px",De.style.flexGrow="2",De.style.fontFamily=Ke,De.style.overflow="hidden";var we=document.createElement("div");we.style.whiteSpace="nowrap",we.style.overflow="hidden",we.style.textOverflow="ellipsis",we.innerHTML="The quick brown fox jumps over the lazy dog",De.appendChild(we),Ne.appendChild(De),Se.fontBoxes.push(Ne)}),Be},Ae.prototype.setCurrentFont=function(Se,Be){var Ke=this;this.currentFont=Se,this.fontBoxes.forEach(function(Ne){Ne.style.borderColor=Ne===Be?Ke.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onFontChanged&&this.onFontChanged(this.currentFont)},Ae}(ae),Qe=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.color="transparent",Ne.padding=5,Ne.DEFAULT_TEXT="\u8BF7\u8F93\u5165\u6587\u672C",Ne.text=Ne.DEFAULT_TEXT,Ne.isMoved=!1,Ne.color=Ke.defaultColor,Ne.fontFamily=Ke.defaultFontFamily,Ne.defaultSize={x:100,y:30},Ne.setColor=Ne.setColor.bind(Ne),Ne.setFont=Ne.setFont.bind(Ne),Ne.renderText=Ne.renderText.bind(Ne),Ne.sizeText=Ne.sizeText.bind(Ne),Ne.textEditDivClicked=Ne.textEditDivClicked.bind(Ne),Ne.showTextEditor=Ne.showTextEditor.bind(Ne),Ne.setSize=Ne.setSize.bind(Ne),Ne.positionTextEditor=Ne.positionTextEditor.bind(Ne),Ne.colorPanel=new oe("Color",Ke.defaultColorSet,Ke.defaultColor),Ne.colorPanel.onColorChanged=Ne.setColor,Ne.fontFamilyPanel=new Pe("Font",Ke.defaultFontFamilies,Ke.defaultFontFamily),Ne.fontFamilyPanel.onFontChanged=Ne.setFont,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){if(We.prototype.ownsTarget.call(this,Se)||Se===this.visual||Se===this.textElement||Se===this.bgRectangle)return!0;var Be=!1;return this.textElement.childNodes.forEach(function(Ke){Ke===Se&&(Be=!0)}),Be},Ae.prototype.createVisual=function(){this.visual=te.createGroup(),this.bgRectangle=te.createRect(1,1,[["fill","transparent"]]),this.visual.appendChild(this.bgRectangle),this.textElement=te.createText([["fill",this.color],["font-family",this.fontFamily],["font-size","16px"],["x","0"],["y","0"]]),this.textElement.transform.baseVal.appendItem(te.createTransform()),this.textElement.transform.baseVal.appendItem(te.createTransform()),this.visual.appendChild(this.textElement),this.addMarkerVisualToContainer(this.visual),this.renderText()},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.isMoved=!1,this.pointerDownPoint=Se,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(Se),this._state="creating")},Ae.prototype.renderText=function(){var Se=this;if(this.textElement){for(;this.textElement.lastChild;)this.textElement.removeChild(this.textElement.lastChild);this.text.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/).forEach(function(Be){Se.textElement.appendChild(te.createTSpan(Be.trim()===""?" ":Be.trim(),[["x","0"],["dy","1.2em"]]))}),setTimeout(this.sizeText,10)}},Ae.prototype.getTextScale=function(){var Se=this.textElement.getBBox(),Be=1;if(Se.width>0&&Se.height>0){var Ke=(1*this.width-this.width*this.padding*2/100)/Se.width,Ne=(1*this.height-this.height*this.padding*2/100)/Se.height;Be=Math.min(Ke,Ne)}return Be},Ae.prototype.getTextPosition=function(Se){var Be=this.textElement.getBBox(),Ke=0,Ne=0;return Be.width>0&&Be.height>0&&(Ke=(this.width-Be.width*Se)/2,Ne=this.height/2-Be.height*Se/2),{x:Ke,y:Ne}},Ae.prototype.sizeText=function(){var Se=this.textElement.getBBox(),Be=this.getTextScale(),Ke=this.getTextPosition(Be);Ke.y-=Se.y*Be,navigator.userAgent.indexOf("Edge/")>-1?this.textElement.style.transform="translate("+Ke.x+"px, "+Ke.y+"px) scale("+Be+", "+Be+")":(this.textElement.transform.baseVal.getItem(0).setTranslate(Ke.x,Ke.y),this.textElement.transform.baseVal.getItem(1).setScale(Be,Be))},Ae.prototype.manipulate=function(Se){We.prototype.manipulate.call(this,Se),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(Se.x-this.pointerDownPoint.x)>5||Math.abs(Se.y-this.pointerDownPoint.y)>5)},Ae.prototype.resize=function(Se){We.prototype.resize.call(this,Se),this.isMoved=!0,this.setSize(),this.sizeText()},Ae.prototype.setSize=function(){We.prototype.setSize.call(this),this.visual&&this.bgRectangle&&(te.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),te.setAttributes(this.bgRectangle,[["width",this.width.toString()],["height",this.height.toString()]]))},Ae.prototype.pointerUp=function(Se){var Be=this.state;Be==="creating"&&(this._suppressMarkerCreateEvent=!0),We.prototype.pointerUp.call(this,Se),this.setSize(),(Be==="creating"||!this.isMoved&&Date.now()-this.pointerDownTimestamp>500)&&this.showTextEditor(),this.pointerDownPoint=void 0},Ae.prototype.showTextEditor=function(){var Se=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditor=document.createElement("div"),this.textEditor.style.position="absolute",this.textEditor.style.fontFamily=this.fontFamily,this.textEditor.style.lineHeight="1em",this.textEditor.innerText=this.text,this.textEditor.contentEditable="true",this.textEditor.style.color=this.color,this.textEditor.style.whiteSpace="pre",this.positionTextEditor(),this.textEditor.addEventListener("pointerup",function(Be){Be.stopPropagation()}),this.textEditor.addEventListener("input",function(){for(var Be=Number.parseFloat(Se.textEditor.style.fontSize);Se.textEditor.clientWidth>=Number.parseInt(Se.textEditor.style.maxWidth)&&Be>.9;)Be-=.1,Se.textEditor.style.fontSize=Math.max(Be,.9)+"em"}),this.textEditor.addEventListener("keyup",function(Be){Be.cancelBubble=!0}),this.textEditor.addEventListener("paste",function(Be){if(Be.clipboardData){var Ke=Be.clipboardData.getData("text"),Ne=window.getSelection();if(!Ne.rangeCount)return!1;Ne.deleteFromDocument(),Ne.getRangeAt(0).insertNode(document.createTextNode(Ke)),Be.preventDefault()}}),this.textEditDiv.addEventListener("pointerup",function(){Se.textEditDivClicked(Se.textEditor.innerText)}),this.textEditDiv.appendChild(this.textEditor),this.overlayContainer.appendChild(this.textEditDiv),this.hideVisual(),this.textEditor.focus(),document.execCommand("selectAll")},Ae.prototype.positionTextEditor=function(){if(this.state==="edit")if(this.textEditor===void 0)this.showTextEditor();else{this.textElement.style.display="";var Se=this.getTextScale(),Be=this.rotatePoint({x:this.left+this.width/2,y:this.top+this.height/2}),Ke=this.textElement.getBBox(),Ne={x:Ke.width*Se,y:Ke.height*Se};Be.x-=Ne.x/2,Be.y-=Ne.y/2,this.textEditor.style.top=Be.y+"px",this.textEditor.style.left=Be.x+"px",this.textEditor.style.maxWidth=this.overlayContainer.offsetWidth-Be.x+"px",this.textEditor.style.fontSize=Math.max(16*Se,12)+"px",this.textElement.style.display="none"}},Ae.prototype.textEditDivClicked=function(Se){this.text=Se.trim(),this.overlayContainer.innerHTML="",this.renderText(),this.showVisual(),this._suppressMarkerCreateEvent&&(this._suppressMarkerCreateEvent=!1,this.onMarkerCreated&&this.onMarkerCreated(this)),this.stateChanged()},Ae.prototype.select=function(){We.prototype.select.call(this),this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText)},Ae.prototype.deselect=function(){this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText),We.prototype.deselect.call(this)},Ae.prototype.dblClick=function(Se,Be){We.prototype.dblClick.call(this,Se,Be),this.showTextEditor()},Ae.prototype.setColor=function(Se){this.textElement&&te.setAttributes(this.textElement,[["fill",Se]]),this.color=Se,this.textEditor&&(this.textEditor.style.color=this.color),this.colorChanged(Se)},Ae.prototype.setFont=function(Se){this.textElement&&te.setAttributes(this.textElement,[["font-family",Se]]),this.fontFamily=Se,this.textEditor&&(this.textEditor.style.fontFamily=this.fontFamily),this.renderText(),this.stateChanged()},Ae.prototype.hideVisual=function(){this.textElement.style.display="none",this.hideControlBox()},Ae.prototype.showVisual=function(){this.state==="edit"&&(this._state="select"),this.textElement.style.display="",this.showControlBox()},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({color:this.color,fontFamily:this.fontFamily,padding:this.padding,text:this.text},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){var Be=Se;this.color=Be.color,this.fontFamily=Be.fontFamily,this.padding=Be.padding,this.text=Be.text,this.createVisual(),We.prototype.restoreState.call(this,Se),this.setSize()},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.setSize(),this.sizeText(),this.positionTextEditor()},Ae.typeName="TextMarker",Ae.title="Text marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M9.6 14L12 7.7l2.4 6.3M11 5L5.5 19h2.2l1.1-3H15l1.1 3h2.2L13 5h-2z"/></svg>',Ae}(_e),Xe=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.color="transparent",Ne.lineWidth=3,Ne.drawing=!1,Ne.pixelRatio=1,Ne.color=Ke.defaultColor,Ne.lineWidth=Ke.defaultStrokeWidth,Ne.pixelRatio=Ke.freehandPixelRatio,Ne.setColor=Ne.setColor.bind(Ne),Ne.addCanvas=Ne.addCanvas.bind(Ne),Ne.finishCreation=Ne.finishCreation.bind(Ne),Ne.setLineWidth=Ne.setLineWidth.bind(Ne),Ne.colorPanel=new oe("Color",Ke.defaultColorSet,Ke.defaultColor),Ne.colorPanel.onColorChanged=Ne.setColor,Ne.lineWidthPanel=new pe("Line width",Ke.defaultStrokeWidths,Ke.defaultStrokeWidth),Ne.lineWidthPanel.onWidthChanged=Ne.setLineWidth,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.visual&&Se!==this.drawingImage)},Ae.prototype.createVisual=function(){this.visual=te.createGroup(),this.drawingImage=te.createImage(),this.visual.appendChild(this.drawingImage);var Se=te.createTransform();this.visual.transform.baseVal.appendItem(Se),this.addMarkerVisualToContainer(this.visual)},Ae.prototype.pointerDown=function(Se,Be){this.state==="new"&&(this.addCanvas(),this.createVisual(),this._state="creating"),this.state==="creating"?(this.canvasContext.strokeStyle=this.color,this.canvasContext.lineWidth=this.lineWidth,this.canvasContext.beginPath(),this.canvasContext.moveTo(Se.x,Se.y),this.drawing=!0):We.prototype.pointerDown.call(this,Se,Be)},Ae.prototype.manipulate=function(Se){this.state==="creating"?this.drawing&&(this.canvasContext.lineTo(Se.x,Se.y),this.canvasContext.stroke()):We.prototype.manipulate.call(this,Se)},Ae.prototype.resize=function(Se){We.prototype.resize.call(this,Se),te.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),te.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]])},Ae.prototype.pointerUp=function(Se){this._state==="creating"?this.drawing&&(this.canvasContext.closePath(),this.drawing=!1,this.globalSettings.newFreehandMarkerOnPointerUp&&this.finishCreation()):We.prototype.pointerUp.call(this,Se)},Ae.prototype.addCanvas=function(){this.overlayContainer.innerHTML="",this.canvasElement=document.createElement("canvas"),this.canvasElement.width=this.overlayContainer.clientWidth*this.pixelRatio,this.canvasElement.height=this.overlayContainer.clientHeight*this.pixelRatio,this.canvasContext=this.canvasElement.getContext("2d"),this.canvasContext.scale(this.pixelRatio,this.pixelRatio),this.overlayContainer.appendChild(this.canvasElement)},Ae.prototype.select=function(){this.state==="creating"&&this.finishCreation(),We.prototype.select.call(this)},Ae.prototype.deselect=function(){this.state==="creating"&&this.finishCreation(),We.prototype.deselect.call(this)},Ae.prototype.finishCreation=function(){for(var Se=this.canvasContext.getImageData(0,0,this.canvasElement.width,this.canvasElement.height),Be=[this.canvasElement.width+1,this.canvasElement.height+1,-1,-1],Ke=Be[0],Ne=Be[1],De=Be[2],we=Be[3],Le=!1,Ue=0;Ue<this.canvasElement.height;Ue++)for(var Me=0;Me<this.canvasElement.width;Me++)Se.data[Ue*this.canvasElement.width*4+4*Me+3]>0&&(Le=!0,Ue<Ne&&(Ne=Ue),Me<Ke&&(Ke=Me),Ue>we&&(we=Ue),Me>De&&(De=Me));if(Le){this.left=Ke/this.pixelRatio,this.top=Ne/this.pixelRatio,this.width=(De-Ke)/this.pixelRatio,this.height=(we-Ne)/this.pixelRatio;var Re=document.createElement("canvas");Re.width=De-Ke,Re.height=we-Ne,Re.getContext("2d").putImageData(this.canvasContext.getImageData(Ke,Ne,De-Ke,we-Ne),0,0),this.drawingImgUrl=Re.toDataURL("image/png"),this.setDrawingImage(),this._state="select",this.onMarkerCreated&&this.onMarkerCreated(this)}this.overlayContainer.innerHTML=""},Ae.prototype.setDrawingImage=function(){te.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]]),te.setAttributes(this.drawingImage,[["href",this.drawingImgUrl]]),this.moveVisual({x:this.left,y:this.top})},Ae.prototype.setColor=function(Se){this.color=Se,this.colorChanged(Se)},Ae.prototype.setLineWidth=function(Se){this.lineWidth=Se},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return this.state==="new"||this.state==="creating"?[this.colorPanel,this.lineWidthPanel]:[]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({drawingImgUrl:this.drawingImgUrl},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){this.createVisual(),We.prototype.restoreState.call(this,Se),this.drawingImgUrl=Se.drawingImgUrl,this.setDrawingImage()},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.setDrawingImage()},Ae.typeName="FreehandMarker",Ae.title="Freehand marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M9.75 20.85c1.78-.7 1.39-2.63.49-3.85-.89-1.25-2.12-2.11-3.36-2.94A9.817 9.817 0 014.54 12c-.28-.33-.85-.94-.27-1.06.59-.12 1.61.46 2.13.68.91.38 1.81.82 2.65 1.34l1.01-1.7C8.5 10.23 6.5 9.32 4.64 9.05c-1.06-.16-2.18.06-2.54 1.21-.32.99.19 1.99.77 2.77 1.37 1.83 3.5 2.71 5.09 4.29.34.33.75.72.95 1.18.21.44.16.47-.31.47-1.24 0-2.79-.97-3.8-1.61l-1.01 1.7c1.53.94 4.09 2.41 5.96 1.79m11.09-15.6c.22-.22.22-.58 0-.79l-1.3-1.3a.562.562 0 00-.78 0l-1.02 1.02 2.08 2.08M11 10.92V13h2.08l6.15-6.15-2.08-2.08L11 10.92z"/></svg>',Ae}(_e),ot=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Ke||'<svg viewBox="0 0 24 24"><path d="M8 14v4l-6-6 6-6v4h8V6l6 6-6 6v-4H8z"/></svg>')||this;return Ne.typeBoxes=[],Ne.currentType=Be,Ne.setCurrentType=Ne.setCurrentType.bind(Ne),Ne}return ie(Ae,We),Ae.prototype.getUi=function(){var Se=this,Be=document.createElement("div");Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2";for(var Ke=function(we){var Le="both";switch(we){case 0:Le="both";break;case 1:Le="start";break;case 2:Le="end";break;case 3:Le="none"}var Ue=document.createElement("div");if(Ue.style.display="flex",Ue.style.flexGrow="2",Ue.style.alignItems="center",Ue.style.justifyContent="space-between",Ue.style.padding="5px",Ue.style.borderWidth="2px",Ue.style.borderStyle="solid",Ue.style.borderColor=Le===Ne.currentType?Ne.uiStyleSettings.toolboxAccentColor:"transparent",Ue.addEventListener("click",function(){Se.setCurrentType(Le,Ue)}),Be.appendChild(Ue),Le==="both"||Le==="start"){var Me=document.createElement("div");Me.style.display="flex",Me.style.alignItems="center",Me.style.minHeight="20px",Me.innerHTML=`<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">
|
|
|
<polygon points="0,5 10,0 10,10" fill="`+(Ne.uiStyleSettings!==void 0?Ne.uiStyleSettings.toolboxColor:"#eeeeee")+`" />
|
|
|
</svg>`,Me.style.marginLeft="5px",Ue.appendChild(Me)}var Re=document.createElement("div");Re.style.display="flex",Re.style.alignItems="center",Re.style.minHeight="20px",Re.style.flexGrow="2";var tt=document.createElement("hr");if(tt.style.minWidth="20px",tt.style.border="0px",tt.style.borderTop="3px solid "+(Ne.uiStyleSettings!==void 0?Ne.uiStyleSettings.toolboxColor:"#eeeeee"),tt.style.flexGrow="2",Re.appendChild(tt),Ue.appendChild(Re),Le==="both"||Le==="end"){var lt=document.createElement("div");lt.style.display="flex",lt.style.alignItems="center",lt.style.minHeight="20px",lt.innerHTML=`<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">
|
|
|
<polygon points="0,0 10,5 0,10" fill="`+(Ne.uiStyleSettings!==void 0?Ne.uiStyleSettings.toolboxColor:"#eeeeee")+`" />
|
|
|
</svg>`,lt.style.marginRight="5px",Ue.appendChild(lt)}Ne.typeBoxes.push(Ue)},Ne=this,De=0;De<4;De++)Ke(De);return Be},Ae.prototype.setCurrentType=function(Se,Be){var Ke=this;this.currentType=Se,this.typeBoxes.forEach(function(Ne){Ne.style.borderColor=Ne===Be?Ke.uiStyleSettings!==void 0?Ke.uiStyleSettings.toolboxAccentColor:"#3080c3":"transparent"}),this.onArrowTypeChanged&&this.onArrowTypeChanged(this.currentType)},Ae}(ae),He=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.arrowType="end",Ne.arrowBaseHeight=10,Ne.arrowBaseWidth=10,Ne.getArrowPoints=Ne.getArrowPoints.bind(Ne),Ne.setArrowType=Ne.setArrowType.bind(Ne),Ne.arrowTypePanel=new ot("Arrow type","end"),Ne.arrowTypePanel.onArrowTypeChanged=Ne.setArrowType,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.arrow1&&Se!==this.arrow2)},Ae.prototype.getArrowPoints=function(Se,Be){var Ke=this.arrowBaseWidth+2*this.strokeWidth,Ne=this.arrowBaseHeight+2*this.strokeWidth;return Se-Ke/2+","+(Be+Ne/2)+" "+Se+","+(Be-Ne/2)+" "+(Se+Ke/2)+","+(Be+Ne/2)},Ae.prototype.createTips=function(){this.arrow1=te.createPolygon(this.getArrowPoints(this.x1,this.y1),[["fill",this.strokeColor]]),this.arrow1.transform.baseVal.appendItem(te.createTransform()),this.visual.appendChild(this.arrow1),this.arrow2=te.createPolygon(this.getArrowPoints(this.x2,this.y2),[["fill",this.strokeColor]]),this.arrow2.transform.baseVal.appendItem(te.createTransform()),this.visual.appendChild(this.arrow2)},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.state==="creating"&&this.createTips()},Ae.prototype.adjustVisual=function(){if(We.prototype.adjustVisual.call(this),this.arrow1&&this.arrow2){this.arrow1.style.display=this.arrowType==="both"||this.arrowType==="start"?"":"none",this.arrow2.style.display=this.arrowType==="both"||this.arrowType==="end"?"":"none",te.setAttributes(this.arrow1,[["points",this.getArrowPoints(this.x1,this.y1)],["fill",this.strokeColor]]),te.setAttributes(this.arrow2,[["points",this.getArrowPoints(this.x2,this.y2)],["fill",this.strokeColor]]);var Se=0;Math.abs(this.x1-this.x2)>.1&&(Se=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2));var Be=this.arrow1.transform.baseVal.getItem(0);Be.setRotate(Se,this.x1,this.y1),this.arrow1.transform.baseVal.replaceItem(Be,0);var Ke=this.arrow2.transform.baseVal.getItem(0);Ke.setRotate(Se+180,this.x2,this.y2),this.arrow2.transform.baseVal.replaceItem(Ke,0)}},Ae.prototype.setArrowType=function(Se){this.arrowType=Se,this.adjustVisual(),this.stateChanged()},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel,this.arrowTypePanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({arrowType:this.arrowType},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){We.prototype.restoreState.call(this,Se);var Be=Se;this.arrowType=Be.arrowType,this.createTips(),this.adjustVisual()},Ae.typeName="ArrowMarker",Ae.title="Arrow marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M19 6.41L17.59 5 7 15.59V9H5v10h10v-2H8.41L19 6.41z"/></svg>',Ae}(je),rt=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.fillColor=Ke.defaultFillColor,Ne.strokeWidth=0,Ne.fillPanel=new oe("Color",Ke.defaultColorSet,Ke.defaultFillColor),Ne.fillPanel.onColorChanged=Ne.setFillColor,Ne}return ie(Ae,We),Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.fillPanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=We.prototype.getState.call(this);return Se.typeName=Ae.typeName,Se},Ae.typeName="CoverMarker",Ae.title="Cover marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4z"/></svg>',Ae}(he),Ye=function(We){function Ae(Se,Be,Ke,Ne){var De=We.call(this,Se,Ne||'<svg viewBox="0 0 24 24"><path d="M17.66 8L12 2.35 6.34 8A8.02 8.02 0 004 13.64c0 2 .78 4.11 2.34 5.67a7.99 7.99 0 0011.32 0c1.56-1.56 2.34-3.67 2.34-5.67S19.22 9.56 17.66 8M6 14c0-2 .62-3.27 1.76-4.4L12 5.27l4.24 4.38C17.38 10.77 18 12 18 14H6z"/></svg>')||this;return De.opacities=[],De.opacityBoxes=[],De.opacities=Be,De.currentOpacity=Ke,De.setCurrentOpacity=De.setCurrentOpacity.bind(De),De}return ie(Ae,We),Ae.prototype.getUi=function(){var Se=this,Be=document.createElement("div");return Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2",Be.style.justifyContent="space-between",this.opacities.forEach(function(Ke){var Ne=document.createElement("div");Ne.style.display="flex",Ne.style.alignItems="center",Ne.style.justifyContent="center",Ne.style.padding="5px",Ne.style.borderWidth="2px",Ne.style.borderStyle="solid",Ne.style.borderColor=Ke===Se.currentOpacity?Se.uiStyleSettings.toolboxAccentColor:"transparent",Ne.addEventListener("click",function(){Se.setCurrentOpacity(Ke,Ne)}),Be.appendChild(Ne);var De=document.createElement("div");De.innerText=100*Ke+"%",Ne.appendChild(De),Se.opacityBoxes.push(Ne)}),Be},Ae.prototype.setCurrentOpacity=function(Se,Be){var Ke=this;this.currentOpacity=Se,this.opacityBoxes.forEach(function(Ne){Ne.style.borderColor=Ne===Be?Ke.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onOpacityChanged&&this.onOpacityChanged(this.currentOpacity)},Ae}(ae),ut=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.setOpacity=Ne.setOpacity.bind(Ne),Ne.fillColor=Ke.defaultHighlightColor,Ne.strokeWidth=0,Ne.opacity=Ke.defaultHighlightOpacity,Ne.fillPanel=new oe("Color",Ke.defaultColorSet,Ne.fillColor),Ne.fillPanel.onColorChanged=Ne.setFillColor,Ne.opacityPanel=new Ye("Opacity",Ke.defaultOpacitySteps,Ne.opacity),Ne.opacityPanel.onOpacityChanged=Ne.setOpacity,Ne}return ie(Ae,We),Ae.prototype.setOpacity=function(Se){this.opacity=Se,this.visual&&te.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.fillPanel,this.opacityPanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=We.prototype.getState.call(this);return Se.typeName=Ae.typeName,Se},Ae.typeName="HighlightMarker",Ae.title="Highlight marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M18.5 1.15c-.53 0-1.04.19-1.43.58l-5.81 5.82 5.65 5.65 5.82-5.81c.77-.78.77-2.04 0-2.83l-2.84-2.83c-.39-.39-.89-.58-1.39-.58M10.3 8.5l-5.96 5.96c-.78.78-.78 2.04.02 2.85C3.14 18.54 1.9 19.77.67 21h5.66l.86-.86c.78.76 2.03.75 2.81-.02l5.95-5.96"/></svg>',Ae}(rt),Ge='<svg viewBox="0 0 24 24"><path d="M9.62 12L12 5.67 14.37 12M11 3L5.5 17h2.25l1.12-3h6.25l1.13 3h2.25L13 3h-2z"/></svg>',ze='<svg viewBox="0 0 24 24"><path d="M19 11.5s-2 2.17-2 3.5a2 2 0 002 2 2 2 0 002-2c0-1.33-2-3.5-2-3.5M5.21 10L10 5.21 14.79 10m1.77-1.06L7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.56-.59 1.53 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.59.59-1.56 0-2.12z"/></svg>',Ve=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.bgColor="transparent",Ne.tipPosition={x:0,y:0},Ne.tipBase1Position={x:0,y:0},Ne.tipBase2Position={x:0,y:0},Ne.tipMoving=!1,Ne.color=Ke.defaultStrokeColor,Ne.bgColor=Ke.defaultFillColor,Ne.fontFamily=Ke.defaultFontFamily,Ne.defaultSize={x:100,y:30},Ne.setBgColor=Ne.setBgColor.bind(Ne),Ne.getTipPoints=Ne.getTipPoints.bind(Ne),Ne.positionTip=Ne.positionTip.bind(Ne),Ne.setTipPoints=Ne.setTipPoints.bind(Ne),Ne.colorPanel=new oe("Text color",Ke.defaultColorSet,Ne.color,Ge),Ne.colorPanel.onColorChanged=Ne.setColor,Ne.bgColorPanel=new oe("Fill color",Ke.defaultColorSet,Ne.bgColor,ze),Ne.bgColorPanel.onColorChanged=Ne.setBgColor,Ne.fontFamilyPanel=new Pe("Font",Ke.defaultFontFamilies,Ke.defaultFontFamily),Ne.fontFamilyPanel.onFontChanged=Ne.setFont,Ne.tipGrip=new me,Ne.tipGrip.visual.transform.baseVal.appendItem(te.createTransform()),Ne.controlBox.appendChild(Ne.tipGrip.visual),Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return We.prototype.ownsTarget.call(this,Se)||this.tipGrip.ownsTarget(Se)||this.tip===Se},Ae.prototype.createTip=function(){te.setAttributes(this.bgRectangle,[["fill",this.bgColor],["rx","10px"]]),this.tip=te.createPolygon(this.getTipPoints(),[["fill",this.bgColor]]),this.visual.appendChild(this.tip)},Ae.prototype.pointerDown=function(Se,Be){this.state==="new"&&We.prototype.pointerDown.call(this,Se,Be),this.state==="creating"?this.createTip():this.tipGrip.ownsTarget(Be)?(this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.tipMoving=!0):We.prototype.pointerDown.call(this,Se,Be)},Ae.prototype.pointerUp=function(Se){if(this.tipMoving)this.tipMoving=!1,this.isMoved=!0,We.prototype.pointerUp.call(this,Se);else{var Be=this.state==="creating";We.prototype.pointerUp.call(this,Se),this.setTipPoints(Be),this.positionTip()}},Ae.prototype.manipulate=function(Se){if(this.tipMoving){var Be=this.unrotatePoint(Se);this.tipPosition={x:Be.x-this.manipulationStartLeft,y:Be.y-this.manipulationStartTop},this.positionTip()}else We.prototype.manipulate.call(this,Se)},Ae.prototype.setBgColor=function(Se){this.bgRectangle&&this.tip&&(te.setAttributes(this.bgRectangle,[["fill",Se]]),te.setAttributes(this.tip,[["fill",Se]])),this.bgColor=Se,this.fillColorChanged(Se)},Ae.prototype.getTipPoints=function(){return this.setTipPoints(this.state==="creating"),this.tipBase1Position.x+","+this.tipBase1Position.y+" "+this.tipBase2Position.x+","+this.tipBase2Position.y+" "+this.tipPosition.x+","+this.tipPosition.y},Ae.prototype.setTipPoints=function(Se){Se===void 0&&(Se=!1);var Be=Math.min(this.height/2,15),Ke=this.height/5;Se&&(this.tipPosition={x:Be+Ke/2,y:this.height+20});var Ne=Math.atan(this.height/2/(this.width/2));this.tipPosition.x<this.width/2&&this.tipPosition.y<this.height/2?Ne<Math.atan((this.height/2-this.tipPosition.y)/(this.width/2-this.tipPosition.x))?(Ke=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:Be,y:0},this.tipBase2Position={x:Be+Ke,y:0}):(this.tipBase1Position={x:0,y:Be},this.tipBase2Position={x:0,y:Be+Ke}):this.tipPosition.x>=this.width/2&&this.tipPosition.y<this.height/2?Ne<Math.atan((this.height/2-this.tipPosition.y)/(this.tipPosition.x-this.width/2))?(Ke=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-Be-Ke,y:0},this.tipBase2Position={x:this.width-Be,y:0}):(this.tipBase1Position={x:this.width,y:Be},this.tipBase2Position={x:this.width,y:Be+Ke}):this.tipPosition.x>=this.width/2&&this.tipPosition.y>=this.height/2?Ne<Math.atan((this.tipPosition.y-this.height/2)/(this.tipPosition.x-this.width/2))?(Ke=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-Be-Ke,y:this.height},this.tipBase2Position={x:this.width-Be,y:this.height}):(this.tipBase1Position={x:this.width,y:this.height-Be-Ke},this.tipBase2Position={x:this.width,y:this.height-Be}):Ne<Math.atan((this.tipPosition.y-this.height/2)/(this.width/2-this.tipPosition.x))?(Ke=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:Be,y:this.height},this.tipBase2Position={x:Be+Ke,y:this.height}):(this.tipBase1Position={x:0,y:this.height-Be},this.tipBase2Position={x:0,y:this.height-Be-Ke})},Ae.prototype.resize=function(Se){We.prototype.resize.call(this,Se),this.positionTip()},Ae.prototype.positionTip=function(){te.setAttributes(this.tip,[["points",this.getTipPoints()]]);var Se=this.tipGrip.visual.transform.baseVal.getItem(0);Se.setTranslate(this.tipPosition.x,this.tipPosition.y),this.tipGrip.visual.transform.baseVal.replaceItem(Se,0)},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.bgColorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),Ae.prototype.select=function(){this.positionTip(),We.prototype.select.call(this)},Ae.prototype.getState=function(){var Se=Object.assign({bgColor:this.bgColor,tipPosition:this.tipPosition},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){var Be=Se;this.bgColor=Be.bgColor,this.tipPosition=Be.tipPosition,We.prototype.restoreState.call(this,Se),this.createTip(),this.setTipPoints()},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.tipPosition={x:this.tipPosition.x*Se,y:this.tipPosition.y*Be},this.positionTip()},Ae.typeName="CalloutMarker",Ae.title="Callout marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M4 2h16a2 2 0 012 2v12a2 2 0 01-2 2h-4l-4 4-4-4H4a2 2 0 01-2-2V4a2 2 0 012-2m0 2v12h4.83L12 19.17 15.17 16H20V4H4m2 3h12v2H6V7m0 4h10v2H6v-2z"/></svg>',Ae}(Qe),$e=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.fillColor="transparent",Ne.strokeColor="transparent",Ne.strokeWidth=0,Ne.strokeDasharray="",Ne.opacity=1,Ne.strokeColor=Ke.defaultColor,Ne.strokeWidth=Ke.defaultStrokeWidth,Ne.strokeDasharray=Ke.defaultStrokeDasharray,Ne.fillColor=Ke.defaultFillColor,Ne.setStrokeColor=Ne.setStrokeColor.bind(Ne),Ne.setFillColor=Ne.setFillColor.bind(Ne),Ne.setStrokeWidth=Ne.setStrokeWidth.bind(Ne),Ne.setStrokeDasharray=Ne.setStrokeDasharray.bind(Ne),Ne.setOpacity=Ne.setOpacity.bind(Ne),Ne.createVisual=Ne.createVisual.bind(Ne),Ne.strokePanel=new oe("Line color",se(Ke.defaultColorSet,["transparent"]),Ke.defaultColor),Ne.strokePanel.onColorChanged=Ne.setStrokeColor,Ne.fillPanel=new oe("Fill color",se(Ke.defaultColorSet,["transparent"]),Ne.fillColor,ze),Ne.fillPanel.onColorChanged=Ne.setFillColor,Ne.strokeWidthPanel=new pe("Line width",Ke.defaultStrokeWidths,Ke.defaultStrokeWidth),Ne.strokeWidthPanel.onWidthChanged=Ne.setStrokeWidth,Ne.strokeStylePanel=new ke("Line style",Ke.defaultStrokeDasharrays,Ke.defaultStrokeDasharray),Ne.strokeStylePanel.onStyleChanged=Ne.setStrokeDasharray,Ne.opacityPanel=new Ye("Opacity",Ke.defaultOpacitySteps,Ne.opacity),Ne.opacityPanel.onOpacityChanged=Ne.setOpacity,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.visual)},Ae.prototype.createVisual=function(){this.visual=te.createEllipse(this.width/2,this.height/2,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.state==="new"&&(this.createVisual(),this.moveVisual(Se),this._state="creating")},Ae.prototype.manipulate=function(Se){We.prototype.manipulate.call(this,Se)},Ae.prototype.resize=function(Se){We.prototype.resize.call(this,Se),this.setSize()},Ae.prototype.setSize=function(){We.prototype.setSize.call(this),te.setAttributes(this.visual,[["cx",(this.width/2).toString()],["cy",(this.height/2).toString()],["rx",(this.width/2).toString()],["ry",(this.height/2).toString()]])},Ae.prototype.pointerUp=function(Se){We.prototype.pointerUp.call(this,Se),this.setSize()},Ae.prototype.setStrokeColor=function(Se){this.strokeColor=Se,this.visual&&te.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(Se),this.stateChanged()},Ae.prototype.setFillColor=function(Se){this.fillColor=Se,this.visual&&te.setAttributes(this.visual,[["fill",this.fillColor]]),this.fillColorChanged(Se),this.stateChanged()},Ae.prototype.setStrokeWidth=function(Se){this.strokeWidth=Se,this.visual&&te.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},Ae.prototype.setStrokeDasharray=function(Se){this.strokeDasharray=Se,this.visual&&te.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Ae.prototype.setOpacity=function(Se){this.opacity=Se,this.visual&&te.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.opacityPanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){var Be=Se;this.fillColor=Be.fillColor,this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.opacity=Be.opacity,this.createVisual(),We.prototype.restoreState.call(this,Se),this.setSize()},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.setSize()},Ae.typeName="EllipseMarker",Ae.title="Ellipse marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M12 4C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',Ae}(_e),nt=function(We){function Ae(Se,Be,Ke){return We.call(this,Se,Be,Ke)||this}return ie(Ae,We),Object.defineProperty(Ae.prototype,"tipLength",{get:function(){return 10+3*this.strokeWidth},enumerable:!1,configurable:!0}),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.tip1&&Se!==this.tip2)},Ae.prototype.createTips=function(){this.tip1=te.createLine(this.x1-this.tipLength/2,this.y1,this.x1+this.tipLength/2,this.y1,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip1.transform.baseVal.appendItem(te.createTransform()),this.visual.appendChild(this.tip1),this.tip2=te.createLine(this.x2-this.tipLength/2,this.y2,this.x2+this.tipLength/2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip2.transform.baseVal.appendItem(te.createTransform()),this.visual.appendChild(this.tip2)},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.state==="creating"&&this.createTips()},Ae.prototype.adjustVisual=function(){if(We.prototype.adjustVisual.call(this),this.tip1&&this.tip2&&(te.setAttributes(this.tip1,[["x1",(this.x1-this.tipLength/2).toString()],["y1",this.y1.toString()],["x2",(this.x1+this.tipLength/2).toString()],["y2",this.y1.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),te.setAttributes(this.tip2,[["x1",(this.x2-this.tipLength/2).toString()],["y1",this.y2.toString()],["x2",(this.x2+this.tipLength/2).toString()],["y2",this.y2.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),Math.abs(this.x1-this.x2)>.1)){var Se=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2),Be=this.tip1.transform.baseVal.getItem(0);Be.setRotate(Se,this.x1,this.y1),this.tip1.transform.baseVal.replaceItem(Be,0);var Ke=this.tip2.transform.baseVal.getItem(0);Ke.setRotate(Se+180,this.x2,this.y2),this.tip2.transform.baseVal.replaceItem(Ke,0)}},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=We.prototype.getState.call(this);return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){We.prototype.restoreState.call(this,Se),this.createTips(),this.adjustVisual()},Ae.typeName="MeasurementMarker",Ae.title="Measurement marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M1.39 18.36l1.77-1.76L4.58 18l1.06-1.05-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.42 1.41L10.59 12l-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.41 1.41 1.07-1.06-1.42-1.41 1.42-1.42L18 6.7l1.07-1.06-2.47-2.48 1.76-1.77 4.25 4.25L5.64 22.61l-4.25-4.25z"/></svg>',Ae}(je),et=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.strokePanel.colors=Ke.defaultColorSet,Ne.fillColor="transparent",Ne}return ie(Ae,We),Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=We.prototype.getState.call(this);return Se.typeName=Ae.typeName,Se},Ae.typeName="EllipseFrameMarker",Ae.title="Ellipse frame marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M12 6c4.41 0 8 2.69 8 6s-3.59 6-8 6-8-2.69-8-6 3.59-6 8-6m0-2C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',Ae}($e),pt=function(){function We(){this.undoStack=[],this.redoStack=[]}return Object.defineProperty(We.prototype,"isUndoPossible",{get:function(){return this.undoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"isRedoPossible",{get:function(){return this.redoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"undoStepCount",{get:function(){return this.undoStack.length},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"redoStepCount",{get:function(){return this.redoStack.length},enumerable:!1,configurable:!0}),We.prototype.addUndoStep=function(Ae){this.undoStack.length!==0&&JSON.stringify(this.undoStack[this.undoStack.length-1])===JSON.stringify(Ae)||(this.undoStack.push(Ae),JSON.stringify(this.lastRedoStep)!==JSON.stringify(Ae)&&this.redoStack.splice(0,this.redoStack.length))},We.prototype.replaceLastUndoStep=function(Ae){this.undoStack.length>0&&(this.undoStack[this.undoStack.length-1]=Ae)},We.prototype.getLastUndoStep=function(){return this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0},We.prototype.undo=function(){if(this.undoStack.length>1){var Ae=this.undoStack.pop();return Ae!==void 0&&this.redoStack.push(Ae),this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0}},We.prototype.redo=function(){return this.lastRedoStep=this.redoStack.pop(),this.lastRedoStep},We}(),ct=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.strokeColor="transparent",Ne.strokeWidth=0,Ne.strokeDasharray="",Ne.curveX=0,Ne.curveY=0,Ne.manipulationStartCurveX=0,Ne.manipulationStartCurveY=0,Ne.setStrokeColor=Ne.setStrokeColor.bind(Ne),Ne.setStrokeWidth=Ne.setStrokeWidth.bind(Ne),Ne.setStrokeDasharray=Ne.setStrokeDasharray.bind(Ne),Ne.positionGrips=Ne.positionGrips.bind(Ne),Ne.addControlGrips=Ne.addControlGrips.bind(Ne),Ne.adjustVisual=Ne.adjustVisual.bind(Ne),Ne.setupControlBox=Ne.setupControlBox.bind(Ne),Ne.resize=Ne.resize.bind(Ne),Ne.strokeColor=Ke.defaultColor,Ne.strokeWidth=Ke.defaultStrokeWidth,Ne.strokeDasharray=Ke.defaultStrokeDasharray,Ne.strokePanel=new oe("Line color",Ke.defaultColorSet,Ke.defaultColor),Ne.strokePanel.onColorChanged=Ne.setStrokeColor,Ne.strokeWidthPanel=new pe("Line width",Ke.defaultStrokeWidths,Ke.defaultStrokeWidth),Ne.strokeWidthPanel.onWidthChanged=Ne.setStrokeWidth,Ne.strokeStylePanel=new ke("Line style",Ke.defaultStrokeDasharrays,Ke.defaultStrokeDasharray),Ne.strokeStylePanel.onStyleChanged=Ne.setStrokeDasharray,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.visual&&Se!==this.selectorCurve&&Se!==this.visibleCurve&&!this.curveGrip.ownsTarget(Se))},Ae.prototype.getPathD=function(){return"M "+this.x1+" "+this.y1+" Q "+this.curveX+" "+this.curveY+", "+this.x2+" "+this.y2},Ae.prototype.createVisual=function(){this.visual=te.createGroup(),this.selectorCurve=te.createPath(this.getPathD(),[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()],["fill","transparent"]]),this.visibleCurve=te.createPath(this.getPathD(),[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["fill","transparent"]]),this.visual.appendChild(this.selectorCurve),this.visual.appendChild(this.visibleCurve),this.addMarkerVisualToContainer(this.visual)},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.manipulationStartCurveX=this.curveX,this.manipulationStartCurveY=this.curveY,this.state==="new"&&(this.curveX=Se.x,this.curveY=Se.y),this.state==="new"?(this.createVisual(),this.adjustVisual(),this._state="creating"):this.curveGrip.ownsTarget(Be)&&(this.activeGrip=this.curveGrip,this._state="resize")},Ae.prototype.adjustVisual=function(){this.selectorCurve&&this.visibleCurve&&(this.selectorCurve.setAttribute("d",this.getPathD()),this.visibleCurve.setAttribute("d",this.getPathD()),te.setAttributes(this.visibleCurve,[["stroke",this.strokeColor]]),te.setAttributes(this.visibleCurve,[["stroke-width",this.strokeWidth.toString()]]),te.setAttributes(this.visibleCurve,[["stroke-dasharray",this.strokeDasharray.toString()]]))},Ae.prototype.setupControlBox=function(){We.prototype.setupControlBox.call(this),this.curveControlLine1=te.createLine(this.x1,this.y1,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.curveControlLine2=te.createLine(this.x2,this.y2,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.insertBefore(this.curveControlLine1,this.controlBox.firstChild),this.controlBox.insertBefore(this.curveControlLine2,this.controlBox.firstChild)},Ae.prototype.addControlGrips=function(){this.curveGrip=this.createGrip(),this.curveX=0,this.curveY=0,We.prototype.addControlGrips.call(this)},Ae.prototype.positionGrips=function(){We.prototype.positionGrips.call(this);var Se=this.curveGrip.GRIP_SIZE;this.positionGrip(this.curveGrip.visual,this.curveX-Se/2,this.curveY-Se/2),this.curveControlLine1&&this.curveControlLine2&&(this.curveControlLine1.setAttribute("x1",this.x1.toString()),this.curveControlLine1.setAttribute("y1",this.y1.toString()),this.curveControlLine1.setAttribute("x2",this.curveX.toString()),this.curveControlLine1.setAttribute("y2",this.curveY.toString()),this.curveControlLine2.setAttribute("x1",this.x2.toString()),this.curveControlLine2.setAttribute("y1",this.y2.toString()),this.curveControlLine2.setAttribute("x2",this.curveX.toString()),this.curveControlLine2.setAttribute("y2",this.curveY.toString()))},Ae.prototype.manipulate=function(Se){this.state==="move"&&(this.curveX=this.manipulationStartCurveX+Se.x-this.manipulationStartX,this.curveY=this.manipulationStartCurveY+Se.y-this.manipulationStartY),We.prototype.manipulate.call(this,Se)},Ae.prototype.resize=function(Se){this.activeGrip===this.curveGrip&&(this.curveX=Se.x,this.curveY=Se.y),We.prototype.resize.call(this,Se),this.state==="creating"&&(this.curveX=this.x1+(this.x2-this.x1)/2,this.curveY=this.y1+(this.y2-this.y1)/2)},Ae.prototype.setStrokeColor=function(Se){this.strokeColor=Se,this.adjustVisual(),this.colorChanged(Se)},Ae.prototype.setStrokeWidth=function(Se){this.strokeWidth=Se,this.adjustVisual()},Ae.prototype.setStrokeDasharray=function(Se){this.strokeDasharray=Se,this.adjustVisual()},Ae.prototype.scale=function(Se,Be){this.curveX=this.curveX*Se,this.curveY=this.curveY*Be,We.prototype.scale.call(this,Se,Be)},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,curveX:this.curveX,curveY:this.curveY},We.prototype.getState.call(this));return Se.typeName=Ae.typeName,Se},Ae.prototype.restoreState=function(Se){We.prototype.restoreState.call(this,Se);var Be=Se;this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.curveX=Be.curveX,this.curveY=Be.curveY,this.createVisual(),this.adjustVisual()},Ae.typeName="CurveMarker",Ae.title="Curve marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M18.5 2A1.5 1.5 0 0120 3.5 1.5 1.5 0 0118.5 5c-.23 0-.45-.05-.65-.15l-3.69 3.7.34.45c2.19-1.26 4.76-2 7.5-2l1 .03v2.01L22 9c-2.58 0-5 .75-7 2.04A3.96 3.96 0 0111.04 15C9.75 17 9 19.42 9 22l.04 1H7.03L7 22c0-2.74.74-5.31 2-7.5l-.45-.34-3.7 3.69c.1.2.15.42.15.65A1.5 1.5 0 013.5 20 1.5 1.5 0 012 18.5 1.5 1.5 0 013.5 17c.23 0 .45.05.65.15l3.69-3.7C7.31 12.78 7 11.92 7 11a4 4 0 014-4c.92 0 1.78.31 2.45.84l3.7-3.69c-.1-.2-.15-.42-.15-.65A1.5 1.5 0 0118.5 2M11 9a2 2 0 00-2 2 2 2 0 002 2 2 2 0 002-2 2 2 0 00-2-2z"/></svg>',Ae}(Oe),Ot=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,Be,Ke)||this;return Ne.fillColor="transparent",Ne.strokeColor="transparent",Ne.strokeWidth=0,Ne.strokeDasharray="",Ne.textColor="transparent",Ne.fontSize="1rem",Ne.isMoved=!1,Ne.captionText="Caption",Ne.PADDING=5,Ne.captionBoxWidth=0,Ne.captionBoxHeight=0,Ne.strokeColor=Ke.defaultColor,Ne.strokeWidth=Ke.defaultStrokeWidth,Ne.strokeDasharray=Ke.defaultStrokeDasharray,Ne.fillColor=Ke.defaultFillColor,Ne.textColor=Ke.defaultStrokeColor,Ne.fontFamily=Ke.defaultFontFamily,Ne.fontSize=Ke.defaultCaptionFontSize,Ne.captionText=Ke.defaultCaptionText,Ne.setStrokeColor=Ne.setStrokeColor.bind(Ne),Ne.setFillColor=Ne.setFillColor.bind(Ne),Ne.setStrokeWidth=Ne.setStrokeWidth.bind(Ne),Ne.setStrokeDasharray=Ne.setStrokeDasharray.bind(Ne),Ne.createVisual=Ne.createVisual.bind(Ne),Ne.sizeCaption=Ne.sizeCaption.bind(Ne),Ne.setCaptionText=Ne.setCaptionText.bind(Ne),Ne.showTextEditor=Ne.showTextEditor.bind(Ne),Ne.positionTextEditor=Ne.positionTextEditor.bind(Ne),Ne.finishTextEditing=Ne.finishTextEditing.bind(Ne),Ne.setFont=Ne.setFont.bind(Ne),Ne.setTextColor=Ne.setTextColor.bind(Ne),Ne.strokePanel=new oe("Line color",se(Ke.defaultColorSet,["transparent"]),Ne.strokeColor),Ne.strokePanel.onColorChanged=Ne.setStrokeColor,Ne.fillPanel=new oe("Fill color",se(Ke.defaultColorSet,["transparent"]),Ne.fillColor,ze),Ne.fillPanel.onColorChanged=Ne.setFillColor,Ne.strokeWidthPanel=new pe("Line width",Ke.defaultStrokeWidths,Ke.defaultStrokeWidth),Ne.strokeWidthPanel.onWidthChanged=Ne.setStrokeWidth,Ne.strokeStylePanel=new ke("Line style",Ke.defaultStrokeDasharrays,Ke.defaultStrokeDasharray),Ne.strokeStylePanel.onStyleChanged=Ne.setStrokeDasharray,Ne.fontFamilyPanel=new Pe("Font",Ke.defaultFontFamilies,Ke.defaultFontFamily),Ne.fontFamilyPanel.onFontChanged=Ne.setFont,Ne.textColorPanel=new oe("Text color",Ke.defaultColorSet,Ne.textColor,Ge),Ne.textColorPanel.onColorChanged=Ne.setTextColor,Ne}return ie(Ae,We),Ae.prototype.ownsTarget=function(Se){return!(!We.prototype.ownsTarget.call(this,Se)&&Se!==this.visual&&Se!==this.frame&&Se!==this.captionBg&&Se!==this.captionElement)},Ae.prototype.createVisual=function(){this.visual=te.createGroup(),this.addMarkerVisualToContainer(this.visual),this.captionBg=te.createRect(1,1,[["fill",this.fillColor]]),this.visual.appendChild(this.captionBg),this.captionElement=te.createText([["fill",this.textColor],["font-family",this.fontFamily]]),this.captionElement.style.fontSize=this.fontSize,this.captionElement.style.textAnchor="start",this.captionElement.style.dominantBaseline="text-before-edge",this.captionElement.textContent=this.captionText,this.visual.appendChild(this.captionElement),this.frame=te.createRect(this.width,this.height,[["fill","transparent"],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray]]),this.visual.appendChild(this.frame),this.sizeCaption()},Ae.prototype.setCaptionText=function(Se){this.captionText=Se,this.captionElement.textContent=this.captionText,this.sizeCaption()},Ae.prototype.pointerDown=function(Se,Be){We.prototype.pointerDown.call(this,Se,Be),this.isMoved=!1,this.pointerDownPoint=Se,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(Se),this._state="creating")},Ae.prototype.manipulate=function(Se){We.prototype.manipulate.call(this,Se),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(Se.x-this.pointerDownPoint.x)>5||Math.abs(Se.y-this.pointerDownPoint.y)>5)},Ae.prototype.resize=function(Se){We.prototype.resize.call(this,Se),this.setSize()},Ae.prototype.sizeCaption=function(){var Se=this.captionElement.getBBox();this.captionText.trim()!==""?(this.captionBoxWidth=Se.width+2*this.PADDING,this.captionBoxHeight=Se.height+2*this.PADDING):(this.captionBoxWidth=0,this.captionBoxHeight=0),te.setAttributes(this.captionBg,[["width",this.captionBoxWidth.toString()],["height",this.captionBoxHeight.toString()],["clip-path","path('M0,0 H"+this.width+" V"+this.height+" H"+-this.width+" Z')"]]),te.setAttributes(this.captionElement,[["x",this.PADDING.toString()],["y",this.PADDING.toString()],["clip-path","path('M0,0 H"+(this.width-this.PADDING)+" V"+this.height+" H"+(-this.width-this.PADDING)+" Z')"]])},Ae.prototype.showTextEditor=function(){var Se=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditBox=document.createElement("input"),this.textEditBox.style.position="absolute",this.textEditBox.style.width=this.width+"px",this.captionBoxHeight>0&&(this.textEditBox.style.height=this.captionBoxHeight+"px"),this.textEditBox.style.fontSize=this.fontSize,this.textEditBox.style.fontFamily=this.fontFamily,this.textEditBox.style.backgroundColor=this.fillColor,this.textEditBox.style.color=this.textColor,this.textEditBox.style.borderWidth="0",this.textEditBox.setAttribute("value",this.captionText),this.textEditBox.select(),this.textEditDiv.appendChild(this.textEditBox),this.overlayContainer.appendChild(this.textEditDiv),this.textEditBox.addEventListener("pointerup",function(Be){Be.stopPropagation()}),this.textEditBox.addEventListener("keypress",function(Be){Be.key==="Enter"&&Se.finishTextEditing(Se.textEditBox.value)}),this.textEditBox.addEventListener("keyup",function(Be){Be.cancelBubble=!0}),this.textEditBox.addEventListener("blur",function(){Se.finishTextEditing(Se.textEditBox.value)}),this.textEditDiv.addEventListener("pointerup",function(){Se.finishTextEditing(Se.textEditBox.value)}),this.positionTextEditor(),this.textEditBox.focus()},Ae.prototype.positionTextEditor=function(){this.state==="edit"&&(this.textEditBox===void 0?this.showTextEditor():(this.textEditBox.style.left=this.left+"px",this.textEditBox.style.top=this.top+"px",this.textEditBox.style.transform="rotate("+this.rotationAngle+"deg)",this.textEditBox.style.transformOrigin=this.width/2+"px "+this.height/2+"px"))},Ae.prototype.finishTextEditing=function(Se){this.setCaptionText(Se.trim()),this.overlayContainer.innerHTML="",this.stateChanged()},Ae.prototype.setFont=function(Se){this.captionElement&&te.setAttributes(this.captionElement,[["font-family",Se]]),this.fontFamily=Se,this.textEditBox&&(this.textEditBox.style.fontFamily=this.fontFamily),this.sizeCaption(),this.stateChanged()},Ae.prototype.setTextColor=function(Se){this.captionElement&&te.setAttributes(this.captionElement,[["fill",Se]]),this.textColor=Se,this.textEditBox&&(this.textEditBox.style.color=this.textColor),this.stateChanged()},Ae.prototype.setSize=function(){We.prototype.setSize.call(this),te.setAttributes(this.frame,[["width",this.width.toString()],["height",this.height.toString()]]),this.sizeCaption()},Ae.prototype.pointerUp=function(Se){We.prototype.pointerUp.call(this,Se),this.setSize(),!this.isMoved&&Date.now()-this.pointerDownTimestamp>500&&this.showTextEditor(),this.pointerDownPoint=void 0},Ae.prototype.dblClick=function(Se,Be){We.prototype.dblClick.call(this,Se,Be),this.showTextEditor()},Ae.prototype.setStrokeColor=function(Se){this.strokeColor=Se,this.frame&&te.setAttributes(this.frame,[["stroke",this.strokeColor]]),this.colorChanged(Se),this.stateChanged()},Ae.prototype.setFillColor=function(Se){this.fillColor=Se,this.captionBg&&te.setAttributes(this.captionBg,[["fill",this.fillColor]]),this.fillColorChanged(Se),this.stateChanged()},Ae.prototype.setStrokeWidth=function(Se){this.strokeWidth=Se,this.frame&&te.setAttributes(this.frame,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},Ae.prototype.setStrokeDasharray=function(Se){this.strokeDasharray=Se,this.frame&&te.setAttributes(this.frame,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Object.defineProperty(Ae.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.fontFamilyPanel,this.textColorPanel]},enumerable:!1,configurable:!0}),Ae.prototype.getState=function(){var Se=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:1,textColor:this.textColor,fontFamily:this.fontFamily,fontSize:this.fontSize,captionText:this.captionText},We.prototype.getState.call(this));return Se.typeName=this.typeName,Se},Ae.prototype.restoreState=function(Se){var Be=Se;this.fillColor=Be.fillColor,this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.textColor=Be.textColor,this.fontFamily=Be.fontFamily,this.captionText=Be.captionText,this.fontSize=Be.fontSize,this.createVisual(),We.prototype.restoreState.call(this,Se),this.setSize()},Ae.prototype.scale=function(Se,Be){We.prototype.scale.call(this,Se,Be),this.setSize()},Ae.typeName="CaptionFrameMarker",Ae.title="Caption frame marker",Ae.icon='<svg viewBox="0 0 24 24"><path d="M5 3c-1.11 0-2 .89-2 2v14c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2H5m0 2h14v14H5V5m2 2v2h10V7H7z"/></svg>',Ae}(_e),dt=function(){function We(Ae,Se){Se===void 0&&(Se=!1),this.cancelable=!1,this._defaultPrevented=!1,this.markerArea=Ae,this.cancelable=Se}return Object.defineProperty(We.prototype,"defaultPrevented",{get:function(){return this._defaultPrevented},enumerable:!1,configurable:!0}),We.prototype.preventDefault=function(){this._defaultPrevented=!0},We}(),Rt=function(We){function Ae(Se,Be,Ke){var Ne=We.call(this,Se,!1)||this;return Ne.dataUrl=Be,Ne.state=Ke,Ne}return ie(Ae,We),Ae}(dt),xt=function(We){function Ae(Se,Be,Ke){Ke===void 0&&(Ke=!1);var Ne=We.call(this,Se,Ke)||this;return Ne.marker=Be,Ne}return ie(Ae,We),Ae}(dt),gt=function(){function We(){this.render=[],this.beforeclose=[],this.close=[],this.show=[],this.restorestate=[],this.statechange=[],this.markerselect=[],this.markerdeselect=[],this.markercreating=[],this.markercreate=[],this.markerbeforedelete=[],this.markerdelete=[],this.markerchange=[],this.focus=[],this.blur=[]}return We.prototype.addEventListener=function(Ae,Se){this[Ae].push(Se)},We.prototype.removeEventListener=function(Ae,Se){var Be=this[Ae].indexOf(Se);Be>-1&&this[Ae].splice(Be,1)},We}(),_t=function(){function We(Ae){this.touchPoints=0,this._availableMarkerTypes=this.DEFAULT_MARKER_TYPES,this.mode="select",this.markers=[],this.isDragging=!1,this.renderEventListeners=[],this.closeEventListeners=[],this.settings=new Ee,this._isOpen=!1,this.undoRedoManager=new pt,this.renderAtNaturalSize=!1,this.renderImageType="image/png",this.renderMarkersOnly=!1,this.zoomSteps=[1,1.5,2,4],this._zoomLevel=1,this._isResizing=!1,this.prevPanPoint={x:0,y:0},this.eventListeners=new gt,this._silentRenderMode=!1,this._isFocused=!1,this._instanceNo=We.instanceCounter++,this.styles=new E(this.instanceNo),this.uiStyleSettings=this.styles.settings,this.target=Ae,this.targetRoot=document.body,this.width=Ae.clientWidth,this.height=Ae.clientHeight,this.styles.removeStyleSheet(),this.open=this.open.bind(this),this.setTopLeft=this.setTopLeft.bind(this),this.toolbarButtonClicked=this.toolbarButtonClicked.bind(this),this.createNewMarker=this.createNewMarker.bind(this),this.addNewMarker=this.addNewMarker.bind(this),this.markerCreated=this.markerCreated.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onDblClick=this.onDblClick.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.onPointerOut=this.onPointerOut.bind(this),this.onKeyUp=this.onKeyUp.bind(this),this.overrideOverflow=this.overrideOverflow.bind(this),this.restoreOverflow=this.restoreOverflow.bind(this),this.close=this.close.bind(this),this.closeUI=this.closeUI.bind(this),this.addCloseEventListener=this.addCloseEventListener.bind(this),this.removeCloseEventListener=this.removeCloseEventListener.bind(this),this.addRenderEventListener=this.addRenderEventListener.bind(this),this.removeRenderEventListener=this.removeRenderEventListener.bind(this),this.clientToLocalCoordinates=this.clientToLocalCoordinates.bind(this),this.onWindowResize=this.onWindowResize.bind(this),this.deleteSelectedMarker=this.deleteSelectedMarker.bind(this),this.setWindowHeight=this.setWindowHeight.bind(this),this.removeMarker=this.removeMarker.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this),this.onPopupTargetResize=this.onPopupTargetResize.bind(this),this.showNotesEditor=this.showNotesEditor.bind(this),this.hideNotesEditor=this.hideNotesEditor.bind(this),this.stepZoom=this.stepZoom.bind(this),this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.markerStateChanged=this.markerStateChanged.bind(this),this.switchToSelectMode=this.switchToSelectMode.bind(this),this.addDefs=this.addDefs.bind(this),this.addDefsToImage=this.addDefsToImage.bind(this)}return Object.defineProperty(We.prototype,"ALL_MARKER_TYPES",{get:function(){return[Te,Xe,He,Qe,et,$e,ut,Ve,nt,rt,je,ct,Ot]},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"DEFAULT_MARKER_TYPES",{get:function(){return[Te,Xe,He,Qe,$e,ut,Ve]},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"BASIC_MARKER_TYPES",{get:function(){return[Te,Xe,He,Qe,ut]},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"availableMarkerTypes",{get:function(){return this._availableMarkerTypes},set:function(Ae){var Se=this;this._availableMarkerTypes.splice(0),Ae.forEach(function(Be){if(typeof Be=="string"){var Ke=Se.ALL_MARKER_TYPES.find(function(Ne){return Ne.typeName===Be});Ke!==void 0&&Se._availableMarkerTypes.push(Ke)}else Se._availableMarkerTypes.push(Be)})},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"currentMarker",{get:function(){return this._currentMarker},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"isUndoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isUndoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"isRedoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isRedoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"zoomLevel",{get:function(){return this._zoomLevel},set:function(Ae){this._zoomLevel=Ae,this.editorCanvas&&this.contentDiv&&(this.editorCanvas.style.transform="scale("+this._zoomLevel+")",this.contentDiv.scrollTo({left:(this.editorCanvas.clientWidth*this._zoomLevel-this.contentDiv.clientWidth)/2,top:(this.editorCanvas.clientHeight*this._zoomLevel-this.contentDiv.clientHeight)/2}))},enumerable:!1,configurable:!0}),Object.defineProperty(We.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),We.prototype.open=function(){this.setupResizeObserver(),this.setEditingTarget(),this.setTopLeft(),this.initMarkerCanvas(),this.initOverlay(),this.attachEvents(),this.settings.displayMode==="popup"&&this.onPopupTargetResize(),le.isLicensed||this.addLogo(),this._isOpen=!0,this._isFocused=!0},We.prototype.show=function(){var Ae=this;this.styles.styleSheetRoot===void 0&&ne.styleSheetRoot!==void 0&&(this.styles.styleSheetRoot=ne.styleSheetRoot),this.setWindowHeight(),this.showUI(),this.open(),this.eventListeners.show.forEach(function(Se){return Se(new dt(Ae))})},We.prototype.render=function(){return Ce(this,void 0,void 0,function(){var Ae;return ue(this,function(Se){switch(Se.label){case 0:return this.setCurrentMarker(),(Ae=new ee).naturalSize=this.renderAtNaturalSize,Ae.imageType=this.renderImageType,Ae.imageQuality=this.renderImageQuality,Ae.markersOnly=this.renderMarkersOnly,Ae.width=this.renderWidth,Ae.height=this.renderHeight,[4,Ae.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 1:return Se.sent(),[4,Ae.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 2:return[2,Se.sent()]}})})},We.prototype.close=function(Ae){var Se=this;if(Ae===void 0&&(Ae=!1),this.isOpen){var Be=!1;Ae||this.eventListeners.beforeclose.forEach(function(Ke){var Ne=new dt(Se,!0);Ke(Ne),Ne.defaultPrevented&&(Be=!0)}),Be||(this.coverDiv&&this.closeUI(),this.targetObserver&&(this.targetObserver.unobserve(this.target),this.targetObserver.unobserve(this.editorCanvas)),this.settings.displayMode==="popup"&&window.removeEventListener("resize",this.setWindowHeight),this.eventListeners.close.forEach(function(Ke){return Ke(new dt(Se))}),this.detachEvents(),this._isOpen=!1)}},We.prototype.addMarkersToToolbar=function(){for(var Ae,Se=[],Be=0;Be<arguments.length;Be++)Se[Be]=arguments[Be];(Ae=this._availableMarkerTypes).push.apply(Ae,Se)},We.prototype.addRenderEventListener=function(Ae){this.addEventListener("render",function(Se){Ae(Se.dataUrl,Se.state)})},We.prototype.removeRenderEventListener=function(Ae){},We.prototype.addCloseEventListener=function(Ae){this.addEventListener("close",function(){Ae()})},We.prototype.removeCloseEventListener=function(Ae){},We.prototype.setupResizeObserver=function(){var Ae=this;this.settings.displayMode==="inline"?window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){Ae.resize(Ae.target.clientWidth,Ae.target.clientHeight)}),this.targetObserver.observe(this.target)):this.settings.displayMode==="popup"&&(window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){return Ae.onPopupTargetResize()}),this.targetObserver.observe(this.editorCanvas)),window.addEventListener("resize",this.setWindowHeight))},We.prototype.onPopupTargetResize=function(){var Ae=1*this.target.clientWidth/this.target.clientHeight,Se=this.editorCanvas.clientWidth/Ae>this.editorCanvas.clientHeight?this.editorCanvas.clientHeight*Ae:this.editorCanvas.clientWidth,Be=Se<this.editorCanvas.clientWidth?this.editorCanvas.clientHeight:this.editorCanvas.clientWidth/Ae;this.resize(Se,Be)},We.prototype.setWindowHeight=function(){this.windowHeight=window.innerHeight},We.prototype.resize=function(Ae,Se){this._isResizing=!0;var Be=Ae/this.imageWidth,Ke=Se/this.imageHeight;this.imageWidth=Math.round(Ae),this.imageHeight=Math.round(Se),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px",this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.settings.displayMode!=="popup"?this.coverDiv.style.width=this.imageWidth.toString()+"px":(this.setTopLeft(),this.positionMarkerImage()),this.toolbar!==void 0&&this.toolbar.adjustLayout(),this.positionLogo(),this.scaleMarkers(Be,Ke),this._isResizing=!1},We.prototype.scaleMarkers=function(Ae,Se){var Be,Ke=this;this._currentMarker&&this._currentMarker instanceof Qe?this._currentMarker.scale(Ae,Se):(Be=this._currentMarker,this.setCurrentMarker()),this.markers.forEach(function(Ne){Ne!==Ke._currentMarker&&Ne.scale(Ae,Se)}),Be!==void 0&&this.setCurrentMarker(Be)},We.prototype.setEditingTarget=function(){this.imageWidth=Math.round(this.target.clientWidth),this.imageHeight=Math.round(this.target.clientHeight),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px"},We.prototype.setTopLeft=function(){var Ae=this.editingTarget.getBoundingClientRect(),Se=this.editorCanvas.getBoundingClientRect();this.left=Ae.left-Se.left,this.top=Ae.top-Se.top},We.prototype.initMarkerCanvas=function(){this.markerImageHolder=document.createElement("div"),this.markerImageHolder.style.setProperty("touch-action","pinch-zoom"),this.markerImage=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.markerImage.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImage.style.pointerEvents="auto",this.markerImageHolder.style.position="absolute",this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.markerImageHolder.style.transformOrigin="top left",this.positionMarkerImage(),this.markerImageHolder.appendChild(this.markerImage),this.editorCanvas.appendChild(this.markerImageHolder)},We.prototype.addDefs=function(){for(var Ae,Se=[],Be=0;Be<arguments.length;Be++)Se[Be]=arguments[Be];this.defs=te.createDefs(),this.addDefsToImage(),(Ae=this.defs).append.apply(Ae,Se)},We.prototype.addDefsToImage=function(){this.defs&&this.markerImage.insertBefore(this.defs,this.markerImage.firstChild)},We.prototype.initOverlay=function(){this.overlayContainer=document.createElement("div"),this.overlayContainer.style.position="absolute",this.overlayContainer.style.left="0px",this.overlayContainer.style.top="0px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.overlayContainer.style.display="flex",this.markerImageHolder.appendChild(this.overlayContainer)},We.prototype.positionMarkerImage=function(){this.markerImageHolder.style.top=this.top/this.zoomLevel+"px",this.markerImageHolder.style.left=this.left/this.zoomLevel+"px"},We.prototype.attachEvents=function(){this.markerImage.addEventListener("pointerdown",this.onPointerDown),this.markerImage.addEventListener("dblclick",this.onDblClick),this.attachWindowEvents()},We.prototype.attachWindowEvents=function(){window.addEventListener("pointermove",this.onPointerMove),window.addEventListener("pointerup",this.onPointerUp),window.addEventListener("pointercancel",this.onPointerOut),window.addEventListener("pointerout",this.onPointerOut),window.addEventListener("pointerleave",this.onPointerUp),window.addEventListener("resize",this.onWindowResize),window.addEventListener("keyup",this.onKeyUp)},We.prototype.detachEvents=function(){this.markerImage.removeEventListener("pointerdown",this.onPointerDown),this.markerImage.removeEventListener("dblclick",this.onDblClick),this.detachWindowEvents()},We.prototype.detachWindowEvents=function(){window.removeEventListener("pointermove",this.onPointerMove),window.removeEventListener("pointerup",this.onPointerUp),window.removeEventListener("pointercancel",this.onPointerOut),window.removeEventListener("pointerout",this.onPointerOut),window.removeEventListener("pointerleave",this.onPointerUp),window.removeEventListener("resize",this.onWindowResize),window.removeEventListener("keyup",this.onKeyUp)},We.prototype.addLogo=function(){this.logoUI=document.createElement("div"),this.logoUI.style.display="inline-block",this.logoUI.style.margin="0px",this.logoUI.style.padding="0px",this.logoUI.style.fill="#333333";var Ae=document.createElement("a");Ae.href="https://markerjs.com/",Ae.target="_blank",Ae.innerHTML='<svg viewBox="0 0 112 96" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="1.414"><path fill="#e5f20d" fill-opacity=".647" d="M0 40.386h111.96V95.62H0z"/><path d="M93.61 61.452c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.591 1.048-1.481 0-2.222-.74-2.222-2.22 0-16.617-.533-29.347-1.604-38.192-1.068-8.842-2.92-13.265-5.552-13.265-4.443 0-10.94 15.509-19.497 46.52v.124c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.592 1.048-1.48 0-2.22-.74-2.22-2.22 0-3.29.165-8.392.493-15.302.33-7.732.494-13.82.494-18.262 0-6.17-.186-10.55-.556-13.142-.37-2.591-1.172-3.887-2.406-3.887-2.796 0-6.333 5.12-10.612 15.363C38.494 34.367 34.01 46.44 29.32 60.34l-1.11 3.209a5.714 5.714 0 01-1.42 2.097c-.617.578-1.295.864-2.036.864-.987 0-1.644-.081-1.974-.247-.328-.162-.533-.656-.617-1.48-.41-4.03-.74-9.418-.987-16.165-.163-1.728-.329-4.566-.494-8.515-.822-13.901-1.562-23.3-2.221-28.196-.657-4.893-.987-7.628-.987-8.205 0-.657.33-1.44.987-2.345.659-.903 1.276-1.357 1.85-1.357 1.319 0 2.387.947 3.21 2.838.411.906.863 4.526 1.357 10.859.493 6.335.905 14.19 1.233 23.568l.617 18.88c4.527-13.983 9.216-26.673 14.068-38.068C45.65 6.686 50.093.988 54.123.988c2.715 0 4.566 1.974 5.553 5.923.987 3.949 1.481 9.667 1.481 17.152 0 3.949-.081 9.625-.247 17.029l-.123 5.676c3.373-11.762 6.725-21.634 10.057-29.615 3.331-7.979 6.685-11.97 10.056-11.97 8.475 0 12.71 18.757 12.71 56.269z" fill-rule="nonzero"/></svg>',Ae.title="Powered by marker.js",Ae.style.display="grid",Ae.style.alignItems="center",Ae.style.justifyItems="center",Ae.style.padding="3px",Ae.style.width="20px",Ae.style.height="20px",this.logoUI.appendChild(Ae),this.editorCanvas.appendChild(this.logoUI),this.logoUI.style.position="absolute",this.logoUI.style.pointerEvents="all",this.positionLogo()},We.prototype.positionLogo=function(){this.logoUI&&(this.uiStyleSettings.logoPosition!=="right"?this.logoUI.style.left=this.markerImageHolder.offsetLeft+10+"px":this.logoUI.style.left=this.markerImageHolder.offsetLeft+this.markerImageHolder.offsetWidth-this.logoUI.clientWidth-10+"px",this.logoUI.style.top=this.markerImageHolder.offsetTop+this.markerImageHolder.offsetHeight-this.logoUI.clientHeight-10+"px")},We.prototype.overrideOverflow=function(){this.scrollXState=window.scrollX,this.scrollYState=window.scrollY,this.bodyOverflowState=document.body.style.overflow,window.scroll({top:0,left:0}),document.body.style.overflow="hidden"},We.prototype.restoreOverflow=function(){document.body.style.overflow=this.bodyOverflowState,window.scroll({top:this.scrollYState,left:this.scrollXState})},We.prototype.showUI=function(){switch(this.settings.displayMode==="popup"&&this.overrideOverflow(),this.coverDiv=document.createElement("div"),this.coverDiv.style.visibility=this._silentRenderMode?"hidden":"visible",this.coverDiv.className=this.styles.classNamePrefixBase+" "+this.styles.classNamePrefix,this.coverDiv.style.fontSize="16px",this.coverDiv.style.userSelect="none",this.settings.displayMode){case"inline":this.coverDiv.style.position="absolute";var Ae=this.settings.uiOffsetTop!==void 0?this.target.offsetTop+this.settings.uiOffsetTop:this.target.offsetTop>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=Ae+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px",this.coverDiv.style.width=this.target.offsetWidth.toString()+"px",this.coverDiv.style.zIndex=this.uiStyleSettings.zIndex!==void 0?this.uiStyleSettings.zIndex:"5";break;case"popup":this.coverDiv.style.position="absolute",this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=window.innerHeight+"px",this.coverDiv.style.backgroundColor="rgba(0, 0, 0, 0.75)",this.coverDiv.style.zIndex=this.uiStyleSettings.zIndex!==void 0?this.uiStyleSettings.zIndex:"1000",this.coverDiv.style.display="flex"}this.targetRoot.appendChild(this.coverDiv),this.uiDiv=document.createElement("div"),this.uiDiv.style.display="flex",this.uiDiv.style.flexDirection="column",this.uiDiv.style.flexGrow="2",this.uiDiv.style.margin=this.settings.displayMode==="popup"?this.settings.popupMargin+"px":"0px",this.uiDiv.style.border="0px",this.coverDiv.appendChild(this.uiDiv),this.toolbar=new x(this.uiDiv,this.settings.displayMode,this._availableMarkerTypes,this.uiStyleSettings,this.styles),this.toolbar.addButtonClickListener(this.toolbarButtonClicked),this.toolbar.show(this._silentRenderMode||this.uiStyleSettings.hideToolbar?"hidden":"visible"),this.contentDiv=document.createElement("div"),this.contentDiv.style.display="flex",this.contentDiv.style.flexDirection="row",this.contentDiv.style.flexGrow="2",this.contentDiv.style.flexShrink="1",this.settings.displayMode==="popup"&&(this.contentDiv.style.backgroundColor=this.uiStyleSettings.canvasBackgroundColor,this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.uiStyleSettings.toolbarHeight+"px",this.contentDiv.style.maxWidth="calc(100vw - "+2*this.settings.popupMargin+"px)"),this.contentDiv.style.overflow="auto",this.uiDiv.appendChild(this.contentDiv),this.editorCanvas=document.createElement("div"),this.editorCanvas.style.flexGrow="2",this.editorCanvas.style.flexShrink="1",this.editorCanvas.style.position="relative",this.editorCanvas.style.overflow="hidden",this.editorCanvas.style.display="flex",this.settings.displayMode==="popup"&&(this.editorCanvas.style.alignItems="center",this.editorCanvas.style.justifyContent="center"),this.editorCanvas.style.pointerEvents="none",this.editorCanvas.style.transformOrigin="left top",this.editorCanvas.style.transform="scale("+this.zoomLevel+")",this.contentDiv.appendChild(this.editorCanvas),this.editingTarget=this.target instanceof HTMLImageElement?document.createElement("img"):document.createElement("canvas"),this.settings.uiOffsetTop===void 0&&this.target.offsetTop<this.styles.settings.toolbarHeight&&(this.editingTarget.style.marginTop=this.target.offsetTop-this.styles.settings.toolbarHeight+"px"),this.editorCanvas.appendChild(this.editingTarget),this.toolbox=new re(this.uiDiv,this.settings.displayMode,this.uiStyleSettings,this.styles),this.toolbox.show(this._silentRenderMode||this.uiStyleSettings.hideToolbox?"hidden":"visible")},We.prototype.closeUI=function(){this.settings.displayMode==="popup"&&this.restoreOverflow(),this.targetRoot.removeChild(this.coverDiv)},We.prototype.removeMarker=function(Ae){this.markerImage.removeChild(Ae.container),this.markers.indexOf(Ae)>-1&&this.markers.splice(this.markers.indexOf(Ae),1),Ae.dispose()},We.prototype.switchToSelectMode=function(){this.mode="select",this.hideNotesEditor(),this._currentMarker!==void 0&&(this._currentMarker.state!=="new"?this._currentMarker.select():(this.removeMarker(this._currentMarker),this.setCurrentMarker(),this.markerImage.style.cursor="default"),this.addUndoStep())},We.prototype.toolbarButtonClicked=function(Ae,Se){if(Ae==="marker"&&Se!==void 0)this.createNewMarker(Se);else if(Ae==="action")switch(Se){case"select":this.switchToSelectMode(),this.switchToSelectMode();break;case"delete":this.deleteSelectedMarker();break;case"clear":this.clear();break;case"undo":this.undo();break;case"redo":this.redo();break;case"zoom":this.stepZoom();break;case"zoom-out":this.zoomLevel=1;break;case"notes":this.notesArea===void 0?(this.switchToSelectMode(),this.zoomLevel=1,this.showNotesEditor()):this.switchToSelectMode();break;case"close":this.close();break;case"render":this.switchToSelectMode(),this.startRenderAndClose()}},We.prototype.deleteSelectedMarker=function(){var Ae=this;if(this._currentMarker!==void 0){var Se=!1;if(this.eventListeners.markerbeforedelete.forEach(function(Ke){var Ne=new xt(Ae,Ae._currentMarker,!0);Ke(Ne),Ne.defaultPrevented&&(Se=!0)}),!Se){var Be=this._currentMarker;this._currentMarker.dispose(),this.markerImage.removeChild(this._currentMarker.container),this.markers.splice(this.markers.indexOf(this._currentMarker),1),this.setCurrentMarker(),this.addUndoStep(),this.eventListeners.markerdelete.forEach(function(Ke){return Ke(new xt(Ae,Be))})}}},We.prototype.clear=function(){var Ae=this,Se=!1;if(this.markers.length>0&&(this.eventListeners.markerbeforedelete.forEach(function(De){var we=new xt(Ae,void 0,!0);De(we),we.defaultPrevented&&(Se=!0)}),!Se)){this.setCurrentMarker();for(var Be=function(De){var we=Ke.markers[De];Ke.setCurrentMarker(Ke.markers[De]),Ke._currentMarker.dispose(),Ke.markerImage.removeChild(Ke._currentMarker.container),Ke.markers.splice(Ke.markers.indexOf(Ke._currentMarker),1),Ke.eventListeners.markerdelete.forEach(function(Le){return Le(new xt(Ae,we))})},Ke=this,Ne=this.markers.length-1;Ne>=0;Ne--)Be(Ne);this.addUndoStep()}},Object.defineProperty(We.prototype,"isNotesAreaOpen",{get:function(){return this.notesArea!==void 0},enumerable:!1,configurable:!0}),We.prototype.showNotesEditor=function(){var Ae;this._currentMarker!==void 0&&(this.overlayContainer.innerHTML="",this.notesArea=document.createElement("textarea"),this.notesArea.className=this.uiStyleSettings.notesAreaStyleClassName,this.notesArea.style.pointerEvents="auto",this.notesArea.style.alignSelf="stretch",this.notesArea.style.width="100%",this.notesArea.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.notesArea.value=(Ae=this._currentMarker.notes)!==null&&Ae!==void 0?Ae:"",this.overlayContainer.appendChild(this.notesArea))},We.prototype.hideNotesEditor=function(){this.isNotesAreaOpen&&(this._currentMarker!==void 0&&(this._currentMarker.notes=this.notesArea.value.trim()!==""?this.notesArea.value:void 0),this.overlayContainer.removeChild(this.notesArea),this.notesArea=void 0)},We.prototype.selectLastMarker=function(){this.markers.length>0?this.setCurrentMarker(this.markers[this.markers.length-1]):this.setCurrentMarker()},We.prototype.addUndoStep=function(){var Ae=this;if(this._currentMarker===void 0||this._currentMarker.state!=="edit"){var Se=this.getState(),Be=this.undoRedoManager.getLastUndoStep();if(!Be||Be.width===Se.width&&Be.height===Se.height){var Ke=this.undoRedoManager.undoStepCount;this.undoRedoManager.addUndoStep(Se),Ke<this.undoRedoManager.undoStepCount&&this.eventListeners.statechange.forEach(function(Ne){return Ne(new dt(Ae))})}else this.undoRedoManager.replaceLastUndoStep(Se),this.eventListeners.statechange.forEach(function(Ne){return Ne(new dt(Ae))})}},We.prototype.undo=function(){this.switchToSelectMode(),this.addUndoStep(),this.undoStep()},We.prototype.undoStep=function(){var Ae=this,Se=this.undoRedoManager.undo();Se!==void 0&&(this.restoreState(Se),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach(function(Be){return Be(new dt(Ae))}))},We.prototype.redo=function(){this.switchToSelectMode(),this.redoStep()},We.prototype.redoStep=function(){var Ae=this,Se=this.undoRedoManager.redo();Se!==void 0&&(this.restoreState(Se),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach(function(Be){return Be(new dt(Ae))}))},We.prototype.stepZoom=function(){var Ae=this.zoomSteps.indexOf(this.zoomLevel);this.zoomLevel=Ae<this.zoomSteps.length-1?this.zoomSteps[Ae+1]:this.zoomSteps[0]},We.prototype.panTo=function(Ae){this.contentDiv.scrollBy({left:this.prevPanPoint.x-Ae.x,top:this.prevPanPoint.y-Ae.y}),this.prevPanPoint=Ae},We.prototype.startRenderAndClose=function(){return Ce(this,void 0,void 0,function(){var Ae,Se,Be=this;return ue(this,function(Ke){switch(Ke.label){case 0:return[4,this.render()];case 1:return Ae=Ke.sent(),Se=this.getState(),this.eventListeners.render.forEach(function(Ne){return Ne(new Rt(Be,Ae,Se))}),this.close(!0),[2]}})})},We.prototype.getState=function(Ae){Ae===!0&&this.setCurrentMarker();var Se={width:this.imageWidth,height:this.imageHeight,markers:[]};return this.markers.forEach(function(Be){return Se.markers.push(Be.getState())}),Se},We.prototype.restoreState=function(Ae){var Se=this;for(this.markers.splice(0);this.markerImage.lastChild;)this.markerImage.removeChild(this.markerImage.lastChild);Ae.markers.forEach(function(Be){var Ke=Se._availableMarkerTypes.find(function(De){return De.typeName===Be.typeName});if(Ke!==void 0){var Ne=Se.addNewMarker(Ke);Ne.restoreState(Be),Se.markers.push(Ne)}}),Ae.width&&Ae.height&&(Ae.width!==this.imageWidth||Ae.height!==this.imageHeight)&&this.scaleMarkers(this.imageWidth/Ae.width,this.imageHeight/Ae.height),this.eventListeners.restorestate.forEach(function(Be){return Be(new dt(Se))})},We.prototype.addNewMarker=function(Ae){var Se=te.createGroup();return this.markerImage.appendChild(Se),new Ae(Se,this.overlayContainer,this.settings)},We.prototype.createNewMarker=function(Ae){var Se,Be=this;(Se=typeof Ae=="string"?this._availableMarkerTypes.find(function(Ke){return Ke.typeName===Ae}):Ae)&&(this.setCurrentMarker(),this.addUndoStep(),this._currentMarker=this.addNewMarker(Se),this._currentMarker.onMarkerCreated=this.markerCreated,this._currentMarker.onColorChanged=this.colorChanged,this._currentMarker.onFillColorChanged=this.fillColorChanged,this._currentMarker.onStateChanged=this.markerStateChanged,this.markerImage.style.cursor="crosshair",this.toolbar.setActiveMarkerButton(Se.typeName),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this.eventListeners.markercreating.forEach(function(Ke){return Ke(new xt(Be,Be._currentMarker))}))},We.prototype.markerCreated=function(Ae){var Se=this;this.mode="select",this.markerImage.style.cursor="default",this.markers.push(Ae),this.setCurrentMarker(Ae),Ae instanceof Xe&&this.settings.newFreehandMarkerOnPointerUp?this.createNewMarker(Xe):this.toolbar.setSelectMode(),this.addUndoStep(),this.eventListeners.markercreate.forEach(function(Be){return Be(new xt(Se,Se._currentMarker))})},We.prototype.colorChanged=function(Ae){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultColor=Ae,this.settings.defaultStrokeColor=Ae)},We.prototype.fillColorChanged=function(Ae){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultFillColor=Ae)},We.prototype.markerStateChanged=function(Ae){var Se=this;this.eventListeners.markerchange.forEach(function(Be){return Be(new xt(Se,Ae))})},We.prototype.setCurrentMarker=function(Ae){var Se=this;this._currentMarker!==Ae&&this._currentMarker!==void 0&&(this._currentMarker.deselect(),this.toolbar.setCurrentMarker(),this.toolbox.setPanelButtons([]),this._isResizing||this.eventListeners.markerdeselect.forEach(function(Be){return Be(new xt(Se,Se._currentMarker))})),this._currentMarker=Ae,this._currentMarker===void 0||this._currentMarker.isSelected||(this._currentMarker.state!=="new"&&this._currentMarker.select(),this.toolbar.setCurrentMarker(this._currentMarker),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this._isResizing||this.eventListeners.markerselect.forEach(function(Be){return Be(new xt(Se,Se._currentMarker))}))},We.prototype.onPointerDown=function(Ae){if(this._isFocused||this.focus(),this.touchPoints++,this.touchPoints===1||Ae.pointerType!=="touch")if(this._currentMarker===void 0||this._currentMarker.state!=="new"&&this._currentMarker.state!=="creating"){if(this.mode==="select"){var Se=this.markers.find(function(Be){return Be.ownsTarget(Ae.target)});Se!==void 0?(this.setCurrentMarker(Se),this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(Ae.clientX,Ae.clientY),Ae.target)):(this.setCurrentMarker(),this.isDragging=!0,this.prevPanPoint={x:Ae.clientX,y:Ae.clientY})}}else this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(Ae.clientX,Ae.clientY))},We.prototype.onDblClick=function(Ae){if(this._isFocused||this.focus(),this.mode==="select"){var Se=this.markers.find(function(Be){return Be.ownsTarget(Ae.target)});Se!==void 0&&Se!==this._currentMarker&&this.setCurrentMarker(Se),this._currentMarker!==void 0?this._currentMarker.dblClick(this.clientToLocalCoordinates(Ae.clientX,Ae.clientY),Ae.target):this.setCurrentMarker()}},We.prototype.onPointerMove=function(Ae){this.touchPoints!==1&&Ae.pointerType==="touch"||(this._currentMarker!==void 0||this.isDragging)&&(this._currentMarker!==void 0&&this._currentMarker.state==="edit"||Ae.preventDefault(),this._currentMarker!==void 0?this._currentMarker.manipulate(this.clientToLocalCoordinates(Ae.clientX,Ae.clientY)):this.zoomLevel>1&&this.panTo({x:Ae.clientX,y:Ae.clientY}))},We.prototype.onPointerUp=function(Ae){this.touchPoints>0&&this.touchPoints--,this.touchPoints===0&&this.isDragging&&this._currentMarker!==void 0&&this._currentMarker.pointerUp(this.clientToLocalCoordinates(Ae.clientX,Ae.clientY)),this.isDragging=!1,this.addUndoStep()},We.prototype.onPointerOut=function(){this.touchPoints>0&&this.touchPoints--},We.prototype.onKeyUp=function(Ae){this._currentMarker===void 0||this.notesArea!==void 0||Ae.key!=="Delete"&&Ae.key!=="Backspace"||this.deleteSelectedMarker()},We.prototype.clientToLocalCoordinates=function(Ae,Se){var Be=this.markerImage.getBoundingClientRect();return{x:(Ae-Be.left)/this.zoomLevel,y:(Se-Be.top)/this.zoomLevel}},We.prototype.onWindowResize=function(){this.positionUI()},We.prototype.positionUI=function(){switch(this.setTopLeft(),this.settings.displayMode){case"inline":var Ae=this.target.getClientRects().item(0).y>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=Ae+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px";break;case"popup":this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=this.windowHeight+"px",this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.styles.settings.toolbarHeight+"px"}this.positionMarkerImage(),this.positionLogo()},We.prototype.addLicenseKey=function(Ae){le.addKey(Ae)},We.prototype.addEventListener=function(Ae,Se){this.eventListeners.addEventListener(Ae,Se)},We.prototype.removeEventListener=function(Ae,Se){this.eventListeners.removeEventListener(Ae,Se)},We.prototype.renderState=function(Ae){this._silentRenderMode=!0,this.settings.displayMode="inline",this.isOpen||this.show(),this.restoreState(Ae),this.startRenderAndClose(),this._silentRenderMode=!1},Object.defineProperty(We.prototype,"isFocused",{get:function(){return this._isFocused},enumerable:!1,configurable:!0}),We.prototype.focus=function(){var Ae=this;this._isFocused||(this.attachWindowEvents(),this._isFocused=!0,this._previousCurrentMarker!==void 0&&this.setCurrentMarker(this._previousCurrentMarker),this.eventListeners.focus.forEach(function(Se){return Se(new dt(Ae))}))},We.prototype.blur=function(){var Ae=this;this._isFocused&&(this.detachWindowEvents(),this._isFocused=!1,this._previousCurrentMarker=this._currentMarker,this.setCurrentMarker(),this.eventListeners.blur.forEach(function(Se){return Se(new dt(Ae))}))},We.instanceCounter=0,We}()},66042:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return Qe}});var ce=be(27247),ie=be(11913),Ce=be(43403),ue=be(34280),se=be(59301),te=se.createContext(null),le=se.createContext({}),ee=te,ne=be(74430),E=be(32855),b=be(92310),z=be.n(b),x=be(77900),re=be(10228),ae=be(26112),oe=be(43079),ve=be(8654),ye=["prefixCls","className","containerRef"],me=function(ot){var He=ot.prefixCls,rt=ot.className,Ye=ot.containerRef,ut=(0,oe.Z)(ot,ye),Ge=se.useContext(le),ze=Ge.panel,Ve=(0,ve.x1)(ze,Ye);return se.createElement("div",(0,E.Z)({className:z()("".concat(He,"-content"),rt),role:"dialog",ref:Ve},(0,ae.Z)(ot,{aria:!0}),{"aria-modal":"true"},ut))},ge=me,_e=be(48736);function he(Xe){return typeof Xe=="string"&&String(Number(Xe))===Xe?((0,_e.ZP)(!1,"Invalid value type of `width` or `height` which should be number type instead."),Number(Xe)):Xe}function pe(Xe){warning(!("wrapperClassName"in Xe),"'wrapperClassName' is removed. Please use 'rootClassName' instead."),warning(canUseDom()||!Xe.open,"Drawer with 'open' in SSR is not work since no place to createPortal. Please move to 'useEffect' instead.")}var ke={width:0,height:0,overflow:"hidden",outline:"none",position:"absolute"};function Te(Xe,ot){var He,rt,Ye,ut=Xe.prefixCls,Ge=Xe.open,ze=Xe.placement,Ve=Xe.inline,$e=Xe.push,nt=Xe.forceRender,et=Xe.autoFocus,pt=Xe.keyboard,ct=Xe.classNames,Ot=Xe.rootClassName,dt=Xe.rootStyle,Rt=Xe.zIndex,xt=Xe.className,gt=Xe.id,_t=Xe.style,We=Xe.motion,Ae=Xe.width,Se=Xe.height,Be=Xe.children,Ke=Xe.mask,Ne=Xe.maskClosable,De=Xe.maskMotion,we=Xe.maskClassName,Le=Xe.maskStyle,Ue=Xe.afterOpenChange,Me=Xe.onClose,Re=Xe.onMouseEnter,tt=Xe.onMouseOver,lt=Xe.onMouseLeave,Nt=Xe.onClick,Ct=Xe.onKeyDown,vt=Xe.onKeyUp,Pt=Xe.styles,Ht=Xe.drawerRender,jt=se.useRef(),yt=se.useRef(),Yt=se.useRef();se.useImperativeHandle(ot,function(){return jt.current});var Lt=function(yn){var Hn=yn.keyCode,dr=yn.shiftKey;switch(Hn){case re.Z.TAB:{if(Hn===re.Z.TAB){if(!dr&&document.activeElement===Yt.current){var Mn;(Mn=yt.current)===null||Mn===void 0||Mn.focus({preventScroll:!0})}else if(dr&&document.activeElement===yt.current){var Cn;(Cn=Yt.current)===null||Cn===void 0||Cn.focus({preventScroll:!0})}}break}case re.Z.ESC:{Me&&pt&&(yn.stopPropagation(),Me(yn));break}}};se.useEffect(function(){if(Ge&&et){var Nn;(Nn=jt.current)===null||Nn===void 0||Nn.focus({preventScroll:!0})}},[Ge]);var Kt=se.useState(!1),sn=(0,ie.Z)(Kt,2),wn=sn[0],Vt=sn[1],Rn=se.useContext(ee),Gn;typeof $e=="boolean"?Gn=$e?{}:{distance:0}:Gn=$e||{};var Zn=(He=(rt=(Ye=Gn)===null||Ye===void 0?void 0:Ye.distance)!==null&&rt!==void 0?rt:Rn==null?void 0:Rn.pushDistance)!==null&&He!==void 0?He:180,tr=se.useMemo(function(){return{pushDistance:Zn,push:function(){Vt(!0)},pull:function(){Vt(!1)}}},[Zn]);se.useEffect(function(){if(Ge){var Nn;Rn==null||(Nn=Rn.push)===null||Nn===void 0||Nn.call(Rn)}else{var yn;Rn==null||(yn=Rn.pull)===null||yn===void 0||yn.call(Rn)}},[Ge]),se.useEffect(function(){return function(){var Nn;Rn==null||(Nn=Rn.pull)===null||Nn===void 0||Nn.call(Rn)}},[]);var hr=Ke&&se.createElement(x.default,(0,E.Z)({key:"mask"},De,{visible:Ge}),function(Nn,yn){var Hn=Nn.className,dr=Nn.style;return se.createElement("div",{className:z()("".concat(ut,"-mask"),Hn,ct==null?void 0:ct.mask,we),style:(0,ce.Z)((0,ce.Z)((0,ce.Z)({},dr),Le),Pt==null?void 0:Pt.mask),onClick:Ne&&Ge?Me:void 0,ref:yn})}),ur=typeof We=="function"?We(ze):We,zn={};if(wn&&Zn)switch(ze){case"top":zn.transform="translateY(".concat(Zn,"px)");break;case"bottom":zn.transform="translateY(".concat(-Zn,"px)");break;case"left":zn.transform="translateX(".concat(Zn,"px)");break;default:zn.transform="translateX(".concat(-Zn,"px)");break}ze==="left"||ze==="right"?zn.width=he(Ae):zn.height=he(Se);var Bn={onMouseEnter:Re,onMouseOver:tt,onMouseLeave:lt,onClick:Nt,onKeyDown:Ct,onKeyUp:vt},ir=se.createElement(x.default,(0,E.Z)({key:"panel"},ur,{visible:Ge,forceRender:nt,onVisibleChanged:function(yn){Ue==null||Ue(yn)},removeOnLeave:!1,leavedClassName:"".concat(ut,"-content-wrapper-hidden")}),function(Nn,yn){var Hn=Nn.className,dr=Nn.style,Mn=se.createElement(ge,(0,E.Z)({id:gt,containerRef:yn,prefixCls:ut,className:z()(xt,ct==null?void 0:ct.content),style:(0,ce.Z)((0,ce.Z)({},_t),Pt==null?void 0:Pt.content)},(0,ae.Z)(Xe,{aria:!0}),Bn),Be);return se.createElement("div",(0,E.Z)({className:z()("".concat(ut,"-content-wrapper"),ct==null?void 0:ct.wrapper,Hn),style:(0,ce.Z)((0,ce.Z)((0,ce.Z)({},zn),dr),Pt==null?void 0:Pt.wrapper)},(0,ae.Z)(Xe,{data:!0})),Ht?Ht(Mn):Mn)}),Kn=(0,ce.Z)({},dt);return Rt&&(Kn.zIndex=Rt),se.createElement(ee.Provider,{value:tr},se.createElement("div",{className:z()(ut,"".concat(ut,"-").concat(ze),Ot,(0,ne.Z)((0,ne.Z)({},"".concat(ut,"-open"),Ge),"".concat(ut,"-inline"),Ve)),style:Kn,tabIndex:-1,ref:jt,onKeyDown:Lt},hr,se.createElement("div",{tabIndex:0,ref:yt,style:ke,"aria-hidden":"true","data-sentinel":"start"}),ir,se.createElement("div",{tabIndex:0,ref:Yt,style:ke,"aria-hidden":"true","data-sentinel":"end"})))}var Ee=se.forwardRef(Te),Oe=Ee,je=function(ot){var He=ot.open,rt=He===void 0?!1:He,Ye=ot.prefixCls,ut=Ye===void 0?"rc-drawer":Ye,Ge=ot.placement,ze=Ge===void 0?"right":Ge,Ve=ot.autoFocus,$e=Ve===void 0?!0:Ve,nt=ot.keyboard,et=nt===void 0?!0:nt,pt=ot.width,ct=pt===void 0?378:pt,Ot=ot.mask,dt=Ot===void 0?!0:Ot,Rt=ot.maskClosable,xt=Rt===void 0?!0:Rt,gt=ot.getContainer,_t=ot.forceRender,We=ot.afterOpenChange,Ae=ot.destroyOnClose,Se=ot.onMouseEnter,Be=ot.onMouseOver,Ke=ot.onMouseLeave,Ne=ot.onClick,De=ot.onKeyDown,we=ot.onKeyUp,Le=ot.panelRef,Ue=se.useState(!1),Me=(0,ie.Z)(Ue,2),Re=Me[0],tt=Me[1],lt=se.useState(!1),Nt=(0,ie.Z)(lt,2),Ct=Nt[0],vt=Nt[1];(0,ue.Z)(function(){vt(!0)},[]);var Pt=Ct?rt:!1,Ht=se.useRef(),jt=se.useRef();(0,ue.Z)(function(){Pt&&(jt.current=document.activeElement)},[Pt]);var yt=function(wn){var Vt;if(tt(wn),We==null||We(wn),!wn&&jt.current&&!((Vt=Ht.current)!==null&&Vt!==void 0&&Vt.contains(jt.current))){var Rn;(Rn=jt.current)===null||Rn===void 0||Rn.focus({preventScroll:!0})}},Yt=se.useMemo(function(){return{panel:Le}},[Le]);if(!_t&&!Re&&!Pt&&Ae)return null;var Lt={onMouseEnter:Se,onMouseOver:Be,onMouseLeave:Ke,onClick:Ne,onKeyDown:De,onKeyUp:we},Kt=(0,ce.Z)((0,ce.Z)({},ot),{},{open:Pt,prefixCls:ut,placement:ze,autoFocus:$e,keyboard:et,width:ct,mask:dt,maskClosable:xt,inline:gt===!1,afterOpenChange:yt,ref:Ht},Lt);return se.createElement(le.Provider,{value:Yt},se.createElement(Ce.Z,{open:Pt||_t||Re,autoDestroy:!1,getContainer:gt,autoLock:dt&&(Pt||Re)},se.createElement(Oe,Kt)))},Pe=je,Qe=Pe},91574:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return Nt}});var ce=be(32855),ie=be(27247),Ce=be(74430),ue=be(11913),se=be(34666),te=be(43079),le=be(92310),ee=be.n(le),ne=/margin|padding|width|height|max|min|offset/,E={left:!0,top:!0},b={cssFloat:1,styleFloat:1,float:1};function z(Ct){return Ct.nodeType===1?Ct.ownerDocument.defaultView.getComputedStyle(Ct,null):{}}function x(Ct,vt,Pt){if(vt=vt.toLowerCase(),Pt==="auto"){if(vt==="height")return Ct.offsetHeight;if(vt==="width")return Ct.offsetWidth}return vt in E||(E[vt]=ne.test(vt)),E[vt]?parseFloat(Pt)||0:Pt}function re(Ct,vt){var Pt=arguments.length,Ht=z(Ct);return vt=b[vt]?"cssFloat"in Ct.style?"cssFloat":"styleFloat":vt,Pt===1?Ht:x(Ct,vt,Ht[vt]||Ct.style[vt])}function ae(Ct,vt,Pt){var Ht=arguments.length;if(vt=b[vt]?"cssFloat"in Ct.style?"cssFloat":"styleFloat":vt,Ht===3)return typeof Pt=="number"&&ne.test(vt)&&(Pt="".concat(Pt,"px")),Ct.style[vt]=Pt,Pt;for(var jt in vt)vt.hasOwnProperty(jt)&&ae(Ct,jt,vt[jt]);return z(Ct)}function oe(Ct){return Ct===document.body?document.documentElement.clientWidth:Ct.offsetWidth}function ve(Ct){return Ct===document.body?window.innerHeight||document.documentElement.clientHeight:Ct.offsetHeight}function ye(){var Ct=Math.max(document.documentElement.scrollWidth,document.body.scrollWidth),vt=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);return{width:Ct,height:vt}}function me(){var Ct=document.documentElement.clientWidth,vt=window.innerHeight||document.documentElement.clientHeight;return{width:Ct,height:vt}}function ge(){return{scrollLeft:Math.max(document.documentElement.scrollLeft,document.body.scrollLeft),scrollTop:Math.max(document.documentElement.scrollTop,document.body.scrollTop)}}function _e(Ct){var vt=Ct.getBoundingClientRect(),Pt=document.documentElement;return{left:vt.left+(window.pageXOffset||Pt.scrollLeft)-(Pt.clientLeft||document.body.clientLeft||0),top:vt.top+(window.pageYOffset||Pt.scrollTop)-(Pt.clientTop||document.body.clientTop||0)}}var he=be(18929),pe=be(59301),ke=be(55311),Te=be(8224),Ee=be(10228),Oe=be(43403),je=be(77900),Pe=pe.createContext(null),Qe=function(vt){var Pt=vt.visible,Ht=vt.maskTransitionName,jt=vt.getContainer,yt=vt.prefixCls,Yt=vt.rootClassName,Lt=vt.icons,Kt=vt.countRender,sn=vt.showSwitch,wn=vt.showProgress,Vt=vt.current,Rn=vt.transform,Gn=vt.count,Zn=vt.scale,tr=vt.minScale,hr=vt.maxScale,ur=vt.closeIcon,zn=vt.onActive,Bn=vt.onClose,ir=vt.onZoomIn,Kn=vt.onZoomOut,Nn=vt.onRotateRight,yn=vt.onRotateLeft,Hn=vt.onFlipX,dr=vt.onFlipY,Mn=vt.onReset,Cn=vt.toolbarRender,$n=vt.zIndex,Jt=vt.image,Ie=(0,pe.useContext)(Pe),Ze=Lt.rotateLeft,qe=Lt.rotateRight,st=Lt.zoomIn,mt=Lt.zoomOut,Bt=Lt.close,kt=Lt.left,Ft=Lt.right,qt=Lt.flipX,En=Lt.flipY,Yn="".concat(yt,"-operations-operation");pe.useEffect(function(){var Tt=function(bn){bn.keyCode===Ee.Z.ESC&&Bn()};return Pt&&window.addEventListener("keydown",Tt),function(){window.removeEventListener("keydown",Tt)}},[Pt]);var At=function(jn,bn){jn.preventDefault(),jn.stopPropagation(),zn(bn)},St=pe.useCallback(function(Tt){var jn=Tt.type,bn=Tt.disabled,Fn=Tt.onClick,Un=Tt.icon;return pe.createElement("div",{key:jn,className:ee()(Yn,"".concat(yt,"-operations-operation-").concat(jn),(0,Ce.Z)({},"".concat(yt,"-operations-operation-disabled"),!!bn)),onClick:Fn},Un)},[Yn,yt]),an=sn?St({icon:kt,onClick:function(jn){return At(jn,-1)},type:"prev",disabled:Vt===0}):void 0,Wt=sn?St({icon:Ft,onClick:function(jn){return At(jn,1)},type:"next",disabled:Vt===Gn-1}):void 0,Et=St({icon:En,onClick:dr,type:"flipY"}),zt=St({icon:qt,onClick:Hn,type:"flipX"}),tn=St({icon:Ze,onClick:yn,type:"rotateLeft"}),nn=St({icon:qe,onClick:Nn,type:"rotateRight"}),gn=St({icon:mt,onClick:Kn,type:"zoomOut",disabled:Zn<=tr}),Sn=St({icon:st,onClick:ir,type:"zoomIn",disabled:Zn===hr}),Tn=pe.createElement("div",{className:"".concat(yt,"-operations")},Et,zt,tn,nn,gn,Sn);return pe.createElement(je.default,{visible:Pt,motionName:Ht},function(Tt){var jn=Tt.className,bn=Tt.style;return pe.createElement(Oe.Z,{open:!0,getContainer:jt!=null?jt:document.body},pe.createElement("div",{className:ee()("".concat(yt,"-operations-wrapper"),jn,Yt),style:(0,ie.Z)((0,ie.Z)({},bn),{},{zIndex:$n})},ur===null?null:pe.createElement("button",{className:"".concat(yt,"-close"),onClick:Bn},ur||Bt),sn&&pe.createElement(pe.Fragment,null,pe.createElement("div",{className:ee()("".concat(yt,"-switch-left"),(0,Ce.Z)({},"".concat(yt,"-switch-left-disabled"),Vt===0)),onClick:function(Un){return At(Un,-1)}},kt),pe.createElement("div",{className:ee()("".concat(yt,"-switch-right"),(0,Ce.Z)({},"".concat(yt,"-switch-right-disabled"),Vt===Gn-1)),onClick:function(Un){return At(Un,1)}},Ft)),pe.createElement("div",{className:"".concat(yt,"-footer")},wn&&pe.createElement("div",{className:"".concat(yt,"-progress")},Kt?Kt(Vt+1,Gn):"".concat(Vt+1," / ").concat(Gn)),Cn?Cn(Tn,(0,ie.Z)((0,ie.Z)({icons:{prevIcon:an,nextIcon:Wt,flipYIcon:Et,flipXIcon:zt,rotateLeftIcon:tn,rotateRightIcon:nn,zoomOutIcon:gn,zoomInIcon:Sn},actions:{onActive:zn,onFlipY:dr,onFlipX:Hn,onRotateLeft:yn,onRotateRight:Nn,onZoomOut:Kn,onZoomIn:ir,onReset:Mn,onClose:Bn},transform:Rn},Ie?{current:Vt,total:Gn}:{}),{},{image:Jt})):Tn)))})},Xe=Qe,ot=be(13697),He=be(16089),rt={x:0,y:0,rotate:0,scale:1,flipX:!1,flipY:!1};function Ye(Ct,vt,Pt,Ht){var jt=(0,pe.useRef)(null),yt=(0,pe.useRef)([]),Yt=(0,pe.useState)(rt),Lt=(0,ue.Z)(Yt,2),Kt=Lt[0],sn=Lt[1],wn=function(Zn){sn(rt),(0,ot.Z)(rt,Kt)||Ht==null||Ht({transform:rt,action:Zn})},Vt=function(Zn,tr){jt.current===null&&(yt.current=[],jt.current=(0,He.Z)(function(){sn(function(hr){var ur=hr;return yt.current.forEach(function(zn){ur=(0,ie.Z)((0,ie.Z)({},ur),zn)}),jt.current=null,Ht==null||Ht({transform:ur,action:tr}),ur})})),yt.current.push((0,ie.Z)((0,ie.Z)({},Kt),Zn))},Rn=function(Zn,tr,hr,ur,zn){var Bn=Ct.current,ir=Bn.width,Kn=Bn.height,Nn=Bn.offsetWidth,yn=Bn.offsetHeight,Hn=Bn.offsetLeft,dr=Bn.offsetTop,Mn=Zn,Cn=Kt.scale*Zn;Cn>Pt?(Cn=Pt,Mn=Pt/Kt.scale):Cn<vt&&(Cn=zn?Cn:vt,Mn=Cn/Kt.scale);var $n=hr!=null?hr:innerWidth/2,Jt=ur!=null?ur:innerHeight/2,Ie=Mn-1,Ze=Ie*ir*.5,qe=Ie*Kn*.5,st=Ie*($n-Kt.x-Hn),mt=Ie*(Jt-Kt.y-dr),Bt=Kt.x-(st-Ze),kt=Kt.y-(mt-qe);if(Zn<1&&Cn===1){var Ft=Nn*Cn,qt=yn*Cn,En=me(),Yn=En.width,At=En.height;Ft<=Yn&&qt<=At&&(Bt=0,kt=0)}Vt({x:Bt,y:kt,scale:Cn},tr)};return{transform:Kt,resetTransform:wn,updateTransform:Vt,dispatchZoomChange:Rn}}var ut=be(48736);function Ge(Ct,vt,Pt,Ht){var jt=vt+Pt,yt=(Pt-Ht)/2;if(Pt>Ht){if(vt>0)return(0,Ce.Z)({},Ct,yt);if(vt<0&&jt<Ht)return(0,Ce.Z)({},Ct,-yt)}else if(vt<0||jt>Ht)return(0,Ce.Z)({},Ct,vt<0?yt:-yt);return{}}function ze(Ct,vt,Pt,Ht){var jt=me(),yt=jt.width,Yt=jt.height,Lt=null;return Ct<=yt&&vt<=Yt?Lt={x:0,y:0}:(Ct>yt||vt>Yt)&&(Lt=(0,ie.Z)((0,ie.Z)({},Ge("x",Pt,Ct,yt)),Ge("y",Ht,vt,Yt))),Lt}var Ve=1,$e=1;function nt(Ct,vt,Pt,Ht,jt,yt,Yt){var Lt=jt.rotate,Kt=jt.scale,sn=jt.x,wn=jt.y,Vt=(0,pe.useState)(!1),Rn=(0,ue.Z)(Vt,2),Gn=Rn[0],Zn=Rn[1],tr=(0,pe.useRef)({diffX:0,diffY:0,transformX:0,transformY:0}),hr=function(Kn){!vt||Kn.button!==0||(Kn.preventDefault(),Kn.stopPropagation(),tr.current={diffX:Kn.pageX-sn,diffY:Kn.pageY-wn,transformX:sn,transformY:wn},Zn(!0))},ur=function(Kn){Pt&&Gn&&yt({x:Kn.pageX-tr.current.diffX,y:Kn.pageY-tr.current.diffY},"move")},zn=function(){if(Pt&&Gn){Zn(!1);var Kn=tr.current,Nn=Kn.transformX,yn=Kn.transformY,Hn=sn!==Nn&&wn!==yn;if(!Hn)return;var dr=Ct.current.offsetWidth*Kt,Mn=Ct.current.offsetHeight*Kt,Cn=Ct.current.getBoundingClientRect(),$n=Cn.left,Jt=Cn.top,Ie=Lt%180!==0,Ze=ze(Ie?Mn:dr,Ie?dr:Mn,$n,Jt);Ze&&yt((0,ie.Z)({},Ze),"dragRebound")}},Bn=function(Kn){if(!(!Pt||Kn.deltaY==0)){var Nn=Math.abs(Kn.deltaY/100),yn=Math.min(Nn,$e),Hn=Ve+yn*Ht;Kn.deltaY>0&&(Hn=Ve/Hn),Yt(Hn,"wheel",Kn.clientX,Kn.clientY)}};return(0,pe.useEffect)(function(){var ir,Kn,Nn,yn;if(vt){Nn=(0,Te.Z)(window,"mouseup",zn,!1),yn=(0,Te.Z)(window,"mousemove",ur,!1);try{window.top!==window.self&&(ir=(0,Te.Z)(window.top,"mouseup",zn,!1),Kn=(0,Te.Z)(window.top,"mousemove",ur,!1))}catch(Hn){(0,ut.Kp)(!1,"[rc-image] ".concat(Hn))}}return function(){var Hn,dr,Mn,Cn;(Hn=Nn)===null||Hn===void 0||Hn.remove(),(dr=yn)===null||dr===void 0||dr.remove(),(Mn=ir)===null||Mn===void 0||Mn.remove(),(Cn=Kn)===null||Cn===void 0||Cn.remove()}},[Pt,Gn,sn,wn,Lt,vt]),{isMoving:Gn,onMouseDown:hr,onMouseMove:ur,onMouseUp:zn,onWheel:Bn}}function et(Ct){return new Promise(function(vt){if(!Ct){vt(!1);return}var Pt=document.createElement("img");Pt.onerror=function(){return vt(!1)},Pt.onload=function(){return vt(!0)},Pt.src=Ct})}function pt(Ct){var vt=Ct.src,Pt=Ct.isCustomPlaceholder,Ht=Ct.fallback,jt=(0,pe.useState)(Pt?"loading":"normal"),yt=(0,ue.Z)(jt,2),Yt=yt[0],Lt=yt[1],Kt=(0,pe.useRef)(!1),sn=Yt==="error";(0,pe.useEffect)(function(){var Gn=!0;return et(vt).then(function(Zn){!Zn&&Gn&&Lt("error")}),function(){Gn=!1}},[vt]),(0,pe.useEffect)(function(){Pt&&!Kt.current?Lt("loading"):sn&&Lt("normal")},[vt]);var wn=function(){Lt("normal")},Vt=function(Zn){Kt.current=!1,Yt==="loading"&&Zn!==null&&Zn!==void 0&&Zn.complete&&(Zn.naturalWidth||Zn.naturalHeight)&&(Kt.current=!0,wn())},Rn=sn&&Ht?{src:Ht}:{onLoad:wn,src:vt};return[Vt,Rn,Yt]}function ct(Ct,vt){var Pt=Ct.x-vt.x,Ht=Ct.y-vt.y;return Math.hypot(Pt,Ht)}function Ot(Ct,vt,Pt,Ht){var jt=ct(Ct,Pt),yt=ct(vt,Ht);if(jt===0&&yt===0)return[Ct.x,Ct.y];var Yt=jt/(jt+yt),Lt=Ct.x+Yt*(vt.x-Ct.x),Kt=Ct.y+Yt*(vt.y-Ct.y);return[Lt,Kt]}function dt(Ct,vt,Pt,Ht,jt,yt,Yt){var Lt=jt.rotate,Kt=jt.scale,sn=jt.x,wn=jt.y,Vt=(0,pe.useState)(!1),Rn=(0,ue.Z)(Vt,2),Gn=Rn[0],Zn=Rn[1],tr=(0,pe.useRef)({point1:{x:0,y:0},point2:{x:0,y:0},eventType:"none"}),hr=function(Kn){tr.current=(0,ie.Z)((0,ie.Z)({},tr.current),Kn)},ur=function(Kn){if(vt){Kn.stopPropagation(),Zn(!0);var Nn=Kn.touches,yn=Nn===void 0?[]:Nn;yn.length>1?hr({point1:{x:yn[0].clientX,y:yn[0].clientY},point2:{x:yn[1].clientX,y:yn[1].clientY},eventType:"touchZoom"}):hr({point1:{x:yn[0].clientX-sn,y:yn[0].clientY-wn},eventType:"move"})}},zn=function(Kn){var Nn=Kn.touches,yn=Nn===void 0?[]:Nn,Hn=tr.current,dr=Hn.point1,Mn=Hn.point2,Cn=Hn.eventType;if(yn.length>1&&Cn==="touchZoom"){var $n={x:yn[0].clientX,y:yn[0].clientY},Jt={x:yn[1].clientX,y:yn[1].clientY},Ie=Ot(dr,Mn,$n,Jt),Ze=(0,ue.Z)(Ie,2),qe=Ze[0],st=Ze[1],mt=ct($n,Jt)/ct(dr,Mn);Yt(mt,"touchZoom",qe,st,!0),hr({point1:$n,point2:Jt,eventType:"touchZoom"})}else Cn==="move"&&(yt({x:yn[0].clientX-dr.x,y:yn[0].clientY-dr.y},"move"),hr({eventType:"move"}))},Bn=function(){if(Pt){if(Gn&&Zn(!1),hr({eventType:"none"}),Ht>Kt)return yt({x:0,y:0,scale:Ht},"touchZoom");var Kn=Ct.current.offsetWidth*Kt,Nn=Ct.current.offsetHeight*Kt,yn=Ct.current.getBoundingClientRect(),Hn=yn.left,dr=yn.top,Mn=Lt%180!==0,Cn=ze(Mn?Nn:Kn,Mn?Kn:Nn,Hn,dr);Cn&&yt((0,ie.Z)({},Cn),"dragRebound")}};return(0,pe.useEffect)(function(){var ir;return Pt&&vt&&(ir=(0,Te.Z)(window,"touchmove",function(Kn){return Kn.preventDefault()},{passive:!1})),function(){var Kn;(Kn=ir)===null||Kn===void 0||Kn.remove()}},[Pt,vt]),{isTouching:Gn,onTouchStart:ur,onTouchMove:zn,onTouchEnd:Bn}}var Rt=["fallback","src","imgRef"],xt=["prefixCls","src","alt","imageInfo","fallback","movable","onClose","visible","icons","rootClassName","closeIcon","getContainer","current","count","countRender","scaleStep","minScale","maxScale","transitionName","maskTransitionName","imageRender","imgCommonProps","toolbarRender","onTransform","onChange"],gt=function(vt){var Pt=vt.fallback,Ht=vt.src,jt=vt.imgRef,yt=(0,te.Z)(vt,Rt),Yt=pt({src:Ht,fallback:Pt}),Lt=(0,ue.Z)(Yt,2),Kt=Lt[0],sn=Lt[1];return pe.createElement("img",(0,ce.Z)({ref:function(Vt){jt.current=Vt,Kt(Vt)}},yt,sn))},_t=function(vt){var Pt=vt.prefixCls,Ht=vt.src,jt=vt.alt,yt=vt.imageInfo,Yt=vt.fallback,Lt=vt.movable,Kt=Lt===void 0?!0:Lt,sn=vt.onClose,wn=vt.visible,Vt=vt.icons,Rn=Vt===void 0?{}:Vt,Gn=vt.rootClassName,Zn=vt.closeIcon,tr=vt.getContainer,hr=vt.current,ur=hr===void 0?0:hr,zn=vt.count,Bn=zn===void 0?1:zn,ir=vt.countRender,Kn=vt.scaleStep,Nn=Kn===void 0?.5:Kn,yn=vt.minScale,Hn=yn===void 0?1:yn,dr=vt.maxScale,Mn=dr===void 0?50:dr,Cn=vt.transitionName,$n=Cn===void 0?"zoom":Cn,Jt=vt.maskTransitionName,Ie=Jt===void 0?"fade":Jt,Ze=vt.imageRender,qe=vt.imgCommonProps,st=vt.toolbarRender,mt=vt.onTransform,Bt=vt.onChange,kt=(0,te.Z)(vt,xt),Ft=(0,pe.useRef)(),qt=(0,pe.useContext)(Pe),En=qt&&Bn>1,Yn=qt&&Bn>=1,At=(0,pe.useState)(!0),St=(0,ue.Z)(At,2),an=St[0],Wt=St[1],Et=Ye(Ft,Hn,Mn,mt),zt=Et.transform,tn=Et.resetTransform,nn=Et.updateTransform,gn=Et.dispatchZoomChange,Sn=nt(Ft,Kt,wn,Nn,zt,nn,gn),Tn=Sn.isMoving,Tt=Sn.onMouseDown,jn=Sn.onWheel,bn=dt(Ft,Kt,wn,Hn,zt,nn,gn),Fn=bn.isTouching,Un=bn.onTouchStart,rr=bn.onTouchMove,pr=bn.onTouchEnd,Rr=zt.rotate,wr=zt.scale,Lr=ee()((0,Ce.Z)({},"".concat(Pt,"-moving"),Tn));(0,pe.useEffect)(function(){an||Wt(!0)},[an]);var Vr=function(){tn("close")},xr=function(){gn(Ve+Nn,"zoomIn")},Ir=function(){gn(Ve/(Ve+Nn),"zoomOut")},jr=function(){nn({rotate:Rr+90},"rotateRight")},ti=function(){nn({rotate:Rr-90},"rotateLeft")},di=function(){nn({flipX:!zt.flipX},"flipX")},wi=function(){nn({flipY:!zt.flipY},"flipY")},xi=function(){tn("reset")},ai=function(qr){var $r=ur+qr;!Number.isInteger($r)||$r<0||$r>Bn-1||(Wt(!1),tn(qr<0?"prev":"next"),Bt==null||Bt($r,ur))},Di=function(qr){!wn||!En||(qr.keyCode===Ee.Z.LEFT?ai(-1):qr.keyCode===Ee.Z.RIGHT&&ai(1))},_i=function(qr){wn&&(wr!==1?nn({x:0,y:0,scale:1},"doubleClick"):gn(Ve+Nn,"doubleClick",qr.clientX,qr.clientY))};(0,pe.useEffect)(function(){var Ar=(0,Te.Z)(window,"keydown",Di,!1);return function(){Ar.remove()}},[wn,En,ur]);var or=pe.createElement(gt,(0,ce.Z)({},qe,{width:vt.width,height:vt.height,imgRef:Ft,className:"".concat(Pt,"-img"),alt:jt,style:{transform:"translate3d(".concat(zt.x,"px, ").concat(zt.y,"px, 0) scale3d(").concat(zt.flipX?"-":"").concat(wr,", ").concat(zt.flipY?"-":"").concat(wr,", 1) rotate(").concat(Rr,"deg)"),transitionDuration:(!an||Fn)&&"0s"},fallback:Yt,src:Ht,onWheel:jn,onMouseDown:Tt,onDoubleClick:_i,onTouchStart:Un,onTouchMove:rr,onTouchEnd:pr,onTouchCancel:pr})),br=(0,ie.Z)({url:Ht,alt:jt},yt);return pe.createElement(pe.Fragment,null,pe.createElement(ke.Z,(0,ce.Z)({transitionName:$n,maskTransitionName:Ie,closable:!1,keyboard:!0,prefixCls:Pt,onClose:sn,visible:wn,classNames:{wrapper:Lr},rootClassName:Gn,getContainer:tr},kt,{afterClose:Vr}),pe.createElement("div",{className:"".concat(Pt,"-img-wrapper")},Ze?Ze(or,(0,ie.Z)({transform:zt,image:br},qt?{current:ur}:{})):or)),pe.createElement(Xe,{visible:wn,transform:zt,maskTransitionName:Ie,closeIcon:Zn,getContainer:tr,prefixCls:Pt,rootClassName:Gn,icons:Rn,countRender:ir,showSwitch:En,showProgress:Yn,current:ur,count:Bn,scale:wr,minScale:Hn,maxScale:Mn,toolbarRender:st,onActive:ai,onZoomIn:xr,onZoomOut:Ir,onRotateRight:jr,onRotateLeft:ti,onFlipX:di,onFlipY:wi,onClose:sn,onReset:xi,zIndex:kt.zIndex!==void 0?kt.zIndex+1:void 0,image:br}))},We=_t,Ae=be(3300),Se=["crossOrigin","decoding","draggable","loading","referrerPolicy","sizes","srcSet","useMap","alt"];function Be(Ct){var vt=pe.useState({}),Pt=(0,ue.Z)(vt,2),Ht=Pt[0],jt=Pt[1],yt=pe.useCallback(function(Lt,Kt){return jt(function(sn){return(0,ie.Z)((0,ie.Z)({},sn),{},(0,Ce.Z)({},Lt,Kt))}),function(){jt(function(sn){var wn=(0,ie.Z)({},sn);return delete wn[Lt],wn})}},[]),Yt=pe.useMemo(function(){return Ct?Ct.map(function(Lt){if(typeof Lt=="string")return{data:{src:Lt}};var Kt={};return Object.keys(Lt).forEach(function(sn){["src"].concat((0,Ae.Z)(Se)).includes(sn)&&(Kt[sn]=Lt[sn])}),{data:Kt}}):Object.keys(Ht).reduce(function(Lt,Kt){var sn=Ht[Kt],wn=sn.canPreview,Vt=sn.data;return wn&&Lt.push({data:Vt,id:Kt}),Lt},[])},[Ct,Ht]);return[Yt,yt,!!Ct]}var Ke=["visible","onVisibleChange","getContainer","current","movable","minScale","maxScale","countRender","closeIcon","onChange","onTransform","toolbarRender","imageRender"],Ne=["src"],De=function(vt){var Pt,Ht=vt.previewPrefixCls,jt=Ht===void 0?"rc-image-preview":Ht,yt=vt.children,Yt=vt.icons,Lt=Yt===void 0?{}:Yt,Kt=vt.items,sn=vt.preview,wn=vt.fallback,Vt=(0,se.Z)(sn)==="object"?sn:{},Rn=Vt.visible,Gn=Vt.onVisibleChange,Zn=Vt.getContainer,tr=Vt.current,hr=Vt.movable,ur=Vt.minScale,zn=Vt.maxScale,Bn=Vt.countRender,ir=Vt.closeIcon,Kn=Vt.onChange,Nn=Vt.onTransform,yn=Vt.toolbarRender,Hn=Vt.imageRender,dr=(0,te.Z)(Vt,Ke),Mn=Be(Kt),Cn=(0,ue.Z)(Mn,3),$n=Cn[0],Jt=Cn[1],Ie=Cn[2],Ze=(0,he.Z)(0,{value:tr}),qe=(0,ue.Z)(Ze,2),st=qe[0],mt=qe[1],Bt=(0,pe.useState)(!1),kt=(0,ue.Z)(Bt,2),Ft=kt[0],qt=kt[1],En=((Pt=$n[st])===null||Pt===void 0?void 0:Pt.data)||{},Yn=En.src,At=(0,te.Z)(En,Ne),St=(0,he.Z)(!!Rn,{value:Rn,onChange:function(Fn,Un){Gn==null||Gn(Fn,Un,st)}}),an=(0,ue.Z)(St,2),Wt=an[0],Et=an[1],zt=(0,pe.useState)(null),tn=(0,ue.Z)(zt,2),nn=tn[0],gn=tn[1],Sn=pe.useCallback(function(bn,Fn,Un,rr){var pr=Ie?$n.findIndex(function(Rr){return Rr.data.src===Fn}):$n.findIndex(function(Rr){return Rr.id===bn});mt(pr<0?0:pr),Et(!0),gn({x:Un,y:rr}),qt(!0)},[$n,Ie]);pe.useEffect(function(){Wt?Ft||mt(0):qt(!1)},[Wt]);var Tn=function(Fn,Un){mt(Fn),Kn==null||Kn(Fn,Un)},Tt=function(){Et(!1),gn(null)},jn=pe.useMemo(function(){return{register:Jt,onPreview:Sn}},[Jt,Sn]);return pe.createElement(Pe.Provider,{value:jn},yt,pe.createElement(We,(0,ce.Z)({"aria-hidden":!Wt,movable:hr,visible:Wt,prefixCls:jt,closeIcon:ir,onClose:Tt,mousePosition:nn,imgCommonProps:At,src:Yn,fallback:wn,icons:Lt,minScale:ur,maxScale:zn,getContainer:Zn,current:st,count:$n.length,countRender:Bn,onTransform:Nn,toolbarRender:yn,imageRender:Hn,onChange:Tn},dr)))},we=De,Le=0;function Ue(Ct,vt){var Pt=pe.useState(function(){return Le+=1,String(Le)}),Ht=(0,ue.Z)(Pt,1),jt=Ht[0],yt=pe.useContext(Pe),Yt={data:vt,canPreview:Ct};return pe.useEffect(function(){if(yt)return yt.register(jt,Yt)},[]),pe.useEffect(function(){yt&&yt.register(jt,Yt)},[Ct,vt]),jt}var Me=["src","alt","onPreviewClose","prefixCls","previewPrefixCls","placeholder","fallback","width","height","style","preview","className","onClick","onError","wrapperClassName","wrapperStyle","rootClassName"],Re=["src","visible","onVisibleChange","getContainer","mask","maskClassName","movable","icons","scaleStep","minScale","maxScale","imageRender","toolbarRender"],tt=function(vt){var Pt=vt.src,Ht=vt.alt,jt=vt.onPreviewClose,yt=vt.prefixCls,Yt=yt===void 0?"rc-image":yt,Lt=vt.previewPrefixCls,Kt=Lt===void 0?"".concat(Yt,"-preview"):Lt,sn=vt.placeholder,wn=vt.fallback,Vt=vt.width,Rn=vt.height,Gn=vt.style,Zn=vt.preview,tr=Zn===void 0?!0:Zn,hr=vt.className,ur=vt.onClick,zn=vt.onError,Bn=vt.wrapperClassName,ir=vt.wrapperStyle,Kn=vt.rootClassName,Nn=(0,te.Z)(vt,Me),yn=sn&&sn!==!0,Hn=(0,se.Z)(tr)==="object"?tr:{},dr=Hn.src,Mn=Hn.visible,Cn=Mn===void 0?void 0:Mn,$n=Hn.onVisibleChange,Jt=$n===void 0?jt:$n,Ie=Hn.getContainer,Ze=Ie===void 0?void 0:Ie,qe=Hn.mask,st=Hn.maskClassName,mt=Hn.movable,Bt=Hn.icons,kt=Hn.scaleStep,Ft=Hn.minScale,qt=Hn.maxScale,En=Hn.imageRender,Yn=Hn.toolbarRender,At=(0,te.Z)(Hn,Re),St=dr!=null?dr:Pt,an=(0,he.Z)(!!Cn,{value:Cn,onChange:Jt}),Wt=(0,ue.Z)(an,2),Et=Wt[0],zt=Wt[1],tn=pt({src:Pt,isCustomPlaceholder:yn,fallback:wn}),nn=(0,ue.Z)(tn,3),gn=nn[0],Sn=nn[1],Tn=nn[2],Tt=(0,pe.useState)(null),jn=(0,ue.Z)(Tt,2),bn=jn[0],Fn=jn[1],Un=(0,pe.useContext)(Pe),rr=!!tr,pr=function(){zt(!1),Fn(null)},Rr=ee()(Yt,Bn,Kn,(0,Ce.Z)({},"".concat(Yt,"-error"),Tn==="error")),wr=(0,pe.useMemo)(function(){var Ir={};return Se.forEach(function(jr){vt[jr]!==void 0&&(Ir[jr]=vt[jr])}),Ir},Se.map(function(Ir){return vt[Ir]})),Lr=(0,pe.useMemo)(function(){return(0,ie.Z)((0,ie.Z)({},wr),{},{src:St})},[St,wr]),Vr=Ue(rr,Lr),xr=function(jr){var ti=_e(jr.target),di=ti.left,wi=ti.top;Un?Un.onPreview(Vr,St,di,wi):(Fn({x:di,y:wi}),zt(!0)),ur==null||ur(jr)};return pe.createElement(pe.Fragment,null,pe.createElement("div",(0,ce.Z)({},Nn,{className:Rr,onClick:rr?xr:ur,style:(0,ie.Z)({width:Vt,height:Rn},ir)}),pe.createElement("img",(0,ce.Z)({},wr,{className:ee()("".concat(Yt,"-img"),(0,Ce.Z)({},"".concat(Yt,"-img-placeholder"),sn===!0),hr),style:(0,ie.Z)({height:Rn},Gn),ref:gn},Sn,{width:Vt,height:Rn,onError:zn})),Tn==="loading"&&pe.createElement("div",{"aria-hidden":"true",className:"".concat(Yt,"-placeholder")},sn),qe&&rr&&pe.createElement("div",{className:ee()("".concat(Yt,"-mask"),st),style:{display:(Gn==null?void 0:Gn.display)==="none"?"none":void 0}},qe)),!Un&&rr&&pe.createElement(We,(0,ce.Z)({"aria-hidden":!Et,visible:Et,prefixCls:Kt,onClose:pr,mousePosition:bn,src:St,alt:Ht,imageInfo:{width:Vt,height:Rn},fallback:wn,getContainer:Ze,icons:Bt,movable:mt,scaleStep:kt,minScale:Ft,maxScale:qt,rootClassName:Kn,imageRender:En,imgCommonProps:wr,toolbarRender:Yn},At)))};tt.PreviewGroup=we;var lt=tt,Nt=lt},23425:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ke}});var ce=be(74430),ie=be(32855),Ce=be(34666),ue=be(27247),se=be(11913),te=be(92310),le=be.n(te),ee=be(18929),ne=be(10228),E=be(26112),b=be(48736),z=be(59301),x=be(17119),re=[10,20,50,100],ae=function(Ee){var Oe=Ee.pageSizeOptions,je=Oe===void 0?re:Oe,Pe=Ee.locale,Qe=Ee.changeSize,Xe=Ee.pageSize,ot=Ee.goButton,He=Ee.quickGo,rt=Ee.rootPrefixCls,Ye=Ee.disabled,ut=Ee.buildOptionText,Ge=Ee.showSizeChanger,ze=Ee.sizeChangerRender,Ve=z.useState(""),$e=(0,se.Z)(Ve,2),nt=$e[0],et=$e[1],pt=function(){return!nt||Number.isNaN(nt)?void 0:Number(nt)},ct=typeof ut=="function"?ut:function(Se){return"".concat(Se," ").concat(Pe.items_per_page)},Ot=function(Be){et(Be.target.value)},dt=function(Be){ot||nt===""||(et(""),!(Be.relatedTarget&&(Be.relatedTarget.className.indexOf("".concat(rt,"-item-link"))>=0||Be.relatedTarget.className.indexOf("".concat(rt,"-item"))>=0))&&(He==null||He(pt())))},Rt=function(Be){nt!==""&&(Be.keyCode===ne.Z.ENTER||Be.type==="click")&&(et(""),He==null||He(pt()))},xt=function(){return je.some(function(Be){return Be.toString()===Xe.toString()})?je:je.concat([Xe]).sort(function(Be,Ke){var Ne=Number.isNaN(Number(Be))?0:Number(Be),De=Number.isNaN(Number(Ke))?0:Number(Ke);return Ne-De})},gt="".concat(rt,"-options");if(!Ge&&!He)return null;var _t=null,We=null,Ae=null;return Ge&&ze&&(_t=ze({disabled:Ye,size:Xe,onSizeChange:function(Be){Qe==null||Qe(Number(Be))},"aria-label":Pe.page_size,className:"".concat(gt,"-size-changer"),options:xt().map(function(Se){return{label:ct(Se),value:Se}})})),He&&(ot&&(Ae=typeof ot=="boolean"?z.createElement("button",{type:"button",onClick:Rt,onKeyUp:Rt,disabled:Ye,className:"".concat(gt,"-quick-jumper-button")},Pe.jump_to_confirm):z.createElement("span",{onClick:Rt,onKeyUp:Rt},ot)),We=z.createElement("div",{className:"".concat(gt,"-quick-jumper")},Pe.jump_to,z.createElement("input",{disabled:Ye,type:"text",value:nt,onChange:Ot,onKeyUp:Rt,onBlur:dt,"aria-label":Pe.page}),Pe.page,Ae)),z.createElement("li",{className:gt},_t,We)},oe=ae,ve=function(Ee){var Oe=Ee.rootPrefixCls,je=Ee.page,Pe=Ee.active,Qe=Ee.className,Xe=Ee.showTitle,ot=Ee.onClick,He=Ee.onKeyPress,rt=Ee.itemRender,Ye="".concat(Oe,"-item"),ut=le()(Ye,"".concat(Ye,"-").concat(je),(0,ce.Z)((0,ce.Z)({},"".concat(Ye,"-active"),Pe),"".concat(Ye,"-disabled"),!je),Qe),Ge=function(){ot(je)},ze=function(nt){He(nt,ot,je)},Ve=rt(je,"page",z.createElement("a",{rel:"nofollow"},je));return Ve?z.createElement("li",{title:Xe?String(je):null,className:ut,onClick:Ge,onKeyDown:ze,tabIndex:0},Ve):null},ye=ve,me=function(Ee,Oe,je){return je};function ge(){}function _e(Te){var Ee=Number(Te);return typeof Ee=="number"&&!Number.isNaN(Ee)&&isFinite(Ee)&&Math.floor(Ee)===Ee}function he(Te,Ee,Oe){var je=typeof Te=="undefined"?Ee:Te;return Math.floor((Oe-1)/je)+1}var pe=function(Ee){var Oe=Ee.prefixCls,je=Oe===void 0?"rc-pagination":Oe,Pe=Ee.selectPrefixCls,Qe=Pe===void 0?"rc-select":Pe,Xe=Ee.className,ot=Ee.current,He=Ee.defaultCurrent,rt=He===void 0?1:He,Ye=Ee.total,ut=Ye===void 0?0:Ye,Ge=Ee.pageSize,ze=Ee.defaultPageSize,Ve=ze===void 0?10:ze,$e=Ee.onChange,nt=$e===void 0?ge:$e,et=Ee.hideOnSinglePage,pt=Ee.align,ct=Ee.showPrevNextJumpers,Ot=ct===void 0?!0:ct,dt=Ee.showQuickJumper,Rt=Ee.showLessItems,xt=Ee.showTitle,gt=xt===void 0?!0:xt,_t=Ee.onShowSizeChange,We=_t===void 0?ge:_t,Ae=Ee.locale,Se=Ae===void 0?x.Z:Ae,Be=Ee.style,Ke=Ee.totalBoundaryShowSizeChanger,Ne=Ke===void 0?50:Ke,De=Ee.disabled,we=Ee.simple,Le=Ee.showTotal,Ue=Ee.showSizeChanger,Me=Ue===void 0?ut>Ne:Ue,Re=Ee.sizeChangerRender,tt=Ee.pageSizeOptions,lt=Ee.itemRender,Nt=lt===void 0?me:lt,Ct=Ee.jumpPrevIcon,vt=Ee.jumpNextIcon,Pt=Ee.prevIcon,Ht=Ee.nextIcon,jt=z.useRef(null),yt=(0,ee.Z)(10,{value:Ge,defaultValue:Ve}),Yt=(0,se.Z)(yt,2),Lt=Yt[0],Kt=Yt[1],sn=(0,ee.Z)(1,{value:ot,defaultValue:rt,postState:function(br){return Math.max(1,Math.min(br,he(void 0,Lt,ut)))}}),wn=(0,se.Z)(sn,2),Vt=wn[0],Rn=wn[1],Gn=z.useState(Vt),Zn=(0,se.Z)(Gn,2),tr=Zn[0],hr=Zn[1];(0,z.useEffect)(function(){hr(Vt)},[Vt]);var ur=nt!==ge,zn="current"in Ee,Bn=Math.max(1,Vt-(Rt?3:5)),ir=Math.min(he(void 0,Lt,ut),Vt+(Rt?3:5));function Kn(or,br){var Ar=or||z.createElement("button",{type:"button","aria-label":br,className:"".concat(je,"-item-link")});return typeof or=="function"&&(Ar=z.createElement(or,(0,ue.Z)({},Ee))),Ar}function Nn(or){var br=or.target.value,Ar=he(void 0,Lt,ut),qr;return br===""?qr=br:Number.isNaN(Number(br))?qr=tr:br>=Ar?qr=Ar:qr=Number(br),qr}function yn(or){return _e(or)&&or!==Vt&&_e(ut)&&ut>0}var Hn=ut>Lt?dt:!1;function dr(or){(or.keyCode===ne.Z.UP||or.keyCode===ne.Z.DOWN)&&or.preventDefault()}function Mn(or){var br=Nn(or);switch(br!==tr&&hr(br),or.keyCode){case ne.Z.ENTER:Jt(br);break;case ne.Z.UP:Jt(br-1);break;case ne.Z.DOWN:Jt(br+1);break;default:break}}function Cn(or){Jt(Nn(or))}function $n(or){var br=he(or,Lt,ut),Ar=Vt>br&&br!==0?br:Vt;Kt(or),hr(Ar),We==null||We(Vt,or),Rn(Ar),nt==null||nt(Ar,or)}function Jt(or){if(yn(or)&&!De){var br=he(void 0,Lt,ut),Ar=or;return or>br?Ar=br:or<1&&(Ar=1),Ar!==tr&&hr(Ar),Rn(Ar),nt==null||nt(Ar,Lt),Ar}return Vt}var Ie=Vt>1,Ze=Vt<he(void 0,Lt,ut);function qe(){Ie&&Jt(Vt-1)}function st(){Ze&&Jt(Vt+1)}function mt(){Jt(Bn)}function Bt(){Jt(ir)}function kt(or,br){if(or.key==="Enter"||or.charCode===ne.Z.ENTER||or.keyCode===ne.Z.ENTER){for(var Ar=arguments.length,qr=new Array(Ar>2?Ar-2:0),$r=2;$r<Ar;$r++)qr[$r-2]=arguments[$r];br.apply(void 0,qr)}}function Ft(or){kt(or,qe)}function qt(or){kt(or,st)}function En(or){kt(or,mt)}function Yn(or){kt(or,Bt)}function At(or){var br=Nt(or,"prev",Kn(Pt,"prev page"));return z.isValidElement(br)?z.cloneElement(br,{disabled:!Ie}):br}function St(or){var br=Nt(or,"next",Kn(Ht,"next page"));return z.isValidElement(br)?z.cloneElement(br,{disabled:!Ze}):br}function an(or){(or.type==="click"||or.keyCode===ne.Z.ENTER)&&Jt(tr)}var Wt=null,Et=(0,E.Z)(Ee,{aria:!0,data:!0}),zt=Le&&z.createElement("li",{className:"".concat(je,"-total-text")},Le(ut,[ut===0?0:(Vt-1)*Lt+1,Vt*Lt>ut?ut:Vt*Lt])),tn=null,nn=he(void 0,Lt,ut);if(et&&ut<=Lt)return null;var gn=[],Sn={rootPrefixCls:je,onClick:Jt,onKeyPress:kt,showTitle:gt,itemRender:Nt,page:-1},Tn=Vt-1>0?Vt-1:0,Tt=Vt+1<nn?Vt+1:nn,jn=dt&&dt.goButton,bn=(0,Ce.Z)(we)==="object"?we.readOnly:!we,Fn=jn,Un=null;we&&(jn&&(typeof jn=="boolean"?Fn=z.createElement("button",{type:"button",onClick:an,onKeyUp:an},Se.jump_to_confirm):Fn=z.createElement("span",{onClick:an,onKeyUp:an},jn),Fn=z.createElement("li",{title:gt?"".concat(Se.jump_to).concat(Vt,"/").concat(nn):null,className:"".concat(je,"-simple-pager")},Fn)),Un=z.createElement("li",{title:gt?"".concat(Vt,"/").concat(nn):null,className:"".concat(je,"-simple-pager")},bn?tr:z.createElement("input",{type:"text","aria-label":Se.jump_to,value:tr,disabled:De,onKeyDown:dr,onKeyUp:Mn,onChange:Mn,onBlur:Cn,size:3}),z.createElement("span",{className:"".concat(je,"-slash")},"/"),nn));var rr=Rt?1:2;if(nn<=3+rr*2){nn||gn.push(z.createElement(ye,(0,ie.Z)({},Sn,{key:"noPager",page:1,className:"".concat(je,"-item-disabled")})));for(var pr=1;pr<=nn;pr+=1)gn.push(z.createElement(ye,(0,ie.Z)({},Sn,{key:pr,page:pr,active:Vt===pr})))}else{var Rr=Rt?Se.prev_3:Se.prev_5,wr=Rt?Se.next_3:Se.next_5,Lr=Nt(Bn,"jump-prev",Kn(Ct,"prev page")),Vr=Nt(ir,"jump-next",Kn(vt,"next page"));Ot&&(Wt=Lr?z.createElement("li",{title:gt?Rr:null,key:"prev",onClick:mt,tabIndex:0,onKeyDown:En,className:le()("".concat(je,"-jump-prev"),(0,ce.Z)({},"".concat(je,"-jump-prev-custom-icon"),!!Ct))},Lr):null,tn=Vr?z.createElement("li",{title:gt?wr:null,key:"next",onClick:Bt,tabIndex:0,onKeyDown:Yn,className:le()("".concat(je,"-jump-next"),(0,ce.Z)({},"".concat(je,"-jump-next-custom-icon"),!!vt))},Vr):null);var xr=Math.max(1,Vt-rr),Ir=Math.min(Vt+rr,nn);Vt-1<=rr&&(Ir=1+rr*2),nn-Vt<=rr&&(xr=nn-rr*2);for(var jr=xr;jr<=Ir;jr+=1)gn.push(z.createElement(ye,(0,ie.Z)({},Sn,{key:jr,page:jr,active:Vt===jr})));if(Vt-1>=rr*2&&Vt!==3&&(gn[0]=z.cloneElement(gn[0],{className:le()("".concat(je,"-item-after-jump-prev"),gn[0].props.className)}),gn.unshift(Wt)),nn-Vt>=rr*2&&Vt!==nn-2){var ti=gn[gn.length-1];gn[gn.length-1]=z.cloneElement(ti,{className:le()("".concat(je,"-item-before-jump-next"),ti.props.className)}),gn.push(tn)}xr!==1&&gn.unshift(z.createElement(ye,(0,ie.Z)({},Sn,{key:1,page:1}))),Ir!==nn&&gn.push(z.createElement(ye,(0,ie.Z)({},Sn,{key:nn,page:nn})))}var di=At(Tn);if(di){var wi=!Ie||!nn;di=z.createElement("li",{title:gt?Se.prev_page:null,onClick:qe,tabIndex:wi?null:0,onKeyDown:Ft,className:le()("".concat(je,"-prev"),(0,ce.Z)({},"".concat(je,"-disabled"),wi)),"aria-disabled":wi},di)}var xi=St(Tt);if(xi){var ai,Di;we?(ai=!Ze,Di=Ie?0:null):(ai=!Ze||!nn,Di=ai?null:0),xi=z.createElement("li",{title:gt?Se.next_page:null,onClick:st,tabIndex:Di,onKeyDown:qt,className:le()("".concat(je,"-next"),(0,ce.Z)({},"".concat(je,"-disabled"),ai)),"aria-disabled":ai},xi)}var _i=le()(je,Xe,(0,ce.Z)((0,ce.Z)((0,ce.Z)((0,ce.Z)((0,ce.Z)({},"".concat(je,"-start"),pt==="start"),"".concat(je,"-center"),pt==="center"),"".concat(je,"-end"),pt==="end"),"".concat(je,"-simple"),we),"".concat(je,"-disabled"),De));return z.createElement("ul",(0,ie.Z)({className:_i,style:Be,ref:jt},Et),zt,di,we?Un:gn,xi,z.createElement(oe,{locale:Se,rootPrefixCls:je,disabled:De,selectPrefixCls:Qe,changeSize:$n,pageSize:Lt,pageSizeOptions:tt,quickGo:Hn?Jt:null,goButton:Fn,showSizeChanger:Me,sizeChangerRender:Re}))},ke=pe},6551:function(Xt,Mt,be){"use strict";be.d(Mt,{ZP:function(){return le}});var ce=be(11913),ie=be(59301),Ce=be(47273),ue=0,se=(0,Ce.Z)();function te(){var ee;return se?(ee=ue,ue+=1):ee="TEST_OR_SSR",ee}function le(ee){var ne=ie.useState(),E=(0,ce.Z)(ne,2),b=E[0],z=E[1];return ie.useEffect(function(){z("rc_select_".concat(te()))},[]),ee||b}},37463:function(Xt,Mt,be){"use strict";be.d(Mt,{Ac:function(){return yt},Xo:function(){return Lt},Wx:function(){return sn},ZP:function(){return Yn},lk:function(){return ge}});var ce=be(32855),ie=be(3300),Ce=be(74430),ue=be(27247),se=be(11913),te=be(43079),le=be(34666),ee=be(18929),ne=be(48736),E=be(59301),b=be(92310),z=be.n(b),x=be(34280),re=be(49658),ae=be(8654),oe=function(St){var an=St.className,Wt=St.customizeIcon,Et=St.customizeIconProps,zt=St.children,tn=St.onMouseDown,nn=St.onClick,gn=typeof Wt=="function"?Wt(Et):Wt;return E.createElement("span",{className:an,onMouseDown:function(Tn){Tn.preventDefault(),tn==null||tn(Tn)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:nn,"aria-hidden":!0},gn!==void 0?gn:E.createElement("span",{className:z()(an.split(/\s+/).map(function(Sn){return"".concat(Sn,"-icon")}))},zt))},ve=oe,ye=function(St,an,Wt,Et,zt){var tn=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,nn=arguments.length>6?arguments[6]:void 0,gn=arguments.length>7?arguments[7]:void 0,Sn=E.useMemo(function(){if((0,le.Z)(Et)==="object")return Et.clearIcon;if(zt)return zt},[Et,zt]),Tn=E.useMemo(function(){return!!(!tn&&Et&&(Wt.length||nn)&&!(gn==="combobox"&&nn===""))},[Et,tn,Wt.length,nn,gn]);return{allowClear:Tn,clearIcon:E.createElement(ve,{className:"".concat(St,"-clear"),onMouseDown:an,customizeIcon:Sn},"\xD7")}},me=E.createContext(null);function ge(){return E.useContext(me)}function _e(){var At=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,St=E.useState(!1),an=(0,se.Z)(St,2),Wt=an[0],Et=an[1],zt=E.useRef(null),tn=function(){window.clearTimeout(zt.current)};E.useEffect(function(){return tn},[]);var nn=function(Sn,Tn){tn(),zt.current=window.setTimeout(function(){Et(Sn),Tn&&Tn()},At)};return[Wt,nn,tn]}function he(){var At=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,St=E.useRef(null),an=E.useRef(null);E.useEffect(function(){return function(){window.clearTimeout(an.current)}},[]);function Wt(Et){(Et||St.current===null)&&(St.current=Et),window.clearTimeout(an.current),an.current=window.setTimeout(function(){St.current=null},At)}return[function(){return St.current},Wt]}function pe(At,St,an,Wt){var Et=E.useRef(null);Et.current={open:St,triggerOpen:an,customizedTrigger:Wt},E.useEffect(function(){function zt(tn){var nn;if(!((nn=Et.current)!==null&&nn!==void 0&&nn.customizedTrigger)){var gn=tn.target;gn.shadowRoot&&tn.composed&&(gn=tn.composedPath()[0]||gn),Et.current.open&&At().filter(function(Sn){return Sn}).every(function(Sn){return!Sn.contains(gn)&&Sn!==gn})&&Et.current.triggerOpen(!1)}}return window.addEventListener("mousedown",zt),function(){return window.removeEventListener("mousedown",zt)}},[])}var ke=be(10228);function Te(At){return At&&![ke.Z.ESC,ke.Z.SHIFT,ke.Z.BACKSPACE,ke.Z.TAB,ke.Z.WIN_KEY,ke.Z.ALT,ke.Z.META,ke.Z.WIN_KEY_RIGHT,ke.Z.CTRL,ke.Z.SEMICOLON,ke.Z.EQUALS,ke.Z.CAPS_LOCK,ke.Z.CONTEXT_MENU,ke.Z.F1,ke.Z.F2,ke.Z.F3,ke.Z.F4,ke.Z.F5,ke.Z.F6,ke.Z.F7,ke.Z.F8,ke.Z.F9,ke.Z.F10,ke.Z.F11,ke.Z.F12].includes(At)}var Ee=be(26112),Oe=be(11780);function je(At,St,an){var Wt=(0,ue.Z)((0,ue.Z)({},At),an?St:{});return Object.keys(St).forEach(function(Et){var zt=St[Et];typeof zt=="function"&&(Wt[Et]=function(){for(var tn,nn=arguments.length,gn=new Array(nn),Sn=0;Sn<nn;Sn++)gn[Sn]=arguments[Sn];return zt.apply(void 0,gn),(tn=At[Et])===null||tn===void 0?void 0:tn.call.apply(tn,[At].concat(gn))})}),Wt}var Pe=je,Qe=["prefixCls","id","inputElement","autoFocus","autoComplete","editable","activeDescendantId","value","open","attrs"],Xe=function(St,an){var Wt=St.prefixCls,Et=St.id,zt=St.inputElement,tn=St.autoFocus,nn=St.autoComplete,gn=St.editable,Sn=St.activeDescendantId,Tn=St.value,Tt=St.open,jn=St.attrs,bn=(0,te.Z)(St,Qe),Fn=zt||E.createElement("input",null),Un=Fn,rr=Un.ref,pr=Un.props;return(0,ne.Kp)(!("maxLength"in Fn.props),"Passing 'maxLength' to input element directly may not work because input in BaseSelect is controlled."),Fn=E.cloneElement(Fn,(0,ue.Z)((0,ue.Z)((0,ue.Z)({type:"search"},Pe(bn,pr,!0)),{},{id:Et,ref:(0,ae.sQ)(an,rr),autoComplete:nn||"off",autoFocus:tn,className:z()("".concat(Wt,"-selection-search-input"),pr==null?void 0:pr.className),role:"combobox","aria-expanded":Tt||!1,"aria-haspopup":"listbox","aria-owns":"".concat(Et,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(Et,"_list"),"aria-activedescendant":Tt?Sn:void 0},jn),{},{value:gn?Tn:"",readOnly:!gn,unselectable:gn?null:"on",style:(0,ue.Z)((0,ue.Z)({},pr.style),{},{opacity:gn?null:0})})),Fn},ot=E.forwardRef(Xe),He=ot;function rt(At){return Array.isArray(At)?At:At!==void 0?[At]:[]}var Ye=typeof window!="undefined"&&window.document&&window.document.documentElement,ut=Ye;function Ge(At){return At!=null}function ze(At){return!At&&At!==0}function Ve(At){return["string","number"].includes((0,le.Z)(At))}function $e(At){var St=void 0;return At&&(Ve(At.title)?St=At.title.toString():Ve(At.label)&&(St=At.label.toString())),St}function nt(At,St){ut?E.useLayoutEffect(At,St):E.useEffect(At,St)}function et(At){var St;return(St=At.key)!==null&&St!==void 0?St:At.value}var pt=function(St){St.preventDefault(),St.stopPropagation()},ct=function(St){var an=St.id,Wt=St.prefixCls,Et=St.values,zt=St.open,tn=St.searchValue,nn=St.autoClearSearchValue,gn=St.inputRef,Sn=St.placeholder,Tn=St.disabled,Tt=St.mode,jn=St.showSearch,bn=St.autoFocus,Fn=St.autoComplete,Un=St.activeDescendantId,rr=St.tabIndex,pr=St.removeIcon,Rr=St.maxTagCount,wr=St.maxTagTextLength,Lr=St.maxTagPlaceholder,Vr=Lr===void 0?function(dn){return"+ ".concat(dn.length," ...")}:Lr,xr=St.tagRender,Ir=St.onToggleOpen,jr=St.onRemove,ti=St.onInputChange,di=St.onInputPaste,wi=St.onInputKeyDown,xi=St.onInputMouseDown,ai=St.onInputCompositionStart,Di=St.onInputCompositionEnd,_i=St.onInputBlur,or=E.useRef(null),br=(0,E.useState)(0),Ar=(0,se.Z)(br,2),qr=Ar[0],$r=Ar[1],bi=(0,E.useState)(!1),Wi=(0,se.Z)(bi,2),Dt=Wi[0],$t=Wi[1],Zt="".concat(Wt,"-selection"),en=zt||Tt==="multiple"&&nn===!1||Tt==="tags"?tn:"",on=Tt==="tags"||Tt==="multiple"&&nn===!1||jn&&(zt||Dt);nt(function(){$r(or.current.scrollWidth)},[en]);var hn=function(un,mn,ln,fn,vn){return E.createElement("span",{title:$e(un),className:z()("".concat(Zt,"-item"),(0,Ce.Z)({},"".concat(Zt,"-item-disabled"),ln))},E.createElement("span",{className:"".concat(Zt,"-item-content")},mn),fn&&E.createElement(ve,{className:"".concat(Zt,"-item-remove"),onMouseDown:pt,onClick:vn,customizeIcon:pr},"\xD7"))},Pn=function(un,mn,ln,fn,vn,Ln){var Jn=function(gr){pt(gr),Ir(!zt)};return E.createElement("span",{onMouseDown:Jn},xr({label:mn,value:un,disabled:ln,closable:fn,onClose:vn,isMaxTag:!!Ln}))},kn=function(un){var mn=un.disabled,ln=un.label,fn=un.value,vn=!Tn&&!mn,Ln=ln;if(typeof wr=="number"&&(typeof ln=="string"||typeof ln=="number")){var Jn=String(Ln);Jn.length>wr&&(Ln="".concat(Jn.slice(0,wr),"..."))}var Xn=function(nr){nr&&nr.stopPropagation(),jr(un)};return typeof xr=="function"?Pn(fn,Ln,mn,vn,Xn):hn(un,Ln,mn,vn,Xn)},_n=function(un){if(!Et.length)return null;var mn=typeof Vr=="function"?Vr(un):Vr;return typeof xr=="function"?Pn(void 0,mn,!1,!1,void 0,!0):hn({title:mn},mn,!1)},Gt=E.createElement("div",{className:"".concat(Zt,"-search"),style:{width:qr},onFocus:function(){$t(!0)},onBlur:function(){$t(!1)}},E.createElement(He,{ref:gn,open:zt,prefixCls:Wt,id:an,inputElement:null,disabled:Tn,autoFocus:bn,autoComplete:Fn,editable:on,activeDescendantId:Un,value:en,onKeyDown:wi,onMouseDown:xi,onChange:ti,onPaste:di,onCompositionStart:ai,onCompositionEnd:Di,onBlur:_i,tabIndex:rr,attrs:(0,Ee.Z)(St,!0)}),E.createElement("span",{ref:or,className:"".concat(Zt,"-search-mirror"),"aria-hidden":!0},en,"\xA0")),cn=E.createElement(Oe.Z,{prefixCls:"".concat(Zt,"-overflow"),data:Et,renderItem:kn,renderRest:_n,suffix:Gt,itemKey:et,maxCount:Rr});return E.createElement("span",{className:"".concat(Zt,"-wrap")},cn,!Et.length&&!en&&E.createElement("span",{className:"".concat(Zt,"-placeholder")},Sn))},Ot=ct,dt=function(St){var an=St.inputElement,Wt=St.prefixCls,Et=St.id,zt=St.inputRef,tn=St.disabled,nn=St.autoFocus,gn=St.autoComplete,Sn=St.activeDescendantId,Tn=St.mode,Tt=St.open,jn=St.values,bn=St.placeholder,Fn=St.tabIndex,Un=St.showSearch,rr=St.searchValue,pr=St.activeValue,Rr=St.maxLength,wr=St.onInputKeyDown,Lr=St.onInputMouseDown,Vr=St.onInputChange,xr=St.onInputPaste,Ir=St.onInputCompositionStart,jr=St.onInputCompositionEnd,ti=St.onInputBlur,di=St.title,wi=E.useState(!1),xi=(0,se.Z)(wi,2),ai=xi[0],Di=xi[1],_i=Tn==="combobox",or=_i||Un,br=jn[0],Ar=rr||"";_i&&pr&&!ai&&(Ar=pr),E.useEffect(function(){_i&&Di(!1)},[_i,pr]);var qr=Tn!=="combobox"&&!Tt&&!Un?!1:!!Ar,$r=di===void 0?$e(br):di,bi=E.useMemo(function(){return br?null:E.createElement("span",{className:"".concat(Wt,"-selection-placeholder"),style:qr?{visibility:"hidden"}:void 0},bn)},[br,qr,bn,Wt]);return E.createElement("span",{className:"".concat(Wt,"-selection-wrap")},E.createElement("span",{className:"".concat(Wt,"-selection-search")},E.createElement(He,{ref:zt,prefixCls:Wt,id:Et,open:Tt,inputElement:an,disabled:tn,autoFocus:nn,autoComplete:gn,editable:or,activeDescendantId:Sn,value:Ar,onKeyDown:wr,onMouseDown:Lr,onChange:function(Dt){Di(!0),Vr(Dt)},onPaste:xr,onCompositionStart:Ir,onCompositionEnd:jr,onBlur:ti,tabIndex:Fn,attrs:(0,Ee.Z)(St,!0),maxLength:_i?Rr:void 0})),!_i&&br?E.createElement("span",{className:"".concat(Wt,"-selection-item"),title:$r,style:qr?{visibility:"hidden"}:void 0},br.label):null,bi)},Rt=dt,xt=function(St,an){var Wt=(0,E.useRef)(null),Et=(0,E.useRef)(!1),zt=St.prefixCls,tn=St.open,nn=St.mode,gn=St.showSearch,Sn=St.tokenWithEnter,Tn=St.disabled,Tt=St.prefix,jn=St.autoClearSearchValue,bn=St.onSearch,Fn=St.onSearchSubmit,Un=St.onToggleOpen,rr=St.onInputKeyDown,pr=St.onInputBlur,Rr=St.domRef;E.useImperativeHandle(an,function(){return{focus:function($r){Wt.current.focus($r)},blur:function(){Wt.current.blur()}}});var wr=he(0),Lr=(0,se.Z)(wr,2),Vr=Lr[0],xr=Lr[1],Ir=function($r){var bi=$r.which,Wi=Wt.current instanceof HTMLTextAreaElement;!Wi&&tn&&(bi===ke.Z.UP||bi===ke.Z.DOWN)&&$r.preventDefault(),rr&&rr($r),bi===ke.Z.ENTER&&nn==="tags"&&!Et.current&&!tn&&(Fn==null||Fn($r.target.value)),!(Wi&&!tn&&~[ke.Z.UP,ke.Z.DOWN,ke.Z.LEFT,ke.Z.RIGHT].indexOf(bi))&&Te(bi)&&Un(!0)},jr=function(){xr(!0)},ti=(0,E.useRef)(null),di=function($r){bn($r,!0,Et.current)!==!1&&Un(!0)},wi=function(){Et.current=!0},xi=function($r){Et.current=!1,nn!=="combobox"&&di($r.target.value)},ai=function($r){var bi=$r.target.value;if(Sn&&ti.current&&/[\r\n]/.test(ti.current)){var Wi=ti.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");bi=bi.replace(Wi,ti.current)}ti.current=null,di(bi)},Di=function($r){var bi=$r.clipboardData,Wi=bi==null?void 0:bi.getData("text");ti.current=Wi||""},_i=function($r){var bi=$r.target;if(bi!==Wt.current){var Wi=document.body.style.msTouchAction!==void 0;Wi?setTimeout(function(){Wt.current.focus()}):Wt.current.focus()}},or=function($r){var bi=Vr();$r.target!==Wt.current&&!bi&&!(nn==="combobox"&&Tn)&&$r.preventDefault(),(nn!=="combobox"&&(!gn||!bi)||!tn)&&(tn&&jn!==!1&&bn("",!0,!1),Un())},br={inputRef:Wt,onInputKeyDown:Ir,onInputMouseDown:jr,onInputChange:ai,onInputPaste:Di,onInputCompositionStart:wi,onInputCompositionEnd:xi,onInputBlur:pr},Ar=nn==="multiple"||nn==="tags"?E.createElement(Ot,(0,ce.Z)({},St,br)):E.createElement(Rt,(0,ce.Z)({},St,br));return E.createElement("div",{ref:Rr,className:"".concat(zt,"-selector"),onClick:_i,onMouseDown:or},Tt&&E.createElement("div",{className:"".concat(zt,"-prefix")},Tt),Ar)},gt=E.forwardRef(xt),_t=gt,We=be(65030),Ae=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],Se=function(St){var an=St===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:an,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:an,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:an,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:an,adjustY:1},htmlRegion:"scroll"}}},Be=function(St,an){var Wt=St.prefixCls,Et=St.disabled,zt=St.visible,tn=St.children,nn=St.popupElement,gn=St.animation,Sn=St.transitionName,Tn=St.dropdownStyle,Tt=St.dropdownClassName,jn=St.direction,bn=jn===void 0?"ltr":jn,Fn=St.placement,Un=St.builtinPlacements,rr=St.dropdownMatchSelectWidth,pr=St.dropdownRender,Rr=St.dropdownAlign,wr=St.getPopupContainer,Lr=St.empty,Vr=St.getTriggerDOMNode,xr=St.onPopupVisibleChange,Ir=St.onPopupMouseEnter,jr=(0,te.Z)(St,Ae),ti="".concat(Wt,"-dropdown"),di=nn;pr&&(di=pr(nn));var wi=E.useMemo(function(){return Un||Se(rr)},[Un,rr]),xi=gn?"".concat(ti,"-").concat(gn):Sn,ai=typeof rr=="number",Di=E.useMemo(function(){return ai?null:rr===!1?"minWidth":"width"},[rr,ai]),_i=Tn;ai&&(_i=(0,ue.Z)((0,ue.Z)({},_i),{},{width:rr}));var or=E.useRef(null);return E.useImperativeHandle(an,function(){return{getPopupElement:function(){var Ar;return(Ar=or.current)===null||Ar===void 0?void 0:Ar.popupElement}}}),E.createElement(We.Z,(0,ce.Z)({},jr,{showAction:xr?["click"]:[],hideAction:xr?["click"]:[],popupPlacement:Fn||(bn==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:wi,prefixCls:ti,popupTransitionName:xi,popup:E.createElement("div",{onMouseEnter:Ir},di),ref:or,stretch:Di,popupAlign:Rr,popupVisible:zt,getPopupContainer:wr,popupClassName:z()(Tt,(0,Ce.Z)({},"".concat(ti,"-empty"),Lr)),popupStyle:_i,getTriggerDOMNode:Vr,onPopupVisibleChange:xr}),tn)},Ke=E.forwardRef(Be),Ne=Ke,De=be(40954);function we(At,St){var an=At.key,Wt;return"value"in At&&(Wt=At.value),an!=null?an:Wt!==void 0?Wt:"rc-index-key-".concat(St)}function Le(At){return typeof At!="undefined"&&!Number.isNaN(At)}function Ue(At,St){var an=At||{},Wt=an.label,Et=an.value,zt=an.options,tn=an.groupLabel,nn=Wt||(St?"children":"label");return{label:nn,value:Et||"value",options:zt||"options",groupLabel:tn||nn}}function Me(At){var St=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},an=St.fieldNames,Wt=St.childrenAsData,Et=[],zt=Ue(an,!1),tn=zt.label,nn=zt.value,gn=zt.options,Sn=zt.groupLabel;function Tn(Tt,jn){Array.isArray(Tt)&&Tt.forEach(function(bn){if(jn||!(gn in bn)){var Fn=bn[nn];Et.push({key:we(bn,Et.length),groupOption:jn,data:bn,label:bn[tn],value:Fn})}else{var Un=bn[Sn];Un===void 0&&Wt&&(Un=bn.label),Et.push({key:we(bn,Et.length),group:!0,data:bn,label:Un}),Tn(bn[gn],!0)}})}return Tn(At,!1),Et}function Re(At){var St=(0,ue.Z)({},At);return"props"in St||Object.defineProperty(St,"props",{get:function(){return(0,ne.ZP)(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),St}}),St}var tt=function(St,an,Wt){if(!an||!an.length)return null;var Et=!1,zt=function nn(gn,Sn){var Tn=(0,De.Z)(Sn),Tt=Tn[0],jn=Tn.slice(1);if(!Tt)return[gn];var bn=gn.split(Tt);return Et=Et||bn.length>1,bn.reduce(function(Fn,Un){return[].concat((0,ie.Z)(Fn),(0,ie.Z)(nn(Un,jn)))},[]).filter(Boolean)},tn=zt(St,an);return Et?typeof Wt!="undefined"?tn.slice(0,Wt):tn:null},lt=E.createContext(null),Nt=lt;function Ct(At){var St=At.visible,an=At.values;if(!St)return null;var Wt=50;return E.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(an.slice(0,Wt).map(function(Et){var zt=Et.label,tn=Et.value;return["number","string"].includes((0,le.Z)(zt))?zt:tn}).join(", ")),an.length>Wt?", ...":null)}var vt=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],Pt=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],Ht=function(St){return St==="tags"||St==="multiple"},jt=E.forwardRef(function(At,St){var an,Wt=At.id,Et=At.prefixCls,zt=At.className,tn=At.showSearch,nn=At.tagRender,gn=At.direction,Sn=At.omitDomProps,Tn=At.displayValues,Tt=At.onDisplayValuesChange,jn=At.emptyOptions,bn=At.notFoundContent,Fn=bn===void 0?"Not Found":bn,Un=At.onClear,rr=At.mode,pr=At.disabled,Rr=At.loading,wr=At.getInputElement,Lr=At.getRawInputElement,Vr=At.open,xr=At.defaultOpen,Ir=At.onDropdownVisibleChange,jr=At.activeValue,ti=At.onActiveValueChange,di=At.activeDescendantId,wi=At.searchValue,xi=At.autoClearSearchValue,ai=At.onSearch,Di=At.onSearchSplit,_i=At.tokenSeparators,or=At.allowClear,br=At.prefix,Ar=At.suffixIcon,qr=At.clearIcon,$r=At.OptionList,bi=At.animation,Wi=At.transitionName,Dt=At.dropdownStyle,$t=At.dropdownClassName,Zt=At.dropdownMatchSelectWidth,en=At.dropdownRender,on=At.dropdownAlign,hn=At.placement,Pn=At.builtinPlacements,kn=At.getPopupContainer,_n=At.showAction,Gt=_n===void 0?[]:_n,cn=At.onFocus,dn=At.onBlur,un=At.onKeyUp,mn=At.onKeyDown,ln=At.onMouseDown,fn=(0,te.Z)(At,vt),vn=Ht(rr),Ln=(tn!==void 0?tn:vn)||rr==="combobox",Jn=(0,ue.Z)({},fn);Pt.forEach(function(vi){delete Jn[vi]}),Sn==null||Sn.forEach(function(vi){delete Jn[vi]});var Xn=E.useState(!1),gr=(0,se.Z)(Xn,2),nr=gr[0],Cr=gr[1];E.useEffect(function(){Cr((0,re.Z)())},[]);var Tr=E.useRef(null),Gr=E.useRef(null),Or=E.useRef(null),Kr=E.useRef(null),ni=E.useRef(null),Wr=E.useRef(!1),ei=_e(),Dr=(0,se.Z)(ei,3),ar=Dr[0],fr=Dr[1],cr=Dr[2];E.useImperativeHandle(St,function(){var vi,si;return{focus:(vi=Kr.current)===null||vi===void 0?void 0:vi.focus,blur:(si=Kr.current)===null||si===void 0?void 0:si.blur,scrollTo:function(Qi){var io;return(io=ni.current)===null||io===void 0?void 0:io.scrollTo(Qi)},nativeElement:Tr.current||Gr.current}});var Yr=E.useMemo(function(){var vi;if(rr!=="combobox")return wi;var si=(vi=Tn[0])===null||vi===void 0?void 0:vi.value;return typeof si=="string"||typeof si=="number"?String(si):""},[wi,rr,Tn]),Xr=rr==="combobox"&&typeof wr=="function"&&wr()||null,Jr=typeof Lr=="function"&&Lr(),hi=(0,ae.x1)(Gr,Jr==null||(an=Jr.props)===null||an===void 0?void 0:an.ref),ao=E.useState(!1),Hi=(0,se.Z)(ao,2),Lo=Hi[0],po=Hi[1];(0,x.Z)(function(){po(!0)},[]);var Ri=(0,ee.Z)(!1,{defaultValue:xr,value:Vr}),Ii=(0,se.Z)(Ri,2),Pi=Ii[0],mo=Ii[1],Fi=Lo?Pi:!1,Ki=!Fn&&jn;(pr||Ki&&Fi&&rr==="combobox")&&(Fi=!1);var ji=Ki?!1:Fi,yr=E.useCallback(function(vi){var si=vi!==void 0?vi:!Fi;pr||(mo(si),Fi!==si&&(Ir==null||Ir(si)))},[pr,Fi,mo,Ir]),zr=E.useMemo(function(){return(_i||[]).some(function(vi){return[`
|
|
|
`,`\r
|
|
|
`].includes(vi)})},[_i]),Ur=E.useContext(Nt)||{},Zr=Ur.maxCount,Ci=Ur.rawValues,Oi=function(si,ro,Qi){if(!(vn&&Le(Zr)&&(Ci==null?void 0:Ci.size)>=Zr)){var io=!0,co=si;ti==null||ti(null);var na=tt(si,_i,Le(Zr)?Zr-Ci.size:void 0),Go=Qi?null:na;return rr!=="combobox"&&Go&&(co="",Di==null||Di(Go),yr(!1),io=!1),ai&&Yr!==co&&ai(co,{source:ro?"typing":"effect"}),io}},Ao=function(si){!si||!si.trim()||ai(si,{source:"submit"})};E.useEffect(function(){!Fi&&!vn&&rr!=="combobox"&&Oi("",!1,!1)},[Fi]),E.useEffect(function(){Pi&&pr&&mo(!1),pr&&!Wr.current&&fr(!1)},[pr]);var Xi=he(),qi=(0,se.Z)(Xi,2),ui=qi[0],no=qi[1],Io=E.useRef(!1),Ui=function(si){var ro=ui(),Qi=si.key,io=Qi==="Enter";if(io&&(rr!=="combobox"&&si.preventDefault(),Fi||yr(!0)),no(!!Yr),Qi==="Backspace"&&!ro&&vn&&!Yr&&Tn.length){for(var co=(0,ie.Z)(Tn),na=null,Go=co.length-1;Go>=0;Go-=1){var ca=co[Go];if(!ca.disabled){co.splice(Go,1),na=ca;break}}na&&Tt(co,{type:"remove",values:[na]})}for(var $i=arguments.length,go=new Array($i>1?$i-1:0),Fo=1;Fo<$i;Fo++)go[Fo-1]=arguments[Fo];if(Fi&&(!io||!Io.current)){var Xo;io&&(Io.current=!0),(Xo=ni.current)===null||Xo===void 0||Xo.onKeyDown.apply(Xo,[si].concat(go))}mn==null||mn.apply(void 0,[si].concat(go))},Ho=function(si){for(var ro=arguments.length,Qi=new Array(ro>1?ro-1:0),io=1;io<ro;io++)Qi[io-1]=arguments[io];if(Fi){var co;(co=ni.current)===null||co===void 0||co.onKeyUp.apply(co,[si].concat(Qi))}si.key==="Enter"&&(Io.current=!1),un==null||un.apply(void 0,[si].concat(Qi))},xo=function(si){var ro=Tn.filter(function(Qi){return Qi!==si});Tt(ro,{type:"remove",values:[si]})},Oo=function(){Io.current=!1},Vi=E.useRef(!1),Wo=function(){fr(!0),pr||(cn&&!Vi.current&&cn.apply(void 0,arguments),Gt.includes("focus")&&yr(!0)),Vi.current=!0},za=function(){Wr.current=!0,fr(!1,function(){Vi.current=!1,Wr.current=!1,yr(!1)}),!pr&&(Yr&&(rr==="tags"?ai(Yr,{source:"submit"}):rr==="multiple"&&ai("",{source:"blur"})),dn&&dn.apply(void 0,arguments))},Yo=[];E.useEffect(function(){return function(){Yo.forEach(function(vi){return clearTimeout(vi)}),Yo.splice(0,Yo.length)}},[]);var la=function(si){var ro,Qi=si.target,io=(ro=Or.current)===null||ro===void 0?void 0:ro.getPopupElement();if(io&&io.contains(Qi)){var co=setTimeout(function(){var $i=Yo.indexOf(co);if($i!==-1&&Yo.splice($i,1),cr(),!nr&&!io.contains(document.activeElement)){var go;(go=Kr.current)===null||go===void 0||go.focus()}});Yo.push(co)}for(var na=arguments.length,Go=new Array(na>1?na-1:0),ca=1;ca<na;ca++)Go[ca-1]=arguments[ca];ln==null||ln.apply(void 0,[si].concat(Go))},Zo=E.useState({}),Da=(0,se.Z)(Zo,2),qa=Da[1];function ba(){qa({})}var cs;Jr&&(cs=function(si){yr(si)}),pe(function(){var vi;return[Tr.current,(vi=Or.current)===null||vi===void 0?void 0:vi.getPopupElement()]},ji,yr,!!Jr);var Ma=E.useMemo(function(){return(0,ue.Z)((0,ue.Z)({},At),{},{notFoundContent:Fn,open:Fi,triggerOpen:ji,id:Wt,showSearch:Ln,multiple:vn,toggleOpen:yr})},[At,Fn,ji,Fi,Wt,Ln,vn,yr]),Ha=!!Ar||Rr,Ra;Ha&&(Ra=E.createElement(ve,{className:z()("".concat(Et,"-arrow"),(0,Ce.Z)({},"".concat(Et,"-arrow-loading"),Rr)),customizeIcon:Ar,customizeIconProps:{loading:Rr,searchValue:Yr,open:Fi,focused:ar,showSearch:Ln}}));var pa=function(){var si;Un==null||Un(),(si=Kr.current)===null||si===void 0||si.focus(),Tt([],{type:"clear",values:Tn}),Oi("",!1,!1)},Wa=ye(Et,pa,Tn,or,qr,pr,Yr,rr),Ja=Wa.allowClear,Sa=Wa.clearIcon,wa=E.createElement($r,{ref:ni}),ua=z()(Et,zt,(0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)({},"".concat(Et,"-focused"),ar),"".concat(Et,"-multiple"),vn),"".concat(Et,"-single"),!vn),"".concat(Et,"-allow-clear"),or),"".concat(Et,"-show-arrow"),Ha),"".concat(Et,"-disabled"),pr),"".concat(Et,"-loading"),Rr),"".concat(Et,"-open"),Fi),"".concat(Et,"-customize-input"),Xr),"".concat(Et,"-show-search"),Ln)),To=E.createElement(Ne,{ref:Or,disabled:pr,prefixCls:Et,visible:ji,popupElement:wa,animation:bi,transitionName:Wi,dropdownStyle:Dt,dropdownClassName:$t,direction:gn,dropdownMatchSelectWidth:Zt,dropdownRender:en,dropdownAlign:on,placement:hn,builtinPlacements:Pn,getPopupContainer:kn,empty:jn,getTriggerDOMNode:function(si){return Gr.current||si},onPopupVisibleChange:cs,onPopupMouseEnter:ba},Jr?E.cloneElement(Jr,{ref:hi}):E.createElement(_t,(0,ce.Z)({},At,{domRef:Gr,prefixCls:Et,inputElement:Xr,ref:Kr,id:Wt,prefix:br,showSearch:Ln,autoClearSearchValue:xi,mode:rr,activeDescendantId:di,tagRender:nn,values:Tn,open:Fi,onToggleOpen:yr,activeValue:jr,searchValue:Yr,onSearch:Oi,onSearchSubmit:Ao,onRemove:xo,tokenWithEnter:zr,onInputBlur:Oo}))),Ji;return Jr?Ji=To:Ji=E.createElement("div",(0,ce.Z)({className:ua},Jn,{ref:Tr,onMouseDown:la,onKeyDown:Ui,onKeyUp:Ho,onFocus:Wo,onBlur:za}),E.createElement(Ct,{visible:ar&&!Fi,values:Tn}),To,Ra,Ja&&Sa),E.createElement(me.Provider,{value:Ma},Ji)}),yt=jt,Yt=function(){return null};Yt.isSelectOptGroup=!0;var Lt=Yt,Kt=function(){return null};Kt.isSelectOption=!0;var sn=Kt,wn=be(80547),Vt=be(2738),Rn=be(6790);function Gn(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var Zn=["disabled","title","children","style","className"];function tr(At){return typeof At=="string"||typeof At=="number"}var hr=function(St,an){var Wt=ge(),Et=Wt.prefixCls,zt=Wt.id,tn=Wt.open,nn=Wt.multiple,gn=Wt.mode,Sn=Wt.searchValue,Tn=Wt.toggleOpen,Tt=Wt.notFoundContent,jn=Wt.onPopupScroll,bn=E.useContext(Nt),Fn=bn.maxCount,Un=bn.flattenOptions,rr=bn.onActiveValue,pr=bn.defaultActiveFirstOption,Rr=bn.onSelect,wr=bn.menuItemSelectedIcon,Lr=bn.rawValues,Vr=bn.fieldNames,xr=bn.virtual,Ir=bn.direction,jr=bn.listHeight,ti=bn.listItemHeight,di=bn.optionRender,wi="".concat(Et,"-item"),xi=(0,wn.Z)(function(){return Un},[tn,Un],function(_n,Gt){return Gt[0]&&_n[1]!==Gt[1]}),ai=E.useRef(null),Di=E.useMemo(function(){return nn&&Le(Fn)&&(Lr==null?void 0:Lr.size)>=Fn},[nn,Fn,Lr==null?void 0:Lr.size]),_i=function(Gt){Gt.preventDefault()},or=function(Gt){var cn;(cn=ai.current)===null||cn===void 0||cn.scrollTo(typeof Gt=="number"?{index:Gt}:Gt)},br=E.useCallback(function(_n){return gn==="combobox"?!1:Lr.has(_n)},[gn,(0,ie.Z)(Lr).toString(),Lr.size]),Ar=function(Gt){for(var cn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,dn=xi.length,un=0;un<dn;un+=1){var mn=(Gt+un*cn+dn)%dn,ln=xi[mn]||{},fn=ln.group,vn=ln.data;if(!fn&&!(vn!=null&&vn.disabled)&&(br(vn.value)||!Di))return mn}return-1},qr=E.useState(function(){return Ar(0)}),$r=(0,se.Z)(qr,2),bi=$r[0],Wi=$r[1],Dt=function(Gt){var cn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;Wi(Gt);var dn={source:cn?"keyboard":"mouse"},un=xi[Gt];if(!un){rr(null,-1,dn);return}rr(un.value,Gt,dn)};(0,E.useEffect)(function(){Dt(pr!==!1?Ar(0):-1)},[xi.length,Sn]);var $t=E.useCallback(function(_n){return gn==="combobox"?String(_n).toLowerCase()===Sn.toLowerCase():Lr.has(_n)},[gn,Sn,(0,ie.Z)(Lr).toString(),Lr.size]);(0,E.useEffect)(function(){var _n=setTimeout(function(){if(!nn&&tn&&Lr.size===1){var cn=Array.from(Lr)[0],dn=xi.findIndex(function(un){var mn=un.data;return Sn?String(mn.value).startsWith(Sn):mn.value===cn});dn!==-1&&(Dt(dn),or(dn))}});if(tn){var Gt;(Gt=ai.current)===null||Gt===void 0||Gt.scrollTo(void 0)}return function(){return clearTimeout(_n)}},[tn,Sn]);var Zt=function(Gt){Gt!==void 0&&Rr(Gt,{selected:!Lr.has(Gt)}),nn||Tn(!1)};if(E.useImperativeHandle(an,function(){return{onKeyDown:function(Gt){var cn=Gt.which,dn=Gt.ctrlKey;switch(cn){case ke.Z.N:case ke.Z.P:case ke.Z.UP:case ke.Z.DOWN:{var un=0;if(cn===ke.Z.UP?un=-1:cn===ke.Z.DOWN?un=1:Gn()&&dn&&(cn===ke.Z.N?un=1:cn===ke.Z.P&&(un=-1)),un!==0){var mn=Ar(bi+un,un);or(mn),Dt(mn,!0)}break}case ke.Z.TAB:case ke.Z.ENTER:{var ln,fn=xi[bi];fn&&!(fn!=null&&(ln=fn.data)!==null&&ln!==void 0&&ln.disabled)&&!Di?Zt(fn.value):Zt(void 0),tn&&Gt.preventDefault();break}case ke.Z.ESC:Tn(!1),tn&&Gt.stopPropagation()}},onKeyUp:function(){},scrollTo:function(Gt){or(Gt)}}}),xi.length===0)return E.createElement("div",{role:"listbox",id:"".concat(zt,"_list"),className:"".concat(wi,"-empty"),onMouseDown:_i},Tt);var en=Object.keys(Vr).map(function(_n){return Vr[_n]}),on=function(Gt){return Gt.label};function hn(_n,Gt){var cn=_n.group;return{role:cn?"presentation":"option",id:"".concat(zt,"_list_").concat(Gt)}}var Pn=function(Gt){var cn=xi[Gt];if(!cn)return null;var dn=cn.data||{},un=dn.value,mn=cn.group,ln=(0,Ee.Z)(dn,!0),fn=on(cn);return cn?E.createElement("div",(0,ce.Z)({"aria-label":typeof fn=="string"&&!mn?fn:null},ln,{key:Gt},hn(cn,Gt),{"aria-selected":$t(un)}),un):null},kn={role:"listbox",id:"".concat(zt,"_list")};return E.createElement(E.Fragment,null,xr&&E.createElement("div",(0,ce.Z)({},kn,{style:{height:0,width:0,overflow:"hidden"}}),Pn(bi-1),Pn(bi),Pn(bi+1)),E.createElement(Rn.Z,{itemKey:"key",ref:ai,data:xi,height:jr,itemHeight:ti,fullHeight:!1,onMouseDown:_i,onScroll:jn,virtual:xr,direction:Ir,innerProps:xr?null:kn},function(_n,Gt){var cn=_n.group,dn=_n.groupOption,un=_n.data,mn=_n.label,ln=_n.value,fn=un.key;if(cn){var vn,Ln=(vn=un.title)!==null&&vn!==void 0?vn:tr(mn)?mn.toString():void 0;return E.createElement("div",{className:z()(wi,"".concat(wi,"-group"),un.className),title:Ln},mn!==void 0?mn:fn)}var Jn=un.disabled,Xn=un.title,gr=un.children,nr=un.style,Cr=un.className,Tr=(0,te.Z)(un,Zn),Gr=(0,Vt.Z)(Tr,en),Or=br(ln),Kr=Jn||!Or&&Di,ni="".concat(wi,"-option"),Wr=z()(wi,ni,Cr,(0,Ce.Z)((0,Ce.Z)((0,Ce.Z)((0,Ce.Z)({},"".concat(ni,"-grouped"),dn),"".concat(ni,"-active"),bi===Gt&&!Kr),"".concat(ni,"-disabled"),Kr),"".concat(ni,"-selected"),Or)),ei=on(_n),Dr=!wr||typeof wr=="function"||Or,ar=typeof ei=="number"?ei:ei||ln,fr=tr(ar)?ar.toString():void 0;return Xn!==void 0&&(fr=Xn),E.createElement("div",(0,ce.Z)({},(0,Ee.Z)(Gr),xr?{}:hn(_n,Gt),{"aria-selected":$t(ln),className:Wr,title:fr,onMouseMove:function(){bi===Gt||Kr||Dt(Gt)},onClick:function(){Kr||Zt(ln)},style:nr}),E.createElement("div",{className:"".concat(ni,"-content")},typeof di=="function"?di(_n,{index:Gt}):ar),E.isValidElement(wr)||Or,Dr&&E.createElement(ve,{className:"".concat(wi,"-option-state"),customizeIcon:wr,customizeIconProps:{value:ln,disabled:Kr,isSelected:Or}},Or?"\u2713":null))}))},ur=E.forwardRef(hr),zn=ur,Bn=function(At,St){var an=E.useRef({values:new Map,options:new Map}),Wt=E.useMemo(function(){var zt=an.current,tn=zt.values,nn=zt.options,gn=At.map(function(Tt){if(Tt.label===void 0){var jn;return(0,ue.Z)((0,ue.Z)({},Tt),{},{label:(jn=tn.get(Tt.value))===null||jn===void 0?void 0:jn.label})}return Tt}),Sn=new Map,Tn=new Map;return gn.forEach(function(Tt){Sn.set(Tt.value,Tt),Tn.set(Tt.value,St.get(Tt.value)||nn.get(Tt.value))}),an.current.values=Sn,an.current.options=Tn,gn},[At,St]),Et=E.useCallback(function(zt){return St.get(zt)||an.current.options.get(zt)},[St]);return[Wt,Et]};function ir(At,St){return rt(At).join("").toUpperCase().includes(St)}var Kn=function(At,St,an,Wt,Et){return E.useMemo(function(){if(!an||Wt===!1)return At;var zt=St.options,tn=St.label,nn=St.value,gn=[],Sn=typeof Wt=="function",Tn=an.toUpperCase(),Tt=Sn?Wt:function(bn,Fn){return Et?ir(Fn[Et],Tn):Fn[zt]?ir(Fn[tn!=="children"?tn:"label"],Tn):ir(Fn[nn],Tn)},jn=Sn?function(bn){return Re(bn)}:function(bn){return bn};return At.forEach(function(bn){if(bn[zt]){var Fn=Tt(an,jn(bn));if(Fn)gn.push(bn);else{var Un=bn[zt].filter(function(rr){return Tt(an,jn(rr))});Un.length&&gn.push((0,ue.Z)((0,ue.Z)({},bn),{},(0,Ce.Z)({},zt,Un)))}return}Tt(an,jn(bn))&&gn.push(bn)}),gn},[At,Wt,Et,an,St])},Nn=be(6551),yn=be(11592),Hn=["children","value"],dr=["children"];function Mn(At){var St=At,an=St.key,Wt=St.props,Et=Wt.children,zt=Wt.value,tn=(0,te.Z)(Wt,Hn);return(0,ue.Z)({key:an,value:zt!==void 0?zt:an,children:Et},tn)}function Cn(At){var St=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return(0,yn.Z)(At).map(function(an,Wt){if(!E.isValidElement(an)||!an.type)return null;var Et=an,zt=Et.type.isSelectOptGroup,tn=Et.key,nn=Et.props,gn=nn.children,Sn=(0,te.Z)(nn,dr);return St||!zt?Mn(an):(0,ue.Z)((0,ue.Z)({key:"__RC_SELECT_GRP__".concat(tn===null?Wt:tn,"__"),label:tn},Sn),{},{options:Cn(gn)})}).filter(function(an){return an})}var $n=function(St,an,Wt,Et,zt){return E.useMemo(function(){var tn=St,nn=!St;nn&&(tn=Cn(an));var gn=new Map,Sn=new Map,Tn=function(bn,Fn,Un){Un&&typeof Un=="string"&&bn.set(Fn[Un],Fn)},Tt=function jn(bn){for(var Fn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Un=0;Un<bn.length;Un+=1){var rr=bn[Un];!rr[Wt.options]||Fn?(gn.set(rr[Wt.value],rr),Tn(Sn,rr,Wt.label),Tn(Sn,rr,Et),Tn(Sn,rr,zt)):jn(rr[Wt.options],!0)}};return Tt(tn),{options:tn,valueOptions:gn,labelOptions:Sn}},[St,an,Wt,Et,zt])},Jt=$n;function Ie(At){var St=E.useRef();St.current=At;var an=E.useCallback(function(){return St.current.apply(St,arguments)},[]);return an}function Ze(At){var St=At.mode,an=At.options,Wt=At.children,Et=At.backfill,zt=At.allowClear,tn=At.placeholder,nn=At.getInputElement,gn=At.showSearch,Sn=At.onSearch,Tn=At.defaultOpen,Tt=At.autoFocus,jn=At.labelInValue,bn=At.value,Fn=At.inputValue,Un=At.optionLabelProp,rr=isMultiple(St),pr=gn!==void 0?gn:rr||St==="combobox",Rr=an||convertChildrenToData(Wt);if(warning(St!=="tags"||Rr.every(function(xr){return!xr.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),St==="tags"||St==="combobox"){var wr=Rr.some(function(xr){return xr.options?xr.options.some(function(Ir){return typeof("value"in Ir?Ir.value:Ir.key)=="number"}):typeof("value"in xr?xr.value:xr.key)=="number"});warning(!wr,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(warning(St!=="combobox"||!Un,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),warning(St==="combobox"||!Et,"`backfill` only works with `combobox` mode."),warning(St==="combobox"||!nn,"`getInputElement` only work with `combobox` mode."),noteOnce(St!=="combobox"||!nn||!zt||!tn,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),Sn&&!pr&&St!=="combobox"&&St!=="tags"&&warning(!1,"`onSearch` should work with `showSearch` instead of use alone."),noteOnce(!Tn||Tt,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),bn!=null){var Lr=toArray(bn);warning(!jn||Lr.every(function(xr){return _typeof(xr)==="object"&&("key"in xr||"value"in xr)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),warning(!rr||Array.isArray(bn),"`value` should be array when `mode` is `multiple` or `tags`")}if(Wt){var Vr=null;toNodeArray(Wt).some(function(xr){if(!React.isValidElement(xr)||!xr.type)return!1;var Ir=xr,jr=Ir.type;if(jr.isSelectOption)return!1;if(jr.isSelectOptGroup){var ti=toNodeArray(xr.props.children).every(function(di){return!React.isValidElement(di)||!xr.type||di.type.isSelectOption?!0:(Vr=di.type,!1)});return!ti}return Vr=jr,!0}),Vr&&warning(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(Vr.displayName||Vr.name||Vr,"`.")),warning(Fn===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}function qe(At,St){if(At){var an=function Wt(Et){for(var zt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,tn=0;tn<Et.length;tn++){var nn=Et[tn];if(nn[St==null?void 0:St.value]===null)return warning(!1,"`value` in Select options should not be `null`."),!0;if(!zt&&Array.isArray(nn[St==null?void 0:St.options])&&Wt(nn[St==null?void 0:St.options],!0))break}};an(At)}}var st=null,mt=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],Bt=["inputValue"];function kt(At){return!At||(0,le.Z)(At)!=="object"}var Ft=E.forwardRef(function(At,St){var an=At.id,Wt=At.mode,Et=At.prefixCls,zt=Et===void 0?"rc-select":Et,tn=At.backfill,nn=At.fieldNames,gn=At.inputValue,Sn=At.searchValue,Tn=At.onSearch,Tt=At.autoClearSearchValue,jn=Tt===void 0?!0:Tt,bn=At.onSelect,Fn=At.onDeselect,Un=At.dropdownMatchSelectWidth,rr=Un===void 0?!0:Un,pr=At.filterOption,Rr=At.filterSort,wr=At.optionFilterProp,Lr=At.optionLabelProp,Vr=At.options,xr=At.optionRender,Ir=At.children,jr=At.defaultActiveFirstOption,ti=At.menuItemSelectedIcon,di=At.virtual,wi=At.direction,xi=At.listHeight,ai=xi===void 0?200:xi,Di=At.listItemHeight,_i=Di===void 0?20:Di,or=At.labelRender,br=At.value,Ar=At.defaultValue,qr=At.labelInValue,$r=At.onChange,bi=At.maxCount,Wi=(0,te.Z)(At,mt),Dt=(0,Nn.ZP)(an),$t=Ht(Wt),Zt=!!(!Vr&&Ir),en=E.useMemo(function(){return pr===void 0&&Wt==="combobox"?!1:pr},[pr,Wt]),on=E.useMemo(function(){return Ue(nn,Zt)},[JSON.stringify(nn),Zt]),hn=(0,ee.Z)("",{value:Sn!==void 0?Sn:gn,postState:function(zr){return zr||""}}),Pn=(0,se.Z)(hn,2),kn=Pn[0],_n=Pn[1],Gt=Jt(Vr,Ir,on,wr,Lr),cn=Gt.valueOptions,dn=Gt.labelOptions,un=Gt.options,mn=E.useCallback(function(yr){var zr=rt(yr);return zr.map(function(Ur){var Zr,Ci,Oi,Ao,Xi;if(kt(Ur))Zr=Ur;else{var qi;Oi=Ur.key,Ci=Ur.label,Zr=(qi=Ur.value)!==null&&qi!==void 0?qi:Oi}var ui=cn.get(Zr);if(ui){var no;if(Ci===void 0&&(Ci=ui==null?void 0:ui[Lr||on.label]),Oi===void 0&&(Oi=(no=ui==null?void 0:ui.key)!==null&&no!==void 0?no:Zr),Ao=ui==null?void 0:ui.disabled,Xi=ui==null?void 0:ui.title,0)var Io}return{label:Ci,value:Zr,key:Oi,disabled:Ao,title:Xi}})},[on,Lr,cn]),ln=(0,ee.Z)(Ar,{value:br}),fn=(0,se.Z)(ln,2),vn=fn[0],Ln=fn[1],Jn=E.useMemo(function(){var yr,zr=$t&&vn===null?[]:vn,Ur=mn(zr);return Wt==="combobox"&&ze((yr=Ur[0])===null||yr===void 0?void 0:yr.value)?[]:Ur},[vn,mn,Wt,$t]),Xn=Bn(Jn,cn),gr=(0,se.Z)(Xn,2),nr=gr[0],Cr=gr[1],Tr=E.useMemo(function(){if(!Wt&&nr.length===1){var yr=nr[0];if(yr.value===null&&(yr.label===null||yr.label===void 0))return[]}return nr.map(function(zr){var Ur;return(0,ue.Z)((0,ue.Z)({},zr),{},{label:(Ur=typeof or=="function"?or(zr):zr.label)!==null&&Ur!==void 0?Ur:zr.value})})},[Wt,nr,or]),Gr=E.useMemo(function(){return new Set(nr.map(function(yr){return yr.value}))},[nr]);E.useEffect(function(){if(Wt==="combobox"){var yr,zr=(yr=nr[0])===null||yr===void 0?void 0:yr.value;_n(Ge(zr)?String(zr):"")}},[nr]);var Or=Ie(function(yr,zr){var Ur=zr!=null?zr:yr;return(0,Ce.Z)((0,Ce.Z)({},on.value,yr),on.label,Ur)}),Kr=E.useMemo(function(){if(Wt!=="tags")return un;var yr=(0,ie.Z)(un),zr=function(Zr){return cn.has(Zr)};return(0,ie.Z)(nr).sort(function(Ur,Zr){return Ur.value<Zr.value?-1:1}).forEach(function(Ur){var Zr=Ur.value;zr(Zr)||yr.push(Or(Zr,Ur.label))}),yr},[Or,un,cn,nr,Wt]),ni=Kn(Kr,on,kn,en,wr),Wr=E.useMemo(function(){return Wt!=="tags"||!kn||ni.some(function(yr){return yr[wr||"value"]===kn})||ni.some(function(yr){return yr[on.value]===kn})?ni:[Or(kn)].concat((0,ie.Z)(ni))},[Or,wr,Wt,ni,kn,on]),ei=function yr(zr){var Ur=(0,ie.Z)(zr).sort(function(Zr,Ci){return Rr(Zr,Ci,{searchValue:kn})});return Ur.map(function(Zr){return Array.isArray(Zr.options)?(0,ue.Z)((0,ue.Z)({},Zr),{},{options:Zr.options.length>0?yr(Zr.options):Zr.options}):Zr})},Dr=E.useMemo(function(){return Rr?ei(Wr):Wr},[Wr,Rr,kn]),ar=E.useMemo(function(){return Me(Dr,{fieldNames:on,childrenAsData:Zt})},[Dr,on,Zt]),fr=function(zr){var Ur=mn(zr);if(Ln(Ur),$r&&(Ur.length!==nr.length||Ur.some(function(Oi,Ao){var Xi;return((Xi=nr[Ao])===null||Xi===void 0?void 0:Xi.value)!==(Oi==null?void 0:Oi.value)}))){var Zr=qr?Ur:Ur.map(function(Oi){return Oi.value}),Ci=Ur.map(function(Oi){return Re(Cr(Oi.value))});$r($t?Zr:Zr[0],$t?Ci:Ci[0])}},cr=E.useState(null),Yr=(0,se.Z)(cr,2),Xr=Yr[0],Jr=Yr[1],hi=E.useState(0),ao=(0,se.Z)(hi,2),Hi=ao[0],Lo=ao[1],po=jr!==void 0?jr:Wt!=="combobox",Ri=E.useCallback(function(yr,zr){var Ur=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Zr=Ur.source,Ci=Zr===void 0?"keyboard":Zr;Lo(zr),tn&&Wt==="combobox"&&yr!==null&&Ci==="keyboard"&&Jr(String(yr))},[tn,Wt]),Ii=function(zr,Ur,Zr){var Ci=function(){var xo,Oo=Cr(zr);return[qr?{label:Oo==null?void 0:Oo[on.label],value:zr,key:(xo=Oo==null?void 0:Oo.key)!==null&&xo!==void 0?xo:zr}:zr,Re(Oo)]};if(Ur&&bn){var Oi=Ci(),Ao=(0,se.Z)(Oi,2),Xi=Ao[0],qi=Ao[1];bn(Xi,qi)}else if(!Ur&&Fn&&Zr!=="clear"){var ui=Ci(),no=(0,se.Z)(ui,2),Io=no[0],Ui=no[1];Fn(Io,Ui)}},Pi=Ie(function(yr,zr){var Ur,Zr=$t?zr.selected:!0;Zr?Ur=$t?[].concat((0,ie.Z)(nr),[yr]):[yr]:Ur=nr.filter(function(Ci){return Ci.value!==yr}),fr(Ur),Ii(yr,Zr),Wt==="combobox"?Jr(""):(!Ht||jn)&&(_n(""),Jr(""))}),mo=function(zr,Ur){fr(zr);var Zr=Ur.type,Ci=Ur.values;(Zr==="remove"||Zr==="clear")&&Ci.forEach(function(Oi){Ii(Oi.value,!1,Zr)})},Fi=function(zr,Ur){if(_n(zr),Jr(null),Ur.source==="submit"){var Zr=(zr||"").trim();if(Zr){var Ci=Array.from(new Set([].concat((0,ie.Z)(Gr),[Zr])));fr(Ci),Ii(Zr,!0),_n("")}return}Ur.source!=="blur"&&(Wt==="combobox"&&fr(zr),Tn==null||Tn(zr))},Ki=function(zr){var Ur=zr;Wt!=="tags"&&(Ur=zr.map(function(Ci){var Oi=dn.get(Ci);return Oi==null?void 0:Oi.value}).filter(function(Ci){return Ci!==void 0}));var Zr=Array.from(new Set([].concat((0,ie.Z)(Gr),(0,ie.Z)(Ur))));fr(Zr),Zr.forEach(function(Ci){Ii(Ci,!0)})},ji=E.useMemo(function(){var yr=di!==!1&&rr!==!1;return(0,ue.Z)((0,ue.Z)({},Gt),{},{flattenOptions:ar,onActiveValue:Ri,defaultActiveFirstOption:po,onSelect:Pi,menuItemSelectedIcon:ti,rawValues:Gr,fieldNames:on,virtual:yr,direction:wi,listHeight:ai,listItemHeight:_i,childrenAsData:Zt,maxCount:bi,optionRender:xr})},[bi,Gt,ar,Ri,po,Pi,ti,Gr,on,di,rr,wi,ai,_i,Zt,xr]);return E.createElement(Nt.Provider,{value:ji},E.createElement(yt,(0,ce.Z)({},Wi,{id:Dt,prefixCls:zt,ref:St,omitDomProps:Bt,mode:Wt,displayValues:Tr,onDisplayValuesChange:mo,direction:wi,searchValue:kn,onSearch:Fi,autoClearSearchValue:jn,onSearchSplit:Ki,dropdownMatchSelectWidth:rr,OptionList:zn,emptyOptions:!ar.length,activeValue:Xr,activeDescendantId:"".concat(Dt,"_list_").concat(Hi)})))}),qt=Ft;qt.Option=sn,qt.OptGroup=Lt;var En=qt,Yn=En},63158:function(Xt,Mt,be){"use strict";var ce=be(32855),ie=be(74430),Ce=be(11913),ue=be(43079),se=be(59301),te=be(92310),le=be.n(te),ee=be(18929),ne=be(10228),E=["prefixCls","className","checked","defaultChecked","disabled","loadingIcon","checkedChildren","unCheckedChildren","onClick","onChange","onKeyDown"],b=se.forwardRef(function(z,x){var re,ae=z.prefixCls,oe=ae===void 0?"rc-switch":ae,ve=z.className,ye=z.checked,me=z.defaultChecked,ge=z.disabled,_e=z.loadingIcon,he=z.checkedChildren,pe=z.unCheckedChildren,ke=z.onClick,Te=z.onChange,Ee=z.onKeyDown,Oe=(0,ue.Z)(z,E),je=(0,ee.Z)(!1,{value:ye,defaultValue:me}),Pe=(0,Ce.Z)(je,2),Qe=Pe[0],Xe=Pe[1];function ot(ut,Ge){var ze=Qe;return ge||(ze=ut,Xe(ze),Te==null||Te(ze,Ge)),ze}function He(ut){ut.which===ne.Z.LEFT?ot(!1,ut):ut.which===ne.Z.RIGHT&&ot(!0,ut),Ee==null||Ee(ut)}function rt(ut){var Ge=ot(!Qe,ut);ke==null||ke(Ge,ut)}var Ye=le()(oe,ve,(re={},(0,ie.Z)(re,"".concat(oe,"-checked"),Qe),(0,ie.Z)(re,"".concat(oe,"-disabled"),ge),re));return se.createElement("button",(0,ce.Z)({},Oe,{type:"button",role:"switch","aria-checked":Qe,disabled:ge,className:Ye,ref:x,onKeyDown:He,onClick:rt}),_e,se.createElement("span",{className:"".concat(oe,"-inner")},se.createElement("span",{className:"".concat(oe,"-inner-checked")},he),se.createElement("span",{className:"".concat(oe,"-inner-unchecked")},pe)))});b.displayName="Switch",Mt.Z=b},86351:function(Xt,Mt,be){"use strict";be.d(Mt,{R:function(){return ie},w:function(){return ce}});var ce={},ie="rc-table-internal-hook"},97347:function(Xt,Mt,be){"use strict";be.d(Mt,{L:function(){return oe},Z:function(){return _e}});var ce=be(11913),ie=be(74430),Ce=be(3300),ue=be(34666),se=be(27247),te=be(43079),le=be(11592),ee=be(48736),ne=be(59301),E=be(86351),b=be(54451);function z(he){var pe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return typeof pe=="number"?pe:pe.endsWith("%")?he*parseFloat(pe)/100:null}function x(he,pe,ke){return ne.useMemo(function(){if(pe&&pe>0){var Te=0,Ee=0;he.forEach(function(rt){var Ye=z(pe,rt.width);Ye?Te+=Ye:Ee+=1});var Oe=Math.max(pe,ke),je=Math.max(Oe-Te,Ee),Pe=Ee,Qe=je/Ee,Xe=0,ot=he.map(function(rt){var Ye=(0,se.Z)({},rt),ut=z(pe,Ye.width);if(ut)Ye.width=ut;else{var Ge=Math.floor(Qe);Ye.width=Pe===1?je:Ge,je-=Ge,Pe-=1}return Xe+=Ye.width,Ye});if(Xe<Oe){var He=Oe/Xe;je=Oe,ot.forEach(function(rt,Ye){var ut=Math.floor(rt.width*He);rt.width=Ye===ot.length-1?je:ut,je-=ut})}return[ot,Math.max(Xe,Oe)]}return[he,pe]},[he,pe,ke])}var re=["children"],ae=["fixed"];function oe(he){return(0,le.Z)(he).filter(function(pe){return ne.isValidElement(pe)}).map(function(pe){var ke=pe.key,Te=pe.props,Ee=Te.children,Oe=(0,te.Z)(Te,re),je=(0,se.Z)({key:ke},Oe);return Ee&&(je.children=oe(Ee)),je})}function ve(he){return he.filter(function(pe){return pe&&(0,ue.Z)(pe)==="object"&&!pe.hidden}).map(function(pe){var ke=pe.children;return ke&&ke.length>0?(0,se.Z)((0,se.Z)({},pe),{},{children:ve(ke)}):pe})}function ye(he){var pe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"key";return he.filter(function(ke){return ke&&(0,ue.Z)(ke)==="object"}).reduce(function(ke,Te,Ee){var Oe=Te.fixed,je=Oe===!0?"left":Oe,Pe="".concat(pe,"-").concat(Ee),Qe=Te.children;return Qe&&Qe.length>0?[].concat((0,Ce.Z)(ke),(0,Ce.Z)(ye(Qe,Pe).map(function(Xe){return(0,se.Z)({fixed:je},Xe)}))):[].concat((0,Ce.Z)(ke),[(0,se.Z)((0,se.Z)({key:Pe},Te),{},{fixed:je})])},[])}function me(he){return he.map(function(pe){var ke=pe.fixed,Te=(0,te.Z)(pe,ae),Ee=ke;return ke==="left"?Ee="right":ke==="right"&&(Ee="left"),(0,se.Z)({fixed:Ee},Te)})}function ge(he,pe){var ke=he.prefixCls,Te=he.columns,Ee=he.children,Oe=he.expandable,je=he.expandedKeys,Pe=he.columnTitle,Qe=he.getRowKey,Xe=he.onTriggerExpand,ot=he.expandIcon,He=he.rowExpandable,rt=he.expandIconColumnIndex,Ye=he.direction,ut=he.expandRowByClick,Ge=he.columnWidth,ze=he.fixed,Ve=he.scrollWidth,$e=he.clientWidth,nt=ne.useMemo(function(){var _t=Te||oe(Ee)||[];return ve(_t.slice())},[Te,Ee]),et=ne.useMemo(function(){if(Oe){var _t=nt.slice();if(!_t.includes(E.w)){var We=rt||0;We>=0&&(We||ze==="left"||!ze)&&_t.splice(We,0,E.w),ze==="right"&&_t.splice(nt.length,0,E.w)}var Ae=_t.indexOf(E.w);_t=_t.filter(function(Ne,De){return Ne!==E.w||De===Ae});var Se=nt[Ae],Be;ze?Be=ze:Be=Se?Se.fixed:null;var Ke=(0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)({},b.v,{className:"".concat(ke,"-expand-icon-col"),columnType:"EXPAND_COLUMN"}),"title",Pe),"fixed",Be),"className","".concat(ke,"-row-expand-icon-cell")),"width",Ge),"render",function(De,we,Le){var Ue=Qe(we,Le),Me=je.has(Ue),Re=He?He(we):!0,tt=ot({prefixCls:ke,expanded:Me,expandable:Re,record:we,onExpand:Xe});return ut?ne.createElement("span",{onClick:function(Nt){return Nt.stopPropagation()}},tt):tt});return _t.map(function(Ne){return Ne===E.w?Ke:Ne})}return nt.filter(function(Ne){return Ne!==E.w})},[Oe,nt,Qe,je,ot,Ye]),pt=ne.useMemo(function(){var _t=et;return pe&&(_t=pe(_t)),_t.length||(_t=[{render:function(){return null}}]),_t},[pe,et,Ye]),ct=ne.useMemo(function(){return Ye==="rtl"?me(ye(pt)):ye(pt)},[pt,Ye,Ve]),Ot=ne.useMemo(function(){for(var _t=-1,We=ct.length-1;We>=0;We-=1){var Ae=ct[We].fixed;if(Ae==="left"||Ae===!0){_t=We;break}}if(_t>=0)for(var Se=0;Se<=_t;Se+=1){var Be=ct[Se].fixed;if(Be!=="left"&&Be!==!0)return!0}var Ke=ct.findIndex(function(we){var Le=we.fixed;return Le==="right"});if(Ke>=0)for(var Ne=Ke;Ne<ct.length;Ne+=1){var De=ct[Ne].fixed;if(De!=="right")return!0}return!1},[ct]),dt=x(ct,Ve,$e),Rt=(0,ce.Z)(dt,2),xt=Rt[0],gt=Rt[1];return[pt,xt,gt,Ot]}var _e=ge},4030:function(Xt,Mt,be){"use strict";be.d(Mt,{w2:function(){return ce.w},vP:function(){return tr.v},RQ:function(){return ce.R},ER:function(){return Ue},Q$:function(){return pr},TN:function(){return $r}});var ce=be(86351),ie=be(11913),Ce=be(6089),ue=be(34280),se=be(13697),te=be(59301),le=be(4676);function ee(Dt){var $t=te.createContext(void 0),Zt=function(on){var hn=on.value,Pn=on.children,kn=te.useRef(hn);kn.current=hn;var _n=te.useState(function(){return{getValue:function(){return kn.current},listeners:new Set}}),Gt=(0,ie.Z)(_n,1),cn=Gt[0];return(0,ue.Z)(function(){(0,le.unstable_batchedUpdates)(function(){cn.listeners.forEach(function(dn){dn(hn)})})},[hn]),te.createElement($t.Provider,{value:cn},Pn)};return{Context:$t,Provider:Zt,defaultValue:Dt}}function ne(Dt,$t){var Zt=(0,Ce.Z)(typeof $t=="function"?$t:function(dn){if($t===void 0)return dn;if(!Array.isArray($t))return dn[$t];var un={};return $t.forEach(function(mn){un[mn]=dn[mn]}),un}),en=te.useContext(Dt==null?void 0:Dt.Context),on=en||{},hn=on.listeners,Pn=on.getValue,kn=te.useRef();kn.current=Zt(en?Pn():Dt==null?void 0:Dt.defaultValue);var _n=te.useState({}),Gt=(0,ie.Z)(_n,2),cn=Gt[1];return(0,ue.Z)(function(){if(!en)return;function dn(un){var mn=Zt(un);(0,se.Z)(kn.current,mn,!0)||cn({})}return hn.add(dn),function(){hn.delete(dn)}},[en]),kn.current}var E=be(32855),b=be(8654);function z(){var Dt=te.createContext(null);function $t(){return te.useContext(Dt)}function Zt(on,hn){var Pn=(0,b.Yr)(on),kn=function(Gt,cn){var dn=Pn?{ref:cn}:{},un=te.useRef(0),mn=te.useRef(Gt),ln=$t();return ln!==null?te.createElement(on,(0,E.Z)({},Gt,dn)):((!hn||hn(mn.current,Gt))&&(un.current+=1),mn.current=Gt,te.createElement(Dt.Provider,{value:un.current},te.createElement(on,(0,E.Z)({},Gt,dn))))};return Pn?te.forwardRef(kn):kn}function en(on,hn){var Pn=(0,b.Yr)(on),kn=function(Gt,cn){var dn=Pn?{ref:cn}:{};return $t(),te.createElement(on,(0,E.Z)({},Gt,dn))};return Pn?te.memo(te.forwardRef(kn),hn):te.memo(kn,hn)}return{makeImmutable:Zt,responseImmutable:en,useImmutableMark:$t}}var x=z(),re=x.makeImmutable,ae=x.responseImmutable,oe=x.useImmutableMark,ve=z(),ye=ve.makeImmutable,me=ve.responseImmutable,ge=ve.useImmutableMark,_e=ee(),he=_e;function pe(Dt,$t){var Zt=React.useRef(0);Zt.current+=1;var en=React.useRef(Dt),on=[];Object.keys(Dt||{}).map(function(Pn){var kn;(Dt==null?void 0:Dt[Pn])!==((kn=en.current)===null||kn===void 0?void 0:kn[Pn])&&on.push(Pn)}),en.current=Dt;var hn=React.useRef([]);return on.length&&(hn.current=on),React.useDebugValue(Zt.current),React.useDebugValue(hn.current.join(", ")),$t&&console.log("".concat($t,":"),Zt.current,hn.current),Zt.current}var ke=null,Te=null,Ee=be(34666),Oe=be(27247),je=be(74430),Pe=be(92310),Qe=be.n(Pe),Xe=be(80547),ot=be(97938),He=be(48736),rt=te.createContext({renderWithProps:!1}),Ye=rt,ut="RC_TABLE_KEY";function Ge(Dt){return Dt==null?[]:Array.isArray(Dt)?Dt:[Dt]}function ze(Dt){var $t=[],Zt={};return Dt.forEach(function(en){for(var on=en||{},hn=on.key,Pn=on.dataIndex,kn=hn||Ge(Pn).join("-")||ut;Zt[kn];)kn="".concat(kn,"_next");Zt[kn]=!0,$t.push(kn)}),$t}function Ve(Dt){return Dt!=null}function $e(Dt){return typeof Dt=="number"&&!Number.isNaN(Dt)}function nt(Dt){return Dt&&(0,Ee.Z)(Dt)==="object"&&!Array.isArray(Dt)&&!te.isValidElement(Dt)}function et(Dt,$t,Zt,en,on,hn){var Pn=te.useContext(Ye),kn=ge(),_n=(0,Xe.Z)(function(){if(Ve(en))return[en];var Gt=$t==null||$t===""?[]:Array.isArray($t)?$t:[$t],cn=(0,ot.Z)(Dt,Gt),dn=cn,un=void 0;if(on){var mn=on(cn,Dt,Zt);nt(mn)?(dn=mn.children,un=mn.props,Pn.renderWithProps=!0):dn=mn}return[dn,un]},[kn,Dt,en,$t,on,Zt],function(Gt,cn){if(hn){var dn=(0,ie.Z)(Gt,2),un=dn[1],mn=(0,ie.Z)(cn,2),ln=mn[1];return hn(ln,un)}return Pn.renderWithProps?!0:!(0,se.Z)(Gt,cn,!0)});return _n}function pt(Dt,$t,Zt,en){var on=Dt+$t-1;return Dt<=en&&on>=Zt}function ct(Dt,$t){return ne(he,function(Zt){var en=pt(Dt,$t||1,Zt.hoverStartRow,Zt.hoverEndRow);return[en,Zt.onHover]})}var Ot=be(70425),dt=function($t){var Zt=$t.ellipsis,en=$t.rowType,on=$t.children,hn,Pn=Zt===!0?{showTitle:!0}:Zt;return Pn&&(Pn.showTitle||en==="header")&&(typeof on=="string"||typeof on=="number"?hn=on.toString():te.isValidElement(on)&&typeof on.props.children=="string"&&(hn=on.props.children)),hn};function Rt(Dt){var $t,Zt,en,on,hn,Pn,kn,_n,Gt=Dt.component,cn=Dt.children,dn=Dt.ellipsis,un=Dt.scope,mn=Dt.prefixCls,ln=Dt.className,fn=Dt.align,vn=Dt.record,Ln=Dt.render,Jn=Dt.dataIndex,Xn=Dt.renderIndex,gr=Dt.shouldCellUpdate,nr=Dt.index,Cr=Dt.rowType,Tr=Dt.colSpan,Gr=Dt.rowSpan,Or=Dt.fixLeft,Kr=Dt.fixRight,ni=Dt.firstFixLeft,Wr=Dt.lastFixLeft,ei=Dt.firstFixRight,Dr=Dt.lastFixRight,ar=Dt.appendNode,fr=Dt.additionalProps,cr=fr===void 0?{}:fr,Yr=Dt.isSticky,Xr="".concat(mn,"-cell"),Jr=ne(he,["supportSticky","allColumnsFixedLeft","rowHoverable"]),hi=Jr.supportSticky,ao=Jr.allColumnsFixedLeft,Hi=Jr.rowHoverable,Lo=et(vn,Jn,Xn,cn,Ln,gr),po=(0,ie.Z)(Lo,2),Ri=po[0],Ii=po[1],Pi={},mo=typeof Or=="number"&&hi,Fi=typeof Kr=="number"&&hi;mo&&(Pi.position="sticky",Pi.left=Or),Fi&&(Pi.position="sticky",Pi.right=Kr);var Ki=($t=(Zt=(en=Ii==null?void 0:Ii.colSpan)!==null&&en!==void 0?en:cr.colSpan)!==null&&Zt!==void 0?Zt:Tr)!==null&&$t!==void 0?$t:1,ji=(on=(hn=(Pn=Ii==null?void 0:Ii.rowSpan)!==null&&Pn!==void 0?Pn:cr.rowSpan)!==null&&hn!==void 0?hn:Gr)!==null&&on!==void 0?on:1,yr=ct(nr,ji),zr=(0,ie.Z)(yr,2),Ur=zr[0],Zr=zr[1],Ci=(0,Ot.zX)(function(Io){var Ui;vn&&Zr(nr,nr+ji-1),cr==null||(Ui=cr.onMouseEnter)===null||Ui===void 0||Ui.call(cr,Io)}),Oi=(0,Ot.zX)(function(Io){var Ui;vn&&Zr(-1,-1),cr==null||(Ui=cr.onMouseLeave)===null||Ui===void 0||Ui.call(cr,Io)});if(Ki===0||ji===0)return null;var Ao=(kn=cr.title)!==null&&kn!==void 0?kn:dt({rowType:Cr,ellipsis:dn,children:Ri}),Xi=Qe()(Xr,ln,(_n={},(0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)(_n,"".concat(Xr,"-fix-left"),mo&&hi),"".concat(Xr,"-fix-left-first"),ni&&hi),"".concat(Xr,"-fix-left-last"),Wr&&hi),"".concat(Xr,"-fix-left-all"),Wr&&ao&&hi),"".concat(Xr,"-fix-right"),Fi&&hi),"".concat(Xr,"-fix-right-first"),ei&&hi),"".concat(Xr,"-fix-right-last"),Dr&&hi),"".concat(Xr,"-ellipsis"),dn),"".concat(Xr,"-with-append"),ar),"".concat(Xr,"-fix-sticky"),(mo||Fi)&&Yr&&hi),(0,je.Z)(_n,"".concat(Xr,"-row-hover"),!Ii&&Ur)),cr.className,Ii==null?void 0:Ii.className),qi={};fn&&(qi.textAlign=fn);var ui=(0,Oe.Z)((0,Oe.Z)((0,Oe.Z)((0,Oe.Z)({},Ii==null?void 0:Ii.style),Pi),qi),cr.style),no=Ri;return(0,Ee.Z)(no)==="object"&&!Array.isArray(no)&&!te.isValidElement(no)&&(no=null),dn&&(Wr||ei)&&(no=te.createElement("span",{className:"".concat(Xr,"-content")},no)),te.createElement(Gt,(0,E.Z)({},Ii,cr,{className:Xi,style:ui,title:Ao,scope:un,onMouseEnter:Hi?Ci:void 0,onMouseLeave:Hi?Oi:void 0,colSpan:Ki!==1?Ki:null,rowSpan:ji!==1?ji:null}),ar,no)}var xt=te.memo(Rt);function gt(Dt,$t,Zt,en,on){var hn=Zt[Dt]||{},Pn=Zt[$t]||{},kn,_n;hn.fixed==="left"?kn=en.left[on==="rtl"?$t:Dt]:Pn.fixed==="right"&&(_n=en.right[on==="rtl"?Dt:$t]);var Gt=!1,cn=!1,dn=!1,un=!1,mn=Zt[$t+1],ln=Zt[Dt-1],fn=mn&&!mn.fixed||ln&&!ln.fixed||Zt.every(function(gr){return gr.fixed==="left"});if(on==="rtl"){if(kn!==void 0){var vn=ln&&ln.fixed==="left";un=!vn&&fn}else if(_n!==void 0){var Ln=mn&&mn.fixed==="right";dn=!Ln&&fn}}else if(kn!==void 0){var Jn=mn&&mn.fixed==="left";Gt=!Jn&&fn}else if(_n!==void 0){var Xn=ln&&ln.fixed==="right";cn=!Xn&&fn}return{fixLeft:kn,fixRight:_n,lastFixLeft:Gt,firstFixRight:cn,lastFixRight:dn,firstFixLeft:un,isSticky:en.isSticky}}var _t=te.createContext({}),We=_t;function Ae(Dt){var $t=Dt.className,Zt=Dt.index,en=Dt.children,on=Dt.colSpan,hn=on===void 0?1:on,Pn=Dt.rowSpan,kn=Dt.align,_n=ne(he,["prefixCls","direction"]),Gt=_n.prefixCls,cn=_n.direction,dn=te.useContext(We),un=dn.scrollColumnIndex,mn=dn.stickyOffsets,ln=dn.flattenColumns,fn=Zt+hn-1,vn=fn+1===un?hn+1:hn,Ln=gt(Zt,Zt+vn-1,ln,mn,cn);return te.createElement(xt,(0,E.Z)({className:$t,index:Zt,component:"td",prefixCls:Gt,record:null,dataIndex:null,align:kn,colSpan:vn,rowSpan:Pn,render:function(){return en}},Ln))}var Se=be(43079),Be=["children"];function Ke(Dt){var $t=Dt.children,Zt=(0,Se.Z)(Dt,Be);return te.createElement("tr",Zt,$t)}function Ne(Dt){var $t=Dt.children;return $t}Ne.Row=Ke,Ne.Cell=Ae;var De=Ne;function we(Dt){var $t=Dt.children,Zt=Dt.stickyOffsets,en=Dt.flattenColumns,on=ne(he,"prefixCls"),hn=en.length-1,Pn=en[hn],kn=te.useMemo(function(){return{stickyOffsets:Zt,flattenColumns:en,scrollColumnIndex:Pn!=null&&Pn.scrollbar?hn:null}},[Pn,en,hn,Zt]);return te.createElement(We.Provider,{value:kn},te.createElement("tfoot",{className:"".concat(on,"-summary")},$t))}var Le=me(we),Ue=De,Me=be(29301),Re=be(24514),tt=be(75152),lt=be(26112);function Nt(Dt,$t,Zt,en,on,hn,Pn){Dt.push({record:$t,indent:Zt,index:Pn});var kn=hn($t),_n=on==null?void 0:on.has(kn);if($t&&Array.isArray($t[en])&&_n)for(var Gt=0;Gt<$t[en].length;Gt+=1)Nt(Dt,$t[en][Gt],Zt+1,en,on,hn,Gt)}function Ct(Dt,$t,Zt,en){var on=te.useMemo(function(){if(Zt!=null&&Zt.size){for(var hn=[],Pn=0;Pn<(Dt==null?void 0:Dt.length);Pn+=1){var kn=Dt[Pn];Nt(hn,kn,0,$t,Zt,en,Pn)}return hn}return Dt==null?void 0:Dt.map(function(_n,Gt){return{record:_n,indent:0,index:Gt}})},[Dt,$t,Zt,en]);return on}function vt(Dt,$t,Zt,en){var on=ne(he,["prefixCls","fixedInfoList","flattenColumns","expandableType","expandRowByClick","onTriggerExpand","rowClassName","expandedRowClassName","indentSize","expandIcon","expandedRowRender","expandIconColumnIndex","expandedKeys","childrenColumnName","rowExpandable","onRow"]),hn=on.flattenColumns,Pn=on.expandableType,kn=on.expandedKeys,_n=on.childrenColumnName,Gt=on.onTriggerExpand,cn=on.rowExpandable,dn=on.onRow,un=on.expandRowByClick,mn=on.rowClassName,ln=Pn==="nest",fn=Pn==="row"&&(!cn||cn(Dt)),vn=fn||ln,Ln=kn&&kn.has($t),Jn=_n&&Dt&&Dt[_n],Xn=(0,Ot.zX)(Gt),gr=dn==null?void 0:dn(Dt,Zt),nr=gr==null?void 0:gr.onClick,Cr=function(Kr){un&&vn&&Gt(Dt,Kr);for(var ni=arguments.length,Wr=new Array(ni>1?ni-1:0),ei=1;ei<ni;ei++)Wr[ei-1]=arguments[ei];nr==null||nr.apply(void 0,[Kr].concat(Wr))},Tr;typeof mn=="string"?Tr=mn:typeof mn=="function"&&(Tr=mn(Dt,Zt,en));var Gr=ze(hn);return(0,Oe.Z)((0,Oe.Z)({},on),{},{columnsKey:Gr,nestExpandable:ln,expanded:Ln,hasNestChildren:Jn,record:Dt,onTriggerExpand:Xn,rowSupportExpand:fn,expandable:vn,rowProps:(0,Oe.Z)((0,Oe.Z)({},gr),{},{className:Qe()(Tr,gr==null?void 0:gr.className),onClick:Cr})})}function Pt(Dt){var $t=Dt.prefixCls,Zt=Dt.children,en=Dt.component,on=Dt.cellComponent,hn=Dt.className,Pn=Dt.expanded,kn=Dt.colSpan,_n=Dt.isEmpty,Gt=ne(he,["scrollbarSize","fixHeader","fixColumn","componentWidth","horizonScroll"]),cn=Gt.scrollbarSize,dn=Gt.fixHeader,un=Gt.fixColumn,mn=Gt.componentWidth,ln=Gt.horizonScroll,fn=Zt;return(_n?ln&&mn:un)&&(fn=te.createElement("div",{style:{width:mn-(dn&&!_n?cn:0),position:"sticky",left:0,overflow:"hidden"},className:"".concat($t,"-expanded-row-fixed")},fn)),te.createElement(en,{className:hn,style:{display:Pn?null:"none"}},te.createElement(xt,{component:on,prefixCls:$t,colSpan:kn},fn))}var Ht=Pt;function jt(Dt){var $t=Dt.prefixCls,Zt=Dt.record,en=Dt.onExpand,on=Dt.expanded,hn=Dt.expandable,Pn="".concat($t,"-row-expand-icon");if(!hn)return te.createElement("span",{className:Qe()(Pn,"".concat($t,"-row-spaced"))});var kn=function(Gt){en(Zt,Gt),Gt.stopPropagation()};return te.createElement("span",{className:Qe()(Pn,(0,je.Z)((0,je.Z)({},"".concat($t,"-row-expanded"),on),"".concat($t,"-row-collapsed"),!on)),onClick:kn})}function yt(Dt,$t,Zt){var en=[];function on(hn){(hn||[]).forEach(function(Pn,kn){en.push($t(Pn,kn)),on(Pn[Zt])})}return on(Dt),en}function Yt(Dt,$t,Zt,en){return typeof Dt=="string"?Dt:typeof Dt=="function"?Dt($t,Zt,en):""}function Lt(Dt,$t,Zt,en,on){var hn=Dt.record,Pn=Dt.prefixCls,kn=Dt.columnsKey,_n=Dt.fixedInfoList,Gt=Dt.expandIconColumnIndex,cn=Dt.nestExpandable,dn=Dt.indentSize,un=Dt.expandIcon,mn=Dt.expanded,ln=Dt.hasNestChildren,fn=Dt.onTriggerExpand,vn=kn[Zt],Ln=_n[Zt],Jn;Zt===(Gt||0)&&cn&&(Jn=te.createElement(te.Fragment,null,te.createElement("span",{style:{paddingLeft:"".concat(dn*en,"px")},className:"".concat(Pn,"-row-indent indent-level-").concat(en)}),un({prefixCls:Pn,expanded:mn,expandable:ln,record:hn,onExpand:fn})));var Xn;return $t.onCell&&(Xn=$t.onCell(hn,on)),{key:vn,fixedInfo:Ln,appendCellNode:Jn,additionalCellProps:Xn||{}}}function Kt(Dt){var $t=Dt.className,Zt=Dt.style,en=Dt.record,on=Dt.index,hn=Dt.renderIndex,Pn=Dt.rowKey,kn=Dt.indent,_n=kn===void 0?0:kn,Gt=Dt.rowComponent,cn=Dt.cellComponent,dn=Dt.scopeCellComponent,un=vt(en,Pn,on,_n),mn=un.prefixCls,ln=un.flattenColumns,fn=un.expandedRowClassName,vn=un.expandedRowRender,Ln=un.rowProps,Jn=un.expanded,Xn=un.rowSupportExpand,gr=te.useRef(!1);gr.current||(gr.current=Jn);var nr=Yt(fn,en,on,_n),Cr=te.createElement(Gt,(0,E.Z)({},Ln,{"data-row-key":Pn,className:Qe()($t,"".concat(mn,"-row"),"".concat(mn,"-row-level-").concat(_n),Ln==null?void 0:Ln.className,(0,je.Z)({},nr,_n>=1)),style:(0,Oe.Z)((0,Oe.Z)({},Zt),Ln==null?void 0:Ln.style)}),ln.map(function(Or,Kr){var ni=Or.render,Wr=Or.dataIndex,ei=Or.className,Dr=Lt(un,Or,Kr,_n,on),ar=Dr.key,fr=Dr.fixedInfo,cr=Dr.appendCellNode,Yr=Dr.additionalCellProps;return te.createElement(xt,(0,E.Z)({className:ei,ellipsis:Or.ellipsis,align:Or.align,scope:Or.rowScope,component:Or.rowScope?dn:cn,prefixCls:mn,key:ar,record:en,index:on,renderIndex:hn,dataIndex:Wr,render:ni,shouldCellUpdate:Or.shouldCellUpdate},fr,{appendNode:cr,additionalProps:Yr}))})),Tr;if(Xn&&(gr.current||Jn)){var Gr=vn(en,on,_n+1,Jn);Tr=te.createElement(Ht,{expanded:Jn,className:Qe()("".concat(mn,"-expanded-row"),"".concat(mn,"-expanded-row-level-").concat(_n+1),nr),prefixCls:mn,component:Gt,cellComponent:cn,colSpan:ln.length,isEmpty:!1},Gr)}return te.createElement(te.Fragment,null,Cr,Tr)}var sn=me(Kt);function wn(Dt){var $t=Dt.columnKey,Zt=Dt.onColumnResize,en=te.useRef();return(0,ue.Z)(function(){en.current&&Zt($t,en.current.offsetWidth)},[]),te.createElement(Me.Z,{data:$t},te.createElement("td",{ref:en,style:{padding:0,border:0,height:0}},te.createElement("div",{style:{height:0,overflow:"hidden"}},"\xA0")))}var Vt=be(29194);function Rn(Dt){var $t=Dt.prefixCls,Zt=Dt.columnsKey,en=Dt.onColumnResize,on=te.useRef(null);return te.createElement("tr",{"aria-hidden":"true",className:"".concat($t,"-measure-row"),style:{height:0,fontSize:0},ref:on},te.createElement(Me.Z.Collection,{onBatchResize:function(Pn){(0,Vt.Z)(on.current)&&Pn.forEach(function(kn){var _n=kn.data,Gt=kn.size;en(_n,Gt.offsetWidth)})}},Zt.map(function(hn){return te.createElement(wn,{key:hn,columnKey:hn,onColumnResize:en})})))}function Gn(Dt){var $t=Dt.data,Zt=Dt.measureColumnWidth,en=ne(he,["prefixCls","getComponent","onColumnResize","flattenColumns","getRowKey","expandedKeys","childrenColumnName","emptyNode"]),on=en.prefixCls,hn=en.getComponent,Pn=en.onColumnResize,kn=en.flattenColumns,_n=en.getRowKey,Gt=en.expandedKeys,cn=en.childrenColumnName,dn=en.emptyNode,un=Ct($t,cn,Gt,_n),mn=te.useRef({renderWithProps:!1}),ln=hn(["body","wrapper"],"tbody"),fn=hn(["body","row"],"tr"),vn=hn(["body","cell"],"td"),Ln=hn(["body","cell"],"th"),Jn;$t.length?Jn=un.map(function(gr,nr){var Cr=gr.record,Tr=gr.indent,Gr=gr.index,Or=_n(Cr,nr);return te.createElement(sn,{key:Or,rowKey:Or,record:Cr,index:nr,renderIndex:Gr,rowComponent:fn,cellComponent:vn,scopeCellComponent:Ln,indent:Tr})}):Jn=te.createElement(Ht,{expanded:!0,className:"".concat(on,"-placeholder"),prefixCls:on,component:fn,cellComponent:vn,colSpan:kn.length,isEmpty:!0},dn);var Xn=ze(kn);return te.createElement(Ye.Provider,{value:mn.current},te.createElement(ln,{className:"".concat(on,"-tbody")},Zt&&te.createElement(Rn,{prefixCls:on,columnsKey:Xn,onColumnResize:Pn}),Jn))}var Zn=me(Gn),tr=be(54451),hr=["columnType"];function ur(Dt){for(var $t=Dt.colWidths,Zt=Dt.columns,en=Dt.columCount,on=ne(he,["tableLayout"]),hn=on.tableLayout,Pn=[],kn=en||Zt.length,_n=!1,Gt=kn-1;Gt>=0;Gt-=1){var cn=$t[Gt],dn=Zt&&Zt[Gt],un=void 0,mn=void 0;if(dn&&(un=dn[tr.v],hn==="auto"&&(mn=dn.minWidth)),cn||mn||un||_n){var ln=un||{},fn=ln.columnType,vn=(0,Se.Z)(ln,hr);Pn.unshift(te.createElement("col",(0,E.Z)({key:Gt,style:{width:cn,minWidth:mn}},vn))),_n=!0}}return te.createElement("colgroup",null,Pn)}var zn=ur,Bn=be(3300),ir=["className","noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","stickyTopOffset","stickyBottomOffset","stickyClassName","onScroll","maxContentScroll","children"];function Kn(Dt,$t){return(0,te.useMemo)(function(){for(var Zt=[],en=0;en<$t;en+=1){var on=Dt[en];if(on!==void 0)Zt[en]=on;else return null}return Zt},[Dt.join("_"),$t])}var Nn=te.forwardRef(function(Dt,$t){var Zt=Dt.className,en=Dt.noData,on=Dt.columns,hn=Dt.flattenColumns,Pn=Dt.colWidths,kn=Dt.columCount,_n=Dt.stickyOffsets,Gt=Dt.direction,cn=Dt.fixHeader,dn=Dt.stickyTopOffset,un=Dt.stickyBottomOffset,mn=Dt.stickyClassName,ln=Dt.onScroll,fn=Dt.maxContentScroll,vn=Dt.children,Ln=(0,Se.Z)(Dt,ir),Jn=ne(he,["prefixCls","scrollbarSize","isSticky","getComponent"]),Xn=Jn.prefixCls,gr=Jn.scrollbarSize,nr=Jn.isSticky,Cr=Jn.getComponent,Tr=Cr(["header","table"],"table"),Gr=nr&&!cn?0:gr,Or=te.useRef(null),Kr=te.useCallback(function(Yr){(0,b.mH)($t,Yr),(0,b.mH)(Or,Yr)},[]);te.useEffect(function(){var Yr;function Xr(Jr){var hi=Jr,ao=hi.currentTarget,Hi=hi.deltaX;Hi&&(ln({currentTarget:ao,scrollLeft:ao.scrollLeft+Hi}),Jr.preventDefault())}return(Yr=Or.current)===null||Yr===void 0||Yr.addEventListener("wheel",Xr,{passive:!1}),function(){var Jr;(Jr=Or.current)===null||Jr===void 0||Jr.removeEventListener("wheel",Xr)}},[]);var ni=te.useMemo(function(){return hn.every(function(Yr){return Yr.width})},[hn]),Wr=hn[hn.length-1],ei={fixed:Wr?Wr.fixed:null,scrollbar:!0,onHeaderCell:function(){return{className:"".concat(Xn,"-cell-scrollbar")}}},Dr=(0,te.useMemo)(function(){return Gr?[].concat((0,Bn.Z)(on),[ei]):on},[Gr,on]),ar=(0,te.useMemo)(function(){return Gr?[].concat((0,Bn.Z)(hn),[ei]):hn},[Gr,hn]),fr=(0,te.useMemo)(function(){var Yr=_n.right,Xr=_n.left;return(0,Oe.Z)((0,Oe.Z)({},_n),{},{left:Gt==="rtl"?[].concat((0,Bn.Z)(Xr.map(function(Jr){return Jr+Gr})),[0]):Xr,right:Gt==="rtl"?Yr:[].concat((0,Bn.Z)(Yr.map(function(Jr){return Jr+Gr})),[0]),isSticky:nr})},[Gr,_n,nr]),cr=Kn(Pn,kn);return te.createElement("div",{style:(0,Oe.Z)({overflow:"hidden"},nr?{top:dn,bottom:un}:{}),ref:Kr,className:Qe()(Zt,(0,je.Z)({},mn,!!mn))},te.createElement(Tr,{style:{tableLayout:"fixed",visibility:en||cr?null:"hidden"}},(!en||!fn||ni)&&te.createElement(zn,{colWidths:cr?[].concat((0,Bn.Z)(cr),[Gr]):[],columCount:kn+1,columns:ar}),vn((0,Oe.Z)((0,Oe.Z)({},Ln),{},{stickyOffsets:fr,columns:Dr,flattenColumns:ar}))))}),yn=te.memo(Nn),Hn=function($t){var Zt=$t.cells,en=$t.stickyOffsets,on=$t.flattenColumns,hn=$t.rowComponent,Pn=$t.cellComponent,kn=$t.onHeaderRow,_n=$t.index,Gt=ne(he,["prefixCls","direction"]),cn=Gt.prefixCls,dn=Gt.direction,un;kn&&(un=kn(Zt.map(function(ln){return ln.column}),_n));var mn=ze(Zt.map(function(ln){return ln.column}));return te.createElement(hn,un,Zt.map(function(ln,fn){var vn=ln.column,Ln=gt(ln.colStart,ln.colEnd,on,en,dn),Jn;return vn&&vn.onHeaderCell&&(Jn=ln.column.onHeaderCell(vn)),te.createElement(xt,(0,E.Z)({},ln,{scope:vn.title?ln.colSpan>1?"colgroup":"col":null,ellipsis:vn.ellipsis,align:vn.align,component:Pn,prefixCls:cn,key:mn[fn]},Ln,{additionalProps:Jn,rowType:"header"}))}))},dr=Hn;function Mn(Dt){var $t=[];function Zt(Pn,kn){var _n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;$t[_n]=$t[_n]||[];var Gt=kn,cn=Pn.filter(Boolean).map(function(dn){var un={key:dn.key,className:dn.className||"",children:dn.title,column:dn,colStart:Gt},mn=1,ln=dn.children;return ln&&ln.length>0&&(mn=Zt(ln,Gt,_n+1).reduce(function(fn,vn){return fn+vn},0),un.hasSubColumns=!0),"colSpan"in dn&&(mn=dn.colSpan),"rowSpan"in dn&&(un.rowSpan=dn.rowSpan),un.colSpan=mn,un.colEnd=un.colStart+mn-1,$t[_n].push(un),Gt+=mn,mn});return cn}Zt(Dt,0);for(var en=$t.length,on=function(kn){$t[kn].forEach(function(_n){!("rowSpan"in _n)&&!_n.hasSubColumns&&(_n.rowSpan=en-kn)})},hn=0;hn<en;hn+=1)on(hn);return $t}var Cn=function($t){var Zt=$t.stickyOffsets,en=$t.columns,on=$t.flattenColumns,hn=$t.onHeaderRow,Pn=ne(he,["prefixCls","getComponent"]),kn=Pn.prefixCls,_n=Pn.getComponent,Gt=te.useMemo(function(){return Mn(en)},[en]),cn=_n(["header","wrapper"],"thead"),dn=_n(["header","row"],"tr"),un=_n(["header","cell"],"th");return te.createElement(cn,{className:"".concat(kn,"-thead")},Gt.map(function(mn,ln){var fn=te.createElement(dr,{key:ln,flattenColumns:on,cells:mn,stickyOffsets:Zt,rowComponent:dn,cellComponent:un,onHeaderRow:hn,index:ln});return fn}))},$n=me(Cn),Jt=be(97347);function Ie(Dt,$t,Zt){var en=(0,tr.g)(Dt),on=en.expandIcon,hn=en.expandedRowKeys,Pn=en.defaultExpandedRowKeys,kn=en.defaultExpandAllRows,_n=en.expandedRowRender,Gt=en.onExpand,cn=en.onExpandedRowsChange,dn=en.childrenColumnName,un=on||jt,mn=dn||"children",ln=te.useMemo(function(){return _n?"row":Dt.expandable&&Dt.internalHooks===ce.R&&Dt.expandable.__PARENT_RENDER_ICON__||$t.some(function(nr){return nr&&(0,Ee.Z)(nr)==="object"&&nr[mn]})?"nest":!1},[!!_n,$t]),fn=te.useState(function(){return Pn||(kn?yt($t,Zt,mn):[])}),vn=(0,ie.Z)(fn,2),Ln=vn[0],Jn=vn[1],Xn=te.useMemo(function(){return new Set(hn||Ln||[])},[hn,Ln]),gr=te.useCallback(function(nr){var Cr=Zt(nr,$t.indexOf(nr)),Tr,Gr=Xn.has(Cr);Gr?(Xn.delete(Cr),Tr=(0,Bn.Z)(Xn)):Tr=[].concat((0,Bn.Z)(Xn),[Cr]),Jn(Tr),Gt&&Gt(!Gr,nr),cn&&cn(Tr)},[Zt,Xn,$t,Gt,cn]);return[en,ln,Xn,un,mn,gr]}function Ze(Dt,$t,Zt){var en=Dt.map(function(on,hn){return gt(hn,hn,Dt,$t,Zt)});return(0,Xe.Z)(function(){return en},[en],function(on,hn){return!(0,se.Z)(on,hn)})}function qe(Dt){var $t=(0,te.useRef)(Dt),Zt=(0,te.useState)({}),en=(0,ie.Z)(Zt,2),on=en[1],hn=(0,te.useRef)(null),Pn=(0,te.useRef)([]);function kn(_n){Pn.current.push(_n);var Gt=Promise.resolve();hn.current=Gt,Gt.then(function(){if(hn.current===Gt){var cn=Pn.current,dn=$t.current;Pn.current=[],cn.forEach(function(un){$t.current=un($t.current)}),hn.current=null,dn!==$t.current&&on({})}})}return(0,te.useEffect)(function(){return function(){hn.current=null}},[]),[$t.current,kn]}function st(Dt){var $t=(0,te.useRef)(Dt||null),Zt=(0,te.useRef)();function en(){window.clearTimeout(Zt.current)}function on(Pn){$t.current=Pn,en(),Zt.current=window.setTimeout(function(){$t.current=null,Zt.current=void 0},100)}function hn(){return $t.current}return(0,te.useEffect)(function(){return en},[]),[on,hn]}function mt(){var Dt=te.useState(-1),$t=(0,ie.Z)(Dt,2),Zt=$t[0],en=$t[1],on=te.useState(-1),hn=(0,ie.Z)(on,2),Pn=hn[0],kn=hn[1],_n=te.useCallback(function(Gt,cn){en(Gt),kn(cn)},[]);return[Zt,Pn,_n]}var Bt=be(47273),kt=(0,Bt.Z)()?window:null;function Ft(Dt,$t){var Zt=(0,Ee.Z)(Dt)==="object"?Dt:{},en=Zt.offsetHeader,on=en===void 0?0:en,hn=Zt.offsetSummary,Pn=hn===void 0?0:hn,kn=Zt.offsetScroll,_n=kn===void 0?0:kn,Gt=Zt.getContainer,cn=Gt===void 0?function(){return kt}:Gt,dn=cn()||kt,un=!!Dt;return te.useMemo(function(){return{isSticky:un,stickyClassName:un?"".concat($t,"-sticky-holder"):"",offsetHeader:on,offsetSummary:Pn,offsetScroll:_n,container:dn}},[un,_n,on,Pn,$t,dn])}function qt(Dt,$t,Zt){var en=(0,te.useMemo)(function(){var on=$t.length,hn=function(Gt,cn,dn){for(var un=[],mn=0,ln=Gt;ln!==cn;ln+=dn)un.push(mn),$t[ln].fixed&&(mn+=Dt[ln]||0);return un},Pn=hn(0,on,1),kn=hn(on-1,-1,-1).reverse();return Zt==="rtl"?{left:kn,right:Pn}:{left:Pn,right:kn}},[Dt,$t,Zt]);return en}var En=qt;function Yn(Dt){var $t=Dt.className,Zt=Dt.children;return te.createElement("div",{className:$t},Zt)}var At=Yn,St=be(8224),an=be(16089),Wt=be(76846);function Et(Dt){var $t=(0,Wt.bn)(Dt),Zt=$t.getBoundingClientRect(),en=document.documentElement;return{left:Zt.left+(window.pageXOffset||en.scrollLeft)-(en.clientLeft||document.body.clientLeft||0),top:Zt.top+(window.pageYOffset||en.scrollTop)-(en.clientTop||document.body.clientTop||0)}}var zt=function($t,Zt){var en,on,hn=$t.scrollBodyRef,Pn=$t.onScroll,kn=$t.offsetScroll,_n=$t.container,Gt=$t.direction,cn=ne(he,"prefixCls"),dn=((en=hn.current)===null||en===void 0?void 0:en.scrollWidth)||0,un=((on=hn.current)===null||on===void 0?void 0:on.clientWidth)||0,mn=dn&&un*(un/dn),ln=te.useRef(),fn=qe({scrollLeft:0,isHiddenScrollBar:!0}),vn=(0,ie.Z)(fn,2),Ln=vn[0],Jn=vn[1],Xn=te.useRef({delta:0,x:0}),gr=te.useState(!1),nr=(0,ie.Z)(gr,2),Cr=nr[0],Tr=nr[1],Gr=te.useRef(null);te.useEffect(function(){return function(){an.Z.cancel(Gr.current)}},[]);var Or=function(){Tr(!1)},Kr=function(ar){ar.persist(),Xn.current.delta=ar.pageX-Ln.scrollLeft,Xn.current.x=0,Tr(!0),ar.preventDefault()},ni=function(ar){var fr,cr=ar||((fr=window)===null||fr===void 0?void 0:fr.event),Yr=cr.buttons;if(!Cr||Yr===0){Cr&&Tr(!1);return}var Xr=Xn.current.x+ar.pageX-Xn.current.x-Xn.current.delta,Jr=Gt==="rtl";Xr=Math.max(Jr?mn-un:0,Math.min(Jr?0:un-mn,Xr));var hi=!Jr||Math.abs(Xr)+Math.abs(mn)<un;hi&&(Pn({scrollLeft:Xr/un*(dn+2)}),Xn.current.x=ar.pageX)},Wr=function(){an.Z.cancel(Gr.current),Gr.current=(0,an.Z)(function(){if(hn.current){var ar=Et(hn.current).top,fr=ar+hn.current.offsetHeight,cr=_n===window?document.documentElement.scrollTop+window.innerHeight:Et(_n).top+_n.clientHeight;fr-(0,tt.Z)()<=cr||ar>=cr-kn?Jn(function(Yr){return(0,Oe.Z)((0,Oe.Z)({},Yr),{},{isHiddenScrollBar:!0})}):Jn(function(Yr){return(0,Oe.Z)((0,Oe.Z)({},Yr),{},{isHiddenScrollBar:!1})})}})},ei=function(ar){Jn(function(fr){return(0,Oe.Z)((0,Oe.Z)({},fr),{},{scrollLeft:ar/dn*un||0})})};return te.useImperativeHandle(Zt,function(){return{setScrollLeft:ei,checkScrollBarVisible:Wr}}),te.useEffect(function(){var Dr=(0,St.Z)(document.body,"mouseup",Or,!1),ar=(0,St.Z)(document.body,"mousemove",ni,!1);return Wr(),function(){Dr.remove(),ar.remove()}},[mn,Cr]),te.useEffect(function(){if(hn.current){for(var Dr=[],ar=(0,Wt.bn)(hn.current);ar;)Dr.push(ar),ar=ar.parentElement;return Dr.forEach(function(fr){return fr.addEventListener("scroll",Wr,!1)}),window.addEventListener("resize",Wr,!1),window.addEventListener("scroll",Wr,!1),_n.addEventListener("scroll",Wr,!1),function(){Dr.forEach(function(fr){return fr.removeEventListener("scroll",Wr)}),window.removeEventListener("resize",Wr),window.removeEventListener("scroll",Wr),_n.removeEventListener("scroll",Wr)}}},[_n]),te.useEffect(function(){Ln.isHiddenScrollBar||Jn(function(Dr){var ar=hn.current;return ar?(0,Oe.Z)((0,Oe.Z)({},Dr),{},{scrollLeft:ar.scrollLeft/ar.scrollWidth*ar.clientWidth}):Dr})},[Ln.isHiddenScrollBar]),dn<=un||!mn||Ln.isHiddenScrollBar?null:te.createElement("div",{style:{height:(0,tt.Z)(),width:un,bottom:kn},className:"".concat(cn,"-sticky-scroll")},te.createElement("div",{onMouseDown:Kr,ref:ln,className:Qe()("".concat(cn,"-sticky-scroll-bar"),(0,je.Z)({},"".concat(cn,"-sticky-scroll-bar-active"),Cr)),style:{width:"".concat(mn,"px"),transform:"translate3d(".concat(Ln.scrollLeft,"px, 0, 0)")}}))},tn=te.forwardRef(zt);function nn(Dt){return null}var gn=nn;function Sn(Dt){return null}var Tn=Sn,Tt="rc-table",jn=[],bn={};function Fn(){return"No Data"}function Un(Dt,$t){var Zt=(0,Oe.Z)({rowKey:"key",prefixCls:Tt,emptyText:Fn},Dt),en=Zt.prefixCls,on=Zt.className,hn=Zt.rowClassName,Pn=Zt.style,kn=Zt.data,_n=Zt.rowKey,Gt=Zt.scroll,cn=Zt.tableLayout,dn=Zt.direction,un=Zt.title,mn=Zt.footer,ln=Zt.summary,fn=Zt.caption,vn=Zt.id,Ln=Zt.showHeader,Jn=Zt.components,Xn=Zt.emptyText,gr=Zt.onRow,nr=Zt.onHeaderRow,Cr=Zt.onScroll,Tr=Zt.internalHooks,Gr=Zt.transformColumns,Or=Zt.internalRefs,Kr=Zt.tailor,ni=Zt.getContainerWidth,Wr=Zt.sticky,ei=Zt.rowHoverable,Dr=ei===void 0?!0:ei,ar=kn||jn,fr=!!ar.length,cr=Tr===ce.R,Yr=te.useCallback(function(pi,_r){return(0,ot.Z)(Jn,pi)||_r},[Jn]),Xr=te.useMemo(function(){return typeof _n=="function"?_n:function(pi){var _r=pi&&pi[_n];return _r}},[_n]),Jr=Yr(["body"]),hi=mt(),ao=(0,ie.Z)(hi,3),Hi=ao[0],Lo=ao[1],po=ao[2],Ri=Ie(Zt,ar,Xr),Ii=(0,ie.Z)(Ri,6),Pi=Ii[0],mo=Ii[1],Fi=Ii[2],Ki=Ii[3],ji=Ii[4],yr=Ii[5],zr=Gt==null?void 0:Gt.x,Ur=te.useState(0),Zr=(0,ie.Z)(Ur,2),Ci=Zr[0],Oi=Zr[1],Ao=(0,Jt.Z)((0,Oe.Z)((0,Oe.Z)((0,Oe.Z)({},Zt),Pi),{},{expandable:!!Pi.expandedRowRender,columnTitle:Pi.columnTitle,expandedKeys:Fi,getRowKey:Xr,onTriggerExpand:yr,expandIcon:Ki,expandIconColumnIndex:Pi.expandIconColumnIndex,direction:dn,scrollWidth:cr&&Kr&&typeof zr=="number"?zr:null,clientWidth:Ci}),cr?Gr:null),Xi=(0,ie.Z)(Ao,4),qi=Xi[0],ui=Xi[1],no=Xi[2],Io=Xi[3],Ui=no!=null?no:zr,Ho=te.useMemo(function(){return{columns:qi,flattenColumns:ui}},[qi,ui]),xo=te.useRef(),Oo=te.useRef(),Vi=te.useRef(),Wo=te.useRef();te.useImperativeHandle($t,function(){return{nativeElement:xo.current,scrollTo:function(_r){var Ei;if(Vi.current instanceof HTMLElement){var bo=_r.index,Ni=_r.top,Na=_r.key;if($e(Ni)){var va;(va=Vi.current)===null||va===void 0||va.scrollTo({top:Ni})}else{var Aa,Po=Na!=null?Na:Xr(ar[bo]);(Aa=Vi.current.querySelector('[data-row-key="'.concat(Po,'"]')))===null||Aa===void 0||Aa.scrollIntoView()}}else(Ei=Vi.current)!==null&&Ei!==void 0&&Ei.scrollTo&&Vi.current.scrollTo(_r)}}});var za=te.useRef(),Yo=te.useState(!1),la=(0,ie.Z)(Yo,2),Zo=la[0],Da=la[1],qa=te.useState(!1),ba=(0,ie.Z)(qa,2),cs=ba[0],Ma=ba[1],Ha=te.useState(new Map),Ra=(0,ie.Z)(Ha,2),pa=Ra[0],Wa=Ra[1],Ja=ze(ui),Sa=Ja.map(function(pi){return pa.get(pi)}),wa=te.useMemo(function(){return Sa},[Sa.join("_")]),ua=En(wa,ui,dn),To=Gt&&Ve(Gt.y),Ji=Gt&&Ve(Ui)||!!Pi.fixed,vi=Ji&&ui.some(function(pi){var _r=pi.fixed;return _r}),si=te.useRef(),ro=Ft(Wr,en),Qi=ro.isSticky,io=ro.offsetHeader,co=ro.offsetSummary,na=ro.offsetScroll,Go=ro.stickyClassName,ca=ro.container,$i=te.useMemo(function(){return ln==null?void 0:ln(ar)},[ln,ar]),go=(To||Qi)&&te.isValidElement($i)&&$i.type===De&&$i.props.fixed,Fo,Xo,Ia;To&&(Xo={overflowY:fr?"scroll":"auto",maxHeight:Gt.y}),Ji&&(Fo={overflowX:"auto"},To||(Xo={overflowY:"hidden"}),Ia={width:Ui===!0?"auto":Ui,minWidth:"100%"});var ds=te.useCallback(function(pi,_r){Wa(function(Ei){if(Ei.get(pi)!==_r){var bo=new Map(Ei);return bo.set(pi,_r),bo}return Ei})},[]),fs=st(null),da=(0,ie.Z)(fs,2),yo=da[0],Co=da[1];function Eo(pi,_r){_r&&(typeof _r=="function"?_r(pi):_r.scrollLeft!==pi&&(_r.scrollLeft=pi,_r.scrollLeft!==pi&&setTimeout(function(){_r.scrollLeft=pi},0)))}var Ko=(0,Ce.Z)(function(pi){var _r=pi.currentTarget,Ei=pi.scrollLeft,bo=dn==="rtl",Ni=typeof Ei=="number"?Ei:_r.scrollLeft,Na=_r||bn;if(!Co()||Co()===Na){var va;yo(Na),Eo(Ni,Oo.current),Eo(Ni,Vi.current),Eo(Ni,za.current),Eo(Ni,(va=si.current)===null||va===void 0?void 0:va.setScrollLeft)}var Aa=_r||Oo.current;if(Aa){var Po=cr&&Kr&&typeof Ui=="number"?Ui:Aa.scrollWidth,fa=Aa.clientWidth;if(Po===fa){Da(!1),Ma(!1);return}bo?(Da(-Ni<Po-fa),Ma(-Ni>0)):(Da(Ni>0),Ma(Ni<Po-fa))}}),Qa=(0,Ce.Z)(function(pi){Ko(pi),Cr==null||Cr(pi)}),xa=function(){if(Ji&&Vi.current){var _r;Ko({currentTarget:(0,Wt.bn)(Vi.current),scrollLeft:(_r=Vi.current)===null||_r===void 0?void 0:_r.scrollLeft})}else Da(!1),Ma(!1)},_s=function(_r){var Ei,bo=_r.width;(Ei=si.current)===null||Ei===void 0||Ei.checkScrollBarVisible();var Ni=xo.current?xo.current.offsetWidth:bo;cr&&ni&&xo.current&&(Ni=ni(xo.current,Ni)||Ni),Ni!==Ci&&(xa(),Oi(Ni))},Oa=te.useRef(!1);te.useEffect(function(){Oa.current&&xa()},[Ji,kn,qi.length]),te.useEffect(function(){Oa.current=!0},[]);var bs=te.useState(0),$a=(0,ie.Z)(bs,2),Ca=$a[0],Ss=$a[1],es=te.useState(!0),ra=(0,ie.Z)(es,2),Za=ra[0],Ea=ra[1];(0,ue.Z)(function(){(!Kr||!cr)&&(Vi.current instanceof Element?Ss((0,tt.o)(Vi.current).width):Ss((0,tt.o)(Wo.current).width)),Ea((0,Re.G)("position","sticky"))},[]),te.useEffect(function(){cr&&Or&&(Or.body.current=Vi.current)});var Ga=te.useCallback(function(pi){return te.createElement(te.Fragment,null,te.createElement($n,pi),go==="top"&&te.createElement(Le,pi,$i))},[go,$i]),ts=te.useCallback(function(pi){return te.createElement(Le,pi,$i)},[$i]),hs=Yr(["table"],"table"),ka=te.useMemo(function(){return cn||(vi?Ui==="max-content"?"auto":"fixed":To||Qi||ui.some(function(pi){var _r=pi.ellipsis;return _r})?"fixed":"auto")},[To,vi,ui,cn,Qi]),ps,ms={colWidths:wa,columCount:ui.length,stickyOffsets:ua,onHeaderRow:nr,fixHeader:To,scroll:Gt},ws=te.useMemo(function(){return fr?null:typeof Xn=="function"?Xn():Xn},[fr,Xn]),ns=te.createElement(Zn,{data:ar,measureColumnWidth:To||Ji||Qi}),rs=te.createElement(zn,{colWidths:ui.map(function(pi){var _r=pi.width;return _r}),columns:ui}),La=fn!=null?te.createElement("caption",{className:"".concat(en,"-caption")},fn):void 0,Nr=(0,lt.Z)(Zt,{data:!0}),xs=(0,lt.Z)(Zt,{aria:!0});if(To||Qi){var Pa;typeof Jr=="function"?(Pa=Jr(ar,{scrollbarSize:Ca,ref:Vi,onScroll:Ko}),ms.colWidths=ui.map(function(pi,_r){var Ei=pi.width,bo=_r===ui.length-1?Ei-Ca:Ei;return typeof bo=="number"&&!Number.isNaN(bo)?bo:0})):Pa=te.createElement("div",{style:(0,Oe.Z)((0,Oe.Z)({},Fo),Xo),onScroll:Qa,ref:Vi,className:Qe()("".concat(en,"-body"))},te.createElement(hs,(0,E.Z)({style:(0,Oe.Z)((0,Oe.Z)({},Ia),{},{tableLayout:ka})},xs),La,rs,ns,!go&&$i&&te.createElement(Le,{stickyOffsets:ua,flattenColumns:ui},$i)));var vs=(0,Oe.Z)((0,Oe.Z)((0,Oe.Z)({noData:!ar.length,maxContentScroll:Ji&&Ui==="max-content"},ms),Ho),{},{direction:dn,stickyClassName:Go,onScroll:Ko});ps=te.createElement(te.Fragment,null,Ln!==!1&&te.createElement(yn,(0,E.Z)({},vs,{stickyTopOffset:io,className:"".concat(en,"-header"),ref:Oo}),Ga),Pa,go&&go!=="top"&&te.createElement(yn,(0,E.Z)({},vs,{stickyBottomOffset:co,className:"".concat(en,"-summary"),ref:za}),ts),Qi&&Vi.current&&Vi.current instanceof Element&&te.createElement(tn,{ref:si,offsetScroll:na,scrollBodyRef:Vi,onScroll:Ko,container:ca,direction:dn}))}else ps=te.createElement("div",{style:(0,Oe.Z)((0,Oe.Z)({},Fo),Xo),className:Qe()("".concat(en,"-content")),onScroll:Ko,ref:Vi},te.createElement(hs,(0,E.Z)({style:(0,Oe.Z)((0,Oe.Z)({},Ia),{},{tableLayout:ka})},xs),La,rs,Ln!==!1&&te.createElement($n,(0,E.Z)({},ms,Ho)),ns,$i&&te.createElement(Le,{stickyOffsets:ua,flattenColumns:ui},$i)));var ia=te.createElement("div",(0,E.Z)({className:Qe()(en,on,(0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)((0,je.Z)({},"".concat(en,"-rtl"),dn==="rtl"),"".concat(en,"-ping-left"),Zo),"".concat(en,"-ping-right"),cs),"".concat(en,"-layout-fixed"),cn==="fixed"),"".concat(en,"-fixed-header"),To),"".concat(en,"-fixed-column"),vi),"".concat(en,"-fixed-column-gapped"),vi&&Io),"".concat(en,"-scroll-horizontal"),Ji),"".concat(en,"-has-fix-left"),ui[0]&&ui[0].fixed),"".concat(en,"-has-fix-right"),ui[ui.length-1]&&ui[ui.length-1].fixed==="right")),style:Pn,id:vn,ref:xo},Nr),un&&te.createElement(At,{className:"".concat(en,"-title")},un(ar)),te.createElement("div",{ref:Wo,className:"".concat(en,"-container")},ps),mn&&te.createElement(At,{className:"".concat(en,"-footer")},mn(ar)));Ji&&(ia=te.createElement(Me.Z,{onResize:_s},ia));var is=Ze(ui,ua,dn),ma=te.useMemo(function(){return{scrollX:Ui,prefixCls:en,getComponent:Yr,scrollbarSize:Ca,direction:dn,fixedInfoList:is,isSticky:Qi,supportSticky:Za,componentWidth:Ci,fixHeader:To,fixColumn:vi,horizonScroll:Ji,tableLayout:ka,rowClassName:hn,expandedRowClassName:Pi.expandedRowClassName,expandIcon:Ki,expandableType:mo,expandRowByClick:Pi.expandRowByClick,expandedRowRender:Pi.expandedRowRender,onTriggerExpand:yr,expandIconColumnIndex:Pi.expandIconColumnIndex,indentSize:Pi.indentSize,allColumnsFixedLeft:ui.every(function(pi){return pi.fixed==="left"}),emptyNode:ws,columns:qi,flattenColumns:ui,onColumnResize:ds,hoverStartRow:Hi,hoverEndRow:Lo,onHover:po,rowExpandable:Pi.rowExpandable,onRow:gr,getRowKey:Xr,expandedKeys:Fi,childrenColumnName:ji,rowHoverable:Dr}},[Ui,en,Yr,Ca,dn,is,Qi,Za,Ci,To,vi,Ji,ka,hn,Pi.expandedRowClassName,Ki,mo,Pi.expandRowByClick,Pi.expandedRowRender,yr,Pi.expandIconColumnIndex,Pi.indentSize,ws,qi,ui,ds,Hi,Lo,po,Pi.rowExpandable,gr,Xr,Fi,ji,Dr]);return te.createElement(he.Provider,{value:ma},ia)}var rr=te.forwardRef(Un);function pr(Dt){return ye(rr,Dt)}var Rr=pr();Rr.EXPAND_COLUMN=ce.w,Rr.INTERNAL_HOOKS=ce.R,Rr.Column=gn,Rr.ColumnGroup=Tn,Rr.Summary=Ue;var wr=Rr,Lr=be(6790),Vr=ee(null),xr=ee(null);function Ir(Dt,$t,Zt){var en=$t||1;return Zt[Dt+en]-(Zt[Dt]||0)}function jr(Dt){var $t=Dt.rowInfo,Zt=Dt.column,en=Dt.colIndex,on=Dt.indent,hn=Dt.index,Pn=Dt.component,kn=Dt.renderIndex,_n=Dt.record,Gt=Dt.style,cn=Dt.className,dn=Dt.inverse,un=Dt.getHeight,mn=Zt.render,ln=Zt.dataIndex,fn=Zt.className,vn=Zt.width,Ln=ne(xr,["columnsOffset"]),Jn=Ln.columnsOffset,Xn=Lt($t,Zt,en,on,hn),gr=Xn.key,nr=Xn.fixedInfo,Cr=Xn.appendCellNode,Tr=Xn.additionalCellProps,Gr=Tr.style,Or=Tr.colSpan,Kr=Or===void 0?1:Or,ni=Tr.rowSpan,Wr=ni===void 0?1:ni,ei=en-1,Dr=Ir(ei,Kr,Jn),ar=Kr>1?vn-Dr:0,fr=(0,Oe.Z)((0,Oe.Z)((0,Oe.Z)({},Gr),Gt),{},{flex:"0 0 ".concat(Dr,"px"),width:"".concat(Dr,"px"),marginRight:ar,pointerEvents:"auto"}),cr=te.useMemo(function(){return dn?Wr<=1:Kr===0||Wr===0||Wr>1},[Wr,Kr,dn]);cr?fr.visibility="hidden":dn&&(fr.height=un==null?void 0:un(Wr));var Yr=cr?function(){return null}:mn,Xr={};return(Wr===0||Kr===0)&&(Xr.rowSpan=1,Xr.colSpan=1),te.createElement(xt,(0,E.Z)({className:Qe()(fn,cn),ellipsis:Zt.ellipsis,align:Zt.align,scope:Zt.rowScope,component:Pn,prefixCls:$t.prefixCls,key:gr,record:_n,index:hn,renderIndex:kn,dataIndex:ln,render:Yr,shouldCellUpdate:Zt.shouldCellUpdate},nr,{appendNode:Cr,additionalProps:(0,Oe.Z)((0,Oe.Z)({},Tr),{},{style:fr},Xr)}))}var ti=jr,di=["data","index","className","rowKey","style","extra","getHeight"],wi=te.forwardRef(function(Dt,$t){var Zt=Dt.data,en=Dt.index,on=Dt.className,hn=Dt.rowKey,Pn=Dt.style,kn=Dt.extra,_n=Dt.getHeight,Gt=(0,Se.Z)(Dt,di),cn=Zt.record,dn=Zt.indent,un=Zt.index,mn=ne(he,["prefixCls","flattenColumns","fixColumn","componentWidth","scrollX"]),ln=mn.scrollX,fn=mn.flattenColumns,vn=mn.prefixCls,Ln=mn.fixColumn,Jn=mn.componentWidth,Xn=ne(Vr,["getComponent"]),gr=Xn.getComponent,nr=vt(cn,hn,en,dn),Cr=gr(["body","row"],"div"),Tr=gr(["body","cell"],"div"),Gr=nr.rowSupportExpand,Or=nr.expanded,Kr=nr.rowProps,ni=nr.expandedRowRender,Wr=nr.expandedRowClassName,ei;if(Gr&&Or){var Dr=ni(cn,en,dn+1,Or),ar=Yt(Wr,cn,en,dn),fr={};Ln&&(fr={style:(0,je.Z)({},"--virtual-width","".concat(Jn,"px"))});var cr="".concat(vn,"-expanded-row-cell");ei=te.createElement(Cr,{className:Qe()("".concat(vn,"-expanded-row"),"".concat(vn,"-expanded-row-level-").concat(dn+1),ar)},te.createElement(xt,{component:Tr,prefixCls:vn,className:Qe()(cr,(0,je.Z)({},"".concat(cr,"-fixed"),Ln)),additionalProps:fr},Dr))}var Yr=(0,Oe.Z)((0,Oe.Z)({},Pn),{},{width:ln});kn&&(Yr.position="absolute",Yr.pointerEvents="none");var Xr=te.createElement(Cr,(0,E.Z)({},Kr,Gt,{"data-row-key":hn,ref:Gr?null:$t,className:Qe()(on,"".concat(vn,"-row"),Kr==null?void 0:Kr.className,(0,je.Z)({},"".concat(vn,"-row-extra"),kn)),style:(0,Oe.Z)((0,Oe.Z)({},Yr),Kr==null?void 0:Kr.style)}),fn.map(function(Jr,hi){return te.createElement(ti,{key:hi,component:Tr,rowInfo:nr,column:Jr,colIndex:hi,indent:dn,index:en,renderIndex:un,record:cn,inverse:kn,getHeight:_n})}));return Gr?te.createElement("div",{ref:$t},Xr,ei):Xr}),xi=me(wi),ai=xi,Di=te.forwardRef(function(Dt,$t){var Zt=Dt.data,en=Dt.onScroll,on=ne(he,["flattenColumns","onColumnResize","getRowKey","prefixCls","expandedKeys","childrenColumnName","scrollX","direction"]),hn=on.flattenColumns,Pn=on.onColumnResize,kn=on.getRowKey,_n=on.expandedKeys,Gt=on.prefixCls,cn=on.childrenColumnName,dn=on.scrollX,un=on.direction,mn=ne(Vr),ln=mn.sticky,fn=mn.scrollY,vn=mn.listItemHeight,Ln=mn.getComponent,Jn=mn.onScroll,Xn=te.useRef(),gr=Ct(Zt,cn,_n,kn),nr=te.useMemo(function(){var ei=0;return hn.map(function(Dr){var ar=Dr.width,fr=Dr.key;return ei+=ar,[fr,ar,ei]})},[hn]),Cr=te.useMemo(function(){return nr.map(function(ei){return ei[2]})},[nr]);te.useEffect(function(){nr.forEach(function(ei){var Dr=(0,ie.Z)(ei,2),ar=Dr[0],fr=Dr[1];Pn(ar,fr)})},[nr]),te.useImperativeHandle($t,function(){var ei,Dr={scrollTo:function(fr){var cr;(cr=Xn.current)===null||cr===void 0||cr.scrollTo(fr)},nativeElement:(ei=Xn.current)===null||ei===void 0?void 0:ei.nativeElement};return Object.defineProperty(Dr,"scrollLeft",{get:function(){var fr;return((fr=Xn.current)===null||fr===void 0?void 0:fr.getScrollInfo().x)||0},set:function(fr){var cr;(cr=Xn.current)===null||cr===void 0||cr.scrollTo({left:fr})}}),Dr});var Tr=function(Dr,ar){var fr,cr=(fr=gr[ar])===null||fr===void 0?void 0:fr.record,Yr=Dr.onCell;if(Yr){var Xr,Jr=Yr(cr,ar);return(Xr=Jr==null?void 0:Jr.rowSpan)!==null&&Xr!==void 0?Xr:1}return 1},Gr=function(Dr){var ar=Dr.start,fr=Dr.end,cr=Dr.getSize,Yr=Dr.offsetY;if(fr<0)return null;for(var Xr=hn.filter(function(Ki){return Tr(Ki,ar)===0}),Jr=ar,hi=function(ji){if(Xr=Xr.filter(function(yr){return Tr(yr,ji)===0}),!Xr.length)return Jr=ji,1},ao=ar;ao>=0&&!hi(ao);ao-=1);for(var Hi=hn.filter(function(Ki){return Tr(Ki,fr)!==1}),Lo=fr,po=function(ji){if(Hi=Hi.filter(function(yr){return Tr(yr,ji)!==1}),!Hi.length)return Lo=Math.max(ji-1,fr),1},Ri=fr;Ri<gr.length&&!po(Ri);Ri+=1);for(var Ii=[],Pi=function(ji){var yr=gr[ji];if(!yr)return 1;hn.some(function(zr){return Tr(zr,ji)>1})&&Ii.push(ji)},mo=Jr;mo<=Lo;mo+=1)Pi(mo);var Fi=Ii.map(function(Ki){var ji=gr[Ki],yr=kn(ji.record,Ki),zr=function(Ci){var Oi=Ki+Ci-1,Ao=kn(gr[Oi].record,Oi),Xi=cr(yr,Ao);return Xi.bottom-Xi.top},Ur=cr(yr);return te.createElement(ai,{key:Ki,data:ji,rowKey:yr,index:Ki,style:{top:-Yr+Ur.top},extra:!0,getHeight:zr})});return Fi},Or=te.useMemo(function(){return{columnsOffset:Cr}},[Cr]),Kr="".concat(Gt,"-tbody"),ni=Ln(["body","wrapper"]),Wr={};return ln&&(Wr.position="sticky",Wr.bottom=0,(0,Ee.Z)(ln)==="object"&&ln.offsetScroll&&(Wr.bottom=ln.offsetScroll)),te.createElement(xr.Provider,{value:Or},te.createElement(Lr.Z,{fullHeight:!1,ref:Xn,prefixCls:"".concat(Kr,"-virtual"),styles:{horizontalScrollBar:Wr},className:Kr,height:fn,itemHeight:vn||24,data:gr,itemKey:function(Dr){return kn(Dr.record)},component:ni,scrollWidth:dn,direction:un,onVirtualScroll:function(Dr){var ar,fr=Dr.x;en({currentTarget:(ar=Xn.current)===null||ar===void 0?void 0:ar.nativeElement,scrollLeft:fr})},onScroll:Jn,extraRender:Gr},function(ei,Dr,ar){var fr=kn(ei.record,Dr);return te.createElement(ai,{data:ei,rowKey:fr,index:Dr,style:ar.style})}))}),_i=me(Di),or=_i,br=function($t,Zt){var en=Zt.ref,on=Zt.onScroll;return te.createElement(or,{ref:en,data:$t,onScroll:on})};function Ar(Dt,$t){var Zt=Dt.data,en=Dt.columns,on=Dt.scroll,hn=Dt.sticky,Pn=Dt.prefixCls,kn=Pn===void 0?Tt:Pn,_n=Dt.className,Gt=Dt.listItemHeight,cn=Dt.components,dn=Dt.onScroll,un=on||{},mn=un.x,ln=un.y;typeof mn!="number"&&(mn=1),typeof ln!="number"&&(ln=500);var fn=(0,Ot.zX)(function(Jn,Xn){return(0,ot.Z)(cn,Jn)||Xn}),vn=(0,Ot.zX)(dn),Ln=te.useMemo(function(){return{sticky:hn,scrollY:ln,listItemHeight:Gt,getComponent:fn,onScroll:vn}},[hn,ln,Gt,fn,vn]);return te.createElement(Vr.Provider,{value:Ln},te.createElement(wr,(0,E.Z)({},Dt,{className:Qe()(_n,"".concat(kn,"-virtual")),scroll:(0,Oe.Z)((0,Oe.Z)({},on),{},{x:mn}),components:(0,Oe.Z)((0,Oe.Z)({},cn),{},{body:Zt!=null&&Zt.length?br:void 0}),columns:en,internalHooks:ce.R,tailor:!0,ref:$t})))}var qr=te.forwardRef(Ar);function $r(Dt){return ye(qr,Dt)}var bi=$r(),Wi=null},54451:function(Xt,Mt,be){"use strict";be.d(Mt,{g:function(){return te},v:function(){return se}});var ce=be(27247),ie=be(43079),Ce=be(48736),ue=["expandable"],se="RC_TABLE_INTERNAL_COL_DEFINE";function te(le){var ee=le.expandable,ne=(0,ie.Z)(le,ue),E;return"expandable"in le?E=(0,ce.Z)((0,ce.Z)({},ne),ee):E=ne,E.showExpandColumn===!1&&(E.expandIconColumnIndex=-1),E}},22711:function(Xt,Mt,be){"use strict";be.r(Mt),be.d(Mt,{ResizableTextArea:function(){return Pe},default:function(){return He}});var ce=be(32855),ie=be(74430),Ce=be(27247),ue=be(3300),se=be(11913),te=be(43079),le=be(92310),ee=be.n(le),ne=be(36901),E=be(66003),b=be(30292),z=be(18929),x=be(59301),re=be(34666),ae=be(29301),oe=be(34280),ve=be(16089),ye=`
|
|
|
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;
|
|
|
pointer-events: none !important;
|
|
|
`,me=["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","white-space"],ge={},_e;function he(rt){var Ye=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,ut=rt.getAttribute("id")||rt.getAttribute("data-reactid")||rt.getAttribute("name");if(Ye&&ge[ut])return ge[ut];var Ge=window.getComputedStyle(rt),ze=Ge.getPropertyValue("box-sizing")||Ge.getPropertyValue("-moz-box-sizing")||Ge.getPropertyValue("-webkit-box-sizing"),Ve=parseFloat(Ge.getPropertyValue("padding-bottom"))+parseFloat(Ge.getPropertyValue("padding-top")),$e=parseFloat(Ge.getPropertyValue("border-bottom-width"))+parseFloat(Ge.getPropertyValue("border-top-width")),nt=me.map(function(pt){return"".concat(pt,":").concat(Ge.getPropertyValue(pt))}).join(";"),et={sizingStyle:nt,paddingSize:Ve,borderSize:$e,boxSizing:ze};return Ye&&ut&&(ge[ut]=et),et}function pe(rt){var Ye=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,ut=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,Ge=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null;_e||(_e=document.createElement("textarea"),_e.setAttribute("tab-index","-1"),_e.setAttribute("aria-hidden","true"),_e.setAttribute("name","hiddenTextarea"),document.body.appendChild(_e)),rt.getAttribute("wrap")?_e.setAttribute("wrap",rt.getAttribute("wrap")):_e.removeAttribute("wrap");var ze=he(rt,Ye),Ve=ze.paddingSize,$e=ze.borderSize,nt=ze.boxSizing,et=ze.sizingStyle;_e.setAttribute("style","".concat(et,";").concat(ye)),_e.value=rt.value||rt.placeholder||"";var pt=void 0,ct=void 0,Ot,dt=_e.scrollHeight;if(nt==="border-box"?dt+=$e:nt==="content-box"&&(dt-=Ve),ut!==null||Ge!==null){_e.value=" ";var Rt=_e.scrollHeight-Ve;ut!==null&&(pt=Rt*ut,nt==="border-box"&&(pt=pt+Ve+$e),dt=Math.max(pt,dt)),Ge!==null&&(ct=Rt*Ge,nt==="border-box"&&(ct=ct+Ve+$e),Ot=dt>ct?"":"hidden",dt=Math.min(ct,dt))}var xt={height:dt,overflowY:Ot,resize:"none"};return pt&&(xt.minHeight=pt),ct&&(xt.maxHeight=ct),xt}var ke=["prefixCls","defaultValue","value","autoSize","onResize","className","style","disabled","onChange","onInternalAutoSize"],Te=0,Ee=1,Oe=2,je=x.forwardRef(function(rt,Ye){var ut=rt,Ge=ut.prefixCls,ze=ut.defaultValue,Ve=ut.value,$e=ut.autoSize,nt=ut.onResize,et=ut.className,pt=ut.style,ct=ut.disabled,Ot=ut.onChange,dt=ut.onInternalAutoSize,Rt=(0,te.Z)(ut,ke),xt=(0,z.Z)(ze,{value:Ve,postState:function(sn){return sn!=null?sn:""}}),gt=(0,se.Z)(xt,2),_t=gt[0],We=gt[1],Ae=function(sn){We(sn.target.value),Ot==null||Ot(sn)},Se=x.useRef();x.useImperativeHandle(Ye,function(){return{textArea:Se.current}});var Be=x.useMemo(function(){return $e&&(0,re.Z)($e)==="object"?[$e.minRows,$e.maxRows]:[]},[$e]),Ke=(0,se.Z)(Be,2),Ne=Ke[0],De=Ke[1],we=!!$e,Le=function(){try{if(document.activeElement===Se.current){var sn=Se.current,wn=sn.selectionStart,Vt=sn.selectionEnd,Rn=sn.scrollTop;Se.current.setSelectionRange(wn,Vt),Se.current.scrollTop=Rn}}catch(Gn){}},Ue=x.useState(Oe),Me=(0,se.Z)(Ue,2),Re=Me[0],tt=Me[1],lt=x.useState(),Nt=(0,se.Z)(lt,2),Ct=Nt[0],vt=Nt[1],Pt=function(){tt(Te)};(0,oe.Z)(function(){we&&Pt()},[Ve,Ne,De,we]),(0,oe.Z)(function(){if(Re===Te)tt(Ee);else if(Re===Ee){var Kt=pe(Se.current,!1,Ne,De);tt(Oe),vt(Kt)}else Le()},[Re]);var Ht=x.useRef(),jt=function(){ve.Z.cancel(Ht.current)},yt=function(sn){Re===Oe&&(nt==null||nt(sn),$e&&(jt(),Ht.current=(0,ve.Z)(function(){Pt()})))};x.useEffect(function(){return jt},[]);var Yt=we?Ct:null,Lt=(0,Ce.Z)((0,Ce.Z)({},pt),Yt);return(Re===Te||Re===Ee)&&(Lt.overflowY="hidden",Lt.overflowX="hidden"),x.createElement(ae.Z,{onResize:yt,disabled:!($e||nt)},x.createElement("textarea",(0,ce.Z)({},Rt,{ref:Se,style:Lt,className:ee()(Ge,et,(0,ie.Z)({},"".concat(Ge,"-disabled"),ct)),disabled:ct,value:_t,onChange:Ae})))}),Pe=je,Qe=["defaultValue","value","onFocus","onBlur","onChange","allowClear","maxLength","onCompositionStart","onCompositionEnd","suffix","prefixCls","showCount","count","className","style","disabled","hidden","classNames","styles","onResize","onClear","onPressEnter","readOnly","autoSize","onKeyDown"],Xe=x.forwardRef(function(rt,Ye){var ut,Ge=rt.defaultValue,ze=rt.value,Ve=rt.onFocus,$e=rt.onBlur,nt=rt.onChange,et=rt.allowClear,pt=rt.maxLength,ct=rt.onCompositionStart,Ot=rt.onCompositionEnd,dt=rt.suffix,Rt=rt.prefixCls,xt=Rt===void 0?"rc-textarea":Rt,gt=rt.showCount,_t=rt.count,We=rt.className,Ae=rt.style,Se=rt.disabled,Be=rt.hidden,Ke=rt.classNames,Ne=rt.styles,De=rt.onResize,we=rt.onClear,Le=rt.onPressEnter,Ue=rt.readOnly,Me=rt.autoSize,Re=rt.onKeyDown,tt=(0,te.Z)(rt,Qe),lt=(0,z.Z)(Ge,{value:ze,defaultValue:Ge}),Nt=(0,se.Z)(lt,2),Ct=Nt[0],vt=Nt[1],Pt=Ct==null?"":String(Ct),Ht=x.useState(!1),jt=(0,se.Z)(Ht,2),yt=jt[0],Yt=jt[1],Lt=x.useRef(!1),Kt=x.useState(null),sn=(0,se.Z)(Kt,2),wn=sn[0],Vt=sn[1],Rn=(0,x.useRef)(null),Gn=(0,x.useRef)(null),Zn=function(){var qt;return(qt=Gn.current)===null||qt===void 0?void 0:qt.textArea},tr=function(){Zn().focus()};(0,x.useImperativeHandle)(Ye,function(){var Ft;return{resizableTextArea:Gn.current,focus:tr,blur:function(){Zn().blur()},nativeElement:((Ft=Rn.current)===null||Ft===void 0?void 0:Ft.nativeElement)||Zn()}}),(0,x.useEffect)(function(){Yt(function(Ft){return!Se&&Ft})},[Se]);var hr=x.useState(null),ur=(0,se.Z)(hr,2),zn=ur[0],Bn=ur[1];x.useEffect(function(){if(zn){var Ft;(Ft=Zn()).setSelectionRange.apply(Ft,(0,ue.Z)(zn))}},[zn]);var ir=(0,E.Z)(_t,gt),Kn=(ut=ir.max)!==null&&ut!==void 0?ut:pt,Nn=Number(Kn)>0,yn=ir.strategy(Pt),Hn=!!Kn&&yn>Kn,dr=function(qt,En){var Yn=En;!Lt.current&&ir.exceedFormatter&&ir.max&&ir.strategy(En)>ir.max&&(Yn=ir.exceedFormatter(En,{max:ir.max}),En!==Yn&&Bn([Zn().selectionStart||0,Zn().selectionEnd||0])),vt(Yn),(0,b.rJ)(qt.currentTarget,qt,nt,Yn)},Mn=function(qt){Lt.current=!0,ct==null||ct(qt)},Cn=function(qt){Lt.current=!1,dr(qt,qt.currentTarget.value),Ot==null||Ot(qt)},$n=function(qt){dr(qt,qt.target.value)},Jt=function(qt){qt.key==="Enter"&&Le&&Le(qt),Re==null||Re(qt)},Ie=function(qt){Yt(!0),Ve==null||Ve(qt)},Ze=function(qt){Yt(!1),$e==null||$e(qt)},qe=function(qt){vt(""),tr(),(0,b.rJ)(Zn(),qt,nt)},st=dt,mt;ir.show&&(ir.showFormatter?mt=ir.showFormatter({value:Pt,count:yn,maxLength:Kn}):mt="".concat(yn).concat(Nn?" / ".concat(Kn):""),st=x.createElement(x.Fragment,null,st,x.createElement("span",{className:ee()("".concat(xt,"-data-count"),Ke==null?void 0:Ke.count),style:Ne==null?void 0:Ne.count},mt)));var Bt=function(qt){var En;De==null||De(qt),(En=Zn())!==null&&En!==void 0&&En.style.height&&Vt(!0)},kt=!Me&&!gt&&!et;return x.createElement(ne.BaseInput,{ref:Rn,value:Pt,allowClear:et,handleReset:qe,suffix:st,prefixCls:xt,classNames:(0,Ce.Z)((0,Ce.Z)({},Ke),{},{affixWrapper:ee()(Ke==null?void 0:Ke.affixWrapper,(0,ie.Z)((0,ie.Z)({},"".concat(xt,"-show-count"),gt),"".concat(xt,"-textarea-allow-clear"),et))}),disabled:Se,focused:yt,className:ee()(We,Hn&&"".concat(xt,"-out-of-range")),style:(0,Ce.Z)((0,Ce.Z)({},Ae),wn&&!kt?{height:"auto"}:{}),dataAttrs:{affixWrapper:{"data-count":typeof mt=="string"?mt:void 0}},hidden:Be,readOnly:Ue,onClear:we},x.createElement(Pe,(0,ce.Z)({},tt,{autoSize:Me,maxLength:pt,onKeyDown:Jt,onChange:$n,onFocus:Ie,onBlur:Ze,onCompositionStart:Mn,onCompositionEnd:Cn,className:ee()(Ke==null?void 0:Ke.textarea),style:(0,Ce.Z)((0,Ce.Z)({},Ne==null?void 0:Ne.textarea),{},{resize:Ae==null?void 0:Ae.resize}),disabled:Se,prefixCls:xt,onResize:Bt,ref:Gn,readOnly:Ue})))}),ot=Xe,He=ot},639:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ge}});var ce=be(32855),ie=be(74430),Ce=be(27247),ue=be(11913),se=be(43079),te=be(59301),le=be(92310),ee=be.n(le),ne=be(26112),E=be(30699),b=function(he){for(var pe=he.prefixCls,ke=he.level,Te=he.isStart,Ee=he.isEnd,Oe="".concat(pe,"-indent-unit"),je=[],Pe=0;Pe<ke;Pe+=1)je.push(te.createElement("span",{key:Pe,className:ee()(Oe,(0,ie.Z)((0,ie.Z)({},"".concat(Oe,"-start"),Te[Pe]),"".concat(Oe,"-end"),Ee[Pe]))}));return te.createElement("span",{"aria-hidden":"true",className:"".concat(pe,"-indent")},je)},z=te.memo(b),x=be(65065),re=be(34061),ae=["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","data","onMouseMove","selectable"],oe="open",ve="close",ye="---",me=function(he){var pe,ke,Te,Ee=he.eventKey,Oe=he.className,je=he.style,Pe=he.dragOver,Qe=he.dragOverGapTop,Xe=he.dragOverGapBottom,ot=he.isLeaf,He=he.isStart,rt=he.isEnd,Ye=he.expanded,ut=he.selected,Ge=he.checked,ze=he.halfChecked,Ve=he.loading,$e=he.domRef,nt=he.active,et=he.data,pt=he.onMouseMove,ct=he.selectable,Ot=(0,se.Z)(he,ae),dt=te.useContext(E.k),Rt=te.useContext(E.y),xt=te.useRef(null),gt=te.useState(!1),_t=(0,ue.Z)(gt,2),We=_t[0],Ae=_t[1],Se=!!(dt.disabled||he.disabled||(pe=Rt.nodeDisabled)!==null&&pe!==void 0&&pe.call(Rt,et)),Be=te.useMemo(function(){return!dt.checkable||he.checkable===!1?!1:dt.checkable},[dt.checkable,he.checkable]),Ke=function(yn){Se||dt.onNodeSelect(yn,(0,re.F)(he))},Ne=function(yn){Se||!Be||he.disableCheckbox||dt.onNodeCheck(yn,(0,re.F)(he),!Ge)},De=te.useMemo(function(){return typeof ct=="boolean"?ct:dt.selectable},[ct,dt.selectable]),we=function(yn){dt.onNodeClick(yn,(0,re.F)(he)),De?Ke(yn):Ne(yn)},Le=function(yn){dt.onNodeDoubleClick(yn,(0,re.F)(he))},Ue=function(yn){dt.onNodeMouseEnter(yn,(0,re.F)(he))},Me=function(yn){dt.onNodeMouseLeave(yn,(0,re.F)(he))},Re=function(yn){dt.onNodeContextMenu(yn,(0,re.F)(he))},tt=te.useMemo(function(){return!!(dt.draggable&&(!dt.draggable.nodeDraggable||dt.draggable.nodeDraggable(et)))},[dt.draggable,et]),lt=function(yn){yn.stopPropagation(),Ae(!0),dt.onNodeDragStart(yn,he);try{yn.dataTransfer.setData("text/plain","")}catch(Hn){}},Nt=function(yn){yn.preventDefault(),yn.stopPropagation(),dt.onNodeDragEnter(yn,he)},Ct=function(yn){yn.preventDefault(),yn.stopPropagation(),dt.onNodeDragOver(yn,he)},vt=function(yn){yn.stopPropagation(),dt.onNodeDragLeave(yn,he)},Pt=function(yn){yn.stopPropagation(),Ae(!1),dt.onNodeDragEnd(yn,he)},Ht=function(yn){yn.preventDefault(),yn.stopPropagation(),Ae(!1),dt.onNodeDrop(yn,he)},jt=function(yn){Ve||dt.onNodeExpand(yn,(0,re.F)(he))},yt=te.useMemo(function(){var Nn=(0,x.Z)(dt.keyEntities,Ee)||{},yn=Nn.children;return!!(yn||[]).length},[dt.keyEntities,Ee]),Yt=te.useMemo(function(){return ot===!1?!1:ot||!dt.loadData&&!yt||dt.loadData&&he.loaded&&!yt},[ot,dt.loadData,yt,he.loaded]);te.useEffect(function(){Ve||typeof dt.loadData=="function"&&Ye&&!Yt&&!he.loaded&&dt.onNodeLoad((0,re.F)(he))},[Ve,dt.loadData,dt.onNodeLoad,Ye,Yt,he]);var Lt=te.useMemo(function(){var Nn;return(Nn=dt.draggable)!==null&&Nn!==void 0&&Nn.icon?te.createElement("span",{className:"".concat(dt.prefixCls,"-draggable-icon")},dt.draggable.icon):null},[dt.draggable]),Kt=function(yn){var Hn=he.switcherIcon||dt.switcherIcon;return typeof Hn=="function"?Hn((0,Ce.Z)((0,Ce.Z)({},he),{},{isLeaf:yn})):Hn},sn=function(){if(Yt){var yn=Kt(!0);return yn!==!1?te.createElement("span",{className:ee()("".concat(dt.prefixCls,"-switcher"),"".concat(dt.prefixCls,"-switcher-noop"))},yn):null}var Hn=Kt(!1);return Hn!==!1?te.createElement("span",{onClick:jt,className:ee()("".concat(dt.prefixCls,"-switcher"),"".concat(dt.prefixCls,"-switcher_").concat(Ye?oe:ve))},Hn):null},wn=te.useMemo(function(){if(!Be)return null;var Nn=typeof Be!="boolean"?Be:null;return te.createElement("span",{className:ee()("".concat(dt.prefixCls,"-checkbox"),(0,ie.Z)((0,ie.Z)((0,ie.Z)({},"".concat(dt.prefixCls,"-checkbox-checked"),Ge),"".concat(dt.prefixCls,"-checkbox-indeterminate"),!Ge&&ze),"".concat(dt.prefixCls,"-checkbox-disabled"),Se||he.disableCheckbox)),onClick:Ne,role:"checkbox","aria-checked":ze?"mixed":Ge,"aria-disabled":Se||he.disableCheckbox,"aria-label":"Select ".concat(typeof he.title=="string"?he.title:"tree node")},Nn)},[Be,Ge,ze,Se,he.disableCheckbox,he.title]),Vt=te.useMemo(function(){return Yt?null:Ye?oe:ve},[Yt,Ye]),Rn=te.useMemo(function(){return te.createElement("span",{className:ee()("".concat(dt.prefixCls,"-iconEle"),"".concat(dt.prefixCls,"-icon__").concat(Vt||"docu"),(0,ie.Z)({},"".concat(dt.prefixCls,"-icon_loading"),Ve))})},[dt.prefixCls,Vt,Ve]),Gn=te.useMemo(function(){var Nn=!!dt.draggable,yn=!he.disabled&&Nn&&dt.dragOverNodeKey===Ee;return yn?dt.dropIndicatorRender({dropPosition:dt.dropPosition,dropLevelOffset:dt.dropLevelOffset,indent:dt.indent,prefixCls:dt.prefixCls,direction:dt.direction}):null},[dt.dropPosition,dt.dropLevelOffset,dt.indent,dt.prefixCls,dt.direction,dt.draggable,dt.dragOverNodeKey,dt.dropIndicatorRender]),Zn=te.useMemo(function(){var Nn=he.title,yn=Nn===void 0?ye:Nn,Hn="".concat(dt.prefixCls,"-node-content-wrapper"),dr;if(dt.showIcon){var Mn=he.icon||dt.icon;dr=Mn?te.createElement("span",{className:ee()("".concat(dt.prefixCls,"-iconEle"),"".concat(dt.prefixCls,"-icon__customize"))},typeof Mn=="function"?Mn(he):Mn):Rn}else dt.loadData&&Ve&&(dr=Rn);var Cn;return typeof yn=="function"?Cn=yn(et):dt.titleRender?Cn=dt.titleRender(et):Cn=yn,te.createElement("span",{ref:xt,title:typeof yn=="string"?yn:"",className:ee()(Hn,"".concat(Hn,"-").concat(Vt||"normal"),(0,ie.Z)({},"".concat(dt.prefixCls,"-node-selected"),!Se&&(ut||We))),onMouseEnter:Ue,onMouseLeave:Me,onContextMenu:Re,onClick:we,onDoubleClick:Le},dr,te.createElement("span",{className:"".concat(dt.prefixCls,"-title")},Cn),Gn)},[dt.prefixCls,dt.showIcon,he,dt.icon,Rn,dt.titleRender,et,Vt,Ue,Me,Re,we,Le]),tr=(0,ne.Z)(Ot,{aria:!0,data:!0}),hr=(0,x.Z)(dt.keyEntities,Ee)||{},ur=hr.level,zn=rt[rt.length-1],Bn=!Se&&tt,ir=dt.draggingNodeKey===Ee,Kn=ct!==void 0?{"aria-selected":!!ct}:void 0;return te.createElement("div",(0,ce.Z)({ref:$e,role:"treeitem","aria-expanded":ot?void 0:Ye,className:ee()(Oe,"".concat(dt.prefixCls,"-treenode"),(Te={},(0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)(Te,"".concat(dt.prefixCls,"-treenode-disabled"),Se),"".concat(dt.prefixCls,"-treenode-switcher-").concat(Ye?"open":"close"),!ot),"".concat(dt.prefixCls,"-treenode-checkbox-checked"),Ge),"".concat(dt.prefixCls,"-treenode-checkbox-indeterminate"),ze),"".concat(dt.prefixCls,"-treenode-selected"),ut),"".concat(dt.prefixCls,"-treenode-loading"),Ve),"".concat(dt.prefixCls,"-treenode-active"),nt),"".concat(dt.prefixCls,"-treenode-leaf-last"),zn),"".concat(dt.prefixCls,"-treenode-draggable"),tt),"dragging",ir),(0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)((0,ie.Z)(Te,"drop-target",dt.dropTargetKey===Ee),"drop-container",dt.dropContainerKey===Ee),"drag-over",!Se&&Pe),"drag-over-gap-top",!Se&&Qe),"drag-over-gap-bottom",!Se&&Xe),"filter-node",(ke=dt.filterTreeNode)===null||ke===void 0?void 0:ke.call(dt,(0,re.F)(he))),"".concat(dt.prefixCls,"-treenode-leaf"),Yt))),style:je,draggable:Bn,onDragStart:Bn?lt:void 0,onDragEnter:tt?Nt:void 0,onDragOver:tt?Ct:void 0,onDragLeave:tt?vt:void 0,onDrop:tt?Ht:void 0,onDragEnd:tt?Pt:void 0,onMouseMove:pt},Kn,tr),te.createElement(z,{prefixCls:dt.prefixCls,level:ur,isStart:He,isEnd:rt}),Lt,sn(),wn,Zn)};me.isTreeNode=1;var ge=me},30699:function(Xt,Mt,be){"use strict";be.d(Mt,{k:function(){return ie},y:function(){return Ce}});var ce=be(59301),ie=ce.createContext(null),Ce=ce.createContext({})},89149:function(Xt,Mt,be){"use strict";be.d(Mt,{OF:function(){return Ee.Z},y6:function(){return ve.y},ZP:function(){return Se}});var ce=be(32855),ie=be(34666),Ce=be(27247),ue=be(3300),se=be(33377),te=be(93912),le=be(83383),ee=be(18881),ne=be(85461),E=be(74430),b=be(92310),z=be.n(b),x=be(10228),re=be(26112),ae=be(48736),oe=be(59301),ve=be(30699),ye=function(Ke){var Ne=Ke.dropPosition,De=Ke.dropLevelOffset,we=Ke.indent,Le={pointerEvents:"none",position:"absolute",right:0,backgroundColor:"red",height:2};switch(Ne){case-1:Le.top=0,Le.left=-De*we;break;case 1:Le.bottom=0,Le.left=-De*we;break;case 0:Le.bottom=0,Le.left=we;break}return oe.createElement("div",{style:Le})},me=ye;function ge(Be){if(Be==null)throw new TypeError("Cannot destructure "+Be)}var _e=be(11913),he=be(43079),pe=be(34280),ke=be(6790),Te=be(77900),Ee=be(639);function Oe(Be,Ke){var Ne=oe.useState(!1),De=(0,_e.Z)(Ne,2),we=De[0],Le=De[1];(0,pe.Z)(function(){if(we)return Be(),function(){Ke()}},[we]),(0,pe.Z)(function(){return Le(!0),function(){Le(!1)}},[])}var je=Oe,Pe=be(34061),Qe=["className","style","motion","motionNodes","motionType","onMotionStart","onMotionEnd","active","treeNodeRequiredProps"],Xe=oe.forwardRef(function(Be,Ke){var Ne=Be.className,De=Be.style,we=Be.motion,Le=Be.motionNodes,Ue=Be.motionType,Me=Be.onMotionStart,Re=Be.onMotionEnd,tt=Be.active,lt=Be.treeNodeRequiredProps,Nt=(0,he.Z)(Be,Qe),Ct=oe.useState(!0),vt=(0,_e.Z)(Ct,2),Pt=vt[0],Ht=vt[1],jt=oe.useContext(ve.k),yt=jt.prefixCls,Yt=Le&&Ue!=="hide";(0,pe.Z)(function(){Le&&Yt!==Pt&&Ht(Yt)},[Le]);var Lt=function(){Le&&Me()},Kt=oe.useRef(!1),sn=function(){Le&&!Kt.current&&(Kt.current=!0,Re())};je(Lt,sn);var wn=function(Rn){Yt===Rn&&sn()};return Le?oe.createElement(Te.default,(0,ce.Z)({ref:Ke,visible:Pt},we,{motionAppear:Ue==="show",onVisibleChanged:wn}),function(Vt,Rn){var Gn=Vt.className,Zn=Vt.style;return oe.createElement("div",{ref:Rn,className:z()("".concat(yt,"-treenode-motion"),Gn),style:Zn},Le.map(function(tr){var hr=Object.assign({},(ge(tr.data),tr.data)),ur=tr.title,zn=tr.key,Bn=tr.isStart,ir=tr.isEnd;delete hr.children;var Kn=(0,Pe.H8)(zn,lt);return oe.createElement(Ee.Z,(0,ce.Z)({},hr,Kn,{title:ur,active:tt,data:tr.data,key:zn,isStart:Bn,isEnd:ir}))}))}):oe.createElement(Ee.Z,(0,ce.Z)({domRef:Ke,className:Ne,style:De},Nt,{active:tt}))}),ot=Xe;function He(){var Be=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],Ke=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],Ne=Be.length,De=Ke.length;if(Math.abs(Ne-De)!==1)return{add:!1,key:null};function we(Le,Ue){var Me=new Map;Le.forEach(function(tt){Me.set(tt,!0)});var Re=Ue.filter(function(tt){return!Me.has(tt)});return Re.length===1?Re[0]:null}return Ne<De?{add:!0,key:we(Be,Ke)}:{add:!1,key:we(Ke,Be)}}function rt(Be,Ke,Ne){var De=Be.findIndex(function(Me){return Me.key===Ne}),we=Be[De+1],Le=Ke.findIndex(function(Me){return Me.key===Ne});if(we){var Ue=Ke.findIndex(function(Me){return Me.key===we.key});return Ke.slice(Le+1,Ue)}return Ke.slice(Le+1)}var Ye=["prefixCls","data","selectable","checkable","expandedKeys","selectedKeys","checkedKeys","loadedKeys","loadingKeys","halfCheckedKeys","keyEntities","disabled","dragging","dragOverNodeKey","dropPosition","motion","height","itemHeight","virtual","scrollWidth","focusable","activeItem","focused","tabIndex","onKeyDown","onFocus","onBlur","onActiveChange","onListChangeStart","onListChangeEnd"],ut={width:0,height:0,display:"flex",overflow:"hidden",opacity:0,border:0,padding:0,margin:0},Ge=function(){},ze="RC_TREE_MOTION_".concat(Math.random()),Ve={key:ze},$e={key:ze,level:0,index:0,pos:"0",node:Ve,nodes:[Ve]},nt={parent:null,children:[],pos:$e.pos,data:Ve,title:null,key:ze,isStart:[],isEnd:[]};function et(Be,Ke,Ne,De){return Ke===!1||!Ne?Be:Be.slice(0,Math.ceil(Ne/De)+1)}function pt(Be){var Ke=Be.key,Ne=Be.pos;return(0,Pe.km)(Ke,Ne)}function ct(Be){for(var Ke=String(Be.data.key),Ne=Be;Ne.parent;)Ne=Ne.parent,Ke="".concat(Ne.data.key," > ").concat(Ke);return Ke}var Ot=oe.forwardRef(function(Be,Ke){var Ne=Be.prefixCls,De=Be.data,we=Be.selectable,Le=Be.checkable,Ue=Be.expandedKeys,Me=Be.selectedKeys,Re=Be.checkedKeys,tt=Be.loadedKeys,lt=Be.loadingKeys,Nt=Be.halfCheckedKeys,Ct=Be.keyEntities,vt=Be.disabled,Pt=Be.dragging,Ht=Be.dragOverNodeKey,jt=Be.dropPosition,yt=Be.motion,Yt=Be.height,Lt=Be.itemHeight,Kt=Be.virtual,sn=Be.scrollWidth,wn=Be.focusable,Vt=Be.activeItem,Rn=Be.focused,Gn=Be.tabIndex,Zn=Be.onKeyDown,tr=Be.onFocus,hr=Be.onBlur,ur=Be.onActiveChange,zn=Be.onListChangeStart,Bn=Be.onListChangeEnd,ir=(0,he.Z)(Be,Ye),Kn=oe.useRef(null),Nn=oe.useRef(null);oe.useImperativeHandle(Ke,function(){return{scrollTo:function(nn){Kn.current.scrollTo(nn)},getIndentWidth:function(){return Nn.current.offsetWidth}}});var yn=oe.useState(Ue),Hn=(0,_e.Z)(yn,2),dr=Hn[0],Mn=Hn[1],Cn=oe.useState(De),$n=(0,_e.Z)(Cn,2),Jt=$n[0],Ie=$n[1],Ze=oe.useState(De),qe=(0,_e.Z)(Ze,2),st=qe[0],mt=qe[1],Bt=oe.useState([]),kt=(0,_e.Z)(Bt,2),Ft=kt[0],qt=kt[1],En=oe.useState(null),Yn=(0,_e.Z)(En,2),At=Yn[0],St=Yn[1],an=oe.useRef(De);an.current=De;function Wt(){var tn=an.current;Ie(tn),mt(tn),qt([]),St(null),Bn()}(0,pe.Z)(function(){Mn(Ue);var tn=He(dr,Ue);if(tn.key!==null)if(tn.add){var nn=Jt.findIndex(function(bn){var Fn=bn.key;return Fn===tn.key}),gn=et(rt(Jt,De,tn.key),Kt,Yt,Lt),Sn=Jt.slice();Sn.splice(nn+1,0,nt),mt(Sn),qt(gn),St("show")}else{var Tn=De.findIndex(function(bn){var Fn=bn.key;return Fn===tn.key}),Tt=et(rt(De,Jt,tn.key),Kt,Yt,Lt),jn=De.slice();jn.splice(Tn+1,0,nt),mt(jn),qt(Tt),St("hide")}else Jt!==De&&(Ie(De),mt(De))},[Ue,De]),oe.useEffect(function(){Pt||Wt()},[Pt]);var Et=yt?st:De,zt={expandedKeys:Ue,selectedKeys:Me,loadedKeys:tt,loadingKeys:lt,checkedKeys:Re,halfCheckedKeys:Nt,dragOverNodeKey:Ht,dropPosition:jt,keyEntities:Ct};return oe.createElement(oe.Fragment,null,Rn&&Vt&&oe.createElement("span",{style:ut,"aria-live":"assertive"},ct(Vt)),oe.createElement("div",null,oe.createElement("input",{style:ut,disabled:wn===!1||vt,tabIndex:wn!==!1?Gn:null,onKeyDown:Zn,onFocus:tr,onBlur:hr,value:"",onChange:Ge,"aria-label":"for screen reader"})),oe.createElement("div",{className:"".concat(Ne,"-treenode"),"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},oe.createElement("div",{className:"".concat(Ne,"-indent")},oe.createElement("div",{ref:Nn,className:"".concat(Ne,"-indent-unit")}))),oe.createElement(ke.Z,(0,ce.Z)({},ir,{data:Et,itemKey:pt,height:Yt,fullHeight:!1,virtual:Kt,itemHeight:Lt,scrollWidth:sn,prefixCls:"".concat(Ne,"-list"),ref:Kn,role:"tree",onVisibleChange:function(nn){nn.every(function(gn){return pt(gn)!==ze})&&Wt()}}),function(tn){var nn=tn.pos,gn=Object.assign({},(ge(tn.data),tn.data)),Sn=tn.title,Tn=tn.key,Tt=tn.isStart,jn=tn.isEnd,bn=(0,Pe.km)(Tn,nn);delete gn.key,delete gn.children;var Fn=(0,Pe.H8)(bn,zt);return oe.createElement(ot,(0,ce.Z)({},gn,Fn,{title:Sn,active:!!Vt&&Tn===Vt.key,pos:nn,data:tn.data,isStart:Tt,isEnd:jn,motion:yt,motionNodes:Tn===ze?Ft:null,motionType:At,onMotionStart:zn,onMotionEnd:Wt,treeNodeRequiredProps:zt,onMouseMove:function(){ur(null)}}))}))}),dt=Ot,Rt=be(82661),xt=be(34643),gt=be(65065),_t=10,We=function(Be){(0,ee.Z)(Ne,Be);var Ke=(0,ne.Z)(Ne);function Ne(){var De;(0,se.Z)(this,Ne);for(var we=arguments.length,Le=new Array(we),Ue=0;Ue<we;Ue++)Le[Ue]=arguments[Ue];return De=Ke.call.apply(Ke,[this].concat(Le)),(0,E.Z)((0,le.Z)(De),"destroyed",!1),(0,E.Z)((0,le.Z)(De),"delayedDragEnterLogic",void 0),(0,E.Z)((0,le.Z)(De),"loadingRetryTimes",{}),(0,E.Z)((0,le.Z)(De),"state",{keyEntities:{},indent:null,selectedKeys:[],checkedKeys:[],halfCheckedKeys:[],loadedKeys:[],loadingKeys:[],expandedKeys:[],draggingNodeKey:null,dragChildrenKeys:[],dropTargetKey:null,dropPosition:null,dropContainerKey:null,dropLevelOffset:null,dropTargetPos:null,dropAllowed:!0,dragOverNodeKey:null,treeData:[],flattenNodes:[],focused:!1,activeKey:null,listChanging:!1,prevProps:null,fieldNames:(0,Pe.w$)()}),(0,E.Z)((0,le.Z)(De),"dragStartMousePosition",null),(0,E.Z)((0,le.Z)(De),"dragNodeProps",null),(0,E.Z)((0,le.Z)(De),"currentMouseOverDroppableNodeKey",null),(0,E.Z)((0,le.Z)(De),"listRef",oe.createRef()),(0,E.Z)((0,le.Z)(De),"onNodeDragStart",function(Me,Re){var tt=De.state,lt=tt.expandedKeys,Nt=tt.keyEntities,Ct=De.props.onDragStart,vt=Re.eventKey;De.dragNodeProps=Re,De.dragStartMousePosition={x:Me.clientX,y:Me.clientY};var Pt=(0,Rt._5)(lt,vt);De.setState({draggingNodeKey:vt,dragChildrenKeys:(0,Rt.wA)(vt,Nt),indent:De.listRef.current.getIndentWidth()}),De.setExpandedKeys(Pt),window.addEventListener("dragend",De.onWindowDragEnd),Ct==null||Ct({event:Me,node:(0,Pe.F)(Re)})}),(0,E.Z)((0,le.Z)(De),"onNodeDragEnter",function(Me,Re){var tt=De.state,lt=tt.expandedKeys,Nt=tt.keyEntities,Ct=tt.dragChildrenKeys,vt=tt.flattenNodes,Pt=tt.indent,Ht=De.props,jt=Ht.onDragEnter,yt=Ht.onExpand,Yt=Ht.allowDrop,Lt=Ht.direction,Kt=Re.pos,sn=Re.eventKey;if(De.currentMouseOverDroppableNodeKey!==sn&&(De.currentMouseOverDroppableNodeKey=sn),!De.dragNodeProps){De.resetDragState();return}var wn=(0,Rt.OM)(Me,De.dragNodeProps,Re,Pt,De.dragStartMousePosition,Yt,vt,Nt,lt,Lt),Vt=wn.dropPosition,Rn=wn.dropLevelOffset,Gn=wn.dropTargetKey,Zn=wn.dropContainerKey,tr=wn.dropTargetPos,hr=wn.dropAllowed,ur=wn.dragOverNodeKey;if(Ct.includes(Gn)||!hr){De.resetDragState();return}if(De.delayedDragEnterLogic||(De.delayedDragEnterLogic={}),Object.keys(De.delayedDragEnterLogic).forEach(function(zn){clearTimeout(De.delayedDragEnterLogic[zn])}),De.dragNodeProps.eventKey!==Re.eventKey&&(Me.persist(),De.delayedDragEnterLogic[Kt]=window.setTimeout(function(){if(De.state.draggingNodeKey!==null){var zn=(0,ue.Z)(lt),Bn=(0,gt.Z)(Nt,Re.eventKey);Bn&&(Bn.children||[]).length&&(zn=(0,Rt.L0)(lt,Re.eventKey)),De.props.hasOwnProperty("expandedKeys")||De.setExpandedKeys(zn),yt==null||yt(zn,{node:(0,Pe.F)(Re),expanded:!0,nativeEvent:Me.nativeEvent})}},800)),De.dragNodeProps.eventKey===Gn&&Rn===0){De.resetDragState();return}De.setState({dragOverNodeKey:ur,dropPosition:Vt,dropLevelOffset:Rn,dropTargetKey:Gn,dropContainerKey:Zn,dropTargetPos:tr,dropAllowed:hr}),jt==null||jt({event:Me,node:(0,Pe.F)(Re),expandedKeys:lt})}),(0,E.Z)((0,le.Z)(De),"onNodeDragOver",function(Me,Re){var tt=De.state,lt=tt.dragChildrenKeys,Nt=tt.flattenNodes,Ct=tt.keyEntities,vt=tt.expandedKeys,Pt=tt.indent,Ht=De.props,jt=Ht.onDragOver,yt=Ht.allowDrop,Yt=Ht.direction;if(De.dragNodeProps){var Lt=(0,Rt.OM)(Me,De.dragNodeProps,Re,Pt,De.dragStartMousePosition,yt,Nt,Ct,vt,Yt),Kt=Lt.dropPosition,sn=Lt.dropLevelOffset,wn=Lt.dropTargetKey,Vt=Lt.dropContainerKey,Rn=Lt.dropTargetPos,Gn=Lt.dropAllowed,Zn=Lt.dragOverNodeKey;lt.includes(wn)||!Gn||(De.dragNodeProps.eventKey===wn&&sn===0?De.state.dropPosition===null&&De.state.dropLevelOffset===null&&De.state.dropTargetKey===null&&De.state.dropContainerKey===null&&De.state.dropTargetPos===null&&De.state.dropAllowed===!1&&De.state.dragOverNodeKey===null||De.resetDragState():Kt===De.state.dropPosition&&sn===De.state.dropLevelOffset&&wn===De.state.dropTargetKey&&Vt===De.state.dropContainerKey&&Rn===De.state.dropTargetPos&&Gn===De.state.dropAllowed&&Zn===De.state.dragOverNodeKey||De.setState({dropPosition:Kt,dropLevelOffset:sn,dropTargetKey:wn,dropContainerKey:Vt,dropTargetPos:Rn,dropAllowed:Gn,dragOverNodeKey:Zn}),jt==null||jt({event:Me,node:(0,Pe.F)(Re)}))}}),(0,E.Z)((0,le.Z)(De),"onNodeDragLeave",function(Me,Re){De.currentMouseOverDroppableNodeKey===Re.eventKey&&!Me.currentTarget.contains(Me.relatedTarget)&&(De.resetDragState(),De.currentMouseOverDroppableNodeKey=null);var tt=De.props.onDragLeave;tt==null||tt({event:Me,node:(0,Pe.F)(Re)})}),(0,E.Z)((0,le.Z)(De),"onWindowDragEnd",function(Me){De.onNodeDragEnd(Me,null,!0),window.removeEventListener("dragend",De.onWindowDragEnd)}),(0,E.Z)((0,le.Z)(De),"onNodeDragEnd",function(Me,Re){var tt=De.props.onDragEnd;De.setState({dragOverNodeKey:null}),De.cleanDragState(),tt==null||tt({event:Me,node:(0,Pe.F)(Re)}),De.dragNodeProps=null,window.removeEventListener("dragend",De.onWindowDragEnd)}),(0,E.Z)((0,le.Z)(De),"onNodeDrop",function(Me,Re){var tt,lt=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,Nt=De.state,Ct=Nt.dragChildrenKeys,vt=Nt.dropPosition,Pt=Nt.dropTargetKey,Ht=Nt.dropTargetPos,jt=Nt.dropAllowed;if(jt){var yt=De.props.onDrop;if(De.setState({dragOverNodeKey:null}),De.cleanDragState(),Pt!==null){var Yt=(0,Ce.Z)((0,Ce.Z)({},(0,Pe.H8)(Pt,De.getTreeNodeRequiredProps())),{},{active:((tt=De.getActiveItem())===null||tt===void 0?void 0:tt.key)===Pt,data:(0,gt.Z)(De.state.keyEntities,Pt).node}),Lt=Ct.includes(Pt);(0,ae.ZP)(!Lt,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");var Kt=(0,Rt.yx)(Ht),sn={event:Me,node:(0,Pe.F)(Yt),dragNode:De.dragNodeProps?(0,Pe.F)(De.dragNodeProps):null,dragNodesKeys:[De.dragNodeProps.eventKey].concat(Ct),dropToGap:vt!==0,dropPosition:vt+Number(Kt[Kt.length-1])};lt||yt==null||yt(sn),De.dragNodeProps=null}}}),(0,E.Z)((0,le.Z)(De),"cleanDragState",function(){var Me=De.state.draggingNodeKey;Me!==null&&De.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),De.dragStartMousePosition=null,De.currentMouseOverDroppableNodeKey=null}),(0,E.Z)((0,le.Z)(De),"triggerExpandActionExpand",function(Me,Re){var tt=De.state,lt=tt.expandedKeys,Nt=tt.flattenNodes,Ct=Re.expanded,vt=Re.key,Pt=Re.isLeaf;if(!(Pt||Me.shiftKey||Me.metaKey||Me.ctrlKey)){var Ht=Nt.filter(function(yt){return yt.key===vt})[0],jt=(0,Pe.F)((0,Ce.Z)((0,Ce.Z)({},(0,Pe.H8)(vt,De.getTreeNodeRequiredProps())),{},{data:Ht.data}));De.setExpandedKeys(Ct?(0,Rt._5)(lt,vt):(0,Rt.L0)(lt,vt)),De.onNodeExpand(Me,jt)}}),(0,E.Z)((0,le.Z)(De),"onNodeClick",function(Me,Re){var tt=De.props,lt=tt.onClick,Nt=tt.expandAction;Nt==="click"&&De.triggerExpandActionExpand(Me,Re),lt==null||lt(Me,Re)}),(0,E.Z)((0,le.Z)(De),"onNodeDoubleClick",function(Me,Re){var tt=De.props,lt=tt.onDoubleClick,Nt=tt.expandAction;Nt==="doubleClick"&&De.triggerExpandActionExpand(Me,Re),lt==null||lt(Me,Re)}),(0,E.Z)((0,le.Z)(De),"onNodeSelect",function(Me,Re){var tt=De.state.selectedKeys,lt=De.state,Nt=lt.keyEntities,Ct=lt.fieldNames,vt=De.props,Pt=vt.onSelect,Ht=vt.multiple,jt=Re.selected,yt=Re[Ct.key],Yt=!jt;Yt?Ht?tt=(0,Rt.L0)(tt,yt):tt=[yt]:tt=(0,Rt._5)(tt,yt);var Lt=tt.map(function(Kt){var sn=(0,gt.Z)(Nt,Kt);return sn?sn.node:null}).filter(Boolean);De.setUncontrolledState({selectedKeys:tt}),Pt==null||Pt(tt,{event:"select",selected:Yt,node:Re,selectedNodes:Lt,nativeEvent:Me.nativeEvent})}),(0,E.Z)((0,le.Z)(De),"onNodeCheck",function(Me,Re,tt){var lt=De.state,Nt=lt.keyEntities,Ct=lt.checkedKeys,vt=lt.halfCheckedKeys,Pt=De.props,Ht=Pt.checkStrictly,jt=Pt.onCheck,yt=Re.key,Yt,Lt={event:"check",node:Re,checked:tt,nativeEvent:Me.nativeEvent};if(Ht){var Kt=tt?(0,Rt.L0)(Ct,yt):(0,Rt._5)(Ct,yt),sn=(0,Rt._5)(vt,yt);Yt={checked:Kt,halfChecked:sn},Lt.checkedNodes=Kt.map(function(tr){return(0,gt.Z)(Nt,tr)}).filter(Boolean).map(function(tr){return tr.node}),De.setUncontrolledState({checkedKeys:Kt})}else{var wn=(0,xt.S)([].concat((0,ue.Z)(Ct),[yt]),!0,Nt),Vt=wn.checkedKeys,Rn=wn.halfCheckedKeys;if(!tt){var Gn=new Set(Vt);Gn.delete(yt);var Zn=(0,xt.S)(Array.from(Gn),{checked:!1,halfCheckedKeys:Rn},Nt);Vt=Zn.checkedKeys,Rn=Zn.halfCheckedKeys}Yt=Vt,Lt.checkedNodes=[],Lt.checkedNodesPositions=[],Lt.halfCheckedKeys=Rn,Vt.forEach(function(tr){var hr=(0,gt.Z)(Nt,tr);if(hr){var ur=hr.node,zn=hr.pos;Lt.checkedNodes.push(ur),Lt.checkedNodesPositions.push({node:ur,pos:zn})}}),De.setUncontrolledState({checkedKeys:Vt},!1,{halfCheckedKeys:Rn})}jt==null||jt(Yt,Lt)}),(0,E.Z)((0,le.Z)(De),"onNodeLoad",function(Me){var Re,tt=Me.key,lt=De.state.keyEntities,Nt=(0,gt.Z)(lt,tt);if(!(Nt!=null&&(Re=Nt.children)!==null&&Re!==void 0&&Re.length)){var Ct=new Promise(function(vt,Pt){De.setState(function(Ht){var jt=Ht.loadedKeys,yt=jt===void 0?[]:jt,Yt=Ht.loadingKeys,Lt=Yt===void 0?[]:Yt,Kt=De.props,sn=Kt.loadData,wn=Kt.onLoad;if(!sn||yt.includes(tt)||Lt.includes(tt))return null;var Vt=sn(Me);return Vt.then(function(){var Rn=De.state.loadedKeys,Gn=(0,Rt.L0)(Rn,tt);wn==null||wn(Gn,{event:"load",node:Me}),De.setUncontrolledState({loadedKeys:Gn}),De.setState(function(Zn){return{loadingKeys:(0,Rt._5)(Zn.loadingKeys,tt)}}),vt()}).catch(function(Rn){if(De.setState(function(Zn){return{loadingKeys:(0,Rt._5)(Zn.loadingKeys,tt)}}),De.loadingRetryTimes[tt]=(De.loadingRetryTimes[tt]||0)+1,De.loadingRetryTimes[tt]>=_t){var Gn=De.state.loadedKeys;(0,ae.ZP)(!1,"Retry for `loadData` many times but still failed. No more retry."),De.setUncontrolledState({loadedKeys:(0,Rt.L0)(Gn,tt)}),vt()}Pt(Rn)}),{loadingKeys:(0,Rt.L0)(Lt,tt)}})});return Ct.catch(function(){}),Ct}}),(0,E.Z)((0,le.Z)(De),"onNodeMouseEnter",function(Me,Re){var tt=De.props.onMouseEnter;tt==null||tt({event:Me,node:Re})}),(0,E.Z)((0,le.Z)(De),"onNodeMouseLeave",function(Me,Re){var tt=De.props.onMouseLeave;tt==null||tt({event:Me,node:Re})}),(0,E.Z)((0,le.Z)(De),"onNodeContextMenu",function(Me,Re){var tt=De.props.onRightClick;tt&&(Me.preventDefault(),tt({event:Me,node:Re}))}),(0,E.Z)((0,le.Z)(De),"onFocus",function(){var Me=De.props.onFocus;De.setState({focused:!0});for(var Re=arguments.length,tt=new Array(Re),lt=0;lt<Re;lt++)tt[lt]=arguments[lt];Me==null||Me.apply(void 0,tt)}),(0,E.Z)((0,le.Z)(De),"onBlur",function(){var Me=De.props.onBlur;De.setState({focused:!1}),De.onActiveChange(null);for(var Re=arguments.length,tt=new Array(Re),lt=0;lt<Re;lt++)tt[lt]=arguments[lt];Me==null||Me.apply(void 0,tt)}),(0,E.Z)((0,le.Z)(De),"getTreeNodeRequiredProps",function(){var Me=De.state,Re=Me.expandedKeys,tt=Me.selectedKeys,lt=Me.loadedKeys,Nt=Me.loadingKeys,Ct=Me.checkedKeys,vt=Me.halfCheckedKeys,Pt=Me.dragOverNodeKey,Ht=Me.dropPosition,jt=Me.keyEntities;return{expandedKeys:Re||[],selectedKeys:tt||[],loadedKeys:lt||[],loadingKeys:Nt||[],checkedKeys:Ct||[],halfCheckedKeys:vt||[],dragOverNodeKey:Pt,dropPosition:Ht,keyEntities:jt}}),(0,E.Z)((0,le.Z)(De),"setExpandedKeys",function(Me){var Re=De.state,tt=Re.treeData,lt=Re.fieldNames,Nt=(0,Pe.oH)(tt,Me,lt);De.setUncontrolledState({expandedKeys:Me,flattenNodes:Nt},!0)}),(0,E.Z)((0,le.Z)(De),"onNodeExpand",function(Me,Re){var tt=De.state.expandedKeys,lt=De.state,Nt=lt.listChanging,Ct=lt.fieldNames,vt=De.props,Pt=vt.onExpand,Ht=vt.loadData,jt=Re.expanded,yt=Re[Ct.key];if(!Nt){var Yt=tt.includes(yt),Lt=!jt;if((0,ae.ZP)(jt&&Yt||!jt&&!Yt,"Expand state not sync with index check"),tt=Lt?(0,Rt.L0)(tt,yt):(0,Rt._5)(tt,yt),De.setExpandedKeys(tt),Pt==null||Pt(tt,{node:Re,expanded:Lt,nativeEvent:Me.nativeEvent}),Lt&&Ht){var Kt=De.onNodeLoad(Re);Kt&&Kt.then(function(){var sn=(0,Pe.oH)(De.state.treeData,tt,Ct);De.setUncontrolledState({flattenNodes:sn})}).catch(function(){var sn=De.state.expandedKeys,wn=(0,Rt._5)(sn,yt);De.setExpandedKeys(wn)})}}}),(0,E.Z)((0,le.Z)(De),"onListChangeStart",function(){De.setUncontrolledState({listChanging:!0})}),(0,E.Z)((0,le.Z)(De),"onListChangeEnd",function(){setTimeout(function(){De.setUncontrolledState({listChanging:!1})})}),(0,E.Z)((0,le.Z)(De),"onActiveChange",function(Me){var Re=De.state.activeKey,tt=De.props,lt=tt.onActiveChange,Nt=tt.itemScrollOffset,Ct=Nt===void 0?0:Nt;Re!==Me&&(De.setState({activeKey:Me}),Me!==null&&De.scrollTo({key:Me,offset:Ct}),lt==null||lt(Me))}),(0,E.Z)((0,le.Z)(De),"getActiveItem",function(){var Me=De.state,Re=Me.activeKey,tt=Me.flattenNodes;return Re===null?null:tt.find(function(lt){var Nt=lt.key;return Nt===Re})||null}),(0,E.Z)((0,le.Z)(De),"offsetActiveKey",function(Me){var Re=De.state,tt=Re.flattenNodes,lt=Re.activeKey,Nt=tt.findIndex(function(Pt){var Ht=Pt.key;return Ht===lt});Nt===-1&&Me<0&&(Nt=tt.length),Nt=(Nt+Me+tt.length)%tt.length;var Ct=tt[Nt];if(Ct){var vt=Ct.key;De.onActiveChange(vt)}else De.onActiveChange(null)}),(0,E.Z)((0,le.Z)(De),"onKeyDown",function(Me){var Re=De.state,tt=Re.activeKey,lt=Re.expandedKeys,Nt=Re.checkedKeys,Ct=Re.fieldNames,vt=De.props,Pt=vt.onKeyDown,Ht=vt.checkable,jt=vt.selectable;switch(Me.which){case x.Z.UP:{De.offsetActiveKey(-1),Me.preventDefault();break}case x.Z.DOWN:{De.offsetActiveKey(1),Me.preventDefault();break}}var yt=De.getActiveItem();if(yt&&yt.data){var Yt=De.getTreeNodeRequiredProps(),Lt=yt.data.isLeaf===!1||!!(yt.data[Ct.children]||[]).length,Kt=(0,Pe.F)((0,Ce.Z)((0,Ce.Z)({},(0,Pe.H8)(tt,Yt)),{},{data:yt.data,active:!0}));switch(Me.which){case x.Z.LEFT:{Lt&<.includes(tt)?De.onNodeExpand({},Kt):yt.parent&&De.onActiveChange(yt.parent.key),Me.preventDefault();break}case x.Z.RIGHT:{Lt&&!lt.includes(tt)?De.onNodeExpand({},Kt):yt.children&&yt.children.length&&De.onActiveChange(yt.children[0].key),Me.preventDefault();break}case x.Z.ENTER:case x.Z.SPACE:{Ht&&!Kt.disabled&&Kt.checkable!==!1&&!Kt.disableCheckbox?De.onNodeCheck({},Kt,!Nt.includes(tt)):!Ht&&jt&&!Kt.disabled&&Kt.selectable!==!1&&De.onNodeSelect({},Kt);break}}}Pt==null||Pt(Me)}),(0,E.Z)((0,le.Z)(De),"setUncontrolledState",function(Me){var Re=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,tt=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(!De.destroyed){var lt=!1,Nt=!0,Ct={};Object.keys(Me).forEach(function(vt){if(De.props.hasOwnProperty(vt)){Nt=!1;return}lt=!0,Ct[vt]=Me[vt]}),lt&&(!Re||Nt)&&De.setState((0,Ce.Z)((0,Ce.Z)({},Ct),tt))}}),(0,E.Z)((0,le.Z)(De),"scrollTo",function(Me){De.listRef.current.scrollTo(Me)}),De}return(0,te.Z)(Ne,[{key:"componentDidMount",value:function(){this.destroyed=!1,this.onUpdated()}},{key:"componentDidUpdate",value:function(){this.onUpdated()}},{key:"onUpdated",value:function(){var we=this.props,Le=we.activeKey,Ue=we.itemScrollOffset,Me=Ue===void 0?0:Ue;Le!==void 0&&Le!==this.state.activeKey&&(this.setState({activeKey:Le}),Le!==null&&this.scrollTo({key:Le,offset:Me}))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("dragend",this.onWindowDragEnd),this.destroyed=!0}},{key:"resetDragState",value:function(){this.setState({dragOverNodeKey:null,dropPosition:null,dropLevelOffset:null,dropTargetKey:null,dropContainerKey:null,dropTargetPos:null,dropAllowed:!1})}},{key:"render",value:function(){var we=this.state,Le=we.focused,Ue=we.flattenNodes,Me=we.keyEntities,Re=we.draggingNodeKey,tt=we.activeKey,lt=we.dropLevelOffset,Nt=we.dropContainerKey,Ct=we.dropTargetKey,vt=we.dropPosition,Pt=we.dragOverNodeKey,Ht=we.indent,jt=this.props,yt=jt.prefixCls,Yt=jt.className,Lt=jt.style,Kt=jt.showLine,sn=jt.focusable,wn=jt.tabIndex,Vt=wn===void 0?0:wn,Rn=jt.selectable,Gn=jt.showIcon,Zn=jt.icon,tr=jt.switcherIcon,hr=jt.draggable,ur=jt.checkable,zn=jt.checkStrictly,Bn=jt.disabled,ir=jt.motion,Kn=jt.loadData,Nn=jt.filterTreeNode,yn=jt.height,Hn=jt.itemHeight,dr=jt.scrollWidth,Mn=jt.virtual,Cn=jt.titleRender,$n=jt.dropIndicatorRender,Jt=jt.onContextMenu,Ie=jt.onScroll,Ze=jt.direction,qe=jt.rootClassName,st=jt.rootStyle,mt=(0,re.Z)(this.props,{aria:!0,data:!0}),Bt;hr&&((0,ie.Z)(hr)==="object"?Bt=hr:typeof hr=="function"?Bt={nodeDraggable:hr}:Bt={});var kt={prefixCls:yt,selectable:Rn,showIcon:Gn,icon:Zn,switcherIcon:tr,draggable:Bt,draggingNodeKey:Re,checkable:ur,checkStrictly:zn,disabled:Bn,keyEntities:Me,dropLevelOffset:lt,dropContainerKey:Nt,dropTargetKey:Ct,dropPosition:vt,dragOverNodeKey:Pt,indent:Ht,direction:Ze,dropIndicatorRender:$n,loadData:Kn,filterTreeNode:Nn,titleRender:Cn,onNodeClick:this.onNodeClick,onNodeDoubleClick:this.onNodeDoubleClick,onNodeExpand:this.onNodeExpand,onNodeSelect:this.onNodeSelect,onNodeCheck:this.onNodeCheck,onNodeLoad:this.onNodeLoad,onNodeMouseEnter:this.onNodeMouseEnter,onNodeMouseLeave:this.onNodeMouseLeave,onNodeContextMenu:this.onNodeContextMenu,onNodeDragStart:this.onNodeDragStart,onNodeDragEnter:this.onNodeDragEnter,onNodeDragOver:this.onNodeDragOver,onNodeDragLeave:this.onNodeDragLeave,onNodeDragEnd:this.onNodeDragEnd,onNodeDrop:this.onNodeDrop};return oe.createElement(ve.k.Provider,{value:kt},oe.createElement("div",{className:z()(yt,Yt,qe,(0,E.Z)((0,E.Z)((0,E.Z)({},"".concat(yt,"-show-line"),Kt),"".concat(yt,"-focused"),Le),"".concat(yt,"-active-focused"),tt!==null)),style:st},oe.createElement(dt,(0,ce.Z)({ref:this.listRef,prefixCls:yt,style:Lt,data:Ue,disabled:Bn,selectable:Rn,checkable:!!ur,motion:ir,dragging:Re!==null,height:yn,itemHeight:Hn,virtual:Mn,focusable:sn,focused:Le,tabIndex:Vt,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:Jt,onScroll:Ie,scrollWidth:dr},this.getTreeNodeRequiredProps(),mt))))}}],[{key:"getDerivedStateFromProps",value:function(we,Le){var Ue=Le.prevProps,Me={prevProps:we};function Re(Vt){return!Ue&&we.hasOwnProperty(Vt)||Ue&&Ue[Vt]!==we[Vt]}var tt,lt=Le.fieldNames;if(Re("fieldNames")&&(lt=(0,Pe.w$)(we.fieldNames),Me.fieldNames=lt),Re("treeData")?tt=we.treeData:Re("children")&&((0,ae.ZP)(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),tt=(0,Pe.zn)(we.children)),tt){Me.treeData=tt;var Nt=(0,Pe.I8)(tt,{fieldNames:lt});Me.keyEntities=(0,Ce.Z)((0,E.Z)({},ze,$e),Nt.keyEntities)}var Ct=Me.keyEntities||Le.keyEntities;if(Re("expandedKeys")||Ue&&Re("autoExpandParent"))Me.expandedKeys=we.autoExpandParent||!Ue&&we.defaultExpandParent?(0,Rt.r7)(we.expandedKeys,Ct):we.expandedKeys;else if(!Ue&&we.defaultExpandAll){var vt=(0,Ce.Z)({},Ct);delete vt[ze];var Pt=[];Object.keys(vt).forEach(function(Vt){var Rn=vt[Vt];Rn.children&&Rn.children.length&&Pt.push(Rn.key)}),Me.expandedKeys=Pt}else!Ue&&we.defaultExpandedKeys&&(Me.expandedKeys=we.autoExpandParent||we.defaultExpandParent?(0,Rt.r7)(we.defaultExpandedKeys,Ct):we.defaultExpandedKeys);if(Me.expandedKeys||delete Me.expandedKeys,tt||Me.expandedKeys){var Ht=(0,Pe.oH)(tt||Le.treeData,Me.expandedKeys||Le.expandedKeys,lt);Me.flattenNodes=Ht}if(we.selectable&&(Re("selectedKeys")?Me.selectedKeys=(0,Rt.BT)(we.selectedKeys,we):!Ue&&we.defaultSelectedKeys&&(Me.selectedKeys=(0,Rt.BT)(we.defaultSelectedKeys,we))),we.checkable){var jt;if(Re("checkedKeys")?jt=(0,Rt.E6)(we.checkedKeys)||{}:!Ue&&we.defaultCheckedKeys?jt=(0,Rt.E6)(we.defaultCheckedKeys)||{}:tt&&(jt=(0,Rt.E6)(we.checkedKeys)||{checkedKeys:Le.checkedKeys,halfCheckedKeys:Le.halfCheckedKeys}),jt){var yt=jt,Yt=yt.checkedKeys,Lt=Yt===void 0?[]:Yt,Kt=yt.halfCheckedKeys,sn=Kt===void 0?[]:Kt;if(!we.checkStrictly){var wn=(0,xt.S)(Lt,!0,Ct);Lt=wn.checkedKeys,sn=wn.halfCheckedKeys}Me.checkedKeys=Lt,Me.halfCheckedKeys=sn}}return Re("loadedKeys")&&(Me.loadedKeys=we.loadedKeys),Me}}]),Ne}(oe.Component);(0,E.Z)(We,"defaultProps",{prefixCls:"rc-tree",showLine:!1,showIcon:!0,selectable:!0,multiple:!1,checkable:!1,disabled:!1,checkStrictly:!1,draggable:!1,defaultExpandParent:!0,autoExpandParent:!1,defaultExpandAll:!1,defaultExpandedKeys:[],defaultCheckedKeys:[],defaultSelectedKeys:[],dropIndicatorRender:me,allowDrop:function(){return!0},expandAction:!1}),(0,E.Z)(We,"TreeNode",Ee.Z);var Ae=We,Se=Ae},82661:function(Xt,Mt,be){"use strict";be.d(Mt,{BT:function(){return oe},E6:function(){return me},L0:function(){return E},OM:function(){return ae},_5:function(){return ne},r7:function(){return ge},wA:function(){return z},yx:function(){return b}});var ce=be(3300),ie=be(34666),Ce=be(48736),ue=be(59301),se=be(639),te=be(65065),le=be(34061),ee=null;function ne(_e,he){if(!_e)return[];var pe=_e.slice(),ke=pe.indexOf(he);return ke>=0&&pe.splice(ke,1),pe}function E(_e,he){var pe=(_e||[]).slice();return pe.indexOf(he)===-1&&pe.push(he),pe}function b(_e){return _e.split("-")}function z(_e,he){var pe=[],ke=(0,te.Z)(he,_e);function Te(){var Ee=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];Ee.forEach(function(Oe){var je=Oe.key,Pe=Oe.children;pe.push(je),Te(Pe)})}return Te(ke.children),pe}function x(_e){if(_e.parent){var he=b(_e.pos);return Number(he[he.length-1])===_e.parent.children.length-1}return!1}function re(_e){var he=b(_e.pos);return Number(he[he.length-1])===0}function ae(_e,he,pe,ke,Te,Ee,Oe,je,Pe,Qe){var Xe,ot=_e.clientX,He=_e.clientY,rt=_e.target.getBoundingClientRect(),Ye=rt.top,ut=rt.height,Ge=(Qe==="rtl"?-1:1)*(((Te==null?void 0:Te.x)||0)-ot),ze=(Ge-12)/ke,Ve=Pe.filter(function(Se){var Be;return(Be=je[Se])===null||Be===void 0||(Be=Be.children)===null||Be===void 0?void 0:Be.length}),$e=(0,te.Z)(je,pe.eventKey);if(He<Ye+ut/2){var nt=Oe.findIndex(function(Se){return Se.key===$e.key}),et=nt<=0?0:nt-1,pt=Oe[et].key;$e=(0,te.Z)(je,pt)}var ct=$e.key,Ot=$e,dt=$e.key,Rt=0,xt=0;if(!Ve.includes(ct))for(var gt=0;gt<ze&&x($e);gt+=1)$e=$e.parent,xt+=1;var _t=he.data,We=$e.node,Ae=!0;return re($e)&&$e.level===0&&He<Ye+ut/2&&Ee({dragNode:_t,dropNode:We,dropPosition:-1})&&$e.key===pe.eventKey?Rt=-1:(Ot.children||[]).length&&Ve.includes(dt)?Ee({dragNode:_t,dropNode:We,dropPosition:0})?Rt=0:Ae=!1:xt===0?ze>-1.5?Ee({dragNode:_t,dropNode:We,dropPosition:1})?Rt=1:Ae=!1:Ee({dragNode:_t,dropNode:We,dropPosition:0})?Rt=0:Ee({dragNode:_t,dropNode:We,dropPosition:1})?Rt=1:Ae=!1:Ee({dragNode:_t,dropNode:We,dropPosition:1})?Rt=1:Ae=!1,{dropPosition:Rt,dropLevelOffset:xt,dropTargetKey:$e.key,dropTargetPos:$e.pos,dragOverNodeKey:dt,dropContainerKey:Rt===0?null:((Xe=$e.parent)===null||Xe===void 0?void 0:Xe.key)||null,dropAllowed:Ae}}function oe(_e,he){if(_e){var pe=he.multiple;return pe?_e.slice():_e.length?[_e[0]]:_e}}var ve=function(he){return he};function ye(_e,he){if(!_e)return[];var pe=he||{},ke=pe.processProps,Te=ke===void 0?ve:ke,Ee=Array.isArray(_e)?_e:[_e];return Ee.map(function(Oe){var je=Oe.children,Pe=_objectWithoutProperties(Oe,ee),Qe=ye(je,he);return React.createElement(TreeNode,_extends({key:Pe.key},Te(Pe)),Qe)})}function me(_e){if(!_e)return null;var he;if(Array.isArray(_e))he={checkedKeys:_e,halfCheckedKeys:void 0};else if((0,ie.Z)(_e)==="object")he={checkedKeys:_e.checked||void 0,halfCheckedKeys:_e.halfChecked||void 0};else return(0,Ce.ZP)(!1,"`checkedKeys` is not an array or an object"),null;return he}function ge(_e,he){var pe=new Set;function ke(Te){if(!pe.has(Te)){var Ee=(0,te.Z)(he,Te);if(Ee){pe.add(Te);var Oe=Ee.parent,je=Ee.node;je.disabled||Oe&&ke(Oe.key)}}}return(_e||[]).forEach(function(Te){ke(Te)}),(0,ce.Z)(pe)}},34643:function(Xt,Mt,be){"use strict";be.d(Mt,{S:function(){return le}});var ce=be(48736),ie=be(65065);function Ce(ee,ne){var E=new Set;return ee.forEach(function(b){ne.has(b)||E.add(b)}),E}function ue(ee){var ne=ee||{},E=ne.disabled,b=ne.disableCheckbox,z=ne.checkable;return!!(E||b)||z===!1}function se(ee,ne,E,b){for(var z=new Set(ee),x=new Set,re=0;re<=E;re+=1){var ae=ne.get(re)||new Set;ae.forEach(function(me){var ge=me.key,_e=me.node,he=me.children,pe=he===void 0?[]:he;z.has(ge)&&!b(_e)&&pe.filter(function(ke){return!b(ke.node)}).forEach(function(ke){z.add(ke.key)})})}for(var oe=new Set,ve=E;ve>=0;ve-=1){var ye=ne.get(ve)||new Set;ye.forEach(function(me){var ge=me.parent,_e=me.node;if(!(b(_e)||!me.parent||oe.has(me.parent.key))){if(b(me.parent.node)){oe.add(ge.key);return}var he=!0,pe=!1;(ge.children||[]).filter(function(ke){return!b(ke.node)}).forEach(function(ke){var Te=ke.key,Ee=z.has(Te);he&&!Ee&&(he=!1),!pe&&(Ee||x.has(Te))&&(pe=!0)}),he&&z.add(ge.key),pe&&x.add(ge.key),oe.add(ge.key)}})}return{checkedKeys:Array.from(z),halfCheckedKeys:Array.from(Ce(x,z))}}function te(ee,ne,E,b,z){for(var x=new Set(ee),re=new Set(ne),ae=0;ae<=b;ae+=1){var oe=E.get(ae)||new Set;oe.forEach(function(ge){var _e=ge.key,he=ge.node,pe=ge.children,ke=pe===void 0?[]:pe;!x.has(_e)&&!re.has(_e)&&!z(he)&&ke.filter(function(Te){return!z(Te.node)}).forEach(function(Te){x.delete(Te.key)})})}re=new Set;for(var ve=new Set,ye=b;ye>=0;ye-=1){var me=E.get(ye)||new Set;me.forEach(function(ge){var _e=ge.parent,he=ge.node;if(!(z(he)||!ge.parent||ve.has(ge.parent.key))){if(z(ge.parent.node)){ve.add(_e.key);return}var pe=!0,ke=!1;(_e.children||[]).filter(function(Te){return!z(Te.node)}).forEach(function(Te){var Ee=Te.key,Oe=x.has(Ee);pe&&!Oe&&(pe=!1),!ke&&(Oe||re.has(Ee))&&(ke=!0)}),pe||x.delete(_e.key),ke&&re.add(_e.key),ve.add(_e.key)}})}return{checkedKeys:Array.from(x),halfCheckedKeys:Array.from(Ce(re,x))}}function le(ee,ne,E,b){var z=[],x;b?x=b:x=ue;var re=new Set(ee.filter(function(ye){var me=!!(0,ie.Z)(E,ye);return me||z.push(ye),me})),ae=new Map,oe=0;Object.keys(E).forEach(function(ye){var me=E[ye],ge=me.level,_e=ae.get(ge);_e||(_e=new Set,ae.set(ge,_e)),_e.add(me),oe=Math.max(oe,ge)}),(0,ce.ZP)(!z.length,"Tree missing follow keys: ".concat(z.slice(0,100).map(function(ye){return"'".concat(ye,"'")}).join(", ")));var ve;return ne===!0?ve=se(re,ae,oe,x):ve=te(re,ne.halfCheckedKeys,ae,oe,x),ve}},65065:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ce}});function ce(ie,Ce){return ie[Ce]}},34061:function(Xt,Mt,be){"use strict";be.d(Mt,{F:function(){return ge},H8:function(){return me},I8:function(){return ye},km:function(){return z},oH:function(){return oe},w$:function(){return x},zn:function(){return ae}});var ce=be(34666),ie=be(3300),Ce=be(27247),ue=be(43079),se=be(11592),te=be(2738),le=be(48736),ee=be(65065),ne=["children"];function E(_e,he){return"".concat(_e,"-").concat(he)}function b(_e){return _e&&_e.type&&_e.type.isTreeNode}function z(_e,he){return _e!=null?_e:he}function x(_e){var he=_e||{},pe=he.title,ke=he._title,Te=he.key,Ee=he.children,Oe=pe||"title";return{title:Oe,_title:ke||[Oe],key:Te||"key",children:Ee||"children"}}function re(_e,he){var pe=new Map;function ke(Te){var Ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";(Te||[]).forEach(function(Oe){var je=Oe[he.key],Pe=Oe[he.children];warning(je!=null,"Tree node must have a certain key: [".concat(Ee).concat(je,"]"));var Qe=String(je);warning(!pe.has(Qe)||je===null||je===void 0,"Same 'key' exist in the Tree: ".concat(Qe)),pe.set(Qe,!0),ke(Pe,"".concat(Ee).concat(Qe," > "))})}ke(_e)}function ae(_e){function he(pe){var ke=(0,se.Z)(pe);return ke.map(function(Te){if(!b(Te))return(0,le.ZP)(!Te,"Tree/TreeNode can only accept TreeNode as children."),null;var Ee=Te.key,Oe=Te.props,je=Oe.children,Pe=(0,ue.Z)(Oe,ne),Qe=(0,Ce.Z)({key:Ee},Pe),Xe=he(je);return Xe.length&&(Qe.children=Xe),Qe}).filter(function(Te){return Te})}return he(_e)}function oe(_e,he,pe){var ke=x(pe),Te=ke._title,Ee=ke.key,Oe=ke.children,je=new Set(he===!0?[]:he),Pe=[];function Qe(Xe){var ot=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;return Xe.map(function(He,rt){for(var Ye=E(ot?ot.pos:"0",rt),ut=z(He[Ee],Ye),Ge,ze=0;ze<Te.length;ze+=1){var Ve=Te[ze];if(He[Ve]!==void 0){Ge=He[Ve];break}}var $e=Object.assign((0,te.Z)(He,[].concat((0,ie.Z)(Te),[Ee,Oe])),{title:Ge,key:ut,parent:ot,pos:Ye,children:null,data:He,isStart:[].concat((0,ie.Z)(ot?ot.isStart:[]),[rt===0]),isEnd:[].concat((0,ie.Z)(ot?ot.isEnd:[]),[rt===Xe.length-1])});return Pe.push($e),he===!0||je.has(ut)?$e.children=Qe(He[Oe]||[],$e):$e.children=[],$e})}return Qe(_e),Pe}function ve(_e,he,pe){var ke={};(0,ce.Z)(pe)==="object"?ke=pe:ke={externalGetKey:pe},ke=ke||{};var Te=ke,Ee=Te.childrenPropName,Oe=Te.externalGetKey,je=Te.fieldNames,Pe=x(je),Qe=Pe.key,Xe=Pe.children,ot=Ee||Xe,He;Oe?typeof Oe=="string"?He=function(ut){return ut[Oe]}:typeof Oe=="function"&&(He=function(ut){return Oe(ut)}):He=function(ut,Ge){return z(ut[Qe],Ge)};function rt(Ye,ut,Ge,ze){var Ve=Ye?Ye[ot]:_e,$e=Ye?E(Ge.pos,ut):"0",nt=Ye?[].concat((0,ie.Z)(ze),[Ye]):[];if(Ye){var et=He(Ye,$e),pt={node:Ye,index:ut,pos:$e,key:et,parentPos:Ge.node?Ge.pos:null,level:Ge.level+1,nodes:nt};he(pt)}Ve&&Ve.forEach(function(ct,Ot){rt(ct,Ot,{node:Ye,pos:$e,level:Ge?Ge.level+1:-1},nt)})}rt(null)}function ye(_e){var he=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},pe=he.initWrapper,ke=he.processEntity,Te=he.onProcessFinished,Ee=he.externalGetKey,Oe=he.childrenPropName,je=he.fieldNames,Pe=arguments.length>2?arguments[2]:void 0,Qe=Ee||Pe,Xe={},ot={},He={posEntities:Xe,keyEntities:ot};return pe&&(He=pe(He)||He),ve(_e,function(rt){var Ye=rt.node,ut=rt.index,Ge=rt.pos,ze=rt.key,Ve=rt.parentPos,$e=rt.level,nt=rt.nodes,et={node:Ye,nodes:nt,index:ut,key:ze,pos:Ge,level:$e},pt=z(ze,Ge);Xe[Ge]=et,ot[pt]=et,et.parent=Xe[Ve],et.parent&&(et.parent.children=et.parent.children||[],et.parent.children.push(et)),ke&&ke(et,He)},{externalGetKey:Qe,childrenPropName:Oe,fieldNames:je}),Te&&Te(He),He}function me(_e,he){var pe=he.expandedKeys,ke=he.selectedKeys,Te=he.loadedKeys,Ee=he.loadingKeys,Oe=he.checkedKeys,je=he.halfCheckedKeys,Pe=he.dragOverNodeKey,Qe=he.dropPosition,Xe=he.keyEntities,ot=(0,ee.Z)(Xe,_e),He={eventKey:_e,expanded:pe.indexOf(_e)!==-1,selected:ke.indexOf(_e)!==-1,loaded:Te.indexOf(_e)!==-1,loading:Ee.indexOf(_e)!==-1,checked:Oe.indexOf(_e)!==-1,halfChecked:je.indexOf(_e)!==-1,pos:String(ot?ot.pos:""),dragOver:Pe===_e&&Qe===0,dragOverGapTop:Pe===_e&&Qe===-1,dragOverGapBottom:Pe===_e&&Qe===1};return He}function ge(_e){var he=_e.data,pe=_e.expanded,ke=_e.selected,Te=_e.checked,Ee=_e.loaded,Oe=_e.loading,je=_e.halfChecked,Pe=_e.dragOver,Qe=_e.dragOverGapTop,Xe=_e.dragOverGapBottom,ot=_e.pos,He=_e.active,rt=_e.eventKey,Ye=(0,Ce.Z)((0,Ce.Z)({},he),{},{expanded:pe,selected:ke,checked:Te,loaded:Ee,loading:Oe,halfChecked:je,dragOver:Pe,dragOverGapTop:Qe,dragOverGapBottom:Xe,pos:ot,active:He,key:rt});return"props"in Ye||Object.defineProperty(Ye,"props",{get:function(){return(0,le.ZP)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),_e}}),Ye}},8224:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ie}});var ce=be(4676);function ie(Ce,ue,se,te){var le=ce.unstable_batchedUpdates?function(ne){ce.unstable_batchedUpdates(se,ne)}:se;return Ce!=null&&Ce.addEventListener&&Ce.addEventListener(ue,le,te),{remove:function(){Ce!=null&&Ce.removeEventListener&&Ce.removeEventListener(ue,le,te)}}}},24514:function(Xt,Mt,be){"use strict";be.d(Mt,{G:function(){return ue}});var ce=be(47273),ie=function(te){if((0,ce.Z)()&&window.document.documentElement){var le=Array.isArray(te)?te:[te],ee=window.document.documentElement;return le.some(function(ne){return ne in ee.style})}return!1},Ce=function(te,le){if(!ie(te))return!1;var ee=document.createElement("div"),ne=ee.style[te];return ee.style[te]=le,ee.style[te]!==ne};function ue(se,te){return!Array.isArray(se)&&te!==void 0?Ce(se,te):ie(se)}},6790:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return _t}});var ce=be(32855),ie=be(34666),Ce=be(27247),ue=be(74430),se=be(11913),te=be(43079),le=be(92310),ee=be.n(le),ne=be(29301),E=be(70425),b=be(34280),z=be(59301),x=be(4676),re=z.forwardRef(function(We,Ae){var Se=We.height,Be=We.offsetY,Ke=We.offsetX,Ne=We.children,De=We.prefixCls,we=We.onInnerResize,Le=We.innerProps,Ue=We.rtl,Me=We.extra,Re={},tt={display:"flex",flexDirection:"column"};return Be!==void 0&&(Re={height:Se,position:"relative",overflow:"hidden"},tt=(0,Ce.Z)((0,Ce.Z)({},tt),{},(0,ue.Z)((0,ue.Z)((0,ue.Z)((0,ue.Z)((0,ue.Z)({transform:"translateY(".concat(Be,"px)")},Ue?"marginRight":"marginLeft",-Ke),"position","absolute"),"left",0),"right",0),"top",0))),z.createElement("div",{style:Re},z.createElement(ne.Z,{onResize:function(Nt){var Ct=Nt.offsetHeight;Ct&&we&&we()}},z.createElement("div",(0,ce.Z)({style:tt,className:ee()((0,ue.Z)({},"".concat(De,"-holder-inner"),De)),ref:Ae},Le),Ne,Me)))});re.displayName="Filler";var ae=re;function oe(We){var Ae=We.children,Se=We.setRef,Be=z.useCallback(function(Ke){Se(Ke)},[]);return z.cloneElement(Ae,{ref:Be})}function ve(We,Ae,Se,Be,Ke,Ne,De,we){var Le=we.getKey;return We.slice(Ae,Se+1).map(function(Ue,Me){var Re=Ae+Me,tt=De(Ue,Re,{style:{width:Be},offsetX:Ke}),lt=Le(Ue);return z.createElement(oe,{key:lt,setRef:function(Ct){return Ne(Ue,Ct)}},tt)})}function ye(We,Ae,Se,Be){var Ke=Se-We,Ne=Ae-Se,De=Math.min(Ke,Ne)*2;if(Be<=De){var we=Math.floor(Be/2);return Be%2?Se+we+1:Se-we}return Ke>Ne?Se-(Be-Ne):Se+(Be-Ke)}function me(We,Ae,Se){var Be=We.length,Ke=Ae.length,Ne,De;if(Be===0&&Ke===0)return null;Be<Ke?(Ne=We,De=Ae):(Ne=Ae,De=We);var we={__EMPTY_ITEM__:!0};function Le(Nt){return Nt!==void 0?Se(Nt):we}for(var Ue=null,Me=Math.abs(Be-Ke)!==1,Re=0;Re<De.length;Re+=1){var tt=Le(Ne[Re]),lt=Le(De[Re]);if(tt!==lt){Ue=Re,Me=Me||tt!==Le(De[Re+1]);break}}return Ue===null?null:{index:Ue,multiple:Me}}function ge(We,Ae,Se){var Be=z.useState(We),Ke=(0,se.Z)(Be,2),Ne=Ke[0],De=Ke[1],we=z.useState(null),Le=(0,se.Z)(we,2),Ue=Le[0],Me=Le[1];return z.useEffect(function(){var Re=me(Ne||[],We||[],Ae);(Re==null?void 0:Re.index)!==void 0&&(Se==null||Se(Re.index),Me(We[Re.index])),De(We)},[We]),[Ue]}var _e=be(16089),he=(typeof navigator=="undefined"?"undefined":(0,ie.Z)(navigator))==="object"&&/Firefox/i.test(navigator.userAgent),pe=he,ke=function(We,Ae,Se,Be){var Ke=(0,z.useRef)(!1),Ne=(0,z.useRef)(null);function De(){clearTimeout(Ne.current),Ke.current=!0,Ne.current=setTimeout(function(){Ke.current=!1},50)}var we=(0,z.useRef)({top:We,bottom:Ae,left:Se,right:Be});return we.current.top=We,we.current.bottom=Ae,we.current.left=Se,we.current.right=Be,function(Le,Ue){var Me=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,Re=Le?Ue<0&&we.current.left||Ue>0&&we.current.right:Ue<0&&we.current.top||Ue>0&&we.current.bottom;return Me&&Re?(clearTimeout(Ne.current),Ke.current=!1):(!Re||Ke.current)&&De(),!Ke.current&&Re}};function Te(We,Ae,Se,Be,Ke,Ne,De){var we=(0,z.useRef)(0),Le=(0,z.useRef)(null),Ue=(0,z.useRef)(null),Me=(0,z.useRef)(!1),Re=ke(Ae,Se,Be,Ke);function tt(Ht,jt){if(_e.Z.cancel(Le.current),!Re(!1,jt)){var yt=Ht;if(!yt._virtualHandled)yt._virtualHandled=!0;else return;we.current+=jt,Ue.current=jt,pe||yt.preventDefault(),Le.current=(0,_e.Z)(function(){var Yt=Me.current?10:1;De(we.current*Yt,!1),we.current=0})}}function lt(Ht,jt){De(jt,!0),pe||Ht.preventDefault()}var Nt=(0,z.useRef)(null),Ct=(0,z.useRef)(null);function vt(Ht){if(We){_e.Z.cancel(Ct.current),Ct.current=(0,_e.Z)(function(){Nt.current=null},2);var jt=Ht.deltaX,yt=Ht.deltaY,Yt=Ht.shiftKey,Lt=jt,Kt=yt;(Nt.current==="sx"||!Nt.current&&Yt&&yt&&!jt)&&(Lt=yt,Kt=0,Nt.current="sx");var sn=Math.abs(Lt),wn=Math.abs(Kt);Nt.current===null&&(Nt.current=Ne&&sn>wn?"x":"y"),Nt.current==="y"?tt(Ht,Kt):lt(Ht,Lt)}}function Pt(Ht){We&&(Me.current=Ht.detail===Ue.current)}return[vt,Pt]}function Ee(We,Ae,Se,Be){var Ke=z.useMemo(function(){return[new Map,[]]},[We,Se.id,Be]),Ne=(0,se.Z)(Ke,2),De=Ne[0],we=Ne[1],Le=function(Me){var Re=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Me,tt=De.get(Me),lt=De.get(Re);if(tt===void 0||lt===void 0)for(var Nt=We.length,Ct=we.length;Ct<Nt;Ct+=1){var vt,Pt=We[Ct],Ht=Ae(Pt);De.set(Ht,Ct);var jt=(vt=Se.get(Ht))!==null&&vt!==void 0?vt:Be;if(we[Ct]=(we[Ct-1]||0)+jt,Ht===Me&&(tt=Ct),Ht===Re&&(lt=Ct),tt!==void 0&<!==void 0)break}return{top:we[tt-1]||0,bottom:we[lt]}};return Le}var Oe=be(33377),je=be(93912),Pe=function(){function We(){(0,Oe.Z)(this,We),(0,ue.Z)(this,"maps",void 0),(0,ue.Z)(this,"id",0),(0,ue.Z)(this,"diffRecords",new Map),this.maps=Object.create(null)}return(0,je.Z)(We,[{key:"set",value:function(Se,Be){this.diffRecords.set(Se,this.maps[Se]),this.maps[Se]=Be,this.id+=1}},{key:"get",value:function(Se){return this.maps[Se]}},{key:"resetRecord",value:function(){this.diffRecords.clear()}},{key:"getRecord",value:function(){return this.diffRecords}}]),We}(),Qe=Pe;function Xe(We){var Ae=parseFloat(We);return isNaN(Ae)?0:Ae}function ot(We,Ae,Se){var Be=z.useState(0),Ke=(0,se.Z)(Be,2),Ne=Ke[0],De=Ke[1],we=(0,z.useRef)(new Map),Le=(0,z.useRef)(new Qe),Ue=(0,z.useRef)(0);function Me(){Ue.current+=1}function Re(){var lt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;Me();var Nt=function(){var Pt=!1;we.current.forEach(function(Ht,jt){if(Ht&&Ht.offsetParent){var yt=Ht.offsetHeight,Yt=getComputedStyle(Ht),Lt=Yt.marginTop,Kt=Yt.marginBottom,sn=Xe(Lt),wn=Xe(Kt),Vt=yt+sn+wn;Le.current.get(jt)!==Vt&&(Le.current.set(jt,Vt),Pt=!0)}}),Pt&&De(function(Ht){return Ht+1})};if(lt)Nt();else{Ue.current+=1;var Ct=Ue.current;Promise.resolve().then(function(){Ct===Ue.current&&Nt()})}}function tt(lt,Nt){var Ct=We(lt),vt=we.current.get(Ct);Nt?(we.current.set(Ct,Nt),Re()):we.current.delete(Ct),!vt!=!Nt&&(Nt?Ae==null||Ae(lt):Se==null||Se(lt))}return(0,z.useEffect)(function(){return Me},[]),[tt,Re,Le.current,Ne]}var He=14/15;function rt(We,Ae,Se){var Be=(0,z.useRef)(!1),Ke=(0,z.useRef)(0),Ne=(0,z.useRef)(0),De=(0,z.useRef)(null),we=(0,z.useRef)(null),Le,Ue=function(lt){if(Be.current){var Nt=Math.ceil(lt.touches[0].pageX),Ct=Math.ceil(lt.touches[0].pageY),vt=Ke.current-Nt,Pt=Ne.current-Ct,Ht=Math.abs(vt)>Math.abs(Pt);Ht?Ke.current=Nt:Ne.current=Ct;var jt=Se(Ht,Ht?vt:Pt,!1,lt);jt&<.preventDefault(),clearInterval(we.current),jt&&(we.current=setInterval(function(){Ht?vt*=He:Pt*=He;var yt=Math.floor(Ht?vt:Pt);(!Se(Ht,yt,!0)||Math.abs(yt)<=.1)&&clearInterval(we.current)},16))}},Me=function(){Be.current=!1,Le()},Re=function(lt){Le(),lt.touches.length===1&&!Be.current&&(Be.current=!0,Ke.current=Math.ceil(lt.touches[0].pageX),Ne.current=Math.ceil(lt.touches[0].pageY),De.current=lt.target,De.current.addEventListener("touchmove",Ue,{passive:!1}),De.current.addEventListener("touchend",Me,{passive:!0}))};Le=function(){De.current&&(De.current.removeEventListener("touchmove",Ue),De.current.removeEventListener("touchend",Me))},(0,b.Z)(function(){return We&&Ae.current.addEventListener("touchstart",Re,{passive:!0}),function(){var tt;(tt=Ae.current)===null||tt===void 0||tt.removeEventListener("touchstart",Re),Le(),clearInterval(we.current)}},[We])}function Ye(We){return Math.floor(Math.pow(We,.5))}function ut(We,Ae){var Se="touches"in We?We.touches[0]:We;return Se[Ae?"pageX":"pageY"]-window[Ae?"scrollX":"scrollY"]}function Ge(We,Ae,Se){z.useEffect(function(){var Be=Ae.current;if(We&&Be){var Ke=!1,Ne,De,we=function(){_e.Z.cancel(Ne)},Le=function tt(){we(),Ne=(0,_e.Z)(function(){Se(De),tt()})},Ue=function(lt){if(!(lt.target.draggable||lt.button!==0)){var Nt=lt;Nt._virtualHandled||(Nt._virtualHandled=!0,Ke=!0)}},Me=function(){Ke=!1,we()},Re=function(lt){if(Ke){var Nt=ut(lt,!1),Ct=Be.getBoundingClientRect(),vt=Ct.top,Pt=Ct.bottom;if(Nt<=vt){var Ht=vt-Nt;De=-Ye(Ht),Le()}else if(Nt>=Pt){var jt=Nt-Pt;De=Ye(jt),Le()}else we()}};return Be.addEventListener("mousedown",Ue),Be.ownerDocument.addEventListener("mouseup",Me),Be.ownerDocument.addEventListener("mousemove",Re),function(){Be.removeEventListener("mousedown",Ue),Be.ownerDocument.removeEventListener("mouseup",Me),Be.ownerDocument.removeEventListener("mousemove",Re),we()}}},[We])}var ze=10;function Ve(We,Ae,Se,Be,Ke,Ne,De,we){var Le=z.useRef(),Ue=z.useState(null),Me=(0,se.Z)(Ue,2),Re=Me[0],tt=Me[1];return(0,b.Z)(function(){if(Re&&Re.times<ze){if(!We.current){tt(function(ir){return(0,Ce.Z)({},ir)});return}Ne();var lt=Re.targetAlign,Nt=Re.originAlign,Ct=Re.index,vt=Re.offset,Pt=We.current.clientHeight,Ht=!1,jt=lt,yt=null;if(Pt){for(var Yt=lt||Nt,Lt=0,Kt=0,sn=0,wn=Math.min(Ae.length-1,Ct),Vt=0;Vt<=wn;Vt+=1){var Rn=Ke(Ae[Vt]);Kt=Lt;var Gn=Se.get(Rn);sn=Kt+(Gn===void 0?Be:Gn),Lt=sn}for(var Zn=Yt==="top"?vt:Pt-vt,tr=wn;tr>=0;tr-=1){var hr=Ke(Ae[tr]),ur=Se.get(hr);if(ur===void 0){Ht=!0;break}if(Zn-=ur,Zn<=0)break}switch(Yt){case"top":yt=Kt-vt;break;case"bottom":yt=sn-Pt+vt;break;default:{var zn=We.current.scrollTop,Bn=zn+Pt;Kt<zn?jt="top":sn>Bn&&(jt="bottom")}}yt!==null&&De(yt),yt!==Re.lastTop&&(Ht=!0)}Ht&&tt((0,Ce.Z)((0,Ce.Z)({},Re),{},{times:Re.times+1,targetAlign:jt,lastTop:yt}))}},[Re,We.current]),function(lt){if(lt==null){we();return}if(_e.Z.cancel(Le.current),typeof lt=="number")De(lt);else if(lt&&(0,ie.Z)(lt)==="object"){var Nt,Ct=lt.align;"index"in lt?Nt=lt.index:Nt=Ae.findIndex(function(Ht){return Ke(Ht)===lt.key});var vt=lt.offset,Pt=vt===void 0?0:vt;tt({times:0,index:Nt,offset:Pt,originAlign:Ct})}}}var $e=z.forwardRef(function(We,Ae){var Se=We.prefixCls,Be=We.rtl,Ke=We.scrollOffset,Ne=We.scrollRange,De=We.onStartMove,we=We.onStopMove,Le=We.onScroll,Ue=We.horizontal,Me=We.spinSize,Re=We.containerSize,tt=We.style,lt=We.thumbStyle,Nt=We.showScrollBar,Ct=z.useState(!1),vt=(0,se.Z)(Ct,2),Pt=vt[0],Ht=vt[1],jt=z.useState(null),yt=(0,se.Z)(jt,2),Yt=yt[0],Lt=yt[1],Kt=z.useState(null),sn=(0,se.Z)(Kt,2),wn=sn[0],Vt=sn[1],Rn=!Be,Gn=z.useRef(),Zn=z.useRef(),tr=z.useState(Nt),hr=(0,se.Z)(tr,2),ur=hr[0],zn=hr[1],Bn=z.useRef(),ir=function(){Nt===!0||Nt===!1||(clearTimeout(Bn.current),zn(!0),Bn.current=setTimeout(function(){zn(!1)},3e3))},Kn=Ne-Re||0,Nn=Re-Me||0,yn=z.useMemo(function(){if(Ke===0||Kn===0)return 0;var qe=Ke/Kn;return qe*Nn},[Ke,Kn,Nn]),Hn=function(st){st.stopPropagation(),st.preventDefault()},dr=z.useRef({top:yn,dragging:Pt,pageY:Yt,startTop:wn});dr.current={top:yn,dragging:Pt,pageY:Yt,startTop:wn};var Mn=function(st){Ht(!0),Lt(ut(st,Ue)),Vt(dr.current.top),De(),st.stopPropagation(),st.preventDefault()};z.useEffect(function(){var qe=function(kt){kt.preventDefault()},st=Gn.current,mt=Zn.current;return st.addEventListener("touchstart",qe,{passive:!1}),mt.addEventListener("touchstart",Mn,{passive:!1}),function(){st.removeEventListener("touchstart",qe),mt.removeEventListener("touchstart",Mn)}},[]);var Cn=z.useRef();Cn.current=Kn;var $n=z.useRef();$n.current=Nn,z.useEffect(function(){if(Pt){var qe,st=function(kt){var Ft=dr.current,qt=Ft.dragging,En=Ft.pageY,Yn=Ft.startTop;_e.Z.cancel(qe);var At=Gn.current.getBoundingClientRect(),St=Re/(Ue?At.width:At.height);if(qt){var an=(ut(kt,Ue)-En)*St,Wt=Yn;!Rn&&Ue?Wt-=an:Wt+=an;var Et=Cn.current,zt=$n.current,tn=zt?Wt/zt:0,nn=Math.ceil(tn*Et);nn=Math.max(nn,0),nn=Math.min(nn,Et),qe=(0,_e.Z)(function(){Le(nn,Ue)})}},mt=function(){Ht(!1),we()};return window.addEventListener("mousemove",st,{passive:!0}),window.addEventListener("touchmove",st,{passive:!0}),window.addEventListener("mouseup",mt,{passive:!0}),window.addEventListener("touchend",mt,{passive:!0}),function(){window.removeEventListener("mousemove",st),window.removeEventListener("touchmove",st),window.removeEventListener("mouseup",mt),window.removeEventListener("touchend",mt),_e.Z.cancel(qe)}}},[Pt]),z.useEffect(function(){return ir(),function(){clearTimeout(Bn.current)}},[Ke]),z.useImperativeHandle(Ae,function(){return{delayHidden:ir}});var Jt="".concat(Se,"-scrollbar"),Ie={position:"absolute",visibility:ur?null:"hidden"},Ze={position:"absolute",borderRadius:99,background:"var(--rc-virtual-list-scrollbar-bg, rgba(0, 0, 0, 0.5))",cursor:"pointer",userSelect:"none"};return Ue?(Object.assign(Ie,{height:8,left:0,right:0,bottom:0}),Object.assign(Ze,(0,ue.Z)({height:"100%",width:Me},Rn?"left":"right",yn))):(Object.assign(Ie,(0,ue.Z)({width:8,top:0,bottom:0},Rn?"right":"left",0)),Object.assign(Ze,{width:"100%",height:Me,top:yn})),z.createElement("div",{ref:Gn,className:ee()(Jt,(0,ue.Z)((0,ue.Z)((0,ue.Z)({},"".concat(Jt,"-horizontal"),Ue),"".concat(Jt,"-vertical"),!Ue),"".concat(Jt,"-visible"),ur)),style:(0,Ce.Z)((0,Ce.Z)({},Ie),tt),onMouseDown:Hn,onMouseMove:ir},z.createElement("div",{ref:Zn,className:ee()("".concat(Jt,"-thumb"),(0,ue.Z)({},"".concat(Jt,"-thumb-moving"),Pt)),style:(0,Ce.Z)((0,Ce.Z)({},Ze),lt),onMouseDown:Mn}))}),nt=$e,et=20;function pt(){var We=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,Ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,Se=We/Ae*We;return isNaN(Se)&&(Se=0),Se=Math.max(Se,et),Math.floor(Se)}var ct=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],Ot=[],dt={overflowY:"auto",overflowAnchor:"none"};function Rt(We,Ae){var Se=We.prefixCls,Be=Se===void 0?"rc-virtual-list":Se,Ke=We.className,Ne=We.height,De=We.itemHeight,we=We.fullHeight,Le=we===void 0?!0:we,Ue=We.style,Me=We.data,Re=We.children,tt=We.itemKey,lt=We.virtual,Nt=We.direction,Ct=We.scrollWidth,vt=We.component,Pt=vt===void 0?"div":vt,Ht=We.onScroll,jt=We.onVirtualScroll,yt=We.onVisibleChange,Yt=We.innerProps,Lt=We.extraRender,Kt=We.styles,sn=We.showScrollBar,wn=sn===void 0?"optional":sn,Vt=(0,te.Z)(We,ct),Rn=z.useCallback(function(Gt){return typeof tt=="function"?tt(Gt):Gt==null?void 0:Gt[tt]},[tt]),Gn=ot(Rn,null,null),Zn=(0,se.Z)(Gn,4),tr=Zn[0],hr=Zn[1],ur=Zn[2],zn=Zn[3],Bn=!!(lt!==!1&&Ne&&De),ir=z.useMemo(function(){return Object.values(ur.maps).reduce(function(Gt,cn){return Gt+cn},0)},[ur.id,ur.maps]),Kn=Bn&&Me&&(Math.max(De*Me.length,ir)>Ne||!!Ct),Nn=Nt==="rtl",yn=ee()(Be,(0,ue.Z)({},"".concat(Be,"-rtl"),Nn),Ke),Hn=Me||Ot,dr=(0,z.useRef)(),Mn=(0,z.useRef)(),Cn=(0,z.useRef)(),$n=(0,z.useState)(0),Jt=(0,se.Z)($n,2),Ie=Jt[0],Ze=Jt[1],qe=(0,z.useState)(0),st=(0,se.Z)(qe,2),mt=st[0],Bt=st[1],kt=(0,z.useState)(!1),Ft=(0,se.Z)(kt,2),qt=Ft[0],En=Ft[1],Yn=function(){En(!0)},At=function(){En(!1)},St={getKey:Rn};function an(Gt){Ze(function(cn){var dn;typeof Gt=="function"?dn=Gt(cn):dn=Gt;var un=jr(dn);return dr.current.scrollTop=un,un})}var Wt=(0,z.useRef)({start:0,end:Hn.length}),Et=(0,z.useRef)(),zt=ge(Hn,Rn),tn=(0,se.Z)(zt,1),nn=tn[0];Et.current=nn;var gn=z.useMemo(function(){if(!Bn)return{scrollHeight:void 0,start:0,end:Hn.length-1,offset:void 0};if(!Kn){var Gt;return{scrollHeight:((Gt=Mn.current)===null||Gt===void 0?void 0:Gt.offsetHeight)||0,start:0,end:Hn.length-1,offset:void 0}}for(var cn=0,dn,un,mn,ln=Hn.length,fn=0;fn<ln;fn+=1){var vn=Hn[fn],Ln=Rn(vn),Jn=ur.get(Ln),Xn=cn+(Jn===void 0?De:Jn);Xn>=Ie&&dn===void 0&&(dn=fn,un=cn),Xn>Ie+Ne&&mn===void 0&&(mn=fn),cn=Xn}return dn===void 0&&(dn=0,un=0,mn=Math.ceil(Ne/De)),mn===void 0&&(mn=Hn.length-1),mn=Math.min(mn+1,Hn.length-1),{scrollHeight:cn,start:dn,end:mn,offset:un}},[Kn,Bn,Ie,Hn,zn,Ne]),Sn=gn.scrollHeight,Tn=gn.start,Tt=gn.end,jn=gn.offset;Wt.current.start=Tn,Wt.current.end=Tt,z.useLayoutEffect(function(){var Gt=ur.getRecord();if(Gt.size===1){var cn=Array.from(Gt.keys())[0],dn=Gt.get(cn),un=Hn[Tn];if(un&&dn===void 0){var mn=Rn(un);if(mn===cn){var ln=ur.get(cn),fn=ln-De;an(function(vn){return vn+fn})}}}ur.resetRecord()},[Sn]);var bn=z.useState({width:0,height:Ne}),Fn=(0,se.Z)(bn,2),Un=Fn[0],rr=Fn[1],pr=function(cn){rr({width:cn.offsetWidth,height:cn.offsetHeight})},Rr=(0,z.useRef)(),wr=(0,z.useRef)(),Lr=z.useMemo(function(){return pt(Un.width,Ct)},[Un.width,Ct]),Vr=z.useMemo(function(){return pt(Un.height,Sn)},[Un.height,Sn]),xr=Sn-Ne,Ir=(0,z.useRef)(xr);Ir.current=xr;function jr(Gt){var cn=Gt;return Number.isNaN(Ir.current)||(cn=Math.min(cn,Ir.current)),cn=Math.max(cn,0),cn}var ti=Ie<=0,di=Ie>=xr,wi=mt<=0,xi=mt>=Ct,ai=ke(ti,di,wi,xi),Di=function(){return{x:Nn?-mt:mt,y:Ie}},_i=(0,z.useRef)(Di()),or=(0,E.zX)(function(Gt){if(jt){var cn=(0,Ce.Z)((0,Ce.Z)({},Di()),Gt);(_i.current.x!==cn.x||_i.current.y!==cn.y)&&(jt(cn),_i.current=cn)}});function br(Gt,cn){var dn=Gt;cn?((0,x.flushSync)(function(){Bt(dn)}),or()):an(dn)}function Ar(Gt){var cn=Gt.currentTarget.scrollTop;cn!==Ie&&an(cn),Ht==null||Ht(Gt),or()}var qr=function(cn){var dn=cn,un=Ct?Ct-Un.width:0;return dn=Math.max(dn,0),dn=Math.min(dn,un),dn},$r=(0,E.zX)(function(Gt,cn){cn?((0,x.flushSync)(function(){Bt(function(dn){var un=dn+(Nn?-Gt:Gt);return qr(un)})}),or()):an(function(dn){var un=dn+Gt;return un})}),bi=Te(Bn,ti,di,wi,xi,!!Ct,$r),Wi=(0,se.Z)(bi,2),Dt=Wi[0],$t=Wi[1];rt(Bn,dr,function(Gt,cn,dn,un){var mn=un;return ai(Gt,cn,dn)?!1:!mn||!mn._virtualHandled?(mn&&(mn._virtualHandled=!0),Dt({preventDefault:function(){},deltaX:Gt?cn:0,deltaY:Gt?0:cn}),!0):!1}),Ge(Kn,dr,function(Gt){an(function(cn){return cn+Gt})}),(0,b.Z)(function(){function Gt(dn){var un=ti&&dn.detail<0,mn=di&&dn.detail>0;Bn&&!un&&!mn&&dn.preventDefault()}var cn=dr.current;return cn.addEventListener("wheel",Dt,{passive:!1}),cn.addEventListener("DOMMouseScroll",$t,{passive:!0}),cn.addEventListener("MozMousePixelScroll",Gt,{passive:!1}),function(){cn.removeEventListener("wheel",Dt),cn.removeEventListener("DOMMouseScroll",$t),cn.removeEventListener("MozMousePixelScroll",Gt)}},[Bn,ti,di]),(0,b.Z)(function(){if(Ct){var Gt=qr(mt);Bt(Gt),or({x:Gt})}},[Un.width,Ct]);var Zt=function(){var cn,dn;(cn=Rr.current)===null||cn===void 0||cn.delayHidden(),(dn=wr.current)===null||dn===void 0||dn.delayHidden()},en=Ve(dr,Hn,ur,De,Rn,function(){return hr(!0)},an,Zt);z.useImperativeHandle(Ae,function(){return{nativeElement:Cn.current,getScrollInfo:Di,scrollTo:function(cn){function dn(un){return un&&(0,ie.Z)(un)==="object"&&("left"in un||"top"in un)}dn(cn)?(cn.left!==void 0&&Bt(qr(cn.left)),en(cn.top)):en(cn)}}}),(0,b.Z)(function(){if(yt){var Gt=Hn.slice(Tn,Tt+1);yt(Gt,Hn)}},[Tn,Tt,Hn]);var on=Ee(Hn,Rn,ur,De),hn=Lt==null?void 0:Lt({start:Tn,end:Tt,virtual:Kn,offsetX:mt,offsetY:jn,rtl:Nn,getSize:on}),Pn=ve(Hn,Tn,Tt,Ct,mt,tr,Re,St),kn=null;Ne&&(kn=(0,Ce.Z)((0,ue.Z)({},Le?"height":"maxHeight",Ne),dt),Bn&&(kn.overflowY="hidden",Ct&&(kn.overflowX="hidden"),qt&&(kn.pointerEvents="none")));var _n={};return Nn&&(_n.dir="rtl"),z.createElement("div",(0,ce.Z)({ref:Cn,style:(0,Ce.Z)((0,Ce.Z)({},Ue),{},{position:"relative"}),className:yn},_n,Vt),z.createElement(ne.Z,{onResize:pr},z.createElement(Pt,{className:"".concat(Be,"-holder"),style:kn,ref:dr,onScroll:Ar,onMouseEnter:Zt},z.createElement(ae,{prefixCls:Be,height:Sn,offsetX:mt,offsetY:jn,scrollWidth:Ct,onInnerResize:hr,ref:Mn,innerProps:Yt,rtl:Nn,extra:hn},Pn))),Kn&&Sn>Ne&&z.createElement(nt,{ref:Rr,prefixCls:Be,scrollOffset:Ie,scrollRange:Sn,rtl:Nn,onScroll:br,onStartMove:Yn,onStopMove:At,spinSize:Vr,containerSize:Un.height,style:Kt==null?void 0:Kt.verticalScrollBar,thumbStyle:Kt==null?void 0:Kt.verticalScrollBarThumb,showScrollBar:wn}),Kn&&Ct>Un.width&&z.createElement(nt,{ref:wr,prefixCls:Be,scrollOffset:mt,scrollRange:Ct,rtl:Nn,onScroll:br,onStartMove:Yn,onStopMove:At,spinSize:Lr,containerSize:Un.width,horizontal:!0,style:Kt==null?void 0:Kt.horizontalScrollBar,thumbStyle:Kt==null?void 0:Kt.horizontalScrollBarThumb,showScrollBar:wn}))}var xt=z.forwardRef(Rt);xt.displayName="List";var gt=xt,_t=gt},7062:function(Xt,Mt,be){var ce=be(19637),ie=be(97573),Ce=[be(96627)];Xt.exports=ce.createStore(ie,Ce)},96627:function(Xt,Mt,be){Xt.exports=ce;function ce(){return be(42424),{}}},42424:function(){typeof JSON!="object"&&(JSON={}),function(){"use strict";var rx_one=/^[\],:{}\s]*$/,rx_two=/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,rx_three=/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,rx_four=/(?:^|:|,)(?:\s*\[)+/g,rx_escapable=/[\\"\u0000-\u001f\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,rx_dangerous=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g;function f(Xt){return Xt<10?"0"+Xt:Xt}function this_value(){return this.valueOf()}typeof Date.prototype.toJSON!="function"&&(Date.prototype.toJSON=function(){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null},Boolean.prototype.toJSON=this_value,Number.prototype.toJSON=this_value,String.prototype.toJSON=this_value);var gap,indent,meta,rep;function quote(Xt){return rx_escapable.lastIndex=0,rx_escapable.test(Xt)?'"'+Xt.replace(rx_escapable,function(Mt){var be=meta[Mt];return typeof be=="string"?be:"\\u"+("0000"+Mt.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+Xt+'"'}function str(Xt,Mt){var be,ce,ie,Ce,ue=gap,se,te=Mt[Xt];switch(te&&typeof te=="object"&&typeof te.toJSON=="function"&&(te=te.toJSON(Xt)),typeof rep=="function"&&(te=rep.call(Mt,Xt,te)),typeof te){case"string":return quote(te);case"number":return isFinite(te)?String(te):"null";case"boolean":case"null":return String(te);case"object":if(!te)return"null";if(gap+=indent,se=[],Object.prototype.toString.apply(te)==="[object Array]"){for(Ce=te.length,be=0;be<Ce;be+=1)se[be]=str(be,te)||"null";return ie=se.length===0?"[]":gap?`[
|
|
|
`+gap+se.join(`,
|
|
|
`+gap)+`
|
|
|
`+ue+"]":"["+se.join(",")+"]",gap=ue,ie}if(rep&&typeof rep=="object")for(Ce=rep.length,be=0;be<Ce;be+=1)typeof rep[be]=="string"&&(ce=rep[be],ie=str(ce,te),ie&&se.push(quote(ce)+(gap?": ":":")+ie));else for(ce in te)Object.prototype.hasOwnProperty.call(te,ce)&&(ie=str(ce,te),ie&&se.push(quote(ce)+(gap?": ":":")+ie));return ie=se.length===0?"{}":gap?`{
|
|
|
`+gap+se.join(`,
|
|
|
`+gap)+`
|
|
|
`+ue+"}":"{"+se.join(",")+"}",gap=ue,ie}}typeof JSON.stringify!="function"&&(meta={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},JSON.stringify=function(Xt,Mt,be){var ce;if(gap="",indent="",typeof be=="number")for(ce=0;ce<be;ce+=1)indent+=" ";else typeof be=="string"&&(indent=be);if(rep=Mt,Mt&&typeof Mt!="function"&&(typeof Mt!="object"||typeof Mt.length!="number"))throw new Error("JSON.stringify");return str("",{"":Xt})}),typeof JSON.parse!="function"&&(JSON.parse=function(text,reviver){var j;function walk(Xt,Mt){var be,ce,ie=Xt[Mt];if(ie&&typeof ie=="object")for(be in ie)Object.prototype.hasOwnProperty.call(ie,be)&&(ce=walk(ie,be),ce!==void 0?ie[be]=ce:delete ie[be]);return reviver.call(Xt,Mt,ie)}if(text=String(text),rx_dangerous.lastIndex=0,rx_dangerous.test(text)&&(text=text.replace(rx_dangerous,function(Xt){return"\\u"+("0000"+Xt.charCodeAt(0).toString(16)).slice(-4)})),rx_one.test(text.replace(rx_two,"@").replace(rx_three,"]").replace(rx_four,"")))return j=eval("("+text+")"),typeof reviver=="function"?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}()},19637:function(Xt,Mt,be){var ce=be(67039),ie=ce.slice,Ce=ce.pluck,ue=ce.each,se=ce.bind,te=ce.create,le=ce.isList,ee=ce.isFunction,ne=ce.isObject;Xt.exports={createStore:z};var E={version:"2.0.12",enabled:!1,get:function(x,re){var ae=this.storage.read(this._namespacePrefix+x);return this._deserialize(ae,re)},set:function(x,re){return re===void 0?this.remove(x):(this.storage.write(this._namespacePrefix+x,this._serialize(re)),re)},remove:function(x){this.storage.remove(this._namespacePrefix+x)},each:function(x){var re=this;this.storage.each(function(ae,oe){x.call(re,re._deserialize(ae),(oe||"").replace(re._namespaceRegexp,""))})},clearAll:function(){this.storage.clearAll()},hasNamespace:function(x){return this._namespacePrefix=="__storejs_"+x+"_"},createStore:function(){return z.apply(this,arguments)},addPlugin:function(x){this._addPlugin(x)},namespace:function(x){return z(this.storage,this.plugins,x)}};function b(){var x=typeof console=="undefined"?null:console;if(x){var re=x.warn?x.warn:x.log;re.apply(x,arguments)}}function z(x,re,ae){ae||(ae=""),x&&!le(x)&&(x=[x]),re&&!le(re)&&(re=[re]);var oe=ae?"__storejs_"+ae+"_":"",ve=ae?new RegExp("^"+oe):null,ye=/^[a-zA-Z0-9_\-]*$/;if(!ye.test(ae))throw new Error("store.js namespaces can only have alphanumerics + underscores and dashes");var me={_namespacePrefix:oe,_namespaceRegexp:ve,_testStorage:function(_e){try{var he="__storejs__test__";_e.write(he,he);var pe=_e.read(he)===he;return _e.remove(he),pe}catch(ke){return!1}},_assignPluginFnProp:function(_e,he){var pe=this[he];this[he]=function(){var Te=ie(arguments,0),Ee=this;function Oe(){if(pe)return ue(arguments,function(Pe,Qe){Te[Qe]=Pe}),pe.apply(Ee,Te)}var je=[Oe].concat(Te);return _e.apply(Ee,je)}},_serialize:function(_e){return JSON.stringify(_e)},_deserialize:function(_e,he){if(!_e)return he;var pe="";try{pe=JSON.parse(_e)}catch(ke){pe=_e}return pe!==void 0?pe:he},_addStorage:function(_e){this.enabled||this._testStorage(_e)&&(this.storage=_e,this.enabled=!0)},_addPlugin:function(_e){var he=this;if(le(_e)){ue(_e,function(Te){he._addPlugin(Te)});return}var pe=Ce(this.plugins,function(Te){return _e===Te});if(!pe){if(this.plugins.push(_e),!ee(_e))throw new Error("Plugins must be function values that return objects");var ke=_e.call(this);if(!ne(ke))throw new Error("Plugins must return an object of function properties");ue(ke,function(Te,Ee){if(!ee(Te))throw new Error("Bad plugin property: "+Ee+" from plugin "+_e.name+". Plugins should only return functions.");he._assignPluginFnProp(Te,Ee)})}},addStorage:function(_e){b("store.addStorage(storage) is deprecated. Use createStore([storages])"),this._addStorage(_e)}},ge=te(me,E,{plugins:[]});return ge.raw={},ue(ge,function(_e,he){ee(_e)&&(ge.raw[he]=se(ge,_e))}),ue(x,function(_e){ge._addStorage(_e)}),ue(re,function(_e){ge._addPlugin(_e)}),ge}},67039:function(Xt,Mt,be){var ce=se(),ie=te(),Ce=le(),ue=typeof window!="undefined"?window:be.g;Xt.exports={assign:ce,create:ie,trim:Ce,bind:ee,slice:ne,each:E,map:b,pluck:z,isList:x,isFunction:re,isObject:ae,Global:ue};function se(){return Object.assign?Object.assign:function(ve,ye,me,ge){for(var _e=1;_e<arguments.length;_e++)E(Object(arguments[_e]),function(he,pe){ve[pe]=he});return ve}}function te(){if(Object.create)return function(ye,me,ge,_e){var he=ne(arguments,1);return ce.apply(this,[Object.create(ye)].concat(he))};{let ve=function(){};var oe=ve;return function(me,ge,_e,he){var pe=ne(arguments,1);return ve.prototype=me,ce.apply(this,[new ve].concat(pe))}}}function le(){return String.prototype.trim?function(ve){return String.prototype.trim.call(ve)}:function(ve){return ve.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}}function ee(oe,ve){return function(){return ve.apply(oe,Array.prototype.slice.call(arguments,0))}}function ne(oe,ve){return Array.prototype.slice.call(oe,ve||0)}function E(oe,ve){z(oe,function(ye,me){return ve(ye,me),!1})}function b(oe,ve){var ye=x(oe)?[]:{};return z(oe,function(me,ge){return ye[ge]=ve(me,ge),!1}),ye}function z(oe,ve){if(x(oe)){for(var ye=0;ye<oe.length;ye++)if(ve(oe[ye],ye))return oe[ye]}else for(var me in oe)if(oe.hasOwnProperty(me)&&ve(oe[me],me))return oe[me]}function x(oe){return oe!=null&&typeof oe!="function"&&typeof oe.length=="number"}function re(oe){return oe&&{}.toString.call(oe)==="[object Function]"}function ae(oe){return oe&&{}.toString.call(oe)==="[object Object]"}},97573:function(Xt,Mt,be){Xt.exports=[be(52496),be(16436),be(76673),be(35701),be(65578),be(65300)]},35701:function(Xt,Mt,be){var ce=be(67039),ie=ce.Global,Ce=ce.trim;Xt.exports={name:"cookieStorage",read:se,write:le,each:te,remove:ee,clearAll:ne};var ue=ie.document;function se(b){if(!b||!E(b))return null;var z="(?:^|.*;\\s*)"+escape(b).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*((?:[^;](?!;))*[^;]?).*";return unescape(ue.cookie.replace(new RegExp(z),"$1"))}function te(b){for(var z=ue.cookie.split(/; ?/g),x=z.length-1;x>=0;x--)if(Ce(z[x])){var re=z[x].split("="),ae=unescape(re[0]),oe=unescape(re[1]);b(oe,ae)}}function le(b,z){b&&(ue.cookie=escape(b)+"="+escape(z)+"; expires=Tue, 19 Jan 2038 03:14:07 GMT; path=/")}function ee(b){!b||!E(b)||(ue.cookie=escape(b)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/")}function ne(){te(function(b,z){ee(z)})}function E(b){return new RegExp("(?:^|;\\s*)"+escape(b).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=").test(ue.cookie)}},52496:function(Xt,Mt,be){var ce=be(67039),ie=ce.Global;Xt.exports={name:"localStorage",read:ue,write:se,each:te,remove:le,clearAll:ee};function Ce(){return ie.localStorage}function ue(ne){return Ce().getItem(ne)}function se(ne,E){return Ce().setItem(ne,E)}function te(ne){for(var E=Ce().length-1;E>=0;E--){var b=Ce().key(E);ne(ue(b),b)}}function le(ne){return Ce().removeItem(ne)}function ee(){return Ce().clear()}},65300:function(Xt){Xt.exports={name:"memoryStorage",read:be,write:ce,each:ie,remove:Ce,clearAll:ue};var Mt={};function be(se){return Mt[se]}function ce(se,te){Mt[se]=te}function ie(se){for(var te in Mt)Mt.hasOwnProperty(te)&&se(Mt[te],te)}function Ce(se){delete Mt[se]}function ue(se){Mt={}}},16436:function(Xt,Mt,be){var ce=be(67039),ie=ce.Global;Xt.exports={name:"oldFF-globalStorage",read:ue,write:se,each:te,remove:le,clearAll:ee};var Ce=ie.globalStorage;function ue(ne){return Ce[ne]}function se(ne,E){Ce[ne]=E}function te(ne){for(var E=Ce.length-1;E>=0;E--){var b=Ce.key(E);ne(Ce[b],b)}}function le(ne){return Ce.removeItem(ne)}function ee(){te(function(ne,E){delete Ce[ne]})}},76673:function(Xt,Mt,be){var ce=be(67039),ie=ce.Global;Xt.exports={name:"oldIE-userDataStorage",write:le,read:ee,each:ne,remove:E,clearAll:b};var Ce="storejs",ue=ie.document,se=re(),te=(ie.navigator?ie.navigator.userAgent:"").match(/ (MSIE 8|MSIE 9|MSIE 10)\./);function le(ae,oe){if(!te){var ve=x(ae);se(function(ye){ye.setAttribute(ve,oe),ye.save(Ce)})}}function ee(ae){if(!te){var oe=x(ae),ve=null;return se(function(ye){ve=ye.getAttribute(oe)}),ve}}function ne(ae){se(function(oe){for(var ve=oe.XMLDocument.documentElement.attributes,ye=ve.length-1;ye>=0;ye--){var me=ve[ye];ae(oe.getAttribute(me.name),me.name)}})}function E(ae){var oe=x(ae);se(function(ve){ve.removeAttribute(oe),ve.save(Ce)})}function b(){se(function(ae){var oe=ae.XMLDocument.documentElement.attributes;ae.load(Ce);for(var ve=oe.length-1;ve>=0;ve--)ae.removeAttribute(oe[ve].name);ae.save(Ce)})}var z=new RegExp("[!\"#$%&'()*+,/\\\\:;<=>?@[\\]^`{|}~]","g");function x(ae){return ae.replace(/^\d/,"___$&").replace(z,"___")}function re(){if(!ue||!ue.documentElement||!ue.documentElement.addBehavior)return null;var ae="script",oe,ve,ye;try{ve=new ActiveXObject("htmlfile"),ve.open(),ve.write("<"+ae+">document.w=window</"+ae+'><iframe src="/favicon.ico"></iframe>'),ve.close(),oe=ve.w.frames[0].document,ye=oe.createElement("div")}catch(me){ye=ue.createElement("div"),oe=ue.body}return function(me){var ge=[].slice.call(arguments,0);ge.unshift(ye),oe.appendChild(ye),ye.addBehavior("#default#userData"),ye.load(Ce),me.apply(this,ge),oe.removeChild(ye)}}},65578:function(Xt,Mt,be){var ce=be(67039),ie=ce.Global;Xt.exports={name:"sessionStorage",read:ue,write:se,each:te,remove:le,clearAll:ee};function Ce(){return ie.sessionStorage}function ue(ne){return Ce().getItem(ne)}function se(ne,E){return Ce().setItem(ne,E)}function te(ne){for(var E=Ce().length-1;E>=0;E--){var b=Ce().key(E);ne(ue(b),b)}}function le(ne){return Ce().removeItem(ne)}function ee(){return Ce().clear()}},82059:function(Xt){var Mt=arguments[3],be=arguments[4],ce=arguments[5],ie=JSON.stringify;Xt.exports=function(Ce,ue){for(var se,te=Object.keys(ce),le=0,ee=te.length;le<ee;le++){var ne=te[le],E=ce[ne].exports;if(E===Ce||E&&E.default===Ce){se=ne;break}}if(!se){se=Math.floor(Math.pow(16,8)*Math.random()).toString(16);for(var b={},le=0,ee=te.length;le<ee;le++){var ne=te[le];b[ne]=ne}be[se]=["function(require,module,exports){"+Ce+"(self); }",b]}var z=Math.floor(Math.pow(16,8)*Math.random()).toString(16),x={};x[se]=se,be[z]=["function(require,module,exports){var f = require("+ie(se)+");(f.default ? f.default : f)(self);}",x];var re={};ae(z);function ae(_e){re[_e]=!0;for(var he in be[_e][1]){var pe=be[_e][1][he];re[pe]||ae(pe)}}var oe="("+Mt+")({"+Object.keys(re).map(function(_e){return ie(_e)+":["+be[_e][0]+","+ie(be[_e][1])+"]"}).join(",")+"},{},["+ie(z)+"])",ve=window.URL||window.webkitURL||window.mozURL||window.msURL,ye=new Blob([oe],{type:"text/javascript"});if(ue&&ue.bare)return ye;var me=ve.createObjectURL(ye),ge=new Worker(me);return ge.objectURL=me,ge}},34376:function(Xt){(function(Mt,be){if(1)Xt.exports=be();else var ce,ie})(window,function(){return function(Mt){var be={};function ce(ie){if(be[ie])return be[ie].exports;var Ce=be[ie]={i:ie,l:!1,exports:{}};return Mt[ie].call(Ce.exports,Ce,Ce.exports,ce),Ce.l=!0,Ce.exports}return ce.m=Mt,ce.c=be,ce.d=function(ie,Ce,ue){ce.o(ie,Ce)||Object.defineProperty(ie,Ce,{enumerable:!0,get:ue})},ce.r=function(ie){typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(ie,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(ie,"__esModule",{value:!0})},ce.t=function(ie,Ce){if(1&Ce&&(ie=ce(ie)),8&Ce||4&Ce&&typeof ie=="object"&&ie&&ie.__esModule)return ie;var ue=Object.create(null);if(ce.r(ue),Object.defineProperty(ue,"default",{enumerable:!0,value:ie}),2&Ce&&typeof ie!="string")for(var se in ie)ce.d(ue,se,function(te){return ie[te]}.bind(null,se));return ue},ce.n=function(ie){var Ce=ie&&ie.__esModule?function(){return ie.default}:function(){return ie};return ce.d(Ce,"a",Ce),Ce},ce.o=function(ie,Ce){return Object.prototype.hasOwnProperty.call(ie,Ce)},ce.p="",ce(ce.s=34)}([function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.forwardEvent=be.EventEmitter=void 0;var ie=function(){function Ce(){this._listeners=[],this._disposed=!1}return Object.defineProperty(Ce.prototype,"event",{get:function(){var ue=this;return this._event||(this._event=function(se){return ue._listeners.push(se),{dispose:function(){if(!ue._disposed){for(var te=0;te<ue._listeners.length;te++)if(ue._listeners[te]===se)return void ue._listeners.splice(te,1)}}}}),this._event},enumerable:!1,configurable:!0}),Ce.prototype.fire=function(ue,se){for(var te=[],le=0;le<this._listeners.length;le++)te.push(this._listeners[le]);for(le=0;le<te.length;le++)te[le].call(void 0,ue,se)},Ce.prototype.dispose=function(){this._listeners&&(this._listeners.length=0),this._disposed=!0},Ce}();be.EventEmitter=ie,be.forwardEvent=function(Ce,ue){return Ce(function(se){return ue.fire(se)})}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.IUnicodeService=be.IOptionsService=be.ILogService=be.IInstantiationService=be.IDirtyRowService=be.ICharsetService=be.ICoreService=be.ICoreMouseService=be.IBufferService=void 0;var ie=ce(14);be.IBufferService=ie.createDecorator("BufferService"),be.ICoreMouseService=ie.createDecorator("CoreMouseService"),be.ICoreService=ie.createDecorator("CoreService"),be.ICharsetService=ie.createDecorator("CharsetService"),be.IDirtyRowService=ie.createDecorator("DirtyRowService"),be.IInstantiationService=ie.createDecorator("InstantiationService"),be.ILogService=ie.createDecorator("LogService"),be.IOptionsService=ie.createDecorator("OptionsService"),be.IUnicodeService=ie.createDecorator("UnicodeService")},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.getDisposeArrayDisposable=be.disposeArray=be.Disposable=void 0;var ie=function(){function ue(){this._disposables=[],this._isDisposed=!1}return ue.prototype.dispose=function(){this._isDisposed=!0;for(var se=0,te=this._disposables;se<te.length;se++)te[se].dispose();this._disposables.length=0},ue.prototype.register=function(se){return this._disposables.push(se),se},ue.prototype.unregister=function(se){var te=this._disposables.indexOf(se);te!==-1&&this._disposables.splice(te,1)},ue}();function Ce(ue){for(var se=0,te=ue;se<te.length;se++)te[se].dispose();ue.length=0}be.Disposable=ie,be.disposeArray=Ce,be.getDisposeArrayDisposable=function(ue){return{dispose:function(){return Ce(ue)}}}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.WHITESPACE_CELL_CODE=be.WHITESPACE_CELL_WIDTH=be.WHITESPACE_CELL_CHAR=be.NULL_CELL_CODE=be.NULL_CELL_WIDTH=be.NULL_CELL_CHAR=be.CHAR_DATA_CODE_INDEX=be.CHAR_DATA_WIDTH_INDEX=be.CHAR_DATA_CHAR_INDEX=be.CHAR_DATA_ATTR_INDEX=be.DEFAULT_ATTR=be.DEFAULT_COLOR=void 0,be.DEFAULT_COLOR=256,be.DEFAULT_ATTR=256|be.DEFAULT_COLOR<<9,be.CHAR_DATA_ATTR_INDEX=0,be.CHAR_DATA_CHAR_INDEX=1,be.CHAR_DATA_WIDTH_INDEX=2,be.CHAR_DATA_CODE_INDEX=3,be.NULL_CELL_CHAR="",be.NULL_CELL_WIDTH=1,be.NULL_CELL_CODE=0,be.WHITESPACE_CELL_CHAR=" ",be.WHITESPACE_CELL_WIDTH=1,be.WHITESPACE_CELL_CODE=32},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ee,ne){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(E,b){E.__proto__=b}||function(E,b){for(var z in b)b.hasOwnProperty(z)&&(E[z]=b[z])})(ee,ne)},function(ee,ne){function E(){this.constructor=ee}ie(ee,ne),ee.prototype=ne===null?Object.create(ne):(E.prototype=ne.prototype,new E)});Object.defineProperty(be,"__esModule",{value:!0}),be.CellData=void 0;var ue=ce(8),se=ce(3),te=ce(6),le=function(ee){function ne(){var E=ee!==null&&ee.apply(this,arguments)||this;return E.content=0,E.fg=0,E.bg=0,E.extended=new te.ExtendedAttrs,E.combinedData="",E}return Ce(ne,ee),ne.fromCharData=function(E){var b=new ne;return b.setFromCharData(E),b},ne.prototype.isCombined=function(){return 2097152&this.content},ne.prototype.getWidth=function(){return this.content>>22},ne.prototype.getChars=function(){return 2097152&this.content?this.combinedData:2097151&this.content?ue.stringFromCodePoint(2097151&this.content):""},ne.prototype.getCode=function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content},ne.prototype.setFromCharData=function(E){this.fg=E[se.CHAR_DATA_ATTR_INDEX],this.bg=0;var b=!1;if(E[se.CHAR_DATA_CHAR_INDEX].length>2)b=!0;else if(E[se.CHAR_DATA_CHAR_INDEX].length===2){var z=E[se.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=z&&z<=56319){var x=E[se.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=x&&x<=57343?this.content=1024*(z-55296)+x-56320+65536|E[se.CHAR_DATA_WIDTH_INDEX]<<22:b=!0}else b=!0}else this.content=E[se.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|E[se.CHAR_DATA_WIDTH_INDEX]<<22;b&&(this.combinedData=E[se.CHAR_DATA_CHAR_INDEX],this.content=2097152|E[se.CHAR_DATA_WIDTH_INDEX]<<22)},ne.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},ne}(te.AttributeData);be.CellData=le},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.ISoundService=be.ISelectionService=be.IRenderService=be.IMouseService=be.ICoreBrowserService=be.ICharSizeService=void 0;var ie=ce(14);be.ICharSizeService=ie.createDecorator("CharSizeService"),be.ICoreBrowserService=ie.createDecorator("CoreBrowserService"),be.IMouseService=ie.createDecorator("MouseService"),be.IRenderService=ie.createDecorator("RenderService"),be.ISelectionService=ie.createDecorator("SelectionService"),be.ISoundService=ie.createDecorator("SoundService")},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.ExtendedAttrs=be.AttributeData=void 0;var ie=function(){function ue(){this.fg=0,this.bg=0,this.extended=new Ce}return ue.toColorRGB=function(se){return[se>>>16&255,se>>>8&255,255&se]},ue.fromColorRGB=function(se){return(255&se[0])<<16|(255&se[1])<<8|255&se[2]},ue.prototype.clone=function(){var se=new ue;return se.fg=this.fg,se.bg=this.bg,se.extended=this.extended.clone(),se},ue.prototype.isInverse=function(){return 67108864&this.fg},ue.prototype.isBold=function(){return 134217728&this.fg},ue.prototype.isUnderline=function(){return 268435456&this.fg},ue.prototype.isBlink=function(){return 536870912&this.fg},ue.prototype.isInvisible=function(){return 1073741824&this.fg},ue.prototype.isItalic=function(){return 67108864&this.bg},ue.prototype.isDim=function(){return 134217728&this.bg},ue.prototype.getFgColorMode=function(){return 50331648&this.fg},ue.prototype.getBgColorMode=function(){return 50331648&this.bg},ue.prototype.isFgRGB=function(){return(50331648&this.fg)==50331648},ue.prototype.isBgRGB=function(){return(50331648&this.bg)==50331648},ue.prototype.isFgPalette=function(){return(50331648&this.fg)==16777216||(50331648&this.fg)==33554432},ue.prototype.isBgPalette=function(){return(50331648&this.bg)==16777216||(50331648&this.bg)==33554432},ue.prototype.isFgDefault=function(){return(50331648&this.fg)==0},ue.prototype.isBgDefault=function(){return(50331648&this.bg)==0},ue.prototype.isAttributeDefault=function(){return this.fg===0&&this.bg===0},ue.prototype.getFgColor=function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}},ue.prototype.getBgColor=function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}},ue.prototype.hasExtendedAttrs=function(){return 268435456&this.bg},ue.prototype.updateExtended=function(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456},ue.prototype.getUnderlineColor=function(){if(268435456&this.bg&&~this.extended.underlineColor)switch(50331648&this.extended.underlineColor){case 16777216:case 33554432:return 255&this.extended.underlineColor;case 50331648:return 16777215&this.extended.underlineColor;default:return this.getFgColor()}return this.getFgColor()},ue.prototype.getUnderlineColorMode=function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648&this.extended.underlineColor:this.getFgColorMode()},ue.prototype.isUnderlineColorRGB=function(){return 268435456&this.bg&&~this.extended.underlineColor?(50331648&this.extended.underlineColor)==50331648:this.isFgRGB()},ue.prototype.isUnderlineColorPalette=function(){return 268435456&this.bg&&~this.extended.underlineColor?(50331648&this.extended.underlineColor)==16777216||(50331648&this.extended.underlineColor)==33554432:this.isFgPalette()},ue.prototype.isUnderlineColorDefault=function(){return 268435456&this.bg&&~this.extended.underlineColor?(50331648&this.extended.underlineColor)==0:this.isFgDefault()},ue.prototype.getUnderlineStyle=function(){return 268435456&this.fg?268435456&this.bg?this.extended.underlineStyle:1:0},ue}();be.AttributeData=ie;var Ce=function(){function ue(se,te){se===void 0&&(se=0),te===void 0&&(te=-1),this.underlineStyle=se,this.underlineColor=te}return ue.prototype.clone=function(){return new ue(this.underlineStyle,this.underlineColor)},ue.prototype.isEmpty=function(){return this.underlineStyle===0},ue}();be.ExtendedAttrs=Ce},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.addDisposableDomListener=void 0,be.addDisposableDomListener=function(ie,Ce,ue,se){ie.addEventListener(Ce,ue,se);var te=!1;return{dispose:function(){te||(te=!0,ie.removeEventListener(Ce,ue,se))}}}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.Utf8ToUtf32=be.StringToUtf32=be.utf32ToString=be.stringFromCodePoint=void 0,be.stringFromCodePoint=function(ue){return ue>65535?(ue-=65536,String.fromCharCode(55296+(ue>>10))+String.fromCharCode(ue%1024+56320)):String.fromCharCode(ue)},be.utf32ToString=function(ue,se,te){se===void 0&&(se=0),te===void 0&&(te=ue.length);for(var le="",ee=se;ee<te;++ee){var ne=ue[ee];ne>65535?(ne-=65536,le+=String.fromCharCode(55296+(ne>>10))+String.fromCharCode(ne%1024+56320)):le+=String.fromCharCode(ne)}return le};var ie=function(){function ue(){this._interim=0}return ue.prototype.clear=function(){this._interim=0},ue.prototype.decode=function(se,te){var le=se.length;if(!le)return 0;var ee=0,ne=0;this._interim&&(56320<=(z=se.charCodeAt(ne++))&&z<=57343?te[ee++]=1024*(this._interim-55296)+z-56320+65536:(te[ee++]=this._interim,te[ee++]=z),this._interim=0);for(var E=ne;E<le;++E){var b=se.charCodeAt(E);if(55296<=b&&b<=56319){if(++E>=le)return this._interim=b,ee;var z;56320<=(z=se.charCodeAt(E))&&z<=57343?te[ee++]=1024*(b-55296)+z-56320+65536:(te[ee++]=b,te[ee++]=z)}else te[ee++]=b}return ee},ue}();be.StringToUtf32=ie;var Ce=function(){function ue(){this.interim=new Uint8Array(3)}return ue.prototype.clear=function(){this.interim.fill(0)},ue.prototype.decode=function(se,te){var le=se.length;if(!le)return 0;var ee,ne,E,b,z=0,x=0,re=0;if(this.interim[0]){var ae=!1,oe=this.interim[0];oe&=(224&oe)==192?31:(240&oe)==224?15:7;for(var ve=0,ye=void 0;(ye=63&this.interim[++ve])&&ve<4;)oe<<=6,oe|=ye;for(var me=(224&this.interim[0])==192?2:(240&this.interim[0])==224?3:4,ge=me-ve;re<ge;){if(re>=le)return 0;if((192&(ye=se[re++]))!=128){re--,ae=!0;break}this.interim[ve++]=ye,oe<<=6,oe|=63&ye}ae||(me===2?oe<128?re--:te[z++]=oe:me===3?oe<2048||oe>=55296&&oe<=57343||(te[z++]=oe):oe<65536||oe>1114111||(te[z++]=oe)),this.interim.fill(0)}for(var _e=le-4,he=re;he<le;){for(;!(!(he<_e)||128&(ee=se[he])||128&(ne=se[he+1])||128&(E=se[he+2])||128&(b=se[he+3]));)te[z++]=ee,te[z++]=ne,te[z++]=E,te[z++]=b,he+=4;if((ee=se[he++])<128)te[z++]=ee;else if((224&ee)==192){if(he>=le)return this.interim[0]=ee,z;if((192&(ne=se[he++]))!=128){he--;continue}if((x=(31&ee)<<6|63&ne)<128){he--;continue}te[z++]=x}else if((240&ee)==224){if(he>=le)return this.interim[0]=ee,z;if((192&(ne=se[he++]))!=128){he--;continue}if(he>=le)return this.interim[0]=ee,this.interim[1]=ne,z;if((192&(E=se[he++]))!=128){he--;continue}if((x=(15&ee)<<12|(63&ne)<<6|63&E)<2048||x>=55296&&x<=57343)continue;te[z++]=x}else if((248&ee)==240){if(he>=le)return this.interim[0]=ee,z;if((192&(ne=se[he++]))!=128){he--;continue}if(he>=le)return this.interim[0]=ee,this.interim[1]=ne,z;if((192&(E=se[he++]))!=128){he--;continue}if(he>=le)return this.interim[0]=ee,this.interim[1]=ne,this.interim[2]=E,z;if((192&(b=se[he++]))!=128){he--;continue}if((x=(7&ee)<<18|(63&ne)<<12|(63&E)<<6|63&b)<65536||x>1114111)continue;te[z++]=x}}return z},ue}();be.Utf8ToUtf32=Ce},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.CHAR_ATLAS_CELL_SPACING=be.DIM_OPACITY=be.INVERTED_DEFAULT_COLOR=void 0,be.INVERTED_DEFAULT_COLOR=257,be.DIM_OPACITY=.5,be.CHAR_ATLAS_CELL_SPACING=1},function(Mt,be,ce){"use strict";var ie,Ce,ue,se;function te(ee){var ne=ee.toString(16);return ne.length<2?"0"+ne:ne}function le(ee,ne){return ee<ne?(ne+.05)/(ee+.05):(ee+.05)/(ne+.05)}Object.defineProperty(be,"__esModule",{value:!0}),be.contrastRatio=be.toPaddedHex=be.rgba=be.rgb=be.css=be.color=be.channels=void 0,function(ee){ee.toCss=function(ne,E,b,z){return z!==void 0?"#"+te(ne)+te(E)+te(b)+te(z):"#"+te(ne)+te(E)+te(b)},ee.toRgba=function(ne,E,b,z){return z===void 0&&(z=255),(ne<<24|E<<16|b<<8|z)>>>0}}(ie=be.channels||(be.channels={})),(Ce=be.color||(be.color={})).blend=function(ee,ne){var E=(255&ne.rgba)/255;if(E===1)return{css:ne.css,rgba:ne.rgba};var b=ne.rgba>>24&255,z=ne.rgba>>16&255,x=ne.rgba>>8&255,re=ee.rgba>>24&255,ae=ee.rgba>>16&255,oe=ee.rgba>>8&255,ve=re+Math.round((b-re)*E),ye=ae+Math.round((z-ae)*E),me=oe+Math.round((x-oe)*E);return{css:ie.toCss(ve,ye,me),rgba:ie.toRgba(ve,ye,me)}},Ce.isOpaque=function(ee){return(255&ee.rgba)==255},Ce.ensureContrastRatio=function(ee,ne,E){var b=se.ensureContrastRatio(ee.rgba,ne.rgba,E);if(b)return se.toColor(b>>24&255,b>>16&255,b>>8&255)},Ce.opaque=function(ee){var ne=(255|ee.rgba)>>>0,E=se.toChannels(ne),b=E[0],z=E[1],x=E[2];return{css:ie.toCss(b,z,x),rgba:ne}},Ce.opacity=function(ee,ne){var E=Math.round(255*ne),b=se.toChannels(ee.rgba),z=b[0],x=b[1],re=b[2];return{css:ie.toCss(z,x,re,E),rgba:ie.toRgba(z,x,re,E)}},(be.css||(be.css={})).toColor=function(ee){switch(ee.length){case 7:return{css:ee,rgba:(parseInt(ee.slice(1),16)<<8|255)>>>0};case 9:return{css:ee,rgba:parseInt(ee.slice(1),16)>>>0}}throw new Error("css.toColor: Unsupported css format")},function(ee){function ne(E,b,z){var x=E/255,re=b/255,ae=z/255;return .2126*(x<=.03928?x/12.92:Math.pow((x+.055)/1.055,2.4))+.7152*(re<=.03928?re/12.92:Math.pow((re+.055)/1.055,2.4))+.0722*(ae<=.03928?ae/12.92:Math.pow((ae+.055)/1.055,2.4))}ee.relativeLuminance=function(E){return ne(E>>16&255,E>>8&255,255&E)},ee.relativeLuminance2=ne}(ue=be.rgb||(be.rgb={})),function(ee){function ne(b,z,x){for(var re=b>>24&255,ae=b>>16&255,oe=b>>8&255,ve=z>>24&255,ye=z>>16&255,me=z>>8&255,ge=le(ue.relativeLuminance2(ve,me,ye),ue.relativeLuminance2(re,ae,oe));ge<x&&(ve>0||ye>0||me>0);)ve-=Math.max(0,Math.ceil(.1*ve)),ye-=Math.max(0,Math.ceil(.1*ye)),me-=Math.max(0,Math.ceil(.1*me)),ge=le(ue.relativeLuminance2(ve,me,ye),ue.relativeLuminance2(re,ae,oe));return(ve<<24|ye<<16|me<<8|255)>>>0}function E(b,z,x){for(var re=b>>24&255,ae=b>>16&255,oe=b>>8&255,ve=z>>24&255,ye=z>>16&255,me=z>>8&255,ge=le(ue.relativeLuminance2(ve,me,ye),ue.relativeLuminance2(re,ae,oe));ge<x&&(ve<255||ye<255||me<255);)ve=Math.min(255,ve+Math.ceil(.1*(255-ve))),ye=Math.min(255,ye+Math.ceil(.1*(255-ye))),me=Math.min(255,me+Math.ceil(.1*(255-me))),ge=le(ue.relativeLuminance2(ve,me,ye),ue.relativeLuminance2(re,ae,oe));return(ve<<24|ye<<16|me<<8|255)>>>0}ee.ensureContrastRatio=function(b,z,x){var re=ue.relativeLuminance(b>>8),ae=ue.relativeLuminance(z>>8);if(le(re,ae)<x)return ae<re?ne(b,z,x):E(b,z,x)},ee.reduceLuminance=ne,ee.increaseLuminance=E,ee.toChannels=function(b){return[b>>24&255,b>>16&255,b>>8&255,255&b]},ee.toColor=function(b,z,x){return{css:ie.toCss(b,z,x),rgba:ie.toRgba(b,z,x)}}}(se=be.rgba||(be.rgba={})),be.toPaddedHex=te,be.contrastRatio=le},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.isLinux=be.isWindows=be.isIphone=be.isIpad=be.isMac=be.isSafari=be.isFirefox=void 0;var ie=typeof navigator=="undefined",Ce=ie?"node":navigator.userAgent,ue=ie?"node":navigator.platform;function se(te,le){return te.indexOf(le)>=0}be.isFirefox=!!~Ce.indexOf("Firefox"),be.isSafari=/^((?!chrome|android).)*safari/i.test(Ce),be.isMac=se(["Macintosh","MacIntel","MacPPC","Mac68K"],ue),be.isIpad=ue==="iPad",be.isIphone=ue==="iPhone",be.isWindows=se(["Windows","Win16","Win32","WinCE"],ue),be.isLinux=ue.indexOf("Linux")>=0},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.C1=be.C0=void 0,function(ie){ie.NUL="\0",ie.SOH="",ie.STX="",ie.ETX="",ie.EOT="",ie.ENQ="",ie.ACK="",ie.BEL="\x07",ie.BS="\b",ie.HT=" ",ie.LF=`
|
|
|
`,ie.VT="\v",ie.FF="\f",ie.CR="\r",ie.SO="",ie.SI="",ie.DLE="",ie.DC1="",ie.DC2="",ie.DC3="",ie.DC4="",ie.NAK="",ie.SYN="",ie.ETB="",ie.CAN="",ie.EM="",ie.SUB="",ie.ESC="\x1B",ie.FS="",ie.GS="",ie.RS="",ie.US="",ie.SP=" ",ie.DEL="\x7F"}(be.C0||(be.C0={})),function(ie){ie.PAD="\x80",ie.HOP="\x81",ie.BPH="\x82",ie.NBH="\x83",ie.IND="\x84",ie.NEL="\x85",ie.SSA="\x86",ie.ESA="\x87",ie.HTS="\x88",ie.HTJ="\x89",ie.VTS="\x8A",ie.PLD="\x8B",ie.PLU="\x8C",ie.RI="\x8D",ie.SS2="\x8E",ie.SS3="\x8F",ie.DCS="\x90",ie.PU1="\x91",ie.PU2="\x92",ie.STS="\x93",ie.CCH="\x94",ie.MW="\x95",ie.SPA="\x96",ie.EPA="\x97",ie.SOS="\x98",ie.SGCI="\x99",ie.SCI="\x9A",ie.CSI="\x9B",ie.ST="\x9C",ie.OSC="\x9D",ie.PM="\x9E",ie.APC="\x9F"}(be.C1||(be.C1={}))},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.BaseRenderLayer=void 0;var ie=ce(3),Ce=ce(9),ue=ce(25),se=ce(6),te=ce(28),le=ce(10),ee=ce(17),ne=function(){function E(b,z,x,re,ae,oe,ve,ye){this._container=b,this._alpha=re,this._colors=ae,this._rendererId=oe,this._bufferService=ve,this._optionsService=ye,this._scaledCharWidth=0,this._scaledCharHeight=0,this._scaledCellWidth=0,this._scaledCellHeight=0,this._scaledCharLeft=0,this._scaledCharTop=0,this._currentGlyphIdentifier={chars:"",code:0,bg:0,fg:0,bold:!1,dim:!1,italic:!1},this._canvas=document.createElement("canvas"),this._canvas.classList.add("xterm-"+z+"-layer"),this._canvas.style.zIndex=x.toString(),this._initCanvas(),this._container.appendChild(this._canvas)}return E.prototype.dispose=function(){var b;ee.removeElementFromParent(this._canvas),(b=this._charAtlas)===null||b===void 0||b.dispose()},E.prototype._initCanvas=function(){this._ctx=te.throwIfFalsy(this._canvas.getContext("2d",{alpha:this._alpha})),this._alpha||this._clearAll()},E.prototype.onOptionsChanged=function(){},E.prototype.onBlur=function(){},E.prototype.onFocus=function(){},E.prototype.onCursorMove=function(){},E.prototype.onGridChanged=function(b,z){},E.prototype.onSelectionChanged=function(b,z,x){x===void 0&&(x=!1)},E.prototype.setColors=function(b){this._refreshCharAtlas(b)},E.prototype._setTransparency=function(b){if(b!==this._alpha){var z=this._canvas;this._alpha=b,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,z),this._refreshCharAtlas(this._colors),this.onGridChanged(0,this._bufferService.rows-1)}},E.prototype._refreshCharAtlas=function(b){this._scaledCharWidth<=0&&this._scaledCharHeight<=0||(this._charAtlas=ue.acquireCharAtlas(this._optionsService.options,this._rendererId,b,this._scaledCharWidth,this._scaledCharHeight),this._charAtlas.warmUp())},E.prototype.resize=function(b){this._scaledCellWidth=b.scaledCellWidth,this._scaledCellHeight=b.scaledCellHeight,this._scaledCharWidth=b.scaledCharWidth,this._scaledCharHeight=b.scaledCharHeight,this._scaledCharLeft=b.scaledCharLeft,this._scaledCharTop=b.scaledCharTop,this._canvas.width=b.scaledCanvasWidth,this._canvas.height=b.scaledCanvasHeight,this._canvas.style.width=b.canvasWidth+"px",this._canvas.style.height=b.canvasHeight+"px",this._alpha||this._clearAll(),this._refreshCharAtlas(this._colors)},E.prototype._fillCells=function(b,z,x,re){this._ctx.fillRect(b*this._scaledCellWidth,z*this._scaledCellHeight,x*this._scaledCellWidth,re*this._scaledCellHeight)},E.prototype._fillBottomLineAtCells=function(b,z,x){x===void 0&&(x=1),this._ctx.fillRect(b*this._scaledCellWidth,(z+1)*this._scaledCellHeight-window.devicePixelRatio-1,x*this._scaledCellWidth,window.devicePixelRatio)},E.prototype._fillLeftLineAtCell=function(b,z,x){this._ctx.fillRect(b*this._scaledCellWidth,z*this._scaledCellHeight,window.devicePixelRatio*x,this._scaledCellHeight)},E.prototype._strokeRectAtCell=function(b,z,x,re){this._ctx.lineWidth=window.devicePixelRatio,this._ctx.strokeRect(b*this._scaledCellWidth+window.devicePixelRatio/2,z*this._scaledCellHeight+window.devicePixelRatio/2,x*this._scaledCellWidth-window.devicePixelRatio,re*this._scaledCellHeight-window.devicePixelRatio)},E.prototype._clearAll=function(){this._alpha?this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(0,0,this._canvas.width,this._canvas.height))},E.prototype._clearCells=function(b,z,x,re){this._alpha?this._ctx.clearRect(b*this._scaledCellWidth,z*this._scaledCellHeight,x*this._scaledCellWidth,re*this._scaledCellHeight):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(b*this._scaledCellWidth,z*this._scaledCellHeight,x*this._scaledCellWidth,re*this._scaledCellHeight))},E.prototype._fillCharTrueColor=function(b,z,x){this._ctx.font=this._getFont(!1,!1),this._ctx.textBaseline="middle",this._clipRow(x),this._ctx.fillText(b.getChars(),z*this._scaledCellWidth+this._scaledCharLeft,x*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2)},E.prototype._drawChars=function(b,z,x){var re,ae,oe=this._getContrastColor(b);oe||b.isFgRGB()||b.isBgRGB()?this._drawUncachedChars(b,z,x,oe):(b.isInverse()?(re=b.isBgDefault()?Ce.INVERTED_DEFAULT_COLOR:b.getBgColor(),ae=b.isFgDefault()?Ce.INVERTED_DEFAULT_COLOR:b.getFgColor()):(ae=b.isBgDefault()?ie.DEFAULT_COLOR:b.getBgColor(),re=b.isFgDefault()?ie.DEFAULT_COLOR:b.getFgColor()),re+=this._optionsService.options.drawBoldTextInBrightColors&&b.isBold()&&re<8?8:0,this._currentGlyphIdentifier.chars=b.getChars()||ie.WHITESPACE_CELL_CHAR,this._currentGlyphIdentifier.code=b.getCode()||ie.WHITESPACE_CELL_CODE,this._currentGlyphIdentifier.bg=ae,this._currentGlyphIdentifier.fg=re,this._currentGlyphIdentifier.bold=!!b.isBold(),this._currentGlyphIdentifier.dim=!!b.isDim(),this._currentGlyphIdentifier.italic=!!b.isItalic(),this._charAtlas&&this._charAtlas.draw(this._ctx,this._currentGlyphIdentifier,z*this._scaledCellWidth+this._scaledCharLeft,x*this._scaledCellHeight+this._scaledCharTop)||this._drawUncachedChars(b,z,x))},E.prototype._drawUncachedChars=function(b,z,x,re){if(this._ctx.save(),this._ctx.font=this._getFont(!!b.isBold(),!!b.isItalic()),this._ctx.textBaseline="middle",b.isInverse())if(re)this._ctx.fillStyle=re.css;else if(b.isBgDefault())this._ctx.fillStyle=le.color.opaque(this._colors.background).css;else if(b.isBgRGB())this._ctx.fillStyle="rgb("+se.AttributeData.toColorRGB(b.getBgColor()).join(",")+")";else{var ae=b.getBgColor();this._optionsService.options.drawBoldTextInBrightColors&&b.isBold()&&ae<8&&(ae+=8),this._ctx.fillStyle=this._colors.ansi[ae].css}else if(re)this._ctx.fillStyle=re.css;else if(b.isFgDefault())this._ctx.fillStyle=this._colors.foreground.css;else if(b.isFgRGB())this._ctx.fillStyle="rgb("+se.AttributeData.toColorRGB(b.getFgColor()).join(",")+")";else{var oe=b.getFgColor();this._optionsService.options.drawBoldTextInBrightColors&&b.isBold()&&oe<8&&(oe+=8),this._ctx.fillStyle=this._colors.ansi[oe].css}this._clipRow(x),b.isDim()&&(this._ctx.globalAlpha=Ce.DIM_OPACITY),this._ctx.fillText(b.getChars(),z*this._scaledCellWidth+this._scaledCharLeft,x*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2),this._ctx.restore()},E.prototype._clipRow=function(b){this._ctx.beginPath(),this._ctx.rect(0,b*this._scaledCellHeight,this._bufferService.cols*this._scaledCellWidth,this._scaledCellHeight),this._ctx.clip()},E.prototype._getFont=function(b,z){return(z?"italic":"")+" "+(b?this._optionsService.options.fontWeightBold:this._optionsService.options.fontWeight)+" "+this._optionsService.options.fontSize*window.devicePixelRatio+"px "+this._optionsService.options.fontFamily},E.prototype._getContrastColor=function(b){if(this._optionsService.options.minimumContrastRatio!==1){var z=this._colors.contrastCache.getColor(b.bg,b.fg);if(z!==void 0)return z||void 0;var x=b.getFgColor(),re=b.getFgColorMode(),ae=b.getBgColor(),oe=b.getBgColorMode(),ve=!!b.isInverse(),ye=!!b.isInverse();if(ve){var me=x;x=ae,ae=me;var ge=re;re=oe,oe=ge}var _e=this._resolveBackgroundRgba(oe,ae,ve),he=this._resolveForegroundRgba(re,x,ve,ye),pe=le.rgba.ensureContrastRatio(_e,he,this._optionsService.options.minimumContrastRatio);if(pe){var ke={css:le.channels.toCss(pe>>24&255,pe>>16&255,pe>>8&255),rgba:pe};return this._colors.contrastCache.setColor(b.bg,b.fg,ke),ke}this._colors.contrastCache.setColor(b.bg,b.fg,null)}},E.prototype._resolveBackgroundRgba=function(b,z,x){switch(b){case 16777216:case 33554432:return this._colors.ansi[z].rgba;case 50331648:return z<<8;case 0:default:return x?this._colors.foreground.rgba:this._colors.background.rgba}},E.prototype._resolveForegroundRgba=function(b,z,x,re){switch(b){case 16777216:case 33554432:return this._optionsService.options.drawBoldTextInBrightColors&&re&&z<8&&(z+=8),this._colors.ansi[z].rgba;case 50331648:return z<<8;case 0:default:return x?this._colors.background.rgba:this._colors.foreground.rgba}},E}();be.BaseRenderLayer=ne},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.createDecorator=be.getServiceDependencies=be.serviceRegistry=void 0;function ie(Ce,ue,se){ue.di$target===ue?ue.di$dependencies.push({id:Ce,index:se}):(ue.di$dependencies=[{id:Ce,index:se}],ue.di$target=ue)}be.serviceRegistry=new Map,be.getServiceDependencies=function(Ce){return Ce.di$dependencies||[]},be.createDecorator=function(Ce){if(be.serviceRegistry.has(Ce))return be.serviceRegistry.get(Ce);var ue=function(se,te,le){if(arguments.length!==3)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");ie(ue,se,le)};return ue.toString=function(){return Ce},be.serviceRegistry.set(Ce,ue),ue}},function(Mt,be,ce){"use strict";function ie(Ce,ue,se,te){if(se===void 0&&(se=0),te===void 0&&(te=Ce.length),se>=Ce.length)return Ce;se=(Ce.length+se)%Ce.length,te=te>=Ce.length?Ce.length:(Ce.length+te)%Ce.length;for(var le=se;le<te;++le)Ce[le]=ue;return Ce}Object.defineProperty(be,"__esModule",{value:!0}),be.concat=be.fillFallback=be.fill=void 0,be.fill=function(Ce,ue,se,te){return Ce.fill?Ce.fill(ue,se,te):ie(Ce,ue,se,te)},be.fillFallback=ie,be.concat=function(Ce,ue){var se=new Ce.constructor(Ce.length+ue.length);return se.set(Ce),se.set(ue,Ce.length),se}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.BufferLine=be.DEFAULT_ATTR_DATA=void 0;var ie=ce(8),Ce=ce(3),ue=ce(4),se=ce(6);be.DEFAULT_ATTR_DATA=Object.freeze(new se.AttributeData);var te=function(){function le(ee,ne,E){E===void 0&&(E=!1),this.isWrapped=E,this._combined={},this._extendedAttrs={},this._data=new Uint32Array(3*ee);for(var b=ne||ue.CellData.fromCharData([0,Ce.NULL_CELL_CHAR,Ce.NULL_CELL_WIDTH,Ce.NULL_CELL_CODE]),z=0;z<ee;++z)this.setCell(z,b);this.length=ee}return le.prototype.get=function(ee){var ne=this._data[3*ee+0],E=2097151≠return[this._data[3*ee+1],2097152&ne?this._combined[ee]:E?ie.stringFromCodePoint(E):"",ne>>22,2097152&ne?this._combined[ee].charCodeAt(this._combined[ee].length-1):E]},le.prototype.set=function(ee,ne){this._data[3*ee+1]=ne[Ce.CHAR_DATA_ATTR_INDEX],ne[Ce.CHAR_DATA_CHAR_INDEX].length>1?(this._combined[ee]=ne[1],this._data[3*ee+0]=2097152|ee|ne[Ce.CHAR_DATA_WIDTH_INDEX]<<22):this._data[3*ee+0]=ne[Ce.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|ne[Ce.CHAR_DATA_WIDTH_INDEX]<<22},le.prototype.getWidth=function(ee){return this._data[3*ee+0]>>22},le.prototype.hasWidth=function(ee){return 12582912&this._data[3*ee+0]},le.prototype.getFg=function(ee){return this._data[3*ee+1]},le.prototype.getBg=function(ee){return this._data[3*ee+2]},le.prototype.hasContent=function(ee){return 4194303&this._data[3*ee+0]},le.prototype.getCodePoint=function(ee){var ne=this._data[3*ee+0];return 2097152&ne?this._combined[ee].charCodeAt(this._combined[ee].length-1):2097151&ne},le.prototype.isCombined=function(ee){return 2097152&this._data[3*ee+0]},le.prototype.getString=function(ee){var ne=this._data[3*ee+0];return 2097152&ne?this._combined[ee]:2097151&ne?ie.stringFromCodePoint(2097151&ne):""},le.prototype.loadCell=function(ee,ne){var E=3*ee;return ne.content=this._data[E+0],ne.fg=this._data[E+1],ne.bg=this._data[E+2],2097152&ne.content&&(ne.combinedData=this._combined[ee]),268435456&ne.bg&&(ne.extended=this._extendedAttrs[ee]),ne},le.prototype.setCell=function(ee,ne){2097152&ne.content&&(this._combined[ee]=ne.combinedData),268435456&ne.bg&&(this._extendedAttrs[ee]=ne.extended),this._data[3*ee+0]=ne.content,this._data[3*ee+1]=ne.fg,this._data[3*ee+2]=ne.bg},le.prototype.setCellFromCodePoint=function(ee,ne,E,b,z,x){268435456&z&&(this._extendedAttrs[ee]=x),this._data[3*ee+0]=ne|E<<22,this._data[3*ee+1]=b,this._data[3*ee+2]=z},le.prototype.addCodepointToCell=function(ee,ne){var E=this._data[3*ee+0];2097152&E?this._combined[ee]+=ie.stringFromCodePoint(ne):(2097151&E?(this._combined[ee]=ie.stringFromCodePoint(2097151&E)+ie.stringFromCodePoint(ne),E&=-2097152,E|=2097152):E=ne|1<<22,this._data[3*ee+0]=E)},le.prototype.insertCells=function(ee,ne,E,b){if((ee%=this.length)&&this.getWidth(ee-1)===2&&this.setCellFromCodePoint(ee-1,0,1,(b==null?void 0:b.fg)||0,(b==null?void 0:b.bg)||0,(b==null?void 0:b.extended)||new se.ExtendedAttrs),ne<this.length-ee){for(var z=new ue.CellData,x=this.length-ee-ne-1;x>=0;--x)this.setCell(ee+ne+x,this.loadCell(ee+x,z));for(x=0;x<ne;++x)this.setCell(ee+x,E)}else for(x=ee;x<this.length;++x)this.setCell(x,E);this.getWidth(this.length-1)===2&&this.setCellFromCodePoint(this.length-1,0,1,(b==null?void 0:b.fg)||0,(b==null?void 0:b.bg)||0,(b==null?void 0:b.extended)||new se.ExtendedAttrs)},le.prototype.deleteCells=function(ee,ne,E,b){if(ee%=this.length,ne<this.length-ee){for(var z=new ue.CellData,x=0;x<this.length-ee-ne;++x)this.setCell(ee+x,this.loadCell(ee+ne+x,z));for(x=this.length-ne;x<this.length;++x)this.setCell(x,E)}else for(x=ee;x<this.length;++x)this.setCell(x,E);ee&&this.getWidth(ee-1)===2&&this.setCellFromCodePoint(ee-1,0,1,(b==null?void 0:b.fg)||0,(b==null?void 0:b.bg)||0,(b==null?void 0:b.extended)||new se.ExtendedAttrs),this.getWidth(ee)!==0||this.hasContent(ee)||this.setCellFromCodePoint(ee,0,1,(b==null?void 0:b.fg)||0,(b==null?void 0:b.bg)||0,(b==null?void 0:b.extended)||new se.ExtendedAttrs)},le.prototype.replaceCells=function(ee,ne,E,b){for(ee&&this.getWidth(ee-1)===2&&this.setCellFromCodePoint(ee-1,0,1,(b==null?void 0:b.fg)||0,(b==null?void 0:b.bg)||0,(b==null?void 0:b.extended)||new se.ExtendedAttrs),ne<this.length&&this.getWidth(ne-1)===2&&this.setCellFromCodePoint(ne,0,1,(b==null?void 0:b.fg)||0,(b==null?void 0:b.bg)||0,(b==null?void 0:b.extended)||new se.ExtendedAttrs);ee<ne&&ee<this.length;)this.setCell(ee++,E)},le.prototype.resize=function(ee,ne){if(ee!==this.length){if(ee>this.length){var E=new Uint32Array(3*ee);this.length&&(3*ee<this._data.length?E.set(this._data.subarray(0,3*ee)):E.set(this._data)),this._data=E;for(var b=this.length;b<ee;++b)this.setCell(b,ne)}else if(ee){(E=new Uint32Array(3*ee)).set(this._data.subarray(0,3*ee)),this._data=E;var z=Object.keys(this._combined);for(b=0;b<z.length;b++){var x=parseInt(z[b],10);x>=ee&&delete this._combined[x]}}else this._data=new Uint32Array(0),this._combined={};this.length=ee}},le.prototype.fill=function(ee){this._combined={},this._extendedAttrs={};for(var ne=0;ne<this.length;++ne)this.setCell(ne,ee)},le.prototype.copyFrom=function(ee){for(var ne in this.length!==ee.length?this._data=new Uint32Array(ee._data):this._data.set(ee._data),this.length=ee.length,this._combined={},ee._combined)this._combined[ne]=ee._combined[ne];for(var ne in this._extendedAttrs={},ee._extendedAttrs)this._extendedAttrs[ne]=ee._extendedAttrs[ne];this.isWrapped=ee.isWrapped},le.prototype.clone=function(){var ee=new le(0);for(var ne in ee._data=new Uint32Array(this._data),ee.length=this.length,this._combined)ee._combined[ne]=this._combined[ne];for(var ne in this._extendedAttrs)ee._extendedAttrs[ne]=this._extendedAttrs[ne];return ee.isWrapped=this.isWrapped,ee},le.prototype.getTrimmedLength=function(){for(var ee=this.length-1;ee>=0;--ee)if(4194303&this._data[3*ee+0])return ee+(this._data[3*ee+0]>>22);return 0},le.prototype.copyCellsFrom=function(ee,ne,E,b,z){var x=ee._data;if(z)for(var re=b-1;re>=0;re--)for(var ae=0;ae<3;ae++)this._data[3*(E+re)+ae]=x[3*(ne+re)+ae];else for(re=0;re<b;re++)for(ae=0;ae<3;ae++)this._data[3*(E+re)+ae]=x[3*(ne+re)+ae];var oe=Object.keys(ee._combined);for(ae=0;ae<oe.length;ae++){var ve=parseInt(oe[ae],10);ve>=ne&&(this._combined[ve-ne+E]=ee._combined[ve])}},le.prototype.translateToString=function(ee,ne,E){ee===void 0&&(ee=!1),ne===void 0&&(ne=0),E===void 0&&(E=this.length),ee&&(E=Math.min(E,this.getTrimmedLength()));for(var b="";ne<E;){var z=this._data[3*ne+0],x=2097151&z;b+=2097152&z?this._combined[ne]:x?ie.stringFromCodePoint(x):Ce.WHITESPACE_CELL_CHAR,ne+=z>>22||1}return b},le}();be.BufferLine=te},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.removeElementFromParent=void 0,be.removeElementFromParent=function(){for(var ie,Ce=[],ue=0;ue<arguments.length;ue++)Ce[ue]=arguments[ue];for(var se=0,te=Ce;se<te.length;se++){var le=te[se];(ie=le==null?void 0:le.parentElement)===null||ie===void 0||ie.removeChild(le)}}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.tooMuchOutput=be.promptLabel=void 0,be.promptLabel="Terminal input",be.tooMuchOutput="Too much output to announce, navigate to rows manually to read"},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(he,pe){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ke,Te){ke.__proto__=Te}||function(ke,Te){for(var Ee in Te)Te.hasOwnProperty(Ee)&&(ke[Ee]=Te[Ee])})(he,pe)},function(he,pe){function ke(){this.constructor=he}ie(he,pe),he.prototype=pe===null?Object.create(pe):(ke.prototype=pe.prototype,new ke)});Object.defineProperty(be,"__esModule",{value:!0}),be.InputHandler=be.WindowsOptionsReportType=void 0;var ue,se=ce(12),te=ce(20),le=ce(39),ee=ce(2),ne=ce(15),E=ce(8),b=ce(16),z=ce(0),x=ce(3),re=ce(4),ae=ce(6),oe=ce(22),ve=ce(24),ye={"(":0,")":1,"*":2,"+":3,"-":1,".":2};function me(he,pe){if(he>24)return pe.setWinLines||!1;switch(he){case 1:return!!pe.restoreWin;case 2:return!!pe.minimizeWin;case 3:return!!pe.setWinPosition;case 4:return!!pe.setWinSizePixels;case 5:return!!pe.raiseWin;case 6:return!!pe.lowerWin;case 7:return!!pe.refreshWin;case 8:return!!pe.setWinSizeChars;case 9:return!!pe.maximizeWin;case 10:return!!pe.fullscreenWin;case 11:return!!pe.getWinState;case 13:return!!pe.getWinPosition;case 14:return!!pe.getWinSizePixels;case 15:return!!pe.getScreenSizePixels;case 16:return!!pe.getCellSizePixels;case 18:return!!pe.getWinSizeChars;case 19:return!!pe.getScreenSizeChars;case 20:return!!pe.getIconTitle;case 21:return!!pe.getWinTitle;case 22:return!!pe.pushTitle;case 23:return!!pe.popTitle;case 24:return!!pe.setWinLines}return!1}(function(he){he[he.GET_WIN_SIZE_PIXELS=0]="GET_WIN_SIZE_PIXELS",he[he.GET_CELL_SIZE_PIXELS=1]="GET_CELL_SIZE_PIXELS"})(ue=be.WindowsOptionsReportType||(be.WindowsOptionsReportType={}));var ge=function(){function he(pe,ke,Te,Ee){this._bufferService=pe,this._coreService=ke,this._logService=Te,this._optionsService=Ee,this._data=new Uint32Array(0)}return he.prototype.hook=function(pe){this._data=new Uint32Array(0)},he.prototype.put=function(pe,ke,Te){this._data=ne.concat(this._data,pe.subarray(ke,Te))},he.prototype.unhook=function(pe){if(pe){var ke=E.utf32ToString(this._data);switch(this._data=new Uint32Array(0),ke){case'"q':return this._coreService.triggerDataEvent(se.C0.ESC+'P1$r0"q'+se.C0.ESC+"\\");case'"p':return this._coreService.triggerDataEvent(se.C0.ESC+'P1$r61;1"p'+se.C0.ESC+"\\");case"r":var Te=this._bufferService.buffer.scrollTop+1+";"+(this._bufferService.buffer.scrollBottom+1)+"r";return this._coreService.triggerDataEvent(se.C0.ESC+"P1$r"+Te+se.C0.ESC+"\\");case"m":return this._coreService.triggerDataEvent(se.C0.ESC+"P1$r0m"+se.C0.ESC+"\\");case" q":var Ee={block:2,underline:4,bar:6}[this._optionsService.options.cursorStyle];return Ee-=this._optionsService.options.cursorBlink?1:0,this._coreService.triggerDataEvent(se.C0.ESC+"P1$r"+Ee+" q"+se.C0.ESC+"\\");default:this._logService.debug("Unknown DCS $q %s",ke),this._coreService.triggerDataEvent(se.C0.ESC+"P0$r"+se.C0.ESC+"\\")}}else this._data=new Uint32Array(0)},he}(),_e=function(he){function pe(ke,Te,Ee,Oe,je,Pe,Qe,Xe,ot){ot===void 0&&(ot=new le.EscapeSequenceParser);var He=he.call(this)||this;He._bufferService=ke,He._charsetService=Te,He._coreService=Ee,He._dirtyRowService=Oe,He._logService=je,He._optionsService=Pe,He._coreMouseService=Qe,He._unicodeService=Xe,He._parser=ot,He._parseBuffer=new Uint32Array(4096),He._stringDecoder=new E.StringToUtf32,He._utf8Decoder=new E.Utf8ToUtf32,He._workCell=new re.CellData,He._windowTitle="",He._iconName="",He._windowTitleStack=[],He._iconNameStack=[],He._curAttrData=b.DEFAULT_ATTR_DATA.clone(),He._eraseAttrDataInternal=b.DEFAULT_ATTR_DATA.clone(),He._onRequestBell=new z.EventEmitter,He._onRequestRefreshRows=new z.EventEmitter,He._onRequestReset=new z.EventEmitter,He._onRequestScroll=new z.EventEmitter,He._onRequestSyncScrollBar=new z.EventEmitter,He._onRequestWindowsOptionsReport=new z.EventEmitter,He._onA11yChar=new z.EventEmitter,He._onA11yTab=new z.EventEmitter,He._onCursorMove=new z.EventEmitter,He._onLineFeed=new z.EventEmitter,He._onScroll=new z.EventEmitter,He._onTitleChange=new z.EventEmitter,He.register(He._parser),He._parser.setCsiHandlerFallback(function(Ge,ze){He._logService.debug("Unknown CSI code: ",{identifier:He._parser.identToString(Ge),params:ze.toArray()})}),He._parser.setEscHandlerFallback(function(Ge){He._logService.debug("Unknown ESC code: ",{identifier:He._parser.identToString(Ge)})}),He._parser.setExecuteHandlerFallback(function(Ge){He._logService.debug("Unknown EXECUTE code: ",{code:Ge})}),He._parser.setOscHandlerFallback(function(Ge,ze,Ve){He._logService.debug("Unknown OSC code: ",{identifier:Ge,action:ze,data:Ve})}),He._parser.setDcsHandlerFallback(function(Ge,ze,Ve){ze==="HOOK"&&(Ve=Ve.toArray()),He._logService.debug("Unknown DCS code: ",{identifier:He._parser.identToString(Ge),action:ze,payload:Ve})}),He._parser.setPrintHandler(function(Ge,ze,Ve){return He.print(Ge,ze,Ve)}),He._parser.setCsiHandler({final:"@"},function(Ge){return He.insertChars(Ge)}),He._parser.setCsiHandler({intermediates:" ",final:"@"},function(Ge){return He.scrollLeft(Ge)}),He._parser.setCsiHandler({final:"A"},function(Ge){return He.cursorUp(Ge)}),He._parser.setCsiHandler({intermediates:" ",final:"A"},function(Ge){return He.scrollRight(Ge)}),He._parser.setCsiHandler({final:"B"},function(Ge){return He.cursorDown(Ge)}),He._parser.setCsiHandler({final:"C"},function(Ge){return He.cursorForward(Ge)}),He._parser.setCsiHandler({final:"D"},function(Ge){return He.cursorBackward(Ge)}),He._parser.setCsiHandler({final:"E"},function(Ge){return He.cursorNextLine(Ge)}),He._parser.setCsiHandler({final:"F"},function(Ge){return He.cursorPrecedingLine(Ge)}),He._parser.setCsiHandler({final:"G"},function(Ge){return He.cursorCharAbsolute(Ge)}),He._parser.setCsiHandler({final:"H"},function(Ge){return He.cursorPosition(Ge)}),He._parser.setCsiHandler({final:"I"},function(Ge){return He.cursorForwardTab(Ge)}),He._parser.setCsiHandler({final:"J"},function(Ge){return He.eraseInDisplay(Ge)}),He._parser.setCsiHandler({prefix:"?",final:"J"},function(Ge){return He.eraseInDisplay(Ge)}),He._parser.setCsiHandler({final:"K"},function(Ge){return He.eraseInLine(Ge)}),He._parser.setCsiHandler({prefix:"?",final:"K"},function(Ge){return He.eraseInLine(Ge)}),He._parser.setCsiHandler({final:"L"},function(Ge){return He.insertLines(Ge)}),He._parser.setCsiHandler({final:"M"},function(Ge){return He.deleteLines(Ge)}),He._parser.setCsiHandler({final:"P"},function(Ge){return He.deleteChars(Ge)}),He._parser.setCsiHandler({final:"S"},function(Ge){return He.scrollUp(Ge)}),He._parser.setCsiHandler({final:"T"},function(Ge){return He.scrollDown(Ge)}),He._parser.setCsiHandler({final:"X"},function(Ge){return He.eraseChars(Ge)}),He._parser.setCsiHandler({final:"Z"},function(Ge){return He.cursorBackwardTab(Ge)}),He._parser.setCsiHandler({final:"`"},function(Ge){return He.charPosAbsolute(Ge)}),He._parser.setCsiHandler({final:"a"},function(Ge){return He.hPositionRelative(Ge)}),He._parser.setCsiHandler({final:"b"},function(Ge){return He.repeatPrecedingCharacter(Ge)}),He._parser.setCsiHandler({final:"c"},function(Ge){return He.sendDeviceAttributesPrimary(Ge)}),He._parser.setCsiHandler({prefix:">",final:"c"},function(Ge){return He.sendDeviceAttributesSecondary(Ge)}),He._parser.setCsiHandler({final:"d"},function(Ge){return He.linePosAbsolute(Ge)}),He._parser.setCsiHandler({final:"e"},function(Ge){return He.vPositionRelative(Ge)}),He._parser.setCsiHandler({final:"f"},function(Ge){return He.hVPosition(Ge)}),He._parser.setCsiHandler({final:"g"},function(Ge){return He.tabClear(Ge)}),He._parser.setCsiHandler({final:"h"},function(Ge){return He.setMode(Ge)}),He._parser.setCsiHandler({prefix:"?",final:"h"},function(Ge){return He.setModePrivate(Ge)}),He._parser.setCsiHandler({final:"l"},function(Ge){return He.resetMode(Ge)}),He._parser.setCsiHandler({prefix:"?",final:"l"},function(Ge){return He.resetModePrivate(Ge)}),He._parser.setCsiHandler({final:"m"},function(Ge){return He.charAttributes(Ge)}),He._parser.setCsiHandler({final:"n"},function(Ge){return He.deviceStatus(Ge)}),He._parser.setCsiHandler({prefix:"?",final:"n"},function(Ge){return He.deviceStatusPrivate(Ge)}),He._parser.setCsiHandler({intermediates:"!",final:"p"},function(Ge){return He.softReset(Ge)}),He._parser.setCsiHandler({intermediates:" ",final:"q"},function(Ge){return He.setCursorStyle(Ge)}),He._parser.setCsiHandler({final:"r"},function(Ge){return He.setScrollRegion(Ge)}),He._parser.setCsiHandler({final:"s"},function(Ge){return He.saveCursor(Ge)}),He._parser.setCsiHandler({final:"t"},function(Ge){return He.windowOptions(Ge)}),He._parser.setCsiHandler({final:"u"},function(Ge){return He.restoreCursor(Ge)}),He._parser.setCsiHandler({intermediates:"'",final:"}"},function(Ge){return He.insertColumns(Ge)}),He._parser.setCsiHandler({intermediates:"'",final:"~"},function(Ge){return He.deleteColumns(Ge)}),He._parser.setExecuteHandler(se.C0.BEL,function(){return He.bell()}),He._parser.setExecuteHandler(se.C0.LF,function(){return He.lineFeed()}),He._parser.setExecuteHandler(se.C0.VT,function(){return He.lineFeed()}),He._parser.setExecuteHandler(se.C0.FF,function(){return He.lineFeed()}),He._parser.setExecuteHandler(se.C0.CR,function(){return He.carriageReturn()}),He._parser.setExecuteHandler(se.C0.BS,function(){return He.backspace()}),He._parser.setExecuteHandler(se.C0.HT,function(){return He.tab()}),He._parser.setExecuteHandler(se.C0.SO,function(){return He.shiftOut()}),He._parser.setExecuteHandler(se.C0.SI,function(){return He.shiftIn()}),He._parser.setExecuteHandler(se.C1.IND,function(){return He.index()}),He._parser.setExecuteHandler(se.C1.NEL,function(){return He.nextLine()}),He._parser.setExecuteHandler(se.C1.HTS,function(){return He.tabSet()}),He._parser.setOscHandler(0,new oe.OscHandler(function(Ge){He.setTitle(Ge),He.setIconName(Ge)})),He._parser.setOscHandler(1,new oe.OscHandler(function(Ge){return He.setIconName(Ge)})),He._parser.setOscHandler(2,new oe.OscHandler(function(Ge){return He.setTitle(Ge)})),He._parser.setEscHandler({final:"7"},function(){return He.saveCursor()}),He._parser.setEscHandler({final:"8"},function(){return He.restoreCursor()}),He._parser.setEscHandler({final:"D"},function(){return He.index()}),He._parser.setEscHandler({final:"E"},function(){return He.nextLine()}),He._parser.setEscHandler({final:"H"},function(){return He.tabSet()}),He._parser.setEscHandler({final:"M"},function(){return He.reverseIndex()}),He._parser.setEscHandler({final:"="},function(){return He.keypadApplicationMode()}),He._parser.setEscHandler({final:">"},function(){return He.keypadNumericMode()}),He._parser.setEscHandler({final:"c"},function(){return He.fullReset()}),He._parser.setEscHandler({final:"n"},function(){return He.setgLevel(2)}),He._parser.setEscHandler({final:"o"},function(){return He.setgLevel(3)}),He._parser.setEscHandler({final:"|"},function(){return He.setgLevel(3)}),He._parser.setEscHandler({final:"}"},function(){return He.setgLevel(2)}),He._parser.setEscHandler({final:"~"},function(){return He.setgLevel(1)}),He._parser.setEscHandler({intermediates:"%",final:"@"},function(){return He.selectDefaultCharset()}),He._parser.setEscHandler({intermediates:"%",final:"G"},function(){return He.selectDefaultCharset()});var rt=function(Ge){Ye._parser.setEscHandler({intermediates:"(",final:Ge},function(){return He.selectCharset("("+Ge)}),Ye._parser.setEscHandler({intermediates:")",final:Ge},function(){return He.selectCharset(")"+Ge)}),Ye._parser.setEscHandler({intermediates:"*",final:Ge},function(){return He.selectCharset("*"+Ge)}),Ye._parser.setEscHandler({intermediates:"+",final:Ge},function(){return He.selectCharset("+"+Ge)}),Ye._parser.setEscHandler({intermediates:"-",final:Ge},function(){return He.selectCharset("-"+Ge)}),Ye._parser.setEscHandler({intermediates:".",final:Ge},function(){return He.selectCharset("."+Ge)}),Ye._parser.setEscHandler({intermediates:"/",final:Ge},function(){return He.selectCharset("/"+Ge)})},Ye=this;for(var ut in te.CHARSETS)rt(ut);return He._parser.setEscHandler({intermediates:"#",final:"8"},function(){return He.screenAlignmentPattern()}),He._parser.setErrorHandler(function(Ge){return He._logService.error("Parsing error: ",Ge),Ge}),He._parser.setDcsHandler({intermediates:"$",final:"q"},new ge(He._bufferService,He._coreService,He._logService,He._optionsService)),He}return Ce(pe,he),Object.defineProperty(pe.prototype,"onRequestBell",{get:function(){return this._onRequestBell.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onRequestRefreshRows",{get:function(){return this._onRequestRefreshRows.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onRequestReset",{get:function(){return this._onRequestReset.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onRequestScroll",{get:function(){return this._onRequestScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onRequestSyncScrollBar",{get:function(){return this._onRequestSyncScrollBar.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onRequestWindowsOptionsReport",{get:function(){return this._onRequestWindowsOptionsReport.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onA11yChar",{get:function(){return this._onA11yChar.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onA11yTab",{get:function(){return this._onA11yTab.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onCursorMove",{get:function(){return this._onCursorMove.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onLineFeed",{get:function(){return this._onLineFeed.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onScroll",{get:function(){return this._onScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"onTitleChange",{get:function(){return this._onTitleChange.event},enumerable:!1,configurable:!0}),pe.prototype.dispose=function(){he.prototype.dispose.call(this)},pe.prototype.parse=function(ke){var Te=this._bufferService.buffer,Ee=Te.x,Oe=Te.y;if(this._logService.debug("parsing data",ke),this._parseBuffer.length<ke.length&&this._parseBuffer.length<131072&&(this._parseBuffer=new Uint32Array(Math.min(ke.length,131072))),this._dirtyRowService.clearRange(),ke.length>131072)for(var je=0;je<ke.length;je+=131072){var Pe=je+131072<ke.length?je+131072:ke.length,Qe=typeof ke=="string"?this._stringDecoder.decode(ke.substring(je,Pe),this._parseBuffer):this._utf8Decoder.decode(ke.subarray(je,Pe),this._parseBuffer);this._parser.parse(this._parseBuffer,Qe)}else Qe=typeof ke=="string"?this._stringDecoder.decode(ke,this._parseBuffer):this._utf8Decoder.decode(ke,this._parseBuffer),this._parser.parse(this._parseBuffer,Qe);(Te=this._bufferService.buffer).x===Ee&&Te.y===Oe||this._onCursorMove.fire(),this._onRequestRefreshRows.fire(this._dirtyRowService.start,this._dirtyRowService.end)},pe.prototype.print=function(ke,Te,Ee){var Oe,je,Pe=this._bufferService.buffer,Qe=this._charsetService.charset,Xe=this._optionsService.options.screenReaderMode,ot=this._bufferService.cols,He=this._coreService.decPrivateModes.wraparound,rt=this._coreService.modes.insertMode,Ye=this._curAttrData,ut=Pe.lines.get(Pe.ybase+Pe.y);this._dirtyRowService.markDirty(Pe.y),Pe.x&&Ee-Te>0&&ut.getWidth(Pe.x-1)===2&&ut.setCellFromCodePoint(Pe.x-1,0,1,Ye.fg,Ye.bg,Ye.extended);for(var Ge=Te;Ge<Ee;++Ge){if(Oe=ke[Ge],je=this._unicodeService.wcwidth(Oe),Oe<127&&Qe){var ze=Qe[String.fromCharCode(Oe)];ze&&(Oe=ze.charCodeAt(0))}if(Xe&&this._onA11yChar.fire(E.stringFromCodePoint(Oe)),je||!Pe.x){if(Pe.x+je-1>=ot){if(He){for(;Pe.x<ot;)ut.setCellFromCodePoint(Pe.x++,0,1,Ye.fg,Ye.bg,Ye.extended);Pe.x=0,Pe.y++,Pe.y===Pe.scrollBottom+1?(Pe.y--,this._onRequestScroll.fire(this._eraseAttrData(),!0)):(Pe.y>=this._bufferService.rows&&(Pe.y=this._bufferService.rows-1),Pe.lines.get(Pe.ybase+Pe.y).isWrapped=!0),ut=Pe.lines.get(Pe.ybase+Pe.y)}else if(Pe.x=ot-1,je===2)continue}if(rt&&(ut.insertCells(Pe.x,je,Pe.getNullCell(Ye),Ye),ut.getWidth(ot-1)===2&&ut.setCellFromCodePoint(ot-1,x.NULL_CELL_CODE,x.NULL_CELL_WIDTH,Ye.fg,Ye.bg,Ye.extended)),ut.setCellFromCodePoint(Pe.x++,Oe,je,Ye.fg,Ye.bg,Ye.extended),je>0)for(;--je;)ut.setCellFromCodePoint(Pe.x++,0,0,Ye.fg,Ye.bg,Ye.extended)}else ut.getWidth(Pe.x-1)?ut.addCodepointToCell(Pe.x-1,Oe):ut.addCodepointToCell(Pe.x-2,Oe)}Ee-Te>0&&(ut.loadCell(Pe.x-1,this._workCell),this._workCell.getWidth()===2||this._workCell.getCode()>65535?this._parser.precedingCodepoint=0:this._workCell.isCombined()?this._parser.precedingCodepoint=this._workCell.getChars().charCodeAt(0):this._parser.precedingCodepoint=this._workCell.content),Pe.x<ot&&Ee-Te>0&&ut.getWidth(Pe.x)===0&&!ut.hasContent(Pe.x)&&ut.setCellFromCodePoint(Pe.x,0,1,Ye.fg,Ye.bg,Ye.extended),this._dirtyRowService.markDirty(Pe.y)},pe.prototype.addCsiHandler=function(ke,Te){var Ee=this;return ke.final!=="t"||ke.prefix||ke.intermediates?this._parser.addCsiHandler(ke,Te):this._parser.addCsiHandler(ke,function(Oe){return!me(Oe.params[0],Ee._optionsService.options.windowOptions)||Te(Oe)})},pe.prototype.addDcsHandler=function(ke,Te){return this._parser.addDcsHandler(ke,new ve.DcsHandler(Te))},pe.prototype.addEscHandler=function(ke,Te){return this._parser.addEscHandler(ke,Te)},pe.prototype.addOscHandler=function(ke,Te){return this._parser.addOscHandler(ke,new oe.OscHandler(Te))},pe.prototype.bell=function(){this._onRequestBell.fire()},pe.prototype.lineFeed=function(){var ke=this._bufferService.buffer;this._dirtyRowService.markDirty(ke.y),this._optionsService.options.convertEol&&(ke.x=0),ke.y++,ke.y===ke.scrollBottom+1?(ke.y--,this._onRequestScroll.fire(this._eraseAttrData())):ke.y>=this._bufferService.rows&&(ke.y=this._bufferService.rows-1),ke.x>=this._bufferService.cols&&ke.x--,this._dirtyRowService.markDirty(ke.y),this._onLineFeed.fire()},pe.prototype.carriageReturn=function(){this._bufferService.buffer.x=0},pe.prototype.backspace=function(){var ke,Te=this._bufferService.buffer;if(!this._coreService.decPrivateModes.reverseWraparound)return this._restrictCursor(),void(Te.x>0&&Te.x--);if(this._restrictCursor(this._bufferService.cols),Te.x>0)Te.x--;else if(Te.x===0&&Te.y>Te.scrollTop&&Te.y<=Te.scrollBottom&&(!((ke=Te.lines.get(Te.ybase+Te.y))===null||ke===void 0)&&ke.isWrapped)){Te.lines.get(Te.ybase+Te.y).isWrapped=!1,Te.y--,Te.x=this._bufferService.cols-1;var Ee=Te.lines.get(Te.ybase+Te.y);Ee.hasWidth(Te.x)&&!Ee.hasContent(Te.x)&&Te.x--}this._restrictCursor()},pe.prototype.tab=function(){if(!(this._bufferService.buffer.x>=this._bufferService.cols)){var ke=this._bufferService.buffer.x;this._bufferService.buffer.x=this._bufferService.buffer.nextStop(),this._optionsService.options.screenReaderMode&&this._onA11yTab.fire(this._bufferService.buffer.x-ke)}},pe.prototype.shiftOut=function(){this._charsetService.setgLevel(1)},pe.prototype.shiftIn=function(){this._charsetService.setgLevel(0)},pe.prototype._restrictCursor=function(ke){ke===void 0&&(ke=this._bufferService.cols-1),this._bufferService.buffer.x=Math.min(ke,Math.max(0,this._bufferService.buffer.x)),this._bufferService.buffer.y=this._coreService.decPrivateModes.origin?Math.min(this._bufferService.buffer.scrollBottom,Math.max(this._bufferService.buffer.scrollTop,this._bufferService.buffer.y)):Math.min(this._bufferService.rows-1,Math.max(0,this._bufferService.buffer.y)),this._dirtyRowService.markDirty(this._bufferService.buffer.y)},pe.prototype._setCursor=function(ke,Te){this._dirtyRowService.markDirty(this._bufferService.buffer.y),this._coreService.decPrivateModes.origin?(this._bufferService.buffer.x=ke,this._bufferService.buffer.y=this._bufferService.buffer.scrollTop+Te):(this._bufferService.buffer.x=ke,this._bufferService.buffer.y=Te),this._restrictCursor(),this._dirtyRowService.markDirty(this._bufferService.buffer.y)},pe.prototype._moveCursor=function(ke,Te){this._restrictCursor(),this._setCursor(this._bufferService.buffer.x+ke,this._bufferService.buffer.y+Te)},pe.prototype.cursorUp=function(ke){var Te=this._bufferService.buffer.y-this._bufferService.buffer.scrollTop;Te>=0?this._moveCursor(0,-Math.min(Te,ke.params[0]||1)):this._moveCursor(0,-(ke.params[0]||1))},pe.prototype.cursorDown=function(ke){var Te=this._bufferService.buffer.scrollBottom-this._bufferService.buffer.y;Te>=0?this._moveCursor(0,Math.min(Te,ke.params[0]||1)):this._moveCursor(0,ke.params[0]||1)},pe.prototype.cursorForward=function(ke){this._moveCursor(ke.params[0]||1,0)},pe.prototype.cursorBackward=function(ke){this._moveCursor(-(ke.params[0]||1),0)},pe.prototype.cursorNextLine=function(ke){this.cursorDown(ke),this._bufferService.buffer.x=0},pe.prototype.cursorPrecedingLine=function(ke){this.cursorUp(ke),this._bufferService.buffer.x=0},pe.prototype.cursorCharAbsolute=function(ke){this._setCursor((ke.params[0]||1)-1,this._bufferService.buffer.y)},pe.prototype.cursorPosition=function(ke){this._setCursor(ke.length>=2?(ke.params[1]||1)-1:0,(ke.params[0]||1)-1)},pe.prototype.charPosAbsolute=function(ke){this._setCursor((ke.params[0]||1)-1,this._bufferService.buffer.y)},pe.prototype.hPositionRelative=function(ke){this._moveCursor(ke.params[0]||1,0)},pe.prototype.linePosAbsolute=function(ke){this._setCursor(this._bufferService.buffer.x,(ke.params[0]||1)-1)},pe.prototype.vPositionRelative=function(ke){this._moveCursor(0,ke.params[0]||1)},pe.prototype.hVPosition=function(ke){this.cursorPosition(ke)},pe.prototype.tabClear=function(ke){var Te=ke.params[0];Te===0?delete this._bufferService.buffer.tabs[this._bufferService.buffer.x]:Te===3&&(this._bufferService.buffer.tabs={})},pe.prototype.cursorForwardTab=function(ke){if(!(this._bufferService.buffer.x>=this._bufferService.cols))for(var Te=ke.params[0]||1;Te--;)this._bufferService.buffer.x=this._bufferService.buffer.nextStop()},pe.prototype.cursorBackwardTab=function(ke){if(!(this._bufferService.buffer.x>=this._bufferService.cols))for(var Te=ke.params[0]||1,Ee=this._bufferService.buffer;Te--;)Ee.x=Ee.prevStop()},pe.prototype._eraseInBufferLine=function(ke,Te,Ee,Oe){Oe===void 0&&(Oe=!1);var je=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+ke);je.replaceCells(Te,Ee,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),Oe&&(je.isWrapped=!1)},pe.prototype._resetBufferLine=function(ke){var Te=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+ke);Te.fill(this._bufferService.buffer.getNullCell(this._eraseAttrData())),Te.isWrapped=!1},pe.prototype.eraseInDisplay=function(ke){var Te;switch(this._restrictCursor(),ke.params[0]){case 0:for(Te=this._bufferService.buffer.y,this._dirtyRowService.markDirty(Te),this._eraseInBufferLine(Te++,this._bufferService.buffer.x,this._bufferService.cols,this._bufferService.buffer.x===0);Te<this._bufferService.rows;Te++)this._resetBufferLine(Te);this._dirtyRowService.markDirty(Te);break;case 1:for(Te=this._bufferService.buffer.y,this._dirtyRowService.markDirty(Te),this._eraseInBufferLine(Te,0,this._bufferService.buffer.x+1,!0),this._bufferService.buffer.x+1>=this._bufferService.cols&&(this._bufferService.buffer.lines.get(Te+1).isWrapped=!1);Te--;)this._resetBufferLine(Te);this._dirtyRowService.markDirty(0);break;case 2:for(Te=this._bufferService.rows,this._dirtyRowService.markDirty(Te-1);Te--;)this._resetBufferLine(Te);this._dirtyRowService.markDirty(0);break;case 3:var Ee=this._bufferService.buffer.lines.length-this._bufferService.rows;Ee>0&&(this._bufferService.buffer.lines.trimStart(Ee),this._bufferService.buffer.ybase=Math.max(this._bufferService.buffer.ybase-Ee,0),this._bufferService.buffer.ydisp=Math.max(this._bufferService.buffer.ydisp-Ee,0),this._onScroll.fire(0))}},pe.prototype.eraseInLine=function(ke){switch(this._restrictCursor(),ke.params[0]){case 0:this._eraseInBufferLine(this._bufferService.buffer.y,this._bufferService.buffer.x,this._bufferService.cols);break;case 1:this._eraseInBufferLine(this._bufferService.buffer.y,0,this._bufferService.buffer.x+1);break;case 2:this._eraseInBufferLine(this._bufferService.buffer.y,0,this._bufferService.cols)}this._dirtyRowService.markDirty(this._bufferService.buffer.y)},pe.prototype.insertLines=function(ke){this._restrictCursor();var Te=ke.params[0]||1,Ee=this._bufferService.buffer;if(!(Ee.y>Ee.scrollBottom||Ee.y<Ee.scrollTop)){for(var Oe=Ee.ybase+Ee.y,je=this._bufferService.rows-1-Ee.scrollBottom,Pe=this._bufferService.rows-1+Ee.ybase-je+1;Te--;)Ee.lines.splice(Pe-1,1),Ee.lines.splice(Oe,0,Ee.getBlankLine(this._eraseAttrData()));this._dirtyRowService.markRangeDirty(Ee.y,Ee.scrollBottom),Ee.x=0}},pe.prototype.deleteLines=function(ke){this._restrictCursor();var Te=ke.params[0]||1,Ee=this._bufferService.buffer;if(!(Ee.y>Ee.scrollBottom||Ee.y<Ee.scrollTop)){var Oe,je=Ee.ybase+Ee.y;for(Oe=this._bufferService.rows-1-Ee.scrollBottom,Oe=this._bufferService.rows-1+Ee.ybase-Oe;Te--;)Ee.lines.splice(je,1),Ee.lines.splice(Oe,0,Ee.getBlankLine(this._eraseAttrData()));this._dirtyRowService.markRangeDirty(Ee.y,Ee.scrollBottom),Ee.x=0}},pe.prototype.insertChars=function(ke){this._restrictCursor();var Te=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+this._bufferService.buffer.y);Te&&(Te.insertCells(this._bufferService.buffer.x,ke.params[0]||1,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowService.markDirty(this._bufferService.buffer.y))},pe.prototype.deleteChars=function(ke){this._restrictCursor();var Te=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+this._bufferService.buffer.y);Te&&(Te.deleteCells(this._bufferService.buffer.x,ke.params[0]||1,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowService.markDirty(this._bufferService.buffer.y))},pe.prototype.scrollUp=function(ke){for(var Te=ke.params[0]||1,Ee=this._bufferService.buffer;Te--;)Ee.lines.splice(Ee.ybase+Ee.scrollTop,1),Ee.lines.splice(Ee.ybase+Ee.scrollBottom,0,Ee.getBlankLine(this._eraseAttrData()));this._dirtyRowService.markRangeDirty(Ee.scrollTop,Ee.scrollBottom)},pe.prototype.scrollDown=function(ke){for(var Te=ke.params[0]||1,Ee=this._bufferService.buffer;Te--;)Ee.lines.splice(Ee.ybase+Ee.scrollBottom,1),Ee.lines.splice(Ee.ybase+Ee.scrollTop,0,Ee.getBlankLine(b.DEFAULT_ATTR_DATA));this._dirtyRowService.markRangeDirty(Ee.scrollTop,Ee.scrollBottom)},pe.prototype.scrollLeft=function(ke){var Te=this._bufferService.buffer;if(!(Te.y>Te.scrollBottom||Te.y<Te.scrollTop)){for(var Ee=ke.params[0]||1,Oe=Te.scrollTop;Oe<=Te.scrollBottom;++Oe){var je=Te.lines.get(Te.ybase+Oe);je.deleteCells(0,Ee,Te.getNullCell(this._eraseAttrData()),this._eraseAttrData()),je.isWrapped=!1}this._dirtyRowService.markRangeDirty(Te.scrollTop,Te.scrollBottom)}},pe.prototype.scrollRight=function(ke){var Te=this._bufferService.buffer;if(!(Te.y>Te.scrollBottom||Te.y<Te.scrollTop)){for(var Ee=ke.params[0]||1,Oe=Te.scrollTop;Oe<=Te.scrollBottom;++Oe){var je=Te.lines.get(Te.ybase+Oe);je.insertCells(0,Ee,Te.getNullCell(this._eraseAttrData()),this._eraseAttrData()),je.isWrapped=!1}this._dirtyRowService.markRangeDirty(Te.scrollTop,Te.scrollBottom)}},pe.prototype.insertColumns=function(ke){var Te=this._bufferService.buffer;if(!(Te.y>Te.scrollBottom||Te.y<Te.scrollTop)){for(var Ee=ke.params[0]||1,Oe=Te.scrollTop;Oe<=Te.scrollBottom;++Oe){var je=this._bufferService.buffer.lines.get(Te.ybase+Oe);je.insertCells(Te.x,Ee,Te.getNullCell(this._eraseAttrData()),this._eraseAttrData()),je.isWrapped=!1}this._dirtyRowService.markRangeDirty(Te.scrollTop,Te.scrollBottom)}},pe.prototype.deleteColumns=function(ke){var Te=this._bufferService.buffer;if(!(Te.y>Te.scrollBottom||Te.y<Te.scrollTop)){for(var Ee=ke.params[0]||1,Oe=Te.scrollTop;Oe<=Te.scrollBottom;++Oe){var je=Te.lines.get(Te.ybase+Oe);je.deleteCells(Te.x,Ee,Te.getNullCell(this._eraseAttrData()),this._eraseAttrData()),je.isWrapped=!1}this._dirtyRowService.markRangeDirty(Te.scrollTop,Te.scrollBottom)}},pe.prototype.eraseChars=function(ke){this._restrictCursor();var Te=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+this._bufferService.buffer.y);Te&&(Te.replaceCells(this._bufferService.buffer.x,this._bufferService.buffer.x+(ke.params[0]||1),this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowService.markDirty(this._bufferService.buffer.y))},pe.prototype.repeatPrecedingCharacter=function(ke){if(this._parser.precedingCodepoint){for(var Te=ke.params[0]||1,Ee=new Uint32Array(Te),Oe=0;Oe<Te;++Oe)Ee[Oe]=this._parser.precedingCodepoint;this.print(Ee,0,Ee.length)}},pe.prototype.sendDeviceAttributesPrimary=function(ke){ke.params[0]>0||(this._is("xterm")||this._is("rxvt-unicode")||this._is("screen")?this._coreService.triggerDataEvent(se.C0.ESC+"[?1;2c"):this._is("linux")&&this._coreService.triggerDataEvent(se.C0.ESC+"[?6c"))},pe.prototype.sendDeviceAttributesSecondary=function(ke){ke.params[0]>0||(this._is("xterm")?this._coreService.triggerDataEvent(se.C0.ESC+"[>0;276;0c"):this._is("rxvt-unicode")?this._coreService.triggerDataEvent(se.C0.ESC+"[>85;95;0c"):this._is("linux")?this._coreService.triggerDataEvent(ke.params[0]+"c"):this._is("screen")&&this._coreService.triggerDataEvent(se.C0.ESC+"[>83;40003;0c"))},pe.prototype._is=function(ke){return(this._optionsService.options.termName+"").indexOf(ke)===0},pe.prototype.setMode=function(ke){for(var Te=0;Te<ke.length;Te++)switch(ke.params[Te]){case 4:this._coreService.modes.insertMode=!0}},pe.prototype.setModePrivate=function(ke){for(var Te=0;Te<ke.length;Te++)switch(ke.params[Te]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!0;break;case 2:this._charsetService.setgCharset(0,te.DEFAULT_CHARSET),this._charsetService.setgCharset(1,te.DEFAULT_CHARSET),this._charsetService.setgCharset(2,te.DEFAULT_CHARSET),this._charsetService.setgCharset(3,te.DEFAULT_CHARSET);break;case 3:this._optionsService.options.windowOptions.setWinLines&&(this._bufferService.resize(132,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!0,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!0;break;case 12:break;case 45:this._coreService.decPrivateModes.reverseWraparound=!0;break;case 66:this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire();break;case 9:this._coreMouseService.activeProtocol="X10";break;case 1e3:this._coreMouseService.activeProtocol="VT200";break;case 1002:this._coreMouseService.activeProtocol="DRAG";break;case 1003:this._coreMouseService.activeProtocol="ANY";break;case 1004:this._coreService.decPrivateModes.sendFocus=!0;break;case 1005:this._logService.debug("DECSET 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="SGR";break;case 1015:this._logService.debug("DECSET 1015 not supported (see #2507)");break;case 25:this._coreService.isCursorHidden=!1;break;case 1048:this.saveCursor();break;case 1049:this.saveCursor();case 47:case 1047:this._bufferService.buffers.activateAltBuffer(this._eraseAttrData()),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(0,this._bufferService.rows-1),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!0}},pe.prototype.resetMode=function(ke){for(var Te=0;Te<ke.length;Te++)switch(ke.params[Te]){case 4:this._coreService.modes.insertMode=!1}},pe.prototype.resetModePrivate=function(ke){for(var Te=0;Te<ke.length;Te++)switch(ke.params[Te]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!1;break;case 3:this._optionsService.options.windowOptions.setWinLines&&(this._bufferService.resize(80,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!1,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!1;break;case 12:break;case 45:this._coreService.decPrivateModes.reverseWraparound=!1;break;case 66:this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire();break;case 9:case 1e3:case 1002:case 1003:this._coreMouseService.activeProtocol="NONE";break;case 1004:this._coreService.decPrivateModes.sendFocus=!1;break;case 1005:this._logService.debug("DECRST 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="DEFAULT";break;case 1015:this._logService.debug("DECRST 1015 not supported (see #2507)");break;case 25:this._coreService.isCursorHidden=!0;break;case 1048:this.restoreCursor();break;case 1049:case 47:case 1047:this._bufferService.buffers.activateNormalBuffer(),ke.params[Te]===1049&&this.restoreCursor(),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(0,this._bufferService.rows-1),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!1}},pe.prototype._updateAttrColor=function(ke,Te,Ee,Oe,je){return Te===2?(ke|=50331648,ke&=-16777216,ke|=ae.AttributeData.fromColorRGB([Ee,Oe,je])):Te===5&&(ke&=-50331904,ke|=33554432|255&Ee),ke},pe.prototype._extractColor=function(ke,Te,Ee){var Oe=[0,0,-1,0,0,0],je=0,Pe=0;do{if(Oe[Pe+je]=ke.params[Te+Pe],ke.hasSubParams(Te+Pe)){var Qe=ke.getSubParams(Te+Pe),Xe=0;do Oe[1]===5&&(je=1),Oe[Pe+Xe+1+je]=Qe[Xe];while(++Xe<Qe.length&&Xe+Pe+1+je<Oe.length);break}if(Oe[1]===5&&Pe+je>=2||Oe[1]===2&&Pe+je>=5)break;Oe[1]&&(je=1)}while(++Pe+Te<ke.length&&Pe+je<Oe.length);for(Xe=2;Xe<Oe.length;++Xe)Oe[Xe]===-1&&(Oe[Xe]=0);switch(Oe[0]){case 38:Ee.fg=this._updateAttrColor(Ee.fg,Oe[1],Oe[3],Oe[4],Oe[5]);break;case 48:Ee.bg=this._updateAttrColor(Ee.bg,Oe[1],Oe[3],Oe[4],Oe[5]);break;case 58:Ee.extended=Ee.extended.clone(),Ee.extended.underlineColor=this._updateAttrColor(Ee.extended.underlineColor,Oe[1],Oe[3],Oe[4],Oe[5])}return Pe},pe.prototype._processUnderline=function(ke,Te){Te.extended=Te.extended.clone(),(!~ke||ke>5)&&(ke=1),Te.extended.underlineStyle=ke,Te.fg|=268435456,ke===0&&(Te.fg&=-268435457),Te.updateExtended()},pe.prototype.charAttributes=function(ke){if(ke.length===1&&ke.params[0]===0)return this._curAttrData.fg=b.DEFAULT_ATTR_DATA.fg,void(this._curAttrData.bg=b.DEFAULT_ATTR_DATA.bg);for(var Te,Ee=ke.length,Oe=this._curAttrData,je=0;je<Ee;je++)(Te=ke.params[je])>=30&&Te<=37?(Oe.fg&=-50331904,Oe.fg|=16777216|Te-30):Te>=40&&Te<=47?(Oe.bg&=-50331904,Oe.bg|=16777216|Te-40):Te>=90&&Te<=97?(Oe.fg&=-50331904,Oe.fg|=16777224|Te-90):Te>=100&&Te<=107?(Oe.bg&=-50331904,Oe.bg|=16777224|Te-100):Te===0?(Oe.fg=b.DEFAULT_ATTR_DATA.fg,Oe.bg=b.DEFAULT_ATTR_DATA.bg):Te===1?Oe.fg|=134217728:Te===3?Oe.bg|=67108864:Te===4?(Oe.fg|=268435456,this._processUnderline(ke.hasSubParams(je)?ke.getSubParams(je)[0]:1,Oe)):Te===5?Oe.fg|=536870912:Te===7?Oe.fg|=67108864:Te===8?Oe.fg|=1073741824:Te===2?Oe.bg|=134217728:Te===21?this._processUnderline(2,Oe):Te===22?(Oe.fg&=-134217729,Oe.bg&=-134217729):Te===23?Oe.bg&=-67108865:Te===24?Oe.fg&=-268435457:Te===25?Oe.fg&=-536870913:Te===27?Oe.fg&=-67108865:Te===28?Oe.fg&=-1073741825:Te===39?(Oe.fg&=-67108864,Oe.fg|=16777215&b.DEFAULT_ATTR_DATA.fg):Te===49?(Oe.bg&=-67108864,Oe.bg|=16777215&b.DEFAULT_ATTR_DATA.bg):Te===38||Te===48||Te===58?je+=this._extractColor(ke,je,Oe):Te===59?(Oe.extended=Oe.extended.clone(),Oe.extended.underlineColor=-1,Oe.updateExtended()):Te===100?(Oe.fg&=-67108864,Oe.fg|=16777215&b.DEFAULT_ATTR_DATA.fg,Oe.bg&=-67108864,Oe.bg|=16777215&b.DEFAULT_ATTR_DATA.bg):this._logService.debug("Unknown SGR attribute: %d.",Te)},pe.prototype.deviceStatus=function(ke){switch(ke.params[0]){case 5:this._coreService.triggerDataEvent(se.C0.ESC+"[0n");break;case 6:var Te=this._bufferService.buffer.y+1,Ee=this._bufferService.buffer.x+1;this._coreService.triggerDataEvent(se.C0.ESC+"["+Te+";"+Ee+"R")}},pe.prototype.deviceStatusPrivate=function(ke){switch(ke.params[0]){case 6:var Te=this._bufferService.buffer.y+1,Ee=this._bufferService.buffer.x+1;this._coreService.triggerDataEvent(se.C0.ESC+"[?"+Te+";"+Ee+"R")}},pe.prototype.softReset=function(ke){this._coreService.isCursorHidden=!1,this._onRequestSyncScrollBar.fire(),this._bufferService.buffer.scrollTop=0,this._bufferService.buffer.scrollBottom=this._bufferService.rows-1,this._curAttrData=b.DEFAULT_ATTR_DATA.clone(),this._coreService.reset(),this._charsetService.reset(),this._bufferService.buffer.savedX=0,this._bufferService.buffer.savedY=this._bufferService.buffer.ybase,this._bufferService.buffer.savedCurAttrData.fg=this._curAttrData.fg,this._bufferService.buffer.savedCurAttrData.bg=this._curAttrData.bg,this._bufferService.buffer.savedCharset=this._charsetService.charset,this._coreService.decPrivateModes.origin=!1},pe.prototype.setCursorStyle=function(ke){var Te=ke.params[0]||1;switch(Te){case 1:case 2:this._optionsService.options.cursorStyle="block";break;case 3:case 4:this._optionsService.options.cursorStyle="underline";break;case 5:case 6:this._optionsService.options.cursorStyle="bar"}var Ee=Te%2==1;this._optionsService.options.cursorBlink=Ee},pe.prototype.setScrollRegion=function(ke){var Te,Ee=ke.params[0]||1;(ke.length<2||(Te=ke.params[1])>this._bufferService.rows||Te===0)&&(Te=this._bufferService.rows),Te>Ee&&(this._bufferService.buffer.scrollTop=Ee-1,this._bufferService.buffer.scrollBottom=Te-1,this._setCursor(0,0))},pe.prototype.windowOptions=function(ke){if(me(ke.params[0],this._optionsService.options.windowOptions)){var Te=ke.length>1?ke.params[1]:0;switch(ke.params[0]){case 14:Te!==2&&this._onRequestWindowsOptionsReport.fire(ue.GET_WIN_SIZE_PIXELS);break;case 16:this._onRequestWindowsOptionsReport.fire(ue.GET_CELL_SIZE_PIXELS);break;case 18:this._bufferService&&this._coreService.triggerDataEvent(se.C0.ESC+"[8;"+this._bufferService.rows+";"+this._bufferService.cols+"t");break;case 22:Te!==0&&Te!==2||(this._windowTitleStack.push(this._windowTitle),this._windowTitleStack.length>10&&this._windowTitleStack.shift()),Te!==0&&Te!==1||(this._iconNameStack.push(this._iconName),this._iconNameStack.length>10&&this._iconNameStack.shift());break;case 23:Te!==0&&Te!==2||this._windowTitleStack.length&&this.setTitle(this._windowTitleStack.pop()),Te!==0&&Te!==1||this._iconNameStack.length&&this.setIconName(this._iconNameStack.pop())}}},pe.prototype.saveCursor=function(ke){this._bufferService.buffer.savedX=this._bufferService.buffer.x,this._bufferService.buffer.savedY=this._bufferService.buffer.ybase+this._bufferService.buffer.y,this._bufferService.buffer.savedCurAttrData.fg=this._curAttrData.fg,this._bufferService.buffer.savedCurAttrData.bg=this._curAttrData.bg,this._bufferService.buffer.savedCharset=this._charsetService.charset},pe.prototype.restoreCursor=function(ke){this._bufferService.buffer.x=this._bufferService.buffer.savedX||0,this._bufferService.buffer.y=Math.max(this._bufferService.buffer.savedY-this._bufferService.buffer.ybase,0),this._curAttrData.fg=this._bufferService.buffer.savedCurAttrData.fg,this._curAttrData.bg=this._bufferService.buffer.savedCurAttrData.bg,this._charsetService.charset=this._savedCharset,this._bufferService.buffer.savedCharset&&(this._charsetService.charset=this._bufferService.buffer.savedCharset),this._restrictCursor()},pe.prototype.setTitle=function(ke){this._windowTitle=ke,this._onTitleChange.fire(ke)},pe.prototype.setIconName=function(ke){this._iconName=ke},pe.prototype.nextLine=function(){this._bufferService.buffer.x=0,this.index()},pe.prototype.keypadApplicationMode=function(){this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire()},pe.prototype.keypadNumericMode=function(){this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire()},pe.prototype.selectDefaultCharset=function(){this._charsetService.setgLevel(0),this._charsetService.setgCharset(0,te.DEFAULT_CHARSET)},pe.prototype.selectCharset=function(ke){ke.length===2?ke[0]!=="/"&&this._charsetService.setgCharset(ye[ke[0]],te.CHARSETS[ke[1]]||te.DEFAULT_CHARSET):this.selectDefaultCharset()},pe.prototype.index=function(){this._restrictCursor();var ke=this._bufferService.buffer;this._bufferService.buffer.y++,ke.y===ke.scrollBottom+1?(ke.y--,this._onRequestScroll.fire(this._eraseAttrData())):ke.y>=this._bufferService.rows&&(ke.y=this._bufferService.rows-1),this._restrictCursor()},pe.prototype.tabSet=function(){this._bufferService.buffer.tabs[this._bufferService.buffer.x]=!0},pe.prototype.reverseIndex=function(){this._restrictCursor();var ke=this._bufferService.buffer;if(ke.y===ke.scrollTop){var Te=ke.scrollBottom-ke.scrollTop;ke.lines.shiftElements(ke.ybase+ke.y,Te,1),ke.lines.set(ke.ybase+ke.y,ke.getBlankLine(this._eraseAttrData())),this._dirtyRowService.markRangeDirty(ke.scrollTop,ke.scrollBottom)}else ke.y--,this._restrictCursor()},pe.prototype.fullReset=function(){this._parser.reset(),this._onRequestReset.fire()},pe.prototype.reset=function(){this._curAttrData=b.DEFAULT_ATTR_DATA.clone(),this._eraseAttrDataInternal=b.DEFAULT_ATTR_DATA.clone()},pe.prototype._eraseAttrData=function(){return this._eraseAttrDataInternal.bg&=-67108864,this._eraseAttrDataInternal.bg|=67108863&this._curAttrData.bg,this._eraseAttrDataInternal},pe.prototype.setgLevel=function(ke){this._charsetService.setgLevel(ke)},pe.prototype.screenAlignmentPattern=function(){var ke=new re.CellData;ke.content=1<<22|69,ke.fg=this._curAttrData.fg,ke.bg=this._curAttrData.bg;var Te=this._bufferService.buffer;this._setCursor(0,0);for(var Ee=0;Ee<this._bufferService.rows;++Ee){var Oe=Te.ybase+Te.y+Ee,je=Te.lines.get(Oe);je&&(je.fill(ke),je.isWrapped=!1)}this._dirtyRowService.markAllDirty(),this._setCursor(0,0)},pe}(ee.Disposable);be.InputHandler=_e},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.DEFAULT_CHARSET=be.CHARSETS=void 0,be.CHARSETS={},be.DEFAULT_CHARSET=be.CHARSETS.B,be.CHARSETS[0]={"`":"\u25C6",a:"\u2592",b:"\u2409",c:"\u240C",d:"\u240D",e:"\u240A",f:"\xB0",g:"\xB1",h:"\u2424",i:"\u240B",j:"\u2518",k:"\u2510",l:"\u250C",m:"\u2514",n:"\u253C",o:"\u23BA",p:"\u23BB",q:"\u2500",r:"\u23BC",s:"\u23BD",t:"\u251C",u:"\u2524",v:"\u2534",w:"\u252C",x:"\u2502",y:"\u2264",z:"\u2265","{":"\u03C0","|":"\u2260","}":"\xA3","~":"\xB7"},be.CHARSETS.A={"#":"\xA3"},be.CHARSETS.B=void 0,be.CHARSETS[4]={"#":"\xA3","@":"\xBE","[":"ij","\\":"\xBD","]":"|","{":"\xA8","|":"f","}":"\xBC","~":"\xB4"},be.CHARSETS.C=be.CHARSETS[5]={"[":"\xC4","\\":"\xD6","]":"\xC5","^":"\xDC","`":"\xE9","{":"\xE4","|":"\xF6","}":"\xE5","~":"\xFC"},be.CHARSETS.R={"#":"\xA3","@":"\xE0","[":"\xB0","\\":"\xE7","]":"\xA7","{":"\xE9","|":"\xF9","}":"\xE8","~":"\xA8"},be.CHARSETS.Q={"@":"\xE0","[":"\xE2","\\":"\xE7","]":"\xEA","^":"\xEE","`":"\xF4","{":"\xE9","|":"\xF9","}":"\xE8","~":"\xFB"},be.CHARSETS.K={"@":"\xA7","[":"\xC4","\\":"\xD6","]":"\xDC","{":"\xE4","|":"\xF6","}":"\xFC","~":"\xDF"},be.CHARSETS.Y={"#":"\xA3","@":"\xA7","[":"\xB0","\\":"\xE7","]":"\xE9","`":"\xF9","{":"\xE0","|":"\xF2","}":"\xE8","~":"\xEC"},be.CHARSETS.E=be.CHARSETS[6]={"@":"\xC4","[":"\xC6","\\":"\xD8","]":"\xC5","^":"\xDC","`":"\xE4","{":"\xE6","|":"\xF8","}":"\xE5","~":"\xFC"},be.CHARSETS.Z={"#":"\xA3","@":"\xA7","[":"\xA1","\\":"\xD1","]":"\xBF","{":"\xB0","|":"\xF1","}":"\xE7"},be.CHARSETS.H=be.CHARSETS[7]={"@":"\xC9","[":"\xC4","\\":"\xD6","]":"\xC5","^":"\xDC","`":"\xE9","{":"\xE4","|":"\xF6","}":"\xE5","~":"\xFC"},be.CHARSETS["="]={"#":"\xF9","@":"\xE0","[":"\xE9","\\":"\xE7","]":"\xEA","^":"\xEE",_:"\xE8","`":"\xF4","{":"\xE4","|":"\xF6","}":"\xFC","~":"\xFB"}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.Params=void 0;var ie=function(){function Ce(ue,se){if(ue===void 0&&(ue=32),se===void 0&&(se=32),this.maxLength=ue,this.maxSubParamsLength=se,se>256)throw new Error("maxSubParamsLength must not be greater than 256");this.params=new Int32Array(ue),this.length=0,this._subParams=new Int32Array(se),this._subParamsLength=0,this._subParamsIdx=new Uint16Array(ue),this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}return Ce.fromArray=function(ue){var se=new Ce;if(!ue.length)return se;for(var te=ue[0]instanceof Array?1:0;te<ue.length;++te){var le=ue[te];if(le instanceof Array)for(var ee=0;ee<le.length;++ee)se.addSubParam(le[ee]);else se.addParam(le)}return se},Ce.prototype.clone=function(){var ue=new Ce(this.maxLength,this.maxSubParamsLength);return ue.params.set(this.params),ue.length=this.length,ue._subParams.set(this._subParams),ue._subParamsLength=this._subParamsLength,ue._subParamsIdx.set(this._subParamsIdx),ue._rejectDigits=this._rejectDigits,ue._rejectSubDigits=this._rejectSubDigits,ue._digitIsSub=this._digitIsSub,ue},Ce.prototype.toArray=function(){for(var ue=[],se=0;se<this.length;++se){ue.push(this.params[se]);var te=this._subParamsIdx[se]>>8,le=255&this._subParamsIdx[se];le-te>0&&ue.push(Array.prototype.slice.call(this._subParams,te,le))}return ue},Ce.prototype.reset=function(){this.length=0,this._subParamsLength=0,this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1},Ce.prototype.addParam=function(ue){if(this._digitIsSub=!1,this.length>=this.maxLength)this._rejectDigits=!0;else{if(ue<-1)throw new Error("values lesser than -1 are not allowed");this._subParamsIdx[this.length]=this._subParamsLength<<8|this._subParamsLength,this.params[this.length++]=ue>2147483647?2147483647:ue}},Ce.prototype.addSubParam=function(ue){if(this._digitIsSub=!0,this.length)if(this._rejectDigits||this._subParamsLength>=this.maxSubParamsLength)this._rejectSubDigits=!0;else{if(ue<-1)throw new Error("values lesser than -1 are not allowed");this._subParams[this._subParamsLength++]=ue>2147483647?2147483647:ue,this._subParamsIdx[this.length-1]++}},Ce.prototype.hasSubParams=function(ue){return(255&this._subParamsIdx[ue])-(this._subParamsIdx[ue]>>8)>0},Ce.prototype.getSubParams=function(ue){var se=this._subParamsIdx[ue]>>8,te=255&this._subParamsIdx[ue];return te-se>0?this._subParams.subarray(se,te):null},Ce.prototype.getSubParamsAll=function(){for(var ue={},se=0;se<this.length;++se){var te=this._subParamsIdx[se]>>8,le=255&this._subParamsIdx[se];le-te>0&&(ue[se]=this._subParams.slice(te,le))}return ue},Ce.prototype.addDigit=function(ue){var se;if(!(this._rejectDigits||!(se=this._digitIsSub?this._subParamsLength:this.length)||this._digitIsSub&&this._rejectSubDigits)){var te=this._digitIsSub?this._subParams:this.params,le=te[se-1];te[se-1]=~le?Math.min(10*le+ue,2147483647):ue}},Ce}();be.Params=ie},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.OscHandler=be.OscParser=void 0;var ie=ce(23),Ce=ce(8),ue=function(){function te(){this._state=0,this._id=-1,this._handlers=Object.create(null),this._handlerFb=function(){}}return te.prototype.addHandler=function(le,ee){this._handlers[le]===void 0&&(this._handlers[le]=[]);var ne=this._handlers[le];return ne.push(ee),{dispose:function(){var E=ne.indexOf(ee);E!==-1&&ne.splice(E,1)}}},te.prototype.setHandler=function(le,ee){this._handlers[le]=[ee]},te.prototype.clearHandler=function(le){this._handlers[le]&&delete this._handlers[le]},te.prototype.setHandlerFallback=function(le){this._handlerFb=le},te.prototype.dispose=function(){this._handlers=Object.create(null),this._handlerFb=function(){}},te.prototype.reset=function(){this._state===2&&this.end(!1),this._id=-1,this._state=0},te.prototype._start=function(){var le=this._handlers[this._id];if(le)for(var ee=le.length-1;ee>=0;ee--)le[ee].start();else this._handlerFb(this._id,"START")},te.prototype._put=function(le,ee,ne){var E=this._handlers[this._id];if(E)for(var b=E.length-1;b>=0;b--)E[b].put(le,ee,ne);else this._handlerFb(this._id,"PUT",Ce.utf32ToString(le,ee,ne))},te.prototype._end=function(le){var ee=this._handlers[this._id];if(ee){for(var ne=ee.length-1;ne>=0&&ee[ne].end(le)===!1;ne--);for(ne--;ne>=0;ne--)ee[ne].end(!1)}else this._handlerFb(this._id,"END",le)},te.prototype.start=function(){this.reset(),this._id=-1,this._state=1},te.prototype.put=function(le,ee,ne){if(this._state!==3){if(this._state===1)for(;ee<ne;){var E=le[ee++];if(E===59){this._state=2,this._start();break}if(E<48||57<E)return void(this._state=3);this._id===-1&&(this._id=0),this._id=10*this._id+E-48}this._state===2&&ne-ee>0&&this._put(le,ee,ne)}},te.prototype.end=function(le){this._state!==0&&(this._state!==3&&(this._state===1&&this._start(),this._end(le)),this._id=-1,this._state=0)},te}();be.OscParser=ue;var se=function(){function te(le){this._handler=le,this._data="",this._hitLimit=!1}return te.prototype.start=function(){this._data="",this._hitLimit=!1},te.prototype.put=function(le,ee,ne){this._hitLimit||(this._data+=Ce.utf32ToString(le,ee,ne),this._data.length>ie.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))},te.prototype.end=function(le){var ee;return this._hitLimit?ee=!1:le&&(ee=this._handler(this._data)),this._data="",this._hitLimit=!1,ee},te}();be.OscHandler=se},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.PAYLOAD_LIMIT=void 0,be.PAYLOAD_LIMIT=1e7},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.DcsHandler=be.DcsParser=void 0;var ie=ce(8),Ce=ce(21),ue=ce(23),se=[],te=function(){function ee(){this._handlers=Object.create(null),this._active=se,this._ident=0,this._handlerFb=function(){}}return ee.prototype.dispose=function(){this._handlers=Object.create(null),this._handlerFb=function(){}},ee.prototype.addHandler=function(ne,E){this._handlers[ne]===void 0&&(this._handlers[ne]=[]);var b=this._handlers[ne];return b.push(E),{dispose:function(){var z=b.indexOf(E);z!==-1&&b.splice(z,1)}}},ee.prototype.setHandler=function(ne,E){this._handlers[ne]=[E]},ee.prototype.clearHandler=function(ne){this._handlers[ne]&&delete this._handlers[ne]},ee.prototype.setHandlerFallback=function(ne){this._handlerFb=ne},ee.prototype.reset=function(){this._active.length&&this.unhook(!1),this._active=se,this._ident=0},ee.prototype.hook=function(ne,E){if(this.reset(),this._ident=ne,this._active=this._handlers[ne]||se,this._active.length)for(var b=this._active.length-1;b>=0;b--)this._active[b].hook(E);else this._handlerFb(this._ident,"HOOK",E)},ee.prototype.put=function(ne,E,b){if(this._active.length)for(var z=this._active.length-1;z>=0;z--)this._active[z].put(ne,E,b);else this._handlerFb(this._ident,"PUT",ie.utf32ToString(ne,E,b))},ee.prototype.unhook=function(ne){if(this._active.length){for(var E=this._active.length-1;E>=0&&this._active[E].unhook(ne)===!1;E--);for(E--;E>=0;E--)this._active[E].unhook(!1)}else this._handlerFb(this._ident,"UNHOOK",ne);this._active=se,this._ident=0},ee}();be.DcsParser=te;var le=function(){function ee(ne){this._handler=ne,this._data="",this._hitLimit=!1}return ee.prototype.hook=function(ne){this._params=ne.clone(),this._data="",this._hitLimit=!1},ee.prototype.put=function(ne,E,b){this._hitLimit||(this._data+=ie.utf32ToString(ne,E,b),this._data.length>ue.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))},ee.prototype.unhook=function(ne){var E;return this._hitLimit?E=!1:ne&&(E=this._handler(this._data,this._params||new Ce.Params)),this._params=void 0,this._data="",this._hitLimit=!1,E},ee}();be.DcsHandler=le},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.removeTerminalFromCache=be.acquireCharAtlas=void 0;var ie=ce(26),Ce=ce(43),ue=[];be.acquireCharAtlas=function(se,te,le,ee,ne){for(var E=ie.generateConfig(ee,ne,se,le),b=0;b<ue.length;b++){var z=(x=ue[b]).ownedBy.indexOf(te);if(z>=0){if(ie.configEquals(x.config,E))return x.atlas;x.ownedBy.length===1?(x.atlas.dispose(),ue.splice(b,1)):x.ownedBy.splice(z,1);break}}for(b=0;b<ue.length;b++){var x=ue[b];if(ie.configEquals(x.config,E))return x.ownedBy.push(te),x.atlas}var re={atlas:new Ce.DynamicCharAtlas(document,E),config:E,ownedBy:[te]};return ue.push(re),re.atlas},be.removeTerminalFromCache=function(se){for(var te=0;te<ue.length;te++){var le=ue[te].ownedBy.indexOf(se);if(le!==-1){ue[te].ownedBy.length===1?(ue[te].atlas.dispose(),ue.splice(te,1)):ue[te].ownedBy.splice(le,1);break}}}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.is256Color=be.configEquals=be.generateConfig=void 0;var ie=ce(3);be.generateConfig=function(Ce,ue,se,te){var le={foreground:te.foreground,background:te.background,cursor:void 0,cursorAccent:void 0,selection:void 0,ansi:te.ansi.slice(0,16)};return{devicePixelRatio:window.devicePixelRatio,scaledCharWidth:Ce,scaledCharHeight:ue,fontFamily:se.fontFamily,fontSize:se.fontSize,fontWeight:se.fontWeight,fontWeightBold:se.fontWeightBold,allowTransparency:se.allowTransparency,colors:le}},be.configEquals=function(Ce,ue){for(var se=0;se<Ce.colors.ansi.length;se++)if(Ce.colors.ansi[se].rgba!==ue.colors.ansi[se].rgba)return!1;return Ce.devicePixelRatio===ue.devicePixelRatio&&Ce.fontFamily===ue.fontFamily&&Ce.fontSize===ue.fontSize&&Ce.fontWeight===ue.fontWeight&&Ce.fontWeightBold===ue.fontWeightBold&&Ce.allowTransparency===ue.allowTransparency&&Ce.scaledCharWidth===ue.scaledCharWidth&&Ce.scaledCharHeight===ue.scaledCharHeight&&Ce.colors.foreground===ue.colors.foreground&&Ce.colors.background===ue.colors.background},be.is256Color=function(Ce){return Ce<ie.DEFAULT_COLOR}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.ColorManager=be.DEFAULT_ANSI_COLORS=void 0;var ie=ce(10),Ce=ce(45),ue=ie.css.toColor("#ffffff"),se=ie.css.toColor("#000000"),te=ie.css.toColor("#ffffff"),le=ie.css.toColor("#000000"),ee={css:"rgba(255, 255, 255, 0.3)",rgba:4294967117};be.DEFAULT_ANSI_COLORS=function(){for(var E=[ie.css.toColor("#2e3436"),ie.css.toColor("#cc0000"),ie.css.toColor("#4e9a06"),ie.css.toColor("#c4a000"),ie.css.toColor("#3465a4"),ie.css.toColor("#75507b"),ie.css.toColor("#06989a"),ie.css.toColor("#d3d7cf"),ie.css.toColor("#555753"),ie.css.toColor("#ef2929"),ie.css.toColor("#8ae234"),ie.css.toColor("#fce94f"),ie.css.toColor("#729fcf"),ie.css.toColor("#ad7fa8"),ie.css.toColor("#34e2e2"),ie.css.toColor("#eeeeec")],b=[0,95,135,175,215,255],z=0;z<216;z++){var x=b[z/36%6|0],re=b[z/6%6|0],ae=b[z%6];E.push({css:ie.channels.toCss(x,re,ae),rgba:ie.channels.toRgba(x,re,ae)})}for(z=0;z<24;z++){var oe=8+10*z;E.push({css:ie.channels.toCss(oe,oe,oe),rgba:ie.channels.toRgba(oe,oe,oe)})}return E}();var ne=function(){function E(b,z){this.allowTransparency=z;var x=b.createElement("canvas");x.width=1,x.height=1;var re=x.getContext("2d");if(!re)throw new Error("Could not get rendering context");this._ctx=re,this._ctx.globalCompositeOperation="copy",this._litmusColor=this._ctx.createLinearGradient(0,0,1,1),this._contrastCache=new Ce.ColorContrastCache,this.colors={foreground:ue,background:se,cursor:te,cursorAccent:le,selectionTransparent:ee,selectionOpaque:ie.color.blend(se,ee),ansi:be.DEFAULT_ANSI_COLORS.slice(),contrastCache:this._contrastCache}}return E.prototype.onOptionsChange=function(b){b==="minimumContrastRatio"&&this._contrastCache.clear()},E.prototype.setTheme=function(b){b===void 0&&(b={}),this.colors.foreground=this._parseColor(b.foreground,ue),this.colors.background=this._parseColor(b.background,se),this.colors.cursor=this._parseColor(b.cursor,te,!0),this.colors.cursorAccent=this._parseColor(b.cursorAccent,le,!0),this.colors.selectionTransparent=this._parseColor(b.selection,ee,!0),this.colors.selectionOpaque=ie.color.blend(this.colors.background,this.colors.selectionTransparent),ie.color.isOpaque(this.colors.selectionTransparent)&&(this.colors.selectionTransparent=ie.color.opacity(this.colors.selectionTransparent,.3)),this.colors.ansi[0]=this._parseColor(b.black,be.DEFAULT_ANSI_COLORS[0]),this.colors.ansi[1]=this._parseColor(b.red,be.DEFAULT_ANSI_COLORS[1]),this.colors.ansi[2]=this._parseColor(b.green,be.DEFAULT_ANSI_COLORS[2]),this.colors.ansi[3]=this._parseColor(b.yellow,be.DEFAULT_ANSI_COLORS[3]),this.colors.ansi[4]=this._parseColor(b.blue,be.DEFAULT_ANSI_COLORS[4]),this.colors.ansi[5]=this._parseColor(b.magenta,be.DEFAULT_ANSI_COLORS[5]),this.colors.ansi[6]=this._parseColor(b.cyan,be.DEFAULT_ANSI_COLORS[6]),this.colors.ansi[7]=this._parseColor(b.white,be.DEFAULT_ANSI_COLORS[7]),this.colors.ansi[8]=this._parseColor(b.brightBlack,be.DEFAULT_ANSI_COLORS[8]),this.colors.ansi[9]=this._parseColor(b.brightRed,be.DEFAULT_ANSI_COLORS[9]),this.colors.ansi[10]=this._parseColor(b.brightGreen,be.DEFAULT_ANSI_COLORS[10]),this.colors.ansi[11]=this._parseColor(b.brightYellow,be.DEFAULT_ANSI_COLORS[11]),this.colors.ansi[12]=this._parseColor(b.brightBlue,be.DEFAULT_ANSI_COLORS[12]),this.colors.ansi[13]=this._parseColor(b.brightMagenta,be.DEFAULT_ANSI_COLORS[13]),this.colors.ansi[14]=this._parseColor(b.brightCyan,be.DEFAULT_ANSI_COLORS[14]),this.colors.ansi[15]=this._parseColor(b.brightWhite,be.DEFAULT_ANSI_COLORS[15]),this._contrastCache.clear()},E.prototype._parseColor=function(b,z,x){if(x===void 0&&(x=this.allowTransparency),b===void 0)return z;if(this._ctx.fillStyle=this._litmusColor,this._ctx.fillStyle=b,typeof this._ctx.fillStyle!="string")return console.warn("Color: "+b+" is invalid using fallback "+z.css),z;this._ctx.fillRect(0,0,1,1);var re=this._ctx.getImageData(0,0,1,1).data;if(re[3]!==255){if(!x)return console.warn("Color: "+b+" is using transparency, but allowTransparency is false. Using fallback "+z.css+"."),z;var ae=this._ctx.fillStyle.substring(5,this._ctx.fillStyle.length-1).split(",").map(function(_e){return Number(_e)}),oe=ae[0],ve=ae[1],ye=ae[2],me=ae[3],ge=Math.round(255*me);return{rgba:ie.channels.toRgba(oe,ve,ye,ge),css:b}}return{css:this._ctx.fillStyle,rgba:ie.channels.toRgba(re[0],re[1],re[2],re[3])}},E}();be.ColorManager=ne},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.throwIfFalsy=void 0,be.throwIfFalsy=function(ie){if(!ie)throw new Error("value must not be falsy");return ie}},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ne,E){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,z){b.__proto__=z}||function(b,z){for(var x in z)z.hasOwnProperty(x)&&(b[x]=z[x])})(ne,E)},function(ne,E){function b(){this.constructor=ne}ie(ne,E),ne.prototype=E===null?Object.create(E):(b.prototype=E.prototype,new b)});Object.defineProperty(be,"__esModule",{value:!0}),be.CharacterJoinerRegistry=be.JoinedCellData=void 0;var ue=ce(6),se=ce(3),te=ce(4),le=function(ne){function E(b,z,x){var re=ne.call(this)||this;return re.content=0,re.combinedData="",re.fg=b.fg,re.bg=b.bg,re.combinedData=z,re._width=x,re}return Ce(E,ne),E.prototype.isCombined=function(){return 2097152},E.prototype.getWidth=function(){return this._width},E.prototype.getChars=function(){return this.combinedData},E.prototype.getCode=function(){return 2097151},E.prototype.setFromCharData=function(b){throw new Error("not implemented")},E.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},E}(ue.AttributeData);be.JoinedCellData=le;var ee=function(){function ne(E){this._bufferService=E,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new te.CellData}return ne.prototype.registerCharacterJoiner=function(E){var b={id:this._nextCharacterJoinerId++,handler:E};return this._characterJoiners.push(b),b.id},ne.prototype.deregisterCharacterJoiner=function(E){for(var b=0;b<this._characterJoiners.length;b++)if(this._characterJoiners[b].id===E)return this._characterJoiners.splice(b,1),!0;return!1},ne.prototype.getJoinedCharacters=function(E){if(this._characterJoiners.length===0)return[];var b=this._bufferService.buffer.lines.get(E);if(!b||b.length===0)return[];for(var z=[],x=b.translateToString(!0),re=0,ae=0,oe=0,ve=b.getFg(0),ye=b.getBg(0),me=0;me<b.getTrimmedLength();me++)if(b.loadCell(me,this._workCell),this._workCell.getWidth()!==0){if(this._workCell.fg!==ve||this._workCell.bg!==ye){if(me-re>1)for(var ge=this._getJoinedRanges(x,oe,ae,b,re),_e=0;_e<ge.length;_e++)z.push(ge[_e]);re=me,oe=ae,ve=this._workCell.fg,ye=this._workCell.bg}ae+=this._workCell.getChars().length||se.WHITESPACE_CELL_CHAR.length}if(this._bufferService.cols-re>1)for(ge=this._getJoinedRanges(x,oe,ae,b,re),_e=0;_e<ge.length;_e++)z.push(ge[_e]);return z},ne.prototype._getJoinedRanges=function(E,b,z,x,re){for(var ae=E.substring(b,z),oe=this._characterJoiners[0].handler(ae),ve=1;ve<this._characterJoiners.length;ve++)for(var ye=this._characterJoiners[ve].handler(ae),me=0;me<ye.length;me++)ne._mergeRanges(oe,ye[me]);return this._stringRangesToCellRanges(oe,x,re),oe},ne.prototype._stringRangesToCellRanges=function(E,b,z){var x=0,re=!1,ae=0,oe=E[x];if(oe){for(var ve=z;ve<this._bufferService.cols;ve++){var ye=b.getWidth(ve),me=b.getString(ve).length||se.WHITESPACE_CELL_CHAR.length;if(ye!==0){if(!re&&oe[0]<=ae&&(oe[0]=ve,re=!0),oe[1]<=ae){if(oe[1]=ve,!(oe=E[++x]))break;oe[0]<=ae?(oe[0]=ve,re=!0):re=!1}ae+=me}}oe&&(oe[1]=this._bufferService.cols)}},ne._mergeRanges=function(E,b){for(var z=!1,x=0;x<E.length;x++){var re=E[x];if(z){if(b[1]<=re[0])return E[x-1][1]=b[1],E;if(b[1]<=re[1])return E[x-1][1]=Math.max(b[1],re[1]),E.splice(x,1),E;E.splice(x,1),x--}else{if(b[1]<=re[0])return E.splice(x,0,b),E;if(b[1]<=re[1])return re[0]=Math.min(b[0],re[0]),E;b[0]<re[1]&&(re[0]=Math.min(b[0],re[0]),z=!0)}}return z?E[E.length-1][1]=b[1]:E.push(b),E},ne}();be.CharacterJoinerRegistry=ee},function(Mt,be,ce){"use strict";function ie(Ce,ue){var se=ue.getBoundingClientRect();return[Ce.clientX-se.left,Ce.clientY-se.top]}Object.defineProperty(be,"__esModule",{value:!0}),be.getRawByteCoords=be.getCoords=be.getCoordsRelativeToElement=void 0,be.getCoordsRelativeToElement=ie,be.getCoords=function(Ce,ue,se,te,le,ee,ne,E){if(le){var b=ie(Ce,ue);if(b)return b[0]=Math.ceil((b[0]+(E?ee/2:0))/ee),b[1]=Math.ceil(b[1]/ne),b[0]=Math.min(Math.max(b[0],1),se+(E?1:0)),b[1]=Math.min(Math.max(b[1],1),te),b}},be.getRawByteCoords=function(Ce){if(Ce)return{x:Ce[0]+32,y:Ce[1]+32}}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.RenderDebouncer=void 0;var ie=function(){function Ce(ue){this._renderCallback=ue}return Ce.prototype.dispose=function(){this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},Ce.prototype.refresh=function(ue,se,te){var le=this;this._rowCount=te,ue=ue!==void 0?ue:0,se=se!==void 0?se:this._rowCount-1,this._rowStart=this._rowStart!==void 0?Math.min(this._rowStart,ue):ue,this._rowEnd=this._rowEnd!==void 0?Math.max(this._rowEnd,se):se,this._animationFrame||(this._animationFrame=window.requestAnimationFrame(function(){return le._innerRefresh()}))},Ce.prototype._innerRefresh=function(){if(this._rowStart!==void 0&&this._rowEnd!==void 0&&this._rowCount!==void 0){var ue=Math.max(this._rowStart,0),se=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._animationFrame=void 0,this._renderCallback(ue,se)}},Ce}();be.RenderDebouncer=ie},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(se,te){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(le,ee){le.__proto__=ee}||function(le,ee){for(var ne in ee)ee.hasOwnProperty(ne)&&(le[ne]=ee[ne])})(se,te)},function(se,te){function le(){this.constructor=se}ie(se,te),se.prototype=te===null?Object.create(te):(le.prototype=te.prototype,new le)});Object.defineProperty(be,"__esModule",{value:!0}),be.ScreenDprMonitor=void 0;var ue=function(se){function te(){var le=se!==null&&se.apply(this,arguments)||this;return le._currentDevicePixelRatio=window.devicePixelRatio,le}return Ce(te,se),te.prototype.setListener=function(le){var ee=this;this._listener&&this.clearListener(),this._listener=le,this._outerListener=function(){ee._listener&&(ee._listener(window.devicePixelRatio,ee._currentDevicePixelRatio),ee._updateDpr())},this._updateDpr()},te.prototype.dispose=function(){se.prototype.dispose.call(this),this.clearListener()},te.prototype._updateDpr=function(){var le;this._outerListener&&((le=this._resolutionMediaMatchList)===null||le===void 0||le.removeListener(this._outerListener),this._currentDevicePixelRatio=window.devicePixelRatio,this._resolutionMediaMatchList=window.matchMedia("screen and (resolution: "+window.devicePixelRatio+"dppx)"),this._resolutionMediaMatchList.addListener(this._outerListener))},te.prototype.clearListener=function(){this._resolutionMediaMatchList&&this._listener&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._resolutionMediaMatchList=void 0,this._listener=void 0,this._outerListener=void 0)},te}(ce(2).Disposable);be.ScreenDprMonitor=ue},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.clone=void 0,be.clone=function ie(Ce,ue){if(ue===void 0&&(ue=5),typeof Ce!="object")return Ce;var se=Array.isArray(Ce)?[]:{};for(var te in Ce)se[te]=ue<=1?Ce[te]:Ce[te]?ie(Ce[te],ue-1):Ce[te];return se}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.Terminal=void 0;var ie=ce(4),Ce=ce(35),ue=ce(18),se=ce(0),te=ce(83),le=function(){function x(re){this._core=new Ce.Terminal(re),this._addonManager=new te.AddonManager}return x.prototype._checkProposedApi=function(){if(!this._core.optionsService.options.allowProposedApi)throw new Error("You must set the allowProposedApi option to true to use proposed API")},Object.defineProperty(x.prototype,"onCursorMove",{get:function(){return this._core.onCursorMove},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onLineFeed",{get:function(){return this._core.onLineFeed},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onSelectionChange",{get:function(){return this._core.onSelectionChange},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onData",{get:function(){return this._core.onData},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onBinary",{get:function(){return this._core.onBinary},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onTitleChange",{get:function(){return this._core.onTitleChange},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onScroll",{get:function(){return this._core.onScroll},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onKey",{get:function(){return this._core.onKey},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onRender",{get:function(){return this._core.onRender},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"onResize",{get:function(){return this._core.onResize},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"element",{get:function(){return this._core.element},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"parser",{get:function(){return this._checkProposedApi(),this._parser||(this._parser=new b(this._core)),this._parser},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"unicode",{get:function(){return this._checkProposedApi(),new z(this._core)},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"textarea",{get:function(){return this._core.textarea},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"rows",{get:function(){return this._core.rows},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"cols",{get:function(){return this._core.cols},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"buffer",{get:function(){return this._checkProposedApi(),new ne(this._core.buffers)},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"markers",{get:function(){return this._checkProposedApi(),this._core.markers},enumerable:!1,configurable:!0}),x.prototype.blur=function(){this._core.blur()},x.prototype.focus=function(){this._core.focus()},x.prototype.resize=function(re,ae){this._verifyIntegers(re,ae),this._core.resize(re,ae)},x.prototype.open=function(re){this._core.open(re)},x.prototype.attachCustomKeyEventHandler=function(re){this._core.attachCustomKeyEventHandler(re)},x.prototype.registerLinkMatcher=function(re,ae,oe){return this._checkProposedApi(),this._core.registerLinkMatcher(re,ae,oe)},x.prototype.deregisterLinkMatcher=function(re){this._checkProposedApi(),this._core.deregisterLinkMatcher(re)},x.prototype.registerLinkProvider=function(re){return this._checkProposedApi(),this._core.registerLinkProvider(re)},x.prototype.registerCharacterJoiner=function(re){return this._checkProposedApi(),this._core.registerCharacterJoiner(re)},x.prototype.deregisterCharacterJoiner=function(re){this._checkProposedApi(),this._core.deregisterCharacterJoiner(re)},x.prototype.registerMarker=function(re){return this._checkProposedApi(),this._verifyIntegers(re),this._core.addMarker(re)},x.prototype.addMarker=function(re){return this.registerMarker(re)},x.prototype.hasSelection=function(){return this._core.hasSelection()},x.prototype.select=function(re,ae,oe){this._verifyIntegers(re,ae,oe),this._core.select(re,ae,oe)},x.prototype.getSelection=function(){return this._core.getSelection()},x.prototype.getSelectionPosition=function(){return this._core.getSelectionPosition()},x.prototype.clearSelection=function(){this._core.clearSelection()},x.prototype.selectAll=function(){this._core.selectAll()},x.prototype.selectLines=function(re,ae){this._verifyIntegers(re,ae),this._core.selectLines(re,ae)},x.prototype.dispose=function(){this._addonManager.dispose(),this._core.dispose()},x.prototype.scrollLines=function(re){this._verifyIntegers(re),this._core.scrollLines(re)},x.prototype.scrollPages=function(re){this._verifyIntegers(re),this._core.scrollPages(re)},x.prototype.scrollToTop=function(){this._core.scrollToTop()},x.prototype.scrollToBottom=function(){this._core.scrollToBottom()},x.prototype.scrollToLine=function(re){this._verifyIntegers(re),this._core.scrollToLine(re)},x.prototype.clear=function(){this._core.clear()},x.prototype.write=function(re,ae){this._core.write(re,ae)},x.prototype.writeUtf8=function(re,ae){this._core.write(re,ae)},x.prototype.writeln=function(re,ae){this._core.write(re),this._core.write(`\r
|
|
|
`,ae)},x.prototype.paste=function(re){this._core.paste(re)},x.prototype.getOption=function(re){return this._core.optionsService.getOption(re)},x.prototype.setOption=function(re,ae){this._core.optionsService.setOption(re,ae)},x.prototype.refresh=function(re,ae){this._verifyIntegers(re,ae),this._core.refresh(re,ae)},x.prototype.reset=function(){this._core.reset()},x.prototype.loadAddon=function(re){return this._addonManager.loadAddon(this,re)},Object.defineProperty(x,"strings",{get:function(){return ue},enumerable:!1,configurable:!0}),x.prototype._verifyIntegers=function(){for(var re=[],ae=0;ae<arguments.length;ae++)re[ae]=arguments[ae];for(var oe=0,ve=re;oe<ve.length;oe++){var ye=ve[oe];if(ye===1/0||isNaN(ye)||ye%1!=0)throw new Error("This API only accepts integers")}},x}();be.Terminal=le;var ee=function(){function x(re,ae){this._buffer=re,this.type=ae}return x.prototype.init=function(re){return this._buffer=re,this},Object.defineProperty(x.prototype,"cursorY",{get:function(){return this._buffer.y},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"cursorX",{get:function(){return this._buffer.x},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"viewportY",{get:function(){return this._buffer.ydisp},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"baseY",{get:function(){return this._buffer.ybase},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"length",{get:function(){return this._buffer.lines.length},enumerable:!1,configurable:!0}),x.prototype.getLine=function(re){var ae=this._buffer.lines.get(re);if(ae)return new E(ae)},x.prototype.getNullCell=function(){return new ie.CellData},x}(),ne=function(){function x(re){var ae=this;this._buffers=re,this._onBufferChange=new se.EventEmitter,this._normal=new ee(this._buffers.normal,"normal"),this._alternate=new ee(this._buffers.alt,"alternate"),this._buffers.onBufferActivate(function(){return ae._onBufferChange.fire(ae.active)})}return Object.defineProperty(x.prototype,"onBufferChange",{get:function(){return this._onBufferChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"active",{get:function(){if(this._buffers.active===this._buffers.normal)return this.normal;if(this._buffers.active===this._buffers.alt)return this.alternate;throw new Error("Active buffer is neither normal nor alternate")},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"normal",{get:function(){return this._normal.init(this._buffers.normal)},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"alternate",{get:function(){return this._alternate.init(this._buffers.alt)},enumerable:!1,configurable:!0}),x}(),E=function(){function x(re){this._line=re}return Object.defineProperty(x.prototype,"isWrapped",{get:function(){return this._line.isWrapped},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"length",{get:function(){return this._line.length},enumerable:!1,configurable:!0}),x.prototype.getCell=function(re,ae){if(!(re<0||re>=this._line.length))return ae?(this._line.loadCell(re,ae),ae):this._line.loadCell(re,new ie.CellData)},x.prototype.translateToString=function(re,ae,oe){return this._line.translateToString(re,ae,oe)},x}(),b=function(){function x(re){this._core=re}return x.prototype.registerCsiHandler=function(re,ae){return this._core.addCsiHandler(re,function(oe){return ae(oe.toArray())})},x.prototype.addCsiHandler=function(re,ae){return this.registerCsiHandler(re,ae)},x.prototype.registerDcsHandler=function(re,ae){return this._core.addDcsHandler(re,function(oe,ve){return ae(oe,ve.toArray())})},x.prototype.addDcsHandler=function(re,ae){return this.registerDcsHandler(re,ae)},x.prototype.registerEscHandler=function(re,ae){return this._core.addEscHandler(re,ae)},x.prototype.addEscHandler=function(re,ae){return this.registerEscHandler(re,ae)},x.prototype.registerOscHandler=function(re,ae){return this._core.addOscHandler(re,ae)},x.prototype.addOscHandler=function(re,ae){return this.registerOscHandler(re,ae)},x}(),z=function(){function x(re){this._core=re}return x.prototype.register=function(re){this._core.unicodeService.register(re)},Object.defineProperty(x.prototype,"versions",{get:function(){return this._core.unicodeService.versions},enumerable:!1,configurable:!0}),Object.defineProperty(x.prototype,"activeVersion",{get:function(){return this._core.unicodeService.activeVersion},set:function(re){this._core.unicodeService.activeVersion=re},enumerable:!1,configurable:!0}),x}()},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ot,He){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(rt,Ye){rt.__proto__=Ye}||function(rt,Ye){for(var ut in Ye)Ye.hasOwnProperty(ut)&&(rt[ut]=Ye[ut])})(ot,He)},function(ot,He){function rt(){this.constructor=ot}ie(ot,He),ot.prototype=He===null?Object.create(He):(rt.prototype=He.prototype,new rt)});Object.defineProperty(be,"__esModule",{value:!0}),be.Terminal=void 0;var ue=ce(36),se=ce(37),te=ce(38),le=ce(12),ee=ce(19),ne=ce(40),E=ce(50),b=ce(51),z=ce(11),x=ce(7),re=ce(18),ae=ce(54),oe=ce(55),ve=ce(56),ye=ce(57),me=ce(59),ge=ce(0),_e=ce(16),he=ce(27),pe=ce(60),ke=ce(5),Te=ce(61),Ee=ce(62),Oe=ce(63),je=ce(64),Pe=ce(65),Qe=typeof window!="undefined"?window.document:null,Xe=function(ot){function He(rt){rt===void 0&&(rt={});var Ye=ot.call(this,rt)||this;return Ye.browser=z,Ye._keyDownHandled=!1,Ye._onCursorMove=new ge.EventEmitter,Ye._onKey=new ge.EventEmitter,Ye._onRender=new ge.EventEmitter,Ye._onSelectionChange=new ge.EventEmitter,Ye._onTitleChange=new ge.EventEmitter,Ye._onFocus=new ge.EventEmitter,Ye._onBlur=new ge.EventEmitter,Ye._onA11yCharEmitter=new ge.EventEmitter,Ye._onA11yTabEmitter=new ge.EventEmitter,Ye._setup(),Ye.linkifier=Ye._instantiationService.createInstance(E.Linkifier),Ye.linkifier2=Ye.register(Ye._instantiationService.createInstance(Oe.Linkifier2)),Ye.register(Ye._inputHandler.onRequestBell(function(){return Ye.bell()})),Ye.register(Ye._inputHandler.onRequestRefreshRows(function(ut,Ge){return Ye.refresh(ut,Ge)})),Ye.register(Ye._inputHandler.onRequestReset(function(){return Ye.reset()})),Ye.register(Ye._inputHandler.onRequestScroll(function(ut,Ge){return Ye.scroll(ut,Ge||void 0)})),Ye.register(Ye._inputHandler.onRequestWindowsOptionsReport(function(ut){return Ye._reportWindowsOptions(ut)})),Ye.register(ge.forwardEvent(Ye._inputHandler.onCursorMove,Ye._onCursorMove)),Ye.register(ge.forwardEvent(Ye._inputHandler.onTitleChange,Ye._onTitleChange)),Ye.register(ge.forwardEvent(Ye._inputHandler.onA11yChar,Ye._onA11yCharEmitter)),Ye.register(ge.forwardEvent(Ye._inputHandler.onA11yTab,Ye._onA11yTabEmitter)),Ye.register(Ye._bufferService.onResize(function(ut){return Ye._afterResize(ut.cols,ut.rows)})),Ye}return Ce(He,ot),Object.defineProperty(He.prototype,"options",{get:function(){return this.optionsService.options},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onCursorMove",{get:function(){return this._onCursorMove.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onKey",{get:function(){return this._onKey.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onRender",{get:function(){return this._onRender.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onSelectionChange",{get:function(){return this._onSelectionChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onTitleChange",{get:function(){return this._onTitleChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onFocus",{get:function(){return this._onFocus.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onBlur",{get:function(){return this._onBlur.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onA11yChar",{get:function(){return this._onA11yCharEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(He.prototype,"onA11yTab",{get:function(){return this._onA11yTabEmitter.event},enumerable:!1,configurable:!0}),He.prototype.dispose=function(){var rt,Ye,ut;this._isDisposed||(ot.prototype.dispose.call(this),(rt=this._renderService)===null||rt===void 0||rt.dispose(),this._customKeyEventHandler=void 0,this.write=function(){},(ut=(Ye=this.element)===null||Ye===void 0?void 0:Ye.parentNode)===null||ut===void 0||ut.removeChild(this.element))},He.prototype._setup=function(){ot.prototype._setup.call(this),this._customKeyEventHandler=void 0},Object.defineProperty(He.prototype,"buffer",{get:function(){return this.buffers.active},enumerable:!1,configurable:!0}),He.prototype.focus=function(){this.textarea&&this.textarea.focus({preventScroll:!0})},He.prototype._updateOptions=function(rt){var Ye,ut,Ge,ze;switch(ot.prototype._updateOptions.call(this,rt),rt){case"fontFamily":case"fontSize":(Ye=this._renderService)===null||Ye===void 0||Ye.clear(),(ut=this._charSizeService)===null||ut===void 0||ut.measure();break;case"cursorBlink":case"cursorStyle":this.refresh(this.buffer.y,this.buffer.y);break;case"drawBoldTextInBrightColors":case"letterSpacing":case"lineHeight":case"fontWeight":case"fontWeightBold":case"minimumContrastRatio":this._renderService&&(this._renderService.clear(),this._renderService.onResize(this.cols,this.rows),this.refresh(0,this.rows-1));break;case"rendererType":this._renderService&&(this._renderService.setRenderer(this._createRenderer()),this._renderService.onResize(this.cols,this.rows));break;case"scrollback":(Ge=this.viewport)===null||Ge===void 0||Ge.syncScrollArea();break;case"screenReaderMode":this.optionsService.options.screenReaderMode?!this._accessibilityManager&&this._renderService&&(this._accessibilityManager=new ve.AccessibilityManager(this,this._renderService)):((ze=this._accessibilityManager)===null||ze===void 0||ze.dispose(),this._accessibilityManager=void 0);break;case"tabStopWidth":this.buffers.setupTabStops();break;case"theme":this._setTheme(this.optionsService.options.theme)}},He.prototype._onTextAreaFocus=function(rt){this._coreService.decPrivateModes.sendFocus&&this._coreService.triggerDataEvent(le.C0.ESC+"[I"),this.updateCursorStyle(rt),this.element.classList.add("focus"),this._showCursor(),this._onFocus.fire()},He.prototype.blur=function(){var rt;return(rt=this.textarea)===null||rt===void 0?void 0:rt.blur()},He.prototype._onTextAreaBlur=function(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this._coreService.decPrivateModes.sendFocus&&this._coreService.triggerDataEvent(le.C0.ESC+"[O"),this.element.classList.remove("focus"),this._onBlur.fire()},He.prototype._syncTextArea=function(){if(this.textarea&&this.buffer.isCursorInViewport&&!this._compositionHelper.isComposing){var rt=Math.ceil(this._charSizeService.height*this.optionsService.options.lineHeight),Ye=this._bufferService.buffer.y*rt,ut=this._bufferService.buffer.x*this._charSizeService.width;this.textarea.style.left=ut+"px",this.textarea.style.top=Ye+"px",this.textarea.style.width=this._charSizeService.width+"px",this.textarea.style.height=rt+"px",this.textarea.style.lineHeight=rt+"px",this.textarea.style.zIndex="-5"}},He.prototype._initGlobal=function(){var rt=this;this._bindKeys(),this.register(x.addDisposableDomListener(this.element,"copy",function(ut){rt.hasSelection()&&te.copyHandler(ut,rt._selectionService)}));var Ye=function(ut){return te.handlePasteEvent(ut,rt.textarea,rt._coreService)};this.register(x.addDisposableDomListener(this.textarea,"paste",Ye)),this.register(x.addDisposableDomListener(this.element,"paste",Ye)),z.isFirefox?this.register(x.addDisposableDomListener(this.element,"mousedown",function(ut){ut.button===2&&te.rightClickHandler(ut,rt.textarea,rt.screenElement,rt._selectionService,rt.options.rightClickSelectsWord)})):this.register(x.addDisposableDomListener(this.element,"contextmenu",function(ut){te.rightClickHandler(ut,rt.textarea,rt.screenElement,rt._selectionService,rt.options.rightClickSelectsWord)})),z.isLinux&&this.register(x.addDisposableDomListener(this.element,"auxclick",function(ut){ut.button===1&&te.moveTextAreaUnderMouseCursor(ut,rt.textarea,rt.screenElement)}))},He.prototype._bindKeys=function(){var rt=this;this.register(x.addDisposableDomListener(this.textarea,"keyup",function(Ye){return rt._keyUp(Ye)},!0)),this.register(x.addDisposableDomListener(this.textarea,"keydown",function(Ye){return rt._keyDown(Ye)},!0)),this.register(x.addDisposableDomListener(this.textarea,"keypress",function(Ye){return rt._keyPress(Ye)},!0)),this.register(x.addDisposableDomListener(this.textarea,"compositionstart",function(){return rt._compositionHelper.compositionstart()})),this.register(x.addDisposableDomListener(this.textarea,"compositionupdate",function(Ye){return rt._compositionHelper.compositionupdate(Ye)})),this.register(x.addDisposableDomListener(this.textarea,"compositionend",function(){return rt._compositionHelper.compositionend()})),this.register(this.onRender(function(){return rt._compositionHelper.updateCompositionElements()})),this.register(this.onRender(function(Ye){return rt._queueLinkification(Ye.start,Ye.end)}))},He.prototype.open=function(rt){var Ye=this;if(!rt)throw new Error("Terminal requires a parent element.");Qe.body.contains(rt)||this._logService.debug("Terminal.open was called on an element that was not attached to the DOM"),this._document=rt.ownerDocument,this.element=this._document.createElement("div"),this.element.dir="ltr",this.element.classList.add("terminal"),this.element.classList.add("xterm"),this.element.setAttribute("tabindex","0"),rt.appendChild(this.element);var ut=Qe.createDocumentFragment();this._viewportElement=Qe.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),ut.appendChild(this._viewportElement),this._viewportScrollArea=Qe.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=Qe.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=Qe.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),ut.appendChild(this.screenElement),this.textarea=Qe.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",re.promptLabel),this.textarea.setAttribute("aria-multiline","false"),this.textarea.setAttribute("autocorrect","off"),this.textarea.setAttribute("autocapitalize","off"),this.textarea.setAttribute("spellcheck","false"),this.textarea.tabIndex=0,this.register(x.addDisposableDomListener(this.textarea,"focus",function(Ve){return Ye._onTextAreaFocus(Ve)})),this.register(x.addDisposableDomListener(this.textarea,"blur",function(){return Ye._onTextAreaBlur()})),this._helperContainer.appendChild(this.textarea);var Ge=this._instantiationService.createInstance(je.CoreBrowserService,this.textarea);this._instantiationService.setService(ke.ICoreBrowserService,Ge),this._charSizeService=this._instantiationService.createInstance(Te.CharSizeService,this._document,this._helperContainer),this._instantiationService.setService(ke.ICharSizeService,this._charSizeService),this._compositionView=Qe.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=this._instantiationService.createInstance(ue.CompositionHelper,this.textarea,this._compositionView),this._helperContainer.appendChild(this._compositionView),this.element.appendChild(ut),this._theme=this.options.theme||this._theme,this._colorManager=new he.ColorManager(Qe,this.options.allowTransparency),this.register(this.optionsService.onOptionChange(function(Ve){return Ye._colorManager.onOptionsChange(Ve)})),this._colorManager.setTheme(this._theme);var ze=this._createRenderer();this._renderService=this.register(this._instantiationService.createInstance(pe.RenderService,ze,this.rows,this.screenElement)),this._instantiationService.setService(ke.IRenderService,this._renderService),this.register(this._renderService.onRenderedBufferChange(function(Ve){return Ye._onRender.fire(Ve)})),this.onResize(function(Ve){return Ye._renderService.resize(Ve.cols,Ve.rows)}),this._soundService=this._instantiationService.createInstance(ae.SoundService),this._instantiationService.setService(ke.ISoundService,this._soundService),this._mouseService=this._instantiationService.createInstance(Ee.MouseService),this._instantiationService.setService(ke.IMouseService,this._mouseService),this.viewport=this._instantiationService.createInstance(se.Viewport,function(Ve,$e){return Ye.scrollLines(Ve,$e)},this._viewportElement,this._viewportScrollArea),this.viewport.onThemeChange(this._colorManager.colors),this.register(this._inputHandler.onRequestSyncScrollBar(function(){return Ye.viewport.syncScrollArea()})),this.register(this.viewport),this.register(this.onCursorMove(function(){Ye._renderService.onCursorMove(),Ye._syncTextArea()})),this.register(this.onResize(function(){return Ye._renderService.onResize(Ye.cols,Ye.rows)})),this.register(this.onBlur(function(){return Ye._renderService.onBlur()})),this.register(this.onFocus(function(){return Ye._renderService.onFocus()})),this.register(this._renderService.onDimensionsChange(function(){return Ye.viewport.syncScrollArea()})),this._selectionService=this.register(this._instantiationService.createInstance(b.SelectionService,this.element,this.screenElement)),this._instantiationService.setService(ke.ISelectionService,this._selectionService),this.register(this._selectionService.onRequestScrollLines(function(Ve){return Ye.scrollLines(Ve.amount,Ve.suppressScrollEvent)})),this.register(this._selectionService.onSelectionChange(function(){return Ye._onSelectionChange.fire()})),this.register(this._selectionService.onRequestRedraw(function(Ve){return Ye._renderService.onSelectionChanged(Ve.start,Ve.end,Ve.columnSelectMode)})),this.register(this._selectionService.onLinuxMouseSelection(function(Ve){Ye.textarea.value=Ve,Ye.textarea.focus(),Ye.textarea.select()})),this.register(this.onScroll(function(){Ye.viewport.syncScrollArea(),Ye._selectionService.refresh()})),this.register(x.addDisposableDomListener(this._viewportElement,"scroll",function(){return Ye._selectionService.refresh()})),this._mouseZoneManager=this._instantiationService.createInstance(oe.MouseZoneManager,this.element,this.screenElement),this.register(this._mouseZoneManager),this.register(this.onScroll(function(){return Ye._mouseZoneManager.clearAll()})),this.linkifier.attachToDom(this.element,this._mouseZoneManager),this.linkifier2.attachToDom(this.element,this._mouseService,this._renderService),this.register(x.addDisposableDomListener(this.element,"mousedown",function(Ve){return Ye._selectionService.onMouseDown(Ve)})),this._coreMouseService.areMouseEventsActive?(this._selectionService.disable(),this.element.classList.add("enable-mouse-events")):this._selectionService.enable(),this.options.screenReaderMode&&(this._accessibilityManager=new ve.AccessibilityManager(this,this._renderService)),this._charSizeService.measure(),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()},He.prototype._createRenderer=function(){switch(this.options.rendererType){case"canvas":return this._instantiationService.createInstance(ne.Renderer,this._colorManager.colors,this.screenElement,this.linkifier,this.linkifier2);case"dom":return this._instantiationService.createInstance(ye.DomRenderer,this._colorManager.colors,this.element,this.screenElement,this._viewportElement,this.linkifier,this.linkifier2);default:throw new Error('Unrecognized rendererType "'+this.options.rendererType+'"')}},He.prototype._setTheme=function(rt){var Ye,ut,Ge;this._theme=rt,(Ye=this._colorManager)===null||Ye===void 0||Ye.setTheme(rt),(ut=this._renderService)===null||ut===void 0||ut.setColors(this._colorManager.colors),(Ge=this.viewport)===null||Ge===void 0||Ge.onThemeChange(this._colorManager.colors)},He.prototype.bindMouse=function(){var rt=this,Ye=this,ut=this.element;function Ge(pt){var ct,Ot,dt=Ye._mouseService.getRawByteCoords(pt,Ye.screenElement,Ye.cols,Ye.rows);if(!dt)return!1;switch(pt.overrideType||pt.type){case"mousemove":Ot=32,pt.buttons===void 0?(ct=3,pt.button!==void 0&&(ct=pt.button<3?pt.button:3)):ct=1&pt.buttons?0:4&pt.buttons?1:2&pt.buttons?2:3;break;case"mouseup":Ot=0,ct=pt.button<3?pt.button:3;break;case"mousedown":Ot=1,ct=pt.button<3?pt.button:3;break;case"wheel":pt.deltaY!==0&&(Ot=pt.deltaY<0?0:1),ct=4;break;default:return!1}return!(Ot===void 0||ct===void 0||ct>4)&&Ye._coreMouseService.triggerMouseEvent({col:dt.x-33,row:dt.y-33,button:ct,action:Ot,ctrl:pt.ctrlKey,alt:pt.altKey,shift:pt.shiftKey})}var ze={mouseup:null,wheel:null,mousedrag:null,mousemove:null},Ve=function(pt){return Ge(pt),pt.buttons||(rt._document.removeEventListener("mouseup",ze.mouseup),ze.mousedrag&&rt._document.removeEventListener("mousemove",ze.mousedrag)),rt.cancel(pt)},$e=function(pt){return Ge(pt),pt.preventDefault(),rt.cancel(pt)},nt=function(pt){pt.buttons&&Ge(pt)},et=function(pt){pt.buttons||Ge(pt)};this.register(this._coreMouseService.onProtocolChange(function(pt){pt?(rt.optionsService.options.logLevel==="debug"&&rt._logService.debug("Binding to mouse events:",rt._coreMouseService.explainEvents(pt)),rt.element.classList.add("enable-mouse-events"),rt._selectionService.disable()):(rt._logService.debug("Unbinding from mouse events."),rt.element.classList.remove("enable-mouse-events"),rt._selectionService.enable()),8&pt?ze.mousemove||(ut.addEventListener("mousemove",et),ze.mousemove=et):(ut.removeEventListener("mousemove",ze.mousemove),ze.mousemove=null),16&pt?ze.wheel||(ut.addEventListener("wheel",$e,{passive:!1}),ze.wheel=$e):(ut.removeEventListener("wheel",ze.wheel),ze.wheel=null),2&pt?ze.mouseup||(ze.mouseup=Ve):(rt._document.removeEventListener("mouseup",ze.mouseup),ze.mouseup=null),4&pt?ze.mousedrag||(ze.mousedrag=nt):(rt._document.removeEventListener("mousemove",ze.mousedrag),ze.mousedrag=null)})),this._coreMouseService.activeProtocol=this._coreMouseService.activeProtocol,this.register(x.addDisposableDomListener(ut,"mousedown",function(pt){if(pt.preventDefault(),rt.focus(),rt._coreMouseService.areMouseEventsActive&&!rt._selectionService.shouldForceSelection(pt))return Ge(pt),ze.mouseup&&rt._document.addEventListener("mouseup",ze.mouseup),ze.mousedrag&&rt._document.addEventListener("mousemove",ze.mousedrag),rt.cancel(pt)})),this.register(x.addDisposableDomListener(ut,"wheel",function(pt){if(!ze.wheel){if(!rt.buffer.hasScrollback){var ct=rt.viewport.getLinesScrolled(pt);if(ct===0)return;for(var Ot=le.C0.ESC+(rt._coreService.decPrivateModes.applicationCursorKeys?"O":"[")+(pt.deltaY<0?"A":"B"),dt="",Rt=0;Rt<Math.abs(ct);Rt++)dt+=Ot;rt._coreService.triggerDataEvent(dt,!0)}}},{passive:!0})),this.register(x.addDisposableDomListener(ut,"wheel",function(pt){if(!ze.wheel)return rt.viewport.onWheel(pt)?void 0:rt.cancel(pt)},{passive:!1})),this.register(x.addDisposableDomListener(ut,"touchstart",function(pt){if(!rt._coreMouseService.areMouseEventsActive)return rt.viewport.onTouchStart(pt),rt.cancel(pt)},{passive:!0})),this.register(x.addDisposableDomListener(ut,"touchmove",function(pt){if(!rt._coreMouseService.areMouseEventsActive)return rt.viewport.onTouchMove(pt)?void 0:rt.cancel(pt)},{passive:!1}))},He.prototype.refresh=function(rt,Ye){var ut;(ut=this._renderService)===null||ut===void 0||ut.refreshRows(rt,Ye)},He.prototype._queueLinkification=function(rt,Ye){var ut;(ut=this.linkifier)===null||ut===void 0||ut.linkifyRows(rt,Ye)},He.prototype.updateCursorStyle=function(rt){this._selectionService&&this._selectionService.shouldColumnSelect(rt)?this.element.classList.add("column-select"):this.element.classList.remove("column-select")},He.prototype._showCursor=function(){this._coreService.isCursorInitialized||(this._coreService.isCursorInitialized=!0,this.refresh(this.buffer.y,this.buffer.y))},He.prototype.scrollLines=function(rt,Ye){ot.prototype.scrollLines.call(this,rt,Ye),this.refresh(0,this.rows-1)},He.prototype.paste=function(rt){te.paste(rt,this.textarea,this._coreService)},He.prototype.attachCustomKeyEventHandler=function(rt){this._customKeyEventHandler=rt},He.prototype.registerLinkMatcher=function(rt,Ye,ut){var Ge=this.linkifier.registerLinkMatcher(rt,Ye,ut);return this.refresh(0,this.rows-1),Ge},He.prototype.deregisterLinkMatcher=function(rt){this.linkifier.deregisterLinkMatcher(rt)&&this.refresh(0,this.rows-1)},He.prototype.registerLinkProvider=function(rt){return this.linkifier2.registerLinkProvider(rt)},He.prototype.registerCharacterJoiner=function(rt){var Ye=this._renderService.registerCharacterJoiner(rt);return this.refresh(0,this.rows-1),Ye},He.prototype.deregisterCharacterJoiner=function(rt){this._renderService.deregisterCharacterJoiner(rt)&&this.refresh(0,this.rows-1)},Object.defineProperty(He.prototype,"markers",{get:function(){return this.buffer.markers},enumerable:!1,configurable:!0}),He.prototype.addMarker=function(rt){if(this.buffer===this.buffers.normal)return this.buffer.addMarker(this.buffer.ybase+this.buffer.y+rt)},He.prototype.hasSelection=function(){return!!this._selectionService&&this._selectionService.hasSelection},He.prototype.select=function(rt,Ye,ut){this._selectionService.setSelection(rt,Ye,ut)},He.prototype.getSelection=function(){return this._selectionService?this._selectionService.selectionText:""},He.prototype.getSelectionPosition=function(){if(this._selectionService&&this._selectionService.hasSelection)return{startColumn:this._selectionService.selectionStart[0],startRow:this._selectionService.selectionStart[1],endColumn:this._selectionService.selectionEnd[0],endRow:this._selectionService.selectionEnd[1]}},He.prototype.clearSelection=function(){var rt;(rt=this._selectionService)===null||rt===void 0||rt.clearSelection()},He.prototype.selectAll=function(){var rt;(rt=this._selectionService)===null||rt===void 0||rt.selectAll()},He.prototype.selectLines=function(rt,Ye){var ut;(ut=this._selectionService)===null||ut===void 0||ut.selectLines(rt,Ye)},He.prototype._keyDown=function(rt){if(this._keyDownHandled=!1,this._customKeyEventHandler&&this._customKeyEventHandler(rt)===!1)return!1;if(!this._compositionHelper.keydown(rt))return this.buffer.ybase!==this.buffer.ydisp&&this.scrollToBottom(),!1;var Ye=me.evaluateKeyboardEvent(rt,this._coreService.decPrivateModes.applicationCursorKeys,this.browser.isMac,this.options.macOptionIsMeta);if(this.updateCursorStyle(rt),Ye.type===3||Ye.type===2){var ut=this.rows-1;return this.scrollLines(Ye.type===2?-ut:ut),this.cancel(rt,!0)}return Ye.type===1&&this.selectAll(),!!this._isThirdLevelShift(this.browser,rt)||(Ye.cancel&&this.cancel(rt,!0),!Ye.key||(Ye.key!==le.C0.ETX&&Ye.key!==le.C0.CR||(this.textarea.value=""),this._onKey.fire({key:Ye.key,domEvent:rt}),this._showCursor(),this._coreService.triggerDataEvent(Ye.key,!0),this.optionsService.options.screenReaderMode?void(this._keyDownHandled=!0):this.cancel(rt,!0)))},He.prototype._isThirdLevelShift=function(rt,Ye){var ut=rt.isMac&&!this.options.macOptionIsMeta&&Ye.altKey&&!Ye.ctrlKey&&!Ye.metaKey||rt.isWindows&&Ye.altKey&&Ye.ctrlKey&&!Ye.metaKey;return Ye.type==="keypress"?ut:ut&&(!Ye.keyCode||Ye.keyCode>47)},He.prototype._keyUp=function(rt){this._customKeyEventHandler&&this._customKeyEventHandler(rt)===!1||(function(Ye){return Ye.keyCode===16||Ye.keyCode===17||Ye.keyCode===18}(rt)||this.focus(),this.updateCursorStyle(rt))},He.prototype._keyPress=function(rt){var Ye;if(this._keyDownHandled||this._customKeyEventHandler&&this._customKeyEventHandler(rt)===!1)return!1;if(this.cancel(rt),rt.charCode)Ye=rt.charCode;else if(rt.which===null||rt.which===void 0)Ye=rt.keyCode;else{if(rt.which===0||rt.charCode===0)return!1;Ye=rt.which}return!(!Ye||(rt.altKey||rt.ctrlKey||rt.metaKey)&&!this._isThirdLevelShift(this.browser,rt))&&(Ye=String.fromCharCode(Ye),this._onKey.fire({key:Ye,domEvent:rt}),this._showCursor(),this._coreService.triggerDataEvent(Ye,!0),!0)},He.prototype.bell=function(){this._soundBell()&&this._soundService.playBellSound()},He.prototype.resize=function(rt,Ye){rt!==this.cols||Ye!==this.rows?ot.prototype.resize.call(this,rt,Ye):this._charSizeService&&!this._charSizeService.hasValidSize&&this._charSizeService.measure()},He.prototype._afterResize=function(rt,Ye){var ut,Ge;(ut=this._charSizeService)===null||ut===void 0||ut.measure(),(Ge=this.viewport)===null||Ge===void 0||Ge.syncScrollArea(!0)},He.prototype.clear=function(){if(this.buffer.ybase!==0||this.buffer.y!==0){this.buffer.lines.set(0,this.buffer.lines.get(this.buffer.ybase+this.buffer.y)),this.buffer.lines.length=1,this.buffer.ydisp=0,this.buffer.ybase=0,this.buffer.y=0;for(var rt=1;rt<this.rows;rt++)this.buffer.lines.push(this.buffer.getBlankLine(_e.DEFAULT_ATTR_DATA));this.refresh(0,this.rows-1),this._onScroll.fire(this.buffer.ydisp)}},He.prototype.reset=function(){var rt,Ye;this.options.rows=this.rows,this.options.cols=this.cols;var ut=this._customKeyEventHandler;this._setup(),ot.prototype.reset.call(this),(rt=this._selectionService)===null||rt===void 0||rt.reset(),this._customKeyEventHandler=ut,this.refresh(0,this.rows-1),(Ye=this.viewport)===null||Ye===void 0||Ye.syncScrollArea()},He.prototype._reportWindowsOptions=function(rt){if(this._renderService)switch(rt){case ee.WindowsOptionsReportType.GET_WIN_SIZE_PIXELS:var Ye=this._renderService.dimensions.scaledCanvasWidth.toFixed(0),ut=this._renderService.dimensions.scaledCanvasHeight.toFixed(0);this._coreService.triggerDataEvent(le.C0.ESC+"[4;"+ut+";"+Ye+"t");break;case ee.WindowsOptionsReportType.GET_CELL_SIZE_PIXELS:var Ge=this._renderService.dimensions.scaledCellWidth.toFixed(0),ze=this._renderService.dimensions.scaledCellHeight.toFixed(0);this._coreService.triggerDataEvent(le.C0.ESC+"[6;"+ze+";"+Ge+"t")}},He.prototype.cancel=function(rt,Ye){if(this.options.cancelEvents||Ye)return rt.preventDefault(),rt.stopPropagation(),!1},He.prototype._visualBell=function(){return!1},He.prototype._soundBell=function(){return this.options.bellStyle==="sound"},He}(Pe.CoreTerminal);be.Terminal=Xe},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(le,ee,ne,E){var b,z=arguments.length,x=z<3?ee:E===null?E=Object.getOwnPropertyDescriptor(ee,ne):E;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")x=Reflect.decorate(le,ee,ne,E);else for(var re=le.length-1;re>=0;re--)(b=le[re])&&(x=(z<3?b(x):z>3?b(ee,ne,x):b(ee,ne))||x);return z>3&&x&&Object.defineProperty(ee,ne,x),x},Ce=this&&this.__param||function(le,ee){return function(ne,E){ee(ne,E,le)}};Object.defineProperty(be,"__esModule",{value:!0}),be.CompositionHelper=void 0;var ue=ce(5),se=ce(1),te=function(){function le(ee,ne,E,b,z,x){this._textarea=ee,this._compositionView=ne,this._bufferService=E,this._optionsService=b,this._charSizeService=z,this._coreService=x,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:0,end:0}}return Object.defineProperty(le.prototype,"isComposing",{get:function(){return this._isComposing},enumerable:!1,configurable:!0}),le.prototype.compositionstart=function(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._compositionView.classList.add("active")},le.prototype.compositionupdate=function(ee){var ne=this;this._compositionView.textContent=ee.data,this.updateCompositionElements(),setTimeout(function(){ne._compositionPosition.end=ne._textarea.value.length},0)},le.prototype.compositionend=function(){this._finalizeComposition(!0)},le.prototype.keydown=function(ee){if(this._isComposing||this._isSendingComposition){if(ee.keyCode===229||ee.keyCode===16||ee.keyCode===17||ee.keyCode===18)return!1;this._finalizeComposition(!1)}return ee.keyCode!==229||(this._handleAnyTextareaChanges(),!1)},le.prototype._finalizeComposition=function(ee){var ne=this;if(this._compositionView.classList.remove("active"),this._isComposing=!1,ee){var E={start:this._compositionPosition.start,end:this._compositionPosition.end};this._isSendingComposition=!0,setTimeout(function(){if(ne._isSendingComposition){ne._isSendingComposition=!1;var z=void 0;z=ne._isComposing?ne._textarea.value.substring(E.start,E.end):ne._textarea.value.substring(E.start),ne._coreService.triggerDataEvent(z,!0)}},0)}else{this._isSendingComposition=!1;var b=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end);this._coreService.triggerDataEvent(b,!0)}},le.prototype._handleAnyTextareaChanges=function(){var ee=this,ne=this._textarea.value;setTimeout(function(){if(!ee._isComposing){var E=ee._textarea.value.replace(ne,"");E.length>0&&ee._coreService.triggerDataEvent(E,!0)}},0)},le.prototype.updateCompositionElements=function(ee){var ne=this;if(this._isComposing){if(this._bufferService.buffer.isCursorInViewport){var E=Math.ceil(this._charSizeService.height*this._optionsService.options.lineHeight),b=this._bufferService.buffer.y*E,z=this._bufferService.buffer.x*this._charSizeService.width;this._compositionView.style.left=z+"px",this._compositionView.style.top=b+"px",this._compositionView.style.height=E+"px",this._compositionView.style.lineHeight=E+"px",this._compositionView.style.fontFamily=this._optionsService.options.fontFamily,this._compositionView.style.fontSize=this._optionsService.options.fontSize+"px";var x=this._compositionView.getBoundingClientRect();this._textarea.style.left=z+"px",this._textarea.style.top=b+"px",this._textarea.style.width=x.width+"px",this._textarea.style.height=x.height+"px",this._textarea.style.lineHeight=x.height+"px"}ee||setTimeout(function(){return ne.updateCompositionElements(!0)},0)}},le=ie([Ce(2,se.IBufferService),Ce(3,se.IOptionsService),Ce(4,ue.ICharSizeService),Ce(5,se.ICoreService)],le)}();be.CompositionHelper=te},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(b,z){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,re){x.__proto__=re}||function(x,re){for(var ae in re)re.hasOwnProperty(ae)&&(x[ae]=re[ae])})(b,z)},function(b,z){function x(){this.constructor=b}ie(b,z),b.prototype=z===null?Object.create(z):(x.prototype=z.prototype,new x)}),ue=this&&this.__decorate||function(b,z,x,re){var ae,oe=arguments.length,ve=oe<3?z:re===null?re=Object.getOwnPropertyDescriptor(z,x):re;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ve=Reflect.decorate(b,z,x,re);else for(var ye=b.length-1;ye>=0;ye--)(ae=b[ye])&&(ve=(oe<3?ae(ve):oe>3?ae(z,x,ve):ae(z,x))||ve);return oe>3&&ve&&Object.defineProperty(z,x,ve),ve},se=this&&this.__param||function(b,z){return function(x,re){z(x,re,b)}};Object.defineProperty(be,"__esModule",{value:!0}),be.Viewport=void 0;var te=ce(2),le=ce(7),ee=ce(5),ne=ce(1),E=function(b){function z(x,re,ae,oe,ve,ye,me){var ge=b.call(this)||this;return ge._scrollLines=x,ge._viewportElement=re,ge._scrollArea=ae,ge._bufferService=oe,ge._optionsService=ve,ge._charSizeService=ye,ge._renderService=me,ge.scrollBarWidth=0,ge._currentRowHeight=0,ge._lastRecordedBufferLength=0,ge._lastRecordedViewportHeight=0,ge._lastRecordedBufferHeight=0,ge._lastTouchY=0,ge._lastScrollTop=0,ge._wheelPartialScroll=0,ge._refreshAnimationFrame=null,ge._ignoreNextScrollEvent=!1,ge.scrollBarWidth=ge._viewportElement.offsetWidth-ge._scrollArea.offsetWidth||15,ge.register(le.addDisposableDomListener(ge._viewportElement,"scroll",ge._onScroll.bind(ge))),setTimeout(function(){return ge.syncScrollArea()},0),ge}return Ce(z,b),z.prototype.onThemeChange=function(x){this._viewportElement.style.backgroundColor=x.background.css},z.prototype._refresh=function(x){var re=this;if(x)return this._innerRefresh(),void(this._refreshAnimationFrame!==null&&cancelAnimationFrame(this._refreshAnimationFrame));this._refreshAnimationFrame===null&&(this._refreshAnimationFrame=requestAnimationFrame(function(){return re._innerRefresh()}))},z.prototype._innerRefresh=function(){if(this._charSizeService.height>0){this._currentRowHeight=this._renderService.dimensions.scaledCellHeight/window.devicePixelRatio,this._lastRecordedViewportHeight=this._viewportElement.offsetHeight;var x=Math.round(this._currentRowHeight*this._lastRecordedBufferLength)+(this._lastRecordedViewportHeight-this._renderService.dimensions.canvasHeight);this._lastRecordedBufferHeight!==x&&(this._lastRecordedBufferHeight=x,this._scrollArea.style.height=this._lastRecordedBufferHeight+"px")}var re=this._bufferService.buffer.ydisp*this._currentRowHeight;this._viewportElement.scrollTop!==re&&(this._ignoreNextScrollEvent=!0,this._viewportElement.scrollTop=re),this._refreshAnimationFrame=null},z.prototype.syncScrollArea=function(x){if(x===void 0&&(x=!1),this._lastRecordedBufferLength!==this._bufferService.buffer.lines.length)return this._lastRecordedBufferLength=this._bufferService.buffer.lines.length,void this._refresh(x);if(this._lastRecordedViewportHeight===this._renderService.dimensions.canvasHeight){var re=this._bufferService.buffer.ydisp*this._currentRowHeight;this._lastScrollTop===re&&this._lastScrollTop===this._viewportElement.scrollTop&&this._renderService.dimensions.scaledCellHeight/window.devicePixelRatio===this._currentRowHeight||this._refresh(x)}else this._refresh(x)},z.prototype._onScroll=function(x){if(this._lastScrollTop=this._viewportElement.scrollTop,this._viewportElement.offsetParent)if(this._ignoreNextScrollEvent)this._ignoreNextScrollEvent=!1;else{var re=Math.round(this._lastScrollTop/this._currentRowHeight)-this._bufferService.buffer.ydisp;this._scrollLines(re,!0)}},z.prototype._bubbleScroll=function(x,re){var ae=this._viewportElement.scrollTop+this._lastRecordedViewportHeight;return!(re<0&&this._viewportElement.scrollTop!==0||re>0&&ae<this._lastRecordedBufferHeight)||(x.cancelable&&x.preventDefault(),!1)},z.prototype.onWheel=function(x){var re=this._getPixelsScrolled(x);return re!==0&&(this._viewportElement.scrollTop+=re,this._bubbleScroll(x,re))},z.prototype._getPixelsScrolled=function(x){if(x.deltaY===0)return 0;var re=this._applyScrollModifier(x.deltaY,x);return x.deltaMode===WheelEvent.DOM_DELTA_LINE?re*=this._currentRowHeight:x.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(re*=this._currentRowHeight*this._bufferService.rows),re},z.prototype.getLinesScrolled=function(x){if(x.deltaY===0)return 0;var re=this._applyScrollModifier(x.deltaY,x);return x.deltaMode===WheelEvent.DOM_DELTA_PIXEL?(re/=this._currentRowHeight+0,this._wheelPartialScroll+=re,re=Math.floor(Math.abs(this._wheelPartialScroll))*(this._wheelPartialScroll>0?1:-1),this._wheelPartialScroll%=1):x.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(re*=this._bufferService.rows),re},z.prototype._applyScrollModifier=function(x,re){var ae=this._optionsService.options.fastScrollModifier;return ae==="alt"&&re.altKey||ae==="ctrl"&&re.ctrlKey||ae==="shift"&&re.shiftKey?x*this._optionsService.options.fastScrollSensitivity*this._optionsService.options.scrollSensitivity:x*this._optionsService.options.scrollSensitivity},z.prototype.onTouchStart=function(x){this._lastTouchY=x.touches[0].pageY},z.prototype.onTouchMove=function(x){var re=this._lastTouchY-x.touches[0].pageY;return this._lastTouchY=x.touches[0].pageY,re!==0&&(this._viewportElement.scrollTop+=re,this._bubbleScroll(x,re))},z=ue([se(3,ne.IBufferService),se(4,ne.IOptionsService),se(5,ee.ICharSizeService),se(6,ee.IRenderService)],z)}(te.Disposable);be.Viewport=E},function(Mt,be,ce){"use strict";function ie(te){return te.replace(/\r?\n/g,"\r")}function Ce(te,le){return le?"\x1B[200~"+te+"\x1B[201~":te}function ue(te,le,ee){te=Ce(te=ie(te),ee.decPrivateModes.bracketedPasteMode),ee.triggerDataEvent(te,!0),le.value=""}function se(te,le,ee){var ne=ee.getBoundingClientRect(),E=te.clientX-ne.left-10,b=te.clientY-ne.top-10;le.style.width="20px",le.style.height="20px",le.style.left=E+"px",le.style.top=b+"px",le.style.zIndex="1000",le.focus()}Object.defineProperty(be,"__esModule",{value:!0}),be.rightClickHandler=be.moveTextAreaUnderMouseCursor=be.paste=be.handlePasteEvent=be.copyHandler=be.bracketTextForPaste=be.prepareTextForTerminal=void 0,be.prepareTextForTerminal=ie,be.bracketTextForPaste=Ce,be.copyHandler=function(te,le){te.clipboardData&&te.clipboardData.setData("text/plain",le.selectionText),te.preventDefault()},be.handlePasteEvent=function(te,le,ee){te.stopPropagation(),te.clipboardData&&ue(te.clipboardData.getData("text/plain"),le,ee)},be.paste=ue,be.moveTextAreaUnderMouseCursor=se,be.rightClickHandler=function(te,le,ee,ne,E){se(te,le,ee),E&&!ne.isClickInSelection(te)&&ne.selectWordAtCursor(te),le.value=ne.selectionText,le.select()}},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(b,z){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,re){x.__proto__=re}||function(x,re){for(var ae in re)re.hasOwnProperty(ae)&&(x[ae]=re[ae])})(b,z)},function(b,z){function x(){this.constructor=b}ie(b,z),b.prototype=z===null?Object.create(z):(x.prototype=z.prototype,new x)});Object.defineProperty(be,"__esModule",{value:!0}),be.EscapeSequenceParser=be.VT500_TRANSITION_TABLE=be.TransitionTable=void 0;var ue=ce(2),se=ce(15),te=ce(21),le=ce(22),ee=ce(24),ne=function(){function b(z){this.table=new Uint8Array(z)}return b.prototype.setDefault=function(z,x){se.fill(this.table,z<<4|x)},b.prototype.add=function(z,x,re,ae){this.table[x<<8|z]=re<<4|ae},b.prototype.addMany=function(z,x,re,ae){for(var oe=0;oe<z.length;oe++)this.table[x<<8|z[oe]]=re<<4|ae},b}();be.TransitionTable=ne,be.VT500_TRANSITION_TABLE=function(){var b=new ne(4095),z=Array.apply(null,Array(256)).map(function(ye,me){return me}),x=function(ye,me){return z.slice(ye,me)},re=x(32,127),ae=x(0,24);ae.push(25),ae.push.apply(ae,x(28,32));var oe,ve=x(0,14);for(oe in b.setDefault(1,0),b.addMany(re,0,2,0),ve)b.addMany([24,26,153,154],oe,3,0),b.addMany(x(128,144),oe,3,0),b.addMany(x(144,152),oe,3,0),b.add(156,oe,0,0),b.add(27,oe,11,1),b.add(157,oe,4,8),b.addMany([152,158,159],oe,0,7),b.add(155,oe,11,3),b.add(144,oe,11,9);return b.addMany(ae,0,3,0),b.addMany(ae,1,3,1),b.add(127,1,0,1),b.addMany(ae,8,0,8),b.addMany(ae,3,3,3),b.add(127,3,0,3),b.addMany(ae,4,3,4),b.add(127,4,0,4),b.addMany(ae,6,3,6),b.addMany(ae,5,3,5),b.add(127,5,0,5),b.addMany(ae,2,3,2),b.add(127,2,0,2),b.add(93,1,4,8),b.addMany(re,8,5,8),b.add(127,8,5,8),b.addMany([156,27,24,26,7],8,6,0),b.addMany(x(28,32),8,0,8),b.addMany([88,94,95],1,0,7),b.addMany(re,7,0,7),b.addMany(ae,7,0,7),b.add(156,7,0,0),b.add(127,7,0,7),b.add(91,1,11,3),b.addMany(x(64,127),3,7,0),b.addMany(x(48,60),3,8,4),b.addMany([60,61,62,63],3,9,4),b.addMany(x(48,60),4,8,4),b.addMany(x(64,127),4,7,0),b.addMany([60,61,62,63],4,0,6),b.addMany(x(32,64),6,0,6),b.add(127,6,0,6),b.addMany(x(64,127),6,0,0),b.addMany(x(32,48),3,9,5),b.addMany(x(32,48),5,9,5),b.addMany(x(48,64),5,0,6),b.addMany(x(64,127),5,7,0),b.addMany(x(32,48),4,9,5),b.addMany(x(32,48),1,9,2),b.addMany(x(32,48),2,9,2),b.addMany(x(48,127),2,10,0),b.addMany(x(48,80),1,10,0),b.addMany(x(81,88),1,10,0),b.addMany([89,90,92],1,10,0),b.addMany(x(96,127),1,10,0),b.add(80,1,11,9),b.addMany(ae,9,0,9),b.add(127,9,0,9),b.addMany(x(28,32),9,0,9),b.addMany(x(32,48),9,9,12),b.addMany(x(48,60),9,8,10),b.addMany([60,61,62,63],9,9,10),b.addMany(ae,11,0,11),b.addMany(x(32,128),11,0,11),b.addMany(x(28,32),11,0,11),b.addMany(ae,10,0,10),b.add(127,10,0,10),b.addMany(x(28,32),10,0,10),b.addMany(x(48,60),10,8,10),b.addMany([60,61,62,63],10,0,11),b.addMany(x(32,48),10,9,12),b.addMany(ae,12,0,12),b.add(127,12,0,12),b.addMany(x(28,32),12,0,12),b.addMany(x(32,48),12,9,12),b.addMany(x(48,64),12,0,11),b.addMany(x(64,127),12,12,13),b.addMany(x(64,127),10,12,13),b.addMany(x(64,127),9,12,13),b.addMany(ae,13,13,13),b.addMany(re,13,13,13),b.add(127,13,0,13),b.addMany([27,156,24,26],13,14,0),b.add(160,0,2,0),b.add(160,8,5,8),b.add(160,6,0,6),b.add(160,11,0,11),b.add(160,13,13,13),b}();var E=function(b){function z(x){x===void 0&&(x=be.VT500_TRANSITION_TABLE);var re=b.call(this)||this;return re._transitions=x,re.initialState=0,re.currentState=re.initialState,re._params=new te.Params,re._params.addParam(0),re._collect=0,re.precedingCodepoint=0,re._printHandlerFb=function(ae,oe,ve){},re._executeHandlerFb=function(ae){},re._csiHandlerFb=function(ae,oe){},re._escHandlerFb=function(ae){},re._errorHandlerFb=function(ae){return ae},re._printHandler=re._printHandlerFb,re._executeHandlers=Object.create(null),re._csiHandlers=Object.create(null),re._escHandlers=Object.create(null),re._oscParser=new le.OscParser,re._dcsParser=new ee.DcsParser,re._errorHandler=re._errorHandlerFb,re.setEscHandler({final:"\\"},function(){}),re}return Ce(z,b),z.prototype._identifier=function(x,re){re===void 0&&(re=[64,126]);var ae=0;if(x.prefix){if(x.prefix.length>1)throw new Error("only one byte as prefix supported");if((ae=x.prefix.charCodeAt(0))&&60>ae||ae>63)throw new Error("prefix must be in range 0x3c .. 0x3f")}if(x.intermediates){if(x.intermediates.length>2)throw new Error("only two bytes as intermediates are supported");for(var oe=0;oe<x.intermediates.length;++oe){var ve=x.intermediates.charCodeAt(oe);if(32>ve||ve>47)throw new Error("intermediate must be in range 0x20 .. 0x2f");ae<<=8,ae|=ve}}if(x.final.length!==1)throw new Error("final must be a single byte");var ye=x.final.charCodeAt(0);if(re[0]>ye||ye>re[1])throw new Error("final must be in range "+re[0]+" .. "+re[1]);return ae<<=8,ae|=ye},z.prototype.identToString=function(x){for(var re=[];x;)re.push(String.fromCharCode(255&x)),x>>=8;return re.reverse().join("")},z.prototype.dispose=function(){this._csiHandlers=Object.create(null),this._executeHandlers=Object.create(null),this._escHandlers=Object.create(null),this._oscParser.dispose(),this._dcsParser.dispose()},z.prototype.setPrintHandler=function(x){this._printHandler=x},z.prototype.clearPrintHandler=function(){this._printHandler=this._printHandlerFb},z.prototype.addEscHandler=function(x,re){var ae=this._identifier(x,[48,126]);this._escHandlers[ae]===void 0&&(this._escHandlers[ae]=[]);var oe=this._escHandlers[ae];return oe.push(re),{dispose:function(){var ve=oe.indexOf(re);ve!==-1&&oe.splice(ve,1)}}},z.prototype.setEscHandler=function(x,re){this._escHandlers[this._identifier(x,[48,126])]=[re]},z.prototype.clearEscHandler=function(x){this._escHandlers[this._identifier(x,[48,126])]&&delete this._escHandlers[this._identifier(x,[48,126])]},z.prototype.setEscHandlerFallback=function(x){this._escHandlerFb=x},z.prototype.setExecuteHandler=function(x,re){this._executeHandlers[x.charCodeAt(0)]=re},z.prototype.clearExecuteHandler=function(x){this._executeHandlers[x.charCodeAt(0)]&&delete this._executeHandlers[x.charCodeAt(0)]},z.prototype.setExecuteHandlerFallback=function(x){this._executeHandlerFb=x},z.prototype.addCsiHandler=function(x,re){var ae=this._identifier(x);this._csiHandlers[ae]===void 0&&(this._csiHandlers[ae]=[]);var oe=this._csiHandlers[ae];return oe.push(re),{dispose:function(){var ve=oe.indexOf(re);ve!==-1&&oe.splice(ve,1)}}},z.prototype.setCsiHandler=function(x,re){this._csiHandlers[this._identifier(x)]=[re]},z.prototype.clearCsiHandler=function(x){this._csiHandlers[this._identifier(x)]&&delete this._csiHandlers[this._identifier(x)]},z.prototype.setCsiHandlerFallback=function(x){this._csiHandlerFb=x},z.prototype.addDcsHandler=function(x,re){return this._dcsParser.addHandler(this._identifier(x),re)},z.prototype.setDcsHandler=function(x,re){this._dcsParser.setHandler(this._identifier(x),re)},z.prototype.clearDcsHandler=function(x){this._dcsParser.clearHandler(this._identifier(x))},z.prototype.setDcsHandlerFallback=function(x){this._dcsParser.setHandlerFallback(x)},z.prototype.addOscHandler=function(x,re){return this._oscParser.addHandler(x,re)},z.prototype.setOscHandler=function(x,re){this._oscParser.setHandler(x,re)},z.prototype.clearOscHandler=function(x){this._oscParser.clearHandler(x)},z.prototype.setOscHandlerFallback=function(x){this._oscParser.setHandlerFallback(x)},z.prototype.setErrorHandler=function(x){this._errorHandler=x},z.prototype.clearErrorHandler=function(){this._errorHandler=this._errorHandlerFb},z.prototype.reset=function(){this.currentState=this.initialState,this._oscParser.reset(),this._dcsParser.reset(),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingCodepoint=0},z.prototype.parse=function(x,re){for(var ae=0,oe=0,ve=this.currentState,ye=this._oscParser,me=this._dcsParser,ge=this._collect,_e=this._params,he=this._transitions.table,pe=0;pe<re;++pe){switch((oe=he[ve<<8|((ae=x[pe])<160?ae:160)])>>4){case 2:for(var ke=pe+1;;++ke){if(ke>=re||(ae=x[ke])<32||ae>126&&ae<160){this._printHandler(x,pe,ke),pe=ke-1;break}if(++ke>=re||(ae=x[ke])<32||ae>126&&ae<160){this._printHandler(x,pe,ke),pe=ke-1;break}if(++ke>=re||(ae=x[ke])<32||ae>126&&ae<160){this._printHandler(x,pe,ke),pe=ke-1;break}if(++ke>=re||(ae=x[ke])<32||ae>126&&ae<160){this._printHandler(x,pe,ke),pe=ke-1;break}}break;case 3:this._executeHandlers[ae]?this._executeHandlers[ae]():this._executeHandlerFb(ae),this.precedingCodepoint=0;break;case 0:break;case 1:if(this._errorHandler({position:pe,code:ae,currentState:ve,collect:ge,params:_e,abort:!1}).abort)return;break;case 7:for(var Te=this._csiHandlers[ge<<8|ae],Ee=Te?Te.length-1:-1;Ee>=0&&Te[Ee](_e)===!1;Ee--);Ee<0&&this._csiHandlerFb(ge<<8|ae,_e),this.precedingCodepoint=0;break;case 8:do switch(ae){case 59:_e.addParam(0);break;case 58:_e.addSubParam(-1);break;default:_e.addDigit(ae-48)}while(++pe<re&&(ae=x[pe])>47&&ae<60);pe--;break;case 9:ge<<=8,ge|=ae;break;case 10:for(var Oe=this._escHandlers[ge<<8|ae],je=Oe?Oe.length-1:-1;je>=0&&Oe[je]()===!1;je--);je<0&&this._escHandlerFb(ge<<8|ae),this.precedingCodepoint=0;break;case 11:_e.reset(),_e.addParam(0),ge=0;break;case 12:me.hook(ge<<8|ae,_e);break;case 13:for(var Pe=pe+1;;++Pe)if(Pe>=re||(ae=x[Pe])===24||ae===26||ae===27||ae>127&&ae<160){me.put(x,pe,Pe),pe=Pe-1;break}break;case 14:me.unhook(ae!==24&&ae!==26),ae===27&&(oe|=1),_e.reset(),_e.addParam(0),ge=0,this.precedingCodepoint=0;break;case 4:ye.start();break;case 5:for(var Qe=pe+1;;Qe++)if(Qe>=re||(ae=x[Qe])<32||ae>127&&ae<=159){ye.put(x,pe,Qe),pe=Qe-1;break}break;case 6:ye.end(ae!==24&&ae!==26),ae===27&&(oe|=1),_e.reset(),_e.addParam(0),ge=0,this.precedingCodepoint=0}ve=15&oe}this._collect=ge,this.currentState=ve},z}(ue.Disposable);be.EscapeSequenceParser=E},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ye,me){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ge,_e){ge.__proto__=_e}||function(ge,_e){for(var he in _e)_e.hasOwnProperty(he)&&(ge[he]=_e[he])})(ye,me)},function(ye,me){function ge(){this.constructor=ye}ie(ye,me),ye.prototype=me===null?Object.create(me):(ge.prototype=me.prototype,new ge)}),ue=this&&this.__decorate||function(ye,me,ge,_e){var he,pe=arguments.length,ke=pe<3?me:_e===null?_e=Object.getOwnPropertyDescriptor(me,ge):_e;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ke=Reflect.decorate(ye,me,ge,_e);else for(var Te=ye.length-1;Te>=0;Te--)(he=ye[Te])&&(ke=(pe<3?he(ke):pe>3?he(me,ge,ke):he(me,ge))||ke);return pe>3&&ke&&Object.defineProperty(me,ge,ke),ke},se=this&&this.__param||function(ye,me){return function(ge,_e){me(ge,_e,ye)}};Object.defineProperty(be,"__esModule",{value:!0}),be.Renderer=void 0;var te=ce(41),le=ce(47),ee=ce(48),ne=ce(49),E=ce(29),b=ce(2),z=ce(5),x=ce(1),re=ce(25),ae=ce(0),oe=1,ve=function(ye){function me(ge,_e,he,pe,ke,Te,Ee,Oe,je){var Pe=ye.call(this)||this;Pe._colors=ge,Pe._screenElement=_e,Pe._bufferService=ke,Pe._charSizeService=Te,Pe._optionsService=Ee,Pe._id=oe++,Pe._onRequestRedraw=new ae.EventEmitter;var Qe=Pe._optionsService.options.allowTransparency;return Pe._characterJoinerRegistry=new E.CharacterJoinerRegistry(Pe._bufferService),Pe._renderLayers=[new te.TextRenderLayer(Pe._screenElement,0,Pe._colors,Pe._characterJoinerRegistry,Qe,Pe._id,Pe._bufferService,Ee),new le.SelectionRenderLayer(Pe._screenElement,1,Pe._colors,Pe._id,Pe._bufferService,Ee),new ne.LinkRenderLayer(Pe._screenElement,2,Pe._colors,Pe._id,he,pe,Pe._bufferService,Ee),new ee.CursorRenderLayer(Pe._screenElement,3,Pe._colors,Pe._id,Pe._onRequestRedraw,Pe._bufferService,Ee,Oe,je)],Pe.dimensions={scaledCharWidth:0,scaledCharHeight:0,scaledCellWidth:0,scaledCellHeight:0,scaledCharLeft:0,scaledCharTop:0,scaledCanvasWidth:0,scaledCanvasHeight:0,canvasWidth:0,canvasHeight:0,actualCellWidth:0,actualCellHeight:0},Pe._devicePixelRatio=window.devicePixelRatio,Pe._updateDimensions(),Pe.onOptionsChanged(),Pe}return Ce(me,ye),Object.defineProperty(me.prototype,"onRequestRedraw",{get:function(){return this._onRequestRedraw.event},enumerable:!1,configurable:!0}),me.prototype.dispose=function(){for(var ge=0,_e=this._renderLayers;ge<_e.length;ge++)_e[ge].dispose();ye.prototype.dispose.call(this),re.removeTerminalFromCache(this._id)},me.prototype.onDevicePixelRatioChange=function(){this._devicePixelRatio!==window.devicePixelRatio&&(this._devicePixelRatio=window.devicePixelRatio,this.onResize(this._bufferService.cols,this._bufferService.rows))},me.prototype.setColors=function(ge){this._colors=ge;for(var _e=0,he=this._renderLayers;_e<he.length;_e++){var pe=he[_e];pe.setColors(this._colors),pe.reset()}},me.prototype.onResize=function(ge,_e){this._updateDimensions();for(var he=0,pe=this._renderLayers;he<pe.length;he++)pe[he].resize(this.dimensions);this._screenElement.style.width=this.dimensions.canvasWidth+"px",this._screenElement.style.height=this.dimensions.canvasHeight+"px"},me.prototype.onCharSizeChanged=function(){this.onResize(this._bufferService.cols,this._bufferService.rows)},me.prototype.onBlur=function(){this._runOperation(function(ge){return ge.onBlur()})},me.prototype.onFocus=function(){this._runOperation(function(ge){return ge.onFocus()})},me.prototype.onSelectionChanged=function(ge,_e,he){he===void 0&&(he=!1),this._runOperation(function(pe){return pe.onSelectionChanged(ge,_e,he)})},me.prototype.onCursorMove=function(){this._runOperation(function(ge){return ge.onCursorMove()})},me.prototype.onOptionsChanged=function(){this._runOperation(function(ge){return ge.onOptionsChanged()})},me.prototype.clear=function(){this._runOperation(function(ge){return ge.reset()})},me.prototype._runOperation=function(ge){for(var _e=0,he=this._renderLayers;_e<he.length;_e++)ge(he[_e])},me.prototype.renderRows=function(ge,_e){for(var he=0,pe=this._renderLayers;he<pe.length;he++)pe[he].onGridChanged(ge,_e)},me.prototype._updateDimensions=function(){this._charSizeService.hasValidSize&&(this.dimensions.scaledCharWidth=Math.floor(this._charSizeService.width*window.devicePixelRatio),this.dimensions.scaledCharHeight=Math.ceil(this._charSizeService.height*window.devicePixelRatio),this.dimensions.scaledCellHeight=Math.floor(this.dimensions.scaledCharHeight*this._optionsService.options.lineHeight),this.dimensions.scaledCharTop=this._optionsService.options.lineHeight===1?0:Math.round((this.dimensions.scaledCellHeight-this.dimensions.scaledCharHeight)/2),this.dimensions.scaledCellWidth=this.dimensions.scaledCharWidth+Math.round(this._optionsService.options.letterSpacing),this.dimensions.scaledCharLeft=Math.floor(this._optionsService.options.letterSpacing/2),this.dimensions.scaledCanvasHeight=this._bufferService.rows*this.dimensions.scaledCellHeight,this.dimensions.scaledCanvasWidth=this._bufferService.cols*this.dimensions.scaledCellWidth,this.dimensions.canvasHeight=Math.round(this.dimensions.scaledCanvasHeight/window.devicePixelRatio),this.dimensions.canvasWidth=Math.round(this.dimensions.scaledCanvasWidth/window.devicePixelRatio),this.dimensions.actualCellHeight=this.dimensions.canvasHeight/this._bufferService.rows,this.dimensions.actualCellWidth=this.dimensions.canvasWidth/this._bufferService.cols)},me.prototype.registerCharacterJoiner=function(ge){return this._characterJoinerRegistry.registerCharacterJoiner(ge)},me.prototype.deregisterCharacterJoiner=function(ge){return this._characterJoinerRegistry.deregisterCharacterJoiner(ge)},me=ue([se(4,x.IBufferService),se(5,z.ICharSizeService),se(6,x.IOptionsService),se(7,x.ICoreService),se(8,z.ICoreBrowserService)],me)}(b.Disposable);be.Renderer=ve},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(b,z){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,re){x.__proto__=re}||function(x,re){for(var ae in re)re.hasOwnProperty(ae)&&(x[ae]=re[ae])})(b,z)},function(b,z){function x(){this.constructor=b}ie(b,z),b.prototype=z===null?Object.create(z):(x.prototype=z.prototype,new x)});Object.defineProperty(be,"__esModule",{value:!0}),be.TextRenderLayer=void 0;var ue=ce(42),se=ce(13),te=ce(6),le=ce(3),ee=ce(29),ne=ce(4),E=function(b){function z(x,re,ae,oe,ve,ye,me,ge){var _e=b.call(this,x,"text",re,ve,ae,ye,me,ge)||this;return _e._characterWidth=0,_e._characterFont="",_e._characterOverlapCache={},_e._workCell=new ne.CellData,_e._state=new ue.GridCache,_e._characterJoinerRegistry=oe,_e}return Ce(z,b),z.prototype.resize=function(x){b.prototype.resize.call(this,x);var re=this._getFont(!1,!1);this._characterWidth===x.scaledCharWidth&&this._characterFont===re||(this._characterWidth=x.scaledCharWidth,this._characterFont=re,this._characterOverlapCache={}),this._state.clear(),this._state.resize(this._bufferService.cols,this._bufferService.rows)},z.prototype.reset=function(){this._state.clear(),this._clearAll()},z.prototype._forEachCell=function(x,re,ae,oe){for(var ve=x;ve<=re;ve++)for(var ye=ve+this._bufferService.buffer.ydisp,me=this._bufferService.buffer.lines.get(ye),ge=ae?ae.getJoinedCharacters(ye):[],_e=0;_e<this._bufferService.cols;_e++){me.loadCell(_e,this._workCell);var he=this._workCell,pe=!1,ke=_e;if(he.getWidth()!==0){if(ge.length>0&&_e===ge[0][0]){pe=!0;var Te=ge.shift();he=new ee.JoinedCellData(this._workCell,me.translateToString(!0,Te[0],Te[1]),Te[1]-Te[0]),ke=Te[1]-1}!pe&&this._isOverlapping(he)&&ke<me.length-1&&me.getCodePoint(ke+1)===le.NULL_CELL_CODE&&(he.content&=-12582913,he.content|=2<<22),oe(he,_e,ve),_e=ke}}},z.prototype._drawBackground=function(x,re){var ae=this,oe=this._ctx,ve=this._bufferService.cols,ye=0,me=0,ge=null;oe.save(),this._forEachCell(x,re,null,function(_e,he,pe){var ke=null;_e.isInverse()?ke=_e.isFgDefault()?ae._colors.foreground.css:_e.isFgRGB()?"rgb("+te.AttributeData.toColorRGB(_e.getFgColor()).join(",")+")":ae._colors.ansi[_e.getFgColor()].css:_e.isBgRGB()?ke="rgb("+te.AttributeData.toColorRGB(_e.getBgColor()).join(",")+")":_e.isBgPalette()&&(ke=ae._colors.ansi[_e.getBgColor()].css),ge===null&&(ye=he,me=pe),pe!==me?(oe.fillStyle=ge||"",ae._fillCells(ye,me,ve-ye,1),ye=he,me=pe):ge!==ke&&(oe.fillStyle=ge||"",ae._fillCells(ye,me,he-ye,1),ye=he,me=pe),ge=ke}),ge!==null&&(oe.fillStyle=ge,this._fillCells(ye,me,ve-ye,1)),oe.restore()},z.prototype._drawForeground=function(x,re){var ae=this;this._forEachCell(x,re,this._characterJoinerRegistry,function(oe,ve,ye){if(!oe.isInvisible()&&(ae._drawChars(oe,ve,ye),oe.isUnderline())){if(ae._ctx.save(),oe.isInverse())if(oe.isBgDefault())ae._ctx.fillStyle=ae._colors.background.css;else if(oe.isBgRGB())ae._ctx.fillStyle="rgb("+te.AttributeData.toColorRGB(oe.getBgColor()).join(",")+")";else{var me=oe.getBgColor();ae._optionsService.options.drawBoldTextInBrightColors&&oe.isBold()&&me<8&&(me+=8),ae._ctx.fillStyle=ae._colors.ansi[me].css}else if(oe.isFgDefault())ae._ctx.fillStyle=ae._colors.foreground.css;else if(oe.isFgRGB())ae._ctx.fillStyle="rgb("+te.AttributeData.toColorRGB(oe.getFgColor()).join(",")+")";else{var ge=oe.getFgColor();ae._optionsService.options.drawBoldTextInBrightColors&&oe.isBold()&&ge<8&&(ge+=8),ae._ctx.fillStyle=ae._colors.ansi[ge].css}ae._fillBottomLineAtCells(ve,ye,oe.getWidth()),ae._ctx.restore()}})},z.prototype.onGridChanged=function(x,re){this._state.cache.length!==0&&(this._charAtlas&&this._charAtlas.beginFrame(),this._clearCells(0,x,this._bufferService.cols,re-x+1),this._drawBackground(x,re),this._drawForeground(x,re))},z.prototype.onOptionsChanged=function(){this._setTransparency(this._optionsService.options.allowTransparency)},z.prototype._isOverlapping=function(x){if(x.getWidth()!==1||x.getCode()<256)return!1;var re=x.getChars();if(this._characterOverlapCache.hasOwnProperty(re))return this._characterOverlapCache[re];this._ctx.save(),this._ctx.font=this._characterFont;var ae=Math.floor(this._ctx.measureText(re).width)>this._characterWidth;return this._ctx.restore(),this._characterOverlapCache[re]=ae,ae},z}(se.BaseRenderLayer);be.TextRenderLayer=E},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.GridCache=void 0;var ie=function(){function Ce(){this.cache=[]}return Ce.prototype.resize=function(ue,se){for(var te=0;te<ue;te++){this.cache.length<=te&&this.cache.push([]);for(var le=this.cache[te].length;le<se;le++)this.cache[te].push(void 0);this.cache[te].length=se}this.cache.length=ue},Ce.prototype.clear=function(){for(var ue=0;ue<this.cache.length;ue++)for(var se=0;se<this.cache[ue].length;se++)this.cache[ue][se]=void 0},Ce}();be.GridCache=ie},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ae,oe){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ve,ye){ve.__proto__=ye}||function(ve,ye){for(var me in ye)ye.hasOwnProperty(me)&&(ve[me]=ye[me])})(ae,oe)},function(ae,oe){function ve(){this.constructor=ae}ie(ae,oe),ae.prototype=oe===null?Object.create(oe):(ve.prototype=oe.prototype,new ve)});Object.defineProperty(be,"__esModule",{value:!0}),be.NoneCharAtlas=be.DynamicCharAtlas=be.getGlyphCacheKey=void 0;var ue=ce(9),se=ce(44),te=ce(27),le=ce(46),ee=ce(11),ne=ce(28),E=ce(10),b={css:"rgba(0, 0, 0, 0)",rgba:0};function z(ae){return ae.code<<21|ae.bg<<12|ae.fg<<3|(ae.bold?0:4)+(ae.dim?0:2)+(ae.italic?0:1)}be.getGlyphCacheKey=z;var x=function(ae){function oe(ve,ye){var me=ae.call(this)||this;me._config=ye,me._drawToCacheCount=0,me._glyphsWaitingOnBitmap=[],me._bitmapCommitTimeout=null,me._bitmap=null,me._cacheCanvas=ve.createElement("canvas"),me._cacheCanvas.width=1024,me._cacheCanvas.height=1024,me._cacheCtx=ne.throwIfFalsy(me._cacheCanvas.getContext("2d",{alpha:!0}));var ge=ve.createElement("canvas");ge.width=me._config.scaledCharWidth,ge.height=me._config.scaledCharHeight,me._tmpCtx=ne.throwIfFalsy(ge.getContext("2d",{alpha:me._config.allowTransparency})),me._width=Math.floor(1024/me._config.scaledCharWidth),me._height=Math.floor(1024/me._config.scaledCharHeight);var _e=me._width*me._height;return me._cacheMap=new le.LRUMap(_e),me._cacheMap.prealloc(_e),me}return Ce(oe,ae),oe.prototype.dispose=function(){this._bitmapCommitTimeout!==null&&(window.clearTimeout(this._bitmapCommitTimeout),this._bitmapCommitTimeout=null)},oe.prototype.beginFrame=function(){this._drawToCacheCount=0},oe.prototype.draw=function(ve,ye,me,ge){if(ye.code===32)return!0;if(!this._canCache(ye))return!1;var _e=z(ye),he=this._cacheMap.get(_e);if(he!=null)return this._drawFromCache(ve,he,me,ge),!0;if(this._drawToCacheCount<100){var pe=void 0;pe=this._cacheMap.size<this._cacheMap.capacity?this._cacheMap.size:this._cacheMap.peek().index;var ke=this._drawToCache(ye,pe);return this._cacheMap.set(_e,ke),this._drawFromCache(ve,ke,me,ge),!0}return!1},oe.prototype._canCache=function(ve){return ve.code<256},oe.prototype._toCoordinateX=function(ve){return ve%this._width*this._config.scaledCharWidth},oe.prototype._toCoordinateY=function(ve){return Math.floor(ve/this._width)*this._config.scaledCharHeight},oe.prototype._drawFromCache=function(ve,ye,me,ge){if(!ye.isEmpty){var _e=this._toCoordinateX(ye.index),he=this._toCoordinateY(ye.index);ve.drawImage(ye.inBitmap?this._bitmap:this._cacheCanvas,_e,he,this._config.scaledCharWidth,this._config.scaledCharHeight,me,ge,this._config.scaledCharWidth,this._config.scaledCharHeight)}},oe.prototype._getColorFromAnsiIndex=function(ve){return ve<this._config.colors.ansi.length?this._config.colors.ansi[ve]:te.DEFAULT_ANSI_COLORS[ve]},oe.prototype._getBackgroundColor=function(ve){return this._config.allowTransparency?b:ve.bg===ue.INVERTED_DEFAULT_COLOR?this._config.colors.foreground:ve.bg<256?this._getColorFromAnsiIndex(ve.bg):this._config.colors.background},oe.prototype._getForegroundColor=function(ve){return ve.fg===ue.INVERTED_DEFAULT_COLOR?E.color.opaque(this._config.colors.background):ve.fg<256?this._getColorFromAnsiIndex(ve.fg):this._config.colors.foreground},oe.prototype._drawToCache=function(ve,ye){this._drawToCacheCount++,this._tmpCtx.save();var me=this._getBackgroundColor(ve);this._tmpCtx.globalCompositeOperation="copy",this._tmpCtx.fillStyle=me.css,this._tmpCtx.fillRect(0,0,this._config.scaledCharWidth,this._config.scaledCharHeight),this._tmpCtx.globalCompositeOperation="source-over";var ge=ve.bold?this._config.fontWeightBold:this._config.fontWeight,_e=ve.italic?"italic":"";this._tmpCtx.font=_e+" "+ge+" "+this._config.fontSize*this._config.devicePixelRatio+"px "+this._config.fontFamily,this._tmpCtx.textBaseline="middle",this._tmpCtx.fillStyle=this._getForegroundColor(ve).css,ve.dim&&(this._tmpCtx.globalAlpha=ue.DIM_OPACITY),this._tmpCtx.fillText(ve.chars,0,this._config.scaledCharHeight/2),this._tmpCtx.restore();var he=this._tmpCtx.getImageData(0,0,this._config.scaledCharWidth,this._config.scaledCharHeight),pe=!1;this._config.allowTransparency||(pe=function(Oe,je){for(var Pe=!0,Qe=je.rgba>>>24,Xe=je.rgba>>>16&255,ot=je.rgba>>>8&255,He=0;He<Oe.data.length;He+=4)Oe.data[He]===Qe&&Oe.data[He+1]===Xe&&Oe.data[He+2]===ot?Oe.data[He+3]=0:Pe=!1;return Pe}(he,me));var ke=this._toCoordinateX(ye),Te=this._toCoordinateY(ye);this._cacheCtx.putImageData(he,ke,Te);var Ee={index:ye,isEmpty:pe,inBitmap:!1};return this._addGlyphToBitmap(Ee),Ee},oe.prototype._addGlyphToBitmap=function(ve){var ye=this;!("createImageBitmap"in window)||ee.isFirefox||ee.isSafari||(this._glyphsWaitingOnBitmap.push(ve),this._bitmapCommitTimeout===null&&(this._bitmapCommitTimeout=window.setTimeout(function(){return ye._generateBitmap()},100)))},oe.prototype._generateBitmap=function(){var ve=this,ye=this._glyphsWaitingOnBitmap;this._glyphsWaitingOnBitmap=[],window.createImageBitmap(this._cacheCanvas).then(function(me){ve._bitmap=me;for(var ge=0;ge<ye.length;ge++)ye[ge].inBitmap=!0}),this._bitmapCommitTimeout=null},oe}(se.BaseCharAtlas);be.DynamicCharAtlas=x;var re=function(ae){function oe(ve,ye){return ae.call(this)||this}return Ce(oe,ae),oe.prototype.draw=function(ve,ye,me,ge){return!1},oe}(se.BaseCharAtlas);be.NoneCharAtlas=re},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.BaseCharAtlas=void 0;var ie=function(){function Ce(){this._didWarmUp=!1}return Ce.prototype.dispose=function(){},Ce.prototype.warmUp=function(){this._didWarmUp||(this._doWarmUp(),this._didWarmUp=!0)},Ce.prototype._doWarmUp=function(){},Ce.prototype.beginFrame=function(){},Ce}();be.BaseCharAtlas=ie},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.ColorContrastCache=void 0;var ie=function(){function Ce(){this._color={},this._rgba={}}return Ce.prototype.clear=function(){this._color={},this._rgba={}},Ce.prototype.setCss=function(ue,se,te){this._rgba[ue]||(this._rgba[ue]={}),this._rgba[ue][se]=te},Ce.prototype.getCss=function(ue,se){return this._rgba[ue]?this._rgba[ue][se]:void 0},Ce.prototype.setColor=function(ue,se,te){this._color[ue]||(this._color[ue]={}),this._color[ue][se]=te},Ce.prototype.getColor=function(ue,se){return this._color[ue]?this._color[ue][se]:void 0},Ce}();be.ColorContrastCache=ie},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.LRUMap=void 0;var ie=function(){function Ce(ue){this.capacity=ue,this._map={},this._head=null,this._tail=null,this._nodePool=[],this.size=0}return Ce.prototype._unlinkNode=function(ue){var se=ue.prev,te=ue.next;ue===this._head&&(this._head=te),ue===this._tail&&(this._tail=se),se!==null&&(se.next=te),te!==null&&(te.prev=se)},Ce.prototype._appendNode=function(ue){var se=this._tail;se!==null&&(se.next=ue),ue.prev=se,ue.next=null,this._tail=ue,this._head===null&&(this._head=ue)},Ce.prototype.prealloc=function(ue){for(var se=this._nodePool,te=0;te<ue;te++)se.push({prev:null,next:null,key:null,value:null})},Ce.prototype.get=function(ue){var se=this._map[ue];return se!==void 0?(this._unlinkNode(se),this._appendNode(se),se.value):null},Ce.prototype.peekValue=function(ue){var se=this._map[ue];return se!==void 0?se.value:null},Ce.prototype.peek=function(){var ue=this._head;return ue===null?null:ue.value},Ce.prototype.set=function(ue,se){var te=this._map[ue];if(te!==void 0)te=this._map[ue],this._unlinkNode(te),te.value=se;else if(this.size>=this.capacity)te=this._head,this._unlinkNode(te),delete this._map[te.key],te.key=ue,te.value=se,this._map[ue]=te;else{var le=this._nodePool;le.length>0?((te=le.pop()).key=ue,te.value=se):te={prev:null,next:null,key:ue,value:se},this._map[ue]=te,this.size++}this._appendNode(te)},Ce}();be.LRUMap=ie},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(se,te){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(le,ee){le.__proto__=ee}||function(le,ee){for(var ne in ee)ee.hasOwnProperty(ne)&&(le[ne]=ee[ne])})(se,te)},function(se,te){function le(){this.constructor=se}ie(se,te),se.prototype=te===null?Object.create(te):(le.prototype=te.prototype,new le)});Object.defineProperty(be,"__esModule",{value:!0}),be.SelectionRenderLayer=void 0;var ue=function(se){function te(le,ee,ne,E,b,z){var x=se.call(this,le,"selection",ee,!0,ne,E,b,z)||this;return x._clearState(),x}return Ce(te,se),te.prototype._clearState=function(){this._state={start:void 0,end:void 0,columnSelectMode:void 0,ydisp:void 0}},te.prototype.resize=function(le){se.prototype.resize.call(this,le),this._clearState()},te.prototype.reset=function(){this._state.start&&this._state.end&&(this._clearState(),this._clearAll())},te.prototype.onSelectionChanged=function(le,ee,ne){if(this._didStateChange(le,ee,ne,this._bufferService.buffer.ydisp))if(this._clearAll(),le&&ee){var E=le[1]-this._bufferService.buffer.ydisp,b=ee[1]-this._bufferService.buffer.ydisp,z=Math.max(E,0),x=Math.min(b,this._bufferService.rows-1);if(!(z>=this._bufferService.rows||x<0)){if(this._ctx.fillStyle=this._colors.selectionTransparent.css,ne){var re=le[0],ae=ee[0]-re,oe=x-z+1;this._fillCells(re,z,ae,oe)}else{re=E===z?le[0]:0;var ve=z===x?ee[0]:this._bufferService.cols;this._fillCells(re,z,ve-re,1);var ye=Math.max(x-z-1,0);if(this._fillCells(0,z+1,this._bufferService.cols,ye),z!==x){var me=b===x?ee[0]:this._bufferService.cols;this._fillCells(0,x,me,1)}}this._state.start=[le[0],le[1]],this._state.end=[ee[0],ee[1]],this._state.columnSelectMode=ne,this._state.ydisp=this._bufferService.buffer.ydisp}}else this._clearState()},te.prototype._didStateChange=function(le,ee,ne,E){return!this._areCoordinatesEqual(le,this._state.start)||!this._areCoordinatesEqual(ee,this._state.end)||ne!==this._state.columnSelectMode||E!==this._state.ydisp},te.prototype._areCoordinatesEqual=function(le,ee){return!(!le||!ee)&&le[0]===ee[0]&&le[1]===ee[1]},te}(ce(13).BaseRenderLayer);be.SelectionRenderLayer=ue},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ee,ne){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(E,b){E.__proto__=b}||function(E,b){for(var z in b)b.hasOwnProperty(z)&&(E[z]=b[z])})(ee,ne)},function(ee,ne){function E(){this.constructor=ee}ie(ee,ne),ee.prototype=ne===null?Object.create(ne):(E.prototype=ne.prototype,new E)});Object.defineProperty(be,"__esModule",{value:!0}),be.CursorRenderLayer=void 0;var ue=ce(13),se=ce(4),te=function(ee){function ne(E,b,z,x,re,ae,oe,ve,ye){var me=ee.call(this,E,"cursor",b,!0,z,x,ae,oe)||this;return me._onRequestRedraw=re,me._coreService=ve,me._coreBrowserService=ye,me._cell=new se.CellData,me._state={x:0,y:0,isFocused:!1,style:"",width:0},me._cursorRenderers={bar:me._renderBarCursor.bind(me),block:me._renderBlockCursor.bind(me),underline:me._renderUnderlineCursor.bind(me)},me}return Ce(ne,ee),ne.prototype.resize=function(E){ee.prototype.resize.call(this,E),this._state={x:0,y:0,isFocused:!1,style:"",width:0}},ne.prototype.reset=function(){this._clearCursor(),this._cursorBlinkStateManager&&(this._cursorBlinkStateManager.dispose(),this._cursorBlinkStateManager=void 0,this.onOptionsChanged())},ne.prototype.onBlur=function(){this._cursorBlinkStateManager&&this._cursorBlinkStateManager.pause(),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},ne.prototype.onFocus=function(){this._cursorBlinkStateManager?this._cursorBlinkStateManager.resume():this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},ne.prototype.onOptionsChanged=function(){var E,b=this;this._optionsService.options.cursorBlink?this._cursorBlinkStateManager||(this._cursorBlinkStateManager=new le(this._coreBrowserService.isFocused,function(){b._render(!0)})):((E=this._cursorBlinkStateManager)===null||E===void 0||E.dispose(),this._cursorBlinkStateManager=void 0),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},ne.prototype.onCursorMove=function(){this._cursorBlinkStateManager&&this._cursorBlinkStateManager.restartBlinkAnimation()},ne.prototype.onGridChanged=function(E,b){!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isPaused?this._render(!1):this._cursorBlinkStateManager.restartBlinkAnimation()},ne.prototype._render=function(E){if(this._coreService.isCursorInitialized&&!this._coreService.isCursorHidden){var b=this._bufferService.buffer.ybase+this._bufferService.buffer.y,z=b-this._bufferService.buffer.ydisp;if(z<0||z>=this._bufferService.rows)this._clearCursor();else{var x=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1);if(this._bufferService.buffer.lines.get(b).loadCell(x,this._cell),this._cell.content!==void 0){if(!this._coreBrowserService.isFocused){this._clearCursor(),this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css;var re=this._optionsService.options.cursorStyle;return re&&re!=="block"?this._cursorRenderers[re](x,z,this._cell):this._renderBlurCursor(x,z,this._cell),this._ctx.restore(),this._state.x=x,this._state.y=z,this._state.isFocused=!1,this._state.style=re,void(this._state.width=this._cell.getWidth())}if(!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isCursorVisible){if(this._state){if(this._state.x===x&&this._state.y===z&&this._state.isFocused===this._coreBrowserService.isFocused&&this._state.style===this._optionsService.options.cursorStyle&&this._state.width===this._cell.getWidth())return;this._clearCursor()}this._ctx.save(),this._cursorRenderers[this._optionsService.options.cursorStyle||"block"](x,z,this._cell),this._ctx.restore(),this._state.x=x,this._state.y=z,this._state.isFocused=!1,this._state.style=this._optionsService.options.cursorStyle,this._state.width=this._cell.getWidth()}else this._clearCursor()}}}else this._clearCursor()},ne.prototype._clearCursor=function(){this._state&&(this._clearCells(this._state.x,this._state.y,this._state.width,1),this._state={x:0,y:0,isFocused:!1,style:"",width:0})},ne.prototype._renderBarCursor=function(E,b,z){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillLeftLineAtCell(E,b,this._optionsService.options.cursorWidth),this._ctx.restore()},ne.prototype._renderBlockCursor=function(E,b,z){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillCells(E,b,z.getWidth(),1),this._ctx.fillStyle=this._colors.cursorAccent.css,this._fillCharTrueColor(z,E,b),this._ctx.restore()},ne.prototype._renderUnderlineCursor=function(E,b,z){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillBottomLineAtCells(E,b),this._ctx.restore()},ne.prototype._renderBlurCursor=function(E,b,z){this._ctx.save(),this._ctx.strokeStyle=this._colors.cursor.css,this._strokeRectAtCell(E,b,z.getWidth(),1),this._ctx.restore()},ne}(ue.BaseRenderLayer);be.CursorRenderLayer=te;var le=function(){function ee(ne,E){this._renderCallback=E,this.isCursorVisible=!0,ne&&this._restartInterval()}return Object.defineProperty(ee.prototype,"isPaused",{get:function(){return!(this._blinkStartTimeout||this._blinkInterval)},enumerable:!1,configurable:!0}),ee.prototype.dispose=function(){this._blinkInterval&&(window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},ee.prototype.restartBlinkAnimation=function(){var ne=this;this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame||(this._animationFrame=window.requestAnimationFrame(function(){ne._renderCallback(),ne._animationFrame=void 0})))},ee.prototype._restartInterval=function(ne){var E=this;ne===void 0&&(ne=600),this._blinkInterval&&window.clearInterval(this._blinkInterval),this._blinkStartTimeout=window.setTimeout(function(){if(E._animationTimeRestarted){var b=600-(Date.now()-E._animationTimeRestarted);if(E._animationTimeRestarted=void 0,b>0)return void E._restartInterval(b)}E.isCursorVisible=!1,E._animationFrame=window.requestAnimationFrame(function(){E._renderCallback(),E._animationFrame=void 0}),E._blinkInterval=window.setInterval(function(){if(E._animationTimeRestarted){var z=600-(Date.now()-E._animationTimeRestarted);return E._animationTimeRestarted=void 0,void E._restartInterval(z)}E.isCursorVisible=!E.isCursorVisible,E._animationFrame=window.requestAnimationFrame(function(){E._renderCallback(),E._animationFrame=void 0})},600)},ne)},ee.prototype.pause=function(){this.isCursorVisible=!0,this._blinkInterval&&(window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},ee.prototype.resume=function(){this.pause(),this._animationTimeRestarted=void 0,this._restartInterval(),this.restartBlinkAnimation()},ee}()},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ee,ne){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(E,b){E.__proto__=b}||function(E,b){for(var z in b)b.hasOwnProperty(z)&&(E[z]=b[z])})(ee,ne)},function(ee,ne){function E(){this.constructor=ee}ie(ee,ne),ee.prototype=ne===null?Object.create(ne):(E.prototype=ne.prototype,new E)});Object.defineProperty(be,"__esModule",{value:!0}),be.LinkRenderLayer=void 0;var ue=ce(13),se=ce(9),te=ce(26),le=function(ee){function ne(E,b,z,x,re,ae,oe,ve){var ye=ee.call(this,E,"link",b,!0,z,x,oe,ve)||this;return re.onShowLinkUnderline(function(me){return ye._onShowLinkUnderline(me)}),re.onHideLinkUnderline(function(me){return ye._onHideLinkUnderline(me)}),ae.onShowLinkUnderline(function(me){return ye._onShowLinkUnderline(me)}),ae.onHideLinkUnderline(function(me){return ye._onHideLinkUnderline(me)}),ye}return Ce(ne,ee),ne.prototype.resize=function(E){ee.prototype.resize.call(this,E),this._state=void 0},ne.prototype.reset=function(){this._clearCurrentLink()},ne.prototype._clearCurrentLink=function(){if(this._state){this._clearCells(this._state.x1,this._state.y1,this._state.cols-this._state.x1,1);var E=this._state.y2-this._state.y1-1;E>0&&this._clearCells(0,this._state.y1+1,this._state.cols,E),this._clearCells(0,this._state.y2,this._state.x2,1),this._state=void 0}},ne.prototype._onShowLinkUnderline=function(E){if(E.fg===se.INVERTED_DEFAULT_COLOR?this._ctx.fillStyle=this._colors.background.css:E.fg&&te.is256Color(E.fg)?this._ctx.fillStyle=this._colors.ansi[E.fg].css:this._ctx.fillStyle=this._colors.foreground.css,E.y1===E.y2)this._fillBottomLineAtCells(E.x1,E.y1,E.x2-E.x1);else{this._fillBottomLineAtCells(E.x1,E.y1,E.cols-E.x1);for(var b=E.y1+1;b<E.y2;b++)this._fillBottomLineAtCells(0,b,E.cols);this._fillBottomLineAtCells(0,E.y2,E.x2)}this._state=E},ne.prototype._onHideLinkUnderline=function(E){this._clearCurrentLink()},ne}(ue.BaseRenderLayer);be.LinkRenderLayer=le},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(ee,ne,E,b){var z,x=arguments.length,re=x<3?ne:b===null?b=Object.getOwnPropertyDescriptor(ne,E):b;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")re=Reflect.decorate(ee,ne,E,b);else for(var ae=ee.length-1;ae>=0;ae--)(z=ee[ae])&&(re=(x<3?z(re):x>3?z(ne,E,re):z(ne,E))||re);return x>3&&re&&Object.defineProperty(ne,E,re),re},Ce=this&&this.__param||function(ee,ne){return function(E,b){ne(E,b,ee)}};Object.defineProperty(be,"__esModule",{value:!0}),be.MouseZone=be.Linkifier=void 0;var ue=ce(0),se=ce(1),te=function(){function ee(ne,E,b){this._bufferService=ne,this._logService=E,this._unicodeService=b,this._linkMatchers=[],this._nextLinkMatcherId=0,this._onShowLinkUnderline=new ue.EventEmitter,this._onHideLinkUnderline=new ue.EventEmitter,this._onLinkTooltip=new ue.EventEmitter,this._rowsToLinkify={start:void 0,end:void 0}}return Object.defineProperty(ee.prototype,"onShowLinkUnderline",{get:function(){return this._onShowLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(ee.prototype,"onHideLinkUnderline",{get:function(){return this._onHideLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(ee.prototype,"onLinkTooltip",{get:function(){return this._onLinkTooltip.event},enumerable:!1,configurable:!0}),ee.prototype.attachToDom=function(ne,E){this._element=ne,this._mouseZoneManager=E},ee.prototype.linkifyRows=function(ne,E){var b=this;this._mouseZoneManager&&(this._rowsToLinkify.start===void 0||this._rowsToLinkify.end===void 0?(this._rowsToLinkify.start=ne,this._rowsToLinkify.end=E):(this._rowsToLinkify.start=Math.min(this._rowsToLinkify.start,ne),this._rowsToLinkify.end=Math.max(this._rowsToLinkify.end,E)),this._mouseZoneManager.clearAll(ne,E),this._rowsTimeoutId&&clearTimeout(this._rowsTimeoutId),this._rowsTimeoutId=setTimeout(function(){return b._linkifyRows()},ee._timeBeforeLatency))},ee.prototype._linkifyRows=function(){this._rowsTimeoutId=void 0;var ne=this._bufferService.buffer;if(this._rowsToLinkify.start!==void 0&&this._rowsToLinkify.end!==void 0){var E=ne.ydisp+this._rowsToLinkify.start;if(!(E>=ne.lines.length)){for(var b=ne.ydisp+Math.min(this._rowsToLinkify.end,this._bufferService.rows)+1,z=Math.ceil(2e3/this._bufferService.cols),x=this._bufferService.buffer.iterator(!1,E,b,z,z);x.hasNext();)for(var re=x.next(),ae=0;ae<this._linkMatchers.length;ae++)this._doLinkifyRow(re.range.first,re.content,this._linkMatchers[ae]);this._rowsToLinkify.start=void 0,this._rowsToLinkify.end=void 0}}else this._logService.debug("_rowToLinkify was unset before _linkifyRows was called")},ee.prototype.registerLinkMatcher=function(ne,E,b){if(b===void 0&&(b={}),!E)throw new Error("handler must be defined");var z={id:this._nextLinkMatcherId++,regex:ne,handler:E,matchIndex:b.matchIndex,validationCallback:b.validationCallback,hoverTooltipCallback:b.tooltipCallback,hoverLeaveCallback:b.leaveCallback,willLinkActivate:b.willLinkActivate,priority:b.priority||0};return this._addLinkMatcherToList(z),z.id},ee.prototype._addLinkMatcherToList=function(ne){if(this._linkMatchers.length!==0){for(var E=this._linkMatchers.length-1;E>=0;E--)if(ne.priority<=this._linkMatchers[E].priority)return void this._linkMatchers.splice(E+1,0,ne);this._linkMatchers.splice(0,0,ne)}else this._linkMatchers.push(ne)},ee.prototype.deregisterLinkMatcher=function(ne){for(var E=0;E<this._linkMatchers.length;E++)if(this._linkMatchers[E].id===ne)return this._linkMatchers.splice(E,1),!0;return!1},ee.prototype._doLinkifyRow=function(ne,E,b){for(var z,x=this,re=new RegExp(b.regex.source,(b.regex.flags||"")+"g"),ae=-1,oe=function(){var ye=z[typeof b.matchIndex!="number"?0:b.matchIndex];if(!ye)return ve._logService.debug("match found without corresponding matchIndex",z,b),"break";if(ae=E.indexOf(ye,ae+1),re.lastIndex=ae+ye.length,ae<0)return"break";var me=ve._bufferService.buffer.stringIndexToBufferIndex(ne,ae);if(me[0]<0)return"break";var ge=ve._bufferService.buffer.lines.get(me[0]);if(!ge)return"break";var _e=ge.getFg(me[1]),he=_e?_e>>9&511:void 0;b.validationCallback?b.validationCallback(ye,function(pe){x._rowsTimeoutId||pe&&x._addLink(me[1],me[0]-x._bufferService.buffer.ydisp,ye,b,he)}):ve._addLink(me[1],me[0]-ve._bufferService.buffer.ydisp,ye,b,he)},ve=this;(z=re.exec(E))!==null&&oe()!=="break";);},ee.prototype._addLink=function(ne,E,b,z,x){var re=this;if(this._mouseZoneManager&&this._element){var ae=this._unicodeService.getStringCellWidth(b),oe=ne%this._bufferService.cols,ve=E+Math.floor(ne/this._bufferService.cols),ye=(oe+ae)%this._bufferService.cols,me=ve+Math.floor((oe+ae)/this._bufferService.cols);ye===0&&(ye=this._bufferService.cols,me--),this._mouseZoneManager.add(new le(oe+1,ve+1,ye+1,me+1,function(ge){if(z.handler)return z.handler(ge,b);var _e=window.open();_e?(_e.opener=null,_e.location.href=b):console.warn("Opening link blocked as opener could not be cleared")},function(){re._onShowLinkUnderline.fire(re._createLinkHoverEvent(oe,ve,ye,me,x)),re._element.classList.add("xterm-cursor-pointer")},function(ge){re._onLinkTooltip.fire(re._createLinkHoverEvent(oe,ve,ye,me,x)),z.hoverTooltipCallback&&z.hoverTooltipCallback(ge,b,{start:{x:oe,y:ve},end:{x:ye,y:me}})},function(){re._onHideLinkUnderline.fire(re._createLinkHoverEvent(oe,ve,ye,me,x)),re._element.classList.remove("xterm-cursor-pointer"),z.hoverLeaveCallback&&z.hoverLeaveCallback()},function(ge){return!z.willLinkActivate||z.willLinkActivate(ge,b)}))}},ee.prototype._createLinkHoverEvent=function(ne,E,b,z,x){return{x1:ne,y1:E,x2:b,y2:z,cols:this._bufferService.cols,fg:x}},ee._timeBeforeLatency=200,ee=ie([Ce(0,se.IBufferService),Ce(1,se.ILogService),Ce(2,se.IUnicodeService)],ee)}();be.Linkifier=te;var le=function(ee,ne,E,b,z,x,re,ae,oe){this.x1=ee,this.y1=ne,this.x2=E,this.y2=b,this.clickCallback=z,this.hoverCallback=x,this.tooltipCallback=re,this.leaveCallback=ae,this.willLinkActivate=oe};be.MouseZone=le},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ye,me){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ge,_e){ge.__proto__=_e}||function(ge,_e){for(var he in _e)_e.hasOwnProperty(he)&&(ge[he]=_e[he])})(ye,me)},function(ye,me){function ge(){this.constructor=ye}ie(ye,me),ye.prototype=me===null?Object.create(me):(ge.prototype=me.prototype,new ge)}),ue=this&&this.__decorate||function(ye,me,ge,_e){var he,pe=arguments.length,ke=pe<3?me:_e===null?_e=Object.getOwnPropertyDescriptor(me,ge):_e;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ke=Reflect.decorate(ye,me,ge,_e);else for(var Te=ye.length-1;Te>=0;Te--)(he=ye[Te])&&(ke=(pe<3?he(ke):pe>3?he(me,ge,ke):he(me,ge))||ke);return pe>3&&ke&&Object.defineProperty(me,ge,ke),ke},se=this&&this.__param||function(ye,me){return function(ge,_e){me(ge,_e,ye)}};Object.defineProperty(be,"__esModule",{value:!0}),be.SelectionService=void 0;var te=ce(11),le=ce(52),ee=ce(4),ne=ce(0),E=ce(5),b=ce(1),z=ce(30),x=ce(53),re=ce(2),ae="\xA0",oe=new RegExp(ae,"g"),ve=function(ye){function me(ge,_e,he,pe,ke,Te,Ee){var Oe=ye.call(this)||this;return Oe._element=ge,Oe._screenElement=_e,Oe._bufferService=he,Oe._coreService=pe,Oe._mouseService=ke,Oe._optionsService=Te,Oe._renderService=Ee,Oe._dragScrollAmount=0,Oe._enabled=!0,Oe._workCell=new ee.CellData,Oe._mouseDownTimeStamp=0,Oe._onLinuxMouseSelection=Oe.register(new ne.EventEmitter),Oe._onRedrawRequest=Oe.register(new ne.EventEmitter),Oe._onSelectionChange=Oe.register(new ne.EventEmitter),Oe._onRequestScrollLines=Oe.register(new ne.EventEmitter),Oe._mouseMoveListener=function(je){return Oe._onMouseMove(je)},Oe._mouseUpListener=function(je){return Oe._onMouseUp(je)},Oe._coreService.onUserInput(function(){Oe.hasSelection&&Oe.clearSelection()}),Oe._trimListener=Oe._bufferService.buffer.lines.onTrim(function(je){return Oe._onTrim(je)}),Oe.register(Oe._bufferService.buffers.onBufferActivate(function(je){return Oe._onBufferActivate(je)})),Oe.enable(),Oe._model=new le.SelectionModel(Oe._bufferService),Oe._activeSelectionMode=0,Oe}return Ce(me,ye),Object.defineProperty(me.prototype,"onLinuxMouseSelection",{get:function(){return this._onLinuxMouseSelection.event},enumerable:!1,configurable:!0}),Object.defineProperty(me.prototype,"onRequestRedraw",{get:function(){return this._onRedrawRequest.event},enumerable:!1,configurable:!0}),Object.defineProperty(me.prototype,"onSelectionChange",{get:function(){return this._onSelectionChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(me.prototype,"onRequestScrollLines",{get:function(){return this._onRequestScrollLines.event},enumerable:!1,configurable:!0}),me.prototype.dispose=function(){this._removeMouseDownListeners()},me.prototype.reset=function(){this.clearSelection()},me.prototype.disable=function(){this.clearSelection(),this._enabled=!1},me.prototype.enable=function(){this._enabled=!0},Object.defineProperty(me.prototype,"selectionStart",{get:function(){return this._model.finalSelectionStart},enumerable:!1,configurable:!0}),Object.defineProperty(me.prototype,"selectionEnd",{get:function(){return this._model.finalSelectionEnd},enumerable:!1,configurable:!0}),Object.defineProperty(me.prototype,"hasSelection",{get:function(){var ge=this._model.finalSelectionStart,_e=this._model.finalSelectionEnd;return!(!ge||!_e)&&(ge[0]!==_e[0]||ge[1]!==_e[1])},enumerable:!1,configurable:!0}),Object.defineProperty(me.prototype,"selectionText",{get:function(){var ge=this._model.finalSelectionStart,_e=this._model.finalSelectionEnd;if(!ge||!_e)return"";var he=this._bufferService.buffer,pe=[];if(this._activeSelectionMode===3){if(ge[0]===_e[0])return"";for(var ke=ge[1];ke<=_e[1];ke++){var Te=he.translateBufferLineToString(ke,!0,ge[0],_e[0]);pe.push(Te)}}else{var Ee=ge[1]===_e[1]?_e[0]:void 0;for(pe.push(he.translateBufferLineToString(ge[1],!0,ge[0],Ee)),ke=ge[1]+1;ke<=_e[1]-1;ke++){var Oe=he.lines.get(ke);Te=he.translateBufferLineToString(ke,!0),Oe&&Oe.isWrapped?pe[pe.length-1]+=Te:pe.push(Te)}ge[1]!==_e[1]&&(Oe=he.lines.get(_e[1]),Te=he.translateBufferLineToString(_e[1],!0,0,_e[0]),Oe&&Oe.isWrapped?pe[pe.length-1]+=Te:pe.push(Te))}return pe.map(function(je){return je.replace(oe," ")}).join(te.isWindows?`\r
|
|
|
`:`
|
|
|
`)},enumerable:!1,configurable:!0}),me.prototype.clearSelection=function(){this._model.clearSelection(),this._removeMouseDownListeners(),this.refresh(),this._onSelectionChange.fire()},me.prototype.refresh=function(ge){var _e=this;this._refreshAnimationFrame||(this._refreshAnimationFrame=window.requestAnimationFrame(function(){return _e._refresh()})),te.isLinux&&ge&&this.selectionText.length&&this._onLinuxMouseSelection.fire(this.selectionText)},me.prototype._refresh=function(){this._refreshAnimationFrame=void 0,this._onRedrawRequest.fire({start:this._model.finalSelectionStart,end:this._model.finalSelectionEnd,columnSelectMode:this._activeSelectionMode===3})},me.prototype.isClickInSelection=function(ge){var _e=this._getMouseBufferCoords(ge),he=this._model.finalSelectionStart,pe=this._model.finalSelectionEnd;return!!(he&&pe&&_e)&&this._areCoordsInSelection(_e,he,pe)},me.prototype._areCoordsInSelection=function(ge,_e,he){return ge[1]>_e[1]&&ge[1]<he[1]||_e[1]===he[1]&&ge[1]===_e[1]&&ge[0]>=_e[0]&&ge[0]<he[0]||_e[1]<he[1]&&ge[1]===he[1]&&ge[0]<he[0]||_e[1]<he[1]&&ge[1]===_e[1]&&ge[0]>=_e[0]},me.prototype.selectWordAtCursor=function(ge){var _e=this._getMouseBufferCoords(ge);_e&&(this._selectWordAt(_e,!1),this._model.selectionEnd=void 0,this.refresh(!0))},me.prototype.selectAll=function(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()},me.prototype.selectLines=function(ge,_e){this._model.clearSelection(),ge=Math.max(ge,0),_e=Math.min(_e,this._bufferService.buffer.lines.length-1),this._model.selectionStart=[0,ge],this._model.selectionEnd=[this._bufferService.cols,_e],this.refresh(),this._onSelectionChange.fire()},me.prototype._onTrim=function(ge){this._model.onTrim(ge)&&this.refresh()},me.prototype._getMouseBufferCoords=function(ge){var _e=this._mouseService.getCoords(ge,this._screenElement,this._bufferService.cols,this._bufferService.rows,!0);if(_e)return _e[0]--,_e[1]--,_e[1]+=this._bufferService.buffer.ydisp,_e},me.prototype._getMouseEventScrollAmount=function(ge){var _e=z.getCoordsRelativeToElement(ge,this._screenElement)[1],he=this._renderService.dimensions.canvasHeight;return _e>=0&&_e<=he?0:(_e>he&&(_e-=he),_e=Math.min(Math.max(_e,-50),50),(_e/=50)/Math.abs(_e)+Math.round(14*_e))},me.prototype.shouldForceSelection=function(ge){return te.isMac?ge.altKey&&this._optionsService.options.macOptionClickForcesSelection:ge.shiftKey},me.prototype.onMouseDown=function(ge){if(this._mouseDownTimeStamp=ge.timeStamp,(ge.button!==2||!this.hasSelection)&&ge.button===0){if(!this._enabled){if(!this.shouldForceSelection(ge))return;ge.stopPropagation()}ge.preventDefault(),this._dragScrollAmount=0,this._enabled&&ge.shiftKey?this._onIncrementalClick(ge):ge.detail===1?this._onSingleClick(ge):ge.detail===2?this._onDoubleClick(ge):ge.detail===3&&this._onTripleClick(ge),this._addMouseDownListeners(),this.refresh(!0)}},me.prototype._addMouseDownListeners=function(){var ge=this;this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.addEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.addEventListener("mouseup",this._mouseUpListener)),this._dragScrollIntervalTimer=window.setInterval(function(){return ge._dragScroll()},50)},me.prototype._removeMouseDownListeners=function(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.removeEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.removeEventListener("mouseup",this._mouseUpListener)),clearInterval(this._dragScrollIntervalTimer),this._dragScrollIntervalTimer=void 0},me.prototype._onIncrementalClick=function(ge){this._model.selectionStart&&(this._model.selectionEnd=this._getMouseBufferCoords(ge))},me.prototype._onSingleClick=function(ge){if(this._model.selectionStartLength=0,this._model.isSelectAllActive=!1,this._activeSelectionMode=this.shouldColumnSelect(ge)?3:0,this._model.selectionStart=this._getMouseBufferCoords(ge),this._model.selectionStart){this._model.selectionEnd=void 0;var _e=this._bufferService.buffer.lines.get(this._model.selectionStart[1]);_e&&_e.length!==this._model.selectionStart[0]&&_e.hasWidth(this._model.selectionStart[0])===0&&this._model.selectionStart[0]++}},me.prototype._onDoubleClick=function(ge){var _e=this._getMouseBufferCoords(ge);_e&&(this._activeSelectionMode=1,this._selectWordAt(_e,!0))},me.prototype._onTripleClick=function(ge){var _e=this._getMouseBufferCoords(ge);_e&&(this._activeSelectionMode=2,this._selectLineAt(_e[1]))},me.prototype.shouldColumnSelect=function(ge){return ge.altKey&&!(te.isMac&&this._optionsService.options.macOptionClickForcesSelection)},me.prototype._onMouseMove=function(ge){if(ge.stopImmediatePropagation(),this._model.selectionStart){var _e=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;if(this._model.selectionEnd=this._getMouseBufferCoords(ge),this._model.selectionEnd){this._activeSelectionMode===2?this._model.selectionEnd[1]<this._model.selectionStart[1]?this._model.selectionEnd[0]=0:this._model.selectionEnd[0]=this._bufferService.cols:this._activeSelectionMode===1&&this._selectToWordAt(this._model.selectionEnd),this._dragScrollAmount=this._getMouseEventScrollAmount(ge),this._activeSelectionMode!==3&&(this._dragScrollAmount>0?this._model.selectionEnd[0]=this._bufferService.cols:this._dragScrollAmount<0&&(this._model.selectionEnd[0]=0));var he=this._bufferService.buffer;if(this._model.selectionEnd[1]<he.lines.length){var pe=he.lines.get(this._model.selectionEnd[1]);pe&&pe.hasWidth(this._model.selectionEnd[0])===0&&this._model.selectionEnd[0]++}_e&&_e[0]===this._model.selectionEnd[0]&&_e[1]===this._model.selectionEnd[1]||this.refresh(!0)}else this.refresh(!0)}},me.prototype._dragScroll=function(){if(this._model.selectionEnd&&this._model.selectionStart&&this._dragScrollAmount){this._onRequestScrollLines.fire({amount:this._dragScrollAmount,suppressScrollEvent:!1});var ge=this._bufferService.buffer;this._dragScrollAmount>0?(this._activeSelectionMode!==3&&(this._model.selectionEnd[0]=this._bufferService.cols),this._model.selectionEnd[1]=Math.min(ge.ydisp+this._bufferService.rows,ge.lines.length-1)):(this._activeSelectionMode!==3&&(this._model.selectionEnd[0]=0),this._model.selectionEnd[1]=ge.ydisp),this.refresh()}},me.prototype._onMouseUp=function(ge){var _e=ge.timeStamp-this._mouseDownTimeStamp;if(this._removeMouseDownListeners(),this.selectionText.length<=1&&_e<500&&ge.altKey){if(this._bufferService.buffer.ybase===this._bufferService.buffer.ydisp){var he=this._mouseService.getCoords(ge,this._element,this._bufferService.cols,this._bufferService.rows,!1);if(he&&he[0]!==void 0&&he[1]!==void 0){var pe=x.moveToCellSequence(he[0]-1,he[1]-1,this._bufferService,this._coreService.decPrivateModes.applicationCursorKeys);this._coreService.triggerDataEvent(pe,!0)}}}else this.hasSelection&&this._onSelectionChange.fire()},me.prototype._onBufferActivate=function(ge){var _e=this;this.clearSelection(),this._trimListener.dispose(),this._trimListener=ge.activeBuffer.lines.onTrim(function(he){return _e._onTrim(he)})},me.prototype._convertViewportColToCharacterIndex=function(ge,_e){for(var he=_e[0],pe=0;_e[0]>=pe;pe++){var ke=ge.loadCell(pe,this._workCell).getChars().length;this._workCell.getWidth()===0?he--:ke>1&&_e[0]!==pe&&(he+=ke-1)}return he},me.prototype.setSelection=function(ge,_e,he){this._model.clearSelection(),this._removeMouseDownListeners(),this._model.selectionStart=[ge,_e],this._model.selectionStartLength=he,this.refresh()},me.prototype._getWordAt=function(ge,_e,he,pe){if(he===void 0&&(he=!0),pe===void 0&&(pe=!0),!(ge[0]>=this._bufferService.cols)){var ke=this._bufferService.buffer,Te=ke.lines.get(ge[1]);if(Te){var Ee=ke.translateBufferLineToString(ge[1],!1),Oe=this._convertViewportColToCharacterIndex(Te,ge),je=Oe,Pe=ge[0]-Oe,Qe=0,Xe=0,ot=0,He=0;if(Ee.charAt(Oe)===" "){for(;Oe>0&&Ee.charAt(Oe-1)===" ";)Oe--;for(;je<Ee.length&&Ee.charAt(je+1)===" ";)je++}else{var rt=ge[0],Ye=ge[0];Te.getWidth(rt)===0&&(Qe++,rt--),Te.getWidth(Ye)===2&&(Xe++,Ye++);var ut=Te.getString(Ye).length;for(ut>1&&(He+=ut-1,je+=ut-1);rt>0&&Oe>0&&!this._isCharWordSeparator(Te.loadCell(rt-1,this._workCell));){Te.loadCell(rt-1,this._workCell);var Ge=this._workCell.getChars().length;this._workCell.getWidth()===0?(Qe++,rt--):Ge>1&&(ot+=Ge-1,Oe-=Ge-1),Oe--,rt--}for(;Ye<Te.length&&je+1<Ee.length&&!this._isCharWordSeparator(Te.loadCell(Ye+1,this._workCell));){Te.loadCell(Ye+1,this._workCell);var ze=this._workCell.getChars().length;this._workCell.getWidth()===2?(Xe++,Ye++):ze>1&&(He+=ze-1,je+=ze-1),je++,Ye++}}je++;var Ve=Oe+Pe-Qe+ot,$e=Math.min(this._bufferService.cols,je-Oe+Qe+Xe-ot-He);if(_e||Ee.slice(Oe,je).trim()!==""){if(he&&Ve===0&&Te.getCodePoint(0)!==32){var nt=ke.lines.get(ge[1]-1);if(nt&&Te.isWrapped&&nt.getCodePoint(this._bufferService.cols-1)!==32){var et=this._getWordAt([this._bufferService.cols-1,ge[1]-1],!1,!0,!1);if(et){var pt=this._bufferService.cols-et.start;Ve-=pt,$e+=pt}}}if(pe&&Ve+$e===this._bufferService.cols&&Te.getCodePoint(this._bufferService.cols-1)!==32){var ct=ke.lines.get(ge[1]+1);if(ct&&ct.isWrapped&&ct.getCodePoint(0)!==32){var Ot=this._getWordAt([0,ge[1]+1],!1,!1,!0);Ot&&($e+=Ot.length)}}return{start:Ve,length:$e}}}}},me.prototype._selectWordAt=function(ge,_e){var he=this._getWordAt(ge,_e);if(he){for(;he.start<0;)he.start+=this._bufferService.cols,ge[1]--;this._model.selectionStart=[he.start,ge[1]],this._model.selectionStartLength=he.length}},me.prototype._selectToWordAt=function(ge){var _e=this._getWordAt(ge,!0);if(_e){for(var he=ge[1];_e.start<0;)_e.start+=this._bufferService.cols,he--;if(!this._model.areSelectionValuesReversed())for(;_e.start+_e.length>this._bufferService.cols;)_e.length-=this._bufferService.cols,he++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?_e.start:_e.start+_e.length,he]}},me.prototype._isCharWordSeparator=function(ge){return ge.getWidth()!==0&&this._optionsService.options.wordSeparator.indexOf(ge.getChars())>=0},me.prototype._selectLineAt=function(ge){var _e=this._bufferService.buffer.getWrappedRangeForLine(ge);this._model.selectionStart=[0,_e.first],this._model.selectionEnd=[this._bufferService.cols,_e.last],this._model.selectionStartLength=0},me=ue([se(2,b.IBufferService),se(3,b.ICoreService),se(4,E.IMouseService),se(5,b.IOptionsService),se(6,E.IRenderService)],me)}(re.Disposable);be.SelectionService=ve},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.SelectionModel=void 0;var ie=function(){function Ce(ue){this._bufferService=ue,this.isSelectAllActive=!1,this.selectionStartLength=0}return Ce.prototype.clearSelection=function(){this.selectionStart=void 0,this.selectionEnd=void 0,this.isSelectAllActive=!1,this.selectionStartLength=0},Object.defineProperty(Ce.prototype,"finalSelectionStart",{get:function(){return this.isSelectAllActive?[0,0]:this.selectionEnd&&this.selectionStart&&this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart},enumerable:!1,configurable:!0}),Object.defineProperty(Ce.prototype,"finalSelectionEnd",{get:function(){if(this.isSelectAllActive)return[this._bufferService.cols,this._bufferService.buffer.ybase+this._bufferService.rows-1];if(this.selectionStart){if(!this.selectionEnd||this.areSelectionValuesReversed()){var ue=this.selectionStart[0]+this.selectionStartLength;return ue>this._bufferService.cols?[ue%this._bufferService.cols,this.selectionStart[1]+Math.floor(ue/this._bufferService.cols)]:[ue,this.selectionStart[1]]}return this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]?[Math.max(this.selectionStart[0]+this.selectionStartLength,this.selectionEnd[0]),this.selectionEnd[1]]:this.selectionEnd}},enumerable:!1,configurable:!0}),Ce.prototype.areSelectionValuesReversed=function(){var ue=this.selectionStart,se=this.selectionEnd;return!(!ue||!se)&&(ue[1]>se[1]||ue[1]===se[1]&&ue[0]>se[0])},Ce.prototype.onTrim=function(ue){return this.selectionStart&&(this.selectionStart[1]-=ue),this.selectionEnd&&(this.selectionEnd[1]-=ue),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)},Ce}();be.SelectionModel=ie},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.moveToCellSequence=void 0;var ie=ce(12);function Ce(ne,E,b,z){var x=ne-ue(b,ne),re=E-ue(b,E);return ee(Math.abs(x-re)-function(ae,oe,ve){for(var ye=0,me=ae-ue(ve,ae),ge=oe-ue(ve,oe),_e=0;_e<Math.abs(me-ge);_e++){var he=se(ae,oe)==="A"?-1:1,pe=ve.buffer.lines.get(me+he*_e);pe&&pe.isWrapped&&ye++}return ye}(ne,E,b),le(se(ne,E),z))}function ue(ne,E){for(var b=0,z=ne.buffer.lines.get(E),x=z&&z.isWrapped;x&&E>=0&&E<ne.rows;)b++,x=(z=ne.buffer.lines.get(--E))&&z.isWrapped;return b}function se(ne,E){return ne>E?"A":"B"}function te(ne,E,b,z,x,re){for(var ae=ne,oe=E,ve="";ae!==b||oe!==z;)ae+=x?1:-1,x&&ae>re.cols-1?(ve+=re.buffer.translateBufferLineToString(oe,!1,ne,ae),ae=0,ne=0,oe++):!x&&ae<0&&(ve+=re.buffer.translateBufferLineToString(oe,!1,0,ne+1),ne=ae=re.cols-1,oe--);return ve+re.buffer.translateBufferLineToString(oe,!1,ne,ae)}function le(ne,E){var b=E?"O":"[";return ie.C0.ESC+b+ne}function ee(ne,E){ne=Math.floor(ne);for(var b="",z=0;z<ne;z++)b+=E;return b}be.moveToCellSequence=function(ne,E,b,z){var x,re=b.buffer.x,ae=b.buffer.y;if(!b.buffer.hasScrollback)return function(ve,ye,me,ge,_e,he){return Ce(ye,ge,_e,he).length===0?"":ee(te(ve,ye,ve,ye-ue(_e,ye),!1,_e).length,le("D",he))}(re,ae,0,E,b,z)+Ce(ae,E,b,z)+function(ve,ye,me,ge,_e,he){var pe;pe=Ce(ye,ge,_e,he).length>0?ge-ue(_e,ge):ye;var ke=ge,Te=function(Ee,Oe,je,Pe,Qe,Xe){var ot;return ot=Ce(je,Pe,Qe,Xe).length>0?Pe-ue(Qe,Pe):Oe,Ee<je&&ot<=Pe||Ee>=je&&ot<Pe?"C":"D"}(ve,ye,me,ge,_e,he);return ee(te(ve,pe,me,ke,Te==="C",_e).length,le(Te,he))}(re,ae,ne,E,b,z);if(ae===E)return x=re>ne?"D":"C",ee(Math.abs(re-ne),le(x,z));x=ae>E?"D":"C";var oe=Math.abs(ae-E);return ee(function(ve,ye){return ye.cols-ve}(ae>E?ne:re,b)+(oe-1)*b.cols+1+((ae>E?re:ne)-1),le(x,z))}},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(te,le,ee,ne){var E,b=arguments.length,z=b<3?le:ne===null?ne=Object.getOwnPropertyDescriptor(le,ee):ne;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")z=Reflect.decorate(te,le,ee,ne);else for(var x=te.length-1;x>=0;x--)(E=te[x])&&(z=(b<3?E(z):b>3?E(le,ee,z):E(le,ee))||z);return b>3&&z&&Object.defineProperty(le,ee,z),z},Ce=this&&this.__param||function(te,le){return function(ee,ne){le(ee,ne,te)}};Object.defineProperty(be,"__esModule",{value:!0}),be.SoundService=void 0;var ue=ce(1),se=function(){function te(le){this._optionsService=le}return Object.defineProperty(te,"audioContext",{get:function(){if(!te._audioContext){var le=window.AudioContext||window.webkitAudioContext;if(!le)return console.warn("Web Audio API is not supported by this browser. Consider upgrading to the latest version"),null;te._audioContext=new le}return te._audioContext},enumerable:!1,configurable:!0}),te.prototype.playBellSound=function(){var le=te.audioContext;if(le){var ee=le.createBufferSource();le.decodeAudioData(this._base64ToArrayBuffer(this._removeMimeType(this._optionsService.options.bellSound)),function(ne){ee.buffer=ne,ee.connect(le.destination),ee.start(0)})}},te.prototype._base64ToArrayBuffer=function(le){for(var ee=window.atob(le),ne=ee.length,E=new Uint8Array(ne),b=0;b<ne;b++)E[b]=ee.charCodeAt(b);return E.buffer},te.prototype._removeMimeType=function(le){return le.split(",")[1]},te=ie([Ce(0,ue.IOptionsService)],te)}();be.SoundService=se},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(b,z){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,re){x.__proto__=re}||function(x,re){for(var ae in re)re.hasOwnProperty(ae)&&(x[ae]=re[ae])})(b,z)},function(b,z){function x(){this.constructor=b}ie(b,z),b.prototype=z===null?Object.create(z):(x.prototype=z.prototype,new x)}),ue=this&&this.__decorate||function(b,z,x,re){var ae,oe=arguments.length,ve=oe<3?z:re===null?re=Object.getOwnPropertyDescriptor(z,x):re;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ve=Reflect.decorate(b,z,x,re);else for(var ye=b.length-1;ye>=0;ye--)(ae=b[ye])&&(ve=(oe<3?ae(ve):oe>3?ae(z,x,ve):ae(z,x))||ve);return oe>3&&ve&&Object.defineProperty(z,x,ve),ve},se=this&&this.__param||function(b,z){return function(x,re){z(x,re,b)}};Object.defineProperty(be,"__esModule",{value:!0}),be.MouseZoneManager=void 0;var te=ce(2),le=ce(7),ee=ce(5),ne=ce(1),E=function(b){function z(x,re,ae,oe,ve,ye){var me=b.call(this)||this;return me._element=x,me._screenElement=re,me._bufferService=ae,me._mouseService=oe,me._selectionService=ve,me._optionsService=ye,me._zones=[],me._areZonesActive=!1,me._lastHoverCoords=[void 0,void 0],me._initialSelectionLength=0,me.register(le.addDisposableDomListener(me._element,"mousedown",function(ge){return me._onMouseDown(ge)})),me._mouseMoveListener=function(ge){return me._onMouseMove(ge)},me._mouseLeaveListener=function(ge){return me._onMouseLeave(ge)},me._clickListener=function(ge){return me._onClick(ge)},me}return Ce(z,b),z.prototype.dispose=function(){b.prototype.dispose.call(this),this._deactivate()},z.prototype.add=function(x){this._zones.push(x),this._zones.length===1&&this._activate()},z.prototype.clearAll=function(x,re){if(this._zones.length!==0){x&&re||(x=0,re=this._bufferService.rows-1);for(var ae=0;ae<this._zones.length;ae++){var oe=this._zones[ae];(oe.y1>x&&oe.y1<=re+1||oe.y2>x&&oe.y2<=re+1||oe.y1<x&&oe.y2>re+1)&&(this._currentZone&&this._currentZone===oe&&(this._currentZone.leaveCallback(),this._currentZone=void 0),this._zones.splice(ae--,1))}this._zones.length===0&&this._deactivate()}},z.prototype._activate=function(){this._areZonesActive||(this._areZonesActive=!0,this._element.addEventListener("mousemove",this._mouseMoveListener),this._element.addEventListener("mouseleave",this._mouseLeaveListener),this._element.addEventListener("click",this._clickListener))},z.prototype._deactivate=function(){this._areZonesActive&&(this._areZonesActive=!1,this._element.removeEventListener("mousemove",this._mouseMoveListener),this._element.removeEventListener("mouseleave",this._mouseLeaveListener),this._element.removeEventListener("click",this._clickListener))},z.prototype._onMouseMove=function(x){this._lastHoverCoords[0]===x.pageX&&this._lastHoverCoords[1]===x.pageY||(this._onHover(x),this._lastHoverCoords=[x.pageX,x.pageY])},z.prototype._onHover=function(x){var re=this,ae=this._findZoneEventAt(x);ae!==this._currentZone&&(this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=void 0,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout)),ae&&(this._currentZone=ae,ae.hoverCallback&&ae.hoverCallback(x),this._tooltipTimeout=window.setTimeout(function(){return re._onTooltip(x)},this._optionsService.options.linkTooltipHoverDuration)))},z.prototype._onTooltip=function(x){this._tooltipTimeout=void 0;var re=this._findZoneEventAt(x);re&&re.tooltipCallback&&re.tooltipCallback(x)},z.prototype._onMouseDown=function(x){if(this._initialSelectionLength=this._getSelectionLength(),this._areZonesActive){var re=this._findZoneEventAt(x);re!=null&&re.willLinkActivate(x)&&(x.preventDefault(),x.stopImmediatePropagation())}},z.prototype._onMouseLeave=function(x){this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=void 0,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout))},z.prototype._onClick=function(x){var re=this._findZoneEventAt(x),ae=this._getSelectionLength();re&&ae===this._initialSelectionLength&&(re.clickCallback(x),x.preventDefault(),x.stopImmediatePropagation())},z.prototype._getSelectionLength=function(){var x=this._selectionService.selectionText;return x?x.length:0},z.prototype._findZoneEventAt=function(x){var re=this._mouseService.getCoords(x,this._screenElement,this._bufferService.cols,this._bufferService.rows);if(re)for(var ae=re[0],oe=re[1],ve=0;ve<this._zones.length;ve++){var ye=this._zones[ve];if(ye.y1===ye.y2){if(oe===ye.y1&&ae>=ye.x1&&ae<ye.x2)return ye}else if(oe===ye.y1&&ae>=ye.x1||oe===ye.y2&&ae<ye.x2||oe>ye.y1&&oe<ye.y2)return ye}},z=ue([se(2,ne.IBufferService),se(3,ee.IMouseService),se(4,ee.ISelectionService),se(5,ne.IOptionsService)],z)}(te.Disposable);be.MouseZoneManager=E},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(z,x){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(re,ae){re.__proto__=ae}||function(re,ae){for(var oe in ae)ae.hasOwnProperty(oe)&&(re[oe]=ae[oe])})(z,x)},function(z,x){function re(){this.constructor=z}ie(z,x),z.prototype=x===null?Object.create(x):(re.prototype=x.prototype,new re)});Object.defineProperty(be,"__esModule",{value:!0}),be.AccessibilityManager=void 0;var ue=ce(18),se=ce(11),te=ce(31),le=ce(7),ee=ce(2),ne=ce(32),E=ce(17),b=function(z){function x(re,ae){var oe=z.call(this)||this;oe._terminal=re,oe._renderService=ae,oe._liveRegionLineCount=0,oe._charsToConsume=[],oe._charsToAnnounce="",oe._accessibilityTreeRoot=document.createElement("div"),oe._accessibilityTreeRoot.classList.add("xterm-accessibility"),oe._rowContainer=document.createElement("div"),oe._rowContainer.classList.add("xterm-accessibility-tree"),oe._rowContainer.setAttribute("role","list"),oe._rowElements=[];for(var ve=0;ve<oe._terminal.rows;ve++)oe._rowElements[ve]=oe._createAccessibilityTreeNode(),oe._rowContainer.appendChild(oe._rowElements[ve]);if(oe._topBoundaryFocusListener=function(ye){return oe._onBoundaryFocus(ye,0)},oe._bottomBoundaryFocusListener=function(ye){return oe._onBoundaryFocus(ye,1)},oe._rowElements[0].addEventListener("focus",oe._topBoundaryFocusListener),oe._rowElements[oe._rowElements.length-1].addEventListener("focus",oe._bottomBoundaryFocusListener),oe._refreshRowsDimensions(),oe._accessibilityTreeRoot.appendChild(oe._rowContainer),oe._renderRowsDebouncer=new te.RenderDebouncer(oe._renderRows.bind(oe)),oe._refreshRows(),oe._liveRegion=document.createElement("div"),oe._liveRegion.classList.add("live-region"),oe._liveRegion.setAttribute("aria-live","assertive"),oe._accessibilityTreeRoot.appendChild(oe._liveRegion),!oe._terminal.element)throw new Error("Cannot enable accessibility before Terminal.open");return oe._terminal.element.insertAdjacentElement("afterbegin",oe._accessibilityTreeRoot),oe.register(oe._renderRowsDebouncer),oe.register(oe._terminal.onResize(function(ye){return oe._onResize(ye.rows)})),oe.register(oe._terminal.onRender(function(ye){return oe._refreshRows(ye.start,ye.end)})),oe.register(oe._terminal.onScroll(function(){return oe._refreshRows()})),oe.register(oe._terminal.onA11yChar(function(ye){return oe._onChar(ye)})),oe.register(oe._terminal.onLineFeed(function(){return oe._onChar(`
|
|
|
`)})),oe.register(oe._terminal.onA11yTab(function(ye){return oe._onTab(ye)})),oe.register(oe._terminal.onKey(function(ye){return oe._onKey(ye.key)})),oe.register(oe._terminal.onBlur(function(){return oe._clearLiveRegion()})),oe.register(oe._renderService.onDimensionsChange(function(){return oe._refreshRowsDimensions()})),oe._screenDprMonitor=new ne.ScreenDprMonitor,oe.register(oe._screenDprMonitor),oe._screenDprMonitor.setListener(function(){return oe._refreshRowsDimensions()}),oe.register(le.addDisposableDomListener(window,"resize",function(){return oe._refreshRowsDimensions()})),oe}return Ce(x,z),x.prototype.dispose=function(){z.prototype.dispose.call(this),E.removeElementFromParent(this._accessibilityTreeRoot),this._rowElements.length=0},x.prototype._onBoundaryFocus=function(re,ae){var oe=re.target,ve=this._rowElements[ae===0?1:this._rowElements.length-2];if(oe.getAttribute("aria-posinset")!==(ae===0?"1":""+this._terminal.buffer.lines.length)&&re.relatedTarget===ve){var ye,me;if(ae===0?(ye=oe,me=this._rowElements.pop(),this._rowContainer.removeChild(me)):(ye=this._rowElements.shift(),me=oe,this._rowContainer.removeChild(ye)),ye.removeEventListener("focus",this._topBoundaryFocusListener),me.removeEventListener("focus",this._bottomBoundaryFocusListener),ae===0){var ge=this._createAccessibilityTreeNode();this._rowElements.unshift(ge),this._rowContainer.insertAdjacentElement("afterbegin",ge)}else ge=this._createAccessibilityTreeNode(),this._rowElements.push(ge),this._rowContainer.appendChild(ge);this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._terminal.scrollLines(ae===0?-1:1),this._rowElements[ae===0?1:this._rowElements.length-2].focus(),re.preventDefault(),re.stopImmediatePropagation()}},x.prototype._onResize=function(re){this._rowElements[this._rowElements.length-1].removeEventListener("focus",this._bottomBoundaryFocusListener);for(var ae=this._rowContainer.children.length;ae<this._terminal.rows;ae++)this._rowElements[ae]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[ae]);for(;this._rowElements.length>re;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()},x.prototype._createAccessibilityTreeNode=function(){var re=document.createElement("div");return re.setAttribute("role","listitem"),re.tabIndex=-1,this._refreshRowDimensions(re),re},x.prototype._onTab=function(re){for(var ae=0;ae<re;ae++)this._onChar(" ")},x.prototype._onChar=function(re){var ae=this;this._liveRegionLineCount<21&&(this._charsToConsume.length>0?this._charsToConsume.shift()!==re&&(this._charsToAnnounce+=re):this._charsToAnnounce+=re,re===`
|
|
|
`&&(this._liveRegionLineCount++,this._liveRegionLineCount===21&&(this._liveRegion.textContent+=ue.tooMuchOutput)),se.isMac&&this._liveRegion.textContent&&this._liveRegion.textContent.length>0&&!this._liveRegion.parentNode&&setTimeout(function(){ae._accessibilityTreeRoot.appendChild(ae._liveRegion)},0))},x.prototype._clearLiveRegion=function(){this._liveRegion.textContent="",this._liveRegionLineCount=0,se.isMac&&E.removeElementFromParent(this._liveRegion)},x.prototype._onKey=function(re){this._clearLiveRegion(),this._charsToConsume.push(re)},x.prototype._refreshRows=function(re,ae){this._renderRowsDebouncer.refresh(re,ae,this._terminal.rows)},x.prototype._renderRows=function(re,ae){for(var oe=this._terminal.buffer,ve=oe.lines.length.toString(),ye=re;ye<=ae;ye++){var me=oe.translateBufferLineToString(oe.ydisp+ye,!0),ge=(oe.ydisp+ye+1).toString(),_e=this._rowElements[ye];_e&&(me.length===0?_e.innerHTML=" ":_e.textContent=me,_e.setAttribute("aria-posinset",ge),_e.setAttribute("aria-setsize",ve))}this._announceCharacters()},x.prototype._refreshRowsDimensions=function(){if(this._renderService.dimensions.actualCellHeight){this._rowElements.length!==this._terminal.rows&&this._onResize(this._terminal.rows);for(var re=0;re<this._terminal.rows;re++)this._refreshRowDimensions(this._rowElements[re])}},x.prototype._refreshRowDimensions=function(re){re.style.height=this._renderService.dimensions.actualCellHeight+"px"},x.prototype._announceCharacters=function(){this._charsToAnnounce.length!==0&&(this._liveRegion.textContent+=this._charsToAnnounce,this._charsToAnnounce="")},x}(ee.Disposable);be.AccessibilityManager=b},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(oe,ve){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ye,me){ye.__proto__=me}||function(ye,me){for(var ge in me)me.hasOwnProperty(ge)&&(ye[ge]=me[ge])})(oe,ve)},function(oe,ve){function ye(){this.constructor=oe}ie(oe,ve),oe.prototype=ve===null?Object.create(ve):(ye.prototype=ve.prototype,new ye)}),ue=this&&this.__decorate||function(oe,ve,ye,me){var ge,_e=arguments.length,he=_e<3?ve:me===null?me=Object.getOwnPropertyDescriptor(ve,ye):me;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")he=Reflect.decorate(oe,ve,ye,me);else for(var pe=oe.length-1;pe>=0;pe--)(ge=oe[pe])&&(he=(_e<3?ge(he):_e>3?ge(ve,ye,he):ge(ve,ye))||he);return _e>3&&he&&Object.defineProperty(ve,ye,he),he},se=this&&this.__param||function(oe,ve){return function(ye,me){ve(ye,me,oe)}};Object.defineProperty(be,"__esModule",{value:!0}),be.DomRenderer=void 0;var te=ce(58),le=ce(9),ee=ce(2),ne=ce(5),E=ce(1),b=ce(0),z=ce(10),x=ce(17),re=1,ae=function(oe){function ve(ye,me,ge,_e,he,pe,ke,Te,Ee){var Oe=oe.call(this)||this;return Oe._colors=ye,Oe._element=me,Oe._screenElement=ge,Oe._viewportElement=_e,Oe._linkifier=he,Oe._linkifier2=pe,Oe._charSizeService=ke,Oe._optionsService=Te,Oe._bufferService=Ee,Oe._terminalClass=re++,Oe._rowElements=[],Oe._rowContainer=document.createElement("div"),Oe._rowContainer.classList.add("xterm-rows"),Oe._rowContainer.style.lineHeight="normal",Oe._rowContainer.setAttribute("aria-hidden","true"),Oe._refreshRowElements(Oe._bufferService.cols,Oe._bufferService.rows),Oe._selectionContainer=document.createElement("div"),Oe._selectionContainer.classList.add("xterm-selection"),Oe._selectionContainer.setAttribute("aria-hidden","true"),Oe.dimensions={scaledCharWidth:0,scaledCharHeight:0,scaledCellWidth:0,scaledCellHeight:0,scaledCharLeft:0,scaledCharTop:0,scaledCanvasWidth:0,scaledCanvasHeight:0,canvasWidth:0,canvasHeight:0,actualCellWidth:0,actualCellHeight:0},Oe._updateDimensions(),Oe._injectCss(),Oe._rowFactory=new te.DomRendererRowFactory(document,Oe._optionsService,Oe._colors),Oe._element.classList.add("xterm-dom-renderer-owner-"+Oe._terminalClass),Oe._screenElement.appendChild(Oe._rowContainer),Oe._screenElement.appendChild(Oe._selectionContainer),Oe._linkifier.onShowLinkUnderline(function(je){return Oe._onLinkHover(je)}),Oe._linkifier.onHideLinkUnderline(function(je){return Oe._onLinkLeave(je)}),Oe._linkifier2.onShowLinkUnderline(function(je){return Oe._onLinkHover(je)}),Oe._linkifier2.onHideLinkUnderline(function(je){return Oe._onLinkLeave(je)}),Oe}return Ce(ve,oe),Object.defineProperty(ve.prototype,"onRequestRedraw",{get:function(){return new b.EventEmitter().event},enumerable:!1,configurable:!0}),ve.prototype.dispose=function(){this._element.classList.remove("xterm-dom-renderer-owner-"+this._terminalClass),x.removeElementFromParent(this._rowContainer,this._selectionContainer,this._themeStyleElement,this._dimensionsStyleElement),oe.prototype.dispose.call(this)},ve.prototype._updateDimensions=function(){this.dimensions.scaledCharWidth=this._charSizeService.width*window.devicePixelRatio,this.dimensions.scaledCharHeight=Math.ceil(this._charSizeService.height*window.devicePixelRatio),this.dimensions.scaledCellWidth=this.dimensions.scaledCharWidth+Math.round(this._optionsService.options.letterSpacing),this.dimensions.scaledCellHeight=Math.floor(this.dimensions.scaledCharHeight*this._optionsService.options.lineHeight),this.dimensions.scaledCharLeft=0,this.dimensions.scaledCharTop=0,this.dimensions.scaledCanvasWidth=this.dimensions.scaledCellWidth*this._bufferService.cols,this.dimensions.scaledCanvasHeight=this.dimensions.scaledCellHeight*this._bufferService.rows,this.dimensions.canvasWidth=Math.round(this.dimensions.scaledCanvasWidth/window.devicePixelRatio),this.dimensions.canvasHeight=Math.round(this.dimensions.scaledCanvasHeight/window.devicePixelRatio),this.dimensions.actualCellWidth=this.dimensions.canvasWidth/this._bufferService.cols,this.dimensions.actualCellHeight=this.dimensions.canvasHeight/this._bufferService.rows;for(var ye=0,me=this._rowElements;ye<me.length;ye++){var ge=me[ye];ge.style.width=this.dimensions.canvasWidth+"px",ge.style.height=this.dimensions.actualCellHeight+"px",ge.style.lineHeight=this.dimensions.actualCellHeight+"px",ge.style.overflow="hidden"}this._dimensionsStyleElement||(this._dimensionsStyleElement=document.createElement("style"),this._screenElement.appendChild(this._dimensionsStyleElement));var _e=this._terminalSelector+" .xterm-rows span { display: inline-block; height: 100%; vertical-align: top; width: "+this.dimensions.actualCellWidth+"px}";this._dimensionsStyleElement.innerHTML=_e,this._selectionContainer.style.height=this._viewportElement.style.height,this._screenElement.style.width=this.dimensions.canvasWidth+"px",this._screenElement.style.height=this.dimensions.canvasHeight+"px"},ve.prototype.setColors=function(ye){this._colors=ye,this._injectCss()},ve.prototype._injectCss=function(){var ye=this;this._themeStyleElement||(this._themeStyleElement=document.createElement("style"),this._screenElement.appendChild(this._themeStyleElement));var me=this._terminalSelector+" .xterm-rows { color: "+this._colors.foreground.css+"; font-family: "+this._optionsService.options.fontFamily+"; font-size: "+this._optionsService.options.fontSize+"px;}";me+=this._terminalSelector+" span:not(."+te.BOLD_CLASS+") { font-weight: "+this._optionsService.options.fontWeight+";}"+this._terminalSelector+" span."+te.BOLD_CLASS+" { font-weight: "+this._optionsService.options.fontWeightBold+";}"+this._terminalSelector+" span."+te.ITALIC_CLASS+" { font-style: italic;}",me+="@keyframes blink_box_shadow_"+this._terminalClass+" { 50% { box-shadow: none; }}",me+="@keyframes blink_block_"+this._terminalClass+" { 0% { background-color: "+this._colors.cursor.css+"; color: "+this._colors.cursorAccent.css+"; } 50% { background-color: "+this._colors.cursorAccent.css+"; color: "+this._colors.cursor.css+"; }}",me+=this._terminalSelector+" .xterm-rows:not(.xterm-focus) ."+te.CURSOR_CLASS+"."+te.CURSOR_STYLE_BLOCK_CLASS+" { outline: 1px solid "+this._colors.cursor.css+"; outline-offset: -1px;}"+this._terminalSelector+" .xterm-rows.xterm-focus ."+te.CURSOR_CLASS+"."+te.CURSOR_BLINK_CLASS+":not(."+te.CURSOR_STYLE_BLOCK_CLASS+") { animation: blink_box_shadow_"+this._terminalClass+" 1s step-end infinite;}"+this._terminalSelector+" .xterm-rows.xterm-focus ."+te.CURSOR_CLASS+"."+te.CURSOR_BLINK_CLASS+"."+te.CURSOR_STYLE_BLOCK_CLASS+" { animation: blink_block_"+this._terminalClass+" 1s step-end infinite;}"+this._terminalSelector+" .xterm-rows.xterm-focus ."+te.CURSOR_CLASS+"."+te.CURSOR_STYLE_BLOCK_CLASS+" { background-color: "+this._colors.cursor.css+"; color: "+this._colors.cursorAccent.css+";}"+this._terminalSelector+" .xterm-rows ."+te.CURSOR_CLASS+"."+te.CURSOR_STYLE_BAR_CLASS+" { box-shadow: "+this._optionsService.options.cursorWidth+"px 0 0 "+this._colors.cursor.css+" inset;}"+this._terminalSelector+" .xterm-rows ."+te.CURSOR_CLASS+"."+te.CURSOR_STYLE_UNDERLINE_CLASS+" { box-shadow: 0 -1px 0 "+this._colors.cursor.css+" inset;}",me+=this._terminalSelector+" .xterm-selection { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}"+this._terminalSelector+" .xterm-selection div { position: absolute; background-color: "+this._colors.selectionTransparent.css+";}",this._colors.ansi.forEach(function(ge,_e){me+=ye._terminalSelector+" .xterm-fg-"+_e+" { color: "+ge.css+"; }"+ye._terminalSelector+" .xterm-bg-"+_e+" { background-color: "+ge.css+"; }"}),me+=this._terminalSelector+" .xterm-fg-"+le.INVERTED_DEFAULT_COLOR+" { color: "+z.color.opaque(this._colors.background).css+"; }"+this._terminalSelector+" .xterm-bg-"+le.INVERTED_DEFAULT_COLOR+" { background-color: "+this._colors.foreground.css+"; }",this._themeStyleElement.innerHTML=me},ve.prototype.onDevicePixelRatioChange=function(){this._updateDimensions()},ve.prototype._refreshRowElements=function(ye,me){for(var ge=this._rowElements.length;ge<=me;ge++){var _e=document.createElement("div");this._rowContainer.appendChild(_e),this._rowElements.push(_e)}for(;this._rowElements.length>me;)this._rowContainer.removeChild(this._rowElements.pop())},ve.prototype.onResize=function(ye,me){this._refreshRowElements(ye,me),this._updateDimensions()},ve.prototype.onCharSizeChanged=function(){this._updateDimensions()},ve.prototype.onBlur=function(){this._rowContainer.classList.remove("xterm-focus")},ve.prototype.onFocus=function(){this._rowContainer.classList.add("xterm-focus")},ve.prototype.onSelectionChanged=function(ye,me,ge){for(;this._selectionContainer.children.length;)this._selectionContainer.removeChild(this._selectionContainer.children[0]);if(ye&&me){var _e=ye[1]-this._bufferService.buffer.ydisp,he=me[1]-this._bufferService.buffer.ydisp,pe=Math.max(_e,0),ke=Math.min(he,this._bufferService.rows-1);if(!(pe>=this._bufferService.rows||ke<0)){var Te=document.createDocumentFragment();if(ge)Te.appendChild(this._createSelectionElement(pe,ye[0],me[0],ke-pe+1));else{var Ee=_e===pe?ye[0]:0,Oe=pe===ke?me[0]:this._bufferService.cols;Te.appendChild(this._createSelectionElement(pe,Ee,Oe));var je=ke-pe-1;if(Te.appendChild(this._createSelectionElement(pe+1,0,this._bufferService.cols,je)),pe!==ke){var Pe=he===ke?me[0]:this._bufferService.cols;Te.appendChild(this._createSelectionElement(ke,0,Pe))}}this._selectionContainer.appendChild(Te)}}},ve.prototype._createSelectionElement=function(ye,me,ge,_e){_e===void 0&&(_e=1);var he=document.createElement("div");return he.style.height=_e*this.dimensions.actualCellHeight+"px",he.style.top=ye*this.dimensions.actualCellHeight+"px",he.style.left=me*this.dimensions.actualCellWidth+"px",he.style.width=this.dimensions.actualCellWidth*(ge-me)+"px",he},ve.prototype.onCursorMove=function(){},ve.prototype.onOptionsChanged=function(){this._updateDimensions(),this._injectCss()},ve.prototype.clear=function(){for(var ye=0,me=this._rowElements;ye<me.length;ye++)me[ye].innerHTML=""},ve.prototype.renderRows=function(ye,me){for(var ge=this._bufferService.buffer.ybase+this._bufferService.buffer.y,_e=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1),he=this._optionsService.options.cursorBlink,pe=ye;pe<=me;pe++){var ke=this._rowElements[pe];ke.innerHTML="";var Te=pe+this._bufferService.buffer.ydisp,Ee=this._bufferService.buffer.lines.get(Te),Oe=this._optionsService.options.cursorStyle;ke.appendChild(this._rowFactory.createRow(Ee,Te===ge,Oe,_e,he,this.dimensions.actualCellWidth,this._bufferService.cols))}},Object.defineProperty(ve.prototype,"_terminalSelector",{get:function(){return".xterm-dom-renderer-owner-"+this._terminalClass},enumerable:!1,configurable:!0}),ve.prototype.registerCharacterJoiner=function(ye){return-1},ve.prototype.deregisterCharacterJoiner=function(ye){return!1},ve.prototype._onLinkHover=function(ye){this._setCellUnderline(ye.x1,ye.x2,ye.y1,ye.y2,ye.cols,!0)},ve.prototype._onLinkLeave=function(ye){this._setCellUnderline(ye.x1,ye.x2,ye.y1,ye.y2,ye.cols,!1)},ve.prototype._setCellUnderline=function(ye,me,ge,_e,he,pe){for(;ye!==me||ge!==_e;){var ke=this._rowElements[ge];if(!ke)return;var Te=ke.children[ye];Te&&(Te.style.textDecoration=pe?"underline":"none"),++ye>=he&&(ye=0,ge++)}},ve=ue([se(6,ne.ICharSizeService),se(7,E.IOptionsService),se(8,E.IBufferService)],ve)}(ee.Disposable);be.DomRenderer=ae},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.DomRendererRowFactory=be.CURSOR_STYLE_UNDERLINE_CLASS=be.CURSOR_STYLE_BAR_CLASS=be.CURSOR_STYLE_BLOCK_CLASS=be.CURSOR_BLINK_CLASS=be.CURSOR_CLASS=be.UNDERLINE_CLASS=be.ITALIC_CLASS=be.DIM_CLASS=be.BOLD_CLASS=void 0;var ie=ce(9),Ce=ce(3),ue=ce(4),se=ce(10);be.BOLD_CLASS="xterm-bold",be.DIM_CLASS="xterm-dim",be.ITALIC_CLASS="xterm-italic",be.UNDERLINE_CLASS="xterm-underline",be.CURSOR_CLASS="xterm-cursor",be.CURSOR_BLINK_CLASS="xterm-cursor-blink",be.CURSOR_STYLE_BLOCK_CLASS="xterm-cursor-block",be.CURSOR_STYLE_BAR_CLASS="xterm-cursor-bar",be.CURSOR_STYLE_UNDERLINE_CLASS="xterm-cursor-underline";var te=function(){function ee(ne,E,b){this._document=ne,this._optionsService=E,this._colors=b,this._workCell=new ue.CellData}return ee.prototype.setColors=function(ne){this._colors=ne},ee.prototype.createRow=function(ne,E,b,z,x,re,ae){for(var oe=this._document.createDocumentFragment(),ve=0,ye=Math.min(ne.length,ae)-1;ye>=0;ye--)if(ne.loadCell(ye,this._workCell).getCode()!==Ce.NULL_CELL_CODE||E&&ye===z){ve=ye+1;break}for(ye=0;ye<ve;ye++){ne.loadCell(ye,this._workCell);var me=this._workCell.getWidth();if(me!==0){var ge=this._document.createElement("span");if(me>1&&(ge.style.width=re*me+"px"),E&&ye===z)switch(ge.classList.add(be.CURSOR_CLASS),x&&ge.classList.add(be.CURSOR_BLINK_CLASS),b){case"bar":ge.classList.add(be.CURSOR_STYLE_BAR_CLASS);break;case"underline":ge.classList.add(be.CURSOR_STYLE_UNDERLINE_CLASS);break;default:ge.classList.add(be.CURSOR_STYLE_BLOCK_CLASS)}this._workCell.isBold()&&ge.classList.add(be.BOLD_CLASS),this._workCell.isItalic()&&ge.classList.add(be.ITALIC_CLASS),this._workCell.isDim()&&ge.classList.add(be.DIM_CLASS),this._workCell.isUnderline()&&ge.classList.add(be.UNDERLINE_CLASS),this._workCell.isInvisible()?ge.textContent=Ce.WHITESPACE_CELL_CHAR:ge.textContent=this._workCell.getChars()||Ce.WHITESPACE_CELL_CHAR;var _e=this._workCell.getFgColor(),he=this._workCell.getFgColorMode(),pe=this._workCell.getBgColor(),ke=this._workCell.getBgColorMode(),Te=!!this._workCell.isInverse();if(Te){var Ee=_e;_e=pe,pe=Ee;var Oe=he;he=ke,ke=Oe}switch(he){case 16777216:case 33554432:this._workCell.isBold()&&_e<8&&this._optionsService.options.drawBoldTextInBrightColors&&(_e+=8),this._applyMinimumContrast(ge,this._colors.background,this._colors.ansi[_e])||ge.classList.add("xterm-fg-"+_e);break;case 50331648:var je=se.rgba.toColor(_e>>16&255,_e>>8&255,255&_e);this._applyMinimumContrast(ge,this._colors.background,je)||this._addStyle(ge,"color:#"+le(_e.toString(16),"0",6));break;case 0:default:this._applyMinimumContrast(ge,this._colors.background,this._colors.foreground)||Te&&ge.classList.add("xterm-fg-"+ie.INVERTED_DEFAULT_COLOR)}switch(ke){case 16777216:case 33554432:ge.classList.add("xterm-bg-"+pe);break;case 50331648:this._addStyle(ge,"background-color:#"+le(pe.toString(16),"0",6));break;case 0:default:Te&&ge.classList.add("xterm-bg-"+ie.INVERTED_DEFAULT_COLOR)}oe.appendChild(ge)}}return oe},ee.prototype._applyMinimumContrast=function(ne,E,b){if(this._optionsService.options.minimumContrastRatio===1)return!1;var z=this._colors.contrastCache.getColor(this._workCell.bg,this._workCell.fg);return z===void 0&&(z=se.color.ensureContrastRatio(E,b,this._optionsService.options.minimumContrastRatio),this._colors.contrastCache.setColor(this._workCell.bg,this._workCell.fg,z!=null?z:null)),!!z&&(this._addStyle(ne,"color:"+z.css),!0)},ee.prototype._addStyle=function(ne,E){ne.setAttribute("style",""+(ne.getAttribute("style")||"")+E+";")},ee}();function le(ee,ne,E){for(;ee.length<E;)ee=ne+ee;return ee}be.DomRendererRowFactory=te},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.evaluateKeyboardEvent=void 0;var ie=ce(12),Ce={48:["0",")"],49:["1","!"],50:["2","@"],51:["3","#"],52:["4","$"],53:["5","%"],54:["6","^"],55:["7","&"],56:["8","*"],57:["9","("],186:[";",":"],187:["=","+"],188:[",","<"],189:["-","_"],190:[".",">"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};be.evaluateKeyboardEvent=function(ue,se,te,le){var ee={type:0,cancel:!1,key:void 0},ne=(ue.shiftKey?1:0)|(ue.altKey?2:0)|(ue.ctrlKey?4:0)|(ue.metaKey?8:0);switch(ue.keyCode){case 0:ue.key==="UIKeyInputUpArrow"?ee.key=se?ie.C0.ESC+"OA":ie.C0.ESC+"[A":ue.key==="UIKeyInputLeftArrow"?ee.key=se?ie.C0.ESC+"OD":ie.C0.ESC+"[D":ue.key==="UIKeyInputRightArrow"?ee.key=se?ie.C0.ESC+"OC":ie.C0.ESC+"[C":ue.key==="UIKeyInputDownArrow"&&(ee.key=se?ie.C0.ESC+"OB":ie.C0.ESC+"[B");break;case 8:if(ue.shiftKey){ee.key=ie.C0.BS;break}if(ue.altKey){ee.key=ie.C0.ESC+ie.C0.DEL;break}ee.key=ie.C0.DEL;break;case 9:if(ue.shiftKey){ee.key=ie.C0.ESC+"[Z";break}ee.key=ie.C0.HT,ee.cancel=!0;break;case 13:ee.key=ue.altKey?ie.C0.ESC+ie.C0.CR:ie.C0.CR,ee.cancel=!0;break;case 27:ee.key=ie.C0.ESC,ue.altKey&&(ee.key=ie.C0.ESC+ie.C0.ESC),ee.cancel=!0;break;case 37:if(ue.metaKey)break;ne?(ee.key=ie.C0.ESC+"[1;"+(ne+1)+"D",ee.key===ie.C0.ESC+"[1;3D"&&(ee.key=ie.C0.ESC+(te?"b":"[1;5D"))):ee.key=se?ie.C0.ESC+"OD":ie.C0.ESC+"[D";break;case 39:if(ue.metaKey)break;ne?(ee.key=ie.C0.ESC+"[1;"+(ne+1)+"C",ee.key===ie.C0.ESC+"[1;3C"&&(ee.key=ie.C0.ESC+(te?"f":"[1;5C"))):ee.key=se?ie.C0.ESC+"OC":ie.C0.ESC+"[C";break;case 38:if(ue.metaKey)break;ne?(ee.key=ie.C0.ESC+"[1;"+(ne+1)+"A",te||ee.key!==ie.C0.ESC+"[1;3A"||(ee.key=ie.C0.ESC+"[1;5A")):ee.key=se?ie.C0.ESC+"OA":ie.C0.ESC+"[A";break;case 40:if(ue.metaKey)break;ne?(ee.key=ie.C0.ESC+"[1;"+(ne+1)+"B",te||ee.key!==ie.C0.ESC+"[1;3B"||(ee.key=ie.C0.ESC+"[1;5B")):ee.key=se?ie.C0.ESC+"OB":ie.C0.ESC+"[B";break;case 45:ue.shiftKey||ue.ctrlKey||(ee.key=ie.C0.ESC+"[2~");break;case 46:ee.key=ne?ie.C0.ESC+"[3;"+(ne+1)+"~":ie.C0.ESC+"[3~";break;case 36:ee.key=ne?ie.C0.ESC+"[1;"+(ne+1)+"H":se?ie.C0.ESC+"OH":ie.C0.ESC+"[H";break;case 35:ee.key=ne?ie.C0.ESC+"[1;"+(ne+1)+"F":se?ie.C0.ESC+"OF":ie.C0.ESC+"[F";break;case 33:ue.shiftKey?ee.type=2:ee.key=ie.C0.ESC+"[5~";break;case 34:ue.shiftKey?ee.type=3:ee.key=ie.C0.ESC+"[6~";break;case 112:ee.key=ne?ie.C0.ESC+"[1;"+(ne+1)+"P":ie.C0.ESC+"OP";break;case 113:ee.key=ne?ie.C0.ESC+"[1;"+(ne+1)+"Q":ie.C0.ESC+"OQ";break;case 114:ee.key=ne?ie.C0.ESC+"[1;"+(ne+1)+"R":ie.C0.ESC+"OR";break;case 115:ee.key=ne?ie.C0.ESC+"[1;"+(ne+1)+"S":ie.C0.ESC+"OS";break;case 116:ee.key=ne?ie.C0.ESC+"[15;"+(ne+1)+"~":ie.C0.ESC+"[15~";break;case 117:ee.key=ne?ie.C0.ESC+"[17;"+(ne+1)+"~":ie.C0.ESC+"[17~";break;case 118:ee.key=ne?ie.C0.ESC+"[18;"+(ne+1)+"~":ie.C0.ESC+"[18~";break;case 119:ee.key=ne?ie.C0.ESC+"[19;"+(ne+1)+"~":ie.C0.ESC+"[19~";break;case 120:ee.key=ne?ie.C0.ESC+"[20;"+(ne+1)+"~":ie.C0.ESC+"[20~";break;case 121:ee.key=ne?ie.C0.ESC+"[21;"+(ne+1)+"~":ie.C0.ESC+"[21~";break;case 122:ee.key=ne?ie.C0.ESC+"[23;"+(ne+1)+"~":ie.C0.ESC+"[23~";break;case 123:ee.key=ne?ie.C0.ESC+"[24;"+(ne+1)+"~":ie.C0.ESC+"[24~";break;default:if(!ue.ctrlKey||ue.shiftKey||ue.altKey||ue.metaKey)if(te&&!le||!ue.altKey||ue.metaKey)te&&!ue.altKey&&!ue.ctrlKey&&ue.metaKey?ue.keyCode===65&&(ee.type=1):ue.key&&!ue.ctrlKey&&!ue.altKey&&!ue.metaKey&&ue.keyCode>=48&&ue.key.length===1?ee.key=ue.key:ue.key&&ue.ctrlKey&&ue.key==="_"&&(ee.key=ie.C0.US);else{var E=Ce[ue.keyCode],b=E&&E[ue.shiftKey?1:0];if(b)ee.key=ie.C0.ESC+b;else if(ue.keyCode>=65&&ue.keyCode<=90){var z=ue.ctrlKey?ue.keyCode-64:ue.keyCode+32;ee.key=ie.C0.ESC+String.fromCharCode(z)}}else ue.keyCode>=65&&ue.keyCode<=90?ee.key=String.fromCharCode(ue.keyCode-64):ue.keyCode===32?ee.key=ie.C0.NUL:ue.keyCode>=51&&ue.keyCode<=55?ee.key=String.fromCharCode(ue.keyCode-51+27):ue.keyCode===56?ee.key=ie.C0.DEL:ue.keyCode===219?ee.key=ie.C0.ESC:ue.keyCode===220?ee.key=ie.C0.FS:ue.keyCode===221&&(ee.key=ie.C0.GS)}return ee}},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(re,ae){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(oe,ve){oe.__proto__=ve}||function(oe,ve){for(var ye in ve)ve.hasOwnProperty(ye)&&(oe[ye]=ve[ye])})(re,ae)},function(re,ae){function oe(){this.constructor=re}ie(re,ae),re.prototype=ae===null?Object.create(ae):(oe.prototype=ae.prototype,new oe)}),ue=this&&this.__decorate||function(re,ae,oe,ve){var ye,me=arguments.length,ge=me<3?ae:ve===null?ve=Object.getOwnPropertyDescriptor(ae,oe):ve;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ge=Reflect.decorate(re,ae,oe,ve);else for(var _e=re.length-1;_e>=0;_e--)(ye=re[_e])&&(ge=(me<3?ye(ge):me>3?ye(ae,oe,ge):ye(ae,oe))||ge);return me>3&&ge&&Object.defineProperty(ae,oe,ge),ge},se=this&&this.__param||function(re,ae){return function(oe,ve){ae(oe,ve,re)}};Object.defineProperty(be,"__esModule",{value:!0}),be.RenderService=void 0;var te=ce(31),le=ce(0),ee=ce(2),ne=ce(32),E=ce(7),b=ce(1),z=ce(5),x=function(re){function ae(oe,ve,ye,me,ge,_e){var he=re.call(this)||this;if(he._renderer=oe,he._rowCount=ve,he._isPaused=!1,he._needsFullRefresh=!1,he._isNextRenderRedrawOnly=!0,he._needsSelectionRefresh=!1,he._canvasWidth=0,he._canvasHeight=0,he._selectionState={start:void 0,end:void 0,columnSelectMode:!1},he._onDimensionsChange=new le.EventEmitter,he._onRender=new le.EventEmitter,he._onRefreshRequest=new le.EventEmitter,he.register({dispose:function(){return he._renderer.dispose()}}),he._renderDebouncer=new te.RenderDebouncer(function(ke,Te){return he._renderRows(ke,Te)}),he.register(he._renderDebouncer),he._screenDprMonitor=new ne.ScreenDprMonitor,he._screenDprMonitor.setListener(function(){return he.onDevicePixelRatioChange()}),he.register(he._screenDprMonitor),he.register(_e.onResize(function(ke){return he._fullRefresh()})),he.register(me.onOptionChange(function(){return he._renderer.onOptionsChanged()})),he.register(ge.onCharSizeChange(function(){return he.onCharSizeChanged()})),he._renderer.onRequestRedraw(function(ke){return he.refreshRows(ke.start,ke.end,!0)}),he.register(E.addDisposableDomListener(window,"resize",function(){return he.onDevicePixelRatioChange()})),"IntersectionObserver"in window){var pe=new IntersectionObserver(function(ke){return he._onIntersectionChange(ke[ke.length-1])},{threshold:0});pe.observe(ye),he.register({dispose:function(){return pe.disconnect()}})}return he}return Ce(ae,re),Object.defineProperty(ae.prototype,"onDimensionsChange",{get:function(){return this._onDimensionsChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"onRenderedBufferChange",{get:function(){return this._onRender.event},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"onRefreshRequest",{get:function(){return this._onRefreshRequest.event},enumerable:!1,configurable:!0}),Object.defineProperty(ae.prototype,"dimensions",{get:function(){return this._renderer.dimensions},enumerable:!1,configurable:!0}),ae.prototype._onIntersectionChange=function(oe){this._isPaused=oe.intersectionRatio===0,!this._isPaused&&this._needsFullRefresh&&(this.refreshRows(0,this._rowCount-1),this._needsFullRefresh=!1)},ae.prototype.refreshRows=function(oe,ve,ye){ye===void 0&&(ye=!1),this._isPaused?this._needsFullRefresh=!0:(ye||(this._isNextRenderRedrawOnly=!1),this._renderDebouncer.refresh(oe,ve,this._rowCount))},ae.prototype._renderRows=function(oe,ve){this._renderer.renderRows(oe,ve),this._needsSelectionRefresh&&(this._renderer.onSelectionChanged(this._selectionState.start,this._selectionState.end,this._selectionState.columnSelectMode),this._needsSelectionRefresh=!1),this._isNextRenderRedrawOnly||this._onRender.fire({start:oe,end:ve}),this._isNextRenderRedrawOnly=!0},ae.prototype.resize=function(oe,ve){this._rowCount=ve,this._fireOnCanvasResize()},ae.prototype.changeOptions=function(){this._renderer.onOptionsChanged(),this.refreshRows(0,this._rowCount-1),this._fireOnCanvasResize()},ae.prototype._fireOnCanvasResize=function(){this._renderer.dimensions.canvasWidth===this._canvasWidth&&this._renderer.dimensions.canvasHeight===this._canvasHeight||this._onDimensionsChange.fire(this._renderer.dimensions)},ae.prototype.dispose=function(){re.prototype.dispose.call(this)},ae.prototype.setRenderer=function(oe){var ve=this;this._renderer.dispose(),this._renderer=oe,this._renderer.onRequestRedraw(function(ye){return ve.refreshRows(ye.start,ye.end,!0)}),this._needsSelectionRefresh=!0,this._fullRefresh()},ae.prototype._fullRefresh=function(){this._isPaused?this._needsFullRefresh=!0:this.refreshRows(0,this._rowCount-1)},ae.prototype.setColors=function(oe){this._renderer.setColors(oe),this._fullRefresh()},ae.prototype.onDevicePixelRatioChange=function(){this._renderer.onDevicePixelRatioChange(),this.refreshRows(0,this._rowCount-1)},ae.prototype.onResize=function(oe,ve){this._renderer.onResize(oe,ve),this._fullRefresh()},ae.prototype.onCharSizeChanged=function(){this._renderer.onCharSizeChanged()},ae.prototype.onBlur=function(){this._renderer.onBlur()},ae.prototype.onFocus=function(){this._renderer.onFocus()},ae.prototype.onSelectionChanged=function(oe,ve,ye){this._selectionState.start=oe,this._selectionState.end=ve,this._selectionState.columnSelectMode=ye,this._renderer.onSelectionChanged(oe,ve,ye)},ae.prototype.onCursorMove=function(){this._renderer.onCursorMove()},ae.prototype.clear=function(){this._renderer.clear()},ae.prototype.registerCharacterJoiner=function(oe){return this._renderer.registerCharacterJoiner(oe)},ae.prototype.deregisterCharacterJoiner=function(oe){return this._renderer.deregisterCharacterJoiner(oe)},ae=ue([se(3,b.IOptionsService),se(4,z.ICharSizeService),se(5,b.IBufferService)],ae)}(ee.Disposable);be.RenderService=x},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(ee,ne,E,b){var z,x=arguments.length,re=x<3?ne:b===null?b=Object.getOwnPropertyDescriptor(ne,E):b;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")re=Reflect.decorate(ee,ne,E,b);else for(var ae=ee.length-1;ae>=0;ae--)(z=ee[ae])&&(re=(x<3?z(re):x>3?z(ne,E,re):z(ne,E))||re);return x>3&&re&&Object.defineProperty(ne,E,re),re},Ce=this&&this.__param||function(ee,ne){return function(E,b){ne(E,b,ee)}};Object.defineProperty(be,"__esModule",{value:!0}),be.CharSizeService=void 0;var ue=ce(1),se=ce(0),te=function(){function ee(ne,E,b){this._optionsService=b,this.width=0,this.height=0,this._onCharSizeChange=new se.EventEmitter,this._measureStrategy=new le(ne,E,this._optionsService)}return Object.defineProperty(ee.prototype,"hasValidSize",{get:function(){return this.width>0&&this.height>0},enumerable:!1,configurable:!0}),Object.defineProperty(ee.prototype,"onCharSizeChange",{get:function(){return this._onCharSizeChange.event},enumerable:!1,configurable:!0}),ee.prototype.measure=function(){var ne=this._measureStrategy.measure();ne.width===this.width&&ne.height===this.height||(this.width=ne.width,this.height=ne.height,this._onCharSizeChange.fire())},ee=ie([Ce(2,ue.IOptionsService)],ee)}();be.CharSizeService=te;var le=function(){function ee(ne,E,b){this._document=ne,this._parentElement=E,this._optionsService=b,this._result={width:0,height:0},this._measureElement=this._document.createElement("span"),this._measureElement.classList.add("xterm-char-measure-element"),this._measureElement.textContent="W",this._measureElement.setAttribute("aria-hidden","true"),this._parentElement.appendChild(this._measureElement)}return ee.prototype.measure=function(){this._measureElement.style.fontFamily=this._optionsService.options.fontFamily,this._measureElement.style.fontSize=this._optionsService.options.fontSize+"px";var ne=this._measureElement.getBoundingClientRect();return ne.width!==0&&ne.height!==0&&(this._result.width=ne.width,this._result.height=Math.ceil(ne.height)),this._result},ee}()},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(le,ee,ne,E){var b,z=arguments.length,x=z<3?ee:E===null?E=Object.getOwnPropertyDescriptor(ee,ne):E;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")x=Reflect.decorate(le,ee,ne,E);else for(var re=le.length-1;re>=0;re--)(b=le[re])&&(x=(z<3?b(x):z>3?b(ee,ne,x):b(ee,ne))||x);return z>3&&x&&Object.defineProperty(ee,ne,x),x},Ce=this&&this.__param||function(le,ee){return function(ne,E){ee(ne,E,le)}};Object.defineProperty(be,"__esModule",{value:!0}),be.MouseService=void 0;var ue=ce(5),se=ce(30),te=function(){function le(ee,ne){this._renderService=ee,this._charSizeService=ne}return le.prototype.getCoords=function(ee,ne,E,b,z){return se.getCoords(ee,ne,E,b,this._charSizeService.hasValidSize,this._renderService.dimensions.actualCellWidth,this._renderService.dimensions.actualCellHeight,z)},le.prototype.getRawByteCoords=function(ee,ne,E,b){var z=this.getCoords(ee,ne,E,b);return se.getRawByteCoords(z)},le=ie([Ce(0,ue.IRenderService),Ce(1,ue.ICharSizeService)],le)}();be.MouseService=te},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(b,z){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,re){x.__proto__=re}||function(x,re){for(var ae in re)re.hasOwnProperty(ae)&&(x[ae]=re[ae])})(b,z)},function(b,z){function x(){this.constructor=b}ie(b,z),b.prototype=z===null?Object.create(z):(x.prototype=z.prototype,new x)}),ue=this&&this.__decorate||function(b,z,x,re){var ae,oe=arguments.length,ve=oe<3?z:re===null?re=Object.getOwnPropertyDescriptor(z,x):re;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ve=Reflect.decorate(b,z,x,re);else for(var ye=b.length-1;ye>=0;ye--)(ae=b[ye])&&(ve=(oe<3?ae(ve):oe>3?ae(z,x,ve):ae(z,x))||ve);return oe>3&&ve&&Object.defineProperty(z,x,ve),ve},se=this&&this.__param||function(b,z){return function(x,re){z(x,re,b)}};Object.defineProperty(be,"__esModule",{value:!0}),be.Linkifier2=void 0;var te=ce(1),le=ce(0),ee=ce(2),ne=ce(7),E=function(b){function z(x){var re=b.call(this)||this;return re._bufferService=x,re._linkProviders=[],re._linkCacheDisposables=[],re._isMouseOut=!0,re._activeLine=-1,re._onShowLinkUnderline=re.register(new le.EventEmitter),re._onHideLinkUnderline=re.register(new le.EventEmitter),re.register(ee.getDisposeArrayDisposable(re._linkCacheDisposables)),re}return Ce(z,b),Object.defineProperty(z.prototype,"onShowLinkUnderline",{get:function(){return this._onShowLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(z.prototype,"onHideLinkUnderline",{get:function(){return this._onHideLinkUnderline.event},enumerable:!1,configurable:!0}),z.prototype.registerLinkProvider=function(x){var re=this;return this._linkProviders.push(x),{dispose:function(){var ae=re._linkProviders.indexOf(x);ae!==-1&&re._linkProviders.splice(ae,1)}}},z.prototype.attachToDom=function(x,re,ae){var oe=this;this._element=x,this._mouseService=re,this._renderService=ae,this.register(ne.addDisposableDomListener(this._element,"mouseleave",function(){oe._isMouseOut=!0,oe._clearCurrentLink()})),this.register(ne.addDisposableDomListener(this._element,"mousemove",this._onMouseMove.bind(this))),this.register(ne.addDisposableDomListener(this._element,"click",this._onClick.bind(this)))},z.prototype._onMouseMove=function(x){if(this._lastMouseEvent=x,this._element&&this._mouseService){var re=this._positionFromMouseEvent(x,this._element,this._mouseService);if(re){this._isMouseOut=!1;for(var ae=x.composedPath(),oe=0;oe<ae.length;oe++){var ve=ae[oe];if(ve.classList.contains("xterm"))break;if(ve.classList.contains("xterm-hover"))return}this._lastBufferCell&&re.x===this._lastBufferCell.x&&re.y===this._lastBufferCell.y||(this._onHover(re),this._lastBufferCell=re)}}},z.prototype._onHover=function(x){if(this._activeLine!==x.y)return this._clearCurrentLink(),void this._askForLink(x,!1);this._currentLink&&this._linkAtPosition(this._currentLink.link,x)||(this._clearCurrentLink(),this._askForLink(x,!0))},z.prototype._askForLink=function(x,re){var ae=this;this._activeProviderReplies&&re||(this._activeProviderReplies=new Map,this._activeLine=x.y);var oe=!1;this._linkProviders.forEach(function(ve,ye){var me;re?!((me=ae._activeProviderReplies)===null||me===void 0)&&me.get(ye)&&(oe=ae._checkLinkProviderResult(ye,x,oe)):ve.provideLinks(x.y,function(ge){var _e,he;if(!ae._isMouseOut){var pe=ge==null?void 0:ge.map(function(ke){return{link:ke}});(_e=ae._activeProviderReplies)===null||_e===void 0||_e.set(ye,pe),oe=ae._checkLinkProviderResult(ye,x,oe),((he=ae._activeProviderReplies)===null||he===void 0?void 0:he.size)===ae._linkProviders.length&&ae._removeIntersectingLinks(x.y,ae._activeProviderReplies)}})})},z.prototype._removeIntersectingLinks=function(x,re){for(var ae=new Set,oe=0;oe<re.size;oe++){var ve=re.get(oe);if(ve)for(var ye=0;ye<ve.length;ye++)for(var me=ve[ye],ge=me.link.range.start.y<x?0:me.link.range.start.x,_e=me.link.range.end.y>x?this._bufferService.cols:me.link.range.end.x,he=ge;he<=_e;he++){if(ae.has(he)){ve.splice(ye--,1);break}ae.add(he)}}},z.prototype._checkLinkProviderResult=function(x,re,ae){var oe,ve=this;if(!this._activeProviderReplies)return ae;for(var ye=this._activeProviderReplies.get(x),me=!1,ge=0;ge<x;ge++)this._activeProviderReplies.has(ge)&&!this._activeProviderReplies.get(ge)||(me=!0);if(!me&&ye){var _e=ye.find(function(pe){return ve._linkAtPosition(pe.link,re)});_e&&(ae=!0,this._handleNewLink(_e))}if(this._activeProviderReplies.size===this._linkProviders.length&&!ae)for(ge=0;ge<this._activeProviderReplies.size;ge++){var he=(oe=this._activeProviderReplies.get(ge))===null||oe===void 0?void 0:oe.find(function(pe){return ve._linkAtPosition(pe.link,re)});if(he){ae=!0,this._handleNewLink(he);break}}return ae},z.prototype._onClick=function(x){if(this._element&&this._mouseService&&this._currentLink){var re=this._positionFromMouseEvent(x,this._element,this._mouseService);re&&this._linkAtPosition(this._currentLink.link,re)&&this._currentLink.link.activate(x,this._currentLink.link.text)}},z.prototype._clearCurrentLink=function(x,re){this._element&&this._currentLink&&this._lastMouseEvent&&(!x||!re||this._currentLink.link.range.start.y>=x&&this._currentLink.link.range.end.y<=re)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,ee.disposeArray(this._linkCacheDisposables))},z.prototype._handleNewLink=function(x){var re=this;if(this._element&&this._lastMouseEvent&&this._mouseService){var ae=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);ae&&this._linkAtPosition(x.link,ae)&&(this._currentLink=x,this._currentLink.state={decorations:{underline:x.link.decorations===void 0||x.link.decorations.underline,pointerCursor:x.link.decorations===void 0||x.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,x.link,this._lastMouseEvent),x.link.decorations={},Object.defineProperties(x.link.decorations,{pointerCursor:{get:function(){var oe,ve;return(ve=(oe=re._currentLink)===null||oe===void 0?void 0:oe.state)===null||ve===void 0?void 0:ve.decorations.pointerCursor},set:function(oe){var ve,ye;!((ve=re._currentLink)===null||ve===void 0)&&ve.state&&re._currentLink.state.decorations.pointerCursor!==oe&&(re._currentLink.state.decorations.pointerCursor=oe,re._currentLink.state.isHovered&&((ye=re._element)===null||ye===void 0||ye.classList.toggle("xterm-cursor-pointer",oe)))}},underline:{get:function(){var oe,ve;return(ve=(oe=re._currentLink)===null||oe===void 0?void 0:oe.state)===null||ve===void 0?void 0:ve.decorations.underline},set:function(oe){var ve,ye,me;!((ve=re._currentLink)===null||ve===void 0)&&ve.state&&((me=(ye=re._currentLink)===null||ye===void 0?void 0:ye.state)===null||me===void 0?void 0:me.decorations.underline)!==oe&&(re._currentLink.state.decorations.underline=oe,re._currentLink.state.isHovered&&re._fireUnderlineEvent(x.link,oe))}}}),this._renderService&&this._linkCacheDisposables.push(this._renderService.onRenderedBufferChange(function(oe){var ve=oe.start===0?0:oe.start+1+re._bufferService.buffer.ydisp;re._clearCurrentLink(ve,oe.end+1+re._bufferService.buffer.ydisp)})))}},z.prototype._linkHover=function(x,re,ae){var oe;!((oe=this._currentLink)===null||oe===void 0)&&oe.state&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(re,!0),this._currentLink.state.decorations.pointerCursor&&x.classList.add("xterm-cursor-pointer")),re.hover&&re.hover(ae,re.text)},z.prototype._fireUnderlineEvent=function(x,re){var ae=x.range,oe=this._bufferService.buffer.ydisp,ve=this._createLinkUnderlineEvent(ae.start.x-1,ae.start.y-oe-1,ae.end.x,ae.end.y-oe-1,void 0);(re?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(ve)},z.prototype._linkLeave=function(x,re,ae){var oe;!((oe=this._currentLink)===null||oe===void 0)&&oe.state&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(re,!1),this._currentLink.state.decorations.pointerCursor&&x.classList.remove("xterm-cursor-pointer")),re.leave&&re.leave(ae,re.text)},z.prototype._linkAtPosition=function(x,re){var ae=x.range.start.y===x.range.end.y,oe=x.range.start.y<re.y,ve=x.range.end.y>re.y;return(ae&&x.range.start.x<=re.x&&x.range.end.x>=re.x||oe&&x.range.end.x>=re.x||ve&&x.range.start.x<=re.x||oe&&ve)&&x.range.start.y<=re.y&&x.range.end.y>=re.y},z.prototype._positionFromMouseEvent=function(x,re,ae){var oe=ae.getCoords(x,re,this._bufferService.cols,this._bufferService.rows);if(oe)return{x:oe[0],y:oe[1]+this._bufferService.buffer.ydisp}},z.prototype._createLinkUnderlineEvent=function(x,re,ae,oe,ve){return{x1:x,y1:re,x2:ae,y2:oe,cols:this._bufferService.cols,fg:ve}},z=ue([se(0,te.IBufferService)],z)}(ee.Disposable);be.Linkifier2=E},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.CoreBrowserService=void 0;var ie=function(){function Ce(ue){this._textarea=ue}return Object.defineProperty(Ce.prototype,"isFocused",{get:function(){return document.activeElement===this._textarea&&document.hasFocus()},enumerable:!1,configurable:!0}),Ce}();be.CoreBrowserService=ie},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(ge,_e){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(he,pe){he.__proto__=pe}||function(he,pe){for(var ke in pe)pe.hasOwnProperty(ke)&&(he[ke]=pe[ke])})(ge,_e)},function(ge,_e){function he(){this.constructor=ge}ie(ge,_e),ge.prototype=_e===null?Object.create(_e):(he.prototype=_e.prototype,new he)});Object.defineProperty(be,"__esModule",{value:!0}),be.CoreTerminal=void 0;var ue=ce(2),se=ce(1),te=ce(66),le=ce(67),ee=ce(68),ne=ce(74),E=ce(75),b=ce(0),z=ce(76),x=ce(77),re=ce(78),ae=ce(80),oe=ce(81),ve=ce(19),ye=ce(82),me=function(ge){function _e(he){var pe=ge.call(this)||this;return pe._onBinary=new b.EventEmitter,pe._onData=new b.EventEmitter,pe._onLineFeed=new b.EventEmitter,pe._onResize=new b.EventEmitter,pe._onScroll=new b.EventEmitter,pe._instantiationService=new te.InstantiationService,pe.optionsService=new ne.OptionsService(he),pe._instantiationService.setService(se.IOptionsService,pe.optionsService),pe._bufferService=pe.register(pe._instantiationService.createInstance(ee.BufferService)),pe._instantiationService.setService(se.IBufferService,pe._bufferService),pe._logService=pe._instantiationService.createInstance(le.LogService),pe._instantiationService.setService(se.ILogService,pe._logService),pe._coreService=pe.register(pe._instantiationService.createInstance(E.CoreService,function(){return pe.scrollToBottom()})),pe._instantiationService.setService(se.ICoreService,pe._coreService),pe._coreMouseService=pe._instantiationService.createInstance(z.CoreMouseService),pe._instantiationService.setService(se.ICoreMouseService,pe._coreMouseService),pe._dirtyRowService=pe._instantiationService.createInstance(x.DirtyRowService),pe._instantiationService.setService(se.IDirtyRowService,pe._dirtyRowService),pe.unicodeService=pe._instantiationService.createInstance(re.UnicodeService),pe._instantiationService.setService(se.IUnicodeService,pe.unicodeService),pe._charsetService=pe._instantiationService.createInstance(ae.CharsetService),pe._instantiationService.setService(se.ICharsetService,pe._charsetService),pe._inputHandler=new ve.InputHandler(pe._bufferService,pe._charsetService,pe._coreService,pe._dirtyRowService,pe._logService,pe.optionsService,pe._coreMouseService,pe.unicodeService),pe.register(b.forwardEvent(pe._inputHandler.onLineFeed,pe._onLineFeed)),pe.register(pe._inputHandler),pe.register(b.forwardEvent(pe._bufferService.onResize,pe._onResize)),pe.register(b.forwardEvent(pe._coreService.onData,pe._onData)),pe.register(b.forwardEvent(pe._coreService.onBinary,pe._onBinary)),pe.register(pe.optionsService.onOptionChange(function(ke){return pe._updateOptions(ke)})),pe._writeBuffer=new ye.WriteBuffer(function(ke){return pe._inputHandler.parse(ke)}),pe}return Ce(_e,ge),Object.defineProperty(_e.prototype,"onBinary",{get:function(){return this._onBinary.event},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"onData",{get:function(){return this._onData.event},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"onLineFeed",{get:function(){return this._onLineFeed.event},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"onResize",{get:function(){return this._onResize.event},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"onScroll",{get:function(){return this._onScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"cols",{get:function(){return this._bufferService.cols},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"rows",{get:function(){return this._bufferService.rows},enumerable:!1,configurable:!0}),Object.defineProperty(_e.prototype,"buffers",{get:function(){return this._bufferService.buffers},enumerable:!1,configurable:!0}),_e.prototype.dispose=function(){var he;this._isDisposed||(ge.prototype.dispose.call(this),(he=this._windowsMode)===null||he===void 0||he.dispose(),this._windowsMode=void 0)},_e.prototype.write=function(he,pe){this._writeBuffer.write(he,pe)},_e.prototype.writeSync=function(he){this._writeBuffer.writeSync(he)},_e.prototype.resize=function(he,pe){isNaN(he)||isNaN(pe)||(he=Math.max(he,ee.MINIMUM_COLS),pe=Math.max(pe,ee.MINIMUM_ROWS),this._bufferService.resize(he,pe))},_e.prototype.scroll=function(he,pe){pe===void 0&&(pe=!1);var ke,Te=this._bufferService.buffer;(ke=this._cachedBlankLine)&&ke.length===this.cols&&ke.getFg(0)===he.fg&&ke.getBg(0)===he.bg||(ke=Te.getBlankLine(he,pe),this._cachedBlankLine=ke),ke.isWrapped=pe;var Ee=Te.ybase+Te.scrollTop,Oe=Te.ybase+Te.scrollBottom;if(Te.scrollTop===0){var je=Te.lines.isFull;Oe===Te.lines.length-1?je?Te.lines.recycle().copyFrom(ke):Te.lines.push(ke.clone()):Te.lines.splice(Oe+1,0,ke.clone()),je?this._bufferService.isUserScrolling&&(Te.ydisp=Math.max(Te.ydisp-1,0)):(Te.ybase++,this._bufferService.isUserScrolling||Te.ydisp++)}else{var Pe=Oe-Ee+1;Te.lines.shiftElements(Ee+1,Pe-1,-1),Te.lines.set(Oe,ke.clone())}this._bufferService.isUserScrolling||(Te.ydisp=Te.ybase),this._dirtyRowService.markRangeDirty(Te.scrollTop,Te.scrollBottom),this._onScroll.fire(Te.ydisp)},_e.prototype.scrollLines=function(he,pe){var ke=this._bufferService.buffer;if(he<0){if(ke.ydisp===0)return;this._bufferService.isUserScrolling=!0}else he+ke.ydisp>=ke.ybase&&(this._bufferService.isUserScrolling=!1);var Te=ke.ydisp;ke.ydisp=Math.max(Math.min(ke.ydisp+he,ke.ybase),0),Te!==ke.ydisp&&(pe||this._onScroll.fire(ke.ydisp))},_e.prototype.scrollPages=function(he){this.scrollLines(he*(this.rows-1))},_e.prototype.scrollToTop=function(){this.scrollLines(-this._bufferService.buffer.ydisp)},_e.prototype.scrollToBottom=function(){this.scrollLines(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp)},_e.prototype.scrollToLine=function(he){var pe=he-this._bufferService.buffer.ydisp;pe!==0&&this.scrollLines(pe)},_e.prototype.addEscHandler=function(he,pe){return this._inputHandler.addEscHandler(he,pe)},_e.prototype.addDcsHandler=function(he,pe){return this._inputHandler.addDcsHandler(he,pe)},_e.prototype.addCsiHandler=function(he,pe){return this._inputHandler.addCsiHandler(he,pe)},_e.prototype.addOscHandler=function(he,pe){return this._inputHandler.addOscHandler(he,pe)},_e.prototype._setup=function(){this.optionsService.options.windowsMode&&this._enableWindowsMode()},_e.prototype.reset=function(){this._inputHandler.reset(),this._bufferService.reset(),this._charsetService.reset(),this._coreService.reset(),this._coreMouseService.reset()},_e.prototype._updateOptions=function(he){var pe;switch(he){case"scrollback":this.buffers.resize(this.cols,this.rows);break;case"windowsMode":this.optionsService.options.windowsMode?this._enableWindowsMode():((pe=this._windowsMode)===null||pe===void 0||pe.dispose(),this._windowsMode=void 0)}},_e.prototype._enableWindowsMode=function(){var he=this;if(!this._windowsMode){var pe=[];pe.push(this.onLineFeed(oe.updateWindowsModeWrappedState.bind(null,this._bufferService))),pe.push(this.addCsiHandler({final:"H"},function(){return oe.updateWindowsModeWrappedState(he._bufferService),!1})),this._windowsMode={dispose:function(){for(var ke=0,Te=pe;ke<Te.length;ke++)Te[ke].dispose()}}}},_e}(ue.Disposable);be.CoreTerminal=me},function(Mt,be,ce){"use strict";var ie=this&&this.__spreadArrays||function(){for(var le=0,ee=0,ne=arguments.length;ee<ne;ee++)le+=arguments[ee].length;var E=Array(le),b=0;for(ee=0;ee<ne;ee++)for(var z=arguments[ee],x=0,re=z.length;x<re;x++,b++)E[b]=z[x];return E};Object.defineProperty(be,"__esModule",{value:!0}),be.InstantiationService=be.ServiceCollection=void 0;var Ce=ce(1),ue=ce(14),se=function(){function le(){for(var ee=[],ne=0;ne<arguments.length;ne++)ee[ne]=arguments[ne];this._entries=new Map;for(var E=0,b=ee;E<b.length;E++){var z=b[E],x=z[0],re=z[1];this.set(x,re)}}return le.prototype.set=function(ee,ne){var E=this._entries.get(ee);return this._entries.set(ee,ne),E},le.prototype.forEach=function(ee){this._entries.forEach(function(ne,E){return ee(E,ne)})},le.prototype.has=function(ee){return this._entries.has(ee)},le.prototype.get=function(ee){return this._entries.get(ee)},le}();be.ServiceCollection=se;var te=function(){function le(){this._services=new se,this._services.set(Ce.IInstantiationService,this)}return le.prototype.setService=function(ee,ne){this._services.set(ee,ne)},le.prototype.getService=function(ee){return this._services.get(ee)},le.prototype.createInstance=function(ee){for(var ne=[],E=1;E<arguments.length;E++)ne[E-1]=arguments[E];for(var b=ue.getServiceDependencies(ee).sort(function(ye,me){return ye.index-me.index}),z=[],x=0,re=b;x<re.length;x++){var ae=re[x],oe=this._services.get(ae.id);if(!oe)throw new Error("[createInstance] "+ee.name+" depends on UNKNOWN service "+ae.id+".");z.push(oe)}var ve=b.length>0?b[0].index:ne.length;if(ne.length!==ve)throw new Error("[createInstance] First service dependency of "+ee.name+" at position "+(ve+1)+" conflicts with "+ne.length+" static arguments");return new(ee.bind.apply(ee,ie([void 0],ie(ne,z))))},le}();be.InstantiationService=te},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(ne,E,b,z){var x,re=arguments.length,ae=re<3?E:z===null?z=Object.getOwnPropertyDescriptor(E,b):z;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ae=Reflect.decorate(ne,E,b,z);else for(var oe=ne.length-1;oe>=0;oe--)(x=ne[oe])&&(ae=(re<3?x(ae):re>3?x(E,b,ae):x(E,b))||ae);return re>3&&ae&&Object.defineProperty(E,b,ae),ae},Ce=this&&this.__param||function(ne,E){return function(b,z){E(b,z,ne)}},ue=this&&this.__spreadArrays||function(){for(var ne=0,E=0,b=arguments.length;E<b;E++)ne+=arguments[E].length;var z=Array(ne),x=0;for(E=0;E<b;E++)for(var re=arguments[E],ae=0,oe=re.length;ae<oe;ae++,x++)z[x]=re[ae];return z};Object.defineProperty(be,"__esModule",{value:!0}),be.LogService=be.LogLevel=void 0;var se,te=ce(1);(function(ne){ne[ne.DEBUG=0]="DEBUG",ne[ne.INFO=1]="INFO",ne[ne.WARN=2]="WARN",ne[ne.ERROR=3]="ERROR",ne[ne.OFF=4]="OFF"})(se=be.LogLevel||(be.LogLevel={}));var le={debug:se.DEBUG,info:se.INFO,warn:se.WARN,error:se.ERROR,off:se.OFF},ee=function(){function ne(E){var b=this;this._optionsService=E,this._updateLogLevel(),this._optionsService.onOptionChange(function(z){z==="logLevel"&&b._updateLogLevel()})}return ne.prototype._updateLogLevel=function(){this._logLevel=le[this._optionsService.options.logLevel]},ne.prototype._evalLazyOptionalParams=function(E){for(var b=0;b<E.length;b++)typeof E[b]=="function"&&(E[b]=E[b]())},ne.prototype._log=function(E,b,z){this._evalLazyOptionalParams(z),E.call.apply(E,ue([console,"xterm.js: "+b],z))},ne.prototype.debug=function(E){for(var b=[],z=1;z<arguments.length;z++)b[z-1]=arguments[z];this._logLevel<=se.DEBUG&&this._log(console.log,E,b)},ne.prototype.info=function(E){for(var b=[],z=1;z<arguments.length;z++)b[z-1]=arguments[z];this._logLevel<=se.INFO&&this._log(console.info,E,b)},ne.prototype.warn=function(E){for(var b=[],z=1;z<arguments.length;z++)b[z-1]=arguments[z];this._logLevel<=se.WARN&&this._log(console.warn,E,b)},ne.prototype.error=function(E){for(var b=[],z=1;z<arguments.length;z++)b[z-1]=arguments[z];this._logLevel<=se.ERROR&&this._log(console.error,E,b)},ne=ie([Ce(0,te.IOptionsService)],ne)}();be.LogService=ee},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(b,z){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,re){x.__proto__=re}||function(x,re){for(var ae in re)re.hasOwnProperty(ae)&&(x[ae]=re[ae])})(b,z)},function(b,z){function x(){this.constructor=b}ie(b,z),b.prototype=z===null?Object.create(z):(x.prototype=z.prototype,new x)}),ue=this&&this.__decorate||function(b,z,x,re){var ae,oe=arguments.length,ve=oe<3?z:re===null?re=Object.getOwnPropertyDescriptor(z,x):re;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ve=Reflect.decorate(b,z,x,re);else for(var ye=b.length-1;ye>=0;ye--)(ae=b[ye])&&(ve=(oe<3?ae(ve):oe>3?ae(z,x,ve):ae(z,x))||ve);return oe>3&&ve&&Object.defineProperty(z,x,ve),ve},se=this&&this.__param||function(b,z){return function(x,re){z(x,re,b)}};Object.defineProperty(be,"__esModule",{value:!0}),be.BufferService=be.MINIMUM_ROWS=be.MINIMUM_COLS=void 0;var te=ce(1),le=ce(69),ee=ce(0),ne=ce(2);be.MINIMUM_COLS=2,be.MINIMUM_ROWS=1;var E=function(b){function z(x){var re=b.call(this)||this;return re._optionsService=x,re.isUserScrolling=!1,re._onResize=new ee.EventEmitter,re.cols=Math.max(x.options.cols,be.MINIMUM_COLS),re.rows=Math.max(x.options.rows,be.MINIMUM_ROWS),re.buffers=new le.BufferSet(x,re),re}return Ce(z,b),Object.defineProperty(z.prototype,"onResize",{get:function(){return this._onResize.event},enumerable:!1,configurable:!0}),Object.defineProperty(z.prototype,"buffer",{get:function(){return this.buffers.active},enumerable:!1,configurable:!0}),z.prototype.dispose=function(){b.prototype.dispose.call(this),this.buffers.dispose()},z.prototype.resize=function(x,re){this.cols=x,this.rows=re,this.buffers.resize(x,re),this.buffers.setupTabStops(this.cols),this._onResize.fire({cols:x,rows:re})},z.prototype.reset=function(){this.buffers.dispose(),this.buffers=new le.BufferSet(this._optionsService,this),this.isUserScrolling=!1},z=ue([se(0,te.IOptionsService)],z)}(ne.Disposable);be.BufferService=E},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(le,ee){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ne,E){ne.__proto__=E}||function(ne,E){for(var b in E)E.hasOwnProperty(b)&&(ne[b]=E[b])})(le,ee)},function(le,ee){function ne(){this.constructor=le}ie(le,ee),le.prototype=ee===null?Object.create(ee):(ne.prototype=ee.prototype,new ne)});Object.defineProperty(be,"__esModule",{value:!0}),be.BufferSet=void 0;var ue=ce(70),se=ce(0),te=function(le){function ee(ne,E){var b=le.call(this)||this;return b._onBufferActivate=b.register(new se.EventEmitter),b._normal=new ue.Buffer(!0,ne,E),b._normal.fillViewportRows(),b._alt=new ue.Buffer(!1,ne,E),b._activeBuffer=b._normal,b.setupTabStops(),b}return Ce(ee,le),Object.defineProperty(ee.prototype,"onBufferActivate",{get:function(){return this._onBufferActivate.event},enumerable:!1,configurable:!0}),Object.defineProperty(ee.prototype,"alt",{get:function(){return this._alt},enumerable:!1,configurable:!0}),Object.defineProperty(ee.prototype,"active",{get:function(){return this._activeBuffer},enumerable:!1,configurable:!0}),Object.defineProperty(ee.prototype,"normal",{get:function(){return this._normal},enumerable:!1,configurable:!0}),ee.prototype.activateNormalBuffer=function(){this._activeBuffer!==this._normal&&(this._normal.x=this._alt.x,this._normal.y=this._alt.y,this._alt.clear(),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}))},ee.prototype.activateAltBuffer=function(ne){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(ne),this._alt.x=this._normal.x,this._alt.y=this._normal.y,this._activeBuffer=this._alt,this._onBufferActivate.fire({activeBuffer:this._alt,inactiveBuffer:this._normal}))},ee.prototype.resize=function(ne,E){this._normal.resize(ne,E),this._alt.resize(ne,E)},ee.prototype.setupTabStops=function(ne){this._normal.setupTabStops(ne),this._alt.setupTabStops(ne)},ee}(ce(2).Disposable);be.BufferSet=te},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.BufferStringIterator=be.Buffer=be.MAX_BUFFER_SIZE=void 0;var ie=ce(71),Ce=ce(16),ue=ce(4),se=ce(3),te=ce(72),le=ce(73),ee=ce(20),ne=ce(6);be.MAX_BUFFER_SIZE=4294967295;var E=function(){function z(x,re,ae){this._hasScrollback=x,this._optionsService=re,this._bufferService=ae,this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.savedY=0,this.savedX=0,this.savedCurAttrData=Ce.DEFAULT_ATTR_DATA.clone(),this.savedCharset=ee.DEFAULT_CHARSET,this.markers=[],this._nullCell=ue.CellData.fromCharData([0,se.NULL_CELL_CHAR,se.NULL_CELL_WIDTH,se.NULL_CELL_CODE]),this._whitespaceCell=ue.CellData.fromCharData([0,se.WHITESPACE_CELL_CHAR,se.WHITESPACE_CELL_WIDTH,se.WHITESPACE_CELL_CODE]),this._cols=this._bufferService.cols,this._rows=this._bufferService.rows,this.lines=new ie.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}return z.prototype.getNullCell=function(x){return x?(this._nullCell.fg=x.fg,this._nullCell.bg=x.bg,this._nullCell.extended=x.extended):(this._nullCell.fg=0,this._nullCell.bg=0,this._nullCell.extended=new ne.ExtendedAttrs),this._nullCell},z.prototype.getWhitespaceCell=function(x){return x?(this._whitespaceCell.fg=x.fg,this._whitespaceCell.bg=x.bg,this._whitespaceCell.extended=x.extended):(this._whitespaceCell.fg=0,this._whitespaceCell.bg=0,this._whitespaceCell.extended=new ne.ExtendedAttrs),this._whitespaceCell},z.prototype.getBlankLine=function(x,re){return new Ce.BufferLine(this._bufferService.cols,this.getNullCell(x),re)},Object.defineProperty(z.prototype,"hasScrollback",{get:function(){return this._hasScrollback&&this.lines.maxLength>this._rows},enumerable:!1,configurable:!0}),Object.defineProperty(z.prototype,"isCursorInViewport",{get:function(){var x=this.ybase+this.y-this.ydisp;return x>=0&&x<this._rows},enumerable:!1,configurable:!0}),z.prototype._getCorrectBufferLength=function(x){if(!this._hasScrollback)return x;var re=x+this._optionsService.options.scrollback;return re>be.MAX_BUFFER_SIZE?be.MAX_BUFFER_SIZE:re},z.prototype.fillViewportRows=function(x){if(this.lines.length===0){x===void 0&&(x=Ce.DEFAULT_ATTR_DATA);for(var re=this._rows;re--;)this.lines.push(this.getBlankLine(x))}},z.prototype.clear=function(){this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.lines=new ie.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()},z.prototype.resize=function(x,re){var ae=this.getNullCell(Ce.DEFAULT_ATTR_DATA),oe=this._getCorrectBufferLength(re);if(oe>this.lines.maxLength&&(this.lines.maxLength=oe),this.lines.length>0){if(this._cols<x)for(var ve=0;ve<this.lines.length;ve++)this.lines.get(ve).resize(x,ae);var ye=0;if(this._rows<re)for(var me=this._rows;me<re;me++)this.lines.length<re+this.ybase&&(this._optionsService.options.windowsMode?this.lines.push(new Ce.BufferLine(x,ae)):this.ybase>0&&this.lines.length<=this.ybase+this.y+ye+1?(this.ybase--,ye++,this.ydisp>0&&this.ydisp--):this.lines.push(new Ce.BufferLine(x,ae)));else for(me=this._rows;me>re;me--)this.lines.length>re+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));if(oe<this.lines.maxLength){var ge=this.lines.length-oe;ge>0&&(this.lines.trimStart(ge),this.ybase=Math.max(this.ybase-ge,0),this.ydisp=Math.max(this.ydisp-ge,0),this.savedY=Math.max(this.savedY-ge,0)),this.lines.maxLength=oe}this.x=Math.min(this.x,x-1),this.y=Math.min(this.y,re-1),ye&&(this.y+=ye),this.savedX=Math.min(this.savedX,x-1),this.scrollTop=0}if(this.scrollBottom=re-1,this._isReflowEnabled&&(this._reflow(x,re),this._cols>x))for(ve=0;ve<this.lines.length;ve++)this.lines.get(ve).resize(x,ae);this._cols=x,this._rows=re},Object.defineProperty(z.prototype,"_isReflowEnabled",{get:function(){return this._hasScrollback&&!this._optionsService.options.windowsMode},enumerable:!1,configurable:!0}),z.prototype._reflow=function(x,re){this._cols!==x&&(x>this._cols?this._reflowLarger(x,re):this._reflowSmaller(x,re))},z.prototype._reflowLarger=function(x,re){var ae=te.reflowLargerGetLinesToRemove(this.lines,this._cols,x,this.ybase+this.y,this.getNullCell(Ce.DEFAULT_ATTR_DATA));if(ae.length>0){var oe=te.reflowLargerCreateNewLayout(this.lines,ae);te.reflowLargerApplyNewLayout(this.lines,oe.layout),this._reflowLargerAdjustViewport(x,re,oe.countRemoved)}},z.prototype._reflowLargerAdjustViewport=function(x,re,ae){for(var oe=this.getNullCell(Ce.DEFAULT_ATTR_DATA),ve=ae;ve-- >0;)this.ybase===0?(this.y>0&&this.y--,this.lines.length<re&&this.lines.push(new Ce.BufferLine(x,oe))):(this.ydisp===this.ybase&&this.ydisp--,this.ybase--);this.savedY=Math.max(this.savedY-ae,0)},z.prototype._reflowSmaller=function(x,re){for(var ae=this.getNullCell(Ce.DEFAULT_ATTR_DATA),oe=[],ve=0,ye=this.lines.length-1;ye>=0;ye--){var me=this.lines.get(ye);if(!(!me||!me.isWrapped&&me.getTrimmedLength()<=x)){for(var ge=[me];me.isWrapped&&ye>0;)me=this.lines.get(--ye),ge.unshift(me);var _e=this.ybase+this.y;if(!(_e>=ye&&_e<ye+ge.length)){var he=ge[ge.length-1].getTrimmedLength(),pe=te.reflowSmallerGetNewLineLengths(ge,this._cols,x),ke=pe.length-ge.length,Te=void 0;Te=this.ybase===0&&this.y!==this.lines.length-1?Math.max(0,this.y-this.lines.maxLength+ke):Math.max(0,this.lines.length-this.lines.maxLength+ke);for(var Ee=[],Oe=0;Oe<ke;Oe++){var je=this.getBlankLine(Ce.DEFAULT_ATTR_DATA,!0);Ee.push(je)}Ee.length>0&&(oe.push({start:ye+ge.length+ve,newLines:Ee}),ve+=Ee.length),ge.push.apply(ge,Ee);var Pe=pe.length-1,Qe=pe[Pe];Qe===0&&(Qe=pe[--Pe]);for(var Xe=ge.length-ke-1,ot=he;Xe>=0;){var He=Math.min(ot,Qe);if(ge[Pe].copyCellsFrom(ge[Xe],ot-He,Qe-He,He,!0),(Qe-=He)===0&&(Qe=pe[--Pe]),(ot-=He)===0){Xe--;var rt=Math.max(Xe,0);ot=te.getWrappedLineTrimmedLength(ge,rt,this._cols)}}for(Oe=0;Oe<ge.length;Oe++)pe[Oe]<x&&ge[Oe].setCell(pe[Oe],ae);for(var Ye=ke-Te;Ye-- >0;)this.ybase===0?this.y<re-1?(this.y++,this.lines.pop()):(this.ybase++,this.ydisp++):this.ybase<Math.min(this.lines.maxLength,this.lines.length+ve)-re&&(this.ybase===this.ydisp&&this.ydisp++,this.ybase++);this.savedY=Math.min(this.savedY+ke,this.ybase+re-1)}}}if(oe.length>0){var ut=[],Ge=[];for(Oe=0;Oe<this.lines.length;Oe++)Ge.push(this.lines.get(Oe));var ze=this.lines.length,Ve=ze-1,$e=0,nt=oe[$e];this.lines.length=Math.min(this.lines.maxLength,this.lines.length+ve);var et=0;for(Oe=Math.min(this.lines.maxLength-1,ze+ve-1);Oe>=0;Oe--)if(nt&&nt.start>Ve+et){for(var pt=nt.newLines.length-1;pt>=0;pt--)this.lines.set(Oe--,nt.newLines[pt]);Oe++,ut.push({index:Ve+1,amount:nt.newLines.length}),et+=nt.newLines.length,nt=oe[++$e]}else this.lines.set(Oe,Ge[Ve--]);var ct=0;for(Oe=ut.length-1;Oe>=0;Oe--)ut[Oe].index+=ct,this.lines.onInsertEmitter.fire(ut[Oe]),ct+=ut[Oe].amount;var Ot=Math.max(0,ze+ve-this.lines.maxLength);Ot>0&&this.lines.onTrimEmitter.fire(Ot)}},z.prototype.stringIndexToBufferIndex=function(x,re,ae){for(ae===void 0&&(ae=!1);re;){var oe=this.lines.get(x);if(!oe)return[-1,-1];for(var ve=ae?oe.getTrimmedLength():oe.length,ye=0;ye<ve;++ye)if(oe.get(ye)[se.CHAR_DATA_WIDTH_INDEX]&&(re-=oe.get(ye)[se.CHAR_DATA_CHAR_INDEX].length||1),re<0)return[x,ye];x++}return[x,0]},z.prototype.translateBufferLineToString=function(x,re,ae,oe){ae===void 0&&(ae=0);var ve=this.lines.get(x);return ve?ve.translateToString(re,ae,oe):""},z.prototype.getWrappedRangeForLine=function(x){for(var re=x,ae=x;re>0&&this.lines.get(re).isWrapped;)re--;for(;ae+1<this.lines.length&&this.lines.get(ae+1).isWrapped;)ae++;return{first:re,last:ae}},z.prototype.setupTabStops=function(x){for(x!=null?this.tabs[x]||(x=this.prevStop(x)):(this.tabs={},x=0);x<this._cols;x+=this._optionsService.options.tabStopWidth)this.tabs[x]=!0},z.prototype.prevStop=function(x){for(x==null&&(x=this.x);!this.tabs[--x]&&x>0;);return x>=this._cols?this._cols-1:x<0?0:x},z.prototype.nextStop=function(x){for(x==null&&(x=this.x);!this.tabs[++x]&&x<this._cols;);return x>=this._cols?this._cols-1:x<0?0:x},z.prototype.addMarker=function(x){var re=this,ae=new le.Marker(x);return this.markers.push(ae),ae.register(this.lines.onTrim(function(oe){ae.line-=oe,ae.line<0&&ae.dispose()})),ae.register(this.lines.onInsert(function(oe){ae.line>=oe.index&&(ae.line+=oe.amount)})),ae.register(this.lines.onDelete(function(oe){ae.line>=oe.index&&ae.line<oe.index+oe.amount&&ae.dispose(),ae.line>oe.index&&(ae.line-=oe.amount)})),ae.register(ae.onDispose(function(){return re._removeMarker(ae)})),ae},z.prototype._removeMarker=function(x){this.markers.splice(this.markers.indexOf(x),1)},z.prototype.iterator=function(x,re,ae,oe,ve){return new b(this,x,re,ae,oe,ve)},z}();be.Buffer=E;var b=function(){function z(x,re,ae,oe,ve,ye){ae===void 0&&(ae=0),oe===void 0&&(oe=x.lines.length),ve===void 0&&(ve=0),ye===void 0&&(ye=0),this._buffer=x,this._trimRight=re,this._startIndex=ae,this._endIndex=oe,this._startOverscan=ve,this._endOverscan=ye,this._startIndex<0&&(this._startIndex=0),this._endIndex>this._buffer.lines.length&&(this._endIndex=this._buffer.lines.length),this._current=this._startIndex}return z.prototype.hasNext=function(){return this._current<this._endIndex},z.prototype.next=function(){var x=this._buffer.getWrappedRangeForLine(this._current);x.first<this._startIndex-this._startOverscan&&(x.first=this._startIndex-this._startOverscan),x.last>this._endIndex+this._endOverscan&&(x.last=this._endIndex+this._endOverscan),x.first=Math.max(x.first,0),x.last=Math.min(x.last,this._buffer.lines.length);for(var re="",ae=x.first;ae<=x.last;++ae)re+=this._buffer.translateBufferLineToString(ae,this._trimRight);return this._current=x.last+1,{range:x,content:re}},z}();be.BufferStringIterator=b},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.CircularList=void 0;var ie=ce(0),Ce=function(){function ue(se){this._maxLength=se,this.onDeleteEmitter=new ie.EventEmitter,this.onInsertEmitter=new ie.EventEmitter,this.onTrimEmitter=new ie.EventEmitter,this._array=new Array(this._maxLength),this._startIndex=0,this._length=0}return Object.defineProperty(ue.prototype,"onDelete",{get:function(){return this.onDeleteEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(ue.prototype,"onInsert",{get:function(){return this.onInsertEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(ue.prototype,"onTrim",{get:function(){return this.onTrimEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(ue.prototype,"maxLength",{get:function(){return this._maxLength},set:function(se){if(this._maxLength!==se){for(var te=new Array(se),le=0;le<Math.min(se,this.length);le++)te[le]=this._array[this._getCyclicIndex(le)];this._array=te,this._maxLength=se,this._startIndex=0}},enumerable:!1,configurable:!0}),Object.defineProperty(ue.prototype,"length",{get:function(){return this._length},set:function(se){if(se>this._length)for(var te=this._length;te<se;te++)this._array[te]=void 0;this._length=se},enumerable:!1,configurable:!0}),ue.prototype.get=function(se){return this._array[this._getCyclicIndex(se)]},ue.prototype.set=function(se,te){this._array[this._getCyclicIndex(se)]=te},ue.prototype.push=function(se){this._array[this._getCyclicIndex(this._length)]=se,this._length===this._maxLength?(this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1)):this._length++},ue.prototype.recycle=function(){if(this._length!==this._maxLength)throw new Error("Can only recycle when the buffer is full");return this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1),this._array[this._getCyclicIndex(this._length-1)]},Object.defineProperty(ue.prototype,"isFull",{get:function(){return this._length===this._maxLength},enumerable:!1,configurable:!0}),ue.prototype.pop=function(){return this._array[this._getCyclicIndex(this._length---1)]},ue.prototype.splice=function(se,te){for(var le=[],ee=2;ee<arguments.length;ee++)le[ee-2]=arguments[ee];if(te){for(var ne=se;ne<this._length-te;ne++)this._array[this._getCyclicIndex(ne)]=this._array[this._getCyclicIndex(ne+te)];this._length-=te}for(ne=this._length-1;ne>=se;ne--)this._array[this._getCyclicIndex(ne+le.length)]=this._array[this._getCyclicIndex(ne)];for(ne=0;ne<le.length;ne++)this._array[this._getCyclicIndex(se+ne)]=le[ne];if(this._length+le.length>this._maxLength){var E=this._length+le.length-this._maxLength;this._startIndex+=E,this._length=this._maxLength,this.onTrimEmitter.fire(E)}else this._length+=le.length},ue.prototype.trimStart=function(se){se>this._length&&(se=this._length),this._startIndex+=se,this._length-=se,this.onTrimEmitter.fire(se)},ue.prototype.shiftElements=function(se,te,le){if(!(te<=0)){if(se<0||se>=this._length)throw new Error("start argument out of range");if(se+le<0)throw new Error("Cannot shift elements in list beyond index 0");if(le>0){for(var ee=te-1;ee>=0;ee--)this.set(se+ee+le,this.get(se+ee));var ne=se+te+le-this._length;if(ne>0)for(this._length+=ne;this._length>this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(ee=0;ee<te;ee++)this.set(se+ee+le,this.get(se+ee))}},ue.prototype._getCyclicIndex=function(se){return(this._startIndex+se)%this._maxLength},ue}();be.CircularList=Ce},function(Mt,be,ce){"use strict";function ie(Ce,ue,se){if(ue===Ce.length-1)return Ce[ue].getTrimmedLength();var te=!Ce[ue].hasContent(se-1)&&Ce[ue].getWidth(se-1)===1,le=Ce[ue+1].getWidth(0)===2;return te&&le?se-1:se}Object.defineProperty(be,"__esModule",{value:!0}),be.getWrappedLineTrimmedLength=be.reflowSmallerGetNewLineLengths=be.reflowLargerApplyNewLayout=be.reflowLargerCreateNewLayout=be.reflowLargerGetLinesToRemove=void 0,be.reflowLargerGetLinesToRemove=function(Ce,ue,se,te,le){for(var ee=[],ne=0;ne<Ce.length-1;ne++){var E=ne,b=Ce.get(++E);if(b.isWrapped){for(var z=[Ce.get(ne)];E<Ce.length&&b.isWrapped;)z.push(b),b=Ce.get(++E);if(te>=ne&&te<E)ne+=z.length-1;else{for(var x=0,re=ie(z,x,ue),ae=1,oe=0;ae<z.length;){var ve=ie(z,ae,ue),ye=ve-oe,me=se-re,ge=Math.min(ye,me);z[x].copyCellsFrom(z[ae],oe,re,ge,!1),(re+=ge)===se&&(x++,re=0),(oe+=ge)===ve&&(ae++,oe=0),re===0&&x!==0&&z[x-1].getWidth(se-1)===2&&(z[x].copyCellsFrom(z[x-1],se-1,re++,1,!1),z[x-1].setCell(se-1,le))}z[x].replaceCells(re,se,le);for(var _e=0,he=z.length-1;he>0&&(he>x||z[he].getTrimmedLength()===0);he--)_e++;_e>0&&(ee.push(ne+z.length-_e),ee.push(_e)),ne+=z.length-1}}}return ee},be.reflowLargerCreateNewLayout=function(Ce,ue){for(var se=[],te=0,le=ue[te],ee=0,ne=0;ne<Ce.length;ne++)if(le===ne){var E=ue[++te];Ce.onDeleteEmitter.fire({index:ne-ee,amount:E}),ne+=E-1,ee+=E,le=ue[++te]}else se.push(ne);return{layout:se,countRemoved:ee}},be.reflowLargerApplyNewLayout=function(Ce,ue){for(var se=[],te=0;te<ue.length;te++)se.push(Ce.get(ue[te]));for(te=0;te<se.length;te++)Ce.set(te,se[te]);Ce.length=ue.length},be.reflowSmallerGetNewLineLengths=function(Ce,ue,se){for(var te=[],le=Ce.map(function(re,ae){return ie(Ce,ae,ue)}).reduce(function(re,ae){return re+ae}),ee=0,ne=0,E=0;E<le;){if(le-E<se){te.push(le-E);break}ee+=se;var b=ie(Ce,ne,ue);ee>b&&(ee-=b,ne++);var z=Ce[ne].getWidth(ee-1)===2;z&&ee--;var x=z?se-1:se;te.push(x),E+=x}return te},be.getWrappedLineTrimmedLength=ie},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(te,le){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ee,ne){ee.__proto__=ne}||function(ee,ne){for(var E in ne)ne.hasOwnProperty(E)&&(ee[E]=ne[E])})(te,le)},function(te,le){function ee(){this.constructor=te}ie(te,le),te.prototype=le===null?Object.create(le):(ee.prototype=le.prototype,new ee)});Object.defineProperty(be,"__esModule",{value:!0}),be.Marker=void 0;var ue=ce(0),se=function(te){function le(ee){var ne=te.call(this)||this;return ne.line=ee,ne._id=le._nextId++,ne.isDisposed=!1,ne._onDispose=new ue.EventEmitter,ne}return Ce(le,te),Object.defineProperty(le.prototype,"id",{get:function(){return this._id},enumerable:!1,configurable:!0}),Object.defineProperty(le.prototype,"onDispose",{get:function(){return this._onDispose.event},enumerable:!1,configurable:!0}),le.prototype.dispose=function(){this.isDisposed||(this.isDisposed=!0,this.line=-1,this._onDispose.fire())},le._nextId=1,le}(ce(2).Disposable);be.Marker=se},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.OptionsService=be.DEFAULT_OPTIONS=be.DEFAULT_BELL_SOUND=void 0;var ie=ce(0),Ce=ce(11),ue=ce(33);be.DEFAULT_BELL_SOUND="data:audio/mp3;base64,SUQzBAAAAAAAI1RTU0UAAAAPAAADTGF2ZjU4LjMyLjEwNAAAAAAAAAAAAAAA//tQxAADB8AhSmxhIIEVCSiJrDCQBTcu3UrAIwUdkRgQbFAZC1CQEwTJ9mjRvBA4UOLD8nKVOWfh+UlK3z/177OXrfOdKl7pyn3Xf//WreyTRUoAWgBgkOAGbZHBgG1OF6zM82DWbZaUmMBptgQhGjsyYqc9ae9XFz280948NMBWInljyzsNRFLPWdnZGWrddDsjK1unuSrVN9jJsK8KuQtQCtMBjCEtImISdNKJOopIpBFpNSMbIHCSRpRR5iakjTiyzLhchUUBwCgyKiweBv/7UsQbg8isVNoMPMjAAAA0gAAABEVFGmgqK////9bP/6XCykxBTUUzLjEwMKqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq",be.DEFAULT_OPTIONS=Object.freeze({cols:80,rows:24,cursorBlink:!1,cursorStyle:"block",cursorWidth:1,bellSound:be.DEFAULT_BELL_SOUND,bellStyle:"none",drawBoldTextInBrightColors:!0,fastScrollModifier:"alt",fastScrollSensitivity:5,fontFamily:"courier-new, courier, monospace",fontSize:15,fontWeight:"normal",fontWeightBold:"bold",lineHeight:1,linkTooltipHoverDuration:500,letterSpacing:0,logLevel:"info",scrollback:1e3,scrollSensitivity:1,screenReaderMode:!1,macOptionIsMeta:!1,macOptionClickForcesSelection:!1,minimumContrastRatio:1,disableStdin:!1,allowProposedApi:!0,allowTransparency:!1,tabStopWidth:8,theme:{},rightClickSelectsWord:Ce.isMac,rendererType:"canvas",windowOptions:{},windowsMode:!1,wordSeparator:" ()[]{}',\"`",convertEol:!1,termName:"xterm",cancelEvents:!1});var se=["cols","rows"],te=function(){function le(ee){this._onOptionChange=new ie.EventEmitter,this.options=ue.clone(be.DEFAULT_OPTIONS);for(var ne=0,E=Object.keys(ee);ne<E.length;ne++){var b=E[ne];if(b in this.options){var z=ee[b];this.options[b]=z}}}return Object.defineProperty(le.prototype,"onOptionChange",{get:function(){return this._onOptionChange.event},enumerable:!1,configurable:!0}),le.prototype.setOption=function(ee,ne){if(!(ee in be.DEFAULT_OPTIONS))throw new Error('No option with key "'+ee+'"');if(se.indexOf(ee)!==-1)throw new Error('Option "'+ee+'" can only be set in the constructor');this.options[ee]!==ne&&(ne=this._sanitizeAndValidateOption(ee,ne),this.options[ee]!==ne&&(this.options[ee]=ne,this._onOptionChange.fire(ee)))},le.prototype._sanitizeAndValidateOption=function(ee,ne){switch(ee){case"bellStyle":case"cursorStyle":case"fontWeight":case"fontWeightBold":case"rendererType":case"wordSeparator":ne||(ne=be.DEFAULT_OPTIONS[ee]);break;case"cursorWidth":ne=Math.floor(ne);case"lineHeight":case"tabStopWidth":if(ne<1)throw new Error(ee+" cannot be less than 1, value: "+ne);break;case"minimumContrastRatio":ne=Math.max(1,Math.min(21,Math.round(10*ne)/10));break;case"scrollback":if((ne=Math.min(ne,4294967295))<0)throw new Error(ee+" cannot be less than 0, value: "+ne);break;case"fastScrollSensitivity":case"scrollSensitivity":if(ne<=0)throw new Error(ee+" cannot be less than or equal to 0, value: "+ne)}return ne},le.prototype.getOption=function(ee){if(!(ee in be.DEFAULT_OPTIONS))throw new Error('No option with key "'+ee+'"');return this.options[ee]},le}();be.OptionsService=te},function(Mt,be,ce){"use strict";var ie,Ce=this&&this.__extends||(ie=function(x,re){return(ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(ae,oe){ae.__proto__=oe}||function(ae,oe){for(var ve in oe)oe.hasOwnProperty(ve)&&(ae[ve]=oe[ve])})(x,re)},function(x,re){function ae(){this.constructor=x}ie(x,re),x.prototype=re===null?Object.create(re):(ae.prototype=re.prototype,new ae)}),ue=this&&this.__decorate||function(x,re,ae,oe){var ve,ye=arguments.length,me=ye<3?re:oe===null?oe=Object.getOwnPropertyDescriptor(re,ae):oe;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")me=Reflect.decorate(x,re,ae,oe);else for(var ge=x.length-1;ge>=0;ge--)(ve=x[ge])&&(me=(ye<3?ve(me):ye>3?ve(re,ae,me):ve(re,ae))||me);return ye>3&&me&&Object.defineProperty(re,ae,me),me},se=this&&this.__param||function(x,re){return function(ae,oe){re(ae,oe,x)}};Object.defineProperty(be,"__esModule",{value:!0}),be.CoreService=void 0;var te=ce(1),le=ce(0),ee=ce(33),ne=ce(2),E=Object.freeze({insertMode:!1}),b=Object.freeze({applicationCursorKeys:!1,applicationKeypad:!1,bracketedPasteMode:!1,origin:!1,reverseWraparound:!1,sendFocus:!1,wraparound:!0}),z=function(x){function re(ae,oe,ve,ye){var me=x.call(this)||this;return me._bufferService=oe,me._logService=ve,me._optionsService=ye,me.isCursorInitialized=!1,me.isCursorHidden=!1,me._onData=me.register(new le.EventEmitter),me._onUserInput=me.register(new le.EventEmitter),me._onBinary=me.register(new le.EventEmitter),me._scrollToBottom=ae,me.register({dispose:function(){return me._scrollToBottom=void 0}}),me.modes=ee.clone(E),me.decPrivateModes=ee.clone(b),me}return Ce(re,x),Object.defineProperty(re.prototype,"onData",{get:function(){return this._onData.event},enumerable:!1,configurable:!0}),Object.defineProperty(re.prototype,"onUserInput",{get:function(){return this._onUserInput.event},enumerable:!1,configurable:!0}),Object.defineProperty(re.prototype,"onBinary",{get:function(){return this._onBinary.event},enumerable:!1,configurable:!0}),re.prototype.reset=function(){this.modes=ee.clone(E),this.decPrivateModes=ee.clone(b)},re.prototype.triggerDataEvent=function(ae,oe){if(oe===void 0&&(oe=!1),!this._optionsService.options.disableStdin){var ve=this._bufferService.buffer;ve.ybase!==ve.ydisp&&this._scrollToBottom(),oe&&this._onUserInput.fire(),this._logService.debug('sending data "'+ae+'"',function(){return ae.split("").map(function(ye){return ye.charCodeAt(0)})}),this._onData.fire(ae)}},re.prototype.triggerBinaryEvent=function(ae){this._optionsService.options.disableStdin||(this._logService.debug('sending binary "'+ae+'"',function(){return ae.split("").map(function(oe){return oe.charCodeAt(0)})}),this._onBinary.fire(ae))},re=ue([se(1,te.IBufferService),se(2,te.ILogService),se(3,te.IOptionsService)],re)}(ne.Disposable);be.CoreService=z},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(b,z,x,re){var ae,oe=arguments.length,ve=oe<3?z:re===null?re=Object.getOwnPropertyDescriptor(z,x):re;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ve=Reflect.decorate(b,z,x,re);else for(var ye=b.length-1;ye>=0;ye--)(ae=b[ye])&&(ve=(oe<3?ae(ve):oe>3?ae(z,x,ve):ae(z,x))||ve);return oe>3&&ve&&Object.defineProperty(z,x,ve),ve},Ce=this&&this.__param||function(b,z){return function(x,re){z(x,re,b)}};Object.defineProperty(be,"__esModule",{value:!0}),be.CoreMouseService=void 0;var ue=ce(1),se=ce(0),te={NONE:{events:0,restrict:function(){return!1}},X10:{events:1,restrict:function(b){return b.button!==4&&b.action===1&&(b.ctrl=!1,b.alt=!1,b.shift=!1,!0)}},VT200:{events:19,restrict:function(b){return b.action!==32}},DRAG:{events:23,restrict:function(b){return b.action!==32||b.button!==3}},ANY:{events:31,restrict:function(b){return!0}}};function le(b,z){var x=(b.ctrl?16:0)|(b.shift?4:0)|(b.alt?8:0);return b.button===4?(x|=64,x|=b.action):(x|=3&b.button,4&b.button&&(x|=64),8&b.button&&(x|=128),b.action===32?x|=32:b.action!==0||z||(x|=3)),x}var ee=String.fromCharCode,ne={DEFAULT:function(b){var z=[le(b,!1)+32,b.col+32,b.row+32];return z[0]>255||z[1]>255||z[2]>255?"":"\x1B[M"+ee(z[0])+ee(z[1])+ee(z[2])},SGR:function(b){var z=b.action===0&&b.button!==4?"m":"M";return"\x1B[<"+le(b,!0)+";"+b.col+";"+b.row+z}},E=function(){function b(z,x){this._bufferService=z,this._coreService=x,this._protocols={},this._encodings={},this._activeProtocol="",this._activeEncoding="",this._onProtocolChange=new se.EventEmitter,this._lastEvent=null;for(var re=0,ae=Object.keys(te);re<ae.length;re++){var oe=ae[re];this.addProtocol(oe,te[oe])}for(var ve=0,ye=Object.keys(ne);ve<ye.length;ve++){var me=ye[ve];this.addEncoding(me,ne[me])}this.reset()}return b.prototype.addProtocol=function(z,x){this._protocols[z]=x},b.prototype.addEncoding=function(z,x){this._encodings[z]=x},Object.defineProperty(b.prototype,"activeProtocol",{get:function(){return this._activeProtocol},set:function(z){if(!this._protocols[z])throw new Error('unknown protocol "'+z+'"');this._activeProtocol=z,this._onProtocolChange.fire(this._protocols[z].events)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"areMouseEventsActive",{get:function(){return this._protocols[this._activeProtocol].events!==0},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"activeEncoding",{get:function(){return this._activeEncoding},set:function(z){if(!this._encodings[z])throw new Error('unknown encoding "'+z+'"');this._activeEncoding=z},enumerable:!1,configurable:!0}),b.prototype.reset=function(){this.activeProtocol="NONE",this.activeEncoding="DEFAULT",this._lastEvent=null},Object.defineProperty(b.prototype,"onProtocolChange",{get:function(){return this._onProtocolChange.event},enumerable:!1,configurable:!0}),b.prototype.triggerMouseEvent=function(z){if(z.col<0||z.col>=this._bufferService.cols||z.row<0||z.row>=this._bufferService.rows||z.button===4&&z.action===32||z.button===3&&z.action!==32||z.button!==4&&(z.action===2||z.action===3)||(z.col++,z.row++,z.action===32&&this._lastEvent&&this._compareEvents(this._lastEvent,z))||!this._protocols[this._activeProtocol].restrict(z))return!1;var x=this._encodings[this._activeEncoding](z);return x&&(this._activeEncoding==="DEFAULT"?this._coreService.triggerBinaryEvent(x):this._coreService.triggerDataEvent(x,!0)),this._lastEvent=z,!0},b.prototype.explainEvents=function(z){return{down:!!(1&z),up:!!(2&z),drag:!!(4&z),move:!!(8&z),wheel:!!(16&z)}},b.prototype._compareEvents=function(z,x){return z.col===x.col&&z.row===x.row&&z.button===x.button&&z.action===x.action&&z.ctrl===x.ctrl&&z.alt===x.alt&&z.shift===x.shift},b=ie([Ce(0,ue.IBufferService),Ce(1,ue.ICoreService)],b)}();be.CoreMouseService=E},function(Mt,be,ce){"use strict";var ie=this&&this.__decorate||function(te,le,ee,ne){var E,b=arguments.length,z=b<3?le:ne===null?ne=Object.getOwnPropertyDescriptor(le,ee):ne;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")z=Reflect.decorate(te,le,ee,ne);else for(var x=te.length-1;x>=0;x--)(E=te[x])&&(z=(b<3?E(z):b>3?E(le,ee,z):E(le,ee))||z);return b>3&&z&&Object.defineProperty(le,ee,z),z},Ce=this&&this.__param||function(te,le){return function(ee,ne){le(ee,ne,te)}};Object.defineProperty(be,"__esModule",{value:!0}),be.DirtyRowService=void 0;var ue=ce(1),se=function(){function te(le){this._bufferService=le,this.clearRange()}return Object.defineProperty(te.prototype,"start",{get:function(){return this._start},enumerable:!1,configurable:!0}),Object.defineProperty(te.prototype,"end",{get:function(){return this._end},enumerable:!1,configurable:!0}),te.prototype.clearRange=function(){this._start=this._bufferService.buffer.y,this._end=this._bufferService.buffer.y},te.prototype.markDirty=function(le){le<this._start?this._start=le:le>this._end&&(this._end=le)},te.prototype.markRangeDirty=function(le,ee){if(le>ee){var ne=le;le=ee,ee=ne}le<this._start&&(this._start=le),ee>this._end&&(this._end=ee)},te.prototype.markAllDirty=function(){this.markRangeDirty(0,this._bufferService.rows-1)},te=ie([Ce(0,ue.IBufferService)],te)}();be.DirtyRowService=se},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.UnicodeService=void 0;var ie=ce(0),Ce=ce(79),ue=function(){function se(){this._providers=Object.create(null),this._active="",this._onChange=new ie.EventEmitter;var te=new Ce.UnicodeV6;this.register(te),this._active=te.version,this._activeProvider=te}return Object.defineProperty(se.prototype,"onChange",{get:function(){return this._onChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(se.prototype,"versions",{get:function(){return Object.keys(this._providers)},enumerable:!1,configurable:!0}),Object.defineProperty(se.prototype,"activeVersion",{get:function(){return this._active},set:function(te){if(!this._providers[te])throw new Error('unknown Unicode version "'+te+'"');this._active=te,this._activeProvider=this._providers[te],this._onChange.fire(te)},enumerable:!1,configurable:!0}),se.prototype.register=function(te){this._providers[te.version]=te},se.prototype.wcwidth=function(te){return this._activeProvider.wcwidth(te)},se.prototype.getStringCellWidth=function(te){for(var le=0,ee=te.length,ne=0;ne<ee;++ne){var E=te.charCodeAt(ne);if(55296<=E&&E<=56319){if(++ne>=ee)return le+this.wcwidth(E);var b=te.charCodeAt(ne);56320<=b&&b<=57343?E=1024*(E-55296)+b-56320+65536:le+=this.wcwidth(b)}le+=this.wcwidth(E)}return le},se}();be.UnicodeService=ue},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.UnicodeV6=void 0;var ie,Ce=ce(15),ue=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531]],se=[[68097,68099],[68101,68102],[68108,68111],[68152,68154],[68159,68159],[119143,119145],[119155,119170],[119173,119179],[119210,119213],[119362,119364],[917505,917505],[917536,917631],[917760,917999]],te=function(){function le(){if(this.version="6",!ie){ie=new Uint8Array(65536),Ce.fill(ie,1),ie[0]=0,Ce.fill(ie,0,1,32),Ce.fill(ie,0,127,160),Ce.fill(ie,2,4352,4448),ie[9001]=2,ie[9002]=2,Ce.fill(ie,2,11904,42192),ie[12351]=1,Ce.fill(ie,2,44032,55204),Ce.fill(ie,2,63744,64256),Ce.fill(ie,2,65040,65050),Ce.fill(ie,2,65072,65136),Ce.fill(ie,2,65280,65377),Ce.fill(ie,2,65504,65511);for(var ee=0;ee<ue.length;++ee)Ce.fill(ie,0,ue[ee][0],ue[ee][1]+1)}}return le.prototype.wcwidth=function(ee){return ee<32?0:ee<127?1:ee<65536?ie[ee]:function(ne,E){var b,z=0,x=E.length-1;if(ne<E[0][0]||ne>E[x][1])return!1;for(;x>=z;)if(ne>E[b=z+x>>1][1])z=b+1;else{if(!(ne<E[b][0]))return!0;x=b-1}return!1}(ee,se)?0:ee>=131072&&ee<=196605||ee>=196608&&ee<=262141?2:1},le}();be.UnicodeV6=te},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.CharsetService=void 0;var ie=function(){function Ce(){this.glevel=0,this._charsets=[]}return Ce.prototype.reset=function(){this.charset=void 0,this._charsets=[],this.glevel=0},Ce.prototype.setgLevel=function(ue){this.glevel=ue,this.charset=this._charsets[ue]},Ce.prototype.setgCharset=function(ue,se){this._charsets[ue]=se,this.glevel===ue&&(this.charset=se)},Ce}();be.CharsetService=ie},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.updateWindowsModeWrappedState=void 0;var ie=ce(3);be.updateWindowsModeWrappedState=function(Ce){var ue=Ce.buffer.lines.get(Ce.buffer.ybase+Ce.buffer.y-1),se=ue==null?void 0:ue.get(Ce.cols-1),te=Ce.buffer.lines.get(Ce.buffer.ybase+Ce.buffer.y);te&&se&&(te.isWrapped=se[ie.CHAR_DATA_CODE_INDEX]!==ie.NULL_CELL_CODE&&se[ie.CHAR_DATA_CODE_INDEX]!==ie.WHITESPACE_CELL_CODE)}},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.WriteBuffer=void 0;var ie=function(){function Ce(ue){this._action=ue,this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0}return Ce.prototype.writeSync=function(ue){if(this._writeBuffer.length){for(var se=this._bufferOffset;se<this._writeBuffer.length;++se){var te=this._writeBuffer[se],le=this._callbacks[se];this._action(te),le&&le()}this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=2147483647}this._action(ue)},Ce.prototype.write=function(ue,se){var te=this;if(this._pendingData>5e7)throw new Error("write data discarded, use flow control to avoid losing data");this._writeBuffer.length||(this._bufferOffset=0,setTimeout(function(){return te._innerWrite()})),this._pendingData+=ue.length,this._writeBuffer.push(ue),this._callbacks.push(se)},Ce.prototype._innerWrite=function(){for(var ue=this,se=Date.now();this._writeBuffer.length>this._bufferOffset;){var te=this._writeBuffer[this._bufferOffset],le=this._callbacks[this._bufferOffset];if(this._bufferOffset++,this._action(te),this._pendingData-=te.length,le&&le(),Date.now()-se>=12)break}this._writeBuffer.length>this._bufferOffset?(this._bufferOffset>50&&(this._writeBuffer=this._writeBuffer.slice(this._bufferOffset),this._callbacks=this._callbacks.slice(this._bufferOffset),this._bufferOffset=0),setTimeout(function(){return ue._innerWrite()},0)):(this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0)},Ce}();be.WriteBuffer=ie},function(Mt,be,ce){"use strict";Object.defineProperty(be,"__esModule",{value:!0}),be.AddonManager=void 0;var ie=function(){function Ce(){this._addons=[]}return Ce.prototype.dispose=function(){for(var ue=this._addons.length-1;ue>=0;ue--)this._addons[ue].instance.dispose()},Ce.prototype.loadAddon=function(ue,se){var te=this,le={instance:se,dispose:se.dispose,isDisposed:!1};this._addons.push(le),se.dispose=function(){return te._wrappedAddonDispose(le)},se.activate(ue)},Ce.prototype._wrappedAddonDispose=function(ue){if(!ue.isDisposed){for(var se=-1,te=0;te<this._addons.length;te++)if(this._addons[te]===ue){se=te;break}if(se===-1)throw new Error("Could not dispose an addon that has not been loaded");ue.isDisposed=!0,ue.dispose.apply(ue.instance),this._addons.splice(se,1)}},Ce}();be.AddonManager=ie}])})},93314:function(Xt){"use strict";Xt.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMwAAACaCAYAAADl9acYAAAAAXNSR0IArs4c6QAAIABJREFUeF7tXQd4U1Ubfs/NaJtO9kzLahFQEJkiUBBFUFFkCCjiAAVFERT5FREQQQXBBcpysWRP2RtkKRsEOphNodCZdDfjnv85CU2TZt2bhABNDw9PmtzvrO+c957xLQIP0pkz1yrQIEmwwcDzHhTj91klEo7jpcG5zetWUJdmRjmPvTM9GI9JgSGvadOoLE9KJJ5kPp2YXLtZdO1kT8ooz2vigCNelvPYezPEG7z0CDAn4pJqPvJA5A3vdcl/S3LEy3Iee29OeIOX5YDx3nh4VFI5YDxin6DM5YARxKb7g6gcMHd+nMoBc+d57LKGhCQ1ZURBCoVL2nKCO8sBZWW50x1TOWDuLP8FlV4OGEFs8glROWB8wmbPKikHjGf882bucsB4k5t3qKxywNwhxrpRbJkGTOx0ehlA3d9e5VEtzA3ulGe55zmg1QOfrCVo34BgQGvr5rLDRl4RRZG+5NjBESBc4FHw1LlrCAuPsCo0JjKi7J5hYqfTXADBq4byCJLf82Nf3kA3OfD9LgKdgeCzZ4CUTJ1VKQFyKQgpmeMSjiKvQC+oplspN/wOMDcBVFv0Bo+KwYJ4VE50H3Jg7j6CWzkEX74A3MrSgTfeKZpSaBCHcAVn/JunBHlFPDR5BkG9LMjPt7mZLOtbskQADea9wqOW9coqiGHlRPcHBxYcJriQQvB9P+v2cqCwWFxgoOJk6JeTNX4HmJMAHv6xP4/6VXw/+OxNx/bM/pIohdUE9VW/VxwjOHiJYO5A6xolpGSpYW3jIW4w/A8wM+h+UHSY2pvHgzV9NXymeor0wPc7Cf7XzWJ/4Nsm+Ly2LzZx+OwZ3yuVbzhNsPEMwcI3rM8wMikHiURi5gNbbQoKrc84zpjkj2eYzQC6f96DomUd305ctrp8tp5gSk/f1utzlFhUOHYthy9f8D1gdpwnWHiEYOVQ6zNM6QM/AY+CImHnF9YtfwTMCgB9P+5G0SHa9xP3bk2gT9cBU3r6Hjp95nBYNcz3gDlwkRhX843vlfS59PmFHfjFzgC/2pJ1nEEnEIpIAG+834Wia2Ox7PJ8wt0twLz7J8Gsl3zf316zCVYPsz5oe85F1yUcu0YwcQPBjlElZyjL8wsrQeyBn+XxK8DETqefgyACFCPe6kjxfDPfT6C7BpilBLMG+L6/A34h+P1VikCZ60nuTYpzN4AxqznjCqPOMZ1RSp9f2OVLYZH1lbOrNvjVlswIGEAKYOyrj1K82NL3E+huAWbEMnbFSn1+Qzd4AcE3fajPZV6X04D3lnHGM4xOawKFJwLLYiD5H2AoCkHwJQMLA42v090CzJjVBBN7UCh8rN3AgDrqCYq6lX3L6RQ1MGQRhwWvA7UrALbnFzCJjOhG+d2WjFCkUYKZPZpSDIv1PWDGrycY34NCahI0+yxN/Ivg3c4UlUN8VqWxok/XEfRrSdG0tm/rzcoHBv7KYc5AILqqLWDcOb/45RmGEFyhFL8/0Yga33y+Tl9uJhjxOEVIoG9rnrqVKSJSRFb0fb3tG1A81sC39TLRSu85HL57Eaii0Bm3oqEKqZXSJaUURUxTU0Tyuy0ZAc5SYCUbxE+6+x4w3+0kGNiWooqP3/Qz9xB0bUTRsLqI2eEFUlbvA9WBJxv5ltdMit9jFocpLwB1InQIkBEQTmLUHStOBoMBOr24K2+/AwwPHOKArS2iKCY9VzKIg34jyMgTv6f1wpwqL8JLHKgUTLHwjZIxZTKg0V2Bzg2tLzvYBYA75xe/25J1mkEnGAzYyXE40KQmMK23uLeLN8b1j0ME7epTxFTzRmnCy/jzXyCqIny+NVryDzFeKfd+xLcrDOMMO8MMfgx45iFrOZA7AstiTvvVoZ91usM3tClHcLpeZWDmAN8DZtlRgkY1KJr5+BC87hQQLAeebCwcZN6gXH6MgG2P+rfyDmD+WLoV8xZugkIRiNh2TTHghcfRoF4tFBZpkXgpGQ81rmdu9puLOLzwMPBYPR1Cgzw/v7CC/WpLxjrc/jtaT2LApRrhwC+DfA+Y9aeI0dKzbT3vTCChk3r7eaBABzzfTGgO79CtPUmM9b7U2jv9bf3kOyjSlihLcoSg93MdkZ2Th227j2Hoq8/inTeeNzZ+xFIOsTHAsw/pAeL5+cUvAdPuG1pVRnArQgEsGex7wGw7RxAgBTo19M4EEjqtD1wEkrPYm15oDu/QbfkPSM0hHsu8du0/gSnfLkFGVrbThjFLynULJ6FOZHUw2RNbyd/qUJLFHZV+ywr9aksWO4Ou0BK8KueRz/bVq++CUuD+RGbhB3R/0LeAOZEEnFIRvPGYb+vdGw+cvU7w3uOe1dv+mfeRk5svCMUfvz8AA3o9jgkbCJQVgPe7lGTz5MDvj4f+VXs/JH1ip1PmAkHy17u8z42bjl4lxjf9C809m0CCZo4FUVwKsDPOJLz0ZTp6Fdh6jtnWe1bvuCm/4q/tRwQ1/b03e2LIwGfw1RaCkADg425AOvPkYCHZd0cG43dbsk4zaDFgWHiHcG85wjBQoEhnMhAzf5r/Jihkf9/+fjXDtDXqGA108+Eqcy0DYAfwMU95NnEFzVgLovibwK8HCab19qze61s24Pf5K7A5KwB5vHM1CblMij9m/Q87rtc1jsek54CMPIBayGD0BgP0ImUw/gwYFiqjllhHGAcvAkuPcijU8cgv0KGgSGv8LNJqweu1MOh14A3ss+S78W+Dzuo3RsPoTy0YgIjQALFz0C36tBzg570EE3p4NnHFVn5TA0zaSPDzy57Vu2bIS6jF67BDHYBHgnVI0kow+6ZjLyZNm9RD+35jkZINfNO7ZIVhEn+e16NQ6157/OqWjJ1h9n1IXoydTi8AeGD+KzxqinCEsfkswfBJC2HQacXOG7v0B+e9CGXVUK+U5aoQdm5iE3eqh296R/XoDEBu0e3/hcz3FzF+Z292trI91Zgav7N2tKrDrrfFTdgTI4dAl61BipZDDXYINRCMvBrusNvBikAMHT8LTM3/pwElK4xMAuQV6uBuKK4yA5hEVfY8SvmmHCETGyjDtzqbQLHf0KMgaCnWEcaW/whGT1mAHHZP6oW09bueaFy3khdKcl0EO+y+v4xgphs2MWxbs+K46bLCDIoi6+9iVLKY4PbTp8UB5t8h/UB53qimz1aJA9lyLExz7H1vyMCnUa15L/x9EfhtkIk/nh74y9ShPz5JnUGA26qFZIdcTofWqR5xxd5Uip1O9wDoJNYRxs4LBB9PXYxUdaHrGSqAYuWUp9GmSQ0BlN4h8cTq8qVfOGgKStpBeAoJb4DEYPrPsU89b/5e/LvEYPubLCIQX06NEtWpfwa/yA4h0FEgqVCK71OCUeTARdLLfbpg9PAXsfGsBBtOA0uHmKpyV0PZsqFl5lo5QaXWgRqNw4pTHiEYGa2M+KX0yMROpxsA9BDrCGNvAsG4GcuQdMt45eJx+nXsk3iyNbOY9k161wOry8/GqZCr1t4GBA/O3T0Nm7gSDl/89IBRHiU0nRk3CgU3knEmT4pZN51rrjI5TN2oGmCOMP44BKx7B8jINemP8ZRCK2Y5LNXAMrMlS0hSpwKw9TRGME+XHf5ekybEfPCInU7/BDBArCOMw5cIPvt+JRJUGqHj7JRu2rsd0P+JGBuanELTTVpwwO3/cnjFxNcTwMz95hquxud5pd+skIEfR6NJA+F2y6o1S3Fj4xpj/X9lBmK7OsDuChMUKMf+v36AXC4Fc4QxYwew/X0gM8/k5VKvN0BvcF9gfc8CJuGWuh4twgoQnJSBzK+nDP+3eLTsBahJSNL8DdD29kaUAFsDSU4vpVJp3FTETqdzAbwl1hHGySSCCTPX41RimlcmzthBrTCsV1Obss5cJ2hWXQupTIoiHUW+1nRYZkcn5kRbTzlIOQq5hBmimfRu2RwoeU4gl5rAFiI3Odpmb/NRK0zXu+zgKzZtWZWK/VvTxWZzSP/EK5HoEivcxsFQWIBzk8caVxmWmMT+g6thNlfMg/p1xYfv9DXSMEcYEzYAu247wnBXQ9myE/fslixRpf6FUgw2N5bgDChmk6Lw33MMqkqlg8JeVKmn8hRjHI0QIdgbiJynGWhiZ9AZoPhgaEeK50Q4wmDCvwmzt+HwGe8EcH67V1N8MshWV4UBpnlNLQID3Lcn5nkKrZ6iUEex4azEqC08di0BW1XDgsTP+2NHsrH6F+/0m9Xetns1PN9b3IWHPi8XyetXIOPoEeg1WbhYKMGK9CCoiiSoWq0SnuvWzqhLVuyoz+wI411mmi3epZI9Lt2zgElIUht9INtpdDJPMUsSGf59NCFFxc8TknI6AoZ9LqbCmj+V4X33zMAEAOMHtaXoJ0KLVpUJjJuzD3v+vSh+xtnJ0ffxaMwY0dHuCtO8pg6BAcK3LI4axCTai/4hRsBM3kww5DGK6o5vYx32S52pw9QxbEi8k6o2DMeoj2q5VVhqNnB29JsI0TP5M6Dj5Gg7dwmkpVZOsyOMtyg4joDyBhRq3d+Osbru3S2ZSp0LCmf+9ZM5CUY3qBWx3LREUy5RpbkKQOl0FAimvrksPAME08Q6wmD74DGz/8H2A/+5NdClM8U2r4VFE7rZBcwjtXQIkHsOGLbSLP7XBJhvdxD0fJiinhs+pVk5n41IBM/UFryQSHggvpxRooovpsgdFwjoD8MQri3ZIso/XYzm9a2FwDfUAFPxX/AaRYSCeCR/KW7fvQuYJE0RQF3vSQh2UQn3bsOaYXEJSZrPADrJBfP5BceCVx+4LO0r1hGG3gC8//Np/LXrmJjxdUhbv1YE9vzU22eAmbOPBRmieNCNFzvP8/jhaxVSL3vn4M9zBJN/bgSZgJsyplZ0KQ24oSZgq8vmE4V4+9hrkNIS8O5uPhbNOz+CprWpWRhd7Ahj9svMYM871rT38pbM/q2XvelHoeU4bpxBgt+Jjr8MAqfi80NXZEW/H1UEuOMIY/zCRPyxZr9XABMSJMP5pbelahYlsjNMi1p6402Pp8lyhWEhIBpVp2hdV1yp6nwgPAhYvzQF/+zOEpfZCfXgz6LRIMrxKsq0B5YcKsL6UxRFvBygelBdLjhZGMCx/RfTKWMCUGZzbAClvJEmtiGH97oEGLdhzBHGjL4UDyvLOmBUmn9AaamAay7GimAXgdErzG1RlX36k9el+PlgsPFtK9YRxtwtNzBl7havTZoLywYhuJRbSCNgauvBlAg9TQYDjyVHOeOWbOVxoEoo0Mn2JttpNZvOcmhfn0KTXoTr8TlITSnCrRSt8TMvV7gj79KVPDskCo+1tb/rZkLScavzcTlTARBrZUu+MB1coHNHZ8rQXEzvH4T+8yWY9DzQrj6QptFDzzRlPUj37JbM5pZMeCfZK5CNgsPt3PlbEny3LwSlHWEIqWLzcTWGfbFaCKkgml0zeyNaaa3QdqcAs+msSa2k+4OCmmYm2nyWQ98W9idabo4eqSla3EopMn6m3mRgKkJ6KlM6dV5Plz418ES3CjZE7Ar9w2X5UGXbv3bmC1NBAiqBEOf34zFhKlzLq40PuxK0i8qFutBzRdd7FjDx1zSDCKELxA2tmZoyyztqqc9tUdDlDAm+2hUCdxxhHIwrwOAJy5EvIkSCsz78Nq4rnmhpfU/BANOytgEydwQmpSpjQro/b68we+JNArzej4jjKouz0q+luDwGAzWCxnI1Kr0qPfpEZTzXv6pVwUzf6+MVBTiX6vi+hxoKQfUF4AJswWZZGF+UCUN2IsYMaINnbcVd4jp0m/qePcNcvJlTldcaUm5vVN3qnKNM1zUcJm4LhTuOMP65qMWYGWtxJcU76jGT3nwUrz1j7ZnCCBilAbLS96RucIFJtv88ZpLD/HMZSEgFXmkrrqANp2yjEYsroYRar6f44I3zxh9qNwnH8FHWNxBLj2ix6F85SKltmGV9lBrAF6RConCuh8fotCn7MSC2Fob3ELkPddDBexYwrL2JSZqtFPQpdwfHUT7mf+zjTWFwxxHG8St6zPhtCw6cZXcSnqdhLzTF2FethZcMMK2UBki9DBgmbz18mYAJbMUk5shiYBsxORzT5ucZ8PHbcUaC4OpBGDe55AbiShqP9/40gHLOt058UZbxXMPJnQuUKK+DLi8DEs0R/PJBLIIVwjULHPXgnt2SsQbHq7JeIJSYFIi8mNgeeeT6cFRQAItFOsL4L5li0do9WLrLriK06FZ2e7QO5v3PwugcgDcBo9MbsPT2CnMxFcYwdiNFuMhlKjcs/J23AMMEoONHJhj5JA2T44tvS2TTo5cX4kKqY5X9YuYacq9CEhzlMngmr8uGQasFLUpDPcUV/DCiKwrcNBwrrvueBsyKFVTSvG32aQraRPRMdJKBWaa+vSrcqNAo1hEGsyD8Y/1R/LzmjFea1EBZAbtn9rIqywiYSB5Siecey3U6A5YeN23JmCCPORIcK8IWhV0ps1Wpj8hzjyPmsDPN5P+ZNCWInMOXPz9g/PtgohZfbpEZ3SE5TxSGXBUkIa61vPnCDLCzFEuGrOMY1q02Xunq2VS6p7dkrKOJ17N7UAPP1PG9moatCoOBJ9go0hEGe+P+vC4e3yw84JX2VAoLxMmFL9sApnUkD4kXAKPV6bHsuNQIGDb5p28nmCwixmZSJnA5jeCZh1x3NzfpKi7M/xlFGRmo0qoNqnfohPAG1mcH1dUCfDP+sqkwjuCreY2Mf478swiJGa6V3Az518EFVgHhXMu0DYUZ4G8Dhuqy0Sg0EfM+8myHf88DhjEzIUmzAaA9XA+ZcIqR60KRp+XgjiOM3Sdu4s0vtyAkSIrgQCmCg6QIYZ+BMuPf7Dfzs9vP2bPi34ICZTh2szJ6NM41HuyrV7f2G8tWmNZRPCSc5yuMJWCYGcjHawm+7Sv8DPPfdSBfS9C5oWveHhg+GFqNyfRBEhgIeWgY2kz7AZysRDh5KT4fP0y5vZ0lwBdzGoO9FwbOK4S6KMDpCkP1eaD6fCNghCSDNhe8zmTsVznrMD59XIGa7Wx194SUVUxzT2/JihuZmJJThWoNZ0HgNY/EH28MRUY+B7GOMFibcrJzkJuXB3Z1zXHc7U9ivNlh0mX2aXpm/7ekLA57E6R44zHm5slWAs0A0ybKpDDoaWLhHJafMK0wLIm1ujx0iYD56WgrQO3ryuplSN6xzajkqM83+RCr1aUrol95A5zUJIT971QO5n2bZPybXYRNntsYvx4guLJrL1qkbsD2moOQHP6wlUskRkt5PfiCm5AEC/exa9DmgNcVoVL2KQy59RsqhAQg6tPvwAU5U1F0zvH7AjCsC4mqnE6UGpitvsfSJ0IIHb8lmNzIlkCsIwxPJzDLf10NrDtJMNyBjzDvAkaH5SdkbgOGOf5oVAN4sKawnl+YOwspf+81EzPIh9VvgCbvfoDAKlVx9JAai+ZcNz4PVBBE9W+M07uPo9/laeBgknSeC22ObbVeQ06QCRzselivuQhZBNveCX+JGAoyEZEThyE3fkIYNa00yh69UPdF6y2wsJ6ZqO6LLZl5pUlW9wHFMkrh6mTokgdf7QzG5UwpxDrCcFmwAAImPPztIMHorva3RkbA1GEhGoRPDkfVMj/EVoARaabM2vliCxj9QQtJ1GDAtU3rcGPXDmjVWWDfWWJbtHp9BiCwRScU6KQICJRg4VEp4g8ex4tXvrFSpGT0JxXNsKraIEgVFaHLuQ5ZSE1wAeLsEioRFZ5PnAVlTok5hiQwCG1+mAupwr1V5r4CDGNkgkrzEij93Znqi5CB/XafAhduySDWEYaQsl3RFGiB6Tsce4NkgGlbx+WtqatqjM9ZlOAVJ0tWmPeWEvzYX3gYcOY9cuKzsLE1EVK5oagQJ7/4DDlXS67gZTVqI6dlXxwNaIXrJ06j75UZkFhoHbNyK7Zqh2E3usHAlCupDgFhtSAJEmdsxsqJqZSHevmJaHPoC6vm1nvpNdTu7t6R+L4DjAk06t7M+tKuDb+QkQTw00EFTl2XQawjDIHFOyVj6h+frSeY4uC2it1MRVXgIeUIpBLTWcjdxMJArDgpN2/JPlpF8PlzwoPDjl9v0vZ1N2k1apz+ehJyVaZzS3HimUMKIoWUWrusqtDqUTR46308/bUKekghU1QBkbq+PbPXPkNuEog8DAOS5+ABzVEzSWj9GDSf+JVbXbovAcNs+oODFYSjsp8oqCm2gcj06z9BOHJNbjTZ7RDt/oQQWa2ZXEw0ZWY1yYzYGdCYuj5L7AJNwgBlvHRgj3mjnfvtx0YlS/Zcp9dj6wU5nmpiysccdLMYm5UECr3HruHwQ3/P+KPLzcWZ6VOQfdG5xWbVzl0R9fJgEI7DjO0Eu85rQSTuH1lbV45HbmYSzl1OR+2im4g0ZEJpyETdAC26zpnv1tDdt4AptulPNJ1rplMKUY6uFh8PxL5LARDrCMMtLtvJJAYw3qqTlcOCw7JYLUoBwWHZWWvBIYJxz3jeAiZxv7R0AZJ3bIetdT1B7T4voebTPc0VMbe2G08Wur26sII+6JyD5x4JQU6+FkfOp+DA2es4fO4GsvO1qFk5BE3qVEaTupWNn9G1K0AmILT1fQ8YxhhKqfTi9ewBoPQjSiFAxAasOh2AbfGBRr0qMY4wPJ86phLuFmBm7ibo2oSioYAL+uPXgKvpBIMe9VavgctnE5C7fyuyz58Bc2oRVKMWaj7XBxVbWGuELjxMsOxIAYjUtaqMo9Z90CkHz7WwXkoNPMXZy2k4ePYGDvx3HVdSTHIjBqCVn7verJQJwBQzjKnzJyRlPcZJuJ6UxwsAHEoP/joXgA3nAiHWEYa3ps7dAgyTeTwSRdHcuecDYzdXHCN4oBrwaH3v9Fqr55GWmY2ICNe3XWtOEvyy17MVZmRsLnq2dH4bdv5qBt6Ytg3d29TDOAFvhjIFmNLDGp+c1UxCycs8xTu3jcrMJDvi5VhxOghiHWF4Z+rcvRXGGBy2EvCYABB8sZHggycpqoa6f+lgya/MXC20RUUIDXV9gGJueb/d5tkZ5r0OOejd2nldm/+5gkkLDuOzQe3QrY1r2+0yDZjiwbp4PUNJeelKSqlZSX3/ZRkWHVNArCMMbwFm/AaC8c9Qt65rPWkDCw7Lggw9YVLhcprWnCCoH5qKGmHUaC4tl8sgl0kgl7FPqWhdt6upuQiWc1AoXN96MSd849ez62/31YPeeSwHL7Z1DpixvxzA7hNJWP9lL1RmjgtcJL8ADOOBSkWDCqiGaQoYlYn+TZJh/hEF3HGE4YqpQp7/sC0PrzRPhYxPg9yQjmCkoTA/HUV5aZDq0wBZBQQ0my6kKFE028/BGODpOYHBYfPy8qDT6aDT6Y2flolpUxeDhznscAWkfxKzEFNDAbncteIk8xIzYinxSBj1VrtcvPSo4y0Zs0Z96qPVqFpBgcXjnhXEx/saMCZfZNmTQCjTmZCAEC0oUglPU3iOnDEYtCcb16nCrDaN6ZxKU1HK0xOEIOrMDSlmHnDPEYZLzhoKAW0aivLSQXRpCKRp4HTpKMxNAy1KN36XE+cRAHjKIb/pckhk7h967bXz70STao47wWHZ9bZebwJOMYDY38Zrb4vEtKwZeAKMq5IJSDKZFOuPpqFr8yqCNBjYDd3AXwwgnPu+2Qa3zccrjzleNY7G3cR7P+7G8+2jMWaAMH8r9zVg4pKynudA1jmawExnjKf8fwRkAwF+j46MuJSoyupEKdkdnyoh0/e65wjDUX1c3MdA3hUEEO+YL6fU+BwRNUQa07tAM7v5OpNM8LoXg8PqDXrotHrojUDSQafXgXmrKZ3i0uV4vKkwiT2TJ/WcqYWBBLp8PzkieK1NIV5r71iO8/2qE1i2O8542GeHfiHpvgbMRVX2RzzlpwnpKCGEOa76i5dynxCeTriaTvpP2RnqliMMhwC9MBaBBaeFNEcQTU7FvpDWeU0QrVCiCynA7jjHip9Cy3FFxxz/mVYi0//sPD2u5wWgXUOBSmkAXvtVj7R819s3R215ta0Orz/m2FVVnwkbkJyWa7xOZtfKQtJ9DZiEpKzXAfKbkI6W0JAiQrDyZjZ5adyWUM4dRxiO6qOqRVCkLRPXHCfUt2gjhLXw7jmGBYdl18Uf+Tg47K4LBCz0uZh6P1oJnL/p/qH/5dYGvNnBfv5rN7PRb9JGVAoLwoavrC1enQ3gfQ2YC1ey6kil3CV2lhE7S7MKuMIxf4UGuuMIw1FdhszjCLk6XmxTHNLrqRT5TVdAJnNfPaR04cbgsPsIJjzrmbqL2E4evgxsPy+uXubM7+Vfmbss9661X2lDMdhuABRgyc4LmLnmJGKbKfHlW8KNyu5rwLBBS0zSbKBuWGOyWCoj1rrnCMPRZNEX5SLk3ACmVih2PjmkV9WYiso1RHrec1I7i1HJ5Ct3Kjiso6rPXgeY9P6bPsKB2uSRWKSlZbjNy3FjhuOTD5kIzja9891OnEhMxVs9muHVbsL5e98DJu5ydkNOxh934enfhmPsUDl0ZRgCZUS0IwyHWzJmqPPfcATorrk9yKUzZld5DTKlKUCQNxLr98jlJhV/X6ZrmcBXmwnmDBReb2R0CxQWmiOaiG5uj+5dsOyPH23yMd2ybmNWg6nJfDv8cbRpLDzO6H0PGMaN2zYyi8Q6/Ru+Ogw6A8FfIh1hOBs5evE7KLJ3ih5cRxluSR5FWLNxXiuPFeRJ6D53G5KWC3y4gmDhG8IAw7Ssa9Vlpsrup8jaNXHh+A6bAnYcu4bPfjto/H3z1D4IZ5JcgalMAIb1NVGlHkwpmQ1QwRf3H6wPRU6Re44wHPHXcGMTQm7+LJD9rsnU+soIaO2ux1z75Yu163fdStcUuYXA6wsIVg4VBpjMLDUeaOrgAOK6OjNFcvwhVCiluzbh90PYdvQqqlcMxuovSjSkhRRbZgDDOnsxOaczpYaFlEKQp4Sxm0KQlidxyxGGI+Zqs+IRfuUDIbwXTJMWsxghIc79CAsu7C6Ndg0lAAAdVklEQVStMEws88Jsgg3DhQEmSXUdLdt55hLJuIKs/g2x7UvcdrJtWPcxq40q/h2bKfGViAM/K69MAYZ16NKlzHCDlHwBwr0FUKdr7efbQpCs8a4jjMKCfITHDQRH3d97l578qmqTUblWczGYcErLzjDT+/hej63HLA5r32YOCl135dyFeHTuahtsynVOa4qvPv8II4aVyLJOXUzFsG9NW+bXuz+EISK9lJc5wBSz69KNzEheLxlFQVnEIrvmUlN3B+NiuncdYWi1OsjjP0KQznvxIDVVh0Bem1kreCcZg8N2pwhzX4juVkN6zebwx+u8oHr/OXoCPXrZBpsSW/GAvj3wy6yvzdl+WnsKi3aYnKFPHtIBnZu79qBpWWeZBUxxJ69coYE6ae4zlOqfIyBPM59uxc++36/AuZvedYTBJNz6+OkIL3AVn1b40N8K6oawRu8Jz+CCcvImgiEdKKoLF7p7pe4B8zl8148XVO+uPQcwYNAwj+tt0iga/+4t0Z4a8MUms9HY0vE9ECnUHc7tlpR5wFhyfA+l0lqq7L4A/QlAhTmHgnA8We51Rxh5FxejcvZSjwe7uIAk/cOo0nqK18qbsYPghebUGO7Dl+n1Pzh89iwvqN71G7fhzbc/9Lh5LALCzr+PQVMkR2w0Na4u566m49J1tVElRqyDEb8CTDH3LyblPMhTw67fjwZVPXTV+44wspP2oVq6IBU3QRPiprYWwtvOE0QrhGj2PoKO0dSoR+fL9O5SDm/H8oLq/XP5Gowc7R2tic9/XIlNyU2wY5RH1gJGVvklYFjHL6k0Ty85EbhxV6KceNsRRuatS6h1fYTX5mK+IQR5TZcbDb+8kVhw2MY1KFrV8UZpwsv4ZC3BCw8LC0o7/7fF+HRCydnDWS1FOSmQh1S363aX5XtlxGTEBfbCxveAIMFCB/s1+i1gGDsGL9Cvvpgm6eVtRxgZGZmomTQYHNUKn01OKHlIcEG5AfWE+eB2WefKY0DVMCDWO0G5XNZXTMDOTu3qUzxuinDhNH0/cx6+nGYrpS+diflxLkhPgFRRGfIQ+wzq9OxA5DUei5VDgYruObw0V+vXgOn8LR3L85jibUcY6iw1KiV9CLnhpqt5Ieg5DxkOV16PRyKFyTBcFbrxDPNZJj44rKtyXT1nvsYaVqeC4k1OmfoDfpjl2ncYb9CiMOOS0edyUOVoEGM4cuvUuGkrBHdbgIVvALWs4++6arLNc78GTOx0yq6efvS2I4zs7ByEJY1HkNYUactZ4kkg9FwE9JIKMEgijH8bjN/Z36bftCQcudLaeKC6q9KEPd8dB2Tliw8OK6x0x1Q/7SWoGkrRt4XrksZN/Brzfl3skpB59S9IN13hy0KrQxZkK+ANCQ1Do7ePYO5AoIF1DFqX5Zcm8G/AfENfB8Fv3naEkZubi6CkbxCou2yc9CZARJgBwcCRVlgZV3KC0aSmAhwnQYBcYowHI5FIwIN9MjPfkt/shcUQPdq3Mxy5DLDwfQNFBod1t77ifMyxuVxCBdX7wZgJWLzUdXh3Zh7NtmSgPCQBIQgIt+8/qtmw3fj5zep4yDoGregu+TVgOk2nTNl8pbcdYeTnFyA9U2MMDhQYIIFcwoGTSGCgnHHLECTnIJVIMG2H1BjywtcCRBYc9shlgrdEBocVPbtKZVjyDwGLLyqk3mHvjsGa9ZtdV0k4FGZdBa/NM/JbUcX+wSy692z8PDoWAjwpOa3TvwEzjXajHLa0b0DxSXfvnA9cj3AJxfe7TG5bq4aKyeU5bWIqsOkswcguvu3zyuPE6IBDSL2DBr+Hrdv3uOxshVqNkZqwH7q8NCNtYKUG4CS2V2G1OozE7ClvoZOHFx3+DZjptD0F/m4RRTHpOd9OHja4c/cRdHuQGh3r+TKxScuMuXz9kmDRmM/dgKB6+wwYgv0HjrhkS6+Bb2PlbzNQpDbZILEtGdualU4VH3gaX0/92ii89HZSVpY7NQllzvOLfYG7W7d7Nqe3a/NGA1hR7WfQZhKKU0yAN62396wkhTKFyUPa1qVo6KXDvNB62YH/2x0EXzzv/cnjrA07zhPsT4SgepkeGdMnc5V++nE6Phz/PTITmEIlhSykOmQK24M/W3mmzV2Lpxp7f5z9BjCPT6P1DRwuetMRhqsBtnzOnFHEVAMeVvp24hbpmata4lHcFzH9LKZl8TJXn4Cgep98+kWcPmtSknSWVi/7BZNmrsc/G2eC1xVAqqgEeYjtVRjhpPji1wN49qE7x+uYyAi7C4E3XvA+XWFU6Vo1ABsP2MzJwvDlMnjTEYarAbZ8zrYoVUKBR+vduUF01J67YUR2OhmYs49g9suu+9uhy/OIT2DyFedpz/bVWLXtFL77/F3o8zMhCQxHQJh9nZ/RU5diYJc7p95QZgCTnKHLppTaHK3Zm3bwYhkqKIDFg72/VLsabLZFYbYhnRu6nkCuyhL7/G4AJuEWwKT9QsyUWz3WDdeSkl1268zR3ThwLgtDBzyFIo0KnDwYgRH2VfYrP/jCzKTdX3pPZ8ll60wE990Kk5yhi6OU2kSaZx5OBy2UIkDqPUcYAnloJDtwkSC7AHj6Dm4THK4wIoPDiumXI1pVJjBqBcGqYa5fEA+16IxbqaabL2cp+dJJ3MqRoGXL1si7cRKcNAiBFe2vIopqDZemn133kqsyvf38fgTMJkops4WxSUOWSFGoI9joRUcYQhl+SgUkZZK7EtBp3DpgsjhzdqHdckiXlQcMWcReTq4Bw+z5mV2/sxQcrMCVuH+NoQof7DwESf/+aTz4B1WyH8tDHl7zhDpxlwA9A4+7alXAfQcYVYb2V1C8YY8N7y6XQl1AsGoojyD3vZK6zWHm9siDmK9u13u3Mgrtb71GbZCbm+e0mbVq1cDJIyavMK99OAvrfp0IfVEOFJWj7earUKUG9mxZ45WuOzqv2Cv8vgNMcqZuCuXpWHudGb1GipvZxKuOMLwyIn5eSGSDR8AiQDtLDzZ+ALu3rTKSzPrzAMa//xK0OSlQVLHZfd8uhuDQ/p1QKDyPiFCmAaNK17KD3g/2mP/ZXxJcyeAw/xUeNT3UZPXzOe7V7tes2wx6vcFpme3btcaa5SbX2gfP56Dnk62NipiKqo7tB1at+BMPPdjE47a6kr1YVnD/rTAZ+r6U8ivscWnyVgnibnL4sT+P+l6yN/F4NMoLQLXIh2zizpRmy9PduuCP+ab3YE4h8OCjzyMzfrvDMwyjm/rVZPR8vofHHC7TgLmRpetoMFC7Ximm75TgVDJn1G96srHrw6jHnC4vQBAHqipd+zvu/2JP/Dhjsrm8zv0n4sSWHx3KYRjh0DcH44NRnt8sl2nApGTROnqD7oq9kZq1T4IjV0Q7/xc06OVE7nPg6DS2bXL+AqvW4hVEdvnEXEna2bW4uGY4pEGO99ZPPv4YZs3y3DNpmQYM42hyujaBAjbXJxvOcFhxggHGI+UD92dGeU67HDg6/SGAd36GqfHoMNTuULJaFGZexem5T4CTOL7ufCCmAf7dv0EQ11MyrWN6WmYq84C5lqEdyVF8J4hTlkQc+URZUSbMG4PowsVlSEhSO3zlBtm5+alR0UOPD+KaZ5fa0aQryM+3oi/d/ocfaYOCQudxQCeOHYUPRrxpLocZk8U0i8Wt1HSHLQ+Qy3Hj0jFjzE1Xya8Bw4IuJWfoFgJ42RWjip8TQlbVqijtbwz3dw8kfwJM23YdkaXWOOX6tMljMWzIQCuawW9/hJVrNznNt37Fr+jc8VGXI+rXgCnmjipT353w/Es80IIALDAIM56QMFBQSpmkLAUEJzmeX1qrSuBfLrnqQwJ/AkyXJ7sh+bo5ALZdLs+cPgmvDuxj9ezPFesxbETJucZexrfeeAnTv3QdQqTMAyY5TdeZEspcjdjXjfDm5Ka4REDerF1F5tos0Ev1+hNger7QGxfiLzrl3PyfpqJfb+sr4vSMTDR4qCOYy15HSVmrJs4ddx3Dp8wDRpWhvQQKYfGjvTGJCS4rK8nvPDhvt9WfADPwlUE4etx5ROpFv/6A55950mYkn+zxMv45etLpCB/esw5NGjm3Vy77gEnX+lyQIua2xFOM+hNghg8fjp17Djhl2aolc9C1i21A1x9//h3jJn3jNO+EsaPwocWFgT3isg+Y8hXGatzv51uyTz75GGvWb3E66Teu+h0dLYIlFRNfuapCs7bOgzG1a9MCW9ezKI+OU5kHTPkZxnrw72fAfP3VFPy+yK42k7mTOzf+idYt7cfB7PBkH6cmzsz/29ULhxAe5thlT5kHjOV0SUzKfp6CLwkMAnIjJjLcyo3bRZV6Kk8xxpyPIjsmqiQgYkKS5jpAzfauBFzP6Miw9Z5urdzN709bsjmzZ+K7mb84ZdWBnavR9MFGdmm+/XE+Jn7pXOy2cP536NnD8UrkX4BRaSZQSieauUnIphhl+LNWoFJpFlFKSy7yCYmLUYabRyBBpdkISp8pzkMImRitDP/c3QnvaT5/AsyyJQswYcq3Tll29O+NaBht/45HyLZs0Et9MOvbSQ7r8DfArKOUPm/BjSkxkRFWl++JKvUuSvF4CSCwO1oZ0aX4e0KSmmn2fWoBmPXRynAf2ymW9MCfALNt8zqMGD3BKWDOHt2BKKVj36+du/XD8VNnHZZRu2YNnD+xqxwwjAOJKvU1SlHiDYGgT4wywspZb8I19QUQlBhPULokJqqCecVJUKl7g8JkocS0zQiSopURUZ6uFO7m9yfA/HtoL14Z8r5TViWe2Y9qVR2HUftp7kJ84iLGjLNVqsysMKcTk2s3i67t0KXIheTsSlJK0yilJRqVFPVjoiIuW59z1Ew5q8T9EsE3McoI85km4Zq6HgjMvn4IIVRPSJVGtcMy3J30nuTzJ8AkXjiJZ3uXRD+2xzdV/BGEhzsO1JlyMxWNHnncqRDzmymfYuhg+9pS3gKMq/kqZE54pBp85sy1CjRIEmww2BfnKoKC23NEsrzk/IKc/PycRjzTzrudQoLCAi3BwH6mlH6eV5Bjjo3HEUIUitALoDBfpfDU0C+/IM+5gEAIB9ygCVGEXXeUrawpX2bcvIx2jzuPHJ167SQCA5yHZevR9w3s+9uxy9mnn+qMZQtYyFPb5Awwaek3BcUBkEg4jhQY8po2jcpyY8gtprAnuV3kTVCpPwKFOcgkIdgbrYzobJntokrTgKfUKjY4B/RvEBlRAjTT1m4Ppehk0fIxMcoI51KxO9Q3f1phaFEmHmhuNWQ2XNWknHMYpq+YePGytXhnpPkYalNGSEgwkuIOQyq11V721grjjeng0QrjqgGJKs0SSqmF/ynyfUxk+CjLfAlJWR0BYmWFKZVyHevVDPvbmk7zHUBHFv9GCPkzWhkuWOPZVVvFPPcnwFQI5lE1qrlD9jA1/bSkUy7Zl52TiwYPdkBhUZFD2u0blqBta9u6/AcwSZrzFNR8PcxR8mqDqHCm2m9O8Uma/gTUKjY4R0h0A2W4lcbfxWuaQTyhC8yAAbkQHRne2OVI3QECfwIME7pWr9sC+QUFdjkZFhqK5MR/BHH5taEfOtUa+GT0u/hk9Ds2ZfkFYG7coIo8gyabUpiDHUqItGl9ZYjV/WJikmYUBbW66A+RhgfXrEmsLJsuqXIfMlD9mZIVBoZgSXhYaTpBI+chkb8BpknLJ6BKvmGXa1WrVMbFs/sFcXT7rv3o8/Iwh7SO1GT8AjCJydmPUp4/ZMGdwmhleCghRG+11VKpp4HiI4vfNDGRETbG4JRSaaJKk8Ni9ZhBw3HtomuHHRY0Wl4kEgsYL1bt9aJcWVyyCnv1HYBz5+x78K9Zswb27NwqqF16gwGxnZ9Eerr9y01mffnv4QNQKIIElceIfKl0y+q7Y2eY+CTNOwS05NqDkKMxyvDWpTmRqNIsppRanEXIhRgHW60ElYb5I21VXAYFGd4wMtxzTwqCh8dE6G+AGfzW2zhwwPLdV8KwunXqYOtm4VpKX0+bjt//cKxs+cu8n9Gh/WOCR6TMACZRlT2PUr7E0Jtw82KUYUNLcyL+mno3ISi5hiFkV4wy/Al7HEtQZc8F5d8q2ZZx86OVYebvgrnsIaG/Aeaj/43Fhr/smxs3bBiDDWtXCubohbg49OzVzyH9kMGv46MPzXc7LsstO4BJ0hyloC3Nkxt4JzoyYnZpDiRcU8eBwOxTlFK6uGFUhVfscSoxSf02BcwrCgE5Fh0Zbl5xXHLXSwRiAXM/ayuztn88/mv8PM/qrsbMyRbNH8KeLVYSAJdcZnKd/87H26Vr3uxB7NtmrR1d5s8w7LxxUZWdQ0Etzhvk0eja4TaSq4Qko4cFs5iYI9y0Bsqw/9kFTLKmLeWp+cxCQAobKMNszkUuR8xDAn8DzLTv5mDy1B/tcq1d25bYus4+mByxedacBRg7cardxxzH4VrcYSt1/zIPmMuqzKZ6ylnatRpCpPlhNWvWtLr5unmTBmdrNbmWnCOUjIqOCv/eHjdv3LihyNUrspmzjOLnUsI3q6esaL498xALgrL7G2B+W7gcI8fYVw5/PPYxrFvO3DcIT2npGWj4cGfo9Vb3P+YCmMSfSf6LU5kHTPy17FcJ4f8o2Y6R89GR4Taepy+pNNEGShOsAYN+0VERDi2WEpM05yioWf5CKfdaw6gws3xG+LC5T+lvgNmwaQcGDravgNm9a2csX2hfpcUZh/u/+i42b9ttl2T40Ffx1eclm4wyD5jEJM131FoqvyRaGW7tuMqo7pIVSynZa8k1Cr5jw8iKVlJ+y+elb9UIyPfRpbQH3IeCsJz+BphDR46jW0+7x0qj4RczABObNm7ZhZdef89uNmaMxozS/GaFSVSp91KKWAtufBQTGTG9NHcuXtf05w3WUn4CNIiOjHAYhTQhST0agFmHjBDsi1ZGlOiYiR05N+j9DTDxiZfRqoOVzZ+Za/369MD8WfbPI85Yq9Pp0fDhTmDumEondo5hZssRtzWgy/QKw1T5L6o0WZbq+pTiiYZRETYWQolJ2R9Q8DMsGRakDFcoCbGvhwEg/pq6CyEwO7MigKaBMrwCU/l3Y+67lcXfAMNC9tVp1M4ur159uQ9mznBsLemMwWMnTMOsueaduxXp0j9m4ZluJpvCMg2YxCR1fQqY9cDYRA4MC6usDCc2r5KEJDVbKdiKUZzUMZERFZwxWaXSVCwE0i1tbFytSm6hwkkmR4Cxp9rPirnfr5WZM75KymYwGGw99Qr1XmmPnefjEtG2k6UxbgmV5TmmbAMmWd2H8jBLsgjBtWhlhN1wuglJmiWAlTbz+Rg7lwOlmZ2oUl+lFGaLS8Khb3TtCLNFprcBUro8fwMM6z/zYpmaZutc/L23X8eUCZaaTeK437l7Pxw/aWu+3Oyhxvh7h2lIyzZgktRTKGCOY0kI1kUrI+xaICUkqZl715LzB8WumKgIu1J+y2FIVKnXUgqzTT8BvoyOjHBsbCFuDF1SiwWMywLvIoEQXTLWvB49+yAhwcpsydjqYUOHYNT79g/vQrq1bPkqTPj8CxtSdo759/DfCA1lLrcdp/te0p+g0myCRWhx5jGmYVQFu5f4CSpNHCg1S/kJIYuileGDXDE6/lrWBOY5xkxHyOYYZbjZq4yr/J4+90fAvPbGWzh8xFaNf8S772D4OzYaT4JZnJubi/Ydu9gNqTF39kx0irX1qGlZuM8Bc+PGZa86k8jVVzwGwOwRQQLD4CCpxq5LkFxDxXOgCC5mAOEwO5jLdHnlUqAP72KA5FcLxqWHSDPNajiCR8tNwlx9xav2sjo6w9ymTeCobjTR3bpjQlaDvLbddjnrptAV5oPRH2PTZlsPmLVrVv1q7+bf57rJSmO2Zu36TM3LLzArmAVWqo+qD/dD96c6Y1T3CiASx/F1JNpku9t9T9rjLO8d01a+Uw0uL/fucCCoSqPvCYGN9JJS8n5B2nn7ejMCmxpUpUl7TsL9HRHdBVWbD0CYspXRNZA+Lz394IQq91SI4HLACBxUfydTVGs8FpROseUDHZafGufRCtNxOh1nyM+YKFVUMqs86fLSaW7y0U1n5j/teahlLw5eOWC8yMyyXJSiWqMhoLBRGiOUvpaXFueRalLsdPongAGMfwUZl6G4sARtcw4e/XrXNhv7qbvN43sCMGcSUyy1Asw8aRpdw+gcw9FzMcwrLktMnnLaEg4oqjV8DpSzsRSjPAYUpF9Y5gmvOs2gbXke069tm8A9l7enaYNQWXCAhKMNK4ZFdl6yxqHfO0/qdDfvPQEYdxtfns93HIj9xpBm0BVUpgYteH0ReL0W1FAEWXDl/w5+VvEhIS1JSbli98VYnLdGjbr7furWZVGYXDawYlAAgmTSMY8vXn1XXGk56k+ZBYw3ViV7TLvXVipXk1DIRHZGwyYxex47nf4LwJ6xXuK+0cR5CDERjdjzWs8IXsvdvJRTGDDt7HXt9QLtmIJbF34QUcQdJS2zgLmjXPPHwmu2UCj0+SxYr1XiCN8l91a8fT19kXwqBv9Xg975fuHZaw9reZN6YLWqlfYe2rGoRO4motxiwIvI4pS0HDDe4qSflDPrqS5aA6UyAtAR23dz3u52gyffH3vj9HYWrcE0Nyl0lCOjC255dnXtrXaWA8ZbnPSTcna/3PsyBa0LILPLkjWVvN3tyk2emp+fljTEVC5N43j0zU2Ps/KM6u06xZRXDhgx3Cqnxe6Xe12gYKFJSF6XJaudK3qJ5xdRVG3ETNvZJcI5nqPPFt6ME629IL5a4TnKNGAopfLkbIRIDAgBj2BQnUJPiUIqQRD7JNSgAIgCBIGUkkCOIIAHH0gIFwBKAkH5QEogJwRyUCKn4OWEcDJCIQeBnFLIACoFAfOgLQX7TnH7O5UCHAdQCQjhQKkEIKbvAGf8m4DAFAqEEGIcCnLbbMH4m3FDAtDbtj70dtADCmb7w/6B8gB4gBiMfxNiAGW/se8sogLRg0IPYvyvA2D6DqIn7DuFlhJoKeV1BJwWhGophZZQaEG4QhBaSClfxIEr/HbR1mZrli2unp/8X6tcHW92bhJdv/6cLRvW/AIiyweHPIMEubXDkEsI0QqfhibK4KqNXqEA86hxOF9X1B1Zl5mDlHsq3dOASU2lIQYZKuv0usrgSCUJIRUBvgLlSQVKEMGBhPOgEaB8OEDCKBBGYAyJEUKBEAI2ocuTOxw4dfoMzp0/j/j4RJw5+x/i4uJZGBKbotq0boWFf9jGwKSAjgDMwUkuBXIIkA3QbBBOw4GoeVANoVATjmYBXJaB0syWrR79SSaX33rhuef7zpr2P/u+ad3pjBfz3BXAUEq5lCzUNhj0dQmhUQBRArQWBalBCGoAtBqlqAZAuM9QLzKlvCjgzaHDceCgydslc+Eqk8nNoSiYIRn7r9PpUCEiAn/vMxvAepN1BYTgFkBuUYoUApoCEBYcWEUpuSaRSK/UqIBkQghbZX2W7jhgKKWylCx9WwOPdoTQhylIE0IRbemzzGe9La+oTHGA+aWjBIkE9Byl5JSEw6EaFaRHCCFs+3lH0h0FTHK6bjIFhoNtm8pTOQd8wgGiJsBPtSvLrAIPe6vqOw8YguGg5YDx1oCVl+OCA4SoCb1PAcO6Zt6SAe0IpQ9TigcBRANwHhSxfGaUc8A1B1g4s0RC8B8l5JQE9/mWzFF/iw/9hOjrGkCiYKDmQz9AaxKCqpSSagAtP/S7njRllIIUEELZgT+VgqZwIDeMh34JUUlAr1FaRg/9noxm8bUy1esq6+1cK5vORiS8/FrZEy7fmbzOrpUBqgGImhCoCUqulaU8zSBSWbpEh/SqVYmVz+0700rxpd7RM4z45ng3hz3BJSREoadQSDkSZKBQgPIKUAeCS8IHMiElE16aBZeAnICTWQouCYHUJMQ0Ci9vCy6JlIJKOJOAkqNMcGkrwCTMFJdYCCwtBZilBZbsO5NWwiQPoaUFlsQouGQSS8oTkzCzRHAJGIWVtLTgEryOAtpiwSUTWjJhJqi14JKnKCKEFoKgEITLlxDk63laICXIh4Hme0Nw6d3RvzOl/R8AdGoXzom1qQAAAABJRU5ErkJggg=="},62522:function(Xt){"use strict";Xt.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAUYAAABYCAYAAACJfF6vAAAAAXNSR0IArs4c6QAAIABJREFUeF7sXQe4FcXZfmd2T7n90jtYsFGModkVUGNJ7BVTVIxdI5ii/iYmxkRjEhV7ohF7wQaxBqOIxgqCQSkWUKRIv72csjvzP9/M7p7ZPefce8EGhOOD95wt0+ed9yvzDcO2z7YW2NYCm00LNL19cQ/H4j/nEt+vKK38LhtyVWazKdz/UEHY/1Bdt1V1Wwts1i3QMGviGRLyJgAVVFCb4YiykZNe2KwLvZUWbhswbqUdu61aW1YL1L0z4TrG8Cuz1IyxOytH3njOllWTraO024Bx6+jHbbXYglugcfaEC4TErZEqNAN4q2rUpEO24KptsUXfBoxbbNdtK/jW0AINsyfsC2CGlIgzBgGJaRzi9jKeeo2NuDO7NdRxS6zDNmDcEnttW5k32xYYP3XZFADfA6QFsKWTj+2/e7HCyld+azeU1S8AsDOAjxnEGZWjbn7z26rc+H8u/yWEPMti9kV3HdN7+rdVjs0h323AuDn0wrYybDUtMH7a8lsh5QW6Qqxl8rH9yopVrmHWhLMl8HcAL1UK93i21y0N30ZD/Hj66rJYKjMZAid5+T82+dj+J38bZdlc8twGjJtLT2wrx1bRAmc+tWy8ZLhb4yJWTz6mf69CFSO2WF9av5QxLG1w2CH99rmx9dtogDP/uXygFHIqgCG6zOyhxkzf0x4/ibnfRnk2lzy3WGBsmDXhTSkxFAxSAksB9jFneIFZztMVw25Zt7k08Jcpx7p9d6lAPD5BMHkKY/K33V9e8MSXSe+berf+zYmdEZO3VpZUnf6/5od35tTloyTkO15bz5t8bP89CrV7/bsTvg+B+2yOoWUjJq36pvomms/4aStugxTne6A4td/RfU+4ijHxbZVnc8l3SwbGP0ng0gIN6TDgXhv896Wjbli+uTT0xpZj7ZihR0gmJwPoocmH/E33GQv+sLHpfBvP18+eOBFS3sAYplWOnHTst1GGbyvPs5/5oqvjOGphZmBP3X1sv+MLAuOsCVM4w2sVIyfd9m2V1c93/D+XHQWBS7Kl8e8/cGhPsob/z3+2WGCsnz3hcEg8X7QHpUwxxi6uHDXpzi2tl2tG7z4ky8UcAHG/7BJ4vueM+d/fEupSN2viSwzyIAbMqxw1qSBj2hLqsallPGPqshYGlDCGP959TP9fR9ORn1yUaKy1llQ4bCf2LYnQm1q3/5X3tlhgbPrg4h6ilR0NoBJgO0vIsQB2zBuEUl5WvedN121JHbruoKHXCSlNZ986Bjat+4wPztgS6tEwa8JqSUyXyb9VjbzpvC2hzF9lGcdPXbYSQG8p+ZH3HNf32WjaTbMvPsQFP7xq5I2XfJX5bkvrq2uBLRYYC4on7168JxPsCgkcGdxnEFzKMRWjbnrtq2u2rzeltWOHPCKBU1QuDNNjrOXkzi99Wv/15vrVpV4/awL539mc48qKEZOu/upS3jJSGj91+ceA3D4Vk90f/sGA2mip62dPuF5IPNBp1KT/bhk1+t8r5VYFjH73Ncye8CspEbBECTxVPWpSQV3P5tjla8cOeVMCezNgJUtnd+v2xkeNm2M5i5WpbtaEJgaUMc4urxxx45+2pLJ/FWU9Y+qyxUz5MPY7uFB6DbMn/LNy5CSSdrZ9NtMW2CqBUT52otWwXZ80AMtr9wVVoyZpd4TN/LNu/916iZhFRiMLjP22x8sf/H4zL3Je8RpmT3xfSjlUQl5fPeqmX2xp5f+y5R0/bdkqJnDF3cf1J+NZ6FP3/mWdrHT69xUjb7zoy+az7f2vrwW2SmCsfeOCATxmf0ZOWV7TPV01avNfoSXA144d8iSAY6jcUoq9er6y0Hf9+PpGwVeccv27E2+DkOcD7M2qUTfSlrf/mc/oV6S9Q92KVY1Z9H/8pH55vom170w8llbryj1vJN/BbZ/NtAW2SmBsmD3xH1LKM/02t5j8XvnIm/69mfaBKtYXhwwZYbns94A83Ctn4/L6RJcRc+Zscftl62dPHAUp/8gku/1/DQDGP7XiO5KJI+85tn9B16r6WRNulen0b6r3vyNP97g5j89vs2xrxgw5jjGc0W3G/KMYIL+Jsmx1wNjwzoS9JZNvBGyR4f6qkZNO+yYa88vksWbskPcBDDXSeKrHjPlbjF70y9R9a3p3/NSlxyezpdNvP6l7U6F61c+e+EjVyBvHbWqdT3/mi10t1zlTSowF5E4ASwJYx4A5kvEn7L59HrlzBNviFtNi7bF27ODnJZhPFu5Yt1pMGLJw4dcevHfrA8bZE5+QUvqAslzEsHun706q29SB+E29t3bMkMslwzWUH62KEjisx4z5L37d+cvHYKEbZYlyoMJuqXFjpby8NCvczjEeY04qYYML2+ash+uyOMAtBlYGLsshEQNYDC6LcUtWA7Ic4EwIxjizOJjkAsxidJGJCsncwVLCBhhnknFIFWiBQzAOFuiDAbrHyKddswPJpNADlUkwSbsyBJikLWt0X0gmXMaRhbBWMmmtEKBnJHkjuABzIaUEE6SpqBdSNoOLLIfMgCHrZuM1YI4DLh3Eso4U1hqb7nGRzXJHCJltTJSiEYl0Fk5jFp+iBWdDMIaCW+bOfnpl/zuP6rOsUL81vTtxqCvkiVWjJl25Kf3q7cMm9yde7H0GLHGZnHjvMQOe2ZQ8Nrd31o4dulJC9vbLxYAVYHig+8vz/+/rLOtWBYzyldOTDWXVtBE/Ro3GGT+hYuQNpLPb7D9LDt6hqlyUUrTmnTjDn7q9PP/6YoWWr8BGBVhtLUqTtSXlJYmycgi7Ck4sASa7u+lYGWDFmO30hcNLYKE7wBOMsTgYejLJ4hDclpIiRYsqSG4ziVJIZlFUGElgxRnBkCLeGp0UYOuP1MidGzxaujGvqVdzjxf5bqCftyKY+UTTMB7JS89/1pezKO/Q+8wvT2TI0yoU3DMKHVSU6iUlY3AkAS1nrWDCYWA1krEWMAWiDgTWSMgUlzIlpFwvuJuyZXwFIFKIpzOOK1en+x1xmpVe+4ps/M+MkuSGJnRCC4YXB9lo/585bfmVUsqrAKxnDA8I4AMmmC0hhzOGEwB00esH9Zz8e1m834RbjmBkhNxiP6vHDrmCAaZaYi1n1v7dXp738ddZqa0KGGvfmrAdt/CZbjBWXzlyRRfGHt88N8MT9wFY7Us7VKRSg7O9GlsqYGdLIXgP1121I+OpXnDRHdyuZpbsxJjVSQpWCclKmJQ9pFBglpRSJomAqWmv0MDXwtDcMJAp+BGFq2KQYsJQ9Huh3/41Dzl1HxSARq93FHCZMFbovWLXjCnhI6AHZBpqc5/QbR/sdENFytce7Ppp5upEeekSRurhP+Lb/ug3Y2jpNxKly94hMktAm5IMKTCWAU9+zJCth4y3CCHXcJlOwyIWm21yXb4STDaCZ1rSPLH2Bvu2C/YQ//7znuL6Fd0WoIVdpTKXJz42P15hV10Mhis1c1f1md0Fy8b9fPG+q+OVxNSBRhc8ZsHiApylwUorIRprIMuTiv8z4cKVaV0hYUGIVkiXQ4hmSLcesu/2EIsBpDdApnpDDv8CEoMhscBodl0mfwR8KZ0gzZF1Ywf/SoKRzSDOwY/rNuP9uUYXfy1ftypglO9eWtUgUrXekrmyetSkvl9FqylxE4ivWwfLcsFdC6LbWjUog832xOLqllaXV9t2SUZaXTi3ezAZJ5GzJ3N5FzDeFRI9mc07A6ySwA2CE0urUF5FUiQhpS0J49RQ9yjYV1GB/4U08hFws6p1troPRLIcidUfdbxcHqAGOA6pYqZIiQyYbAVjDYDbCMbXCVc0AW7dYj4ocV/ZFUeu4X1I90gagvoRLf+87uQNl7/tSrdFZLJpIeBK+geImJWQkkHINIRwmCsAkYgxtyVLugomShgTMt0kZQLSlRAiDVkhITYkId1WyGoBIco1aKYciIGdIeesgmzsBbluIeSJj+s58k0ZTTreuG0/uVUBI1W1ftYE2mM8jCRAy2Kjyobd+O6mNNZvfwv+i8HlXbK1sifSvNrm8c7cinWyLd6VMbu7xa1qzqxO4LyLBOvCGKohUQnBysBo7Y0OB4PB+ZjnPRPmOLq0Siw1eifKrfw6mbxHsxdTxM3VPPe+yZY01zF5nS61foamIf2NDpIoI/OoapBZsbL65TPYROid/HLk6rOxvDZXyxxiFqqr10u6zY26FypYobbVdfV5ajgvP21SmTbvtD9Klr0HKxUOuZjPbr20aLiwMP+lnggUr6Fcw6QszUtxZ8mlmBffW1eDMTky/Urr8al76rq4XzRKiRop3TrhoEYKd42Q7jrhOGuyWacWqUxNS1OmkWWd1kw6kxbSW/yTQCKblK02kwkJ0ZxlMiGYcAUTMgaZtJtcR0JUuhCuC+E4EM0JuCs6w1UAOQgSV+XkmU2Zk9/kO1sdMDbOnnCClOwByeRKKXF39ahJ10YbVOno0n0rG+viXUsEujPBezLGegsXfTh4HyZZDylkD0antUlUMrBySXrLnOwUiKlqSHrj0pdkc0o5z4ziI1wIMQpN9RBihpV6vknGm4hRNAugTOkE1axStooc8nldHczuQmKsLm8Ah+qL94JWOOZLoAaaUTVDeftlNhE+QCC/jB6squS9awFa5Z4JkMtEMm8FYVRnszlVmbz6UTtoSVbZYAKVQyQ7PwFdB7NP9QoVXAuht7d6+Te9l0nFp1rRu57pviPc8i4o+Wx2MBT9quaqXAB28/oqVy4Fxt7w0gpg0gl7+aqsGZ4qGY9/lVDsWV1osi/tkX0Luzrz0N39Akm0YKCz0APPQEpxwVhKSlnPGKsTUtRIR9RIIdesRo+113e6uef2rR988qMVv56damiuyWRaW9GUTrkMrisgkjakEGUiVmFlU2sbnLIyOCGAfBxkSAsj+TeJeB3Ma6sDxkL1llMGHipS1rGMyb6Q6A3BukOgE5R+jmkLnz+PNvsuM2tYiMN0sOc3y8c2k/q0KZZvXBndss5o3XEUkkvnwG74OsKEtl2e9+L74v7yCWji1Xk9/oOWB3F0y30dGgkEwv8uOQ5TSnVMkCGZ2eLCxiszNnMaIOUGIeU615Fr4IgFaz9fMzXT4NZx28rYaSuTSDRkurXAmROHO5w051sAc9zqgdF9aKffs1b+a9J3RyHFJx8B2QgTigAvFVkymEqUaxVK1385yLRAS0eIhrYCe/YTM02TpAQkMELeTHDPk30NohGQqUh5FJnymZXHMXxx3rc2q+YxlvsgiUi5i+UR1ClCBAtaS6IEt+CKF1ZehfI18CJEJs2yRtQVfhbm2hgdNAER9wh5MfsSpSHjpWjdaS+wdAtKF7+dI+9RYlxkrQus/GZbRHDQJ9rm+Izaghp4Nf5ZejreSB4GlykbjPpcWvcz7JhZGGh9cgO+sE7mxqrrsDA+PHj/qOZ7cWTLg6GeUTRD4LP1S9b9JF3XsiZt8VSpY7c2JxozdiMyS5fCGT0T7ubOGrdqYEw/OmC3WGNinnClct+Jgk1uAhSnCG2Sh0KT9Ute+6bza7e4aoR4ui0PGUMLRQhoDEjx5LyNrU8gxptIv7GJtFsp/4G2EjbvheRn7+VcSc2F0v8uyqqR2mE4eUKh5KM3wFPk7/31VCSaarFcNvAemJM8EKutvqiUdTiq6T7wwu6YRVtwXmJv3F15OVK8DF3dL3DN+h/n1Yu63kk7Tyx/f8WfrCRrjgurWTK7pU42prEOmcGD4JiGyw531zf44FYNjM7kHU9mGf6oJN9eY7T4SuygnX32Za7GhUZ7VEHvqxA9lhcARjsd6LOOfKJg6AWV+42hIywg4gfF7cDMIEW+0h+a7eB9z12LgEGR0RFisKbay9N1hfSSAV0LJ+abdvKXq+KNp97xgDpfS9WeiBvpUJ/+muYnkxrr9SCY9CH2JrUeN795cu3XOmh/iJIKJJbMhVW3us1nzaIEY2MTMFTXMLy05I+x3JXAf9Nf3DyJQOmnTcU5vWKMv5fLjsOUygsRlyncsvqIXN2M14SUi5fPXXluvJQ1Omm3IcOtxngy0WyvrEv3BTLYzHWNWzUwtt65ww/jLn9QEDCaKBiwEV1909Jn8KO8GRoeqznbrX6wLXTK3StkVzRFvVw6+fBTeK5EmYtZp0JMJ1zW8DQKrwy5t3NukhD+hhPaz+IHL9ItEF1L/PIWneO0QYU2uXhGg8A6X2BUBj0YEn/1GxE4D4msyhwkhVYle3qA0Dv+4qDsTLRhxtXpcRI5zYKYsGMODbNvc22Q7bUzrOZa8Ib1hlwabqFC7VK4x8Iek+EeD/VSpA/yx3d0/CkzDQG9t6rnl8m7YtiZaqweuLf6Uvyg8T7skpkXeC+YI4tJ+fnn81b83OWsgUlrQ0yI2qxrN6WbmlpTnZAefifoCJICy/03SAvbyGqrBUbyPUxt6D8+LmJ3amAsNk2LgYffatH32gLAQgAZGi5eosWms5mnDzXR8hXLn7zSPF922sCilD2FaG9RGMkfJpX9wfrtDayaC1m3RN23xlwDlHSFXP8R5Nt/Arjt7XjRrDywDkdTi2KMlQAffhHQZWeIF84DpAO+ywmQiQrPckxT2N/5VoCf1X8KufQlr55ha63GM822Wbch4PtcCvHGNZDrFxVHcMq1/wHgIy4E3CzEa78Daj/xDMvR/or2abElAUBJN10WNw1k/LCaxSCxEE60u7y0IaIXXZK83il2v1Ce7aUV6XAhVi6dv/pKxniNbcu1krs16Ra7wSpraUqvRurxx+FcRdrIzfSzVQLjF8/0LpULM/0qZfx7JeXJmzVe+G4o+X57bfdNeJDkGsznN20xCZ+NRlmFv6eOtgSHffWizLNt2DbSregH65C/ALESiDf/AvH5zHzGyyy1DdkHTJNr5IRDT0Sk3W+H3Qq+y5GQzevh3rs/2K7HwDpIez+JFy6E/PRfHt8mNkZfuQJKxcyyzWFcDpVGgg0aB2vMH3VaC5+EePkXsE57A6wy2BbbZreIT56DeOF8nZ/6FBjK8QpYp/8HLF6uvI3dx44BBM1F3WdR4ZvtdgKsg3V8Y+fRo4F1tJ2DGJX/fI6r+e/7eftSR2jZES6scc+BdR8M8fnrcKf9UJW3raU1l4MpqvsuWDSQuUd8zZEYxnuz4Uy5xmSLhcZVWxDsv5v/np9DWPKSQqxa/uHqaxnnG6SUqzmz1ieYqM3EE42OW9f64C3IbgPGb3BV+OLvKE0vLqt0m53ybj26HF7WKXGzIB//Dn/aY4TRhIo8b8UB2rJMcQzShlNvshP40B+CJavgzv0H0LwmkmAhRuc9YieA8t5qosMmj9sqsEQ5ECsFq9oOfMRZGmhWzgGaVwP0fKwcLFain7dLIT5+FuKNP3lMqwAL8EY+6z4U9slTlbjs/udPkB9OhfWj6WAl2u1DNq7SaRA75RYYidWKqVqQGz6B+9gP9G+FWTofk1cRteSH3gq+sz7fy33tj5CpGlU3PvgUINkJ4oOHgHSt1o1W7wA2+ESwRKVidO67t0O8c6PO23TXNFtTuOD7/Rp8+E91Hm/8GfLd2zSr9T4KchTZlWC7nwbrIL0t17n/IMiaxV7ZuUeFiwwiagdKhPpaJe5lIBzYp78K1nVniMX/gvvPM2kLe2EQz0s60jcl3WDtcwmQqoNMNwKpWv03XQ+01kDWL1eLInNaIZ1WQDiA6xi6QlKH5FQfG8n/iigsik0qBibE6s8/WnujZfO1rovVUsq1Nhc1djbe4LgNLdsNQGZzNsBsVYyRxOc1s5Bsaiov4yzbqUvP6sPKqkomuT4wBh6x5rocFbLDQyb8pM8Pciu0b7jweaOaaDQhTnocvO9IiA+fhvPCxZ4uDUD1AMTO1MfPZB86CnLVewGoqGAwBZTnvkKe9d0H9okPKZFZkmjmZIBsi/7nZsG676Ymslj9AeTaBWBOC2SmFcg0AdlGyEwKsuYTyDV01Ehupc/l6Rl8mAV73D/BegyBbK2Dc/d+sI67D7z3cD3xnbQCAaqnEt/pn3TAynuoeso18+E8eoTB5nLtFtL22iWwTnkesnk1xMuXQ9Z+ohYT6+C/gg08FHBaIeY/Cla9Hfh2YyEzjRCLnoCYdw/QsAygxUehdAH6511jJZ1hETjFyyBXzIb4/FXwXY/yyu2V381CiixYWXewLgP14vLpTA0+6z+EePcOSGJqGuVDIE8AZB9xK1i/vVR5Vds4aUgnpVgzXWexUsjapZBLXoTMpnR/ZBohs9Q3zQqAZZ23xT+AzVw+Kt8uuyB22nRISnvtIr0gJjuBlXWB3LAEYtFUWPv+XAGiyjvTAmQaIFMaRClPd/Ydqj455pj/zWSNftNG4c+fEwFLVg72YclJCrl2xeK1t0DytczCSjCsdaS7oYzH62W8saXvjUizbaJ0sZXlq70uT4S1ZgCSLXVl5Yg51V26Vx9eVpW8MQDG3Lje9IwLEUR/BBFK0mTlcdhH3wk+YB/F3sS7d4OVdVK6OVT0gjX0FK2PW/8J7ZEGEhUaTKaekQcmoYLacbBEJ0iaWG5Ki4WK7nCgtDPi57wDWDbcWXdCLHgCiJcCsSRYvBIgYGhaBbn8zQLOf0YuUsA64ApYo87VmNO4GuK/98PaXx9a6L76B4gPHlQTk0RPWAnIT54D67ITrCNuV6DhPD0ekkT56I6fvJkmgdJuQOt6NaH5/leC9dhdM8QuO4OVds4VjAw0NZ9Ctm7Q4LvybYi3/wzJSDTNbW1U4rHPIGlFIda472UqTfHW9bAO+A34sNM73P/is9fgPDEOMPz/Qi+rRXAK+Hb7dTjN6IPurL/BfY0izhmBQCJmJdZ7BGKnPglZsxTZe8eqvuc7HAL7uLvUGHMeP1UvTKQ+GHsVeN8Reux9+gpYCY29LhAeMLZb0I2nk3lJMinWLl+y/jYKSk9nF4HJNSIrakqteJ1b1tjctxLp/1nGKB8bPBCuHAQpi8aPa7eTog/45jO1rBuj1XVBLlmZjGOJtBt3Um4ZHGdEMmH9lHbG+5+8Po9cMBlgVKj10yjozWAnED/jZQVQSnSNWGwL1pNAzVvh5cq5cB4bFwBjSOw0zSjVA2Af9hc1AVi8RInRsElUToDFEjnQI0bnZgE3o1lMthViyb/hvnylLpsPHqbMQNvKuuyK2OkvBEYN2VqD7B3DwYefDZaogniboqE5YBX9YJ/5uqqW89y5kKvngX/nNCXquXNuU2JbSBzxK+Qp9iSBunpAX6DwhtYxD4JvN0axaLF0plI38O+OV/VQrE1kYe14OFj3QSAdo/PcOQCPhZSFwRY7SlYIFYZRZa1CM3LwwaeCb7e/Bm0Sa0lHyWkxs8Gq+oFV9dELQs2nqlxixbtwFePXuswQ41UXBPiw8WBdd1GirFJfWDEwuwSs1x5gSTIm6Y9ib9TGavGkfPW0cF67HuLtSYEDkKnH87+zHQ5C7IR7FMATawSxQiphSTXEp6/CeeInavFDNoXY+JfAuuwAZ/rlcOdOzhmolH7T15WEtQPqqsf88vWI+Xp5s28LmhKlrFu3vOH5eNKqY3G7JlZi11rxWGOs1G7hiVjGSjBhKck+7Nmw0XgQfYGpEBkL2GkffqmwZF+LKK222z465M9w5cVqj7HpEqbcIjyBxHfV8xCo0IAwLZ0+EwjSMxuFGBhZn10JmRWQGQGRykJkSM/yDXy4hfhPZ6pJIVtrwUq7gFX2gkw1wJ17H9Bap9lOayPsH9wAVlIF57Ub4M6ZrEUwEktVDNZ2PiVdYA0frydGlpgjibQEABQrinR8HmWykmBq4nMNnrEyuO/cCqSKn8Kq2p/biJ3zpmKxxApJj5W9bQ8l9lm7/wjW3hfCfeV3kGs/QOzsWWoyOdN/AT5gP7AdD4Xzr4shl7wQ7LQMgYmBKvaJT4GVddWTlvJ4+FDYR98Lvv1BEIunQ3zwAFDWA/b3rldA4D5/gWLJfNg54AP2V7pS59lzizNs4cA66DrwPqNUu0rhQrxzG8RHTytWb+09AeKDRz0Rlqk2tPf7Jaz9LlEDNHPLd4GWdZ6xyke2In2j+s3XK2rDGuszArEfPQEWU0Fu1Mf98F9wpp2r+4PAkwA5VqbGi0xt0NHjinz4bkcjdvStECvmwvn3FWCl3cAHHwtryLFwFz4N8eGziB11qxKjlZhN8X/XLAQavoBM1UEseRli0TPhyCTtjbUvcV86AulaB3aJDavMhl1qgyUssBhX/2B5BjvfDchD17Z8gUO+JV5TBTu2qAdyOEKBh++AvXBi3e17VGRY9iIwdgwDSE9Cr3wEiSeYFHd0n7mwYKT1rwcYH9h1nJT8YSMoV0GfsHC7FytKIe4U2UDviSAaGAVEVkJkXIi0A2Q1MJq6k0JOLB0dA4XSCd4lJiZcMDcDa9+JsMdeDtm4Bumbh+UsiVIgfv5b4J0GwPnPJDiveae8+vvvPKZVzFxEYiMxFPvAn2uWSOxDKdU99kkskUDTyWgdFgR4lx1VEdN3HQK5blFBCddnDFR+a+S5kM3rEDvmFpVG5ubdwfvvA/u4fyiwdT98Fu7L/4f4+f9VE9B58TLw7Q4E3/lwBfDOi5dCLHzUK1euxXILn0Rs/Fs5dtZSg+zfvwP76HvAdzhYMyLSmxK7SlJgcAoBS0HYaZktA7MTEB8RMBJjzG1xC/WrcBA75gHwHccG3ZN94VeQn0xH7IdTFaMia7vzxGkQa96nOOCwD7wc1t4XqD5M37wH0Oody+I78kf87fP0cb5es6IX4uOfA6vonjesss9eCnfu/XpBUM+TTloTJ27nC1YaDHSfxw67GrJuBdyPXlDMnPUdAWvHMXDnPgCxej5iR1wHsfQNuHMfBMq6qrbjuxwG3nMwnNdvgfPqtR4wdnzaB0+amxk6YIqRjkRrTVYBokX/SmzwhAUe46qeKq57QF4L2vQjiuNCMyJsc881NgVrZ2hdgL83zWbHA6xroflNIr4Q7gk9Zy56O3pfFW3D2xdV2sK2K/e+obbhrUs6WXGMEILIOErHAAAgAElEQVQNqBx1w10dBQzzOfnQoGkyI8Pn5vpwvykJtvdOIJ5JFTSOVisFjKkcMLaXxJe/T8Cko+4TxtnDfozYkddDppuRuW0fSIv0g+VAohLxo28G6zwAYvm7EJ+/qXVp8XKIms/hzrymbT0j8cLv/hix718H6WaQuedoyJYNSomvxGYCRkFHfngiavchSJw9XQPj5CMhV7Ud41NLt5rxxM94GtLJIPvYaYidcDdYvBRi1ftwnrkQrKInYqdM8RjjZRDzH4F99GTwgQcpcMw8cITyGwxEt0gDWwf+BqzrrkqsJQNP5o6hiNH7Ox4Cd+49cF75NVjlAMTPelOD8x17KAOCfdhNsIacAPHhM8g+d64WcYM5Y0weSQB/IVjvYbB2OlTlnn1mAsSCJ2GNOg/2mMu16JhqQPaJ8RCfv4HYIX+ANepM1YbpG4dqXa5qD49ntDVIfANQsjPi46eBd90RYsV/wXsP1Zb9T9+AtcO+yviSuf8UiOUUsFYdzKD/UsT0eDGNk1SMnA8+RvUBklVg8QogSeqUcjjvPUxCP+wxl8KZfQ/ceY9p4F/2NuzRl8P6zgnITr8S7ux/dNAi/uVng3AkUrUOrFILdmkMPGnBImCMW+A2qRMIGDsC0JsOHHXTObKk4Sz+yYCxST1e/uDSgsDYOHviLULKC82bDJhROWrSQZvSRPKBXQ6Dw6YJgUTeqlogQf+ZYnmZ99v8TqsvRdPMEjBqUZoYY6H0o8wv90yuI/LZYW4zYTRNThNw2KlK56P+VfcHq+6riTuJyaQLa2cciGWzkL77CCXqFdt0Rm1kDToa8RPuUCKi+8E0rTMk0VfpHMuV0UWJcMpFpwQsUaqB8f4TFBDnPiHhRF32daykx0uc85LKI33zSFijLwPvNRSZR05F4uyZYCWVQTKZB4+F/GK2Knfs2Mlw339YibrayTxaaa0/IVUQ2+4AxE56BLK1HpnbCRj/AT7we5Ak7jev1+JmdX8tCtct021JTChRAZes/c94wFhk4JCVn5X2QuICHZIzO+0CBagkVtt7XajAUTZ+gezTF0N89h/YR/wF9vAfK/AiYITTkktZScse8EaiuvnAycp7In7a4+DdBkLWLkfm4TOQuOAllUbmiYtgDT0G1i4HQbbUIn3PCZBfzM9593AGnsgBY0hOKusK3mUn5c4k0y1K9UBSAS2MSncqXMQOvRr23ucg+8pfwUo7wd7zTGSmTYC16+Gwdj0Umacugjv/iSKRIwsqsUKt2pakVGh+CUcgVedqxkjidIkHjDELzGOMxXCxmERXDEuimKAKzlm2cRZ/MvURO8WrCHVmA4USlJAlYJjEXPmX7jMXri40fJhii9xaAYo9aH6krK18vroru+qqDii+8pN279v1IubImzuiNivo8UpJRtlzm3KsjreXY4wColUDY9SFOn+y5gNEGDz8X4WQTReS7/p9JE65O3iNDAbMd3amePHL5yg9I4m/1sAD1XNi+Xtw3rxNsUrli9ZSqwHAlF9yKQbfeL+9YB90GcgVhXXdAcyy4Mx9HLJ+mU4r06z0m7HRExUIuO89BueNWyDrV+jJrvwNCwCW0Y0K3PuM0MYh8pGzbCXeypoliP/4SfBee0B89qpya3HnP6aNEF0GQjathnSaQ04nofbWMrtus377IDZuigLCzK0EjHeB73QoxLK34C6aBlbSBfYBv1LGF2fG75Uu1tr9VPA+w+Au+iecZ84L+eapRI3thWoZq+yLxLlvaWB86ly4BNhUAgLmIScp0VoxbikQG/corJ0OVm2Yvml3lZ+pw1KqIaVCNJmpNsCwXsOQOPUesMqeCujTdx2tdrskJ+q8Mw+fBffzt5G8aAZYeTcNjg+cAbGEDFgcFLmdE40INq7nwIrv9n3Ej7lZq06U6oDGOY1t7RLkLn9P6Y7t4eOQefYyWP33hLX7sUg/MA72AZfAGjASaWKp5IIUDK6oySTXL21PPH+QROdMGM6IC6TqXc0YCRiTNniSxGjNGEFHqpljMIquHWZD5qDV/aPdStkvNzwcmwUmf+JKcWfPLgvnsMfhytGj7XprQ//qlz8g61rRD2ucM+E44eIeOgNcG6XYUgb5Ghjuqhw56Y22Xm7vnnvPznfCwVlqS6y5KBWw7oUw0A/p5CtUI3UPdY25eitgJJc6ATframDMeCdJRhi5and1zQSIIp0dvBs5vCkoF9Mg1XMI0LIesrUB9l5nIbbv2Sr97L9+j+ysycp1Bs0bEDvkN4gdcJG65372JpxX/gJ36dtaFCbLYRBsthDhot0lxD457GE/RPwHeveI8/5UOHMeUVZQsorb+5yjxTgp4cx/VgMiufvEyuG88w+4S8idxq+AHz3Hm5jCQfz4v4F16g/33fthj/kleOf+yL78JwUa8cOv0oD79l1w/vNnZfW2Rp4Fe8xlkKveR2bKOL0FzmyfCA4r6bHfnoj/8CllrU3fMhixo++EtfNhcN+7D9kXL1dW4sS570BmWpB9bgJYshL23heDVfeDu3Aask+fF1Y7KCdrhY66X0lHWdEfifP0MM48+VOIj2m3Dj3iwP7BLeB9hmuDFG1R7KH9QGXTeqRu2UNbtf0Atyq8qpd+kI/eTxXb+1y9UMUSui73joNY+jZ47+8g+bOXVXbpyePgfvIy+Pb7ITH+UTA7rnSp2eeuRvY/f8uJ0iRSGztz/Ca0Bh4CRscjrPwv4if/A7xzP2Rn3gixar7yOLCGjYM95Eikp5yL2P4XgvcegtTNByB+8p3gPXZF6u+HQ6x8L5h50V0weSzNuJD/rIdaoWgo+pruZgaXGGODgE1MUTFGW4vSpGMkw4vaiu4fuFbA2u/TGdN7wpzDxrz3iZUqji7A/fysj0//Mnuxg+Eq5/2iDNmGDBtx51d2Jq2krXlryl8RjhyV7+cQgVUTGf1o0d4Yz9vLHwHZoGECxkjiNAGjA6QzoUVSRxQxNMn6FI0gzmA09mJQypBsEyGhweomgNIuiB/1V9hDj1RMIjP9j0qsip94q9qJ0HrtborRWbsdgfhRfwKr0lvgRN0KiKWzkH3tZsg1C4MA3N44038qeiNJohkBrEWGFy/Qge+a47nlKCfibAoyTY7dzcqxWzuC0/e00kHRJCkgSOvqxkpQ8qt5ynKenf5HWMNOVuIhiWlUvviJf4M96Ailn8s89CPIbDOs7fZD7NCrVFu7i19B5vGf0GF6hm+e15IGQPIdRiN+ysMK+NI3D0HsyNtg7XI43PfuR/ZflyoxOnHeO5DZFoiPXoQ15JigO5y5DyA7/Vdg3m4OXRfj+AhvceGdBiJxzqsaGJ8gYHzeD+etfDVjB+efZOrMfRDZ5y4J3Jo0kCr1sbJeB2OZRNjD/ojYfufoR9JNECs+gFyzCJJYe2ln2KN+qO5lX/orBInOrQ2wdjsUsf1+Grh0Zd9+COkpF4KXeuqWaLxK10H8Rw/CHnwEUveeivhxN4BX9oQz7ymIlfPgLnoB9sjTwAeMgjN3CuJHXwekm9B67RAkfz4LvKoXWm/YE3LDZ4EVMjqcQ9ZJv74eMQlNR/90yGKRpbz+VTpGAkYlSlvgSQMYycikHCh8v82INUcNdgMFQ9gQsckYZaWvnOM95tQdwC5YV9DaHEGdoj/b0Xp1NJniz7XevdMOiayc5Qp0UZn5QTr9KClm/UNHcuYmUl5gAq+hAv9h3/1HWfgIFCPAqBo6V8agHP71cFSynAnbfC8qeUSov5oEe56O2H7nKh0PsYv0Uz+H885kWLsdhuQZjypdUMs1g8G67QS56gOgvCeSP31KDVy1Y6XuC7TesJdiACFA9McCsZqBo/VuidYGSNoO5oGe2u2gdqF4/oEkT5COjqzWtnYLYdKBILHY1/3lKYf0BXvoMUiMu0ul1fLXkUj+5EHwnrsh+/odyDz3f0p8jR9yBZz50xTzSZz9HJzXb1NuKLF9ztELwtQL4c5/MvChCw00+pGoQOLM6WCdt1dVFcvegVizSIE3+Q6SzyUZqqzvjPO2txEI/UHrGxtWI/3YjyHXfeT5J1KCBYYyjyFxyiPg2+mzT2T9SmSe/xXkZ68q/RwZf2KjL/UAima6C3fFbLiz71QGGO1W5qVN45ZEaXKKpbHgT9ZkJ5T87FWgtBqp+36ExFHXgnffqc2J4342G86cx5E4/jrd55O+pxzplfHFrIb/3XGUCG71+y7SUy5A/Khr1KJFxh3JY8i+eA3cRc+p7ZKJs/6pnpOuA+fNu5B98x+KyZJhT0kk/sfre/UnSjSKld58zhw7/nej7ASM6UapdYtKlPZ1jCROkyit9alF9YzGfAt8iw0cDaauAZqWjVomxZ7s3E8/+bLI9bUDIxXQuX1H8iF6gjxBQt64QekLLQkGapkoEXonPLOVhEMOvWR8oX8kSqfDBDgiUbfbfnkrqxeJL9pwNMFLLvgXWFlnOB88B9Z1R/BOfZCZfg3E8jkouejfevfFuiXg3QciM/MWiDUfIXnyrQqAMtP/BPez1yE+fyeY5OGy5n5R2rH9zgNL0j5pMq5UALQThYwvcdobnQTI2Vs5EpO/nPZvdBZNR2rySdq/0fuE6kcjULhInvcvWNuNgvv5u2i9ZYya+Fb/YZBNG+DMI7CzdNrxUmVp5VU9VWqpxy6E1W+4EtPJpUc7ufvCldHUUiDxw4dg7UqGlkY1YWlrmwIv2srmLwwBpyWLU1w7S7uO3iMsXDhv3AbnndsVTciBmEpF/Zc49m8hlhnUuXGNcnshVqe2zSlLvrc9UKE0bRZIAyIDd8V7cOdP1fVQHg++OJ1rQWvH0aqdnQ+no+SC6eCd+mtH73gy5Mfov+F+9Bpabz0C9t5nQCz7L8SqBVpCiOsAEXkfK4bSKxaq3VNKd632p3O0/HkkxLpPtIph6NGIfe9y8OreSsep+j1RCrFyPlIPnQGxfknIt7TYwO/I/MifEzo18zrFJ0g1SdjEFAkck1bIXYcCJwWxNc2zfkIFi+KCeTN8jzZDAfKH9gWfPtLupO7AA98IMFI5sjdvfxOAnwUBPyMNaVazrXLnkZxIWymrNLnrBMBIq+TXUc3IEKKgCANGqd7m1X2R/NFdSg/XesuhyrhQdqk+CCnz4l8R/94vlOWz5c97IXHsn2EP+h5Ewxq0Xr+vUsq397H6D0fJRS+qx8joQqxDMUjSlZHxJdUImW5Q+6RlayMSx/wR9q4Hwf3kdbT+jazeOd+/PIpCi/n2+8EefjLcj2fCeW8KEifehtieWiQs9hH1q9Dy51F6H7Cn38ub5T4zJ3eFk25HbOQpSE25UDGf5Kn/AO+1a3tVz92ntr1xL22sCoy5xuiQLuLH/x32d46HWL1IuUbZI37UQReRXDbpx86ES47RKlQj7RPXfoehcajiOHr0R9FK2tViwR52EpKn3KwSa73xEIiWWu1mk01BrP7QA3CPkZKlPmYwX1+soeBrvQajdOJrehFReuKEyq/56sGKxpZe8h+wCu2qR+MoNXmcWoSTZzzkAWUD0lMugrPgaWXo+SY+tLakm0SOLXqMkZy7lbuOdxQ6laXQnI6SU7/MhXBCJcXY3dZFn+poIV/B5+tAjILFkn/vXSpSiXdcIYeoBwosTb6Pc4frFVm61Pj0GCMpf2UrsQsyAhRgLcbxoL7A5OupcirksPycC1yWn6L/LlmDS3/xhlrds7MeRfqRs1UorbLfLVKTsvX2YxA/+mpYfYYi+940pKddirLLZumdMPNfQCsNau98rvyjMnWFrZ6DUfpLvR0v9fBFELWfKdZAaShXHfJzI3ZF3xNlsHY6UCnr3c/nomXSgYox6pS0+5H5Ca4Qg1LRc7jaoZI4+Vbw/t/V7h4UtcXbbkgiqVy3BOl/XQuxZkFuEVLJ5tLWUWw8h1zyv+09FPEDL0DqYTJQ0WTlsLbfG9aAEWDlxB7bXAIhm2uQfeV6r4za4T8YV1638e33QfywK5C69xQV4Yj3GwVr6NHgXQbobZvEeok9q10oxIJt75/e1kdMtvX2AzWLVZsHSJQ29ZjeOPaNMV4ZVPbky7rXaUiedKOSCJqu3A2yaa0qIvO2uAftTu+ppjbkW6/tyOUoccx1iB9wLrJznoCz6EUkx92m+pDGS/aNu8F33A/x0efDefdxpJ/9DWQTHbolQe5DJec8Cd5zF6QeOAvu/GfUTp5ceF9/IvpNZ/aXP0V1LMyctGzuS89d1d9yM4SMoHSagzK+EFv0RWmbaUd2ZZXOjbzo3PfVZ8EjxlyPQofF2GKeYiPYZZ8W39bVYVDRD35jwEiZNV/Xb0Qixl93BWhTbwc/hci9iYi5+8qNQjFGjzUq44tpHY1mGV2XzJN7zYlpPtdGsel8j/OegT1wb8imGqQeOh9IlMDabk/ER+ugDK33nq4mSsn4+zWjvPFg8H7fRfKkG9Qq33Lb0RBLXvPdsyP2SQ/gO/VH+ZXzNA44eqeLzFIg1FbtlEx/lb9bg2KmVp/dwXsMhLtqEVr+NDLHGINN3/4uhNxADwtGXhBcK+HhlTezVVQdan9COo+FFhxR5gzwtoTSrKB3yBldJeHFqNT+MLl9owHAhhcpVRAF3JH+MIcGgR3lYerWaPX0YzIqZmvMArKSKpDSoio5XetAHb7xxRCjA5OngYYhC6NE/IDzkTj2GrWQNF0xEGjx521kTBOKBm46EcUbAeOJNyO+7+lovf+ncOY8BmvnMUiefBN41+08RKMtjwJoqVPO8MQslThN/ygqUHUvZP59PZx5Uw3G3PbCk4OHqDhb7Hd4LhG7TjVD6xb9fwmufBjVzhfl4to+/OgnpDpjO899jzY7WDybzboHlfxq+X86CCgdeqz9knUomY4/lP1Lvz9IsCuUz6H3WiHY8Z0WfEujryA2VxDTwqwajtgiGV8IGGm/NDl4k1U6cCQwGVKYlIcPlw+vf9EhlA8furS83zCUnj8VrLQarfefDWunAxDf+0ehxmm5/Vg4H81E2S9ehfvpW0i/+Fe1wpeMuw2Ztx+A++mb2o3BeMuEBHWnpBolZz4MpBqQnnEzxOfvqhBgjMKRKUtw7qPmfef+yulcttRBNHwRWODNsz18C6F5Ho5ieKZ1sJBjqcGW8vqz4Nwzw3x7NTPdYPIKX0TU8t1ofC8DD1uD1T6MxSrVQrAfPO9bYNUFj1P5MX2D8kWsqH5Zi4E3xckkR3irBLL2cyNqQ35sygAqC5WbMSROuR3pJ3+hw4mprVVxZd22B+4D1nV7ZcBj5bQNkBz8adtk+Py3ltuPg/vRyx778+Ubz5JfcKzlH6fgPxaMEc9dR6fmzxndzrRmppoZrCRXOkZb7XrxQDGWE6VDwytvjfOIQEAnfTlHP8j1PJkU++WyiR1HoI49+Y0Do7yhb4mTBVmptUj9ZT6RiWcaX1zSBRnAGMqmEAn9MuXI+QuBd+qL2N6nI/381bCHnYjS8fcoVkeg5Lz7BFLTLtfmTRLjyMjgR+GhkdSRiDx+OUmUVaPDi5i9UeUvhFi5vavmfA8tH1HSRg+aLgOh0WQ2cqTBDWlUgTO5SxlO04GwZu4aK4ZqJuKFQLUdRtTGbd/xOCiHiooSnEgTRtgQEhdoIL9Z1QFaHsFVeftRf1QjFuk9o5DF9EyKAXtxPGkskFqAouwkCJRpF1aVMmw5C6d7W0U3aqDohzdhvvjAaCu2yLUPY0IDo7JKk7/mpqKP1yycs8X1aB3W7dL1/pkRm1C5wq9satG+VAFar+m1vw02wxHKzVN93J12h6juDN7UCL58MVgTiQHGwAhNDDMsj/+YjsRMrDEkSmc0Y2yrooUE87YEhsKCvOeKpAaSACNLaawEvKKH2gusDCJkfS0AfoXwJupkWIi1RjtBY4tmeUEZjUEdGt8+WQsxKd1KodPjvIzz5kYAbsaREb5jut/aClC07kmLvl5PBCDoiUeBGO31kgeIXnVCTK/QPG1v3hbtrzZHsdniOaaYl5c/sEJKzvDxaiH+71Ok0O4ZjwkZB05pQ60uQ6QkoaHhA1cUZMwxFTX6mnOh0DgvNFfMNizWbH6VPOcGtDYzaGD0wJGs7krHaACjP9iCAhs5hQoeLoHFIQQThycvX6WtkF/x51sBRqpD5g+97hISP6XGFD37wdljn1zVhID14VzwZfoAJhPY2upInzH6ojQFkWAeMAYJFZtFHen5jjR+W7O0vRlcKP3QCPceaKsORXu0HQbV7vIRKZw3C0K7morm7TVu4HiaS0tH7MpRSK3jy2evHWn6dp8phDBFXsp/tI2p4gN+gZhZ/ltRcA4t+iZItlcJ1fdt9KU5NqLjpNgYb29cRt9r73lflG4hpsgDxmgpUZopcPSt0ib2hbiP0Q7RvlDqacYeif/6i1Pba65Nvf+tAWPT/3XvEUvyBeT4LZNlWq/TpTvcgYOB0jJVH+v9WeDL29zSGKp3IEordx2pwo75wNheX0bHUxSQ/d+FxlZHMLWtMekDf1vMpth4b69eZrmLMQF1XWVOu4C8H74hQiWQO6XP45TaUZ+e9Qvti9SBf5oBfjkiGGY79K6y49DqaJBKz0Ibqlu08MYKWbQN2hjd6p22Ot1IP1eTcII5K6wpFhqJdnR2bQwwFpjpHV0nOzpWollsypgnUbq1hcM2gJHHmLcl0NsrHR34HZTZbQv1TjoztPSPNcs3Ffjae6+jXddeOht9X/62c2Vaxpa4UnYNtUcsDnfEAZBduyuLoPXOTLD1RgAMf39mgV5W4yuwSoeBcaML2MEXOsLDOphU6LGNSndTR7yZowdyoTnq6/iKjRLf7cQDRUVkzH/tVdwHV2U00yCrPXeIURieP/5uqejq5E+s9vLpyP0oEBbpgDb7JdpOHVaiGYy5DY1jR6qxuTxDRvLWZgJG2vHClI7Rimu2GPgxmsBoLp7FFizveQtoyDp8YMW1q8kv6Wv5fGvA2Hx5tzMtjn/QRgJzfKufsRjcAw4FKqqAbAbWay+CNdbled3ltR+NLwpUSzvjlPHFAcsa26C8JizEvtpadTsy/wq93xG86ggT9J8pNHcVczN1qF6PtsmiCrIh32iam/pRybc9SZlA0WQXxepWcCSb9TAy6kgbRvG9LWbcXnp590N0yQsGFzzkHQLVluRfTPlnFFrt1S8wNovN+I1qVzMf73sU3Iv1ayGmGF2bouKvn5ZmjB4okvElrv/5sRiVp5XXNu0x3mh9KZSjI3BxxbXrtPf81/D5VoBR/hY8k+k6Kyvk8KKdX1UNMeZw7XOXSYPNmw2+fKnh8qDfDDWavyVQnRwpINNuDhgLjYaCANEBqtAubTDQvhgKb2xnbhSF3NjEizwfHfX+Y+YsNl7VkWg6kHexBztax0LPFSlTB0qT5w9UrBgdLV6QZ97sMhvUG70daS+zEsXqXiidQqhVbJX1N+60lU575TDua8ZIbjqenjHhidHEGGmn6JexStPeIs4Wzt+wfo8Rd+IrC3oTrV6Hxs5X+VDTJVUHWbb1b0e07WAutx8IOdIwyqRagYZ68E8+BL6gwKXhUmmdl9DbXsmXMeOCF2CMAaLSl+jgLbocR0ZkdJkrsOypSwa78Db06kyDm5El3SxPG2kGluNIx+R7dURi0kfr3N5yba4+HahzUJz2qFlBW2sbM69Q3gX6L+d76aVl0J5wfxRwQ2m3zJvmutKhuRONqGO+ZI4hf9AXpXPGOI2CXHRs5bVfcfaQ1zTGBb9dyYruOzUpxthMjJGAkURpDouMLqRnJMqnfPN1gYJ1MpK9/lm4UygGheOIoytvqKN9jl/551thjM0/r35RCBwSuG8YSBV1ixO7DQV2HxbykmdPPw7W0qwNAJHO1g7etCPEA0Y6+6SDzWb2S+F4dW0v1x1hFOFncr/ChKcjKRWrlF/y/DSieYedSvIdqcPt4TuO+PmGW9Usf87ZN1w/cy4Xw1gzVf128RiY/spYjCxG38yvj48MujTR9tA1Ldxjha621WvF26TYiMj1b+F0275aCAML1ye/1n7KbY1Vc0NE/kiQ5EuD1iYtSivWGCfG6OkXaTugxxgDA5Y3IMwRQ76tCmw95NX5eH6vKkAPe6Pkr7X7f5m4i34rN8ye+EdIwSua669iY+5NfePA2PCziv0si7/qio7vZpc9egGDhgCdOgPNTWDTnyuMCurYFR2sVjNGB5y2zKnWNro5mEkFhoC/9Sg4klA/83GP/fDgnrfA4TH0qV+E4Z9PxYilT8D2z1cJXCgKyJN5oqPvh+kvlx4tM5/zv7crn3qVMV1FzLoGLVWorv5N754aeQbMRN1C/PshhPENB5EjH6M+qN6AjkYsVkkVCHgaKoc3IbRrR1SpaoBX0fhZHVhoCrWzaorotCsA737bh9rdbG+vfyPNG4Y+T7wIrQyFdBNmFGcvwbzjM83dRZF0g6YIPM/DiuGgqAXu5y0URh1VW+XGghKlPWBUbNEAxoAxlpVD7rob0LMPUFau31+zGuxVHdw37xPpRosR/5GHV93UoA812sSPfOxEq2G7Pp8B6McYFnGJn200MNKu2LVjBl8Bxn4CyL7dZywoo814HSkTGR2bL6qY4YKNDnZMmMt9Macmv7M8uVStJN7ECzCPnhF0DKYEhTxS4JjRJ/aZm5t0dv6JKvqXz14KSR76nsSTw6/B2zuMC1WzqmUVjpp3NYau0FGh/dTCGw8NB2gDdHLP5FxhwvPGZzFmljmeZVsUXVoi49D5zbnJmnPtzokq+m5OwR+wIH81VuZgcxIauzz0i8Lz2CHlhzq+SfW5vq7/MrjSu0fXKLykMjoztadFvxN+V8UG8zaEUBGD5veu5drULLpn96ZgNPosOKXX1LvDJJ0RoL8zhbbaI1I9R9cBLumMWf+7vk42ALquvkum0qB3PViMUBlzDSkw6HNjKddXuUnmj6Yw7JutnQtgEu13nz371/2ezrmPm3n74zyXSi4YRM79KuBgxujNjZXoBlpznIWFXHPkewOGROkoY/R8GHsD+/wAABucSURBVFUUPPI6OHEcUKLPIwo+ixYA71LovSJqi9woUWW2OWaVrmrYh44t6AgGFXqmftYECh31YHCP4bmNBsa1Y4dMkcBJfiKJDOtc/foH7cfKAlB7QenRMfCpjg6YnQdI5n5LP/1CBTTX7CiwqR1SZJH29ktzP0hBCIAjPhFmAMzIObf+dP37mIfRlOiC9RXbwaXzgI3P7sufwwmzL0PSMYIGm2gbraxZljAa6g0i5pY5owH8r7YlUZIQZJlDayp0YLkKpapOryegAhw6WUEyRsZ/VzCWVYGzGMvScdCS0z04YCwrmHrWEf67HA4kpcOFpANS6Oh6AkDun3ziez4GJ0To4328+cppFkU6L1Qvg1/Qa9625LxQAR1acY2+iIroqkjGGhME3aLzuCRhKEG3Bk9IySm8AZNCOQ1JAZtLWLQzmUnYELC4pO+SwhPFoP/SM+o3h9SnmUgZk3SN4o8JWAS8+tBvLSVFu98HAX8BC4edCW1Nymd3+fipr5htHx2Lhd6JElx/Yvlp5es4cjhSYPs76RhbmizYcdIvMs8iTTtY9QmByir9vcOB3n1Cc0k+Ow1s/froxq/gGbN/6Ts1rhDih1V3ND+8KcAo559f3tgS/1ACfkEcbmH3jQLGNQcPPh6CPeG12Ycc7JLuMz54oSMFkhNR0pQqf8+VcpdgNSgACgUVgtFOLvSeVyi9dVRvC6SAtQoYTZSN0kNTtDAzD6homEc6PIHPuo3AGzudjoV9Dg50n10al+K0189Bz/qP2m8OXxqKgDUxKwZGgOaCSYpImiHwAkNGgGckZMayZLLKcreXHM11sP+bgUX7RDPCoueYSyDImHRIzUrbplQoNg6a6WFG5iMOU+cwqXv6EpEm9Vtdo3vK95o8U9TZPSpJdd3rBvVXNavnjmi+5z/nNwpBrHnNZIfRhgu3vE4/UMDkwW74bfKAiUYeFN47/nUCRg+RVU/4bpT0HD2j/qqDlbyFnMDUg5zgvtbSqKWDnvU4sGKcHqMlMLWYgC0JVIWkqItxLhBnAjEpBJ0NmGASCehTNeNcihiBrQQSBL5Mg2oArCFcizZStBGD8d3+sGz7iY1LyAdGHxR1dDfPj9H3U917HyCbBdatA0jlVVoKLPaCb5vspxDJMOa0zbC0Nd28e7fJ2Og90w2zJt4pIc8ykPeqqj0n/W6jgHH12CFEMY9gwPPdEqnj2AuL24rpFWrn+rNLf8OA39OsjwzhQPGthVb/E9m4X2ANKdRVKh4jBWAmcZrgROrjU/XHTD0navqiRTh3X+AsZoZhWNp1OJ4cdS3WVO2sUo87zThh1qXY4/NnNbL48CIgWZKtI320YCwNsLS00CoZUi7jadholUBGcmJujBidQ/GiiZ35sQY0sAn0yKaPtaQsXReLT81YVoMXkUmLutSSHqPzJqpQXE+zNw10mv7RZJacUWPpe/4z6j0tDWnA01oHDZ7+tZwUl2tQxbsM8KUSEcE0G9UvQ0hSz+lh1LMeYG8sUwyNqQhomkCn2sADPaYDIPpDgwRq4ssKgujQQ2/I+HIitVYAlKo1KLShHlZ+7RmtbNRaOuiPar3gPXVqLEG757/uxaZQ95nWClCHqzw8xqrst8RSIYidyhiXMsEEkkyKJHNRYgkkpZRJLmWJbJX9KdyiytyD5lwFw+ojv9JRBUtunvhVy7VsWJTOCdO5J3OGHOF6xhdijN4/Yosq5okPjF7SbUNuIRkgjCBaXyKvq7yr9bIIuLT5s37Wxb8G2NXGQ29Ujlx5IGOPuxsFjGvGDFnLGLrEhLNjp5kfLu1oIRrPiA9iFp+VldB7/Tbp0/6K5QORYoykY8ySHESEK9fdZtaFiCjdN3MK5eqHCvRC+pEaK4Mknh3xa8wdmgsvtseiKRjzn+tQ0lqraQjN/Z1j9yLGUwQy68p3Kuve/EmTJhpCcpoPNJ3ImOfp3bgHWEpbpvV4ssJJ71LlusfV27HJTZa1wtPzqbWAJAoveoTS21GaaocfAZQPah7AabDTQMaZSz7xckPlrmUPDf7bOQctvfHRoeueXk7vkXJbPavCxitKqQBSKXO4vu9SUCB/xvjPqUb0LBIUstG7bxn3Ff7471Ei3kd/s9RpBRszTOhAP/N5oldueNYH91XN1X1trfF/e3VkLleHNyjAI9BS36mzci2pAFA/o6LvUsQ3RpK2pQBTarDTayp1sgJDyodkdQW66h61jMUYl8wR4MpQS897ek71vgZogliS8VVa6rr3jA+uTLCY/DhzjmKlvjHIDzfJPUUqFc4LY0lo68Uh1opYb6dRVKKOEreO9kk2zZBJaaOLb3ghl2S180XHPw6oTi5NM/eOdr/uVovJtHDdfarvyc5tr4xS/taun1X/R8bwS0Pp8BG33f0rht2idtNsHDCOHUKHEn/aY8YHHQ4ZJk9EvKE8/qoA2ysnc0UUq1Hx1kSnQqgW7T2/JbwDi7QBRusa1bZC5oVlUs95Da7S0AnpPdakqyC2SX+9397ZUvq+vmakoL772+AW7XQEnj/oWqQT+iD6ZKoOw+Y/gt0Wv4AeNYsE286etLz7qOTbA04btrjb6BGjP7nxsX0+u2uRMhkxRpFGKWsFaASQJP4qwCMxWDJlT+qdbbnEYWzeukTiX8rsQUyPnieW6AGpAlHJSFkm6JvUpgR11f+uAM8DRmoZx7Jw28iXftMQ7zWcSTc7aMOLt5308c/+TXilwMsDKfW+B2gK2ChXPz6SoANJlQtFbkT7z3MPTP1QkfSO953AMhxBMjesbbI6ej/NwxjMgU/66uhE8J91BRi9T799TWxagJn3FVgLMFdIRmV3XeoC/WE+2HrMkNLzQdTi9A79ttSSRGBqS+8aMU+PUVIa5IFhWSo6GCdIVODnSjpFlERzbkmLCSa5YpuOBk0Swwm7lDFIU1Ddk3RPA6syJtEt6m7pIGEtzVzu6TZzZ197veF3ivJz9XXYEezRyK1BS8Xp9b4zLpVTNt1XbLZAfGCzD2ieNDfQ6sKU+ExitHbVocp6+kWz13wdfyEcCDqjDWOM9z4H/tvQlN6n3+PwTpMrDJH1syY8Rqaf4K7EJzHGDyoddUOw93qjgHH1mCGLOLC++yvz928Plf37tT+J/55x/IYOVwuAxHdmLbIomKuUD0SFvGECNud9UX+IzamtgdqfUekaSX5R2OOdc+Qw7c7jgV14t4ZWAPqBW4N+8VvK+xvs9PJ/A2go74nnxlyLxQNGh5pHhWZQTDCn9ko6jWsunrnPry3XcTgnzkZ6QEYSSMAg9TUlXYlymdmx0nEuWZOIn5/lzLE0eGrA84Dvk96Hdtll3YtrbQ+k6D49p80KZEohxSXtGtBgR3/p923DX/5VTbzvsVTomGj9+IhPr75kZN1Ta+i3gywVSHWJ7ernY2TXNT5kdTA3XobuW/khZ0LPuvnM0NcKk/Uia9i5VLoZIEumJe8T5KUKlitUNmU8Q+n4t/1n6Lx6Lx3KIks2de+TFWDqMTrNlMCR8rT0NdqUwATNco91kgnLLwsBsaWBVz8H5nDJYtqur8BTid2UJgGra3HvpIHgGgEkKVGUSOyCu0zqZyg9BgJPrhwS6LuUlgJaYXHhyJLYisxNkkptgqH/3R/kAUKaSmddgdA88Pex+xMwoBSeyT4ATg2WCjg1+IPYoioggSKBIQGjJ0YrWuwFGgmxUcM7KIotUTwohj1KGcHl9dX3ZH/RFj7J9y/r1JROnS8kjmMMq1wbP+r03Ul15jsbBYxrxg6+k2xJPWbM92Kqtw2PG35of8+22LOOgDrmJzSbom5vCjULMEn/utFBeRY3490cu/NZo+fTqEDSi1Sv5FWv7N4qpWUq739B6ED9UACSBggGZaBONtQgBJif9dkHb3znLHzaZz8IP+S/l50t0mu7NS15+ZCPr31mQO27tcRpCbwc4UrLUjpFQeOLmI4StMBElkH2TbdOdCwsqk2WPgtXAx39s+k+gJk7/GyHFC+3f7DkqkXSAk0ZGXc0YKnfHgBJi6nrpByOW5DXj/jPFQ3xnqdR8eKyZeapSy64eOem15tM5XHCZjLlX/AOpUiQzdr/JIFkDLI1BSTt8HV1LcbU8Tv0DDlntJAY29rquInCLhZEUIjAm6PLShPpKyN0Co1ZRq3gfYg+0VeiCyXeX5YFS9LZONGh6j9E17OS0X16znyQ2eG8MmlweiZtaxClpiCPMDVGfFW2C0bvBddtSQDHFAgToFkaGDUYx4xrksG/t7LHWNaaPDnbecM1TufGLwgYHQJJR/IYPaP1iJyAkyiYSyCZlqUla9NTpEQ8b1umyRBDQYINQIwCZh6g5vSH1MOv7nUJRvz3PpS2bvAS0fNHhQTzWKFmiNroooFT6x8UgG0M8kTBw3w3gpqW0pCIEzo96E5rG53avrsxxcOaMYP3BWOvS5sP7fni+/PbSrruVOzALfutrIvuPqaZUnHBkHLG7jU/bYU5eahaPGcFjL7oS6xRue94Ry6TPKpYYthXJADFAmwwaCDtHOf1fg5D1WDwixN5P2uXYE3nndGa7Cw+Hjj60qrWxYtHLpvyBTFAy4bIusTamAKtWIyipGUVoMU8NihdNe0lTaS+TnrKChsnu3bCIWAjgJMeCMks5F9Hz/nrOfOO+FWXzNqsjwxKXZ9lssR7rhlAaYxJ9TcO9feGnV6/qCXW5bK4aH7gwiWHX97FWRoo/GQcsjwJKTOQDSTzpyFLyY3H+2Rb4TZ31uA2cANcDIbEib5xO2/h6ajSaJPHc6FjyfEY+OLVsJMOeIyAxAfRJrBupWA1JWANLng1gLo6fb5fUIAqgHnMk5M7bOTTnAYrBzkmA82kyi4H+Q4wNBOE608L+QrEJeMecLY6GlRpgaAYJ6VxsJQjWToGVuKClSzvcyRrLbkWahWQNbKq4YzmLms/JLAlIM4yybNZcALYhB1j/neWFaWJdZkZkqzbxuQJ1Fc+MSkCgGqO+tvO6BkFoDkUNcH23UGn4vkD/4B95/4NY9/8c7ASBrxCsUmyQHvH5xAYWp5u0TtRN9qYphTtz/eQ378xx5Q6IDy8cj3DyLcKtdmss2/XKSBV1SZ9NgoYKYe1Y4e8CIaa7i/PP6VYjqtORLfSGJ/pSDYoqLDBqtR7oZbwfCV8tZ/RsXmWk+hqYbLMYJXzwJEU/8pQ4jl8EyB6orYyisg4Ym4vMJRA8Do49uqANKoiFANKowzR4Cn6t7E7QQE7c5vL+V4yzuticQgCKwK1uIAgpiLJM86CTNIZ7zaTIgNJrCpZwoRIM9lLNu1puTi4pqriavJHKEtByjiTFOO8ItEgp+xyz4CPq0bfd8Vr2x9YlYAkp9LqZI651dDvUv2b1vfOLZC0XIkWSNEMefegx3ocvvCkNT0qIft28t4j09poOGxMDgg3aYRtwS+RYWPxzxC3O+dA0a4CsxrCIMnLwKgd/aquawLr4f2gezWtYJ1LIOkvnX9Y1wryRVAjhZeCNabBqlClQDW2rO8vmMsvzzWbXO12qxmbqmioYXEwAtbyOJTvAgFrmktO7NgSoqykxn1Pu/gYjR5gm/7iy0DGj9DX4BkjDQLM1kQ1VncehLcHn44Ptz9UZdB9w4c47/HDQqKgr3P3nbiVvtJnkL6Bx2eMJiaYUldUujTHUPSd6Pjy9Y1MLnFSYv9uT2HVpgzBjQbGdWN230VAvMcYO637jA8eL5Rp3SnsSRfsuA5FWtmUUrfzjm+dVuzQY4+kdyRuoxmlbl07vSOYzC2wbuJzSN4cBkQTBA2wDAFn9LrPcv3JwZBNlcQGpWKx+pJSJmRKg1pZBRfEUirjdVIkIKtLIDes1y917ge5dh3glkLuWo8rHeCJmnIolu5UhrUS13xnye8E7GGXvTLgyHRnyMEAFiwEUp0gh/eCfHwhZLdBtN0IAlfpU1a+hmb/n0nSJyzeeVwMvwPDwgijHJT7PVOtMcCcVWAUTmpBLRgG6eZK1ITfsxvBSpcNIWdlpfNVHy4fkXssUL52vAWsphzM8sC1IQNWjWpkRLqsc0v6EylREurcEMAV6CKfTNAtg00GPz0gmnzow/i0dy6gS2mqBmc+cyK61S1WcykXvIQMODpwr69L9A06PmhGycTXNXAsJmd2elSO2ZT0NxoYKZO1Y4eeLiFvZVwc1v2lhfqAY+Oz4URcyRi7SslY5smQHruLxppV/WGIy37DmWKAfz94zPui/pisUeXpxcnzxWpKyDsFU62IVCa3AjzVP1RuaddDJlfoa9oRTRt7DVk5d2qeN4qiwOmnaFy3ORYtT8qR2RLIHmWQTi2kU5EDp/RqSAIxerXxY0iaRDMPzBVt3y/wQKw3cifeX+V7LepynvnUso/AsGDysf1zk2lTRsO2d76xFigo9nsjr/bgoYOzQr5vFMa17MyQLpmPCYUwZ2cNpslasERP/Z3GUB+wN7MSOpRfCB1zkysqhkafDc05rwD0zufdR+DOI55UV8pa1+P0F09Drw2eNi0kDXoqJ0/fqOaOZ2wJVGL+6Yv+tI+gUO5YHC8tE7wjPeTPf/XXn5IeaxSQ13d7DG0aYop1+CYBIyW2ZuyQ3wH4OYCf9Jgxf6qZQe0xqJZxzIRk3/GP9NA+w74C10DBApYU9VxQUx8BTZ7j93rOzh9OO6oj0SuaYoq+8THVByxLmiX6CCC5BojVEWLmUNoExADho02pfcT88EjaNU+XmQaCzdHsuji+8xD8+/GFYCcOgsRVADXe7/KHbx6Tk+ehk+vg9/ZduKhQJ/7kqRU720x8BMamTj6m33Hf2MzeltHX2gJrxw5ZLoG+QSZMXt3j5QVXmplGwXXdcdg/buFZR6IiEJl9pAvp78OGFOM83WDs5nlqQOLB0XcikW3CoXOvQ0XLGm/06kmiR32uRFqjpOenvu7r6M0a5EzRsrknZKoLwLNg8QawkvXKouWtFQHSezOr6L5ZJaVrr5IPbVvuX/kIPBls47prk4FRgeOYIbcBOE8yXNNDzP8dm5nTR607ChU8jjMZMCKI4rBxZdvkp42AyH6P+b3n15e5dbseL6VNqmCHlS3/J4vXu8qpWrvA5FTw+iySnGomNwpC5TOh3hsT5DG0hkvc3eVJLNjUyjhn4xjCWPsuhBYfP70zpi07g0lMBvDS5GP7H7Kp+Wx7b/NqgTVjhrwFhr38UjHgje4z5u/XXinXHYVdEMNPLaB3ofhV5txgMUXlgp040WGvniXPeXJkJP9JY0ulvzVSbRNVPmOhkpGXrN4PRN60yoEu9/GO7VYX1C4kmoQ1u54opXEYNs/CLl85h8WaOrDH1khcO5z8lzv4x/+3d7WxTZVR+Dn9WBk4BjLWDdmmyBC2zg9C4g+/YIUpxAxKVIjGIKUgiBKJP4zEECDRxBh/kCEJbN0w/jAGYkdggsC6KUJUVJB1w8wfaiewdW5B0cDW9R7z9mN00G39uGs3ec/P3vOec97nNufe956vybUYkIIzHHY3uexY2G/l7VxQvFkheh+MCwro1dyGpi8Tkzjyqz0Lix5lRXMy4ON4V46zOeLb2MhbMryGXht2XmNsz7RDxFBuIWutexcYGwH8WG3JH7Qj+vCaJMdoQsBjNp1lxoNhNnUbnS4Ru/nfUffCGZm9yngHAY+H5eKLfV7TMy+6s6H5VLI3ndAbY8hYj7n4KWaqgnhKEY4R086pzqajo/Ej/y+LZxom9o5rBAefxoQyY73reLKBj1afdy0+01di0COytdZ9HAzRzaKz2pLnT42SNLYR4Geh9XSZPARkMOMKCK1E+Cq73rVlbO9saOuDgd1dIPF/7qeuNEU3b3LjuahLkNXASBXHKAzxzC+6gzUa0ZVikz/7HvwbgQ5B4c97DPgu74vmiG88Yi0XFaW1G1GY29AS95EzGjDaF5aUaBSuYKA/tKFVaE5WY9PP0axPNg/bMKeP8LK+Eq8PpntNrdvFjGJxbJmQNn5SxZIpIuVQkkRgTCIgSiH/LDV9qADrb2yATxqdzeJtMmmkmmMMWdxuLplB4PVgrAaQFfqdwJdEWhgBfzHoKqCkgWkSCCLl6z4Rp0g36HMyjpwdkZGIHWbTWQw8mgjT/s02XJ8SS5egpN0ZkcxrwzZinNHZMUjLcsBa2+YGc57/AUPaR2qW3XU6mTZKXRIBtREQzrGz1HSCgfBUm+U3B3nV1hsuT3XHGBL+6/y7x2VQxpNM/JgCiNrqB4JVVAP3w+gE+DS0dMrX11szrbE1rijScCB1mIv3gGld2FNIYdZsyGlo2jvc2lRcF8cpbyZa9T24nz4WtRSRyepwi5TIQOcK0KZqS15FKuyVOiUCaiLQZS4u6lPIFQrcMqEup971tJo6hpI1Yo4xktKuxTMn9vWMm8qKL12rV7qv6HxdhTH0dEwEFM8Ck5UJ9qAD+VYL2pLlPO9MROZIru2x4RkwrAY7lgylx+po2wZQAUi5zhpNXU359MMjaZeULREIIbC61r0CjPVareatqvLp38SDzKX5s7J02rSlYCXdpyiHc8PaGd4UgOoyOl39J9B4dMWyJqmOMRbD1ObtNM+exay1KMyNOQ0twaESamtRRx6/BoP3Gs4zY7vBjrhatqtjiZQiERgcAavDLYZQlfm/4hB9YF+WJ/obRk2dpXPm+qA5RoFKSXHiqTc6m/oDL+1m0xlizAtc47+NzubMqIUnyHjbOMYEcUrq8l4b9hBhpY6QS3v9zWgkSQRGHQJWh1t89vI7NQKO2y35wklGTZ5SU2N4IJSAq41TXJOf2w9fMFAqar8DrTQZJ4wNrqTl6UrHGPVtTA6jdy22M2MrAe/oq/B2crRKLRKB2BGwOtzioS16WAi6XG3JnxaLlI5Sk+iJ4m9PxODNOsKp9sv8U3YWilmnEbOlZgTliT7nZVn1TSdikZ8Ir3SMiaCn4lp+ERO8BohKolUEdOv6cC/tiz9zX0XTpCiJQEQErI62VoALQxcV+B7aZ7nnXLRweUpNFxiY7XeMGlomBjURaVcCLKaQ3hh/ybzV2NAcPpslWhVx80nHGDd06izkddB7FYiB1TsAFPilEjamVWK3OhqkFInAyCCw5qB7NyvYECbdXm3Jt0WrLdiMpmYI/otEeCO73vVptDLV4pOOUS0kY5TjXYs3WfGXfC0CBb7TBOmTtCo8H6M4yS4RSDoCLx1qK9T4+Dw40Pzc39Bcy3M/Ki+IulCjw1zygsh7DpY/iubevzPoay376to7cMTU0hI+CSNpe5SOMWlQD1TktaGOcUsqzg/6HjwxVN5iisyVaiUCERFYc/CPVayw3T9AQxDzgerlBTcGTY1R3KRjTNGN67NhnQLsCakn4KguHSuoArKkL0X3RKqNDwGrw11GoPcU4gM1S/Pe7R+dG5+4UbFKOsYU3QZ+BTneXlxk4DIBO/RVqByNTTdSBI9UKxFIKQLSMaYQ/t7VeFj/D76n/ZGn5aXQNKlaInBbI/Af7NFDa4Ye3CIAAAAASUVORK5CYII="},16722:function(Xt,Mt,be){"use strict";be.d(Mt,{Z:function(){return ee}});const ce=ne=>typeof ne=="object"&&ne!=null&&ne.nodeType===1,ie=(ne,E)=>(!E||ne!=="hidden")&&ne!=="visible"&&ne!=="clip",Ce=(ne,E)=>{if(ne.clientHeight<ne.scrollHeight||ne.clientWidth<ne.scrollWidth){const b=getComputedStyle(ne,null);return ie(b.overflowY,E)||ie(b.overflowX,E)||(z=>{const x=(re=>{if(!re.ownerDocument||!re.ownerDocument.defaultView)return null;try{return re.ownerDocument.defaultView.frameElement}catch(ae){return null}})(z);return!!x&&(x.clientHeight<z.scrollHeight||x.clientWidth<z.scrollWidth)})(ne)}return!1},ue=(ne,E,b,z,x,re,ae,oe)=>re<ne&&ae>E||re>ne&&ae<E?0:re<=ne&&oe<=b||ae>=E&&oe>=b?re-ne-z:ae>E&&oe<b||re<ne&&oe>b?ae-E+x:0,se=ne=>{const E=ne.parentElement;return E==null?ne.getRootNode().host||null:E},te=(ne,E)=>{var b,z,x,re;if(typeof document=="undefined")return[];const{scrollMode:ae,block:oe,inline:ve,boundary:ye,skipOverflowHiddenElements:me}=E,ge=typeof ye=="function"?ye:nt=>nt!==ye;if(!ce(ne))throw new TypeError("Invalid target");const _e=document.scrollingElement||document.documentElement,he=[];let pe=ne;for(;ce(pe)&&ge(pe);){if(pe=se(pe),pe===_e){he.push(pe);break}pe!=null&&pe===document.body&&Ce(pe)&&!Ce(document.documentElement)||pe!=null&&Ce(pe,me)&&he.push(pe)}const ke=(z=(b=window.visualViewport)==null?void 0:b.width)!=null?z:innerWidth,Te=(re=(x=window.visualViewport)==null?void 0:x.height)!=null?re:innerHeight,{scrollX:Ee,scrollY:Oe}=window,{height:je,width:Pe,top:Qe,right:Xe,bottom:ot,left:He}=ne.getBoundingClientRect(),{top:rt,right:Ye,bottom:ut,left:Ge}=(nt=>{const et=window.getComputedStyle(nt);return{top:parseFloat(et.scrollMarginTop)||0,right:parseFloat(et.scrollMarginRight)||0,bottom:parseFloat(et.scrollMarginBottom)||0,left:parseFloat(et.scrollMarginLeft)||0}})(ne);let ze=oe==="start"||oe==="nearest"?Qe-rt:oe==="end"?ot+ut:Qe+je/2-rt+ut,Ve=ve==="center"?He+Pe/2-Ge+Ye:ve==="end"?Xe+Ye:He-Ge;const $e=[];for(let nt=0;nt<he.length;nt++){const et=he[nt],{height:pt,width:ct,top:Ot,right:dt,bottom:Rt,left:xt}=et.getBoundingClientRect();if(ae==="if-needed"&&Qe>=0&&He>=0&&ot<=Te&&Xe<=ke&&(et===_e&&!Ce(et)||Qe>=Ot&&ot<=Rt&&He>=xt&&Xe<=dt))return $e;const gt=getComputedStyle(et),_t=parseInt(gt.borderLeftWidth,10),We=parseInt(gt.borderTopWidth,10),Ae=parseInt(gt.borderRightWidth,10),Se=parseInt(gt.borderBottomWidth,10);let Be=0,Ke=0;const Ne="offsetWidth"in et?et.offsetWidth-et.clientWidth-_t-Ae:0,De="offsetHeight"in et?et.offsetHeight-et.clientHeight-We-Se:0,we="offsetWidth"in et?et.offsetWidth===0?0:ct/et.offsetWidth:0,Le="offsetHeight"in et?et.offsetHeight===0?0:pt/et.offsetHeight:0;if(_e===et)Be=oe==="start"?ze:oe==="end"?ze-Te:oe==="nearest"?ue(Oe,Oe+Te,Te,We,Se,Oe+ze,Oe+ze+je,je):ze-Te/2,Ke=ve==="start"?Ve:ve==="center"?Ve-ke/2:ve==="end"?Ve-ke:ue(Ee,Ee+ke,ke,_t,Ae,Ee+Ve,Ee+Ve+Pe,Pe),Be=Math.max(0,Be+Oe),Ke=Math.max(0,Ke+Ee);else{Be=oe==="start"?ze-Ot-We:oe==="end"?ze-Rt+Se+De:oe==="nearest"?ue(Ot,Rt,pt,We,Se+De,ze,ze+je,je):ze-(Ot+pt/2)+De/2,Ke=ve==="start"?Ve-xt-_t:ve==="center"?Ve-(xt+ct/2)+Ne/2:ve==="end"?Ve-dt+Ae+Ne:ue(xt,dt,ct,_t,Ae+Ne,Ve,Ve+Pe,Pe);const{scrollLeft:Ue,scrollTop:Me}=et;Be=Le===0?0:Math.max(0,Math.min(Me+Be/Le,et.scrollHeight-pt/Le+De)),Ke=we===0?0:Math.max(0,Math.min(Ue+Ke/we,et.scrollWidth-ct/we+Ne)),ze+=Me-Be,Ve+=Ue-Ke}$e.push({el:et,top:Be,left:Ke})}return $e},le=ne=>ne===!1?{block:"end",inline:"nearest"}:(E=>E===Object(E)&&Object.keys(E).length!==0)(ne)?ne:{block:"start",inline:"nearest"};function ee(ne,E){if(!ne.isConnected||!(x=>{let re=x;for(;re&&re.parentNode;){if(re.parentNode===document)return!0;re=re.parentNode instanceof ShadowRoot?re.parentNode.host:re.parentNode}return!1})(ne))return;const b=(x=>{const re=window.getComputedStyle(x);return{top:parseFloat(re.scrollMarginTop)||0,right:parseFloat(re.scrollMarginRight)||0,bottom:parseFloat(re.scrollMarginBottom)||0,left:parseFloat(re.scrollMarginLeft)||0}})(ne);if((x=>typeof x=="object"&&typeof x.behavior=="function")(E))return E.behavior(te(ne,E));const z=typeof E=="boolean"||E==null?void 0:E.behavior;for(const{el:x,top:re,left:ae}of te(ne,le(E))){const oe=re-b.top+b.bottom,ve=ae-b.left+b.right;x.scroll({top:oe,left:ve,behavior:z})}}}}]);
|