From 0dda8d56d9f4d97e72201cc60d34c3f4cd799fca Mon Sep 17 00:00:00 2001 From: Bill Church Date: Wed, 10 Jul 2024 12:13:53 +0000 Subject: [PATCH] build: release 0.2.12 --- app/client/public/webssh2.bundle.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/client/public/webssh2.bundle.js b/app/client/public/webssh2.bundle.js index 81fec9b..1e19e39 100644 --- a/app/client/public/webssh2.bundle.js +++ b/app/client/public/webssh2.bundle.js @@ -1 +1 @@ -!function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=56)}([function(t,e,n){var r,i=n(42),o=n(21),s=n(43),a=n(44),l=n(45);"undefined"!=typeof ArrayBuffer&&(r=n(46));var c="undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent),h="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),u=c||h;e.protocol=3;var f=e.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},p=i(f),d={type:"error",data:"parser error"},_=n(47);function m(t,e,n){for(var r=new Array(t.length),i=a(t.length,n),o=0;o=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|t}function d(t,e){if(l.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;var n=(t="string"!=typeof t?""+t:t).length;if(0===n)return 0;for(var r=!1;;)switch(e){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return M(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return D(t).length;default:if(r)return M(t).length;e=(""+e).toLowerCase(),r=!0}}function _(t,e,n){var i,o,s,a=!1;if((e=void 0===e||e<0?0:e)>this.length)return"";if((n=void 0===n||n>this.length?this.length:n)<=0)return"";if((n>>>=0)<=(e>>>=0))return"";for(t=t||"utf8";;)switch(t){case"hex":return function(t,e,n){var r=t.length;(!e||e<0)&&(e=0),(!n||n<0||r=t.length){if(i)return-1;n=t.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof e&&(e=l.from(e,r)),l.isBuffer(e))return 0===e.length?-1:y(t,e,n,r,i);if("number"==typeof e)return e&=255,l.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?(i?Uint8Array.prototype.indexOf:Uint8Array.prototype.lastIndexOf).call(t,e,n):y(t,[e],n,r,i);throw new TypeError("val must be string, number or Buffer")}function y(t,e,n,r,i){var o=1,s=t.length,a=e.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(t.length<2||e.length<2)return-1;s/=o=2,a/=2,n/=2}function l(t,e){return 1===o?t[e]:t.readUInt16BE(e*o)}if(i)for(var c=-1,h=n;h>8,r%=256,i.push(r),i.push(n);return i}(e,t.length-n),t,n,r)}function v(t,e,n){n=Math.min(t.length,n);for(var r=[],i=e;i>>10&1023|55296),h=56320|1023&h),r.push(h),i+=u}return function(t){var e=t.length;if(e<=w)return String.fromCharCode.apply(String,t);for(var n="",r=0;rn&&(t+=" ... ")),""},l.prototype.compare=function(t,e,n,r,i){if(!l.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===n&&(n=t?t.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),(e=void 0===e?0:e)<0||n>t.length||r<0||i>this.length)throw new RangeError("out of range index");if(i<=r&&n<=e)return 0;if(i<=r)return-1;if(n<=e)return 1;if(this===t)return 0;for(var o=(i>>>=0)-(r>>>=0),s=(n>>>=0)-(e>>>=0),a=Math.min(o,s),c=this.slice(r,i),h=t.slice(e,n),u=0;uthis.length)throw new RangeError("Attempt to write outside buffer bounds");r=r||"utf8";for(var o,s,a,l=!1;;)switch(r){case"hex":return function(t,e,n,r){n=Number(n)||0;var i=t.length-n;if((!r||i<(r=Number(r)))&&(r=i),(i=e.length)%2!=0)throw new TypeError("Invalid hex string");i/2t.length)throw new RangeError("Index out of range")}function A(t,e,n,r){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-n,2);i>>8*(r?i:1-i)}function x(t,e,n,r){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-n,4);i>>8*(r?i:3-i)&255}function k(t,e,n,r){if(n+r>t.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function L(t,e,n,r,o){return o||k(t,0,n,4),i.write(t,e,n,r,23,4),n+4}function T(t,e,n,r,o){return o||k(t,0,n,8),i.write(t,e,n,r,52,8),n+8}l.prototype.slice=function(t,e){var n=this.length;if((t=~~t)<0?(t+=n)<0&&(t=0):n>>8):A(this,t,e,!0),e+2},l.prototype.writeUInt16BE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,2,65535,0),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):A(this,t,e,!1),e+2},l.prototype.writeUInt32LE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,4,4294967295,0),l.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):x(this,t,e,!0),e+4},l.prototype.writeUInt32BE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,4,4294967295,0),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):x(this,t,e,!1),e+4},l.prototype.writeIntLE=function(t,e,n,r){t=+t,e|=0,r||E(this,t,e,n,(r=Math.pow(2,8*n-1))-1,-r);var i=0,o=1,s=0;for(this[e]=255&t;++i>0)-s&255;return e+n},l.prototype.writeIntBE=function(t,e,n,r){t=+t,e|=0,r||E(this,t,e,n,(r=Math.pow(2,8*n-1))-1,-r);var i=n-1,o=1,s=0;for(this[e+i]=255&t;0<=--i&&(o*=256);)t<0&&0===s&&0!==this[e+i+1]&&(s=1),this[e+i]=(t/o>>0)-s&255;return e+n},l.prototype.writeInt8=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,1,127,-128),l.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&(t=t<0?255+t+1:t),e+1},l.prototype.writeInt16LE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,2,32767,-32768),l.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):A(this,t,e,!0),e+2},l.prototype.writeInt16BE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,2,32767,-32768),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):A(this,t,e,!1),e+2},l.prototype.writeInt32LE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,4,2147483647,-2147483648),l.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):x(this,t,e,!0),e+4},l.prototype.writeInt32BE=function(t,e,n){return t=+t,e|=0,n||E(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):x(this,t,e,!1),e+4},l.prototype.writeFloatLE=function(t,e,n){return L(this,t,e,!0,n)},l.prototype.writeFloatBE=function(t,e,n){return L(this,t,e,!1,n)},l.prototype.writeDoubleLE=function(t,e,n){return T(this,t,e,!0,n)},l.prototype.writeDoubleBE=function(t,e,n){return T(this,t,e,!1,n)},l.prototype.copy=function(t,e,n,r){if(n=n||0,r||0===r||(r=this.length),e>=t.length&&(e=t.length),(r=0=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length);var i,o=(r=t.length-e>>=0,n=void 0===n?this.length:n>>>0,"number"==typeof(t=t||0))for(a=e;a>6|192,63&n|128)}else if(n<65536){if((e-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function D(t){return r.toByteArray(function(t){var e;if((t=((e=t).trim?e.trim():e.replace(/^\s+|\s+$/g,"")).replace(R,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function B(t,e,n,r){for(var i=0;i=e.length||i>=t.length);++i)e[i+n]=t[i];return i}}).call(this,n(1))},function(t,e,n){var r=n(40);t.exports=function(t){var e=t.xdomain,n=t.xscheme;t=t.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!e||r))return new XMLHttpRequest}catch(t){}try{if("undefined"!=typeof XDomainRequest&&!n&&t)return new XDomainRequest}catch(t){}if(!e)try{return new(self[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(t){}}},function(t,e,n){var r=n(0);function i(t){this.path=t.path,this.hostname=t.hostname,this.port=t.port,this.secure=t.secure,this.query=t.query,this.timestampParam=t.timestampParam,this.timestampRequests=t.timestampRequests,this.readyState="",this.agent=t.agent||!1,this.socket=t.socket,this.enablesXDR=t.enablesXDR,this.pfx=t.pfx,this.key=t.key,this.passphrase=t.passphrase,this.cert=t.cert,this.ca=t.ca,this.ciphers=t.ciphers,this.rejectUnauthorized=t.rejectUnauthorized,this.forceNode=t.forceNode,this.isReactNative=t.isReactNative,this.extraHeaders=t.extraHeaders,this.localAddress=t.localAddress}n(2)((t.exports=i).prototype),i.prototype.onError=function(t,e){return(t=new Error(t)).type="TransportError",t.description=e,this.emit("error",t),this},i.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},i.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},i.prototype.send=function(t){if("open"!==this.readyState)throw new Error("Transport not open");this.write(t)},i.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},i.prototype.onData=function(t){t=r.decodePacket(t,this.socket.binaryType),this.onPacket(t)},i.prototype.onPacket=function(t){this.emit("packet",t)},i.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(t,e,n){t.exports=function t(e,n,r){function i(s,a){if(!n[s]){if(!e[s]){if(o)return o(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}l=n[s]={exports:{}},e[s][0].call(l.exports,(function(t){return i(e[s][1][t]||t)}),l,l.exports,t,e,n,r)}return n[s].exports}for(var o=!1,s=0;st;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()},f.prototype._createAccessibilityTreeNode=function(){var t=document.createElement("div");return t.setAttribute("role","listitem"),t.tabIndex=-1,this._refreshRowDimensions(t),t},f.prototype._onTab=function(t){for(var e=0;ethis._rows},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isCursorInViewport",{get:function(){var t=this.ybase+this.y-this.ydisp;return 0<=t&&tn.MAX_BUFFER_SIZE?n.MAX_BUFFER_SIZE:t},a.prototype.fillViewportRows=function(t){if(0===this.lines.length){void 0===t&&(t=i.DEFAULT_ATTR_DATA);for(var e=this._rows;e--;)this.lines.push(this.getBlankLine(t))}},a.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()},a.prototype.resize=function(t,e){var n=this.getNullCell(i.DEFAULT_ATTR_DATA),r=this._getCorrectBufferLength(e);if(r>this.lines.maxLength&&(this.lines.maxLength=r),0e+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));rt))for(o=0;othis._cols?this._reflowLarger(t,e):this._reflowSmaller(t,e))},a.prototype._reflowLarger=function(t,e){var n=o.reflowLargerGetLinesToRemove(this.lines,this._cols,t,this.ybase+this.y,this.getNullCell(i.DEFAULT_ATTR_DATA));0x+T){for(var R=L.newLines.length-1;0<=R;R--)this.lines.set(_--,L.newLines[R]);_++,S.push({index:x+1,amount:L.newLines.length}),T+=L.newLines.length,L=r[++k]}else this.lines.set(_,E[x--]);var M=0;for(_=S.length-1;0<=_;_--)S[_].index+=M,this.lines.onInsertEmitter.fire(S[_]),M+=S[_].amount;0<(A=Math.max(0,A+s-this.lines.maxLength))&&this.lines.onTrimEmitter.fire(A)}},a.prototype.stringIndexToBufferIndex=function(t,e,n){for(void 0===n&&(n=!1);e;){var r=this.lines.get(t);if(!r)return[-1,-1];for(var o=n?r.getTrimmedLength():r.length,s=0;s=this._cols?this._cols-1:t<0?0:t},a.prototype.nextStop=function(t){for(null==t&&(t=this.x);!this.tabs[++t]&&t=this._cols?this._cols-1:t<0?0:t},a.prototype.addMarker=function(t){var e=this,n=new s.Marker(t);return this.markers.push(n),n.register(this.lines.onTrim((function(t){n.line-=t,n.line<0&&n.dispose()}))),n.register(this.lines.onInsert((function(t){n.line>=t.index&&(n.line+=t.amount)}))),n.register(this.lines.onDelete((function(t){n.line>=t.index&&n.linet.index&&(n.line-=t.amount)}))),n.register(n.onDispose((function(){return e._removeMarker(n)}))),n},a.prototype._removeMarker=function(t){this.markers.splice(this.markers.indexOf(t),1)},a.prototype.iterator=function(t,e,n,r,i){return new l(this,t,e,n,r,i)},t=a,n.Buffer=t;var l=(c.prototype.hasNext=function(){return this._currentthis._endIndex+this._endOverscan&&(t.last=this._endIndex+this._endOverscan),t.first=Math.max(t.first,0),t.last=Math.min(t.last,this._buffer.lines.length);for(var e="",n=t.first;n<=t.last;++n)e+=this._buffer.translateBufferLineToString(n,this._trimRight);return this._current=t.last+1,{range:t,content:e}},c);function c(t,e,n,r,i,o){void 0===n&&(n=0),void 0===r&&(r=t.lines.length),void 0===i&&(i=0),void 0===o&&(o=0),this._buffer=t,this._trimRight=e,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}n.BufferStringIterator=l},{"./common/CircularList":20,"./core/buffer/BufferLine":29,"./core/buffer/BufferReflow":30,"./core/buffer/Marker":31}],3:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("./Buffer"),i=t("./common/EventEmitter2");Object.defineProperty(o.prototype,"onBufferActivate",{get:function(){return this._onBufferActivate.event},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"alt",{get:function(){return this._alt},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"active",{get:function(){return this._activeBuffer},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"normal",{get:function(){return this._normal},enumerable:!0,configurable:!0}),o.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}))},o.prototype.activateAltBuffer=function(t){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(t),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}))},o.prototype.resize=function(t,e){this._normal.resize(t,e),this._alt.resize(t,e)},o.prototype.setupTabStops=function(t){this._normal.setupTabStops(t),this._alt.setupTabStops(t)},t=o;function o(t){this._terminal=t,this._onBufferActivate=new i.EventEmitter2,this._normal=new r.Buffer(this._terminal,!0),this._normal.fillViewportRows(),this._alt=new r.Buffer(this._terminal,!1),this._activeBuffer=this._normal,this.setupTabStops()}n.BufferSet=t},{"./Buffer":2,"./common/EventEmitter2":23}],4:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("./common/EventEmitter2");Object.defineProperty(i.prototype,"onCharSizeChanged",{get:function(){return this._onCharSizeChanged.event},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"width",{get:function(){return this._width},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"height",{get:function(){return this._height},enumerable:!0,configurable:!0}),i.prototype.measure=function(t){this._measureElement.style.fontFamily=t.fontFamily,this._measureElement.style.fontSize=t.fontSize+"px";var e=this._measureElement.getBoundingClientRect();0!==e.width&&0!==e.height&&(t=Math.ceil(e.height),this._width===e.width&&this._height===t||(this._width=e.width,this._height=t,this._onCharSizeChanged.fire()))},t=i;function i(t,e){this._onCharSizeChanged=new r.EventEmitter2,this._document=t,this._parentElement=e,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)}n.CharMeasure=t},{"./common/EventEmitter2":23}],5:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("./common/TypedArrayUtils");n.wcwidth=function(t){var e=[[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]],n=[[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]];var i=0|t.control,o=new Uint8Array(65536);r.fill(o,1),o[0]=t.nul,r.fill(o,t.control,1,32),r.fill(o,t.control,127,160),r.fill(o,2,4352,4448),o[9001]=2,o[9002]=2,r.fill(o,2,11904,42192),o[12351]=1,r.fill(o,2,44032,55204),r.fill(o,2,63744,64256),r.fill(o,2,65040,65050),r.fill(o,2,65072,65136),r.fill(o,2,65280,65377),r.fill(o,2,65504,65511);for(var s=0;se[i][1]))for(;r<=i;)if(t>e[n=r+i>>1][1])r=1+n;else{if(!(t=r)return e+n.wcwidth(o);var s=t.charCodeAt(i);56320<=s&&s<=57343?o=1024*(o-55296)+s-56320+65536:e+=n.wcwidth(s)}e+=n.wcwidth(o)}return e}},{"./common/TypedArrayUtils":26}],6:[function(t,e,n){"use strict";function r(t){return t.replace(/\r?\n/g,"\r")}function i(t,e){return e?"[200~"+t+"[201~":t}function o(t,e){var n=e.screenElement.getBoundingClientRect(),r=t.clientX-n.left-10;n=t.clientY-n.top-10;e.textarea.style.position="absolute",e.textarea.style.width="20px",e.textarea.style.height="20px",e.textarea.style.left=r+"px",e.textarea.style.top=n+"px",e.textarea.style.zIndex="1000",e.textarea.focus(),setTimeout((function(){e.textarea.style.position=null,e.textarea.style.width=null,e.textarea.style.height=null,e.textarea.style.left=null,e.textarea.style.top=null,e.textarea.style.zIndex=null}),200)}Object.defineProperty(n,"__esModule",{value:!0}),n.prepareTextForTerminal=r,n.bracketTextForPaste=i,n.copyHandler=function(t,e,n){e.browser.isMSIE?window.clipboardData.setData("Text",n.selectionText):t.clipboardData.setData("text/plain",n.selectionText),t.preventDefault()},n.pasteHandler=function(t,e){function n(n){n=i(n=r(n),e.bracketedPasteMode),e.handler(n),e.textarea.value="",e.emit("paste",n),e.cancel(t)}t.stopPropagation(),e.browser.isMSIE?window.clipboardData&&n(window.clipboardData.getData("Text")):t.clipboardData&&n(t.clipboardData.getData("text/plain"))},n.moveTextAreaUnderMouseCursor=o,n.rightClickHandler=function(t,e,n,r){o(t,e),r&&!n.isClickInSelection(t)&&n.selectWordAtCursor(t),e.textarea.value=n.selectionText,e.textarea.select()}},{}],7:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=(i.prototype.compositionstart=function(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._compositionView.classList.add("active")},i.prototype.compositionupdate=function(t){var e=this;this._compositionView.textContent=t.data,this.updateCompositionElements(),setTimeout((function(){e._compositionPosition.end=e._textarea.value.length}),0)},i.prototype.compositionend=function(){this._finalizeComposition(!0)},i.prototype.keydown=function(t){if(this._isComposing||this._isSendingComposition){if(229===t.keyCode)return!1;if(16===t.keyCode||17===t.keyCode||18===t.keyCode)return!1;this._finalizeComposition(!1)}return 229!==t.keyCode||(this._handleAnyTextareaChanges(),!1)},i.prototype._finalizeComposition=function(t){var e,n=this;this._compositionView.classList.remove("active"),this._isComposing=!1,this._clearTextareaPosition(),t?(e={start:this._compositionPosition.start,end:this._compositionPosition.end},this._isSendingComposition=!0,setTimeout((function(){var t;n._isSendingComposition&&(n._isSendingComposition=!1,void 0,t=n._isComposing?n._textarea.value.substring(e.start,e.end):n._textarea.value.substring(e.start),n._terminal.handler(t))}),0)):(this._isSendingComposition=!1,t=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end),this._terminal.handler(t))},i.prototype._handleAnyTextareaChanges=function(){var t=this,e=this._textarea.value;setTimeout((function(){var n;t._isComposing||0<(n=t._textarea.value.replace(e,"")).length&&t._terminal.handler(n)}),0)},i.prototype.updateCompositionElements=function(t){var e,n,r,i=this;this._isComposing&&(this._terminal.buffer.isCursorInViewport&&(r=Math.ceil(this._terminal.charMeasure.height*this._terminal.options.lineHeight),e=this._terminal.buffer.y*r,n=this._terminal.buffer.x*this._terminal.charMeasure.width,this._compositionView.style.left=n+"px",this._compositionView.style.top=e+"px",this._compositionView.style.height=r+"px",this._compositionView.style.lineHeight=r+"px",this._compositionView.style.fontFamily=this._terminal.options.fontFamily,this._compositionView.style.fontSize=this._terminal.options.fontSize+"px",r=this._compositionView.getBoundingClientRect(),this._textarea.style.left=n+"px",this._textarea.style.top=e+"px",this._textarea.style.width=r.width+"px",this._textarea.style.height=r.height+"px",this._textarea.style.lineHeight=r.height+"px"),t||setTimeout((function(){return i.updateCompositionElements(!0)}),0))},i.prototype._clearTextareaPosition=function(){this._textarea.style.left="",this._textarea.style.top=""},i);function i(t,e,n){this._textarea=t,this._compositionView=e,this._terminal=n,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:null,end:null}}n.CompositionHelper=r},{}],8:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o=t("./common/Lifecycle"),s=t("./core/input/TextDecoder");function a(t,e){for(var n=e-t,r=new Array(n);n--;)r[n]=--e;return r}var l=(c.prototype.add=function(t,e,n,r){this.table[e<<8|t]=(0|n)<<4|(void 0===r?e:r)},c.prototype.addMany=function(t,e,n,r){for(var i=0;i>4){case 2:a=~a?a:_;break;case 3:~a&&(this._printHandler(t,a,_),a=-1),(d=this._executeHandlers[n])?d():this._executeHandlerFb(n);break;case 0:~a?(this._printHandler(t,a,_),a=-1):~l&&(p.put(t,l,_),l=-1);break;case 1:if(159=s)if(l)r.x=0,r.y++,r.y>r.scrollBottom?(r.y--,this._terminal.scroll(!0)):r.lines.get(r.y).isWrapped=!0,p=r.lines.get(r.y+r.ybase);else if(2===g)continue;if(c&&(p.insertCells(r.x,g,r.getNullCell(h)),2===p.getWidth(s-1)&&p.setCellFromCodePoint(s-1,f.NULL_CELL_CODE,f.NULL_CELL_WIDTH,h.fg,h.bg)),p.setCellFromCodePoint(r.x++,m,g,h.fg,h.bg),0t.scrollBottom&&(t.y--,this._terminal.scroll()),t.x>=this._terminal.cols&&t.x--,this._onLineFeed.fire()},y.prototype.carriageReturn=function(){this._terminal.buffer.x=0},y.prototype.backspace=function(){0=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x>=this._terminal.cols&&this._terminal.buffer.x--},y.prototype.cursorForward=function(t){t=t[0],this._terminal.buffer.x+=t=t<1?1:t,this._terminal.buffer.x>=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.cursorBackward=function(t){(t=t[0])<1&&(t=1),this._terminal.buffer.x>=this._terminal.cols&&this._terminal.buffer.x--,this._terminal.buffer.x-=t,this._terminal.buffer.x<0&&(this._terminal.buffer.x=0)},y.prototype.cursorNextLine=function(t){t=t[0],this._terminal.buffer.y+=t=t<1?1:t,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x=0},y.prototype.cursorPrecedingLine=function(t){t=t[0],this._terminal.buffer.y-=t=t<1?1:t,this._terminal.buffer.y<0&&(this._terminal.buffer.y=0),this._terminal.buffer.x=0},y.prototype.cursorCharAbsolute=function(t){t=t[0],this._terminal.buffer.x=(t=t<1?1:t)-1},y.prototype.cursorPosition=function(t){var e=t[0]-1;t=2<=t.length?t[1]-1:0;e<0?e=0:e>=this._terminal.rows&&(e=this._terminal.rows-1),t<0?t=0:t>=this._terminal.cols&&(t=this._terminal.cols-1),this._terminal.buffer.x=t,this._terminal.buffer.y=e},y.prototype.cursorForwardTab=function(t){for(var e=t[0]||1;e--;)this._terminal.buffer.x=this._terminal.buffer.nextStop()},y.prototype._eraseInBufferLine=function(t,e,n,r){void 0===r&&(r=!1),(t=this._terminal.buffer.lines.get(this._terminal.buffer.ybase+t)).replaceCells(e,n,this._terminal.buffer.getNullCell(this._terminal.eraseAttrData())),r&&(t.isWrapped=!1)},y.prototype._resetBufferLine=function(t){this._eraseInBufferLine(t,0,this._terminal.cols,!0)},y.prototype.eraseInDisplay=function(t){var e;switch(t[0]){case 0:for(e=this._terminal.buffer.y,this._terminal.updateRange(e),this._eraseInBufferLine(e++,this._terminal.buffer.x,this._terminal.cols,0===this._terminal.buffer.x);e=this._terminal.cols&&(this._terminal.buffer.lines.get(e+1).isWrapped=!1);e--;)this._resetBufferLine(e);this._terminal.updateRange(0);break;case 2:for(e=this._terminal.rows,this._terminal.updateRange(e-1);e--;)this._resetBufferLine(e);this._terminal.updateRange(0);break;case 3:var n=this._terminal.buffer.lines.length-this._terminal.rows;0=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.hPositionRelative=function(t){t=t[0],this._terminal.buffer.x+=t=t<1?1:t,this._terminal.buffer.x>=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.repeatPrecedingCharacter=function(t){var e=this._terminal.buffer,n=e.lines.get(e.ybase+e.y);n.loadCell(e.x-1,this._workCell),n.replaceCells(e.x,e.x+(t[0]||1),void 0!==this._workCell.content?this._workCell:e.getNullCell(f.DEFAULT_ATTR_DATA))},y.prototype.sendDeviceAttributes=function(t,e){0"===e&&(this._terminal.is("xterm")?this._terminal.handler(o.C0.ESC+"[>0;276;0c"):this._terminal.is("rxvt-unicode")?this._terminal.handler(o.C0.ESC+"[>85;95;0c"):this._terminal.is("linux")?this._terminal.handler(t[0]+"c"):this._terminal.is("screen")&&this._terminal.handler(o.C0.ESC+"[>83;40003;0c")):this._terminal.is("xterm")||this._terminal.is("rxvt-unicode")||this._terminal.is("screen")?this._terminal.handler(o.C0.ESC+"[?1;2c"):this._terminal.is("linux")&&this._terminal.handler(o.C0.ESC+"[?6c"))},y.prototype.linePosAbsolute=function(t){t=t[0],this._terminal.buffer.y=(t=t<1?1:t)-1,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1)},y.prototype.vPositionRelative=function(t){t=t[0],this._terminal.buffer.y+=t=t<1?1:t,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x>=this._terminal.cols&&this._terminal.buffer.x--},y.prototype.hVPosition=function(t){t[0]<1&&(t[0]=1),t[1]<1&&(t[1]=1),this._terminal.buffer.y=t[0]-1,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x=t[1]-1,this._terminal.buffer.x>=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.tabClear=function(t){(t=t[0])<=0?delete this._terminal.buffer.tabs[this._terminal.buffer.x]:3===t&&(this._terminal.buffer.tabs={})},y.prototype.setMode=function(t,e){if(1",(function(){return n.keypadNumericMode()})),n._parser.setEscHandler("c",(function(){return n.reset()})),n._parser.setEscHandler("n",(function(){return n.setgLevel(2)})),n._parser.setEscHandler("o",(function(){return n.setgLevel(3)})),n._parser.setEscHandler("|",(function(){return n.setgLevel(3)})),n._parser.setEscHandler("}",(function(){return n.setgLevel(2)})),n._parser.setEscHandler("~",(function(){return n.setgLevel(1)})),n._parser.setEscHandler("%@",(function(){return n.selectDefaultCharset()})),n._parser.setEscHandler("%G",(function(){return n.selectDefaultCharset()}));var r,i=this;for(r in s.CHARSETS)!function(t){i._parser.setEscHandler("("+t,(function(){return n.selectCharset("("+t)})),i._parser.setEscHandler(")"+t,(function(){return n.selectCharset(")"+t)})),i._parser.setEscHandler("*"+t,(function(){return n.selectCharset("*"+t)})),i._parser.setEscHandler("+"+t,(function(){return n.selectCharset("+"+t)})),i._parser.setEscHandler("-"+t,(function(){return n.selectCharset("-"+t)})),i._parser.setEscHandler("."+t,(function(){return n.selectCharset("."+t)})),i._parser.setEscHandler("/"+t,(function(){return n.selectCharset("/"+t)}))}(r);return n._parser.setErrorHandler((function(t){return n._terminal.error("Parsing error: ",t),t})),n._parser.setDcsHandler("$q",new _(n._terminal)),n}n.InputHandler=i},{"./CharWidth":5,"./EscapeSequenceParser":8,"./common/EventEmitter2":23,"./common/Lifecycle":24,"./common/TypedArrayUtils":26,"./common/data/EscapeSequences":28,"./core/buffer/BufferLine":29,"./core/data/Charsets":32,"./core/input/TextDecoder":34}],10:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("./MouseZoneManager"),i=t("./CharWidth"),o=t("./common/EventEmitter2");Object.defineProperty(s.prototype,"onLinkHover",{get:function(){return this._onLinkHover.event},enumerable:!0,configurable:!0}),Object.defineProperty(s.prototype,"onLinkLeave",{get:function(){return this._onLinkLeave.event},enumerable:!0,configurable:!0}),Object.defineProperty(s.prototype,"onLinkTooltip",{get:function(){return this._onLinkTooltip.event},enumerable:!0,configurable:!0}),s.prototype.attachToDom=function(t){this._mouseZoneManager=t},s.prototype.linkifyRows=function(t,e){var n=this;this._mouseZoneManager&&(null===this._rowsToLinkify.start?(this._rowsToLinkify.start=t,this._rowsToLinkify.end=e):(this._rowsToLinkify.start=Math.min(this._rowsToLinkify.start,t),this._rowsToLinkify.end=Math.max(this._rowsToLinkify.end,e)),this._mouseZoneManager.clearAll(t,e),this._rowsTimeoutId&&clearTimeout(this._rowsTimeoutId),this._rowsTimeoutId=setTimeout((function(){return n._linkifyRows()}),s.TIME_BEFORE_LINKIFY))},s.prototype._linkifyRows=function(){this._rowsTimeoutId=null;var t=(n=this._terminal.buffer).ydisp+this._rowsToLinkify.start;if(!(t>=n.lines.length)){for(var e=n.ydisp+Math.min(this._rowsToLinkify.end,this._terminal.rows)+1,n=Math.ceil(s.OVERSCAN_CHAR_LIMIT/this._terminal.cols),r=this._terminal.buffer.iterator(!1,t,e,n,n);r.hasNext();)for(var i=r.next(),o=0;o>9&511),n.validationCallback?n.validationCallback(l,(function(t){i._rowsTimeoutId||t&&i._addLink(c[1],c[0]-i._terminal.buffer.ydisp,l,n,h)})):a._addLink(c[1],c[0]-a._terminal.buffer.ydisp,l,n,h)}(););},s.prototype._addLink=function(t,e,n,o,s){var a=this,l=i.getStringCellWidth(n),c=t%this._terminal.cols,h=e+Math.floor(t/this._terminal.cols),u=(c+l)%this._terminal.cols,f=h+Math.floor((c+l)/this._terminal.cols);0===u&&(u=this._terminal.cols,f--),this._mouseZoneManager.add(new r.MouseZone(1+c,h+1,u+1,f+1,(function(t){if(o.handler)return o.handler(t,n);window.open(n,"_blank")}),(function(){a._onLinkHover.fire(a._createLinkHoverEvent(c,h,u,f,s)),a._terminal.element.classList.add("xterm-cursor-pointer")}),(function(t){a._onLinkTooltip.fire(a._createLinkHoverEvent(c,h,u,f,s)),o.hoverTooltipCallback&&o.hoverTooltipCallback(t,n)}),(function(){a._onLinkLeave.fire(a._createLinkHoverEvent(c,h,u,f,s)),a._terminal.element.classList.remove("xterm-cursor-pointer"),o.hoverLeaveCallback&&o.hoverLeaveCallback()}),(function(t){return!o.willLinkActivate||o.willLinkActivate(t,n)})))},s.prototype._createLinkHoverEvent=function(t,e,n,r,i){return{x1:t,y1:e,x2:n,y2:r,cols:this._terminal.cols,fg:i}},s.TIME_BEFORE_LINKIFY=200,s.OVERSCAN_CHAR_LIMIT=2e3,t=s;function s(t){this._terminal=t,this._linkMatchers=[],this._nextLinkMatcherId=0,this._onLinkHover=new o.EventEmitter2,this._onLinkLeave=new o.EventEmitter2,this._onLinkTooltip=new o.EventEmitter2,this._rowsToLinkify={start:null,end:null}}n.Linkifier=t},{"./CharWidth":5,"./MouseZoneManager":12,"./common/EventEmitter2":23}],11:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=(i.getCoordsRelativeToElement=function(t,e){return e=e.getBoundingClientRect(),[t.clientX-e.left,t.clientY-e.top]},i.prototype.getCoords=function(t,e,n,r,o,s){return n.width&&n.height&&(e=i.getCoordsRelativeToElement(t,e))?(e[0]=Math.ceil((e[0]+(s?this._renderCoordinator.dimensions.actualCellWidth/2:0))/this._renderCoordinator.dimensions.actualCellWidth),e[1]=Math.ceil(e[1]/this._renderCoordinator.dimensions.actualCellHeight),e[0]=Math.min(Math.max(e[0],1),r+(s?1:0)),e[1]=Math.min(Math.max(e[1],1),o),e):null},i.prototype.getRawByteCoords=function(t,e,n,r,i){return i=(r=this.getCoords(t,e,n,r,i))[0],r=r[1],{x:i+=32,y:r+=32}},i);function i(t){this._renderCoordinator=t}n.MouseHelper=r},{}],12:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o,s=t("./common/Lifecycle"),a=t("./ui/Lifecycle");i(l,o=s.Disposable),l.prototype.dispose=function(){o.prototype.dispose.call(this),this._deactivate()},l.prototype.add=function(t){this._zones.push(t),1===this._zones.length&&this._activate()},l.prototype.clearAll=function(t,e){if(0!==this._zones.length){e||(t=0,e=this._terminal.rows-1);for(var n=0;nt&&r.y1<=e+1||r.y2>t&&r.y2<=e+1||r.y1e+1)&&(this._currentZone&&this._currentZone===r&&(this._currentZone.leaveCallback(),this._currentZone=null),this._zones.splice(n--,1))}0===this._zones.length&&this._deactivate()}},l.prototype._activate=function(){this._areZonesActive||(this._areZonesActive=!0,this._terminal.element.addEventListener("mousemove",this._mouseMoveListener),this._terminal.element.addEventListener("mouseleave",this._mouseLeaveListener),this._terminal.element.addEventListener("click",this._clickListener))},l.prototype._deactivate=function(){this._areZonesActive&&(this._areZonesActive=!1,this._terminal.element.removeEventListener("mousemove",this._mouseMoveListener),this._terminal.element.removeEventListener("mouseleave",this._mouseLeaveListener),this._terminal.element.removeEventListener("click",this._clickListener))},l.prototype._onMouseMove=function(t){this._lastHoverCoords[0]===t.pageX&&this._lastHoverCoords[1]===t.pageY||(this._onHover(t),this._lastHoverCoords=[t.pageX,t.pageY])},l.prototype._onHover=function(t){var e=this,n=this._findZoneEventAt(t);n!==this._currentZone&&(this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=null,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout)),n&&((this._currentZone=n).hoverCallback&&n.hoverCallback(t),this._tooltipTimeout=setTimeout((function(){return e._onTooltip(t)}),500)))},l.prototype._onTooltip=function(t){this._tooltipTimeout=null;var e=this._findZoneEventAt(t);e&&e.tooltipCallback&&e.tooltipCallback(t)},l.prototype._onMouseDown=function(t){var e;this._initialSelectionLength=this._terminal.getSelection().length,!this._areZonesActive||(e=this._findZoneEventAt(t))&&e.willLinkActivate(t)&&(t.preventDefault(),t.stopImmediatePropagation())},l.prototype._onMouseLeave=function(t){this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=null,this._tooltipTimeout&&clearTimeout(this._tooltipTimeout))},l.prototype._onClick=function(t){var e=this._findZoneEventAt(t),n=this._terminal.getSelection().length;e&&n===this._initialSelectionLength&&(e.clickCallback(t),t.preventDefault(),t.stopImmediatePropagation())},l.prototype._findZoneEventAt=function(t){if(!(t=this._terminal.mouseHelper.getCoords(t,this._terminal.screenElement,this._terminal.charMeasure,this._terminal.cols,this._terminal.rows)))return null;for(var e=t[0],n=t[1],r=0;r=i.x1&&e=i.x1||n===i.y2&&ei.y1&&ne[1]&&t[1]=e[0]&&t[0]=e[0]},h.prototype.selectWordAtCursor=function(t){(t=this._getMouseBufferCoords(t))&&(this._selectWordAt(t,!1),this._model.selectionEnd=null,this.refresh(!0))},h.prototype.selectAll=function(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()},h.prototype.selectLines=function(t,e){this._model.clearSelection(),t=Math.max(t,0),e=Math.min(e,this._terminal.buffer.lines.length-1),this._model.selectionStart=[0,t],this._model.selectionEnd=[this._terminal.cols,e],this.refresh(),this._onSelectionChange.fire()},h.prototype._onTrim=function(t){this._model.onTrim(t)&&this.refresh()},h.prototype._getMouseBufferCoords=function(t){return(t=this._terminal.mouseHelper.getCoords(t,this._terminal.screenElement,this._charMeasure,this._terminal.cols,this._terminal.rows,!0))?(t[0]--,t[1]--,t[1]+=this._terminal.buffer.ydisp,t):null},h.prototype._getMouseEventScrollAmount=function(t){var e=r.MouseHelper.getCoordsRelativeToElement(t,this._terminal.screenElement)[1];t=this._terminal.rows*Math.ceil(this._charMeasure.height*this._terminal.options.lineHeight);return 0<=e&&e<=t?0:(t=this._model.selectionStart[0]||0===t.hasWidth(this._model.selectionStart[0])&&this._model.selectionStart[0]++))},h.prototype._onDoubleClick=function(t){(t=this._getMouseBufferCoords(t))&&(this._activeSelectionMode=1,this._selectWordAt(t,!0))},h.prototype._onTripleClick=function(t){(t=this._getMouseBufferCoords(t))&&(this._activeSelectionMode=2,this._selectLineAt(t[1]))},h.prototype.shouldColumnSelect=function(t){return t.altKey&&!(i.isMac&&this._terminal.options.macOptionClickForcesSelection)},h.prototype._onMouseMove=function(t){t.stopImmediatePropagation();var e=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;this._model.selectionEnd=this._getMouseBufferCoords(t),this._model.selectionEnd?(2===this._activeSelectionMode?this._model.selectionEnd[1]=r;r++){var i=t.loadCell(r,this._workCell).getChars().length;0===this._workCell.getWidth()?n--:1=this._terminal.cols)return null;var i=this._buffer.lines.get(t[1]);if(!i)return null;var o=this._buffer.translateBufferLineToString(t[1],!1),s=this._convertViewportColToCharacterIndex(i,t),a=s,l=t[0]-s,c=0,h=0,u=0,f=0;if(" "===o.charAt(s)){for(;0this._terminal.cols;)e.length-=this._terminal.cols,n++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?e.start:e.start+e.length,n]}},h.prototype._isCharWordSeparator=function(t){return 0!==t.getWidth()&&0<=" ()[]{}'\"".indexOf(t.getChars())},h.prototype._selectLineAt=function(t){t=this._buffer.getWrappedRangeForLine(t),this._model.selectionStart=[0,t.first],this._model.selectionEnd=[this._terminal.cols,t.last],this._model.selectionStartLength=0},t=h;function h(t,e){this._terminal=t,this._charMeasure=e,this._enabled=!0,this._workCell=new a.CellData,this._onLinuxMouseSelection=new l.EventEmitter2,this._onRedrawRequest=new l.EventEmitter2,this._onSelectionChange=new l.EventEmitter2,this._initListeners(),this.enable(),this._model=new o.SelectionModel(t),this._activeSelectionMode=0}n.SelectionManager=t},{"./MouseHelper":11,"./SelectionModel":14,"./common/EventEmitter2":23,"./common/Platform":25,"./core/buffer/BufferLine":29,"./handlers/AltClickHandler":35}],14:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=(i.prototype.clearSelection=function(){this.selectionStart=null,this.selectionEnd=null,this.isSelectAllActive=!1,this.selectionStartLength=0},Object.defineProperty(i.prototype,"finalSelectionStart",{get:function(){return this.isSelectAllActive?[0,0]:this.selectionEnd&&this.selectionStart&&this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"finalSelectionEnd",{get:function(){if(this.isSelectAllActive)return[this._terminal.cols,this._terminal.buffer.ybase+this._terminal.rows-1];if(!this.selectionStart)return null;if(this.selectionEnd&&!this.areSelectionValuesReversed())return this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]?[Math.max(this.selectionStart[0]+this.selectionStartLength,this.selectionEnd[0]),this.selectionEnd[1]]:this.selectionEnd;var t=this.selectionStart[0]+this.selectionStartLength;return t>this._terminal.cols?[t%this._terminal.cols,this.selectionStart[1]+Math.floor(t/this._terminal.cols)]:[t,this.selectionStart[1]]},enumerable:!0,configurable:!0}),i.prototype.areSelectionValuesReversed=function(){var t=this.selectionStart,e=this.selectionEnd;return!(!t||!e)&&(t[1]>e[1]||t[1]===e[1]&&t[0]>e[0])},i.prototype.onTrim=function(t){return this.selectionStart&&(this.selectionStart[1]-=t),this.selectionEnd&&(this.selectionEnd[1]-=t),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)},i);function i(t){this._terminal=t,this.clearSelection()}n.SelectionModel=r},{}],15:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.DEFAULT_BELL_SOUND="data:audio/wav;base64,UklGRigBAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQQBAADpAFgCwAMlBZoG/wdmCcoKRAypDQ8PbRDBEQQTOxRtFYcWlBePGIUZXhoiG88bcBz7HHIdzh0WHlMeZx51HmkeUx4WHs8dah0AHXwc3hs9G4saxRnyGBIYGBcQFv8U4RPAEoYRQBACD70NWwwHC6gJOwjWBloF7gOBAhABkf8b/qv8R/ve+Xf4Ife79W/0JfPZ8Z/wde9N7ijtE+wU6xvqM+lb6H7nw+YX5mrlxuQz5Mzje+Ma49fioeKD4nXiYeJy4pHitOL04j/jn+MN5IPkFOWs5U3mDefM55/ogOl36m7rdOyE7abuyu8D8Unyj/Pg9D/2qfcb+Yn6/vuK/Qj/lAAlAg==";var r=(Object.defineProperty(i,"audioContext",{get:function(){if(!i._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;i._audioContext=new t}return i._audioContext},enumerable:!0,configurable:!0}),i.prototype.playBellSound=function(){var t,e=i.audioContext;e&&(t=e.createBufferSource(),e.decodeAudioData(this._base64ToArrayBuffer(this._removeMimeType(this._terminal.options.bellSound)),(function(n){t.buffer=n,t.connect(e.destination),t.start(0)})))},i.prototype._base64ToArrayBuffer=function(t){for(var e=window.atob(t),n=e.length,r=new Uint8Array(n),i=0;ir&&(n=this.buffer.lines.length-r,r=this.buffer.ydisp-n<0,this.buffer.lines.trimStart(n),this.buffer.ybase=Math.max(this.buffer.ybase-n,0),this.buffer.ydisp=Math.max(this.buffer.ydisp-n,0),r&&this.refresh(0,this.rows-1)))}switch(this.options[t]=e,t){case"fontFamily":case"fontSize":this._renderCoordinator&&(this._renderCoordinator.clear(),this.charMeasure.measure(this.options));break;case"drawBoldTextInBrightColors":case"experimentalCharAtlas":case"enableBold":case"letterSpacing":case"lineHeight":case"fontWeight":case"fontWeightBold":this._renderCoordinator&&(this._renderCoordinator.clear(),this._renderCoordinator.onResize(this.cols,this.rows),this.refresh(0,this.rows-1));break;case"rendererType":this._renderCoordinator&&this._renderCoordinator.setRenderer(this._createRenderer());break;case"scrollback":this.buffers.resize(this.cols,this.rows),this.viewport&&this.viewport.syncScrollArea();break;case"screenReaderMode":e?!this._accessibilityManager&&this._renderCoordinator&&(this._accessibilityManager=new E.AccessibilityManager(this,this._renderCoordinator.dimensions)):this._accessibilityManager&&(this._accessibilityManager.dispose(),this._accessibilityManager=null);break;case"tabStopWidth":this.buffers.setupTabStops();break;case"windowsMode":e?this._windowsMode||(this._windowsMode=M.applyWindowsMode(this)):this._windowsMode&&(this._windowsMode.dispose(),this._windowsMode=void 0)}this._renderCoordinator&&this._renderCoordinator.onOptionsChanged()}},H.prototype._onTextAreaFocus=function(t){this.sendFocus&&this.handler(f.C0.ESC+"[I"),this.updateCursorStyle(t),this.element.classList.add("focus"),this.showCursor(),this.emit("focus")},H.prototype.blur=function(){return this.textarea.blur()},H.prototype._onTextAreaBlur=function(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this.sendFocus&&this.handler(f.C0.ESC+"[O"),this.element.classList.remove("focus"),this.emit("blur")},H.prototype._initGlobal=function(){var t=this;function e(e){return u.pasteHandler(e,t)}this._bindKeys(),this.register(C.addDisposableDomListener(this.element,"copy",(function(e){t.hasSelection()&&u.copyHandler(e,t,t.selectionManager)}))),this.register(C.addDisposableDomListener(this.textarea,"paste",e)),this.register(C.addDisposableDomListener(this.element,"paste",e)),y.isFirefox?this.register(C.addDisposableDomListener(this.element,"mousedown",(function(e){2===e.button&&u.rightClickHandler(e,t,t.selectionManager,t.options.rightClickSelectsWord)}))):this.register(C.addDisposableDomListener(this.element,"contextmenu",(function(e){u.rightClickHandler(e,t,t.selectionManager,t.options.rightClickSelectsWord)}))),y.isLinux&&this.register(C.addDisposableDomListener(this.element,"auxclick",(function(e){1===e.button&&u.moveTextAreaUnderMouseCursor(e,t)})))},H.prototype._bindKeys=function(){var t=this,e=this;this.register(C.addDisposableDomListener(this.element,"keydown",(function(t){O.activeElement===this&&e._keyDown(t)}),!0)),this.register(C.addDisposableDomListener(this.element,"keypress",(function(t){O.activeElement===this&&e._keyPress(t)}),!0)),this.register(C.addDisposableDomListener(this.element,"keyup",(function(n){var r;16!==(r=n).keyCode&&17!==r.keyCode&&18!==r.keyCode&&t.focus(),e._keyUp(n)}),!0)),this.register(C.addDisposableDomListener(this.textarea,"keydown",(function(e){return t._keyDown(e)}),!0)),this.register(C.addDisposableDomListener(this.textarea,"keypress",(function(e){return t._keyPress(e)}),!0)),this.register(C.addDisposableDomListener(this.textarea,"compositionstart",(function(){return t._compositionHelper.compositionstart()}))),this.register(C.addDisposableDomListener(this.textarea,"compositionupdate",(function(e){return t._compositionHelper.compositionupdate(e)}))),this.register(C.addDisposableDomListener(this.textarea,"compositionend",(function(){return t._compositionHelper.compositionend()}))),this.register(this.onRender((function(){return t._compositionHelper.updateCompositionElements()}))),this.register(this.onRender((function(e){return t._queueLinkification(e.start,e.end)})))},H.prototype.open=function(t){var e=this;if(this._parent=t||this._parent,!this._parent)throw new Error("Terminal requires a parent element.");this._context=this._parent.ownerDocument.defaultView,this._document=this._parent.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"),this._parent.appendChild(this.element),t=O.createDocumentFragment(),this._viewportElement=O.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),t.appendChild(this._viewportElement),this._viewportScrollArea=O.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=O.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=O.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),t.appendChild(this.screenElement),this._mouseZoneManager=new S.MouseZoneManager(this),this.register(this._mouseZoneManager),this.register(this.onScroll((function(){return e._mouseZoneManager.clearAll()}))),this.linkifier.attachToDom(this._mouseZoneManager),this.textarea=O.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",b.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(C.addDisposableDomListener(this.textarea,"focus",(function(t){return e._onTextAreaFocus(t)}))),this.register(C.addDisposableDomListener(this.textarea,"blur",(function(){return e._onTextAreaBlur()}))),this._helperContainer.appendChild(this.textarea),this._compositionView=O.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=new l.CompositionHelper(this.textarea,this._compositionView,this),this._helperContainer.appendChild(this._compositionView),this.charMeasure=new g.CharMeasure(O,this._helperContainer),this.element.appendChild(t),this._theme=this.options.theme,this._colorManager=new D.ColorManager(O,this.options.allowTransparency),this._colorManager.setTheme(this._theme),t=this._createRenderer(),this._renderCoordinator=new B.RenderCoordinator(t,this.rows,this.screenElement),this._renderCoordinator.onRender((function(t){return e._onRender.fire(t)})),this.onResize((function(t){return e._renderCoordinator.resize(t.cols,t.rows)})),this.viewport=new h.Viewport(this,this._viewportElement,this._viewportScrollArea,this.charMeasure,this._renderCoordinator.dimensions),this.viewport.onThemeChange(this._colorManager.colors),this.register(this.viewport),this.register(this.onCursorMove((function(){return e._renderCoordinator.onCursorMove()}))),this.register(this.onResize((function(){return e._renderCoordinator.onResize(e.cols,e.rows)}))),this.register(this.addDisposableListener("blur",(function(){return e._renderCoordinator.onBlur()}))),this.register(this.addDisposableListener("focus",(function(){return e._renderCoordinator.onFocus()}))),this.register(this.charMeasure.onCharSizeChanged((function(){return e._renderCoordinator.onCharSizeChanged()}))),this.register(this._renderCoordinator.onDimensionsChange((function(){return e.viewport.syncScrollArea()}))),this.selectionManager=new m.SelectionManager(this,this.charMeasure),this.register(this.selectionManager.onSelectionChange((function(){return e._onSelectionChange.fire()}))),this.register(C.addDisposableDomListener(this.element,"mousedown",(function(t){return e.selectionManager.onMouseDown(t)}))),this.register(this.selectionManager.onRedrawRequest((function(t){return e._renderCoordinator.onSelectionChanged(t.start,t.end,t.columnSelectMode)}))),this.register(this.selectionManager.onLinuxMouseSelection((function(t){e.textarea.value=t,e.textarea.focus(),e.textarea.select()}))),this.register(this.onScroll((function(){e.viewport.syncScrollArea(),e.selectionManager.refresh()}))),this.register(C.addDisposableDomListener(this._viewportElement,"scroll",(function(){return e.selectionManager.refresh()}))),this.mouseHelper=new v.MouseHelper(this._renderCoordinator),this.element.classList.toggle("enable-mouse-events",this.mouseEvents),this.mouseEvents?this.selectionManager.disable():this.selectionManager.enable(),this.options.screenReaderMode&&(this._accessibilityManager=new E.AccessibilityManager(this,this._renderCoordinator.dimensions),this._accessibilityManager.register(this._renderCoordinator.onDimensionsChange((function(t){return e._accessibilityManager.setDimensions(t)})))),this.charMeasure.measure(this.options),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()},H.prototype._createRenderer=function(){switch(this.options.rendererType){case"canvas":return new d.Renderer(this,this._colorManager.colors);case"dom":return new x.DomRenderer(this,this._colorManager.colors);default:throw new Error('Unrecognized rendererType "'+this.options.rendererType+'"')}},H.prototype._setTheme=function(t){this._theme=t,this._colorManager&&this._colorManager.setTheme(t),this._renderCoordinator&&this._renderCoordinator.setColors(this._colorManager.colors),this.viewport&&this.viewport.onThemeChange(this._colorManager.colors)},H.prototype.bindMouse=function(){var t=this,e=this.element,n=this,r=32;function i(t){var e=function(t){var e,r,i;switch(t.overrideType||t.type){case"mousedown":e=null!==t.button&&void 0!==t.button?+t.button:null!==t.which&&void 0!==t.which?t.which-1:null,y.isMSIE&&(e=1===e?0:4===e?1:e);break;case"mouseup":e=3;break;case"DOMMouseScroll":e=t.detail<0?64:65;break;case"wheel":e=t.deltaY<0?64:65}return i=(t.shiftKey?4:0)|(i=t.metaKey?8:0)|(r=t.ctrlKey?16:0),n.vt200Mouse?i&=r:n.normalMouse||(i=0),32+(i<<2)+e}(t),i=n.mouseHelper.getRawByteCoords(t,n.screenElement,n.charMeasure,n.cols,n.rows);if(i)switch(s(e,i),t.overrideType||t.type){case"mousedown":r=e;break;case"mouseup":r=32}}function o(t,e){n.utfMouse?2047=this.buffer.ybase&&(this._userScrolling=!1);var n=this.buffer.ydisp;this.buffer.ydisp=Math.max(Math.min(this.buffer.ydisp+t,this.buffer.ybase),0),n!==this.buffer.ydisp&&(e||this._onScroll.fire(this.buffer.ydisp),this.refresh(0,this.rows-1))},H.prototype.scrollPages=function(t){this.scrollLines(t*(this.rows-1))},H.prototype.scrollToTop=function(){this.scrollLines(-this.buffer.ydisp)},H.prototype.scrollToBottom=function(){this.scrollLines(this.buffer.ybase-this.buffer.ydisp)},H.prototype.scrollToLine=function(t){0!=(t-=this.buffer.ydisp)&&this.scrollLines(t)},H.prototype.writeUtf8=function(t){var e=this;this._isDisposed||t&&(this.writeBufferUtf8.push(t),this.options.useFlowControl&&!this._xoffSentToCatchUp&&5<=this.writeBufferUtf8.length&&(this.handler(f.C0.DC3),this._xoffSentToCatchUp=!0),!this._writeInProgress&&0t;){var r=this.writeBufferUtf8[t];if(t++,this._xoffSentToCatchUp&&this.writeBufferUtf8.length===t&&(this.handler(f.C0.DC1),this._xoffSentToCatchUp=!1),this._refreshStart=this.buffer.y,this._refreshEnd=this.buffer.y,this._inputHandler.parseUtf8(r),this.updateRange(this.buffer.y),this.refresh(this._refreshStart,this._refreshEnd),12<=Date.now()-n)break}this.writeBufferUtf8.length>t?(50t;){var r=this.writeBuffer[t];if(t++,this._xoffSentToCatchUp&&this.writeBuffer.length===t&&(this.handler(f.C0.DC1),this._xoffSentToCatchUp=!1),this._refreshStart=this.buffer.y,this._refreshEnd=this.buffer.y,this._inputHandler.parse(r),this.updateRange(this.buffer.y),this.refresh(this._refreshStart,this._refreshEnd),12<=Date.now()-n)break}this.writeBuffer.length>t?(50this._refreshEnd&&(this._refreshEnd=t)},H.prototype.maxRange=function(){this._refreshStart=0,this._refreshEnd=this.rows-1},H.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 t=1;tthis.buffer.scrollBottom&&(this.buffer.y--,this.scroll()),this.buffer.x>=this.cols&&this.buffer.x--},H.prototype.reverseIndex=function(){var t;this.buffer.y===this.buffer.scrollTop?(t=this.buffer.scrollBottom-this.buffer.scrollTop,this.buffer.lines.shiftElements(this.buffer.y+this.buffer.ybase,t,1),this.buffer.lines.set(this.buffer.y+this.buffer.ybase,this.buffer.getBlankLine(this.eraseAttrData())),this.updateRange(this.buffer.scrollTop),this.updateRange(this.buffer.scrollBottom)):this.buffer.y--},H.prototype.reset=function(){this.options.rows=this.rows,this.options.cols=this.cols;var t=this._customKeyEventHandler,e=this._inputHandler,n=this.cursorState,r=this.writeBuffer,i=this.writeBufferUtf8,o=this._writeInProgress,s=this._xoffSentToCatchUp,a=this._userScrolling;this._setup(),this._customKeyEventHandler=t,this._inputHandler=e,this.cursorState=n,this.writeBuffer=r,this.writeBufferUtf8=i,this._writeInProgress=o,this._xoffSentToCatchUp=s,this._userScrolling=a,this.refresh(0,this.rows-1),this.viewport&&this.viewport.syncScrollArea()},H.prototype.tabSet=function(){this.buffer.tabs[this.buffer.x]=!0},H.prototype.cancel=function(t,e){if(this.options.cancelEvents||e)return t.preventDefault(),t.stopPropagation(),!1},H.prototype._visualBell=function(){return!1},H.prototype._soundBell=function(){return"sound"===this.options.bellStyle},i=H;function H(t){void 0===t&&(t={});var e=o.call(this)||this;return e.browser=y,e._blankLine=null,e._onCursorMove=new T.EventEmitter2,e._onData=new T.EventEmitter2,e._onKey=new T.EventEmitter2,e._onLineFeed=new T.EventEmitter2,e._onRender=new T.EventEmitter2,e._onResize=new T.EventEmitter2,e._onScroll=new T.EventEmitter2,e._onSelectionChange=new T.EventEmitter2,e._onTitleChange=new T.EventEmitter2,e.options=L.clone(t),e._setup(),e.onCursorMove((function(){return e.emit("cursormove")})),e.onData((function(t){return e.emit("data",t)})),e.onKey((function(t){return e.emit("key",t.key,t.domEvent)})),e.onLineFeed((function(){return e.emit("linefeed")})),e.onRender((function(t){return e.emit("refresh",t)})),e.onResize((function(t){return e.emit("resize",t)})),e.onSelectionChange((function(){return e.emit("selection")})),e.onScroll((function(t){return e.emit("scroll",t)})),e.onTitleChange((function(t){return e.emit("title",t)})),e}n.Terminal=i},{"./AccessibilityManager":1,"./Buffer":2,"./BufferSet":3,"./CharMeasure":4,"./Clipboard":6,"./CompositionHelper":7,"./InputHandler":9,"./Linkifier":10,"./MouseHelper":11,"./MouseZoneManager":12,"./SelectionManager":13,"./SoundManager":15,"./Strings":16,"./Viewport":18,"./WindowsMode":19,"./common/Clone":21,"./common/EventEmitter":22,"./common/EventEmitter2":23,"./common/Platform":25,"./common/data/EscapeSequences":28,"./core/buffer/BufferLine":29,"./core/input/Keyboard":33,"./renderer/RenderCoordinator":43,"./renderer/Renderer":44,"./renderer/atlas/CharAtlasCache":48,"./renderer/dom/DomRenderer":56,"./ui/ColorManager":58,"./ui/Lifecycle":59}],18:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o,s=t("./common/Lifecycle"),a=t("./ui/Lifecycle");i(l,o=s.Disposable),l.prototype.onDimensionsChance=function(t){this._dimensions=t},l.prototype.onThemeChange=function(t){this._viewportElement.style.backgroundColor=t.background.css},l.prototype._refresh=function(){var t=this;null===this._refreshAnimationFrame&&(this._refreshAnimationFrame=requestAnimationFrame((function(){return t._innerRefresh()})))},l.prototype._innerRefresh=function(){0this._length)for(var e=this._length;ethis._maxLength?(o=this._length+n.length-this._maxLength,this._startIndex+=o,this._length=this._maxLength,this.onTrimEmitter.fire(o)):this._length+=n.length},i.prototype.trimStart=function(t){t>this._length&&(t=this._length),this._startIndex+=t,this._length-=t,this.onTrimEmitter.fire(t)},i.prototype.shiftElements=function(t,e,n){if(!(e<=0)){if(t<0||t>=this._length)throw new Error("start argument out of range");if(t+n<0)throw new Error("Cannot shift elements in list beyond index 0");if(0this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(r=0;r=t.length)return t;n=(t.length+n)%t.length,r=r>=t.length?t.length:(t.length+r)%t.length;for(var i=n;i>>16&255,t>>>8&255,255&t]},s.fromColorRGB=function(t){return(255&t[0])<<16|(255&t[1])<<8|255&t[2]},s.prototype.clone=function(){var t=new s;return t.fg=this.fg,t.bg=this.bg,t},s.prototype.isInverse=function(){return 67108864&this.fg},s.prototype.isBold=function(){return 134217728&this.fg},s.prototype.isUnderline=function(){return 268435456&this.fg},s.prototype.isBlink=function(){return 536870912&this.fg},s.prototype.isInvisible=function(){return 1073741824&this.fg},s.prototype.isItalic=function(){return 67108864&this.bg},s.prototype.isDim=function(){return 134217728&this.bg},s.prototype.getFgColorMode=function(){return 50331648&this.fg},s.prototype.getBgColorMode=function(){return 50331648&this.bg},s.prototype.isFgRGB=function(){return 50331648==(50331648&this.fg)},s.prototype.isBgRGB=function(){return 50331648==(50331648&this.bg)},s.prototype.isFgPalette=function(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)},s.prototype.isBgPalette=function(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)},s.prototype.isFgDefault=function(){return 0==(50331648&this.fg)},s.prototype.isBgDefault=function(){return 0==(50331648&this.bg)},s.prototype.getFgColor=function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}},s.prototype.getBgColor=function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}},t=s,n.AttributeData=t,n.DEFAULT_ATTR_DATA=Object.freeze(new t);var a,l=(i(c,a=t),c.fromCharData=function(t){var e=new c;return e.setFromCharData(t),e},c.prototype.isCombined=function(){return 2097152&this.content},c.prototype.getWidth=function(){return this.content>>22},c.prototype.getChars=function(){return 2097152&this.content?this.combinedData:2097151&this.content?o.stringFromCodePoint(2097151&this.content):""},c.prototype.getCode=function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content},c.prototype.setFromCharData=function(t){this.fg=t[n.CHAR_DATA_ATTR_INDEX],this.bg=0;var e,r,i=!1;2>22,2097152&e?this._combined[t].charCodeAt(this._combined[t].length-1):n]},h.prototype.set=function(t,e){this._data[3*t+1]=e[n.CHAR_DATA_ATTR_INDEX],1>22},h.prototype.hasWidth=function(t){return 12582912&this._data[3*t+0]},h.prototype.getFg=function(t){return this._data[3*t+1]},h.prototype.getBg=function(t){return this._data[3*t+2]},h.prototype.hasContent=function(t){return 4194303&this._data[3*t+0]},h.prototype.getCodePoint=function(t){var e=this._data[3*t+0];return 2097152&e?this._combined[t].charCodeAt(this._combined[t].length-1):2097151&e},h.prototype.isCombined=function(t){return 2097152&this._data[3*t+0]},h.prototype.getString=function(t){var e=this._data[3*t+0];return 2097152&e?this._combined[t]:2097151&e?o.stringFromCodePoint(2097151&e):""},h.prototype.loadCell=function(t,e){var n=3*t;return e.content=this._data[0+n],e.fg=this._data[1+n],e.bg=this._data[2+n],2097152&e.content&&(e.combinedData=this._combined[t]),e},h.prototype.setCell=function(t,e){2097152&e.content&&(this._combined[t]=e.combinedData),this._data[3*t+0]=e.content,this._data[3*t+1]=e.fg,this._data[3*t+2]=e.bg},h.prototype.setCellFromCodePoint=function(t,e,n,r,i){this._data[3*t+0]=e|n<<22,this._data[3*t+1]=r,this._data[3*t+2]=i},h.prototype.addCodepointToCell=function(t,e){var n=this._data[3*t+0];2097152&n?this._combined[t]+=o.stringFromCodePoint(e):(2097151&n?(this._combined[t]=o.stringFromCodePoint(2097151&n)+o.stringFromCodePoint(e),n&=-2097152,n|=2097152):n=e|1<<22,this._data[3*t+0]=n)},h.prototype.insertCells=function(t,e,n){if(t%=this.length,ethis.length){var n=new Uint32Array(3*t);this.length&&(3*t>22);return 0},h.prototype.copyCellsFrom=function(t,e,n,r,i){var o=t._data;if(i)for(var s=r-1;0<=s;s--)for(var a=0;a<3;a++)this._data[3*(n+s)+a]=o[3*(e+s)+a];else for(s=0;s>22||1}return i},t=h,n.BufferLine=t},{"../../common/Types":27,"../input/TextDecoder":34}],30:[function(t,e,n){"use strict";function r(t,e,n){if(e===t.length-1)return t[e].getTrimmedLength();var r=!t[e].hasContent(n-1)&&1===t[e].getWidth(n-1);e=2===t[e+1].getWidth(0);return r&&e?n-1:n}Object.defineProperty(n,"__esModule",{value:!0}),n.reflowLargerGetLinesToRemove=function(t,e,n,i,o){for(var s=[],a=0;a"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};n.evaluateKeyboardEvent=function(t,e,n,o){var s,a={type:0,cancel:!1,key:void 0},l=(t.shiftKey?1:0)|(t.altKey?2:0)|(t.ctrlKey?4:0)|(t.metaKey?8:0);switch(t.keyCode){case 0:"UIKeyInputUpArrow"===t.key?a.key=e?r.C0.ESC+"OA":r.C0.ESC+"[A":"UIKeyInputLeftArrow"===t.key?a.key=e?r.C0.ESC+"OD":r.C0.ESC+"[D":"UIKeyInputRightArrow"===t.key?a.key=e?r.C0.ESC+"OC":r.C0.ESC+"[C":"UIKeyInputDownArrow"===t.key&&(a.key=e?r.C0.ESC+"OB":r.C0.ESC+"[B");break;case 8:if(t.shiftKey){a.key=r.C0.BS;break}if(t.altKey){a.key=r.C0.ESC+r.C0.DEL;break}a.key=r.C0.DEL;break;case 9:if(t.shiftKey){a.key=r.C0.ESC+"[Z";break}a.key=r.C0.HT,a.cancel=!0;break;case 13:a.key=r.C0.CR,a.cancel=!0;break;case 27:a.key=r.C0.ESC,a.cancel=!0;break;case 37:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"D",a.key===r.C0.ESC+"[1;3D"&&(a.key=n?r.C0.ESC+"b":r.C0.ESC+"[1;5D")):a.key=e?r.C0.ESC+"OD":r.C0.ESC+"[D";break;case 39:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"C",a.key===r.C0.ESC+"[1;3C"&&(a.key=n?r.C0.ESC+"f":r.C0.ESC+"[1;5C")):a.key=e?r.C0.ESC+"OC":r.C0.ESC+"[C";break;case 38:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"A",a.key===r.C0.ESC+"[1;3A"&&(a.key=r.C0.ESC+"[1;5A")):a.key=e?r.C0.ESC+"OA":r.C0.ESC+"[A";break;case 40:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"B",a.key===r.C0.ESC+"[1;3B"&&(a.key=r.C0.ESC+"[1;5B")):a.key=e?r.C0.ESC+"OB":r.C0.ESC+"[B";break;case 45:t.shiftKey||t.ctrlKey||(a.key=r.C0.ESC+"[2~");break;case 46:a.key=l?r.C0.ESC+"[3;"+(1+l)+"~":r.C0.ESC+"[3~";break;case 36:a.key=l?r.C0.ESC+"[1;"+(1+l)+"H":e?r.C0.ESC+"OH":r.C0.ESC+"[H";break;case 35:a.key=l?r.C0.ESC+"[1;"+(1+l)+"F":e?r.C0.ESC+"OF":r.C0.ESC+"[F";break;case 33:t.shiftKey?a.type=2:a.key=r.C0.ESC+"[5~";break;case 34:t.shiftKey?a.type=3:a.key=r.C0.ESC+"[6~";break;case 112:a.key=l?r.C0.ESC+"[1;"+(1+l)+"P":r.C0.ESC+"OP";break;case 113:a.key=l?r.C0.ESC+"[1;"+(1+l)+"Q":r.C0.ESC+"OQ";break;case 114:a.key=l?r.C0.ESC+"[1;"+(1+l)+"R":r.C0.ESC+"OR";break;case 115:a.key=l?r.C0.ESC+"[1;"+(1+l)+"S":r.C0.ESC+"OS";break;case 116:a.key=l?r.C0.ESC+"[15;"+(1+l)+"~":r.C0.ESC+"[15~";break;case 117:a.key=l?r.C0.ESC+"[17;"+(1+l)+"~":r.C0.ESC+"[17~";break;case 118:a.key=l?r.C0.ESC+"[18;"+(1+l)+"~":r.C0.ESC+"[18~";break;case 119:a.key=l?r.C0.ESC+"[19;"+(1+l)+"~":r.C0.ESC+"[19~";break;case 120:a.key=l?r.C0.ESC+"[20;"+(1+l)+"~":r.C0.ESC+"[20~";break;case 121:a.key=l?r.C0.ESC+"[21;"+(1+l)+"~":r.C0.ESC+"[21~";break;case 122:a.key=l?r.C0.ESC+"[23;"+(1+l)+"~":r.C0.ESC+"[23~";break;case 123:a.key=l?r.C0.ESC+"[24;"+(1+l)+"~":r.C0.ESC+"[24~";break;default:!t.ctrlKey||t.shiftKey||t.altKey||t.metaKey?n&&!o||!t.altKey||t.metaKey?n&&!t.altKey&&!t.ctrlKey&&t.metaKey?65===t.keyCode&&(a.type=1):t.key&&!t.ctrlKey&&!t.altKey&&!t.metaKey&&48<=t.keyCode&&1===t.key.length?a.key=t.key:t.key&&t.ctrlKey&&"_"===t.key&&(a.key=r.C0.US):(s=(s=i[t.keyCode])&&s[t.shiftKey?1:0])?a.key=r.C0.ESC+s:65<=t.keyCode&&t.keyCode<=90&&(s=t.ctrlKey?t.keyCode-64:t.keyCode+32,a.key=r.C0.ESC+String.fromCharCode(s)):65<=t.keyCode&&t.keyCode<=90?a.key=String.fromCharCode(t.keyCode-64):32===t.keyCode?a.key=String.fromCharCode(0):51<=t.keyCode&&t.keyCode<=55?a.key=String.fromCharCode(t.keyCode-51+27):56===t.keyCode?a.key=String.fromCharCode(127):219===t.keyCode?a.key=String.fromCharCode(27):220===t.keyCode?a.key=String.fromCharCode(28):221===t.keyCode&&(a.key=String.fromCharCode(29))}return a}},{"../../common/data/EscapeSequences":28}],34:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.stringFromCodePoint=function(t){return 65535>10))+String.fromCharCode(t%1024+56320)):String.fromCharCode(t)},n.utf32ToString=function(t,e,n){void 0===n&&(n=t.length);for(var r="",i=e=void 0===e?0:e;i>10))+String.fromCharCode(o%1024+56320)):r+=String.fromCharCode(o)}return r};var r=(i.prototype.clear=function(){this._interim=0},i.prototype.decode=function(t,e){var n=t.length;if(!n)return 0;var r=0,i=0;this._interim&&(56320<=(s=t.charCodeAt(i++))&&s<=57343?e[r++]=1024*(this._interim-55296)+s-56320+65536:(e[r++]=this._interim,e[r++]=s),this._interim=0);for(var o=i;o=n)return this._interim=a,r;56320<=(s=t.charCodeAt(o))&&s<=57343?e[r++]=1024*(a-55296)+s-56320+65536:(e[r++]=a,e[r++]=s)}else e[r++]=a}return r},i);function i(){this._interim=0}function o(){this.interim=new Uint8Array(3)}n.StringToUtf32=r,o.prototype.clear=function(){this.interim.fill(0)},o.prototype.decode=function(t,e){var n=t.length;if(!n)return 0;var r,i,o,s,a=0,l=0,c=0;if(this.interim[0]){var h=!1,u=this.interim[0];u&=192==(224&u)?31:224==(240&u)?15:7;for(var f=0,p=void 0;(p=63&this.interim[++f])&&f<4;)u<<=6,u|=p;for(var d=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,_=d-f;c<_;){if(n<=c)return 0;if(128!=(192&(p=t[c++]))){c--,h=!0;break}u<<=6,u|=63&(this.interim[f++]=p)}h||(2==d?u<128?c--:e[a++]=u:3==d?u<2048||55296<=u&&u<=57343||(e[a++]=u):l<65536||1114111=this._endCol&&tthis._endRow?"A":"B"},i.prototype._bufferLine=function(t,e,n,r,i){for(var o=t,s=e,a="";o!==n||s!==r;)o+=i?1:-1,i&&o>this._terminal.cols-1?(a+=this._terminal.buffer.translateBufferLineToString(s,!1,t,o),t=o=0,s++):!i&&o<0&&(a+=this._terminal.buffer.translateBufferLineToString(s,!1,0,t+1),t=o=this._terminal.cols-1,s--);return a+this._terminal.buffer.translateBufferLineToString(s,!1,t,o)},i.prototype._sequence=function(t){var e=this._terminal.applicationCursor?"O":"[";return r.C0.ESC+e+t},t=i;function i(t,e){this._mouseEvent=t,this._terminal=e,this._lines=this._terminal.buffer.lines,this._startCol=this._terminal.buffer.x,this._startRow=this._terminal.buffer.y,(e=this._terminal.mouseHelper.getCoords(this._mouseEvent,this._terminal.element,this._terminal.charMeasure,this._terminal.cols,this._terminal.rows,!1))&&(e=e.map((function(t){return t-1})),this._endCol=e[0],this._endRow=e[1])}function o(t,e){t=Math.floor(t);for(var n="",r=0;r=this._line.length))return new u(this._line,t)},h.prototype.translateToString=function(t,e,n){return this._line.translateToString(t,e,n)},h);function h(t){this._line=t}var u=(Object.defineProperty(f.prototype,"char",{get:function(){return this._line.getString(this._x)},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"width",{get:function(){return this._line.getWidth(this._x)},enumerable:!0,configurable:!0}),f);function f(t,e){this._line=t,this._x=e}},{"../Strings":16,"../Terminal":17,"./AddonManager":36}],38:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("../common/Types"),i=t("./atlas/Types"),o=t("./atlas/CharAtlasCache"),s=t("../core/buffer/BufferLine");a.prototype.dispose=function(){this._container.removeChild(this._canvas),this._charAtlas&&this._charAtlas.dispose()},a.prototype._initCanvas=function(){this._ctx=this._canvas.getContext("2d",{alpha:this._alpha}),this._alpha||this.clearAll()},a.prototype.onOptionsChanged=function(t){},a.prototype.onBlur=function(t){},a.prototype.onFocus=function(t){},a.prototype.onCursorMove=function(t){},a.prototype.onGridChanged=function(t,e,n){},a.prototype.onSelectionChanged=function(t,e,n,r){void 0===r&&(r=!1)},a.prototype.setColors=function(t,e){this._refreshCharAtlas(t,e)},a.prototype.setTransparency=function(t,e){var n;e!==this._alpha&&(n=this._canvas,this._alpha=e,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,n),this._refreshCharAtlas(t,this._colors),this.onGridChanged(t,0,t.rows-1))},a.prototype._refreshCharAtlas=function(t,e){this._scaledCharWidth<=0&&this._scaledCharHeight<=0||(this._charAtlas=o.acquireCharAtlas(t,e,this._scaledCharWidth,this._scaledCharHeight),this._charAtlas.warmUp())},a.prototype.resize=function(t,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(t,this._colors)},a.prototype.fillCells=function(t,e,n,r){this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight)},a.prototype.fillBottomLineAtCells=function(t,e,n){void 0===n&&(n=1),this._ctx.fillRect(t*this._scaledCellWidth,(e+1)*this._scaledCellHeight-window.devicePixelRatio-1,n*this._scaledCellWidth,window.devicePixelRatio)},a.prototype.fillLeftLineAtCell=function(t,e){this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,window.devicePixelRatio,this._scaledCellHeight)},a.prototype.strokeRectAtCell=function(t,e,n,r){this._ctx.lineWidth=window.devicePixelRatio,this._ctx.strokeRect(t*this._scaledCellWidth+window.devicePixelRatio/2,e*this._scaledCellHeight+window.devicePixelRatio/2,n*this._scaledCellWidth-window.devicePixelRatio,r*this._scaledCellHeight-window.devicePixelRatio)},a.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))},a.prototype.clearCells=function(t,e,n,r){this._alpha?this._ctx.clearRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight))},a.prototype.fillCharTrueColor=function(t,e,n,r){this._ctx.font=this._getFont(t,!1,!1),this._ctx.textBaseline="middle",this._clipRow(t,r),this._ctx.fillText(e.getChars(),n*this._scaledCellWidth+this._scaledCharLeft,r*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2)},a.prototype.drawChars=function(t,e,n,o){var a,l;e.isFgRGB()||e.isBgRGB()?this._drawUncachedChars(t,e,n,o):(e.isInverse()?(a=e.isBgDefault()?i.INVERTED_DEFAULT_COLOR:e.getBgColor(),l=e.isFgDefault()?i.INVERTED_DEFAULT_COLOR:e.getFgColor()):(l=e.isBgDefault()?r.DEFAULT_COLOR:e.getBgColor(),a=e.isFgDefault()?r.DEFAULT_COLOR:e.getFgColor()),a+=t.options.drawBoldTextInBrightColors&&e.isBold()&&a<8&&a!==i.INVERTED_DEFAULT_COLOR?8:0,this._currentGlyphIdentifier.chars=e.getChars()||s.WHITESPACE_CELL_CHAR,this._currentGlyphIdentifier.code=e.getCode()||s.WHITESPACE_CELL_CODE,this._currentGlyphIdentifier.bg=l,this._currentGlyphIdentifier.fg=a,this._currentGlyphIdentifier.bold=e.isBold()&&t.options.enableBold,this._currentGlyphIdentifier.dim=!!e.isDim(),this._currentGlyphIdentifier.italic=!!e.isItalic(),this._charAtlas&&this._charAtlas.draw(this._ctx,this._currentGlyphIdentifier,n*this._scaledCellWidth+this._scaledCharLeft,o*this._scaledCellHeight+this._scaledCharTop)||this._drawUncachedChars(t,e,n,o))},a.prototype._drawUncachedChars=function(t,e,n,r){var o;this._ctx.save(),this._ctx.font=this._getFont(t,e.isBold()&&t.options.enableBold,!!e.isItalic()),this._ctx.textBaseline="middle",e.isInverse()?e.isBgDefault()?this._ctx.fillStyle=this._colors.background.css:e.isBgRGB()?this._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(e.getBgColor()).join(",")+")":this._ctx.fillStyle=this._colors.ansi[e.getBgColor()].css:e.isFgDefault()?this._ctx.fillStyle=this._colors.foreground.css:e.isFgRGB()?this._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(e.getFgColor()).join(",")+")":(o=e.getFgColor(),t.options.drawBoldTextInBrightColors&&e.isBold()&&o<8&&(o+=8),this._ctx.fillStyle=this._colors.ansi[o].css),this._clipRow(t,r),e.isDim()&&(this._ctx.globalAlpha=i.DIM_OPACITY),this._ctx.fillText(e.getChars(),n*this._scaledCellWidth+this._scaledCharLeft,r*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2),this._ctx.restore()},a.prototype._clipRow=function(t,e){this._ctx.beginPath(),this._ctx.rect(0,e*this._scaledCellHeight,t.cols*this._scaledCellWidth,this._scaledCellHeight),this._ctx.clip()},a.prototype._getFont=function(t,e,n){return(n?"italic":"")+" "+(e?t.options.fontWeightBold:t.options.fontWeight)+" "+t.options.fontSize*window.devicePixelRatio+"px "+t.options.fontFamily},t=a;function a(t,e,n,r,i){this._container=t,this._alpha=r,this._colors=i,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-"+e+"-layer"),this._canvas.style.zIndex=n.toString(),this._initCanvas(),this._container.appendChild(this._canvas)}n.BaseRenderLayer=t},{"../common/Types":27,"../core/buffer/BufferLine":29,"./atlas/CharAtlasCache":48,"./atlas/Types":55}],39:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o,s=t("../core/buffer/BufferLine");i(a,o=s.AttributeData),a.prototype.isCombined=function(){return 2097152},a.prototype.getWidth=function(){return this._width},a.prototype.getChars=function(){return this.combinedData},a.prototype.getCode=function(){return 2097151},a.prototype.setFromCharData=function(t){throw new Error("not implemented")},a.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},i=a;function a(t,e,n){var r=o.call(this)||this;return r.content=0,r.combinedData="",r.fg=t.fg,r.bg=t.bg,r.combinedData=e,r._width=n,r}function l(t){this._terminal=t,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new s.CellData}n.JoinedCellData=i,l.prototype.registerCharacterJoiner=function(t){return t={id:this._nextCharacterJoinerId++,handler:t},this._characterJoiners.push(t),t.id},l.prototype.deregisterCharacterJoiner=function(t){for(var e=0;e=t.rows)this._clearCursor();else if(t.buffer.lines.get(n).loadCell(t.buffer.x,this._cell),void 0!==this._cell.content){if(!t.isFocused)return this._clearCursor(),this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._renderBlurCursor(t,t.buffer.x,r,this._cell),this._ctx.restore(),this._state.x=t.buffer.x,this._state.y=r,this._state.isFocused=!1,this._state.style=t.options.cursorStyle,void(this._state.width=this._cell.getWidth());if(!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isCursorVisible){if(this._state){if(this._state.x===t.buffer.x&&this._state.y===r&&this._state.isFocused===t.isFocused&&this._state.style===t.options.cursorStyle&&this._state.width===this._cell.getWidth())return;this._clearCursor()}this._ctx.save(),this._cursorRenderers[t.options.cursorStyle||"block"](t,t.buffer.x,r,this._cell),this._ctx.restore(),this._state.x=t.buffer.x,this._state.y=r,this._state.isFocused=!1,this._state.style=t.options.cursorStyle,this._state.width=this._cell.getWidth()}else this._clearCursor()}}else this._clearCursor()},l.prototype._clearCursor=function(){this._state&&(this.clearCells(this._state.x,this._state.y,this._state.width,1),this._state={x:null,y:null,isFocused:null,style:null,width:null})},l.prototype._renderBarCursor=function(t,e,n,r){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this.fillLeftLineAtCell(e,n),this._ctx.restore()},l.prototype._renderBlockCursor=function(t,e,n,r){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this.fillCells(e,n,r.getWidth(),1),this._ctx.fillStyle=this._colors.cursorAccent.css,this.fillCharTrueColor(t,r,e,n),this._ctx.restore()},l.prototype._renderUnderlineCursor=function(t,e,n,r){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this.fillBottomLineAtCells(e,n),this._ctx.restore()},l.prototype._renderBlurCursor=function(t,e,n,r){this._ctx.save(),this._ctx.strokeStyle=this._colors.cursor.css,this.strokeRectAtCell(e,n,r.getWidth(),1),this._ctx.restore()},i=l;function l(t,e,n){return(n=o.call(this,t,"cursor",e,!0,n)||this)._cell=new a.CellData,n._state={x:null,y:null,isFocused:null,style:null,width:null},n._cursorRenderers={bar:n._renderBarCursor.bind(n),block:n._renderBlockCursor.bind(n),underline:n._renderUnderlineCursor.bind(n)},n}n.CursorRenderLayer=i;var c=(Object.defineProperty(h.prototype,"isPaused",{get:function(){return!(this._blinkStartTimeout||this._blinkInterval)},enumerable:!0,configurable:!0}),h.prototype.dispose=function(){this._blinkInterval&&(window.clearInterval(this._blinkInterval),this._blinkInterval=null),this._blinkStartTimeout&&(window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=null),this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=null)},h.prototype.restartBlinkAnimation=function(t){var e=this;this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame||(this._animationFrame=window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=null}))))},h.prototype._restartInterval=function(t){var e=this;void 0===t&&(t=600),this._blinkInterval&&window.clearInterval(this._blinkInterval),this._blinkStartTimeout=setTimeout((function(){if(e._animationTimeRestarted){var t=600-(Date.now()-e._animationTimeRestarted);if(e._animationTimeRestarted=null,0=t.rows||o<0||(this._ctx.fillStyle=this._colors.selection.css,r?(l=e[0],s=n[0]-l,this.fillCells(l,i,s,o-i+1)):(l=a===i?e[0]:0,a=i===o?n[0]:t.cols,this.fillCells(l,i,a-l,1),l=Math.max(o-i-1,0),this.fillCells(0,i+1,t.cols,l),i!==o&&(c=c===o?n[0]:t.cols,this.fillCells(0,o,c,1))),this._state.start=[e[0],e[1]],this._state.end=[n[0],n[1]],this._state.columnSelectMode=r,this._state.ydisp=t.buffer.ydisp)):this._clearState())},s.prototype._didStateChange=function(t,e,n,r){return!this._areCoordinatesEqual(t,this._state.start)||!this._areCoordinatesEqual(e,this._state.end)||n!==this._state.columnSelectMode||r!==this._state.ydisp},s.prototype._areCoordinatesEqual=function(t,e){return!(!t||!e)&&t[0]===e[0]&&t[1]===e[1]},i=s;function s(t,e,n){return(n=o.call(this,t,"selection",e,!0,n)||this)._clearState(),n}n.SelectionRenderLayer=i},{"./BaseRenderLayer":38}],46:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o,s=t("./GridCache"),a=t("./BaseRenderLayer"),l=t("../core/buffer/BufferLine"),c=t("./CharacterJoinerRegistry");i(h,o=a.BaseRenderLayer),h.prototype.resize=function(t,e){o.prototype.resize.call(this,t,e);var n=this._getFont(t,!1,!1);this._characterWidth===e.scaledCharWidth&&this._characterFont===n||(this._characterWidth=e.scaledCharWidth,this._characterFont=n,this._characterOverlapCache={}),this._state.clear(),this._state.resize(t.cols,t.rows)},h.prototype.reset=function(t){this._state.clear(),this.clearAll()},h.prototype._forEachCell=function(t,e,n,r,i){for(var o=e;o<=n;o++)for(var s=o+t.buffer.ydisp,a=t.buffer.lines.get(s),h=r?r.getJoinedCharacters(s):[],u=0;uthis._characterWidth,this._ctx.restore(),this._characterOverlapCache[e]=t)},i=h;function h(t,e,n,r,i){return(n=o.call(this,t,"text",e,i,n)||this)._characterOverlapCache={},n._workCell=new l.CellData,n._state=new s.GridCache,n._characterJoinerRegistry=r,n}n.TextRenderLayer=i},{"../core/buffer/BufferLine":29,"./BaseRenderLayer":38,"./CharacterJoinerRegistry":39,"./GridCache":41}],47:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=(i.prototype.dispose=function(){},i.prototype.warmUp=function(){this._didWarmUp||(this._doWarmUp(),this._didWarmUp=!0)},i.prototype._doWarmUp=function(){},i.prototype.beginFrame=function(){},i);function i(){this._didWarmUp=!1}n.default=r},{}],48:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("./CharAtlasUtils"),i=t("./DynamicCharAtlas"),o=t("./NoneCharAtlas"),s=(t=t("./StaticCharAtlas"),{none:o.default,static:t.default,dynamic:i.default}),a=[];n.acquireCharAtlas=function(t,e,n,i){for(var o=r.generateConfig(n,i,t,e),l=0;l>>24,i=e.rgba>>>16&255,o=e.rgba>>>8&255,s=0;s=this.capacity?(r=this._head,this._unlinkNode(r),delete this._map[r.key],r.key=t,r.value=e,this._map[t]=r):(0<(n=this._nodePool).length?((r=n.pop()).key=t,r.value=e):r={prev:null,next:null,key:t,value:e},this._map[t]=r,this.size++),this._appendNode(r)},i);function i(t){this.capacity=t,this._map={},this._head=null,this._tail=null,this._nodePool=[],this.size=0}n.default=r},{}],53:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o;t=t("./BaseCharAtlas"),i(s,o=t.default),s.prototype.draw=function(t,e,n,r){return!1},i=s;function s(t,e){return o.call(this)||this}n.default=i},{"./BaseCharAtlas":47}],54:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o,s=t("./Types"),a=t("./CharAtlasGenerator"),l=t("./BaseCharAtlas"),c=t("./CharAtlasUtils"),h=t("../../common/Types");i(u,o=l.default),u.prototype._doWarmUp=function(){var t=this,e=a.generateStaticCharAtlasTexture(window,this._canvasFactory,this._config);e instanceof HTMLCanvasElement?this._texture=e:e.then((function(e){t._texture=e}))},u.prototype._isCached=function(t,e){var n=t.code<256,r=t.fg<16,i=t.fg===h.DEFAULT_COLOR,o=t.bg===h.DEFAULT_COLOR;return n&&(r||i)&&o&&!t.italic},u.prototype.draw=function(t,e,n,r){if(null===this._texture||void 0===this._texture)return!1;var i=0;if(c.is256Color(e.fg)?i=2+e.fg+(e.bold?16:0):e.fg===h.DEFAULT_COLOR&&e.bold&&(i=1),!this._isCached(e,i))return!1;t.save();var o=this._config.scaledCharWidth+s.CHAR_ATLAS_CELL_SPACING,a=this._config.scaledCharHeight+s.CHAR_ATLAS_CELL_SPACING;return e.dim&&(t.globalAlpha=s.DIM_OPACITY),t.drawImage(this._texture,e.code*o,i*a,o,this._config.scaledCharHeight,n,r,o,this._config.scaledCharHeight),t.restore(),!0},i=u;function u(t,e){var n=o.call(this)||this;return n._document=t,n._config=e,n._canvasFactory=function(t,e){var r=n._document.createElement("canvas");return r.width=t,r.height=e,r},n}n.default=i},{"../../common/Types":27,"./BaseCharAtlas":47,"./CharAtlasGenerator":49,"./CharAtlasUtils":50,"./Types":55}],55:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.INVERTED_DEFAULT_COLOR=257,n.DIM_OPACITY=.5,n.CHAR_ATLAS_CELL_SPACING=1},{}],56:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o,s=t("./DomRendererRowFactory"),a=t("../atlas/Types"),l=(t=t("../../common/Lifecycle"),"xterm-dom-renderer-owner-"),c="xterm-rows",h="xterm-fg-",u="xterm-bg-",f="xterm-focus",p="xterm-selection",d=1;i(_,o=t.Disposable),_.prototype.dispose=function(){this._terminal.element.classList.remove(l+this._terminalClass),this._terminal.screenElement.removeChild(this._rowContainer),this._terminal.screenElement.removeChild(this._selectionContainer),this._terminal.screenElement.removeChild(this._themeStyleElement),this._terminal.screenElement.removeChild(this._dimensionsStyleElement),o.prototype.dispose.call(this)},_.prototype._updateDimensions=function(){var t=this;this.dimensions.scaledCharWidth=this._terminal.charMeasure.width*window.devicePixelRatio,this.dimensions.scaledCharHeight=Math.ceil(this._terminal.charMeasure.height*window.devicePixelRatio),this.dimensions.scaledCellWidth=this.dimensions.scaledCharWidth+Math.round(this._terminal.options.letterSpacing),this.dimensions.scaledCellHeight=Math.floor(this.dimensions.scaledCharHeight*this._terminal.options.lineHeight),this.dimensions.scaledCharLeft=0,this.dimensions.scaledCharTop=0,this.dimensions.scaledCanvasWidth=this.dimensions.scaledCellWidth*this._terminal.cols,this.dimensions.scaledCanvasHeight=this.dimensions.scaledCellHeight*this._terminal.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._terminal.cols,this.dimensions.actualCellHeight=this.dimensions.canvasHeight/this._terminal.rows,this._rowElements.forEach((function(e){e.style.width=t.dimensions.canvasWidth+"px",e.style.height=t.dimensions.actualCellHeight+"px",e.style.lineHeight=t.dimensions.actualCellHeight+"px",e.style.overflow="hidden"})),this._dimensionsStyleElement||(this._dimensionsStyleElement=document.createElement("style"),this._terminal.screenElement.appendChild(this._dimensionsStyleElement));var e=this._terminalSelector+" ."+c+" span { display: inline-block; height: 100%; vertical-align: top; width: "+this.dimensions.actualCellWidth+"px}";this._dimensionsStyleElement.innerHTML=e,this._selectionContainer.style.height=this._terminal._viewportElement.style.height,this._terminal.screenElement.style.width=this.dimensions.canvasWidth+"px",this._terminal.screenElement.style.height=this.dimensions.canvasHeight+"px"},_.prototype.setColors=function(t){this._colors=t,this._injectCss()},_.prototype._injectCss=function(){var t=this;this._themeStyleElement||(this._themeStyleElement=document.createElement("style"),this._terminal.screenElement.appendChild(this._themeStyleElement));var e=this._terminalSelector+" ."+c+" { color: "+this._colors.foreground.css+"; background-color: "+this._colors.background.css+"; font-family: "+this._terminal.options.fontFamily+"; font-size: "+this._terminal.options.fontSize+"px;}";e+=this._terminalSelector+" span:not(."+s.BOLD_CLASS+") { font-weight: "+this._terminal.options.fontWeight+";}"+this._terminalSelector+" span."+s.BOLD_CLASS+" { font-weight: "+this._terminal.options.fontWeightBold+";}"+this._terminalSelector+" span."+s.ITALIC_CLASS+" { font-style: italic;}",e+="@keyframes blink { 0% { opacity: 1.0; } 50% { opacity: 0.0; } 100% { opacity: 1.0; }}",e+=this._terminalSelector+" ."+c+":not(."+f+") ."+s.CURSOR_CLASS+" { outline: 1px solid "+this._colors.cursor.css+"; outline-offset: -1px;}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_BLINK_CLASS+" { animation: blink 1s step-end infinite;}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BLOCK_CLASS+" { background-color: "+this._colors.cursor.css+"; color: "+this._colors.cursorAccent.css+";}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BAR_CLASS+" { box-shadow: 1px 0 0 "+this._colors.cursor.css+" inset;}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_UNDERLINE_CLASS+" { box-shadow: 0 -1px 0 "+this._colors.cursor.css+" inset;}",e+=this._terminalSelector+" ."+p+" { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}"+this._terminalSelector+" ."+p+" div { position: absolute; background-color: "+this._colors.selection.css+";}",this._colors.ansi.forEach((function(n,r){e+=t._terminalSelector+" ."+h+r+" { color: "+n.css+"; }"+t._terminalSelector+" ."+u+r+" { background-color: "+n.css+"; }"})),e+=this._terminalSelector+" ."+h+a.INVERTED_DEFAULT_COLOR+" { color: "+this._colors.background.css+"; }"+this._terminalSelector+" ."+u+a.INVERTED_DEFAULT_COLOR+" { background-color: "+this._colors.foreground.css+"; }",this._themeStyleElement.innerHTML=e},_.prototype.onDevicePixelRatioChange=function(){this._updateDimensions()},_.prototype._refreshRowElements=function(t,e){for(var n=this._rowElements.length;n<=e;n++){var r=document.createElement("div");this._rowContainer.appendChild(r),this._rowElements.push(r)}for(;this._rowElements.length>e;)this._rowContainer.removeChild(this._rowElements.pop())},_.prototype.onResize=function(t,e){this._refreshRowElements(t,e),this._updateDimensions()},_.prototype.onCharSizeChanged=function(){this._updateDimensions()},_.prototype.onBlur=function(){this._rowContainer.classList.remove(f)},_.prototype.onFocus=function(){this._rowContainer.classList.add(f)},_.prototype.onSelectionChanged=function(t,e,n){for(;this._selectionContainer.children.length;)this._selectionContainer.removeChild(this._selectionContainer.children[0]);var r,i,o,s,a;t&&e&&(a=t[1]-this._terminal.buffer.ydisp,r=e[1]-this._terminal.buffer.ydisp,i=Math.max(a,0),o=Math.min(r,this._terminal.rows-1),i>=this._terminal.rows||o<0||(s=document.createDocumentFragment(),n?s.appendChild(this._createSelectionElement(i,t[0],e[0],o-i+1)):(a=a===i?t[0]:0,t=i===o?e[0]:this._terminal.cols,s.appendChild(this._createSelectionElement(i,a,t)),s.appendChild(this._createSelectionElement(i+1,0,this._terminal.cols,o-i-1)),i!==o&&(e=r===o?e[0]:this._terminal.cols,s.appendChild(this._createSelectionElement(o,0,e)))),this._selectionContainer.appendChild(s)))},_.prototype._createSelectionElement=function(t,e,n,r){void 0===r&&(r=1);var i=document.createElement("div");return i.style.height=r*this.dimensions.actualCellHeight+"px",i.style.top=t*this.dimensions.actualCellHeight+"px",i.style.left=e*this.dimensions.actualCellWidth+"px",i.style.width=this.dimensions.actualCellWidth*(n-e)+"px",i},_.prototype.onCursorMove=function(){},_.prototype.onOptionsChanged=function(){this._updateDimensions(),this._injectCss(),this._terminal.refresh(0,this._terminal.rows-1)},_.prototype.clear=function(){this._rowElements.forEach((function(t){return t.innerHTML=""}))},_.prototype.renderRows=function(t,e){for(var n=this._terminal,r=n.buffer.ybase+n.buffer.y,i=this._terminal.buffer.x,o=this._terminal.options.cursorBlink,s=t;s<=e;s++){var a=this._rowElements[s];a.innerHTML="";var l=s+n.buffer.ydisp,c=n.buffer.lines.get(l),h=n.options.cursorStyle;a.appendChild(this._rowFactory.createRow(c,l===r,h,i,o,this.dimensions.actualCellWidth,n.cols))}},Object.defineProperty(_.prototype,"_terminalSelector",{get:function(){return"."+l+this._terminalClass},enumerable:!0,configurable:!0}),_.prototype.registerCharacterJoiner=function(t){return-1},_.prototype.deregisterCharacterJoiner=function(t){return!1},_.prototype._onLinkHover=function(t){this._setCellUnderline(t.x1,t.x2,t.y1,t.y2,t.cols,!0)},_.prototype._onLinkLeave=function(t){this._setCellUnderline(t.x1,t.x2,t.y1,t.y2,t.cols,!1)},_.prototype._setCellUnderline=function(t,e,n,r,i,o){for(;t!==e||n!==r;){var s=this._rowElements[n];if(!s)return;(s=s.children[t])&&(s.style.textDecoration=o?"underline":"none"),++t>=i&&(t=0,n++)}},i=_;function _(t,e){var n=o.call(this)||this;return n._terminal=t,n._colors=e,n._terminalClass=d++,n._rowElements=[],n._rowContainer=document.createElement("div"),n._rowContainer.classList.add(c),n._rowContainer.style.lineHeight="normal",n._rowContainer.setAttribute("aria-hidden","true"),n._refreshRowElements(n._terminal.cols,n._terminal.rows),n._selectionContainer=document.createElement("div"),n._selectionContainer.classList.add(p),n._selectionContainer.setAttribute("aria-hidden","true"),n.dimensions={scaledCharWidth:null,scaledCharHeight:null,scaledCellWidth:null,scaledCellHeight:null,scaledCharLeft:null,scaledCharTop:null,scaledCanvasWidth:null,scaledCanvasHeight:null,canvasWidth:null,canvasHeight:null,actualCellWidth:null,actualCellHeight:null},n._updateDimensions(),n._injectCss(),n._rowFactory=new s.DomRendererRowFactory(t.options,document),n._terminal.element.classList.add(l+n._terminalClass),n._terminal.screenElement.appendChild(n._rowContainer),n._terminal.screenElement.appendChild(n._selectionContainer),n._terminal.linkifier.onLinkHover((function(t){return n._onLinkHover(t)})),n._terminal.linkifier.onLinkLeave((function(t){return n._onLinkLeave(t)})),n}n.DomRenderer=i},{"../../common/Lifecycle":24,"../atlas/Types":55,"./DomRendererRowFactory":57}],57:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=t("../atlas/Types"),i=t("../../core/buffer/BufferLine");function o(t,e){this._terminalOptions=t,this._document=e,this._workCell=new i.CellData}n.BOLD_CLASS="xterm-bold",n.DIM_CLASS="xterm-dim",n.ITALIC_CLASS="xterm-italic",n.UNDERLINE_CLASS="xterm-underline",n.CURSOR_CLASS="xterm-cursor",n.CURSOR_BLINK_CLASS="xterm-cursor-blink",n.CURSOR_STYLE_BLOCK_CLASS="xterm-cursor-block",n.CURSOR_STYLE_BAR_CLASS="xterm-cursor-bar",n.CURSOR_STYLE_UNDERLINE_CLASS="xterm-cursor-underline",o.prototype.createRow=function(t,e,o,s,a,l,c){for(var h=this._document.createDocumentFragment(),u=0,f=Math.min(t.length,c)-1;0<=f;f--)if(t.loadCell(f,this._workCell).getCode()!==i.NULL_CELL_CODE||e&&f===s){u=f+1;break}for(f=0;f>>0})}for(n=0;n<24;n++){var s=8+10*n,a=c(s);t.push({css:"#"+a+a+a,rgba:(s<<24|s<<16|s<<8|255)>>>0})}return t}();var h=(u.prototype.setTheme=function(t){this.colors.foreground=this._parseColor((t=void 0===t?{}:t).foreground,r),this.colors.background=this._parseColor(t.background,i),this.colors.cursor=this._parseColor(t.cursor,o,!0),this.colors.cursorAccent=this._parseColor(t.cursorAccent,s,!0),this.colors.selection=this._parseColor(t.selection,a,!0),this.colors.ansi[0]=this._parseColor(t.black,n.DEFAULT_ANSI_COLORS[0]),this.colors.ansi[1]=this._parseColor(t.red,n.DEFAULT_ANSI_COLORS[1]),this.colors.ansi[2]=this._parseColor(t.green,n.DEFAULT_ANSI_COLORS[2]),this.colors.ansi[3]=this._parseColor(t.yellow,n.DEFAULT_ANSI_COLORS[3]),this.colors.ansi[4]=this._parseColor(t.blue,n.DEFAULT_ANSI_COLORS[4]),this.colors.ansi[5]=this._parseColor(t.magenta,n.DEFAULT_ANSI_COLORS[5]),this.colors.ansi[6]=this._parseColor(t.cyan,n.DEFAULT_ANSI_COLORS[6]),this.colors.ansi[7]=this._parseColor(t.white,n.DEFAULT_ANSI_COLORS[7]),this.colors.ansi[8]=this._parseColor(t.brightBlack,n.DEFAULT_ANSI_COLORS[8]),this.colors.ansi[9]=this._parseColor(t.brightRed,n.DEFAULT_ANSI_COLORS[9]),this.colors.ansi[10]=this._parseColor(t.brightGreen,n.DEFAULT_ANSI_COLORS[10]),this.colors.ansi[11]=this._parseColor(t.brightYellow,n.DEFAULT_ANSI_COLORS[11]),this.colors.ansi[12]=this._parseColor(t.brightBlue,n.DEFAULT_ANSI_COLORS[12]),this.colors.ansi[13]=this._parseColor(t.brightMagenta,n.DEFAULT_ANSI_COLORS[13]),this.colors.ansi[14]=this._parseColor(t.brightCyan,n.DEFAULT_ANSI_COLORS[14]),this.colors.ansi[15]=this._parseColor(t.brightWhite,n.DEFAULT_ANSI_COLORS[15])},u.prototype._parseColor=function(t,e,n){if(void 0===n&&(n=this.allowTransparency),void 0===t)return e;if(this._ctx.fillStyle=this._litmusColor,this._ctx.fillStyle=t,"string"!=typeof this._ctx.fillStyle)return console.warn("Color: "+t+" is invalid using fallback "+e.css),e;this._ctx.fillRect(0,0,1,1);var r=this._ctx.getImageData(0,0,1,1).data;return n||255===r[3]?{css:t,rgba:(r[0]<<24|r[1]<<16|r[2]<<8|r[3])>>>0}:(console.warn("Color: "+t+" is using transparency, but allowTransparency is false. Using fallback "+e.css+"."),e)},u);function u(t,e){if(this.allowTransparency=e,(t=t.createElement("canvas")).width=1,t.height=1,!(t=t.getContext("2d")))throw new Error("Could not get rendering context");this._ctx=t,this._ctx.globalCompositeOperation="copy",this._litmusColor=this._ctx.createLinearGradient(0,0,1,1),this.colors={foreground:r,background:i,cursor:o,cursorAccent:s,selection:a,ansi:n.DEFAULT_ANSI_COLORS.slice()}}n.ColorManager=h},{}],59:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.addDisposableDomListener=function(t,e,n,r){return t.addEventListener(e,n,r),{dispose:function(){n&&t.removeEventListener(e,n,r)}}}},{}],60:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=(i.prototype.dispose=function(){this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},i.prototype.refresh=function(t,e,n){var r=this;this._rowCount=n,t=void 0!==t?t:0,e=void 0!==e?e:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,t):t,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,e):e,this._animationFrame||(this._animationFrame=window.requestAnimationFrame((function(){return r._innerRefresh()})))},i.prototype._innerRefresh=function(){void 0!==this._rowStart&&void 0!==this._rowEnd&&void 0!==this._rowCount&&(this._rowStart=Math.max(this._rowStart,0),this._rowEnd=Math.min(this._rowEnd,this._rowCount-1),this._renderCallback(this._rowStart,this._rowEnd),this._rowStart=void 0,this._rowEnd=void 0,this._animationFrame=void 0)},i);function i(t){this._renderCallback=t}n.RenderDebouncer=r},{}],61:[function(t,e,n){"use strict";var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0});var o;t=t("../common/Lifecycle"),i(s,o=t.Disposable),s.prototype.setListener=function(t){var e=this;this._listener&&this.clearListener(),this._listener=t,this._outerListener=function(){e._listener&&(e._listener(window.devicePixelRatio,e._currentDevicePixelRatio),e._updateDpr())},this._updateDpr()},s.prototype.dispose=function(){o.prototype.dispose.call(this),this.clearListener()},s.prototype._updateDpr=function(){this._resolutionMediaMatchList&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._currentDevicePixelRatio=window.devicePixelRatio,this._resolutionMediaMatchList=window.matchMedia("screen and (resolution: "+window.devicePixelRatio+"dppx)"),this._resolutionMediaMatchList.addListener(this._outerListener))},s.prototype.clearListener=function(){this._resolutionMediaMatchList&&this._listener&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._resolutionMediaMatchList=void 0,this._listener=void 0,this._outerListener=void 0)},i=s;function s(){var t=null!==o&&o.apply(this,arguments)||this;return t._currentDevicePixelRatio=window.devicePixelRatio,t}n.ScreenDprMonitor=i},{"../common/Lifecycle":24}],62:[function(t,e,n){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),t=t("./public/Terminal"),e.exports=t.Terminal},{"./public/Terminal":37}]},{},[62])(62)},function(t,e,n){"use strict";(function(t,r){function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function o(t,e){for(var n=0;n>>0;n--;)e[n]=t[n];return e}function ht(t){return t.classList?ct(t.classList):(t.getAttribute("class")||"").split(" ").filter((function(t){return t}))}function ut(t){return"".concat(t).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function ft(t){return Object.keys(t||{}).reduce((function(e,n){return e+"".concat(n,": ").concat(t[n],";")}),"")}function pt(t){return t.size!==st.size||t.x!==st.x||t.y!==st.y||t.rotate!==st.rotate||t.flipX||t.flipY}function dt(t){var e=t.transform,n=t.containerWidth,r=t.iconWidth,i={transform:"translate(".concat(n/2," 256)")};t="translate(".concat(32*e.x,", ").concat(32*e.y,") "),n="scale(".concat(e.size/16*(e.flipX?-1:1),", ").concat(e.size/16*(e.flipY?-1:1),") "),e="rotate(".concat(e.rotate," 0 0)");return{outer:i,inner:{transform:"".concat(t," ").concat(n," ").concat(e)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}var _t={x:0,y:0,width:"100%",height:"100%"};function mt(t){return t.attributes&&(t.attributes.fill||!(1").concat(i.map(Ft).join(""),"")}var Pt=function(){};function Ht(t){return"string"==typeof(t.getAttribute?t.getAttribute(b):null)}var It={replace:function(t){var e=t[0],n=t[1].map(Ft).join("\n");e.parentNode&&e.outerHTML?e.outerHTML=n+(O.keepOriginalSource&&"svg"!==e.tagName.toLowerCase()?"\x3c!-- ".concat(e.outerHTML," Font Awesome fontawesome.com --\x3e"):""):e.parentNode&&(t=document.createElement("span"),e.parentNode.replaceChild(t,e),t.outerHTML=n)},nest:function(t){var e=t[0],n=t[1];if(~ht(e).indexOf(O.replacementClass))return It.replace(t);var r=new RegExp("".concat(O.familyPrefix,"-.*"));delete n[0].attributes.style,delete n[0].attributes.id,t=n[0].attributes.class.split(" ").reduce((function(t,e){return(e===O.replacementClass||e.match(r)?t.toSvg:t.toNode).push(e),t}),{toNode:[],toSvg:[]}),n[0].attributes.class=t.toSvg.join(" "),n=n.map(Ft).join("\n"),e.setAttribute("class",t.toNode.join(" ")),e.setAttribute(b,""),e.innerHTML=n}};function Ut(t){t()}function jt(t,e){var n="function"==typeof e?e:Pt;0===t.length?n():("async"===O.mutateApproach&&d.requestAnimationFrame||Ut)((function(){var e=!0!==O.autoReplaceSvg&&It[O.autoReplaceSvg]||It.replace,r=St("mutate");t.map(e),r(),n()}))}var Nt=!1;function Wt(){Nt=!1}var zt=null;var qt=function(t){var e={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return t?t.toLowerCase().split(" ").reduce((function(t,e){var n=e.toLowerCase().split("-"),r=(e=n[0],n.slice(1).join("-"));if(e&&"h"===r)return t.flipX=!0,t;if(e&&"v"===r)return t.flipY=!0,t;if(r=parseFloat(r),isNaN(r))return t;switch(e){case"grow":t.size=t.size+r;break;case"shrink":t.size=t.size-r;break;case"left":t.x=t.x-r;break;case"right":t.x=t.x+r;break;case"up":t.y=t.y-r;break;case"down":t.y=t.y+r;break;case"rotate":t.rotate=t.rotate+r}return t}),e):e};function Yt(t){var e,n=(a=function(t){var e=t.getAttribute("data-prefix"),n=t.getAttribute("data-icon"),r=void 0!==t.innerText?t.innerText.trim():"",i=Bt(ht(t));return e&&n&&(i.prefix=e,i.iconName=n),i.prefix&&1 li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';return r===e&&i===n||(t=new RegExp("\\.".concat(e,"\\-"),"g"),e=new RegExp("\\--".concat(e,"\\-"),"g"),n=new RegExp("\\.".concat(n),"g"),o=o.replace(t,".".concat(r,"-")).replace(e,"--".concat(r,"-")).replace(n,".".concat(i))),o}function se(){O.autoAddCss&&!ue&&(at(oe()),ue=!0)}function ae(t,e){return Object.defineProperty(t,"abstract",{get:e}),Object.defineProperty(t,"html",{get:function(){return t.abstract.map(Ft)}}),Object.defineProperty(t,"node",{get:function(){if(g){var e=_.createElement("div");return e.innerHTML=t.html,e.children}}}),t}function le(t){var e=void 0===(e=t.prefix)?"fa":e;if(t=t.iconName)return Ot(he.definitions,e,t)||Ot(F.styles,e,t)}var ce,he=new(function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.definitions={}}var e,n;return e=t,(n=[{key:"add",value:function(){for(var t=this,e=arguments.length,n=new Array(e),r=0;r=this._reconnectionAttempts?(c("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1):(t=this.backoff.duration(),c("will wait %dms before reconnect attempt",t),this.reconnecting=!0,e=setTimeout((function(){n.skipReconnect||(c("attempting reconnect"),n.emitAll("reconnect_attempt",n.backoff.attempts),n.emitAll("reconnecting",n.backoff.attempts),n.skipReconnect||n.open((function(t){t?(c("reconnect attempt error"),n.reconnecting=!1,n.reconnect(),n.emitAll("reconnect_error",t.data)):(c("reconnect success"),n.onreconnect())})))}),t),this.subs.push({destroy:function(){clearTimeout(e)}}))},p.prototype.onreconnect=function(){var t=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",t)}},function(t,e,n){var r=n(12),i=n(41),o=n(49);n=n(50);e.polling=function(t){var e,n,s=!1,a=!1,l=!1!==t.jsonp;if("undefined"!=typeof location&&(e="https:"===location.protocol,n=(n=location.port)||(e?443:80),s=t.hostname!==location.hostname||n!==t.port,a=t.secure!==e),t.xdomain=s,t.xscheme=a,"open"in new r(t)&&!t.forceJSONP)return new i(t);if(!l)throw new Error("JSONP disabled");return new o(t)},e.websocket=n},function(t,e,n){var r=n(13),i=n(5),o=n(0),s=n(6),a=n(22),l=n(7)("engine.io-client:polling");t.exports=h;var c=null!=new(n(12))({xdomain:!1}).responseType;function h(t){var e=t&&t.forceBase64;c&&!e||(this.supportsBinary=!1),r.call(this,t)}s(h,r),h.prototype.name="polling",h.prototype.doOpen=function(){this.poll()},h.prototype.pause=function(t){var e,n=this;function r(){l("paused"),n.readyState="paused",t()}this.readyState="pausing",this.polling||!this.writable?(e=0,this.polling&&(l("we are currently polling - waiting to pause"),e++,this.once("pollComplete",(function(){l("pre-pause polling complete"),--e||r()}))),this.writable||(l("we are currently writing - waiting to pause"),e++,this.once("drain",(function(){l("pre-pause writing complete"),--e||r()})))):r()},h.prototype.poll=function(){l("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},h.prototype.onData=function(t){var e=this;l("polling got data %s",t),o.decodePayload(t,this.socket.binaryType,(function(t,n,r){if("opening"===e.readyState&&e.onOpen(),"close"===t.type)return e.onClose(),!1;e.onPacket(t)})),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():l('ignoring poll - transport state "%s"',this.readyState))},h.prototype.doClose=function(){var t=this;function e(){l("writing close packet"),t.write([{type:"close"}])}"open"===this.readyState?(l("transport open - closing"),e()):(l("transport not open - deferring close"),this.once("open",e))},h.prototype.write=function(t){var e=this;function n(){e.writable=!0,e.emit("drain")}this.writable=!1,o.encodePayload(t,this.supportsBinary,(function(t){e.doWrite(t,n)}))},h.prototype.uri=function(){var t=this.query||{},e=this.secure?"https":"http",n="";return!1!==this.timestampRequests&&(t[this.timestampParam]=a()),this.supportsBinary||t.sid||(t.b64=1),t=i.encode(t),this.port&&("https"==e&&443!==Number(this.port)||"http"==e&&80!==Number(this.port))&&(n=":"+this.port),t.length&&(t="?"+t),e+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+t}},function(t,e,n){(function(e){var r=n(10),i=Object.prototype.toString,o="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===i.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===i.call(File);t.exports=function t(n){if(!n||"object"!=typeof n)return!1;if(r(n)){for(var i=0,a=n.length;i>16&255,a[l++]=e>>8&255,a[l++]=255&e;return 2===s&&(e=i[t.charCodeAt(n)]<<2|i[t.charCodeAt(n+1)]>>4,a[l++]=255&e),1===s&&(e=i[t.charCodeAt(n)]<<10|i[t.charCodeAt(n+1)]<<4|i[t.charCodeAt(n+2)]>>2,a[l++]=e>>8&255,a[l++]=255&e),a},e.fromByteArray=function(t){for(var e,n=t.length,i=n%3,o=[],s=0,a=n-i;s>18&63]+r[t>>12&63]+r[t>>6&63]+r[63&t]}(i));return o.join("")}(t,s,a>2]+r[e<<4&63]+"==")):2==i&&(e=(t[n-2]<<8)+t[n-1],o.push(r[e>>10]+r[e>>4&63]+r[e<<2&63]+"=")),o.join("")};for(var r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,l=s.length;a>1,h=-7,u=n?i-1:0,f=n?-1:1;n=t[e+u];for(u+=f,o=n&(1<<-h)-1,n>>=-h,h+=a;0>=-h,h+=r;0>1,u=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,f=r?0:o-1,p=r?1:-1;o=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=c):(s=Math.floor(Math.log(e)/Math.LN2),e*(r=Math.pow(2,-s))<1&&(s--,r*=2),2<=(e+=1<=s+h?u/r:u*Math.pow(2,1-h))*r&&(s++,r/=2),c<=s+h?(a=0,s=c):1<=s+h?(a=(e*r-1)*Math.pow(2,i),s+=h):(a=e*Math.pow(2,h-1)*Math.pow(2,i),s=0));8<=i;t[n+f]=255&a,f+=p,a/=256,i-=8);for(s=s<>e&63|128)}function c(){if(r<=i)throw Error("Invalid byte index");var t=255&n[i];if(i++,128==(192&t))return 63&t;throw Error("Invalid continuation byte")}t.exports={version:"2.1.2",encode:function(t,e){for(var n=!1!==(e=e||{}).strict,r=s(t),i=r.length,c=-1,h="";++c>6&31|192):0==(4294901760&t)?(a(t,e)||(t=65533),n=o(t>>12&15|224),n+=l(t,6)):0==(4292870144&t)&&(n=o(t>>18&7|240),n+=l(t,12),n+=l(t,6)),n+o(63&t|128)}(r[c],n);return h},decode:function(t,e){var l=!1!==(e=e||{}).strict;n=s(t),r=n.length,i=0;for(var h,u=[];!1!==(h=function(t){var e,o;if(r>>10&1023|55296),e=56320|1023&e),i+=o(e);return i}(u)}}},function(t,e){!function(){"use strict";for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=new Uint8Array(256),r=0;r>2],i+=t[(3&n[o])<<4|n[o+1]>>4],i+=t[(15&n[o+1])<<2|n[o+2]>>6],i+=t[63&n[o+2]];return r%3==2?i=i.substring(0,i.length-1)+"=":r%3==1&&(i=i.substring(0,i.length-2)+"=="),i},e.decode=function(t){var e,r,i,o,s=.75*t.length,a=t.length,l=0;"="===t[t.length-1]&&(s--,"="===t[t.length-2]&&s--);s=new ArrayBuffer(s);for(var c=new Uint8Array(s),h=0;h>4,c[l++]=(15&r)<<4|i>>2,c[l++]=(3&i)<<6|63&o;return s}}()},function(t,e){var n=void 0!==n?n:"undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{return 2===new Blob(["hi"]).size}catch(t){return!1}}(),i=r&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(t){return!1}}(),o=n&&n.prototype.append&&n.prototype.getBlob;function s(t){return t.map((function(t){if(t.buffer instanceof ArrayBuffer){var e,n=t.buffer;return t.byteLength!==n.byteLength&&((e=new Uint8Array(t.byteLength)).set(new Uint8Array(n,t.byteOffset,t.byteLength)),n=e.buffer),n}return t}))}function a(t,e){e=e||{};var r=new n;return s(t).forEach((function(t){r.append(t)})),e.type?r.getBlob(e.type):r.getBlob()}function l(t,e){return new Blob(s(t),e||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,l.prototype=Blob.prototype),t.exports=r?i?Blob:l:o?a:void 0},function(t,e,n){function r(t){var n;function r(){if(r.enabled){var t=r,i=+new Date;t.diff=i-(n||i),t.prev=n,t.curr=i,n=i;for(var o=new Array(arguments.length),s=0;s';o=document.createElement(t)}catch(t){(o=document.createElement("iframe")).name=l.iframeId,o.src="javascript:0"}o.id=l.iframeId,l.form.appendChild(o),l.iframe=o}this.form||(n=document.createElement("form"),r=document.createElement("textarea"),i=this.iframeId="eio_iframe_"+this.index,n.className="socketio",n.style.position="absolute",n.style.top="-1000px",n.style.left="-1000px",n.target=i,n.method="POST",n.setAttribute("accept-charset","utf-8"),r.name="d",n.appendChild(r),document.body.appendChild(n),this.form=n,this.area=r),this.form.action=this.uri(),h(),t=t.replace(a,"\\\n"),this.area.value=t.replace(s,"\\n");try{this.form.submit()}catch(t){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===l.iframe.readyState&&c()}:this.iframe.onload=c}}).call(this,n(1))},function(t,e,n){(function(e){var r,i,o=n(13),s=n(0),a=n(5),l=n(6),c=n(22),h=n(7)("engine.io-client:websocket");if("undefined"!=typeof WebSocket)r=WebSocket;else if("undefined"!=typeof self)r=self.WebSocket||self.MozWebSocket;else try{i=n(51)}catch(l){}var u=r||i;function f(t){t&&t.forceBase64&&(this.supportsBinary=!1),this.perMessageDeflate=t.perMessageDeflate,this.usingBrowserWebSocket=r&&!t.forceNode,this.protocols=t.protocols,this.usingBrowserWebSocket||(u=i),o.call(this,t)}l(t.exports=f,o),f.prototype.name="websocket",f.prototype.supportsBinary=!0,f.prototype.doOpen=function(){if(this.check()){var t=this.uri(),e=this.protocols,n={agent:this.agent,perMessageDeflate:this.perMessageDeflate};n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized,this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket&&!this.isReactNative?e?new u(t,e):new u(t):new u(t,e,n)}catch(t){return this.emit("error",t)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},f.prototype.addEventListeners=function(){var t=this;this.ws.onopen=function(){t.onOpen()},this.ws.onclose=function(){t.onClose()},this.ws.onmessage=function(e){t.onData(e.data)},this.ws.onerror=function(e){t.onError("websocket error",e)}},f.prototype.write=function(t){var n=this;this.writable=!1;for(var r=t.length,i=0,o=r;i Start Log',console.log("stopping log, "+d),h=new Date,a+"\r\n\r\nLog End for "+l+": "+h.getFullYear()+"/"+(h.getMonth()+1)+"/"+h.getDate()+" @ "+h.getHours()+":"+h.getMinutes()+":"+h.getSeconds()+"\r\n"):(_=d=!0,logBtn.innerHTML=' Stop Log',downloadLogBtn.style.color="#000",downloadLogBtn.addEventListener("click",T),console.log("starting log, "+d),h=new Date,"Log Start for "+l+": "+h.getFullYear()+"/"+(h.getMonth()+1)+"/"+h.getDate()+" @ "+h.getHours()+":"+h.getMinutes()+":"+h.getSeconds()+"\r\n\r\n"),c=h,y.focus(),!1}function T(){var t,e;!0===_&&(u="WebSSH2-"+c.getFullYear()+(c.getMonth()+1)+c.getDate()+"_"+c.getHours()+c.getMinutes()+c.getSeconds()+".log",t=new Blob([a.replace(/[\u001b\u009b][[\]()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><;]/g,"")],{type:"text/plain"}),window.navigator.msSaveOrOpenBlob?window.navigator.msSaveBlob(t,u):((e=window.document.createElement("a")).href=window.URL.createObjectURL(t),e.download=u,document.body.appendChild(e),e.click(),document.body.removeChild(e))),y.focus()}y.open(S),y.focus(),y.fit(),window.addEventListener("resize",E,!1),p=r.connect({path:"/ssh/socket.io"}),y.on("data",(function(t){p.emit("data",t)})),p.on("data",(function(t){y.write(t),d&&(a+=t)})),p.on("connect",(function(){p.emit("geometry",y.cols,y.rows)})),p.on("setTerminalOpts",(function(t){y.setOption("cursorBlink",t.cursorBlink),y.setOption("scrollback",t.scrollback),y.setOption("tabStopWidth",t.tabStopWidth),y.setOption("bellStyle",t.bellStyle)})),p.on("title",(function(t){document.title=t})),p.on("menu",(function(t){A(t)})),p.on("status",(function(t){C.innerHTML=t})),p.on("ssherror",(function(t){C.innerHTML=t,C.style.backgroundColor="red",f=!0})),p.on("headerBackground",(function(t){b.style.backgroundColor=t})),p.on("header",(function(t){t&&(b.innerHTML=t,b.style.display="block",S.style.height="calc(100% - 38px)",E())})),p.on("footer",(function(t){l=t,w.innerHTML=t})),p.on("statusBackground",(function(t){C.style.backgroundColor=t})),p.on("allowreplay",(function(t){!0===t?(console.log("allowreplay: "+t),m=!0,A(v.innerHTML+' Credentials')):(m=!1,console.log("allowreplay: "+t))})),p.on("allowreauth",(function(t){!0===t?(console.log("allowreauth: "+t),g=!0,A(v.innerHTML+' Switch User')):(g=!1,console.log("allowreauth: "+t))})),p.on("disconnect",(function(t){f||(C.style.backgroundColor="red",C.innerHTML="WEBSOCKET SERVER DISCONNECTED: "+t),p.io.reconnection(!1)})),p.on("error",(function(t){f||(C.style.backgroundColor="red",C.innerHTML="ERROR: "+t)})),p.on("reauth",(function(){g&&x()})),y.on("title",(function(t){document.title=t}))},function(t,e){},,,,,function(t,e){}]); \ No newline at end of file +!function(t){var e={};function n(r){var i;return(e[r]||(i=e[r]={i:r,l:!1,exports:{}},t[r].call(i.exports,i,i.exports,n),i.l=!0,i)).exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=53)}([function(t,e,n){var r,i=n(41),o=n(20),s=n(42),a=n(43),l=n(44),c=("undefined"!=typeof ArrayBuffer&&(r=n(45)),"undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent)),h="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),u=c||h,f=(e.protocol=3,e.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6}),p=i(f),d={type:"error",data:"parser error"},m=n(46);function _(t,e,n){for(var r=new Array(t.length),i=a(t.length,n),o=0;o=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|t}function d(t,e){if(l.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;var n=(t="string"!=typeof t?""+t:t).length;if(0===n)return 0;for(var r=!1;;)switch(e){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return M(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return D(t).length;default:if(r)return M(t).length;e=(""+e).toLowerCase(),r=!0}}function m(t,e,n){var i,o=!1;if((e=void 0===e||e<0?0:e)>this.length)return"";if((n=void 0===n||n>this.length?this.length:n)<=0)return"";if((n>>>=0)<=(e>>>=0))return"";for(t=t||"utf8";;)switch(t){case"hex":var s=e,a=n,l=this.length;(!a||a<0||l=t.length){if(i)return-1;n=t.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof e&&(e=l.from(e,r)),l.isBuffer(e))return 0===e.length?-1:y(t,e,n,r,i);if("number"==typeof e)return e&=255,l.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?(i?Uint8Array.prototype.indexOf:Uint8Array.prototype.lastIndexOf).call(t,e,n):y(t,[e],n,r,i);throw new TypeError("val must be string, number or Buffer")}function y(t,e,n,r,i){var o=1,s=t.length,a=e.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(t.length<2||e.length<2)return-1;s/=o=2,a/=2,n/=2}function l(t,e){return 1===o?t[e]:t.readUInt16BE(e*o)}if(i)for(var c=-1,h=n;h>8,i.push(n%256),i.push(r);return i}(e,t.length-n),t,n,r)}function C(t,e,n){n=Math.min(t.length,n);for(var r=[],i=e;i>>10&1023|55296),h=56320|1023&h),r.push(h),i+=u}var f=r,p=f.length;if(p<=w)return String.fromCharCode.apply(String,f);for(var d="",m=0;mn)&&(t+=" ... "),""},l.prototype.compare=function(t,e,n,r,i){if(!l.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===n&&(n=t?t.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),(e=void 0===e?0:e)<0||n>t.length||r<0||i>this.length)throw new RangeError("out of range index");if(i<=r&&n<=e)return 0;if(i<=r)return-1;if(n<=e)return 1;if(this===t)return 0;for(var o=(i>>>=0)-(r>>>=0),s=(n>>>=0)-(e>>>=0),a=Math.min(o,s),c=this.slice(r,i),h=t.slice(e,n),u=0;uthis.length)throw new RangeError("Attempt to write outside buffer bounds");r=r||"utf8";for(var o,s,a,l=!1;;)switch(r){case"hex":var c=t,h=e,u=n,f=(h=Number(h)||0,this.length-h);if((!u||f<(u=Number(u)))&&(u=f),(f=c.length)%2!=0)throw new TypeError("Invalid hex string");f/2t.length)throw new RangeError("Index out of range")}function E(t,e,n,r){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-n,2);i>>8*(r?i:1-i)}function x(t,e,n,r){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-n,4);i>>8*(r?i:3-i)&255}function A(t,e,n,r){if(n+r>t.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function L(t,e,n,r,o){return o||A(t,0,n,4),i.write(t,e,n,r,23,4),n+4}function T(t,e,n,r,o){return o||A(t,0,n,8),i.write(t,e,n,r,52,8),n+8}l.prototype.slice=function(t,e){var n=this.length;if((t=~~t)<0?(t+=n)<0&&(t=0):n>>8):E(this,t,e,!0),e+2},l.prototype.writeUInt16BE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,2,65535,0),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):E(this,t,e,!1),e+2},l.prototype.writeUInt32LE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,4,4294967295,0),l.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):x(this,t,e,!0),e+4},l.prototype.writeUInt32BE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,4,4294967295,0),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):x(this,t,e,!1),e+4},l.prototype.writeIntLE=function(t,e,n,r){t=+t,e|=0,r||S(this,t,e,n,(r=Math.pow(2,8*n-1))-1,-r);var i=0,o=1,s=0;for(this[e]=255&t;++i>0)-s&255;return e+n},l.prototype.writeIntBE=function(t,e,n,r){t=+t,e|=0,r||S(this,t,e,n,(r=Math.pow(2,8*n-1))-1,-r);var i=n-1,o=1,s=0;for(this[e+i]=255&t;0<=--i&&(o*=256);)t<0&&0===s&&0!==this[e+i+1]&&(s=1),this[e+i]=(t/o>>0)-s&255;return e+n},l.prototype.writeInt8=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,1,127,-128),l.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&(t=t<0?255+t+1:t),e+1},l.prototype.writeInt16LE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,2,32767,-32768),l.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):E(this,t,e,!0),e+2},l.prototype.writeInt16BE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,2,32767,-32768),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):E(this,t,e,!1),e+2},l.prototype.writeInt32LE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,4,2147483647,-2147483648),l.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):x(this,t,e,!0),e+4},l.prototype.writeInt32BE=function(t,e,n){return t=+t,e|=0,n||S(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),l.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):x(this,t,e,!1),e+4},l.prototype.writeFloatLE=function(t,e,n){return L(this,t,e,!0,n)},l.prototype.writeFloatBE=function(t,e,n){return L(this,t,e,!1,n)},l.prototype.writeDoubleLE=function(t,e,n){return T(this,t,e,!0,n)},l.prototype.writeDoubleBE=function(t,e,n){return T(this,t,e,!1,n)},l.prototype.copy=function(t,e,n,r){if(n=n||0,r||0===r||(r=this.length),e>=t.length&&(e=t.length),(r=0=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length);var i,o=(r=t.length-e>>=0,n=void 0===n?this.length:n>>>0,"number"==typeof(t=t||0))for(a=e;a>6|192,63&n|128)}else if(n<65536){if((e-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function D(t){return r.toByteArray(function(t){var e;if((t=((e=t).trim?e.trim():e.replace(/^\s+|\s+$/g,"")).replace(R,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function O(t,e,n,r){for(var i=0;i=e.length||i>=t.length);++i)e[i+n]=t[i];return i}}).call(this,n(16))},function(t,e,n){var r=n(39);t.exports=function(t){var e=t.xdomain,n=t.xscheme;t=t.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!e||r))return new XMLHttpRequest}catch(t){}try{if("undefined"!=typeof XDomainRequest&&!n&&t)return new XDomainRequest}catch(t){}if(!e)try{return new(self[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(t){}}},function(t,e,n){var r=n(0);function i(t){this.path=t.path,this.hostname=t.hostname,this.port=t.port,this.secure=t.secure,this.query=t.query,this.timestampParam=t.timestampParam,this.timestampRequests=t.timestampRequests,this.readyState="",this.agent=t.agent||!1,this.socket=t.socket,this.enablesXDR=t.enablesXDR,this.pfx=t.pfx,this.key=t.key,this.passphrase=t.passphrase,this.cert=t.cert,this.ca=t.ca,this.ciphers=t.ciphers,this.rejectUnauthorized=t.rejectUnauthorized,this.forceNode=t.forceNode,this.isReactNative=t.isReactNative,this.extraHeaders=t.extraHeaders,this.localAddress=t.localAddress}n(1)((t.exports=i).prototype),i.prototype.onError=function(t,e){return(t=new Error(t)).type="TransportError",t.description=e,this.emit("error",t),this},i.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},i.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},i.prototype.send=function(t){if("open"!==this.readyState)throw new Error("Transport not open");this.write(t)},i.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},i.prototype.onData=function(t){t=r.decodePacket(t,this.socket.binaryType),this.onPacket(t)},i.prototype.onPacket=function(t){this.emit("packet",t)},i.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(t,e,n){t.exports=function t(e,n,r){function i(o,s){if(!n[o]){var a;if(!e[o])throw(a=new Error("Cannot find module '"+o+"'")).code="MODULE_NOT_FOUND",a;a=n[o]={exports:{}},e[o][0].call(a.exports,(function(t){return i(e[o][1][t]||t)}),a,a.exports,t,e,n,r)}return n[o].exports}for(var o=0;ot;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()},f.prototype._createAccessibilityTreeNode=function(){var t=document.createElement("div");return t.setAttribute("role","listitem"),t.tabIndex=-1,this._refreshRowDimensions(t),t},f.prototype._onTab=function(t){for(var e=0;ethis._rows},enumerable:!0,configurable:!0}),Object.defineProperty(a.prototype,"isCursorInViewport",{get:function(){var t=this.ybase+this.y-this.ydisp;return 0<=t&&tn.MAX_BUFFER_SIZE?n.MAX_BUFFER_SIZE:e:t},a.prototype.fillViewportRows=function(t){if(0===this.lines.length){void 0===t&&(t=i.DEFAULT_ATTR_DATA);for(var e=this._rows;e--;)this.lines.push(this.getBlankLine(t))}},a.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()},a.prototype.resize=function(t,e){var n=this.getNullCell(i.DEFAULT_ATTR_DATA),r=this._getCorrectBufferLength(e);if(r>this.lines.maxLength&&(this.lines.maxLength=r),0e+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));rt))for(o=0;othis._cols?this._reflowLarger(t,e):this._reflowSmaller(t,e))},a.prototype._reflowLarger=function(t,e){var n=o.reflowLargerGetLinesToRemove(this.lines,this._cols,t,this.ybase+this.y,this.getNullCell(i.DEFAULT_ATTR_DATA));0x+T){for(var R=L.newLines.length-1;0<=R;R--)this.lines.set(m--,L.newLines[R]);m++,k.push({index:x+1,amount:L.newLines.length}),T+=L.newLines.length,L=r[++A]}else this.lines.set(m,S[x--]);var M=0;for(m=k.length-1;0<=m;m--)k[m].index+=M,this.lines.onInsertEmitter.fire(k[m]),M+=k[m].amount;0<(E=Math.max(0,E+s-this.lines.maxLength))&&this.lines.onTrimEmitter.fire(E)}},a.prototype.stringIndexToBufferIndex=function(t,e,n){for(void 0===n&&(n=!1);e;){var r=this.lines.get(t);if(!r)return[-1,-1];for(var o=n?r.getTrimmedLength():r.length,s=0;s=this._cols?this._cols-1:t<0?0:t},a.prototype.nextStop=function(t){for(null==t&&(t=this.x);!this.tabs[++t]&&t=this._cols?this._cols-1:t<0?0:t},a.prototype.addMarker=function(t){var e=this,n=new s.Marker(t);return this.markers.push(n),n.register(this.lines.onTrim((function(t){n.line-=t,n.line<0&&n.dispose()}))),n.register(this.lines.onInsert((function(t){n.line>=t.index&&(n.line+=t.amount)}))),n.register(this.lines.onDelete((function(t){n.line>=t.index&&n.linet.index&&(n.line-=t.amount)}))),n.register(n.onDispose((function(){return e._removeMarker(n)}))),n},a.prototype._removeMarker=function(t){this.markers.splice(this.markers.indexOf(t),1)},a.prototype.iterator=function(t,e,n,r,i){return new l(this,t,e,n,r,i)},t=a;function a(t,e){this._terminal=t,this._hasScrollback=e,this.savedCurAttrData=i.DEFAULT_ATTR_DATA.clone(),this.markers=[],this._nullCell=i.CellData.fromCharData([0,i.NULL_CELL_CHAR,i.NULL_CELL_WIDTH,i.NULL_CELL_CODE]),this._whitespaceCell=i.CellData.fromCharData([0,i.WHITESPACE_CELL_CHAR,i.WHITESPACE_CELL_WIDTH,i.WHITESPACE_CELL_CODE]),this._cols=this._terminal.cols,this._rows=this._terminal.rows,this.clear()}n.Buffer=t,c.prototype.hasNext=function(){return this._currentthis._endIndex+this._endOverscan&&(t.last=this._endIndex+this._endOverscan),t.first=Math.max(t.first,0),t.last=Math.min(t.last,this._buffer.lines.length),""),n=t.first;n<=t.last;++n)e+=this._buffer.translateBufferLineToString(n,this._trimRight);return this._current=t.last+1,{range:t,content:e}};var l=c;function c(t,e,n,r,i,o){void 0===n&&(n=0),void 0===r&&(r=t.lines.length),void 0===i&&(i=0),void 0===o&&(o=0),this._buffer=t,this._trimRight=e,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}n.BufferStringIterator=l},{"./common/CircularList":20,"./core/buffer/BufferLine":29,"./core/buffer/BufferReflow":30,"./core/buffer/Marker":31}],3:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("./Buffer"),i=t("./common/EventEmitter2");function o(t){this._terminal=t,this._onBufferActivate=new i.EventEmitter2,this._normal=new r.Buffer(this._terminal,!0),this._normal.fillViewportRows(),this._alt=new r.Buffer(this._terminal,!1),this._activeBuffer=this._normal,this.setupTabStops()}Object.defineProperty(o.prototype,"onBufferActivate",{get:function(){return this._onBufferActivate.event},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"alt",{get:function(){return this._alt},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"active",{get:function(){return this._activeBuffer},enumerable:!0,configurable:!0}),Object.defineProperty(o.prototype,"normal",{get:function(){return this._normal},enumerable:!0,configurable:!0}),o.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}))},o.prototype.activateAltBuffer=function(t){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(t),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}))},o.prototype.resize=function(t,e){this._normal.resize(t,e),this._alt.resize(t,e)},o.prototype.setupTabStops=function(t){this._normal.setupTabStops(t),this._alt.setupTabStops(t)},n.BufferSet=o},{"./Buffer":2,"./common/EventEmitter2":23}],4:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("./common/EventEmitter2");function i(t,e){this._onCharSizeChanged=new r.EventEmitter2,this._document=t,this._parentElement=e,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)}Object.defineProperty(i.prototype,"onCharSizeChanged",{get:function(){return this._onCharSizeChanged.event},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"width",{get:function(){return this._width},enumerable:!0,configurable:!0}),Object.defineProperty(i.prototype,"height",{get:function(){return this._height},enumerable:!0,configurable:!0}),i.prototype.measure=function(t){var e;this._measureElement.style.fontFamily=t.fontFamily,this._measureElement.style.fontSize=t.fontSize+"px",0!==(t=this._measureElement.getBoundingClientRect()).width&&0!==t.height&&(e=Math.ceil(t.height),this._width!==t.width||this._height!==e)&&(this._width=t.width,this._height=e,this._onCharSizeChanged.fire())},n.CharMeasure=i},{"./common/EventEmitter2":23}],5:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("./common/TypedArrayUtils");n.wcwidth=function(t){var e=[[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]],n=[[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]];var i=0|t.control,o=new Uint8Array(65536);r.fill(o,1),o[0]=t.nul,r.fill(o,t.control,1,32),r.fill(o,t.control,127,160),r.fill(o,2,4352,4448),o[9001]=2,o[9002]=2,r.fill(o,2,11904,42192),o[12351]=1,r.fill(o,2,44032,55204),r.fill(o,2,63744,64256),r.fill(o,2,65040,65050),r.fill(o,2,65072,65136),r.fill(o,2,65280,65377),r.fill(o,2,65504,65511);for(var s=0;se[i][1]))for(;r<=i;)if(t>e[n=r+i>>1][1])r=1+n;else{if(!(t=r)return e+n.wcwidth(o);var s=t.charCodeAt(i);56320<=s&&s<=57343?o=1024*(o-55296)+s-56320+65536:e+=n.wcwidth(s)}e+=n.wcwidth(o)}return e}},{"./common/TypedArrayUtils":26}],6:[function(t,e,n){function r(t){return t.replace(/\r?\n/g,"\r")}function i(t,e){return e?"[200~"+t+"[201~":t}function o(t,e){var n=e.screenElement.getBoundingClientRect(),r=t.clientX-n.left-10;t=t.clientY-n.top-10;e.textarea.style.position="absolute",e.textarea.style.width="20px",e.textarea.style.height="20px",e.textarea.style.left=r+"px",e.textarea.style.top=t+"px",e.textarea.style.zIndex="1000",e.textarea.focus(),setTimeout((function(){e.textarea.style.position=null,e.textarea.style.width=null,e.textarea.style.height=null,e.textarea.style.left=null,e.textarea.style.top=null,e.textarea.style.zIndex=null}),200)}Object.defineProperty(n,"__esModule",{value:!0}),n.prepareTextForTerminal=r,n.bracketTextForPaste=i,n.copyHandler=function(t,e,n){e.browser.isMSIE?window.clipboardData.setData("Text",n.selectionText):t.clipboardData.setData("text/plain",n.selectionText),t.preventDefault()},n.pasteHandler=function(t,e){function n(n){n=i(n=r(n),e.bracketedPasteMode),e.handler(n),e.textarea.value="",e.emit("paste",n),e.cancel(t)}t.stopPropagation(),e.browser.isMSIE?window.clipboardData&&n(window.clipboardData.getData("Text")):t.clipboardData&&n(t.clipboardData.getData("text/plain"))},n.moveTextAreaUnderMouseCursor=o,n.rightClickHandler=function(t,e,n,r){o(t,e),r&&!n.isClickInSelection(t)&&n.selectWordAtCursor(t),e.textarea.value=n.selectionText,e.textarea.select()}},{}],7:[function(t,e,n){function r(t,e,n){this._textarea=t,this._compositionView=e,this._terminal=n,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:null,end:null}}Object.defineProperty(n,"__esModule",{value:!0}),r.prototype.compositionstart=function(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._compositionView.classList.add("active")},r.prototype.compositionupdate=function(t){var e=this;this._compositionView.textContent=t.data,this.updateCompositionElements(),setTimeout((function(){e._compositionPosition.end=e._textarea.value.length}),0)},r.prototype.compositionend=function(){this._finalizeComposition(!0)},r.prototype.keydown=function(t){if(this._isComposing||this._isSendingComposition){if(229===t.keyCode)return!1;if(16===t.keyCode||17===t.keyCode||18===t.keyCode)return!1;this._finalizeComposition(!1)}return 229!==t.keyCode||(this._handleAnyTextareaChanges(),!1)},r.prototype._finalizeComposition=function(t){var e,n=this;this._compositionView.classList.remove("active"),this._isComposing=!1,this._clearTextareaPosition(),t?(e={start:this._compositionPosition.start,end:this._compositionPosition.end},this._isSendingComposition=!0,setTimeout((function(){var t;n._isSendingComposition&&(n._isSendingComposition=!1,void 0,t=n._isComposing?n._textarea.value.substring(e.start,e.end):n._textarea.value.substring(e.start),n._terminal.handler(t))}),0)):(this._isSendingComposition=!1,t=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end),this._terminal.handler(t))},r.prototype._handleAnyTextareaChanges=function(){var t=this,e=this._textarea.value;setTimeout((function(){var n;t._isComposing||0<(n=t._textarea.value.replace(e,"")).length&&t._terminal.handler(n)}),0)},r.prototype.updateCompositionElements=function(t){var e,n,r,i=this;this._isComposing&&(this._terminal.buffer.isCursorInViewport&&(r=Math.ceil(this._terminal.charMeasure.height*this._terminal.options.lineHeight),e=this._terminal.buffer.y*r,n=this._terminal.buffer.x*this._terminal.charMeasure.width,this._compositionView.style.left=n+"px",this._compositionView.style.top=e+"px",this._compositionView.style.height=r+"px",this._compositionView.style.lineHeight=r+"px",this._compositionView.style.fontFamily=this._terminal.options.fontFamily,this._compositionView.style.fontSize=this._terminal.options.fontSize+"px",r=this._compositionView.getBoundingClientRect(),this._textarea.style.left=n+"px",this._textarea.style.top=e+"px",this._textarea.style.width=r.width+"px",this._textarea.style.height=r.height+"px",this._textarea.style.lineHeight=r.height+"px"),t||setTimeout((function(){return i.updateCompositionElements(!0)}),0))},r.prototype._clearTextareaPosition=function(){this._textarea.style.left="",this._textarea.style.top=""},n.CompositionHelper=r},{}],8:[function(t,e,n){var r,i=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),o=(Object.defineProperty(n,"__esModule",{value:!0}),t("./common/Lifecycle")),s=t("./core/input/TextDecoder");function a(t,e){for(var n=e-t,r=new Array(n);n--;)r[n]=--e;return r}c.prototype.add=function(t,e,n,r){this.table[e<<8|t]=(0|n)<<4|(void 0===r?e:r)},c.prototype.addMany=function(t,e,n,r){for(var i=0;i>4){case 2:a=~a?a:m;break;case 3:~a&&(this._printHandler(t,a,m),a=-1),(d=this._executeHandlers[n])?d():this._executeHandlerFb(n);break;case 0:~a?(this._printHandler(t,a,m),a=-1):~l&&(p.put(t,l,m),l=-1);break;case 1:if(159=s)if(l)r.x=0,r.y++,r.y>r.scrollBottom?(r.y--,this._terminal.scroll(!0)):r.lines.get(r.y).isWrapped=!0,p=r.lines.get(r.y+r.ybase);else if(2===g)continue;if(c&&(p.insertCells(r.x,g,r.getNullCell(h)),2===p.getWidth(s-1))&&p.setCellFromCodePoint(s-1,f.NULL_CELL_CODE,f.NULL_CELL_WIDTH,h.fg,h.bg),p.setCellFromCodePoint(r.x++,_,g,h.fg,h.bg),0t.scrollBottom&&(t.y--,this._terminal.scroll()),t.x>=this._terminal.cols&&t.x--,this._onLineFeed.fire()},y.prototype.carriageReturn=function(){this._terminal.buffer.x=0},y.prototype.backspace=function(){0=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x>=this._terminal.cols&&this._terminal.buffer.x--},y.prototype.cursorForward=function(t){t=t[0],this._terminal.buffer.x+=t=t<1?1:t,this._terminal.buffer.x>=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.cursorBackward=function(t){(t=t[0])<1&&(t=1),this._terminal.buffer.x>=this._terminal.cols&&this._terminal.buffer.x--,this._terminal.buffer.x-=t,this._terminal.buffer.x<0&&(this._terminal.buffer.x=0)},y.prototype.cursorNextLine=function(t){t=t[0],this._terminal.buffer.y+=t=t<1?1:t,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x=0},y.prototype.cursorPrecedingLine=function(t){t=t[0],this._terminal.buffer.y-=t=t<1?1:t,this._terminal.buffer.y<0&&(this._terminal.buffer.y=0),this._terminal.buffer.x=0},y.prototype.cursorCharAbsolute=function(t){t=t[0],this._terminal.buffer.x=(t=t<1?1:t)-1},y.prototype.cursorPosition=function(t){var e=t[0]-1;t=2<=t.length?t[1]-1:0;e<0?e=0:e>=this._terminal.rows&&(e=this._terminal.rows-1),t<0?t=0:t>=this._terminal.cols&&(t=this._terminal.cols-1),this._terminal.buffer.x=t,this._terminal.buffer.y=e},y.prototype.cursorForwardTab=function(t){for(var e=t[0]||1;e--;)this._terminal.buffer.x=this._terminal.buffer.nextStop()},y.prototype._eraseInBufferLine=function(t,e,n,r){void 0===r&&(r=!1),(t=this._terminal.buffer.lines.get(this._terminal.buffer.ybase+t)).replaceCells(e,n,this._terminal.buffer.getNullCell(this._terminal.eraseAttrData())),r&&(t.isWrapped=!1)},y.prototype._resetBufferLine=function(t){this._eraseInBufferLine(t,0,this._terminal.cols,!0)},y.prototype.eraseInDisplay=function(t){var e;switch(t[0]){case 0:for(e=this._terminal.buffer.y,this._terminal.updateRange(e),this._eraseInBufferLine(e++,this._terminal.buffer.x,this._terminal.cols,0===this._terminal.buffer.x);e=this._terminal.cols&&(this._terminal.buffer.lines.get(e+1).isWrapped=!1);e--;)this._resetBufferLine(e);this._terminal.updateRange(0);break;case 2:for(e=this._terminal.rows,this._terminal.updateRange(e-1);e--;)this._resetBufferLine(e);this._terminal.updateRange(0);break;case 3:var n=this._terminal.buffer.lines.length-this._terminal.rows;0=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.hPositionRelative=function(t){t=t[0],this._terminal.buffer.x+=t=t<1?1:t,this._terminal.buffer.x>=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.repeatPrecedingCharacter=function(t){var e=this._terminal.buffer,n=e.lines.get(e.ybase+e.y);n.loadCell(e.x-1,this._workCell),n.replaceCells(e.x,e.x+(t[0]||1),void 0!==this._workCell.content?this._workCell:e.getNullCell(f.DEFAULT_ATTR_DATA))},y.prototype.sendDeviceAttributes=function(t,e){0"===e&&(this._terminal.is("xterm")?this._terminal.handler(o.C0.ESC+"[>0;276;0c"):this._terminal.is("rxvt-unicode")?this._terminal.handler(o.C0.ESC+"[>85;95;0c"):this._terminal.is("linux")?this._terminal.handler(t[0]+"c"):this._terminal.is("screen")&&this._terminal.handler(o.C0.ESC+"[>83;40003;0c")):this._terminal.is("xterm")||this._terminal.is("rxvt-unicode")||this._terminal.is("screen")?this._terminal.handler(o.C0.ESC+"[?1;2c"):this._terminal.is("linux")&&this._terminal.handler(o.C0.ESC+"[?6c"))},y.prototype.linePosAbsolute=function(t){t=t[0],this._terminal.buffer.y=(t=t<1?1:t)-1,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1)},y.prototype.vPositionRelative=function(t){t=t[0],this._terminal.buffer.y+=t=t<1?1:t,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x>=this._terminal.cols&&this._terminal.buffer.x--},y.prototype.hVPosition=function(t){t[0]<1&&(t[0]=1),t[1]<1&&(t[1]=1),this._terminal.buffer.y=t[0]-1,this._terminal.buffer.y>=this._terminal.rows&&(this._terminal.buffer.y=this._terminal.rows-1),this._terminal.buffer.x=t[1]-1,this._terminal.buffer.x>=this._terminal.cols&&(this._terminal.buffer.x=this._terminal.cols-1)},y.prototype.tabClear=function(t){(t=t[0])<=0?delete this._terminal.buffer.tabs[this._terminal.buffer.x]:3===t&&(this._terminal.buffer.tabs={})},y.prototype.setMode=function(t,e){if(1",(function(){return r.keypadNumericMode()})),r._parser.setEscHandler("c",(function(){return r.reset()})),r._parser.setEscHandler("n",(function(){return r.setgLevel(2)})),r._parser.setEscHandler("o",(function(){return r.setgLevel(3)})),r._parser.setEscHandler("|",(function(){return r.setgLevel(3)})),r._parser.setEscHandler("}",(function(){return r.setgLevel(2)})),r._parser.setEscHandler("~",(function(){return r.setgLevel(1)})),r._parser.setEscHandler("%@",(function(){return r.selectDefaultCharset()})),r._parser.setEscHandler("%G",(function(){return r.selectDefaultCharset()})),this);for(n in s.CHARSETS)!function(t){i._parser.setEscHandler("("+t,(function(){return r.selectCharset("("+t)})),i._parser.setEscHandler(")"+t,(function(){return r.selectCharset(")"+t)})),i._parser.setEscHandler("*"+t,(function(){return r.selectCharset("*"+t)})),i._parser.setEscHandler("+"+t,(function(){return r.selectCharset("+"+t)})),i._parser.setEscHandler("-"+t,(function(){return r.selectCharset("-"+t)})),i._parser.setEscHandler("."+t,(function(){return r.selectCharset("."+t)})),i._parser.setEscHandler("/"+t,(function(){return r.selectCharset("/"+t)}))}(n);return r._parser.setErrorHandler((function(t){return r._terminal.error("Parsing error: ",t),t})),r._parser.setDcsHandler("$q",new m(r._terminal)),r}n.InputHandler=t},{"./CharWidth":5,"./EscapeSequenceParser":8,"./common/EventEmitter2":23,"./common/Lifecycle":24,"./common/TypedArrayUtils":26,"./common/data/EscapeSequences":28,"./core/buffer/BufferLine":29,"./core/data/Charsets":32,"./core/input/TextDecoder":34}],10:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("./MouseZoneManager"),i=t("./CharWidth"),o=t("./common/EventEmitter2");function s(t){this._terminal=t,this._linkMatchers=[],this._nextLinkMatcherId=0,this._onLinkHover=new o.EventEmitter2,this._onLinkLeave=new o.EventEmitter2,this._onLinkTooltip=new o.EventEmitter2,this._rowsToLinkify={start:null,end:null}}Object.defineProperty(s.prototype,"onLinkHover",{get:function(){return this._onLinkHover.event},enumerable:!0,configurable:!0}),Object.defineProperty(s.prototype,"onLinkLeave",{get:function(){return this._onLinkLeave.event},enumerable:!0,configurable:!0}),Object.defineProperty(s.prototype,"onLinkTooltip",{get:function(){return this._onLinkTooltip.event},enumerable:!0,configurable:!0}),s.prototype.attachToDom=function(t){this._mouseZoneManager=t},s.prototype.linkifyRows=function(t,e){var n=this;this._mouseZoneManager&&(null===this._rowsToLinkify.start?(this._rowsToLinkify.start=t,this._rowsToLinkify.end=e):(this._rowsToLinkify.start=Math.min(this._rowsToLinkify.start,t),this._rowsToLinkify.end=Math.max(this._rowsToLinkify.end,e)),this._mouseZoneManager.clearAll(t,e),this._rowsTimeoutId&&clearTimeout(this._rowsTimeoutId),this._rowsTimeoutId=setTimeout((function(){return n._linkifyRows()}),s.TIME_BEFORE_LINKIFY))},s.prototype._linkifyRows=function(){this._rowsTimeoutId=null;var t=(e=this._terminal.buffer).ydisp+this._rowsToLinkify.start;if(!(t>=e.lines.length)){for(var e=e.ydisp+Math.min(this._rowsToLinkify.end,this._terminal.rows)+1,n=Math.ceil(s.OVERSCAN_CHAR_LIMIT/this._terminal.cols),r=this._terminal.buffer.iterator(!1,t,e,n,n);r.hasNext();)for(var i=r.next(),o=0;o>9&511),void(n.validationCallback?n.validationCallback(u,(function(t){i._rowsTimeoutId||t&&i._addLink(l[1],l[0]-i._terminal.buffer.ydisp,u,n,h)})):a._addLink(l[1],l[0]-a._terminal.buffer.ydisp,u,n,h)));if(a._terminal.debug)throw console.log({match:r,matcher:n}),new Error("match found without corresponding matchIndex");return"break"}(););},s.prototype._addLink=function(t,e,n,o,s){var a=this,l=i.getStringCellWidth(n),c=t%this._terminal.cols,h=e+Math.floor(t/this._terminal.cols),u=(c+l)%this._terminal.cols,f=h+Math.floor((c+l)/this._terminal.cols);0===u&&(u=this._terminal.cols,f--),this._mouseZoneManager.add(new r.MouseZone(1+c,h+1,u+1,f+1,(function(t){if(o.handler)return o.handler(t,n);window.open(n,"_blank")}),(function(){a._onLinkHover.fire(a._createLinkHoverEvent(c,h,u,f,s)),a._terminal.element.classList.add("xterm-cursor-pointer")}),(function(t){a._onLinkTooltip.fire(a._createLinkHoverEvent(c,h,u,f,s)),o.hoverTooltipCallback&&o.hoverTooltipCallback(t,n)}),(function(){a._onLinkLeave.fire(a._createLinkHoverEvent(c,h,u,f,s)),a._terminal.element.classList.remove("xterm-cursor-pointer"),o.hoverLeaveCallback&&o.hoverLeaveCallback()}),(function(t){return!o.willLinkActivate||o.willLinkActivate(t,n)})))},s.prototype._createLinkHoverEvent=function(t,e,n,r,i){return{x1:t,y1:e,x2:n,y2:r,cols:this._terminal.cols,fg:i}},s.TIME_BEFORE_LINKIFY=200,s.OVERSCAN_CHAR_LIMIT=2e3,n.Linkifier=s},{"./CharWidth":5,"./MouseZoneManager":12,"./common/EventEmitter2":23}],11:[function(t,e,n){function r(t){this._renderCoordinator=t}Object.defineProperty(n,"__esModule",{value:!0}),r.getCoordsRelativeToElement=function(t,e){return e=e.getBoundingClientRect(),[t.clientX-e.left,t.clientY-e.top]},r.prototype.getCoords=function(t,e,n,i,o,s){return n.width&&n.height&&(n=r.getCoordsRelativeToElement(t,e))?(n[0]=Math.ceil((n[0]+(s?this._renderCoordinator.dimensions.actualCellWidth/2:0))/this._renderCoordinator.dimensions.actualCellWidth),n[1]=Math.ceil(n[1]/this._renderCoordinator.dimensions.actualCellHeight),n[0]=Math.min(Math.max(n[0],1),i+(s?1:0)),n[1]=Math.min(Math.max(n[1],1),o),n):null},r.prototype.getRawByteCoords=function(t,e,n,r,i){return e=(t=this.getCoords(t,e,n,r,i))[0],n=t[1],{x:e+=32,y:n+=32}},n.MouseHelper=r},{}],12:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),s=(Object.defineProperty(n,"__esModule",{value:!0}),t("./common/Lifecycle")),a=t("./ui/Lifecycle");o(l,i=s.Disposable),l.prototype.dispose=function(){i.prototype.dispose.call(this),this._deactivate()},l.prototype.add=function(t){this._zones.push(t),1===this._zones.length&&this._activate()},l.prototype.clearAll=function(t,e){if(0!==this._zones.length){e||(t=0,e=this._terminal.rows-1);for(var n=0;nt&&r.y1<=e+1||r.y2>t&&r.y2<=e+1||r.y1e+1)&&(this._currentZone&&this._currentZone===r&&(this._currentZone.leaveCallback(),this._currentZone=null),this._zones.splice(n--,1))}0===this._zones.length&&this._deactivate()}},l.prototype._activate=function(){this._areZonesActive||(this._areZonesActive=!0,this._terminal.element.addEventListener("mousemove",this._mouseMoveListener),this._terminal.element.addEventListener("mouseleave",this._mouseLeaveListener),this._terminal.element.addEventListener("click",this._clickListener))},l.prototype._deactivate=function(){this._areZonesActive&&(this._areZonesActive=!1,this._terminal.element.removeEventListener("mousemove",this._mouseMoveListener),this._terminal.element.removeEventListener("mouseleave",this._mouseLeaveListener),this._terminal.element.removeEventListener("click",this._clickListener))},l.prototype._onMouseMove=function(t){this._lastHoverCoords[0]===t.pageX&&this._lastHoverCoords[1]===t.pageY||(this._onHover(t),this._lastHoverCoords=[t.pageX,t.pageY])},l.prototype._onHover=function(t){var e=this,n=this._findZoneEventAt(t);n!==this._currentZone&&(this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=null,this._tooltipTimeout)&&clearTimeout(this._tooltipTimeout),n)&&((this._currentZone=n).hoverCallback&&n.hoverCallback(t),this._tooltipTimeout=setTimeout((function(){return e._onTooltip(t)}),500))},l.prototype._onTooltip=function(t){this._tooltipTimeout=null;var e=this._findZoneEventAt(t);e&&e.tooltipCallback&&e.tooltipCallback(t)},l.prototype._onMouseDown=function(t){var e;this._initialSelectionLength=this._terminal.getSelection().length,this._areZonesActive&&(e=this._findZoneEventAt(t))&&e.willLinkActivate(t)&&(t.preventDefault(),t.stopImmediatePropagation())},l.prototype._onMouseLeave=function(t){this._currentZone&&(this._currentZone.leaveCallback(),this._currentZone=null,this._tooltipTimeout)&&clearTimeout(this._tooltipTimeout)},l.prototype._onClick=function(t){var e=this._findZoneEventAt(t),n=this._terminal.getSelection().length;e&&n===this._initialSelectionLength&&(e.clickCallback(t),t.preventDefault(),t.stopImmediatePropagation())},l.prototype._findZoneEventAt=function(t){if(t=this._terminal.mouseHelper.getCoords(t,this._terminal.screenElement,this._terminal.charMeasure,this._terminal.cols,this._terminal.rows))for(var e=t[0],n=t[1],r=0;r=i.x1&&e=i.x1||n===i.y2&&ei.y1&&ne[1]&&t[1]=e[0]&&t[0]=e[0]},h.prototype.selectWordAtCursor=function(t){(t=this._getMouseBufferCoords(t))&&(this._selectWordAt(t,!1),this._model.selectionEnd=null,this.refresh(!0))},h.prototype.selectAll=function(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()},h.prototype.selectLines=function(t,e){this._model.clearSelection(),t=Math.max(t,0),e=Math.min(e,this._terminal.buffer.lines.length-1),this._model.selectionStart=[0,t],this._model.selectionEnd=[this._terminal.cols,e],this.refresh(),this._onSelectionChange.fire()},h.prototype._onTrim=function(t){this._model.onTrim(t)&&this.refresh()},h.prototype._getMouseBufferCoords=function(t){return(t=this._terminal.mouseHelper.getCoords(t,this._terminal.screenElement,this._charMeasure,this._terminal.cols,this._terminal.rows,!0))?(t[0]--,t[1]--,t[1]+=this._terminal.buffer.ydisp,t):null},h.prototype._getMouseEventScrollAmount=function(t){t=r.MouseHelper.getCoordsRelativeToElement(t,this._terminal.screenElement)[1];var e=this._terminal.rows*Math.ceil(this._charMeasure.height*this._terminal.options.lineHeight);return 0<=t&&t<=e?0:(e=this._model.selectionStart[0]||0===t.hasWidth(this._model.selectionStart[0])&&this._model.selectionStart[0]++)},h.prototype._onDoubleClick=function(t){(t=this._getMouseBufferCoords(t))&&(this._activeSelectionMode=1,this._selectWordAt(t,!0))},h.prototype._onTripleClick=function(t){(t=this._getMouseBufferCoords(t))&&(this._activeSelectionMode=2,this._selectLineAt(t[1]))},h.prototype.shouldColumnSelect=function(t){return t.altKey&&!(i.isMac&&this._terminal.options.macOptionClickForcesSelection)},h.prototype._onMouseMove=function(t){t.stopImmediatePropagation();var e=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;this._model.selectionEnd=this._getMouseBufferCoords(t),this._model.selectionEnd&&(2===this._activeSelectionMode?this._model.selectionEnd[1]=r;r++){var i=t.loadCell(r,this._workCell).getChars().length;0===this._workCell.getWidth()?n--:1=this._terminal.cols)return null;var i=this._buffer.lines.get(t[1]);if(!i)return null;var o=this._buffer.translateBufferLineToString(t[1],!1),s=this._convertViewportColToCharacterIndex(i,t),a=s,l=t[0]-s,c=0,h=0,u=0,f=0;if(" "===o.charAt(s)){for(;0this._terminal.cols;)e.length-=this._terminal.cols,n++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?e.start:e.start+e.length,n]}},h.prototype._isCharWordSeparator=function(t){return 0!==t.getWidth()&&0<=" ()[]{}'\"".indexOf(t.getChars())},h.prototype._selectLineAt=function(t){t=this._buffer.getWrappedRangeForLine(t),this._model.selectionStart=[0,t.first],this._model.selectionEnd=[this._terminal.cols,t.last],this._model.selectionStartLength=0},t=h;function h(t,e){this._terminal=t,this._charMeasure=e,this._enabled=!0,this._workCell=new a.CellData,this._onLinuxMouseSelection=new l.EventEmitter2,this._onRedrawRequest=new l.EventEmitter2,this._onSelectionChange=new l.EventEmitter2,this._initListeners(),this.enable(),this._model=new o.SelectionModel(t),this._activeSelectionMode=0}n.SelectionManager=t},{"./MouseHelper":11,"./SelectionModel":14,"./common/EventEmitter2":23,"./common/Platform":25,"./core/buffer/BufferLine":29,"./handlers/AltClickHandler":35}],14:[function(t,e,n){function r(t){this._terminal=t,this.clearSelection()}Object.defineProperty(n,"__esModule",{value:!0}),r.prototype.clearSelection=function(){this.selectionStart=null,this.selectionEnd=null,this.isSelectAllActive=!1,this.selectionStartLength=0},Object.defineProperty(r.prototype,"finalSelectionStart",{get:function(){return this.isSelectAllActive?[0,0]:this.selectionEnd&&this.selectionStart&&this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart},enumerable:!0,configurable:!0}),Object.defineProperty(r.prototype,"finalSelectionEnd",{get:function(){var t;return this.isSelectAllActive?[this._terminal.cols,this._terminal.buffer.ybase+this._terminal.rows-1]:this.selectionStart?!this.selectionEnd||this.areSelectionValuesReversed()?(t=this.selectionStart[0]+this.selectionStartLength)>this._terminal.cols?[t%this._terminal.cols,this.selectionStart[1]+Math.floor(t/this._terminal.cols)]:[t,this.selectionStart[1]]:this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]?[Math.max(this.selectionStart[0]+this.selectionStartLength,this.selectionEnd[0]),this.selectionEnd[1]]:this.selectionEnd:null},enumerable:!0,configurable:!0}),r.prototype.areSelectionValuesReversed=function(){var t=this.selectionStart,e=this.selectionEnd;return!(!t||!e)&&(t[1]>e[1]||t[1]===e[1]&&t[0]>e[0])},r.prototype.onTrim=function(t){return this.selectionStart&&(this.selectionStart[1]-=t),this.selectionEnd&&(this.selectionEnd[1]-=t),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)},n.SelectionModel=r},{}],15:[function(t,e,n){function r(t){this._terminal=t}Object.defineProperty(n,"__esModule",{value:!0}),n.DEFAULT_BELL_SOUND="data:audio/wav;base64,UklGRigBAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQQBAADpAFgCwAMlBZoG/wdmCcoKRAypDQ8PbRDBEQQTOxRtFYcWlBePGIUZXhoiG88bcBz7HHIdzh0WHlMeZx51HmkeUx4WHs8dah0AHXwc3hs9G4saxRnyGBIYGBcQFv8U4RPAEoYRQBACD70NWwwHC6gJOwjWBloF7gOBAhABkf8b/qv8R/ve+Xf4Ife79W/0JfPZ8Z/wde9N7ijtE+wU6xvqM+lb6H7nw+YX5mrlxuQz5Mzje+Ma49fioeKD4nXiYeJy4pHitOL04j/jn+MN5IPkFOWs5U3mDefM55/ogOl36m7rdOyE7abuyu8D8Unyj/Pg9D/2qfcb+Yn6/vuK/Qj/lAAlAg==",Object.defineProperty(r,"audioContext",{get:function(){if(!r._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;r._audioContext=new t}return r._audioContext},enumerable:!0,configurable:!0}),r.prototype.playBellSound=function(){var t,e=r.audioContext;e&&(t=e.createBufferSource(),e.decodeAudioData(this._base64ToArrayBuffer(this._removeMimeType(this._terminal.options.bellSound)),(function(n){t.buffer=n,t.connect(e.destination),t.start(0)})))},r.prototype._base64ToArrayBuffer=function(t){for(var e=window.atob(t),n=e.length,r=new Uint8Array(n),i=0;in)&&(n=this.buffer.lines.length-n,r=this.buffer.ydisp-n<0,this.buffer.lines.trimStart(n),this.buffer.ybase=Math.max(this.buffer.ybase-n,0),this.buffer.ydisp=Math.max(this.buffer.ydisp-n,0),r)&&this.refresh(0,this.rows-1)}switch(this.options[t]=e,t){case"fontFamily":case"fontSize":this._renderCoordinator&&(this._renderCoordinator.clear(),this.charMeasure.measure(this.options));break;case"drawBoldTextInBrightColors":case"experimentalCharAtlas":case"enableBold":case"letterSpacing":case"lineHeight":case"fontWeight":case"fontWeightBold":this._renderCoordinator&&(this._renderCoordinator.clear(),this._renderCoordinator.onResize(this.cols,this.rows),this.refresh(0,this.rows-1));break;case"rendererType":this._renderCoordinator&&this._renderCoordinator.setRenderer(this._createRenderer());break;case"scrollback":this.buffers.resize(this.cols,this.rows),this.viewport&&this.viewport.syncScrollArea();break;case"screenReaderMode":e?!this._accessibilityManager&&this._renderCoordinator&&(this._accessibilityManager=new S.AccessibilityManager(this,this._renderCoordinator.dimensions)):this._accessibilityManager&&(this._accessibilityManager.dispose(),this._accessibilityManager=null);break;case"tabStopWidth":this.buffers.setupTabStops();break;case"windowsMode":e?this._windowsMode||(this._windowsMode=M.applyWindowsMode(this)):this._windowsMode&&(this._windowsMode.dispose(),this._windowsMode=void 0)}this._renderCoordinator&&this._renderCoordinator.onOptionsChanged()}},H.prototype._onTextAreaFocus=function(t){this.sendFocus&&this.handler(f.C0.ESC+"[I"),this.updateCursorStyle(t),this.element.classList.add("focus"),this.showCursor(),this.emit("focus")},H.prototype.blur=function(){return this.textarea.blur()},H.prototype._onTextAreaBlur=function(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this.sendFocus&&this.handler(f.C0.ESC+"[O"),this.element.classList.remove("focus"),this.emit("blur")},H.prototype._initGlobal=function(){function t(t){return u.pasteHandler(t,e)}var e=this;this._bindKeys(),this.register(b.addDisposableDomListener(this.element,"copy",(function(t){e.hasSelection()&&u.copyHandler(t,e,e.selectionManager)}))),this.register(b.addDisposableDomListener(this.textarea,"paste",t)),this.register(b.addDisposableDomListener(this.element,"paste",t)),y.isFirefox?this.register(b.addDisposableDomListener(this.element,"mousedown",(function(t){2===t.button&&u.rightClickHandler(t,e,e.selectionManager,e.options.rightClickSelectsWord)}))):this.register(b.addDisposableDomListener(this.element,"contextmenu",(function(t){u.rightClickHandler(t,e,e.selectionManager,e.options.rightClickSelectsWord)}))),y.isLinux&&this.register(b.addDisposableDomListener(this.element,"auxclick",(function(t){1===t.button&&u.moveTextAreaUnderMouseCursor(t,e)})))},H.prototype._bindKeys=function(){var t=this,e=this;this.register(b.addDisposableDomListener(this.element,"keydown",(function(t){B.activeElement===this&&e._keyDown(t)}),!0)),this.register(b.addDisposableDomListener(this.element,"keypress",(function(t){B.activeElement===this&&e._keyPress(t)}),!0)),this.register(b.addDisposableDomListener(this.element,"keyup",(function(n){var r;16!==(r=n).keyCode&&17!==r.keyCode&&18!==r.keyCode&&t.focus(),e._keyUp(n)}),!0)),this.register(b.addDisposableDomListener(this.textarea,"keydown",(function(e){return t._keyDown(e)}),!0)),this.register(b.addDisposableDomListener(this.textarea,"keypress",(function(e){return t._keyPress(e)}),!0)),this.register(b.addDisposableDomListener(this.textarea,"compositionstart",(function(){return t._compositionHelper.compositionstart()}))),this.register(b.addDisposableDomListener(this.textarea,"compositionupdate",(function(e){return t._compositionHelper.compositionupdate(e)}))),this.register(b.addDisposableDomListener(this.textarea,"compositionend",(function(){return t._compositionHelper.compositionend()}))),this.register(this.onRender((function(){return t._compositionHelper.updateCompositionElements()}))),this.register(this.onRender((function(e){return t._queueLinkification(e.start,e.end)})))},H.prototype.open=function(t){var e=this;if(this._parent=t||this._parent,!this._parent)throw new Error("Terminal requires a parent element.");this._context=this._parent.ownerDocument.defaultView,this._document=this._parent.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"),this._parent.appendChild(this.element),t=B.createDocumentFragment(),this._viewportElement=B.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),t.appendChild(this._viewportElement),this._viewportScrollArea=B.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=B.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=B.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),t.appendChild(this.screenElement),this._mouseZoneManager=new k.MouseZoneManager(this),this.register(this._mouseZoneManager),this.register(this.onScroll((function(){return e._mouseZoneManager.clearAll()}))),this.linkifier.attachToDom(this._mouseZoneManager),this.textarea=B.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",v.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(b.addDisposableDomListener(this.textarea,"focus",(function(t){return e._onTextAreaFocus(t)}))),this.register(b.addDisposableDomListener(this.textarea,"blur",(function(){return e._onTextAreaBlur()}))),this._helperContainer.appendChild(this.textarea),this._compositionView=B.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=new l.CompositionHelper(this.textarea,this._compositionView,this),this._helperContainer.appendChild(this._compositionView),this.charMeasure=new g.CharMeasure(B,this._helperContainer),this.element.appendChild(t),this._theme=this.options.theme,this._colorManager=new D.ColorManager(B,this.options.allowTransparency),this._colorManager.setTheme(this._theme),t=this._createRenderer(),this._renderCoordinator=new O.RenderCoordinator(t,this.rows,this.screenElement),this._renderCoordinator.onRender((function(t){return e._onRender.fire(t)})),this.onResize((function(t){return e._renderCoordinator.resize(t.cols,t.rows)})),this.viewport=new h.Viewport(this,this._viewportElement,this._viewportScrollArea,this.charMeasure,this._renderCoordinator.dimensions),this.viewport.onThemeChange(this._colorManager.colors),this.register(this.viewport),this.register(this.onCursorMove((function(){return e._renderCoordinator.onCursorMove()}))),this.register(this.onResize((function(){return e._renderCoordinator.onResize(e.cols,e.rows)}))),this.register(this.addDisposableListener("blur",(function(){return e._renderCoordinator.onBlur()}))),this.register(this.addDisposableListener("focus",(function(){return e._renderCoordinator.onFocus()}))),this.register(this.charMeasure.onCharSizeChanged((function(){return e._renderCoordinator.onCharSizeChanged()}))),this.register(this._renderCoordinator.onDimensionsChange((function(){return e.viewport.syncScrollArea()}))),this.selectionManager=new _.SelectionManager(this,this.charMeasure),this.register(this.selectionManager.onSelectionChange((function(){return e._onSelectionChange.fire()}))),this.register(b.addDisposableDomListener(this.element,"mousedown",(function(t){return e.selectionManager.onMouseDown(t)}))),this.register(this.selectionManager.onRedrawRequest((function(t){return e._renderCoordinator.onSelectionChanged(t.start,t.end,t.columnSelectMode)}))),this.register(this.selectionManager.onLinuxMouseSelection((function(t){e.textarea.value=t,e.textarea.focus(),e.textarea.select()}))),this.register(this.onScroll((function(){e.viewport.syncScrollArea(),e.selectionManager.refresh()}))),this.register(b.addDisposableDomListener(this._viewportElement,"scroll",(function(){return e.selectionManager.refresh()}))),this.mouseHelper=new C.MouseHelper(this._renderCoordinator),this.element.classList.toggle("enable-mouse-events",this.mouseEvents),this.mouseEvents?this.selectionManager.disable():this.selectionManager.enable(),this.options.screenReaderMode&&(this._accessibilityManager=new S.AccessibilityManager(this,this._renderCoordinator.dimensions),this._accessibilityManager.register(this._renderCoordinator.onDimensionsChange((function(t){return e._accessibilityManager.setDimensions(t)})))),this.charMeasure.measure(this.options),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()},H.prototype._createRenderer=function(){switch(this.options.rendererType){case"canvas":return new d.Renderer(this,this._colorManager.colors);case"dom":return new x.DomRenderer(this,this._colorManager.colors);default:throw new Error('Unrecognized rendererType "'+this.options.rendererType+'"')}},H.prototype._setTheme=function(t){this._theme=t,this._colorManager&&this._colorManager.setTheme(t),this._renderCoordinator&&this._renderCoordinator.setColors(this._colorManager.colors),this.viewport&&this.viewport.onThemeChange(this._colorManager.colors)},H.prototype.bindMouse=function(){var t=this,e=this.element,n=this,r=32;function i(t){var e=function(t){var e,r,i;switch(t.overrideType||t.type){case"mousedown":e=null!==t.button&&void 0!==t.button?+t.button:null!==t.which&&void 0!==t.which?t.which-1:null,y.isMSIE&&(e=1===e?0:4===e?1:e);break;case"mouseup":e=3;break;case"DOMMouseScroll":e=t.detail<0?64:65;break;case"wheel":e=t.deltaY<0?64:65}return i=(i=t.shiftKey?4:0)|(t.metaKey?8:0)|(r=t.ctrlKey?16:0),n.vt200Mouse?i&=r:n.normalMouse||(i=0),32+(i<<2)+e}(t),i=n.mouseHelper.getRawByteCoords(t,n.screenElement,n.charMeasure,n.cols,n.rows);if(i)switch(s(e,i),t.overrideType||t.type){case"mousedown":r=e;break;case"mouseup":r=32}}function o(t,e){n.utfMouse?2047=this.buffer.ybase&&(this._userScrolling=!1);var n=this.buffer.ydisp;this.buffer.ydisp=Math.max(Math.min(this.buffer.ydisp+t,this.buffer.ybase),0),n!==this.buffer.ydisp&&(e||this._onScroll.fire(this.buffer.ydisp),this.refresh(0,this.rows-1))},H.prototype.scrollPages=function(t){this.scrollLines(t*(this.rows-1))},H.prototype.scrollToTop=function(){this.scrollLines(-this.buffer.ydisp)},H.prototype.scrollToBottom=function(){this.scrollLines(this.buffer.ybase-this.buffer.ydisp)},H.prototype.scrollToLine=function(t){0!=(t-=this.buffer.ydisp)&&this.scrollLines(t)},H.prototype.writeUtf8=function(t){var e=this;this._isDisposed||t&&(this.writeBufferUtf8.push(t),this.options.useFlowControl&&!this._xoffSentToCatchUp&&5<=this.writeBufferUtf8.length&&(this.handler(f.C0.DC3),this._xoffSentToCatchUp=!0),!this._writeInProgress)&&0t;){var r=this.writeBufferUtf8[t];if(t++,this._xoffSentToCatchUp&&this.writeBufferUtf8.length===t&&(this.handler(f.C0.DC1),this._xoffSentToCatchUp=!1),this._refreshStart=this.buffer.y,this._refreshEnd=this.buffer.y,this._inputHandler.parseUtf8(r),this.updateRange(this.buffer.y),this.refresh(this._refreshStart,this._refreshEnd),12<=Date.now()-n)break}this.writeBufferUtf8.length>t?(50t;){var r=this.writeBuffer[t];if(t++,this._xoffSentToCatchUp&&this.writeBuffer.length===t&&(this.handler(f.C0.DC1),this._xoffSentToCatchUp=!1),this._refreshStart=this.buffer.y,this._refreshEnd=this.buffer.y,this._inputHandler.parse(r),this.updateRange(this.buffer.y),this.refresh(this._refreshStart,this._refreshEnd),12<=Date.now()-n)break}this.writeBuffer.length>t?(50this._refreshEnd&&(this._refreshEnd=t)},H.prototype.maxRange=function(){this._refreshStart=0,this._refreshEnd=this.rows-1},H.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 t=1;tthis.buffer.scrollBottom&&(this.buffer.y--,this.scroll()),this.buffer.x>=this.cols&&this.buffer.x--},H.prototype.reverseIndex=function(){var t;this.buffer.y===this.buffer.scrollTop?(t=this.buffer.scrollBottom-this.buffer.scrollTop,this.buffer.lines.shiftElements(this.buffer.y+this.buffer.ybase,t,1),this.buffer.lines.set(this.buffer.y+this.buffer.ybase,this.buffer.getBlankLine(this.eraseAttrData())),this.updateRange(this.buffer.scrollTop),this.updateRange(this.buffer.scrollBottom)):this.buffer.y--},H.prototype.reset=function(){this.options.rows=this.rows,this.options.cols=this.cols;var t=this._customKeyEventHandler,e=this._inputHandler,n=this.cursorState,r=this.writeBuffer,i=this.writeBufferUtf8,o=this._writeInProgress,s=this._xoffSentToCatchUp,a=this._userScrolling;this._setup(),this._customKeyEventHandler=t,this._inputHandler=e,this.cursorState=n,this.writeBuffer=r,this.writeBufferUtf8=i,this._writeInProgress=o,this._xoffSentToCatchUp=s,this._userScrolling=a,this.refresh(0,this.rows-1),this.viewport&&this.viewport.syncScrollArea()},H.prototype.tabSet=function(){this.buffer.tabs[this.buffer.x]=!0},H.prototype.cancel=function(t,e){if(this.options.cancelEvents||e)return t.preventDefault(),t.stopPropagation(),!1},H.prototype._visualBell=function(){return!1},H.prototype._soundBell=function(){return"sound"===this.options.bellStyle},t=H;function H(t){void 0===t&&(t={});var e=i.call(this)||this;return e.browser=y,e._blankLine=null,e._onCursorMove=new T.EventEmitter2,e._onData=new T.EventEmitter2,e._onKey=new T.EventEmitter2,e._onLineFeed=new T.EventEmitter2,e._onRender=new T.EventEmitter2,e._onResize=new T.EventEmitter2,e._onScroll=new T.EventEmitter2,e._onSelectionChange=new T.EventEmitter2,e._onTitleChange=new T.EventEmitter2,e.options=L.clone(t),e._setup(),e.onCursorMove((function(){return e.emit("cursormove")})),e.onData((function(t){return e.emit("data",t)})),e.onKey((function(t){return e.emit("key",t.key,t.domEvent)})),e.onLineFeed((function(){return e.emit("linefeed")})),e.onRender((function(t){return e.emit("refresh",t)})),e.onResize((function(t){return e.emit("resize",t)})),e.onSelectionChange((function(){return e.emit("selection")})),e.onScroll((function(t){return e.emit("scroll",t)})),e.onTitleChange((function(t){return e.emit("title",t)})),e}n.Terminal=t},{"./AccessibilityManager":1,"./Buffer":2,"./BufferSet":3,"./CharMeasure":4,"./Clipboard":6,"./CompositionHelper":7,"./InputHandler":9,"./Linkifier":10,"./MouseHelper":11,"./MouseZoneManager":12,"./SelectionManager":13,"./SoundManager":15,"./Strings":16,"./Viewport":18,"./WindowsMode":19,"./common/Clone":21,"./common/EventEmitter":22,"./common/EventEmitter2":23,"./common/Platform":25,"./common/data/EscapeSequences":28,"./core/buffer/BufferLine":29,"./core/input/Keyboard":33,"./renderer/RenderCoordinator":43,"./renderer/Renderer":44,"./renderer/atlas/CharAtlasCache":48,"./renderer/dom/DomRenderer":56,"./ui/ColorManager":58,"./ui/Lifecycle":59}],18:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),s=(Object.defineProperty(n,"__esModule",{value:!0}),t("./common/Lifecycle")),a=t("./ui/Lifecycle");o(l,i=s.Disposable),l.prototype.onDimensionsChance=function(t){this._dimensions=t},l.prototype.onThemeChange=function(t){this._viewportElement.style.backgroundColor=t.background.css},l.prototype._refresh=function(){var t=this;null===this._refreshAnimationFrame&&(this._refreshAnimationFrame=requestAnimationFrame((function(){return t._innerRefresh()})))},l.prototype._innerRefresh=function(){0this._length)for(var e=this._length;ethis._maxLength?(o=this._length+n.length-this._maxLength,this._startIndex+=o,this._length=this._maxLength,this.onTrimEmitter.fire(o)):this._length+=n.length},i.prototype.trimStart=function(t){t>this._length&&(t=this._length),this._startIndex+=t,this._length-=t,this.onTrimEmitter.fire(t)},i.prototype.shiftElements=function(t,e,n){if(!(e<=0)){if(t<0||t>=this._length)throw new Error("start argument out of range");if(t+n<0)throw new Error("Cannot shift elements in list beyond index 0");if(0this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(r=0;r=t.length)){n=(t.length+n)%t.length,r=r>=t.length?t.length:(t.length+r)%t.length;for(var i=n;i>>16&255,t>>>8&255,255&t]},s.fromColorRGB=function(t){return(255&t[0])<<16|(255&t[1])<<8|255&t[2]},s.prototype.clone=function(){var t=new s;return t.fg=this.fg,t.bg=this.bg,t},s.prototype.isInverse=function(){return 67108864&this.fg},s.prototype.isBold=function(){return 134217728&this.fg},s.prototype.isUnderline=function(){return 268435456&this.fg},s.prototype.isBlink=function(){return 536870912&this.fg},s.prototype.isInvisible=function(){return 1073741824&this.fg},s.prototype.isItalic=function(){return 67108864&this.bg},s.prototype.isDim=function(){return 134217728&this.bg},s.prototype.getFgColorMode=function(){return 50331648&this.fg},s.prototype.getBgColorMode=function(){return 50331648&this.bg},s.prototype.isFgRGB=function(){return 50331648==(50331648&this.fg)},s.prototype.isBgRGB=function(){return 50331648==(50331648&this.bg)},s.prototype.isFgPalette=function(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)},s.prototype.isBgPalette=function(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)},s.prototype.isFgDefault=function(){return 0==(50331648&this.fg)},s.prototype.isBgDefault=function(){return 0==(50331648&this.bg)},s.prototype.getFgColor=function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}},s.prototype.getBgColor=function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}},t=s;function s(){this.fg=0,this.bg=0}n.AttributeData=t,n.DEFAULT_ATTR_DATA=Object.freeze(new t),i(c,a=t),c.fromCharData=function(t){var e=new c;return e.setFromCharData(t),e},c.prototype.isCombined=function(){return 2097152&this.content},c.prototype.getWidth=function(){return this.content>>22},c.prototype.getChars=function(){return 2097152&this.content?this.combinedData:2097151&this.content?o.stringFromCodePoint(2097151&this.content):""},c.prototype.getCode=function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content},c.prototype.setFromCharData=function(t){this.fg=t[n.CHAR_DATA_ATTR_INDEX],this.bg=0;var e,r,i=!1;2>22,2097152&e?this._combined[t].charCodeAt(this._combined[t].length-1):n]},h.prototype.set=function(t,e){this._data[3*t+1]=e[n.CHAR_DATA_ATTR_INDEX],1>22},h.prototype.hasWidth=function(t){return 12582912&this._data[3*t+0]},h.prototype.getFg=function(t){return this._data[3*t+1]},h.prototype.getBg=function(t){return this._data[3*t+2]},h.prototype.hasContent=function(t){return 4194303&this._data[3*t+0]},h.prototype.getCodePoint=function(t){var e=this._data[3*t+0];return 2097152&e?this._combined[t].charCodeAt(this._combined[t].length-1):2097151&e},h.prototype.isCombined=function(t){return 2097152&this._data[3*t+0]},h.prototype.getString=function(t){var e=this._data[3*t+0];return 2097152&e?this._combined[t]:2097151&e?o.stringFromCodePoint(2097151&e):""},h.prototype.loadCell=function(t,e){var n=3*t;return e.content=this._data[0+n],e.fg=this._data[1+n],e.bg=this._data[2+n],2097152&e.content&&(e.combinedData=this._combined[t]),e},h.prototype.setCell=function(t,e){2097152&e.content&&(this._combined[t]=e.combinedData),this._data[3*t+0]=e.content,this._data[3*t+1]=e.fg,this._data[3*t+2]=e.bg},h.prototype.setCellFromCodePoint=function(t,e,n,r,i){this._data[3*t+0]=e|n<<22,this._data[3*t+1]=r,this._data[3*t+2]=i},h.prototype.addCodepointToCell=function(t,e){var n=this._data[3*t+0];2097152&n?this._combined[t]+=o.stringFromCodePoint(e):(n=2097151&n?(this._combined[t]=o.stringFromCodePoint(2097151&n)+o.stringFromCodePoint(e),-2097152&n|2097152):e|1<<22,this._data[3*t+0]=n)},h.prototype.insertCells=function(t,e,n){if(t%=this.length,ethis.length){var n=new Uint32Array(3*t);this.length&&(3*t>22);return 0},h.prototype.copyCellsFrom=function(t,e,n,r,i){var o=t._data;if(i)for(var s=r-1;0<=s;s--)for(var a=0;a<3;a++)this._data[3*(n+s)+a]=o[3*(e+s)+a];else for(s=0;s>22||1}return i},n.BufferLine=h},{"../../common/Types":27,"../input/TextDecoder":34}],30:[function(t,e,n){function r(t,e,n){var r;return e===t.length-1?t[e].getTrimmedLength():(r=!t[e].hasContent(n-1)&&1===t[e].getWidth(n-1),t=2===t[e+1].getWidth(0),r&&t?n-1:n)}Object.defineProperty(n,"__esModule",{value:!0}),n.reflowLargerGetLinesToRemove=function(t,e,n,i,o){for(var s=[],a=0;a"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};n.evaluateKeyboardEvent=function(t,e,n,o){var s,a={type:0,cancel:!1,key:void 0},l=(t.shiftKey?1:0)|(t.altKey?2:0)|(t.ctrlKey?4:0)|(t.metaKey?8:0);switch(t.keyCode){case 0:"UIKeyInputUpArrow"===t.key?a.key=e?r.C0.ESC+"OA":r.C0.ESC+"[A":"UIKeyInputLeftArrow"===t.key?a.key=e?r.C0.ESC+"OD":r.C0.ESC+"[D":"UIKeyInputRightArrow"===t.key?a.key=e?r.C0.ESC+"OC":r.C0.ESC+"[C":"UIKeyInputDownArrow"===t.key&&(a.key=e?r.C0.ESC+"OB":r.C0.ESC+"[B");break;case 8:t.shiftKey?a.key=r.C0.BS:t.altKey?a.key=r.C0.ESC+r.C0.DEL:a.key=r.C0.DEL;break;case 9:t.shiftKey?a.key=r.C0.ESC+"[Z":(a.key=r.C0.HT,a.cancel=!0);break;case 13:a.key=r.C0.CR,a.cancel=!0;break;case 27:a.key=r.C0.ESC,a.cancel=!0;break;case 37:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"D",a.key===r.C0.ESC+"[1;3D"&&(a.key=n?r.C0.ESC+"b":r.C0.ESC+"[1;5D")):a.key=e?r.C0.ESC+"OD":r.C0.ESC+"[D";break;case 39:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"C",a.key===r.C0.ESC+"[1;3C"&&(a.key=n?r.C0.ESC+"f":r.C0.ESC+"[1;5C")):a.key=e?r.C0.ESC+"OC":r.C0.ESC+"[C";break;case 38:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"A",a.key===r.C0.ESC+"[1;3A"&&(a.key=r.C0.ESC+"[1;5A")):a.key=e?r.C0.ESC+"OA":r.C0.ESC+"[A";break;case 40:l?(a.key=r.C0.ESC+"[1;"+(1+l)+"B",a.key===r.C0.ESC+"[1;3B"&&(a.key=r.C0.ESC+"[1;5B")):a.key=e?r.C0.ESC+"OB":r.C0.ESC+"[B";break;case 45:t.shiftKey||t.ctrlKey||(a.key=r.C0.ESC+"[2~");break;case 46:a.key=l?r.C0.ESC+"[3;"+(1+l)+"~":r.C0.ESC+"[3~";break;case 36:a.key=l?r.C0.ESC+"[1;"+(1+l)+"H":e?r.C0.ESC+"OH":r.C0.ESC+"[H";break;case 35:a.key=l?r.C0.ESC+"[1;"+(1+l)+"F":e?r.C0.ESC+"OF":r.C0.ESC+"[F";break;case 33:t.shiftKey?a.type=2:a.key=r.C0.ESC+"[5~";break;case 34:t.shiftKey?a.type=3:a.key=r.C0.ESC+"[6~";break;case 112:a.key=l?r.C0.ESC+"[1;"+(1+l)+"P":r.C0.ESC+"OP";break;case 113:a.key=l?r.C0.ESC+"[1;"+(1+l)+"Q":r.C0.ESC+"OQ";break;case 114:a.key=l?r.C0.ESC+"[1;"+(1+l)+"R":r.C0.ESC+"OR";break;case 115:a.key=l?r.C0.ESC+"[1;"+(1+l)+"S":r.C0.ESC+"OS";break;case 116:a.key=l?r.C0.ESC+"[15;"+(1+l)+"~":r.C0.ESC+"[15~";break;case 117:a.key=l?r.C0.ESC+"[17;"+(1+l)+"~":r.C0.ESC+"[17~";break;case 118:a.key=l?r.C0.ESC+"[18;"+(1+l)+"~":r.C0.ESC+"[18~";break;case 119:a.key=l?r.C0.ESC+"[19;"+(1+l)+"~":r.C0.ESC+"[19~";break;case 120:a.key=l?r.C0.ESC+"[20;"+(1+l)+"~":r.C0.ESC+"[20~";break;case 121:a.key=l?r.C0.ESC+"[21;"+(1+l)+"~":r.C0.ESC+"[21~";break;case 122:a.key=l?r.C0.ESC+"[23;"+(1+l)+"~":r.C0.ESC+"[23~";break;case 123:a.key=l?r.C0.ESC+"[24;"+(1+l)+"~":r.C0.ESC+"[24~";break;default:!t.ctrlKey||t.shiftKey||t.altKey||t.metaKey?n&&!o||!t.altKey||t.metaKey?n&&!t.altKey&&!t.ctrlKey&&t.metaKey?65===t.keyCode&&(a.type=1):t.key&&!t.ctrlKey&&!t.altKey&&!t.metaKey&&48<=t.keyCode&&1===t.key.length?a.key=t.key:t.key&&t.ctrlKey&&"_"===t.key&&(a.key=r.C0.US):(s=(s=i[t.keyCode])&&s[t.shiftKey?1:0])?a.key=r.C0.ESC+s:65<=t.keyCode&&t.keyCode<=90&&(s=t.ctrlKey?t.keyCode-64:t.keyCode+32,a.key=r.C0.ESC+String.fromCharCode(s)):65<=t.keyCode&&t.keyCode<=90?a.key=String.fromCharCode(t.keyCode-64):32===t.keyCode?a.key=String.fromCharCode(0):51<=t.keyCode&&t.keyCode<=55?a.key=String.fromCharCode(t.keyCode-51+27):56===t.keyCode?a.key=String.fromCharCode(127):219===t.keyCode?a.key=String.fromCharCode(27):220===t.keyCode?a.key=String.fromCharCode(28):221===t.keyCode&&(a.key=String.fromCharCode(29))}return a}},{"../../common/data/EscapeSequences":28}],34:[function(t,e,n){function r(){this._interim=0}function i(){this.interim=new Uint8Array(3)}Object.defineProperty(n,"__esModule",{value:!0}),n.stringFromCodePoint=function(t){return 65535>10))+String.fromCharCode(t%1024+56320)):String.fromCharCode(t)},n.utf32ToString=function(t,e,n){void 0===n&&(n=t.length);for(var r="",i=e=void 0===e?0:e;i>10))+String.fromCharCode(o%1024+56320)):r+=String.fromCharCode(o)}return r},r.prototype.clear=function(){this._interim=0},r.prototype.decode=function(t,e){var n=t.length;if(!n)return 0;var r=0,i=0;this._interim&&(56320<=(s=t.charCodeAt(i++))&&s<=57343?e[r++]=1024*(this._interim-55296)+s-56320+65536:(e[r++]=this._interim,e[r++]=s),this._interim=0);for(var o=i;o=n)return this._interim=a,r;56320<=(s=t.charCodeAt(o))&&s<=57343?e[r++]=1024*(a-55296)+s-56320+65536:(e[r++]=a,e[r++]=s)}else e[r++]=a}return r},n.StringToUtf32=r,i.prototype.clear=function(){this.interim.fill(0)},i.prototype.decode=function(t,e){var n=t.length;if(!n)return 0;var r,i,o,s,a=0,l=0,c=0;if(this.interim[0]){for(var h=!1,u=this.interim[0],f=(u&=192==(224&u)?31:224==(240&u)?15:7,0),p=void 0;(p=63&this.interim[++f])&&f<4;)u=u<<6|p;for(var d=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,m=d-f;c=this._endCol&&tthis._endRow?"A":"B"},i.prototype._bufferLine=function(t,e,n,r,i){for(var o=t,s=e,a="";o!==n||s!==r;)o+=i?1:-1,i&&o>this._terminal.cols-1?(a+=this._terminal.buffer.translateBufferLineToString(s,!1,t,o),t=o=0,s++):!i&&o<0&&(a+=this._terminal.buffer.translateBufferLineToString(s,!1,0,t+1),t=o=this._terminal.cols-1,s--);return a+this._terminal.buffer.translateBufferLineToString(s,!1,t,o)},i.prototype._sequence=function(t){var e=this._terminal.applicationCursor?"O":"[";return r.C0.ESC+e+t},n.AltClickHandler=i},{"../common/data/EscapeSequences":28}],36:[function(t,e,n){function r(){this._addons=[]}Object.defineProperty(n,"__esModule",{value:!0}),r.prototype.dispose=function(){for(var t=this._addons.length-1;0<=t;t--)this._addons[t].instance.dispose()},r.prototype.loadAddon=function(t,e){var n=this,r={instance:e,dispose:e.dispose,isDisposed:!1};this._addons.push(r),e.dispose=function(){return n._wrappedAddonDispose(r)},e.activate(t)},r.prototype._wrappedAddonDispose=function(t){if(!t.isDisposed){for(var e=-1,n=0;n=this._line.length))return new u(this._line,t)},h.prototype.translateToString=function(t,e,n){return this._line.translateToString(t,e,n)};var c=h;function h(t){this._line=t}Object.defineProperty(f.prototype,"char",{get:function(){return this._line.getString(this._x)},enumerable:!0,configurable:!0}),Object.defineProperty(f.prototype,"width",{get:function(){return this._line.getWidth(this._x)},enumerable:!0,configurable:!0});var u=f;function f(t,e){this._line=t,this._x=e}},{"../Strings":16,"../Terminal":17,"./AddonManager":36}],38:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("../common/Types"),i=t("./atlas/Types"),o=t("./atlas/CharAtlasCache"),s=t("../core/buffer/BufferLine");function a(t,e,n,r,i){this._container=t,this._alpha=r,this._colors=i,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-"+e+"-layer"),this._canvas.style.zIndex=n.toString(),this._initCanvas(),this._container.appendChild(this._canvas)}a.prototype.dispose=function(){this._container.removeChild(this._canvas),this._charAtlas&&this._charAtlas.dispose()},a.prototype._initCanvas=function(){this._ctx=this._canvas.getContext("2d",{alpha:this._alpha}),this._alpha||this.clearAll()},a.prototype.onOptionsChanged=function(t){},a.prototype.onBlur=function(t){},a.prototype.onFocus=function(t){},a.prototype.onCursorMove=function(t){},a.prototype.onGridChanged=function(t,e,n){},a.prototype.onSelectionChanged=function(t,e,n,r){},a.prototype.setColors=function(t,e){this._refreshCharAtlas(t,e)},a.prototype.setTransparency=function(t,e){var n;e!==this._alpha&&(n=this._canvas,this._alpha=e,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,n),this._refreshCharAtlas(t,this._colors),this.onGridChanged(t,0,t.rows-1))},a.prototype._refreshCharAtlas=function(t,e){this._scaledCharWidth<=0&&this._scaledCharHeight<=0||(this._charAtlas=o.acquireCharAtlas(t,e,this._scaledCharWidth,this._scaledCharHeight),this._charAtlas.warmUp())},a.prototype.resize=function(t,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(t,this._colors)},a.prototype.fillCells=function(t,e,n,r){this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight)},a.prototype.fillBottomLineAtCells=function(t,e,n){void 0===n&&(n=1),this._ctx.fillRect(t*this._scaledCellWidth,(e+1)*this._scaledCellHeight-window.devicePixelRatio-1,n*this._scaledCellWidth,window.devicePixelRatio)},a.prototype.fillLeftLineAtCell=function(t,e){this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,window.devicePixelRatio,this._scaledCellHeight)},a.prototype.strokeRectAtCell=function(t,e,n,r){this._ctx.lineWidth=window.devicePixelRatio,this._ctx.strokeRect(t*this._scaledCellWidth+window.devicePixelRatio/2,e*this._scaledCellHeight+window.devicePixelRatio/2,n*this._scaledCellWidth-window.devicePixelRatio,r*this._scaledCellHeight-window.devicePixelRatio)},a.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))},a.prototype.clearCells=function(t,e,n,r){this._alpha?this._ctx.clearRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight):(this._ctx.fillStyle=this._colors.background.css,this._ctx.fillRect(t*this._scaledCellWidth,e*this._scaledCellHeight,n*this._scaledCellWidth,r*this._scaledCellHeight))},a.prototype.fillCharTrueColor=function(t,e,n,r){this._ctx.font=this._getFont(t,!1,!1),this._ctx.textBaseline="middle",this._clipRow(t,r),this._ctx.fillText(e.getChars(),n*this._scaledCellWidth+this._scaledCharLeft,r*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2)},a.prototype.drawChars=function(t,e,n,o){var a,l;!e.isFgRGB()&&!e.isBgRGB()&&(e.isInverse()?(a=e.isBgDefault()?i.INVERTED_DEFAULT_COLOR:e.getBgColor(),l=e.isFgDefault()?i.INVERTED_DEFAULT_COLOR:e.getFgColor()):(l=e.isBgDefault()?r.DEFAULT_COLOR:e.getBgColor(),a=e.isFgDefault()?r.DEFAULT_COLOR:e.getFgColor()),a+=t.options.drawBoldTextInBrightColors&&e.isBold()&&a<8&&a!==i.INVERTED_DEFAULT_COLOR?8:0,this._currentGlyphIdentifier.chars=e.getChars()||s.WHITESPACE_CELL_CHAR,this._currentGlyphIdentifier.code=e.getCode()||s.WHITESPACE_CELL_CODE,this._currentGlyphIdentifier.bg=l,this._currentGlyphIdentifier.fg=a,this._currentGlyphIdentifier.bold=e.isBold()&&t.options.enableBold,this._currentGlyphIdentifier.dim=!!e.isDim(),this._currentGlyphIdentifier.italic=!!e.isItalic(),this._charAtlas)&&this._charAtlas.draw(this._ctx,this._currentGlyphIdentifier,n*this._scaledCellWidth+this._scaledCharLeft,o*this._scaledCellHeight+this._scaledCharTop)||this._drawUncachedChars(t,e,n,o)},a.prototype._drawUncachedChars=function(t,e,n,r){var o;this._ctx.save(),this._ctx.font=this._getFont(t,e.isBold()&&t.options.enableBold,!!e.isItalic()),this._ctx.textBaseline="middle",e.isInverse()?e.isBgDefault()?this._ctx.fillStyle=this._colors.background.css:e.isBgRGB()?this._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(e.getBgColor()).join(",")+")":this._ctx.fillStyle=this._colors.ansi[e.getBgColor()].css:e.isFgDefault()?this._ctx.fillStyle=this._colors.foreground.css:e.isFgRGB()?this._ctx.fillStyle="rgb("+s.AttributeData.toColorRGB(e.getFgColor()).join(",")+")":(o=e.getFgColor(),t.options.drawBoldTextInBrightColors&&e.isBold()&&o<8&&(o+=8),this._ctx.fillStyle=this._colors.ansi[o].css),this._clipRow(t,r),e.isDim()&&(this._ctx.globalAlpha=i.DIM_OPACITY),this._ctx.fillText(e.getChars(),n*this._scaledCellWidth+this._scaledCharLeft,r*this._scaledCellHeight+this._scaledCharTop+this._scaledCharHeight/2),this._ctx.restore()},a.prototype._clipRow=function(t,e){this._ctx.beginPath(),this._ctx.rect(0,e*this._scaledCellHeight,t.cols*this._scaledCellWidth,this._scaledCellHeight),this._ctx.clip()},a.prototype._getFont=function(t,e,n){return(n?"italic":"")+" "+(e?t.options.fontWeightBold:t.options.fontWeight)+" "+t.options.fontSize*window.devicePixelRatio+"px "+t.options.fontFamily},n.BaseRenderLayer=a},{"../common/Types":27,"../core/buffer/BufferLine":29,"./atlas/CharAtlasCache":48,"./atlas/Types":55}],39:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),s=(Object.defineProperty(n,"__esModule",{value:!0}),t("../core/buffer/BufferLine"));o(a,i=s.AttributeData),a.prototype.isCombined=function(){return 2097152},a.prototype.getWidth=function(){return this._width},a.prototype.getChars=function(){return this.combinedData},a.prototype.getCode=function(){return 2097151},a.prototype.setFromCharData=function(t){throw new Error("not implemented")},a.prototype.getAsCharData=function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]},t=a;function a(t,e,n){var r=i.call(this)||this;return r.content=0,r.combinedData="",r.fg=t.fg,r.bg=t.bg,r.combinedData=e,r._width=n,r}function l(t){this._terminal=t,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new s.CellData}n.JoinedCellData=t,l.prototype.registerCharacterJoiner=function(t){return t={id:this._nextCharacterJoinerId++,handler:t},this._characterJoiners.push(t),t.id},l.prototype.deregisterCharacterJoiner=function(t){for(var e=0;e=t.rows)this._clearCursor();else if(t.buffer.lines.get(n).loadCell(t.buffer.x,this._cell),void 0!==this._cell.content)if(t.isFocused)if(this._cursorBlinkStateManager&&!this._cursorBlinkStateManager.isCursorVisible)this._clearCursor();else{if(this._state){if(this._state.x===t.buffer.x&&this._state.y===r&&this._state.isFocused===t.isFocused&&this._state.style===t.options.cursorStyle&&this._state.width===this._cell.getWidth())return;this._clearCursor()}this._ctx.save(),this._cursorRenderers[t.options.cursorStyle||"block"](t,t.buffer.x,r,this._cell),this._ctx.restore(),this._state.x=t.buffer.x,this._state.y=r,this._state.isFocused=!1,this._state.style=t.options.cursorStyle,this._state.width=this._cell.getWidth()}else this._clearCursor(),this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this._renderBlurCursor(t,t.buffer.x,r,this._cell),this._ctx.restore(),this._state.x=t.buffer.x,this._state.y=r,this._state.isFocused=!1,this._state.style=t.options.cursorStyle,this._state.width=this._cell.getWidth()}},l.prototype._clearCursor=function(){this._state&&(this.clearCells(this._state.x,this._state.y,this._state.width,1),this._state={x:null,y:null,isFocused:null,style:null,width:null})},l.prototype._renderBarCursor=function(t,e,n,r){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this.fillLeftLineAtCell(e,n),this._ctx.restore()},l.prototype._renderBlockCursor=function(t,e,n,r){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this.fillCells(e,n,r.getWidth(),1),this._ctx.fillStyle=this._colors.cursorAccent.css,this.fillCharTrueColor(t,r,e,n),this._ctx.restore()},l.prototype._renderUnderlineCursor=function(t,e,n,r){this._ctx.save(),this._ctx.fillStyle=this._colors.cursor.css,this.fillBottomLineAtCells(e,n),this._ctx.restore()},l.prototype._renderBlurCursor=function(t,e,n,r){this._ctx.save(),this._ctx.strokeStyle=this._colors.cursor.css,this.strokeRectAtCell(e,n,r.getWidth(),1),this._ctx.restore()},t=l;function l(t,e,n){return(t=i.call(this,t,"cursor",e,!0,n)||this)._cell=new a.CellData,t._state={x:null,y:null,isFocused:null,style:null,width:null},t._cursorRenderers={bar:t._renderBarCursor.bind(t),block:t._renderBlockCursor.bind(t),underline:t._renderUnderlineCursor.bind(t)},t}n.CursorRenderLayer=t,Object.defineProperty(h.prototype,"isPaused",{get:function(){return!(this._blinkStartTimeout||this._blinkInterval)},enumerable:!0,configurable:!0}),h.prototype.dispose=function(){this._blinkInterval&&(window.clearInterval(this._blinkInterval),this._blinkInterval=null),this._blinkStartTimeout&&(window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=null),this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=null)},h.prototype.restartBlinkAnimation=function(t){var e=this;this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame)||(this._animationFrame=window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=null})))},h.prototype._restartInterval=function(t){var e=this;void 0===t&&(t=600),this._blinkInterval&&window.clearInterval(this._blinkInterval),this._blinkStartTimeout=setTimeout((function(){if(e._animationTimeRestarted){var t=600-(Date.now()-e._animationTimeRestarted);if(e._animationTimeRestarted=null,0=t.rows||s<0||(this._ctx.fillStyle=this._colors.selection.css,r?(a=e[0],c=n[0]-a,this.fillCells(a,o,c,s-o+1)):(a=l===o?e[0]:0,c=o===s?n[0]:t.cols,this.fillCells(a,o,c-a,1),l=Math.max(s-o-1,0),this.fillCells(0,o+1,t.cols,l),o!==s&&(c=i===s?n[0]:t.cols,this.fillCells(0,s,c,1))),this._state.start=[e[0],e[1]],this._state.end=[n[0],n[1]],this._state.columnSelectMode=r,this._state.ydisp=t.buffer.ydisp)):this._clearState())},s.prototype._didStateChange=function(t,e,n,r){return!this._areCoordinatesEqual(t,this._state.start)||!this._areCoordinatesEqual(e,this._state.end)||n!==this._state.columnSelectMode||r!==this._state.ydisp},s.prototype._areCoordinatesEqual=function(t,e){return!(!t||!e)&&t[0]===e[0]&&t[1]===e[1]},t=s;function s(t,e,n){return(t=i.call(this,t,"selection",e,!0,n)||this)._clearState(),t}n.SelectionRenderLayer=t},{"./BaseRenderLayer":38}],46:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),s=(Object.defineProperty(n,"__esModule",{value:!0}),t("./GridCache")),a=t("./BaseRenderLayer"),l=t("../core/buffer/BufferLine"),c=t("./CharacterJoinerRegistry");o(h,i=a.BaseRenderLayer),h.prototype.resize=function(t,e){i.prototype.resize.call(this,t,e);var n=this._getFont(t,!1,!1);this._characterWidth===e.scaledCharWidth&&this._characterFont===n||(this._characterWidth=e.scaledCharWidth,this._characterFont=n,this._characterOverlapCache={}),this._state.clear(),this._state.resize(t.cols,t.rows)},h.prototype.reset=function(t){this._state.clear(),this.clearAll()},h.prototype._forEachCell=function(t,e,n,r,i){for(var o=e;o<=n;o++)for(var s=o+t.buffer.ydisp,a=t.buffer.lines.get(s),h=r?r.getJoinedCharacters(s):[],u=0;uthis._characterWidth;return this._ctx.restore(),this._characterOverlapCache[t]=e},t=h;function h(t,e,n,r,o){return(t=i.call(this,t,"text",e,o,n)||this)._characterOverlapCache={},t._workCell=new l.CellData,t._state=new s.GridCache,t._characterJoinerRegistry=r,t}n.TextRenderLayer=t},{"../core/buffer/BufferLine":29,"./BaseRenderLayer":38,"./CharacterJoinerRegistry":39,"./GridCache":41}],47:[function(t,e,n){function r(){this._didWarmUp=!1}Object.defineProperty(n,"__esModule",{value:!0}),r.prototype.dispose=function(){},r.prototype.warmUp=function(){this._didWarmUp||(this._doWarmUp(),this._didWarmUp=!0)},r.prototype._doWarmUp=function(){},r.prototype.beginFrame=function(){},n.default=r},{}],48:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("./CharAtlasUtils"),i=t("./DynamicCharAtlas"),o=t("./NoneCharAtlas"),s=(t=t("./StaticCharAtlas"),{none:o.default,static:t.default,dynamic:i.default}),a=[];n.acquireCharAtlas=function(t,e,n,i){for(var o=r.generateConfig(n,i,t,e),l=0;l>>24,i=e.rgba>>>16&255,o=e.rgba>>>8&255,s=0;s=this.capacity?(r=this._head,this._unlinkNode(r),delete this._map[r.key],r.key=t,r.value=e,this._map[t]=r):(0<(n=this._nodePool).length?((r=n.pop()).key=t,r.value=e):r={prev:null,next:null,key:t,value:e},this._map[t]=r,this.size++),this._appendNode(r)},n.default=r},{}],53:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0}),t=t("./BaseCharAtlas"),o(s,i=t.default),s.prototype.draw=function(t,e,n,r){return!1},t=s;function s(t,e){return i.call(this)||this}n.default=t},{"./BaseCharAtlas":47}],54:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),s=(Object.defineProperty(n,"__esModule",{value:!0}),t("./Types")),a=t("./CharAtlasGenerator"),l=t("./BaseCharAtlas"),c=t("./CharAtlasUtils"),h=t("../../common/Types");o(u,i=l.default),u.prototype._doWarmUp=function(){var t=this,e=a.generateStaticCharAtlasTexture(window,this._canvasFactory,this._config);e instanceof HTMLCanvasElement?this._texture=e:e.then((function(e){t._texture=e}))},u.prototype._isCached=function(t,e){var n=t.code<256,r=t.fg<16,i=t.fg===h.DEFAULT_COLOR,o=t.bg===h.DEFAULT_COLOR;return n&&(r||i)&&o&&!t.italic},u.prototype.draw=function(t,e,n,r){if(null===this._texture||void 0===this._texture)return!1;var i=0;if(c.is256Color(e.fg)?i=2+e.fg+(e.bold?16:0):e.fg===h.DEFAULT_COLOR&&e.bold&&(i=1),!this._isCached(e,i))return!1;t.save();var o=this._config.scaledCharWidth+s.CHAR_ATLAS_CELL_SPACING,a=this._config.scaledCharHeight+s.CHAR_ATLAS_CELL_SPACING;return e.dim&&(t.globalAlpha=s.DIM_OPACITY),t.drawImage(this._texture,e.code*o,i*a,o,this._config.scaledCharHeight,n,r,o,this._config.scaledCharHeight),t.restore(),!0},t=u;function u(t,e){var n=i.call(this)||this;return n._document=t,n._config=e,n._canvasFactory=function(t,e){var r=n._document.createElement("canvas");return r.width=t,r.height=e,r},n}n.default=t},{"../../common/Types":27,"./BaseCharAtlas":47,"./CharAtlasGenerator":49,"./CharAtlasUtils":50,"./Types":55}],55:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0}),n.INVERTED_DEFAULT_COLOR=257,n.DIM_OPACITY=.5,n.CHAR_ATLAS_CELL_SPACING=1},{}],56:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),s=(Object.defineProperty(n,"__esModule",{value:!0}),t("./DomRendererRowFactory")),a=t("../atlas/Types"),l=(t=t("../../common/Lifecycle"),"xterm-dom-renderer-owner-"),c="xterm-rows",h="xterm-fg-",u="xterm-bg-",f="xterm-focus",p="xterm-selection",d=1;o(m,i=t.Disposable),m.prototype.dispose=function(){this._terminal.element.classList.remove(l+this._terminalClass),this._terminal.screenElement.removeChild(this._rowContainer),this._terminal.screenElement.removeChild(this._selectionContainer),this._terminal.screenElement.removeChild(this._themeStyleElement),this._terminal.screenElement.removeChild(this._dimensionsStyleElement),i.prototype.dispose.call(this)},m.prototype._updateDimensions=function(){var t=this,e=(this.dimensions.scaledCharWidth=this._terminal.charMeasure.width*window.devicePixelRatio,this.dimensions.scaledCharHeight=Math.ceil(this._terminal.charMeasure.height*window.devicePixelRatio),this.dimensions.scaledCellWidth=this.dimensions.scaledCharWidth+Math.round(this._terminal.options.letterSpacing),this.dimensions.scaledCellHeight=Math.floor(this.dimensions.scaledCharHeight*this._terminal.options.lineHeight),this.dimensions.scaledCharLeft=0,this.dimensions.scaledCharTop=0,this.dimensions.scaledCanvasWidth=this.dimensions.scaledCellWidth*this._terminal.cols,this.dimensions.scaledCanvasHeight=this.dimensions.scaledCellHeight*this._terminal.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._terminal.cols,this.dimensions.actualCellHeight=this.dimensions.canvasHeight/this._terminal.rows,this._rowElements.forEach((function(e){e.style.width=t.dimensions.canvasWidth+"px",e.style.height=t.dimensions.actualCellHeight+"px",e.style.lineHeight=t.dimensions.actualCellHeight+"px",e.style.overflow="hidden"})),this._dimensionsStyleElement||(this._dimensionsStyleElement=document.createElement("style"),this._terminal.screenElement.appendChild(this._dimensionsStyleElement)),this._terminalSelector+" ."+c+" span { display: inline-block; height: 100%; vertical-align: top; width: "+this.dimensions.actualCellWidth+"px}");this._dimensionsStyleElement.innerHTML=e,this._selectionContainer.style.height=this._terminal._viewportElement.style.height,this._terminal.screenElement.style.width=this.dimensions.canvasWidth+"px",this._terminal.screenElement.style.height=this.dimensions.canvasHeight+"px"},m.prototype.setColors=function(t){this._colors=t,this._injectCss()},m.prototype._injectCss=function(){var t=this;this._themeStyleElement||(this._themeStyleElement=document.createElement("style"),this._terminal.screenElement.appendChild(this._themeStyleElement));var e=(e=(e=(e=this._terminalSelector+" ."+c+" { color: "+this._colors.foreground.css+"; background-color: "+this._colors.background.css+"; font-family: "+this._terminal.options.fontFamily+"; font-size: "+this._terminal.options.fontSize+"px;}")+this._terminalSelector+" span:not(."+s.BOLD_CLASS+") { font-weight: "+this._terminal.options.fontWeight+";}"+this._terminalSelector+" span."+s.BOLD_CLASS+" { font-weight: "+this._terminal.options.fontWeightBold+";}"+this._terminalSelector+" span."+s.ITALIC_CLASS+" { font-style: italic;}@keyframes blink { 0% { opacity: 1.0; } 50% { opacity: 0.0; } 100% { opacity: 1.0; }}")+this._terminalSelector+" ."+c+":not(."+f+") ."+s.CURSOR_CLASS+" { outline: 1px solid "+this._colors.cursor.css+"; outline-offset: -1px;}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_BLINK_CLASS+" { animation: blink 1s step-end infinite;}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BLOCK_CLASS+" { background-color: "+this._colors.cursor.css+"; color: "+this._colors.cursorAccent.css+";}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_BAR_CLASS+" { box-shadow: 1px 0 0 "+this._colors.cursor.css+" inset;}"+this._terminalSelector+" ."+c+"."+f+" ."+s.CURSOR_CLASS+"."+s.CURSOR_STYLE_UNDERLINE_CLASS+" { box-shadow: 0 -1px 0 "+this._colors.cursor.css+" inset;}")+this._terminalSelector+" ."+p+" { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}"+this._terminalSelector+" ."+p+" div { position: absolute; background-color: "+this._colors.selection.css+";}";this._colors.ansi.forEach((function(n,r){e+=t._terminalSelector+" ."+h+r+" { color: "+n.css+"; }"+t._terminalSelector+" ."+u+r+" { background-color: "+n.css+"; }"})),e+=this._terminalSelector+" ."+h+a.INVERTED_DEFAULT_COLOR+" { color: "+this._colors.background.css+"; }"+this._terminalSelector+" ."+u+a.INVERTED_DEFAULT_COLOR+" { background-color: "+this._colors.foreground.css+"; }",this._themeStyleElement.innerHTML=e},m.prototype.onDevicePixelRatioChange=function(){this._updateDimensions()},m.prototype._refreshRowElements=function(t,e){for(var n=this._rowElements.length;n<=e;n++){var r=document.createElement("div");this._rowContainer.appendChild(r),this._rowElements.push(r)}for(;this._rowElements.length>e;)this._rowContainer.removeChild(this._rowElements.pop())},m.prototype.onResize=function(t,e){this._refreshRowElements(t,e),this._updateDimensions()},m.prototype.onCharSizeChanged=function(){this._updateDimensions()},m.prototype.onBlur=function(){this._rowContainer.classList.remove(f)},m.prototype.onFocus=function(){this._rowContainer.classList.add(f)},m.prototype.onSelectionChanged=function(t,e,n){for(;this._selectionContainer.children.length;)this._selectionContainer.removeChild(this._selectionContainer.children[0]);var r,i,o,s,a;t&&e&&(a=t[1]-this._terminal.buffer.ydisp,r=e[1]-this._terminal.buffer.ydisp,i=Math.max(a,0),o=Math.min(r,this._terminal.rows-1),i>=this._terminal.rows||o<0||(s=document.createDocumentFragment(),n?s.appendChild(this._createSelectionElement(i,t[0],e[0],o-i+1)):(n=a===i?t[0]:0,a=i===o?e[0]:this._terminal.cols,s.appendChild(this._createSelectionElement(i,n,a)),s.appendChild(this._createSelectionElement(i+1,0,this._terminal.cols,o-i-1)),i!==o&&(t=r===o?e[0]:this._terminal.cols,s.appendChild(this._createSelectionElement(o,0,t)))),this._selectionContainer.appendChild(s)))},m.prototype._createSelectionElement=function(t,e,n,r){void 0===r&&(r=1);var i=document.createElement("div");return i.style.height=r*this.dimensions.actualCellHeight+"px",i.style.top=t*this.dimensions.actualCellHeight+"px",i.style.left=e*this.dimensions.actualCellWidth+"px",i.style.width=this.dimensions.actualCellWidth*(n-e)+"px",i},m.prototype.onCursorMove=function(){},m.prototype.onOptionsChanged=function(){this._updateDimensions(),this._injectCss(),this._terminal.refresh(0,this._terminal.rows-1)},m.prototype.clear=function(){this._rowElements.forEach((function(t){return t.innerHTML=""}))},m.prototype.renderRows=function(t,e){for(var n=this._terminal,r=n.buffer.ybase+n.buffer.y,i=this._terminal.buffer.x,o=this._terminal.options.cursorBlink,s=t;s<=e;s++){var a=this._rowElements[s],l=(a.innerHTML="",s+n.buffer.ydisp),c=n.buffer.lines.get(l),h=n.options.cursorStyle;a.appendChild(this._rowFactory.createRow(c,l===r,h,i,o,this.dimensions.actualCellWidth,n.cols))}},Object.defineProperty(m.prototype,"_terminalSelector",{get:function(){return"."+l+this._terminalClass},enumerable:!0,configurable:!0}),m.prototype.registerCharacterJoiner=function(t){return-1},m.prototype.deregisterCharacterJoiner=function(t){return!1},m.prototype._onLinkHover=function(t){this._setCellUnderline(t.x1,t.x2,t.y1,t.y2,t.cols,!0)},m.prototype._onLinkLeave=function(t){this._setCellUnderline(t.x1,t.x2,t.y1,t.y2,t.cols,!1)},m.prototype._setCellUnderline=function(t,e,n,r,i,o){for(;t!==e||n!==r;){var s=this._rowElements[n];if(!s)return;(s=s.children[t])&&(s.style.textDecoration=o?"underline":"none"),++t>=i&&(t=0,n++)}},t=m;function m(t,e){var n=i.call(this)||this;return n._terminal=t,n._colors=e,n._terminalClass=d++,n._rowElements=[],n._rowContainer=document.createElement("div"),n._rowContainer.classList.add(c),n._rowContainer.style.lineHeight="normal",n._rowContainer.setAttribute("aria-hidden","true"),n._refreshRowElements(n._terminal.cols,n._terminal.rows),n._selectionContainer=document.createElement("div"),n._selectionContainer.classList.add(p),n._selectionContainer.setAttribute("aria-hidden","true"),n.dimensions={scaledCharWidth:null,scaledCharHeight:null,scaledCellWidth:null,scaledCellHeight:null,scaledCharLeft:null,scaledCharTop:null,scaledCanvasWidth:null,scaledCanvasHeight:null,canvasWidth:null,canvasHeight:null,actualCellWidth:null,actualCellHeight:null},n._updateDimensions(),n._injectCss(),n._rowFactory=new s.DomRendererRowFactory(t.options,document),n._terminal.element.classList.add(l+n._terminalClass),n._terminal.screenElement.appendChild(n._rowContainer),n._terminal.screenElement.appendChild(n._selectionContainer),n._terminal.linkifier.onLinkHover((function(t){return n._onLinkHover(t)})),n._terminal.linkifier.onLinkLeave((function(t){return n._onLinkLeave(t)})),n}n.DomRenderer=t},{"../../common/Lifecycle":24,"../atlas/Types":55,"./DomRendererRowFactory":57}],57:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0});var r=t("../atlas/Types"),i=t("../../core/buffer/BufferLine");n.BOLD_CLASS="xterm-bold",n.DIM_CLASS="xterm-dim",n.ITALIC_CLASS="xterm-italic",n.UNDERLINE_CLASS="xterm-underline",n.CURSOR_CLASS="xterm-cursor",n.CURSOR_BLINK_CLASS="xterm-cursor-blink",n.CURSOR_STYLE_BLOCK_CLASS="xterm-cursor-block",n.CURSOR_STYLE_BAR_CLASS="xterm-cursor-bar",n.CURSOR_STYLE_UNDERLINE_CLASS="xterm-cursor-underline",o.prototype.createRow=function(t,e,o,s,a,l,c){for(var h=this._document.createDocumentFragment(),u=0,f=Math.min(t.length,c)-1;0<=f;f--)if(t.loadCell(f,this._workCell).getCode()!==i.NULL_CELL_CODE||e&&f===s){u=f+1;break}for(f=0;f>>0})}for(n=0;n<24;n++){var s=8+10*n,a=c(s);t.push({css:"#"+a+a+a,rgba:(s<<24|s<<16|s<<8|255)>>>0})}return t}(),h.prototype.setTheme=function(t){this.colors.foreground=this._parseColor((t=void 0===t?{}:t).foreground,r),this.colors.background=this._parseColor(t.background,i),this.colors.cursor=this._parseColor(t.cursor,o,!0),this.colors.cursorAccent=this._parseColor(t.cursorAccent,s,!0),this.colors.selection=this._parseColor(t.selection,a,!0),this.colors.ansi[0]=this._parseColor(t.black,n.DEFAULT_ANSI_COLORS[0]),this.colors.ansi[1]=this._parseColor(t.red,n.DEFAULT_ANSI_COLORS[1]),this.colors.ansi[2]=this._parseColor(t.green,n.DEFAULT_ANSI_COLORS[2]),this.colors.ansi[3]=this._parseColor(t.yellow,n.DEFAULT_ANSI_COLORS[3]),this.colors.ansi[4]=this._parseColor(t.blue,n.DEFAULT_ANSI_COLORS[4]),this.colors.ansi[5]=this._parseColor(t.magenta,n.DEFAULT_ANSI_COLORS[5]),this.colors.ansi[6]=this._parseColor(t.cyan,n.DEFAULT_ANSI_COLORS[6]),this.colors.ansi[7]=this._parseColor(t.white,n.DEFAULT_ANSI_COLORS[7]),this.colors.ansi[8]=this._parseColor(t.brightBlack,n.DEFAULT_ANSI_COLORS[8]),this.colors.ansi[9]=this._parseColor(t.brightRed,n.DEFAULT_ANSI_COLORS[9]),this.colors.ansi[10]=this._parseColor(t.brightGreen,n.DEFAULT_ANSI_COLORS[10]),this.colors.ansi[11]=this._parseColor(t.brightYellow,n.DEFAULT_ANSI_COLORS[11]),this.colors.ansi[12]=this._parseColor(t.brightBlue,n.DEFAULT_ANSI_COLORS[12]),this.colors.ansi[13]=this._parseColor(t.brightMagenta,n.DEFAULT_ANSI_COLORS[13]),this.colors.ansi[14]=this._parseColor(t.brightCyan,n.DEFAULT_ANSI_COLORS[14]),this.colors.ansi[15]=this._parseColor(t.brightWhite,n.DEFAULT_ANSI_COLORS[15])},h.prototype._parseColor=function(t,e,n){if(void 0===n&&(n=this.allowTransparency),void 0===t)return e;if(this._ctx.fillStyle=this._litmusColor,this._ctx.fillStyle=t,"string"!=typeof this._ctx.fillStyle)return console.warn("Color: "+t+" is invalid using fallback "+e.css),e;this._ctx.fillRect(0,0,1,1);var r=this._ctx.getImageData(0,0,1,1).data;return n||255===r[3]?{css:t,rgba:(r[0]<<24|r[1]<<16|r[2]<<8|r[3])>>>0}:(console.warn("Color: "+t+" is using transparency, but allowTransparency is false. Using fallback "+e.css+"."),e)},n.ColorManager=h},{}],59:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0}),n.addDisposableDomListener=function(t,e,n,r){return t.addEventListener(e,n,r),{dispose:function(){n&&t.removeEventListener(e,n,r)}}}},{}],60:[function(t,e,n){function r(t){this._renderCallback=t}Object.defineProperty(n,"__esModule",{value:!0}),r.prototype.dispose=function(){this._animationFrame&&(window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)},r.prototype.refresh=function(t,e,n){var r=this;this._rowCount=n,t=void 0!==t?t:0,e=void 0!==e?e:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,t):t,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,e):e,this._animationFrame||(this._animationFrame=window.requestAnimationFrame((function(){return r._innerRefresh()})))},r.prototype._innerRefresh=function(){void 0!==this._rowStart&&void 0!==this._rowEnd&&void 0!==this._rowCount&&(this._rowStart=Math.max(this._rowStart,0),this._rowEnd=Math.min(this._rowEnd,this._rowCount-1),this._renderCallback(this._rowStart,this._rowEnd),this._rowStart=void 0,this._rowEnd=void 0,this._animationFrame=void 0)},n.RenderDebouncer=r},{}],61:[function(t,e,n){var r,i,o=this&&this.__extends||(r=function(t,e){return(r=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])}))(t,e)},function(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)});Object.defineProperty(n,"__esModule",{value:!0}),t=t("../common/Lifecycle"),o(s,i=t.Disposable),s.prototype.setListener=function(t){var e=this;this._listener&&this.clearListener(),this._listener=t,this._outerListener=function(){e._listener&&(e._listener(window.devicePixelRatio,e._currentDevicePixelRatio),e._updateDpr())},this._updateDpr()},s.prototype.dispose=function(){i.prototype.dispose.call(this),this.clearListener()},s.prototype._updateDpr=function(){this._resolutionMediaMatchList&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._currentDevicePixelRatio=window.devicePixelRatio,this._resolutionMediaMatchList=window.matchMedia("screen and (resolution: "+window.devicePixelRatio+"dppx)"),this._resolutionMediaMatchList.addListener(this._outerListener))},s.prototype.clearListener=function(){this._resolutionMediaMatchList&&this._listener&&this._outerListener&&(this._resolutionMediaMatchList.removeListener(this._outerListener),this._resolutionMediaMatchList=void 0,this._listener=void 0,this._outerListener=void 0)},t=s;function s(){var t=null!==i&&i.apply(this,arguments)||this;return t._currentDevicePixelRatio=window.devicePixelRatio,t}n.ScreenDprMonitor=t},{"../common/Lifecycle":24}],62:[function(t,e,n){Object.defineProperty(n,"__esModule",{value:!0}),n=t("./public/Terminal"),e.exports=n.Terminal},{"./public/Terminal":37}]},{},[62])(62)},function(t,e){var n=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,r=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];t.exports=function(t){for(var e=t,i=t.indexOf("["),o=t.indexOf("]"),s=(-1!=i&&-1!=o&&(t=t.substring(0,i)+t.substring(i,o).replace(/:/g,";")+t.substring(o,t.length)),n.exec(t||"")),a={},l=14;l--;)a[r[l]]=s[l]||"";return-1!=i&&-1!=o&&(a.source=e,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a}},function(t,e,n){(function(e){t.exports=function(t){return n&&e.isBuffer(t)||r&&(t instanceof ArrayBuffer||i(t))};var n="function"==typeof e&&"function"==typeof e.isBuffer,r="function"==typeof ArrayBuffer,i=function(t){return"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(t):t.buffer instanceof ArrayBuffer}}).call(this,n(10).Buffer)},function(t,e){var n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){var r=n(37),i=n(23),o=n(1),s=n(8),a=n(24),l=n(25),c=n(2)("socket.io-client:manager"),h=n(22),u=n(52),f=Object.prototype.hasOwnProperty;function p(t,e){if(!(this instanceof p))return new p(t,e);t&&"object"==typeof t&&(e=t,t=void 0),(e=e||{}).path=e.path||"/socket.io",this.nsps={},this.subs=[],this.opts=e,this.reconnection(!1!==e.reconnection),this.reconnectionAttempts(e.reconnectionAttempts||1/0),this.reconnectionDelay(e.reconnectionDelay||1e3),this.reconnectionDelayMax(e.reconnectionDelayMax||5e3),this.randomizationFactor(e.randomizationFactor||.5),this.backoff=new u({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==e.timeout?2e4:e.timeout),this.readyState="closed",this.uri=t,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[],t=e.parser||s,this.encoder=new t.Encoder,this.decoder=new t.Decoder,this.autoConnect=!1!==e.autoConnect,this.autoConnect&&this.open()}(t.exports=p).prototype.emitAll=function(){for(var t in this.emit.apply(this,arguments),this.nsps)f.call(this.nsps,t)&&this.nsps[t].emit.apply(this.nsps[t],arguments)},p.prototype.updateSocketIds=function(){for(var t in this.nsps)f.call(this.nsps,t)&&(this.nsps[t].id=this.generateId(t))},p.prototype.generateId=function(t){return("/"===t?"":t+"#")+this.engine.id},o(p.prototype),p.prototype.reconnection=function(t){return arguments.length?(this._reconnection=!!t,this):this._reconnection},p.prototype.reconnectionAttempts=function(t){return arguments.length?(this._reconnectionAttempts=t,this):this._reconnectionAttempts},p.prototype.reconnectionDelay=function(t){return arguments.length?(this._reconnectionDelay=t,this.backoff&&this.backoff.setMin(t),this):this._reconnectionDelay},p.prototype.randomizationFactor=function(t){return arguments.length?(this._randomizationFactor=t,this.backoff&&this.backoff.setJitter(t),this):this._randomizationFactor},p.prototype.reconnectionDelayMax=function(t){return arguments.length?(this._reconnectionDelayMax=t,this.backoff&&this.backoff.setMax(t),this):this._reconnectionDelayMax},p.prototype.timeout=function(t){return arguments.length?(this._timeout=t,this):this._timeout},p.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},p.prototype.open=p.prototype.connect=function(t,e){var n,i,o,s,l,h;return c("readyState %s",this.readyState),~this.readyState.indexOf("open")||(c("opening %s",this.uri),this.engine=r(this.uri,this.opts),n=this.engine,(i=this).readyState="opening",this.skipReconnect=!1,o=a(n,"open",(function(){i.onopen(),t&&t()})),s=a(n,"error",(function(e){var n;c("connect_error"),i.cleanup(),i.readyState="closed",i.emitAll("connect_error",e),t?((n=new Error("Connection error")).data=e,t(n)):i.maybeReconnectOnOpen()})),!1!==this._timeout&&(l=this._timeout,c("connect attempt will timeout after %d",l),h=setTimeout((function(){c("connect attempt timed out after %d",l),o.destroy(),n.close(),n.emit("error","timeout"),i.emitAll("connect_timeout",l)}),l),this.subs.push({destroy:function(){clearTimeout(h)}})),this.subs.push(o),this.subs.push(s)),this},p.prototype.onopen=function(){c("open"),this.cleanup(),this.readyState="open",this.emit("open");var t=this.engine;this.subs.push(a(t,"data",l(this,"ondata"))),this.subs.push(a(t,"ping",l(this,"onping"))),this.subs.push(a(t,"pong",l(this,"onpong"))),this.subs.push(a(t,"error",l(this,"onerror"))),this.subs.push(a(t,"close",l(this,"onclose"))),this.subs.push(a(this.decoder,"decoded",l(this,"ondecoded")))},p.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},p.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},p.prototype.ondata=function(t){this.decoder.add(t)},p.prototype.ondecoded=function(t){this.emit("packet",t)},p.prototype.onerror=function(t){c("error",t),this.emitAll("error",t)},p.prototype.socket=function(t,e){var n,r=this.nsps[t];function o(){~h(n.connecting,r)||n.connecting.push(r)}return r||(r=new i(this,t,e),this.nsps[t]=r,n=this,r.on("connecting",o),r.on("connect",(function(){r.id=n.generateId(t)})),this.autoConnect&&o()),r},p.prototype.destroy=function(t){~(t=h(this.connecting,t))&&this.connecting.splice(t,1),this.connecting.length||this.close()},p.prototype.packet=function(t){c("writing packet %j",t);var e=this;t.query&&0===t.type&&(t.nsp+="?"+t.query),e.encoding?e.packetBuffer.push(t):(e.encoding=!0,this.encoder.encode(t,(function(n){for(var r=0;r=this._reconnectionAttempts?(c("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1):(t=this.backoff.duration(),c("will wait %dms before reconnect attempt",t),this.reconnecting=!0,e=setTimeout((function(){n.skipReconnect||(c("attempting reconnect"),n.emitAll("reconnect_attempt",n.backoff.attempts),n.emitAll("reconnecting",n.backoff.attempts),n.skipReconnect)||n.open((function(t){t?(c("reconnect attempt error"),n.reconnecting=!1,n.reconnect(),n.emitAll("reconnect_error",t.data)):(c("reconnect success"),n.onreconnect())}))}),t),this.subs.push({destroy:function(){clearTimeout(e)}}))},p.prototype.onreconnect=function(){var t=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",t)}},function(t,e,n){var r=n(11),i=n(40),o=n(48);n=n(49);e.polling=function(t){var e,n,s=!1,a=!1,l=!1!==t.jsonp;if("undefined"!=typeof location&&(e="https:"===location.protocol,n=(n=location.port)||(e?443:80),s=t.hostname!==location.hostname||n!==t.port,a=t.secure!==e),t.xdomain=s,t.xscheme=a,"open"in new r(t)&&!t.forceJSONP)return new i(t);if(l)return new o(t);throw new Error("JSONP disabled")},e.websocket=n},function(t,e,n){var r=n(12),i=n(3),o=n(0),s=n(4),a=n(21),l=n(5)("engine.io-client:polling"),c=(t.exports=h,null!=new(n(11))({xdomain:!1}).responseType);function h(t){var e=t&&t.forceBase64;c&&!e||(this.supportsBinary=!1),r.call(this,t)}s(h,r),h.prototype.name="polling",h.prototype.doOpen=function(){this.poll()},h.prototype.pause=function(t){var e,n=this;function r(){l("paused"),n.readyState="paused",t()}this.readyState="pausing",this.polling||!this.writable?(e=0,this.polling&&(l("we are currently polling - waiting to pause"),e++,this.once("pollComplete",(function(){l("pre-pause polling complete"),--e||r()}))),this.writable||(l("we are currently writing - waiting to pause"),e++,this.once("drain",(function(){l("pre-pause writing complete"),--e||r()})))):r()},h.prototype.poll=function(){l("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},h.prototype.onData=function(t){var e=this;l("polling got data %s",t),o.decodePayload(t,this.socket.binaryType,(function(t,n,r){if("opening"===e.readyState&&e.onOpen(),"close"===t.type)return e.onClose(),!1;e.onPacket(t)})),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():l('ignoring poll - transport state "%s"',this.readyState))},h.prototype.doClose=function(){var t=this;function e(){l("writing close packet"),t.write([{type:"close"}])}"open"===this.readyState?(l("transport open - closing"),e()):(l("transport not open - deferring close"),this.once("open",e))},h.prototype.write=function(t){function e(){n.writable=!0,n.emit("drain")}var n=this;this.writable=!1,o.encodePayload(t,this.supportsBinary,(function(t){n.doWrite(t,e)}))},h.prototype.uri=function(){var t=this.query||{},e=this.secure?"https":"http",n="";return!1!==this.timestampRequests&&(t[this.timestampParam]=a()),this.supportsBinary||t.sid||(t.b64=1),t=i.encode(t),this.port&&("https"==e&&443!==Number(this.port)||"http"==e&&80!==Number(this.port))&&(n=":"+this.port),t.length&&(t="?"+t),e+"://"+(-1!==this.hostname.indexOf(":")?"["+this.hostname+"]":this.hostname)+n+this.path+t}},function(t,e,n){(function(e){var r=n(9),i=Object.prototype.toString,o="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===i.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===i.call(File);t.exports=function t(n){if(!n||"object"!=typeof n)return!1;if(r(n)){for(var i=0,a=n.length;i>16&255,a[l++]=e>>8&255,a[l++]=255&e;return 2===s&&(e=i[t.charCodeAt(n)]<<2|i[t.charCodeAt(n+1)]>>4,a[l++]=255&e),1===s&&(e=i[t.charCodeAt(n)]<<10|i[t.charCodeAt(n+1)]<<4|i[t.charCodeAt(n+2)]>>2,a[l++]=e>>8&255,a[l++]=255&e),a},e.fromByteArray=function(t){for(var e,n=t.length,i=n%3,o=[],s=0,a=n-i;s>18&63]+r[t>>12&63]+r[t>>6&63]+r[63&t]}(i));return o.join("")}(t,s,a>2]+r[e<<4&63]+"==")):2==i&&(e=(t[n-2]<<8)+t[n-1],o.push(r[e>>10]+r[e>>4&63]+r[e<<2&63]+"=")),o.join("")};for(var r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,l=s.length;a>1,h=-7,u=n?i-1:0,f=n?-1:1;i=t[e+u];for(u+=f,o=i&(1<<-h)-1,i>>=-h,h+=a;0>=-h,h+=r;0>1,u=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,f=r?0:o-1,p=r?1:-1;o=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=c):(s=Math.floor(Math.log(e)/Math.LN2),e*(r=Math.pow(2,-s))<1&&(s--,r*=2),2<=(e+=1<=s+h?u/r:u*Math.pow(2,1-h))*r&&(s++,r/=2),c<=s+h?(a=0,s=c):1<=s+h?(a=(e*r-1)*Math.pow(2,i),s+=h):(a=e*Math.pow(2,h-1)*Math.pow(2,i),s=0));8<=i;t[n+f]=255&a,f+=p,a/=256,i-=8);for(s=s<>e&63|128)}function c(){if(r<=i)throw Error("Invalid byte index");var t=255&n[i];if(i++,128==(192&t))return 63&t;throw Error("Invalid continuation byte")}t.exports={version:"2.1.2",encode:function(t,e){for(var n,r,i,c=!1!==(e=e||{}).strict,h=s(t),u=h.length,f=-1,p="";++f>6&31|192):0==(4294901760&n)?(a(n,r)||(n=65533),i=o(n>>12&15|224),i+=l(n,6)):0==(4292870144&n)&&(i=o(n>>18&7|240),i=(i+=l(n,12))+l(n,6)),i+o(63&n|128)));return p},decode:function(t,e){for(var l,h=!1!==(e=e||{}).strict,u=(n=s(t),r=n.length,i=0,[]);!1!==(l=function(t){var e,o;if(r>>10&1023|55296),f=56320|1023&f),_+=o(f);return _}}},function(t,e){for(var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=new Uint8Array(256),i=0;i>2])+n[(3&e[o])<<4|e[o+1]>>4])+n[(15&e[o+1])<<2|e[o+2]>>6])+n[63&e[o+2]];return r%3==2?i=i.substring(0,i.length-1)+"=":r%3==1&&(i=i.substring(0,i.length-2)+"=="),i},e.decode=function(t){for(var e,n,i,o,s=.75*t.length,a=t.length,l=0,c=(s=("="===t[t.length-1]&&(s--,"="===t[t.length-2])&&s--,new ArrayBuffer(s)),new Uint8Array(s)),h=0;h>4,c[l++]=(15&n)<<4|i>>2,c[l++]=(3&i)<<6|63&o;return s}},function(t,e){var n="undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{return 2===new Blob(["hi"]).size}catch(t){return!1}}(),i=r&&function(){try{return 2===new Blob([new Uint8Array([1,2])]).size}catch(t){return!1}}(),o=n&&n.prototype.append&&n.prototype.getBlob;function s(t){return t.map((function(t){var e,n;return t.buffer instanceof ArrayBuffer?(e=t.buffer,t.byteLength!==e.byteLength&&((n=new Uint8Array(t.byteLength)).set(new Uint8Array(e,t.byteOffset,t.byteLength)),e=n.buffer),e):t}))}function a(t,e){e=e||{};var r=new n;return s(t).forEach((function(t){r.append(t)})),e.type?r.getBlob(e.type):r.getBlob()}function l(t,e){return new Blob(s(t),e||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,l.prototype=Blob.prototype),t.exports=r?i?Blob:l:o?a:void 0},function(t,e,n){function r(t){var n;function r(){if(r.enabled){for(var t=r,i=+new Date,o=i-(n||i),s=(t.diff=o,t.prev=n,t.curr=i,n=i,new Array(arguments.length)),a=0;a';o=document.createElement(t)}catch(t){(o=document.createElement("iframe")).name=l.iframeId,o.src="javascript:0"}o.id=l.iframeId,l.form.appendChild(o),l.iframe=o}this.form||(n=document.createElement("form"),r=document.createElement("textarea"),i=this.iframeId="eio_iframe_"+this.index,n.className="socketio",n.style.position="absolute",n.style.top="-1000px",n.style.left="-1000px",n.target=i,n.method="POST",n.setAttribute("accept-charset","utf-8"),r.name="d",n.appendChild(r),document.body.appendChild(n),this.form=n,this.area=r),this.form.action=this.uri(),h(),t=t.replace(a,"\\\n"),this.area.value=t.replace(s,"\\n");try{this.form.submit()}catch(t){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===l.iframe.readyState&&c()}:this.iframe.onload=c}}).call(this,n(16))},function(t,e,n){(function(e){var r,i,o=n(12),s=n(0),a=n(3),l=n(4),c=n(21),h=n(5)("engine.io-client:websocket");if("undefined"!=typeof WebSocket)r=WebSocket;else if("undefined"!=typeof self)r=self.WebSocket||self.MozWebSocket;else try{i=n(50)}catch(l){}var u=r||i;function f(t){t&&t.forceBase64&&(this.supportsBinary=!1),this.perMessageDeflate=t.perMessageDeflate,this.usingBrowserWebSocket=r&&!t.forceNode,this.protocols=t.protocols,this.usingBrowserWebSocket||(u=i),o.call(this,t)}l(t.exports=f,o),f.prototype.name="websocket",f.prototype.supportsBinary=!0,f.prototype.doOpen=function(){if(this.check()){var t=this.uri(),e=this.protocols,n={agent:this.agent,perMessageDeflate:this.perMessageDeflate};n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized,this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket&&!this.isReactNative?e?new u(t,e):new u(t):new u(t,e,n)}catch(t){return this.emit("error",t)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},f.prototype.addEventListeners=function(){var t=this;this.ws.onopen=function(){t.onOpen()},this.ws.onclose=function(){t.onClose()},this.ws.onmessage=function(e){t.onData(e.data)},this.ws.onerror=function(e){t.onError("websocket error",e)}},f.prototype.write=function(t){for(var n=this,r=(this.writable=!1,t.length),i=0,o=r;it.length)&&(e=t.length);for(var n=0,r=new Array(e);n>>0;n--;)e[n]=t[n];return e}function tt(t){return t.classList?Q(t.classList):(t.getAttribute("class")||"").split(" ").filter((function(t){return t}))}function et(t){return"".concat(t).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function nt(t){return Object.keys(t||{}).reduce((function(e,n){return e+"".concat(n,": ").concat(t[n].trim(),";")}),"")}function rt(t){return t.size!==Z.size||t.x!==Z.x||t.y!==Z.y||t.rotate!==Z.rotate||t.flipX||t.flipY}function it(){var t,e,n=S,r=X.familyPrefix,i=X.replacementClass,o=':root, :host {\n --fa-font-solid: normal 900 1em/1 "Font Awesome 6 Solid";\n --fa-font-regular: normal 400 1em/1 "Font Awesome 6 Regular";\n --fa-font-light: normal 300 1em/1 "Font Awesome 6 Light";\n --fa-font-thin: normal 100 1em/1 "Font Awesome 6 Thin";\n --fa-font-duotone: normal 900 1em/1 "Font Awesome 6 Duotone";\n --fa-font-brands: normal 400 1em/1 "Font Awesome 6 Brands";\n}\n\nsvg:not(:root).svg-inline--fa, svg:not(:host).svg-inline--fa {\n overflow: visible;\n box-sizing: content-box;\n}\n\n.svg-inline--fa {\n display: var(--fa-display, inline-block);\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-2xs {\n vertical-align: 0.1em;\n}\n.svg-inline--fa.fa-xs {\n vertical-align: 0em;\n}\n.svg-inline--fa.fa-sm {\n vertical-align: -0.0714285705em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.2em;\n}\n.svg-inline--fa.fa-xl {\n vertical-align: -0.25em;\n}\n.svg-inline--fa.fa-2xl {\n vertical-align: -0.3125em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: var(--fa-pull-margin, 0.3em);\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: var(--fa-pull-margin, 0.3em);\n width: auto;\n}\n.svg-inline--fa.fa-li {\n width: var(--fa-li-width, 2em);\n top: 0.25em;\n}\n.svg-inline--fa.fa-fw {\n width: var(--fa-fw-width, 1.25em);\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: var(--fa-counter-background-color, #ff253a);\n border-radius: var(--fa-counter-border-radius, 1em);\n box-sizing: border-box;\n color: var(--fa-inverse, #fff);\n line-height: var(--fa-counter-line-height, 1);\n max-width: var(--fa-counter-max-width, 5em);\n min-width: var(--fa-counter-min-width, 1.5em);\n overflow: hidden;\n padding: var(--fa-counter-padding, 0.25em 0.5em);\n right: var(--fa-right, 0);\n text-overflow: ellipsis;\n top: var(--fa-top, 0);\n -webkit-transform: scale(var(--fa-counter-scale, 0.25));\n transform: scale(var(--fa-counter-scale, 0.25));\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: var(--fa-bottom, 0);\n right: var(--fa-right, 0);\n top: auto;\n -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n transform: scale(var(--fa-layers-scale, 0.25));\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: var(--fa-bottom, 0);\n left: var(--fa-left, 0);\n right: auto;\n top: auto;\n -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n transform: scale(var(--fa-layers-scale, 0.25));\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n top: var(--fa-top, 0);\n right: var(--fa-right, 0);\n -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n transform: scale(var(--fa-layers-scale, 0.25));\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: var(--fa-left, 0);\n right: auto;\n top: var(--fa-top, 0);\n -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n transform: scale(var(--fa-layers-scale, 0.25));\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-2xs {\n font-size: 0.625em;\n line-height: 0.1em;\n vertical-align: 0.225em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n line-height: 0.0833333337em;\n vertical-align: 0.125em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n line-height: 0.0714285718em;\n vertical-align: 0.0535714295em;\n}\n\n.fa-lg {\n font-size: 1.25em;\n line-height: 0.05em;\n vertical-align: -0.075em;\n}\n\n.fa-xl {\n font-size: 1.5em;\n line-height: 0.0416666682em;\n vertical-align: -0.125em;\n}\n\n.fa-2xl {\n font-size: 2em;\n line-height: 0.03125em;\n vertical-align: -0.1875em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: var(--fa-li-margin, 2.5em);\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: calc(var(--fa-li-width, 2em) * -1);\n position: absolute;\n text-align: center;\n width: var(--fa-li-width, 2em);\n line-height: inherit;\n}\n\n.fa-border {\n border-color: var(--fa-border-color, #eee);\n border-radius: var(--fa-border-radius, 0.1em);\n border-style: var(--fa-border-style, solid);\n border-width: var(--fa-border-width, 0.08em);\n padding: var(--fa-border-padding, 0.2em 0.25em 0.15em);\n}\n\n.fa-pull-left {\n float: left;\n margin-right: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-pull-right {\n float: right;\n margin-left: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-beat {\n -webkit-animation-name: fa-beat;\n animation-name: fa-beat;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, ease-in-out);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-bounce {\n -webkit-animation-name: fa-bounce;\n animation-name: fa-bounce;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n}\n\n.fa-fade {\n -webkit-animation-name: fa-fade;\n animation-name: fa-fade;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-beat-fade {\n -webkit-animation-name: fa-beat-fade;\n animation-name: fa-beat-fade;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-flip {\n -webkit-animation-name: fa-flip;\n animation-name: fa-flip;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, ease-in-out);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-shake {\n -webkit-animation-name: fa-shake;\n animation-name: fa-shake;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, linear);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin {\n -webkit-animation-name: fa-spin;\n animation-name: fa-spin;\n -webkit-animation-delay: var(--fa-animation-delay, 0);\n animation-delay: var(--fa-animation-delay, 0);\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 2s);\n animation-duration: var(--fa-animation-duration, 2s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, linear);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin-reverse {\n --fa-animation-direction: reverse;\n}\n\n.fa-pulse,\n.fa-spin-pulse {\n -webkit-animation-name: fa-spin;\n animation-name: fa-spin;\n -webkit-animation-direction: var(--fa-animation-direction, normal);\n animation-direction: var(--fa-animation-direction, normal);\n -webkit-animation-duration: var(--fa-animation-duration, 1s);\n animation-duration: var(--fa-animation-duration, 1s);\n -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n -webkit-animation-timing-function: var(--fa-animation-timing, steps(8));\n animation-timing-function: var(--fa-animation-timing, steps(8));\n}\n\n@media (prefers-reduced-motion: reduce) {\n .fa-beat,\n.fa-bounce,\n.fa-fade,\n.fa-beat-fade,\n.fa-flip,\n.fa-pulse,\n.fa-shake,\n.fa-spin,\n.fa-spin-pulse {\n -webkit-animation-delay: -1ms;\n animation-delay: -1ms;\n -webkit-animation-duration: 1ms;\n animation-duration: 1ms;\n -webkit-animation-iteration-count: 1;\n animation-iteration-count: 1;\n transition-delay: 0s;\n transition-duration: 0s;\n }\n}\n@-webkit-keyframes fa-beat {\n 0%, 90% {\n -webkit-transform: scale(1);\n transform: scale(1);\n }\n 45% {\n -webkit-transform: scale(var(--fa-beat-scale, 1.25));\n transform: scale(var(--fa-beat-scale, 1.25));\n }\n}\n@keyframes fa-beat {\n 0%, 90% {\n -webkit-transform: scale(1);\n transform: scale(1);\n }\n 45% {\n -webkit-transform: scale(var(--fa-beat-scale, 1.25));\n transform: scale(var(--fa-beat-scale, 1.25));\n }\n}\n@-webkit-keyframes fa-bounce {\n 0% {\n -webkit-transform: scale(1, 1) translateY(0);\n transform: scale(1, 1) translateY(0);\n }\n 10% {\n -webkit-transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n }\n 30% {\n -webkit-transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n }\n 50% {\n -webkit-transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n }\n 57% {\n -webkit-transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n }\n 64% {\n -webkit-transform: scale(1, 1) translateY(0);\n transform: scale(1, 1) translateY(0);\n }\n 100% {\n -webkit-transform: scale(1, 1) translateY(0);\n transform: scale(1, 1) translateY(0);\n }\n}\n@keyframes fa-bounce {\n 0% {\n -webkit-transform: scale(1, 1) translateY(0);\n transform: scale(1, 1) translateY(0);\n }\n 10% {\n -webkit-transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n }\n 30% {\n -webkit-transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n }\n 50% {\n -webkit-transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n }\n 57% {\n -webkit-transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n }\n 64% {\n -webkit-transform: scale(1, 1) translateY(0);\n transform: scale(1, 1) translateY(0);\n }\n 100% {\n -webkit-transform: scale(1, 1) translateY(0);\n transform: scale(1, 1) translateY(0);\n }\n}\n@-webkit-keyframes fa-fade {\n 50% {\n opacity: var(--fa-fade-opacity, 0.4);\n }\n}\n@keyframes fa-fade {\n 50% {\n opacity: var(--fa-fade-opacity, 0.4);\n }\n}\n@-webkit-keyframes fa-beat-fade {\n 0%, 100% {\n opacity: var(--fa-beat-fade-opacity, 0.4);\n -webkit-transform: scale(1);\n transform: scale(1);\n }\n 50% {\n opacity: 1;\n -webkit-transform: scale(var(--fa-beat-fade-scale, 1.125));\n transform: scale(var(--fa-beat-fade-scale, 1.125));\n }\n}\n@keyframes fa-beat-fade {\n 0%, 100% {\n opacity: var(--fa-beat-fade-opacity, 0.4);\n -webkit-transform: scale(1);\n transform: scale(1);\n }\n 50% {\n opacity: 1;\n -webkit-transform: scale(var(--fa-beat-fade-scale, 1.125));\n transform: scale(var(--fa-beat-fade-scale, 1.125));\n }\n}\n@-webkit-keyframes fa-flip {\n 50% {\n -webkit-transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n }\n}\n@keyframes fa-flip {\n 50% {\n -webkit-transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n }\n}\n@-webkit-keyframes fa-shake {\n 0% {\n -webkit-transform: rotate(-15deg);\n transform: rotate(-15deg);\n }\n 4% {\n -webkit-transform: rotate(15deg);\n transform: rotate(15deg);\n }\n 8%, 24% {\n -webkit-transform: rotate(-18deg);\n transform: rotate(-18deg);\n }\n 12%, 28% {\n -webkit-transform: rotate(18deg);\n transform: rotate(18deg);\n }\n 16% {\n -webkit-transform: rotate(-22deg);\n transform: rotate(-22deg);\n }\n 20% {\n -webkit-transform: rotate(22deg);\n transform: rotate(22deg);\n }\n 32% {\n -webkit-transform: rotate(-12deg);\n transform: rotate(-12deg);\n }\n 36% {\n -webkit-transform: rotate(12deg);\n transform: rotate(12deg);\n }\n 40%, 100% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n}\n@keyframes fa-shake {\n 0% {\n -webkit-transform: rotate(-15deg);\n transform: rotate(-15deg);\n }\n 4% {\n -webkit-transform: rotate(15deg);\n transform: rotate(15deg);\n }\n 8%, 24% {\n -webkit-transform: rotate(-18deg);\n transform: rotate(-18deg);\n }\n 12%, 28% {\n -webkit-transform: rotate(18deg);\n transform: rotate(18deg);\n }\n 16% {\n -webkit-transform: rotate(-22deg);\n transform: rotate(-22deg);\n }\n 20% {\n -webkit-transform: rotate(22deg);\n transform: rotate(22deg);\n }\n 32% {\n -webkit-transform: rotate(-12deg);\n transform: rotate(-12deg);\n }\n 36% {\n -webkit-transform: rotate(12deg);\n transform: rotate(12deg);\n }\n 40%, 100% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n}\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both,\n.fa-flip-horizontal.fa-flip-vertical {\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n.fa-rotate-by {\n -webkit-transform: rotate(var(--fa-rotate-angle, none));\n transform: rotate(var(--fa-rotate-angle, none));\n}\n\n.fa-stack {\n display: inline-block;\n vertical-align: middle;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n z-index: var(--fa-stack-z-index, auto);\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: var(--fa-inverse, #fff);\n}\n\n.sr-only,\n.fa-sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border-width: 0;\n}\n\n.sr-only-focusable:not(:focus),\n.fa-sr-only-focusable:not(:focus) {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border-width: 0;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse,\n.fa-duotone.fa-inverse {\n color: var(--fa-inverse, #fff);\n}';return"fa"===r&&i===n||(t=new RegExp("\\.".concat("fa","\\-"),"g"),e=new RegExp("\\--".concat("fa","\\-"),"g"),n=new RegExp("\\.".concat(n),"g"),o=o.replace(t,".".concat(r,"-")).replace(e,"--".concat(r,"-")).replace(n,".".concat(i))),o}var ot=!1;function st(){if(X.autoAddCss&&!ot){var t=it();if(t&&w){for(var e=v.createElement("style"),n=(e.setAttribute("type","text/css"),e.innerHTML=t,v.head.childNodes),r=null,i=n.length-1;-1").concat(i.map(ht).join(""),"")}function ut(t,e,n){if(t&&t[e]&&t[e][n])return{prefix:e,iconName:n,icon:t[e][n]}}function ft(t,e,n,r){for(var i,o,s=Object.keys(t),a=s.length,l=void 0!==r?pt(e,r):e,c=void 0===n?(i=1,t[s[0]]):(i=0,n);i=ke[0]&&d<=ke[1],p={value:dt((_=2===f.length&&f[0]===f[1])?f[0]:f),isSecondary:m||_},d=p.value,f=p.isSecondary,m=u[0].startsWith("FontAwesome"),_=Tt(a,d),l=_,m&&(u=St[p=d],p=Tt("fas",p),(m=u||(p?{prefix:"fas",iconName:p}:null)||{prefix:null,iconName:null}).iconName)&&m.prefix&&(_=m.iconName,a=m.prefix),!_)||f||o&&o.getAttribute(A)===a&&o.getAttribute(L)===l?r():(t.setAttribute(n,l),o&&t.removeChild(o),(h=(c={iconName:null,title:null,titleId:null,prefix:null,transform:Z,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}}).extra).attributes[x]=e,Jt(_,a).then((function(i){i=qt(s(s({},c),{},{icons:{main:i,mask:{prefix:null,iconName:null,rest:[]}},prefix:a,iconName:l,extra:h,watchable:!0}));var o=v.createElement("svg");"::before"===e?t.insertBefore(o,t.firstChild):t.appendChild(o),o.outerHTML=i.map(ht).join("\n"),t.removeAttribute(n),r()})).catch(i))))}))}function Ee(t){return Promise.all([Se(t,"::before"),Se(t,"::after")])}function xe(t){return!(t.parentNode===document.head||~R.indexOf(t.tagName.toUpperCase())||t.getAttribute(x)||t.parentNode&&"svg"===t.parentNode.tagName)}function Ae(t){if(w)return new Promise((function(e,n){var r=Q(t.querySelectorAll("*")).filter(xe).map(Ee),i=ee("searchPseudoElements");he(),Promise.all(r).then((function(){i(),ue(),e()})).catch((function(){i(),ue(),n()}))}))}function Le(t){return t.toLowerCase().split(" ").reduce((function(t,e){var n=(e=e.toLowerCase().split("-"))[0],r=e.slice(1).join("-");if(n&&"h"===r)t.flipX=!0;else if(n&&"v"===r)t.flipY=!0;else if(r=parseFloat(r),!isNaN(r))switch(n){case"grow":t.size=t.size+r;break;case"shrink":t.size=t.size-r;break;case"left":t.x=t.x-r;break;case"right":t.x=t.x+r;break;case"up":t.y=t.y-r;break;case"down":t.y=t.y+r;break;case"rotate":t.rotate=t.rotate+r}return t}),{size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0})}var Te=!1,Re={x:0,y:0,width:"100%",height:"100%"};function Me(t){return t.attributes&&(t.attributes.fill||!(1 Start Log',console.log("stopping log, "+Ue),Fe=new Date,Oe+"\r\n\r\nLog End for "+Be+": "+Fe.getFullYear()+"/"+(Fe.getMonth()+1)+"/"+Fe.getDate()+" @ "+Fe.getHours()+":"+Fe.getMinutes()+":"+Fe.getSeconds()+"\r\n"):(je=Ue=!0,logBtn.innerHTML=' Stop Log',downloadLogBtn.style.color="#000",downloadLogBtn.addEventListener("click",en),console.log("starting log, "+Ue),Fe=new Date,"Log Start for "+Be+": "+Fe.getFullYear()+"/"+(Fe.getMonth()+1)+"/"+Fe.getDate()+" @ "+Fe.getHours()+":"+Fe.getMinutes()+":"+Fe.getSeconds()+"\r\n\r\n"),Pe=Fe,Ye.focus(),!1}function en(){var t,e;!0===je&&(He="WebSSH2-"+Pe.getFullYear()+(Pe.getMonth()+1)+Pe.getDate()+"_"+Pe.getHours()+Pe.getMinutes()+Pe.getSeconds()+".log",t=new Blob([Oe.replace(/[\u001b\u009b][[\]()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><;]/g,"")],{type:"text/plain"}),window.navigator.msSaveOrOpenBlob?window.navigator.msSaveBlob(t,He):((e=window.document.createElement("a")).href=window.URL.createObjectURL(t),e.download=He,document.body.appendChild(e),e.click(),document.body.removeChild(e))),Ye.focus()}Ye.open(Ge),Ye.focus(),Ye.fit(),window.addEventListener("resize",Je,!1),Ne=e.connect({path:"/ssh/socket.io"}),Ye.on("data",(function(t){Ne.emit("data",t)})),Ne.on("data",(function(t){Ye.write(t),Ue&&(Oe+=t)})),Ne.on("connect",(function(){Ne.emit("geometry",Ye.cols,Ye.rows)})),Ne.on("setTerminalOpts",(function(t){Ye.setOption("cursorBlink",t.cursorBlink),Ye.setOption("scrollback",t.scrollback),Ye.setOption("tabStopWidth",t.tabStopWidth),Ye.setOption("bellStyle",t.bellStyle)})),Ne.on("title",(function(t){document.title=t})),Ne.on("menu",(function(t){Ze(t)})),Ne.on("status",(function(t){qe.innerHTML=t})),Ne.on("ssherror",(function(t){qe.innerHTML=t,qe.style.backgroundColor="red",Ie=!0})),Ne.on("headerBackground",(function(t){Ke.style.backgroundColor=t})),Ne.on("header",(function(t){t&&(Ke.innerHTML=t,Ke.style.display="block",Ge.style.height="calc(100% - 38px)",Je())})),Ne.on("footer",(function(t){Be=t,Xe.innerHTML=t})),Ne.on("statusBackground",(function(t){qe.style.backgroundColor=t})),Ne.on("allowreplay",(function(t){!0===t?(console.log("allowreplay: "+t),We=!0,Ze(Ve.innerHTML+' Credentials')):(We=!1,console.log("allowreplay: "+t))})),Ne.on("allowreauth",(function(t){!0===t?(console.log("allowreauth: "+t),ze=!0,Ze(Ve.innerHTML+' Switch User')):(ze=!1,console.log("allowreauth: "+t))})),Ne.on("disconnect",(function(t){Ie||(qe.style.backgroundColor="red",qe.innerHTML="WEBSOCKET SERVER DISCONNECTED: "+t),Ne.io.reconnection(!1)})),Ne.on("error",(function(t){Ie||(qe.style.backgroundColor="red",qe.innerHTML="ERROR: "+t)})),Ne.on("reauth",(function(){ze&&$e()})),Ye.on("title",(function(t){document.title=t})),document.addEventListener("keydown",(function(t){t.ctrlKey&&t.shiftKey&&"Digit6"===t.code&&(t.preventDefault(),Ne.emit("data",""))}))},function(t,e){},,,,,function(t,e){}]); \ No newline at end of file