(window.webpackJsonp=window.webpackJsonp||[]).push([[163,3,6,8],{"+QRC": /*!*************************************************!*\ !*** ./node_modules/copy-to-clipboard/index.js ***! \*************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";var r=n(/*! toggle-selection */"E9nw"),i={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var n,o,s,a,c,l,u=!1;t||(t={}),n=t.debug||!1;try{if(s=r(),a=document.createRange(),c=document.getSelection(),(l=document.createElement("span")).textContent=e,l.style.all="unset",l.style.position="fixed",l.style.top=0,l.style.clip="rect(0, 0, 0, 0)",l.style.whiteSpace="pre",l.style.webkitUserSelect="text",l.style.MozUserSelect="text",l.style.msUserSelect="text",l.style.userSelect="text",l.addEventListener("copy",(function(r){if(r.stopPropagation(),t.format)if(r.preventDefault(),void 0===r.clipboardData){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var o=i[t.format]||i.default;window.clipboardData.setData(o,e)}else r.clipboardData.clearData(),r.clipboardData.setData(t.format,e);t.onCopy&&(r.preventDefault(),t.onCopy(r.clipboardData))})),document.body.appendChild(l),a.selectNodeContents(l),c.addRange(a),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");u=!0}catch(r){n&&console.error("unable to copy using execCommand: ",r),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(r){n&&console.error("unable to copy using clipboardData: ",r),n&&console.error("falling back to prompt"),o=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(o,e)}}finally{c&&("function"==typeof c.removeRange?c.removeRange(a):c.removeAllRanges()),l&&document.body.removeChild(l),s()}return u}},"/POA": /*!*****************************************!*\ !*** ./node_modules/xterm/lib/xterm.js ***! \*****************************************/ /*! no static exports found */ /*! exports used: Terminal */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){window,e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=34)}([function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.forwardEvent=t.EventEmitter=void 0;var r=function(){function e(){this._listeners=[],this._disposed=!1}return Object.defineProperty(e.prototype,"event",{get:function(){var e=this;return this._event||(this._event=function(t){return e._listeners.push(t),{dispose:function(){if(!e._disposed)for(var n=0;n>22},t.prototype.getChars=function(){return 2097152&this.content?this.combinedData:2097151&this.content?o.stringFromCodePoint(2097151&this.content):""},t.prototype.getCode=function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content},t.prototype.setFromCharData=function(e){this.fg=e[s.CHAR_DATA_ATTR_INDEX],this.bg=0;var t=!1;if(e[s.CHAR_DATA_CHAR_INDEX].length>2)t=!0;else if(2===e[s.CHAR_DATA_CHAR_INDEX].length){var n=e[s.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=n&&n<=56319){var r=e[s.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=r&&r<=57343?this.content=1024*(n-55296)+r-56320+65536|e[s.CHAR_DATA_WIDTH_INDEX]<<22:t=!0}else t=!0}else this.content=e[s.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|e[s.CHAR_DATA_WIDTH_INDEX]<<22;t&&(this.combinedData=e[s.CHAR_DATA_CHAR_INDEX],this.content=2097152|e[s.CHAR_DATA_WIDTH_INDEX]<<22)},t.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},t}(a.AttributeData);t.CellData=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ISoundService=t.ISelectionService=t.IRenderService=t.IMouseService=t.ICoreBrowserService=t.ICharSizeService=void 0;var r=n(14);t.ICharSizeService=r.createDecorator("CharSizeService"),t.ICoreBrowserService=r.createDecorator("CoreBrowserService"),t.IMouseService=r.createDecorator("MouseService"),t.IRenderService=r.createDecorator("RenderService"),t.ISelectionService=r.createDecorator("SelectionService"),t.ISoundService=r.createDecorator("SoundService")},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ExtendedAttrs=t.AttributeData=void 0;var r=function(){function e(){this.fg=0,this.bg=0,this.extended=new i}return e.toColorRGB=function(e){return[e>>>16&255,e>>>8&255,255&e]},e.fromColorRGB=function(e){return(255&e[0])<<16|(255&e[1])<<8|255&e[2]},e.prototype.clone=function(){var t=new e;return t.fg=this.fg,t.bg=this.bg,t.extended=this.extended.clone(),t},e.prototype.isInverse=function(){return 67108864&this.fg},e.prototype.isBold=function(){return 134217728&this.fg},e.prototype.isUnderline=function(){return 268435456&this.fg},e.prototype.isBlink=function(){return 536870912&this.fg},e.prototype.isInvisible=function(){return 1073741824&this.fg},e.prototype.isItalic=function(){return 67108864&this.bg},e.prototype.isDim=function(){return 134217728&this.bg},e.prototype.getFgColorMode=function(){return 50331648&this.fg},e.prototype.getBgColorMode=function(){return 50331648&this.bg},e.prototype.isFgRGB=function(){return 50331648==(50331648&this.fg)},e.prototype.isBgRGB=function(){return 50331648==(50331648&this.bg)},e.prototype.isFgPalette=function(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)},e.prototype.isBgPalette=function(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)},e.prototype.isFgDefault=function(){return 0==(50331648&this.fg)},e.prototype.isBgDefault=function(){return 0==(50331648&this.bg)},e.prototype.isAttributeDefault=function(){return 0===this.fg&&0===this.bg},e.prototype.getFgColor=function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}},e.prototype.getBgColor=function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}},e.prototype.hasExtendedAttrs=function(){return 268435456&this.bg},e.prototype.updateExtended=function(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456},e.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()},e.prototype.getUnderlineColorMode=function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648&this.extended.underlineColor:this.getFgColorMode()},e.prototype.isUnderlineColorRGB=function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648==(50331648&this.extended.underlineColor):this.isFgRGB()},e.prototype.isUnderlineColorPalette=function(){return 268435456&this.bg&&~this.extended.underlineColor?16777216==(50331648&this.extended.underlineColor)||33554432==(50331648&this.extended.underlineColor):this.isFgPalette()},e.prototype.isUnderlineColorDefault=function(){return 268435456&this.bg&&~this.extended.underlineColor?0==(50331648&this.extended.underlineColor):this.isFgDefault()},e.prototype.getUnderlineStyle=function(){return 268435456&this.fg?268435456&this.bg?this.extended.underlineStyle:1:0},e}();t.AttributeData=r;var i=function(){function e(e,t){void 0===e&&(e=0),void 0===t&&(t=-1),this.underlineStyle=e,this.underlineColor=t}return e.prototype.clone=function(){return new e(this.underlineStyle,this.underlineColor)},e.prototype.isEmpty=function(){return 0===this.underlineStyle},e}();t.ExtendedAttrs=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addDisposableDomListener=void 0,t.addDisposableDomListener=function(e,t,n,r){e.addEventListener(t,n,r);var i=!1;return{dispose:function(){i||(i=!0,e.removeEventListener(t,n,r))}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ToUtf32=t.StringToUtf32=t.utf32ToString=t.stringFromCodePoint=void 0,t.stringFromCodePoint=function(e){return e>65535?(e-=65536,String.fromCharCode(55296+(e>>10))+String.fromCharCode(e%1024+56320)):String.fromCharCode(e)},t.utf32ToString=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=e.length);for(var r="",i=t;i65535?(o-=65536,r+=String.fromCharCode(55296+(o>>10))+String.fromCharCode(o%1024+56320)):r+=String.fromCharCode(o)}return r};var r=function(){function e(){this._interim=0}return e.prototype.clear=function(){this._interim=0},e.prototype.decode=function(e,t){var n=e.length;if(!n)return 0;var r=0,i=0;this._interim&&(56320<=(a=e.charCodeAt(i++))&&a<=57343?t[r++]=1024*(this._interim-55296)+a-56320+65536:(t[r++]=this._interim,t[r++]=a),this._interim=0);for(var o=i;o=n)return this._interim=s,r;var a;56320<=(a=e.charCodeAt(o))&&a<=57343?t[r++]=1024*(s-55296)+a-56320+65536:(t[r++]=s,t[r++]=a)}else t[r++]=s}return r},e}();t.StringToUtf32=r;var i=function(){function e(){this.interim=new Uint8Array(3)}return e.prototype.clear=function(){this.interim.fill(0)},e.prototype.decode=function(e,t){var n=e.length;if(!n)return 0;var r,i,o,s,a=0,c=0,l=0;if(this.interim[0]){var u=!1,h=this.interim[0];h&=192==(224&h)?31:224==(240&h)?15:7;for(var d=0,f=void 0;(f=63&this.interim[++d])&&d<4;)h<<=6,h|=f;for(var p=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,_=p-d;l<_;){if(l>=n)return 0;if(128!=(192&(f=e[l++]))){l--,u=!0;break}this.interim[d++]=f,h<<=6,h|=63&f}u||(2===p?h<128?l--:t[a++]=h:3===p?h<2048||h>=55296&&h<=57343||(t[a++]=h):h<65536||h>1114111||(t[a++]=h)),this.interim.fill(0)}for(var v=n-4,b=l;b=n)return this.interim[0]=r,a;if(128!=(192&(i=e[b++]))){b--;continue}if((c=(31&r)<<6|63&i)<128){b--;continue}t[a++]=c}else if(224==(240&r)){if(b>=n)return this.interim[0]=r,a;if(128!=(192&(i=e[b++]))){b--;continue}if(b>=n)return this.interim[0]=r,this.interim[1]=i,a;if(128!=(192&(o=e[b++]))){b--;continue}if((c=(15&r)<<12|(63&i)<<6|63&o)<2048||c>=55296&&c<=57343)continue;t[a++]=c}else if(240==(248&r)){if(b>=n)return this.interim[0]=r,a;if(128!=(192&(i=e[b++]))){b--;continue}if(b>=n)return this.interim[0]=r,this.interim[1]=i,a;if(128!=(192&(o=e[b++]))){b--;continue}if(b>=n)return this.interim[0]=r,this.interim[1]=i,this.interim[2]=o,a;if(128!=(192&(s=e[b++]))){b--;continue}if((c=(7&r)<<18|(63&i)<<12|(63&o)<<6|63&s)<65536||c>1114111)continue;t[a++]=c}}return a},e}();t.Utf8ToUtf32=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CHAR_ATLAS_CELL_SPACING=t.DIM_OPACITY=t.INVERTED_DEFAULT_COLOR=void 0,t.INVERTED_DEFAULT_COLOR=257,t.DIM_OPACITY=.5,t.CHAR_ATLAS_CELL_SPACING=1},function(e,t,n){"use strict";var r,i,o,s;function a(e){var t=e.toString(16);return t.length<2?"0"+t:t}function c(e,t){return e>>0}}(r=t.channels||(t.channels={})),(i=t.color||(t.color={})).blend=function(e,t){var n=(255&t.rgba)/255;if(1===n)return{css:t.css,rgba:t.rgba};var i=t.rgba>>24&255,o=t.rgba>>16&255,s=t.rgba>>8&255,a=e.rgba>>24&255,c=e.rgba>>16&255,l=e.rgba>>8&255,u=a+Math.round((i-a)*n),h=c+Math.round((o-c)*n),d=l+Math.round((s-l)*n);return{css:r.toCss(u,h,d),rgba:r.toRgba(u,h,d)}},i.isOpaque=function(e){return 255==(255&e.rgba)},i.ensureContrastRatio=function(e,t,n){var r=s.ensureContrastRatio(e.rgba,t.rgba,n);if(r)return s.toColor(r>>24&255,r>>16&255,r>>8&255)},i.opaque=function(e){var t=(255|e.rgba)>>>0,n=s.toChannels(t),i=n[0],o=n[1],a=n[2];return{css:r.toCss(i,o,a),rgba:t}},i.opacity=function(e,t){var n=Math.round(255*t),i=s.toChannels(e.rgba),o=i[0],a=i[1],c=i[2];return{css:r.toCss(o,a,c,n),rgba:r.toRgba(o,a,c,n)}},(t.css||(t.css={})).toColor=function(e){switch(e.length){case 7:return{css:e,rgba:(parseInt(e.slice(1),16)<<8|255)>>>0};case 9:return{css:e,rgba:parseInt(e.slice(1),16)>>>0}}throw new Error("css.toColor: Unsupported css format")},function(e){function t(e,t,n){var r=e/255,i=t/255,o=n/255;return.2126*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))+.7152*(i<=.03928?i/12.92:Math.pow((i+.055)/1.055,2.4))+.0722*(o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4))}e.relativeLuminance=function(e){return t(e>>16&255,e>>8&255,255&e)},e.relativeLuminance2=t}(o=t.rgb||(t.rgb={})),function(e){function t(e,t,n){for(var r=e>>24&255,i=e>>16&255,s=e>>8&255,a=t>>24&255,l=t>>16&255,u=t>>8&255,h=c(o.relativeLuminance2(a,u,l),o.relativeLuminance2(r,i,s));h0||l>0||u>0);)a-=Math.max(0,Math.ceil(.1*a)),l-=Math.max(0,Math.ceil(.1*l)),u-=Math.max(0,Math.ceil(.1*u)),h=c(o.relativeLuminance2(a,u,l),o.relativeLuminance2(r,i,s));return(a<<24|l<<16|u<<8|255)>>>0}function n(e,t,n){for(var r=e>>24&255,i=e>>16&255,s=e>>8&255,a=t>>24&255,l=t>>16&255,u=t>>8&255,h=c(o.relativeLuminance2(a,u,l),o.relativeLuminance2(r,i,s));h>>0}e.ensureContrastRatio=function(e,r,i){var s=o.relativeLuminance(e>>8),a=o.relativeLuminance(r>>8);if(c(s,a)>24&255,e>>16&255,e>>8&255,255&e]},e.toColor=function(e,t,n){return{css:r.toCss(e,t,n),rgba:r.toRgba(e,t,n)}}}(s=t.rgba||(t.rgba={})),t.toPaddedHex=a,t.contrastRatio=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isLinux=t.isWindows=t.isIphone=t.isIpad=t.isMac=t.isSafari=t.isFirefox=void 0;var r="undefined"==typeof navigator,i=r?"node":navigator.userAgent,o=r?"node":navigator.platform;function s(e,t){return e.indexOf(t)>=0}t.isFirefox=!!~i.indexOf("Firefox"),t.isSafari=/^((?!chrome|android).)*safari/i.test(i),t.isMac=s(["Macintosh","MacIntel","MacPPC","Mac68K"],o),t.isIpad="iPad"===o,t.isIphone="iPhone"===o,t.isWindows=s(["Windows","Win16","Win32","WinCE"],o),t.isLinux=o.indexOf("Linux")>=0},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.C1=t.C0=void 0,function(e){e.NUL="\0",e.SOH="",e.STX="",e.ETX="",e.EOT="",e.ENQ="",e.ACK="",e.BEL="",e.BS="\b",e.HT="\t",e.LF="\n",e.VT="\v",e.FF="\f",e.CR="\r",e.SO="",e.SI="",e.DLE="",e.DC1="",e.DC2="",e.DC3="",e.DC4="",e.NAK="",e.SYN="",e.ETB="",e.CAN="",e.EM="",e.SUB="",e.ESC="",e.FS="",e.GS="",e.RS="",e.US="",e.SP=" ",e.DEL=""}(t.C0||(t.C0={})),function(e){e.PAD="€",e.HOP="",e.BPH="‚",e.NBH="ƒ",e.IND="„",e.NEL="…",e.SSA="†",e.ESA="‡",e.HTS="ˆ",e.HTJ="‰",e.VTS="Š",e.PLD="‹",e.PLU="Œ",e.RI="",e.SS2="Ž",e.SS3="",e.DCS="",e.PU1="‘",e.PU2="’",e.STS="“",e.CCH="”",e.MW="•",e.SPA="–",e.EPA="—",e.SOS="˜",e.SGCI="™",e.SCI="š",e.CSI="›",e.ST="œ",e.OSC="",e.PM="ž",e.APC="Ÿ"}(t.C1||(t.C1={}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseRenderLayer=void 0;var r=n(3),i=n(9),o=n(25),s=n(6),a=n(28),c=n(10),l=n(17),u=function(){function e(e,t,n,r,i,o,s,a){this._container=e,this._alpha=r,this._colors=i,this._rendererId=o,this._bufferService=s,this._optionsService=a,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-"+t+"-layer"),this._canvas.style.zIndex=n.toString(),this._initCanvas(),this._container.appendChild(this._canvas)}return e.prototype.dispose=function(){var e;l.removeElementFromParent(this._canvas),null===(e=this._charAtlas)||void 0===e||e.dispose()},e.prototype._initCanvas=function(){this._ctx=a.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(e,t){},e.prototype.onSelectionChanged=function(e,t,n){void 0===n&&(n=!1)},e.prototype.setColors=function(e){this._refreshCharAtlas(e)},e.prototype._setTransparency=function(e){if(e!==this._alpha){var t=this._canvas;this._alpha=e,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,t),this._refreshCharAtlas(this._colors),this.onGridChanged(0,this._bufferService.rows-1)}},e.prototype._refreshCharAtlas=function(e){this._scaledCharWidth<=0&&this._scaledCharHeight<=0||(this._charAtlas=o.acquireCharAtlas(this._optionsService.options,this._rendererId,e,this._scaledCharWidth,this._scaledCharHeight),this._charAtlas.warmUp())},e.prototype.resize=function(e){this._scaledCellWidth=e.scaledCellWidth,this._scaledCellHeight=e.scaledCellHeight,this._scaledCharWidth=e.scaledCharWidth,this._scaledCharHeight=e.scaledCharHeight,this._scaledCharLeft=e.scaledCharLeft,this._scaledCharTop=e.scaledCharTop,this._canvas.width=e.scaledCanvasWidth,this._canvas.height=e.scaledCanvasHeight,this._canvas.style.width=e.canvasWidth+"px",this._canvas.style.height=e.canvasHeight+"px",this._alpha||this._clearAll(),this._refreshCharAtlas(this._colors)},e.prototype._fillCells=function(e,t,n,r){this._ctx.fillRect(e*this._scaledCellWidth,t*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight)},e.prototype._fillBottomLineAtCells=function(e,t,n){void 0===n&&(n=1),this._ctx.fillRect(e*this._scaledCellWidth,(t+1)*this._scaledCellHeight-window.devicePixelRatio-1,n*this._scaledCellWidth,window.devicePixelRatio)},e.prototype._fillLeftLineAtCell=function(e,t,n){this._ctx.fillRect(e*this._scaledCellWidth,t*this._scaledCellHeight,window.devicePixelRatio*n,this._scaledCellHeight)},e.prototype._strokeRectAtCell=function(e,t,n,r){this._ctx.lineWidth=window.devicePixelRatio,this._ctx.strokeRect(e*this._scaledCellWidth+window.devicePixelRatio/2,t*this._scaledCellHeight+window.devicePixelRatio/2,n*this._scaledCellWidth-window.devicePixelRatio,r*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(e,t,n,r){this._alpha?this._ctx.clearRect(e*this._scaledCellWidth,t*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(e*this._scaledCellWidth,t*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight))},e.prototype._fillCharTrueColor=function(e,t,n){this._ctx.font=this._getFont(!1,!1),this._ctx.textBaseline="middle",this._clipRow(n),this._ctx.fillText(e.getChars(),t*this._scaledCellWidth+this._scaledCharLeft,n*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2)},e.prototype._drawChars=function(e,t,n){var o,s,a=this._getContrastColor(e);a||e.isFgRGB()||e.isBgRGB()?this._drawUncachedChars(e,t,n,a):(e.isInverse()?(o=e.isBgDefault()?i.INVERTED_DEFAULT_COLOR:e.getBgColor(),s=e.isFgDefault()?i.INVERTED_DEFAULT_COLOR:e.getFgColor()):(s=e.isBgDefault()?r.DEFAULT_COLOR:e.getBgColor(),o=e.isFgDefault()?r.DEFAULT_COLOR:e.getFgColor()),o+=this._optionsService.options.drawBoldTextInBrightColors&&e.isBold()&&o<8?8:0,this._currentGlyphIdentifier.chars=e.getChars()||r.WHITESPACE_CELL_CHAR,this._currentGlyphIdentifier.code=e.getCode()||r.WHITESPACE_CELL_CODE,this._currentGlyphIdentifier.bg=s,this._currentGlyphIdentifier.fg=o,this._currentGlyphIdentifier.bold=!!e.isBold(),this._currentGlyphIdentifier.dim=!!e.isDim(),this._currentGlyphIdentifier.italic=!!e.isItalic(),this._charAtlas&&this._charAtlas.draw(this._ctx,this._currentGlyphIdentifier,t*this._scaledCellWidth+this._scaledCharLeft,n*this._scaledCellHeight+this._scaledCharTop)||this._drawUncachedChars(e,t,n))},e.prototype._drawUncachedChars=function(e,t,n,r){if(this._ctx.save(),this._ctx.font=this._getFont(!!e.isBold(),!!e.isItalic()),this._ctx.textBaseline="middle",e.isInverse())if(r)this._ctx.fillStyle=r.css;else if(e.isBgDefault())this._ctx.fillStyle=c.color.opaque(this._colors.background).css;else if(e.isBgRGB())this._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(e.getBgColor()).join(",")+")";else{var o=e.getBgColor();this._optionsService.options.drawBoldTextInBrightColors&&e.isBold()&&o<8&&(o+=8),this._ctx.fillStyle=this._colors.ansi[o].css}else if(r)this._ctx.fillStyle=r.css;else if(e.isFgDefault())this._ctx.fillStyle=this._colors.foreground.css;else if(e.isFgRGB())this._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(e.getFgColor()).join(",")+")";else{var a=e.getFgColor();this._optionsService.options.drawBoldTextInBrightColors&&e.isBold()&&a<8&&(a+=8),this._ctx.fillStyle=this._colors.ansi[a].css}this._clipRow(n),e.isDim()&&(this._ctx.globalAlpha=i.DIM_OPACITY),this._ctx.fillText(e.getChars(),t*this._scaledCellWidth+this._scaledCharLeft,n*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2),this._ctx.restore()},e.prototype._clipRow=function(e){this._ctx.beginPath(),this._ctx.rect(0,e*this._scaledCellHeight,this._bufferService.cols*this._scaledCellWidth,this._scaledCellHeight),this._ctx.clip()},e.prototype._getFont=function(e,t){return(t?"italic":"")+" "+(e?this._optionsService.options.fontWeightBold:this._optionsService.options.fontWeight)+" "+this._optionsService.options.fontSize*window.devicePixelRatio+"px "+this._optionsService.options.fontFamily},e.prototype._getContrastColor=function(e){if(1!==this._optionsService.options.minimumContrastRatio){var t=this._colors.contrastCache.getColor(e.bg,e.fg);if(void 0!==t)return t||void 0;var n=e.getFgColor(),r=e.getFgColorMode(),i=e.getBgColor(),o=e.getBgColorMode(),s=!!e.isInverse(),a=!!e.isInverse();if(s){var l=n;n=i,i=l;var u=r;r=o,o=u}var h=this._resolveBackgroundRgba(o,i,s),d=this._resolveForegroundRgba(r,n,s,a),f=c.rgba.ensureContrastRatio(h,d,this._optionsService.options.minimumContrastRatio);if(f){var p={css:c.channels.toCss(f>>24&255,f>>16&255,f>>8&255),rgba:f};return this._colors.contrastCache.setColor(e.bg,e.fg,p),p}this._colors.contrastCache.setColor(e.bg,e.fg,null)}},e.prototype._resolveBackgroundRgba=function(e,t,n){switch(e){case 16777216:case 33554432:return this._colors.ansi[t].rgba;case 50331648:return t<<8;case 0:default:return n?this._colors.foreground.rgba:this._colors.background.rgba}},e.prototype._resolveForegroundRgba=function(e,t,n,r){switch(e){case 16777216:case 33554432:return this._optionsService.options.drawBoldTextInBrightColors&&r&&t<8&&(t+=8),this._colors.ansi[t].rgba;case 50331648:return t<<8;case 0:default:return n?this._colors.background.rgba:this._colors.foreground.rgba}},e}();t.BaseRenderLayer=u},function(e,t,n){"use strict";function r(e,t,n){t.di$target===t?t.di$dependencies.push({id:e,index:n}):(t.di$dependencies=[{id:e,index:n}],t.di$target=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.createDecorator=t.getServiceDependencies=t.serviceRegistry=void 0,t.serviceRegistry=new Map,t.getServiceDependencies=function(e){return e.di$dependencies||[]},t.createDecorator=function(e){if(t.serviceRegistry.has(e))return t.serviceRegistry.get(e);var n=function(e,t,i){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");r(n,e,i)};return n.toString=function(){return e},t.serviceRegistry.set(e,n),n}},function(e,t,n){"use strict";function r(e,t,n,r){if(void 0===n&&(n=0),void 0===r&&(r=e.length),n>=e.length)return e;n=(e.length+n)%e.length,r=r>=e.length?e.length:(e.length+r)%e.length;for(var i=n;i>22,2097152&t?this._combined[e].charCodeAt(this._combined[e].length-1):n]},e.prototype.set=function(e,t){this._data[3*e+1]=t[i.CHAR_DATA_ATTR_INDEX],t[i.CHAR_DATA_CHAR_INDEX].length>1?(this._combined[e]=t[1],this._data[3*e+0]=2097152|e|t[i.CHAR_DATA_WIDTH_INDEX]<<22):this._data[3*e+0]=t[i.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|t[i.CHAR_DATA_WIDTH_INDEX]<<22},e.prototype.getWidth=function(e){return this._data[3*e+0]>>22},e.prototype.hasWidth=function(e){return 12582912&this._data[3*e+0]},e.prototype.getFg=function(e){return this._data[3*e+1]},e.prototype.getBg=function(e){return this._data[3*e+2]},e.prototype.hasContent=function(e){return 4194303&this._data[3*e+0]},e.prototype.getCodePoint=function(e){var t=this._data[3*e+0];return 2097152&t?this._combined[e].charCodeAt(this._combined[e].length-1):2097151&t},e.prototype.isCombined=function(e){return 2097152&this._data[3*e+0]},e.prototype.getString=function(e){var t=this._data[3*e+0];return 2097152&t?this._combined[e]:2097151&t?r.stringFromCodePoint(2097151&t):""},e.prototype.loadCell=function(e,t){var n=3*e;return t.content=this._data[n+0],t.fg=this._data[n+1],t.bg=this._data[n+2],2097152&t.content&&(t.combinedData=this._combined[e]),268435456&t.bg&&(t.extended=this._extendedAttrs[e]),t},e.prototype.setCell=function(e,t){2097152&t.content&&(this._combined[e]=t.combinedData),268435456&t.bg&&(this._extendedAttrs[e]=t.extended),this._data[3*e+0]=t.content,this._data[3*e+1]=t.fg,this._data[3*e+2]=t.bg},e.prototype.setCellFromCodePoint=function(e,t,n,r,i,o){268435456&i&&(this._extendedAttrs[e]=o),this._data[3*e+0]=t|n<<22,this._data[3*e+1]=r,this._data[3*e+2]=i},e.prototype.addCodepointToCell=function(e,t){var n=this._data[3*e+0];2097152&n?this._combined[e]+=r.stringFromCodePoint(t):(2097151&n?(this._combined[e]=r.stringFromCodePoint(2097151&n)+r.stringFromCodePoint(t),n&=-2097152,n|=2097152):n=t|1<<22,this._data[3*e+0]=n)},e.prototype.insertCells=function(e,t,n,r){if((e%=this.length)&&2===this.getWidth(e-1)&&this.setCellFromCodePoint(e-1,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new s.ExtendedAttrs),t=0;--a)this.setCell(e+t+a,this.loadCell(e+a,i));for(a=0;athis.length){var n=new Uint32Array(3*e);this.length&&(3*e=e&&delete this._combined[o]}}else this._data=new Uint32Array(0),this._combined={};this.length=e}},e.prototype.fill=function(e){this._combined={},this._extendedAttrs={};for(var t=0;t=0;--e)if(4194303&this._data[3*e+0])return e+(this._data[3*e+0]>>22);return 0},e.prototype.copyCellsFrom=function(e,t,n,r,i){var o=e._data;if(i)for(var s=r-1;s>=0;s--)for(var a=0;a<3;a++)this._data[3*(n+s)+a]=o[3*(t+s)+a];else for(s=0;s=t&&(this._combined[l-t+n]=e._combined[l])}},e.prototype.translateToString=function(e,t,n){void 0===e&&(e=!1),void 0===t&&(t=0),void 0===n&&(n=this.length),e&&(n=Math.min(n,this.getTrimmedLength()));for(var o="";t>22||1}return o},e}();t.BufferLine=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeElementFromParent=void 0,t.removeElementFromParent=function(){for(var e,t=[],n=0;n24)return t.setWinLines||!1;switch(e){case 1:return!!t.restoreWin;case 2:return!!t.minimizeWin;case 3:return!!t.setWinPosition;case 4:return!!t.setWinSizePixels;case 5:return!!t.raiseWin;case 6:return!!t.lowerWin;case 7:return!!t.refreshWin;case 8:return!!t.setWinSizeChars;case 9:return!!t.maximizeWin;case 10:return!!t.fullscreenWin;case 11:return!!t.getWinState;case 13:return!!t.getWinPosition;case 14:return!!t.getWinSizePixels;case 15:return!!t.getScreenSizePixels;case 16:return!!t.getCellSizePixels;case 18:return!!t.getWinSizeChars;case 19:return!!t.getScreenSizeChars;case 20:return!!t.getIconTitle;case 21:return!!t.getWinTitle;case 22:return!!t.pushTitle;case 23:return!!t.popTitle;case 24:return!!t.setWinLines}return!1}!function(e){e[e.GET_WIN_SIZE_PIXELS=0]="GET_WIN_SIZE_PIXELS",e[e.GET_CELL_SIZE_PIXELS=1]="GET_CELL_SIZE_PIXELS"}(o=t.WindowsOptionsReportType||(t.WindowsOptionsReportType={}));var w=function(){function e(e,t,n,r){this._bufferService=e,this._coreService=t,this._logService=n,this._optionsService=r,this._data=new Uint32Array(0)}return e.prototype.hook=function(e){this._data=new Uint32Array(0)},e.prototype.put=function(e,t,n){this._data=u.concat(this._data,e.subarray(t,n))},e.prototype.unhook=function(e){if(e){var t=h.utf32ToString(this._data);switch(this._data=new Uint32Array(0),t){case'"q':return this._coreService.triggerDataEvent(s.C0.ESC+'P1$r0"q'+s.C0.ESC+"\\");case'"p':return this._coreService.triggerDataEvent(s.C0.ESC+'P1$r61;1"p'+s.C0.ESC+"\\");case"r":var n=this._bufferService.buffer.scrollTop+1+";"+(this._bufferService.buffer.scrollBottom+1)+"r";return this._coreService.triggerDataEvent(s.C0.ESC+"P1$r"+n+s.C0.ESC+"\\");case"m":return this._coreService.triggerDataEvent(s.C0.ESC+"P1$r0m"+s.C0.ESC+"\\");case" q":var r={block:2,underline:4,bar:6}[this._optionsService.options.cursorStyle];return r-=this._optionsService.options.cursorBlink?1:0,this._coreService.triggerDataEvent(s.C0.ESC+"P1$r"+r+" q"+s.C0.ESC+"\\");default:this._logService.debug("Unknown DCS $q %s",t),this._coreService.triggerDataEvent(s.C0.ESC+"P0$r"+s.C0.ESC+"\\")}}else this._data=new Uint32Array(0)},e}(),S=function(e){function t(t,n,r,i,o,l,u,p,v){void 0===v&&(v=new c.EscapeSequenceParser);var g=e.call(this)||this;g._bufferService=t,g._charsetService=n,g._coreService=r,g._dirtyRowService=i,g._logService=o,g._optionsService=l,g._coreMouseService=u,g._unicodeService=p,g._parser=v,g._parseBuffer=new Uint32Array(4096),g._stringDecoder=new h.StringToUtf32,g._utf8Decoder=new h.Utf8ToUtf32,g._workCell=new _.CellData,g._windowTitle="",g._iconName="",g._windowTitleStack=[],g._iconNameStack=[],g._curAttrData=d.DEFAULT_ATTR_DATA.clone(),g._eraseAttrDataInternal=d.DEFAULT_ATTR_DATA.clone(),g._onRequestBell=new f.EventEmitter,g._onRequestRefreshRows=new f.EventEmitter,g._onRequestReset=new f.EventEmitter,g._onRequestScroll=new f.EventEmitter,g._onRequestSyncScrollBar=new f.EventEmitter,g._onRequestWindowsOptionsReport=new f.EventEmitter,g._onA11yChar=new f.EventEmitter,g._onA11yTab=new f.EventEmitter,g._onCursorMove=new f.EventEmitter,g._onLineFeed=new f.EventEmitter,g._onScroll=new f.EventEmitter,g._onTitleChange=new f.EventEmitter,g.register(g._parser),g._parser.setCsiHandlerFallback((function(e,t){g._logService.debug("Unknown CSI code: ",{identifier:g._parser.identToString(e),params:t.toArray()})})),g._parser.setEscHandlerFallback((function(e){g._logService.debug("Unknown ESC code: ",{identifier:g._parser.identToString(e)})})),g._parser.setExecuteHandlerFallback((function(e){g._logService.debug("Unknown EXECUTE code: ",{code:e})})),g._parser.setOscHandlerFallback((function(e,t,n){g._logService.debug("Unknown OSC code: ",{identifier:e,action:t,data:n})})),g._parser.setDcsHandlerFallback((function(e,t,n){"HOOK"===t&&(n=n.toArray()),g._logService.debug("Unknown DCS code: ",{identifier:g._parser.identToString(e),action:t,payload:n})})),g._parser.setPrintHandler((function(e,t,n){return g.print(e,t,n)})),g._parser.setCsiHandler({final:"@"},(function(e){return g.insertChars(e)})),g._parser.setCsiHandler({intermediates:" ",final:"@"},(function(e){return g.scrollLeft(e)})),g._parser.setCsiHandler({final:"A"},(function(e){return g.cursorUp(e)})),g._parser.setCsiHandler({intermediates:" ",final:"A"},(function(e){return g.scrollRight(e)})),g._parser.setCsiHandler({final:"B"},(function(e){return g.cursorDown(e)})),g._parser.setCsiHandler({final:"C"},(function(e){return g.cursorForward(e)})),g._parser.setCsiHandler({final:"D"},(function(e){return g.cursorBackward(e)})),g._parser.setCsiHandler({final:"E"},(function(e){return g.cursorNextLine(e)})),g._parser.setCsiHandler({final:"F"},(function(e){return g.cursorPrecedingLine(e)})),g._parser.setCsiHandler({final:"G"},(function(e){return g.cursorCharAbsolute(e)})),g._parser.setCsiHandler({final:"H"},(function(e){return g.cursorPosition(e)})),g._parser.setCsiHandler({final:"I"},(function(e){return g.cursorForwardTab(e)})),g._parser.setCsiHandler({final:"J"},(function(e){return g.eraseInDisplay(e)})),g._parser.setCsiHandler({prefix:"?",final:"J"},(function(e){return g.eraseInDisplay(e)})),g._parser.setCsiHandler({final:"K"},(function(e){return g.eraseInLine(e)})),g._parser.setCsiHandler({prefix:"?",final:"K"},(function(e){return g.eraseInLine(e)})),g._parser.setCsiHandler({final:"L"},(function(e){return g.insertLines(e)})),g._parser.setCsiHandler({final:"M"},(function(e){return g.deleteLines(e)})),g._parser.setCsiHandler({final:"P"},(function(e){return g.deleteChars(e)})),g._parser.setCsiHandler({final:"S"},(function(e){return g.scrollUp(e)})),g._parser.setCsiHandler({final:"T"},(function(e){return g.scrollDown(e)})),g._parser.setCsiHandler({final:"X"},(function(e){return g.eraseChars(e)})),g._parser.setCsiHandler({final:"Z"},(function(e){return g.cursorBackwardTab(e)})),g._parser.setCsiHandler({final:"`"},(function(e){return g.charPosAbsolute(e)})),g._parser.setCsiHandler({final:"a"},(function(e){return g.hPositionRelative(e)})),g._parser.setCsiHandler({final:"b"},(function(e){return g.repeatPrecedingCharacter(e)})),g._parser.setCsiHandler({final:"c"},(function(e){return g.sendDeviceAttributesPrimary(e)})),g._parser.setCsiHandler({prefix:">",final:"c"},(function(e){return g.sendDeviceAttributesSecondary(e)})),g._parser.setCsiHandler({final:"d"},(function(e){return g.linePosAbsolute(e)})),g._parser.setCsiHandler({final:"e"},(function(e){return g.vPositionRelative(e)})),g._parser.setCsiHandler({final:"f"},(function(e){return g.hVPosition(e)})),g._parser.setCsiHandler({final:"g"},(function(e){return g.tabClear(e)})),g._parser.setCsiHandler({final:"h"},(function(e){return g.setMode(e)})),g._parser.setCsiHandler({prefix:"?",final:"h"},(function(e){return g.setModePrivate(e)})),g._parser.setCsiHandler({final:"l"},(function(e){return g.resetMode(e)})),g._parser.setCsiHandler({prefix:"?",final:"l"},(function(e){return g.resetModePrivate(e)})),g._parser.setCsiHandler({final:"m"},(function(e){return g.charAttributes(e)})),g._parser.setCsiHandler({final:"n"},(function(e){return g.deviceStatus(e)})),g._parser.setCsiHandler({prefix:"?",final:"n"},(function(e){return g.deviceStatusPrivate(e)})),g._parser.setCsiHandler({intermediates:"!",final:"p"},(function(e){return g.softReset(e)})),g._parser.setCsiHandler({intermediates:" ",final:"q"},(function(e){return g.setCursorStyle(e)})),g._parser.setCsiHandler({final:"r"},(function(e){return g.setScrollRegion(e)})),g._parser.setCsiHandler({final:"s"},(function(e){return g.saveCursor(e)})),g._parser.setCsiHandler({final:"t"},(function(e){return g.windowOptions(e)})),g._parser.setCsiHandler({final:"u"},(function(e){return g.restoreCursor(e)})),g._parser.setCsiHandler({intermediates:"'",final:"}"},(function(e){return g.insertColumns(e)})),g._parser.setCsiHandler({intermediates:"'",final:"~"},(function(e){return g.deleteColumns(e)})),g._parser.setExecuteHandler(s.C0.BEL,(function(){return g.bell()})),g._parser.setExecuteHandler(s.C0.LF,(function(){return g.lineFeed()})),g._parser.setExecuteHandler(s.C0.VT,(function(){return g.lineFeed()})),g._parser.setExecuteHandler(s.C0.FF,(function(){return g.lineFeed()})),g._parser.setExecuteHandler(s.C0.CR,(function(){return g.carriageReturn()})),g._parser.setExecuteHandler(s.C0.BS,(function(){return g.backspace()})),g._parser.setExecuteHandler(s.C0.HT,(function(){return g.tab()})),g._parser.setExecuteHandler(s.C0.SO,(function(){return g.shiftOut()})),g._parser.setExecuteHandler(s.C0.SI,(function(){return g.shiftIn()})),g._parser.setExecuteHandler(s.C1.IND,(function(){return g.index()})),g._parser.setExecuteHandler(s.C1.NEL,(function(){return g.nextLine()})),g._parser.setExecuteHandler(s.C1.HTS,(function(){return g.tabSet()})),g._parser.setOscHandler(0,new b.OscHandler((function(e){g.setTitle(e),g.setIconName(e)}))),g._parser.setOscHandler(1,new b.OscHandler((function(e){return g.setIconName(e)}))),g._parser.setOscHandler(2,new b.OscHandler((function(e){return g.setTitle(e)}))),g._parser.setEscHandler({final:"7"},(function(){return g.saveCursor()})),g._parser.setEscHandler({final:"8"},(function(){return g.restoreCursor()})),g._parser.setEscHandler({final:"D"},(function(){return g.index()})),g._parser.setEscHandler({final:"E"},(function(){return g.nextLine()})),g._parser.setEscHandler({final:"H"},(function(){return g.tabSet()})),g._parser.setEscHandler({final:"M"},(function(){return g.reverseIndex()})),g._parser.setEscHandler({final:"="},(function(){return g.keypadApplicationMode()})),g._parser.setEscHandler({final:">"},(function(){return g.keypadNumericMode()})),g._parser.setEscHandler({final:"c"},(function(){return g.fullReset()})),g._parser.setEscHandler({final:"n"},(function(){return g.setgLevel(2)})),g._parser.setEscHandler({final:"o"},(function(){return g.setgLevel(3)})),g._parser.setEscHandler({final:"|"},(function(){return g.setgLevel(3)})),g._parser.setEscHandler({final:"}"},(function(){return g.setgLevel(2)})),g._parser.setEscHandler({final:"~"},(function(){return g.setgLevel(1)})),g._parser.setEscHandler({intermediates:"%",final:"@"},(function(){return g.selectDefaultCharset()})),g._parser.setEscHandler({intermediates:"%",final:"G"},(function(){return g.selectDefaultCharset()}));var m=function(e){y._parser.setEscHandler({intermediates:"(",final:e},(function(){return g.selectCharset("("+e)})),y._parser.setEscHandler({intermediates:")",final:e},(function(){return g.selectCharset(")"+e)})),y._parser.setEscHandler({intermediates:"*",final:e},(function(){return g.selectCharset("*"+e)})),y._parser.setEscHandler({intermediates:"+",final:e},(function(){return g.selectCharset("+"+e)})),y._parser.setEscHandler({intermediates:"-",final:e},(function(){return g.selectCharset("-"+e)})),y._parser.setEscHandler({intermediates:".",final:e},(function(){return g.selectCharset("."+e)})),y._parser.setEscHandler({intermediates:"/",final:e},(function(){return g.selectCharset("/"+e)}))},y=this;for(var S in a.CHARSETS)m(S);return g._parser.setEscHandler({intermediates:"#",final:"8"},(function(){return g.screenAlignmentPattern()})),g._parser.setErrorHandler((function(e){return g._logService.error("Parsing error: ",e),e})),g._parser.setDcsHandler({intermediates:"$",final:"q"},new w(g._bufferService,g._coreService,g._logService,g._optionsService)),g}return i(t,e),Object.defineProperty(t.prototype,"onRequestBell",{get:function(){return this._onRequestBell.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestRefreshRows",{get:function(){return this._onRequestRefreshRows.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestReset",{get:function(){return this._onRequestReset.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestScroll",{get:function(){return this._onRequestScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestSyncScrollBar",{get:function(){return this._onRequestSyncScrollBar.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestWindowsOptionsReport",{get:function(){return this._onRequestWindowsOptionsReport.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onA11yChar",{get:function(){return this._onA11yChar.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onA11yTab",{get:function(){return this._onA11yTab.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onCursorMove",{get:function(){return this._onCursorMove.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onLineFeed",{get:function(){return this._onLineFeed.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onScroll",{get:function(){return this._onScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onTitleChange",{get:function(){return this._onTitleChange.event},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){e.prototype.dispose.call(this)},t.prototype.parse=function(e){var t=this._bufferService.buffer,n=t.x,r=t.y;if(this._logService.debug("parsing data",e),this._parseBuffer.length131072)for(var i=0;i0&&2===f.getWidth(o.x-1)&&f.setCellFromCodePoint(o.x-1,0,1,d.fg,d.bg,d.extended);for(var _=t;_=c)if(l){for(;o.x=this._bufferService.rows&&(o.y=this._bufferService.rows-1),o.lines.get(o.ybase+o.y).isWrapped=!0),f=o.lines.get(o.ybase+o.y)}else if(o.x=c-1,2===i)continue;if(u&&(f.insertCells(o.x,i,o.getNullCell(d),d),2===f.getWidth(c-1)&&f.setCellFromCodePoint(c-1,p.NULL_CELL_CODE,p.NULL_CELL_WIDTH,d.fg,d.bg,d.extended)),f.setCellFromCodePoint(o.x++,r,i,d.fg,d.bg,d.extended),i>0)for(;--i;)f.setCellFromCodePoint(o.x++,0,0,d.fg,d.bg,d.extended)}else f.getWidth(o.x-1)?f.addCodepointToCell(o.x-1,r):f.addCodepointToCell(o.x-2,r)}n-t>0&&(f.loadCell(o.x-1,this._workCell),2===this._workCell.getWidth()||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),o.x0&&0===f.getWidth(o.x)&&!f.hasContent(o.x)&&f.setCellFromCodePoint(o.x,0,1,d.fg,d.bg,d.extended),this._dirtyRowService.markDirty(o.y)},t.prototype.addCsiHandler=function(e,t){var n=this;return"t"!==e.final||e.prefix||e.intermediates?this._parser.addCsiHandler(e,t):this._parser.addCsiHandler(e,(function(e){return!y(e.params[0],n._optionsService.options.windowOptions)||t(e)}))},t.prototype.addDcsHandler=function(e,t){return this._parser.addDcsHandler(e,new g.DcsHandler(t))},t.prototype.addEscHandler=function(e,t){return this._parser.addEscHandler(e,t)},t.prototype.addOscHandler=function(e,t){return this._parser.addOscHandler(e,new b.OscHandler(t))},t.prototype.bell=function(){this._onRequestBell.fire()},t.prototype.lineFeed=function(){var e=this._bufferService.buffer;this._dirtyRowService.markDirty(e.y),this._optionsService.options.convertEol&&(e.x=0),e.y++,e.y===e.scrollBottom+1?(e.y--,this._onRequestScroll.fire(this._eraseAttrData())):e.y>=this._bufferService.rows&&(e.y=this._bufferService.rows-1),e.x>=this._bufferService.cols&&e.x--,this._dirtyRowService.markDirty(e.y),this._onLineFeed.fire()},t.prototype.carriageReturn=function(){this._bufferService.buffer.x=0},t.prototype.backspace=function(){var e,t=this._bufferService.buffer;if(!this._coreService.decPrivateModes.reverseWraparound)return this._restrictCursor(),void(t.x>0&&t.x--);if(this._restrictCursor(this._bufferService.cols),t.x>0)t.x--;else if(0===t.x&&t.y>t.scrollTop&&t.y<=t.scrollBottom&&(null===(e=t.lines.get(t.ybase+t.y))||void 0===e?void 0:e.isWrapped)){t.lines.get(t.ybase+t.y).isWrapped=!1,t.y--,t.x=this._bufferService.cols-1;var n=t.lines.get(t.ybase+t.y);n.hasWidth(t.x)&&!n.hasContent(t.x)&&t.x--}this._restrictCursor()},t.prototype.tab=function(){if(!(this._bufferService.buffer.x>=this._bufferService.cols)){var e=this._bufferService.buffer.x;this._bufferService.buffer.x=this._bufferService.buffer.nextStop(),this._optionsService.options.screenReaderMode&&this._onA11yTab.fire(this._bufferService.buffer.x-e)}},t.prototype.shiftOut=function(){this._charsetService.setgLevel(1)},t.prototype.shiftIn=function(){this._charsetService.setgLevel(0)},t.prototype._restrictCursor=function(e){void 0===e&&(e=this._bufferService.cols-1),this._bufferService.buffer.x=Math.min(e,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)},t.prototype._setCursor=function(e,t){this._dirtyRowService.markDirty(this._bufferService.buffer.y),this._coreService.decPrivateModes.origin?(this._bufferService.buffer.x=e,this._bufferService.buffer.y=this._bufferService.buffer.scrollTop+t):(this._bufferService.buffer.x=e,this._bufferService.buffer.y=t),this._restrictCursor(),this._dirtyRowService.markDirty(this._bufferService.buffer.y)},t.prototype._moveCursor=function(e,t){this._restrictCursor(),this._setCursor(this._bufferService.buffer.x+e,this._bufferService.buffer.y+t)},t.prototype.cursorUp=function(e){var t=this._bufferService.buffer.y-this._bufferService.buffer.scrollTop;t>=0?this._moveCursor(0,-Math.min(t,e.params[0]||1)):this._moveCursor(0,-(e.params[0]||1))},t.prototype.cursorDown=function(e){var t=this._bufferService.buffer.scrollBottom-this._bufferService.buffer.y;t>=0?this._moveCursor(0,Math.min(t,e.params[0]||1)):this._moveCursor(0,e.params[0]||1)},t.prototype.cursorForward=function(e){this._moveCursor(e.params[0]||1,0)},t.prototype.cursorBackward=function(e){this._moveCursor(-(e.params[0]||1),0)},t.prototype.cursorNextLine=function(e){this.cursorDown(e),this._bufferService.buffer.x=0},t.prototype.cursorPrecedingLine=function(e){this.cursorUp(e),this._bufferService.buffer.x=0},t.prototype.cursorCharAbsolute=function(e){this._setCursor((e.params[0]||1)-1,this._bufferService.buffer.y)},t.prototype.cursorPosition=function(e){this._setCursor(e.length>=2?(e.params[1]||1)-1:0,(e.params[0]||1)-1)},t.prototype.charPosAbsolute=function(e){this._setCursor((e.params[0]||1)-1,this._bufferService.buffer.y)},t.prototype.hPositionRelative=function(e){this._moveCursor(e.params[0]||1,0)},t.prototype.linePosAbsolute=function(e){this._setCursor(this._bufferService.buffer.x,(e.params[0]||1)-1)},t.prototype.vPositionRelative=function(e){this._moveCursor(0,e.params[0]||1)},t.prototype.hVPosition=function(e){this.cursorPosition(e)},t.prototype.tabClear=function(e){var t=e.params[0];0===t?delete this._bufferService.buffer.tabs[this._bufferService.buffer.x]:3===t&&(this._bufferService.buffer.tabs={})},t.prototype.cursorForwardTab=function(e){if(!(this._bufferService.buffer.x>=this._bufferService.cols))for(var t=e.params[0]||1;t--;)this._bufferService.buffer.x=this._bufferService.buffer.nextStop()},t.prototype.cursorBackwardTab=function(e){if(!(this._bufferService.buffer.x>=this._bufferService.cols))for(var t=e.params[0]||1,n=this._bufferService.buffer;t--;)n.x=n.prevStop()},t.prototype._eraseInBufferLine=function(e,t,n,r){void 0===r&&(r=!1);var i=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+e);i.replaceCells(t,n,this._bufferService.buffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r&&(i.isWrapped=!1)},t.prototype._resetBufferLine=function(e){var t=this._bufferService.buffer.lines.get(this._bufferService.buffer.ybase+e);t.fill(this._bufferService.buffer.getNullCell(this._eraseAttrData())),t.isWrapped=!1},t.prototype.eraseInDisplay=function(e){var t;switch(this._restrictCursor(),e.params[0]){case 0:for(t=this._bufferService.buffer.y,this._dirtyRowService.markDirty(t),this._eraseInBufferLine(t++,this._bufferService.buffer.x,this._bufferService.cols,0===this._bufferService.buffer.x);t=this._bufferService.cols&&(this._bufferService.buffer.lines.get(t+1).isWrapped=!1);t--;)this._resetBufferLine(t);this._dirtyRowService.markDirty(0);break;case 2:for(t=this._bufferService.rows,this._dirtyRowService.markDirty(t-1);t--;)this._resetBufferLine(t);this._dirtyRowService.markDirty(0);break;case 3:var n=this._bufferService.buffer.lines.length-this._bufferService.rows;n>0&&(this._bufferService.buffer.lines.trimStart(n),this._bufferService.buffer.ybase=Math.max(this._bufferService.buffer.ybase-n,0),this._bufferService.buffer.ydisp=Math.max(this._bufferService.buffer.ydisp-n,0),this._onScroll.fire(0))}},t.prototype.eraseInLine=function(e){switch(this._restrictCursor(),e.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)},t.prototype.insertLines=function(e){this._restrictCursor();var t=e.params[0]||1,n=this._bufferService.buffer;if(!(n.y>n.scrollBottom||n.yn.scrollBottom||n.yt.scrollBottom||t.yt.scrollBottom||t.yt.scrollBottom||t.yt.scrollBottom||t.y0||(this._is("xterm")||this._is("rxvt-unicode")||this._is("screen")?this._coreService.triggerDataEvent(s.C0.ESC+"[?1;2c"):this._is("linux")&&this._coreService.triggerDataEvent(s.C0.ESC+"[?6c"))},t.prototype.sendDeviceAttributesSecondary=function(e){e.params[0]>0||(this._is("xterm")?this._coreService.triggerDataEvent(s.C0.ESC+"[>0;276;0c"):this._is("rxvt-unicode")?this._coreService.triggerDataEvent(s.C0.ESC+"[>85;95;0c"):this._is("linux")?this._coreService.triggerDataEvent(e.params[0]+"c"):this._is("screen")&&this._coreService.triggerDataEvent(s.C0.ESC+"[>83;40003;0c"))},t.prototype._is=function(e){return 0===(this._optionsService.options.termName+"").indexOf(e)},t.prototype.setMode=function(e){for(var t=0;t=2||2===r[1]&&o+i>=5)break;r[1]&&(i=1)}while(++o+t5)&&(e=1),t.extended.underlineStyle=e,t.fg|=268435456,0===e&&(t.fg&=-268435457),t.updateExtended()},t.prototype.charAttributes=function(e){if(1===e.length&&0===e.params[0])return this._curAttrData.fg=d.DEFAULT_ATTR_DATA.fg,void(this._curAttrData.bg=d.DEFAULT_ATTR_DATA.bg);for(var t,n=e.length,r=this._curAttrData,i=0;i=30&&t<=37?(r.fg&=-50331904,r.fg|=16777216|t-30):t>=40&&t<=47?(r.bg&=-50331904,r.bg|=16777216|t-40):t>=90&&t<=97?(r.fg&=-50331904,r.fg|=16777224|t-90):t>=100&&t<=107?(r.bg&=-50331904,r.bg|=16777224|t-100):0===t?(r.fg=d.DEFAULT_ATTR_DATA.fg,r.bg=d.DEFAULT_ATTR_DATA.bg):1===t?r.fg|=134217728:3===t?r.bg|=67108864:4===t?(r.fg|=268435456,this._processUnderline(e.hasSubParams(i)?e.getSubParams(i)[0]:1,r)):5===t?r.fg|=536870912:7===t?r.fg|=67108864:8===t?r.fg|=1073741824:2===t?r.bg|=134217728:21===t?this._processUnderline(2,r):22===t?(r.fg&=-134217729,r.bg&=-134217729):23===t?r.bg&=-67108865:24===t?r.fg&=-268435457:25===t?r.fg&=-536870913:27===t?r.fg&=-67108865:28===t?r.fg&=-1073741825:39===t?(r.fg&=-67108864,r.fg|=16777215&d.DEFAULT_ATTR_DATA.fg):49===t?(r.bg&=-67108864,r.bg|=16777215&d.DEFAULT_ATTR_DATA.bg):38===t||48===t||58===t?i+=this._extractColor(e,i,r):59===t?(r.extended=r.extended.clone(),r.extended.underlineColor=-1,r.updateExtended()):100===t?(r.fg&=-67108864,r.fg|=16777215&d.DEFAULT_ATTR_DATA.fg,r.bg&=-67108864,r.bg|=16777215&d.DEFAULT_ATTR_DATA.bg):this._logService.debug("Unknown SGR attribute: %d.",t)},t.prototype.deviceStatus=function(e){switch(e.params[0]){case 5:this._coreService.triggerDataEvent(s.C0.ESC+"[0n");break;case 6:var t=this._bufferService.buffer.y+1,n=this._bufferService.buffer.x+1;this._coreService.triggerDataEvent(s.C0.ESC+"["+t+";"+n+"R")}},t.prototype.deviceStatusPrivate=function(e){switch(e.params[0]){case 6:var t=this._bufferService.buffer.y+1,n=this._bufferService.buffer.x+1;this._coreService.triggerDataEvent(s.C0.ESC+"[?"+t+";"+n+"R")}},t.prototype.softReset=function(e){this._coreService.isCursorHidden=!1,this._onRequestSyncScrollBar.fire(),this._bufferService.buffer.scrollTop=0,this._bufferService.buffer.scrollBottom=this._bufferService.rows-1,this._curAttrData=d.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},t.prototype.setCursorStyle=function(e){var t=e.params[0]||1;switch(t){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 n=t%2==1;this._optionsService.options.cursorBlink=n},t.prototype.setScrollRegion=function(e){var t,n=e.params[0]||1;(e.length<2||(t=e.params[1])>this._bufferService.rows||0===t)&&(t=this._bufferService.rows),t>n&&(this._bufferService.buffer.scrollTop=n-1,this._bufferService.buffer.scrollBottom=t-1,this._setCursor(0,0))},t.prototype.windowOptions=function(e){if(y(e.params[0],this._optionsService.options.windowOptions)){var t=e.length>1?e.params[1]:0;switch(e.params[0]){case 14:2!==t&&this._onRequestWindowsOptionsReport.fire(o.GET_WIN_SIZE_PIXELS);break;case 16:this._onRequestWindowsOptionsReport.fire(o.GET_CELL_SIZE_PIXELS);break;case 18:this._bufferService&&this._coreService.triggerDataEvent(s.C0.ESC+"[8;"+this._bufferService.rows+";"+this._bufferService.cols+"t");break;case 22:0!==t&&2!==t||(this._windowTitleStack.push(this._windowTitle),this._windowTitleStack.length>10&&this._windowTitleStack.shift()),0!==t&&1!==t||(this._iconNameStack.push(this._iconName),this._iconNameStack.length>10&&this._iconNameStack.shift());break;case 23:0!==t&&2!==t||this._windowTitleStack.length&&this.setTitle(this._windowTitleStack.pop()),0!==t&&1!==t||this._iconNameStack.length&&this.setIconName(this._iconNameStack.pop())}}},t.prototype.saveCursor=function(e){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},t.prototype.restoreCursor=function(e){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()},t.prototype.setTitle=function(e){this._windowTitle=e,this._onTitleChange.fire(e)},t.prototype.setIconName=function(e){this._iconName=e},t.prototype.nextLine=function(){this._bufferService.buffer.x=0,this.index()},t.prototype.keypadApplicationMode=function(){this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire()},t.prototype.keypadNumericMode=function(){this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire()},t.prototype.selectDefaultCharset=function(){this._charsetService.setgLevel(0),this._charsetService.setgCharset(0,a.DEFAULT_CHARSET)},t.prototype.selectCharset=function(e){2===e.length?"/"!==e[0]&&this._charsetService.setgCharset(m[e[0]],a.CHARSETS[e[1]]||a.DEFAULT_CHARSET):this.selectDefaultCharset()},t.prototype.index=function(){this._restrictCursor();var e=this._bufferService.buffer;this._bufferService.buffer.y++,e.y===e.scrollBottom+1?(e.y--,this._onRequestScroll.fire(this._eraseAttrData())):e.y>=this._bufferService.rows&&(e.y=this._bufferService.rows-1),this._restrictCursor()},t.prototype.tabSet=function(){this._bufferService.buffer.tabs[this._bufferService.buffer.x]=!0},t.prototype.reverseIndex=function(){this._restrictCursor();var e=this._bufferService.buffer;if(e.y===e.scrollTop){var t=e.scrollBottom-e.scrollTop;e.lines.shiftElements(e.ybase+e.y,t,1),e.lines.set(e.ybase+e.y,e.getBlankLine(this._eraseAttrData())),this._dirtyRowService.markRangeDirty(e.scrollTop,e.scrollBottom)}else e.y--,this._restrictCursor()},t.prototype.fullReset=function(){this._parser.reset(),this._onRequestReset.fire()},t.prototype.reset=function(){this._curAttrData=d.DEFAULT_ATTR_DATA.clone(),this._eraseAttrDataInternal=d.DEFAULT_ATTR_DATA.clone()},t.prototype._eraseAttrData=function(){return this._eraseAttrDataInternal.bg&=-67108864,this._eraseAttrDataInternal.bg|=67108863&this._curAttrData.bg,this._eraseAttrDataInternal},t.prototype.setgLevel=function(e){this._charsetService.setgLevel(e)},t.prototype.screenAlignmentPattern=function(){var e=new _.CellData;e.content=1<<22|"E".charCodeAt(0),e.fg=this._curAttrData.fg,e.bg=this._curAttrData.bg;var t=this._bufferService.buffer;this._setCursor(0,0);for(var n=0;n256)throw new Error("maxSubParamsLength must not be greater than 256");this.params=new Int32Array(e),this.length=0,this._subParams=new Int32Array(t),this._subParamsLength=0,this._subParamsIdx=new Uint16Array(e),this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}return e.fromArray=function(t){var n=new e;if(!t.length)return n;for(var r=t[0]instanceof Array?1:0;r>8,r=255&this._subParamsIdx[t];r-n>0&&e.push(Array.prototype.slice.call(this._subParams,n,r))}return e},e.prototype.reset=function(){this.length=0,this._subParamsLength=0,this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1},e.prototype.addParam=function(e){if(this._digitIsSub=!1,this.length>=this.maxLength)this._rejectDigits=!0;else{if(e<-1)throw new Error("values lesser than -1 are not allowed");this._subParamsIdx[this.length]=this._subParamsLength<<8|this._subParamsLength,this.params[this.length++]=e>2147483647?2147483647:e}},e.prototype.addSubParam=function(e){if(this._digitIsSub=!0,this.length)if(this._rejectDigits||this._subParamsLength>=this.maxSubParamsLength)this._rejectSubDigits=!0;else{if(e<-1)throw new Error("values lesser than -1 are not allowed");this._subParams[this._subParamsLength++]=e>2147483647?2147483647:e,this._subParamsIdx[this.length-1]++}},e.prototype.hasSubParams=function(e){return(255&this._subParamsIdx[e])-(this._subParamsIdx[e]>>8)>0},e.prototype.getSubParams=function(e){var t=this._subParamsIdx[e]>>8,n=255&this._subParamsIdx[e];return n-t>0?this._subParams.subarray(t,n):null},e.prototype.getSubParamsAll=function(){for(var e={},t=0;t>8,r=255&this._subParamsIdx[t];r-n>0&&(e[t]=this._subParams.slice(n,r))}return e},e.prototype.addDigit=function(e){var t;if(!(this._rejectDigits||!(t=this._digitIsSub?this._subParamsLength:this.length)||this._digitIsSub&&this._rejectSubDigits)){var n=this._digitIsSub?this._subParams:this.params,r=n[t-1];n[t-1]=~r?Math.min(10*r+e,2147483647):e}},e}();t.Params=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OscHandler=t.OscParser=void 0;var r=n(23),i=n(8),o=function(){function e(){this._state=0,this._id=-1,this._handlers=Object.create(null),this._handlerFb=function(){}}return e.prototype.addHandler=function(e,t){void 0===this._handlers[e]&&(this._handlers[e]=[]);var n=this._handlers[e];return n.push(t),{dispose:function(){var e=n.indexOf(t);-1!==e&&n.splice(e,1)}}},e.prototype.setHandler=function(e,t){this._handlers[e]=[t]},e.prototype.clearHandler=function(e){this._handlers[e]&&delete this._handlers[e]},e.prototype.setHandlerFallback=function(e){this._handlerFb=e},e.prototype.dispose=function(){this._handlers=Object.create(null),this._handlerFb=function(){}},e.prototype.reset=function(){2===this._state&&this.end(!1),this._id=-1,this._state=0},e.prototype._start=function(){var e=this._handlers[this._id];if(e)for(var t=e.length-1;t>=0;t--)e[t].start();else this._handlerFb(this._id,"START")},e.prototype._put=function(e,t,n){var r=this._handlers[this._id];if(r)for(var o=r.length-1;o>=0;o--)r[o].put(e,t,n);else this._handlerFb(this._id,"PUT",i.utf32ToString(e,t,n))},e.prototype._end=function(e){var t=this._handlers[this._id];if(t){for(var n=t.length-1;n>=0&&!1===t[n].end(e);n--);for(n--;n>=0;n--)t[n].end(!1)}else this._handlerFb(this._id,"END",e)},e.prototype.start=function(){this.reset(),this._id=-1,this._state=1},e.prototype.put=function(e,t,n){if(3!==this._state){if(1===this._state)for(;t0&&this._put(e,t,n)}},e.prototype.end=function(e){0!==this._state&&(3!==this._state&&(1===this._state&&this._start(),this._end(e)),this._id=-1,this._state=0)},e}();t.OscParser=o;var s=function(){function e(e){this._handler=e,this._data="",this._hitLimit=!1}return e.prototype.start=function(){this._data="",this._hitLimit=!1},e.prototype.put=function(e,t,n){this._hitLimit||(this._data+=i.utf32ToString(e,t,n),this._data.length>r.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))},e.prototype.end=function(e){var t;return this._hitLimit?t=!1:e&&(t=this._handler(this._data)),this._data="",this._hitLimit=!1,t},e}();t.OscHandler=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PAYLOAD_LIMIT=void 0,t.PAYLOAD_LIMIT=1e7},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DcsHandler=t.DcsParser=void 0;var r=n(8),i=n(21),o=n(23),s=[],a=function(){function e(){this._handlers=Object.create(null),this._active=s,this._ident=0,this._handlerFb=function(){}}return e.prototype.dispose=function(){this._handlers=Object.create(null),this._handlerFb=function(){}},e.prototype.addHandler=function(e,t){void 0===this._handlers[e]&&(this._handlers[e]=[]);var n=this._handlers[e];return n.push(t),{dispose:function(){var e=n.indexOf(t);-1!==e&&n.splice(e,1)}}},e.prototype.setHandler=function(e,t){this._handlers[e]=[t]},e.prototype.clearHandler=function(e){this._handlers[e]&&delete this._handlers[e]},e.prototype.setHandlerFallback=function(e){this._handlerFb=e},e.prototype.reset=function(){this._active.length&&this.unhook(!1),this._active=s,this._ident=0},e.prototype.hook=function(e,t){if(this.reset(),this._ident=e,this._active=this._handlers[e]||s,this._active.length)for(var n=this._active.length-1;n>=0;n--)this._active[n].hook(t);else this._handlerFb(this._ident,"HOOK",t)},e.prototype.put=function(e,t,n){if(this._active.length)for(var i=this._active.length-1;i>=0;i--)this._active[i].put(e,t,n);else this._handlerFb(this._ident,"PUT",r.utf32ToString(e,t,n))},e.prototype.unhook=function(e){if(this._active.length){for(var t=this._active.length-1;t>=0&&!1===this._active[t].unhook(e);t--);for(t--;t>=0;t--)this._active[t].unhook(!1)}else this._handlerFb(this._ident,"UNHOOK",e);this._active=s,this._ident=0},e}();t.DcsParser=a;var c=function(){function e(e){this._handler=e,this._data="",this._hitLimit=!1}return e.prototype.hook=function(e){this._params=e.clone(),this._data="",this._hitLimit=!1},e.prototype.put=function(e,t,n){this._hitLimit||(this._data+=r.utf32ToString(e,t,n),this._data.length>o.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))},e.prototype.unhook=function(e){var t;return this._hitLimit?t=!1:e&&(t=this._handler(this._data,this._params||new i.Params)),this._params=void 0,this._data="",this._hitLimit=!1,t},e}();t.DcsHandler=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeTerminalFromCache=t.acquireCharAtlas=void 0;var r=n(26),i=n(43),o=[];t.acquireCharAtlas=function(e,t,n,s,a){for(var c=r.generateConfig(s,a,e,n),l=0;l=0){if(r.configEquals(h.config,c))return h.atlas;1===h.ownedBy.length?(h.atlas.dispose(),o.splice(l,1)):h.ownedBy.splice(u,1);break}}for(l=0;l1)for(var h=this._getJoinedRanges(r,a,o,t,i),d=0;d1)for(h=this._getJoinedRanges(r,a,o,t,i),d=0;d=this._line.length))return t?(this._line.loadCell(e,t),t):this._line.loadCell(e,new r.CellData)},e.prototype.translateToString=function(e,t,n){return this._line.translateToString(e,t,n)},e}(),d=function(){function e(e){this._core=e}return e.prototype.registerCsiHandler=function(e,t){return this._core.addCsiHandler(e,(function(e){return t(e.toArray())}))},e.prototype.addCsiHandler=function(e,t){return this.registerCsiHandler(e,t)},e.prototype.registerDcsHandler=function(e,t){return this._core.addDcsHandler(e,(function(e,n){return t(e,n.toArray())}))},e.prototype.addDcsHandler=function(e,t){return this.registerDcsHandler(e,t)},e.prototype.registerEscHandler=function(e,t){return this._core.addEscHandler(e,t)},e.prototype.addEscHandler=function(e,t){return this.registerEscHandler(e,t)},e.prototype.registerOscHandler=function(e,t){return this._core.addOscHandler(e,t)},e.prototype.addOscHandler=function(e,t){return this.registerOscHandler(e,t)},e}(),f=function(){function e(e){this._core=e}return e.prototype.register=function(e){this._core.unicodeService.register(e)},Object.defineProperty(e.prototype,"versions",{get:function(){return this._core.unicodeService.versions},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activeVersion",{get:function(){return this._core.unicodeService.activeVersion},set:function(e){this._core.unicodeService.activeVersion=e},enumerable:!1,configurable:!0}),e}()},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.Terminal=void 0;var o=n(36),s=n(37),a=n(38),c=n(12),l=n(19),u=n(40),h=n(50),d=n(51),f=n(11),p=n(7),_=n(18),v=n(54),b=n(55),g=n(56),m=n(57),y=n(59),w=n(0),S=n(16),C=n(27),k=n(60),E=n(5),O=n(61),x=n(62),A=n(63),j=n(64),L=n(65),R="undefined"!=typeof window?window.document:null,M=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;return n.browser=f,n._keyDownHandled=!1,n._onCursorMove=new w.EventEmitter,n._onKey=new w.EventEmitter,n._onRender=new w.EventEmitter,n._onSelectionChange=new w.EventEmitter,n._onTitleChange=new w.EventEmitter,n._onFocus=new w.EventEmitter,n._onBlur=new w.EventEmitter,n._onA11yCharEmitter=new w.EventEmitter,n._onA11yTabEmitter=new w.EventEmitter,n._setup(),n.linkifier=n._instantiationService.createInstance(h.Linkifier),n.linkifier2=n.register(n._instantiationService.createInstance(A.Linkifier2)),n.register(n._inputHandler.onRequestBell((function(){return n.bell()}))),n.register(n._inputHandler.onRequestRefreshRows((function(e,t){return n.refresh(e,t)}))),n.register(n._inputHandler.onRequestReset((function(){return n.reset()}))),n.register(n._inputHandler.onRequestScroll((function(e,t){return n.scroll(e,t||void 0)}))),n.register(n._inputHandler.onRequestWindowsOptionsReport((function(e){return n._reportWindowsOptions(e)}))),n.register(w.forwardEvent(n._inputHandler.onCursorMove,n._onCursorMove)),n.register(w.forwardEvent(n._inputHandler.onTitleChange,n._onTitleChange)),n.register(w.forwardEvent(n._inputHandler.onA11yChar,n._onA11yCharEmitter)),n.register(w.forwardEvent(n._inputHandler.onA11yTab,n._onA11yTabEmitter)),n.register(n._bufferService.onResize((function(e){return n._afterResize(e.cols,e.rows)}))),n}return i(t,e),Object.defineProperty(t.prototype,"options",{get:function(){return this.optionsService.options},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onCursorMove",{get:function(){return this._onCursorMove.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onKey",{get:function(){return this._onKey.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRender",{get:function(){return this._onRender.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onSelectionChange",{get:function(){return this._onSelectionChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onTitleChange",{get:function(){return this._onTitleChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onFocus",{get:function(){return this._onFocus.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onBlur",{get:function(){return this._onBlur.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onA11yChar",{get:function(){return this._onA11yCharEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onA11yTab",{get:function(){return this._onA11yTabEmitter.event},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){var t,n,r;this._isDisposed||(e.prototype.dispose.call(this),null===(t=this._renderService)||void 0===t||t.dispose(),this._customKeyEventHandler=void 0,this.write=function(){},null===(r=null===(n=this.element)||void 0===n?void 0:n.parentNode)||void 0===r||r.removeChild(this.element))},t.prototype._setup=function(){e.prototype._setup.call(this),this._customKeyEventHandler=void 0},Object.defineProperty(t.prototype,"buffer",{get:function(){return this.buffers.active},enumerable:!1,configurable:!0}),t.prototype.focus=function(){this.textarea&&this.textarea.focus({preventScroll:!0})},t.prototype._updateOptions=function(t){var n,r,i,o;switch(e.prototype._updateOptions.call(this,t),t){case"fontFamily":case"fontSize":null===(n=this._renderService)||void 0===n||n.clear(),null===(r=this._charSizeService)||void 0===r||r.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":null===(i=this.viewport)||void 0===i||i.syncScrollArea();break;case"screenReaderMode":this.optionsService.options.screenReaderMode?!this._accessibilityManager&&this._renderService&&(this._accessibilityManager=new g.AccessibilityManager(this,this._renderService)):(null===(o=this._accessibilityManager)||void 0===o||o.dispose(),this._accessibilityManager=void 0);break;case"tabStopWidth":this.buffers.setupTabStops();break;case"theme":this._setTheme(this.optionsService.options.theme)}},t.prototype._onTextAreaFocus=function(e){this._coreService.decPrivateModes.sendFocus&&this._coreService.triggerDataEvent(c.C0.ESC+"[I"),this.updateCursorStyle(e),this.element.classList.add("focus"),this._showCursor(),this._onFocus.fire()},t.prototype.blur=function(){var e;return null===(e=this.textarea)||void 0===e?void 0:e.blur()},t.prototype._onTextAreaBlur=function(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this._coreService.decPrivateModes.sendFocus&&this._coreService.triggerDataEvent(c.C0.ESC+"[O"),this.element.classList.remove("focus"),this._onBlur.fire()},t.prototype._syncTextArea=function(){if(this.textarea&&this.buffer.isCursorInViewport&&!this._compositionHelper.isComposing){var e=Math.ceil(this._charSizeService.height*this.optionsService.options.lineHeight),t=this._bufferService.buffer.y*e,n=this._bufferService.buffer.x*this._charSizeService.width;this.textarea.style.left=n+"px",this.textarea.style.top=t+"px",this.textarea.style.width=this._charSizeService.width+"px",this.textarea.style.height=e+"px",this.textarea.style.lineHeight=e+"px",this.textarea.style.zIndex="-5"}},t.prototype._initGlobal=function(){var e=this;this._bindKeys(),this.register(p.addDisposableDomListener(this.element,"copy",(function(t){e.hasSelection()&&a.copyHandler(t,e._selectionService)})));var t=function(t){return a.handlePasteEvent(t,e.textarea,e._coreService)};this.register(p.addDisposableDomListener(this.textarea,"paste",t)),this.register(p.addDisposableDomListener(this.element,"paste",t)),f.isFirefox?this.register(p.addDisposableDomListener(this.element,"mousedown",(function(t){2===t.button&&a.rightClickHandler(t,e.textarea,e.screenElement,e._selectionService,e.options.rightClickSelectsWord)}))):this.register(p.addDisposableDomListener(this.element,"contextmenu",(function(t){a.rightClickHandler(t,e.textarea,e.screenElement,e._selectionService,e.options.rightClickSelectsWord)}))),f.isLinux&&this.register(p.addDisposableDomListener(this.element,"auxclick",(function(t){1===t.button&&a.moveTextAreaUnderMouseCursor(t,e.textarea,e.screenElement)})))},t.prototype._bindKeys=function(){var e=this;this.register(p.addDisposableDomListener(this.textarea,"keyup",(function(t){return e._keyUp(t)}),!0)),this.register(p.addDisposableDomListener(this.textarea,"keydown",(function(t){return e._keyDown(t)}),!0)),this.register(p.addDisposableDomListener(this.textarea,"keypress",(function(t){return e._keyPress(t)}),!0)),this.register(p.addDisposableDomListener(this.textarea,"compositionstart",(function(){return e._compositionHelper.compositionstart()}))),this.register(p.addDisposableDomListener(this.textarea,"compositionupdate",(function(t){return e._compositionHelper.compositionupdate(t)}))),this.register(p.addDisposableDomListener(this.textarea,"compositionend",(function(){return e._compositionHelper.compositionend()}))),this.register(this.onRender((function(){return e._compositionHelper.updateCompositionElements()}))),this.register(this.onRender((function(t){return e._queueLinkification(t.start,t.end)})))},t.prototype.open=function(e){var t=this;if(!e)throw new Error("Terminal requires a parent element.");R.body.contains(e)||this._logService.debug("Terminal.open was called on an element that was not attached to the DOM"),this._document=e.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"),e.appendChild(this.element);var n=R.createDocumentFragment();this._viewportElement=R.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),n.appendChild(this._viewportElement),this._viewportScrollArea=R.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=R.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=R.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),n.appendChild(this.screenElement),this.textarea=R.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",_.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(p.addDisposableDomListener(this.textarea,"focus",(function(e){return t._onTextAreaFocus(e)}))),this.register(p.addDisposableDomListener(this.textarea,"blur",(function(){return t._onTextAreaBlur()}))),this._helperContainer.appendChild(this.textarea);var r=this._instantiationService.createInstance(j.CoreBrowserService,this.textarea);this._instantiationService.setService(E.ICoreBrowserService,r),this._charSizeService=this._instantiationService.createInstance(O.CharSizeService,this._document,this._helperContainer),this._instantiationService.setService(E.ICharSizeService,this._charSizeService),this._compositionView=R.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=this._instantiationService.createInstance(o.CompositionHelper,this.textarea,this._compositionView),this._helperContainer.appendChild(this._compositionView),this.element.appendChild(n),this._theme=this.options.theme||this._theme,this._colorManager=new C.ColorManager(R,this.options.allowTransparency),this.register(this.optionsService.onOptionChange((function(e){return t._colorManager.onOptionsChange(e)}))),this._colorManager.setTheme(this._theme);var i=this._createRenderer();this._renderService=this.register(this._instantiationService.createInstance(k.RenderService,i,this.rows,this.screenElement)),this._instantiationService.setService(E.IRenderService,this._renderService),this.register(this._renderService.onRenderedBufferChange((function(e){return t._onRender.fire(e)}))),this.onResize((function(e){return t._renderService.resize(e.cols,e.rows)})),this._soundService=this._instantiationService.createInstance(v.SoundService),this._instantiationService.setService(E.ISoundService,this._soundService),this._mouseService=this._instantiationService.createInstance(x.MouseService),this._instantiationService.setService(E.IMouseService,this._mouseService),this.viewport=this._instantiationService.createInstance(s.Viewport,(function(e,n){return t.scrollLines(e,n)}),this._viewportElement,this._viewportScrollArea),this.viewport.onThemeChange(this._colorManager.colors),this.register(this._inputHandler.onRequestSyncScrollBar((function(){return t.viewport.syncScrollArea()}))),this.register(this.viewport),this.register(this.onCursorMove((function(){t._renderService.onCursorMove(),t._syncTextArea()}))),this.register(this.onResize((function(){return t._renderService.onResize(t.cols,t.rows)}))),this.register(this.onBlur((function(){return t._renderService.onBlur()}))),this.register(this.onFocus((function(){return t._renderService.onFocus()}))),this.register(this._renderService.onDimensionsChange((function(){return t.viewport.syncScrollArea()}))),this._selectionService=this.register(this._instantiationService.createInstance(d.SelectionService,this.element,this.screenElement)),this._instantiationService.setService(E.ISelectionService,this._selectionService),this.register(this._selectionService.onRequestScrollLines((function(e){return t.scrollLines(e.amount,e.suppressScrollEvent)}))),this.register(this._selectionService.onSelectionChange((function(){return t._onSelectionChange.fire()}))),this.register(this._selectionService.onRequestRedraw((function(e){return t._renderService.onSelectionChanged(e.start,e.end,e.columnSelectMode)}))),this.register(this._selectionService.onLinuxMouseSelection((function(e){t.textarea.value=e,t.textarea.focus(),t.textarea.select()}))),this.register(this.onScroll((function(){t.viewport.syncScrollArea(),t._selectionService.refresh()}))),this.register(p.addDisposableDomListener(this._viewportElement,"scroll",(function(){return t._selectionService.refresh()}))),this._mouseZoneManager=this._instantiationService.createInstance(b.MouseZoneManager,this.element,this.screenElement),this.register(this._mouseZoneManager),this.register(this.onScroll((function(){return t._mouseZoneManager.clearAll()}))),this.linkifier.attachToDom(this.element,this._mouseZoneManager),this.linkifier2.attachToDom(this.element,this._mouseService,this._renderService),this.register(p.addDisposableDomListener(this.element,"mousedown",(function(e){return t._selectionService.onMouseDown(e)}))),this._coreMouseService.areMouseEventsActive?(this._selectionService.disable(),this.element.classList.add("enable-mouse-events")):this._selectionService.enable(),this.options.screenReaderMode&&(this._accessibilityManager=new g.AccessibilityManager(this,this._renderService)),this._charSizeService.measure(),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()},t.prototype._createRenderer=function(){switch(this.options.rendererType){case"canvas":return this._instantiationService.createInstance(u.Renderer,this._colorManager.colors,this.screenElement,this.linkifier,this.linkifier2);case"dom":return this._instantiationService.createInstance(m.DomRenderer,this._colorManager.colors,this.element,this.screenElement,this._viewportElement,this.linkifier,this.linkifier2);default:throw new Error('Unrecognized rendererType "'+this.options.rendererType+'"')}},t.prototype._setTheme=function(e){var t,n,r;this._theme=e,null===(t=this._colorManager)||void 0===t||t.setTheme(e),null===(n=this._renderService)||void 0===n||n.setColors(this._colorManager.colors),null===(r=this.viewport)||void 0===r||r.onThemeChange(this._colorManager.colors)},t.prototype.bindMouse=function(){var e=this,t=this,n=this.element;function r(e){var n,r,i=t._mouseService.getRawByteCoords(e,t.screenElement,t.cols,t.rows);if(!i)return!1;switch(e.overrideType||e.type){case"mousemove":r=32,void 0===e.buttons?(n=3,void 0!==e.button&&(n=e.button<3?e.button:3)):n=1&e.buttons?0:4&e.buttons?1:2&e.buttons?2:3;break;case"mouseup":r=0,n=e.button<3?e.button:3;break;case"mousedown":r=1,n=e.button<3?e.button:3;break;case"wheel":0!==e.deltaY&&(r=e.deltaY<0?0:1),n=4;break;default:return!1}return!(void 0===r||void 0===n||n>4)&&t._coreMouseService.triggerMouseEvent({col:i.x-33,row:i.y-33,button:n,action:r,ctrl:e.ctrlKey,alt:e.altKey,shift:e.shiftKey})}var i={mouseup:null,wheel:null,mousedrag:null,mousemove:null},o=function(t){return r(t),t.buttons||(e._document.removeEventListener("mouseup",i.mouseup),i.mousedrag&&e._document.removeEventListener("mousemove",i.mousedrag)),e.cancel(t)},s=function(t){return r(t),t.preventDefault(),e.cancel(t)},a=function(e){e.buttons&&r(e)},l=function(e){e.buttons||r(e)};this.register(this._coreMouseService.onProtocolChange((function(t){t?("debug"===e.optionsService.options.logLevel&&e._logService.debug("Binding to mouse events:",e._coreMouseService.explainEvents(t)),e.element.classList.add("enable-mouse-events"),e._selectionService.disable()):(e._logService.debug("Unbinding from mouse events."),e.element.classList.remove("enable-mouse-events"),e._selectionService.enable()),8&t?i.mousemove||(n.addEventListener("mousemove",l),i.mousemove=l):(n.removeEventListener("mousemove",i.mousemove),i.mousemove=null),16&t?i.wheel||(n.addEventListener("wheel",s,{passive:!1}),i.wheel=s):(n.removeEventListener("wheel",i.wheel),i.wheel=null),2&t?i.mouseup||(i.mouseup=o):(e._document.removeEventListener("mouseup",i.mouseup),i.mouseup=null),4&t?i.mousedrag||(i.mousedrag=a):(e._document.removeEventListener("mousemove",i.mousedrag),i.mousedrag=null)}))),this._coreMouseService.activeProtocol=this._coreMouseService.activeProtocol,this.register(p.addDisposableDomListener(n,"mousedown",(function(t){if(t.preventDefault(),e.focus(),e._coreMouseService.areMouseEventsActive&&!e._selectionService.shouldForceSelection(t))return r(t),i.mouseup&&e._document.addEventListener("mouseup",i.mouseup),i.mousedrag&&e._document.addEventListener("mousemove",i.mousedrag),e.cancel(t)}))),this.register(p.addDisposableDomListener(n,"wheel",(function(t){if(i.wheel);else if(!e.buffer.hasScrollback){var n=e.viewport.getLinesScrolled(t);if(0===n)return;for(var r=c.C0.ESC+(e._coreService.decPrivateModes.applicationCursorKeys?"O":"[")+(t.deltaY<0?"A":"B"),o="",s=0;s47)},t.prototype._keyUp=function(e){this._customKeyEventHandler&&!1===this._customKeyEventHandler(e)||(function(e){return 16===e.keyCode||17===e.keyCode||18===e.keyCode}(e)||this.focus(),this.updateCursorStyle(e))},t.prototype._keyPress=function(e){var t;if(this._keyDownHandled)return!1;if(this._customKeyEventHandler&&!1===this._customKeyEventHandler(e))return!1;if(this.cancel(e),e.charCode)t=e.charCode;else if(null===e.which||void 0===e.which)t=e.keyCode;else{if(0===e.which||0===e.charCode)return!1;t=e.which}return!(!t||(e.altKey||e.ctrlKey||e.metaKey)&&!this._isThirdLevelShift(this.browser,e)||(t=String.fromCharCode(t),this._onKey.fire({key:t,domEvent:e}),this._showCursor(),this._coreService.triggerDataEvent(t,!0),0))},t.prototype.bell=function(){this._soundBell()&&this._soundService.playBellSound()},t.prototype.resize=function(t,n){t!==this.cols||n!==this.rows?e.prototype.resize.call(this,t,n):this._charSizeService&&!this._charSizeService.hasValidSize&&this._charSizeService.measure()},t.prototype._afterResize=function(e,t){var n,r;null===(n=this._charSizeService)||void 0===n||n.measure(),null===(r=this.viewport)||void 0===r||r.syncScrollArea(!0)},t.prototype.clear=function(){if(0!==this.buffer.ybase||0!==this.buffer.y){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 e=1;e=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CompositionHelper=void 0;var o=n(5),s=n(1),a=function(){function e(e,t,n,r,i,o){this._textarea=e,this._compositionView=t,this._bufferService=n,this._optionsService=r,this._charSizeService=i,this._coreService=o,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:0,end:0}}return Object.defineProperty(e.prototype,"isComposing",{get:function(){return this._isComposing},enumerable:!1,configurable:!0}),e.prototype.compositionstart=function(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._compositionView.classList.add("active")},e.prototype.compositionupdate=function(e){var t=this;this._compositionView.textContent=e.data,this.updateCompositionElements(),setTimeout((function(){t._compositionPosition.end=t._textarea.value.length}),0)},e.prototype.compositionend=function(){this._finalizeComposition(!0)},e.prototype.keydown=function(e){if(this._isComposing||this._isSendingComposition){if(229===e.keyCode)return!1;if(16===e.keyCode||17===e.keyCode||18===e.keyCode)return!1;this._finalizeComposition(!1)}return 229!==e.keyCode||(this._handleAnyTextareaChanges(),!1)},e.prototype._finalizeComposition=function(e){var t=this;if(this._compositionView.classList.remove("active"),this._isComposing=!1,e){var n={start:this._compositionPosition.start,end:this._compositionPosition.end};this._isSendingComposition=!0,setTimeout((function(){var e;t._isSendingComposition&&(t._isSendingComposition=!1,e=t._isComposing?t._textarea.value.substring(n.start,n.end):t._textarea.value.substring(n.start),t._coreService.triggerDataEvent(e,!0))}),0)}else{this._isSendingComposition=!1;var r=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end);this._coreService.triggerDataEvent(r,!0)}},e.prototype._handleAnyTextareaChanges=function(){var e=this,t=this._textarea.value;setTimeout((function(){if(!e._isComposing){var n=e._textarea.value.replace(t,"");n.length>0&&e._coreService.triggerDataEvent(n,!0)}}),0)},e.prototype.updateCompositionElements=function(e){var t=this;if(this._isComposing){if(this._bufferService.buffer.isCursorInViewport){var n=Math.ceil(this._charSizeService.height*this._optionsService.options.lineHeight),r=this._bufferService.buffer.y*n,i=this._bufferService.buffer.x*this._charSizeService.width;this._compositionView.style.left=i+"px",this._compositionView.style.top=r+"px",this._compositionView.style.height=n+"px",this._compositionView.style.lineHeight=n+"px",this._compositionView.style.fontFamily=this._optionsService.options.fontFamily,this._compositionView.style.fontSize=this._optionsService.options.fontSize+"px";var o=this._compositionView.getBoundingClientRect();this._textarea.style.left=i+"px",this._textarea.style.top=r+"px",this._textarea.style.width=o.width+"px",this._textarea.style.height=o.height+"px",this._textarea.style.lineHeight=o.height+"px"}e||setTimeout((function(){return t.updateCompositionElements(!0)}),0)}},r([i(2,s.IBufferService),i(3,s.IOptionsService),i(4,o.ICharSizeService),i(5,s.ICoreService)],e)}();t.CompositionHelper=a},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Viewport=void 0;var a=n(2),c=n(7),l=n(5),u=n(1),h=function(e){function t(t,n,r,i,o,s,a){var l=e.call(this)||this;return l._scrollLines=t,l._viewportElement=n,l._scrollArea=r,l._bufferService=i,l._optionsService=o,l._charSizeService=s,l._renderService=a,l.scrollBarWidth=0,l._currentRowHeight=0,l._lastRecordedBufferLength=0,l._lastRecordedViewportHeight=0,l._lastRecordedBufferHeight=0,l._lastTouchY=0,l._lastScrollTop=0,l._wheelPartialScroll=0,l._refreshAnimationFrame=null,l._ignoreNextScrollEvent=!1,l.scrollBarWidth=l._viewportElement.offsetWidth-l._scrollArea.offsetWidth||15,l.register(c.addDisposableDomListener(l._viewportElement,"scroll",l._onScroll.bind(l))),setTimeout((function(){return l.syncScrollArea()}),0),l}return i(t,e),t.prototype.onThemeChange=function(e){this._viewportElement.style.backgroundColor=e.background.css},t.prototype._refresh=function(e){var t=this;if(e)return this._innerRefresh(),void(null!==this._refreshAnimationFrame&&cancelAnimationFrame(this._refreshAnimationFrame));null===this._refreshAnimationFrame&&(this._refreshAnimationFrame=requestAnimationFrame((function(){return t._innerRefresh()})))},t.prototype._innerRefresh=function(){if(this._charSizeService.height>0){this._currentRowHeight=this._renderService.dimensions.scaledCellHeight/window.devicePixelRatio,this._lastRecordedViewportHeight=this._viewportElement.offsetHeight;var e=Math.round(this._currentRowHeight*this._lastRecordedBufferLength)+(this._lastRecordedViewportHeight-this._renderService.dimensions.canvasHeight);this._lastRecordedBufferHeight!==e&&(this._lastRecordedBufferHeight=e,this._scrollArea.style.height=this._lastRecordedBufferHeight+"px")}var t=this._bufferService.buffer.ydisp*this._currentRowHeight;this._viewportElement.scrollTop!==t&&(this._ignoreNextScrollEvent=!0,this._viewportElement.scrollTop=t),this._refreshAnimationFrame=null},t.prototype.syncScrollArea=function(e){if(void 0===e&&(e=!1),this._lastRecordedBufferLength!==this._bufferService.buffer.lines.length)return this._lastRecordedBufferLength=this._bufferService.buffer.lines.length,void this._refresh(e);if(this._lastRecordedViewportHeight===this._renderService.dimensions.canvasHeight){var t=this._bufferService.buffer.ydisp*this._currentRowHeight;this._lastScrollTop===t&&this._lastScrollTop===this._viewportElement.scrollTop&&this._renderService.dimensions.scaledCellHeight/window.devicePixelRatio===this._currentRowHeight||this._refresh(e)}else this._refresh(e)},t.prototype._onScroll=function(e){if(this._lastScrollTop=this._viewportElement.scrollTop,this._viewportElement.offsetParent)if(this._ignoreNextScrollEvent)this._ignoreNextScrollEvent=!1;else{var t=Math.round(this._lastScrollTop/this._currentRowHeight)-this._bufferService.buffer.ydisp;this._scrollLines(t,!0)}},t.prototype._bubbleScroll=function(e,t){var n=this._viewportElement.scrollTop+this._lastRecordedViewportHeight;return!(t<0&&0!==this._viewportElement.scrollTop||t>0&&n0?1:-1),this._wheelPartialScroll%=1):e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(t*=this._bufferService.rows),t},t.prototype._applyScrollModifier=function(e,t){var n=this._optionsService.options.fastScrollModifier;return"alt"===n&&t.altKey||"ctrl"===n&&t.ctrlKey||"shift"===n&&t.shiftKey?e*this._optionsService.options.fastScrollSensitivity*this._optionsService.options.scrollSensitivity:e*this._optionsService.options.scrollSensitivity},t.prototype.onTouchStart=function(e){this._lastTouchY=e.touches[0].pageY},t.prototype.onTouchMove=function(e){var t=this._lastTouchY-e.touches[0].pageY;return this._lastTouchY=e.touches[0].pageY,0!==t&&(this._viewportElement.scrollTop+=t,this._bubbleScroll(e,t))},o([s(3,u.IBufferService),s(4,u.IOptionsService),s(5,l.ICharSizeService),s(6,l.IRenderService)],t)}(a.Disposable);t.Viewport=h},function(e,t,n){"use strict";function r(e){return e.replace(/\r?\n/g,"\r")}function i(e,t){return t?"[200~"+e+"[201~":e}function o(e,t,n){e=i(e=r(e),n.decPrivateModes.bracketedPasteMode),n.triggerDataEvent(e,!0),t.value=""}function s(e,t,n){var r=n.getBoundingClientRect(),i=e.clientX-r.left-10,o=e.clientY-r.top-10;t.style.width="20px",t.style.height="20px",t.style.left=i+"px",t.style.top=o+"px",t.style.zIndex="1000",t.focus()}Object.defineProperty(t,"__esModule",{value:!0}),t.rightClickHandler=t.moveTextAreaUnderMouseCursor=t.paste=t.handlePasteEvent=t.copyHandler=t.bracketTextForPaste=t.prepareTextForTerminal=void 0,t.prepareTextForTerminal=r,t.bracketTextForPaste=i,t.copyHandler=function(e,t){e.clipboardData&&e.clipboardData.setData("text/plain",t.selectionText),e.preventDefault()},t.handlePasteEvent=function(e,t,n){e.stopPropagation(),e.clipboardData&&o(e.clipboardData.getData("text/plain"),t,n)},t.paste=o,t.moveTextAreaUnderMouseCursor=s,t.rightClickHandler=function(e,t,n,r,i){s(e,t,n),i&&!r.isClickInSelection(e)&&r.selectWordAtCursor(e),t.value=r.selectionText,t.select()}},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.EscapeSequenceParser=t.VT500_TRANSITION_TABLE=t.TransitionTable=void 0;var o=n(2),s=n(15),a=n(21),c=n(22),l=n(24),u=function(){function e(e){this.table=new Uint8Array(e)}return e.prototype.setDefault=function(e,t){s.fill(this.table,e<<4|t)},e.prototype.add=function(e,t,n,r){this.table[t<<8|e]=n<<4|r},e.prototype.addMany=function(e,t,n,r){for(var i=0;i1)throw new Error("only one byte as prefix supported");if((n=e.prefix.charCodeAt(0))&&60>n||n>63)throw new Error("prefix must be in range 0x3c .. 0x3f")}if(e.intermediates){if(e.intermediates.length>2)throw new Error("only two bytes as intermediates are supported");for(var r=0;ri||i>47)throw new Error("intermediate must be in range 0x20 .. 0x2f");n<<=8,n|=i}}if(1!==e.final.length)throw new Error("final must be a single byte");var o=e.final.charCodeAt(0);if(t[0]>o||o>t[1])throw new Error("final must be in range "+t[0]+" .. "+t[1]);return(n<<=8)|o},n.prototype.identToString=function(e){for(var t=[];e;)t.push(String.fromCharCode(255&e)),e>>=8;return t.reverse().join("")},n.prototype.dispose=function(){this._csiHandlers=Object.create(null),this._executeHandlers=Object.create(null),this._escHandlers=Object.create(null),this._oscParser.dispose(),this._dcsParser.dispose()},n.prototype.setPrintHandler=function(e){this._printHandler=e},n.prototype.clearPrintHandler=function(){this._printHandler=this._printHandlerFb},n.prototype.addEscHandler=function(e,t){var n=this._identifier(e,[48,126]);void 0===this._escHandlers[n]&&(this._escHandlers[n]=[]);var r=this._escHandlers[n];return r.push(t),{dispose:function(){var e=r.indexOf(t);-1!==e&&r.splice(e,1)}}},n.prototype.setEscHandler=function(e,t){this._escHandlers[this._identifier(e,[48,126])]=[t]},n.prototype.clearEscHandler=function(e){this._escHandlers[this._identifier(e,[48,126])]&&delete this._escHandlers[this._identifier(e,[48,126])]},n.prototype.setEscHandlerFallback=function(e){this._escHandlerFb=e},n.prototype.setExecuteHandler=function(e,t){this._executeHandlers[e.charCodeAt(0)]=t},n.prototype.clearExecuteHandler=function(e){this._executeHandlers[e.charCodeAt(0)]&&delete this._executeHandlers[e.charCodeAt(0)]},n.prototype.setExecuteHandlerFallback=function(e){this._executeHandlerFb=e},n.prototype.addCsiHandler=function(e,t){var n=this._identifier(e);void 0===this._csiHandlers[n]&&(this._csiHandlers[n]=[]);var r=this._csiHandlers[n];return r.push(t),{dispose:function(){var e=r.indexOf(t);-1!==e&&r.splice(e,1)}}},n.prototype.setCsiHandler=function(e,t){this._csiHandlers[this._identifier(e)]=[t]},n.prototype.clearCsiHandler=function(e){this._csiHandlers[this._identifier(e)]&&delete this._csiHandlers[this._identifier(e)]},n.prototype.setCsiHandlerFallback=function(e){this._csiHandlerFb=e},n.prototype.addDcsHandler=function(e,t){return this._dcsParser.addHandler(this._identifier(e),t)},n.prototype.setDcsHandler=function(e,t){this._dcsParser.setHandler(this._identifier(e),t)},n.prototype.clearDcsHandler=function(e){this._dcsParser.clearHandler(this._identifier(e))},n.prototype.setDcsHandlerFallback=function(e){this._dcsParser.setHandlerFallback(e)},n.prototype.addOscHandler=function(e,t){return this._oscParser.addHandler(e,t)},n.prototype.setOscHandler=function(e,t){this._oscParser.setHandler(e,t)},n.prototype.clearOscHandler=function(e){this._oscParser.clearHandler(e)},n.prototype.setOscHandlerFallback=function(e){this._oscParser.setHandlerFallback(e)},n.prototype.setErrorHandler=function(e){this._errorHandler=e},n.prototype.clearErrorHandler=function(){this._errorHandler=this._errorHandlerFb},n.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},n.prototype.parse=function(e,t){for(var n=0,r=0,i=this.currentState,o=this._oscParser,s=this._dcsParser,a=this._collect,c=this._params,l=this._transitions.table,u=0;u>4){case 2:for(var h=u+1;;++h){if(h>=t||(n=e[h])<32||n>126&&n<160){this._printHandler(e,u,h),u=h-1;break}if(++h>=t||(n=e[h])<32||n>126&&n<160){this._printHandler(e,u,h),u=h-1;break}if(++h>=t||(n=e[h])<32||n>126&&n<160){this._printHandler(e,u,h),u=h-1;break}if(++h>=t||(n=e[h])<32||n>126&&n<160){this._printHandler(e,u,h),u=h-1;break}}break;case 3:this._executeHandlers[n]?this._executeHandlers[n]():this._executeHandlerFb(n),this.precedingCodepoint=0;break;case 0:break;case 1:if(this._errorHandler({position:u,code:n,currentState:i,collect:a,params:c,abort:!1}).abort)return;break;case 7:for(var d=this._csiHandlers[a<<8|n],f=d?d.length-1:-1;f>=0&&!1===d[f](c);f--);f<0&&this._csiHandlerFb(a<<8|n,c),this.precedingCodepoint=0;break;case 8:do{switch(n){case 59:c.addParam(0);break;case 58:c.addSubParam(-1);break;default:c.addDigit(n-48)}}while(++u47&&n<60);u--;break;case 9:a<<=8,a|=n;break;case 10:for(var p=this._escHandlers[a<<8|n],_=p?p.length-1:-1;_>=0&&!1===p[_]();_--);_<0&&this._escHandlerFb(a<<8|n),this.precedingCodepoint=0;break;case 11:c.reset(),c.addParam(0),a=0;break;case 12:s.hook(a<<8|n,c);break;case 13:for(var v=u+1;;++v)if(v>=t||24===(n=e[v])||26===n||27===n||n>127&&n<160){s.put(e,u,v),u=v-1;break}break;case 14:s.unhook(24!==n&&26!==n),27===n&&(r|=1),c.reset(),c.addParam(0),a=0,this.precedingCodepoint=0;break;case 4:o.start();break;case 5:for(var b=u+1;;b++)if(b>=t||(n=e[b])<32||n>127&&n<=159){o.put(e,u,b),u=b-1;break}break;case 6:o.end(24!==n&&26!==n),27===n&&(r|=1),c.reset(),c.addParam(0),a=0,this.precedingCodepoint=0}i=15&r}this._collect=a,this.currentState=i},n}(o.Disposable);t.EscapeSequenceParser=h},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Renderer=void 0;var a=n(41),c=n(47),l=n(48),u=n(49),h=n(29),d=n(2),f=n(5),p=n(1),_=n(25),v=n(0),b=1,g=function(e){function t(t,n,r,i,o,s,d,f,p){var _=e.call(this)||this;_._colors=t,_._screenElement=n,_._bufferService=o,_._charSizeService=s,_._optionsService=d,_._id=b++,_._onRequestRedraw=new v.EventEmitter;var g=_._optionsService.options.allowTransparency;return _._characterJoinerRegistry=new h.CharacterJoinerRegistry(_._bufferService),_._renderLayers=[new a.TextRenderLayer(_._screenElement,0,_._colors,_._characterJoinerRegistry,g,_._id,_._bufferService,d),new c.SelectionRenderLayer(_._screenElement,1,_._colors,_._id,_._bufferService,d),new u.LinkRenderLayer(_._screenElement,2,_._colors,_._id,r,i,_._bufferService,d),new l.CursorRenderLayer(_._screenElement,3,_._colors,_._id,_._onRequestRedraw,_._bufferService,d,f,p)],_.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},_._devicePixelRatio=window.devicePixelRatio,_._updateDimensions(),_.onOptionsChanged(),_}return i(t,e),Object.defineProperty(t.prototype,"onRequestRedraw",{get:function(){return this._onRequestRedraw.event},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){for(var t=0,n=this._renderLayers;t0&&u===a[0][0]){d=!0;var p=a.shift();h=new l.JoinedCellData(this._workCell,s.translateToString(!0,p[0],p[1]),p[1]-p[0]),f=p[1]-1}!d&&this._isOverlapping(h)&&fthis._characterWidth;return this._ctx.restore(),this._characterOverlapCache[t]=n,n},t}(s.BaseRenderLayer);t.TextRenderLayer=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GridCache=void 0;var r=function(){function e(){this.cache=[]}return e.prototype.resize=function(e,t){for(var n=0;n>>24,i=t.rgba>>>16&255,o=t.rgba>>>8&255,s=0;s=this.capacity)n=this._head,this._unlinkNode(n),delete this._map[n.key],n.key=e,n.value=t,this._map[e]=n;else{var r=this._nodePool;r.length>0?((n=r.pop()).key=e,n.value=t):n={prev:null,next:null,key:e,value:t},this._map[e]=n,this.size++}this._appendNode(n)},e}();t.LRUMap=r},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionRenderLayer=void 0;var o=function(e){function t(t,n,r,i,o,s){var a=e.call(this,t,"selection",n,!0,r,i,o,s)||this;return a._clearState(),a}return i(t,e),t.prototype._clearState=function(){this._state={start:void 0,end:void 0,columnSelectMode:void 0,ydisp:void 0}},t.prototype.resize=function(t){e.prototype.resize.call(this,t),this._clearState()},t.prototype.reset=function(){this._state.start&&this._state.end&&(this._clearState(),this._clearAll())},t.prototype.onSelectionChanged=function(e,t,n){if(this._didStateChange(e,t,n,this._bufferService.buffer.ydisp))if(this._clearAll(),e&&t){var r=e[1]-this._bufferService.buffer.ydisp,i=t[1]-this._bufferService.buffer.ydisp,o=Math.max(r,0),s=Math.min(i,this._bufferService.rows-1);if(!(o>=this._bufferService.rows||s<0)){if(this._ctx.fillStyle=this._colors.selectionTransparent.css,n){var a=e[0],c=t[0]-a,l=s-o+1;this._fillCells(a,o,c,l)}else{a=r===o?e[0]:0;var u=o===s?t[0]:this._bufferService.cols;this._fillCells(a,o,u-a,1);var h=Math.max(s-o-1,0);if(this._fillCells(0,o+1,this._bufferService.cols,h),o!==s){var d=i===s?t[0]:this._bufferService.cols;this._fillCells(0,s,d,1)}}this._state.start=[e[0],e[1]],this._state.end=[t[0],t[1]],this._state.columnSelectMode=n,this._state.ydisp=this._bufferService.buffer.ydisp}}else this._clearState()},t.prototype._didStateChange=function(e,t,n,r){return!this._areCoordinatesEqual(e,this._state.start)||!this._areCoordinatesEqual(t,this._state.end)||n!==this._state.columnSelectMode||r!==this._state.ydisp},t.prototype._areCoordinatesEqual=function(e,t){return!(!e||!t)&&e[0]===t[0]&&e[1]===t[1]},t}(n(13).BaseRenderLayer);t.SelectionRenderLayer=o},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.CursorRenderLayer=void 0;var o=n(13),s=n(4),a=function(e){function t(t,n,r,i,o,a,c,l,u){var h=e.call(this,t,"cursor",n,!0,r,i,a,c)||this;return h._onRequestRedraw=o,h._coreService=l,h._coreBrowserService=u,h._cell=new s.CellData,h._state={x:0,y:0,isFocused:!1,style:"",width:0},h._cursorRenderers={bar:h._renderBarCursor.bind(h),block:h._renderBlockCursor.bind(h),underline:h._renderUnderlineCursor.bind(h)},h}return i(t,e),t.prototype.resize=function(t){e.prototype.resize.call(this,t),this._state={x:0,y:0,isFocused:!1,style:"",width:0}},t.prototype.reset=function(){this._clearCursor(),this._cursorBlinkStateManager&&(this._cursorBlinkStateManager.dispose(),this._cursorBlinkStateManager=void 0,this.onOptionsChanged())},t.prototype.onBlur=function(){this._cursorBlinkStateManager&&this._cursorBlinkStateManager.pause(),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},t.prototype.onFocus=function(){this._cursorBlinkStateManager?this._cursorBlinkStateManager.resume():this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},t.prototype.onOptionsChanged=function(){var e,t=this;this._optionsService.options.cursorBlink?this._cursorBlinkStateManager||(this._cursorBlinkStateManager=new c(this._coreBrowserService.isFocused,(function(){t._render(!0)}))):(null===(e=this._cursorBlinkStateManager)||void 0===e||e.dispose(),this._cursorBlinkStateManager=void 0),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})},t.prototype.onCursorMove=function(){this._cursorBlinkStateManager&&this._cursorBlinkStateManager.restartBlinkAnimation()},t.prototype.onGridChanged=function(e,t){!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isPaused?this._render(!1):this._cursorBlinkStateManager.restartBlinkAnimation()},t.prototype._render=function(e){if(this._coreService.isCursorInitialized&&!this._coreService.isCursorHidden){var t=this._bufferService.buffer.ybase+this._bufferService.buffer.y,n=t-this._bufferService.buffer.ydisp;if(n<0||n>=this._bufferService.rows)this._clearCursor();else{var r=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1);if(this._bufferService.buffer.lines.get(t).loadCell(r,this._cell),void 0!==this._cell.content){if(!this._coreBrowserService.isFocused){this._clearCursor(),this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css;var i=this._optionsService.options.cursorStyle;return i&&"block"!==i?this._cursorRenderers[i](r,n,this._cell):this._renderBlurCursor(r,n,this._cell),this._ctx.restore(),this._state.x=r,this._state.y=n,this._state.isFocused=!1,this._state.style=i,void(this._state.width=this._cell.getWidth())}if(!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isCursorVisible){if(this._state){if(this._state.x===r&&this._state.y===n&&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"](r,n,this._cell),this._ctx.restore(),this._state.x=r,this._state.y=n,this._state.isFocused=!1,this._state.style=this._optionsService.options.cursorStyle,this._state.width=this._cell.getWidth()}else this._clearCursor()}}}else this._clearCursor()},t.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})},t.prototype._renderBarCursor=function(e,t,n){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillLeftLineAtCell(e,t,this._optionsService.options.cursorWidth),this._ctx.restore()},t.prototype._renderBlockCursor=function(e,t,n){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillCells(e,t,n.getWidth(),1),this._ctx.fillStyle=this._colors.cursorAccent.css,this._fillCharTrueColor(n,e,t),this._ctx.restore()},t.prototype._renderUnderlineCursor=function(e,t,n){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._fillBottomLineAtCells(e,t),this._ctx.restore()},t.prototype._renderBlurCursor=function(e,t,n){this._ctx.save(),this._ctx.strokeStyle=this._colors.cursor.css,this._strokeRectAtCell(e,t,n.getWidth(),1),this._ctx.restore()},t}(o.BaseRenderLayer);t.CursorRenderLayer=a;var c=function(){function e(e,t){this._renderCallback=t,this.isCursorVisible=!0,e&&this._restartInterval()}return Object.defineProperty(e.prototype,"isPaused",{get:function(){return!(this._blinkStartTimeout||this._blinkInterval)},enumerable:!1,configurable:!0}),e.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)},e.prototype.restartBlinkAnimation=function(){var e=this;this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame||(this._animationFrame=window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=void 0}))))},e.prototype._restartInterval=function(e){var t=this;void 0===e&&(e=600),this._blinkInterval&&window.clearInterval(this._blinkInterval),this._blinkStartTimeout=window.setTimeout((function(){if(t._animationTimeRestarted){var e=600-(Date.now()-t._animationTimeRestarted);if(t._animationTimeRestarted=void 0,e>0)return void t._restartInterval(e)}t.isCursorVisible=!1,t._animationFrame=window.requestAnimationFrame((function(){t._renderCallback(),t._animationFrame=void 0})),t._blinkInterval=window.setInterval((function(){if(t._animationTimeRestarted){var e=600-(Date.now()-t._animationTimeRestarted);return t._animationTimeRestarted=void 0,void t._restartInterval(e)}t.isCursorVisible=!t.isCursorVisible,t._animationFrame=window.requestAnimationFrame((function(){t._renderCallback(),t._animationFrame=void 0}))}),600)}),e)},e.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)},e.prototype.resume=function(){this.pause(),this._animationTimeRestarted=void 0,this._restartInterval(),this.restartBlinkAnimation()},e}()},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.LinkRenderLayer=void 0;var o=n(13),s=n(9),a=n(26),c=function(e){function t(t,n,r,i,o,s,a,c){var l=e.call(this,t,"link",n,!0,r,i,a,c)||this;return o.onShowLinkUnderline((function(e){return l._onShowLinkUnderline(e)})),o.onHideLinkUnderline((function(e){return l._onHideLinkUnderline(e)})),s.onShowLinkUnderline((function(e){return l._onShowLinkUnderline(e)})),s.onHideLinkUnderline((function(e){return l._onHideLinkUnderline(e)})),l}return i(t,e),t.prototype.resize=function(t){e.prototype.resize.call(this,t),this._state=void 0},t.prototype.reset=function(){this._clearCurrentLink()},t.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}},t.prototype._onShowLinkUnderline=function(e){if(e.fg===s.INVERTED_DEFAULT_COLOR?this._ctx.fillStyle=this._colors.background.css:e.fg&&a.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 t=e.y1+1;t=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.MouseZone=t.Linkifier=void 0;var o=n(0),s=n(1),a=function(){function e(e,t,n){this._bufferService=e,this._logService=t,this._unicodeService=n,this._linkMatchers=[],this._nextLinkMatcherId=0,this._onShowLinkUnderline=new o.EventEmitter,this._onHideLinkUnderline=new o.EventEmitter,this._onLinkTooltip=new o.EventEmitter,this._rowsToLinkify={start:void 0,end:void 0}}return Object.defineProperty(e.prototype,"onShowLinkUnderline",{get:function(){return this._onShowLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onHideLinkUnderline",{get:function(){return this._onHideLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onLinkTooltip",{get:function(){return this._onLinkTooltip.event},enumerable:!1,configurable:!0}),e.prototype.attachToDom=function(e,t){this._element=e,this._mouseZoneManager=t},e.prototype.linkifyRows=function(t,n){var r=this;this._mouseZoneManager&&(void 0===this._rowsToLinkify.start||void 0===this._rowsToLinkify.end?(this._rowsToLinkify.start=t,this._rowsToLinkify.end=n):(this._rowsToLinkify.start=Math.min(this._rowsToLinkify.start,t),this._rowsToLinkify.end=Math.max(this._rowsToLinkify.end,n)),this._mouseZoneManager.clearAll(t,n),this._rowsTimeoutId&&clearTimeout(this._rowsTimeoutId),this._rowsTimeoutId=setTimeout((function(){return r._linkifyRows()}),e._timeBeforeLatency))},e.prototype._linkifyRows=function(){this._rowsTimeoutId=void 0;var e=this._bufferService.buffer;if(void 0!==this._rowsToLinkify.start&&void 0!==this._rowsToLinkify.end){var t=e.ydisp+this._rowsToLinkify.start;if(!(t>=e.lines.length)){for(var n=e.ydisp+Math.min(this._rowsToLinkify.end,this._bufferService.rows)+1,r=Math.ceil(2e3/this._bufferService.cols),i=this._bufferService.buffer.iterator(!1,t,n,r,r);i.hasNext();)for(var o=i.next(),s=0;s=0;t--)if(e.priority<=this._linkMatchers[t].priority)return void this._linkMatchers.splice(t+1,0,e);this._linkMatchers.splice(0,0,e)}else this._linkMatchers.push(e)},e.prototype.deregisterLinkMatcher=function(e){for(var t=0;t>9&511:void 0;n.validationCallback?n.validationCallback(a,(function(e){i._rowsTimeoutId||e&&i._addLink(l[1],l[0]-i._bufferService.buffer.ydisp,a,n,d)})):c._addLink(l[1],l[0]-c._bufferService.buffer.ydisp,a,n,d)},c=this;null!==(r=o.exec(t))&&"break"!==a(););},e.prototype._addLink=function(e,t,n,r,i){var o=this;if(this._mouseZoneManager&&this._element){var s=this._unicodeService.getStringCellWidth(n),a=e%this._bufferService.cols,l=t+Math.floor(e/this._bufferService.cols),u=(a+s)%this._bufferService.cols,h=l+Math.floor((a+s)/this._bufferService.cols);0===u&&(u=this._bufferService.cols,h--),this._mouseZoneManager.add(new c(a+1,l+1,u+1,h+1,(function(e){if(r.handler)return r.handler(e,n);var t=window.open();t?(t.opener=null,t.location.href=n):console.warn("Opening link blocked as opener could not be cleared")}),(function(){o._onShowLinkUnderline.fire(o._createLinkHoverEvent(a,l,u,h,i)),o._element.classList.add("xterm-cursor-pointer")}),(function(e){o._onLinkTooltip.fire(o._createLinkHoverEvent(a,l,u,h,i)),r.hoverTooltipCallback&&r.hoverTooltipCallback(e,n,{start:{x:a,y:l},end:{x:u,y:h}})}),(function(){o._onHideLinkUnderline.fire(o._createLinkHoverEvent(a,l,u,h,i)),o._element.classList.remove("xterm-cursor-pointer"),r.hoverLeaveCallback&&r.hoverLeaveCallback()}),(function(e){return!r.willLinkActivate||r.willLinkActivate(e,n)})))}},e.prototype._createLinkHoverEvent=function(e,t,n,r,i){return{x1:e,y1:t,x2:n,y2:r,cols:this._bufferService.cols,fg:i}},e._timeBeforeLatency=200,e=r([i(0,s.IBufferService),i(1,s.ILogService),i(2,s.IUnicodeService)],e)}();t.Linkifier=a;var c=function(e,t,n,r,i,o,s,a,c){this.x1=e,this.y1=t,this.x2=n,this.y2=r,this.clickCallback=i,this.hoverCallback=o,this.tooltipCallback=s,this.leaveCallback=a,this.willLinkActivate=c};t.MouseZone=c},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionService=void 0;var a=n(11),c=n(52),l=n(4),u=n(0),h=n(5),d=n(1),f=n(30),p=n(53),_=n(2),v=String.fromCharCode(160),b=new RegExp(v,"g"),g=function(e){function t(t,n,r,i,o,s,a){var h=e.call(this)||this;return h._element=t,h._screenElement=n,h._bufferService=r,h._coreService=i,h._mouseService=o,h._optionsService=s,h._renderService=a,h._dragScrollAmount=0,h._enabled=!0,h._workCell=new l.CellData,h._mouseDownTimeStamp=0,h._onLinuxMouseSelection=h.register(new u.EventEmitter),h._onRedrawRequest=h.register(new u.EventEmitter),h._onSelectionChange=h.register(new u.EventEmitter),h._onRequestScrollLines=h.register(new u.EventEmitter),h._mouseMoveListener=function(e){return h._onMouseMove(e)},h._mouseUpListener=function(e){return h._onMouseUp(e)},h._coreService.onUserInput((function(){h.hasSelection&&h.clearSelection()})),h._trimListener=h._bufferService.buffer.lines.onTrim((function(e){return h._onTrim(e)})),h.register(h._bufferService.buffers.onBufferActivate((function(e){return h._onBufferActivate(e)}))),h.enable(),h._model=new c.SelectionModel(h._bufferService),h._activeSelectionMode=0,h}return i(t,e),Object.defineProperty(t.prototype,"onLinuxMouseSelection",{get:function(){return this._onLinuxMouseSelection.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestRedraw",{get:function(){return this._onRedrawRequest.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onSelectionChange",{get:function(){return this._onSelectionChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRequestScrollLines",{get:function(){return this._onRequestScrollLines.event},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){this._removeMouseDownListeners()},t.prototype.reset=function(){this.clearSelection()},t.prototype.disable=function(){this.clearSelection(),this._enabled=!1},t.prototype.enable=function(){this._enabled=!0},Object.defineProperty(t.prototype,"selectionStart",{get:function(){return this._model.finalSelectionStart},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectionEnd",{get:function(){return this._model.finalSelectionEnd},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasSelection",{get:function(){var e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;return!(!e||!t||e[0]===t[0]&&e[1]===t[1])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectionText",{get:function(){var e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;if(!e||!t)return"";var n=this._bufferService.buffer,r=[];if(3===this._activeSelectionMode){if(e[0]===t[0])return"";for(var i=e[1];i<=t[1];i++){var o=n.translateBufferLineToString(i,!0,e[0],t[0]);r.push(o)}}else{var s=e[1]===t[1]?t[0]:void 0;for(r.push(n.translateBufferLineToString(e[1],!0,e[0],s)),i=e[1]+1;i<=t[1]-1;i++){var c=n.lines.get(i);o=n.translateBufferLineToString(i,!0),c&&c.isWrapped?r[r.length-1]+=o:r.push(o)}e[1]!==t[1]&&(c=n.lines.get(t[1]),o=n.translateBufferLineToString(t[1],!0,0,t[0]),c&&c.isWrapped?r[r.length-1]+=o:r.push(o))}return r.map((function(e){return e.replace(b," ")})).join(a.isWindows?"\r\n":"\n")},enumerable:!1,configurable:!0}),t.prototype.clearSelection=function(){this._model.clearSelection(),this._removeMouseDownListeners(),this.refresh(),this._onSelectionChange.fire()},t.prototype.refresh=function(e){var t=this;this._refreshAnimationFrame||(this._refreshAnimationFrame=window.requestAnimationFrame((function(){return t._refresh()}))),a.isLinux&&e&&this.selectionText.length&&this._onLinuxMouseSelection.fire(this.selectionText)},t.prototype._refresh=function(){this._refreshAnimationFrame=void 0,this._onRedrawRequest.fire({start:this._model.finalSelectionStart,end:this._model.finalSelectionEnd,columnSelectMode:3===this._activeSelectionMode})},t.prototype.isClickInSelection=function(e){var t=this._getMouseBufferCoords(e),n=this._model.finalSelectionStart,r=this._model.finalSelectionEnd;return!!(n&&r&&t)&&this._areCoordsInSelection(t,n,r)},t.prototype._areCoordsInSelection=function(e,t,n){return e[1]>t[1]&&e[1]=t[0]&&e[0]=t[0]},t.prototype.selectWordAtCursor=function(e){var t=this._getMouseBufferCoords(e);t&&(this._selectWordAt(t,!1),this._model.selectionEnd=void 0,this.refresh(!0))},t.prototype.selectAll=function(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()},t.prototype.selectLines=function(e,t){this._model.clearSelection(),e=Math.max(e,0),t=Math.min(t,this._bufferService.buffer.lines.length-1),this._model.selectionStart=[0,e],this._model.selectionEnd=[this._bufferService.cols,t],this.refresh(),this._onSelectionChange.fire()},t.prototype._onTrim=function(e){this._model.onTrim(e)&&this.refresh()},t.prototype._getMouseBufferCoords=function(e){var t=this._mouseService.getCoords(e,this._screenElement,this._bufferService.cols,this._bufferService.rows,!0);if(t)return t[0]--,t[1]--,t[1]+=this._bufferService.buffer.ydisp,t},t.prototype._getMouseEventScrollAmount=function(e){var t=f.getCoordsRelativeToElement(e,this._screenElement)[1],n=this._renderService.dimensions.canvasHeight;return t>=0&&t<=n?0:(t>n&&(t-=n),t=Math.min(Math.max(t,-50),50),(t/=50)/Math.abs(t)+Math.round(14*t))},t.prototype.shouldForceSelection=function(e){return a.isMac?e.altKey&&this._optionsService.options.macOptionClickForcesSelection:e.shiftKey},t.prototype.onMouseDown=function(e){if(this._mouseDownTimeStamp=e.timeStamp,(2!==e.button||!this.hasSelection)&&0===e.button){if(!this._enabled){if(!this.shouldForceSelection(e))return;e.stopPropagation()}e.preventDefault(),this._dragScrollAmount=0,this._enabled&&e.shiftKey?this._onIncrementalClick(e):1===e.detail?this._onSingleClick(e):2===e.detail?this._onDoubleClick(e):3===e.detail&&this._onTripleClick(e),this._addMouseDownListeners(),this.refresh(!0)}},t.prototype._addMouseDownListeners=function(){var e=this;this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.addEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.addEventListener("mouseup",this._mouseUpListener)),this._dragScrollIntervalTimer=window.setInterval((function(){return e._dragScroll()}),50)},t.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},t.prototype._onIncrementalClick=function(e){this._model.selectionStart&&(this._model.selectionEnd=this._getMouseBufferCoords(e))},t.prototype._onSingleClick=function(e){if(this._model.selectionStartLength=0,this._model.isSelectAllActive=!1,this._activeSelectionMode=this.shouldColumnSelect(e)?3:0,this._model.selectionStart=this._getMouseBufferCoords(e),this._model.selectionStart){this._model.selectionEnd=void 0;var t=this._bufferService.buffer.lines.get(this._model.selectionStart[1]);t&&t.length!==this._model.selectionStart[0]&&0===t.hasWidth(this._model.selectionStart[0])&&this._model.selectionStart[0]++}},t.prototype._onDoubleClick=function(e){var t=this._getMouseBufferCoords(e);t&&(this._activeSelectionMode=1,this._selectWordAt(t,!0))},t.prototype._onTripleClick=function(e){var t=this._getMouseBufferCoords(e);t&&(this._activeSelectionMode=2,this._selectLineAt(t[1]))},t.prototype.shouldColumnSelect=function(e){return e.altKey&&!(a.isMac&&this._optionsService.options.macOptionClickForcesSelection)},t.prototype._onMouseMove=function(e){if(e.stopImmediatePropagation(),this._model.selectionStart){var t=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;if(this._model.selectionEnd=this._getMouseBufferCoords(e),this._model.selectionEnd){2===this._activeSelectionMode?this._model.selectionEnd[1]0?this._model.selectionEnd[0]=this._bufferService.cols:this._dragScrollAmount<0&&(this._model.selectionEnd[0]=0));var n=this._bufferService.buffer;if(this._model.selectionEnd[1]0?(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=this._bufferService.cols),this._model.selectionEnd[1]=Math.min(e.ydisp+this._bufferService.rows,e.lines.length-1)):(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=0),this._model.selectionEnd[1]=e.ydisp),this.refresh()}},t.prototype._onMouseUp=function(e){var t=e.timeStamp-this._mouseDownTimeStamp;if(this._removeMouseDownListeners(),this.selectionText.length<=1&&t<500&&e.altKey){if(this._bufferService.buffer.ybase===this._bufferService.buffer.ydisp){var n=this._mouseService.getCoords(e,this._element,this._bufferService.cols,this._bufferService.rows,!1);if(n&&void 0!==n[0]&&void 0!==n[1]){var r=p.moveToCellSequence(n[0]-1,n[1]-1,this._bufferService,this._coreService.decPrivateModes.applicationCursorKeys);this._coreService.triggerDataEvent(r,!0)}}}else this.hasSelection&&this._onSelectionChange.fire()},t.prototype._onBufferActivate=function(e){var t=this;this.clearSelection(),this._trimListener.dispose(),this._trimListener=e.activeBuffer.lines.onTrim((function(e){return t._onTrim(e)}))},t.prototype._convertViewportColToCharacterIndex=function(e,t){for(var n=t[0],r=0;t[0]>=r;r++){var i=e.loadCell(r,this._workCell).getChars().length;0===this._workCell.getWidth()?n--:i>1&&t[0]!==r&&(n+=i-1)}return n},t.prototype.setSelection=function(e,t,n){this._model.clearSelection(),this._removeMouseDownListeners(),this._model.selectionStart=[e,t],this._model.selectionStartLength=n,this.refresh()},t.prototype._getWordAt=function(e,t,n,r){if(void 0===n&&(n=!0),void 0===r&&(r=!0),!(e[0]>=this._bufferService.cols)){var i=this._bufferService.buffer,o=i.lines.get(e[1]);if(o){var s=i.translateBufferLineToString(e[1],!1),a=this._convertViewportColToCharacterIndex(o,e),c=a,l=e[0]-a,u=0,h=0,d=0,f=0;if(" "===s.charAt(a)){for(;a>0&&" "===s.charAt(a-1);)a--;for(;c1&&(f+=v-1,c+=v-1);p>0&&a>0&&!this._isCharWordSeparator(o.loadCell(p-1,this._workCell));){o.loadCell(p-1,this._workCell);var b=this._workCell.getChars().length;0===this._workCell.getWidth()?(u++,p--):b>1&&(d+=b-1,a-=b-1),a--,p--}for(;_1&&(f+=g-1,c+=g-1),c++,_++}}c++;var m=a+l-u+d,y=Math.min(this._bufferService.cols,c-a+u+h-d-f);if(t||""!==s.slice(a,c).trim()){if(n&&0===m&&32!==o.getCodePoint(0)){var w=i.lines.get(e[1]-1);if(w&&o.isWrapped&&32!==w.getCodePoint(this._bufferService.cols-1)){var S=this._getWordAt([this._bufferService.cols-1,e[1]-1],!1,!0,!1);if(S){var C=this._bufferService.cols-S.start;m-=C,y+=C}}}if(r&&m+y===this._bufferService.cols&&32!==o.getCodePoint(this._bufferService.cols-1)){var k=i.lines.get(e[1]+1);if(k&&k.isWrapped&&32!==k.getCodePoint(0)){var E=this._getWordAt([0,e[1]+1],!1,!1,!0);E&&(y+=E.length)}}return{start:m,length:y}}}}},t.prototype._selectWordAt=function(e,t){var n=this._getWordAt(e,t);if(n){for(;n.start<0;)n.start+=this._bufferService.cols,e[1]--;this._model.selectionStart=[n.start,e[1]],this._model.selectionStartLength=n.length}},t.prototype._selectToWordAt=function(e){var t=this._getWordAt(e,!0);if(t){for(var n=e[1];t.start<0;)t.start+=this._bufferService.cols,n--;if(!this._model.areSelectionValuesReversed())for(;t.start+t.length>this._bufferService.cols;)t.length-=this._bufferService.cols,n++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?t.start:t.start+t.length,n]}},t.prototype._isCharWordSeparator=function(e){return 0!==e.getWidth()&&this._optionsService.options.wordSeparator.indexOf(e.getChars())>=0},t.prototype._selectLineAt=function(e){var t=this._bufferService.buffer.getWrappedRangeForLine(e);this._model.selectionStart=[0,t.first],this._model.selectionEnd=[this._bufferService.cols,t.last],this._model.selectionStartLength=0},o([s(2,d.IBufferService),s(3,d.ICoreService),s(4,h.IMouseService),s(5,d.IOptionsService),s(6,h.IRenderService)],t)}(_.Disposable);t.SelectionService=g},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionModel=void 0;var r=function(){function e(e){this._bufferService=e,this.isSelectAllActive=!1,this.selectionStartLength=0}return e.prototype.clearSelection=function(){this.selectionStart=void 0,this.selectionEnd=void 0,this.isSelectAllActive=!1,this.selectionStartLength=0},Object.defineProperty(e.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(e.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 e=this.selectionStart[0]+this.selectionStartLength;return e>this._bufferService.cols?[e%this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)]:[e,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}),e.prototype.areSelectionValuesReversed=function(){var e=this.selectionStart,t=this.selectionEnd;return!(!e||!t)&&(e[1]>t[1]||e[1]===t[1]&&e[0]>t[0])},e.prototype.onTrim=function(e){return this.selectionStart&&(this.selectionStart[1]-=e),this.selectionEnd&&(this.selectionEnd[1]-=e),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)},e}();t.SelectionModel=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.moveToCellSequence=void 0;var r=n(12);function i(e,t,n,r){var i=e-o(n,e),a=t-o(n,t);return l(Math.abs(i-a)-function(e,t,n){for(var r=0,i=e-o(n,e),a=t-o(n,t),c=0;c=0&&tt?"A":"B"}function a(e,t,n,r,i,o){for(var s=e,a=t,c="";s!==n||a!==r;)s+=i?1:-1,i&&s>o.cols-1?(c+=o.buffer.translateBufferLineToString(a,!1,e,s),s=0,e=0,a++):!i&&s<0&&(c+=o.buffer.translateBufferLineToString(a,!1,0,e+1),e=s=o.cols-1,a--);return c+o.buffer.translateBufferLineToString(a,!1,e,s)}function c(e,t){var n=t?"O":"[";return r.C0.ESC+n+e}function l(e,t){e=Math.floor(e);for(var n="",r=0;r0?r-o(s,r):t;var d=r,f=function(e,t,n,r,s,a){var c;return c=i(n,r,s,a).length>0?r-o(s,r):t,e=n&&ce?"D":"C",l(Math.abs(u-e),c(s,r));s=h>t?"D":"C";var d=Math.abs(h-t);return l(function(e,t){return t.cols-e}(h>t?e:u,n)+(d-1)*n.cols+1+((h>t?u:e)-1),c(s,r))}},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.SoundService=void 0;var o=n(1),s=function(){function e(e){this._optionsService=e}return Object.defineProperty(e,"audioContext",{get:function(){if(!e._audioContext){var t=window.AudioContext||window.webkitAudioContext;if(!t)return console.warn("Web Audio API is not supported by this browser. Consider upgrading to the latest version"),null;e._audioContext=new t}return e._audioContext},enumerable:!1,configurable:!0}),e.prototype.playBellSound=function(){var t=e.audioContext;if(t){var n=t.createBufferSource();t.decodeAudioData(this._base64ToArrayBuffer(this._removeMimeType(this._optionsService.options.bellSound)),(function(e){n.buffer=e,n.connect(t.destination),n.start(0)}))}},e.prototype._base64ToArrayBuffer=function(e){for(var t=window.atob(e),n=t.length,r=new Uint8Array(n),i=0;i=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.MouseZoneManager=void 0;var a=n(2),c=n(7),l=n(5),u=n(1),h=function(e){function t(t,n,r,i,o,s){var a=e.call(this)||this;return a._element=t,a._screenElement=n,a._bufferService=r,a._mouseService=i,a._selectionService=o,a._optionsService=s,a._zones=[],a._areZonesActive=!1,a._lastHoverCoords=[void 0,void 0],a._initialSelectionLength=0,a.register(c.addDisposableDomListener(a._element,"mousedown",(function(e){return a._onMouseDown(e)}))),a._mouseMoveListener=function(e){return a._onMouseMove(e)},a._mouseLeaveListener=function(e){return a._onMouseLeave(e)},a._clickListener=function(e){return a._onClick(e)},a}return i(t,e),t.prototype.dispose=function(){e.prototype.dispose.call(this),this._deactivate()},t.prototype.add=function(e){this._zones.push(e),1===this._zones.length&&this._activate()},t.prototype.clearAll=function(e,t){if(0!==this._zones.length){e&&t||(e=0,t=this._bufferService.rows-1);for(var n=0;ne&&r.y1<=t+1||r.y2>e&&r.y2<=t+1||r.y1t+1)&&(this._currentZone&&this._currentZone===r&&(this._currentZone.leaveCallback(),this._currentZone=void 0),this._zones.splice(n--,1))}0===this._zones.length&&this._deactivate()}},t.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))},t.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))},t.prototype._onMouseMove=function(e){this._lastHoverCoords[0]===e.pageX&&this._lastHoverCoords[1]===e.pageY||(this._onHover(e),this._lastHoverCoords=[e.pageX,e.pageY])},t.prototype._onHover=function(e){var t=this,n=this._findZoneEventAt(e);n!==this._currentZone&&(this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=void 0,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout)),n&&(this._currentZone=n,n.hoverCallback&&n.hoverCallback(e),this._tooltipTimeout=window.setTimeout((function(){return t._onTooltip(e)}),this._optionsService.options.linkTooltipHoverDuration)))},t.prototype._onTooltip=function(e){this._tooltipTimeout=void 0;var t=this._findZoneEventAt(e);t&&t.tooltipCallback&&t.tooltipCallback(e)},t.prototype._onMouseDown=function(e){if(this._initialSelectionLength=this._getSelectionLength(),this._areZonesActive){var t=this._findZoneEventAt(e);(null==t?void 0:t.willLinkActivate(e))&&(e.preventDefault(),e.stopImmediatePropagation())}},t.prototype._onMouseLeave=function(e){this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=void 0,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout))},t.prototype._onClick=function(e){var t=this._findZoneEventAt(e),n=this._getSelectionLength();t&&n===this._initialSelectionLength&&(t.clickCallback(e),e.preventDefault(),e.stopImmediatePropagation())},t.prototype._getSelectionLength=function(){var e=this._selectionService.selectionText;return e?e.length:0},t.prototype._findZoneEventAt=function(e){var t=this._mouseService.getCoords(e,this._screenElement,this._bufferService.cols,this._bufferService.rows);if(t)for(var n=t[0],r=t[1],i=0;i=o.x1&&n=o.x1||r===o.y2&&no.y1&&re;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()},t.prototype._createAccessibilityTreeNode=function(){var e=document.createElement("div");return e.setAttribute("role","listitem"),e.tabIndex=-1,this._refreshRowDimensions(e),e},t.prototype._onTab=function(e){for(var t=0;t0?this._charsToConsume.shift()!==e&&(this._charsToAnnounce+=e):this._charsToAnnounce+=e,"\n"===e&&(this._liveRegionLineCount++,21===this._liveRegionLineCount&&(this._liveRegion.textContent+=o.tooMuchOutput)),s.isMac&&this._liveRegion.textContent&&this._liveRegion.textContent.length>0&&!this._liveRegion.parentNode&&setTimeout((function(){t._accessibilityTreeRoot.appendChild(t._liveRegion)}),0))},t.prototype._clearLiveRegion=function(){this._liveRegion.textContent="",this._liveRegionLineCount=0,s.isMac&&h.removeElementFromParent(this._liveRegion)},t.prototype._onKey=function(e){this._clearLiveRegion(),this._charsToConsume.push(e)},t.prototype._refreshRows=function(e,t){this._renderRowsDebouncer.refresh(e,t,this._terminal.rows)},t.prototype._renderRows=function(e,t){for(var n=this._terminal.buffer,r=n.lines.length.toString(),i=e;i<=t;i++){var o=n.translateBufferLineToString(n.ydisp+i,!0),s=(n.ydisp+i+1).toString(),a=this._rowElements[i];a&&(0===o.length?a.innerHTML=" ":a.textContent=o,a.setAttribute("aria-posinset",s),a.setAttribute("aria-setsize",r))}this._announceCharacters()},t.prototype._refreshRowsDimensions=function(){if(this._renderService.dimensions.actualCellHeight){this._rowElements.length!==this._terminal.rows&&this._onResize(this._terminal.rows);for(var e=0;e=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.DomRenderer=void 0;var a=n(58),c=n(9),l=n(2),u=n(5),h=n(1),d=n(0),f=n(10),p=n(17),_=1,v=function(e){function t(t,n,r,i,o,s,c,l,u){var h=e.call(this)||this;return h._colors=t,h._element=n,h._screenElement=r,h._viewportElement=i,h._linkifier=o,h._linkifier2=s,h._charSizeService=c,h._optionsService=l,h._bufferService=u,h._terminalClass=_++,h._rowElements=[],h._rowContainer=document.createElement("div"),h._rowContainer.classList.add("xterm-rows"),h._rowContainer.style.lineHeight="normal",h._rowContainer.setAttribute("aria-hidden","true"),h._refreshRowElements(h._bufferService.cols,h._bufferService.rows),h._selectionContainer=document.createElement("div"),h._selectionContainer.classList.add("xterm-selection"),h._selectionContainer.setAttribute("aria-hidden","true"),h.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},h._updateDimensions(),h._injectCss(),h._rowFactory=new a.DomRendererRowFactory(document,h._optionsService,h._colors),h._element.classList.add("xterm-dom-renderer-owner-"+h._terminalClass),h._screenElement.appendChild(h._rowContainer),h._screenElement.appendChild(h._selectionContainer),h._linkifier.onShowLinkUnderline((function(e){return h._onLinkHover(e)})),h._linkifier.onHideLinkUnderline((function(e){return h._onLinkLeave(e)})),h._linkifier2.onShowLinkUnderline((function(e){return h._onLinkHover(e)})),h._linkifier2.onHideLinkUnderline((function(e){return h._onLinkLeave(e)})),h}return i(t,e),Object.defineProperty(t.prototype,"onRequestRedraw",{get:function(){return(new d.EventEmitter).event},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){this._element.classList.remove("xterm-dom-renderer-owner-"+this._terminalClass),p.removeElementFromParent(this._rowContainer,this._selectionContainer,this._themeStyleElement,this._dimensionsStyleElement),e.prototype.dispose.call(this)},t.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 e=0,t=this._rowElements;et;)this._rowContainer.removeChild(this._rowElements.pop())},t.prototype.onResize=function(e,t){this._refreshRowElements(e,t),this._updateDimensions()},t.prototype.onCharSizeChanged=function(){this._updateDimensions()},t.prototype.onBlur=function(){this._rowContainer.classList.remove("xterm-focus")},t.prototype.onFocus=function(){this._rowContainer.classList.add("xterm-focus")},t.prototype.onSelectionChanged=function(e,t,n){for(;this._selectionContainer.children.length;)this._selectionContainer.removeChild(this._selectionContainer.children[0]);if(e&&t){var r=e[1]-this._bufferService.buffer.ydisp,i=t[1]-this._bufferService.buffer.ydisp,o=Math.max(r,0),s=Math.min(i,this._bufferService.rows-1);if(!(o>=this._bufferService.rows||s<0)){var a=document.createDocumentFragment();if(n)a.appendChild(this._createSelectionElement(o,e[0],t[0],s-o+1));else{var c=r===o?e[0]:0,l=o===s?t[0]:this._bufferService.cols;a.appendChild(this._createSelectionElement(o,c,l));var u=s-o-1;if(a.appendChild(this._createSelectionElement(o+1,0,this._bufferService.cols,u)),o!==s){var h=i===s?t[0]:this._bufferService.cols;a.appendChild(this._createSelectionElement(s,0,h))}}this._selectionContainer.appendChild(a)}}},t.prototype._createSelectionElement=function(e,t,n,r){void 0===r&&(r=1);var i=document.createElement("div");return i.style.height=r*this.dimensions.actualCellHeight+"px",i.style.top=e*this.dimensions.actualCellHeight+"px",i.style.left=t*this.dimensions.actualCellWidth+"px",i.style.width=this.dimensions.actualCellWidth*(n-t)+"px",i},t.prototype.onCursorMove=function(){},t.prototype.onOptionsChanged=function(){this._updateDimensions(),this._injectCss()},t.prototype.clear=function(){for(var e=0,t=this._rowElements;e=i&&(e=0,n++)}},o([s(6,u.ICharSizeService),s(7,h.IOptionsService),s(8,h.IBufferService)],t)}(l.Disposable);t.DomRenderer=v},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DomRendererRowFactory=t.CURSOR_STYLE_UNDERLINE_CLASS=t.CURSOR_STYLE_BAR_CLASS=t.CURSOR_STYLE_BLOCK_CLASS=t.CURSOR_BLINK_CLASS=t.CURSOR_CLASS=t.UNDERLINE_CLASS=t.ITALIC_CLASS=t.DIM_CLASS=t.BOLD_CLASS=void 0;var r=n(9),i=n(3),o=n(4),s=n(10);t.BOLD_CLASS="xterm-bold",t.DIM_CLASS="xterm-dim",t.ITALIC_CLASS="xterm-italic",t.UNDERLINE_CLASS="xterm-underline",t.CURSOR_CLASS="xterm-cursor",t.CURSOR_BLINK_CLASS="xterm-cursor-blink",t.CURSOR_STYLE_BLOCK_CLASS="xterm-cursor-block",t.CURSOR_STYLE_BAR_CLASS="xterm-cursor-bar",t.CURSOR_STYLE_UNDERLINE_CLASS="xterm-cursor-underline";var a=function(){function e(e,t,n){this._document=e,this._optionsService=t,this._colors=n,this._workCell=new o.CellData}return e.prototype.setColors=function(e){this._colors=e},e.prototype.createRow=function(e,n,o,a,l,u,h){for(var d=this._document.createDocumentFragment(),f=0,p=Math.min(e.length,h)-1;p>=0;p--)if(e.loadCell(p,this._workCell).getCode()!==i.NULL_CELL_CODE||n&&p===a){f=p+1;break}for(p=0;p1&&(v.style.width=u*_+"px"),n&&p===a)switch(v.classList.add(t.CURSOR_CLASS),l&&v.classList.add(t.CURSOR_BLINK_CLASS),o){case"bar":v.classList.add(t.CURSOR_STYLE_BAR_CLASS);break;case"underline":v.classList.add(t.CURSOR_STYLE_UNDERLINE_CLASS);break;default:v.classList.add(t.CURSOR_STYLE_BLOCK_CLASS)}this._workCell.isBold()&&v.classList.add(t.BOLD_CLASS),this._workCell.isItalic()&&v.classList.add(t.ITALIC_CLASS),this._workCell.isDim()&&v.classList.add(t.DIM_CLASS),this._workCell.isUnderline()&&v.classList.add(t.UNDERLINE_CLASS),this._workCell.isInvisible()?v.textContent=i.WHITESPACE_CELL_CHAR:v.textContent=this._workCell.getChars()||i.WHITESPACE_CELL_CHAR;var b=this._workCell.getFgColor(),g=this._workCell.getFgColorMode(),m=this._workCell.getBgColor(),y=this._workCell.getBgColorMode(),w=!!this._workCell.isInverse();if(w){var S=b;b=m,m=S;var C=g;g=y,y=C}switch(g){case 16777216:case 33554432:this._workCell.isBold()&&b<8&&this._optionsService.options.drawBoldTextInBrightColors&&(b+=8),this._applyMinimumContrast(v,this._colors.background,this._colors.ansi[b])||v.classList.add("xterm-fg-"+b);break;case 50331648:var k=s.rgba.toColor(b>>16&255,b>>8&255,255&b);this._applyMinimumContrast(v,this._colors.background,k)||this._addStyle(v,"color:#"+c(b.toString(16),"0",6));break;case 0:default:this._applyMinimumContrast(v,this._colors.background,this._colors.foreground)||w&&v.classList.add("xterm-fg-"+r.INVERTED_DEFAULT_COLOR)}switch(y){case 16777216:case 33554432:v.classList.add("xterm-bg-"+m);break;case 50331648:this._addStyle(v,"background-color:#"+c(m.toString(16),"0",6));break;case 0:default:w&&v.classList.add("xterm-bg-"+r.INVERTED_DEFAULT_COLOR)}d.appendChild(v)}}return d},e.prototype._applyMinimumContrast=function(e,t,n){if(1===this._optionsService.options.minimumContrastRatio)return!1;var r=this._colors.contrastCache.getColor(this._workCell.bg,this._workCell.fg);return void 0===r&&(r=s.color.ensureContrastRatio(t,n,this._optionsService.options.minimumContrastRatio),this._colors.contrastCache.setColor(this._workCell.bg,this._workCell.fg,null!=r?r:null)),!!r&&(this._addStyle(e,"color:"+r.css),!0)},e.prototype._addStyle=function(e,t){e.setAttribute("style",""+(e.getAttribute("style")||"")+t+";")},e}();function c(e,t,n){for(;e.length"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};t.evaluateKeyboardEvent=function(e,t,n,o){var s={type:0,cancel:!1,key:void 0},a=(e.shiftKey?1:0)|(e.altKey?2:0)|(e.ctrlKey?4:0)|(e.metaKey?8:0);switch(e.keyCode){case 0:"UIKeyInputUpArrow"===e.key?s.key=t?r.C0.ESC+"OA":r.C0.ESC+"[A":"UIKeyInputLeftArrow"===e.key?s.key=t?r.C0.ESC+"OD":r.C0.ESC+"[D":"UIKeyInputRightArrow"===e.key?s.key=t?r.C0.ESC+"OC":r.C0.ESC+"[C":"UIKeyInputDownArrow"===e.key&&(s.key=t?r.C0.ESC+"OB":r.C0.ESC+"[B");break;case 8:if(e.shiftKey){s.key=r.C0.BS;break}if(e.altKey){s.key=r.C0.ESC+r.C0.DEL;break}s.key=r.C0.DEL;break;case 9:if(e.shiftKey){s.key=r.C0.ESC+"[Z";break}s.key=r.C0.HT,s.cancel=!0;break;case 13:s.key=e.altKey?r.C0.ESC+r.C0.CR:r.C0.CR,s.cancel=!0;break;case 27:s.key=r.C0.ESC,e.altKey&&(s.key=r.C0.ESC+r.C0.ESC),s.cancel=!0;break;case 37:if(e.metaKey)break;a?(s.key=r.C0.ESC+"[1;"+(a+1)+"D",s.key===r.C0.ESC+"[1;3D"&&(s.key=r.C0.ESC+(n?"b":"[1;5D"))):s.key=t?r.C0.ESC+"OD":r.C0.ESC+"[D";break;case 39:if(e.metaKey)break;a?(s.key=r.C0.ESC+"[1;"+(a+1)+"C",s.key===r.C0.ESC+"[1;3C"&&(s.key=r.C0.ESC+(n?"f":"[1;5C"))):s.key=t?r.C0.ESC+"OC":r.C0.ESC+"[C";break;case 38:if(e.metaKey)break;a?(s.key=r.C0.ESC+"[1;"+(a+1)+"A",n||s.key!==r.C0.ESC+"[1;3A"||(s.key=r.C0.ESC+"[1;5A")):s.key=t?r.C0.ESC+"OA":r.C0.ESC+"[A";break;case 40:if(e.metaKey)break;a?(s.key=r.C0.ESC+"[1;"+(a+1)+"B",n||s.key!==r.C0.ESC+"[1;3B"||(s.key=r.C0.ESC+"[1;5B")):s.key=t?r.C0.ESC+"OB":r.C0.ESC+"[B";break;case 45:e.shiftKey||e.ctrlKey||(s.key=r.C0.ESC+"[2~");break;case 46:s.key=a?r.C0.ESC+"[3;"+(a+1)+"~":r.C0.ESC+"[3~";break;case 36:s.key=a?r.C0.ESC+"[1;"+(a+1)+"H":t?r.C0.ESC+"OH":r.C0.ESC+"[H";break;case 35:s.key=a?r.C0.ESC+"[1;"+(a+1)+"F":t?r.C0.ESC+"OF":r.C0.ESC+"[F";break;case 33:e.shiftKey?s.type=2:s.key=r.C0.ESC+"[5~";break;case 34:e.shiftKey?s.type=3:s.key=r.C0.ESC+"[6~";break;case 112:s.key=a?r.C0.ESC+"[1;"+(a+1)+"P":r.C0.ESC+"OP";break;case 113:s.key=a?r.C0.ESC+"[1;"+(a+1)+"Q":r.C0.ESC+"OQ";break;case 114:s.key=a?r.C0.ESC+"[1;"+(a+1)+"R":r.C0.ESC+"OR";break;case 115:s.key=a?r.C0.ESC+"[1;"+(a+1)+"S":r.C0.ESC+"OS";break;case 116:s.key=a?r.C0.ESC+"[15;"+(a+1)+"~":r.C0.ESC+"[15~";break;case 117:s.key=a?r.C0.ESC+"[17;"+(a+1)+"~":r.C0.ESC+"[17~";break;case 118:s.key=a?r.C0.ESC+"[18;"+(a+1)+"~":r.C0.ESC+"[18~";break;case 119:s.key=a?r.C0.ESC+"[19;"+(a+1)+"~":r.C0.ESC+"[19~";break;case 120:s.key=a?r.C0.ESC+"[20;"+(a+1)+"~":r.C0.ESC+"[20~";break;case 121:s.key=a?r.C0.ESC+"[21;"+(a+1)+"~":r.C0.ESC+"[21~";break;case 122:s.key=a?r.C0.ESC+"[23;"+(a+1)+"~":r.C0.ESC+"[23~";break;case 123:s.key=a?r.C0.ESC+"[24;"+(a+1)+"~":r.C0.ESC+"[24~";break;default:if(!e.ctrlKey||e.shiftKey||e.altKey||e.metaKey)if(n&&!o||!e.altKey||e.metaKey)n&&!e.altKey&&!e.ctrlKey&&e.metaKey?65===e.keyCode&&(s.type=1):e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&e.keyCode>=48&&1===e.key.length?s.key=e.key:e.key&&e.ctrlKey&&"_"===e.key&&(s.key=r.C0.US);else{var c=i[e.keyCode],l=c&&c[e.shiftKey?1:0];if(l)s.key=r.C0.ESC+l;else if(e.keyCode>=65&&e.keyCode<=90){var u=e.ctrlKey?e.keyCode-64:e.keyCode+32;s.key=r.C0.ESC+String.fromCharCode(u)}}else e.keyCode>=65&&e.keyCode<=90?s.key=String.fromCharCode(e.keyCode-64):32===e.keyCode?s.key=r.C0.NUL:e.keyCode>=51&&e.keyCode<=55?s.key=String.fromCharCode(e.keyCode-51+27):56===e.keyCode?s.key=r.C0.DEL:219===e.keyCode?s.key=r.C0.ESC:220===e.keyCode?s.key=r.C0.FS:221===e.keyCode&&(s.key=r.C0.GS)}return s}},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.RenderService=void 0;var a=n(31),c=n(0),l=n(2),u=n(32),h=n(7),d=n(1),f=n(5),p=function(e){function t(t,n,r,i,o,s){var l=e.call(this)||this;if(l._renderer=t,l._rowCount=n,l._isPaused=!1,l._needsFullRefresh=!1,l._isNextRenderRedrawOnly=!0,l._needsSelectionRefresh=!1,l._canvasWidth=0,l._canvasHeight=0,l._selectionState={start:void 0,end:void 0,columnSelectMode:!1},l._onDimensionsChange=new c.EventEmitter,l._onRender=new c.EventEmitter,l._onRefreshRequest=new c.EventEmitter,l.register({dispose:function(){return l._renderer.dispose()}}),l._renderDebouncer=new a.RenderDebouncer((function(e,t){return l._renderRows(e,t)})),l.register(l._renderDebouncer),l._screenDprMonitor=new u.ScreenDprMonitor,l._screenDprMonitor.setListener((function(){return l.onDevicePixelRatioChange()})),l.register(l._screenDprMonitor),l.register(s.onResize((function(e){return l._fullRefresh()}))),l.register(i.onOptionChange((function(){return l._renderer.onOptionsChanged()}))),l.register(o.onCharSizeChange((function(){return l.onCharSizeChanged()}))),l._renderer.onRequestRedraw((function(e){return l.refreshRows(e.start,e.end,!0)})),l.register(h.addDisposableDomListener(window,"resize",(function(){return l.onDevicePixelRatioChange()}))),"IntersectionObserver"in window){var d=new IntersectionObserver((function(e){return l._onIntersectionChange(e[e.length-1])}),{threshold:0});d.observe(r),l.register({dispose:function(){return d.disconnect()}})}return l}return i(t,e),Object.defineProperty(t.prototype,"onDimensionsChange",{get:function(){return this._onDimensionsChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRenderedBufferChange",{get:function(){return this._onRender.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onRefreshRequest",{get:function(){return this._onRefreshRequest.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dimensions",{get:function(){return this._renderer.dimensions},enumerable:!1,configurable:!0}),t.prototype._onIntersectionChange=function(e){this._isPaused=0===e.intersectionRatio,!this._isPaused&&this._needsFullRefresh&&(this.refreshRows(0,this._rowCount-1),this._needsFullRefresh=!1)},t.prototype.refreshRows=function(e,t,n){void 0===n&&(n=!1),this._isPaused?this._needsFullRefresh=!0:(n||(this._isNextRenderRedrawOnly=!1),this._renderDebouncer.refresh(e,t,this._rowCount))},t.prototype._renderRows=function(e,t){this._renderer.renderRows(e,t),this._needsSelectionRefresh&&(this._renderer.onSelectionChanged(this._selectionState.start,this._selectionState.end,this._selectionState.columnSelectMode),this._needsSelectionRefresh=!1),this._isNextRenderRedrawOnly||this._onRender.fire({start:e,end:t}),this._isNextRenderRedrawOnly=!0},t.prototype.resize=function(e,t){this._rowCount=t,this._fireOnCanvasResize()},t.prototype.changeOptions=function(){this._renderer.onOptionsChanged(),this.refreshRows(0,this._rowCount-1),this._fireOnCanvasResize()},t.prototype._fireOnCanvasResize=function(){this._renderer.dimensions.canvasWidth===this._canvasWidth&&this._renderer.dimensions.canvasHeight===this._canvasHeight||this._onDimensionsChange.fire(this._renderer.dimensions)},t.prototype.dispose=function(){e.prototype.dispose.call(this)},t.prototype.setRenderer=function(e){var t=this;this._renderer.dispose(),this._renderer=e,this._renderer.onRequestRedraw((function(e){return t.refreshRows(e.start,e.end,!0)})),this._needsSelectionRefresh=!0,this._fullRefresh()},t.prototype._fullRefresh=function(){this._isPaused?this._needsFullRefresh=!0:this.refreshRows(0,this._rowCount-1)},t.prototype.setColors=function(e){this._renderer.setColors(e),this._fullRefresh()},t.prototype.onDevicePixelRatioChange=function(){this._renderer.onDevicePixelRatioChange(),this.refreshRows(0,this._rowCount-1)},t.prototype.onResize=function(e,t){this._renderer.onResize(e,t),this._fullRefresh()},t.prototype.onCharSizeChanged=function(){this._renderer.onCharSizeChanged()},t.prototype.onBlur=function(){this._renderer.onBlur()},t.prototype.onFocus=function(){this._renderer.onFocus()},t.prototype.onSelectionChanged=function(e,t,n){this._selectionState.start=e,this._selectionState.end=t,this._selectionState.columnSelectMode=n,this._renderer.onSelectionChanged(e,t,n)},t.prototype.onCursorMove=function(){this._renderer.onCursorMove()},t.prototype.clear=function(){this._renderer.clear()},t.prototype.registerCharacterJoiner=function(e){return this._renderer.registerCharacterJoiner(e)},t.prototype.deregisterCharacterJoiner=function(e){return this._renderer.deregisterCharacterJoiner(e)},o([s(3,d.IOptionsService),s(4,f.ICharSizeService),s(5,d.IBufferService)],t)}(l.Disposable);t.RenderService=p},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CharSizeService=void 0;var o=n(1),s=n(0),a=function(){function e(e,t,n){this._optionsService=n,this.width=0,this.height=0,this._onCharSizeChange=new s.EventEmitter,this._measureStrategy=new c(e,t,this._optionsService)}return Object.defineProperty(e.prototype,"hasValidSize",{get:function(){return this.width>0&&this.height>0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onCharSizeChange",{get:function(){return this._onCharSizeChange.event},enumerable:!1,configurable:!0}),e.prototype.measure=function(){var e=this._measureStrategy.measure();e.width===this.width&&e.height===this.height||(this.width=e.width,this.height=e.height,this._onCharSizeChange.fire())},r([i(2,o.IOptionsService)],e)}();t.CharSizeService=a;var c=function(){function e(e,t,n){this._document=e,this._parentElement=t,this._optionsService=n,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 e.prototype.measure=function(){this._measureElement.style.fontFamily=this._optionsService.options.fontFamily,this._measureElement.style.fontSize=this._optionsService.options.fontSize+"px";var e=this._measureElement.getBoundingClientRect();return 0!==e.width&&0!==e.height&&(this._result.width=e.width,this._result.height=Math.ceil(e.height)),this._result},e}()},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.MouseService=void 0;var o=n(5),s=n(30),a=function(){function e(e,t){this._renderService=e,this._charSizeService=t}return e.prototype.getCoords=function(e,t,n,r,i){return s.getCoords(e,t,n,r,this._charSizeService.hasValidSize,this._renderService.dimensions.actualCellWidth,this._renderService.dimensions.actualCellHeight,i)},e.prototype.getRawByteCoords=function(e,t,n,r){var i=this.getCoords(e,t,n,r);return s.getRawByteCoords(i)},r([i(0,o.IRenderService),i(1,o.ICharSizeService)],e)}();t.MouseService=a},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Linkifier2=void 0;var a=n(1),c=n(0),l=n(2),u=n(7),h=function(e){function t(t){var n=e.call(this)||this;return n._bufferService=t,n._linkProviders=[],n._linkCacheDisposables=[],n._isMouseOut=!0,n._activeLine=-1,n._onShowLinkUnderline=n.register(new c.EventEmitter),n._onHideLinkUnderline=n.register(new c.EventEmitter),n.register(l.getDisposeArrayDisposable(n._linkCacheDisposables)),n}return i(t,e),Object.defineProperty(t.prototype,"onShowLinkUnderline",{get:function(){return this._onShowLinkUnderline.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onHideLinkUnderline",{get:function(){return this._onHideLinkUnderline.event},enumerable:!1,configurable:!0}),t.prototype.registerLinkProvider=function(e){var t=this;return this._linkProviders.push(e),{dispose:function(){var n=t._linkProviders.indexOf(e);-1!==n&&t._linkProviders.splice(n,1)}}},t.prototype.attachToDom=function(e,t,n){var r=this;this._element=e,this._mouseService=t,this._renderService=n,this.register(u.addDisposableDomListener(this._element,"mouseleave",(function(){r._isMouseOut=!0,r._clearCurrentLink()}))),this.register(u.addDisposableDomListener(this._element,"mousemove",this._onMouseMove.bind(this))),this.register(u.addDisposableDomListener(this._element,"click",this._onClick.bind(this)))},t.prototype._onMouseMove=function(e){if(this._lastMouseEvent=e,this._element&&this._mouseService){var t=this._positionFromMouseEvent(e,this._element,this._mouseService);if(t){this._isMouseOut=!1;for(var n=e.composedPath(),r=0;re?this._bufferService.cols:s.link.range.end.x,l=a;l<=c;l++){if(n.has(l)){i.splice(o--,1);break}n.add(l)}}},t.prototype._checkLinkProviderResult=function(e,t,n){var r,i=this;if(!this._activeProviderReplies)return n;for(var o=this._activeProviderReplies.get(e),s=!1,a=0;a=e&&this._currentLink.link.range.end.y<=t)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,l.disposeArray(this._linkCacheDisposables))},t.prototype._handleNewLink=function(e){var t=this;if(this._element&&this._lastMouseEvent&&this._mouseService){var n=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);n&&this._linkAtPosition(e.link,n)&&(this._currentLink=e,this._currentLink.state={decorations:{underline:void 0===e.link.decorations||e.link.decorations.underline,pointerCursor:void 0===e.link.decorations||e.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,e.link,this._lastMouseEvent),e.link.decorations={},Object.defineProperties(e.link.decorations,{pointerCursor:{get:function(){var e,n;return null===(n=null===(e=t._currentLink)||void 0===e?void 0:e.state)||void 0===n?void 0:n.decorations.pointerCursor},set:function(e){var n,r;(null===(n=t._currentLink)||void 0===n?void 0:n.state)&&t._currentLink.state.decorations.pointerCursor!==e&&(t._currentLink.state.decorations.pointerCursor=e,t._currentLink.state.isHovered&&(null===(r=t._element)||void 0===r||r.classList.toggle("xterm-cursor-pointer",e)))}},underline:{get:function(){var e,n;return null===(n=null===(e=t._currentLink)||void 0===e?void 0:e.state)||void 0===n?void 0:n.decorations.underline},set:function(n){var r,i,o;(null===(r=t._currentLink)||void 0===r?void 0:r.state)&&(null===(o=null===(i=t._currentLink)||void 0===i?void 0:i.state)||void 0===o?void 0:o.decorations.underline)!==n&&(t._currentLink.state.decorations.underline=n,t._currentLink.state.isHovered&&t._fireUnderlineEvent(e.link,n))}}}),this._renderService&&this._linkCacheDisposables.push(this._renderService.onRenderedBufferChange((function(e){var n=0===e.start?0:e.start+1+t._bufferService.buffer.ydisp;t._clearCurrentLink(n,e.end+1+t._bufferService.buffer.ydisp)}))))}},t.prototype._linkHover=function(e,t,n){var r;(null===(r=this._currentLink)||void 0===r?void 0:r.state)&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!0),this._currentLink.state.decorations.pointerCursor&&e.classList.add("xterm-cursor-pointer")),t.hover&&t.hover(n,t.text)},t.prototype._fireUnderlineEvent=function(e,t){var n=e.range,r=this._bufferService.buffer.ydisp,i=this._createLinkUnderlineEvent(n.start.x-1,n.start.y-r-1,n.end.x,n.end.y-r-1,void 0);(t?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(i)},t.prototype._linkLeave=function(e,t,n){var r;(null===(r=this._currentLink)||void 0===r?void 0:r.state)&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!1),this._currentLink.state.decorations.pointerCursor&&e.classList.remove("xterm-cursor-pointer")),t.leave&&t.leave(n,t.text)},t.prototype._linkAtPosition=function(e,t){var n=e.range.start.y===e.range.end.y,r=e.range.start.yt.y;return(n&&e.range.start.x<=t.x&&e.range.end.x>=t.x||r&&e.range.end.x>=t.x||i&&e.range.start.x<=t.x||r&&i)&&e.range.start.y<=t.y&&e.range.end.y>=t.y},t.prototype._positionFromMouseEvent=function(e,t,n){var r=n.getCoords(e,t,this._bufferService.cols,this._bufferService.rows);if(r)return{x:r[0],y:r[1]+this._bufferService.buffer.ydisp}},t.prototype._createLinkUnderlineEvent=function(e,t,n,r,i){return{x1:e,y1:t,x2:n,y2:r,cols:this._bufferService.cols,fg:i}},o([s(0,a.IBufferService)],t)}(l.Disposable);t.Linkifier2=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CoreBrowserService=void 0;var r=function(){function e(e){this._textarea=e}return Object.defineProperty(e.prototype,"isFocused",{get:function(){return document.activeElement===this._textarea&&document.hasFocus()},enumerable:!1,configurable:!0}),e}();t.CoreBrowserService=r},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.CoreTerminal=void 0;var o=n(2),s=n(1),a=n(66),c=n(67),l=n(68),u=n(74),h=n(75),d=n(0),f=n(76),p=n(77),_=n(78),v=n(80),b=n(81),g=n(19),m=n(82),y=function(e){function t(t){var n=e.call(this)||this;return n._onBinary=new d.EventEmitter,n._onData=new d.EventEmitter,n._onLineFeed=new d.EventEmitter,n._onResize=new d.EventEmitter,n._onScroll=new d.EventEmitter,n._instantiationService=new a.InstantiationService,n.optionsService=new u.OptionsService(t),n._instantiationService.setService(s.IOptionsService,n.optionsService),n._bufferService=n.register(n._instantiationService.createInstance(l.BufferService)),n._instantiationService.setService(s.IBufferService,n._bufferService),n._logService=n._instantiationService.createInstance(c.LogService),n._instantiationService.setService(s.ILogService,n._logService),n._coreService=n.register(n._instantiationService.createInstance(h.CoreService,(function(){return n.scrollToBottom()}))),n._instantiationService.setService(s.ICoreService,n._coreService),n._coreMouseService=n._instantiationService.createInstance(f.CoreMouseService),n._instantiationService.setService(s.ICoreMouseService,n._coreMouseService),n._dirtyRowService=n._instantiationService.createInstance(p.DirtyRowService),n._instantiationService.setService(s.IDirtyRowService,n._dirtyRowService),n.unicodeService=n._instantiationService.createInstance(_.UnicodeService),n._instantiationService.setService(s.IUnicodeService,n.unicodeService),n._charsetService=n._instantiationService.createInstance(v.CharsetService),n._instantiationService.setService(s.ICharsetService,n._charsetService),n._inputHandler=new g.InputHandler(n._bufferService,n._charsetService,n._coreService,n._dirtyRowService,n._logService,n.optionsService,n._coreMouseService,n.unicodeService),n.register(d.forwardEvent(n._inputHandler.onLineFeed,n._onLineFeed)),n.register(n._inputHandler),n.register(d.forwardEvent(n._bufferService.onResize,n._onResize)),n.register(d.forwardEvent(n._coreService.onData,n._onData)),n.register(d.forwardEvent(n._coreService.onBinary,n._onBinary)),n.register(n.optionsService.onOptionChange((function(e){return n._updateOptions(e)}))),n._writeBuffer=new m.WriteBuffer((function(e){return n._inputHandler.parse(e)})),n}return i(t,e),Object.defineProperty(t.prototype,"onBinary",{get:function(){return this._onBinary.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onData",{get:function(){return this._onData.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onLineFeed",{get:function(){return this._onLineFeed.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onResize",{get:function(){return this._onResize.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onScroll",{get:function(){return this._onScroll.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cols",{get:function(){return this._bufferService.cols},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rows",{get:function(){return this._bufferService.rows},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"buffers",{get:function(){return this._bufferService.buffers},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){var t;this._isDisposed||(e.prototype.dispose.call(this),null===(t=this._windowsMode)||void 0===t||t.dispose(),this._windowsMode=void 0)},t.prototype.write=function(e,t){this._writeBuffer.write(e,t)},t.prototype.writeSync=function(e){this._writeBuffer.writeSync(e)},t.prototype.resize=function(e,t){isNaN(e)||isNaN(t)||(e=Math.max(e,l.MINIMUM_COLS),t=Math.max(t,l.MINIMUM_ROWS),this._bufferService.resize(e,t))},t.prototype.scroll=function(e,t){void 0===t&&(t=!1);var n,r=this._bufferService.buffer;(n=this._cachedBlankLine)&&n.length===this.cols&&n.getFg(0)===e.fg&&n.getBg(0)===e.bg||(n=r.getBlankLine(e,t),this._cachedBlankLine=n),n.isWrapped=t;var i=r.ybase+r.scrollTop,o=r.ybase+r.scrollBottom;if(0===r.scrollTop){var s=r.lines.isFull;o===r.lines.length-1?s?r.lines.recycle().copyFrom(n):r.lines.push(n.clone()):r.lines.splice(o+1,0,n.clone()),s?this._bufferService.isUserScrolling&&(r.ydisp=Math.max(r.ydisp-1,0)):(r.ybase++,this._bufferService.isUserScrolling||r.ydisp++)}else{var a=o-i+1;r.lines.shiftElements(i+1,a-1,-1),r.lines.set(o,n.clone())}this._bufferService.isUserScrolling||(r.ydisp=r.ybase),this._dirtyRowService.markRangeDirty(r.scrollTop,r.scrollBottom),this._onScroll.fire(r.ydisp)},t.prototype.scrollLines=function(e,t){var n=this._bufferService.buffer;if(e<0){if(0===n.ydisp)return;this._bufferService.isUserScrolling=!0}else e+n.ydisp>=n.ybase&&(this._bufferService.isUserScrolling=!1);var r=n.ydisp;n.ydisp=Math.max(Math.min(n.ydisp+e,n.ybase),0),r!==n.ydisp&&(t||this._onScroll.fire(n.ydisp))},t.prototype.scrollPages=function(e){this.scrollLines(e*(this.rows-1))},t.prototype.scrollToTop=function(){this.scrollLines(-this._bufferService.buffer.ydisp)},t.prototype.scrollToBottom=function(){this.scrollLines(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp)},t.prototype.scrollToLine=function(e){var t=e-this._bufferService.buffer.ydisp;0!==t&&this.scrollLines(t)},t.prototype.addEscHandler=function(e,t){return this._inputHandler.addEscHandler(e,t)},t.prototype.addDcsHandler=function(e,t){return this._inputHandler.addDcsHandler(e,t)},t.prototype.addCsiHandler=function(e,t){return this._inputHandler.addCsiHandler(e,t)},t.prototype.addOscHandler=function(e,t){return this._inputHandler.addOscHandler(e,t)},t.prototype._setup=function(){this.optionsService.options.windowsMode&&this._enableWindowsMode()},t.prototype.reset=function(){this._inputHandler.reset(),this._bufferService.reset(),this._charsetService.reset(),this._coreService.reset(),this._coreMouseService.reset()},t.prototype._updateOptions=function(e){var t;switch(e){case"scrollback":this.buffers.resize(this.cols,this.rows);break;case"windowsMode":this.optionsService.options.windowsMode?this._enableWindowsMode():(null===(t=this._windowsMode)||void 0===t||t.dispose(),this._windowsMode=void 0)}},t.prototype._enableWindowsMode=function(){var e=this;if(!this._windowsMode){var t=[];t.push(this.onLineFeed(b.updateWindowsModeWrappedState.bind(null,this._bufferService))),t.push(this.addCsiHandler({final:"H"},(function(){return b.updateWindowsModeWrappedState(e._bufferService),!1}))),this._windowsMode={dispose:function(){for(var e=0,n=t;e0?i[0].index:t.length;if(t.length!==h)throw new Error("[createInstance] First service dependency of "+e.name+" at position "+(h+1)+" conflicts with "+t.length+" static arguments");return new(e.bind.apply(e,r([void 0],r(t,s))))},e}();t.InstantiationService=a},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}},o=this&&this.__spreadArrays||function(){for(var e=0,t=0,n=arguments.length;t=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.BufferService=t.MINIMUM_ROWS=t.MINIMUM_COLS=void 0;var a=n(1),c=n(69),l=n(0),u=n(2);t.MINIMUM_COLS=2,t.MINIMUM_ROWS=1;var h=function(e){function n(n){var r=e.call(this)||this;return r._optionsService=n,r.isUserScrolling=!1,r._onResize=new l.EventEmitter,r.cols=Math.max(n.options.cols,t.MINIMUM_COLS),r.rows=Math.max(n.options.rows,t.MINIMUM_ROWS),r.buffers=new c.BufferSet(n,r),r}return i(n,e),Object.defineProperty(n.prototype,"onResize",{get:function(){return this._onResize.event},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"buffer",{get:function(){return this.buffers.active},enumerable:!1,configurable:!0}),n.prototype.dispose=function(){e.prototype.dispose.call(this),this.buffers.dispose()},n.prototype.resize=function(e,t){this.cols=e,this.rows=t,this.buffers.resize(e,t),this.buffers.setupTabStops(this.cols),this._onResize.fire({cols:e,rows:t})},n.prototype.reset=function(){this.buffers.dispose(),this.buffers=new c.BufferSet(this._optionsService,this),this.isUserScrolling=!1},o([s(0,a.IOptionsService)],n)}(u.Disposable);t.BufferService=h},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.BufferSet=void 0;var o=n(70),s=n(0),a=function(e){function t(t,n){var r=e.call(this)||this;return r._onBufferActivate=r.register(new s.EventEmitter),r._normal=new o.Buffer(!0,t,n),r._normal.fillViewportRows(),r._alt=new o.Buffer(!1,t,n),r._activeBuffer=r._normal,r.setupTabStops(),r}return i(t,e),Object.defineProperty(t.prototype,"onBufferActivate",{get:function(){return this._onBufferActivate.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"alt",{get:function(){return this._alt},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"active",{get:function(){return this._activeBuffer},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"normal",{get:function(){return this._normal},enumerable:!1,configurable:!0}),t.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}))},t.prototype.activateAltBuffer=function(e){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(e),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}))},t.prototype.resize=function(e,t){this._normal.resize(e,t),this._alt.resize(e,t)},t.prototype.setupTabStops=function(e){this._normal.setupTabStops(e),this._alt.setupTabStops(e)},t}(n(2).Disposable);t.BufferSet=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BufferStringIterator=t.Buffer=t.MAX_BUFFER_SIZE=void 0;var r=n(71),i=n(16),o=n(4),s=n(3),a=n(72),c=n(73),l=n(20),u=n(6);t.MAX_BUFFER_SIZE=4294967295;var h=function(){function e(e,t,n){this._hasScrollback=e,this._optionsService=t,this._bufferService=n,this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.savedY=0,this.savedX=0,this.savedCurAttrData=i.DEFAULT_ATTR_DATA.clone(),this.savedCharset=l.DEFAULT_CHARSET,this.markers=[],this._nullCell=o.CellData.fromCharData([0,s.NULL_CELL_CHAR,s.NULL_CELL_WIDTH,s.NULL_CELL_CODE]),this._whitespaceCell=o.CellData.fromCharData([0,s.WHITESPACE_CELL_CHAR,s.WHITESPACE_CELL_WIDTH,s.WHITESPACE_CELL_CODE]),this._cols=this._bufferService.cols,this._rows=this._bufferService.rows,this.lines=new r.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}return e.prototype.getNullCell=function(e){return e?(this._nullCell.fg=e.fg,this._nullCell.bg=e.bg,this._nullCell.extended=e.extended):(this._nullCell.fg=0,this._nullCell.bg=0,this._nullCell.extended=new u.ExtendedAttrs),this._nullCell},e.prototype.getWhitespaceCell=function(e){return e?(this._whitespaceCell.fg=e.fg,this._whitespaceCell.bg=e.bg,this._whitespaceCell.extended=e.extended):(this._whitespaceCell.fg=0,this._whitespaceCell.bg=0,this._whitespaceCell.extended=new u.ExtendedAttrs),this._whitespaceCell},e.prototype.getBlankLine=function(e,t){return new i.BufferLine(this._bufferService.cols,this.getNullCell(e),t)},Object.defineProperty(e.prototype,"hasScrollback",{get:function(){return this._hasScrollback&&this.lines.maxLength>this._rows},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isCursorInViewport",{get:function(){var e=this.ybase+this.y-this.ydisp;return e>=0&&et.MAX_BUFFER_SIZE?t.MAX_BUFFER_SIZE:n},e.prototype.fillViewportRows=function(e){if(0===this.lines.length){void 0===e&&(e=i.DEFAULT_ATTR_DATA);for(var t=this._rows;t--;)this.lines.push(this.getBlankLine(e))}},e.prototype.clear=function(){this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.lines=new r.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()},e.prototype.resize=function(e,t){var n=this.getNullCell(i.DEFAULT_ATTR_DATA),r=this._getCorrectBufferLength(t);if(r>this.lines.maxLength&&(this.lines.maxLength=r),this.lines.length>0){if(this._cols0&&this.lines.length<=this.ybase+this.y+s+1?(this.ybase--,s++,this.ydisp>0&&this.ydisp--):this.lines.push(new i.BufferLine(e,n)));else for(a=this._rows;a>t;a--)this.lines.length>t+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));if(r0&&(this.lines.trimStart(c),this.ybase=Math.max(this.ybase-c,0),this.ydisp=Math.max(this.ydisp-c,0),this.savedY=Math.max(this.savedY-c,0)),this.lines.maxLength=r}this.x=Math.min(this.x,e-1),this.y=Math.min(this.y,t-1),s&&(this.y+=s),this.savedX=Math.min(this.savedX,e-1),this.scrollTop=0}if(this.scrollBottom=t-1,this._isReflowEnabled&&(this._reflow(e,t),this._cols>e))for(o=0;othis._cols?this._reflowLarger(e,t):this._reflowSmaller(e,t))},e.prototype._reflowLarger=function(e,t){var n=a.reflowLargerGetLinesToRemove(this.lines,this._cols,e,this.ybase+this.y,this.getNullCell(i.DEFAULT_ATTR_DATA));if(n.length>0){var r=a.reflowLargerCreateNewLayout(this.lines,n);a.reflowLargerApplyNewLayout(this.lines,r.layout),this._reflowLargerAdjustViewport(e,t,r.countRemoved)}},e.prototype._reflowLargerAdjustViewport=function(e,t,n){for(var r=this.getNullCell(i.DEFAULT_ATTR_DATA),o=n;o-- >0;)0===this.ybase?(this.y>0&&this.y--,this.lines.length=0;s--){var c=this.lines.get(s);if(!(!c||!c.isWrapped&&c.getTrimmedLength()<=e)){for(var l=[c];c.isWrapped&&s>0;)c=this.lines.get(--s),l.unshift(c);var u=this.ybase+this.y;if(!(u>=s&&u0&&(r.push({start:s+l.length+o,newLines:_}),o+=_.length),l.push.apply(l,_);var g=f.length-1,m=f[g];0===m&&(m=f[--g]);for(var y=l.length-p-1,w=d;y>=0;){var S=Math.min(w,m);if(l[g].copyCellsFrom(l[y],w-S,m-S,S,!0),0==(m-=S)&&(m=f[--g]),0==(w-=S)){y--;var C=Math.max(y,0);w=a.getWrappedLineTrimmedLength(l,C,this._cols)}}for(v=0;v0;)0===this.ybase?this.y0){var E=[],O=[];for(v=0;v=0;v--)if(L&&L.start>A+R){for(var M=L.newLines.length-1;M>=0;M--)this.lines.set(v--,L.newLines[M]);v++,E.push({index:A+1,amount:L.newLines.length}),R+=L.newLines.length,L=r[++j]}else this.lines.set(v,O[A--]);var T=0;for(v=E.length-1;v>=0;v--)E[v].index+=T,this.lines.onInsertEmitter.fire(E[v]),T+=E[v].amount;var D=Math.max(0,x+o-this.lines.maxLength);D>0&&this.lines.onTrimEmitter.fire(D)}},e.prototype.stringIndexToBufferIndex=function(e,t,n){for(void 0===n&&(n=!1);t;){var r=this.lines.get(e);if(!r)return[-1,-1];for(var i=n?r.getTrimmedLength():r.length,o=0;o0&&this.lines.get(t).isWrapped;)t--;for(;n+10;);return e>=this._cols?this._cols-1:e<0?0:e},e.prototype.nextStop=function(e){for(null==e&&(e=this.x);!this.tabs[++e]&&e=this._cols?this._cols-1:e<0?0:e},e.prototype.addMarker=function(e){var t=this,n=new c.Marker(e);return this.markers.push(n),n.register(this.lines.onTrim((function(e){n.line-=e,n.line<0&&n.dispose()}))),n.register(this.lines.onInsert((function(e){n.line>=e.index&&(n.line+=e.amount)}))),n.register(this.lines.onDelete((function(e){n.line>=e.index&&n.linee.index&&(n.line-=e.amount)}))),n.register(n.onDispose((function(){return t._removeMarker(n)}))),n},e.prototype._removeMarker=function(e){this.markers.splice(this.markers.indexOf(e),1)},e.prototype.iterator=function(e,t,n,r,i){return new d(this,e,t,n,r,i)},e}();t.Buffer=h;var d=function(){function e(e,t,n,r,i,o){void 0===n&&(n=0),void 0===r&&(r=e.lines.length),void 0===i&&(i=0),void 0===o&&(o=0),this._buffer=e,this._trimRight=t,this._startIndex=n,this._endIndex=r,this._startOverscan=i,this._endOverscan=o,this._startIndex<0&&(this._startIndex=0),this._endIndex>this._buffer.lines.length&&(this._endIndex=this._buffer.lines.length),this._current=this._startIndex}return e.prototype.hasNext=function(){return this._currentthis._endIndex+this._endOverscan&&(e.last=this._endIndex+this._endOverscan),e.first=Math.max(e.first,0),e.last=Math.min(e.last,this._buffer.lines.length);for(var t="",n=e.first;n<=e.last;++n)t+=this._buffer.translateBufferLineToString(n,this._trimRight);return this._current=e.last+1,{range:e,content:t}},e}();t.BufferStringIterator=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CircularList=void 0;var r=n(0),i=function(){function e(e){this._maxLength=e,this.onDeleteEmitter=new r.EventEmitter,this.onInsertEmitter=new r.EventEmitter,this.onTrimEmitter=new r.EventEmitter,this._array=new Array(this._maxLength),this._startIndex=0,this._length=0}return Object.defineProperty(e.prototype,"onDelete",{get:function(){return this.onDeleteEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onInsert",{get:function(){return this.onInsertEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"onTrim",{get:function(){return this.onTrimEmitter.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxLength",{get:function(){return this._maxLength},set:function(e){if(this._maxLength!==e){for(var t=new Array(e),n=0;nthis._length)for(var t=this._length;t=e;i--)this._array[this._getCyclicIndex(i+n.length)]=this._array[this._getCyclicIndex(i)];for(i=0;ithis._maxLength){var o=this._length+n.length-this._maxLength;this._startIndex+=o,this._length=this._maxLength,this.onTrimEmitter.fire(o)}else this._length+=n.length},e.prototype.trimStart=function(e){e>this._length&&(e=this._length),this._startIndex+=e,this._length-=e,this.onTrimEmitter.fire(e)},e.prototype.shiftElements=function(e,t,n){if(!(t<=0)){if(e<0||e>=this._length)throw new Error("start argument out of range");if(e+n<0)throw new Error("Cannot shift elements in list beyond index 0");if(n>0){for(var r=t-1;r>=0;r--)this.set(e+r+n,this.get(e+r));var i=e+t+n-this._length;if(i>0)for(this._length+=i;this._length>this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(r=0;r=a&&i0&&(y>h||0===u[y].getTrimmedLength());y--)m++;m>0&&(s.push(a+u.length-m),s.push(m)),a+=u.length-1}}}return s},t.reflowLargerCreateNewLayout=function(e,t){for(var n=[],r=0,i=t[r],o=0,s=0;sl&&(s-=l,a++);var u=2===e[a].getWidth(s-1);u&&s--;var h=u?n-1:n;i.push(h),c+=h}return i},t.getWrappedLineTrimmedLength=r},function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.Marker=void 0;var o=n(0),s=function(e){function t(n){var r=e.call(this)||this;return r.line=n,r._id=t._nextId++,r.isDisposed=!1,r._onDispose=new o.EventEmitter,r}return i(t,e),Object.defineProperty(t.prototype,"id",{get:function(){return this._id},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onDispose",{get:function(){return this._onDispose.event},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){this.isDisposed||(this.isDisposed=!0,this.line=-1,this._onDispose.fire())},t._nextId=1,t}(n(2).Disposable);t.Marker=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OptionsService=t.DEFAULT_OPTIONS=t.DEFAULT_BELL_SOUND=void 0;var r=n(0),i=n(11),o=n(33);t.DEFAULT_BELL_SOUND="data:audio/mp3;base64,SUQzBAAAAAAAI1RTU0UAAAAPAAADTGF2ZjU4LjMyLjEwNAAAAAAAAAAAAAAA//tQxAADB8AhSmxhIIEVCSiJrDCQBTcu3UrAIwUdkRgQbFAZC1CQEwTJ9mjRvBA4UOLD8nKVOWfh+UlK3z/177OXrfOdKl7pyn3Xf//WreyTRUoAWgBgkOAGbZHBgG1OF6zM82DWbZaUmMBptgQhGjsyYqc9ae9XFz280948NMBWInljyzsNRFLPWdnZGWrddDsjK1unuSrVN9jJsK8KuQtQCtMBjCEtImISdNKJOopIpBFpNSMbIHCSRpRR5iakjTiyzLhchUUBwCgyKiweBv/7UsQbg8isVNoMPMjAAAA0gAAABEVFGmgqK////9bP/6XCykxBTUUzLjEwMKqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq",t.DEFAULT_OPTIONS=Object.freeze({cols:80,rows:24,cursorBlink:!1,cursorStyle:"block",cursorWidth:1,bellSound:t.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:i.isMac,rendererType:"canvas",windowOptions:{},windowsMode:!1,wordSeparator:" ()[]{}',\"`",convertEol:!1,termName:"xterm",cancelEvents:!1});var s=["cols","rows"],a=function(){function e(e){this._onOptionChange=new r.EventEmitter,this.options=o.clone(t.DEFAULT_OPTIONS);for(var n=0,i=Object.keys(e);n=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},s=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CoreService=void 0;var a=n(1),c=n(0),l=n(33),u=n(2),h=Object.freeze({insertMode:!1}),d=Object.freeze({applicationCursorKeys:!1,applicationKeypad:!1,bracketedPasteMode:!1,origin:!1,reverseWraparound:!1,sendFocus:!1,wraparound:!0}),f=function(e){function t(t,n,r,i){var o=e.call(this)||this;return o._bufferService=n,o._logService=r,o._optionsService=i,o.isCursorInitialized=!1,o.isCursorHidden=!1,o._onData=o.register(new c.EventEmitter),o._onUserInput=o.register(new c.EventEmitter),o._onBinary=o.register(new c.EventEmitter),o._scrollToBottom=t,o.register({dispose:function(){return o._scrollToBottom=void 0}}),o.modes=l.clone(h),o.decPrivateModes=l.clone(d),o}return i(t,e),Object.defineProperty(t.prototype,"onData",{get:function(){return this._onData.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onUserInput",{get:function(){return this._onUserInput.event},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"onBinary",{get:function(){return this._onBinary.event},enumerable:!1,configurable:!0}),t.prototype.reset=function(){this.modes=l.clone(h),this.decPrivateModes=l.clone(d)},t.prototype.triggerDataEvent=function(e,t){if(void 0===t&&(t=!1),!this._optionsService.options.disableStdin){var n=this._bufferService.buffer;n.ybase!==n.ydisp&&this._scrollToBottom(),t&&this._onUserInput.fire(),this._logService.debug('sending data "'+e+'"',(function(){return e.split("").map((function(e){return e.charCodeAt(0)}))})),this._onData.fire(e)}},t.prototype.triggerBinaryEvent=function(e){this._optionsService.options.disableStdin||(this._logService.debug('sending binary "'+e+'"',(function(){return e.split("").map((function(e){return e.charCodeAt(0)}))})),this._onBinary.fire(e))},o([s(1,a.IBufferService),s(2,a.ILogService),s(3,a.IOptionsService)],t)}(u.Disposable);t.CoreService=f},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CoreMouseService=void 0;var o=n(1),s=n(0),a={NONE:{events:0,restrict:function(){return!1}},X10:{events:1,restrict:function(e){return 4!==e.button&&1===e.action&&(e.ctrl=!1,e.alt=!1,e.shift=!1,!0)}},VT200:{events:19,restrict:function(e){return 32!==e.action}},DRAG:{events:23,restrict:function(e){return 32!==e.action||3!==e.button}},ANY:{events:31,restrict:function(e){return!0}}};function c(e,t){var n=(e.ctrl?16:0)|(e.shift?4:0)|(e.alt?8:0);return 4===e.button?(n|=64,n|=e.action):(n|=3&e.button,4&e.button&&(n|=64),8&e.button&&(n|=128),32===e.action?n|=32:0!==e.action||t||(n|=3)),n}var l=String.fromCharCode,u={DEFAULT:function(e){var t=[c(e,!1)+32,e.col+32,e.row+32];return t[0]>255||t[1]>255||t[2]>255?"":""+l(t[0])+l(t[1])+l(t[2])},SGR:function(e){var t=0===e.action&&4!==e.button?"m":"M";return"[<"+c(e,!0)+";"+e.col+";"+e.row+t}},h=function(){function e(e,t){this._bufferService=e,this._coreService=t,this._protocols={},this._encodings={},this._activeProtocol="",this._activeEncoding="",this._onProtocolChange=new s.EventEmitter,this._lastEvent=null;for(var n=0,r=Object.keys(a);n=this._bufferService.cols||e.row<0||e.row>=this._bufferService.rows)return!1;if(4===e.button&&32===e.action)return!1;if(3===e.button&&32!==e.action)return!1;if(4!==e.button&&(2===e.action||3===e.action))return!1;if(e.col++,e.row++,32===e.action&&this._lastEvent&&this._compareEvents(this._lastEvent,e))return!1;if(!this._protocols[this._activeProtocol].restrict(e))return!1;var t=this._encodings[this._activeEncoding](e);return t&&("DEFAULT"===this._activeEncoding?this._coreService.triggerBinaryEvent(t):this._coreService.triggerDataEvent(t,!0)),this._lastEvent=e,!0},e.prototype.explainEvents=function(e){return{down:!!(1&e),up:!!(2&e),drag:!!(4&e),move:!!(8&e),wheel:!!(16&e)}},e.prototype._compareEvents=function(e,t){return e.col===t.col&&e.row===t.row&&e.button===t.button&&e.action===t.action&&e.ctrl===t.ctrl&&e.alt===t.alt&&e.shift===t.shift},r([i(0,o.IBufferService),i(1,o.ICoreService)],e)}();t.CoreMouseService=h},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},i=this&&this.__param||function(e,t){return function(n,r){t(n,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.DirtyRowService=void 0;var o=n(1),s=function(){function e(e){this._bufferService=e,this.clearRange()}return Object.defineProperty(e.prototype,"start",{get:function(){return this._start},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"end",{get:function(){return this._end},enumerable:!1,configurable:!0}),e.prototype.clearRange=function(){this._start=this._bufferService.buffer.y,this._end=this._bufferService.buffer.y},e.prototype.markDirty=function(e){ethis._end&&(this._end=e)},e.prototype.markRangeDirty=function(e,t){if(e>t){var n=e;e=t,t=n}ethis._end&&(this._end=t)},e.prototype.markAllDirty=function(){this.markRangeDirty(0,this._bufferService.rows-1)},r([i(0,o.IBufferService)],e)}();t.DirtyRowService=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeService=void 0;var r=n(0),i=n(79),o=function(){function e(){this._providers=Object.create(null),this._active="",this._onChange=new r.EventEmitter;var e=new i.UnicodeV6;this.register(e),this._active=e.version,this._activeProvider=e}return Object.defineProperty(e.prototype,"onChange",{get:function(){return this._onChange.event},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"versions",{get:function(){return Object.keys(this._providers)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activeVersion",{get:function(){return this._active},set:function(e){if(!this._providers[e])throw new Error('unknown Unicode version "'+e+'"');this._active=e,this._activeProvider=this._providers[e],this._onChange.fire(e)},enumerable:!1,configurable:!0}),e.prototype.register=function(e){this._providers[e.version]=e},e.prototype.wcwidth=function(e){return this._activeProvider.wcwidth(e)},e.prototype.getStringCellWidth=function(e){for(var t=0,n=e.length,r=0;r=n)return t+this.wcwidth(i);var o=e.charCodeAt(r);56320<=o&&o<=57343?i=1024*(i-55296)+o-56320+65536:t+=this.wcwidth(o)}t+=this.wcwidth(i)}return t},e}();t.UnicodeService=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeV6=void 0;var r,i=n(15),o=[[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]],s=[[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]],a=function(){function e(){if(this.version="6",!r){r=new Uint8Array(65536),i.fill(r,1),r[0]=0,i.fill(r,0,1,32),i.fill(r,0,127,160),i.fill(r,2,4352,4448),r[9001]=2,r[9002]=2,i.fill(r,2,11904,42192),r[12351]=1,i.fill(r,2,44032,55204),i.fill(r,2,63744,64256),i.fill(r,2,65040,65050),i.fill(r,2,65072,65136),i.fill(r,2,65280,65377),i.fill(r,2,65504,65511);for(var e=0;et[i][1])return!1;for(;i>=r;)if(e>t[n=r+i>>1][1])r=n+1;else{if(!(e=131072&&e<=196605||e>=196608&&e<=262141?2:1},e}();t.UnicodeV6=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CharsetService=void 0;var r=function(){function e(){this.glevel=0,this._charsets=[]}return e.prototype.reset=function(){this.charset=void 0,this._charsets=[],this.glevel=0},e.prototype.setgLevel=function(e){this.glevel=e,this.charset=this._charsets[e]},e.prototype.setgCharset=function(e,t){this._charsets[e]=t,this.glevel===e&&(this.charset=t)},e}();t.CharsetService=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.updateWindowsModeWrappedState=void 0;var r=n(3);t.updateWindowsModeWrappedState=function(e){var t=e.buffer.lines.get(e.buffer.ybase+e.buffer.y-1),n=null==t?void 0:t.get(e.cols-1),i=e.buffer.lines.get(e.buffer.ybase+e.buffer.y);i&&n&&(i.isWrapped=n[r.CHAR_DATA_CODE_INDEX]!==r.NULL_CELL_CODE&&n[r.CHAR_DATA_CODE_INDEX]!==r.WHITESPACE_CELL_CODE)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WriteBuffer=void 0;var r=function(){function e(e){this._action=e,this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0}return e.prototype.writeSync=function(e){if(this._writeBuffer.length){for(var t=this._bufferOffset;t5e7)throw new Error("write data discarded, use flow control to avoid losing data");this._writeBuffer.length||(this._bufferOffset=0,setTimeout((function(){return n._innerWrite()}))),this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t)},e.prototype._innerWrite=function(){for(var e=this,t=Date.now();this._writeBuffer.length>this._bufferOffset;){var n=this._writeBuffer[this._bufferOffset],r=this._callbacks[this._bufferOffset];if(this._bufferOffset++,this._action(n),this._pendingData-=n.length,r&&r(),Date.now()-t>=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 e._innerWrite()}),0)):(this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0)},e}();t.WriteBuffer=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AddonManager=void 0;var r=function(){function e(){this._addons=[]}return e.prototype.dispose=function(){for(var e=this._addons.length-1;e>=0;e--)this._addons[e].instance.dispose()},e.prototype.loadAddon=function(e,t){var n=this,r={instance:t,dispose:t.dispose,isDisposed:!1};this._addons.push(r),t.dispose=function(){return n._wrappedAddonDispose(r)},t.activate(e)},e.prototype._wrappedAddonDispose=function(e){if(!e.isDisposed){for(var t=-1,n=0;n> RFB.constructor"),r._screen=document.createElement("div"),r._screen.style.display="flex",r._screen.style.width="100%",r._screen.style.height="100%",r._screen.style.overflow="auto",r._screen.style.background="rgb(40, 40, 40)",r._canvas=document.createElement("canvas"),r._canvas.style.margin="auto",r._canvas.style.outline="none",r._canvas.style.flexShrink="0",r._canvas.width=0,r._canvas.height=0,r._canvas.tabIndex=-1,r._screen.appendChild(r._canvas),r._cursor=new _.default,r._cursorImage=x.cursors.none,r._decoders[y.encodings.encodingRaw]=new w.default,r._decoders[y.encodings.encodingCopyRect]=new S.default,r._decoders[y.encodings.encodingRRE]=new C.default,r._decoders[y.encodings.encodingHextile]=new k.default,r._decoders[y.encodings.encodingTight]=new E.default,r._decoders[y.encodings.encodingTightPNG]=new O.default;try{r._display=new u.default(r._canvas)}catch(e){throw i.Error("Display exception: "+e),e}return r._display.onflush=r._onFlush.bind(D(r)),r._keyboard=new f.default(r._canvas),r._keyboard.onkeyevent=r._handleKeyEvent.bind(D(r)),r._gestures=new p.default,r._sock=new v.default,r._sock.on("message",(function(){r._handleMessage()})),r._sock.on("open",(function(){"connecting"===r._rfbConnectionState&&""===r._rfbInitState?(r._rfbInitState="ProtocolVersion",i.Debug("Starting VNC handshake")):r._fail("Unexpected server connection while "+r._rfbConnectionState)})),r._sock.on("close",(function(e){i.Debug("WebSocket on-close event");var t="";switch(e.code&&(t="(code: "+e.code,e.reason&&(t+=", reason: "+e.reason),t+=")"),r._rfbConnectionState){case"connecting":r._fail("Connection closed "+t);break;case"connected":r._updateConnectionState("disconnecting"),r._updateConnectionState("disconnected");break;case"disconnecting":r._updateConnectionState("disconnected");break;case"disconnected":r._fail("Unexpected server disconnect when already disconnected "+t);break;default:r._fail("Unexpected server disconnect before connecting "+t)}r._sock.off("close")})),r._sock.on("error",(function(e){return i.Warn("WebSocket on-error event")})),setTimeout(r._updateConnectionState.bind(D(r),"connecting")),i.Debug("<< RFB.constructor"),r.dragViewport=!1,r.focusOnClick=!0,r._viewOnly=!1,r._clipViewport=!1,r._scaleViewport=!1,r._resizeSession=!1,r._showDotCursor=!1,void 0!==n.showDotCursor&&(i.Warn("Specifying showDotCursor as a RFB constructor argument is deprecated"),r._showDotCursor=n.showDotCursor),r._qualityLevel=6,r._compressionLevel=2,r}return t=x,l=[{key:"genDES",value:function(e,t){var n=e.split("").map((function(e){return e.charCodeAt(0)}));return new b.default(n).encrypt(t)}}],(n=[{key:"disconnect",value:function(){this._updateConnectionState("disconnecting"),this._sock.off("error"),this._sock.off("message"),this._sock.off("open")}},{key:"sendCredentials",value:function(e){this._rfbCredentials=e,setTimeout(this._initMsg.bind(this),0)}},{key:"sendCtrlAltDel",value:function(){"connected"!==this._rfbConnectionState||this._viewOnly||(i.Info("Sending Ctrl-Alt-Del"),this.sendKey(g.default.XK_Control_L,"ControlLeft",!0),this.sendKey(g.default.XK_Alt_L,"AltLeft",!0),this.sendKey(g.default.XK_Delete,"Delete",!0),this.sendKey(g.default.XK_Delete,"Delete",!1),this.sendKey(g.default.XK_Alt_L,"AltLeft",!1),this.sendKey(g.default.XK_Control_L,"ControlLeft",!1))}},{key:"machineShutdown",value:function(){this._xvpOp(1,2)}},{key:"machineReboot",value:function(){this._xvpOp(1,3)}},{key:"machineReset",value:function(){this._xvpOp(1,4)}},{key:"sendKey",value:function(e,t,n){if("connected"===this._rfbConnectionState&&!this._viewOnly){if(void 0===n)return this.sendKey(e,t,!0),void this.sendKey(e,t,!1);var r=m.default[t];if(this._qemuExtKeyEventSupported&&r)e=e||0,i.Info("Sending key ("+(n?"down":"up")+"): keysym "+e+", scancode "+r),x.messages.QEMUExtendedKeyEvent(this._sock,e,n,r);else{if(!e)return;i.Info("Sending keysym ("+(n?"down":"up")+"): "+e),x.messages.keyEvent(this._sock,e,n?1:0)}}}},{key:"focus",value:function(){this._canvas.focus()}},{key:"blur",value:function(){this._canvas.blur()}},{key:"clipboardPasteFrom",value:function(e){if("connected"===this._rfbConnectionState&&!this._viewOnly)if(this._clipboardServerCapabilitiesFormats[1]&&this._clipboardServerCapabilitiesActions[1<<27])this._clipboardText=e,x.messages.extendedClipboardNotify(this._sock,[1]);else{for(var t=new Uint8Array(e.length),n=0;n> RFB.connect"),i.Info("connecting to "+this._url);try{this._sock.open(this._url,this._wsProtocols)}catch(e){"SyntaxError"===e.name?this._fail("Invalid host or port ("+e+")"):this._fail("Error when opening socket ("+e+")")}this._target.appendChild(this._screen),this._gestures.attach(this._canvas),this._cursor.attach(this._canvas),this._refreshCursor(),window.addEventListener("resize",this._eventHandlers.windowResize),this._canvas.addEventListener("mousedown",this._eventHandlers.focusCanvas),this._canvas.addEventListener("touchstart",this._eventHandlers.focusCanvas),this._canvas.addEventListener("mousedown",this._eventHandlers.handleMouse),this._canvas.addEventListener("mouseup",this._eventHandlers.handleMouse),this._canvas.addEventListener("mousemove",this._eventHandlers.handleMouse),this._canvas.addEventListener("click",this._eventHandlers.handleMouse),this._canvas.addEventListener("contextmenu",this._eventHandlers.handleMouse),this._canvas.addEventListener("wheel",this._eventHandlers.handleWheel),this._canvas.addEventListener("gesturestart",this._eventHandlers.handleGesture),this._canvas.addEventListener("gesturemove",this._eventHandlers.handleGesture),this._canvas.addEventListener("gestureend",this._eventHandlers.handleGesture),i.Debug("<< RFB.connect")}},{key:"_disconnect",value:function(){i.Debug(">> RFB.disconnect"),this._cursor.detach(),this._canvas.removeEventListener("gesturestart",this._eventHandlers.handleGesture),this._canvas.removeEventListener("gesturemove",this._eventHandlers.handleGesture),this._canvas.removeEventListener("gestureend",this._eventHandlers.handleGesture),this._canvas.removeEventListener("wheel",this._eventHandlers.handleWheel),this._canvas.removeEventListener("mousedown",this._eventHandlers.handleMouse),this._canvas.removeEventListener("mouseup",this._eventHandlers.handleMouse),this._canvas.removeEventListener("mousemove",this._eventHandlers.handleMouse),this._canvas.removeEventListener("click",this._eventHandlers.handleMouse),this._canvas.removeEventListener("contextmenu",this._eventHandlers.handleMouse),this._canvas.removeEventListener("mousedown",this._eventHandlers.focusCanvas),this._canvas.removeEventListener("touchstart",this._eventHandlers.focusCanvas),window.removeEventListener("resize",this._eventHandlers.windowResize),this._keyboard.ungrab(),this._gestures.detach(),this._sock.close();try{this._target.removeChild(this._screen)}catch(e){if("NotFoundError"!==e.name)throw e}clearTimeout(this._resizeTimeout),clearTimeout(this._mouseMoveTimer),i.Debug("<< RFB.disconnect")}},{key:"_focusCanvas",value:function(e){this.focusOnClick&&this.focus()}},{key:"_setDesktopName",value:function(e){this._fbName=e,this.dispatchEvent(new CustomEvent("desktopname",{detail:{name:this._fbName}}))}},{key:"_windowResize",value:function(e){var t=this;window.requestAnimationFrame((function(){t._updateClip(),t._updateScale()})),this._resizeSession&&(clearTimeout(this._resizeTimeout),this._resizeTimeout=setTimeout(this._requestRemoteResize.bind(this),500))}},{key:"_updateClip",value:function(){var e=this._display.clipViewport,t=this._clipViewport;if(this._scaleViewport&&(t=!1),e!==t&&(this._display.clipViewport=t),t){var n=this._screenSize();this._display.viewportChangeSize(n.w,n.h),this._fixScrollbars()}}},{key:"_updateScale",value:function(){if(this._scaleViewport){var e=this._screenSize();this._display.autoscale(e.w,e.h)}else this._display.scale=1;this._fixScrollbars()}},{key:"_requestRemoteResize",value:function(){if(clearTimeout(this._resizeTimeout),this._resizeTimeout=null,this._resizeSession&&!this._viewOnly&&this._supportsSetDesktopSize){var e=this._screenSize();x.messages.setDesktopSize(this._sock,Math.floor(e.w),Math.floor(e.h),this._screenID,this._screenFlags),i.Debug("Requested new desktop size: "+e.w+"x"+e.h)}}},{key:"_screenSize",value:function(){var e=this._screen.getBoundingClientRect();return{w:e.width,h:e.height}}},{key:"_fixScrollbars",value:function(){var e=this._screen.style.overflow;this._screen.style.overflow="hidden",this._screen.getBoundingClientRect(),this._screen.style.overflow=e}},{key:"_updateConnectionState",value:function(e){var t=this,n=this._rfbConnectionState;if(e!==n)if("disconnected"!==n){switch(e){case"connected":if("connecting"!==n)return void i.Error("Bad transition to connected state, previous connection state: "+n);break;case"disconnected":if("disconnecting"!==n)return void i.Error("Bad transition to disconnected state, previous connection state: "+n);break;case"connecting":if(""!==n)return void i.Error("Bad transition to connecting state, previous connection state: "+n);break;case"disconnecting":if("connected"!==n&&"connecting"!==n)return void i.Error("Bad transition to disconnecting state, previous connection state: "+n);break;default:return void i.Error("Unknown connection state: "+e)}switch(this._rfbConnectionState=e,i.Debug("New state '"+e+"', was '"+n+"'."),this._disconnTimer&&"disconnecting"!==e&&(i.Debug("Clearing disconnect timer"),clearTimeout(this._disconnTimer),this._disconnTimer=null,this._sock.off("close")),e){case"connecting":this._connect();break;case"connected":this.dispatchEvent(new CustomEvent("connect",{detail:{}}));break;case"disconnecting":this._disconnect(),this._disconnTimer=setTimeout((function(){i.Error("Disconnection timed out."),t._updateConnectionState("disconnected")}),3e3);break;case"disconnected":this.dispatchEvent(new CustomEvent("disconnect",{detail:{clean:this._rfbCleanDisconnect}}))}}else i.Error("Tried changing state of a disconnected RFB object");else i.Debug("Already in state '"+e+"', ignoring")}},{key:"_fail",value:function(e){switch(this._rfbConnectionState){case"disconnecting":i.Error("Failed when disconnecting: "+e);break;case"connected":i.Error("Failed while connected: "+e);break;case"connecting":i.Error("Failed when connecting: "+e);break;default:i.Error("RFB failure: "+e)}return this._rfbCleanDisconnect=!1,this._updateConnectionState("disconnecting"),this._updateConnectionState("disconnected"),!1}},{key:"_setCapability",value:function(e,t){this._capabilities[e]=t,this.dispatchEvent(new CustomEvent("capabilities",{detail:{capabilities:this._capabilities}}))}},{key:"_handleMessage",value:function(){if(0!==this._sock.rQlen)switch(this._rfbConnectionState){case"disconnected":i.Error("Got data while disconnected");break;case"connected":for(;!this._flushing&&this._normalMsg()&&0!==this._sock.rQlen;);break;default:this._initMsg()}else i.Warn("handleMessage called on an empty receive queue")}},{key:"_handleKeyEvent",value:function(e,t,n){this.sendKey(e,t,n)}},{key:"_handleMouse",value:function(e){if(("click"!==e.type||e.target===this._canvas)&&(e.stopPropagation(),e.preventDefault(),"click"!==e.type&&"contextmenu"!==e.type)){var t=(0,a.clientToElement)(e.clientX,e.clientY,this._canvas);switch(e.type){case"mousedown":(0,c.setCapture)(this._canvas),this._handleMouseButton(t.x,t.y,!0,1<s.dragThreshold||Math.abs(i)>s.dragThreshold)&&(this._viewportHasMoved=!0,this._viewportDragPos={x:e,y:t},this._display.viewportChangePos(r,i))}else if(this._mousePos={x:e,y:t},null==this._mouseMoveTimer){var o=Date.now()-this._mouseLastMoveTime;o>17?(this._sendMouse(e,t,this._mouseButtonMask),this._mouseLastMoveTime=Date.now()):this._mouseMoveTimer=setTimeout((function(){n._handleDelayedMouseMove()}),17-o)}}},{key:"_handleDelayedMouseMove",value:function(){this._mouseMoveTimer=null,this._sendMouse(this._mousePos.x,this._mousePos.y,this._mouseButtonMask),this._mouseLastMoveTime=Date.now()}},{key:"_sendMouse",value:function(e,t,n){"connected"===this._rfbConnectionState&&(this._viewOnly||x.messages.pointerEvent(this._sock,this._display.absX(e),this._display.absY(t),n))}},{key:"_handleWheel",value:function(e){if("connected"===this._rfbConnectionState&&!this._viewOnly){e.stopPropagation(),e.preventDefault();var t=(0,a.clientToElement)(e.clientX,e.clientY,this._canvas),n=e.deltaX,r=e.deltaY;0!==e.deltaMode&&(n*=19,r*=19),this._accumulatedWheelDeltaX+=n,this._accumulatedWheelDeltaY+=r,Math.abs(this._accumulatedWheelDeltaX)>=50&&(this._accumulatedWheelDeltaX<0?(this._handleMouseButton(t.x,t.y,!0,32),this._handleMouseButton(t.x,t.y,!1,32)):this._accumulatedWheelDeltaX>0&&(this._handleMouseButton(t.x,t.y,!0,64),this._handleMouseButton(t.x,t.y,!1,64)),this._accumulatedWheelDeltaX=0),Math.abs(this._accumulatedWheelDeltaY)>=50&&(this._accumulatedWheelDeltaY<0?(this._handleMouseButton(t.x,t.y,!0,8),this._handleMouseButton(t.x,t.y,!1,8)):this._accumulatedWheelDeltaY>0&&(this._handleMouseButton(t.x,t.y,!0,16),this._handleMouseButton(t.x,t.y,!1,16)),this._accumulatedWheelDeltaY=0)}}},{key:"_fakeMouseMove",value:function(e,t,n){this._handleMouseMove(t,n),this._cursor.move(e.detail.clientX,e.detail.clientY)}},{key:"_handleTapEvent",value:function(e,t){var n=(0,a.clientToElement)(e.detail.clientX,e.detail.clientY,this._canvas);if(null!==this._gestureLastTapTime&&Date.now()-this._gestureLastTapTime<1e3&&this._gestureFirstDoubleTapEv.detail.type===e.detail.type){var r=this._gestureFirstDoubleTapEv.detail.clientX-e.detail.clientX,i=this._gestureFirstDoubleTapEv.detail.clientY-e.detail.clientY;Math.hypot(r,i)<50?n=(0,a.clientToElement)(this._gestureFirstDoubleTapEv.detail.clientX,this._gestureFirstDoubleTapEv.detail.clientY,this._canvas):this._gestureFirstDoubleTapEv=e}else this._gestureFirstDoubleTapEv=e;this._gestureLastTapTime=Date.now(),this._fakeMouseMove(this._gestureFirstDoubleTapEv,n.x,n.y),this._handleMouseButton(n.x,n.y,!0,t),this._handleMouseButton(n.x,n.y,!1,t)}},{key:"_handleGesture",value:function(e){var t,n=(0,a.clientToElement)(e.detail.clientX,e.detail.clientY,this._canvas);switch(e.type){case"gesturestart":switch(e.detail.type){case"onetap":this._handleTapEvent(e,1);break;case"twotap":this._handleTapEvent(e,4);break;case"threetap":this._handleTapEvent(e,2);break;case"drag":this._fakeMouseMove(e,n.x,n.y),this._handleMouseButton(n.x,n.y,!0,1);break;case"longpress":this._fakeMouseMove(e,n.x,n.y),this._handleMouseButton(n.x,n.y,!0,4);break;case"twodrag":this._gestureLastMagnitudeX=e.detail.magnitudeX,this._gestureLastMagnitudeY=e.detail.magnitudeY,this._fakeMouseMove(e,n.x,n.y);break;case"pinch":this._gestureLastMagnitudeX=Math.hypot(e.detail.magnitudeX,e.detail.magnitudeY),this._fakeMouseMove(e,n.x,n.y)}break;case"gesturemove":switch(e.detail.type){case"onetap":case"twotap":case"threetap":break;case"drag":case"longpress":this._fakeMouseMove(e,n.x,n.y);break;case"twodrag":for(this._fakeMouseMove(e,n.x,n.y);e.detail.magnitudeY-this._gestureLastMagnitudeY>50;)this._handleMouseButton(n.x,n.y,!0,8),this._handleMouseButton(n.x,n.y,!1,8),this._gestureLastMagnitudeY+=50;for(;e.detail.magnitudeY-this._gestureLastMagnitudeY<-50;)this._handleMouseButton(n.x,n.y,!0,16),this._handleMouseButton(n.x,n.y,!1,16),this._gestureLastMagnitudeY-=50;for(;e.detail.magnitudeX-this._gestureLastMagnitudeX>50;)this._handleMouseButton(n.x,n.y,!0,32),this._handleMouseButton(n.x,n.y,!1,32),this._gestureLastMagnitudeX+=50;for(;e.detail.magnitudeX-this._gestureLastMagnitudeX<-50;)this._handleMouseButton(n.x,n.y,!0,64),this._handleMouseButton(n.x,n.y,!1,64),this._gestureLastMagnitudeX-=50;break;case"pinch":if(this._fakeMouseMove(e,n.x,n.y),t=Math.hypot(e.detail.magnitudeX,e.detail.magnitudeY),Math.abs(t-this._gestureLastMagnitudeX)>75){for(this._handleKeyEvent(g.default.XK_Control_L,"ControlLeft",!0);t-this._gestureLastMagnitudeX>75;)this._handleMouseButton(n.x,n.y,!0,8),this._handleMouseButton(n.x,n.y,!1,8),this._gestureLastMagnitudeX+=75;for(;t-this._gestureLastMagnitudeX<-75;)this._handleMouseButton(n.x,n.y,!0,16),this._handleMouseButton(n.x,n.y,!1,16),this._gestureLastMagnitudeX-=75}this._handleKeyEvent(g.default.XK_Control_L,"ControlLeft",!1)}break;case"gestureend":switch(e.detail.type){case"onetap":case"twotap":case"threetap":case"pinch":case"twodrag":break;case"drag":this._fakeMouseMove(e,n.x,n.y),this._handleMouseButton(n.x,n.y,!1,1);break;case"longpress":this._fakeMouseMove(e,n.x,n.y),this._handleMouseButton(n.x,n.y,!1,4)}}}},{key:"_negotiateProtocolVersion",value:function(){if(this._sock.rQwait("version",12))return!1;var e=this._sock.rQshiftStr(12).substr(4,7);i.Info("Server ProtocolVersion: "+e);var t=0;switch(e){case"000.000":t=1;break;case"003.003":case"003.006":case"003.889":this._rfbVersion=3.3;break;case"003.007":this._rfbVersion=3.7;break;case"003.008":case"004.000":case"004.001":case"005.000":this._rfbVersion=3.8;break;default:return this._fail("Invalid server version "+e)}if(t){for(var n="ID:"+this._repeaterID;n.length<250;)n+="\0";return this._sock.sendString(n),!0}this._rfbVersion>this._rfbMaxVersion&&(this._rfbVersion=this._rfbMaxVersion);var r="00"+parseInt(this._rfbVersion,10)+".00"+10*this._rfbVersion%10;this._sock.sendString("RFB "+r+"\n"),i.Debug("Sent ProtocolVersion: "+r),this._rfbInitState="Security"}},{key:"_negotiateSecurity",value:function(){function e(e,t){for(var n=0;n=3.7){var t=this._sock.rQshift8();if(this._sock.rQwait("security type",t,1))return!1;if(0===t)return this._rfbInitState="SecurityReason",this._securityContext="no security types",this._securityStatus=1,this._initMsg();var n=this._sock.rQshiftBytes(t);if(i.Debug("Server security types: "+n),e(1,n))this._rfbAuthScheme=1;else if(e(22,n))this._rfbAuthScheme=22;else if(e(16,n))this._rfbAuthScheme=16;else if(e(2,n))this._rfbAuthScheme=2;else{if(!e(19,n))return this._fail("Unsupported security types (types: "+n+")");this._rfbAuthScheme=19}this._sock.send([this._rfbAuthScheme])}else{if(this._sock.rQwait("security scheme",4))return!1;if(this._rfbAuthScheme=this._sock.rQshift32(),0==this._rfbAuthScheme)return this._rfbInitState="SecurityReason",this._securityContext="authentication scheme",this._securityStatus=1,this._initMsg()}return this._rfbInitState="Authentication",i.Debug("Authenticating using scheme: "+this._rfbAuthScheme),this._initMsg()}},{key:"_handleSecurityReason",value:function(){if(this._sock.rQwait("reason length",4))return!1;var e=this._sock.rQshift32(),t="";if(e>0){if(this._sock.rQwait("reason",e,4))return!1;t=this._sock.rQshiftStr(e)}return""!==t?(this.dispatchEvent(new CustomEvent("securityfailure",{detail:{status:this._securityStatus,reason:t}})),this._fail("Security negotiation failed on "+this._securityContext+" (reason: "+t+")")):(this.dispatchEvent(new CustomEvent("securityfailure",{detail:{status:this._securityStatus}})),this._fail("Security negotiation failed on "+this._securityContext))}},{key:"_negotiateXvpAuth",value:function(){if(void 0===this._rfbCredentials.username||void 0===this._rfbCredentials.password||void 0===this._rfbCredentials.target)return this.dispatchEvent(new CustomEvent("credentialsrequired",{detail:{types:["username","password","target"]}})),!1;var e=String.fromCharCode(this._rfbCredentials.username.length)+String.fromCharCode(this._rfbCredentials.target.length)+this._rfbCredentials.username+this._rfbCredentials.target;return this._sock.sendString(e),this._rfbAuthScheme=2,this._negotiateAuthentication()}},{key:"_negotiateVeNCryptAuth",value:function(){if(0==this._rfbVeNCryptState){if(this._sock.rQwait("vencrypt version",2))return!1;var e=this._sock.rQshift8(),t=this._sock.rQshift8();if(0!=e||2!=t)return this._fail("Unsupported VeNCrypt version "+e+"."+t);this._sock.send([0,2]),this._rfbVeNCryptState=1}if(1==this._rfbVeNCryptState){if(this._sock.rQwait("vencrypt ack",1))return!1;var n=this._sock.rQshift8();if(0!=n)return this._fail("VeNCrypt failure "+n);this._rfbVeNCryptState=2}if(2==this._rfbVeNCryptState){if(this._sock.rQwait("vencrypt subtypes length",1))return!1;var r=this._sock.rQshift8();if(r<1)return this._fail("VeNCrypt subtypes empty");this._rfbVeNCryptSubtypesLength=r,this._rfbVeNCryptState=3}if(3==this._rfbVeNCryptState){if(this._sock.rQwait("vencrypt subtypes",4*this._rfbVeNCryptSubtypesLength))return!1;for(var i=[],s=0;s0&&this._sock.rQwait("tunnel capabilities",16*e,4))return!1;if(this._rfbTightVNC=!0,e>0)return this._negotiateTightTunnels(e),!1}if(this._sock.rQwait("sub auth count",4))return!1;var t=this._sock.rQshift32();if(0===t)return this._rfbInitState="SecurityResult",!0;if(this._sock.rQwait("sub auth capabilities",16*t,4))return!1;for(var n={STDVNOAUTH__:1,STDVVNCAUTH_:2,TGHTULGNAUTH:129},r=[],o=0;o=3.8?(this._rfbInitState="SecurityResult",!0):(this._rfbInitState="ClientInitialisation",this._initMsg());case 22:return this._negotiateXvpAuth();case 2:return this._negotiateStdVNCAuth();case 16:return this._negotiateTightAuth();case 19:return this._negotiateVeNCryptAuth();case 129:return this._negotiateTightUnixAuth();default:return this._fail("Unsupported auth scheme (scheme: "+this._rfbAuthScheme+")")}}},{key:"_handleSecurityResult",value:function(){if(this._sock.rQwait("VNC auth response ",4))return!1;var e=this._sock.rQshift32();return 0===e?(this._rfbInitState="ClientInitialisation",i.Debug("Authentication OK"),this._initMsg()):this._rfbVersion>=3.8?(this._rfbInitState="SecurityReason",this._securityContext="security result",this._securityStatus=e,this._initMsg()):(this.dispatchEvent(new CustomEvent("securityfailure",{detail:{status:e}})),this._fail("Security handshake failed"))}},{key:"_negotiateServerInit",value:function(){if(this._sock.rQwait("server initialization",24))return!1;var e=this._sock.rQshift16(),t=this._sock.rQshift16(),n=this._sock.rQshift8(),r=this._sock.rQshift8(),s=this._sock.rQshift8(),a=this._sock.rQshift8(),c=this._sock.rQshift16(),l=this._sock.rQshift16(),u=this._sock.rQshift16(),h=this._sock.rQshift8(),d=this._sock.rQshift8(),f=this._sock.rQshift8();this._sock.rQskipBytes(3);var p=this._sock.rQshift32();if(this._sock.rQwait("server init name",p,24))return!1;var _=this._sock.rQshiftStr(p);if(_=(0,o.decodeUTF8)(_,!0),this._rfbTightVNC){if(this._sock.rQwait("TightVNC extended server init header",8,24+p))return!1;var v=this._sock.rQshift16(),b=this._sock.rQshift16(),g=this._sock.rQshift16();this._sock.rQskipBytes(2);var m=16*(v+b+g);if(this._sock.rQwait("TightVNC extended server init header",m,32+p))return!1;this._sock.rQskipBytes(16*v),this._sock.rQskipBytes(16*b),this._sock.rQskipBytes(16*g)}return i.Info("Screen: "+e+"x"+t+", bpp: "+n+", depth: "+r+", bigEndian: "+s+", trueColor: "+a+", redMax: "+c+", greenMax: "+l+", blueMax: "+u+", redShift: "+h+", greenShift: "+d+", blueShift: "+f),this._setDesktopName(_),this._resize(e,t),this._viewOnly||this._keyboard.grab(),this._fbDepth=24,"Intel(r) AMT KVM"===this._fbName&&(i.Warn("Intel AMT KVM only supports 8/16 bit depths. Using low color mode."),this._fbDepth=8),x.messages.pixelFormat(this._sock,this._fbDepth,!0),this._sendEncodings(),x.messages.fbUpdateRequest(this._sock,!1,0,0,this._fbWidth,this._fbHeight),this._updateConnectionState("connected"),!0}},{key:"_sendEncodings",value:function(){var e=[];e.push(y.encodings.encodingCopyRect),24==this._fbDepth&&(e.push(y.encodings.encodingTight),e.push(y.encodings.encodingTightPNG),e.push(y.encodings.encodingHextile),e.push(y.encodings.encodingRRE)),e.push(y.encodings.encodingRaw),e.push(y.encodings.pseudoEncodingQualityLevel0+this._qualityLevel),e.push(y.encodings.pseudoEncodingCompressLevel0+this._compressionLevel),e.push(y.encodings.pseudoEncodingDesktopSize),e.push(y.encodings.pseudoEncodingLastRect),e.push(y.encodings.pseudoEncodingQEMUExtendedKeyEvent),e.push(y.encodings.pseudoEncodingExtendedDesktopSize),e.push(y.encodings.pseudoEncodingXvp),e.push(y.encodings.pseudoEncodingFence),e.push(y.encodings.pseudoEncodingContinuousUpdates),e.push(y.encodings.pseudoEncodingDesktopName),e.push(y.encodings.pseudoEncodingExtendedClipboard),24==this._fbDepth&&(e.push(y.encodings.pseudoEncodingVMwareCursor),e.push(y.encodings.pseudoEncodingCursor)),x.messages.clientEncodings(this._sock,e)}},{key:"_initMsg",value:function(){switch(this._rfbInitState){case"ProtocolVersion":return this._negotiateProtocolVersion();case"Security":return this._negotiateSecurity();case"Authentication":return this._negotiateAuthentication();case"SecurityResult":return this._handleSecurityResult();case"SecurityReason":return this._handleSecurityReason();case"ClientInitialisation":return this._sock.send([this._shared?1:0]),this._rfbInitState="ServerInitialisation",!0;case"ServerInitialisation":return this._negotiateServerInit();default:return this._fail("Unknown init state (state: "+this._rfbInitState+")")}}},{key:"_handleSetColourMapMsg",value:function(){return i.Debug("SetColorMapEntries"),this._fail("Unexpected SetColorMapEntries message")}},{key:"_handleServerCutText",value:function(){if(i.Debug("ServerCutText"),this._sock.rQwait("ServerCutText header",7,1))return!1;this._sock.rQskipBytes(3);var e=this._sock.rQshift32();if(e=(0,r.toSigned32bit)(e),this._sock.rQwait("ServerCutText content",Math.abs(e),8))return!1;if(e>=0){var t=this._sock.rQshiftStr(e);if(this._viewOnly)return!0;this.dispatchEvent(new CustomEvent("clipboard",{detail:{text:t}}))}else{e=Math.abs(e);var n=this._sock.rQshift32(),s=65535&n,a=4278190080&n;if(a&1<<24){this._clipboardServerCapabilitiesFormats={},this._clipboardServerCapabilitiesActions={};for(var c=0;c<=15;c++){var l=1<0&&"\0"===v.charAt(v.length-1)&&(v=v.slice(0,-1)),v=v.replace("\r\n","\n"),this.dispatchEvent(new CustomEvent("clipboard",{detail:{text:v}}))}}}return!0}},{key:"_handleServerFenceMsg",value:function(){if(this._sock.rQwait("ServerFence header",8,1))return!1;this._sock.rQskipBytes(3);var e=this._sock.rQshift32(),t=this._sock.rQshift8();if(this._sock.rQwait("ServerFence payload",t,9))return!1;t>64&&(i.Warn("Bad payload length ("+t+") in fence response"),t=64);var n=this._sock.rQshiftStr(t);return this._supportsFence=!0,e&1<<31?(e&=3,x.messages.clientFence(this._sock,e,n),!0):this._fail("Unexpected fence response")}},{key:"_handleXvpMsg",value:function(){if(this._sock.rQwait("XVP version and message",3,1))return!1;this._sock.rQskipBytes(1);var e=this._sock.rQshift8(),t=this._sock.rQshift8();switch(t){case 0:i.Error("XVP Operation Failed");break;case 1:this._rfbXvpVer=e,i.Info("XVP extensions enabled (version "+this._rfbXvpVer+")"),this._setCapability("power",!0);break;default:this._fail("Illegal server XVP message (msg: "+t+")")}return!0}},{key:"_normalMsg",value:function(){var e,t,n;switch(e=this._FBU.rects>0?0:this._sock.rQshift8()){case 0:return(n=this._framebufferUpdate())&&!this._enabledContinuousUpdates&&x.messages.fbUpdateRequest(this._sock,!0,0,0,this._fbWidth,this._fbHeight),n;case 1:return this._handleSetColourMapMsg();case 2:return i.Debug("Bell"),this.dispatchEvent(new CustomEvent("bell",{detail:{}})),!0;case 3:return this._handleServerCutText();case 150:return t=!this._supportsContinuousUpdates,this._supportsContinuousUpdates=!0,this._enabledContinuousUpdates=!1,t&&(this._enabledContinuousUpdates=!0,this._updateContinuousUpdates(),i.Info("Enabling continuous updates.")),!0;case 248:return this._handleServerFenceMsg();case 250:return this._handleXvpMsg();default:return this._fail("Unexpected server message (type "+e+")"),i.Debug("sock.rQslice(0, 30): "+this._sock.rQslice(0,30)),!0}}},{key:"_onFlush",value:function(){this._flushing=!1,this._sock.rQlen>0&&this._handleMessage()}},{key:"_framebufferUpdate",value:function(){if(0===this._FBU.rects){if(this._sock.rQwait("FBU header",3,1))return!1;if(this._sock.rQskipBytes(1),this._FBU.rects=this._sock.rQshift16(),this._display.pending())return this._flushing=!0,this._display.flush(),!1}for(;this._FBU.rects>0;){if(null===this._FBU.encoding){if(this._sock.rQwait("rect header",12))return!1;var e=this._sock.rQshiftBytes(12);this._FBU.x=(e[0]<<8)+e[1],this._FBU.y=(e[2]<<8)+e[3],this._FBU.width=(e[4]<<8)+e[5],this._FBU.height=(e[6]<<8)+e[7],this._FBU.encoding=parseInt((e[8]<<24)+(e[9]<<16)+(e[10]<<8)+e[11],10)}if(!this._handleRect())return!1;this._FBU.rects--,this._FBU.encoding=null}return this._display.flip(),!0}},{key:"_handleRect",value:function(){switch(this._FBU.encoding){case y.encodings.pseudoEncodingLastRect:return this._FBU.rects=1,!0;case y.encodings.pseudoEncodingVMwareCursor:return this._handleVMwareCursor();case y.encodings.pseudoEncodingCursor:return this._handleCursor();case y.encodings.pseudoEncodingQEMUExtendedKeyEvent:try{void 0!==document.createEvent("keyboardEvent").code&&(this._qemuExtKeyEventSupported=!0)}catch(e){}return!0;case y.encodings.pseudoEncodingDesktopName:return this._handleDesktopName();case y.encodings.pseudoEncodingDesktopSize:return this._resize(this._FBU.width,this._FBU.height),!0;case y.encodings.pseudoEncodingExtendedDesktopSize:return this._handleExtendedDesktopSize();default:return this._handleDataRect()}}},{key:"_handleVMwareCursor",value:function(){var e=this._FBU.x,t=this._FBU.y,n=this._FBU.width,r=this._FBU.height;if(this._sock.rQwait("VMware cursor encoding",1))return!1;var o,s=this._sock.rQshift8();if(this._sock.rQshift8(),0==s){if(o=new Array(n*r*4),this._sock.rQwait("VMware cursor classic encoding",n*r*4*2,2))return!1;for(var a=new Array(n*r),c=0;c>8&255,p=d>>16&255,_=d>>24&255;o[4*h]=f,o[4*h+1]=p,o[4*h+2]=_,o[4*h+3]=255}else-256==(-256&a[h])?0==l[h]?(o[4*h]=0,o[4*h+1]=0,o[4*h+2]=0,o[4*h+3]=0):(l[h],o[4*h]=0,o[4*h+1]=0,o[4*h+2]=0,o[4*h+3]=255):(o[4*h]=0,o[4*h+1]=0,o[4*h+2]=0,o[4*h+3]=255)}else{if(1!=s)return i.Warn("The given cursor type is not supported: "+s+" given."),!1;if(this._sock.rQwait("VMware cursor alpha encoding",n*r*4,2))return!1;o=new Array(n*r*4);for(var v=0;v>24&255,o[4*v+1]=b>>16&255,o[4*v+2]=b>>8&255,o[4*v+3]=255&b}}return this._updateCursor(o,e,t,n,r),!0}},{key:"_handleCursor",value:function(){var e=this._FBU.x,t=this._FBU.y,n=this._FBU.width,r=this._FBU.height,i=n*r*4,o=Math.ceil(n/8)*r,s=i+o;if(this._sock.rQwait("cursor encoding",s))return!1;for(var a=this._sock.rQshiftBytes(i),c=this._sock.rQshiftBytes(o),l=new Uint8Array(n*r*4),u=0,h=0;h9?i.Error("qualityLevel must be an integer between 0 and 9"):this._qualityLevel!==e&&(this._qualityLevel=e,"connected"===this._rfbConnectionState&&this._sendEncodings())}},{key:"compressionLevel",get:function(){return this._compressionLevel},set:function(e){!Number.isInteger(e)||e<0||e>9?i.Error("compressionLevel must be an integer between 0 and 9"):this._compressionLevel!==e&&(this._compressionLevel=e,"connected"===this._rfbConnectionState&&this._sendEncodings())}}])&&L(t.prototype,n),l&&L(t,l),x}(l.default);t.default=K,K.messages={keyEvent:function(e,t,n){var r=e._sQ,i=e._sQlen;r[i]=4,r[i+1]=n,r[i+2]=0,r[i+3]=0,r[i+4]=t>>24,r[i+5]=t>>16,r[i+6]=t>>8,r[i+7]=t,e._sQlen+=8,e.flush()},QEMUExtendedKeyEvent:function(e,t,n,r){var i=e._sQ,o=e._sQlen;i[o]=255,i[o+1]=0,i[o+2]=n>>8,i[o+3]=n,i[o+4]=t>>24,i[o+5]=t>>16,i[o+6]=t>>8,i[o+7]=t;var s,a,c=(s=r,a=255&r,224==r>>8&&a<127?128|a:s);i[o+8]=c>>24,i[o+9]=c>>16,i[o+10]=c>>8,i[o+11]=c,e._sQlen+=12,e.flush()},pointerEvent:function(e,t,n,r){var i=e._sQ,o=e._sQlen;i[o]=5,i[o+1]=r,i[o+2]=t>>8,i[o+3]=t,i[o+4]=n>>8,i[o+5]=n,e._sQlen+=6,e.flush()},_buildExtendedClipboardFlags:function(e,t){for(var n=new Uint8Array(4),r=0,i=0,o=0;o>24,n[1]=0,n[2]=0,n[3]=r,n},extendedClipboardProvide:function(e,t,n){for(var r=new d.default,i=[],s=0;s>24&255,a.length>>16&255,a.length>>8&255,255&a.length);for(var c=0;c>24,i[o+1]=n[r[s]]>>16,i[o+2]=n[r[s]]>>8,i[o+3]=n[r[s]]>>0,o+=4,i[3]|=1<2&&void 0!==arguments[2]&&arguments[2],o=e._sQ,s=e._sQlen;o[s]=6,o[s+1]=0,o[s+2]=0,o[s+3]=0,n=i?(0,r.toUnsigned32bit)(-t.length):t.length,o[s+4]=n>>24,o[s+5]=n>>16,o[s+6]=n>>8,o[s+7]=n,e._sQlen+=8;for(var a=0,c=t.length;c>0;){for(var l=Math.min(c,e._sQbufferSize-e._sQlen),u=0;u>8,o[s+3]=t,o[s+4]=n>>8,o[s+5]=n,o[s+6]=1,o[s+7]=0,o[s+8]=r>>24,o[s+9]=r>>16,o[s+10]=r>>8,o[s+11]=r,o[s+12]=0,o[s+13]=0,o[s+14]=0,o[s+15]=0,o[s+16]=t>>8,o[s+17]=t,o[s+18]=n>>8,o[s+19]=n,o[s+20]=i>>24,o[s+21]=i>>16,o[s+22]=i>>8,o[s+23]=i,e._sQlen+=24,e.flush()},clientFence:function(e,t,n){var r=e._sQ,i=e._sQlen;r[i]=248,r[i+1]=0,r[i+2]=0,r[i+3]=0,r[i+4]=t>>24,r[i+5]=t>>16,r[i+6]=t>>8,r[i+7]=t;var o=n.length;r[i+8]=o;for(var s=0;s>8,s[a+3]=n,s[a+4]=r>>8,s[a+5]=r,s[a+6]=i>>8,s[a+7]=i,s[a+8]=o>>8,s[a+9]=o,e._sQlen+=10,e.flush()},pixelFormat:function(e,t,n){var r,i=e._sQ,o=e._sQlen;r=t>16?32:t>8?16:8;var s=Math.floor(t/3);i[o]=0,i[o+1]=0,i[o+2]=0,i[o+3]=0,i[o+4]=r,i[o+5]=t,i[o+6]=0,i[o+7]=n?1:0,i[o+8]=0,i[o+9]=(1<>8,n[r+3]=t.length;for(var i=r+4,o=0;o>24,n[i+1]=s>>16,n[i+2]=s>>8,n[i+3]=s,i+=4}e._sQlen+=i-r,e.flush()},fbUpdateRequest:function(e,t,n,r,i,o){var s=e._sQ,a=e._sQlen;void 0===n&&(n=0),void 0===r&&(r=0),s[a]=3,s[a+1]=t?1:0,s[a+2]=n>>8&255,s[a+3]=255&n,s[a+4]=r>>8&255,s[a+5]=255&r,s[a+6]=i>>8&255,s[a+7]=255&i,s[a+8]=o>>8&255,s[a+9]=255&o,e._sQlen+=10,e.flush()},xvpOp:function(e,t,n){var r=e._sQ,i=e._sQlen;r[i]=250,r[i+1]=0,r[i+2]=t,r[i+3]=n,e._sQlen+=4,e.flush()}},K.cursors={none:{rgbaPixels:new Uint8Array,w:0,h:0,hotx:0,hoty:0},dot:{rgbaPixels:new Uint8Array([255,255,255,255,0,0,0,255,255,255,255,255,0,0,0,255,0,0,0,0,0,0,0,255,255,255,255,255,0,0,0,255,255,255,255,255]),w:3,h:3,hotx:1,hoty:1}}},"1j5w": /*!*******************************************************!*\ !*** ./node_modules/rc-menu/es/index.js + 11 modules ***! \*******************************************************/ /*! exports provided: SubMenu, Item, MenuItem, MenuItemGroup, ItemGroup, Divider, default */ /*! exports used: Divider, Item, ItemGroup, SubMenu, default */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/extends.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/mini-store/esm/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/omit.js/es/index.js (<- Module is referenced from these modules with unsupported syntax: ./node_modules/antd/lib/button/button.js (referenced with cjs require), ./node_modules/antd/lib/input/Input.js (referenced with cjs require), ./node_modules/antd/lib/input/Password.js (referenced with cjs require), ./node_modules/antd/lib/input/TextArea.js (referenced with cjs require)) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-motion/es/index.js (<- Module is referenced from these modules with unsupported syntax: ./node_modules/antd/lib/button/LoadingIcon.js (referenced with cjs require)) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-trigger/es/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/KeyCode.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/createChainedFunction.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/warning.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-dom/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js (<- Module uses injected variables (global)) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/shallowequal/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";n.d(t,"d",(function(){return se})),n.d(t,"b",(function(){return ye})),n.d(t,"c",(function(){return Se})),n.d(t,"a",(function(){return ke}));var r=n("VTBJ"),i=n("1OyB"),o=n("vuIU"),s=n("JX7q"),a=n("Ji7U"),c=n("LK+K"),l=n("q1tI"),u=n("I8Z2"),h=n("BGR+"),d=n("wx14"),f=n("rePB"),p=n("4IlW"),_=n("2GS6"),v=n("Gytx"),b=n.n(v),g=n("TSYQ"),m=n.n(g),y=n("U8pU"),w=n("ODXe"),S=/iPhone/i,C=/iPod/i,k=/iPad/i,E=/\bAndroid(?:.+)Mobile\b/i,O=/Android/i,x=/\bAndroid(?:.+)SD4930UR\b/i,A=/\bAndroid(?:.+)(?:KF[A-Z]{2,4})\b/i,j=/Windows Phone/i,L=/\bWindows(?:.+)ARM\b/i,R=/BlackBerry/i,M=/BB10/i,T=/Opera Mini/i,D=/\b(CriOS|Chrome)(?:.+)Mobile/i,P=/Mobile(?:.+)Firefox\b/i;function K(e,t){return e.test(t)}function I(e){var t=e||("undefined"!=typeof navigator?navigator.userAgent:""),n=t.split("[FBAN");if(void 0!==n[1]){var r=n;t=Object(w.a)(r,1)[0]}if(void 0!==(n=t.split("Twitter"))[1]){var i=n;t=Object(w.a)(i,1)[0]}var o={apple:{phone:K(S,t)&&!K(j,t),ipod:K(C,t),tablet:!K(S,t)&&K(k,t)&&!K(j,t),device:(K(S,t)||K(C,t)||K(k,t))&&!K(j,t)},amazon:{phone:K(x,t),tablet:!K(x,t)&&K(A,t),device:K(x,t)||K(A,t)},android:{phone:!K(j,t)&&K(x,t)||!K(j,t)&&K(E,t),tablet:!K(j,t)&&!K(x,t)&&!K(E,t)&&(K(A,t)||K(O,t)),device:!K(j,t)&&(K(x,t)||K(A,t)||K(E,t)||K(O,t))||K(/\bokhttp\b/i,t)},windows:{phone:K(j,t),tablet:K(L,t),device:K(j,t)||K(L,t)},other:{blackberry:K(R,t),blackberry10:K(M,t),opera:K(T,t),firefox:K(P,t),chrome:K(D,t),device:K(R,t)||K(M,t)||K(T,t)||K(P,t)||K(D,t)},any:null,phone:null,tablet:null};return o.any=o.apple.device||o.android.device||o.windows.device||o.other.device,o.phone=o.apple.phone||o.android.phone||o.windows.phone,o.tablet=o.apple.tablet||o.android.tablet||o.windows.tablet,o}var F=Object(r.a)(Object(r.a)({},I()),{},{isMobile:I});function X(){}function N(e,t,n){var r=t||"";return e.key||"".concat(r,"item_").concat(n)}function B(e){return"".concat(e,"-menu-")}function H(e,t){var n=-1;l.Children.forEach(e,(function(e){n+=1,e&&e.type&&e.type.isMenuItemGroup?l.Children.forEach(e.props.children,(function(e){t(e,n+=1)})):t(e,n)}))}var U=["defaultSelectedKeys","selectedKeys","defaultOpenKeys","openKeys","mode","getPopupContainer","onSelect","onDeselect","onDestroy","openTransitionName","openAnimation","subMenuOpenDelay","subMenuCloseDelay","forceSubMenuRender","triggerSubMenuAction","level","selectable","multiple","onOpenChange","visible","focusable","defaultActiveFirst","prefixCls","inlineIndent","parentMenu","title","rootPrefixCls","eventKey","active","onItemHover","onTitleMouseEnter","onTitleMouseLeave","onTitleClick","popupAlign","popupOffset","isOpen","renderMenuItem","manualRef","subMenuKey","disabled","index","isSelected","store","activeKey","builtinPlacements","overflowedIndicator","motion","attribute","value","popupClassName","inlineCollapsed","menu","theme","itemIcon","expandIcon"],W=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=e&&"function"==typeof e.getBoundingClientRect&&e.getBoundingClientRect().width;if(n){if(t){var r=getComputedStyle(e),i=r.marginLeft,o=r.marginRight;n+=+i.replace("px","")+ +o.replace("px","")}n=+n.toFixed(6)}return n||0},z=function(e,t,n){e&&"object"===Object(y.a)(e.style)&&(e.style[t]=n)},V=n("KQm4"),Q=n("Ff2n"),q=n("i8i4"),G=n("bdgK"),Y=n("uciX"),Z=n("8XRh"),J={adjustX:1,adjustY:1},$={topLeft:{points:["bl","tl"],overflow:J,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:J,offset:[0,7]},leftTop:{points:["tr","tl"],overflow:J,offset:[-4,0]},rightTop:{points:["tl","tr"],overflow:J,offset:[4,0]}},ee={topLeft:{points:["bl","tl"],overflow:J,offset:[0,-7]},bottomLeft:{points:["tl","bl"],overflow:J,offset:[0,7]},rightTop:{points:["tr","tl"],overflow:J,offset:[-4,0]},leftTop:{points:["tl","tr"],overflow:J,offset:[4,0]}},te=0,ne={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"},re=function(e,t,n){var i=B(t),o=e.getState();e.setState({defaultActiveFirst:Object(r.a)(Object(r.a)({},o.defaultActiveFirst),{},Object(f.a)({},i,n))})},ie=function(e){Object(a.a)(n,e);var t=Object(c.a)(n);function n(e){var o;Object(i.a)(this,n),(o=t.call(this,e)).onDestroy=function(e){o.props.onDestroy(e)},o.onKeyDown=function(e){var t=e.keyCode,n=o.menuInstance,r=o.props,i=r.isOpen,s=r.store;if(t===p.a.ENTER)return o.onTitleClick(e),re(s,o.props.eventKey,!0),!0;if(t===p.a.RIGHT)return i?n.onKeyDown(e):(o.triggerOpenChange(!0),re(s,o.props.eventKey,!0)),!0;if(t===p.a.LEFT){var a;if(!i)return;return(a=n.onKeyDown(e))||(o.triggerOpenChange(!1),a=!0),a}return!i||t!==p.a.UP&&t!==p.a.DOWN?void 0:n.onKeyDown(e)},o.onOpenChange=function(e){o.props.onOpenChange(e)},o.onPopupVisibleChange=function(e){o.triggerOpenChange(e,e?"mouseenter":"mouseleave")},o.onMouseEnter=function(e){var t=o.props,n=t.eventKey,r=t.onMouseEnter,i=t.store;re(i,o.props.eventKey,!1),r({key:n,domEvent:e})},o.onMouseLeave=function(e){var t=o.props,n=t.parentMenu,r=t.eventKey,i=t.onMouseLeave;n.subMenuInstance=Object(s.a)(o),i({key:r,domEvent:e})},o.onTitleMouseEnter=function(e){var t=o.props,n=t.eventKey,r=t.onItemHover,i=t.onTitleMouseEnter;r({key:n,hover:!0}),i({key:n,domEvent:e})},o.onTitleMouseLeave=function(e){var t=o.props,n=t.parentMenu,r=t.eventKey,i=t.onItemHover,a=t.onTitleMouseLeave;n.subMenuInstance=Object(s.a)(o),i({key:r,hover:!1}),a({key:r,domEvent:e})},o.onTitleClick=function(e){var t=Object(s.a)(o).props;t.onTitleClick({key:t.eventKey,domEvent:e}),"hover"!==t.triggerSubMenuAction&&(o.triggerOpenChange(!t.isOpen,"click"),re(t.store,o.props.eventKey,!1))},o.onSubMenuClick=function(e){"function"==typeof o.props.onClick&&o.props.onClick(o.addKeyPath(e))},o.onSelect=function(e){o.props.onSelect(e)},o.onDeselect=function(e){o.props.onDeselect(e)},o.getPrefixCls=function(){return"".concat(o.props.rootPrefixCls,"-submenu")},o.getActiveClassName=function(){return"".concat(o.getPrefixCls(),"-active")},o.getDisabledClassName=function(){return"".concat(o.getPrefixCls(),"-disabled")},o.getSelectedClassName=function(){return"".concat(o.getPrefixCls(),"-selected")},o.getOpenClassName=function(){return"".concat(o.props.rootPrefixCls,"-submenu-open")},o.saveMenuInstance=function(e){o.menuInstance=e},o.addKeyPath=function(e){return Object(r.a)(Object(r.a)({},e),{},{keyPath:(e.keyPath||[]).concat(o.props.eventKey)})},o.triggerOpenChange=function(e,t){var n=o.props.eventKey,r=function(){o.onOpenChange({key:n,item:Object(s.a)(o),trigger:t,open:e})};"mouseenter"===t?o.mouseenterTimeout=setTimeout((function(){r()}),0):r()},o.isChildrenSelected=function(){var e={find:!1};return function e(t,n,r){t&&!r.find&&l.Children.forEach(t,(function(t){if(t){var i=t.type;if(!i||!(i.isSubMenu||i.isMenuItem||i.isMenuItemGroup))return;-1!==n.indexOf(t.key)?r.find=!0:t.props.children&&e(t.props.children,n,r)}}))}(o.props.children,o.props.selectedKeys,e),e.find},o.isOpen=function(){return-1!==o.props.openKeys.indexOf(o.props.eventKey)},o.adjustWidth=function(){if(o.subMenuTitle&&o.menuInstance){var e=q.findDOMNode(o.menuInstance);e.offsetWidth>=o.subMenuTitle.offsetWidth||(e.style.minWidth="".concat(o.subMenuTitle.offsetWidth,"px"))}},o.saveSubMenuTitle=function(e){o.subMenuTitle=e},o.getBaseProps=function(){var e=Object(s.a)(o).props;return{mode:"horizontal"===e.mode?"vertical":e.mode,visible:o.props.isOpen,level:e.level+1,inlineIndent:e.inlineIndent,focusable:!1,onClick:o.onSubMenuClick,onSelect:o.onSelect,onDeselect:o.onDeselect,onDestroy:o.onDestroy,selectedKeys:e.selectedKeys,eventKey:"".concat(e.eventKey,"-menu-"),openKeys:e.openKeys,motion:e.motion,onOpenChange:o.onOpenChange,subMenuOpenDelay:e.subMenuOpenDelay,parentMenu:Object(s.a)(o),subMenuCloseDelay:e.subMenuCloseDelay,forceSubMenuRender:e.forceSubMenuRender,triggerSubMenuAction:e.triggerSubMenuAction,builtinPlacements:e.builtinPlacements,defaultActiveFirst:e.store.getState().defaultActiveFirst[B(e.eventKey)],multiple:e.multiple,prefixCls:e.rootPrefixCls,id:o.internalMenuId,manualRef:o.saveMenuInstance,itemIcon:e.itemIcon,expandIcon:e.expandIcon,direction:e.direction}},o.getMotion=function(e,t){var n=Object(s.a)(o).haveRendered,i=o.props,a=i.motion,c=i.rootPrefixCls;return Object(r.a)(Object(r.a)({},a),{},{leavedClassName:"".concat(c,"-hidden"),removeOnLeave:!1,motionAppear:n||!t||"inline"!==e})};var a=e.store,c=e.eventKey,u=a.getState().defaultActiveFirst;o.isRootMenu=!1;var h=!1;return u&&(h=u[c]),re(a,c,h),o}return Object(o.a)(n,[{key:"componentDidMount",value:function(){this.componentDidUpdate()}},{key:"componentDidUpdate",value:function(){var e=this,t=this.props,n=t.mode,r=t.parentMenu,i=t.manualRef;i&&i(this),"horizontal"===n&&r.isRootMenu&&this.props.isOpen&&(this.minWidthTimeout=setTimeout((function(){return e.adjustWidth()}),0))}},{key:"componentWillUnmount",value:function(){var e=this.props,t=e.onDestroy,n=e.eventKey;t&&t(n),this.minWidthTimeout&&clearTimeout(this.minWidthTimeout),this.mouseenterTimeout&&clearTimeout(this.mouseenterTimeout)}},{key:"renderChildren",value:function(e){var t=this,n=this.getBaseProps(),r=this.getMotion(n.mode,n.visible);if(this.haveRendered=!0,this.haveOpened=this.haveOpened||n.visible||n.forceSubMenuRender,!this.haveOpened)return l.createElement("div",null);var i=n.direction;return l.createElement(Z.default,Object.assign({visible:n.visible},r),(function(r){var o=r.className,s=r.style,a=m()("".concat(n.prefixCls,"-sub"),o,Object(f.a)({},"".concat(n.prefixCls,"-rtl"),"rtl"===i));return l.createElement(pe,Object.assign({},n,{id:t.internalMenuId,className:a,style:s}),e)}))}},{key:"render",value:function(){var e,t=Object(r.a)({},this.props),n=t.isOpen,i=this.getPrefixCls(),o="inline"===t.mode,s=m()(i,"".concat(i,"-").concat(t.mode),(e={},Object(f.a)(e,t.className,!!t.className),Object(f.a)(e,this.getOpenClassName(),n),Object(f.a)(e,this.getActiveClassName(),t.active||n&&!o),Object(f.a)(e,this.getDisabledClassName(),t.disabled),Object(f.a)(e,this.getSelectedClassName(),this.isChildrenSelected()),e));this.internalMenuId||(t.eventKey?this.internalMenuId="".concat(t.eventKey,"$Menu"):(te+=1,this.internalMenuId="$__$".concat(te,"$Menu")));var a={},c={},u={};t.disabled||(a={onMouseLeave:this.onMouseLeave,onMouseEnter:this.onMouseEnter},c={onClick:this.onTitleClick},u={onMouseEnter:this.onTitleMouseEnter,onMouseLeave:this.onTitleMouseLeave});var h={},d=t.direction;o&&("rtl"===d?h.paddingRight=t.inlineIndent*t.level:h.paddingLeft=t.inlineIndent*t.level);var p={};this.props.isOpen&&(p={"aria-owns":this.internalMenuId});var _=null;"horizontal"!==t.mode&&(_=this.props.expandIcon,"function"==typeof this.props.expandIcon&&(_=l.createElement(this.props.expandIcon,Object(r.a)({},this.props))));var v=l.createElement("div",Object.assign({ref:this.saveSubMenuTitle,style:h,className:"".concat(i,"-title"),role:"button"},u,c,{"aria-expanded":n},p,{"aria-haspopup":"true",title:"string"==typeof t.title?t.title:void 0}),t.title,_||l.createElement("i",{className:"".concat(i,"-arrow")})),b=this.renderChildren(t.children),g=t.parentMenu.isRootMenu?t.parentMenu.props.getPopupContainer:function(e){return e.parentNode},y=ne[t.mode],w=t.popupOffset?{offset:t.popupOffset}:{},S="inline"===t.mode?"":t.popupClassName;S+="rtl"===d?" ".concat(i,"-rtl"):"";var C=t.disabled,k=t.triggerSubMenuAction,E=t.subMenuOpenDelay,O=t.forceSubMenuRender,x=t.subMenuCloseDelay,A=t.builtinPlacements;U.forEach((function(e){return delete t[e]})),delete t.onClick;var j="rtl"===d?Object.assign({},ee,A):Object.assign({},$,A);return delete t.direction,l.createElement("li",Object.assign({},t,a,{className:s,role:"menuitem"}),o&&v,o&&b,!o&&l.createElement(Y.a,{prefixCls:i,popupClassName:m()("".concat(i,"-popup"),S),getPopupContainer:g,builtinPlacements:j,popupPlacement:y,popupVisible:n,popupAlign:w,popup:b,action:C?[]:[k],mouseEnterDelay:E,mouseLeaveDelay:x,onPopupVisibleChange:this.onPopupVisibleChange,forceRender:O},v))}}]),n}(l.Component);ie.defaultProps={onMouseEnter:X,onMouseLeave:X,onTitleMouseEnter:X,onTitleMouseLeave:X,onTitleClick:X,manualRef:X,mode:"vertical",title:""};var oe=Object(u.b)((function(e,t){var n=e.openKeys,r=e.activeKey,i=e.selectedKeys,o=t.eventKey,s=t.subMenuKey;return{isOpen:n.indexOf(o)>-1,active:r[s]===o,selectedKeys:i}}))(ie);oe.isSubMenu=!0;var se=oe,ae=function(e){Object(a.a)(n,e);var t=Object(c.a)(n);function n(){var e;return Object(i.a)(this,n),(e=t.apply(this,arguments)).resizeObserver=null,e.mutationObserver=null,e.originalTotalWidth=0,e.overflowedItems=[],e.menuItemSizes=[],e.cancelFrameId=null,e.state={lastVisibleIndex:void 0},e.getMenuItemNodes=function(){var t=e.props.prefixCls,n=q.findDOMNode(Object(s.a)(e));return n?[].slice.call(n.children).filter((function(e){return e.className.split(" ").indexOf("".concat(t,"-overflowed-submenu"))<0})):[]},e.getOverflowedSubMenuItem=function(t,n,i){var o=e.props,s=o.overflowedIndicator,a=o.level,c=o.mode,u=o.prefixCls,h=o.theme;if(1!==a||"horizontal"!==c)return null;var d=e.props.children[0].props,f=(d.children,d.title,d.style),p=Object(Q.a)(d,["children","title","style"]),_=Object(r.a)({},f),v="".concat(t,"-overflowed-indicator"),b="".concat(t,"-overflowed-indicator");0===n.length&&!0!==i?_=Object(r.a)(Object(r.a)({},_),{},{display:"none"}):i&&(_=Object(r.a)(Object(r.a)({},_),{},{visibility:"hidden",position:"absolute"}),v="".concat(v,"-placeholder"),b="".concat(b,"-placeholder"));var g=h?"".concat(u,"-").concat(h):"",m={};return U.forEach((function(e){void 0!==p[e]&&(m[e]=p[e])})),l.createElement(se,Object.assign({title:s,className:"".concat(u,"-overflowed-submenu"),popupClassName:g},m,{key:v,eventKey:b,disabled:!1,style:_}),n)},e.setChildrenWidthAndResize=function(){if("horizontal"===e.props.mode){var t=q.findDOMNode(Object(s.a)(e));if(t){var n=t.children;if(n&&0!==n.length){var r=t.children[n.length-1];z(r,"display","inline-block");var i=e.getMenuItemNodes(),o=i.filter((function(e){return e.className.split(" ").indexOf("menuitem-overflowed")>=0}));o.forEach((function(e){z(e,"display","inline-block")})),e.menuItemSizes=i.map((function(e){return W(e,!0)})),o.forEach((function(e){z(e,"display","none")})),e.overflowedIndicatorWidth=W(t.children[t.children.length-1],!0),e.originalTotalWidth=e.menuItemSizes.reduce((function(e,t){return e+t}),0),e.handleResize(),z(r,"display","none")}}}},e.handleResize=function(){if("horizontal"===e.props.mode){var t=q.findDOMNode(Object(s.a)(e));if(t){var n=W(t);e.overflowedItems=[];var r,i=0;e.originalTotalWidth>n+.5&&(r=-1,e.menuItemSizes.forEach((function(t){(i+=t)+e.overflowedIndicatorWidth<=n&&(r+=1)}))),e.setState({lastVisibleIndex:r})}}},e}return Object(o.a)(n,[{key:"componentDidMount",value:function(){var e=this;if(this.setChildrenWidthAndResize(),1===this.props.level&&"horizontal"===this.props.mode){var t=q.findDOMNode(this);if(!t)return;this.resizeObserver=new G.default((function(t){t.forEach((function(){var t=e.cancelFrameId;cancelAnimationFrame(t),e.cancelFrameId=requestAnimationFrame(e.setChildrenWidthAndResize)}))})),[].slice.call(t.children).concat(t).forEach((function(t){e.resizeObserver.observe(t)})),"undefined"!=typeof MutationObserver&&(this.mutationObserver=new MutationObserver((function(){e.resizeObserver.disconnect(),[].slice.call(t.children).concat(t).forEach((function(t){e.resizeObserver.observe(t)})),e.setChildrenWidthAndResize()})),this.mutationObserver.observe(t,{attributes:!1,childList:!0,subTree:!1}))}}},{key:"componentWillUnmount",value:function(){this.resizeObserver&&this.resizeObserver.disconnect(),this.mutationObserver&&this.mutationObserver.disconnect(),cancelAnimationFrame(this.cancelFrameId)}},{key:"renderChildren",value:function(e){var t=this,n=this.state.lastVisibleIndex;return(e||[]).reduce((function(r,i,o){var s=i;if("horizontal"===t.props.mode){var a=t.getOverflowedSubMenuItem(i.props.eventKey,[]);void 0!==n&&-1!==t.props.className.indexOf("".concat(t.props.prefixCls,"-root"))&&(o>n&&(s=l.cloneElement(i,{style:{display:"none"},eventKey:"".concat(i.props.eventKey,"-hidden"),className:"".concat("menuitem-overflowed")})),o===n+1&&(t.overflowedItems=e.slice(n+1).map((function(e){return l.cloneElement(e,{key:e.props.eventKey,mode:"vertical-left"})})),a=t.getOverflowedSubMenuItem(i.props.eventKey,t.overflowedItems)));var c=[].concat(Object(V.a)(r),[a,s]);return o===e.length-1&&c.push(t.getOverflowedSubMenuItem(i.props.eventKey,[],!0)),c}return[].concat(Object(V.a)(r),[s])}),[])}},{key:"render",value:function(){var e=this.props,t=(e.visible,e.prefixCls,e.overflowedIndicator,e.mode,e.level,e.tag),n=e.children,r=(e.theme,Object(Q.a)(e,["visible","prefixCls","overflowedIndicator","mode","level","tag","children","theme"])),i=t;return l.createElement(i,Object.assign({},r),this.renderChildren(n))}}]),n}(l.Component);ae.defaultProps={tag:"div",className:""};var ce=ae;function le(e,t,n){var i=e.getState();e.setState({activeKey:Object(r.a)(Object(r.a)({},i.activeKey),{},Object(f.a)({},t,n))})}function ue(e){return e.eventKey||"0-menu-"}function he(e,t){var n,r=t,i=e.children,o=e.eventKey;if(r&&(H(i,(function(e,t){e&&e.props&&!e.props.disabled&&r===N(e,o,t)&&(n=!0)})),n))return r;return r=null,e.defaultActiveFirst?(H(i,(function(e,t){r||!e||e.props.disabled||(r=N(e,o,t))})),r):r}function de(e){if(e){var t=this.instanceArray.indexOf(e);-1!==t?this.instanceArray[t]=e:this.instanceArray.push(e)}}var fe=function(e){Object(a.a)(n,e);var t=Object(c.a)(n);function n(e){var o;return Object(i.a)(this,n),(o=t.call(this,e)).onKeyDown=function(e,t){var n,r=e.keyCode;if(o.getFlatInstanceArray().forEach((function(t){t&&t.props.active&&t.onKeyDown&&(n=t.onKeyDown(e))})),n)return 1;var i=null;return r!==p.a.UP&&r!==p.a.DOWN||(i=o.step(r===p.a.UP?-1:1)),i?(e.preventDefault(),le(o.props.store,ue(o.props),i.props.eventKey),"function"==typeof t&&t(i),1):void 0},o.onItemHover=function(e){var t=e.key,n=e.hover;le(o.props.store,ue(o.props),n?t:null)},o.onDeselect=function(e){o.props.onDeselect(e)},o.onSelect=function(e){o.props.onSelect(e)},o.onClick=function(e){o.props.onClick(e)},o.onOpenChange=function(e){o.props.onOpenChange(e)},o.onDestroy=function(e){o.props.onDestroy(e)},o.getFlatInstanceArray=function(){return o.instanceArray},o.step=function(e){var t=o.getFlatInstanceArray(),n=o.props.store.getState().activeKey[ue(o.props)],r=t.length;if(!r)return null;e<0&&(t=t.concat().reverse());var i=-1;if(t.every((function(e,t){return!e||e.props.eventKey!==n||(i=t,!1)})),o.props.defaultActiveFirst||-1===i||(s=t.slice(i,r-1)).length&&!s.every((function(e){return!!e.props.disabled}))){var s,a=(i+1)%r,c=a;do{var l=t[c];if(l&&!l.props.disabled)return l;c=(c+1)%r}while(c!==a);return null}},o.renderCommonMenuItem=function(e,t,n){var i=o.props.store.getState(),a=Object(s.a)(o).props,c=N(e,a.eventKey,t),u=e.props;if(!u||"string"==typeof e.type)return e;var h=c===i.activeKey,d=Object(r.a)(Object(r.a)({mode:u.mode||a.mode,level:a.level,inlineIndent:a.inlineIndent,renderMenuItem:o.renderMenuItem,rootPrefixCls:a.prefixCls,index:t,parentMenu:a.parentMenu,manualRef:u.disabled?void 0:Object(_.a)(e.ref,de.bind(Object(s.a)(o))),eventKey:c,active:!u.disabled&&h,multiple:a.multiple,onClick:function(e){(u.onClick||X)(e),o.onClick(e)},onItemHover:o.onItemHover,motion:a.motion,subMenuOpenDelay:a.subMenuOpenDelay,subMenuCloseDelay:a.subMenuCloseDelay,forceSubMenuRender:a.forceSubMenuRender,onOpenChange:o.onOpenChange,onDeselect:o.onDeselect,onSelect:o.onSelect,builtinPlacements:a.builtinPlacements,itemIcon:u.itemIcon||o.props.itemIcon,expandIcon:u.expandIcon||o.props.expandIcon},n),{},{direction:a.direction});return("inline"===a.mode||F.any)&&(d.triggerSubMenuAction="click"),l.cloneElement(e,d)},o.renderMenuItem=function(e,t,n){if(!e)return null;var r=o.props.store.getState(),i={openKeys:r.openKeys,selectedKeys:r.selectedKeys,triggerSubMenuAction:o.props.triggerSubMenuAction,subMenuKey:n};return o.renderCommonMenuItem(e,t,i)},e.store.setState({activeKey:Object(r.a)(Object(r.a)({},e.store.getState().activeKey),{},Object(f.a)({},e.eventKey,he(e,e.activeKey)))}),o.instanceArray=[],o}return Object(o.a)(n,[{key:"componentDidMount",value:function(){this.props.manualRef&&this.props.manualRef(this)}},{key:"shouldComponentUpdate",value:function(e){return this.props.visible||e.visible||this.props.className!==e.className||!b()(this.props.style,e.style)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n="activeKey"in t?t.activeKey:t.store.getState().activeKey[ue(t)],r=he(t,n);if(r!==n)le(t.store,ue(t),r);else if("activeKey"in e){r!==he(e,e.activeKey)&&le(t.store,ue(t),r)}}},{key:"render",value:function(){var e=this,t=Object(d.a)({},this.props);this.instanceArray=[];var n={className:m()(t.prefixCls,t.className,"".concat(t.prefixCls,"-").concat(t.mode)),role:t.role||"menu"};t.id&&(n.id=t.id),t.focusable&&(n.tabIndex=0,n.onKeyDown=this.onKeyDown);var r=t.prefixCls,i=t.eventKey,o=t.visible,s=t.level,a=t.mode,c=t.overflowedIndicator,u=t.theme;return U.forEach((function(e){return delete t[e]})),delete t.onClick,l.createElement(ce,Object.assign({},t,{prefixCls:r,mode:a,tag:"ul",level:s,theme:u,visible:o,overflowedIndicator:c},n),l.Children.map(t.children,(function(t,n){return e.renderMenuItem(t,n,i||"0-menu-")})))}}]),n}(l.Component);fe.defaultProps={prefixCls:"rc-menu",className:"",mode:"vertical",level:1,inlineIndent:24,visible:!0,focusable:!0,style:{},manualRef:X};var pe=Object(u.b)()(fe),_e=n("Kwbf");function ve(e,t,n){var r=e.prefixCls,i=e.motion,o=e.defaultMotions,s=void 0===o?{}:o,a=e.openAnimation,c=e.openTransitionName,l=t.switchingModeFromInline;if(i)return i;if("object"===Object(y.a)(a)&&a)Object(_e.a)(!1,"Object type of `openAnimation` is removed. Please use `motion` instead.");else if("string"==typeof a)return{motionName:"".concat(r,"-open-").concat(a)};if(c)return{motionName:c};var u=s[n];return u||(l?null:s.other)}var be=function(e){Object(a.a)(n,e);var t=Object(c.a)(n);function n(e){var o;Object(i.a)(this,n),(o=t.call(this,e)).inlineOpenKeys=[],o.onSelect=function(e){var t=Object(s.a)(o).props;if(t.selectable){var n=o.store.getState().selectedKeys,i=e.key;n=t.multiple?n.concat([i]):[i],"selectedKeys"in t||o.store.setState({selectedKeys:n}),t.onSelect(Object(r.a)(Object(r.a)({},e),{},{selectedKeys:n}))}},o.onClick=function(e){var t=o.getRealMenuMode(),n=Object(s.a)(o),r=n.store,i=n.props.onOpenChange;"inline"===t||"openKeys"in o.props||(r.setState({openKeys:[]}),i([])),o.props.onClick(e)},o.onKeyDown=function(e,t){o.innerMenu.getWrappedInstance().onKeyDown(e,t)},o.onOpenChange=function(e){var t=Object(s.a)(o).props,n=o.store.getState().openKeys.concat(),r=!1,i=function(e){var t=!1;if(e.open)(t=-1===n.indexOf(e.key))&&n.push(e.key);else{var i=n.indexOf(e.key);(t=-1!==i)&&n.splice(i,1)}r=r||t};Array.isArray(e)?e.forEach(i):i(e),r&&("openKeys"in o.props||o.store.setState({openKeys:n}),t.onOpenChange(n))},o.onDeselect=function(e){var t=Object(s.a)(o).props;if(t.selectable){var n=o.store.getState().selectedKeys.concat(),i=e.key,a=n.indexOf(i);-1!==a&&n.splice(a,1),"selectedKeys"in t||o.store.setState({selectedKeys:n}),t.onDeselect(Object(r.a)(Object(r.a)({},e),{},{selectedKeys:n}))}},o.onMouseEnter=function(e){o.restoreModeVerticalFromInline();var t=o.props.onMouseEnter;t&&t(e)},o.onTransitionEnd=function(e){var t="width"===e.propertyName&&e.target===e.currentTarget,n=e.target.className,r="[object SVGAnimatedString]"===Object.prototype.toString.call(n)?n.animVal:n,i="font-size"===e.propertyName&&r.indexOf("anticon")>=0;(t||i)&&o.restoreModeVerticalFromInline()},o.setInnerMenu=function(e){o.innerMenu=e},o.isRootMenu=!0;var a=e.defaultSelectedKeys,c=e.defaultOpenKeys;return"selectedKeys"in e&&(a=e.selectedKeys||[]),"openKeys"in e&&(c=e.openKeys||[]),o.store=Object(u.c)({selectedKeys:a,openKeys:c,activeKey:{"0-menu-":he(e,e.activeKey)}}),o.state={switchingModeFromInline:!1},o}return Object(o.a)(n,[{key:"componentDidMount",value:function(){this.updateMiniStore(),this.updateMenuDisplay()}},{key:"componentDidUpdate",value:function(e){this.updateOpentKeysWhenSwitchMode(e),this.updateMiniStore();var t=this.props,n=t.siderCollapsed,r=t.inlineCollapsed,i=t.onOpenChange;(!e.inlineCollapsed&&r||!e.siderCollapsed&&n)&&i([]),this.updateMenuDisplay()}},{key:"updateOpentKeysWhenSwitchMode",value:function(e){var t=this.props,n=this.store,r=this.inlineOpenKeys,i=n.getState(),o={};"inline"===e.mode&&"inline"!==t.mode&&this.setState({switchingModeFromInline:!0}),"openKeys"in t||((t.inlineCollapsed&&!e.inlineCollapsed||t.siderCollapsed&&!e.siderCollapsed)&&(this.setState({switchingModeFromInline:!0}),this.inlineOpenKeys=i.openKeys.concat(),o.openKeys=[]),(!t.inlineCollapsed&&e.inlineCollapsed||!t.siderCollapsed&&e.siderCollapsed)&&(o.openKeys=r,this.inlineOpenKeys=[])),Object.keys(o).length&&n.setState(o)}},{key:"updateMenuDisplay",value:function(){var e=this.props.collapsedWidth,t=this.store,n=this.prevOpenKeys;this.getInlineCollapsed()&&(0===e||"0"===e||"0px"===e)?(this.prevOpenKeys=t.getState().openKeys.concat(),this.store.setState({openKeys:[]})):n&&(this.store.setState({openKeys:n}),this.prevOpenKeys=null)}},{key:"getRealMenuMode",value:function(){var e=this.props.mode,t=this.state.switchingModeFromInline,n=this.getInlineCollapsed();return t&&n?"inline":n?"vertical":e}},{key:"getInlineCollapsed",value:function(){var e=this.props,t=e.inlineCollapsed,n=e.siderCollapsed;return void 0!==n?n:t}},{key:"restoreModeVerticalFromInline",value:function(){this.state.switchingModeFromInline&&this.setState({switchingModeFromInline:!1})}},{key:"updateMiniStore",value:function(){"selectedKeys"in this.props&&this.store.setState({selectedKeys:this.props.selectedKeys||[]}),"openKeys"in this.props&&this.store.setState({openKeys:this.props.openKeys||[]})}},{key:"render",value:function(){var e=Object(r.a)({},Object(h.default)(this.props,["collapsedWidth","siderCollapsed","defaultMotions"])),t=this.getRealMenuMode();return e.className+=" ".concat(e.prefixCls,"-root"),"rtl"===e.direction&&(e.className+=" ".concat(e.prefixCls,"-rtl")),delete(e=Object(r.a)(Object(r.a)({},e),{},{mode:t,onClick:this.onClick,onOpenChange:this.onOpenChange,onDeselect:this.onDeselect,onSelect:this.onSelect,onMouseEnter:this.onMouseEnter,onTransitionEnd:this.onTransitionEnd,parentMenu:this,motion:ve(this.props,this.state,t)})).openAnimation,delete e.openTransitionName,l.createElement(u.a,{store:this.store},l.createElement(pe,Object.assign({},e,{ref:this.setInnerMenu}),this.props.children))}}]),n}(l.Component);be.defaultProps={selectable:!0,onClick:X,onSelect:X,onOpenChange:X,onDeselect:X,defaultSelectedKeys:[],defaultOpenKeys:[],subMenuOpenDelay:.1,subMenuCloseDelay:.1,triggerSubMenuAction:"hover",prefixCls:"rc-menu",className:"",mode:"vertical",style:{},builtinPlacements:{},overflowedIndicator:l.createElement("span",null,"···")};var ge=be,me=function(e){Object(a.a)(n,e);var t=Object(c.a)(n);function n(){var e;return Object(i.a)(this,n),(e=t.apply(this,arguments)).onKeyDown=function(t){if(t.keyCode===p.a.ENTER)return e.onClick(t),!0},e.onMouseLeave=function(t){var n=e.props,r=n.eventKey,i=n.onItemHover,o=n.onMouseLeave;i({key:r,hover:!1}),o({key:r,domEvent:t})},e.onMouseEnter=function(t){var n=e.props,r=n.eventKey,i=n.onItemHover,o=n.onMouseEnter;i({key:r,hover:!0}),o({key:r,domEvent:t})},e.onClick=function(t){var n=e.props,r=n.eventKey,i=n.multiple,o=n.onClick,a=n.onSelect,c=n.onDeselect,l=n.isSelected,u={key:r,keyPath:[r],item:Object(s.a)(e),domEvent:t};o(u),i?l?c(u):a(u):l||a(u)},e.saveNode=function(t){e.node=t},e}return Object(o.a)(n,[{key:"componentDidMount",value:function(){this.callRef()}},{key:"componentDidUpdate",value:function(){this.callRef()}},{key:"componentWillUnmount",value:function(){var e=this.props;e.onDestroy&&e.onDestroy(e.eventKey)}},{key:"getPrefixCls",value:function(){return"".concat(this.props.rootPrefixCls,"-item")}},{key:"getActiveClassName",value:function(){return"".concat(this.getPrefixCls(),"-active")}},{key:"getSelectedClassName",value:function(){return"".concat(this.getPrefixCls(),"-selected")}},{key:"getDisabledClassName",value:function(){return"".concat(this.getPrefixCls(),"-disabled")}},{key:"callRef",value:function(){this.props.manualRef&&this.props.manualRef(this)}},{key:"render",value:function(){var e,t=Object(r.a)({},this.props),n=m()(this.getPrefixCls(),t.className,(e={},Object(f.a)(e,this.getActiveClassName(),!t.disabled&&t.active),Object(f.a)(e,this.getSelectedClassName(),t.isSelected),Object(f.a)(e,this.getDisabledClassName(),t.disabled),e)),i=Object(r.a)(Object(r.a)({},t.attribute),{},{title:"string"==typeof t.title?t.title:void 0,className:n,role:t.role||"menuitem","aria-disabled":t.disabled});"option"===t.role?i=Object(r.a)(Object(r.a)({},i),{},{role:"option","aria-selected":t.isSelected}):null!==t.role&&"none"!==t.role||(i.role="none");var o={onClick:t.disabled?null:this.onClick,onMouseLeave:t.disabled?null:this.onMouseLeave,onMouseEnter:t.disabled?null:this.onMouseEnter},s=Object(r.a)({},t.style);"inline"===t.mode&&("rtl"===t.direction?s.paddingRight=t.inlineIndent*t.level:s.paddingLeft=t.inlineIndent*t.level),U.forEach((function(e){return delete t[e]})),delete t.direction;var a=this.props.itemIcon;return"function"==typeof this.props.itemIcon&&(a=l.createElement(this.props.itemIcon,this.props)),l.createElement("li",Object.assign({},Object(h.default)(t,["onClick","onMouseEnter","onMouseLeave","onSelect"]),i,o,{style:s,ref:this.saveNode}),t.children,a)}}]),n}(l.Component);me.isMenuItem=!0,me.defaultProps={onSelect:X,onMouseEnter:X,onMouseLeave:X,manualRef:X};var ye=Object(u.b)((function(e,t){var n=e.activeKey,r=e.selectedKeys,i=t.eventKey;return{active:n[t.subMenuKey]===i,isSelected:-1!==r.indexOf(i)}}))(me),we=function(e){Object(a.a)(n,e);var t=Object(c.a)(n);function n(){var e;return Object(i.a)(this,n),(e=t.apply(this,arguments)).renderInnerMenuItem=function(t){var n=e.props;return(0,n.renderMenuItem)(t,n.index,e.props.subMenuKey)},e}return Object(o.a)(n,[{key:"render",value:function(){var e=Object(d.a)({},this.props),t=e.className,n=void 0===t?"":t,r=e.rootPrefixCls,i="".concat(r,"-item-group-title"),o="".concat(r,"-item-group-list"),s=e.title,a=e.children;return U.forEach((function(t){return delete e[t]})),delete e.onClick,delete e.direction,l.createElement("li",Object.assign({},e,{className:"".concat(n," ").concat(r,"-item-group")}),l.createElement("div",{className:i,title:"string"==typeof s?s:void 0},s),l.createElement("ul",{className:o},l.Children.map(a,this.renderInnerMenuItem)))}}]),n}(l.Component);we.isMenuItemGroup=!0,we.defaultProps={disabled:!0};var Se=we,Ce=function(e){var t=e.className,n=e.rootPrefixCls,r=e.style;return l.createElement("li",{className:"".concat(t," ").concat(n,"-item-divider"),style:r})};Ce.defaultProps={disabled:!0,className:"",style:{}};var ke=Ce;t.e=ge},"1q3G": /*!***********************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/zlib/zstream.js ***! \***********************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},"34/K": /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/decoders/raw.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e,t){for(var n=0;n>0&3)/3,f[4*p+1]=255*(u[h+p]>>2&3)/3,f[4*p+2]=255*(u[h+p]>>4&3)/3,f[4*p+4]=0;u=f,h=0}return o.blitImage(e,c,n,l,u,h),i.rQskipBytes(l*a),this._lines-=l,!(this._lines>0)}}])&&r(t.prototype,n),i&&r(t,i),e}();t.default=i},3690: /*!***********************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/decoders/hextile.js ***! \***********************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(n,s,a):n[s]=e[s]}n.default=e,t&&t.set(e,n);return n}(n(/*! ../util/logging.js */"Lo0S"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}function s(e,t){for(var n=0;n0;){var c=1;if(o.rQwait("HEXTILE",c))return!1;var l=o.rQ,u=o.rQi,h=l[u];if(h>30)throw new Error("Illegal hextile subencoding (subencoding: "+h+")");var d=this._totalTiles-this._tiles,f=e+d%this._tilesX*16,p=t+16*Math.floor(d/this._tilesX),_=Math.min(16,e+n-f),v=Math.min(16,t+r-p);if(1&h)c+=_*v*4;else if(2&h&&(c+=4),4&h&&(c+=4),8&h){if(c++,o.rQwait("HEXTILE",c))return!1;var b=l[u+c-1];c+=16&h?6*b:2*b}if(o.rQwait("HEXTILE",c))return!1;if(u++,0===h)1&this._lastsubencoding?i.Debug(" Ignoring blank after RAW"):s.fillRect(f,p,_,v,this._background);else if(1&h)s.blitImage(f,p,_,v,l,u),u+=c-1;else{if(2&h&&(this._background=[l[u],l[u+1],l[u+2],l[u+3]],u+=4),4&h&&(this._foreground=[l[u],l[u+1],l[u+2],l[u+3]],u+=4),s.startTile(f,p,_,v,this._background),8&h){var g=l[u];u++;for(var m=0;m>4,C=15&w,k=l[++u];u++;var E=1+(k>>4),O=1+(15&k);s.subTile(S,C,E,O,y)}}s.finishTile()}o.rQi=u,this._lastsubencoding=h,this._tiles--}return!0}}])&&s(t.prototype,n),r&&s(t,r),e}();t.default=a},"3MsV": /*!**********************************************************************!*\ !*** ./src/pages/Innovation/Tasks/vnc-view/clipboard-box/index.less ***! \**********************************************************************/ /*! no static exports found */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){},"4pCv": /*!***********************************************************!*\ !*** ./src/pages/Innovation/Tasks/index.jsx + 13 modules ***! \***********************************************************/ /*! exports provided: default */ /*! all exports used */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/ExclamationCircleOutlined.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/LoadingOutlined.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@ant-design/icons/es/icons/PoweroffOutlined.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@novnc/novnc/lib/rfb.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/defineProperty.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/Jupyter/index.less?modules (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/data-sets/index.less?modules (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/vnc-view/vnc-panel/index.less?modules (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/xterm-panel/index.less?modules (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/.umi-production/core/umiExports.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/Exercise/recordScreen.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/MultiUpload/index.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/Spinner/index.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/mediator.js */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/modal.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/timer-panel/index.jsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/components/useInterval.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Detail/components/DataSetPane/index.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/service/exercise.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/service/innovation.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/service/task.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/utils/env.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/utils/fetch.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/utils/fullscreen.ts */ /*! ModuleConcatenation bailout: Cannot concat with ./src/utils/util.tsx */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/header/data.png (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/header/tool.png (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/resize-enlarge.png (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./src/pages/Innovation/Tasks/resize-small.png (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/button/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/col/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/col/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/drawer/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/drawer/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/form/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/form/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input-number/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input-number/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/input/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/message/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/modal/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/modal/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/pagination/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/pagination/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/progress/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/progress/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/row/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/row/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/statistic/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/statistic/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/tooltip/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/tooltip/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/tree/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/antd/es/tree/style/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/js-base64/base64.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/moment/moment.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-copy-to-clipboard/lib/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-router-dom/esm/react-router-dom.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react-router/esm/react-router.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/resize-observer-polyfill/dist/ResizeObserver.es.js (<- Module uses injected variables (global)) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/xterm/lib/xterm.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";n.r(t);var r,i,o,s=n("oBTY"),a=(n("bbsP"),n("/wGt")),c=n("jrin"),l=(n("2qtc"),n("kLXV")),u=(n("miYZ"),n("tsqr")),h=n("9og8"),d=n("tJVT"),f=n("PpiC"),p=n("k1fw"),_=(n("ozfa"),n("MJZm")),v=n("WmNS"),b=n.n(v),g=n("q1tI"),m=n.n(g),y=n("Ty5D"),w=n("9kvl"),S=(n("BUUv"),n("IxHN")),C=n("M8RZ"),k=(n("giR+"),n("fyUT")),E=(n("5NDa"),n("5rEg")),O=(n("+L6B"),n("2/Rp")),x=(n("y8nQ"),n("Vl3Y")),A=(n("aHsQ"),n("sGsY")),j=n("55Ip"),L=(n("6/vW"),n("SFBS"),n("14J3"),n("BMrR")),R=(n("jCWc"),n("kPKH")),M=(n("lOMy"),n("GIiI")),T=n("P5Jw"),D=n("vS10"),P=n("RCxd"),K=n("500L"),I=n("m3rI"),F=n("ErOA"),X=n("1vsH"),N=Object(g.forwardRef)((function(e,t){e.time;console.log("ScreenRecord:",t);var n=Object(g.useRef)(),r=Object(g.useState)(),i=Object(d.a)(r,2),o=(i[0],i[1],Object(g.useRef)()),s=[];function a(){return(a=Object(h.a)(b.a.mark((function e(t,n){var r,i;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=[],e.next=3,new MediaRecorder(t);case 3:(i=e.sent).ondataavailable=function(e){r.push(e.data)},i.start(),o.current=i,window.recorderRefs=i,i.addEventListener("stop",(function(e){var t=URL.createObjectURL(r[0],{type:"video/mp4"});Object(X.v)("xxx.webm",t)}));case 9:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function c(){window.recorderRefs?(n.current.srcObject.getTracks().forEach((function(e){e.stop()})),window.recorderRefs.addEventListener("dataavailable",(function(e){var t=URL.createObjectURL(e.data,{type:"video/mp4"});Object(X.v)("屏幕录制视频.webm",t)}))):u.b.warn("您还没有开启视频录制,请先去录制视频吧!")}function l(){navigator.mediaDevices.getDisplayMedia({video:!0,audio:!0}).then((function(e){return n.current.srcObject=e,s.push(e),n.current.captureStream=n.current.captureStream||n.current.mozCaptureStream,new Promise((function(e){return n.current.onplaying=e}))})).then((function(){return function(e,t){return a.apply(this,arguments)}(n.current.captureStream(),2e3)})).then((function(e){})).catch((function(e){"NotFoundError"===e.name?u.b.warn("找不到摄像头或麦克风。无法录制."):u.b.warn(e.name)}))}return Object(g.useImperativeHandle)(t,(function(){return{startScreenRecord:l,downloadFile:c}})),m.a.createElement("div",{style:{position:"absolute",top:"0",zIndex:-1}},m.a.createElement("video",{onPause:function(){},width:"60",height:"120",autoPlay:!0,muted:!0,ref:n}))})),B=function(e){var t=e.className,n=(e.mirror_description,e.git_url),r=(e.difficulty,e.task_pass,e.test_set_permission,e.onVncAction),i=e.shixun,o=e.window_vnc_url,s=e.linux_vnc,a=e.vnc_url,c=e.unity_3d_routes,f=Object(y.i)(),p=Object(g.useState)("8082"),_=Object(d.a)(p,2),v=_[0],w=_[1],S=Object(g.useState)(!1),C=Object(d.a)(S,2),k=C[0],x=C[1],A=Object(g.useRef)(),j=o?"C:/Windows/AppReadiness/userfiles":"/data/workspace/userfiles";console.log("recordRef:",A);var B=function(){var e=Object(h.a)(b.a.mark((function e(){var t,n,r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return x(!0),e.next=3,Object(F.a)("/api/tasks/".concat(f.taskId,"/port_proxy"),{method:"post",body:{port:v}});case 3:null!=(n=e.sent)&&null!==(t=n.data)&&void 0!==t&&t.url&&Object(X.Q)(null==n||null===(r=n.data)||void 0===r?void 0:r.url),x(!1);case 6:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return m.a.createElement("div",{className:"tpi-code-setting ".concat(t),style:{height:"calc(100vh - 54px )"}},m.a.createElement("h3",null,"功能"),m.a.createElement("section",null,m.a.createElement("a",{id:"full-screen",title:"全屏",className:"file-item action",onClick:function(){r("full-screen")}}," ",m.a.createElement("i",{className:"iconfont icon-quanping"}),"开启 / 退出全屏 "),!c&&m.a.createElement(m.a.Fragment,null,m.a.createElement("a",{id:"reset-task",onClick:function(){return r("reset-task")},className:"file-item action",title:"重置环境"}," ",m.a.createElement("i",{className:"iconfont icon-zhongzhishixun"}),"重置环境 "),m.a.createElement("a",{onClick:function(){l.a.info({title:"文件上传",icon:null,okText:"关闭",width:600,centered:!0,content:m.a.createElement("div",{className:"pt10"},m.a.createElement(K.b,{isDragger:!0,maxSize:20,additionalText:'默认存放目录路径为"'.concat(j,'"'),action:"".concat(I.a.API_SERVER,"/api/sci/projects/").concat(f.taskId,"/upload_file.json?debug=admin"),onChange:function(e){e.some((function(e){var t;return 0===(null===(t=e.response)||void 0===t?void 0:t.status)}))&&(l.a.destroyAll(),u.b.info("文件上传成功")),console.log("fileList:",e)}}))})},className:"file-item action",title:"上传文件"}," ",m.a.createElement("i",{className:"iconfont icon-shangchuanshipin1"}),"上传文件"),m.a.createElement("a",{onClick:function(){var e;l.a.confirm({title:"下载代码",centered:!0,width:600,content:"代码下载功能:将“".concat(j,"”目录进行打包并下载"),onOk:(e=Object(h.a)(b.a.mark((function e(){return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(F.a)("/api/sci/projects/".concat(f.taskId,"/download_file.json?debug=admin"),{method:"post",headers:{responseType:"arraybuffer",Accept:"application/vnd.ms-excel;charset=utf-8"}});case 2:return e.abrupt("return",!0);case 3:case"end":return e.stop()}}),e)}))),function(){return e.apply(this,arguments)})})},className:"file-item action",title:"下载文件"}," ",m.a.createElement("i",{className:"iconfont icon-xiazai3"}),"下载文件"),m.a.createElement("a",{onClick:function(){var e,t;null===(e=A.current)||void 0===e||null===(t=e.startScreenRecord)||void 0===t||t.call(e)},className:"file-item action",title:"屏幕录制"}," ",m.a.createElement("i",{className:"iconfont icon-jiaruketang1"}),"屏幕录制"),(o||s||a||2===(null==i?void 0:i.hide_code))&&m.a.createElement(m.a.Fragment,null,m.a.createElement("a",{className:"file-item action w100",title:"服务预览"}," ",m.a.createElement("i",{className:"iconfont icon-suanfasheji"}),m.a.createElement(L.a,{align:"middle",className:"w100"},m.a.createElement(R.a,{flex:"1",onClick:B},m.a.createElement(O.a,{type:"text",loading:k},m.a.createElement("span",{style:{color:"#ddd",marginLeft:-11}},"服务预览"))),m.a.createElement(R.a,null,m.a.createElement("a",{href:"javascript:;",onClick:B,className:"c-blue"},"端口号")," ",m.a.createElement(E.a,{onChange:function(e){return w(e.target.value)},style:{width:50},value:v}))))),o&&m.a.createElement("a",{id:"reset-task",onClick:function(){var e;l.a.confirm({title:"重启云主机",icon:m.a.createElement(P.a,null),content:"您确定要重启云主机吗?",centered:!0,okText:"确定",cancelText:"取消",onOk:(e=Object(h.a)(b.a.mark((function e(){var t;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(D.f)({identifier:f.taskId});case 2:return 0===(null==(t=e.sent)?void 0:t.status)&&u.b.info("重启成功"),e.abrupt("return","");case 5:case"end":return e.stop()}}),e)}))),function(){return e.apply(this,arguments)})})},className:"file-item action",title:"重启云主机"}," ",m.a.createElement(M.a,{style:{marginRight:21,color:"#FFF"},className:"c-white font16"}),"重启云主机 "),n?m.a.createElement(T.CopyToClipboard,{text:n,onCopy:function(){return u.b.success("复制成功")}},m.a.createElement("a",{id:"copy-git",title:"复制版本库地址",className:"file-item action"}," ",m.a.createElement("i",{className:"iconfont icon-fuzhibanbenkudizhi1"}),"复制版本库地址 ")):null)),m.a.createElement(N,{ref:A}))},H=n("9VGf"),U=(n("DjyN"),n("NUBc")),W=(n("5Dmo"),n("3S7+")),z=n("JJs0"),V=n.n(z),Q=null!==(r=Object(X.G)())&&void 0!==r&&r.homework_common_id?{homework_common_id:null===(i=Object(X.G)())||void 0===i?void 0:i.homework_common_id}:{};function q(e,t,n){return Object(F.c)("tasks/".concat(e,"/star.json?shixun_id=").concat(t,"&star=").concat(n))}function G(e,t){return Object(F.c)("tasks/".concat(e,"/rep_content.json"),Object(p.a)(Object(p.a)({},t),Q))}function Y(e,t){return Object(F.f)("myshixuns/".concat(e,"/update_file.json"),t)}function Z(e,t){return Object(F.f)("myshixuns/".concat(e,"/reset_repository.json"),t)}function J(e){return Object(F.f)("tasks/".concat(e,"/plus_or_cancel_praise.json"))}function $(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Object(F.f)("myshixuns/".concat(e,"/repository.json"),t)}function ee(e){return te.apply(this,arguments)}function te(){return(te=Object(h.a)(b.a.mark((function e(t){var n;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(F.f)("/sci/projects/".concat(t,"/delete_pod.json"));case 2:if(!((null==(n=e.sent)?void 0:n.status)>=0)){e.next=5;break}return e.abrupt("return",Object(F.f)("/sci/projects/".concat(t,"/start_environment.json"),Q));case 5:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function ne(e,t,n){return Object(F.f)("tasks/".concat(e,"/set_games_status.json"),{result:t,data:n})}function re(e){return Object(F.f)("/sci/projects/".concat(e,"/extend_release.json"))}function ie(e,t){return Object(F.f)("/sci/projects/".concat(e,"/save_mirror.json"),Object(p.a)({},t))}!function(e){e.Classrooms="classrooms",e.Shixuns="shixuns",e.Paths="paths",e.Projects="projects",e.Videos="videos",e.Topics="topics",e.Teach="teach-group"}(o||(o={}));var oe=Object(w.a)((function(e){var t=e.user,n=e.userDetail,r=e.loading;return{user:t,userDetail:n,shixunsDetail:e.shixunsDetail,globalSetting:e.globalSetting,loading:r.models.index}}))((function(e){e.userDetail,e.user,e.globalSetting,e.loading,e.dispatch,e.onClose,e.shixun;var t=Object(f.a)(e,["userDetail","user","globalSetting","loading","dispatch","onClose","shixun"]),n=Object(y.i)(),r=Object(g.useState)([]),i=Object(d.a)(r,2),o=i[0],a=i[1],c=Object(g.useState)(""),l=Object(d.a)(c,2),_=l[0],v=l[1],w=Object(g.useState)(0),S=Object(d.a)(w,2),C=S[0],k=S[1],E=Object(g.useState)(Object(p.a)({page:1,limit:20},n)),O=Object(d.a)(E,2),x=O[0];O[1],Object(g.useCallback)((function(){return t.visible}),[t.visible]);Object(g.useEffect)((function(){x.page=1,A()}),[t.visible]);var A=function(){var e=Object(h.a)(b.a.mark((function e(){var t;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,r=n.taskId,Object(F.c)("sci/projects/".concat(r,"/get_data_sets.json"));case 2:(t=e.sent)&&(a(Object(s.a)(t.data_sets)),k(t.data_sets_count),v(t.folder_name));case 4:case"end":return e.stop()}var r}),e)})));return function(){return e.apply(this,arguments)}}();return m.a.createElement("div",{style:{height:"calc(100vh - 51px)",padding:"20px 15px"}},m.a.createElement("div",{className:"c-grey-999 font14 ml5 mb5"},"数据集"),m.a.createElement("dl",{className:V.a.list},m.a.createElement(W.a,{title:_},m.a.createElement("dt",{className:"c-white"},_)),m.a.createElement("dd",null,m.a.createElement(T.CopyToClipboard,{text:_,onCopy:function(){return u.b.success("复制成功")}},m.a.createElement("span",{className:"".concat(V.a.copy," current")},"点击复制")))),m.a.createElement("div",{className:"c-grey-999 font14 ml5 mb5"},"文件路径"),null==o?void 0:o.map((function(e,t){return m.a.createElement("dl",{className:V.a.list},m.a.createElement(W.a,{title:e.filename},m.a.createElement("dt",{className:"c-white"},e.filename)),m.a.createElement("dd",null,m.a.createElement(T.CopyToClipboard,{text:e.file_path,onCopy:function(){return u.b.success("复制成功")}},m.a.createElement("span",{className:"".concat(V.a.copy," current")},"点击复制"))))})),m.a.createElement("div",{className:"tc"},m.a.createElement(U.a,{onChange:function(e){x.page=e,A()},className:V.a.page,size:"small",total:C,pageSize:x.limit,hideOnSinglePage:!0})))})),se=n("dhSg"),ae=(n("q1cb"),n("iOsX")),ce=n.n(ae),le=n("XG6U"),ue=n.n(le),he=n("bntm"),de=(n("V0Rq"),n("bPs0"));A.a.Countdown;var fe=function(e){var t=e.mirror_description,n=e.difficulty,r=e.git_url,i=e.vnc_url,o=e.window_vnc_url,s=e.linux_vnc,c=(e.isNotice,e.user,e.game,e.shixun),f=void 0===c?{}:c,_=e.taskData,v=void 0===_?{}:_,S=e.resetVncLoading,A=(e.onUpdateCostTime,e.lastedGetTaskInfoTime,e.onShowNotice,e.onResetGitCode),L=e.onResetVnc,R=(e.onBack,e.history),M=e.onAddVncTime,T=(e.onUpdateCode,e.unity_3d_routes),D=(e.st,f.name),K=(f.identifier,f.task_pass),I=f.test_set_permission,F=(v.remaining_time,v.status,Object(g.useState)(!1)),X=Object(d.a)(F,2),N=X[0],H=X[1],U=Object(g.useState)(!1),W=Object(d.a)(U,2),z=W[0],V=W[1],Q=Object(g.useState)({}),q=Object(d.a)(Q,2),G=q[0],Y=(q[1],Object(g.useState)(!1)),Z=Object(d.a)(Y,2),J=Z[0],$=Z[1],ee=Object(g.useState)(null),te=Object(d.a)(ee,2),ne=(te[0],te[1],Object(g.useState)(1800)),re=Object(d.a)(ne,2),ae=re[0],le=re[1],fe=Object(g.useState)(!1),_e=Object(d.a)(fe,2),ve=(_e[0],_e[1],Object(g.useState)(!1)),be=Object(d.a)(ve,2),ge=be[0],me=be[1],ye=Object(y.h)().query,we=Object(y.i)(),Se=Object(g.useState)(!1),Ce=Object(d.a)(Se,2),ke=Ce[0],Ee=Ce[1],Oe=x.a.useForm(),xe=Object(d.a)(Oe,1)[0];Object(g.useEffect)((function(){J||setTimeout((function(){$(!0)}),6e4)}),[J]),Object(g.useEffect)((function(){se.a.subscribe("update-windows-time",(function(e){})),le(1800)}),[]),Object(g.useEffect)((function(){var e;return"exercises"===ye.type&&null!=G&&null!==(e=G.exercise)&&void 0!==e&&e.screen_open&&(de.b.forEach((function(e,t){document.addEventListener(e,Ae,!1),document.addEventListener("blur",Ae,!1)})),window.focus(),window.onblur=function(){Object(he.a)()&&(Ae(),Object(he.b)())}),function(){de.b.forEach((function(e,t){document.removeEventListener(e,Ae,!1)}))}}),[G]);var Ae=function(e){window.parent.postMessage("backExercise","*"),"back"!==e&&Object(he.b)()};function je(){H(!1),V(!1)}function Le(){Object(w.c)()._store.dispatch({type:"globalSetting/headerFooterToggle",payload:!0}),R.replace("/innovation/project/detail/".concat(we.taskId))}function Re(){S||L()}var Me={task_pass:K,test_set_permission:I,mirror_description:t,difficulty:n,resetVncLoading:S,git_url:r,onVncAction:function(e){var t,n;je(),"reset-task"===e&&(S||l.a.confirm({title:"重置环境",icon:m.a.createElement(P.a,null),content:"是否确定重置环境?",centered:!0,okText:"确定",cancelText:"取消",onOk:function(){Re(),$(!1)}})),"reset-code"===e&&(S||l.a.confirm({title:"恢复初始代码",icon:m.a.createElement(P.a,null),content:"您在本文件中修改的内容将丢失,是否确定重新加载初始代码?",centered:!0,okText:"确定",cancelText:"取消",onOk:A})),"full-screen"===e&&(Object(he.a)()?Object(he.b)():Object(he.d)(null===(t=document)||void 0===t||null===(n=t.getElementById)||void 0===n?void 0:n.call(t,"task-right-panel"))),"show-clipboard-box"===e&&se.a.publish("show-clipboard-box")},window_vnc_url:o,linux_vnc:s,vnc_url:i,shixun:f,unity_3d_routes:T},Te=Object(g.useCallback)((function(){return ae?(console.log("VncTimer:",ae),m.a.createElement(pe,{defaultTime:ae,onAddVncTime:M,onReset:Re,toShixun:Le,title:""})):null}),[ae]);return Object(g.useEffect)((function(){ge&&xe.setFieldsValue({name:"",version:"",description:""})}),[ge]),m.a.createElement("div",{className:"task-header-container"},"exercises"!==ye.type&&m.a.createElement(m.a.Fragment,null,v.name),m.a.createElement("h2",{className:"shixun-info"},D),m.a.createElement(m.a.Fragment,null,m.a.createElement("div",{className:"flex-container"},m.a.createElement(m.a.Fragment,null,o&&m.a.createElement(j.a,{onClick:function(e){e.preventDefault(),se.a.publish("send-ctrl-alt-delete")},className:"c-grey-c mr20"},"发送CTRL+ALT+DELETE"),Te()),m.a.createElement("a",{className:"btn-vnc",title:"工具栏",onClick:function(){H(!N)}},m.a.createElement("img",{alt:"tool",src:ce.a,width:16}),"工具栏"),m.a.createElement("a",{className:"btn-vnc",title:"工具栏",onClick:function(){return V(!0)}},m.a.createElement("img",{alt:"tool",src:ue.a,width:18}),"数据集"))),m.a.createElement(O.a,{type:"primary",disabled:!J,onClick:Object(h.a)(b.a.mark((function e(){return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:me(!0);case 1:case"end":return e.stop()}}),e)})))},"保存镜像"),m.a.createElement("a",{className:"btn-out",onClick:function(){l.a.confirm({title:"退出",icon:m.a.createElement(P.a,null),content:"您确定要退出制作镜像吗?",centered:!0,okText:"确定",cancelText:"取消",onOk:Le})},title:"退出实训"},m.a.createElement("i",{className:"iconfont icon-kaiguan"})),m.a.createElement(C.a,null,m.a.createElement(a.a,{className:"setting-drawer",title:null,placement:"right",closable:!1,visible:N,onClose:je},m.a.createElement(B,Me))),m.a.createElement(C.a,null,m.a.createElement(a.a,{className:"setting-drawer",title:null,placement:"right",closable:!1,visible:z,onClose:je,style:{height:"100%"}},m.a.createElement(oe,null))),m.a.createElement(l.a,{title:"保存镜像",visible:ge,okButtonProps:{loading:ke},onCancel:function(){me(!1)},onOk:function(){xe.submit()}},m.a.createElement("div",null,m.a.createElement("p",{style:{color:"#6B758B"}},"把当前的环境存为一个新的镜像。确定保存后,在我的镜像可以看到该镜像的保存状态。"),m.a.createElement(x.a,{labelCol:{span:4},wrapperCol:{span:20},form:xe,onFinish:function(){var e=Object(h.a)(b.a.mark((function e(t){var n;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return Ee(!0),e.next=3,ie(we.taskId,t);case 3:0==(null==(n=e.sent)?void 0:n.status)&&(u.b.info("保存成功"),me(!1)),-5===(null==n?void 0:n.status)&&l.a.confirm({title:"覆盖镜像提示",content:"系统检测到你的【镜像列表】存在同名且同版本号的镜像, 您确定要覆盖原来的镜像?",okText:"确认",cancelText:"取消",onOk:function(){var e=Object(h.a)(b.a.mark((function e(){var n;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,ie(we.taskId,Object(p.a)({is_cover:!0},t));case 2:0==(null==(n=e.sent)?void 0:n.status)&&(u.b.info("覆盖成功"),me(!1));case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()}),Ee(!1);case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()},m.a.createElement(x.a.Item,{label:"镜像名称",name:"name",rules:[{required:!0,message:"请输入镜像名称"},{pattern:/^[a-z0-9_]+$/,message:"只允许输入数字或小写字母"}]},m.a.createElement(E.a,{type:"text",maxLength:60})),m.a.createElement(x.a.Item,{label:" 版本号",name:"version",rules:[{required:!0,message:"请输入版本号"}]},m.a.createElement(k.a,{style:{width:"100%"}})),m.a.createElement(x.a.Item,{label:"镜像描述",name:"description",rules:[{required:!0,message:"请输入镜像描述"}]},m.a.createElement(E.a.TextArea,null))))))};function pe(e){var t=e.onAddVncTime,n=e.onReset,r=e.toShixun,i=(e.title,e.defaultTime),o=Object(g.useState)(i),s=Object(d.a)(o,2),a=s[0],c=s[1],u=Object(g.useState)(!1),f=Object(d.a)(u,2),p=f[0],_=f[1];function v(){return(v=Object(h.a)(b.a.mark((function e(){var r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(_(!1),!(a>0)){e.next=8;break}return e.next=4,t();case 4:r=e.sent,c((null==r?void 0:r.remaining_time)/1e3),e.next=10;break;case 8:c(i),n();case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}return Object(H.a)((function(){c(a-1)}),a>0?1e3:null),Object(g.useEffect)((function(){300===a&&_(!0)}),[a]),Object(g.useEffect)((function(){i<300&&_(!0),c(i)}),[i]),m.a.createElement(g.Fragment,null,m.a.createElement(C.a,null,m.a.createElement(l.a,{title:[m.a.createElement(P.a,{className:"modalIconYellow"}),0!==a?"实验环境延时提醒":"实验环境重置提醒"],closable:!1,centered:!0,wrapClassName:"customModalStyle",visible:p,onOk:function(){return v.apply(this,arguments)},onCancel:function(){0!==a?_(!1):r()},okText:0!==a?"立即延长":"重置",cancelText:0!==a?"不需要":"退出"},0!==a?"当前实验环境将于 ".concat(Math.round(a/60)," 分钟后关闭,需要延长使用时间吗?"):"由于长时间没有使用,资源已经被回收。如有需要,可以重置实验环境。")))}function _e(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=[],r=0;r0||i.target.offsetWidth>0){var o=Ce(i.target.offsetWidth,i.target.offsetHeight,e),s=Object(d.a)(o,2),a=s[0],c=s[1];console.log("cols, rows",a,c),se.a.publish("ssh-xterm-resize",{columns:a,rows:c,width:i.target.offsetWidth,height:i.target.offsetHeight}),e.resize(a,c);var l=ge.Base64.decode("IA=="),u=ge.Base64.decode("CBtbSw==");e.write(l),e.write(u)}}}catch(e){r.e(e)}finally{r.f()}}));return n.observe(t),n}(e,u.current);return function(){e.dispose(),t.unobserve(u.current)}}}),[a,u.current]),Object(g.useEffect)((function(){if(o&&a){var e=setInterval((function(){h.current&&h.current.send(JSON.stringify({tp:"h"}))}),3e4),r=se.a.subscribe("create-socket",(function(r){var i;n==r&&(h.current&&1===h.current.readyState?o.focus():(i=new WebSocket(a),console.log("socketInstance:",a),h.current=i,i.onopen=function(){var e=o.element.parentElement;if(e){var n=e.offsetWidth,r=e.offsetHeight;console.log("init",{tp:"init",data:Object(p.a)(Object(p.a)({},t),{},{secret:c,width:n,height:r,rows:o.rows,columns:o.cols})}),i.send(JSON.stringify({tp:"init",data:Object(p.a)(Object(p.a)({},t),{},{secret:c,width:n,height:r,rows:o.rows,columns:o.cols})}))}o.focus()},i.onerror=function(e){console.log("------in socket error----",e,i,a)},i.onmessage=function(e){f.current||(o.write("\r"),setTimeout((function(){}),1e3)),f.current=!0,console.log("event:",e);var t=ge.Base64.decode(e.data.toString()),n=o._core._renderService.dimensions.actualCellWidth||9.5;console.log("data:",t,n,o),o.write(t)},i.onclose=function(t){e&&clearInterval(e),o.write("\r\nconnection closed")}),o.focus())})),i=se.a.subscribe("close-socket",(function(e){n===e&&(h.current&&(h.current.close(),f.current=!1,o.clear()),h.current=null)})),s=se.a.subscribe("ssh-xterm-resize",(function(e){h.current&&1===h.current.readyState&&h.current.send(JSON.stringify({tp:"resize",data:Object(p.a)({},e)}))})),l=se.a.subscribe("ssh-add-connect-time",(function(){h.current&&1===h.current.readyState&&h.current.send(JSON.stringify({tp:"overtime"}))}));return function(){i(),r(),s(),l(),h.current&&(h.current.close(),f.current=!1)}}}),[o,a,l]),m.a.createElement("div",{className:we.a["xterm-panel-wrp"]},m.a.createElement("div",{ref:u,className:we.a["xterm-panel"]},a?null:m.a.createElement("p",{style:{color:"#fff"}},"正在连接命令行服务...")))},Ee=(n("BWJ9"),n("MXD1"),n("CFYs")),Oe=n("1dTM"),xe=n.n(Oe),Ae=(n("3MsV"),E.a.TextArea),je=function(e){var t=e.onCancel,n=e.onSave,r=e.content,i=Object(g.useState)(r),o=Object(d.a)(i,2),s=o[0],a=o[1];return Object(g.useEffect)((function(){a(r)}),[r]),m.a.createElement("div",{className:"clipboard-box"},m.a.createElement("h3",null,"实验环境剪切板:"),m.a.createElement(Ae,{value:s,onChange:function(e){a(e.target.value)},className:"clipboard"}),m.a.createElement("p",null," ",m.a.createElement("b",null," 1.从外部复制内容到实验环境内: ")," 粘贴内容到上面文本框,点击保存,然后在实验环境中进行粘贴。 "),m.a.createElement("p",null," ",m.a.createElement("b",null," 2.获取实验环境中的内容: ")," 请先在环境中复制内容,复制动作完成后内容会显示在上面文本框,然后在上面文本框中再次复制。 "),m.a.createElement("div",{className:"btn-action-container"},m.a.createElement(O.a,{type:"ghost",onClick:t,style:{marginRight:10}},"取消"),m.a.createElement(O.a,{type:"primary",onClick:function(){n(s)}},"保存")))},Le=n("ye1Q"),Re=n("osed"),Me=n.n(Re),Te=n("wd/R"),De=n.n(Te);Le.a;function Pe(e){e||(e=window.location.search);var t=e.substr(1),n={};return t.split("&").forEach((function(e){var t=e.split("=");n[t[0]]=decodeURIComponent(t[1])})),n}var Ke,Ie={loading:!0,isLarge:!1,showClipBoardBox:!1,transferContent:"",mes:"实验环境准备中"};function Fe(e,t){switch(t.type){case Ke.SET_LOADING:return Object(p.a)(Object(p.a)({},e),{},{loading:t.payload});case Ke.SET_IS_LARGE:return Object(p.a)({},Object(p.a)(Object(p.a)({},e),{},{isLarge:t.payload}));case Ke.SET_MES:return Object(p.a)(Object(p.a)({},e),{},{mes:t.payload});case Ke.SET_STATE:return Object(p.a)(Object(p.a)({},e),t.payload);case Ke.SET_TRANSFER_CONTENT:return Object(p.a)(Object(p.a)({},e),{},{transferContent:t.payload});case Ke.SHOW_CLIPBOARD_BOX:return Object(p.a)(Object(p.a)({},e),{},{showClipBoardBox:t.payload});case Ke.UPDATE_ALL:return Object(p.a)({loading:e.loading},t.payload);default:throw new Error}}!function(e){e[e.SET_LOADING=0]="SET_LOADING",e[e.SET_IS_LARGE=1]="SET_IS_LARGE",e[e.SET_MES=2]="SET_MES",e[e.SET_STATE=3]="SET_STATE",e[e.SHOW_CLIPBOARD_BOX=4]="SHOW_CLIPBOARD_BOX",e[e.SET_TRANSFER_CONTENT=5]="SET_TRANSFER_CONTENT",e[e.UPDATE_ALL=6]="UPDATE_ALL"}(Ke||(Ke={}));var Xe,Ne=function(e){var t,n=e.vnc_url,r=e.window_vnc_url,i=e.linux_vnc,o=e.virtual_machine,s=(e.taskId,e.taskData),a=Object(g.useRef)(),c=Object(g.useRef)(),f=Object(g.useRef)(),p=Object(g.useRef)(),_=Object(g.useState)(),v=Object(d.a)(_,2),w=v[0],k=v[1],E=Object(g.useState)(!1),x=Object(d.a)(E,2),A=x[0],j=x[1],M=Object(g.useReducer)(Fe,Ie),T=Object(d.a)(M,2),D=T[0],P=T[1],K=Object(g.useState)(0),I=Object(d.a)(K,2),F=I[0],X=I[1],N=D.mes,B=D.loading,H=D.showClipBoardBox,U=D.isLarge,W=D.transferContent,z=Object(g.useState)(0),V=Object(d.a)(z,2),Q=V[0],q=V[1],G=Object(g.useRef)();Object(y.i)();Object(g.useEffect)((function(){return window.addEventListener("visibilitychange",Z),function(){var e,t;null===(e=c.current)||void 0===e||null===(t=e.disconnect)||void 0===t||t.call(e),window.removeEventListener("visibilitychange",Z)}}),[]),Object(g.useEffect)((function(){return window.sessionStorage.imageId=w,function(){window.sessionStorage.removeItem("imageId")}}),[w]);var Y=function(){var e;"rdp"===(null==s||null===(e=s.shixun)||void 0===e?void 0:e.windows_connection_mode)?setTimeout((function(){ee()}),1500):Object(he.a)()?f.current.resizeSession=!0:setTimeout((function(){f.current.resizeSession=!1}),900)};Object(g.useEffect)((function(){return window.addEventListener("visibilitychange",Z),document.addEventListener(Object(he.c)(),Y),function(){document.removeEventListener(Object(he.c)(),Y),window.removeEventListener("visibilitychange",Z)}}),[]);var Z=function(e){if("visible"===document.visibilityState){var t=sessionStorage.vncPageLeaveTime;De()(new Date).diff(De()(t),"minutes")>2&&X((new Date).getTime()),sessionStorage.removeItem("vncPageLeaveTime")}else sessionStorage.vncPageLeaveTime=new Date};function J(){P({type:Ke.SHOW_CLIPBOARD_BOX,payload:!1})}function $(e){var t;return a.current&&(t=new Se.default((function(t){var n,r=Object(be.a)(t);try{for(r.s();!(n=r.n()).done;){var i,o,a=n.value;if("rdp"===(null==s||null===(i=s.shixun)||void 0===i?void 0:i.windows_connection_mode)&&ee(),a.target.offsetHeight>0||a.target.offsetWidth>0)null==e||null===(o=e._eventHandlers)||void 0===o||o.windowResize()}}catch(e){r.e(e)}finally{r.f()}}))).observe(a.current),t}function ee(){var e;e=Math.min(document.getElementById("task-right-panel").clientWidth/1920,document.getElementById("task-right-panel").clientHeight/1260),p.current.parentElement.className="wh1080p",p.current.parentElement.style.cssText="transform:scale(".concat(e,");transform-origin:center center"),a.current.style.cssText="translate(-50%, -50%) scale("+e+")"}Object(g.useEffect)((function(){var e,t;function c(e){r&&(u.b.warn("由于长时间未操作,连接失效,正在重新连接Windows VNC服务"),P({type:Ke.SET_LOADING,payload:!0}),X(F+1))}function l(){q(100),clearTimeout(G.current),setTimeout((function(){var t,n;null===(t=e)||void 0===t||null===(n=t._eventHandlers)||void 0===n||n.windowResize(),P({type:Ke.SET_LOADING,payload:!1})}),1300),se.a.subscribe("send-ctrl-alt-delete",(function(){var t;null===(t=e)||void 0===t||t.sendCtrlAltDel()}))}function d(e){var t=e.detail.text.replace(/\\u([\dA-Za-z]{4})/g,(function(e,t){return String.fromCharCode(parseInt("0x"+t))}));P({type:Ke.SET_TRANSFER_CONTENT,payload:t})}if(se.a.subscribe("reset-linux-windows-loading",(function(){P({type:Ke.SET_LOADING,payload:!0})})),se.a.subscribe("reset-linux-windos-vnc",(function(){X(F+1)})),(r||n||i||o&&w)&&a.current){var p;clearTimeout(G.current),"rdp"===(null==s||null===(p=s.shixun)||void 0===p?void 0:p.windows_connection_mode)&&ee(),new Promise(Object(h.a)(b.a.mark((function n(){var i,o,u,h,p,_,v;return b.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:i=Pe(),"",h=new URL(decodeURIComponent(null==s?void 0:s.vnc_url)),p=h.protocol,_=h.searchParams,v=h.host,u=_.get("password"),o="".concat("https:"===p?"wss":"ws","://").concat(v,"/").concat(i.path||"websockify"),e=new xe.a(a.current,o,{credentials:{password:u},wsProtocols:["binary"],resize:"scale",show_dot:!0}),t=$(e),e.viewOnly=i.view_only||!1,e.scaleViewport=!!r||(i.scale||!1),e.scaleViewport=!0,e.showDotCursor=!0,e.resizeSession=!0,f.current=e,e.addEventListener("disconnect",c),e.addEventListener("connect",l),e.addEventListener("clipboard",d);case 17:case"end":return n.stop()}}),n)}))));var _=se.a.subscribe("vnc-reseting",(function(){q(0),P({type:Ke.SET_STATE,payload:{loading:!0,mes:"实验环境重置中"}})})),v=se.a.subscribe("vnc-enlarge",(function(e){})),g=se.a.subscribe("show-clipboard-box",(function(){P({type:Ke.SHOW_CLIPBOARD_BOX,payload:!0})}));return q(0),function(){var n,r,i,o;null===(n=e)||void 0===n||n.removeEventListener("disconnect",c),null===(r=e)||void 0===r||r.removeEventListener("connect",l),null===(i=e)||void 0===i||i.removeEventListener("clipboard",d),_(),v(),g(),null===(o=t)||void 0===o||o.unobserve(a.current)}}}),[n,r,i,F,w]),Object(g.useEffect)((function(){var e,t,n,r;o&&1===(null==s||null===(e=s.shixun_virtual_templates)||void 0===e?void 0:e.length)?k(null==s||null===(n=s.shixun_virtual_templates)||void 0===n||null===(r=n[0])||void 0===r?void 0:r.template_id):o&&(null==s||null===(t=s.shixun_virtual_templates)||void 0===t?void 0:t.length)>1&&j(!0)}),[o]),Object(g.useEffect)((function(){0==Q&&(clearTimeout(G.current),te())}),[Q]);var te=function e(){Q>99?Q=99:(Q+=1,G.current=setTimeout((function(){e()}),1500)),Q<100&&q(Q)},ne=Object(g.useMemo)((function(){var e;return B?"none":i||o||r&&"rdp"===(null==s||null===(e=s.shixun)||void 0===e?void 0:e.windows_connection_mode)?"block":"none"}),[i,B,o,r]);return m.a.createElement(g.Fragment,null,A&&m.a.createElement("div",{className:Me.a.selectImage},m.a.createElement("section",{className:Me.a.container},m.a.createElement("h1",null,"选择角色"),m.a.createElement("aside",null,null==s||null===(t=s.shixun_virtual_templates)||void 0===t?void 0:t.map((function(e,t){return m.a.createElement(L.a,{align:"middle",key:t},m.a.createElement(R.a,{flex:"1"},e.template_name),m.a.createElement(R.a,null,m.a.createElement(O.a,{type:"primary",onClick:function(){k(e.template_id),j(!1)}},"开始实验")))}))))),U&&m.a.createElement("a",{className:"btn-vnc-resize",onClick:function(){P({type:Ke.SET_IS_LARGE,payload:!U})}},m.a.createElement("i",{className:"iconfont icon-tuichuquanping"})),m.a.createElement("div",{style:{width:"100%",height:"calc(100% - 50px)",overflow:"hidden",position:"absolute",display:"block"===ne?"flex":"none",alignItems:"center",justifyContent:"center",zIndex:6}},m.a.createElement("div",null,m.a.createElement("iframe",{style:{position:U?"fixed":"absolute",left:0,top:U?54:40,width:"100%",height:"calc(100% - ".concat(U?"100px":"45px",")")},frameBorder:"0",ref:p,allowFullScreen:!0}))),m.a.createElement("div",{style:{position:U?"fixed":"absolute",left:0,top:0,zIndex:5,width:"100%",height:"calc(100% - ".concat(U?"100px":"0",")")},className:"".concat(r?"vnc-panel-wrapper-windows":"vnc-panel-wrapper"," ").concat(U?"full-screen":"")},B?m.a.createElement(S.a,{message:N,style:{color:"#0152d9"}},m.a.createElement("div",{className:"tc",style:{width:500,margin:"0 auto",color:"#FFF"}},m.a.createElement(Ee.a,{percent:Q,format:function(e){return m.a.createElement("span",{className:"c-white"},e,"%")}}))):null,m.a.createElement("div",{ref:a,className:"vnc-panel ".concat(B?"hidden zIndexf1":"animated fadeIn")})),m.a.createElement(C.a,null,m.a.createElement(l.a,{title:"复制粘贴",centered:!0,maskClosable:!1,visible:H,onCancel:J,footer:null},m.a.createElement(je,{onCancel:J,onSave:function(e){var t;null===(t=f.current)||void 0===t||t.clipboardPasteFrom(e),P({type:Ke.SET_TRANSFER_CONTENT,payload:e}),u.b.success("保存成功!你可以在实验环境中粘贴该内容"),J()},content:W}))))},Be=function(e){var t=e.taskData,n=(e.evaluateLoading,e.evaluateMessage,e.language,e.onEval,t.vnc_url),r=(t.shixun,t.test_sets,t.test_sets_count,t.sets_error_count,t.last_compile_output,t.game,t.allowed_unlock,t.user,Object(g.useState)(!1)),i=Object(d.a)(r,2),o=i[0],s=(i[1],Object(g.useState)(!1)),a=Object(d.a)(s,2),c=a[0],l=a[1];return console.log("vnc_url:",n),m.a.createElement(g.Fragment,null,m.a.createElement(Ne,{vnc_url:n,window_vnc_url:t.windows_vnc,virtual_machine:null==t?void 0:t.virtual_machine,linux_vnc:t.linux_vnc,taskData:t}),c?m.a.createElement("div",{className:"vnc-mask"}):null,m.a.createElement("div",{className:"vnc-test-list ".concat(o?"large":c?"pop":"")},m.a.createElement("div",{className:"vnc-test-list-body"},o?null:m.a.createElement("span",{className:"arrow-container",onClick:function(){l(!c)}},m.a.createElement("i",{className:"iconfont ".concat(c?"icon-xiajiantou":"icon-shangjiantou"," ")})))))},He=n("LQ8X"),Ue=n.n(He),We=function(e,t){switch(t.type){case"MOVE_X":return Object(p.a)(Object(p.a)({},e),{},{moveX:t.payload});case"SET_DRAGMODULE":return Object(p.a)(Object(p.a)({},e),{},{showDragModule:t.payload});case"TRIGGER_RIGHT_PANEL_MASK":return Object(p.a)(Object(p.a)({},e),{},{showDragMask:t.payload})}};A.a.Countdown;!function(e){e[e.LoadFail=1]="LoadFail",e[e.ReLoad=2]="ReLoad",e[e.Success=3]="Success"}(Xe||(Xe={}));var ze={moveX:"40%",showDragModule:!1,showDragMask:!1},Ve=Object(w.a)((function(e){var t=e.loading;return{globalSetting:e.globalSetting,loading:t}}))((function(e){e.globalSetting,e.loading;var t=e.taskData,n=(e.dispatch,Object(f.a)(e,["globalSetting","loading","taskData","dispatch"]),Object(y.i)(),Object(g.useRef)(),Object(g.useState)(!0)),r=Object(d.a)(n,2),i=(r[0],r[1],Object(g.useState)(!1)),o=Object(d.a)(i,2),s=(o[0],o[1],Object(g.useState)(0)),a=Object(d.a)(s,2),c=(a[0],a[1],Object(g.useState)(0)),l=Object(d.a)(c,2),u=(l[0],l[1],Object(g.useState)(!0)),p=Object(d.a)(u,2),_=(p[0],p[1],Object(g.useState)(!1)),v=Object(d.a)(_,2),w=(v[0],v[1],Object(g.useRef)(!0)),S=Object(g.useState)({}),C=Object(d.a)(S,2),k=C[0],E=(C[1],Object(g.useState)({})),O=Object(d.a)(E,2),x=(O[0],O[1],Object(g.useState)()),A=Object(d.a)(x,2),j=(A[0],A[1],Object(g.useRef)(),Object(g.useState)(Xe.Success)),L=Object(d.a)(j,2),R=(L[0],L[1],Object(g.useState)()),M=Object(d.a)(R,2),T=(M[0],M[1],Object(g.useState)()),D=Object(d.a)(T,2),P=(D[0],D[1],Object(g.useState)(!1)),K=Object(d.a)(P,2),I=K[0],F=K[1],X=Object(g.useState)(""),N=Object(d.a)(X,2),B=(N[0],N[1],Object(g.useRef)(null),Object(g.useRef)({}),Object(g.useRef)(!1)),H=Object(g.useReducer)(We,ze),U=Object(d.a)(H,2),W=U[0],z=U[1];Object(g.useEffect)((function(){return window.addEventListener("message",V),function(){window.removeEventListener("message",V)}}),[]);var V=function(e){"jupytermessage"===(null==e?void 0:e.data)&&w.current&&(w.current=!1,Q(),B.current||setTimeout((function(){return w.current=!0}),500))},Q=function(){var e=Object(h.a)(b.a.mark((function e(){return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();Object(g.useEffect)((function(){function e(e){z({type:"MOVE_X",payload:e.pageX})}function t(){z({type:"TRIGGER_RIGHT_PANEL_MASK",payload:!1}),document.onselectstart=null}return W.showDragMask&&(document.addEventListener("mousemove",e),document.addEventListener("mouseup",t)),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}}),[W.showDragMask]);var q="number"==typeof W.moveX&&.01!==W.moveX?"".concat(W.moveX,"px"):"40%",G="calc(100% - 4px - ".concat(q,")");return m.a.createElement("section",{className:Ue.a.bg,style:{userSelect:W.showDragMask?"none":"unset"}},m.a.createElement("section",{className:Ue.a.content,style:{height:null!=k&&k.open_evaluate?"calc(100vh - 130px)":"calc(100vh - 60px)"}},m.a.createElement("section",{className:Ue.a.rightCotainer,style:{width:G}},m.a.createElement("main",{className:Ue.a.main,style:{height:"100%"}},m.a.createElement(g.Fragment,null,m.a.createElement("div",{className:"".concat(Ue.a.dataSetButton," ").concat(I?Ue.a.dataSetOpen:""),onClick:function(){return F(!I)}},m.a.createElement("span",{className:Ue.a.dataSetText},"数据集")),m.a.createElement("iframe",{frameBorder:0,id:"taskJupyterIframe",width:"100%",height:"100%",allow:"geolocation; microphone; camera; midi; encrypted-media;",src:null==t?void 0:t.url}))))))})),Qe=(n("E1Sb"),n("nAPy"),n("WkQV")),qe=n("fr4D"),Ge="UPDATE_TASK_DATA",Ye="EDIT_REP_CONTENT",Ze=_.a.DirectoryTree,Je={moveX:"40%",moveY:0,loading:!0,isError:!1,taskData:{game:{}},evalData:null,lastedGetTaskInfoTime:0,codeRepData:{content:"",language:"c",currentPath:"",paths:[],lastedUpdateTime:0,loading:!1},showEvalResult:!1,showPictureView:!1,isPictureView:!1,showDragMask:!1,webDisplayUrl:"",evaluateLoading:!1,resetVncLoading:!1,evaluateMessage:"",showNotice:!1,timestamp:"",showDocuments:!1,repos:null};function $e(e,t){switch(t.type){case"MOVE_X":return Object(p.a)(Object(p.a)({},e),{},{moveX:t.payload});case"MOVE_Y":return Object(p.a)(Object(p.a)({},e),{},{moveY:t.payload});case"SHOW_REP_loading":case"FETCH_REP_CONTENT":return Object(p.a)(Object(p.a)({},e),{},{codeRepData:t.payload});case Ye:return Object(p.a)(Object(p.a)({},e),{},{codeRepData:Object(p.a)(Object(p.a)({},e.codeRepData),t.payload)});case"SHOW_EVALUATE_RESULT":return Object(p.a)(Object(p.a)({},e),{},{evaluateLoading:!1,showEvalResult:!0});case"UPDATE_TIMESTRAP":return Object(p.a)(Object(p.a)({},e),{},{timestamp:t.payload});case"HIDE_EVALUATE_RESULT":return Object(p.a)(Object(p.a)({},e),{},{showEvalResult:!1});case"FETCH_TASK_START":return Object(p.a)(Object(p.a)({},e),{},{loading:!0});case Ge:return Object(p.a)(Object(p.a)({},e),t.payload);case"TRIGGER_RIGHT_PANEL_MASK ":return Object(p.a)(Object(p.a)({},e),{},{showDragMask:t.payload});case"FETCH_TASK_FAILURE":return Object(p.a)(Object(p.a)({},e),{},{loading:!1,isError:!0});case"FETCH_TASK_SUCCESS":return Object(p.a)(Object(p.a)({},e),t.payload);case"SHOW_EVALUATE_LOADING":return Object(p.a)(Object(p.a)({},e),{},{evaluateLoading:!0});case"HIDE_EVALUATE_LOADING":return Object(p.a)(Object(p.a)({},e),{},{evaluateLoading:!1});case"SET_EVALUATE_MESSAGE":return Object(p.a)(Object(p.a)({},e),{},{evaluateMessage:t.payload});case"SET_SHOW_DIR":return Object(p.a)(Object(p.a)({},e),{},{showDocuments:t.payload});case"SET_REPOS":return Object(p.a)(Object(p.a)({},e),t.payload);case"SHOW_NOTICE":return Object(p.a)(Object(p.a)({},e),{},{showNotice:!0});case"HIDE_NOTICE":return Object(p.a)(Object(p.a)({},e),{},{showNotice:!1});case"HIDE_PICTURE_VIEW":return Object(p.a)(Object(p.a)({},e),{},{showPictureView:!1});case"SHOW_PICTURE_VIEW":return Object(p.a)(Object(p.a)({},e),{},{showPictureView:!0});case"SET_VNC_LOADING ":return Object(p.a)(Object(p.a)({},e),{},{resetVncLoading:t.payload});default:throw new Error}}t.default=function(e){var t,n=e.match,r=e.history,i=Object(f.a)(e,["match","history"]);console.log("props:",i);var o=Object(y.i)(),_=(Object(y.h)().query,Object(g.useReducer)($e,Je)),v=Object(d.a)(_,2),k=v[0],E=v[1],O=Object(g.useState)(1),x=Object(d.a)(O,2),A=x[0],j=x[1],L=Object(g.useState)(o.taskId),R=Object(d.a)(L,2),M=R[0],T=R[1],D=Object(g.useRef)(),P=Object(g.useRef)(),K=Object(g.useRef)(),N=Object(g.useState)(),B=Object(d.a)(N,2),H=B[0],U=B[1],W=r.location;Object(g.useEffect)((function(){console.log("_params:",o),T(o.taskId),Object(w.c)()._store.dispatch({type:"globalSetting/headerFooterToggle",payload:!1})}),[o]);k.moveX;var z=k.taskData,V=(k.moveY,k.evalData),Q=(k.showEvalResult,k.codeRepData),te=k.loading,ie=k.evaluateLoading,oe=k.evaluateMessage,ae=k.showDocuments,ce=k.repos,le=(k.showPictureView,k.showNotice),ue=k.webDisplayUrl,he=k.isPictureView,de=k.resetVncLoading,pe=k.timestamp,be=k.lastedGetTaskInfoTime,me=k.showDragMask,ye=z.st,we=z.challenge,Se=z.shixun,Ce=z.is_teacher,Ee=z.game,Oe=z.has_answer,xe=z.vnc_url,Ae=z.git_url,je=z.user,Le=z.myshixun,Re=z.discusses_count,Me=z.user_praise,Te=z.praise_count,De=z.tpm_cases_modified,Pe=z.tpm_modified,Ke=z.tpm_script_modified,Ie=z.mirror_name,Fe=z.mirror_description,Xe=(z.tomcat_url,z.unity_3d_routes),Ne=z.with_code_file,He=z.unity_3d_result,Ue=(z.next_game,z.prev_game,Q.currentPath),We=Q.paths,ze=Q.content,tt=Q.language,nt=Q.lastedUpdateTime,rt=(Pe||Ke)&&0===ye,it=(De||rt)&&!0===Le.system_tip,ot=((Ie||[]).indexOf("Html"),Object(g.useMemo)((function(){return!(!Ue||!We)&&We.indexOf(Ue)>=0}),[Ue,We])),st=Object(g.useMemo)((function(){return Xe&&!Ne||(null==we?void 0:we.thiry_party)||xe}),[xe,Ne,Xe]);function at(){return(at=Object(h.a)(b.a.mark((function e(){var t;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(F.a)("/api/sci/projects/".concat(M,".json"),{method:"get"});case 2:t=e.sent,U(t);case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function ct(e){return lt.apply(this,arguments)}function lt(){return(lt=Object(h.a)(b.a.mark((function e(t){var n,i,o;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Object(qe.i)(M);case 3:if(n=e.sent,401!==(i=n.status)){e.next=10;break}return r.replace("/user/login",{from:W.pathname}),e.abrupt("return");case 10:if(-3!==i){e.next=14;break}Object(X.o)({onCancel:function(){window.location.href="/"}}),e.next=25;break;case 14:if(403!==i){e.next=18;break}r.replace("/403"),e.next=25;break;case 18:if(404!==i){e.next=23;break}return r.replace("/404"),e.abrupt("return");case 23:o={loading:!1,isError:!1,taskData:n},t||E({type:"FETCH_TASK_SUCCESS",payload:o});case 25:"webssh"===n.mirror_type&&setTimeout((function(){se.a.publish("create-socket",1)}),1e3),e.next=32;break;case 28:e.prev=28,e.t0=e.catch(0),console.log(e.t0),t||E({type:"FETCH_TASK_FAILURE"});case 32:case"end":return e.stop()}}),e,null,[[0,28]])})))).apply(this,arguments)}Object(g.useEffect)((function(){if(Xe&&Ne)return E({type:"SHOW_EVALUATE_LOADING"}),se.a.subscribe("unity3d-load-end",(function(){E({type:"HIDE_EVALUATE_LOADING"})}))}),[M,Xe,null==we?void 0:we.thiry_party,Ne,E]),Object(g.useEffect)((function(){!function(){at.apply(this,arguments)}()}),[]),Object(g.useEffect)((function(){var e=!1;return ct(e),function(){e=!0}}),[E,M]),Object(g.useEffect)((function(){var e=!1;function t(){return(t=Object(h.a)(b.a.mark((function t(){var n,r,i,o,s,a;return b.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(E({type:"SHOW_REP_loading",payload:Object(p.a)(Object(p.a)({},Q),{},{loading:!0})}),!(Xe&&!Ne||null!=we&&we.thiry_party)){t.next=3;break}return t.abrupt("return");case 3:return t.next=5,G(M,{path:Ue});case 5:if(n=t.sent,!e)if(0===n.status)u.b.info(n.message),E({type:"FETCH_REP_CONTENT",payload:Object(p.a)(Object(p.a)({},Q),{},{loading:!1})});else{try{r="txt"===(null==n?void 0:n.file_type)?0===(null===(i=r)||void 0===i?void 0:i.length)?r:window.decodeURIComponent(escape(window.atob(null==n||null===(o=n.content)||void 0===o?void 0:o.content))):null==n||null===(s=n.content)||void 0===s?void 0:s.content}catch(e){r=window.atob(null==n||null===(a=n.content)||void 0===a?void 0:a.content),u.b.warn("请确认文件字符集编码是否为UTF-8"),console.log("err:",e)}E({type:"FETCH_REP_CONTENT",payload:Object(p.a)(Object(p.a)({},Q),{},{content:r,language:n.language,file_type:n.file_type,filename:n.filename,lastedUpdateTime:0,loading:!1})})}case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}if(0===ye&&Ue&&1!==Se.hide_code)return function(){t.apply(this,arguments)}(),function(){e=!0}}),[ye,Ue,be,pe]);var ut=function(){var e=Object(h.a)(b.a.mark((function e(){var t,n,r=arguments;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=r.length>0&&void 0!==r[0]?r[0]:0,console.log("lastedUpdateTime:",ot,t),!(0===ye&&nt>0&&ot||t)){e.next=8;break}return e.next=5,Y(Le.identifier,{path:Ue,evaluate:t,content:ze,game_id:Ee.id});case 5:return n=e.sent,E({type:Ye,payload:{lastedUpdateTime:0}}),e.abrupt("return",n);case 8:return e.abrupt("return",!0);case 9:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();Object(g.useCallback)((function(){}),[ut]);Object(g.useEffect)((function(){return se.a.subscribe("unlock-test-case",(function(){var e;l.a.confirm((e={centered:!0,okText:"确定",cancelText:"取消",title:"提示",content:m.a.createElement(et,{score:we.score,is_teacher:Ce})},Object(c.a)(e,"centered",!0),Object(c.a)(e,"onOk",ht),e))}))}),[ht,we,Ce]);var ht=Object(g.useCallback)(Object(h.a)(b.a.mark((function e(){var t,n,r,i;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o=Ee.identifier,Object(F.c)("tasks/".concat(o,"/check_test_sets.json"));case 2:if(t=e.sent,n=t.test_sets,r=t.message,-1!==t.status){e.next=7;break}return u.b.info(r),e.abrupt("return");case 7:i=z.user.grade,z.user.grade=i-2*we.score,z.test_sets=n,z.game.test_sets_view=!0,E({type:Ge,payload:{taskData:z}});case 12:case"end":return e.stop()}var o}),e)}))),[Ee,we,E]);function dt(){return ft.apply(this,arguments)}function ft(){return(ft=Object(h.a)(b.a.mark((function e(){var t,n;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Z(null==z||null===(t=z.myshixun)||void 0===t?void 0:t.identifier,{});case 2:return n=e.sent,ct(),e.abrupt("return",n);case 5:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function pt(){return(pt=Object(h.a)(b.a.mark((function e(){var t,n,r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,J(M);case 2:t=e.sent,n=t.praise_count,r=t.praise,z.praise_count=n,z.user_praise=r,E({type:Ge,payload:{taskData:z}});case 7:case"end":return e.stop()}}),e)})))).apply(this,arguments)}Object(g.useEffect)((function(){if(!st||xe){function e(e){D.current&&E({type:"MOVE_X",payload:e.pageX}),P.current&&E({type:"MOVE_Y",payload:e.pageY})}function t(){D.current=!1,P.current=!1,E({type:"TRIGGER_RIGHT_PANEL_MASK ",payload:!1}),document.onselectstart=null}return document.addEventListener("mousemove",e),document.addEventListener("mouseup",t),function(){document.removeEventListener("mousemove",e),document.removeEventListener("mouseup",t)}}}),[P.current,D.current,st,E]),K.current=function(){k.moveX=.01!==k.moveX?.01:"40%",E({type:"MOVE_X",payload:k.moveX})},Object(g.useEffect)((function(){return se.a.subscribe("vnc-enlarge",(function(){K.current()}))}),[]),Object(g.useEffect)((function(){if(0===ye&&we&&we.path){var e=we.path.split(";").filter((function(e){return!!e}));E({type:Ye,payload:{currentPath:e[0],paths:e}})}}),[we,ye]),Object(g.useEffect)((function(){Se&&Object(X.V)(Se.name||"实践项目名称-未填写")}),[Se]);var _t=Object(g.useCallback)((function(e){function t(){return(t=Object(h.a)(b.a.mark((function e(t){return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:try{window.navigator.sendBeacon("".concat(I.a.API_SERVER,"/api/tasks/").concat(M,"/cost_time.json?time=").concat(t),{})}catch(e){}case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}!function(e){t.apply(this,arguments)}(e)}),[M]);function vt(){return(vt=Object(h.a)(b.a.mark((function e(t){return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,q(M,Se.id,t);case 2:z.game.star=t,E({type:Ge,payload:{taskData:z}});case 4:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function bt(){return(bt=Object(h.a)(b.a.mark((function e(t){var n,r,i;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.props,r=n.children,i=n.eventKey,e.abrupt("return",new Promise(function(){var e=Object(h.a)(b.a.mark((function e(t){var n,o,a;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r&&r.length>0&&t(),e.next=3,$(Le.identifier,{path:i});case 3:n=e.sent,o=n.trees,a=ve(ce,i,_e(o,i)),E({type:"SET_REPOS",payload:{repos:Object(s.a)(a)}}),t();case 8:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()));case 2:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function gt(){E({type:"SHOW_NOTICE"})}function mt(){return(mt=Object(h.a)(b.a.mark((function e(t,n){var r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!n.node.isLeaf){e.next=7;break}return r=t[0],r.split(".").pop().toLowerCase(),e.next=6,ut();case 6:E({type:Ye,payload:{currentPath:r}});case 7:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function yt(){return(yt=Object(h.a)(b.a.mark((function e(){var t,n;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,E({type:"SET_VNC_LOADING ",payload:!0}),se.a.publish("vnc-reseting"),e.next=5,ee(o.taskId);case 5:t=e.sent,n=t.vnc_url,z.vnc_url=n+"×tamp="+(new Date).getTime(),se.a.publish("vnc-reseting-done",t),E({type:Ge,payload:{taskData:z,resetVncLoading:!1}}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(0),console.log(e.t0);case 15:case"end":return e.stop()}}),e,null,[[0,12]])})))).apply(this,arguments)}function wt(){return(wt=Object(h.a)(b.a.mark((function e(t){var r,i,o,s,a,c;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=t.GameState,i=t.Data,o=t.challenge,console.log("match:",n),"info"!==o){e.next=6;break}se.a.publish("evaluate-unity3d-result",{state:"3d_callback",data:{challenge_info:Object(p.a)({},z.challenge)}}),e.next=16;break;case 6:if("Success"!==r){e.next=16;break}if(!He&&Ne){e.next=15;break}return e.next=10,ne(M,ge.Base64.encode(M+(new Date).getTime()),i);case 10:s=e.sent,a=s.status,c=s.data,0==a&&(2!==Ee.status&&(z.game.status=2,z.user.grade+=c.gold,se.a.publish("update-cost-time")),se.a.publish("evaluate-unity3d-result",{state:"userAndtime",data:{user:je,open_time:c.open_time,end_time:c.end_time}}),E({type:Ge,payload:{taskData:z,evalData:{gold:c.gold,experience:c.experience,next_game:c.next_game},evaluateLoading:!1,showEvalResult:!0}})),e.next=16;break;case 15:E({type:"SHOW_EVALUATE_RESULT"});case 16:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function St(){return(St=Object(h.a)(b.a.mark((function e(){var t,n,r,i,o;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,re(M);case 2:return i=e.sent,null!==(t=i)&&void 0!==t&&null!==(n=t.data)&&void 0!==n&&n.remaining_time&&se.a.publish("update-windows-time",null===(o=i)||void 0===o?void 0:o.data),e.abrupt("return",null===(r=i)||void 0===r?void 0:r.data);case 5:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var Ct="calc(100vw - 4px - ".concat("80px",")");t={game:Ee,taskId:M,user_praise:Me,praise_count:Te,st:ye,challenge:we,rank_name:z.rank_name,shixun:Se,is_teacher:Ce,has_answer:Oe,unity_3d_routes:Xe,with_code_file:Ne,onEvaluateCallback:function(){},onGetUnity3dMessage:function(e){return wt.apply(this,arguments)}},Object(c.a)(t,"taskId",M),Object(c.a)(t,"myshixun",Le),Object(c.a)(t,"user",je),Object(c.a)(t,"discusses_count",Re),Object(c.a)(t,"onPlusOrCancelPraise",(function(){return pt.apply(this,arguments)})),Object(c.a)(t,"minuxUserGrade",(function(e){var t=z.user.grade;z.user.grade=t-e,E({type:Ge,payload:{taskData:z}})})),Object(c.a)(t,"taskData",z),le||(De||rt)&&Le.system_tip,(Le||{}).id,Object(p.a)(Object(p.a)({},V),{},{isPictureView:he,history:r,webDisplayUrl:ue,onShowPictureView:function(){E({type:"SHOW_PICTURE_VIEW"})},star:Ee&&Ee.star,onStarChange:function(e){return vt.apply(this,arguments)},onCloseResult:function(){E({type:"HIDE_EVALUATE_RESULT"})}});return m.a.createElement(g.Fragment,null,te?m.a.createElement(S.a,{message:"努力请求数据中..",className:"tpi-spin"}):m.a.createElement(g.Fragment,null,m.a.createElement("div",{className:"task-wrapper"},me&&m.a.createElement("div",{className:"draging-mask"}),m.a.createElement(fe,{difficulty:null==we?void 0:we.difficulty,mirror_description:Fe,history:r,git_url:Ae,shixun:Se,taskData:z,lastedGetTaskInfoTime:be,onAddVncTime:function(){return St.apply(this,arguments)},taskId:M,isNotice:it,resetVncLoading:de,onResetVnc:function(){return yt.apply(this,arguments)},onResetGitCode:dt,vnc_url:xe,linux_vnc:null==z?void 0:z.linux_vnc,window_vnc_url:(null==z?void 0:z.windows_vnc)||(null==z?void 0:z.virtual_machine),onShowNotice:gt,game:Ee,user:je,st:ye,onUpdateCode:ut,onUpdateCostTime:_t,unity_3d_routes:Xe&&!Ne||(null==we?void 0:we.thiry_party)}),m.a.createElement("div",{className:"tasks-body2"},m.a.createElement("section",{className:"left-panel"},m.a.createElement("ul",null,m.a.createElement("li",{onClick:function(){return j(1)},className:1==A?"on":""},m.a.createElement("span",{className:"iconfont icon-huanjing"}),m.a.createElement("span",null,"环境")),m.a.createElement("li",{onClick:function(){return j(2)},className:2==A?"on":""},m.a.createElement("span",{className:"iconfont icon-shujuwajue"}),m.a.createElement("span",null,"数据集")))),m.a.createElement("section",{id:"task-right-panel",className:"right-panel ".concat(xe||null!=z&&z.windows_vnc||null!=z&&z.linux_vnc||null!=z&&z.virtual_machine?"vnc":""),style:{width:Ct,minWidth:"500px"}},m.a.createElement("div",{style:{height:"100%"},className:1===A?"":"hide"},"webssh"===z.mirror_type&&m.a.createElement(ke,{sshConfigData:z||{},sid:1}),"graph"===z.mirror_type&&m.a.createElement(Be,{taskData:z,evaluateMessage:oe,language:tt,evaluateLoading:ie,onEval:i.onEvalCode}),("jupyterlab"===z.mirror_type||"jupyternotebook"===z.mirror_type)&&m.a.createElement(Ve,{taskData:z,evaluateMessage:oe,language:tt,evaluateLoading:ie,onEval:i.onEvalCode})),m.a.createElement("div",{className:2===A?"data_env_lists":"hide"},m.a.createElement("div",{className:"data_header"},"数据集 (",null==H?void 0:H.data_count,")"),m.a.createElement("div",{style:{padding:20}},m.a.createElement(Qe.a,{detail:H})))))),m.a.createElement(C.a,null,m.a.createElement(a.a,{className:"setting-drawer",title:null,placement:"right",width:400,closable:!1,visible:ae,onClose:function(){E({type:"SET_SHOW_DIR",payload:!1})}},m.a.createElement(Ze,{className:"dir-tree",selectedKeys:["".concat(Ue)],treeData:ce,onSelect:function(e,t){return mt.apply(this,arguments)},loadData:function(e){return bt.apply(this,arguments)}})))))};function et(e){var t=e.is_teacher,n=e.score;return m.a.createElement(g.Fragment,null,t?m.a.createElement(g.Fragment,null,m.a.createElement("div",null,"已经过职业认证的教师可以免金币查看隐藏测试集。"),m.a.createElement("div",null,"解锁本关所有测试集需要扣除".concat(2*n,"金币,确定要解锁吗?")),m.a.createElement("a",{href:"/account/certification",class:"to-certification-link",target:"_blank"},"立即认证")):m.a.createElement("div",null,"解锁本关所有测试集需要扣除".concat(2*n,"金币,确定要解锁吗?")))}},"500L": /*!**********************************************!*\ !*** ./src/components/MultiUpload/index.tsx ***! \**********************************************/ /*! exports provided: coverToFileList, default */ /*! exports used: coverToFileList, default */function(e,t,n){"use strict";n.d(t,"a",(function(){return y}));n(/*! antd/es/button/style */"+L6B");var r=n(/*! antd/es/button */"2/Rp"),i=(n(/*! antd/es/modal/style */"2qtc"),n(/*! antd/es/modal */"kLXV")),o=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator */"9og8"),s=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2 */"k1fw"),a=(n(/*! antd/es/message/style */"miYZ"),n(/*! antd/es/message */"tsqr")),c=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/toConsumableArray */"oBTY"),l=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray */"tJVT"),u=(n(/*! antd/es/upload/style */"DZo9"),n(/*! antd/es/upload */"8z0m")),h=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator */"WmNS"),d=n.n(h),f=n(/*! react */"q1tI"),p=n.n(f),_=n(/*! @/utils/env */"m3rI"),v=n(/*! @/pages/MoopCases/FormPanel/service */"wzkS"),b=n(/*! ../SingleUpload */"y5JW"),g=n(/*! @ant-design/icons */"LtfV"),m=u.a.Dragger;function y(e){var t=[];return e&&e.length>0&&(t=e.map((function(e){return{uid:e.id,id:e.id,name:e.title+b.c+e.filesize,url:e.url,filesize:e.filesize,status:"done",response:{id:e.id}}}))),t}t.b=function(e){var t=e.value,n=e.onChange,h=e.action,y=e.className,w=e.maxSize,S=void 0===w?150:w,C=e.title,k=void 0===C?"上传附件":C,E=e.showRemoveModal,O=void 0!==E&&E,x=e.accept,A=void 0===x?"":x,j=e.additionalText,L=e.isDragger,R=e.number,M=void 0===R?1e3:R,T=e.aloneClear,D=void 0!==T&&T,P=e.restrict,K=void 0===P||P,I=Object(f.useState)(!1),F=Object(l.a)(I,2),X=F[0],N=F[1],B=Object(f.useState)(t||[]),H=Object(l.a)(B,2),U=H[0],W=H[1];Object(f.useEffect)((function(){t&&(W(Object(c.a)(t)),M===(null==t?void 0:t.length)&&N(!0))}),[t]);var z,V=function(){setTimeout((function(){U.pop(),W(Object(c.a)(U))}),500)},Q={multiple:!0,disabled:X,accept:A,withCredentials:!0,fileList:U,beforeUpload:function(e,t){var n=e.size/1024/1024;return U.concat(t).length>M?(U.pop(),W(Object(c.a)(U)),a.b.error("最多只能上传".concat(M,"个文件")),D?Promise.reject():(V(),!1)):n=M?N(!0):N(!1),W(Object(c.a)(t)),t=t.map((function(e){var t,n;null!=e&&null!==(t=e.response)&&void 0!==t&&t.id&&(e.url="/api/attachments/".concat(null==e||null===(n=e.response)||void 0===n?void 0:n.id));return-1===e.name.indexOf(b.c)&&(e.name="".concat(e.name).concat(b.c).concat(Object(b.a)(e.size))),Object(s.a)({},e)})),console.log("info:",e),n(t)},onRemove:(z=Object(o.a)(d.a.mark((function e(t){var n;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=function(){var e=Object(o.a)(d.a.mark((function e(){var n;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(t.response?t.response.id:t.id)){e.next=8;break}return e.next=4,Object(v.d)(t.response?t.response.id:t.uid);case 4:return n=e.sent,e.abrupt("return",n);case 8:return e.abrupt("return",!0);case 9:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),!O){e.next=5;break}return e.abrupt("return",new Promise((function(e,t){var r;i.a.confirm({centered:!0,width:530,okText:"确定",cancelText:"取消",title:"提示",content:p.a.createElement("div",{className:"tc font16"},"是否确认删除?"),onOk:(r=Object(o.a)(d.a.mark((function t(){return d.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,n();case 2:t.sent,a.b.success("删除成功"),e(!0);case 5:case"end":return t.stop()}}),t)}))),function(){return r.apply(this,arguments)}),onCancel:function(){return e(!1)}})})));case 5:return e.next=7,n();case 7:return e.abrupt("return",e.sent);case 8:case"end":return e.stop()}}),e)}))),function(e){return z.apply(this,arguments)})};return p.a.createElement("div",{className:"multi-upload ".concat(y||"")},L&&p.a.createElement(m,Q,p.a.createElement("p",{className:"ant-upload-drag-icon"},p.a.createElement(g.a,null)),p.a.createElement("p",{className:"ant-upload-text"},"点击上传图标,选择要上传的文件或将文件拖拽到此",p.a.createElement("br",null),p.a.createElement("span",{style:{display:K?"block":"none"}},"(单个文件最大限制为",S,"MB) ")),j),!L&&p.a.createElement(u.a,Q,p.a.createElement(r.a,{disabled:X},k),p.a.createElement("span",{onClick:function(e){e.preventDefault(),e.stopPropagation()},style:{marginLeft:10,color:"#FA6400",display:K?"block":"none"}},"(单个文件最大",S,"MB) ")))}},"55Ip": /*!***************************************************************!*\ !*** ./node_modules/react-router-dom/esm/react-router-dom.js ***! \***************************************************************/ /*! exports provided: MemoryRouter, Prompt, Redirect, Route, Router, StaticRouter, Switch, generatePath, matchPath, useHistory, useLocation, useParams, useRouteMatch, withRouter, BrowserRouter, HashRouter, Link, NavLink */ /*! exports used: Link, NavLink */function(e,t,n){"use strict";n.d(t,"a",(function(){return v})),n.d(t,"b",(function(){return m}));var r=n(/*! react-router */"Ty5D"),i=n(/*! @babel/runtime/helpers/esm/inheritsLoose */"dI71"),o=n(/*! react */"q1tI"),s=n.n(o),a=n(/*! history */"YS25"),c=(n(/*! prop-types */"17x9"),n(/*! @babel/runtime/helpers/esm/extends */"wx14")),l=n(/*! @babel/runtime/helpers/esm/objectWithoutPropertiesLoose */"zLVn"),u=n(/*! tiny-invariant */"9R94");s.a.Component;s.a.Component;var h=function(e,t){return"function"==typeof e?e(t):e},d=function(e,t){return"string"==typeof e?Object(a.c)(e,null,null,t):e},f=function(e){return e},p=s.a.forwardRef;void 0===p&&(p=f);var _=p((function(e,t){var n=e.innerRef,r=e.navigate,i=e.onClick,o=Object(l.a)(e,["innerRef","navigate","onClick"]),a=o.target,u=Object(c.a)({},o,{onClick:function(e){try{i&&i(e)}catch(t){throw e.preventDefault(),t}e.defaultPrevented||0!==e.button||a&&"_self"!==a||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e)||(e.preventDefault(),r())}});return u.ref=f!==p&&t||n,s.a.createElement("a",u)}));var v=p((function(e,t){var n=e.component,i=void 0===n?_:n,o=e.replace,a=e.to,v=e.innerRef,b=Object(l.a)(e,["component","replace","to","innerRef"]);return s.a.createElement(r.e.Consumer,null,(function(e){e||Object(u.a)(!1);var n=e.history,r=d(h(a,e.location),e.location),l=r?n.createHref(r):"",_=Object(c.a)({},b,{href:l,navigate:function(){var t=h(a,e.location);(o?n.replace:n.push)(t)}});return f!==p?_.ref=t||v:_.innerRef=v,s.a.createElement(i,_)}))})),b=function(e){return e},g=s.a.forwardRef;void 0===g&&(g=b);var m=g((function(e,t){var n=e["aria-current"],i=void 0===n?"page":n,o=e.activeClassName,a=void 0===o?"active":o,f=e.activeStyle,p=e.className,_=e.exact,m=e.isActive,y=e.location,w=e.sensitive,S=e.strict,C=e.style,k=e.to,E=e.innerRef,O=Object(l.a)(e,["aria-current","activeClassName","activeStyle","className","exact","isActive","location","sensitive","strict","style","to","innerRef"]);return s.a.createElement(r.e.Consumer,null,(function(e){e||Object(u.a)(!1);var n=y||e.location,o=d(h(k,n),n),l=o.pathname,x=l&&l.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),A=x?Object(r.f)(n.pathname,{path:x,exact:_,sensitive:w,strict:S}):null,j=!!(m?m(A,n):A),L=j?function(){for(var e=arguments.length,t=new Array(e),n=0;n=0||t.relatedTarget.className.indexOf("".concat(o,"-next"))>=0)||(e.setState({goInputText:""}),i(e.getValidValue()))},e.go=function(t){""!==e.state.goInputText&&(t.keyCode!==_&&"click"!==t.type||(e.setState({goInputText:""}),e.props.quickGo(e.getValidValue())))},e}return Object(a.a)(n,[{key:"getValidValue",value:function(){var e=this.state,t=e.goInputText,n=e.current;return!t||isNaN(t)?n:Number(t)}},{key:"getPageSizeOptions",value:function(){var e=this.props,t=e.pageSize,n=e.pageSizeOptions;return n.some((function(e){return e.toString()===t.toString()}))?n:n.concat([t.toString()]).sort((function(e,t){return(isNaN(Number(e))?0:Number(e))-(isNaN(Number(t))?0:Number(t))}))}},{key:"render",value:function(){var e=this,t=this.props,n=t.pageSize,r=t.locale,i=t.rootPrefixCls,o=t.changeSize,s=t.quickGo,a=t.goButton,c=t.selectComponentClass,l=t.buildOptionText,u=t.selectPrefixCls,d=t.disabled,f=this.state.goInputText,p="".concat(i,"-options"),_=c,v=null,b=null,g=null;if(!o&&!s)return null;var m=this.getPageSizeOptions();if(o&&_){var y=m.map((function(t,n){return h.a.createElement(_.Option,{key:n,value:t.toString()},(l||e.buildOptionText)(t))}));v=h.a.createElement(_,{disabled:d,prefixCls:u,showSearch:!1,className:"".concat(p,"-size-changer"),optionLabelProp:"children",dropdownMatchSelectWidth:!1,value:(n||m[0]).toString(),onChange:this.changeSize,getPopupContainer:function(e){return e.parentNode}},y)}return s&&(a&&(g="boolean"==typeof a?h.a.createElement("button",{type:"button",onClick:this.go,onKeyUp:this.go,disabled:d,className:"".concat(p,"-quick-jumper-button")},r.jump_to_confirm):h.a.createElement("span",{onClick:this.go,onKeyUp:this.go},a)),b=h.a.createElement("div",{className:"".concat(p,"-quick-jumper")},r.jump_to,h.a.createElement("input",{disabled:d,type:"text",value:f,onChange:this.handleChange,onKeyUp:this.go,onBlur:this.handleBlur}),r.page,g)),h.a.createElement("li",{className:"".concat(p)},v,b)}}]),n}(h.a.Component);g.defaultProps={pageSizeOptions:["10","20","50","100"]};var m=g,y=n("N2Kk");function w(){}function S(e,t,n){var r=void 0===e?t.pageSize:e;return Math.floor((n.total-1)/r)+1}var C=function(e){Object(c.a)(n,e);var t=Object(l.a)(n);function n(e){var r;Object(s.a)(this,n),(r=t.call(this,e)).getJumpPrevPage=function(){return Math.max(1,r.state.current-(r.props.showLessItems?3:5))},r.getJumpNextPage=function(){return Math.min(S(void 0,r.state,r.props),r.state.current+(r.props.showLessItems?3:5))},r.getItemIcon=function(e,t){var n=r.props.prefixCls,i=e||h.a.createElement("button",{type:"button","aria-label":t,className:"".concat(n,"-item-link")});return"function"==typeof e&&(i=h.a.createElement(e,Object(o.a)({},r.props))),i},r.savePaginationNode=function(e){r.paginationNode=e},r.isValid=function(e){return"number"==typeof(t=e)&&isFinite(t)&&Math.floor(t)===t&&e!==r.state.current;var t},r.shouldDisplayQuickJumper=function(){var e=r.props,t=e.showQuickJumper,n=e.pageSize;return!(e.total<=n)&&t},r.handleKeyDown=function(e){e.keyCode!==v&&e.keyCode!==b||e.preventDefault()},r.handleKeyUp=function(e){var t=r.getValidValue(e);t!==r.state.currentInputValue&&r.setState({currentInputValue:t}),e.keyCode===_?r.handleChange(t):e.keyCode===v?r.handleChange(t-1):e.keyCode===b&&r.handleChange(t+1)},r.changePageSize=function(e){var t=r.state.current,n=S(e,r.state,r.props);t=t>n?n:t,0===n&&(t=r.state.current),"number"==typeof e&&("pageSize"in r.props||r.setState({pageSize:e}),"current"in r.props||r.setState({current:t,currentInputValue:t})),r.props.onShowSizeChange(t,e),"onChange"in r.props&&r.props.onChange&&r.props.onChange(t,e)},r.handleChange=function(e){var t=r.props.disabled,n=e;if(r.isValid(n)&&!t){var i=S(void 0,r.state,r.props);n>i?n=i:n<1&&(n=1),"current"in r.props||r.setState({current:n,currentInputValue:n});var o=r.state.pageSize;return r.props.onChange(n,o),n}return r.state.current},r.prev=function(){r.hasPrev()&&r.handleChange(r.state.current-1)},r.next=function(){r.hasNext()&&r.handleChange(r.state.current+1)},r.jumpPrev=function(){r.handleChange(r.getJumpPrevPage())},r.jumpNext=function(){r.handleChange(r.getJumpNextPage())},r.hasPrev=function(){return r.state.current>1},r.hasNext=function(){return r.state.current2?n-2:0),i=2;i=n?n:Number(t)}},{key:"getShowSizeChanger",value:function(){var e=this.props,t=e.showSizeChanger,n=e.total,r=e.totalBoundaryShowSizeChanger;return void 0!==t?t:n>r}},{key:"renderPrev",value:function(e){var t=this.props,n=t.prevIcon,r=(0,t.itemRender)(e,"prev",this.getItemIcon(n,"prev page")),i=!this.hasPrev();return Object(u.isValidElement)(r)?Object(u.cloneElement)(r,{disabled:i}):r}},{key:"renderNext",value:function(e){var t=this.props,n=t.nextIcon,r=(0,t.itemRender)(e,"next",this.getItemIcon(n,"next page")),i=!this.hasNext();return Object(u.isValidElement)(r)?Object(u.cloneElement)(r,{disabled:i}):r}},{key:"render",value:function(){var e=this,t=this.props,n=t.prefixCls,o=t.className,s=t.style,a=t.disabled,c=t.hideOnSinglePage,l=t.total,d=t.locale,_=t.showQuickJumper,v=t.showLessItems,b=t.showTitle,g=t.showTotal,y=t.simple,w=t.itemRender,C=t.showPrevNextJumpers,k=t.jumpPrevIcon,E=t.jumpNextIcon,O=t.selectComponentClass,x=t.selectPrefixCls,A=t.pageSizeOptions,j=this.state,L=j.current,R=j.pageSize,M=j.currentInputValue;if(!0===c&&l<=R)return null;var T=S(void 0,this.state,this.props),D=[],P=null,K=null,I=null,F=null,X=null,N=_&&_.goButton,B=v?1:2,H=L-1>0?L-1:0,U=L+1=2*B&&3!==L&&(D[0]=Object(u.cloneElement)(D[0],{className:"".concat(n,"-item-after-jump-prev")}),D.unshift(P)),T-L>=2*B&&L!==T-2&&(D[D.length-1]=Object(u.cloneElement)(D[D.length-1],{className:"".concat(n,"-item-before-jump-next")}),D.push(K)),1!==Y&&D.unshift(I),Z!==T&&D.push(F)}var ee=null;g&&(ee=h.a.createElement("li",{className:"".concat(n,"-total-text")},g(l,[0===l?0:(L-1)*R+1,L*R>l?l:L*R])));var te=!this.hasPrev()||!T,ne=!this.hasNext()||!T;return h.a.createElement("ul",Object(r.a)({className:f()(n,o,Object(i.a)({},"".concat(n,"-disabled"),a)),style:s,unselectable:"unselectable",ref:this.savePaginationNode},W),ee,h.a.createElement("li",{title:b?d.prev_page:null,onClick:this.prev,tabIndex:te?null:0,onKeyPress:this.runIfEnterPrev,className:f()("".concat(n,"-prev"),Object(i.a)({},"".concat(n,"-disabled"),te)),"aria-disabled":te},this.renderPrev(H)),D,h.a.createElement("li",{title:b?d.next_page:null,onClick:this.next,tabIndex:ne?null:0,onKeyPress:this.runIfEnterNext,className:f()("".concat(n,"-next"),Object(i.a)({},"".concat(n,"-disabled"),ne)),"aria-disabled":ne},this.renderNext(U)),h.a.createElement(m,{disabled:a,locale:d,rootPrefixCls:n,selectComponentClass:O,selectPrefixCls:x,changeSize:this.getShowSizeChanger()?this.changePageSize:null,current:L,pageSize:R,pageSizeOptions:A,quickGo:this.shouldDisplayQuickJumper()?this.handleChange:null,goButton:N}))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n={};if("current"in e&&(n.current=e.current,e.current!==t.current&&(n.currentInputValue=n.current)),"pageSize"in e&&e.pageSize!==t.pageSize){var r=t.current,i=S(e.pageSize,t,e);r=r>i?i:r,"current"in e||(n.current=r,n.currentInputValue=r),n.pageSize=e.pageSize}return n}}]),n}(h.a.Component);C.defaultProps={defaultCurrent:1,total:0,defaultPageSize:10,onChange:w,className:"",selectPrefixCls:"rc-select",prefixCls:"rc-pagination",selectComponentClass:null,hideOnSinglePage:!1,showPrevNextJumpers:!0,showQuickJumper:!1,showLessItems:!1,showTitle:!0,onShowSizeChange:w,locale:y.a,style:{},itemRender:function(e,t,n){return n},totalBoundaryShowSizeChanger:50};var k=C},"6/vW": /*!**********************************************!*\ !*** ./src/components/timer-panel/index.jsx ***! \**********************************************/ /*! exports provided: getTimer, default */ /*! exports used: default, getTimer */function(e,t,n){"use strict";n.d(t,"b",(function(){return l}));var r=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray */"tJVT"),i=n(/*! react */"q1tI"),o=n.n(i),s=n(/*! ../useInterval */"9VGf"),a=n(/*! ../mediator */"dhSg");function c(e){return e.toString().padStart(2,"0")}function l(e){var t=Math.floor(e/60),n=e%60,r=Math.floor(t/60);return"".concat(c(r),":").concat(c(t-60*r),":").concat(c(n))}t.a=function(e){var t=e.defaultTime,n=e.status,c=e.onUpdateCostTime,u=e.lastedGetTaskInfoTime,h=e.title,d=void 0===h?"":h,f=Object(i.useState)(t||0),p=Object(r.a)(f,2),_=p[0],v=p[1],b=Object(i.useRef)();return Object(i.useEffect)((function(){u&&(v(t),b.current=t)}),[t,u]),Object(i.useEffect)((function(){if(u)return a.a.subscribe("update-cost-time",(function(){2!==n&&c(b.current)}))}),[u]),Object(s.a)((function(){v(_+1),b.current=b.current+1}),2===n?null:1e3),o.a.createElement("span",null,d?"".concat(d,":"):null,l(_))}},"6BzB": /*!***********************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/utils/common.js ***! \***********************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shrinkBuf=function(e,t){if(e.length===t)return e;if(e.subarray)return e.subarray(0,t);return e.length=t,e},t.arraySet=function(e,t,n,r,i){if(t.subarray&&e.subarray)return void e.set(t.subarray(n,n+r),i);for(var o=0;o=32&&e<=255)return e;var t=r[e];return void 0!==t?t:16777216|e}};t.default=i},"815F": /*!***************************************************!*\ !*** ./node_modules/rc-tree/es/utils/treeUtil.js ***! \***************************************************/ /*! exports provided: getKey, warningWithoutKey, convertTreeToData, flattenTreeData, traverseDataNodes, convertDataToEntities, getTreeNodeProps, convertNodePropsToEventData */ /*! exports used: convertDataToEntities, convertNodePropsToEventData, convertTreeToData, flattenTreeData, getKey, getTreeNodeProps */function(e,t,n){"use strict";n.d(t,"e",(function(){return l})),n.d(t,"c",(function(){return u})),n.d(t,"d",(function(){return h})),n.d(t,"a",(function(){return f})),n.d(t,"f",(function(){return p})),n.d(t,"b",(function(){return _}));var r=n(/*! @babel/runtime/helpers/esm/toConsumableArray */"KQm4"),i=n(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),o=n(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),s=n(/*! rc-util/es/Children/toArray */"Zm9Q"),a=n(/*! rc-util/es/warning */"Kwbf"),c=n(/*! ../util */"OZM5");function l(e,t){return null!=e?e:t}function u(e){return function e(t){return Object(s.a)(t).map((function(t){if(!Object(c.i)(t))return Object(a.a)(!t,"Tree/TreeNode can only accept TreeNode as children."),null;var n=t.key,r=t.props,s=r.children,l=Object(o.a)(r,["children"]),u=Object(i.a)({key:n},l),h=e(s);return h.length&&(u.children=h),u})).filter((function(e){return e}))}(e)}function h(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=new Set(!0===t?[]:t),o=[];function s(e){var a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return e.map((function(u,h){var d=Object(c.h)(a?a.pos:"0",h),f=l(u.key,d),p=Object(i.a)(Object(i.a)({},u),{},{parent:a,pos:d,children:null,data:u,isStart:[].concat(Object(r.a)(a?a.isStart:[]),[0===h]),isEnd:[].concat(Object(r.a)(a?a.isEnd:[]),[h===e.length-1])});return o.push(p),!0===t||n.has(f)?p.children=s(u.children||[],p):p.children=[],p}))}return s(e),o}function d(e,t,n){var r;n?"string"==typeof n?r=function(e){return e[n]}:"function"==typeof n&&(r=function(e){return n(e)}):r=function(e,t){return l(e.key,t)},function n(i,o,s){var a=i?i.children:e,l=i?Object(c.h)(s.pos,o):"0";if(i){var u=r(i,l),h={node:i,index:o,pos:l,key:u,parentPos:s.node?s.pos:null,level:s.level+1};t(h)}a&&a.forEach((function(e,t){n(e,t,{node:i,pos:l,level:s?s.level+1:-1})}))}(null)}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.initWrapper,r=t.processEntity,i=t.onProcessFinished,o=arguments.length>2?arguments[2]:void 0,s={},a={},c={posEntities:s,keyEntities:a};return n&&(c=n(c)||c),d(e,(function(e){var t=e.node,n=e.index,i=e.pos,o=e.key,u=e.parentPos,h={node:t,index:n,key:o,pos:i,level:e.level},d=l(o,i);s[i]=h,a[d]=h,h.parent=s[u],h.parent&&(h.parent.children=h.parent.children||[],h.parent.children.push(h)),r&&r(h,c)}),o),i&&i(c),c}function p(e,t){var n=t.expandedKeys,r=t.selectedKeys,i=t.loadedKeys,o=t.loadingKeys,s=t.checkedKeys,a=t.halfCheckedKeys,c=t.dragOverNodeKey,l=t.dropPosition,u=t.keyEntities[e];return{eventKey:e,expanded:-1!==n.indexOf(e),selected:-1!==r.indexOf(e),loaded:-1!==i.indexOf(e),loading:-1!==o.indexOf(e),checked:-1!==s.indexOf(e),halfChecked:-1!==a.indexOf(e),pos:String(u?u.pos:""),dragOver:c===e&&0===l,dragOverGapTop:c===e&&-1===l,dragOverGapBottom:c===e&&1===l}}function _(e){var t=e.data,n=e.expanded,r=e.selected,o=e.checked,s=e.loaded,c=e.loading,l=e.halfChecked,u=e.dragOver,h=e.dragOverGapTop,d=e.dragOverGapBottom,f=e.pos,p=e.active,_=Object(i.a)(Object(i.a)({},t),{},{expanded:n,selected:r,checked:o,loaded:s,loading:c,halfChecked:l,dragOver:u,dragOverGapTop:h,dragOverGapBottom:d,pos:f,active:p});return"props"in _||Object.defineProperty(_,"props",{get:function(){return Object(a.a)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),e}}),_}},"8CQX": /*!*****************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/input/util.js ***! \*****************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.getKeycode=d,t.getKey=f,t.getKeysym=function(e){var t=f(e);if("Unidentified"===t)return null;if(t in c.default){var n=e.location;if("Meta"===t&&0===n&&(n=2),"Clear"===t&&3===n)"NumLock"===d(e)&&(n=0);if((void 0===n||n>3)&&(n=0),"Meta"===t){var r=d(e);if("AltLeft"===r)return i.default.XK_Meta_L;if("AltRight"===r)return i.default.XK_Meta_R}if("Clear"===t)if("NumLock"===d(e))return i.default.XK_Num_Lock;return c.default[t][n]}if(1!==t.length)return null;var s=t.charCodeAt();if(s)return o.default.lookup(s);return null};var i=h(n(/*! ./keysym.js */"mHUz")),o=h(n(/*! ./keysymdef.js */"8+yF")),s=h(n(/*! ./vkeys.js */"6Qwc")),a=h(n(/*! ./fixedkeys.js */"gIYZ")),c=h(n(/*! ./domkeytable.js */"mTgk")),l=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=u();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var s=i?Object.getOwnPropertyDescriptor(e,o):null;s&&(s.get||s.set)?Object.defineProperty(n,o,s):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(/*! ../util/browser.js */"GdRQ"));function u(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return u=function(){return e},e}function h(e){return e&&e.__esModule?e:{default:e}}function d(e){if(e.code){switch(e.code){case"OSLeft":return"MetaLeft";case"OSRight":return"MetaRight"}return e.code}if("keypress"!==e.type&&e.keyCode in s.default){var t=s.default[e.keyCode];if(l.isMac()&&"ContextMenu"===t&&(t="MetaRight"),2===e.location)switch(t){case"ShiftLeft":return"ShiftRight";case"ControlLeft":return"ControlRight";case"AltLeft":return"AltRight"}if(3===e.location)switch(t){case"Delete":return"NumpadDecimal";case"Insert":return"Numpad0";case"End":return"Numpad1";case"ArrowDown":return"Numpad2";case"PageDown":return"Numpad3";case"ArrowLeft":return"Numpad4";case"ArrowRight":return"Numpad6";case"Home":return"Numpad7";case"ArrowUp":return"Numpad8";case"PageUp":return"Numpad9";case"Enter":return"NumpadEnter"}return t}return"Unidentified"}function f(e){if(void 0!==e.key){switch(e.key){case"Spacebar":return" ";case"Esc":return"Escape";case"Scroll":return"ScrollLock";case"Win":return"Meta";case"Apps":return"ContextMenu";case"Up":return"ArrowUp";case"Left":return"ArrowLeft";case"Right":return"ArrowRight";case"Down":return"ArrowDown";case"Del":return"Delete";case"Divide":return"/";case"Multiply":return"*";case"Subtract":return"-";case"Add":return"+";case"Decimal":return e.char}switch(e.key){case"OS":return"Meta";case"LaunchMyComputer":return"LaunchApplication1";case"LaunchCalculator":return"LaunchApplication2"}switch(e.key){case"UIKeyInputUpArrow":return"ArrowUp";case"UIKeyInputDownArrow":return"ArrowDown";case"UIKeyInputLeftArrow":return"ArrowLeft";case"UIKeyInputRightArrow":return"ArrowRight";case"UIKeyInputEscape":return"Escape"}if("\0"===e.key&&"NumpadDecimal"===e.code)return"Delete";if(!l.isIE()&&!l.isEdge())return e.key;if(1!==e.key.length&&"Unidentified"!==e.key)return e.key}var t=d(e);return t in a.default?a.default[t]:e.charCode?String.fromCharCode(e.charCode):"Unidentified"}},"8K/p": /*!*********************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/decoders/tight.js ***! \*********************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=a();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var s=i?Object.getOwnPropertyDescriptor(e,o):null;s&&(s.get||s.set)?Object.defineProperty(n,o,s):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(/*! ../util/logging.js */"Lo0S")),s=(i=n(/*! ../inflator.js */"ItS6"))&&i.__esModule?i:{default:i};function a(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return a=function(){return e},e}function c(e,t){for(var n=0;n>c&1&&(this._zlibs[c].reset(),o.Info("Reset zlib stream "+c));this._ctl=this._ctl>>4}var l;if(8===this._ctl)l=this._fillRect(e,t,n,r,i,s,a);else if(9===this._ctl)l=this._jpegRect(e,t,n,r,i,s,a);else if(10===this._ctl)l=this._pngRect(e,t,n,r,i,s,a);else{if(0!=(128&this._ctl))throw new Error("Illegal tight compression received (ctl: "+this._ctl+")");l=this._basicRect(this._ctl,e,t,n,r,i,s,a)}return l&&(this._ctl=null),l}},{key:"_fillRect",value:function(e,t,n,r,i,o,s){if(i.rQwait("TIGHT",3))return!1;var a=i.rQi,c=i.rQ;return o.fillRect(e,t,n,r,[c[a+2],c[a+1],c[a]],!1),i.rQskipBytes(3),!0}},{key:"_jpegRect",value:function(e,t,n,r,i,o,s){var a=this._readData(i);return null!==a&&(o.imageRect(e,t,n,r,"image/jpeg",a),!0)}},{key:"_pngRect",value:function(e,t,n,r,i,o,s){throw new Error("PNG received in standard Tight rect")}},{key:"_basicRect",value:function(e,t,n,r,i,o,s,a){if(null===this._filter)if(4&e){if(o.rQwait("TIGHT",1))return!1;this._filter=o.rQshift8()}else this._filter=0;var c,l=3&e;switch(this._filter){case 0:c=this._copyFilter(l,t,n,r,i,o,s,a);break;case 1:c=this._paletteFilter(l,t,n,r,i,o,s,a);break;case 2:c=this._gradientFilter(l,t,n,r,i,o,s,a);break;default:throw new Error("Illegal tight filter received (ctl: "+this._filter+")")}return c&&(this._filter=null),c}},{key:"_copyFilter",value:function(e,t,n,r,i,o,s,a){var c,l=r*i*3;if(l<12){if(o.rQwait("TIGHT",l))return!1;c=o.rQshiftBytes(l)}else{if(null===(c=this._readData(o)))return!1;this._zlibs[e].setInput(c),c=this._zlibs[e].inflate(l),this._zlibs[e].setInput(null)}return s.blitRgbImage(t,n,r,i,c,0,!1),!0}},{key:"_paletteFilter",value:function(e,t,n,r,i,o,s,a){if(0===this._numColors){if(o.rQwait("TIGHT palette",1))return!1;var c=o.rQpeek8()+1,l=3*c;if(o.rQwait("TIGHT palette",1+l))return!1;this._numColors=c,o.rQskipBytes(1),o.rQshiftTo(this._palette,l)}var u,h=this._numColors<=2?1:8,d=Math.floor((r*h+7)/8)*i;if(d<12){if(o.rQwait("TIGHT",d))return!1;u=o.rQshiftBytes(d)}else{if(null===(u=this._readData(o)))return!1;this._zlibs[e].setInput(u),u=this._zlibs[e].inflate(d),this._zlibs[e].setInput(null)}return 2==this._numColors?this._monoRect(t,n,r,i,u,this._palette,s):this._paletteRect(t,n,r,i,u,this._palette,s),this._numColors=0,!0}},{key:"_monoRect",value:function(e,t,n,r,i,o,s){for(var a=this._getScratchBuffer(n*r*4),c=Math.floor((n+7)/8),l=Math.floor(n/8),u=0;u=0;p--)h=4*(u*n+8*f+7-p),d=3*(i[u*c+f]>>p&1),a[h]=o[d],a[h+1]=o[d+1],a[h+2]=o[d+2],a[h+3]=255;for(var _=7;_>=8-n%8;_--)h=4*(u*n+8*f+7-_),d=3*(i[u*c+f]>>_&1),a[h]=o[d],a[h+1]=o[d+1],a[h+2]=o[d+2],a[h+3]=255}s.blitRgbxImage(e,t,n,r,a,0,!1)}},{key:"_paletteRect",value:function(e,t,n,r,i,o,s){for(var a=this._getScratchBuffer(n*r*4),c=n*r*4,l=0,u=0;l1&&void 0!==arguments[1]?arguments[1]:{};if(!Object(r.a)())return null;var o,s=document.createElement("style");(null===(t=n.csp)||void 0===t?void 0:t.nonce)&&(s.nonce=null===(o=n.csp)||void 0===o?void 0:o.nonce);s.innerHTML=e;var a=i(n),c=a.firstChild;return n.prepend&&a.prepend?a.prepend(s):n.prepend&&c?a.insertBefore(s,c):a.appendChild(s),s}var s=new Map;function a(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=i(n);if(!s.has(r)){var a=o("",n),c=a.parentNode;s.set(r,c),c.removeChild(a)}var l=Array.from(s.get(r).children).find((function(e){return"STYLE"===e.tagName&&e["rc-util-key"]===t}));if(l){var u,h,d;if((null===(u=n.csp)||void 0===u?void 0:u.nonce)&&l.nonce!==(null===(h=n.csp)||void 0===h?void 0:h.nonce))l.nonce=null===(d=n.csp)||void 0===d?void 0:d.nonce;return l.innerHTML!==e&&(l.innerHTML=e),l}var f=o(e,n);return f["rc-util-key"]=t,f}},BUUv: /*!***********************************************!*\ !*** ./src/pages/Innovation/Tasks/index.less ***! \***********************************************/ /*! no static exports found */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){},BWJ9: /*!********************************************************!*\ !*** ./src/pages/Innovation/Tasks/vnc-view/index.less ***! \********************************************************/ /*! no static exports found */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){},E1Sb: /*!*******************************************************!*\ !*** ./src/pages/Innovation/Tasks/resize-enlarge.png ***! \*******************************************************/ /*! no static exports found */ /*! exports used: default */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t){e.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACgAAACgCAYAAAB+HS7YAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTM4IDc5LjE1OTgyNCwgMjAxNi8wOS8xNC0wMTowOTowMSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTcgKFdpbmRvd3MpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOjczMUZFNjhCMDE3NzExRUJCOEU5RDg5RTZBOTI5QTU3IiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOjczMUZFNjhDMDE3NzExRUJCOEU5RDg5RTZBOTI5QTU3Ij4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NzMxRkU2ODkwMTc3MTFFQkI4RTlEODlFNkE5MjlBNTciIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6NzMxRkU2OEEwMTc3MTFFQkI4RTlEODlFNkE5MjlBNTciLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz7zBaLcAAACAElEQVR42uzdzyvDcRzH8ffsZiVc/IjbkOTuShN/gXIgYi5y2AlpFBL/AAdLiXBgBwfUxplmyU2tRK4sTey0+H6+RbKD7Gtfb/V817t963t59Nnn9f58+7aap6LO/yq6KmN13OoJq1MehcD3erS6rUT0VrnVC5qBpgLagWXagQIQIECAAAECBAgQIECAAAECBAgQIECAAAECBAgQIECAAAECBAgQIECAABUCD6Lbkr5L2W2uv9bS3LR4vd6iAb/9BaaBfa7K+oa8+0exEwmOheT5+UXnV9zd2SEHeztSU12ldw+2tjRLbH/X/lQbktqaansluwLtelPs85XKZmRFggN9eseMSbVJ9+Js2HHCizoHRwb7ZWN12V5VtYPaacJdOUmcJNy1o67QhLt6FheScNcfFkyqmxr9eoGHsWMZD8/qBCYvLmV4NCS5XE4f8PrmVnoHRySbzeoLyf1DWnr6huxPdWPGrJhZObOC6ga12Wtmz5m9p/Kom5yZt1Or8mFhbWNLIuubOh+3fjrrXAUWMutcAxY661wBOpl1RQc6nXVFBf7GrHMEPEskP65PE+d5901anc46R68+/rp4/QYQIECAAAECBAgQIECAAAECBAgQIECAAAECBAgQIECAAAECBAgQIECAAP8dMKMdGNcMNH9eMaUR+GR11Oo2q6/eBBgA/5+hicfO9/sAAAAASUVORK5CYII="},E9nw: /*!************************************************!*\ !*** ./node_modules/toggle-selection/index.js ***! \************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t){e.exports=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,n=[],r=0;r=48&&e.keyCode<=57)t=e.keyCode;else if(e.keyCode>=65&&e.keyCode<=90){var r=String.fromCharCode(e.keyCode);t=(r=e.shiftKey?r.toUpperCase():r.toLowerCase()).charCodeAt()}else t=0;this._sendKeyEvent(t,n,!0)}}},{key:"_handleKeyUp",value:function(e){(0,s.stopEvent)(e);var t=this._getKeyCode(e);if(this._altGrArmed&&(this._altGrArmed=!1,clearTimeout(this._altGrTimeout),this._sendKeyEvent(c.default.XK_Control_L,"ControlLeft",!0)),(l.isMac()||l.isIOS())&&"CapsLock"===t)return this._sendKeyEvent(c.default.XK_Caps_Lock,"CapsLock",!0),void this._sendKeyEvent(c.default.XK_Caps_Lock,"CapsLock",!1);this._sendKeyEvent(this._keyDownList[t],t,!1),!l.isWindows()||"ShiftLeft"!==t&&"ShiftRight"!==t||("ShiftRight"in this._keyDownList&&this._sendKeyEvent(this._keyDownList.ShiftRight,"ShiftRight",!1),"ShiftLeft"in this._keyDownList&&this._sendKeyEvent(this._keyDownList.ShiftLeft,"ShiftLeft",!1))}},{key:"_handleAltGrTimeout",value:function(){this._altGrArmed=!1,clearTimeout(this._altGrTimeout),this._sendKeyEvent(c.default.XK_Control_L,"ControlLeft",!0)}},{key:"_allKeysUp",value:function(){for(var e in o.Debug(">> Keyboard.allKeysUp"),this._keyDownList)this._sendKeyEvent(this._keyDownList[e],e,!1);o.Debug("<< Keyboard.allKeysUp")}},{key:"_checkAlt",value:function(e){if(!e.skipCheckAlt&&!e.altKey){var t=this._target,n=this._keyDownList;["AltLeft","AltRight"].forEach((function(e){if(e in n){var r=new KeyboardEvent("keyup",{key:n[e],code:e});r.skipCheckAlt=!0,t.dispatchEvent(r)}}))}}},{key:"grab",value:function(){if(this._target.addEventListener("keydown",this._eventHandlers.keydown),this._target.addEventListener("keyup",this._eventHandlers.keyup),this._target.addEventListener("keypress",this._eventHandlers.keypress),window.addEventListener("blur",this._eventHandlers.blur),l.isWindows()&&l.isFirefox()){var e=this._eventHandlers.checkalt;["mousedown","mouseup","mousemove","wheel","touchstart","touchend","touchmove","keydown","keyup"].forEach((function(t){return document.addEventListener(t,e,{capture:!0,passive:!0})}))}}},{key:"ungrab",value:function(){if(l.isWindows()&&l.isFirefox()){var e=this._eventHandlers.checkalt;["mousedown","mouseup","mousemove","wheel","touchstart","touchend","touchmove","keydown","keyup"].forEach((function(t){return document.removeEventListener(t,e)}))}this._target.removeEventListener("keydown",this._eventHandlers.keydown),this._target.removeEventListener("keyup",this._eventHandlers.keyup),this._target.removeEventListener("keypress",this._eventHandlers.keypress),window.removeEventListener("blur",this._eventHandlers.blur),this._allKeysUp()}}])&&d(t.prototype,n),r&&d(t,r),e}();t.default=f},GQ8N: /*!***************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/int.js ***! \***************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toUnsigned32bit=function(e){return e>>>0},t.toSigned32bit=function(e){return 0|e}},GdRQ: /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/browser.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.isMac=function(){return navigator&&!!/mac/i.exec(navigator.platform)},t.isWindows=function(){return navigator&&!!/win/i.exec(navigator.platform)},t.isIOS=function(){return navigator&&(!!/ipad/i.exec(navigator.platform)||!!/iphone/i.exec(navigator.platform)||!!/ipod/i.exec(navigator.platform))},t.isSafari=function(){return navigator&&-1!==navigator.userAgent.indexOf("Safari")&&-1===navigator.userAgent.indexOf("Chrome")},t.isIE=function(){return navigator&&!!/trident/i.exec(navigator.userAgent)},t.isEdge=function(){return navigator&&!!/edge/i.exec(navigator.userAgent)},t.isFirefox=function(){return navigator&&!!/firefox/i.exec(navigator.userAgent)},t.hasScrollbarGutter=t.supportsImageMetadata=t.supportsCursorURIs=t.dragThreshold=t.isTouchDevice=void 0;var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(n,s,a):n[s]=e[s]}n.default=e,t&&t.set(e,n);return n}(n(/*! ./logging.js */"Lo0S"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}var s="ontouchstart"in document.documentElement||void 0!==document.ontouchstart||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0;t.isTouchDevice=s,window.addEventListener("touchstart",(function e(){t.isTouchDevice=s=!0,window.removeEventListener("touchstart",e,!1)}),!1);var a=10*(window.devicePixelRatio||1);t.dragThreshold=a;var c=!1;try{var l=document.createElement("canvas");l.style.cursor='url("data:image/x-icon;base64,AAACAAEACAgAAAIAAgA4AQAAFgAAACgAAAAIAAAAEAAAAAEAIAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAD/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////AAAAAAAAAAAAAAAAAAAAAA==") 2 2, default',0===l.style.cursor.indexOf("url")?(i.Info("Data URI scheme cursor supported"),c=!0):i.Warn("Data URI scheme cursor not supported")}catch(e){i.Error("Data URI scheme cursor test exception: "+e)}var u=c;t.supportsCursorURIs=u;var h=!1;try{new ImageData(new Uint8ClampedArray(4),1,1),h=!0}catch(e){}var d=h;t.supportsImageMetadata=d;var f=!0;try{var p=document.createElement("div");p.style.visibility="hidden",p.style.overflow="scroll",document.body.appendChild(p);var _=document.createElement("div");p.appendChild(_);var v=p.offsetWidth-_.offsetWidth;p.parentNode.removeChild(p),f=0!=v}catch(e){i.Error("Scrollbar test exception: "+e)}var b=f;t.hasScrollbarGutter=b},GfqC: /*!********************************************************!*\ !*** ./node_modules/rc-upload/es/index.js + 6 modules ***! \********************************************************/ /*! exports provided: default */ /*! exports used: default */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";var r=n("q1tI"),i=n.n(r),o=n("TSYQ"),s=n.n(o);function a(e){var t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch(e){return t}}function c(e){var t=new XMLHttpRequest;e.onProgress&&t.upload&&(t.upload.onprogress=function(t){t.total>0&&(t.percent=t.loaded/t.total*100),e.onProgress(t)});var n=new FormData;e.data&&Object.keys(e.data).forEach((function(t){var r=e.data[t];Array.isArray(r)?r.forEach((function(e){n.append(t+"[]",e)})):n.append(t,e.data[t])})),e.file instanceof Blob?n.append(e.filename,e.file,e.file.name):n.append(e.filename,e.file),t.onerror=function(t){e.onError(t)},t.onload=function(){return t.status<200||t.status>=300?e.onError(function(e,t){var n="cannot "+e.method+" "+e.action+" "+t.status+"'",r=new Error(n);return r.status=t.status,r.method=e.method,r.url=e.action,r}(e,t),a(t)):e.onSuccess(a(t),t)},t.open(e.method,e.action,!0),e.withCredentials&&"withCredentials"in t&&(t.withCredentials=!0);var r=e.headers||{};return null!==r["X-Requested-With"]&&t.setRequestHeader("X-Requested-With","XMLHttpRequest"),Object.keys(r).forEach((function(e){null!==r[e]&&t.setRequestHeader(e,r[e])})),t.send(n),{abort:function(){t.abort()}}}var l=+new Date,u=0;function h(){return"rc-upload-"+l+"-"+ ++u}var d=function(e,t){if(e&&t){var n=Array.isArray(t)?t:t.split(","),r=e.name||"",i=e.type||"",o=i.replace(/\/.*$/,"");return n.some((function(e){var t,n,s=e.trim();return"."===s.charAt(0)?(t=r.toLowerCase(),n=s.toLowerCase(),-1!==t.indexOf(n,t.length-n.length)):/\/\*$/.test(s)?o===s.replace(/\/.*$/,""):i===s}))}return!0};var f=function(e,t,n){var r=function e(r,i){i=i||"",r.isFile?r.file((function(e){n(e)&&(r.fullPath&&!e.webkitRelativePath&&(Object.defineProperties(e,{webkitRelativePath:{writable:!0}}),e.webkitRelativePath=r.fullPath.replace(/^\//,""),Object.defineProperties(e,{webkitRelativePath:{writable:!1}})),t([e]))})):r.isDirectory&&function(e,t){var n=e.createReader(),r=[];!function e(){n.readEntries((function(n){var i=Array.prototype.slice.apply(n);r=r.concat(i),!i.length?t(r):e()}))}()}(r,(function(t){t.forEach((function(t){e(t,""+i+r.name+"/")}))}))};e.forEach((function(e){r(e.webkitGetAsEntry())}))},p=Object.assign||function(e){for(var t=1;t=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(n,["component","prefixCls","className","disabled","id","style","multiple","accept","children","directory","openFileDialogOnClick","onMouseEnter","onMouseLeave"]),w=s()((b(e={},o,!0),b(e,o+"-disabled",c),b(e,a,a),e)),S=c?{}:{onClick:v?this.onClick:function(){},onKeyDown:v?this.onKeyDown:function(){},onMouseEnter:g,onMouseLeave:m,onDrop:this.onFileDrop,onDragOver:this.onFileDrop,tabIndex:"0"};return i.a.createElement(r,p({},S,{className:w,role:"button",style:u}),i.a.createElement("input",p({},(t=y,Object.keys(t).reduce((function(e,n){return"data-"!==n.substr(0,5)&&"aria-"!==n.substr(0,5)&&"role"!==n||(e[n]=t[n]),e}),{})),{id:l,type:"file",ref:this.saveFileInput,onClick:function(e){return e.stopPropagation()},key:this.state.uid,style:{display:"none"},accept:d,directory:_?"directory":null,webkitdirectory:_?"webkitdirectory":null,multiple:h,onChange:this.onChange})),f)}}]),t}(r.Component),w=Object.assign||function(e){for(var t=1;tthis.chunkSize&&(this.chunkSize=e,this.strm.output=new Uint8Array(this.chunkSize)),this.strm.next_out=0,this.strm.avail_out=e,(0,i.inflate)(this.strm,0)<0)throw new Error("zlib inflate failed");if(this.strm.next_out!=e)throw new Error("Incomplete zlib block");return new Uint8Array(this.strm.output.buffer,0,this.strm.next_out)}},{key:"reset",value:function(){(0,i.inflateReset)(this.strm)}}])&&s(t.prototype,n),r&&s(t,r),e}();t.default=a},IxHN: /*!******************************************!*\ !*** ./src/components/Spinner/index.tsx ***! \******************************************/ /*! exports provided: default */ /*! exports used: default */function(e,t,n){"use strict";var r=n(/*! react */"q1tI"),i=n.n(r),o=n(/*! ./index.less?modules */"07cG"),s=n.n(o);t.a=function(e){var t=e.message,n=e.className,r=e.children,o=e.style,a=void 0===o?{}:o;return i.a.createElement("div",{className:"".concat(s.a.idsRingWrapper," ").concat(n)},i.a.createElement("div",{className:s.a.ldsRing},i.a.createElement("div",null),i.a.createElement("div",null),i.a.createElement("div",null),i.a.createElement("div",null)),t?i.a.createElement("p",{style:a},t):null,r)}},J66h: /*!******************************************!*\ !*** ./node_modules/js-base64/base64.js ***! \******************************************/ /*! no static exports found */ /*! exports used: Base64 */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){(function(n){var r;!function(n,i){e.exports=function(n){"use strict";var i,o=(n=n||{}).Base64,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=function(e){for(var t={},n=0,r=e.length;n>>6)+c(128|63&t):c(224|t>>>12&15)+c(128|t>>>6&63)+c(128|63&t);var t=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);return c(240|t>>>18&7)+c(128|t>>>12&63)+c(128|t>>>6&63)+c(128|63&t)},u=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,h=function(e){return e.replace(u,l)},d=function(e){var t=[0,2,1][e.length%3],n=e.charCodeAt(0)<<16|(e.length>1?e.charCodeAt(1):0)<<8|(e.length>2?e.charCodeAt(2):0);return[s.charAt(n>>>18),s.charAt(n>>>12&63),t>=2?"=":s.charAt(n>>>6&63),t>=1?"=":s.charAt(63&n)].join("")},f=n.btoa&&"function"==typeof n.btoa?function(e){return n.btoa(e)}:function(e){if(e.match(/[^\x00-\xFF]/))throw new RangeError("The string contains invalid characters.");return e.replace(/[\s\S]{1,3}/g,d)},p=function(e){return f(h(String(e)))},_=function(e){return e.replace(/[+\/]/g,(function(e){return"+"==e?"-":"_"})).replace(/=/g,"")},v=function(e,t){return t?_(p(e)):p(e)};n.Uint8Array&&(i=function(e,t){for(var n="",r=0,i=e.length;r>>18)+s.charAt(l>>>12&63)+(void 0!==a?s.charAt(l>>>6&63):"=")+(void 0!==c?s.charAt(63&l):"=")}return t?_(n):n});var b,g=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,m=function(e){switch(e.length){case 4:var t=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return c(55296+(t>>>10))+c(56320+(1023&t));case 3:return c((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return c((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},y=function(e){return e.replace(g,m)},w=function(e){var t=e.length,n=t%4,r=(t>0?a[e.charAt(0)]<<18:0)|(t>1?a[e.charAt(1)]<<12:0)|(t>2?a[e.charAt(2)]<<6:0)|(t>3?a[e.charAt(3)]:0),i=[c(r>>>16),c(r>>>8&255),c(255&r)];return i.length-=[0,0,2,1][n],i.join("")},S=n.atob&&"function"==typeof n.atob?function(e){return n.atob(e)}:function(e){return e.replace(/\S{1,4}/g,w)},C=function(e){return S(String(e).replace(/[^A-Za-z0-9\+\/]/g,""))},k=function(e){return String(e).replace(/[-_]/g,(function(e){return"-"==e?"+":"/"})).replace(/[^A-Za-z0-9\+\/]/g,"")},E=function(e){return function(e){return y(S(e))}(k(e))};n.Uint8Array&&(b=function(e){return Uint8Array.from(C(k(e)),(function(e){return e.charCodeAt(0)}))});var O=function(){var e=n.Base64;return n.Base64=o,e};if(n.Base64={VERSION:"2.6.4",atob:C,btoa:f,fromBase64:E,toBase64:v,utob:h,encode:v,encodeURI:function(e){return v(e,!0)},btou:y,decode:E,noConflict:O,fromUint8Array:i,toUint8Array:b},"function"==typeof Object.defineProperty){var x=function(e){return{value:e,enumerable:!1,writable:!0,configurable:!0}};n.Base64.extendString=function(){Object.defineProperty(String.prototype,"fromBase64",x((function(){return E(this)}))),Object.defineProperty(String.prototype,"toBase64",x((function(e){return v(this,e)}))),Object.defineProperty(String.prototype,"toBase64URI",x((function(){return v(this,!0)})))}}n.Meteor&&(Base64=n.Base64);e.exports?e.exports.Base64=n.Base64:void 0===(r=function(){return n.Base64}.apply(t,[]))||(e.exports=r);return{Base64:n.Base64}}(n)}("undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n?n:this)}).call(this,n(/*! ./../@umijs/deps/compiled/webpack/4/global.js */"IyRk"))},JJs0: /*!*****************************************************************!*\ !*** ./src/pages/Innovation/Tasks/data-sets/index.less?modules ***! \*****************************************************************/ /*! no static exports found */ /*! exports used: default */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){e.exports={flex_box_center:"flex_box_center___XQaQv",flex_space_between:"flex_space_between___MKaIy",flex_box_vertical_center:"flex_box_vertical_center___1mxtL",flex_box_center_end:"flex_box_center_end___2F_Ix",flex_box_column:"flex_box_column___2uQCp",wrap:"wrap___3HzlV",list:"list___1j7BW",page:"page___1eDtu"}},JSwD: /*!************************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/zlib/inftrees.js ***! \************************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n,r,o,u,h,d){var f,p,_,v,b,g,m,y,w,S=d.bits,C=0,k=0,E=0,O=0,x=0,A=0,j=0,L=0,R=0,M=0,T=null,D=0,P=new i.Buf16(16),K=new i.Buf16(16),I=null,F=0;for(C=0;C<=15;C++)P[C]=0;for(k=0;k=1&&0===P[O];O--);x>O&&(x=O);if(0===O)return o[u++]=20971520,o[u++]=20971520,d.bits=1,0;for(E=1;E0&&(0===e||1!==O))return-1;for(K[1]=0,C=1;C<15;C++)K[C+1]=K[C]+P[C];for(k=0;k852||2===e&&R>592)return 1;for(;;){m=C-j,h[k]g?(y=I[F+h[k]],w=T[D+h[k]]):(y=96,w=0),f=1<>j)+(p-=f)]=m<<24|y<<16|w|0}while(0!==p);for(f=1<>=1;if(0!==f?(M&=f-1,M+=f):M=0,k++,0==--P[C]){if(C===O)break;C=t[n+h[k]]}if(C>x&&(M&v)!==_){for(0===j&&(j=x),b+=E,L=1<<(A=C-j);A+j852||2===e&&R>592)return 1;o[_=M&v]=x<<24|A<<16|b-u|0}}0!==M&&(o[b+M]=C-j<<24|64<<16|0);return d.bits=x,0};var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(n,s,a):n[s]=e[s]}n.default=e,t&&t.set(e,n);return n}(n(/*! ../utils/common.js */"6BzB"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}var s=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],a=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],c=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],l=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]},LCi9: /*!***************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/input/gesturehandler.js ***! \***************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e,t){for(var n=0;n0&&Date.now()-this._tracked[0].started>250)return this._state=0,void this._ignored.push(e);if(this._waitingRelease)return this._state=0,void this._ignored.push(e);switch(this._tracked.push({id:e,started:Date.now(),active:!0,firstX:t,firstY:n,lastX:t,lastY:n,angle:0}),this._tracked.length){case 1:this._startLongpressTimeout();break;case 2:this._state&=-26,this._stopLongpressTimeout();break;case 3:this._state&=-99;break;default:this._state=0}}}},{key:"_touchMove",value:function(e,t,n){var r=this._tracked.find((function(t){return t.id===e}));if(void 0!==r){r.lastX=t,r.lastY=n;var i=t-r.firstX,o=n-r.firstY;if(r.firstX===r.lastX&&r.firstY===r.lastY||(r.angle=180*Math.atan2(o,i)/Math.PI),!this._hasDetectedGesture()){if(Math.hypot(i,o)<50)return;if(this._state&=-24,this._stopLongpressTimeout(),1!==this._tracked.length&&(this._state&=-9),2!==this._tracked.length&&(this._state&=-97),2===this._tracked.length){var s=this._tracked.find((function(t){return t.id!==e}));if(Math.hypot(s.firstX-s.lastX,s.firstY-s.lastY)>50){var a=Math.abs(r.angle-s.angle);a=Math.abs((a+180)%360-180),this._state&=a>90?-33:-65,this._isTwoTouchTimeoutRunning()&&this._stopTwoTouchTimeout()}else this._isTwoTouchTimeoutRunning()||this._startTwoTouchTimeout()}if(!this._hasDetectedGesture())return;this._pushEvent("gesturestart")}this._pushEvent("gesturemove")}}},{key:"_touchEnd",value:function(e,t,n){if(-1!==this._ignored.indexOf(e))return this._ignored.splice(this._ignored.indexOf(e),1),void(0===this._ignored.length&&0===this._tracked.length&&(this._state=127,this._waitingRelease=!1));if(!this._hasDetectedGesture()&&this._isTwoTouchTimeoutRunning()&&(this._stopTwoTouchTimeout(),this._state=0),!this._hasDetectedGesture()&&(this._state&=-105,this._state&=-17,this._stopLongpressTimeout(),!this._waitingRelease))switch(this._releaseStart=Date.now(),this._waitingRelease=!0,this._tracked.length){case 1:this._state&=-7;break;case 2:this._state&=-6}if(this._waitingRelease)if(Date.now()-this._releaseStart>250&&(this._state=0),this._tracked.some((function(e){return Date.now()-e.started>1e3}))&&(this._state=0),this._tracked.find((function(t){return t.id===e})).active=!1,this._hasDetectedGesture())this._pushEvent("gesturestart");else if(0!==this._state)return;this._hasDetectedGesture()&&this._pushEvent("gestureend");for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:1,n=M.length,r=0;r1&&void 0!==arguments[1]&&arguments[1];return Object(E.a)(e).map((function(e,n){if(!a.isValidElement(e)||!e.type)return null;var r=e.type.isSelectOptGroup,i=e.key,o=e.props,s=o.children,c=Object(l.a)(o,["children"]);return t||!r?O(e):Object(k.a)(Object(k.a)({key:"__RC_SELECT_GRP__".concat(null===i?n:i,"__"),label:i},c),{},{options:x(s)})})).filter((function(e){return e}))}var A=n("2Qr1"),j=n("qNPg"),L=n("U8pU"),R=n("Kwbf"),M=n("WKfj");var T=function(e){var t=e.mode,n=e.options,r=e.children,i=e.backfill,o=e.allowClear,s=e.placeholder,c=e.getInputElement,l=e.showSearch,u=e.onSearch,h=e.defaultOpen,d=e.autoFocus,f=e.labelInValue,p=e.value,_=e.inputValue,v=e.optionLabelProp,b="multiple"===t||"tags"===t,g=void 0!==l?l:b||"combobox"===t,m=n||x(r);if(Object(R.a)("tags"!==t||m.every((function(e){return!e.disabled})),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),"tags"===t||"combobox"===t){var y=m.some((function(e){return e.options?e.options.some((function(e){return"number"==typeof("value"in e?e.value:e.key)})):"number"==typeof("value"in e?e.value:e.key)}));Object(R.a)(!y,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(Object(R.a)("combobox"!==t||!v,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),Object(R.a)("combobox"===t||!i,"`backfill` only works with `combobox` mode."),Object(R.a)("combobox"===t||!c,"`getInputElement` only work with `combobox` mode."),Object(R.b)("combobox"!==t||!c||!o||!s,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),u&&!g&&"combobox"!==t&&"tags"!==t&&Object(R.a)(!1,"`onSearch` should work with `showSearch` instead of use alone."),Object(R.b)(!h||d,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),null!=p){var w=Object(M.d)(p);Object(R.a)(!f||w.every((function(e){return"object"===Object(L.a)(e)&&("key"in e||"value"in e)})),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),Object(R.a)(!b||Array.isArray(p),"`value` should be array when `mode` is `multiple` or `tags`")}if(r){var S=null;Object(E.a)(r).some((function(e){if(!a.isValidElement(e)||!e.type)return!1;var t=e.type;return!t.isSelectOption&&(t.isSelectOptGroup?!Object(E.a)(e.props.children).every((function(t){return!(a.isValidElement(t)&&e.type&&!t.type.isSelectOption)||(S=t.type,!1)})):(S=t,!0))})),S&&Object(R.a)(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(S.displayName||S.name||S,"`.")),Object(R.a)(void 0===_,"`inputValue` is deprecated, please use `searchValue` instead.")}},D=Object(j.a)({prefixCls:"rc-select",components:{optionList:m},convertChildrenToData:x,flattenOptions:A.d,getLabeledValue:A.e,filterOptions:A.b,isValueDisabled:A.g,findValueOption:A.c,warningProps:T,fillOptionsWithMissingValue:A.a}),P=function(e){Object(o.a)(n,e);var t=Object(s.a)(n);function n(){var e;return Object(r.a)(this,n),(e=t.apply(this,arguments)).selectRef=a.createRef(),e.focus=function(){e.selectRef.current.focus()},e.blur=function(){e.selectRef.current.blur()},e}return Object(i.a)(n,[{key:"render",value:function(){return a.createElement(D,Object.assign({ref:this.selectRef},this.props))}}]),n}(a.Component);P.Option=w,P.OptGroup=C;var K=P;t.c=K},Lo0S: /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/logging.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.initLogging=c,t.getLogging=function(){return r},t.Error=t.Warn=t.Info=t.Debug=void 0;var r="warn",i=function(){};t.Debug=i;var o=function(){};t.Info=o;var s=function(){};t.Warn=s;var a=function(){};function c(e){if(void 0===e?e=r:r=e,t.Debug=i=t.Info=o=t.Warn=s=t.Error=a=function(){},void 0!==window.console)switch(e){case"debug":t.Debug=i=console.debug.bind(window.console);case"info":t.Info=o=console.info.bind(window.console);case"warn":t.Warn=s=console.warn.bind(window.console);case"error":t.Error=a=console.error.bind(window.console);case"none":break;default:throw new window.Error("invalid logging type '"+e+"'")}}t.Error=a,c()},M8RZ: /*!**********************************!*\ !*** ./src/components/modal.tsx ***! \**********************************/ /*! exports provided: default */ /*! exports used: default */function(e,t,n){"use strict";n.d(t,"a",(function(){return u}));var r=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/classCallCheck */"fWQN"),i=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createClass */"mtLc"),o=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/inherits */"yKVA"),s=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/createSuper */"879j"),a=n(/*! react */"q1tI"),c=n.n(a),l=n(/*! react-dom */"i8i4"),u=function(e){Object(o.a)(n,e);var t=Object(s.a)(n);function n(e){var i;Object(r.a)(this,n),i=t.call(this,e);var o=window.document;return i.node=o.createElement("div"),o.body.appendChild(i.node),i}return Object(i.a)(n,[{key:"render",value:function(){var e=this.props.children;return Object(l.createPortal)(e,this.node)}},{key:"componentWillUnmount",value:function(){window.document.body.removeChild(this.node)}}]),n}(c.a.Component)},MZdM: /*!**************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/display.js ***! \**************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i,o=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=l();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o)){var s=i?Object.getOwnPropertyDescriptor(e,o):null;s&&(s.get||s.set)?Object.defineProperty(n,o,s):n[o]=e[o]}n.default=e,t&&t.set(e,n);return n}(n(/*! ./util/logging.js */"Lo0S")),s=(i=n(/*! ./base64.js */"N/zr"))&&i.__esModule?i:{default:i},a=n(/*! ./util/browser.js */"GdRQ"),c=n(/*! ./util/int.js */"GQ8N");function l(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return l=function(){return e},e}function u(e,t){for(var n=0;n> Display.constructor"),this._target=t,!this._target)throw new Error("Target must be set");if("string"==typeof this._target)throw new Error("target must be a DOM element");if(!this._target.getContext)throw new Error("no getContext method");if(this._targetCtx=this._target.getContext("2d"),this._viewportLoc={x:0,y:0,w:this._target.width,h:this._target.height},this._backbuffer=document.createElement("canvas"),this._drawCtx=this._backbuffer.getContext("2d"),this._damageBounds={left:0,top:0,right:this._backbuffer.width,bottom:this._backbuffer.height},o.Debug("User Agent: "+navigator.userAgent),!("createImageData"in this._drawCtx))throw new Error("Canvas does not support createImageData");this._tile16x16=this._drawCtx.createImageData(16,16),o.Debug("<< Display.constructor"),this._scale=1,this._clipViewport=!1,this.onflush=function(){}}var t,n,r;return t=e,(n=[{key:"viewportChangePos",value:function(e,t){var n=this._viewportLoc;e=Math.floor(e),t=Math.floor(t),this._clipViewport||(e=-n.w,t=-n.h);var r=n.x+n.w-1,i=n.y+n.h-1;e<0&&n.x+e<0&&(e=-n.x),r+e>=this._fbWidth&&(e-=r+e-this._fbWidth+1),n.y+t<0&&(t=-n.y),i+t>=this._fbHeight&&(t-=i+t-this._fbHeight+1),0===e&&0===t||(o.Debug("viewportChange deltaX: "+e+", deltaY: "+t),n.x+=e,n.y+=t,this._damage(n.x,n.y,n.w,n.h),this.flip())}},{key:"viewportChangeSize",value:function(e,t){this._clipViewport&&void 0!==e&&void 0!==t||(o.Debug("Setting viewport to full display region"),e=this._fbWidth,t=this._fbHeight),e=Math.floor(e),t=Math.floor(t),e>this._fbWidth&&(e=this._fbWidth),t>this._fbHeight&&(t=this._fbHeight);var n=this._viewportLoc;if(n.w!==e||n.h!==t){n.w=e,n.h=t;var r=this._target;r.width=e,r.height=t,this.viewportChangePos(0,0),this._damage(n.x,n.y,n.w,n.h),this.flip(),this._rescale(this._scale)}}},{key:"absX",value:function(e){return 0===this._scale?0:(0,c.toSigned32bit)(e/this._scale+this._viewportLoc.x)}},{key:"absY",value:function(e){return 0===this._scale?0:(0,c.toSigned32bit)(e/this._scale+this._viewportLoc.y)}},{key:"resize",value:function(e,t){this._prevDrawStyle="",this._fbWidth=e,this._fbHeight=t;var n=this._backbuffer;if(n.width!==e||n.height!==t){var r=null;n.width>0&&n.height>0&&(r=this._drawCtx.getImageData(0,0,n.width,n.height)),n.width!==e&&(n.width=e),n.height!==t&&(n.height=t),r&&this._drawCtx.putImageData(r,0,0)}var i=this._viewportLoc;this.viewportChangeSize(i.w,i.h),this.viewportChangePos(0,0)}},{key:"_damage",value:function(e,t,n,r){ethis._damageBounds.right&&(this._damageBounds.right=e+n),t+r>this._damageBounds.bottom&&(this._damageBounds.bottom=t+r)}},{key:"flip",value:function(e){if(0===this._renderQ.length||e){var t=this._damageBounds.left,n=this._damageBounds.top,r=this._damageBounds.right-t,i=this._damageBounds.bottom-n,o=t-this._viewportLoc.x,s=n-this._viewportLoc.y;o<0&&(r+=o,t-=o,o=0),s<0&&(i+=s,n-=s,s=0),o+r>this._viewportLoc.w&&(r=this._viewportLoc.w-o),s+i>this._viewportLoc.h&&(i=this._viewportLoc.h-s),r>0&&i>0&&this._targetCtx.drawImage(this._backbuffer,t,n,r,i,o,s,r,i),this._damageBounds.left=this._damageBounds.top=65535,this._damageBounds.right=this._damageBounds.bottom=0}else this._renderQPush({type:"flip"})}},{key:"pending",value:function(){return this._renderQ.length>0}},{key:"flush",value:function(){0===this._renderQ.length?this.onflush():this._flushing=!0}},{key:"fillRect",value:function(e,t,n,r,i,o){0===this._renderQ.length||o?(this._setFillColor(i),this._drawCtx.fillRect(e,t,n,r),this._damage(e,t,n,r)):this._renderQPush({type:"fill",x:e,y:t,width:n,height:r,color:i})}},{key:"copyImage",value:function(e,t,n,r,i,o,s){0===this._renderQ.length||s?(this._drawCtx.mozImageSmoothingEnabled=!1,this._drawCtx.webkitImageSmoothingEnabled=!1,this._drawCtx.msImageSmoothingEnabled=!1,this._drawCtx.imageSmoothingEnabled=!1,this._drawCtx.drawImage(this._backbuffer,e,t,i,o,n,r,i,o),this._damage(n,r,i,o)):this._renderQPush({type:"copy",oldX:e,oldY:t,x:n,y:r,width:i,height:o})}},{key:"imageRect",value:function(e,t,n,r,i,o){if(0!==n&&0!==r){var a=new Image;a.src="data: "+i+";base64,"+s.default.encode(o),this._renderQPush({type:"img",img:a,x:e,y:t,width:n,height:r})}}},{key:"startTile",value:function(e,t,n,r,i){this._tileX=e,this._tileY=t,this._tile=16===n&&16===r?this._tile16x16:this._drawCtx.createImageData(n,r);for(var o=i[2],s=i[1],a=i[0],c=this._tile.data,l=0;l=i?e/r.w:t/r.h}this._rescale(n)}},{key:"_rescale",value:function(e){this._scale=e;var t=this._viewportLoc,n=e*t.w+"px",r=e*t.h+"px";this._target.style.width===n&&this._target.style.height===r||(this._target.style.width=n,this._target.style.height=r)}},{key:"_setFillColor",value:function(e){var t="rgb("+e[2]+","+e[1]+","+e[0]+")";t!==this._prevDrawStyle&&(this._drawCtx.fillStyle=t,this._prevDrawStyle=t)}},{key:"_rgbImageData",value:function(e,t,n,r,i,o){for(var s=this._drawCtx.createImageData(n,r),a=s.data,c=0,l=o;c0;){var t=this._renderQ[0];switch(t.type){case"flip":this.flip(!0);break;case"copy":this.copyImage(t.oldX,t.oldY,t.x,t.y,t.width,t.height,!0);break;case"fill":this.fillRect(t.x,t.y,t.width,t.height,t.color,!0);break;case"blit":this.blitImage(t.x,t.y,t.width,t.height,t.data,0,!0);break;case"blitRgb":this.blitRgbImage(t.x,t.y,t.width,t.height,t.data,0,!0);break;case"blitRgbx":this.blitRgbxImage(t.x,t.y,t.width,t.height,t.data,0,!0);break;case"img":if(t.img.complete&&0!==t.img.width&&0!==t.img.height){if(t.img.width!==t.width||t.img.height!==t.height)return void o.Error("Decoded image has incorrect dimensions. Got "+t.img.width+"x"+t.img.height+". Expected "+t.width+"x"+t.height+".");this.drawImage(t.img,t.x,t.y)}else t.img._noVNCDisplay=this,t.img.addEventListener("load",this._resumeRenderQ),e=!1}e&&this._renderQ.shift()}0===this._renderQ.length&&this._flushing&&(this._flushing=!1,this.onflush())}},{key:"scale",get:function(){return this._scale},set:function(e){this._rescale(e)}},{key:"clipViewport",get:function(){return this._clipViewport},set:function(e){this._clipViewport=e;var t=this._viewportLoc;this.viewportChangeSize(t.w,t.h),this.viewportChangePos(0,0)}},{key:"width",get:function(){return this._fbWidth}},{key:"height",get:function(){return this._fbHeight}}])&&u(t.prototype,n),r&&u(t,r),e}();t.default=h},Mmt2: /*!**************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/websock.js ***! \**************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(n,s,a):n[s]=e[s]}n.default=e,t&&t.set(e,n);return n}(n(/*! ./util/logging.js */"Lo0S"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}function s(e,t){for(var n=0;n=0;n--)t+=this._rQ[this._rQi++]<<8*n;return t}},{key:"rQshiftStr",value:function(e){void 0===e&&(e=this.rQlen);for(var t="",n=0;n1&&void 0!==arguments[1]?arguments[1]:this.rQlen;return new Uint8Array(this._rQ.buffer,this._rQi+e,t-e)}},{key:"rQwait",value:function(e,t,n){if(this.rQlen0&&this._websocket.readyState===WebSocket.OPEN&&(this._websocket.send(this._encodeMessage()),this._sQlen=0)}},{key:"send",value:function(e){this._sQ.set(e,this._sQlen),this._sQlen+=e.length,this.flush()}},{key:"sendString",value:function(e){this.send(e.split("").map((function(e){return e.charCodeAt(0)})))}},{key:"off",value:function(e){this._eventHandlers[e]=function(){}}},{key:"on",value:function(e,t){this._eventHandlers[e]=t}},{key:"_allocateBuffers",value:function(){this._rQ=new Uint8Array(this._rQbufferSize),this._sQ=new Uint8Array(this._sQbufferSize)}},{key:"init",value:function(){this._allocateBuffers(),this._rQi=0,this._websocket=null}},{key:"open",value:function(e,t){var n=this;this.init(),this._websocket=new WebSocket(e,t),this._websocket.binaryType="arraybuffer",this._websocket.onmessage=this._recvMessage.bind(this),this._websocket.onopen=function(){i.Debug(">> WebSock.onopen"),n._websocket.protocol&&i.Info("Server choose sub-protocol: "+n._websocket.protocol),n._eventHandlers.open(),i.Debug("<< WebSock.onopen")},this._websocket.onclose=function(e){i.Debug(">> WebSock.onclose"),n._eventHandlers.close(e),i.Debug("<< WebSock.onclose")},this._websocket.onerror=function(e){i.Debug(">> WebSock.onerror: "+e),n._eventHandlers.error(e),i.Debug("<< WebSock.onerror: "+e)}}},{key:"close",value:function(){this._websocket&&(this._websocket.readyState!==WebSocket.OPEN&&this._websocket.readyState!==WebSocket.CONNECTING||(i.Info("Closing WebSocket connection"),this._websocket.close()),this._websocket.onmessage=function(){})}},{key:"_encodeMessage",value:function(){return new Uint8Array(this._sQ.buffer,0,this._sQlen)}},{key:"_expandCompactRQ",value:function(e){var t=8*(this._rQlen-this._rQi+e),n=this._rQbufferSize41943040&&(this._rQbufferSize=41943040,this._rQbufferSize-this.rQlenthis._rQbufferSize-this._rQlen&&this._expandCompactRQ(t.length),this._rQ.set(t,this._rQlen),this._rQlen+=t.length}},{key:"_recvMessage",value:function(e){this._DecodeMessage(e.data),this.rQlen>0?(this._eventHandlers.message(),this._rQlen==this._rQi&&(this._rQlen=0,this._rQi=0)):i.Debug("Ignoring empty message")}},{key:"sQ",get:function(){return this._sQ}},{key:"rQ",get:function(){return this._rQ}},{key:"rQi",get:function(){return this._rQi},set:function(e){this._rQi=e}},{key:"rQlen",get:function(){return this._rQlen-this._rQi}}])&&s(t.prototype,n),r&&s(t,r),e}();t.default=a},"N/zr": /*!*************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/base64.js ***! \*************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(n,s,a):n[s]=e[s]}n.default=e,t&&t.set(e,n);return n}(n(/*! ./util/logging.js */"Lo0S"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}var s={toBase64Table:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".split(""),base64Pad:"=",encode:function(e){for(var t="",n=e.length,r=n%3,i=0;i>2],t+=this.toBase64Table[((3&e[i])<<4)+(e[i+1]>>4)],t+=this.toBase64Table[((15&e[i+1])<<2)+(e[i+2]>>6)],t+=this.toBase64Table[63&e[i+2]];var o=n-r;return 2===r?(t+=this.toBase64Table[e[o]>>2],t+=this.toBase64Table[((3&e[o])<<4)+(e[o+1]>>4)],t+=this.toBase64Table[(15&e[o+1])<<2],t+=this.toBase64Table[64]):1===r&&(t+=this.toBase64Table[e[o]>>2],t+=this.toBase64Table[(3&e[o])<<4],t+=this.toBase64Table[64],t+=this.toBase64Table[64]),t},toBinaryTable:[-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63,52,53,54,55,56,57,58,59,60,61,-1,-1,-1,0,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,-1,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,-1,-1,-1,-1,-1],decode:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=e.indexOf("=")-t;n<0&&(n=e.length-t);for(var r=3*(n>>2)+Math.floor(n%4/1.5),o=new Array(r),s=0,a=0,c=0,l=t;l=8&&(s-=8,h||(o[c++]=a>>s&255),a&=(1<=0;l-=1){(t.get(l)||new Set).forEach((function(e){var t=e.parent,n=e.node;if(!r(n)&&e.parent&&!c.has(e.parent.key))if(r(e.parent.node))c.add(t.key);else{var i=!0,a=!1;(t.children||[]).filter((function(e){return!r(e.node)})).forEach((function(e){var t=e.key,n=o.has(t);i&&!n&&(i=!1),a||!n&&!s.has(t)||(a=!0)})),i&&o.add(t.key),a&&s.add(t.key),c.add(t.key)}}))}return{checkedKeys:Array.from(o),halfCheckedKeys:Array.from(i(s,o))}}(l,u,h,a):function(e,t,n,r,o){for(var s=new Set(e),a=new Set(t),c=0;c<=r;c+=1){(n.get(c)||new Set).forEach((function(e){var t=e.key,n=e.node,r=e.children,i=void 0===r?[]:r;s.has(t)||a.has(t)||o(n)||i.filter((function(e){return!o(e.node)})).forEach((function(e){s.delete(e.key)}))}))}a=new Set;for(var l=new Set,u=r;u>=0;u-=1){(n.get(u)||new Set).forEach((function(e){var t=e.parent,n=e.node;if(!o(n)&&e.parent&&!l.has(e.parent.key))if(o(e.parent.node))l.add(t.key);else{var r=!0,i=!1;(t.children||[]).filter((function(e){return!o(e.node)})).forEach((function(e){var t=e.key,n=s.has(t);r&&!n&&(r=!1),i||!n&&!a.has(t)||(i=!0)})),r||s.delete(t.key),i&&a.add(t.key),l.add(t.key)}}))}return{checkedKeys:Array.from(s),halfCheckedKeys:Array.from(i(a,s))}}(l,t.halfCheckedKeys,u,h,a)}},OLES: /*!*********************************************************!*\ !*** ./node_modules/rc-tooltip/es/index.js + 2 modules ***! \*********************************************************/ /*! exports provided: default */ /*! exports used: default */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tooltip/es/placements.js because of ./node_modules/antd/es/tooltip/placements.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-trigger/es/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";var r=n("U8pU"),i=n("VTBJ"),o=n("Ff2n"),s=n("q1tI"),a=n("uciX"),c=n("7ixt"),l=function(e){var t=e.overlay,n=e.prefixCls,r=e.id,i=e.overlayInnerStyle;return s.createElement("div",{className:"".concat(n,"-inner"),id:r,role:"tooltip",style:i},"function"==typeof t?t():t)},u=Object(s.forwardRef)((function(e,t){var n=e.overlayClassName,u=e.trigger,h=void 0===u?["hover"]:u,d=e.mouseEnterDelay,f=void 0===d?0:d,p=e.mouseLeaveDelay,_=void 0===p?.1:p,v=e.overlayStyle,b=e.prefixCls,g=void 0===b?"rc-tooltip":b,m=e.children,y=e.onVisibleChange,w=e.afterVisibleChange,S=e.transitionName,C=e.animation,k=e.placement,E=void 0===k?"right":k,O=e.align,x=void 0===O?{}:O,A=e.destroyTooltipOnHide,j=void 0!==A&&A,L=e.defaultVisible,R=e.getTooltipContainer,M=e.overlayInnerStyle,T=Object(o.a)(e,["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle"]),D=Object(s.useRef)(null);Object(s.useImperativeHandle)(t,(function(){return D.current}));var P=Object(i.a)({},T);"visible"in e&&(P.popupVisible=e.visible);var K=!1,I=!1;if("boolean"==typeof j)K=j;else if(j&&"object"===Object(r.a)(j)){var F=j.keepParent;K=!0===F,I=!1===F}return s.createElement(a.a,Object.assign({popupClassName:n,prefixCls:g,popup:function(){var t=e.arrowContent,n=void 0===t?null:t,r=e.overlay,i=e.id;return[s.createElement("div",{className:"".concat(g,"-arrow"),key:"arrow"},n),s.createElement(l,{key:"content",prefixCls:g,id:i,overlay:r,overlayInnerStyle:M})]},action:h,builtinPlacements:c.a,popupPlacement:E,ref:D,popupAlign:x,getPopupContainer:R,onPopupVisibleChange:y,afterPopupVisibleChange:w,popupTransitionName:S,popupAnimation:C,defaultPopupVisible:L,destroyPopupOnHide:K,autoDestroy:I,mouseLeaveDelay:_,popupStyle:v,mouseEnterDelay:f},P),m)}));t.a=u},OZM5: /*!*****************************************!*\ !*** ./node_modules/rc-tree/es/util.js ***! \*****************************************/ /*! exports provided: arrDel, arrAdd, posToArr, getPosition, isTreeNode, getDragNodesKeys, calcDropPosition, calcSelectedKeys, convertDataToTree, parseCheckedKeys, conductExpandParent, getDataAndAria */ /*! exports used: arrAdd, arrDel, calcDropPosition, calcSelectedKeys, conductExpandParent, getDataAndAria, getDragNodesKeys, getPosition, isTreeNode, parseCheckedKeys, posToArr */function(e,t,n){"use strict";n.d(t,"b",(function(){return s})),n.d(t,"a",(function(){return a})),n.d(t,"k",(function(){return c})),n.d(t,"h",(function(){return l})),n.d(t,"i",(function(){return u})),n.d(t,"g",(function(){return h})),n.d(t,"c",(function(){return d})),n.d(t,"d",(function(){return f})),n.d(t,"j",(function(){return p})),n.d(t,"e",(function(){return _})),n.d(t,"f",(function(){return v}));var r=n(/*! @babel/runtime/helpers/esm/toConsumableArray */"KQm4"),i=n(/*! @babel/runtime/helpers/esm/typeof */"U8pU"),o=(n(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),n(/*! react */"q1tI"),n(/*! rc-util/es/warning */"Kwbf"));n(/*! ./TreeNode */"WaYH");function s(e,t){var n=e.slice(),r=n.indexOf(t);return r>=0&&n.splice(r,1),n}function a(e,t){var n=e.slice();return-1===n.indexOf(t)&&n.push(t),n}function c(e){return e.split("-")}function l(e,t){return"".concat(e,"-").concat(t)}function u(e){return e&&e.type&&e.type.isTreeNode}function h(e,t){var n=[e];return function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];t.forEach((function(t){var r=t.key,i=t.children;n.push(r),e(i)}))}(t[e].children),n}function d(e,t){var n=e.clientY,r=t.selectHandle.getBoundingClientRect(),i=r.top,o=r.bottom,s=r.height,a=Math.max(.25*s,2);return n<=i+a?-1:n>=o-a?1:0}function f(e,t){if(e)return t.multiple?e.slice():e.length?[e[0]]:e}function p(e){if(!e)return null;var t;if(Array.isArray(e))t={checkedKeys:e,halfCheckedKeys:void 0};else{if("object"!==Object(i.a)(e))return Object(o.a)(!1,"`checkedKeys` is not an array or an object"),null;t={checkedKeys:e.checked||void 0,halfCheckedKeys:e.halfChecked||void 0}}return t}function _(e,t){var n=new Set;return(e||[]).forEach((function(e){!function e(r){if(!n.has(r)){var i=t[r];if(i){n.add(r);var o=i.parent;i.node.disabled||o&&e(o.key)}}}(e)})),Object(r.a)(n)}function v(e){var t={};return Object.keys(e).forEach((function(n){(n.startsWith("data-")||n.startsWith("aria-"))&&(t[n]=e[n])})),t}},P2ho: /*!************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/input/xtscancodes.js ***! \************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={Again:57349,AltLeft:56,AltRight:57400,ArrowDown:57424,ArrowLeft:57419,ArrowRight:57421,ArrowUp:57416,AudioVolumeDown:57390,AudioVolumeMute:57376,AudioVolumeUp:57392,Backquote:41,Backslash:43,Backspace:14,BracketLeft:26,BracketRight:27,BrowserBack:57450,BrowserFavorites:57446,BrowserForward:57449,BrowserHome:57394,BrowserRefresh:57447,BrowserSearch:57445,BrowserStop:57448,CapsLock:58,Comma:51,ContextMenu:57437,ControlLeft:29,ControlRight:57373,Convert:121,Copy:57464,Cut:57404,Delete:57427,Digit0:11,Digit1:2,Digit2:3,Digit3:4,Digit4:5,Digit5:6,Digit6:7,Digit7:8,Digit8:9,Digit9:10,Eject:57469,End:57423,Enter:28,Equal:13,Escape:1,F1:59,F10:68,F11:87,F12:88,F13:93,F14:94,F15:95,F16:85,F17:57347,F18:57463,F19:57348,F2:60,F20:90,F21:116,F22:57465,F23:109,F24:111,F3:61,F4:62,F5:63,F6:64,F7:65,F8:66,F9:67,Find:57409,Help:57461,Hiragana:119,Home:57415,Insert:57426,IntlBackslash:86,IntlRo:115,IntlYen:125,KanaMode:112,Katakana:120,KeyA:30,KeyB:48,KeyC:46,KeyD:32,KeyE:18,KeyF:33,KeyG:34,KeyH:35,KeyI:23,KeyJ:36,KeyK:37,KeyL:38,KeyM:50,KeyN:49,KeyO:24,KeyP:25,KeyQ:16,KeyR:19,KeyS:31,KeyT:20,KeyU:22,KeyV:47,KeyW:17,KeyX:45,KeyY:21,KeyZ:44,Lang3:120,Lang4:119,Lang5:118,LaunchApp1:57451,LaunchApp2:57377,LaunchMail:57452,MediaPlayPause:57378,MediaSelect:57453,MediaStop:57380,MediaTrackNext:57369,MediaTrackPrevious:57360,MetaLeft:57435,MetaRight:57436,Minus:12,NonConvert:123,NumLock:69,Numpad0:82,Numpad1:79,Numpad2:80,Numpad3:81,Numpad4:75,Numpad5:76,Numpad6:77,Numpad7:71,Numpad8:72,Numpad9:73,NumpadAdd:78,NumpadComma:126,NumpadDecimal:83,NumpadDivide:57397,NumpadEnter:57372,NumpadEqual:89,NumpadMultiply:55,NumpadParenLeft:57462,NumpadParenRight:57467,NumpadSubtract:74,Open:100,PageDown:57425,PageUp:57417,Paste:101,Pause:57414,Period:52,Power:57438,PrintScreen:84,Props:57350,Quote:40,ScrollLock:70,Semicolon:39,ShiftLeft:42,ShiftRight:54,Slash:53,Sleep:57439,Space:57,Suspend:57381,Tab:15,Undo:57351,WakeUp:57443}},P5Jw: /*!***********************************************************!*\ !*** ./node_modules/react-copy-to-clipboard/lib/index.js ***! \***********************************************************/ /*! no static exports found */ /*! exports used: CopyToClipboard */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";var r=n(/*! ./Component */"rHrb").CopyToClipboard;r.CopyToClipboard=r,e.exports=r},QV2g: /*!*********************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/zlib/crc32.js ***! \*********************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;r()},"SA+Z": /*!********************************************************!*\ !*** ./node_modules/@babel/runtime/helpers/toArray.js ***! \********************************************************/ /*! no static exports found */ /*! exports used: default */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){var r=n(/*! ./arrayWithHoles.js */"wTVA"),i=n(/*! ./iterableToArray.js */"EbDI"),o=n(/*! ./unsupportedIterableToArray.js */"ZhPi"),s=n(/*! ./nonIterableRest.js */"wkBT");e.exports=function(e){return r(e)||i(e)||o(e)||s()},e.exports.__esModule=!0,e.exports.default=e.exports},SFBS: /*!******************************************************!*\ !*** ./src/pages/Innovation/Tasks/header/index.less ***! \******************************************************/ /*! no static exports found */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){},SZEN: /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/element.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clientToElement=function(e,t,n){var r=n.getBoundingClientRect(),i={x:0,y:0};e=r.right?i.x=r.width-1:i.x=e-r.left;t=r.bottom?i.y=r.height-1:i.y=t-r.top;return i}},SgaC: /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/decoders/rre.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e,t){for(var n=0;n0;){if(i.rQwait("RRE",12))return!1;var c=i.rQshiftBytes(4),l=i.rQshift16(),u=i.rQshift16(),h=i.rQshift16(),d=i.rQshift16();o.fillRect(e+l,t+u,h,d,c),this._subrects--}return!0}}])&&r(t.prototype,n),i&&r(t,i),e}();t.default=i},VSMT: /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/strings.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeUTF8=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];try{return decodeURIComponent(escape(e))}catch(n){if(n instanceof URIError&&t)return e;throw n}},t.encodeUTF8=function(e){return unescape(encodeURIComponent(e))}},WaYH: /*!*********************************************************!*\ !*** ./node_modules/rc-tree/es/TreeNode.js + 1 modules ***! \*********************************************************/ /*! exports provided: InternalTreeNode, default */ /*! exports used: default */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createSuper.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tree/es/contextTypes.js because of ./node_modules/rc-tree/es/Tree.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tree/es/util.js because of ./node_modules/antd/es/tree/DirectoryTree.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-tree/es/utils/treeUtil.js because of ./node_modules/antd/es/tree/DirectoryTree.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";var r=n("rePB"),i=n("Ff2n"),o=n("VTBJ"),s=n("1OyB"),a=n("vuIU"),c=n("JX7q"),l=n("Ji7U"),u=n("LK+K"),h=n("q1tI"),d=n("TSYQ"),f=n.n(d),p=n("sboe"),_=n("OZM5"),v=function(e){var t=e.prefixCls,n=e.level,i=e.isStart,o=e.isEnd;if(!n)return null;for(var s="".concat(t,"-indent-unit"),a=[],c=0;c1&&void 0!==arguments[1]&&arguments[1],n=e.getAttribute("id")||e.getAttribute("data-reactid")||e.getAttribute("name");if(t&&A[n])return A[n];var r=window.getComputedStyle(e),i=r.getPropertyValue("box-sizing")||r.getPropertyValue("-moz-box-sizing")||r.getPropertyValue("-webkit-box-sizing"),o=parseFloat(r.getPropertyValue("padding-bottom"))+parseFloat(r.getPropertyValue("padding-top")),s=parseFloat(r.getPropertyValue("border-bottom-width"))+parseFloat(r.getPropertyValue("border-top-width")),a=x.map((function(e){return"".concat(e,":").concat(r.getPropertyValue(e))})).join(";"),c={sizingStyle:a,paddingSize:o,borderSize:s,boxSizing:i};return t&&n&&(A[n]=c),c}var L,R=n("Gytx"),M=n.n(R);!function(e){e[e.NONE=0]="NONE",e[e.RESIZING=1]="RESIZING",e[e.RESIZED=2]="RESIZED"}(L||(L={}));var T=function(e){Object(s.a)(n,e);var t=Object(a.a)(n);function n(e){var o;return Object(i.a)(this,n),(o=t.call(this,e)).nextFrameActionId=void 0,o.resizeFrameId=void 0,o.textArea=void 0,o.saveTextArea=function(e){o.textArea=e},o.handleResize=function(e){var t=o.state.resizeStatus,n=o.props,r=n.autoSize,i=n.onResize;t===L.NONE&&("function"==typeof i&&i(e),r&&o.resizeOnNextFrame())},o.resizeOnNextFrame=function(){cancelAnimationFrame(o.nextFrameActionId),o.nextFrameActionId=requestAnimationFrame(o.resizeTextarea)},o.resizeTextarea=function(){var e=o.props.autoSize;if(e&&o.textArea){var t=e.minRows,n=e.maxRows,r=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;w||((w=document.createElement("textarea")).setAttribute("tab-index","-1"),w.setAttribute("aria-hidden","true"),document.body.appendChild(w)),e.getAttribute("wrap")?w.setAttribute("wrap",e.getAttribute("wrap")):w.removeAttribute("wrap");var i=j(e,t),o=i.paddingSize,s=i.borderSize,a=i.boxSizing,c=i.sizingStyle;w.setAttribute("style","".concat(c,";").concat(O)),w.value=e.value||e.placeholder||"";var l,u=Number.MIN_SAFE_INTEGER,h=Number.MAX_SAFE_INTEGER,d=w.scrollHeight;if("border-box"===a?d+=s:"content-box"===a&&(d-=o),null!==n||null!==r){w.value=" ";var f=w.scrollHeight-o;null!==n&&(u=f*n,"border-box"===a&&(u=u+o+s),d=Math.max(u,d)),null!==r&&(h=f*r,"border-box"===a&&(h=h+o+s),l=d>h?"":"hidden",d=Math.min(h,d))}return{height:d,minHeight:u,maxHeight:h,overflowY:l,resize:"none"}}(o.textArea,!1,t,n);o.setState({textareaStyles:r,resizeStatus:L.RESIZING},(function(){cancelAnimationFrame(o.resizeFrameId),o.resizeFrameId=requestAnimationFrame((function(){o.setState({resizeStatus:L.RESIZED},(function(){o.resizeFrameId=requestAnimationFrame((function(){o.setState({resizeStatus:L.NONE}),o.fixFirefoxAutoScroll()}))}))}))}))}},o.renderTextArea=function(){var e=o.props,t=e.prefixCls,n=void 0===t?"rc-textarea":t,i=e.autoSize,s=e.onResize,a=e.className,h=e.disabled,d=o.state,f=d.textareaStyles,p=d.resizeStatus,_=Object(C.a)(o.props,["prefixCls","onPressEnter","autoSize","defaultValue","onResize"]),v=E()(n,a,Object(u.a)({},"".concat(n,"-disabled"),h));"value"in _&&(_.value=_.value||"");var b=Object(l.a)(Object(l.a)(Object(l.a)({},o.props.style),f),p===L.RESIZING?{overflowX:"hidden",overflowY:"hidden"}:null);return c.createElement(S,{onResize:o.handleResize,disabled:!(i||s)},c.createElement("textarea",Object(r.a)({},_,{className:v,style:b,ref:o.saveTextArea})))},o.state={textareaStyles:{},resizeStatus:L.NONE},o}return Object(o.a)(n,[{key:"componentDidUpdate",value:function(e){e.value===this.props.value&&M()(e.autoSize,this.props.autoSize)||this.resizeTextarea()}},{key:"componentWillUnmount",value:function(){cancelAnimationFrame(this.nextFrameActionId),cancelAnimationFrame(this.resizeFrameId)}},{key:"fixFirefoxAutoScroll",value:function(){try{if(document.activeElement===this.textArea){var e=this.textArea.selectionStart,t=this.textArea.selectionEnd;this.textArea.setSelectionRange(e,t)}}catch(e){}}},{key:"render",value:function(){return this.renderTextArea()}}]),n}(c.Component),D=function(e){Object(s.a)(n,e);var t=Object(a.a)(n);function n(e){var r;Object(i.a)(this,n),(r=t.call(this,e)).resizableTextArea=void 0,r.focus=function(){r.resizableTextArea.textArea.focus()},r.saveTextArea=function(e){r.resizableTextArea=e},r.handleChange=function(e){var t=r.props.onChange;r.setValue(e.target.value,(function(){r.resizableTextArea.resizeTextarea()})),t&&t(e)},r.handleKeyDown=function(e){var t=r.props,n=t.onPressEnter,i=t.onKeyDown;13===e.keyCode&&n&&n(e),i&&i(e)};var o=void 0===e.value||null===e.value?e.defaultValue:e.value;return r.state={value:o},r}return Object(o.a)(n,[{key:"setValue",value:function(e,t){"value"in this.props||this.setState({value:e},t)}},{key:"blur",value:function(){this.resizableTextArea.textArea.blur()}},{key:"render",value:function(){return c.createElement(T,Object(r.a)({},this.props,{value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,ref:this.saveTextArea}))}}],[{key:"getDerivedStateFromProps",value:function(e){return"value"in e?{value:e.value}:null}}]),n}(c.Component);t.default=D},YJ9k: /*!***********************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/eventtarget.js ***! \***********************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e,t){for(var n=0;nt||o>e&&s=t&&a>=n?o-e-r:s>t&&an?s-t+i:0}var a=function(e,t){var n=window,i=t.scrollMode,a=t.block,c=t.inline,l=t.boundary,u=t.skipOverflowHiddenElements,h="function"==typeof l?l:function(e){return e!==l};if(!r(e))throw new TypeError("Invalid target");for(var d=document.scrollingElement||document.documentElement,f=[],p=e;r(p)&&h(p);){if((p=p.parentElement)===d){f.push(p);break}null!=p&&p===document.body&&o(p)&&!o(document.documentElement)||null!=p&&o(p,u)&&f.push(p)}for(var _=n.visualViewport?n.visualViewport.width:innerWidth,v=n.visualViewport?n.visualViewport.height:innerHeight,b=window.scrollX||pageXOffset,g=window.scrollY||pageYOffset,m=e.getBoundingClientRect(),y=m.height,w=m.width,S=m.top,C=m.right,k=m.bottom,E=m.left,O="start"===a||"nearest"===a?S:"end"===a?k:S+y/2,x="center"===c?E+w/2:"end"===c?C:E,A=[],j=0;j=0&&E>=0&&k<=v&&C<=_&&S>=D&&k<=K&&E>=I&&C<=P)return A;var F=getComputedStyle(L),X=parseInt(F.borderLeftWidth,10),N=parseInt(F.borderTopWidth,10),B=parseInt(F.borderRightWidth,10),H=parseInt(F.borderBottomWidth,10),U=0,W=0,z="offsetWidth"in L?L.offsetWidth-L.clientWidth-X-B:0,V="offsetHeight"in L?L.offsetHeight-L.clientHeight-N-H:0;if(d===L)U="start"===a?O:"end"===a?O-v:"nearest"===a?s(g,g+v,v,N,H,g+O,g+O+y,y):O-v/2,W="start"===c?x:"center"===c?x-_/2:"end"===c?x-_:s(b,b+_,_,X,B,b+x,b+x+w,w),U=Math.max(0,U+g),W=Math.max(0,W+b);else{U="start"===a?O-D-N:"end"===a?O-K+H+V:"nearest"===a?s(D,K,M,N,H+V,O,O+y,y):O-(D+M/2)+V/2,W="start"===c?x-I-X:"center"===c?x-(I+T/2)+z/2:"end"===c?x-P+B+z:s(I,P,T,X,B+z,x,x+w,w);var Q=L.scrollLeft,q=L.scrollTop;O+=q-(U=Math.max(0,Math.min(q+U,L.scrollHeight-M+V))),x+=Q-(W=Math.max(0,Math.min(Q+W,L.scrollWidth-T+z)))}A.push({el:L,top:U,left:W})}return A};function c(e){return e===Object(e)&&0!==Object.keys(e).length}t.a=function(e,t){var n=!e.ownerDocument.documentElement.contains(e);if(c(t)&&"function"==typeof t.behavior)return t.behavior(n?[]:a(e,t));if(!n){var r=function(e){return!1===e?{block:"end",inline:"nearest"}:c(e)?e:{block:"start",inline:"nearest"}}(t);return function(e,t){void 0===t&&(t="auto");var n="scrollBehavior"in document.body.style;e.forEach((function(e){var r=e.el,i=e.top,o=e.left;r.scroll&&n?r.scroll({top:i,left:o,behavior:t}):(r.scrollTop=i,r.scrollLeft=o)}))}(a(e,r),r.behavior)}}},Zss7: /*!**********************************************!*\ !*** ./node_modules/tinycolor2/tinycolor.js ***! \**********************************************/ /*! no static exports found */ /*! exports used: default */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){var r;!function(i){var o=/^\s+/,s=/\s+$/,a=0,c=i.round,l=i.min,u=i.max,h=i.random;function d(e,t){if(t=t||{},(e=e||"")instanceof d)return e;if(!(this instanceof d))return new d(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,a=null,c=null,h=!1,d=!1;"string"==typeof e&&(e=function(e){e=e.replace(o,"").replace(s,"").toLowerCase();var t,n=!1;if(L[e])e=L[e],n=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=U.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=U.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=U.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=U.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=U.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=U.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=U.hex8.exec(e))return{r:P(t[1]),g:P(t[2]),b:P(t[3]),a:X(t[4]),format:n?"name":"hex8"};if(t=U.hex6.exec(e))return{r:P(t[1]),g:P(t[2]),b:P(t[3]),format:n?"name":"hex"};if(t=U.hex4.exec(e))return{r:P(t[1]+""+t[1]),g:P(t[2]+""+t[2]),b:P(t[3]+""+t[3]),a:X(t[4]+""+t[4]),format:n?"name":"hex8"};if(t=U.hex3.exec(e))return{r:P(t[1]+""+t[1]),g:P(t[2]+""+t[2]),b:P(t[3]+""+t[3]),format:n?"name":"hex"};return!1}(e));"object"==typeof e&&(W(e.r)&&W(e.g)&&W(e.b)?(f=e.r,p=e.g,_=e.b,t={r:255*T(f,255),g:255*T(p,255),b:255*T(_,255)},h=!0,d="%"===String(e.r).substr(-1)?"prgb":"rgb"):W(e.h)&&W(e.s)&&W(e.v)?(r=I(e.s),a=I(e.v),t=function(e,t,n){e=6*T(e,360),t=T(t,100),n=T(n,100);var r=i.floor(e),o=e-r,s=n*(1-t),a=n*(1-o*t),c=n*(1-(1-o)*t),l=r%6;return{r:255*[n,a,s,s,c,n][l],g:255*[c,n,n,a,s,s][l],b:255*[s,s,c,n,n,a][l]}}(e.h,r,a),h=!0,d="hsv"):W(e.h)&&W(e.s)&&W(e.l)&&(r=I(e.s),c=I(e.l),t=function(e,t,n){var r,i,o;function s(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}if(e=T(e,360),t=T(t,100),n=T(n,100),0===t)r=i=o=n;else{var a=n<.5?n*(1+t):n+t-n*t,c=2*n-a;r=s(c,a,e+1/3),i=s(c,a,e),o=s(c,a,e-1/3)}return{r:255*r,g:255*i,b:255*o}}(e.h,r,c),h=!0,d="hsl"),e.hasOwnProperty("a")&&(n=e.a));var f,p,_;return n=M(n),{ok:h,format:e.format||d,r:l(255,u(t.r,0)),g:l(255,u(t.g,0)),b:l(255,u(t.b,0)),a:n}}(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=c(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=c(this._r)),this._g<1&&(this._g=c(this._g)),this._b<1&&(this._b=c(this._b)),this._ok=n.ok,this._tc_id=a++}function f(e,t,n){e=T(e,255),t=T(t,255),n=T(n,255);var r,i,o=u(e,t,n),s=l(e,t,n),a=(o+s)/2;if(o==s)r=i=0;else{var c=o-s;switch(i=a>.5?c/(2-o-s):c/(o+s),o){case e:r=(t-n)/c+(t>1)+720)%360;--t;)r.h=(r.h+i)%360,o.push(d(r));return o}function j(e,t){t=t||6;for(var n=d(e).toHsv(),r=n.h,i=n.s,o=n.v,s=[],a=1/t;t--;)s.push(d({h:r,s:i,v:o})),o=(o+a)%1;return s}d.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,n,r=this.toRgb();return e=r.r/255,t=r.g/255,n=r.b/255,.2126*(e<=.03928?e/12.92:i.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:i.pow((t+.055)/1.055,2.4))+.0722*(n<=.03928?n/12.92:i.pow((n+.055)/1.055,2.4))},setAlpha:function(e){return this._a=M(e),this._roundA=c(100*this._a)/100,this},toHsv:function(){var e=p(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=p(this._r,this._g,this._b),t=c(360*e.h),n=c(100*e.s),r=c(100*e.v);return 1==this._a?"hsv("+t+", "+n+"%, "+r+"%)":"hsva("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHsl:function(){var e=f(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=f(this._r,this._g,this._b),t=c(360*e.h),n=c(100*e.s),r=c(100*e.l);return 1==this._a?"hsl("+t+", "+n+"%, "+r+"%)":"hsla("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHex:function(e){return _(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,n,r,i){var o=[K(c(e).toString(16)),K(c(t).toString(16)),K(c(n).toString(16)),K(F(r))];if(i&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)&&o[3].charAt(0)==o[3].charAt(1))return o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0);return o.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:c(this._r),g:c(this._g),b:c(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+c(this._r)+", "+c(this._g)+", "+c(this._b)+")":"rgba("+c(this._r)+", "+c(this._g)+", "+c(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:c(100*T(this._r,255))+"%",g:c(100*T(this._g,255))+"%",b:c(100*T(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+c(100*T(this._r,255))+"%, "+c(100*T(this._g,255))+"%, "+c(100*T(this._b,255))+"%)":"rgba("+c(100*T(this._r,255))+"%, "+c(100*T(this._g,255))+"%, "+c(100*T(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(R[_(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+v(this._r,this._g,this._b,this._a),n=t,r=this._gradientType?"GradientType = 1, ":"";if(e){var i=d(e);n="#"+v(i._r,i._g,i._b,i._a)}return"progid:DXImageTransform.Microsoft.gradient("+r+"startColorstr="+t+",endColorstr="+n+")"},toString:function(e){var t=!!e;e=e||this._format;var n=!1,r=this._a<1&&this._a>=0;return t||!r||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return d(this.toString())},_applyModification:function(e,t){var n=e.apply(null,[this].concat([].slice.call(t)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(y,arguments)},brighten:function(){return this._applyModification(w,arguments)},darken:function(){return this._applyModification(S,arguments)},desaturate:function(){return this._applyModification(b,arguments)},saturate:function(){return this._applyModification(g,arguments)},greyscale:function(){return this._applyModification(m,arguments)},spin:function(){return this._applyModification(C,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(A,arguments)},complement:function(){return this._applyCombination(k,arguments)},monochromatic:function(){return this._applyCombination(j,arguments)},splitcomplement:function(){return this._applyCombination(x,arguments)},triad:function(){return this._applyCombination(E,arguments)},tetrad:function(){return this._applyCombination(O,arguments)}},d.fromRatio=function(e,t){if("object"==typeof e){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]="a"===r?e[r]:I(e[r]));e=n}return d(e,t)},d.equals=function(e,t){return!(!e||!t)&&d(e).toRgbString()==d(t).toRgbString()},d.random=function(){return d.fromRatio({r:h(),g:h(),b:h()})},d.mix=function(e,t,n){n=0===n?0:n||50;var r=d(e).toRgb(),i=d(t).toRgb(),o=n/100;return d({r:(i.r-r.r)*o+r.r,g:(i.g-r.g)*o+r.g,b:(i.b-r.b)*o+r.b,a:(i.a-r.a)*o+r.a})},d.readability=function(e,t){var n=d(e),r=d(t);return(i.max(n.getLuminance(),r.getLuminance())+.05)/(i.min(n.getLuminance(),r.getLuminance())+.05)},d.isReadable=function(e,t,n){var r,i,o=d.readability(e,t);switch(i=!1,(r=function(e){var t,n;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==n&&"large"!==n&&(n="small");return{level:t,size:n}}(n)).level+r.size){case"AAsmall":case"AAAlarge":i=o>=4.5;break;case"AAlarge":i=o>=3;break;case"AAAsmall":i=o>=7}return i},d.mostReadable=function(e,t,n){var r,i,o,s,a=null,c=0;i=(n=n||{}).includeFallbackColors,o=n.level,s=n.size;for(var l=0;lc&&(c=r,a=d(t[l]));return d.isReadable(e,a,{level:o,size:s})||!i?a:(n.includeFallbackColors=!1,d.mostReadable(e,["#fff","#000"],n))};var L=d.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},R=d.hexNames=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}(L);function M(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function T(e,t){(function(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var n=function(e){return"string"==typeof e&&-1!=e.indexOf("%")}(e);return e=l(t,u(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),i.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function D(e){return l(1,u(0,e))}function P(e){return parseInt(e,16)}function K(e){return 1==e.length?"0"+e:""+e}function I(e){return e<=1&&(e=100*e+"%"),e}function F(e){return i.round(255*parseFloat(e)).toString(16)}function X(e){return P(e)/255}var N,B,H,U=(B="[\\s|\\(]+("+(N="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+N+")[,|\\s]+("+N+")\\s*\\)?",H="[\\s|\\(]+("+N+")[,|\\s]+("+N+")[,|\\s]+("+N+")[,|\\s]+("+N+")\\s*\\)?",{CSS_UNIT:new RegExp(N),rgb:new RegExp("rgb"+B),rgba:new RegExp("rgba"+H),hsl:new RegExp("hsl"+B),hsla:new RegExp("hsla"+H),hsv:new RegExp("hsv"+B),hsva:new RegExp("hsva"+H),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/});function W(e){return!!U.CSS_UNIT.exec(e)}e.exports?e.exports=d:void 0===(r=function(){return d}.call(t,n,t,e))||(e.exports=r)}(Math)},bPs0: /*!**************************************************!*\ !*** ./src/components/Exercise/recordScreen.tsx ***! \**************************************************/ /*! exports provided: fullchange, default */ /*! exports used: default, fullchange */function(e,t,n){"use strict";n.d(t,"b",(function(){return y}));var r=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2 */"k1fw"),i=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator */"9og8"),o=(n(/*! antd/es/modal/style */"2qtc"),n(/*! antd/es/modal */"kLXV")),s=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/slicedToArray */"tJVT"),a=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties */"PpiC"),c=(n(/*! antd/es/statistic/style */"aHsQ"),n(/*! antd/es/statistic */"sGsY")),l=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator */"WmNS"),u=n.n(l),h=n(/*! react */"q1tI"),d=n.n(h),f=n(/*! @/utils/fullscreen */"bntm"),p=n(/*! @/service/exercise */"V0Rq"),_=n(/*! moment */"wd/R"),v=n.n(_),b=n(/*! umi */"Ty5D"),g=n(/*! umi */"9kvl"),m=c.a.Countdown,y=["fullscreenchange","msfullscreenchange","webkitfullscreenchange","mozfullscreenchange"];t.a=Object(g.a)((function(e){var t=e.loading,n=e.user,r=e.exercise;return{globalSetting:e.globalSetting,user:n,exercise:r,loading:t.effects}}))((function(e){e.globalSetting,e.loading,e.user;var t=e.exercise,n=e.dispatch,c=(Object(a.a)(e,["globalSetting","loading","user","exercise","dispatch"]),Object(h.useState)({})),l=Object(s.a)(c,2),_=(l[0],l[1],o.a.useModal()),g=Object(s.a)(_,2),y=g[0],w=g[1],S=Object(h.useRef)(),C=Object(h.useRef)(null),k=Object(h.useRef)(null),E=Object(h.useState)(!0),O=Object(s.a)(E,2),x=(O[0],O[1]),A=(Object(b.h)().query,Object(b.i)());Object(h.useEffect)((function(){var e,r,i,s,a;if(clearTimeout(C.current),document.addEventListener(Object(f.c)(),I,!1),window.addEventListener("blur",P,!1),null!==(e=t.exerciseUserInfo)&&void 0!==e&&e.screen_open&&Object(f.a)()&&(n({type:"globalSetting/headerFooterToggle",payload:!1}),x(!1)),null!==(r=t.exerciseUserInfo)&&void 0!==r&&r.screen_at&&v()().diff(v()(null===(i=t.exerciseUserInfo)||void 0===i?void 0:i.screen_at),"seconds")>0)j();else if(null!==(s=t.exerciseUserInfo)&&void 0!==s&&s.screen_open&&!Object(f.a)()){var c="kepukehuan.educoder.net"===document.domain?30:t.exerciseUserInfo.screen_sec+10+1;S.current=o.a.info({icon:null,content:d.a.createElement("div",{className:"tc font16"},"本场考试已开启防切屏限制,",d.a.createElement("br",null),"切换页面 ",t.exerciseUserInfo.screen_num-t.exerciseUserInfo.used_screen_num," 次后将进行强制交卷,",d.a.createElement("br",null),"请勿切屏及刷新页面"),okText:d.a.createElement("span",null,"开始考试(",d.a.createElement("span",{style:{display:"inline-block"}},d.a.createElement(m,{onFinish:function(){var e;j(),null===(e=S.current)||void 0===e||e.destroy()},valueStyle:{fontSize:14,lineHeight:1.4,color:"#FFF",display:"inline-block"},format:"ss",value:Date.now()+1e3*c})),"S)"),onOk:function(){var e;null===(e=S.current)||void 0===e||e.destroy(),x(!1),Object(f.d)(document.body),document.getElementById("root").addEventListener("click",L,!1)}})}return null!==(a=t.exerciseUserInfo)&&void 0!==a&&a.screen_open&&!Object(f.a)()||document.getElementById("root").addEventListener("click",L,!1),function(){document.getElementById("root").removeEventListener("click",L,!1),document.removeEventListener(Object(f.c)(),I,!1),window.removeEventListener("blur",P,!1),clearTimeout(C.current)}}),[]),Object(h.useEffect)((function(){setTimeout((function(){t.actionTabs.removeEventListenerExitScreen&&(clearTimeout(C.current),document.getElementById("root").removeEventListener("click",L,!1),document.removeEventListener(Object(f.c)(),I,!1))}),500),R()}),[t.actionTabs]),Object(h.useEffect)((function(){setTimeout((function(){t.exerciseUserInfo.used_screen_num>t.exerciseUserInfo.screen_num&&T()}),500)}),[t.exerciseUserInfo]);var j=function(){var e=Object(i.a)(u.a.mark((function e(){var n;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,K();case 2:n=e.sent,setTimeout((function(){var e,r,s;null===(e=S.current)||void 0===e||e.destroy(),S.current=o.a.info({okText:d.a.createElement("span",null,"回到考试"),content:d.a.createElement("div",null,"您已切屏",d.a.createElement("span",{className:"c-red"},n.used_screen_num),"次,切屏超过",d.a.createElement("span",{className:"c-red"},null===(r=t.exerciseUserInfo)||void 0===r?void 0:r.screen_num),"次将强制交卷"),onOk:(s=Object(i.a)(u.a.mark((function e(){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:Object(f.d)(document.body);case 1:case"end":return e.stop()}}),e)}))),function(){return s.apply(this,arguments)})})}),1e3);case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),L=function(e){Object(f.a)()||"A"===e.target.nodeName||"BUTTON"===e.target.nodeName||"确 定"===e.target.innerHTML||(Object(f.d)(document.body),console.log("documentClick.full"))},R=function(){var e=Object(i.a)(u.a.mark((function e(){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise(function(){var e=Object(i.a)(u.a.mark((function e(t){var i;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n({type:"exercise/getExerciseUserInfo",payload:Object(r.a)({},A)});case 2:return i=e.sent,t(null==i?void 0:i.data),e.abrupt("return",null==i?void 0:i.data);case 5:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()));case 1:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),M=function(){var e=Object(i.a)(u.a.mark((function e(n){var r,s,a;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:null===(r=S.current)||void 0===r||null===(s=r.destroyAll)||void 0===s||s.call(r),S.current=o.a.info({maskClosable:!1,keyboard:!1,okText:d.a.createElement("span",null,"回到考试(",d.a.createElement("span",{style:{display:"inline-block"}},d.a.createElement(m,{onFinish:K,valueStyle:{fontSize:14,lineHeight:1.4,color:"#FFF",display:"inline-block"},format:"ss",value:Date.now()+1e3*(t.exerciseUserInfo.screen_sec+1)})),"S)"),content:d.a.createElement("div",null,"您已切屏",d.a.createElement("span",{className:"c-red"},n),"次,切屏超过",d.a.createElement("span",{className:"c-red"},null===(a=t.exerciseUserInfo)||void 0===a?void 0:a.screen_num),"次将强制交卷,",d.a.createElement("span",{className:"c-red"},t.exerciseUserInfo.screen_sec),"秒内回到",d.a.createElement("br",null),d.a.createElement("span",{style:{marginLeft:38}},"考试不计切屏次数。")),onOk:function(){var e=Object(i.a)(u.a.mark((function e(){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:clearTimeout(k.current),Object(f.d)(document.body),S.current.destroy();case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}()}),k.current=setTimeout((function(){var e;S.current.update({okText:d.a.createElement("span",null,"回到考试"),content:d.a.createElement("div",null,"您已切屏",d.a.createElement("span",{className:"c-red"},n+1),"次,切屏超过",d.a.createElement("span",{className:"c-red"},null===(e=t.exerciseUserInfo)||void 0===e?void 0:e.screen_num),"次将强制交卷")})}),1e3*(t.exerciseUserInfo.screen_sec+1));case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),T=function(){var e=Object(i.a)(u.a.mark((function e(){var t,n;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return null===(t=S.current)||void 0===t||null===(n=t.destroyAll)||void 0===n||n.call(t),e.next=3,Object(p.Y)({categoryId:A.categoryId,commit_method:1});case 3:e.sent&&D();case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),D=function(){var e,t;document.removeEventListener(Object(f.c)(),I,!1),Object(f.b)(),null===(e=S.current)||void 0===e||null===(t=e.destroyAll)||void 0===t||t.call(e),y.info({content:d.a.createElement("div",{className:"tc font16"},"答题结束了,系统已自动提交试卷",d.a.createElement("br",null),"不能再修改答题"),onOk:function(){location.href="/classrooms/".concat(A.coursesId,"/exercise/").concat(A.categoryId,"/detail")}})},P=function(e){Object(f.a)()&&"none"==document.getElementById("iframeShixuns").style.display&&Object(f.b)()},K=function(){var e=Object(i.a)(u.a.mark((function e(){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",new Promise(function(){var e=Object(i.a)(u.a.mark((function e(n){var i,o,s;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null===(i=t.exerciseUserInfo)||void 0===i||!i.screen_at){e.next=3;break}return e.next=3,Object(p.g)(Object(r.a)(Object(r.a)({},A),{},{reset:!0}));case 3:return e.next=5,Object(p.Q)({id:A.categoryId});case 5:if(null==(o=e.sent)||!o.is_commit){e.next=9;break}return D(),e.abrupt("return");case 9:return e.next=11,R();case 11:s=e.sent,n(s);case 13:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()));case 1:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),I=function(){var e=Object(i.a)(u.a.mark((function e(){var o,s,a,c;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(o=!1,console.log("fullscreen change"),!Object(f.a)()){e.next=7;break}null!==(s=t.exerciseUserInfo)&&void 0!==s&&s.screen_at&&Object(p.g)(Object(r.a)(Object(r.a)({},A),{},{reset:!0})),clearTimeout(C.current),e.next=17;break;case 7:return o=!0,e.next=10,Object(p.g)(Object(r.a)({},A));case 10:return e.next=12,R();case 12:a=e.sent,M(a.used_screen_num),c=setTimeout(Object(i.a)(u.a.mark((function e(){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)}))),1e3*t.exerciseUserInfo.screen_sec),window.frames.length!=parent.frames.length&&window.parent.postMessage("backExercise","*"),C.current=c;case 17:n({type:"globalSetting/headerFooterToggle",payload:o});case 18:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return d.a.createElement("div",null,w)}))},bT9E: /*!*****************************************!*\ !*** ./node_modules/rc-util/es/omit.js ***! \*****************************************/ /*! exports provided: default */ /*! exports used: default */function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ");function i(e,t){var n=Object(r.a)({},e);return Array.isArray(t)&&t.forEach((function(e){delete n[e]})),n}},biw7: /*!**********************************************************!*\ !*** ./node_modules/rc-table/es/context/TableContext.js ***! \**********************************************************/ /*! exports provided: default */ /*! exports used: default */function(e,t,n){"use strict";var r=n(/*! react */"q1tI"),i=r.createContext(null);t.a=i},c5fP: /*!*********************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/zlib/trees.js ***! \*********************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t._tr_init=function(e){K||(!function(){var e,t,n,r,i,o=new Array(16);for(n=0,r=0;r<28;r++)for(_[r]=n,e=0;e<1<>=7;r<30;r++)for(m[r]=i<<7,e=0;e<1<0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,n=4093624447;for(t=0;t<=31;t++,n>>>=1)if(1&n&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<256;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),T(e,e.l_desc),T(e,e.d_desc),s=function(e){var t;for(D(e,e.dyn_ltree,e.l_desc.max_code),D(e,e.dyn_dtree,e.d_desc.max_code),T(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*u[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),i=e.opt_len+3+7>>>3,(o=e.static_len+3+7>>>3)<=i&&(i=o)):i=o=n+5;n+4<=i&&-1!==t?I(e,t,n,r):4===e.strategy||o===i?(k(e,2+(r?1:0),3),M(e,h,d)):(k(e,4+(r?1:0),3),function(e,t,n,r){var i;for(k(e,t-257,5),k(e,n-1,5),k(e,r-4,4),i=0;i>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&n,e.last_lit++,0===t?e.dyn_ltree[2*n]++:(e.matches++,t--,e.dyn_ltree[2*(p[n]+256+1)]++,e.dyn_dtree[2*S(t)]++);return e.last_lit===e.lit_bufsize-1},t._tr_align=function(e){k(e,2,3),E(e,256,h),function(e){16===e.bi_valid?(C(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)};var i=function(e){if(e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var t=o();if(t&&t.has(e))return t.get(e);var n={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if(Object.prototype.hasOwnProperty.call(e,s)){var a=i?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(n,s,a):n[s]=e[s]}n.default=e,t&&t.set(e,n);return n}(n(/*! ../utils/common.js */"6BzB"));function o(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return o=function(){return e},e}function s(e){for(var t=e.length;--t>=0;)e[t]=0}var a=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],c=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],l=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],u=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],h=new Array(576);s(h);var d=new Array(60);s(d);var f=new Array(512);s(f);var p=new Array(256);s(p);var _=new Array(29);s(_);var v,b,g,m=new Array(30);function y(e,t,n,r,i){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=e&&e.length}function w(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function S(e){return e<256?f[e]:f[256+(e>>>7)]}function C(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function k(e,t,n){e.bi_valid>16-n?(e.bi_buf|=t<>16-e.bi_valid,e.bi_valid+=n-16):(e.bi_buf|=t<>>=1,n<<=1}while(--t>0);return n>>>1}function x(e,t,n){var r,i,o=new Array(16),s=0;for(r=1;r<=15;r++)o[r]=s=s+n[r-1]<<1;for(i=0;i<=t;i++){var a=e[2*i+1];0!==a&&(e[2*i]=O(o[a]++,a))}}function A(e){var t;for(t=0;t<286;t++)e.dyn_ltree[2*t]=0;for(t=0;t<30;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function j(e){e.bi_valid>8?C(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function L(e,t,n,r){var i=2*t,o=2*n;return e[i]>1;n>=1;n--)R(e,o,n);i=c;do{n=e.heap[1],e.heap[1]=e.heap[e.heap_len--],R(e,o,1),r=e.heap[1],e.heap[--e.heap_max]=n,e.heap[--e.heap_max]=r,o[2*i]=o[2*n]+o[2*r],e.depth[i]=(e.depth[n]>=e.depth[r]?e.depth[n]:e.depth[r])+1,o[2*n+1]=o[2*r+1]=i,e.heap[1]=i++,R(e,o,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var n,r,i,o,s,a,c=t.dyn_tree,l=t.max_code,u=t.stat_desc.static_tree,h=t.stat_desc.has_stree,d=t.stat_desc.extra_bits,f=t.stat_desc.extra_base,p=t.stat_desc.max_length,_=0;for(o=0;o<=15;o++)e.bl_count[o]=0;for(c[2*e.heap[e.heap_max]+1]=0,n=e.heap_max+1;n<573;n++)(o=c[2*c[2*(r=e.heap[n])+1]+1]+1)>p&&(o=p,_++),c[2*r+1]=o,r>l||(e.bl_count[o]++,s=0,r>=f&&(s=d[r-f]),a=c[2*r],e.opt_len+=a*(o+s),h&&(e.static_len+=a*(u[2*r+1]+s)));if(0!==_){do{for(o=p-1;0===e.bl_count[o];)o--;e.bl_count[o]--,e.bl_count[o+1]+=2,e.bl_count[p]--,_-=2}while(_>0);for(o=p;0!==o;o--)for(r=e.bl_count[o];0!==r;)(i=e.heap[--n])>l||(c[2*i+1]!==o&&(e.opt_len+=(o-c[2*i+1])*c[2*i],c[2*i+1]=o),r--)}}(e,t),x(o,l,e.bl_count)}function D(e,t,n){var r,i,o=-1,s=t[1],a=0,c=7,l=4;for(0===s&&(c=138,l=3),t[2*(n+1)+1]=65535,r=0;r<=n;r++)i=s,s=t[2*(r+1)+1],++a1?a-1:0),l=1;l1?n-1:0),o=1;o=0)return parseInt(t.slice(t.indexOf("e-")+2),10);var n=0;return t.indexOf(".")>=0&&(n=t.length-t.indexOf(".")-1),n},r.getInputDisplayValue=function(e){var t,n=e||r.state,i=n.focused,o=n.inputValue,s=n.value;null==(t=i?o:r.toPrecisionAsStep(s))&&(t="");var a=r.formatWrapper(t);return w(r.props.decimalSeparator)&&(a=a.toString().replace(".",r.props.decimalSeparator)),a},r.recordCursorPosition=function(){try{r.cursorStart=r.input.selectionStart,r.cursorEnd=r.input.selectionEnd,r.currentValue=r.input.value,r.cursorBefore=r.input.value.substring(0,r.cursorStart),r.cursorAfter=r.input.value.substring(r.cursorEnd)}catch(e){}},r.restoreByAfter=function(e){if(void 0===e)return!1;var t=r.input.value,n=t.lastIndexOf(e);if(-1===n)return!1;var i=r.cursorBefore.length;return r.lastKeyCode===p.a.DELETE&&r.cursorBefore.charAt(i-1)===e[0]?(r.fixCaret(i,i),!0):n+e.length===t.length&&(r.fixCaret(n,n),!0)},r.partRestoreByAfter=function(e){return void 0!==e&&Array.prototype.some.call(e,(function(t,n){var i=e.substring(n);return r.restoreByAfter(i)}))},r.isNotCompleteNumber=function(e){return isNaN(e)||""===e||null===e||e&&e.toString().indexOf(".")===e.toString().length-1},r.stop=function(){r.autoStepTimer&&clearTimeout(r.autoStepTimer)},r.down=function(e,t,n){r.pressingUpOrDown=!0,r.step("down",e,t,n)},r.up=function(e,t,n){r.pressingUpOrDown=!0,r.step("up",e,t,n)},r.saveInput=function(e){r.input=e};var i=e.value;void 0===i&&(i=e.defaultValue),r.state={focused:e.autoFocus};var s=r.getValidValue(r.toNumber(i));return r.state=v(v({},r.state),{},{inputValue:r.toPrecisionAsStep(s),value:s}),r}return Object(s.a)(n,[{key:"componentDidMount",value:function(){this.componentDidUpdate(null)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.value,r=t.onChange,i=t.max,o=t.min,s=this.state.focused;if(e){if(!S(e.value,n)||!S(e.max,i)||!S(e.min,o)){var a,c=s?n:this.getValidValue(n);a=this.pressingUpOrDown?c:this.inputting?this.rawInput:this.toPrecisionAsStep(c),this.setState({value:c,inputValue:a})}var l="value"in this.props?n:this.state.value;"max"in this.props&&e.max!==i&&"number"==typeof l&&l>i&&r&&r(i),"min"in this.props&&e.min!==o&&"number"==typeof l&&l1&&void 0!==arguments[1]?arguments[1]:this.props.min,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.props.max,r=parseFloat(e);return isNaN(r)?e:(rn&&(r=n),r)}},{key:"setValue",value:function(e,t){var n=this.props.precision,r=this.isNotCompleteNumber(parseFloat(e))?null:parseFloat(e),i=this.state.value,o=void 0===i?null:i,s=this.state.inputValue,a=void 0===s?null:s,c="number"==typeof r?r.toFixed(n):"".concat(r),l=r!==o||c!=="".concat(a);return"value"in this.props?(a=this.toPrecisionAsStep(this.state.value),this.setState({inputValue:a},t)):this.setState({value:r,inputValue:this.toPrecisionAsStep(e)},t),l&&this.props.onChange(r),r}},{key:"getMaxPrecision",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=this.props,r=n.precision,i=n.step;if(w(r))return r;var o=this.getPrecision(t),s=this.getPrecision(i),a=this.getPrecision(e);return e?Math.max(a,o+s):o+s}},{key:"getPrecisionFactor",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=this.getMaxPrecision(e,t);return Math.pow(10,n)}},{key:"focus",value:function(){this.input.focus(),this.recordCursorPosition()}},{key:"blur",value:function(){this.input.blur()}},{key:"select",value:function(){this.input.select()}},{key:"formatWrapper",value:function(e){return this.props.formatter?this.props.formatter(e):e}},{key:"toPrecisionAsStep",value:function(e){if(this.isNotCompleteNumber(e)||""===e)return e;var t=Math.abs(this.getMaxPrecision(e));return isNaN(t)?e.toString():Number(e).toFixed(t)}},{key:"toNumber",value:function(e){var t=this.props.precision,n=this.state.focused,r=e&&e.length>16&&n;return this.isNotCompleteNumber(e)||r?e:w(t)?Math.round(e*Math.pow(10,t))/Math.pow(10,t):Number(e)}},{key:"upStep",value:function(e,t){var n=this.props.step,r=this.getPrecisionFactor(e,t),i=Math.abs(this.getMaxPrecision(e,t)),o=((r*e+r*n*t)/r).toFixed(i);return this.toNumber(o)}},{key:"downStep",value:function(e,t){var n=this.props.step,r=this.getPrecisionFactor(e,t),i=Math.abs(this.getMaxPrecision(e,t)),o=((r*e-r*n*t)/r).toFixed(i);return this.toNumber(o)}},{key:"step",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,i=arguments.length>3?arguments[3]:void 0;this.stop(),t&&(t.persist(),t.preventDefault());var o=this.props;if(!o.disabled){var s=this.getCurrentValidValue(this.state.inputValue)||0;if(!this.isNotCompleteNumber(s)){var a=this["".concat(e,"Step")](s,r),c=a>o.max||ao.max?a=o.max:a=p)||o||s,Q=(N||0===N)&&(isNaN(N)||Number(N)<=_)||o||s,q=f()("".concat(n,"-handler"),"".concat(n,"-handler-up"),Object(i.a)({},"".concat(n,"-handler-up-disabled"),V)),G=f()("".concat(n,"-handler"),"".concat(n,"-handler-down"),Object(i.a)({},"".concat(n,"-handler-down-disabled"),Q)),Y=a?{onTouchStart:V?g:this.up,onTouchEnd:this.stop}:{onMouseDown:V?g:this.up,onMouseUp:this.stop,onMouseLeave:this.stop},Z=a?{onTouchStart:Q?g:this.down,onTouchEnd:this.stop}:{onMouseDown:Q?g:this.down,onMouseUp:this.stop,onMouseLeave:this.stop};return h.a.createElement("div",{className:H,style:v,title:b,onMouseEnter:y,onMouseLeave:w,onMouseOver:S,onMouseOut:C,onFocus:function(){return null},onBlur:function(){return null}},h.a.createElement("div",{className:"".concat(n,"-handler-wrap")},h.a.createElement("span",Object.assign({unselectable:"on"},Y,{role:"button","aria-label":"Increase Value","aria-disabled":V,className:q}),l||h.a.createElement("span",{unselectable:"on",className:"".concat(n,"-handler-up-inner"),onClick:m})),h.a.createElement("span",Object.assign({unselectable:"on"},Z,{role:"button","aria-label":"Decrease Value","aria-disabled":Q,className:G}),u||h.a.createElement("span",{unselectable:"on",className:"".concat(n,"-handler-down-inner"),onClick:m}))),h.a.createElement("div",{className:"".concat(n,"-input-wrap")},h.a.createElement("input",Object.assign({role:"spinbutton","aria-valuemin":_,"aria-valuemax":p,"aria-valuenow":N,required:k,type:x,placeholder:A,onPaste:K,onClick:E,onMouseUp:this.onMouseUp,className:"".concat(n,"-input"),tabIndex:O,autoComplete:c,onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:W?this.onKeyDown:g,onKeyUp:W?this.onKeyUp:g,autoFocus:D,maxLength:T,readOnly:s,disabled:o,max:p,min:_,step:M,name:P,title:b,id:j,onChange:this.onChange,ref:this.saveInput,value:this.getFullNum(z),pattern:R,inputMode:L,onInput:I},U))))}}]),n}(h.a.Component);C.defaultProps={focusOnUpDown:!0,useTouch:!1,prefixCls:"rc-input-number",max:y,min:-y,step:1,style:{},onChange:g,onKeyDown:g,onPressEnter:g,onFocus:g,onBlur:g,parser:function(e){return e.replace(/[^\w.-]+/g,"")},required:!1,autoComplete:"off"};var k=C;t.a=k},eP3c: /*!***********************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/zlib/inflate.js ***! \***********************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.inflateReset=p,t.inflateReset2=_,t.inflateResetKeep=f,t.inflateInit=function(e){return v(e,15)},t.inflateInit2=v,t.inflate=function(e,t){var n,r,l,u,d,f,p,_,v,b,g,m,S,C,k,E,O,x,A,j,L,R,M,T,D=0,P=new i.Buf8(4),K=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return-2;12===(n=e.state).mode&&(n.mode=13);d=e.next_out,l=e.output,p=e.avail_out,u=e.next_in,r=e.input,f=e.avail_in,_=n.hold,v=n.bits,b=f,g=p,R=0;e:for(;;)switch(n.mode){case 1:if(0===n.wrap){n.mode=13;break}for(;v<16;){if(0===f)break e;f--,_+=r[u++]<>>8&255,n.check=(0,s.default)(n.check,P,2,0),_=0,v=0,n.mode=2;break}if(n.flags=0,n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&_)<<8)+(_>>8))%31){e.msg="incorrect header check",n.mode=30;break}if(8!=(15&_)){e.msg="unknown compression method",n.mode=30;break}if(v-=4,L=8+(15&(_>>>=4)),0===n.wbits)n.wbits=L;else if(L>n.wbits){e.msg="invalid window size",n.mode=30;break}n.dmax=1<>8&1),512&n.flags&&(P[0]=255&_,P[1]=_>>>8&255,n.check=(0,s.default)(n.check,P,2,0)),_=0,v=0,n.mode=3;case 3:for(;v<32;){if(0===f)break e;f--,_+=r[u++]<>>8&255,P[2]=_>>>16&255,P[3]=_>>>24&255,n.check=(0,s.default)(n.check,P,4,0)),_=0,v=0,n.mode=4;case 4:for(;v<16;){if(0===f)break e;f--,_+=r[u++]<>8),512&n.flags&&(P[0]=255&_,P[1]=_>>>8&255,n.check=(0,s.default)(n.check,P,2,0)),_=0,v=0,n.mode=5;case 5:if(1024&n.flags){for(;v<16;){if(0===f)break e;f--,_+=r[u++]<>>8&255,n.check=(0,s.default)(n.check,P,2,0)),_=0,v=0}else n.head&&(n.head.extra=null);n.mode=6;case 6:if(1024&n.flags&&((m=n.length)>f&&(m=f),m&&(n.head&&(L=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),i.arraySet(n.head.extra,r,u,m,L)),512&n.flags&&(n.check=(0,s.default)(n.check,r,m,u)),f-=m,u+=m,n.length-=m),n.length))break e;n.length=0,n.mode=7;case 7:if(2048&n.flags){if(0===f)break e;m=0;do{L=r[u+m++],n.head&&L&&n.length<65536&&(n.head.name+=String.fromCharCode(L))}while(L&&m>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=12;break;case 10:for(;v<32;){if(0===f)break e;f--,_+=r[u++]<>>=7&v,v-=7&v,n.mode=27;break}for(;v<3;){if(0===f)break e;f--,_+=r[u++]<>>=1)){case 0:n.mode=14;break;case 1:if(y(n),n.mode=20,6===t){_>>>=2,v-=2;break e}break;case 2:n.mode=17;break;case 3:e.msg="invalid block type",n.mode=30}_>>>=2,v-=2;break;case 14:for(_>>>=7&v,v-=7&v;v<32;){if(0===f)break e;f--,_+=r[u++]<>>16^65535)){e.msg="invalid stored block lengths",n.mode=30;break}if(n.length=65535&_,_=0,v=0,n.mode=15,6===t)break e;case 15:n.mode=16;case 16:if(m=n.length){if(m>f&&(m=f),m>p&&(m=p),0===m)break e;i.arraySet(l,r,u,m,d),f-=m,u+=m,p-=m,d+=m,n.length-=m;break}n.mode=12;break;case 17:for(;v<14;){if(0===f)break e;f--,_+=r[u++]<>>=5,v-=5,n.ndist=1+(31&_),_>>>=5,v-=5,n.ncode=4+(15&_),_>>>=4,v-=4,n.nlen>286||n.ndist>30){e.msg="too many length or distance symbols",n.mode=30;break}n.have=0,n.mode=18;case 18:for(;n.have>>=3,v-=3}for(;n.have<19;)n.lens[K[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,M={bits:n.lenbits},R=(0,c.default)(0,n.lens,0,19,n.lencode,0,n.work,M),n.lenbits=M.bits,R){e.msg="invalid code lengths set",n.mode=30;break}n.have=0,n.mode=19;case 19:for(;n.have>>16&255,O=65535&D,!((k=D>>>24)<=v);){if(0===f)break e;f--,_+=r[u++]<>>=k,v-=k,n.lens[n.have++]=O;else{if(16===O){for(T=k+2;v>>=k,v-=k,0===n.have){e.msg="invalid bit length repeat",n.mode=30;break}L=n.lens[n.have-1],m=3+(3&_),_>>>=2,v-=2}else if(17===O){for(T=k+3;v>>=k)),_>>>=3,v-=3}else{for(T=k+7;v>>=k)),_>>>=7,v-=7}if(n.have+m>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=30;break}for(;m--;)n.lens[n.have++]=L}}if(30===n.mode)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=30;break}if(n.lenbits=9,M={bits:n.lenbits},R=(0,c.default)(1,n.lens,0,n.nlen,n.lencode,0,n.work,M),n.lenbits=M.bits,R){e.msg="invalid literal/lengths set",n.mode=30;break}if(n.distbits=6,n.distcode=n.distdyn,M={bits:n.distbits},R=(0,c.default)(2,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,M),n.distbits=M.bits,R){e.msg="invalid distances set",n.mode=30;break}if(n.mode=20,6===t)break e;case 20:n.mode=21;case 21:if(f>=6&&p>=258){e.next_out=d,e.avail_out=p,e.next_in=u,e.avail_in=f,n.hold=_,n.bits=v,(0,a.default)(e,g),d=e.next_out,l=e.output,p=e.avail_out,u=e.next_in,r=e.input,f=e.avail_in,_=n.hold,v=n.bits,12===n.mode&&(n.back=-1);break}for(n.back=0;D=n.lencode[_&(1<>>16&255,O=65535&D,!((k=D>>>24)<=v);){if(0===f)break e;f--,_+=r[u++]<>x)],E=D>>>16&255,O=65535&D,!(x+(k=D>>>24)<=v);){if(0===f)break e;f--,_+=r[u++]<>>=x,v-=x,n.back+=x}if(_>>>=k,v-=k,n.back+=k,n.length=O,0===E){n.mode=26;break}if(32&E){n.back=-1,n.mode=12;break}if(64&E){e.msg="invalid literal/length code",n.mode=30;break}n.extra=15&E,n.mode=22;case 22:if(n.extra){for(T=n.extra;v>>=n.extra,v-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=23;case 23:for(;D=n.distcode[_&(1<>>16&255,O=65535&D,!((k=D>>>24)<=v);){if(0===f)break e;f--,_+=r[u++]<>x)],E=D>>>16&255,O=65535&D,!(x+(k=D>>>24)<=v);){if(0===f)break e;f--,_+=r[u++]<>>=x,v-=x,n.back+=x}if(_>>>=k,v-=k,n.back+=k,64&E){e.msg="invalid distance code",n.mode=30;break}n.offset=O,n.extra=15&E,n.mode=24;case 24:if(n.extra){for(T=n.extra;v>>=n.extra,v-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=30;break}n.mode=25;case 25:if(0===p)break e;if(m=g-p,n.offset>m){if((m=n.offset-m)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=30;break}m>n.wnext?(m-=n.wnext,S=n.wsize-m):S=n.wnext-m,m>n.length&&(m=n.length),C=n.window}else C=l,S=d-n.offset,m=n.length;m>p&&(m=p),p-=m,n.length-=m;do{l[d++]=C[S++]}while(--m);0===n.length&&(n.mode=21);break;case 26:if(0===p)break e;l[d++]=n.length,p--,n.mode=21;break;case 27:if(n.wrap){for(;v<32;){if(0===f)break e;f--,_|=r[u++]<>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function d(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new i.Buf16(320),this.work=new i.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function f(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=1,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new i.Buf32(852),t.distcode=t.distdyn=new i.Buf32(592),t.sane=1,t.back=-1,0):-2}function p(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,f(e)):-2}function _(e,t){var n,r;return e&&e.state?(r=e.state,t<0?(n=0,t=-t):(n=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?-2:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,p(e))):-2}function v(e,t){var n,r;return e?(r=new d,e.state=r,r.window=null,0!==(n=_(e,t))&&(e.state=null),n):-2}var b,g,m=!0;function y(e){if(m){var t;for(b=new i.Buf32(512),g=new i.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for((0,c.default)(1,e.lens,0,288,b,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;(0,c.default)(2,e.lens,0,32,g,0,e.work,{bits:5}),m=!1}e.lencode=b,e.lenbits=9,e.distcode=g,e.distbits=5}function w(e,t,n,r){var o,s=e.state;return null===s.window&&(s.wsize=1<=s.wsize?(i.arraySet(s.window,t,n-s.wsize,s.wsize,0),s.wnext=0,s.whave=s.wsize):((o=s.wsize-s.wnext)>r&&(o=r),i.arraySet(s.window,t,n-r,o,s.wnext),(r-=o)?(i.arraySet(s.window,t,n-r,r,0),s.wnext=r,s.whave=s.wsize):(s.wnext+=o,s.wnext===s.wsize&&(s.wnext=0),s.whave0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=e.length,r=t.length;if(1!==Math.abs(n-r))return{add:!1,key:null};function i(e,t){var n=new Map;e.forEach((function(e){n.set(e,!0)}));var r=t.filter((function(e){return!n.has(e)}));return 1===r.length?r[0]:null}return n ").concat(t);return t}(L)),u.createElement("div",{role:"tree"},u.createElement("input",{style:O,disabled:!1===j||d,tabIndex:!1!==j?P:null,onKeyDown:K,onFocus:I,onBlur:F,value:"",onChange:x})),u.createElement(y.a,Object.assign({},H,{data:he,itemKey:T,height:w,fullHeight:!1,virtual:C,itemHeight:S,prefixCls:"".concat(n,"-list"),ref:U}),(function(e){var t=e.pos,n=e.data,r=n.key,i=Object(m.a)(n,["key"]),o=e.isStart,s=e.isEnd,a=Object(b.e)(r,t);delete i.children;var c=Object(b.f)(a,de);return u.createElement(k,Object.assign({},i,c,{active:L&&r===L.data.key,pos:t,data:e.data,isStart:o,isEnd:s,motion:v,motionNodes:r===A?ie:null,motionType:ce,onMotionStart:N,onMotionEnd:ue,treeNodeRequiredProps:de,onMouseMove:function(){X(null)}}))})))}));D.displayName="NodeList";var P=D,K=n("NvD2"),I=function(e){Object(c.a)(n,e);var t=Object(l.a)(n);function n(){var e;return Object(s.a)(this,n),(e=t.apply(this,arguments)).destroyed=!1,e.state={keyEntities:{},selectedKeys:[],checkedKeys:[],halfCheckedKeys:[],loadedKeys:[],loadingKeys:[],expandedKeys:[],dragging:!1,dragNodesKeys:[],dragOverNodeKey:null,dropPosition:null,treeData:[],flattenNodes:[],focused:!1,activeKey:null,listChanging:!1,prevProps:null},e.listRef=u.createRef(),e.onNodeDragStart=function(t,n){var r=e.state,i=r.expandedKeys,o=r.keyEntities,s=e.props.onDragStart,a=n.props.eventKey;e.dragNode=n;var c=Object(v.b)(i,a);e.setState({dragging:!0,dragNodesKeys:Object(v.g)(a,o)}),e.setExpandedKeys(c),s&&s({event:t,node:Object(b.b)(n.props)})},e.onNodeDragEnter=function(t,n){var r=e.state,i=r.expandedKeys,s=r.keyEntities,a=r.dragNodesKeys,c=e.props.onDragEnter,l=n.props,u=l.pos,h=l.eventKey;if(e.dragNode&&-1===a.indexOf(h)){var d=Object(v.c)(t,n);e.dragNode.props.eventKey!==h||0!==d?setTimeout((function(){e.setState({dragOverNodeKey:h,dropPosition:d}),e.delayedDragEnterLogic||(e.delayedDragEnterLogic={}),Object.keys(e.delayedDragEnterLogic).forEach((function(t){clearTimeout(e.delayedDragEnterLogic[t])})),e.delayedDragEnterLogic[u]=window.setTimeout((function(){if(e.state.dragging){var r=Object(o.a)(i),a=s[h];a&&(a.children||[]).length&&(r=Object(v.a)(i,h)),"expandedKeys"in e.props||e.setExpandedKeys(r),c&&c({event:t,node:Object(b.b)(n.props),expandedKeys:r})}}),400)}),0):e.setState({dragOverNodeKey:"",dropPosition:null})}},e.onNodeDragOver=function(t,n){var r=e.state.dragNodesKeys,i=e.props.onDragOver,o=n.props.eventKey;if(-1===r.indexOf(o)){if(e.dragNode&&o===e.state.dragOverNodeKey){var s=Object(v.c)(t,n);if(s===e.state.dropPosition)return;e.setState({dropPosition:s})}i&&i({event:t,node:Object(b.b)(n.props)})}},e.onNodeDragLeave=function(t,n){var r=e.props.onDragLeave;e.setState({dragOverNodeKey:""}),r&&r({event:t,node:Object(b.b)(n.props)})},e.onNodeDragEnd=function(t,n){var r=e.props.onDragEnd;e.setState({dragOverNodeKey:""}),e.cleanDragState(),r&&r({event:t,node:Object(b.b)(n.props)}),e.dragNode=null},e.onNodeDrop=function(t,n){var r=e.state,i=r.dragNodesKeys,o=void 0===i?[]:i,s=r.dropPosition,a=e.props.onDrop,c=n.props,l=c.eventKey,u=c.pos;if(e.setState({dragOverNodeKey:""}),e.cleanDragState(),-1===o.indexOf(l)){var h=Object(v.k)(u),f={event:t,node:Object(b.b)(n.props),dragNode:e.dragNode?Object(b.b)(e.dragNode.props):null,dragNodesKeys:o.slice(),dropPosition:s+Number(h[h.length-1]),dropToGap:!1};0!==s&&(f.dropToGap=!0),a&&a(f),e.dragNode=null}else Object(d.a)(!1,"Can not drop to dragNode(include it's children node)")},e.cleanDragState=function(){e.state.dragging&&e.setState({dragging:!1})},e.onNodeClick=function(t,n){var r=e.props.onClick;r&&r(t,n)},e.onNodeDoubleClick=function(t,n){var r=e.props.onDoubleClick;r&&r(t,n)},e.onNodeSelect=function(t,n){var r=e.state.selectedKeys,i=e.state.keyEntities,o=e.props,s=o.onSelect,a=o.multiple,c=n.selected,l=n.key,u=!c,h=(r=u?a?Object(v.a)(r,l):[l]:Object(v.b)(r,l)).map((function(e){var t=i[e];return t?t.node:null})).filter((function(e){return e}));e.setUncontrolledState({selectedKeys:r}),s&&s(r,{event:"select",selected:u,node:n,selectedNodes:h,nativeEvent:t.nativeEvent})},e.onNodeCheck=function(t,n,r){var i,s=e.state,a=s.keyEntities,c=s.checkedKeys,l=s.halfCheckedKeys,u=e.props,h=u.checkStrictly,d=u.onCheck,f=n.key,p={event:"check",node:n,checked:r,nativeEvent:t.nativeEvent};if(h){var _=r?Object(v.a)(c,f):Object(v.b)(c,f);i={checked:_,halfChecked:Object(v.b)(l,f)},p.checkedNodes=_.map((function(e){return a[e]})).filter((function(e){return e})).map((function(e){return e.node})),e.setUncontrolledState({checkedKeys:_})}else{var b=Object(K.a)([].concat(Object(o.a)(c),[f]),!0,a),g=b.checkedKeys,m=b.halfCheckedKeys;if(!r){var y=new Set(g);y.delete(f);var w=Object(K.a)(Array.from(y),{checked:!1,halfCheckedKeys:m},a);g=w.checkedKeys,m=w.halfCheckedKeys}i=g,p.checkedNodes=[],p.checkedNodesPositions=[],p.halfCheckedKeys=m,g.forEach((function(e){var t=a[e];if(t){var n=t.node,r=t.pos;p.checkedNodes.push(n),p.checkedNodesPositions.push({node:n,pos:r})}})),e.setUncontrolledState({checkedKeys:g},!1,{halfCheckedKeys:m})}d&&d(i,p)},e.onNodeLoad=function(t){return new Promise((function(n){e.setState((function(r){var i=r.loadedKeys,o=void 0===i?[]:i,s=r.loadingKeys,a=void 0===s?[]:s,c=e.props,l=c.loadData,u=c.onLoad,h=t.key;return l&&-1===o.indexOf(h)&&-1===a.indexOf(h)?(l(t).then((function(){var r=e.state,i=r.loadedKeys,o=r.loadingKeys,s=Object(v.a)(i,h),a=Object(v.b)(o,h);u&&u(s,{event:"load",node:t}),e.setUncontrolledState({loadedKeys:s}),e.setState({loadingKeys:a}),n()})),{loadingKeys:Object(v.a)(a,h)}):{}}))}))},e.onNodeMouseEnter=function(t,n){var r=e.props.onMouseEnter;r&&r({event:t,node:n})},e.onNodeMouseLeave=function(t,n){var r=e.props.onMouseLeave;r&&r({event:t,node:n})},e.onNodeContextMenu=function(t,n){var r=e.props.onRightClick;r&&(t.preventDefault(),r({event:t,node:n}))},e.onFocus=function(){var t=e.props.onFocus;e.setState({focused:!0}),t&&t.apply(void 0,arguments)},e.onBlur=function(){var t=e.props.onBlur;e.setState({focused:!1}),e.onActiveChange(null),t&&t.apply(void 0,arguments)},e.getTreeNodeRequiredProps=function(){var t=e.state;return{expandedKeys:t.expandedKeys||[],selectedKeys:t.selectedKeys||[],loadedKeys:t.loadedKeys||[],loadingKeys:t.loadingKeys||[],checkedKeys:t.checkedKeys||[],halfCheckedKeys:t.halfCheckedKeys||[],dragOverNodeKey:t.dragOverNodeKey,dropPosition:t.dropPosition,keyEntities:t.keyEntities}},e.setExpandedKeys=function(t){var n=e.state.treeData,r=Object(b.d)(n,t);e.setUncontrolledState({expandedKeys:t,flattenNodes:r},!0)},e.onNodeExpand=function(t,n){var r=e.state.expandedKeys,i=e.state.listChanging,o=e.props,s=o.onExpand,a=o.loadData,c=n.key,l=n.expanded;if(!i){var u=r.indexOf(c),h=!l;if(Object(d.a)(l&&-1!==u||!l&&-1===u,"Expand state not sync with index check"),r=h?Object(v.a)(r,c):Object(v.b)(r,c),e.setExpandedKeys(r),s&&s(r,{node:n,expanded:h,nativeEvent:t.nativeEvent}),h&&a){var f=e.onNodeLoad(n);f&&f.then((function(){var t=Object(b.d)(e.state.treeData,r);e.setUncontrolledState({flattenNodes:t})}))}}},e.onListChangeStart=function(){e.setUncontrolledState({listChanging:!0})},e.onListChangeEnd=function(){setTimeout((function(){e.setUncontrolledState({listChanging:!1})}))},e.onActiveChange=function(t){var n=e.state.activeKey,r=e.props.onActiveChange;n!==t&&(e.setState({activeKey:t}),null!==t&&e.scrollTo({key:t}),r&&r(t))},e.getActiveItem=function(){var t=e.state,n=t.activeKey,r=t.flattenNodes;return null===n?null:r.find((function(e){return e.data.key===n}))||null},e.offsetActiveKey=function(t){var n=e.state,r=n.flattenNodes,i=n.activeKey,o=r.findIndex((function(e){return e.data.key===i}));-1===o&&t<0&&(o=r.length);var s=r[o=(o+t+r.length)%r.length];if(s){var a=s.data.key;e.onActiveChange(a)}else e.onActiveChange(null)},e.onKeyDown=function(t){var n=e.state,r=n.activeKey,o=n.expandedKeys,s=n.checkedKeys,a=e.props,c=a.onKeyDown,l=a.checkable,u=a.selectable;switch(t.which){case h.a.UP:e.offsetActiveKey(-1),t.preventDefault();break;case h.a.DOWN:e.offsetActiveKey(1),t.preventDefault()}var d=e.getActiveItem();if(d&&d.data){var f=e.getTreeNodeRequiredProps(),p=!1===d.data.isLeaf||!!(d.data.children||[]).length,_=Object(b.b)(Object(i.a)(Object(i.a)({},Object(b.f)(r,f)),{},{data:d.data,active:!0}));switch(t.which){case h.a.LEFT:p&&o.includes(r)?e.onNodeExpand({},_):d.parent&&e.onActiveChange(d.parent.data.key),t.preventDefault();break;case h.a.RIGHT:p&&!o.includes(r)?e.onNodeExpand({},_):d.children&&d.children.length&&e.onActiveChange(d.children[0].data.key),t.preventDefault();break;case h.a.ENTER:case h.a.SPACE:!l||_.disabled||!1===_.checkable||_.disableCheckbox?l||!u||_.disabled||!1===_.selectable||e.onNodeSelect({},_):e.onNodeCheck({},_,!s.includes(r))}}c&&c(t)},e.setUncontrolledState=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!e.destroyed){var o=!1,s=!0,a={};Object.keys(t).forEach((function(n){n in e.props?s=!1:(o=!0,a[n]=t[n])})),!o||n&&!s||e.setState(Object(i.a)(Object(i.a)({},a),r))}},e.scrollTo=function(t){e.listRef.current.scrollTo(t)},e}return Object(a.a)(n,[{key:"componentWillUnmount",value:function(){this.destroyed=!0}},{key:"render",value:function(){var e,t=this.state,n=t.focused,i=t.flattenNodes,o=t.keyEntities,s=t.dragging,a=t.activeKey,c=this.props,l=c.prefixCls,h=c.className,d=c.style,f=c.showLine,b=c.focusable,g=c.tabIndex,m=void 0===g?0:g,y=c.selectable,w=c.showIcon,S=c.icon,C=c.switcherIcon,k=c.draggable,E=c.checkable,O=c.checkStrictly,x=c.disabled,A=c.motion,j=c.loadData,L=c.filterTreeNode,R=c.height,M=c.itemHeight,T=c.virtual,D=c.titleRender,K=c.onContextMenu,I=Object(v.f)(this.props);return u.createElement(_.a.Provider,{value:{prefixCls:l,selectable:y,showIcon:w,icon:S,switcherIcon:C,draggable:k,checkable:E,checkStrictly:O,disabled:x,keyEntities:o,loadData:j,filterTreeNode:L,titleRender:D,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}},u.createElement("div",{className:p()(l,h,(e={},Object(r.a)(e,"".concat(l,"-show-line"),f),Object(r.a)(e,"".concat(l,"-focused"),n),Object(r.a)(e,"".concat(l,"-active-focused"),null!==a),e))},u.createElement(P,Object.assign({ref:this.listRef,prefixCls:l,style:d,data:i,disabled:x,selectable:y,checkable:!!E,motion:A,dragging:s,height:R,itemHeight:M,virtual:T,focusable:b,focused:n,tabIndex:m,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:K},this.getTreeNodeRequiredProps(),I))))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n,o=t.prevProps,s={prevProps:e};function a(t){return!o&&t in e||o&&o[t]!==e[t]}if(a("treeData")?n=e.treeData:a("children")&&(Object(d.a)(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),n=Object(b.c)(e.children)),n){s.treeData=n;var c=Object(b.a)(n);s.keyEntities=Object(i.a)(Object(r.a)({},A,L),c.keyEntities)}var l,u=s.keyEntities||t.keyEntities;if(a("expandedKeys")||o&&a("autoExpandParent"))s.expandedKeys=e.autoExpandParent||!o&&e.defaultExpandParent?Object(v.e)(e.expandedKeys,u):e.expandedKeys;else if(!o&&e.defaultExpandAll){var h=Object(i.a)({},u);delete h[A],s.expandedKeys=Object.keys(h).map((function(e){return h[e].key}))}else!o&&e.defaultExpandedKeys&&(s.expandedKeys=e.autoExpandParent||e.defaultExpandParent?Object(v.e)(e.defaultExpandedKeys,u):e.defaultExpandedKeys);if(s.expandedKeys||delete s.expandedKeys,n||s.expandedKeys){var f=Object(b.d)(n||t.treeData,s.expandedKeys||t.expandedKeys);s.flattenNodes=f}if((e.selectable&&(a("selectedKeys")?s.selectedKeys=Object(v.d)(e.selectedKeys,e):!o&&e.defaultSelectedKeys&&(s.selectedKeys=Object(v.d)(e.defaultSelectedKeys,e))),e.checkable)&&(a("checkedKeys")?l=Object(v.j)(e.checkedKeys)||{}:!o&&e.defaultCheckedKeys?l=Object(v.j)(e.defaultCheckedKeys)||{}:n&&(l=Object(v.j)(e.checkedKeys)||{checkedKeys:t.checkedKeys,halfCheckedKeys:t.halfCheckedKeys}),l)){var p=l,_=p.checkedKeys,g=void 0===_?[]:_,m=p.halfCheckedKeys,y=void 0===m?[]:m;if(!e.checkStrictly){var w=Object(K.a)(g,!0,u);g=w.checkedKeys,y=w.halfCheckedKeys}s.checkedKeys=g,s.halfCheckedKeys=y}return a("loadedKeys")&&(s.loadedKeys=e.loadedKeys),s}}]),n}(u.Component);I.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:[]},I.TreeNode=S.a;var F=I;t.b=F},fcSX: /*!********************************************************!*\ !*** ./node_modules/rc-drawer/es/index.js + 3 modules ***! \********************************************************/ /*! exports provided: default */ /*! exports used: default */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/createClass.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/inherits.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/KeyCode.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/PortalWrapper.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/getScrollBarSize.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";var r=n("Ff2n"),i=n("1OyB"),o=n("vuIU"),s=n("Ji7U"),a=n("md7G"),c=n("foSv"),l=n("1W/9"),u=n("q1tI"),h=n("rePB"),d=n("JX7q"),f=n("TSYQ"),p=n.n(f),_=n("qx4F"),v=n("4IlW");var b={transition:"transitionend",WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend"},g=Object.keys(b).filter((function(e){if("undefined"==typeof document)return!1;var t=document.getElementsByTagName("html")[0];return e in(t?t.style:{})}))[0],m=b[g];function y(e,t,n,r){e.addEventListener?e.addEventListener(t,n,r):e.attachEvent&&e.attachEvent("on".concat(t),n)}function w(e,t,n,r){e.removeEventListener?e.removeEventListener(t,n,r):e.attachEvent&&e.detachEvent("on".concat(t),n)}var S=function(e){return!isNaN(parseFloat(e))&&isFinite(e)},C=!("undefined"!=typeof window&&window.document&&window.document.createElement);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object(c.a)(e);if(t){var i=Object(c.a)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Object(a.a)(this,n)}}var E={},O=function(e){Object(s.a)(n,e);var t=k(n);function n(e){var r;return Object(i.a)(this,n),(r=t.call(this,e)).domFocus=function(){r.dom&&r.dom.focus()},r.removeStartHandler=function(e){e.touches.length>1||(r.startPos={x:e.touches[0].clientX,y:e.touches[0].clientY})},r.removeMoveHandler=function(e){if(!(e.changedTouches.length>1)){var t=e.currentTarget,n=e.changedTouches[0].clientX-r.startPos.x,i=e.changedTouches[0].clientY-r.startPos.y;(t===r.maskDom||t===r.handlerDom||t===r.contentDom&&function e(t,n,r,i){if(!n||n===document||n instanceof Document)return!1;if(n===t.parentNode)return!0;var o=Math.max(Math.abs(r),Math.abs(i))===Math.abs(i),s=Math.max(Math.abs(r),Math.abs(i))===Math.abs(r),a=n.scrollHeight-n.clientHeight,c=n.scrollWidth-n.clientWidth,l=document.defaultView.getComputedStyle(n),u="auto"===l.overflowY||"scroll"===l.overflowY,h="auto"===l.overflowX||"scroll"===l.overflowX,d=a&&u,f=c&&h;return!!(o&&(!d||d&&(n.scrollTop>=a&&i<0||n.scrollTop<=0&&i>0))||s&&(!f||f&&(n.scrollLeft>=c&&r<0||n.scrollLeft<=0&&r>0)))&&e(t,n.parentNode,r,i)}(t,e.target,n,i))&&e.cancelable&&e.preventDefault()}},r.transitionEnd=function(e){var t=e.target;w(t,m,r.transitionEnd),t.style.transition=""},r.onKeyDown=function(e){if(e.keyCode===v.a.ESC){var t=r.props.onClose;e.stopPropagation(),t&&t(e)}},r.onWrapperTransitionEnd=function(e){var t=r.props,n=t.open,i=t.afterVisibleChange;e.target===r.contentWrapper&&e.propertyName.match(/transform$/)&&(r.dom.style.transition="",!n&&r.getCurrentDrawerSome()&&(document.body.style.overflowX="",r.maskDom&&(r.maskDom.style.left="",r.maskDom.style.width="")),i&&i(!!n))},r.openLevelTransition=function(){var e=r.props,t=e.open,n=e.width,i=e.height,o=r.getHorizontalBoolAndPlacementName(),s=o.isHorizontal,a=o.placementName,c=r.contentDom?r.contentDom.getBoundingClientRect()[s?"width":"height"]:0,l=(s?n:i)||c;r.setLevelAndScrolling(t,a,l)},r.setLevelTransform=function(e,t,n,i){var o=r.props,s=o.placement,a=o.levelMove,c=o.duration,l=o.ease,u=o.showMask;r.levelDom.forEach((function(o){o.style.transition="transform ".concat(c," ").concat(l),y(o,m,r.transitionEnd);var h,d,f,p=e?n:0;if(a){var _=(d={target:o,open:e},f="function"==typeof(h=a)?h(d):h,Array.isArray(f)?2===f.length?f:[f[0],f[1]]:[f]);p=e?_[0]:_[1]||0}var v="number"==typeof p?"".concat(p,"px"):p,b="left"===s||"top"===s?v:"-".concat(v);b=u&&"right"===s&&i?"calc(".concat(b," + ").concat(i,"px)"):b,o.style.transform=p?"".concat(t,"(").concat(b,")"):""}))},r.setLevelAndScrolling=function(e,t,n){var i=r.props.onChange;if(!C){var o=document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth?Object(_.a)(!0):0;r.setLevelTransform(e,t,n,o),r.toggleScrollingToDrawerAndBody(o)}i&&i(e)},r.toggleScrollingToDrawerAndBody=function(e){var t=r.props,n=t.getOpenCount,i=t.getContainer,o=t.showMask,s=t.open,a=i&&i(),c=n&&n();if(a&&a.parentNode===document.body&&o){var l=["touchstart"],u=[document.body,r.maskDom,r.handlerDom,r.contentDom];s&&"hidden"!==document.body.style.overflow?(e&&r.addScrollingEffect(e),1===c&&(document.body.style.overflow="hidden"),document.body.style.touchAction="none",u.forEach((function(e,t){e&&y(e,l[t]||"touchmove",t?r.removeMoveHandler:r.removeStartHandler,r.passive)}))):r.getCurrentDrawerSome()&&(c||(document.body.style.overflow=""),document.body.style.touchAction="",e&&r.remScrollingEffect(e),u.forEach((function(e,t){e&&w(e,l[t]||"touchmove",t?r.removeMoveHandler:r.removeStartHandler,r.passive)})))}},r.addScrollingEffect=function(e){var t=r.props,n=t.placement,i=t.duration,o=t.ease,s=t.getOpenCount,a=t.switchScrollingEffect;1===(s&&s())&&a();var c="width ".concat(i," ").concat(o),l="transform ".concat(i," ").concat(o);switch(r.dom.style.transition="none",n){case"right":r.dom.style.transform="translateX(-".concat(e,"px)");break;case"top":case"bottom":r.dom.style.width="calc(100% - ".concat(e,"px)"),r.dom.style.transform="translateZ(0)"}clearTimeout(r.timeout),r.timeout=setTimeout((function(){r.dom&&(r.dom.style.transition="".concat(l,",").concat(c),r.dom.style.width="",r.dom.style.transform="")}))},r.remScrollingEffect=function(e){var t,n=r.props,i=n.placement,o=n.duration,s=n.ease,a=n.getOpenCount,c=n.switchScrollingEffect;a&&a()||c(!0),g&&(document.body.style.overflowX="hidden"),r.dom.style.transition="none";var l="width ".concat(o," ").concat(s),u="transform ".concat(o," ").concat(s);switch(i){case"left":r.dom.style.width="100%",l="width 0s ".concat(s," ").concat(o);break;case"right":r.dom.style.transform="translateX(".concat(e,"px)"),r.dom.style.width="100%",l="width 0s ".concat(s," ").concat(o),r.maskDom&&(r.maskDom.style.left="-".concat(e,"px"),r.maskDom.style.width="calc(100% + ".concat(e,"px)"));break;case"top":case"bottom":r.dom.style.width="calc(100% + ".concat(e,"px)"),r.dom.style.height="100%",r.dom.style.transform="translateZ(0)",t="height 0s ".concat(s," ").concat(o)}clearTimeout(r.timeout),r.timeout=setTimeout((function(){r.dom&&(r.dom.style.transition="".concat(u,",").concat(t?"".concat(t,","):"").concat(l),r.dom.style.transform="",r.dom.style.width="",r.dom.style.height="")}))},r.getCurrentDrawerSome=function(){return!Object.keys(E).some((function(e){return E[e]}))},r.getLevelDom=function(e){var t=e.level,n=e.getContainer;if(!C){var i,o=n&&n(),s=o?o.parentNode:null;if(r.levelDom=[],"all"===t)(s?Array.prototype.slice.call(s.children):[]).forEach((function(e){"SCRIPT"!==e.nodeName&&"STYLE"!==e.nodeName&&"LINK"!==e.nodeName&&e!==o&&r.levelDom.push(e)}));else t&&(i=t,Array.isArray(i)?i:[i]).forEach((function(e){document.querySelectorAll(e).forEach((function(e){r.levelDom.push(e)}))}))}},r.getHorizontalBoolAndPlacementName=function(){var e=r.props.placement,t="left"===e||"right"===e;return{isHorizontal:t,placementName:"translate".concat(t?"X":"Y")}},r.state={_self:Object(d.a)(r)},r}return Object(o.a)(n,[{key:"componentDidMount",value:function(){var e=this;if(!C){var t=!1;try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:function(){return t=!0,null}}))}catch(e){}this.passive=!!t&&{passive:!1}}var n=this.props,r=n.open,i=n.getContainer,o=i&&i();this.drawerId="drawer_id_".concat(Number((Date.now()+Math.random()).toString().replace(".",Math.round(9*Math.random()).toString())).toString(16)),this.getLevelDom(this.props),r&&(o&&o.parentNode===document.body&&(E[this.drawerId]=r),this.openLevelTransition(),this.forceUpdate((function(){e.domFocus()})))}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.open,r=t.getContainer,i=r&&r();n!==e.open&&(n&&this.domFocus(),i&&i.parentNode===document.body&&(E[this.drawerId]=!!n),this.openLevelTransition())}},{key:"componentWillUnmount",value:function(){var e=this.props,t=e.getOpenCount,n=e.open,r=e.switchScrollingEffect,i="function"==typeof t&&t();delete E[this.drawerId],n&&(this.setLevelTransform(!1),document.body.style.touchAction=""),i||(document.body.style.overflow="",r(!0))}},{key:"render",value:function(){var e,t=this,n=this.props,i=n.className,o=n.children,s=n.style,a=n.width,c=n.height,l=(n.defaultOpen,n.open),d=n.prefixCls,f=n.placement,_=(n.level,n.levelMove,n.ease,n.duration,n.getContainer,n.handler),v=(n.onChange,n.afterVisibleChange,n.showMask),b=n.maskClosable,g=n.maskStyle,m=n.onClose,y=n.onHandleClick,w=n.keyboard,C=(n.getOpenCount,n.switchScrollingEffect,Object(r.a)(n,["className","children","style","width","height","defaultOpen","open","prefixCls","placement","level","levelMove","ease","duration","getContainer","handler","onChange","afterVisibleChange","showMask","maskClosable","maskStyle","onClose","onHandleClick","keyboard","getOpenCount","switchScrollingEffect"])),k=!!this.dom&&l,E=p()(d,(e={},Object(h.a)(e,"".concat(d,"-").concat(f),!0),Object(h.a)(e,"".concat(d,"-open"),k),Object(h.a)(e,i||"",!!i),Object(h.a)(e,"no-mask",!v),e)),O=this.getHorizontalBoolAndPlacementName().placementName,x="left"===f||"top"===f?"-100%":"100%",A=k?"":"".concat(O,"(").concat(x,")"),j=_&&u.cloneElement(_,{onClick:function(e){_.props.onClick&&_.props.onClick(),y&&y(e)},ref:function(e){t.handlerDom=e}});return u.createElement("div",Object.assign({},C,{tabIndex:-1,className:E,style:s,ref:function(e){t.dom=e},onKeyDown:k&&w?this.onKeyDown:void 0,onTransitionEnd:this.onWrapperTransitionEnd}),v&&u.createElement("div",{className:"".concat(d,"-mask"),onClick:b?m:void 0,style:g,ref:function(e){t.maskDom=e}}),u.createElement("div",{className:"".concat(d,"-content-wrapper"),style:{transform:A,msTransform:A,width:S(a)?"".concat(a,"px"):a,height:S(c)?"".concat(c,"px"):c},ref:function(e){t.contentWrapper=e}},u.createElement("div",{className:"".concat(d,"-content"),ref:function(e){t.contentDom=e},onTouchStart:k&&v?this.removeStartHandler:void 0,onTouchMove:k&&v?this.removeMoveHandler:void 0},o),j))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r=t._self,i={prevProps:e};if(void 0!==n){var o=e.placement,s=e.level;o!==n.placement&&(r.contentDom=null),s!==n.level&&r.getLevelDom(e)}return i}}]),n}(u.Component);O.defaultProps={switchScrollingEffect:function(){}};var x=O;function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Object(c.a)(e);if(t){var i=Object(c.a)(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Object(a.a)(this,n)}}var j=function(e){Object(s.a)(n,e);var t=A(n);function n(e){var r;Object(i.a)(this,n),(r=t.call(this,e)).onHandleClick=function(e){var t=r.props,n=t.onHandleClick,i=t.open;if(n&&n(e),void 0===i){var o=r.state.open;r.setState({open:!o})}},r.onClose=function(e){var t=r.props,n=t.onClose,i=t.open;n&&n(e),void 0===i&&r.setState({open:!1})};var o=void 0!==e.open?e.open:!!e.defaultOpen;return r.state={open:o},"onMaskClick"in e&&console.warn("`onMaskClick` are removed, please use `onClose` instead."),r}return Object(o.a)(n,[{key:"render",value:function(){var e=this,t=this.props,n=(t.defaultOpen,t.getContainer),i=t.wrapperClassName,o=t.forceRender,s=t.handler,a=Object(r.a)(t,["defaultOpen","getContainer","wrapperClassName","forceRender","handler"]),c=this.state.open;if(!n)return u.createElement("div",{className:i,ref:function(t){e.dom=t}},u.createElement(x,Object.assign({},a,{open:c,handler:s,getContainer:function(){return e.dom},onClose:this.onClose,onHandleClick:this.onHandleClick})));var h=!!s||o;return u.createElement(l.a,{visible:c,forceRender:h,getContainer:n,wrapperClassName:i},(function(t){var n=t.visible,i=t.afterClose,o=Object(r.a)(t,["visible","afterClose"]);return u.createElement(x,Object.assign({},a,o,{open:void 0!==n?n:c,afterVisibleChange:void 0!==i?i:a.afterVisibleChange,handler:s,onClose:e.onClose,onHandleClick:e.onHandleClick}))}))}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r={prevProps:e};return void 0!==n&&e.open!==n.open&&(r.open=e.open),r}}]),n}(u.Component);j.defaultProps={prefixCls:"drawer",placement:"left",getContainer:"body",defaultOpen:!1,level:"all",duration:".3s",ease:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",onChange:function(){},afterVisibleChange:function(){},handler:u.createElement("div",{className:"drawer-handle"},u.createElement("i",{className:"drawer-handle-icon"})),showMask:!0,maskClosable:!0,maskStyle:{},wrapperClassName:"",className:"",keyboard:!0,forceRender:!1};var L=j;t.a=L},fr4D: /*!***********************************!*\ !*** ./src/service/innovation.ts ***! \***********************************/ /*! exports provided: createProject, editProject, getMirrorRepos, getProjectList, deleteProject, getProjectDetail, getDataSetList, removeDataSets, startEnvironment, forkProject, getProjectDataSet */ /*! exports used: createProject, deleteProject, editProject, forkProject, getDataSetList, getMirrorRepos, getProjectDataSet, getProjectDetail, startEnvironment */function(e,t,n){"use strict";n.d(t,"a",(function(){return a})),n.d(t,"c",(function(){return l})),n.d(t,"f",(function(){return h})),n.d(t,"b",(function(){return f})),n.d(t,"h",(function(){return _})),n.d(t,"e",(function(){return b})),n.d(t,"i",(function(){return m})),n.d(t,"d",(function(){return w})),n.d(t,"g",(function(){return C}));var r=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator */"9og8"),i=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator */"WmNS"),o=n.n(i),s=n(/*! @/utils/fetch */"ErOA");function a(e){return c.apply(this,arguments)}function c(){return(c=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects.json",{method:"post",body:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function l(e,t){return u.apply(this,arguments)}function u(){return(u=Object(r.a)(o.a.mark((function e(t,n){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/".concat(n,".json"),{method:"put",body:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function h(e){return d.apply(this,arguments)}function d(){return(d=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/sci_mirror_repositories.json",{method:"get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function f(e,t){return p.apply(this,arguments)}function p(){return(p=Object(r.a)(o.a.mark((function e(t,n){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/".concat(t,".json"),{method:"delete",body:n}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function _(e){return v.apply(this,arguments)}function v(){return(v=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/".concat(t,".json"),{method:"get"}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function b(e){return g.apply(this,arguments)}function g(){return(g=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/data_sets.json",{method:"get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function m(e){return y.apply(this,arguments)}function y(){return(y=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/".concat(t,"/start_environment.json"),{method:"post"}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function w(e,t){return S.apply(this,arguments)}function S(){return(S=Object(r.a)(o.a.mark((function e(t,n){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/".concat(t,"/fork_sci_project.json"),{method:"post",body:n}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function C(e,t){return k.apply(this,arguments)}function k(){return(k=Object(r.a)(o.a.mark((function e(t,n){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/sci/projects/".concat(t,"/get_data_sets.json"),{method:"get",params:n}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}},fyJ8: /*!************************************************!*\ !*** ./node_modules/rc-table/es/Cell/index.js ***! \************************************************/ /*! exports provided: default */ /*! exports used: default */function(e,t,n){"use strict";var r=n(/*! @babel/runtime/helpers/esm/defineProperty */"rePB"),i=n(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),o=n(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),s=n(/*! @babel/runtime/helpers/esm/typeof */"U8pU"),a=n(/*! react */"q1tI"),c=n(/*! classnames */"TSYQ"),l=n.n(c),u=n(/*! rc-util/es/ref */"c+Xe"),h=n(/*! ../utils/valueUtil */"sR1s");var d=a.forwardRef((function(e,t){var n,c,d,f,p=e.prefixCls,_=e.className,v=e.record,b=e.index,g=e.dataIndex,m=e.render,y=e.children,w=e.component,S=void 0===w?"td":w,C=e.colSpan,k=e.rowSpan,E=e.fixLeft,O=e.fixRight,x=e.firstFixLeft,A=e.lastFixLeft,j=e.firstFixRight,L=e.lastFixRight,R=e.appendNode,M=e.additionalProps,T=void 0===M?{}:M,D=e.ellipsis,P=e.align,K=e.rowType,I=e.isSticky,F="".concat(p,"-cell");if(y)d=y;else{var X=Object(h.b)(v,g);if(d=X,m){var N=m(X,v,b);!(f=N)||"object"!==Object(s.a)(f)||Array.isArray(f)||a.isValidElement(f)?d=N:(d=N.children,c=N.props)}}"object"!==Object(s.a)(d)||Array.isArray(d)||a.isValidElement(d)||(d=null),D&&(A||j)&&(d=a.createElement("span",{className:"".concat(F,"-content")},d));var B=c||{},H=B.colSpan,U=B.rowSpan,W=B.style,z=B.className,V=Object(o.a)(B,["colSpan","rowSpan","style","className"]),Q=void 0!==H?H:C,q=void 0!==U?U:k;if(0===Q||0===q)return null;var G={},Y="number"==typeof E,Z="number"==typeof O;Y&&(G.position="sticky",G.left=E),Z&&(G.position="sticky",G.right=O);var J,$={};P&&($.textAlign=P);var ee=!0===D?{showTitle:!0}:D;ee&&(ee.showTitle||"header"===K)&&("string"==typeof d||"number"==typeof d?J=d.toString():a.isValidElement(d)&&"string"==typeof d.props.children&&(J=d.props.children));var te,ne=Object(i.a)(Object(i.a)(Object(i.a)({title:J},V),T),{},{colSpan:Q&&1!==Q?Q:null,rowSpan:q&&1!==q?q:null,className:l()(F,_,(n={},Object(r.a)(n,"".concat(F,"-fix-left"),Y),Object(r.a)(n,"".concat(F,"-fix-left-first"),x),Object(r.a)(n,"".concat(F,"-fix-left-last"),A),Object(r.a)(n,"".concat(F,"-fix-right"),Z),Object(r.a)(n,"".concat(F,"-fix-right-first"),j),Object(r.a)(n,"".concat(F,"-fix-right-last"),L),Object(r.a)(n,"".concat(F,"-ellipsis"),D),Object(r.a)(n,"".concat(F,"-with-append"),R),Object(r.a)(n,"".concat(F,"-fix-sticky"),(Y||Z)&&I),n),T.className,z),style:Object(i.a)(Object(i.a)(Object(i.a)(Object(i.a)({},T.style),$),G),W),ref:(te=S,"string"==typeof te||Object(u.c)(te)?t:null)});return a.createElement(S,Object.assign({},ne),R,d)}));d.displayName="Cell";var f=a.memo(d,(function(e,t){return!!t.shouldCellUpdate&&!t.shouldCellUpdate(t.record,e.record)}));t.a=f},gIYZ: /*!**********************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/input/fixedkeys.js ***! \**********************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={Backspace:"Backspace",AltLeft:"Alt",AltRight:"Alt",CapsLock:"CapsLock",ContextMenu:"ContextMenu",ControlLeft:"Control",ControlRight:"Control",Enter:"Enter",MetaLeft:"Meta",MetaRight:"Meta",ShiftLeft:"Shift",ShiftRight:"Shift",Tab:"Tab",Delete:"Delete",End:"End",Help:"Help",Home:"Home",Insert:"Insert",PageDown:"PageDown",PageUp:"PageUp",ArrowDown:"ArrowDown",ArrowLeft:"ArrowLeft",ArrowRight:"ArrowRight",ArrowUp:"ArrowUp",NumLock:"NumLock",NumpadBackspace:"Backspace",NumpadClear:"Clear",Escape:"Escape",F1:"F1",F2:"F2",F3:"F3",F4:"F4",F5:"F5",F6:"F6",F7:"F7",F8:"F8",F9:"F9",F10:"F10",F11:"F11",F12:"F12",F13:"F13",F14:"F14",F15:"F15",F16:"F16",F17:"F17",F18:"F18",F19:"F19",F20:"F20",F21:"F21",F22:"F22",F23:"F23",F24:"F24",F25:"F25",F26:"F26",F27:"F27",F28:"F28",F29:"F29",F30:"F30",F31:"F31",F32:"F32",F33:"F33",F34:"F34",F35:"F35",PrintScreen:"PrintScreen",ScrollLock:"ScrollLock",Pause:"Pause",BrowserBack:"BrowserBack",BrowserFavorites:"BrowserFavorites",BrowserForward:"BrowserForward",BrowserHome:"BrowserHome",BrowserRefresh:"BrowserRefresh",BrowserSearch:"BrowserSearch",BrowserStop:"BrowserStop",Eject:"Eject",LaunchApp1:"LaunchMyComputer",LaunchApp2:"LaunchCalendar",LaunchMail:"LaunchMail",MediaPlayPause:"MediaPlay",MediaStop:"MediaStop",MediaTrackNext:"MediaTrackNext",MediaTrackPrevious:"MediaTrackPrevious",Power:"Power",Sleep:"Sleep",AudioVolumeDown:"AudioVolumeDown",AudioVolumeMute:"AudioVolumeMute",AudioVolumeUp:"AudioVolumeUp",WakeUp:"WakeUp"}},h78n: /*!**********************************************************!*\ !*** ./node_modules/rc-progress/es/index.js + 3 modules ***! \**********************************************************/ /*! exports provided: Line, Circle, default */ /*! exports used: Circle */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";n.d(t,"a",(function(){return C}));var r=n("q1tI"),i=n.n(r),o=n("TSYQ"),s=n.n(o),a={className:"",percent:0,prefixCls:"rc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,style:{},trailColor:"#D9D9D9",trailWidth:1},c=function(e){var t=e.map((function(){return Object(r.useRef)()})),n=Object(r.useRef)();return Object(r.useEffect)((function(){var e=Date.now(),r=!1;Object.keys(t).forEach((function(i){var o=t[i].current;if(o){r=!0;var s=o.style;s.transitionDuration=".3s, .3s, .3s, .06s",n.current&&e-n.current<100&&(s.transitionDuration="0s, 0s")}})),r&&(n.current=Date.now())})),[t]};function l(){return(l=Object.assign||function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}var f=function(e){var t=e.className,n=e.percent,r=e.prefixCls,o=e.strokeColor,a=e.strokeLinecap,h=e.strokeWidth,f=e.style,p=e.trailColor,_=e.trailWidth,v=e.transition,b=d(e,["className","percent","prefixCls","strokeColor","strokeLinecap","strokeWidth","style","trailColor","trailWidth","transition"]);delete b.gapPosition;var g=Array.isArray(n)?n:[n],m=Array.isArray(o)?o:[o],y=u(c(g),1)[0],w=h/2,S=100-h/2,C="M ".concat("round"===a?w:0,",").concat(w,"\n L ").concat("round"===a?S:100,",").concat(w),k="0 0 100 ".concat(h),E=0;return i.a.createElement("svg",l({className:s()("".concat(r,"-line"),t),viewBox:k,preserveAspectRatio:"none",style:f},b),i.a.createElement("path",{className:"".concat(r,"-line-trail"),d:C,strokeLinecap:a,stroke:p,strokeWidth:_||h,fillOpacity:"0"}),g.map((function(e,t){var n={strokeDasharray:"".concat(e,"px, 100px"),strokeDashoffset:"-".concat(E,"px"),transition:v||"stroke-dashoffset 0.3s ease 0s, stroke-dasharray .3s ease 0s, stroke 0.3s linear"},o=m[t]||m[m.length-1];return E+=e,i.a.createElement("path",{key:t,className:"".concat(r,"-line-path"),d:C,strokeLinecap:a,stroke:o,strokeWidth:h,fillOpacity:"0",ref:y[t],style:n})})))};f.defaultProps=a;function p(){return(p=Object.assign||function(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}var g=0;function m(e){return+e.replace("%","")}function y(e){return Array.isArray(e)?e:[e]}function w(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o=arguments.length>5?arguments[5]:void 0,s=50-r/2,a=0,c=-s,l=0,u=-2*s;switch(o){case"left":a=-s,c=0,l=2*s,u=0;break;case"right":a=s,c=0,l=-2*s,u=0;break;case"bottom":c=s,u=2*s}var h="M 50,50 m ".concat(a,",").concat(c,"\n a ").concat(s,",").concat(s," 0 1 1 ").concat(l,",").concat(-u,"\n a ").concat(s,",").concat(s," 0 1 1 ").concat(-l,",").concat(u),d=2*Math.PI*s,f={stroke:n,strokeDasharray:"".concat(t/100*(d-i),"px ").concat(d,"px"),strokeDashoffset:"-".concat(i/2+e/100*(d-i),"px"),transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s"};return{pathString:h,pathStyle:f}}var S=function(e){var t,n=e.prefixCls,o=e.strokeWidth,a=e.trailWidth,l=e.gapDegree,u=e.gapPosition,h=e.trailColor,d=e.strokeLinecap,f=e.style,v=e.className,S=e.strokeColor,C=e.percent,k=b(e,["prefixCls","strokeWidth","trailWidth","gapDegree","gapPosition","trailColor","strokeLinecap","style","className","strokeColor","percent"]),E=Object(r.useMemo)((function(){return g+=1}),[]),O=w(0,100,h,o,l,u),x=O.pathString,A=O.pathStyle,j=y(C),L=y(S),R=L.find((function(e){return"[object Object]"===Object.prototype.toString.call(e)})),M=_(c(j),1)[0];return i.a.createElement("svg",p({className:s()("".concat(n,"-circle"),v),viewBox:"0 0 100 100",style:f},k),R&&i.a.createElement("defs",null,i.a.createElement("linearGradient",{id:"".concat(n,"-gradient-").concat(E),x1:"100%",y1:"0%",x2:"0%",y2:"0%"},Object.keys(R).sort((function(e,t){return m(e)-m(t)})).map((function(e,t){return i.a.createElement("stop",{key:t,offset:e,stopColor:R[e]})})))),i.a.createElement("path",{className:"".concat(n,"-circle-trail"),d:x,stroke:h,strokeLinecap:d,strokeWidth:a||o,fillOpacity:"0",style:A}),(t=0,j.map((function(e,r){var s=L[r]||L[L.length-1],a="[object Object]"===Object.prototype.toString.call(s)?"url(#".concat(n,"-gradient-").concat(E,")"):"",c=w(t,e,s,o,l,u);return t+=e,i.a.createElement("path",{key:r,className:"".concat(n,"-circle-path"),d:c.pathString,stroke:a,strokeLinecap:d,strokeWidth:o,opacity:0===e?0:1,fillOpacity:"0",style:c.pathStyle,ref:M[r]})}))).reverse())};S.defaultProps=a;var C=S},hW8S: /*!******************************************************!*\ !*** ./node_modules/rc-table/es/utils/legacyUtil.js ***! \******************************************************/ /*! exports provided: INTERNAL_COL_DEFINE, getExpandableProps, getDataAndAriaProps */ /*! exports used: INTERNAL_COL_DEFINE, getDataAndAriaProps, getExpandableProps */function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"c",(function(){return s})),n.d(t,"b",(function(){return a}));var r=n(/*! @babel/runtime/helpers/esm/objectSpread2 */"VTBJ"),i=n(/*! @babel/runtime/helpers/esm/objectWithoutProperties */"Ff2n"),o=(n(/*! rc-util/es/warning */"Kwbf"),"RC_TABLE_INTERNAL_COL_DEFINE");function s(e){var t=e.expandable,n=Object(i.a)(e,["expandable"]);return"expandable"in e?Object(r.a)(Object(r.a)({},n),t):n}function a(e){return Object.keys(e).reduce((function(t,n){return"data-"!==n.substr(0,5)&&"aria-"!==n.substr(0,5)||(t[n]=e[n]),t}),{})}},hXwI: /*!************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/decoders/copyrect.js ***! \************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e,t){for(var n=0;n>>3]&1<>>10,this.keys[m]|=(4032&w)>>>6,++m,this.keys[m]=(258048&y)<<12,this.keys[m]|=(63&y)<<16,this.keys[m]|=(258048&w)>>>4,this.keys[m]|=63&w,++m}}var t,n,i;return t=e,(n=[{key:"enc8",value:function(e){var t,n,r,i=e.slice(),o=0;t=i[o++]<<24|i[o++]<<16|i[o++]<<8|i[o++],n=i[o++]<<24|i[o++]<<16|i[o++]<<8|i[o++],n^=r=252645135&(t>>>4^n),n^=r=65535&((t^=r<<4)>>>16^n),n^=(r=858993459&(n>>>2^(t^=r<<16)))<<2,n=(n^=(r=16711935&(n>>>8^(t^=r)))<<8)<<1|n>>>31&1,n^=r=2863311530&((t^=r)^n),t=(t^=r)<<1|t>>>31&1;for(var s=0,a=0;s<8;++s){r=n<<28|n>>>4,r^=this.keys[a++];var c=g[63&r];c|=v[r>>>8&63],c|=p[r>>>16&63],c|=d[r>>>24&63],r=n^this.keys[a++],c|=m[63&r],c|=b[r>>>8&63],c|=_[r>>>16&63],r=(t^=c|=f[r>>>24&63])<<28|t>>>4,r^=this.keys[a++],c=g[63&r],c|=v[r>>>8&63],c|=p[r>>>16&63],c|=d[r>>>24&63],r=t^this.keys[a++],c|=m[63&r],c|=b[r>>>8&63],c|=_[r>>>16&63],n^=c|=f[r>>>24&63]}for(n=n<<31|n>>>1,n^=r=2863311530&(t^n),n^=r=16711935&((t=(t^=r)<<31|t>>>1)>>>8^n),n^=r=858993459&((t^=r<<8)>>>2^n),n^=(r=65535&(n>>>16^(t^=r<<2)))<<16,r=[n^=(r=252645135&(n>>>4^(t^=r)))<<4,t^=r],o=0;o<8;o++)i[o]=(r[o>>>2]>>>8*(3-o%4))%256,i[o]<0&&(i[o]+=256);return i}},{key:"encrypt",value:function(e){return this.enc8(e.slice(0,8)).concat(this.enc8(e.slice(8,16)))}}])&&r(t.prototype,n),i&&r(t,i),e}();t.default=y},lNSK: /*!***********************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/vendor/pako/lib/zlib/deflate.js ***! \***********************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.deflateInit=function(e,t){return A(e,t,8,15,8,0)},t.deflateInit2=A,t.deflateReset=x,t.deflateResetKeep=O,t.deflateSetHeader=function(e,t){if(!e||!e.state)return-2;if(2!==e.state.wrap)return-2;return e.state.gzhead=t,0},t.deflate=function(e,t){var n,r,i,s;if(!e||!e.state||t>5||t<0)return e?f(e,-2):-2;if(r=e.state,!e.output||!e.input&&0!==e.avail_in||666===r.status&&4!==t)return f(e,0===e.avail_out?-5:-2);if(r.strm=e,n=r.last_flush,r.last_flush=t,42===r.status)if(2===r.wrap)e.adler=0,g(r,31),g(r,139),g(r,8),r.gzhead?(g(r,(r.gzhead.text?1:0)+(r.gzhead.hcrc?2:0)+(r.gzhead.extra?4:0)+(r.gzhead.name?8:0)+(r.gzhead.comment?16:0)),g(r,255&r.gzhead.time),g(r,r.gzhead.time>>8&255),g(r,r.gzhead.time>>16&255),g(r,r.gzhead.time>>24&255),g(r,9===r.level?2:r.strategy>=2||r.level<2?4:0),g(r,255&r.gzhead.os),r.gzhead.extra&&r.gzhead.extra.length&&(g(r,255&r.gzhead.extra.length),g(r,r.gzhead.extra.length>>8&255)),r.gzhead.hcrc&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending,0)),r.gzindex=0,r.status=69):(g(r,0),g(r,0),g(r,0),g(r,0),g(r,0),g(r,9===r.level?2:r.strategy>=2||r.level<2?4:0),g(r,3),r.status=113);else{var c=8+(r.w_bits-8<<4)<<8,l=-1;l=r.strategy>=2||r.level<2?0:r.level<6?1:6===r.level?2:3,c|=l<<6,0!==r.strstart&&(c|=32),c+=31-c%31,r.status=113,m(r,c),0!==r.strstart&&(m(r,e.adler>>>16),m(r,65535&e.adler)),e.adler=1}if(69===r.status)if(r.gzhead.extra){for(i=r.pending;r.gzindex<(65535&r.gzhead.extra.length)&&(r.pending!==r.pending_buf_size||(r.gzhead.hcrc&&r.pending>i&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending-i,i)),v(e),i=r.pending,r.pending!==r.pending_buf_size));)g(r,255&r.gzhead.extra[r.gzindex]),r.gzindex++;r.gzhead.hcrc&&r.pending>i&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending-i,i)),r.gzindex===r.gzhead.extra.length&&(r.gzindex=0,r.status=73)}else r.status=73;if(73===r.status)if(r.gzhead.name){i=r.pending;do{if(r.pending===r.pending_buf_size&&(r.gzhead.hcrc&&r.pending>i&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending-i,i)),v(e),i=r.pending,r.pending===r.pending_buf_size)){s=1;break}s=r.gzindexi&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending-i,i)),0===s&&(r.gzindex=0,r.status=91)}else r.status=91;if(91===r.status)if(r.gzhead.comment){i=r.pending;do{if(r.pending===r.pending_buf_size&&(r.gzhead.hcrc&&r.pending>i&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending-i,i)),v(e),i=r.pending,r.pending===r.pending_buf_size)){s=1;break}s=r.gzindexi&&(e.adler=(0,a.default)(e.adler,r.pending_buf,r.pending-i,i)),0===s&&(r.status=103)}else r.status=103;103===r.status&&(r.gzhead.hcrc?(r.pending+2>r.pending_buf_size&&v(e),r.pending+2<=r.pending_buf_size&&(g(r,255&e.adler),g(r,e.adler>>8&255),e.adler=0,r.status=113)):r.status=113);if(0!==r.pending){if(v(e),0===e.avail_out)return r.last_flush=-1,0}else if(0===e.avail_in&&p(t)<=p(n)&&4!==t)return f(e,-5);if(666===r.status&&0!==e.avail_in)return f(e,-5);if(0!==e.avail_in||0!==r.lookahead||0!==t&&666!==r.status){var u=2===r.strategy?function(e,t){for(var n;;){if(0===e.lookahead&&(w(e),0===e.lookahead)){if(0===t)return 1;break}if(e.match_length=0,n=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(b(e,!1),0===e.strm.avail_out))return 1}if(e.insert=0,4===t)return b(e,!0),0===e.strm.avail_out?3:4;if(e.last_lit&&(b(e,!1),0===e.strm.avail_out))return 1;return 2}(r,t):3===r.strategy?function(e,t){for(var n,r,i,s,a=e.window;;){if(e.lookahead<=258){if(w(e),e.lookahead<=258&&0===t)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&(i=e.strstart-1,(r=a[i])===a[++i]&&r===a[++i]&&r===a[++i])){s=e.strstart+258;do{}while(r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&ie.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(n=o._tr_tally(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=o._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(b(e,!1),0===e.strm.avail_out))return 1}if(e.insert=0,4===t)return b(e,!0),0===e.strm.avail_out?3:4;if(e.last_lit&&(b(e,!1),0===e.strm.avail_out))return 1;return 2}(r,t):d[r.level].func(r,t);if(3!==u&&4!==u||(r.status=666),1===u||3===u)return 0===e.avail_out&&(r.last_flush=-1),0;if(2===u&&(1===t?o._tr_align(r):5!==t&&(o._tr_stored_block(r,0,0,!1),3===t&&(_(r.head),0===r.lookahead&&(r.strstart=0,r.block_start=0,r.insert=0))),v(e),0===e.avail_out))return r.last_flush=-1,0}if(4!==t)return 0;if(r.wrap<=0)return 1;2===r.wrap?(g(r,255&e.adler),g(r,e.adler>>8&255),g(r,e.adler>>16&255),g(r,e.adler>>24&255),g(r,255&e.total_in),g(r,e.total_in>>8&255),g(r,e.total_in>>16&255),g(r,e.total_in>>24&255)):(m(r,e.adler>>>16),m(r,65535&e.adler));v(e),r.wrap>0&&(r.wrap=-r.wrap);return 0!==r.pending?0:1},t.deflateEnd=function(e){var t;if(!e||!e.state)return-2;if(42!==(t=e.state.status)&&69!==t&&73!==t&&91!==t&&103!==t&&113!==t&&666!==t)return f(e,-2);return e.state=null,113===t?f(e,-3):0},t.deflateSetDictionary=function(e,t){var n,r,o,a,c,l,u,h,d=t.length;if(!e||!e.state)return-2;if(n=e.state,2===(a=n.wrap)||1===a&&42!==n.status||n.lookahead)return-2;1===a&&(e.adler=(0,s.default)(e.adler,t,d,0));n.wrap=0,d>=n.w_size&&(0===a&&(_(n.head),n.strstart=0,n.block_start=0,n.insert=0),h=new i.Buf8(n.w_size),i.arraySet(h,t,d-n.w_size,n.w_size,0),t=h,d=n.w_size);c=e.avail_in,l=e.next_in,u=e.input,e.avail_in=d,e.next_in=0,e.input=t,w(n);for(;n.lookahead>=3;){r=n.strstart,o=n.lookahead-2;do{n.ins_h=(n.ins_h<4?9:0)}function _(e){for(var t=e.length;--t>=0;)e[t]=0}function v(e){var t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(i.arraySet(e.output,t.pending_buf,t.pending_out,n,e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,0===t.pending&&(t.pending_out=0))}function b(e,t){o._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,v(e.strm)}function g(e,t){e.pending_buf[e.pending++]=t}function m(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function y(e,t){var n,r,i=e.max_chain_length,o=e.strstart,s=e.prev_length,a=e.nice_match,c=e.strstart>e.w_size-262?e.strstart-(e.w_size-262):0,l=e.window,u=e.w_mask,h=e.prev,d=e.strstart+258,f=l[o+s-1],p=l[o+s];e.prev_length>=e.good_match&&(i>>=2),a>e.lookahead&&(a=e.lookahead);do{if(l[(n=t)+s]===p&&l[n+s-1]===f&&l[n]===l[o]&&l[++n]===l[o+1]){o+=2,n++;do{}while(l[++o]===l[++n]&&l[++o]===l[++n]&&l[++o]===l[++n]&&l[++o]===l[++n]&&l[++o]===l[++n]&&l[++o]===l[++n]&&l[++o]===l[++n]&&l[++o]===l[++n]&&os){if(e.match_start=t,s=r,r>=a)break;f=l[o+s-1],p=l[o+s]}}}while((t=h[t&u])>c&&0!=--i);return s<=e.lookahead?s:e.lookahead}function w(e){var t,n,r,o,c,l,u,h,d,f,p=e.w_size;do{if(o=e.window_size-e.lookahead-e.strstart,e.strstart>=p+(p-262)){i.arraySet(e.window,e.window,p,p,0),e.match_start-=p,e.strstart-=p,e.block_start-=p,t=n=e.hash_size;do{r=e.head[--t],e.head[t]=r>=p?r-p:0}while(--n);t=n=p;do{r=e.prev[--t],e.prev[t]=r>=p?r-p:0}while(--n);o+=p}if(0===e.strm.avail_in)break;if(l=e.strm,u=e.window,h=e.strstart+e.lookahead,d=o,f=void 0,(f=l.avail_in)>d&&(f=d),n=0===f?0:(l.avail_in-=f,i.arraySet(u,l.input,l.next_in,f,h),1===l.state.wrap?l.adler=(0,s.default)(l.adler,u,f,h):2===l.state.wrap&&(l.adler=(0,a.default)(l.adler,u,f,h)),l.next_in+=f,l.total_in+=f,f),e.lookahead+=n,e.lookahead+e.insert>=3)for(c=e.strstart-e.insert,e.ins_h=e.window[c],e.ins_h=(e.ins_h<=3&&(e.ins_h=(e.ins_h<=3)if(r=o._tr_tally(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do{e.strstart++,e.ins_h=(e.ins_h<=3&&(e.ins_h=(e.ins_h<4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-3,r=o._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=i&&(e.ins_h=(e.ins_h<15&&(a=2,r-=16),o<1||o>9||8!==n||r<8||r>15||t<0||t>9||s<0||s>4)return f(e,-2);8===r&&(r=9);var c=new E;return e.state=c,c.strm=e,c.wrap=a,c.gzhead=null,c.w_bits=r,c.w_size=1<e.pending_buf_size-5&&(n=e.pending_buf_size-5);;){if(e.lookahead<=1){if(w(e),0===e.lookahead&&0===t)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var r=e.block_start+n;if((0===e.strstart||e.strstart>=r)&&(e.lookahead=e.strstart-r,e.strstart=r,b(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-262&&(b(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(b(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(b(e,!1),e.strm.avail_out),1)})),new k(4,4,8,4,S),new k(4,5,16,8,S),new k(4,6,32,32,S),new k(4,4,16,16,C),new k(8,16,32,32,C),new k(8,16,128,128,C),new k(8,32,128,256,C),new k(32,128,258,1024,C),new k(32,258,258,4096,C)];t.deflateInfo="pako deflate (from Nodeca project)"},lOMy: /*!****************************************************!*\ !*** ./src/components/tpi-code-setting/index.less ***! \****************************************************/ /*! no static exports found */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){},mHUz: /*!*******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/input/keysym.js ***! \*******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={XK_VoidSymbol:16777215,XK_BackSpace:65288,XK_Tab:65289,XK_Linefeed:65290,XK_Clear:65291,XK_Return:65293,XK_Pause:65299,XK_Scroll_Lock:65300,XK_Sys_Req:65301,XK_Escape:65307,XK_Delete:65535,XK_Multi_key:65312,XK_Codeinput:65335,XK_SingleCandidate:65340,XK_MultipleCandidate:65341,XK_PreviousCandidate:65342,XK_Kanji:65313,XK_Muhenkan:65314,XK_Henkan_Mode:65315,XK_Henkan:65315,XK_Romaji:65316,XK_Hiragana:65317,XK_Katakana:65318,XK_Hiragana_Katakana:65319,XK_Zenkaku:65320,XK_Hankaku:65321,XK_Zenkaku_Hankaku:65322,XK_Touroku:65323,XK_Massyo:65324,XK_Kana_Lock:65325,XK_Kana_Shift:65326,XK_Eisu_Shift:65327,XK_Eisu_toggle:65328,XK_Kanji_Bangou:65335,XK_Zen_Koho:65341,XK_Mae_Koho:65342,XK_Home:65360,XK_Left:65361,XK_Up:65362,XK_Right:65363,XK_Down:65364,XK_Prior:65365,XK_Page_Up:65365,XK_Next:65366,XK_Page_Down:65366,XK_End:65367,XK_Begin:65368,XK_Select:65376,XK_Print:65377,XK_Execute:65378,XK_Insert:65379,XK_Undo:65381,XK_Redo:65382,XK_Menu:65383,XK_Find:65384,XK_Cancel:65385,XK_Help:65386,XK_Break:65387,XK_Mode_switch:65406,XK_script_switch:65406,XK_Num_Lock:65407,XK_KP_Space:65408,XK_KP_Tab:65417,XK_KP_Enter:65421,XK_KP_F1:65425,XK_KP_F2:65426,XK_KP_F3:65427,XK_KP_F4:65428,XK_KP_Home:65429,XK_KP_Left:65430,XK_KP_Up:65431,XK_KP_Right:65432,XK_KP_Down:65433,XK_KP_Prior:65434,XK_KP_Page_Up:65434,XK_KP_Next:65435,XK_KP_Page_Down:65435,XK_KP_End:65436,XK_KP_Begin:65437,XK_KP_Insert:65438,XK_KP_Delete:65439,XK_KP_Equal:65469,XK_KP_Multiply:65450,XK_KP_Add:65451,XK_KP_Separator:65452,XK_KP_Subtract:65453,XK_KP_Decimal:65454,XK_KP_Divide:65455,XK_KP_0:65456,XK_KP_1:65457,XK_KP_2:65458,XK_KP_3:65459,XK_KP_4:65460,XK_KP_5:65461,XK_KP_6:65462,XK_KP_7:65463,XK_KP_8:65464,XK_KP_9:65465,XK_F1:65470,XK_F2:65471,XK_F3:65472,XK_F4:65473,XK_F5:65474,XK_F6:65475,XK_F7:65476,XK_F8:65477,XK_F9:65478,XK_F10:65479,XK_F11:65480,XK_L1:65480,XK_F12:65481,XK_L2:65481,XK_F13:65482,XK_L3:65482,XK_F14:65483,XK_L4:65483,XK_F15:65484,XK_L5:65484,XK_F16:65485,XK_L6:65485,XK_F17:65486,XK_L7:65486,XK_F18:65487,XK_L8:65487,XK_F19:65488,XK_L9:65488,XK_F20:65489,XK_L10:65489,XK_F21:65490,XK_R1:65490,XK_F22:65491,XK_R2:65491,XK_F23:65492,XK_R3:65492,XK_F24:65493,XK_R4:65493,XK_F25:65494,XK_R5:65494,XK_F26:65495,XK_R6:65495,XK_F27:65496,XK_R7:65496,XK_F28:65497,XK_R8:65497,XK_F29:65498,XK_R9:65498,XK_F30:65499,XK_R10:65499,XK_F31:65500,XK_R11:65500,XK_F32:65501,XK_R12:65501,XK_F33:65502,XK_R13:65502,XK_F34:65503,XK_R14:65503,XK_F35:65504,XK_R15:65504,XK_Shift_L:65505,XK_Shift_R:65506,XK_Control_L:65507,XK_Control_R:65508,XK_Caps_Lock:65509,XK_Shift_Lock:65510,XK_Meta_L:65511,XK_Meta_R:65512,XK_Alt_L:65513,XK_Alt_R:65514,XK_Super_L:65515,XK_Super_R:65516,XK_Hyper_L:65517,XK_Hyper_R:65518,XK_ISO_Level3_Shift:65027,XK_ISO_Next_Group:65032,XK_ISO_Prev_Group:65034,XK_ISO_First_Group:65036,XK_ISO_Last_Group:65038,XK_space:32,XK_exclam:33,XK_quotedbl:34,XK_numbersign:35,XK_dollar:36,XK_percent:37,XK_ampersand:38,XK_apostrophe:39,XK_quoteright:39,XK_parenleft:40,XK_parenright:41,XK_asterisk:42,XK_plus:43,XK_comma:44,XK_minus:45,XK_period:46,XK_slash:47,XK_0:48,XK_1:49,XK_2:50,XK_3:51,XK_4:52,XK_5:53,XK_6:54,XK_7:55,XK_8:56,XK_9:57,XK_colon:58,XK_semicolon:59,XK_less:60,XK_equal:61,XK_greater:62,XK_question:63,XK_at:64,XK_A:65,XK_B:66,XK_C:67,XK_D:68,XK_E:69,XK_F:70,XK_G:71,XK_H:72,XK_I:73,XK_J:74,XK_K:75,XK_L:76,XK_M:77,XK_N:78,XK_O:79,XK_P:80,XK_Q:81,XK_R:82,XK_S:83,XK_T:84,XK_U:85,XK_V:86,XK_W:87,XK_X:88,XK_Y:89,XK_Z:90,XK_bracketleft:91,XK_backslash:92,XK_bracketright:93,XK_asciicircum:94,XK_underscore:95,XK_grave:96,XK_quoteleft:96,XK_a:97,XK_b:98,XK_c:99,XK_d:100,XK_e:101,XK_f:102,XK_g:103,XK_h:104,XK_i:105,XK_j:106,XK_k:107,XK_l:108,XK_m:109,XK_n:110,XK_o:111,XK_p:112,XK_q:113,XK_r:114,XK_s:115,XK_t:116,XK_u:117,XK_v:118,XK_w:119,XK_x:120,XK_y:121,XK_z:122,XK_braceleft:123,XK_bar:124,XK_braceright:125,XK_asciitilde:126,XK_nobreakspace:160,XK_exclamdown:161,XK_cent:162,XK_sterling:163,XK_currency:164,XK_yen:165,XK_brokenbar:166,XK_section:167,XK_diaeresis:168,XK_copyright:169,XK_ordfeminine:170,XK_guillemotleft:171,XK_notsign:172,XK_hyphen:173,XK_registered:174,XK_macron:175,XK_degree:176,XK_plusminus:177,XK_twosuperior:178,XK_threesuperior:179,XK_acute:180,XK_mu:181,XK_paragraph:182,XK_periodcentered:183,XK_cedilla:184,XK_onesuperior:185,XK_masculine:186,XK_guillemotright:187,XK_onequarter:188,XK_onehalf:189,XK_threequarters:190,XK_questiondown:191,XK_Agrave:192,XK_Aacute:193,XK_Acircumflex:194,XK_Atilde:195,XK_Adiaeresis:196,XK_Aring:197,XK_AE:198,XK_Ccedilla:199,XK_Egrave:200,XK_Eacute:201,XK_Ecircumflex:202,XK_Ediaeresis:203,XK_Igrave:204,XK_Iacute:205,XK_Icircumflex:206,XK_Idiaeresis:207,XK_ETH:208,XK_Eth:208,XK_Ntilde:209,XK_Ograve:210,XK_Oacute:211,XK_Ocircumflex:212,XK_Otilde:213,XK_Odiaeresis:214,XK_multiply:215,XK_Oslash:216,XK_Ooblique:216,XK_Ugrave:217,XK_Uacute:218,XK_Ucircumflex:219,XK_Udiaeresis:220,XK_Yacute:221,XK_THORN:222,XK_Thorn:222,XK_ssharp:223,XK_agrave:224,XK_aacute:225,XK_acircumflex:226,XK_atilde:227,XK_adiaeresis:228,XK_aring:229,XK_ae:230,XK_ccedilla:231,XK_egrave:232,XK_eacute:233,XK_ecircumflex:234,XK_ediaeresis:235,XK_igrave:236,XK_iacute:237,XK_icircumflex:238,XK_idiaeresis:239,XK_eth:240,XK_ntilde:241,XK_ograve:242,XK_oacute:243,XK_ocircumflex:244,XK_otilde:245,XK_odiaeresis:246,XK_division:247,XK_oslash:248,XK_ooblique:248,XK_ugrave:249,XK_uacute:250,XK_ucircumflex:251,XK_udiaeresis:252,XK_yacute:253,XK_thorn:254,XK_ydiaeresis:255,XK_Hangul:65329,XK_Hangul_Hanja:65332,XK_Hangul_Jeonja:65336,XF86XK_ModeLock:269025025,XF86XK_MonBrightnessUp:269025026,XF86XK_MonBrightnessDown:269025027,XF86XK_KbdLightOnOff:269025028,XF86XK_KbdBrightnessUp:269025029,XF86XK_KbdBrightnessDown:269025030,XF86XK_Standby:269025040,XF86XK_AudioLowerVolume:269025041,XF86XK_AudioMute:269025042,XF86XK_AudioRaiseVolume:269025043,XF86XK_AudioPlay:269025044,XF86XK_AudioStop:269025045,XF86XK_AudioPrev:269025046,XF86XK_AudioNext:269025047,XF86XK_HomePage:269025048,XF86XK_Mail:269025049,XF86XK_Start:269025050,XF86XK_Search:269025051,XF86XK_AudioRecord:269025052,XF86XK_Calculator:269025053,XF86XK_Memo:269025054,XF86XK_ToDoList:269025055,XF86XK_Calendar:269025056,XF86XK_PowerDown:269025057,XF86XK_ContrastAdjust:269025058,XF86XK_RockerUp:269025059,XF86XK_RockerDown:269025060,XF86XK_RockerEnter:269025061,XF86XK_Back:269025062,XF86XK_Forward:269025063,XF86XK_Stop:269025064,XF86XK_Refresh:269025065,XF86XK_PowerOff:269025066,XF86XK_WakeUp:269025067,XF86XK_Eject:269025068,XF86XK_ScreenSaver:269025069,XF86XK_WWW:269025070,XF86XK_Sleep:269025071,XF86XK_Favorites:269025072,XF86XK_AudioPause:269025073,XF86XK_AudioMedia:269025074,XF86XK_MyComputer:269025075,XF86XK_VendorHome:269025076,XF86XK_LightBulb:269025077,XF86XK_Shop:269025078,XF86XK_History:269025079,XF86XK_OpenURL:269025080,XF86XK_AddFavorite:269025081,XF86XK_HotLinks:269025082,XF86XK_BrightnessAdjust:269025083,XF86XK_Finance:269025084,XF86XK_Community:269025085,XF86XK_AudioRewind:269025086,XF86XK_BackForward:269025087,XF86XK_Launch0:269025088,XF86XK_Launch1:269025089,XF86XK_Launch2:269025090,XF86XK_Launch3:269025091,XF86XK_Launch4:269025092,XF86XK_Launch5:269025093,XF86XK_Launch6:269025094,XF86XK_Launch7:269025095,XF86XK_Launch8:269025096,XF86XK_Launch9:269025097,XF86XK_LaunchA:269025098,XF86XK_LaunchB:269025099,XF86XK_LaunchC:269025100,XF86XK_LaunchD:269025101,XF86XK_LaunchE:269025102,XF86XK_LaunchF:269025103,XF86XK_ApplicationLeft:269025104,XF86XK_ApplicationRight:269025105,XF86XK_Book:269025106,XF86XK_CD:269025107,XF86XK_Calculater:269025108,XF86XK_Clear:269025109,XF86XK_Close:269025110,XF86XK_Copy:269025111,XF86XK_Cut:269025112,XF86XK_Display:269025113,XF86XK_DOS:269025114,XF86XK_Documents:269025115,XF86XK_Excel:269025116,XF86XK_Explorer:269025117,XF86XK_Game:269025118,XF86XK_Go:269025119,XF86XK_iTouch:269025120,XF86XK_LogOff:269025121,XF86XK_Market:269025122,XF86XK_Meeting:269025123,XF86XK_MenuKB:269025125,XF86XK_MenuPB:269025126,XF86XK_MySites:269025127,XF86XK_New:269025128,XF86XK_News:269025129,XF86XK_OfficeHome:269025130,XF86XK_Open:269025131,XF86XK_Option:269025132,XF86XK_Paste:269025133,XF86XK_Phone:269025134,XF86XK_Q:269025136,XF86XK_Reply:269025138,XF86XK_Reload:269025139,XF86XK_RotateWindows:269025140,XF86XK_RotationPB:269025141,XF86XK_RotationKB:269025142,XF86XK_Save:269025143,XF86XK_ScrollUp:269025144,XF86XK_ScrollDown:269025145,XF86XK_ScrollClick:269025146,XF86XK_Send:269025147,XF86XK_Spell:269025148,XF86XK_SplitScreen:269025149,XF86XK_Support:269025150,XF86XK_TaskPane:269025151,XF86XK_Terminal:269025152,XF86XK_Tools:269025153,XF86XK_Travel:269025154,XF86XK_UserPB:269025156,XF86XK_User1KB:269025157,XF86XK_User2KB:269025158,XF86XK_Video:269025159,XF86XK_WheelButton:269025160,XF86XK_Word:269025161,XF86XK_Xfer:269025162,XF86XK_ZoomIn:269025163,XF86XK_ZoomOut:269025164,XF86XK_Away:269025165,XF86XK_Messenger:269025166,XF86XK_WebCam:269025167,XF86XK_MailForward:269025168,XF86XK_Pictures:269025169,XF86XK_Music:269025170,XF86XK_Battery:269025171,XF86XK_Bluetooth:269025172,XF86XK_WLAN:269025173,XF86XK_UWB:269025174,XF86XK_AudioForward:269025175,XF86XK_AudioRepeat:269025176,XF86XK_AudioRandomPlay:269025177,XF86XK_Subtitle:269025178,XF86XK_AudioCycleTrack:269025179,XF86XK_CycleAngle:269025180,XF86XK_FrameBack:269025181,XF86XK_FrameForward:269025182,XF86XK_Time:269025183,XF86XK_Select:269025184,XF86XK_View:269025185,XF86XK_TopMenu:269025186,XF86XK_Red:269025187,XF86XK_Green:269025188,XF86XK_Yellow:269025189,XF86XK_Blue:269025190,XF86XK_Suspend:269025191,XF86XK_Hibernate:269025192,XF86XK_TouchpadToggle:269025193,XF86XK_TouchpadOn:269025200,XF86XK_TouchpadOff:269025201,XF86XK_AudioMicMute:269025202,XF86XK_Switch_VT_1:269024769,XF86XK_Switch_VT_2:269024770,XF86XK_Switch_VT_3:269024771,XF86XK_Switch_VT_4:269024772,XF86XK_Switch_VT_5:269024773,XF86XK_Switch_VT_6:269024774,XF86XK_Switch_VT_7:269024775,XF86XK_Switch_VT_8:269024776,XF86XK_Switch_VT_9:269024777,XF86XK_Switch_VT_10:269024778,XF86XK_Switch_VT_11:269024779,XF86XK_Switch_VT_12:269024780,XF86XK_Ungrab:269024800,XF86XK_ClearGrab:269024801,XF86XK_Next_VMode:269024802,XF86XK_Prev_VMode:269024803,XF86XK_LogWindowTree:269024804,XF86XK_LogGrabInfo:269024805}},mTgk: /*!************************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/input/domkeytable.js ***! \************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,i=(r=n(/*! ./keysym.js */"mHUz"))&&r.__esModule?r:{default:r};var o={};function s(e,t){if(void 0===t)throw new Error('Undefined keysym for key "'+e+'"');if(e in o)throw new Error('Duplicate entry for key "'+e+'"');o[e]=[t,t,t,t]}function a(e,t,n){if(void 0===t)throw new Error('Undefined keysym for key "'+e+'"');if(void 0===n)throw new Error('Undefined keysym for key "'+e+'"');if(e in o)throw new Error('Duplicate entry for key "'+e+'"');o[e]=[t,t,n,t]}function c(e,t,n){if(void 0===t)throw new Error('Undefined keysym for key "'+e+'"');if(void 0===n)throw new Error('Undefined keysym for key "'+e+'"');if(e in o)throw new Error('Duplicate entry for key "'+e+'"');o[e]=[t,t,t,n]}a("Alt",i.default.XK_Alt_L,i.default.XK_Alt_R),s("AltGraph",i.default.XK_ISO_Level3_Shift),s("CapsLock",i.default.XK_Caps_Lock),a("Control",i.default.XK_Control_L,i.default.XK_Control_R),a("Meta",i.default.XK_Super_L,i.default.XK_Super_R),s("NumLock",i.default.XK_Num_Lock),s("ScrollLock",i.default.XK_Scroll_Lock),a("Shift",i.default.XK_Shift_L,i.default.XK_Shift_R),c("Enter",i.default.XK_Return,i.default.XK_KP_Enter),s("Tab",i.default.XK_Tab),c(" ",i.default.XK_space,i.default.XK_KP_Space),c("ArrowDown",i.default.XK_Down,i.default.XK_KP_Down),c("ArrowUp",i.default.XK_Up,i.default.XK_KP_Up),c("ArrowLeft",i.default.XK_Left,i.default.XK_KP_Left),c("ArrowRight",i.default.XK_Right,i.default.XK_KP_Right),c("End",i.default.XK_End,i.default.XK_KP_End),c("Home",i.default.XK_Home,i.default.XK_KP_Home),c("PageDown",i.default.XK_Next,i.default.XK_KP_Next),c("PageUp",i.default.XK_Prior,i.default.XK_KP_Prior),s("Backspace",i.default.XK_BackSpace),c("Clear",i.default.XK_Clear,i.default.XK_KP_Begin),s("Copy",i.default.XF86XK_Copy),s("Cut",i.default.XF86XK_Cut),c("Delete",i.default.XK_Delete,i.default.XK_KP_Delete),c("Insert",i.default.XK_Insert,i.default.XK_KP_Insert),s("Paste",i.default.XF86XK_Paste),s("Redo",i.default.XK_Redo),s("Undo",i.default.XK_Undo),s("Cancel",i.default.XK_Cancel),s("ContextMenu",i.default.XK_Menu),s("Escape",i.default.XK_Escape),s("Execute",i.default.XK_Execute),s("Find",i.default.XK_Find),s("Help",i.default.XK_Help),s("Pause",i.default.XK_Pause),s("Select",i.default.XK_Select),s("ZoomIn",i.default.XF86XK_ZoomIn),s("ZoomOut",i.default.XF86XK_ZoomOut),s("BrightnessDown",i.default.XF86XK_MonBrightnessDown),s("BrightnessUp",i.default.XF86XK_MonBrightnessUp),s("Eject",i.default.XF86XK_Eject),s("LogOff",i.default.XF86XK_LogOff),s("Power",i.default.XF86XK_PowerOff),s("PowerOff",i.default.XF86XK_PowerDown),s("PrintScreen",i.default.XK_Print),s("Hibernate",i.default.XF86XK_Hibernate),s("Standby",i.default.XF86XK_Standby),s("WakeUp",i.default.XF86XK_WakeUp),s("AllCandidates",i.default.XK_MultipleCandidate),s("Alphanumeric",i.default.XK_Eisu_Shift),s("CodeInput",i.default.XK_Codeinput),s("Compose",i.default.XK_Multi_key),s("Convert",i.default.XK_Henkan),s("GroupFirst",i.default.XK_ISO_First_Group),s("GroupLast",i.default.XK_ISO_Last_Group),s("GroupNext",i.default.XK_ISO_Next_Group),s("GroupPrevious",i.default.XK_ISO_Prev_Group),s("NonConvert",i.default.XK_Muhenkan),s("PreviousCandidate",i.default.XK_PreviousCandidate),s("SingleCandidate",i.default.XK_SingleCandidate),s("HangulMode",i.default.XK_Hangul),s("HanjaMode",i.default.XK_Hangul_Hanja),s("JunjuaMode",i.default.XK_Hangul_Jeonja),s("Eisu",i.default.XK_Eisu_toggle),s("Hankaku",i.default.XK_Hankaku),s("Hiragana",i.default.XK_Hiragana),s("HiraganaKatakana",i.default.XK_Hiragana_Katakana),s("KanaMode",i.default.XK_Kana_Shift),s("KanjiMode",i.default.XK_Kanji),s("Katakana",i.default.XK_Katakana),s("Romaji",i.default.XK_Romaji),s("Zenkaku",i.default.XK_Zenkaku),s("ZenkakuHanaku",i.default.XK_Zenkaku_Hankaku),s("F1",i.default.XK_F1),s("F2",i.default.XK_F2),s("F3",i.default.XK_F3),s("F4",i.default.XK_F4),s("F5",i.default.XK_F5),s("F6",i.default.XK_F6),s("F7",i.default.XK_F7),s("F8",i.default.XK_F8),s("F9",i.default.XK_F9),s("F10",i.default.XK_F10),s("F11",i.default.XK_F11),s("F12",i.default.XK_F12),s("F13",i.default.XK_F13),s("F14",i.default.XK_F14),s("F15",i.default.XK_F15),s("F16",i.default.XK_F16),s("F17",i.default.XK_F17),s("F18",i.default.XK_F18),s("F19",i.default.XK_F19),s("F20",i.default.XK_F20),s("F21",i.default.XK_F21),s("F22",i.default.XK_F22),s("F23",i.default.XK_F23),s("F24",i.default.XK_F24),s("F25",i.default.XK_F25),s("F26",i.default.XK_F26),s("F27",i.default.XK_F27),s("F28",i.default.XK_F28),s("F29",i.default.XK_F29),s("F30",i.default.XK_F30),s("F31",i.default.XK_F31),s("F32",i.default.XK_F32),s("F33",i.default.XK_F33),s("F34",i.default.XK_F34),s("F35",i.default.XK_F35),s("Close",i.default.XF86XK_Close),s("MailForward",i.default.XF86XK_MailForward),s("MailReply",i.default.XF86XK_Reply),s("MailSend",i.default.XF86XK_Send),s("MediaFastForward",i.default.XF86XK_AudioForward),s("MediaPause",i.default.XF86XK_AudioPause),s("MediaPlay",i.default.XF86XK_AudioPlay),s("MediaRecord",i.default.XF86XK_AudioRecord),s("MediaRewind",i.default.XF86XK_AudioRewind),s("MediaStop",i.default.XF86XK_AudioStop),s("MediaTrackNext",i.default.XF86XK_AudioNext),s("MediaTrackPrevious",i.default.XF86XK_AudioPrev),s("New",i.default.XF86XK_New),s("Open",i.default.XF86XK_Open),s("Print",i.default.XK_Print),s("Save",i.default.XF86XK_Save),s("SpellCheck",i.default.XF86XK_Spell),s("AudioVolumeDown",i.default.XF86XK_AudioLowerVolume),s("AudioVolumeUp",i.default.XF86XK_AudioRaiseVolume),s("AudioVolumeMute",i.default.XF86XK_AudioMute),s("MicrophoneVolumeMute",i.default.XF86XK_AudioMicMute),s("LaunchApplication1",i.default.XF86XK_MyComputer),s("LaunchApplication2",i.default.XF86XK_Calculator),s("LaunchCalendar",i.default.XF86XK_Calendar),s("LaunchMail",i.default.XF86XK_Mail),s("LaunchMediaPlayer",i.default.XF86XK_AudioMedia),s("LaunchMusicPlayer",i.default.XF86XK_Music),s("LaunchPhone",i.default.XF86XK_Phone),s("LaunchScreenSaver",i.default.XF86XK_ScreenSaver),s("LaunchSpreadsheet",i.default.XF86XK_Excel),s("LaunchWebBrowser",i.default.XF86XK_WWW),s("LaunchWebCam",i.default.XF86XK_WebCam),s("LaunchWordProcessor",i.default.XF86XK_Word),s("BrowserBack",i.default.XF86XK_Back),s("BrowserFavorites",i.default.XF86XK_Favorites),s("BrowserForward",i.default.XF86XK_Forward),s("BrowserHome",i.default.XF86XK_HomePage),s("BrowserRefresh",i.default.XF86XK_Refresh),s("BrowserSearch",i.default.XF86XK_Search),s("BrowserStop",i.default.XF86XK_Stop),s("Dimmer",i.default.XF86XK_BrightnessAdjust),s("MediaAudioTrack",i.default.XF86XK_AudioCycleTrack),s("RandomToggle",i.default.XF86XK_AudioRandomPlay),s("SplitScreenToggle",i.default.XF86XK_SplitScreen),s("Subtitle",i.default.XF86XK_Subtitle),s("VideoModeNext",i.default.XF86XK_Next_VMode),c("=",i.default.XK_equal,i.default.XK_KP_Equal),c("+",i.default.XK_plus,i.default.XK_KP_Add),c("-",i.default.XK_minus,i.default.XK_KP_Subtract),c("*",i.default.XK_asterisk,i.default.XK_KP_Multiply),c("/",i.default.XK_slash,i.default.XK_KP_Divide),c(".",i.default.XK_period,i.default.XK_KP_Decimal),c(",",i.default.XK_comma,i.default.XK_KP_Separator),c("0",i.default.XK_0,i.default.XK_KP_0),c("1",i.default.XK_1,i.default.XK_KP_1),c("2",i.default.XK_2,i.default.XK_KP_2),c("3",i.default.XK_3,i.default.XK_KP_3),c("4",i.default.XK_4,i.default.XK_KP_4),c("5",i.default.XK_5,i.default.XK_KP_5),c("6",i.default.XK_6,i.default.XK_KP_6),c("7",i.default.XK_7,i.default.XK_KP_7),c("8",i.default.XK_8,i.default.XK_KP_8),c("9",i.default.XK_9,i.default.XK_KP_9);var l=o;t.default=l},mdZa: /*!********************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/polyfill.js ***! \********************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";"function"!=typeof Object.assign&&Object.defineProperty(Object,"assign",{value:function(e,t){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var n=Object(e),r=1;r=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){c=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(c)throw s}}}}},rHrb: /*!***************************************************************!*\ !*** ./node_modules/react-copy-to-clipboard/lib/Component.js ***! \***************************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CopyToClipboard=void 0;var r=o(n(/*! react */"q1tI")),i=o(n(/*! copy-to-clipboard */"+QRC"));function o(e){return e&&e.__esModule?e:{default:e}}function s(e){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){for(var n=0;n>>=y=m>>>24,p-=y,0===(y=m>>>16&255))O[o++]=65535&m;else{if(!(16&y)){if(0==(64&y)){m=_[(65535&m)+(f&(1<>>=y,p-=y),p<15&&(f+=E[r++]<>>=y=m>>>24,p-=y,!(16&(y=m>>>16&255))){if(0==(64&y)){m=v[(65535&m)+(f&(1<c){e.msg="invalid distance too far back",n.mode=30;break e}if(f>>>=y,p-=y,S>(y=o-s)){if((y=S-y)>u&&n.sane){e.msg="invalid distance too far back",n.mode=30;break e}if(C=0,k=d,0===h){if(C+=l-y,y2;)O[o++]=k[C++],O[o++]=k[C++],O[o++]=k[C++],w-=3;w&&(O[o++]=k[C++],w>1&&(O[o++]=k[C++]))}else{C=o-S;do{O[o++]=O[C++],O[o++]=O[C++],O[o++]=O[C++],w-=3}while(w>2);w&&(O[o++]=O[C++],w>1&&(O[o++]=O[C++]))}break}}break}}while(r>3,f&=(1<<(p-=w<<3))-1,e.next_in=r,e.next_out=o,e.avail_in=r1)Object(h.a)(!1,"Find more than one child node with `children` in ResizeObserver. Will only observe first one.");else if(0===t.length)return Object(h.a)(!1,"`children` of ResizeObserver is empty. Nothing is in observe."),null;var n=t[0];if(c.isValidElement(n)&&Object(d.c)(n)){var r=n.ref;t[0]=c.cloneElement(n,{ref:Object(d.a)(r,this.setChildNode)})}return 1===t.length?t[0]:t.map((function(e,t){return!c.isValidElement(e)||"key"in e&&null!==e.key?e:c.cloneElement(e,{key:"".concat("rc-observer-key","-").concat(t)})}))}}]),n}(c.Component);p.displayName="ResizeObserver",t.a=p},vS10: /*!*****************************!*\ !*** ./src/service/task.ts ***! \*****************************/ /*! exports provided: saveWithTPI, getJupyterData, getInfoWithTPI, getTimeInfoWithTPI, resetWithTPI, activeWithTPI, syncCode, getDataSets, rebootEsc, getLatexFileTree */ /*! exports used: activeWithTPI, getDataSets, getInfoWithTPI, getJupyterData, getTimeInfoWithTPI, rebootEsc, resetWithTPI, saveWithTPI, syncCode */function(e,t,n){"use strict";n.d(t,"h",(function(){return a})),n.d(t,"d",(function(){return l})),n.d(t,"c",(function(){return h})),n.d(t,"e",(function(){return f})),n.d(t,"g",(function(){return _})),n.d(t,"a",(function(){return b})),n.d(t,"i",(function(){return m})),n.d(t,"b",(function(){return w})),n.d(t,"f",(function(){return C}));var r=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator */"9og8"),i=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator */"WmNS"),o=n.n(i),s=n(/*! @/utils/fetch */"ErOA");function a(e){return c.apply(this,arguments)}function c(){return(c=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/jupyters/save_with_tpi.json",{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function l(e){return u.apply(this,arguments)}function u(){return(u=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/tasks/".concat(t.identifier,"/jupyter.json"),{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function h(e){return d.apply(this,arguments)}function d(){return(d=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/jupyters/get_info_with_tpi.json",{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function f(e){return p.apply(this,arguments)}function p(){return(p=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/jupyters/timeinfo_with_tpi.json",{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function _(e){return v.apply(this,arguments)}function v(){return(v=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/jupyters/reset_with_tpi.json",{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function b(e){return g.apply(this,arguments)}function g(){return(g=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/jupyters/active_with_tpi.json",{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function m(e){return y.apply(this,arguments)}function y(){return(y=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/myshixuns/".concat(t.identifier,"/sync_code.json"),{method:"Post",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function w(e){return S.apply(this,arguments)}function S(){return(S=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/shixuns/".concat(t.identifier,"/get_data_sets.json"),{method:"Get",params:t}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function C(e){return k.apply(this,arguments)}function k(){return(k=Object(r.a)(o.a.mark((function e(t){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Object(s.a)("/api/tasks/".concat(t.identifier,"/reboot_esc.json"),{method:"post"}));case 1:case"end":return e.stop()}}),e)})))).apply(this,arguments)}},vewr: /*!******************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/util/events.js ***! \******************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPointerEvent=function(e){return e.changedTouches?e.changedTouches[0]:e.touches?e.touches[0]:e},t.stopEvent=function(e){e.stopPropagation(),e.preventDefault()},t.setCapture=function(e){if(e.setCapture)e.setCapture(),document.captureElement=e,e.addEventListener("mouseup",c);else{c();var t=document.getElementById("noVNC_mouse_capture_elem");null===t&&((t=document.createElement("div")).id="noVNC_mouse_capture_elem",t.style.position="fixed",t.style.top="0px",t.style.left="0px",t.style.width="100%",t.style.height="100%",t.style.zIndex=1e4,t.style.display="none",document.body.appendChild(t),t.addEventListener("contextmenu",o),t.addEventListener("mousemove",o),t.addEventListener("mouseup",o)),document.captureElement=e,a.observe(e,{attributes:!0}),s(),t.style.display="",window.addEventListener("mousemove",o),window.addEventListener("mouseup",o)}},t.releaseCapture=c;var r=!1,i=null;function o(e){if(!r){var t=new e.constructor(e.type,e);r=!0,document.captureElement?document.captureElement.dispatchEvent(t):i.dispatchEvent(t),r=!1,e.stopPropagation(),t.defaultPrevented&&e.preventDefault(),"mouseup"===e.type&&c()}}function s(){document.getElementById("noVNC_mouse_capture_elem").style.cursor=window.getComputedStyle(document.captureElement).cursor}document.captureElement=null;var a=new MutationObserver(s);function c(){if(document.releaseCapture)document.releaseCapture(),document.captureElement=null;else{if(!document.captureElement)return;i=document.captureElement,document.captureElement=null,a.disconnect(),document.getElementById("noVNC_mouse_capture_elem").style.display="none",window.removeEventListener("mousemove",o),window.removeEventListener("mouseup",o)}}},wCXF: /*!********************************************************!*\ !*** ./node_modules/rc-table/es/Table.js + 17 modules ***! \********************************************************/ /*! exports provided: INTERNAL_HOOKS, default */ /*! exports used: INTERNAL_HOOKS, default */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/defineProperty.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectSpread2.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/slicedToArray.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/@babel/runtime/helpers/esm/typeof.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/classnames/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/raf/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-resize-observer/es/index.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/Cell/index.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/Footer/index.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/context/TableContext.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/hooks/useColumns.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/sugar/Column.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/sugar/ColumnGroup.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/utils/legacyUtil.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-table/es/utils/valueUtil.js because of ./node_modules/antd/es/table/Table.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Dom/addEventListener.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/Dom/css.js because of ./node_modules/rc-image/es/Image.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/getScrollBarSize.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/ref.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/rc-util/es/warning.js */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/react/index.js (<- Module is not an ECMAScript module) */ /*! ModuleConcatenation bailout: Cannot concat with ./node_modules/shallowequal/index.js (<- Module is not an ECMAScript module) */function(e,t,n){"use strict";n.d(t,"a",(function(){return J}));var r=n("rePB"),i=n("VTBJ"),o=n("KQm4"),s=n("U8pU"),a=n("ODXe"),c=n("q1tI"),l=n("TSYQ"),u=n.n(l),h=n("Gytx"),d=n.n(h),f=n("Kwbf"),p=n("t23M"),_=n("qx4F"),v=n("6eGT"),b=n("IBYe"),g=n("Ff2n"),m=n("c+Xe"),y=n("fyJ8"),w=n("biw7");function S(e,t,n,r,i){var o,s,a=n[e]||{},c=n[t]||{};"left"===a.fixed?o=r.left[e]:"right"===c.fixed&&(s=r.right[t]);var l=!1,u=!1,h=!1,d=!1,f=n[t+1],p=n[e-1];if("rtl"===i){if(void 0!==o)d=!(p&&"left"===p.fixed);else if(void 0!==s){h=!(f&&"right"===f.fixed)}}else if(void 0!==o){l=!(f&&"left"===f.fixed)}else if(void 0!==s){u=!(p&&"right"===p.fixed)}return{fixLeft:o,fixRight:s,lastFixLeft:l,firstFixRight:u,lastFixRight:h,firstFixLeft:d,isSticky:r.isSticky}}var C=n("sR1s");function k(e){var t,n=e.cells,r=e.stickyOffsets,i=e.flattenColumns,o=e.rowComponent,s=e.cellComponent,a=e.onHeaderRow,l=e.index,u=c.useContext(w.a),h=u.prefixCls,d=u.direction;a&&(t=a(n.map((function(e){return e.column})),l));var f=Object(C.a)(n.map((function(e){return e.column})));return c.createElement(o,Object.assign({},t),n.map((function(e,t){var n,o=e.column,a=S(e.colStart,e.colEnd,i,r,d);return o&&o.onHeaderCell&&(n=e.column.onHeaderCell(o)),c.createElement(y.a,Object.assign({},e,{ellipsis:o.ellipsis,align:o.align,component:s,prefixCls:h,key:f[t]},a,{additionalProps:n,rowType:"header"}))})))}k.displayName="HeaderRow";var E=k;var O=function(e){var t=e.stickyOffsets,n=e.columns,r=e.flattenColumns,i=e.onHeaderRow,o=c.useContext(w.a),s=o.prefixCls,a=o.getComponent,l=c.useMemo((function(){return function(e){var t=[];!function e(n,r){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;t[i]=t[i]||[];var o=r,s=n.filter(Boolean).map((function(n){var r={key:n.key,className:n.className||"",children:n.title,column:n,colStart:o},s=1,a=n.children;return a&&a.length>0&&(s=e(a,o,i+1).reduce((function(e,t){return e+t}),0),r.hasSubColumns=!0),"colSpan"in n&&(s=n.colSpan),"rowSpan"in n&&(r.rowSpan=n.rowSpan),r.colSpan=s,r.colEnd=r.colStart+s-1,t[i].push(r),o+=s,s}));return s}(e,0);for(var n=t.length,r=function(e){t[e].forEach((function(t){"rowSpan"in t||t.hasSubColumns||(t.rowSpan=n-e)}))},i=0;i=0;o-=1){var s=t[o],a=n&&n[o],l=a&&a[x.a];(s||l||i)&&(r.unshift(c.createElement("col",Object.assign({key:o,style:{width:s,minWidth:s}},l))),i=!0)}return c.createElement("colgroup",null,r)};var j=c.forwardRef((function(e,t){var n=e.noData,s=e.columns,a=e.flattenColumns,l=e.colWidths,h=e.columCount,d=e.stickyOffsets,f=e.direction,p=e.fixHeader,_=e.offsetHeader,v=e.stickyClassName,b=e.onScroll,y=Object(g.a)(e,["noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","offsetHeader","stickyClassName","onScroll"]),S=c.useContext(w.a),C=S.prefixCls,k=S.scrollbarSize,E=S.isSticky,x=E&&!p?0:k,j=c.useRef(null),L=c.useCallback((function(e){Object(m.b)(t,e),Object(m.b)(j,e)}),[]);c.useEffect((function(){var e;function t(e){var t=e.currentTarget,n=e.deltaX;n&&(b({currentTarget:t,scrollLeft:t.scrollLeft+n}),e.preventDefault())}return null===(e=j.current)||void 0===e||e.addEventListener("wheel",t),function(){var e;null===(e=j.current)||void 0===e||e.removeEventListener("wheel",t)}}),[]);var R=a[a.length-1],M={fixed:R?R.fixed:null,onHeaderCell:function(){return{className:"".concat(C,"-cell-scrollbar")}}},T=Object(c.useMemo)((function(){return x?[].concat(Object(o.a)(s),[M]):s}),[x,s]),D=Object(c.useMemo)((function(){return x?[].concat(Object(o.a)(a),[M]):a}),[x,a]),P=Object(c.useMemo)((function(){var e=d.right,t=d.left;return Object(i.a)(Object(i.a)({},d),{},{left:"rtl"===f?[].concat(Object(o.a)(t.map((function(e){return e+x}))),[0]):t,right:"rtl"===f?e:[].concat(Object(o.a)(e.map((function(e){return e+x}))),[0]),isSticky:E})}),[x,d,E]),K=function(e,t){return Object(c.useMemo)((function(){for(var n=[],r=0;r1?n-1:0),o=1;o=p&&(r=p-v),l({scrollLeft:r/p*(f+2)}),C.current.x=e.pageX}else O&&x(!1)},L=function(){var e=Object(q.b)(s.current).top,t=e+s.current.offsetHeight,n=document.documentElement.scrollTop+window.innerHeight;t-Object(_.a)()<=n||e>=n-h?S((function(e){return Object(i.a)(Object(i.a)({},e),{},{isHiddenScrollBar:!0})})):S((function(e){return Object(i.a)(Object(i.a)({},e),{},{isHiddenScrollBar:!1})}))},R=function(e){S((function(t){return Object(i.a)(Object(i.a)({},t),{},{scrollLeft:e/f*p||0})}))};return c.useImperativeHandle(t,(function(){return{setScrollLeft:R}})),c.useEffect((function(){var e=Object(Q.a)(document.body,"mouseup",A,!1),t=Object(Q.a)(document.body,"mousemove",j,!1);return L(),function(){e.remove(),t.remove()}}),[v,O]),c.useEffect((function(){var e=Object(Q.a)(window,"scroll",L,!1),t=Object(Q.a)(window,"resize",L,!1);return function(){e.remove(),t.remove()}}),[]),c.useEffect((function(){y.isHiddenScrollBar||S((function(e){var t,n;return Object(i.a)(Object(i.a)({},e),{},{scrollLeft:s.current.scrollLeft/(null===(t=s.current)||void 0===t?void 0:t.scrollWidth)*(null===(n=s.current)||void 0===n?void 0:n.clientWidth)})}))}),[y.isHiddenScrollBar]),f<=p||!v||y.isHiddenScrollBar?null:c.createElement("div",{style:{height:Object(_.a)(),width:p,bottom:h},className:"".concat(d,"-sticky-scroll")},c.createElement("div",{onMouseDown:function(e){e.persist(),C.current.delta=e.pageX-y.scrollLeft,C.current.x=0,x(!0),e.preventDefault()},ref:b,className:u()("".concat(d,"-sticky-scroll-bar"),Object(r.a)({},"".concat(d,"-sticky-scroll-bar-active"),O)),style:{width:"".concat(v,"px"),transform:"translate3d(".concat(y.scrollLeft,"px, 0, 0)")}}))}));var Y=[],Z={},J="rc-table-internal-hook",$=c.memo((function(e){return e.children}),(function(e,t){return!!d()(e.props,t.props)&&(e.pingLeft!==t.pingLeft||e.pingRight!==t.pingRight)}));function ee(e){var t,n=e.prefixCls,l=e.className,h=e.rowClassName,d=e.style,v=e.data,b=e.rowKey,g=e.scroll,m=e.tableLayout,y=e.direction,k=e.title,E=e.footer,j=e.summary,M=e.id,T=e.showHeader,D=e.components,K=e.emptyText,I=e.onRow,N=e.onHeaderRow,B=e.internalHooks,Q=e.transformColumns,q=e.internalRefs,ee=e.sticky,te=v||Y,ne=!!te.length,re=c.useState(0),ie=Object(a.a)(re,2),oe=ie[0],se=ie[1];c.useEffect((function(){se(Object(_.a)())}));var ae,ce,le,ue=c.useMemo((function(){return Object(C.c)(D,{})}),[D]),he=c.useCallback((function(e,t){return Object(C.b)(ue,e)||t}),[ue]),de=c.useMemo((function(){return"function"==typeof b?b:function(e){return e&&e[b]}}),[b]),fe=Object(x.c)(e),pe=fe.expandIcon,_e=fe.expandedRowKeys,ve=fe.defaultExpandedRowKeys,be=fe.defaultExpandAllRows,ge=fe.expandedRowRender,me=fe.onExpand,ye=fe.onExpandedRowsChange,we=fe.expandRowByClick,Se=fe.rowExpandable,Ce=fe.expandIconColumnIndex,ke=fe.expandedRowClassName,Ee=fe.childrenColumnName,Oe=fe.indentSize,xe=pe||V,Ae=Ee||"children",je=c.useMemo((function(){return ge?"row":!!(e.expandable&&B===J&&e.expandable.__PARENT_RENDER_ICON__||te.some((function(e){return e&&"object"===Object(s.a)(e)&&e[Ae]})))&&"nest"}),[!!ge,te]),Le=c.useState((function(){return ve||(be?function(e,t,n){var r=[];return function e(i){(i||[]).forEach((function(i,o){r.push(t(i,o)),e(i[n])}))}(e),r}(te,de,Ae):[])})),Re=Object(a.a)(Le,2),Me=Re[0],Te=Re[1],De=c.useMemo((function(){return new Set(_e||Me||[])}),[_e,Me]),Pe=c.useCallback((function(e){var t,n=de(e,te.indexOf(e)),r=De.has(n);r?(De.delete(n),t=Object(o.a)(De)):t=[].concat(Object(o.a)(De),[n]),Te(t),me&&me(!r,e),ye&&ye(t)}),[de,De,te,me,ye]),Ke=c.useState(0),Ie=Object(a.a)(Ke,2),Fe=Ie[0],Xe=Ie[1],Ne=Object(X.b)(Object(i.a)(Object(i.a)(Object(i.a)({},e),fe),{},{expandable:!!ge,expandedKeys:De,getRowKey:de,onTriggerExpand:Pe,expandIcon:xe,expandIconColumnIndex:Ce,direction:y}),B===J?Q:null),Be=Object(a.a)(Ne,2),He=Be[0],Ue=Be[1],We=c.useMemo((function(){return{columns:He,flattenColumns:Ue}}),[He,Ue]),ze=c.useRef(),Ve=c.useRef(),Qe=c.useRef(),qe=c.useState(!1),Ge=Object(a.a)(qe,2),Ye=Ge[0],Ze=Ge[1],Je=c.useState(!1),$e=Object(a.a)(Je,2),et=$e[0],tt=$e[1],nt=H(new Map),rt=Object(a.a)(nt,2),it=rt[0],ot=rt[1],st=Object(C.a)(Ue).map((function(e){return it.get(e)})),at=c.useMemo((function(){return st}),[st.join("_")]),ct=U(at,Ue.length,y),lt=g&&Object(C.d)(g.y),ut=g&&Object(C.d)(g.x),ht=ut&&Ue.some((function(e){return e.fixed})),dt=c.useRef(),ft=function(e,t){return c.useMemo((function(){var n=!!e;return{isSticky:n,stickyClassName:n?"".concat(t,"-sticky-header"):"",offsetHeader:"object"===Object(s.a)(e)&&e.offsetHeader||0,offsetScroll:"object"===Object(s.a)(e)&&e.offsetScroll||0}}),[e,t])}(ee,n),pt=ft.isSticky,_t=ft.offsetHeader,vt=ft.offsetScroll,bt=ft.stickyClassName;lt&&(ce={overflowY:"scroll",maxHeight:g.y}),ut&&(ae={overflowX:"auto"},lt||(ce={overflowY:"hidden"}),le={width:!0===g.x?"auto":g.x,minWidth:"100%"});var gt=c.useCallback((function(e,t){ot((function(n){var r=new Map(n);return r.set(e,t),r}))}),[]),mt=function(e){var t=Object(c.useRef)(e),n=Object(c.useRef)(null);function r(){window.clearTimeout(n.current)}return Object(c.useEffect)((function(){return r}),[]),[function(e){t.current=e,r(),n.current=window.setTimeout((function(){t.current=null,n.current=null}),100)},function(){return t.current}]}(null),yt=Object(a.a)(mt,2),wt=yt[0],St=yt[1];function Ct(e,t){t&&("function"==typeof t?t(e):t.scrollLeft!==e&&(t.scrollLeft=e))}var kt=function(e){var t,n=e.currentTarget,r=e.scrollLeft,i="number"==typeof r?r:n.scrollLeft,o=n||Z;St()&&St()!==o||(wt(o),Ct(i,Ve.current),Ct(i,Qe.current),Ct(i,null===(t=dt.current)||void 0===t?void 0:t.setScrollLeft));if(n){var s=n.scrollWidth,a=n.clientWidth;Ze(i>0),tt(i0?[].concat(Object(i.a)(e),Object(i.a)(h(s).map((function(e){return Object(o.a)({fixed:r},e)})))):[].concat(Object(i.a)(e),[Object(o.a)(Object(o.a)({},t),{},{fixed:r})])}),[])}t.b=function(e,t){var n=e.prefixCls,i=e.columns,c=e.children,d=e.expandable,f=e.expandedKeys,p=e.getRowKey,_=e.onTriggerExpand,v=e.expandIcon,b=e.rowExpandable,g=e.expandIconColumnIndex,m=e.direction,y=e.expandRowByClick,w=a.useMemo((function(){return i||u(c)}),[i,c]),S=a.useMemo((function(){if(d){var e,t=g||0,i=w[t],o=(e={},Object(r.a)(e,l.a,{className:"".concat(n,"-expand-icon-col")}),Object(r.a)(e,"title",""),Object(r.a)(e,"fixed",i?i.fixed:null),Object(r.a)(e,"className","".concat(n,"-row-expand-icon-cell")),Object(r.a)(e,"render",(function(e,t,r){var i=p(t,r),o=f.has(i),s=!b||b(t),c=v({prefixCls:n,expanded:o,expandable:s,record:t,onExpand:_});return y?a.createElement("span",{onClick:function(e){return e.stopPropagation()}},c):c})),e),s=w.slice();return t>=0&&s.splice(t,0,o),s}return w}),[d,w,p,f,v,m]),C=a.useMemo((function(){var e=S;return t&&(e=t(e)),e.length||(e=[{render:function(){return null}}]),e}),[t,S,m]),k=a.useMemo((function(){return"rtl"===m?function(e){return e.map((function(e){var t=e.fixed,n=Object(s.a)(e,["fixed"]),r=t;return"left"===t?r="right":"right"===t&&(r="left"),Object(o.a)({fixed:r},n)}))}(h(C)):h(C)}),[C,m]);return[C,k]}},whVF: /*!***************************************************!*\ !*** ./node_modules/@novnc/novnc/lib/deflator.js ***! \***************************************************/ /*! no static exports found */ /*! all exports used */ /*! ModuleConcatenation bailout: Module is not an ECMAScript module */function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,i=n(/*! ../lib/vendor/pako/lib/zlib/deflate.js */"lNSK"),o=(r=n(/*! ../lib/vendor/pako/lib/zlib/zstream.js */"1q3G"))&&r.__esModule?r:{default:r};function s(e,t){for(var n=0;n0){var r=[n],o=n.length;do{if(this.strm.output=new Uint8Array(this.chunkSize),this.strm.next_out=0,this.strm.avail_out=this.chunkSize,(t=(0,i.deflate)(this.strm,i.Z_FULL_FLUSH))<0)throw new Error("zlib deflate failed");var s=new Uint8Array(this.strm.output.buffer,0,this.strm.next_out);o+=s.length,r.push(s)}while(this.strm.avail_in>0);for(var a=new Uint8Array(o),c=0,l=0;l>>16&65535|0,s=0;for(;0!==n;){n-=s=n>2e3?2e3:n;do{i=i+t[r++]|0,o=o+i|0}while(--s);i%=65521,o%=65521}return i|o<<16|0}},"y0+3": /*!********************************************!*\ !*** ./node_modules/rc-util/es/Dom/css.js ***! \********************************************/ /*! exports provided: get, set, getOuterWidth, getOuterHeight, getDocSize, getClientSize, getScroll, getOffset */ /*! exports used: getClientSize, getOffset */function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return i}));function r(){return{width:document.documentElement.clientWidth,height:window.innerHeight||document.documentElement.clientHeight}}function i(e){var t=e.getBoundingClientRect(),n=document.documentElement;return{left:t.left+(window.pageXOffset||n.scrollLeft)-(n.clientLeft||document.body.clientLeft||0),top:t.top+(window.pageYOffset||n.scrollTop)-(n.clientTop||document.body.clientTop||0)}}},y5JW: /*!***********************************************!*\ !*** ./src/components/SingleUpload/index.tsx ***! \***********************************************/ /*! exports provided: uploadNameSizeSeperator, bytesToSize, default */ /*! exports used: bytesToSize, default, uploadNameSizeSeperator */function(e,t,n){"use strict";n.d(t,"c",(function(){return _})),n.d(t,"a",(function(){return v}));n(/*! antd/es/upload/style */"DZo9");var r=n(/*! antd/es/upload */"8z0m"),i=(n(/*! antd/es/button/style */"+L6B"),n(/*! antd/es/button */"2/Rp")),o=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/asyncToGenerator */"9og8"),s=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/objectSpread2 */"k1fw"),a=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/helpers/esm/toConsumableArray */"oBTY"),c=(n(/*! antd/es/message/style */"miYZ"),n(/*! antd/es/message */"tsqr")),l=n(/*! ./node_modules/@umijs/babel-preset-umi/node_modules/@babel/runtime/regenerator */"WmNS"),u=n.n(l),h=n(/*! react */"q1tI"),d=n.n(h),f=n(/*! @/utils/env */"m3rI"),p=n(/*! @/pages/MoopCases/FormPanel/service */"wzkS"),_="  ";function v(e){if(0==e)return"0 Byte";var t=parseInt(""+Math.floor(Math.log(e)/Math.log(1024)),10);return(e/Math.pow(1024,t)).toFixed(1)+" "+["Bytes","KB","MB","GB","TB"][t]}t.b=function(e){var t,n=e.value,l=void 0===n?[]:n,h=(e.action,e.onChange),b=e.className,g=e.maxSize,m=void 0===g?150:g,y=e.title,w=void 0===y?"文件上传":y,S=e.accept,C={multiple:!1,fileList:l,accept:void 0===S?null:S,withCredentials:!0,beforeUpload:function(e){return e.size/1024/10240?"每次只能上传一个资源, 删除下面资源可重新上传 ":"",disabled:l.length>0,ghost:!0},w),d.a.createElement("span",{onClick:function(e){e.preventDefault(),e.stopPropagation()},style:{marginLeft:10}},"(单个文件最大",m,"M) ")))}}}]);