mirror of
https://github.com/Websoft9/websoft9.git
synced 2025-01-27 21:18:39 +08:00
3 lines
508 KiB
JavaScript
3 lines
508 KiB
JavaScript
/*! For license information please see 769.3b95354d.chunk.js.LICENSE.txt */
|
|
(self.webpackChunkapps=self.webpackChunkapps||[]).push([[769],{6396:function(e,t,i){"use strict";i.d(t,{zx:function(){return m}});var r,n=i(4942),s=i(9388),o=i(2791),a={badge:"pf-c-badge",button:"pf-c-button",buttonCount:"pf-c-button__count",buttonIcon:"pf-c-button__icon",buttonProgress:"pf-c-button__progress",modifiers:{active:"pf-m-active",block:"pf-m-block",small:"pf-m-small",primary:"pf-m-primary",displayLg:"pf-m-display-lg",secondary:"pf-m-secondary",tertiary:"pf-m-tertiary",link:"pf-m-link",unread:"pf-m-unread",inline:"pf-m-inline",danger:"pf-m-danger",warning:"pf-m-warning",control:"pf-m-control",expanded:"pf-m-expanded",plain:"pf-m-plain",disabled:"pf-m-disabled",ariaDisabled:"pf-m-aria-disabled",progress:"pf-m-progress",inProgress:"pf-m-in-progress",start:"pf-m-start",end:"pf-m-end",overpassFont:"pf-m-overpass-font"},spinner:"pf-c-spinner",themeDark:"pf-theme-dark"},c=i(1994),l={modifiers:{inline:"pf-m-inline",sm:"pf-m-sm",md:"pf-m-md",lg:"pf-m-lg",xl:"pf-m-xl"},spinner:"pf-c-spinner",spinnerClipper:"pf-c-spinner__clipper",spinnerLeadBall:"pf-c-spinner__lead-ball",spinnerPath:"pf-c-spinner__path",spinnerTailBall:"pf-c-spinner__tail-ball"};!function(e){e.sm="sm",e.md="md",e.lg="lg",e.xl="xl"}(r||(r={}));var u=function(e){var t=e.className,i=void 0===t?"":t,r=e.size,n=void 0===r?"xl":r,a=e["aria-valuetext"],u=void 0===a?"Loading...":a,h=e.isSVG,f=void 0!==h&&h,d=e.diameter,v=e.isInline,_=void 0!==v&&v,p=e["aria-label"],g=e["aria-labelledBy"],m=(0,s._T)(e,["className","size","aria-valuetext","isSVG","diameter","isInline","aria-label","aria-labelledBy"]),y=f?"svg":"span";return o.createElement(y,Object.assign({className:(0,c.i)(l.spinner,_?l.modifiers.inline:l.modifiers[n],i),role:"progressbar","aria-valuetext":u},f&&{viewBox:"0 0 100 100"},d&&{style:{"--pf-c-spinner--diameter":d}},p&&{"aria-label":p},g&&{"aria-labelledBy":g},!p&&!g&&{"aria-label":"Contents"},m),f?o.createElement("circle",{className:l.spinnerPath,cx:"50",cy:"50",r:"45",fill:"none"}):o.createElement(o.Fragment,null,o.createElement("span",{className:(0,c.i)(l.spinnerClipper)}),o.createElement("span",{className:(0,c.i)(l.spinnerLeadBall)}),o.createElement("span",{className:(0,c.i)(l.spinnerTailBall)})))};u.displayName="Spinner";var h,f,d=i(4134),v="pf-c-badge",_={read:"pf-m-read",unread:"pf-m-unread"},p=function(e){var t=e.isRead,i=void 0!==t&&t,r=e.className,n=void 0===r?"":r,a=e.children,l=void 0===a?"":a,u=e.screenReaderText,h=(0,s._T)(e,["isRead","className","children","screenReaderText"]);return o.createElement("span",Object.assign({},h,{className:(0,c.i)(v,i?_.read:_.unread,n)}),l,u&&o.createElement("span",{className:"pf-screen-reader"},u))};p.displayName="Badge",function(e){e.primary="primary",e.secondary="secondary",e.tertiary="tertiary",e.danger="danger",e.warning="warning",e.link="link",e.plain="plain",e.control="control"}(h||(h={})),function(e){e.button="button",e.submit="submit",e.reset="reset"}(f||(f={}));var g=function(e){var t=e.children,i=void 0===t?null:t,l=e.className,v=void 0===l?"":l,_=e.component,g=void 0===_?"button":_,y=e.isActive,b=void 0!==y&&y,C=e.isBlock,S=void 0!==C&&C,w=e.isDisabled,k=void 0!==w&&w,x=e.isAriaDisabled,L=void 0!==x&&x,E=e.isLoading,R=void 0===E?null:E,M=e.isDanger,A=void 0!==M&&M,D=e.spinnerAriaValueText,O=e.spinnerAriaLabelledBy,T=e.spinnerAriaLabel,B=e.isSmall,I=void 0!==B&&B,P=e.isLarge,F=void 0!==P&&P,H=e.inoperableEvents,N=void 0===H?["onClick","onKeyPress"]:H,W=e.isInline,U=void 0!==W&&W,j=e.type,z=void 0===j?f.button:j,q=e.variant,G=void 0===q?h.primary:q,K=e.iconPosition,Z=void 0===K?"left":K,V=e["aria-label"],X=void 0===V?null:V,Y=e.icon,J=void 0===Y?null:Y,$=e.ouiaId,Q=e.ouiaSafe,ee=void 0===Q||Q,te=e.tabIndex,ie=void 0===te?null:te,re=e.innerRef,ne=e.countOptions,se=(0,s._T)(e,["children","className","component","isActive","isBlock","isDisabled","isAriaDisabled","isLoading","isDanger","spinnerAriaValueText","spinnerAriaLabelledBy","spinnerAriaLabel","isSmall","isLarge","inoperableEvents","isInline","type","variant","iconPosition","aria-label","icon","ouiaId","ouiaSafe","tabIndex","innerRef","countOptions"]),oe=(0,d.S$)(m.displayName,$,ee,G),ae=g,ce="button"===ae,le=U&&"span"===ae,ue=N.reduce((function(e,t){return Object.assign(Object.assign({},e),(0,n.Z)({},t,(function(e){e.preventDefault()})))}),{});return o.createElement(ae,Object.assign({},se,L?ue:null,{"aria-disabled":k||L,"aria-label":X,className:(0,c.i)(a.button,a.modifiers[G],S&&a.modifiers.block,k&&a.modifiers.disabled,L&&a.modifiers.ariaDisabled,b&&a.modifiers.active,U&&G===h.link&&a.modifiers.inline,A&&(G===h.secondary||G===h.link)&&a.modifiers.danger,null!==R&&null!==i&&a.modifiers.progress,R&&a.modifiers.inProgress,I&&a.modifiers.small,F&&a.modifiers.displayLg,v),disabled:ce?k:null,tabIndex:null!==ie?ie:k?ce?null:-1:L?null:le?0:void 0,type:ce||le?z:null,role:le?"button":null,ref:re},oe),R&&o.createElement("span",{className:(0,c.i)(a.buttonProgress)},o.createElement(u,{size:r.md,isInline:U,"aria-valuetext":D,"aria-label":T,"aria-labelledby":O})),G===h.plain&&null===i&&J?J:null,G!==h.plain&&J&&"left"===Z&&o.createElement("span",{className:(0,c.i)(a.buttonIcon,a.modifiers.start)},J),i,G!==h.plain&&J&&"right"===Z&&o.createElement("span",{className:(0,c.i)(a.buttonIcon,a.modifiers.end)},J),ne&&o.createElement("span",{className:(0,c.i)(a.buttonCount,ne.className)},o.createElement(p,{isRead:ne.isRead},ne.count)))},m=o.forwardRef((function(e,t){return o.createElement(g,Object.assign({innerRef:t},e))}));m.displayName="Button"},9061:function(e,t,i){"use strict";i.d(t,{i:function(){return d}});var r=i(5671),n=i(3144),s=i(136),o=i(7277),a=i(9388),c=i(2791),l=i(4226),u=i(1994),h=i(8132),f=i(4134),d=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(e){var n;return(0,r.Z)(this,i),(n=t.call(this,e)).handleChange=function(e){n.props.onChange(e.currentTarget.value,e)},e.id||e["aria-label"]||console.error("FormSelect requires either an id or aria-label to be specified"),n.state={ouiaStateId:(0,f.ql)(i.displayName,e.validated)},n}return(0,n.Z)(i,[{key:"render",value:function(){var e=this.props,t=e.children,r=e.className,n=e.value,s=e.validated,o=e.isDisabled,d=e.isRequired,v=e.isIconSprite,_=e.ouiaId,p=e.ouiaSafe,g=(0,a._T)(e,["children","className","value","validated","isDisabled","isRequired","isIconSprite","ouiaId","ouiaSafe"]),m=c.Children.toArray(t).find((function(e){return e.props.value===n})),y=m&&m.props.isPlaceholder;return c.createElement("select",Object.assign({},g,{className:(0,u.i)(l.Z.formControl,v&&l.Z.modifiers.iconSprite,r,s===h.LD.success&&l.Z.modifiers.success,s===h.LD.warning&&l.Z.modifiers.warning,y&&l.Z.modifiers.placeholder),"aria-invalid":s===h.LD.error},(0,f.dp)(i.displayName,void 0!==_?_:this.state.ouiaStateId,p),{onChange:this.handleChange,disabled:o,required:d,value:n}),t)}}]),i}(c.Component);d.displayName="FormSelect",d.defaultProps={className:"",value:"",validated:"default",isDisabled:!1,isRequired:!1,isIconSprite:!1,onBlur:function(){},onFocus:function(){},onChange:function(){},ouiaSafe:!0}},433:function(e,t,i){"use strict";i.d(t,{j:function(){return s}});var r=i(9388),n=i(2791),s=function(e){var t=e.className,i=void 0===t?"":t,s=e.value,o=void 0===s?"":s,a=e.isDisabled,c=void 0!==a&&a,l=e.label,u=(e.isPlaceholder,(0,r._T)(e,["className","value","isDisabled","label","isPlaceholder"]));return n.createElement("option",Object.assign({},u,{className:i,value:o,disabled:c}),l)};s.displayName="FormSelectOption"},2187:function(e,t,i){"use strict";i.d(t,{u:function(){return Xt}});var r=i(5671),n=i(3144),s=i(136),o=i(7277),a=i(9388),c=i(2791),l=i(4164),u=i(8132),h=i(1677),f=i(1994),d="pf-c-backdrop",v="pf-c-backdrop__open",_=["input","select","textarea","a[href]","button","[tabindex]:not(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"],p=_.join(","),g="undefined"===typeof Element,m=g?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,y=!g&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},b=function(e,t,i){var r=Array.prototype.slice.apply(e.querySelectorAll(p));return t&&m.call(e,p)&&r.unshift(e),r=r.filter(i)},C=function e(t,i,r){for(var n=[],s=Array.from(t);s.length;){var o=s.shift();if("SLOT"===o.tagName){var a=o.assignedElements(),c=e(a.length?a:o.children,!0,r);r.flatten?n.push.apply(n,c):n.push({scope:o,candidates:c})}else{m.call(o,p)&&r.filter(o)&&(i||!t.includes(o))&&n.push(o);var l=o.shadowRoot||"function"===typeof r.getShadowRoot&&r.getShadowRoot(o),u=!r.shadowRootFilter||r.shadowRootFilter(o);if(l&&u){var h=e(!0===l?o.children:l.children,!0,r);r.flatten?n.push.apply(n,h):n.push({scope:o,candidates:h})}else s.unshift.apply(s,o.children)}}return n},S=function(e,t){return e.tabIndex<0&&(t||/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||e.isContentEditable)&&isNaN(parseInt(e.getAttribute("tabindex"),10))?0:e.tabIndex},w=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},k=function(e){return"INPUT"===e.tagName},x=function(e){return function(e){return k(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t,i=e.form||y(e),r=function(e){return i.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("undefined"!==typeof window&&"undefined"!==typeof window.CSS&&"function"===typeof window.CSS.escape)t=r(window.CSS.escape(e.name));else try{t=r(e.name)}catch(s){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",s.message),!1}var n=function(e,t){for(var i=0;i<e.length;i++)if(e[i].checked&&e[i].form===t)return e[i]}(t,e.form);return!n||n===e}(e)},L=function(e){var t=e.getBoundingClientRect(),i=t.width,r=t.height;return 0===i&&0===r},E=function(e,t){return!(t.disabled||function(e){return k(e)&&"hidden"===e.type}(t)||function(e,t){var i=t.displayCheck,r=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var n=m.call(e,"details>summary:first-of-type")?e.parentElement:e;if(m.call(n,"details:not([open]) *"))return!0;var s=y(e).host,o=(null===s||void 0===s?void 0:s.ownerDocument.contains(s))||e.ownerDocument.contains(e);if(i&&"full"!==i){if("non-zero-area"===i)return L(e)}else{if("function"===typeof r){for(var a=e;e;){var c=e.parentElement,l=y(e);if(c&&!c.shadowRoot&&!0===r(c))return L(e);e=e.assignedSlot?e.assignedSlot:c||l===e.ownerDocument?c:l.host}e=a}if(o)return!e.getClientRects().length}return!1}(t,e)||function(e){return"DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some((function(e){return"SUMMARY"===e.tagName}))}(t)||function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var i=0;i<t.children.length;i++){var r=t.children.item(i);if("LEGEND"===r.tagName)return!!m.call(t,"fieldset[disabled] *")||!r.contains(e)}return!0}t=t.parentElement}return!1}(t))},R=function(e,t){return!(x(t)||S(t)<0||!E(e,t))},M=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},A=function e(t){var i=[],r=[];return t.forEach((function(t,n){var s=!!t.scope,o=s?t.scope:t,a=S(o,s),c=s?e(t.candidates):o;0===a?s?i.push.apply(i,c):i.push(o):r.push({documentOrder:n,tabIndex:a,item:t,isScope:s,content:c})})),r.sort(w).reduce((function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e}),[]).concat(i)},D=function(e,t){var i;return i=(t=t||{}).getShadowRoot?C([e],t.includeContainer,{filter:R.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:M}):b(e,t.includeContainer,R.bind(null,t)),A(i)},O=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return!1!==m.call(e,p)&&R(t,e)},T=_.concat("iframe").join(","),B=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return!1!==m.call(e,T)&&E(t,e)};function I(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,r)}return i}function P(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?I(Object(i),!0).forEach((function(t){F(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):I(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function F(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var H=function(){var e=[];return{activateTrap:function(t){if(e.length>0){var i=e[e.length-1];i!==t&&i.pause()}var r=e.indexOf(t);-1===r||e.splice(r,1),e.push(t)},deactivateTrap:function(t){var i=e.indexOf(t);-1!==i&&e.splice(i,1),e.length>0&&e[e.length-1].unpause()}}}(),N=function(e){return setTimeout(e,0)},W=function(e,t){var i=-1;return e.every((function(e,r){return!t(e)||(i=r,!1)})),i},U=function(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),r=1;r<t;r++)i[r-1]=arguments[r];return"function"===typeof e?e.apply(void 0,i):e},j=function(e){return e.target.shadowRoot&&"function"===typeof e.composedPath?e.composedPath()[0]:e.target},z=function(e,t){var i,r=(null===t||void 0===t?void 0:t.document)||document,n=P({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0},t),s={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0},o=function(e,t,i){return e&&void 0!==e[t]?e[t]:n[i||t]},a=function(e){return s.containerGroups.findIndex((function(t){var i=t.container,r=t.tabbableNodes;return i.contains(e)||r.find((function(t){return t===e}))}))},c=function(e){var t=n[e];if("function"===typeof t){for(var i=arguments.length,s=new Array(i>1?i-1:0),o=1;o<i;o++)s[o-1]=arguments[o];t=t.apply(void 0,s)}if(!0===t&&(t=void 0),!t){if(void 0===t||!1===t)return t;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var a=t;if("string"===typeof t&&!(a=r.querySelector(t)))throw new Error("`".concat(e,"` as selector refers to no known node"));return a},l=function(){var e=c("initialFocus");if(!1===e)return!1;if(void 0===e)if(a(r.activeElement)>=0)e=r.activeElement;else{var t=s.tabbableGroups[0];e=t&&t.firstTabbableNode||c("fallbackFocus")}if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},u=function(){if(s.containerGroups=s.containers.map((function(e){var t,i,r=D(e,n.tabbableOptions),s=(t=e,(i=(i=n.tabbableOptions)||{}).getShadowRoot?C([t],i.includeContainer,{filter:E.bind(null,i),flatten:!0,getShadowRoot:i.getShadowRoot}):b(t,i.includeContainer,E.bind(null,i)));return{container:e,tabbableNodes:r,focusableNodes:s,firstTabbableNode:r.length>0?r[0]:null,lastTabbableNode:r.length>0?r[r.length-1]:null,nextTabbableNode:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=s.findIndex((function(t){return t===e}));if(!(i<0))return t?s.slice(i+1).find((function(e){return O(e,n.tabbableOptions)})):s.slice(0,i).reverse().find((function(e){return O(e,n.tabbableOptions)}))}}})),s.tabbableGroups=s.containerGroups.filter((function(e){return e.tabbableNodes.length>0})),s.tabbableGroups.length<=0&&!c("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},h=function e(t){!1!==t&&t!==r.activeElement&&(t&&t.focus?(t.focus({preventScroll:!!n.preventScroll}),s.mostRecentlyFocusedNode=t,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"===typeof e.select}(t)&&t.select()):e(l()))},f=function(e){var t=c("setReturnFocus",e);return t||!1!==t&&e},d=function(e){var t=j(e);a(t)>=0||(U(n.clickOutsideDeactivates,e)?i.deactivate({returnFocus:n.returnFocusOnDeactivate&&!B(t,n.tabbableOptions)}):U(n.allowOutsideClick,e)||e.preventDefault())},v=function(e){var t=j(e),i=a(t)>=0;i||t instanceof Document?i&&(s.mostRecentlyFocusedNode=t):(e.stopImmediatePropagation(),h(s.mostRecentlyFocusedNode||l()))},_=function(e){if(function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e)&&!1!==U(n.escapeDeactivates,e))return e.preventDefault(),void i.deactivate();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){var t=j(e);u();var i=null;if(s.tabbableGroups.length>0){var r=a(t),o=r>=0?s.containerGroups[r]:void 0;if(r<0)i=e.shiftKey?s.tabbableGroups[s.tabbableGroups.length-1].lastTabbableNode:s.tabbableGroups[0].firstTabbableNode;else if(e.shiftKey){var l=W(s.tabbableGroups,(function(e){var i=e.firstTabbableNode;return t===i}));if(l<0&&(o.container===t||B(t,n.tabbableOptions)&&!O(t,n.tabbableOptions)&&!o.nextTabbableNode(t,!1))&&(l=r),l>=0){var f=0===l?s.tabbableGroups.length-1:l-1;i=s.tabbableGroups[f].lastTabbableNode}}else{var d=W(s.tabbableGroups,(function(e){var i=e.lastTabbableNode;return t===i}));if(d<0&&(o.container===t||B(t,n.tabbableOptions)&&!O(t,n.tabbableOptions)&&!o.nextTabbableNode(t))&&(d=r),d>=0){var v=d===s.tabbableGroups.length-1?0:d+1;i=s.tabbableGroups[v].firstTabbableNode}}}else i=c("fallbackFocus");i&&(e.preventDefault(),h(i))}(e)},p=function(e){var t=j(e);a(t)>=0||U(n.clickOutsideDeactivates,e)||U(n.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},g=function(){if(s.active)return H.activateTrap(i),s.delayInitialFocusTimer=n.delayInitialFocus?N((function(){h(l())})):h(l()),r.addEventListener("focusin",v,!0),r.addEventListener("mousedown",d,{capture:!0,passive:!1}),r.addEventListener("touchstart",d,{capture:!0,passive:!1}),r.addEventListener("click",p,{capture:!0,passive:!1}),r.addEventListener("keydown",_,{capture:!0,passive:!1}),i},m=function(){if(s.active)return r.removeEventListener("focusin",v,!0),r.removeEventListener("mousedown",d,!0),r.removeEventListener("touchstart",d,!0),r.removeEventListener("click",p,!0),r.removeEventListener("keydown",_,!0),i};return(i={get active(){return s.active},get paused(){return s.paused},activate:function(e){if(s.active)return this;var t=o(e,"onActivate"),i=o(e,"onPostActivate"),n=o(e,"checkCanFocusTrap");n||u(),s.active=!0,s.paused=!1,s.nodeFocusedBeforeActivation=r.activeElement,t&&t();var a=function(){n&&u(),g(),i&&i()};return n?(n(s.containers.concat()).then(a,a),this):(a(),this)},deactivate:function(e){if(!s.active)return this;var t=P({onDeactivate:n.onDeactivate,onPostDeactivate:n.onPostDeactivate,checkCanReturnFocus:n.checkCanReturnFocus},e);clearTimeout(s.delayInitialFocusTimer),s.delayInitialFocusTimer=void 0,m(),s.active=!1,s.paused=!1,H.deactivateTrap(i);var r=o(t,"onDeactivate"),a=o(t,"onPostDeactivate"),c=o(t,"checkCanReturnFocus"),l=o(t,"returnFocus","returnFocusOnDeactivate");r&&r();var u=function(){N((function(){l&&h(f(s.nodeFocusedBeforeActivation)),a&&a()}))};return l&&c?(c(f(s.nodeFocusedBeforeActivation)).then(u,u),this):(u(),this)},pause:function(){return s.paused||!s.active||(s.paused=!0,m()),this},unpause:function(){return s.paused&&s.active?(s.paused=!1,u(),g(),this):this},updateContainerElements:function(e){var t=[].concat(e).filter(Boolean);return s.containers=t.map((function(e){return"string"===typeof e?r.querySelector(e):e})),s.active&&u(),this}}).updateContainerElements(e),i},q=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(e){var n;return(0,r.Z)(this,i),(n=t.call(this,e)).divRef=n.props.innerRef||c.createRef(),"undefined"!==typeof document&&(n.previouslyFocusedElement=document.activeElement),n}return(0,n.Z)(i,[{key:"componentDidMount",value:function(){this.focusTrap=z(this.divRef.current,Object.assign(Object.assign({},this.props.focusTrapOptions),{returnFocusOnDeactivate:!1})),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()}},{key:"componentDidUpdate",value:function(e){e.active&&!this.props.active?this.focusTrap.deactivate():!e.active&&this.props.active&&this.focusTrap.activate(),e.paused&&!this.props.paused?this.focusTrap.unpause():!e.paused&&this.props.paused&&this.focusTrap.pause()}},{key:"componentWillUnmount",value:function(){this.focusTrap.deactivate(),!1!==this.props.focusTrapOptions.returnFocusOnDeactivate&&this.previouslyFocusedElement&&this.previouslyFocusedElement.focus&&this.previouslyFocusedElement.focus({preventScroll:this.props.preventScrollOnDeactivate})}},{key:"render",value:function(){var e=this.props,t=e.children,i=e.className,r=(e.focusTrapOptions,e.active,e.paused,e.preventScrollOnDeactivate,e.innerRef,(0,a._T)(e,["children","className","focusTrapOptions","active","paused","preventScrollOnDeactivate","innerRef"]));return c.createElement("div",Object.assign({ref:this.divRef,className:i},r),t)}}]),i}(c.Component);q.displayName="FocusTrap",q.defaultProps={active:!0,paused:!1,focusTrapOptions:{},preventScrollOnDeactivate:!1};var G=c.forwardRef((function(e,t){return c.createElement(q,Object.assign({innerRef:t},e))})),K={button:"pf-c-button",modalBox:"pf-c-modal-box",modalBoxBody:"pf-c-modal-box__body",modalBoxDescription:"pf-c-modal-box__description",modalBoxFooter:"pf-c-modal-box__footer",modalBoxHeader:"pf-c-modal-box__header",modalBoxHeaderMain:"pf-c-modal-box__header-main",modalBoxTitle:"pf-c-modal-box__title",modalBoxTitleIcon:"pf-c-modal-box__title-icon",modalBoxTitleText:"pf-c-modal-box__title-text",modifiers:{sm:"pf-m-sm",md:"pf-m-md",lg:"pf-m-lg",alignTop:"pf-m-align-top",danger:"pf-m-danger",warning:"pf-m-warning",success:"pf-m-success",default:"pf-m-default",info:"pf-m-info",help:"pf-m-help",icon:"pf-m-icon"},themeDark:"pf-theme-dark"},Z="pf-l-bullseye",V=i(4134),X=function(e){var t=e.children,i=void 0===t?null:t,r=e.className,n=void 0===r?"":r,s=(0,a._T)(e,["children","className"]);return c.createElement("div",Object.assign({},s,{className:(0,f.i)(d,n)}),i)};X.displayName="Backdrop";var Y=function(e){var t=e.children,i=void 0===t?null:t,r=e.className,n=void 0===r?"":r,s=(0,a._T)(e,["children","className"]);return c.createElement("div",Object.assign({},s,{className:(0,f.i)(K.modalBoxBody,n)}),i)};Y.displayName="ModalBoxBody";var J=i(6396),$=i(9720),Q=(0,$.IU)({name:"TimesIcon",height:512,width:352,svgPath:"M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z",yOffset:0,xOffset:0}),ee=function e(t){var i=t.className,r=void 0===i?"":i,n=t.onClose,s=void 0===n?function(){}:n,o=t.ouiaId,l=(0,a._T)(t,["className","onClose","ouiaId"]);return c.createElement(J.zx,Object.assign({className:r,variant:"plain",onClick:s,"aria-label":"Close"},o&&{ouiaId:"".concat(o,"-").concat(e.displayName)},l),c.createElement(Q,null))};ee.displayName="ModalBoxCloseButton";var te={name:"--pf-c-modal-box--m-align-top--spacer",value:"0.5rem",var:"var(--pf-c-modal-box--m-align-top--spacer)"},ie=function(e){var t=e.children,i=e.className,r=void 0===i?"":i,n=e.variant,s=void 0===n?"default":n,o=e.position,l=e.positionOffset,u=e["aria-labelledby"],h=e["aria-label"],d=void 0===h?"":h,v=e["aria-describedby"],_=e.style,p=(0,a._T)(e,["children","className","variant","position","positionOffset","aria-labelledby","aria-label","aria-describedby","style"]);return l&&((_=_||{})[te.name]=l),c.createElement("div",Object.assign({},p,{role:"dialog","aria-label":d||null,"aria-labelledby":u||null,"aria-describedby":v,"aria-modal":"true",className:(0,f.i)(K.modalBox,r,"top"===o&&K.modifiers.alignTop,"large"===s&&K.modifiers.lg,"small"===s&&K.modifiers.sm,"medium"===s&&K.modifiers.md),style:_}),t)};ie.displayName="ModalBox";var re=function(e){var t=e.children,i=void 0===t?null:t,r=e.className,n=void 0===r?"":r,s=(0,a._T)(e,["children","className"]);return c.createElement("footer",Object.assign({},s,{className:(0,f.i)(K.modalBoxFooter,n)}),i)};re.displayName="ModalBoxFooter";var ne=function(e){var t=e.children,i=void 0===t?null:t,r=e.className,n=void 0===r?"":r,s=e.id,o=void 0===s?"":s,l=(0,a._T)(e,["children","className","id"]);return c.createElement("div",Object.assign({},l,{id:o,className:(0,f.i)(K.modalBoxDescription,n)}),i)};ne.displayName="ModalBoxDescription";var se=function(e){var t=e.children,i=void 0===t?null:t,r=e.className,n=void 0===r?"":r,s=e.help,o=void 0===s?null:s,l=(0,a._T)(e,["children","className","help"]);return c.createElement("header",Object.assign({className:(0,f.i)(K.modalBoxHeader,o&&K.modifiers.help,n)},l),o&&c.createElement(c.Fragment,null,c.createElement("div",{className:(0,f.i)(K.modalBoxHeaderMain)},i),c.createElement("div",{className:"pf-c-modal-box__header-help"},o)),!o&&i)};se.displayName="ModalBoxHeader";var oe=i(9439),ae="pf-u-screen-reader",ce={top:"pf-m-top",topLeft:"pf-m-top-left",topRight:"pf-m-top-right",bottom:"pf-m-bottom",bottomLeft:"pf-m-bottom-left",bottomRight:"pf-m-bottom-right",left:"pf-m-left",leftTop:"pf-m-left-top",leftBottom:"pf-m-left-bottom",right:"pf-m-right",rightTop:"pf-m-right-top",rightBottom:"pf-m-right-bottom",textAlignLeft:"pf-m-text-align-left"},le="pf-c-tooltip",ue="pf-c-tooltip__arrow",he="pf-c-tooltip__content",fe=function(e){var t=e.className,i=e.children,r=e.isLeftAligned,n=(0,a._T)(e,["className","children","isLeftAligned"]);return c.createElement("div",Object.assign({className:(0,f.i)(he,r&&ce.textAlignLeft,t)},n),i)};fe.displayName="TooltipContent";var de=function(e){var t=e.className,i=(0,a._T)(e,["className"]);return c.createElement("div",Object.assign({className:(0,f.i)(ue,t)},i))};de.displayName="TooltipArrow";var ve={name:"--pf-c-tooltip--MaxWidth",value:"18.75rem",var:"var(--pf-c-tooltip--MaxWidth)"},_e=i(3433);function pe(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function ge(e){if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t?t.defaultView:window}return e}function me(e){var t=ge(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function ye(e){return e instanceof ge(e).Element||e instanceof Element}function be(e){return e instanceof ge(e).HTMLElement||e instanceof HTMLElement}function Ce(e){return e?(e.nodeName||"").toLowerCase():null}function Se(e){return(ye(e)?e.ownerDocument:e.document).documentElement}function we(e){return pe(Se(e)).left+me(e).scrollLeft}function ke(e){return ge(e).getComputedStyle(e)}function xe(e){var t=ke(e),i=t.overflow,r=t.overflowX,n=t.overflowY;return/auto|scroll|overlay|hidden/.test(i+n+r)}function Le(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=Se(t),n=pe(e),s=be(t),o={scrollLeft:0,scrollTop:0},a={x:0,y:0};return(s||!s&&!i)&&(("body"!==Ce(t)||xe(r))&&(o=function(e){return e!==ge(e)&&be(e)?{scrollLeft:(t=e).scrollLeft,scrollTop:t.scrollTop}:me(e);var t}(t)),be(t)?((a=pe(t)).x+=t.clientLeft,a.y+=t.clientTop):r&&(a.x=we(r))),{x:n.left+o.scrollLeft-a.x,y:n.top+o.scrollTop-a.y,width:n.width,height:n.height}}function Ee(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function Re(e){return"html"===Ce(e)?e:e.assignedSlot||e.parentNode||e.host||Se(e)}function Me(e){return["html","body","#document"].indexOf(Ce(e))>=0?e.ownerDocument.body:be(e)&&xe(e)?e:Me(Re(e))}function Ae(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=Me(e),r="body"===Ce(i),n=ge(i),s=r?[n].concat(n.visualViewport||[],xe(i)?i:[]):i,o=t.concat(s);return r?o:o.concat(Ae(Re(s)))}function De(e){return["table","td","th"].indexOf(Ce(e))>=0}function Oe(e){if(!be(e)||"fixed"===ke(e).position)return null;var t=e.offsetParent;if(t){var i=Se(t);if("body"===Ce(t)&&"static"===ke(t).position&&"static"!==ke(i).position)return i}return t}function Te(e){for(var t=ge(e),i=Oe(e);i&&De(i)&&"static"===ke(i).position;)i=Oe(i);return i&&"body"===Ce(i)&&"static"===ke(i).position?t:i||function(e){for(var t=Re(e);be(t)&&["html","body"].indexOf(Ce(t))<0;){var i=ke(t);if("none"!==i.transform||"none"!==i.perspective||i.willChange&&"auto"!==i.willChange)return t;t=t.parentNode}return null}(e)||t}var Be="top",Ie="bottom",Pe="right",Fe="left",He="auto",Ne=[Be,Ie,Pe,Fe],We="start",Ue="end",je="clippingParents",ze="viewport",qe="popper",Ge="reference",Ke=Ne.reduce((function(e,t){return e.concat(["".concat(t,"-").concat(We),"".concat(t,"-").concat(Ue)])}),[]),Ze=[].concat(Ne,[He]).reduce((function(e,t){return e.concat([t,"".concat(t,"-").concat(We),"".concat(t,"-").concat(Ue)])}),[]),Ve=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function Xe(e){var t=new Map,i=new Set,r=[];function n(e){i.add(e.name),[].concat((0,_e.Z)(e.requires||[]),(0,_e.Z)(e.requiresIfExists||[])).forEach((function(e){if(!i.has(e)){var r=t.get(e);r&&n(r)}})),r.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){i.has(e.name)||n(e)})),r}function Ye(e){var t;return function(){return t||(t=new Promise((function(i){Promise.resolve().then((function(){t=void 0,i(e())}))}))),t}}var Je={placement:"bottom",modifiers:[],strategy:"absolute"};function $e(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return!t.some((function(e){return!(e&&"function"===typeof e.getBoundingClientRect)}))}function Qe(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.defaultModifiers,i=void 0===t?[]:t,r=e.defaultOptions,n=void 0===r?Je:r;return function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:n,s={placement:"bottom",orderedModifiers:[],options:Object.assign(Object.assign({},Je),n),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},o=[],a=!1,c={state:s,setOptions:function(r){l(),s.options=Object.assign(Object.assign(Object.assign({},n),s.options),r),s.scrollParents={reference:ye(e)?Ae(e):e.contextElement?Ae(e.contextElement):[],popper:Ae(t)};var a=function(e){var t=Xe(e);return Ve.reduce((function(e,i){return e.concat(t.filter((function(e){return e.phase===i})))}),[])}(function(e){var t=e.reduce((function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign(Object.assign(Object.assign({},i),t),{options:Object.assign(Object.assign({},i.options),t.options),data:Object.assign(Object.assign({},i.data),t.data)}):t,e}),{});return Object.keys(t).map((function(e){return t[e]}))}([].concat((0,_e.Z)(i),(0,_e.Z)(s.options.modifiers))));return s.orderedModifiers=a.filter((function(e){return e.enabled})),s.orderedModifiers.forEach((function(e){var t=e.name,i=e.options,r=void 0===i?{}:i,n=e.effect;if("function"===typeof n){var a=n({state:s,name:t,instance:c,options:r}),l=function(){};o.push(a||l)}})),c.update()},forceUpdate:function(){if(!a){var e=s.elements,t=e.reference,i=e.popper;if($e(t,i)){s.rects={reference:Le(t,Te(i),"fixed"===s.options.strategy),popper:Ee(i)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach((function(e){return s.modifiersData[e.name]=Object.assign({},e.data)}));for(var r=0;r<s.orderedModifiers.length;r++)if(!0!==s.reset){var n=s.orderedModifiers[r],o=n.fn,l=n.options,u=void 0===l?{}:l,h=n.name;"function"===typeof o&&(s=o({state:s,options:u,name:h,instance:c})||s)}else s.reset=!1,r=-1}}},update:Ye((function(){return new Promise((function(e){c.forceUpdate(),e(s)}))})),destroy:function(){l(),a=!0}};if(!$e(e,t))return c;function l(){o.forEach((function(e){return e()})),o=[]}return c.setOptions(r).then((function(e){!a&&r.onFirstUpdate&&r.onFirstUpdate(e)})),c}}Qe();var et={passive:!0};var tt={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,i=e.instance,r=e.options,n=r.scroll,s=void 0===n||n,o=r.resize,a=void 0===o||o,c=ge(t.elements.popper),l=[].concat((0,_e.Z)(t.scrollParents.reference),(0,_e.Z)(t.scrollParents.popper));return s&&l.forEach((function(e){e.addEventListener("scroll",i.update,et)})),a&&c.addEventListener("resize",i.update,et),function(){s&&l.forEach((function(e){e.removeEventListener("scroll",i.update,et)})),a&&c.removeEventListener("resize",i.update,et)}},data:{}};function it(e){return e.split("-")[0]}function rt(e){return e.split("-")[1]}function nt(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function st(e){var t,i=e.reference,r=e.element,n=e.placement,s=n?it(n):null,o=n?rt(n):null,a=i.x+i.width/2-r.width/2,c=i.y+i.height/2-r.height/2;switch(s){case Be:t={x:a,y:i.y-r.height};break;case Ie:t={x:a,y:i.y+i.height};break;case Pe:t={x:i.x+i.width,y:c};break;case Fe:t={x:i.x-r.width,y:c};break;default:t={x:i.x,y:i.y}}var l=s?nt(s):null;if(null!=l){var u="y"===l?"height":"width";switch(o){case We:t[l]=Math.floor(t[l])-Math.floor(i[u]/2-r[u]/2);break;case Ue:t[l]=Math.floor(t[l])+Math.ceil(i[u]/2-r[u]/2)}}return t}var ot={name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,i=e.name;t.modifiersData[i]=st({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},at=i(4942),ct={top:"auto",right:"auto",bottom:"auto",left:"auto"};function lt(e){var t,i=e.popper,r=e.popperRect,n=e.placement,s=e.offsets,o=e.position,a=e.gpuAcceleration,c=e.adaptive,l=function(e){var t=e.x,i=e.y,r=window.devicePixelRatio||1;return{x:Math.round(t*r)/r||0,y:Math.round(i*r)/r||0}}(s),u=l.x,h=l.y,f=s.hasOwnProperty("x"),d=s.hasOwnProperty("y"),v=Fe,_=Be,p=window;if(c){var g=Te(i);g===ge(i)&&(g=Se(i)),n===Be&&(_=Ie,h-=g.clientHeight-r.height,h*=a?1:-1),n===Fe&&(v=Pe,u-=g.clientWidth-r.width,u*=a?1:-1)}var m,y=Object.assign({position:o},c&&ct);return a?Object.assign(Object.assign({},y),(m={},(0,at.Z)(m,_,d?"0":""),(0,at.Z)(m,v,f?"0":""),(0,at.Z)(m,"transform",(p.devicePixelRatio||1)<2?"translate(".concat(u,"px, ").concat(h,"px)"):"translate3d(".concat(u,"px, ").concat(h,"px, 0)")),m)):Object.assign(Object.assign({},y),(t={},(0,at.Z)(t,_,d?"".concat(h,"px"):""),(0,at.Z)(t,v,f?"".concat(u,"px"):""),(0,at.Z)(t,"transform",""),t))}var ut={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,i=e.options,r=e.name,n=i.offset,s=void 0===n?[0,0]:n,o=Ze.reduce((function(e,i){return e[i]=function(e,t,i){var r=it(e),n=[Fe,Be].indexOf(r)>=0?-1:1,s="function"===typeof i?i(Object.assign(Object.assign({},t),{placement:e})):i,o=(0,oe.Z)(s,2),a=o[0],c=o[1];return a=a||0,c=(c||0)*n,[Fe,Pe].indexOf(r)>=0?{x:c,y:a}:{x:a,y:c}}(i,t.rects,s),e}),{}),a=o[t.placement],c=a.x,l=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=l),t.modifiersData[r]=o}},ht={left:"right",right:"left",bottom:"top",top:"bottom"};function ft(e){return e.replace(/left|right|bottom|top/g,(function(e){return ht[e]}))}var dt={start:"end",end:"start"};function vt(e){return e.replace(/start|end/g,(function(e){return dt[e]}))}function _t(e,t){var i=Boolean(t.getRootNode&&t.getRootNode().host);if(e.contains(t))return!0;if(i){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function pt(e){return Object.assign(Object.assign({},e),{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function gt(e,t){return t===ze?pt(function(e){var t=ge(e),i=Se(e),r=t.visualViewport,n=i.clientWidth,s=i.clientHeight,o=0,a=0;return r&&(n=r.width,s=r.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(o=r.offsetLeft,a=r.offsetTop)),{width:n,height:s,x:o+we(e),y:a}}(e)):be(t)?function(e){var t=pe(e);return t.top=t.top+e.clientTop,t.left=t.left+e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}(t):pt(function(e){var t=Se(e),i=me(e),r=e.ownerDocument.body,n=Math.max(t.scrollWidth,t.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),s=Math.max(t.scrollHeight,t.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),o=-i.scrollLeft+we(e),a=-i.scrollTop;return"rtl"===ke(r||t).direction&&(o+=Math.max(t.clientWidth,r?r.clientWidth:0)-n),{width:n,height:s,x:o,y:a}}(Se(e)))}function mt(e,t,i){var r="clippingParents"===t?function(e){var t=Ae(Re(e)),i=["absolute","fixed"].indexOf(ke(e).position)>=0&&be(e)?Te(e):e;return ye(i)?t.filter((function(e){return ye(e)&&_t(e,i)&&"body"!==Ce(e)})):[]}(e):[].concat(t),n=[].concat((0,_e.Z)(r),[i]),s=n[0],o=n.reduce((function(t,i){var r=gt(e,i);return t.top=Math.max(r.top,t.top),t.right=Math.min(r.right,t.right),t.bottom=Math.min(r.bottom,t.bottom),t.left=Math.max(r.left,t.left),t}),gt(e,s));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function yt(e){return Object.assign(Object.assign({},{top:0,right:0,bottom:0,left:0}),e)}function bt(e,t){return t.reduce((function(t,i){return t[i]=e,t}),{})}function Ct(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.placement,r=void 0===i?e.placement:i,n=t.boundary,s=void 0===n?je:n,o=t.rootBoundary,a=void 0===o?ze:o,c=t.elementContext,l=void 0===c?qe:c,u=t.altBoundary,h=void 0!==u&&u,f=t.padding,d=void 0===f?0:f,v=yt("number"!==typeof d?d:bt(d,Ne)),_=l===qe?Ge:qe,p=e.elements.reference,g=e.rects.popper,m=e.elements[h?_:l],y=mt(ye(m)?m:m.contextElement||Se(e.elements.popper),s,a),b=pe(p),C=st({reference:b,element:g,strategy:"absolute",placement:r}),S=pt(Object.assign(Object.assign({},g),C)),w=l===qe?S:b,k={top:y.top-w.top+v.top,bottom:w.bottom-y.bottom+v.bottom,left:y.left-w.left+v.left,right:w.right-y.right+v.right},x=e.modifiersData.offset;if(l===qe&&x){var L=x[r];Object.keys(k).forEach((function(e){var t=[Pe,Ie].indexOf(e)>=0?1:-1,i=[Be,Ie].indexOf(e)>=0?"y":"x";k[e]+=L[i]*t}))}return k}var St={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var n=i.mainAxis,s=void 0===n||n,o=i.altAxis,a=void 0===o||o,c=i.fallbackPlacements,l=i.padding,u=i.boundary,h=i.rootBoundary,f=i.altBoundary,d=i.flipVariations,v=void 0===d||d,_=i.allowedAutoPlacements,p=t.options.placement,g=it(p),m=c||(g===p||!v?[ft(p)]:function(e){if(it(e)===He)return[];var t=ft(e);return[vt(e),t,vt(t)]}(p)),y=[p].concat((0,_e.Z)(m)).reduce((function(e,i){return e.concat(it(i)===He?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.placement,r=t.boundary,n=t.rootBoundary,s=t.padding,o=t.flipVariations,a=t.allowedAutoPlacements,c=void 0===a?Ze:a,l=rt(i),u=l?o?Ke:Ke.filter((function(e){return rt(e)===l})):Ne,h=u.filter((function(e){return c.indexOf(e)>=0}));0===h.length&&(h=u);var f=h.reduce((function(t,i){return t[i]=Ct(e,{placement:i,boundary:r,rootBoundary:n,padding:s})[it(i)],t}),{});return Object.keys(f).sort((function(e,t){return f[e]-f[t]}))}(t,{placement:i,boundary:u,rootBoundary:h,padding:l,flipVariations:v,allowedAutoPlacements:_}):i)}),[]),b=t.rects.reference,C=t.rects.popper,S=new Map,w=!0,k=y[0],x=0;x<y.length;x++){var L=y[x],E=it(L),R=rt(L)===We,M=[Be,Ie].indexOf(E)>=0,A=M?"width":"height",D=Ct(t,{placement:L,boundary:u,rootBoundary:h,altBoundary:f,padding:l}),O=M?R?Pe:Fe:R?Ie:Be;b[A]>C[A]&&(O=ft(O));var T=ft(O),B=[];if(s&&B.push(D[E]<=0),a&&B.push(D[O]<=0,D[T]<=0),B.every((function(e){return e}))){k=L,w=!1;break}S.set(L,B)}if(w)for(var I=function(e){var t=y.find((function(t){var i=S.get(t);if(i)return i.slice(0,e).every((function(e){return e}))}));if(t)return k=t,"break"},P=v?3:1;P>0;P--){if("break"===I(P))break}t.placement!==k&&(t.modifiersData[r]._skip=!0,t.placement=k,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function wt(e,t,i){return Math.max(e,Math.min(t,i))}var kt={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,r=e.name,n=i.mainAxis,s=void 0===n||n,o=i.altAxis,a=void 0!==o&&o,c=i.boundary,l=i.rootBoundary,u=i.altBoundary,h=i.padding,f=i.tether,d=void 0===f||f,v=i.tetherOffset,_=void 0===v?0:v,p=Ct(t,{boundary:c,rootBoundary:l,padding:h,altBoundary:u}),g=it(t.placement),m=rt(t.placement),y=!m,b=nt(g),C="x"===b?"y":"x",S=t.modifiersData.popperOffsets,w=t.rects.reference,k=t.rects.popper,x="function"===typeof _?_(Object.assign(Object.assign({},t.rects),{placement:t.placement})):_,L={x:0,y:0};if(S){if(s){var E="y"===b?Be:Fe,R="y"===b?Ie:Pe,M="y"===b?"height":"width",A=S[b],D=S[b]+p[E],O=S[b]-p[R],T=d?-k[M]/2:0,B=m===We?w[M]:k[M],I=m===We?-k[M]:-w[M],P=t.elements.arrow,F=d&&P?Ee(P):{width:0,height:0},H=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},N=H[E],W=H[R],U=wt(0,w[M],F[M]),j=y?w[M]/2-T-U-N-x:B-U-N-x,z=y?-w[M]/2+T+U+W+x:I+U+W+x,q=t.elements.arrow&&Te(t.elements.arrow),G=q?"y"===b?q.clientTop||0:q.clientLeft||0:0,K=t.modifiersData.offset?t.modifiersData.offset[t.placement][b]:0,Z=S[b]+j-K-G,V=S[b]+z-K,X=wt(d?Math.min(D,Z):D,A,d?Math.max(O,V):O);S[b]=X,L[b]=X-A}if(a){var Y="x"===b?Be:Fe,J="x"===b?Ie:Pe,$=S[C],Q=wt($+p[Y],$,$-p[J]);S[C]=Q,L[C]=Q-$}t.modifiersData[r]=L}},requiresIfExists:["offset"]};var xt={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,i=e.state,r=e.name,n=i.elements.arrow,s=i.modifiersData.popperOffsets,o=it(i.placement),a=nt(o),c=[Fe,Pe].indexOf(o)>=0?"height":"width";if(n&&s){var l=i.modifiersData["".concat(r,"#persistent")].padding,u=Ee(n),h="y"===a?Be:Fe,f="y"===a?Ie:Pe,d=i.rects.reference[c]+i.rects.reference[a]-s[a]-i.rects.popper[c],v=s[a]-i.rects.reference[a],_=Te(n),p=_?"y"===a?_.clientHeight||0:_.clientWidth||0:0,g=d/2-v/2,m=l[h],y=p-u[c]-l[f],b=p/2-u[c]/2+g,C=wt(m,b,y),S=a;i.modifiersData[r]=(t={},(0,at.Z)(t,S,C),(0,at.Z)(t,"centerOffset",C-b),t)}},effect:function(e){var t=e.state,i=e.options,r=e.name,n=i.element,s=void 0===n?"[data-popper-arrow]":n,o=i.padding,a=void 0===o?0:o;null!=s&&("string"!==typeof s||(s=t.elements.popper.querySelector(s)))&&_t(t.elements.popper,s)&&(t.elements.arrow=s,t.modifiersData["".concat(r,"#persistent")]={padding:yt("number"!==typeof a?a:bt(a,Ne))})},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Lt(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{x:0,y:0};return{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function Et(e){return[Be,Pe,Ie,Fe].some((function(t){return e[t]>=0}))}var Rt=Qe({defaultModifiers:[tt,ot,{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,i=e.options,r=i.gpuAcceleration,n=void 0===r||r,s=i.adaptive,o=void 0===s||s,a={placement:it(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:n};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign(Object.assign({},t.styles.popper),lt(Object.assign(Object.assign({},a),{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign(Object.assign({},t.styles.arrow),lt(Object.assign(Object.assign({},a),{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1})))),t.attributes.popper=Object.assign(Object.assign({},t.attributes.popper),{"data-popper-placement":t.placement})},data:{}},{name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var i=t.styles[e]||{},r=t.attributes[e]||{},n=t.elements[e];be(n)&&Ce(n)&&(Object.assign(n.style,i),Object.keys(r).forEach((function(e){var t=r[e];!1===t?n.removeAttribute(e):n.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach((function(e){var r=t.elements[e],n=t.attributes[e]||{},s=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce((function(e,t){return e[t]="",e}),{});be(r)&&Ce(r)&&(Object.assign(r.style,s),Object.keys(n).forEach((function(e){r.removeAttribute(e)})))}))}},requires:["computeStyles"]},ut,St,kt,xt,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,i=e.name,r=t.rects.reference,n=t.rects.popper,s=t.modifiersData.preventOverflow,o=Ct(t,{elementContext:"reference"}),a=Ct(t,{altBoundary:!0}),c=Lt(o,r),l=Lt(a,n,s),u=Et(c),h=Et(l);t.modifiersData[i]={referenceClippingOffsets:c,popperEscapeOffsets:l,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign(Object.assign({},t.attributes.popper),{"data-popper-reference-hidden":u,"data-popper-escaped":h})}}]}),Mt=h.Nq?c.useLayoutEffect:c.useEffect,At=function(e){return e.reduce((function(e,t){var i=(0,oe.Z)(t,2),r=i[0],n=i[1];return e[r]=n,e}),{})},Dt=[],Ot=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=c.useRef(null),n={onFirstUpdate:i.onFirstUpdate,placement:i.placement||"bottom",strategy:i.strategy||"absolute",modifiers:i.modifiers||Dt},s=c.useState({styles:{popper:{position:n.strategy,left:"0",top:"0"}},attributes:{}}),o=(0,oe.Z)(s,2),a=o[0],l=o[1],u=c.useMemo((function(){return{name:"updateState",enabled:!0,phase:"write",fn:function(e){var t=e.state,i=Object.keys(t.elements);l({styles:At(i.map((function(e){return[e,t.styles[e]||{}]}))),attributes:At(i.map((function(e){return[e,t.attributes[e]]})))})},requires:["computeStyles"]}}),[]),h=c.useMemo((function(){var e,t,i={onFirstUpdate:n.onFirstUpdate,placement:n.placement,strategy:n.strategy,modifiers:[].concat((0,_e.Z)(n.modifiers),[u,{name:"applyStyles",enabled:!1}])};return e=r.current,t=i,JSON.stringify(e)===JSON.stringify(t)?r.current||i:(r.current=i,i)}),[n.onFirstUpdate,n.placement,n.strategy,n.modifiers,u]),f=c.useRef();return Mt((function(){f&&f.current&&f.current.setOptions(h)}),[h]),Mt((function(){if(null!=e&&null!=t){var r=(i.createPopper||Rt)(e,t,h);return f.current=r,function(){r.destroy(),f.current=null}}}),[e,t,i.createPopper]),{state:f.current?f.current.state:null,styles:a.styles,attributes:a.attributes,update:f.current?f.current.update:null,forceUpdate:f.current?f.current.forceUpdate:null}},Tt=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(){return(0,r.Z)(this,i),t.apply(this,arguments)}return(0,n.Z)(i,[{key:"componentDidMount",value:function(){var e=l.findDOMNode(this);this.props.onFoundRef(e)}},{key:"render",value:function(){return this.props.children||null}}]),i}(c.Component);Tt.displayName="FindRefWrapper";var Bt,It={left:"right",right:"left",bottom:"top",top:"bottom","top-start":"bottom-end","top-end":"bottom-start","bottom-start":"top-end","bottom-end":"top-start","left-start":"right-end","left-end":"right-start","right-start":"left-end","right-end":"left-start"},Pt=function(e){return"opacity ".concat(e,"ms cubic-bezier(.54, 1.5, .38, 1.11)")},Ft=function(e){var t=e.trigger,i=e.popper,r=e.popperMatchesTriggerWidth,n=void 0===r||r,s=e.direction,o=void 0===s?"down":s,a=e.position,u=void 0===a?"left":a,h=e.placement,d=e.appendTo,v=void 0===d?function(){return document.body}:d,_=e.zIndex,p=void 0===_?9999:_,g=e.isVisible,m=void 0===g||g,y=e.positionModifiers,b=e.distance,C=void 0===b?0:b,S=e.onMouseEnter,w=e.onMouseLeave,k=e.onFocus,x=e.onBlur,L=e.onDocumentClick,E=e.onTriggerClick,R=e.onTriggerEnter,M=e.onPopperClick,A=e.onPopperMouseEnter,D=e.onPopperMouseLeave,O=e.onDocumentKeyDown,T=e.enableFlip,B=void 0===T||T,I=e.flipBehavior,P=void 0===I?"flip":I,F=e.reference,H=e.removeFindDomNode,N=void 0!==H&&H,W=e.popperRef,U=c.useState(null),j=(0,oe.Z)(U,2),z=j[0],q=j[1],G=c.useState(null),K=(0,oe.Z)(G,2),Z=K[0],V=K[1],X=c.useState(null),Y=(0,oe.Z)(X,2),J=Y[0],$=Y[1],Q=c.useState(!1),ee=(0,oe.Z)(Q,2),te=ee[0],ie=ee[1],re=Z||z,ne=c.useCallback((function(e){return L(e,re,J)}),[m,z,Z,J,L]);c.useEffect((function(){ie(!0)}),[]),c.useEffect((function(){F&&(F.current?V(F.current):"function"===typeof F&&V(F()))}),[F]),c.useEffect((function(){W&&(W.current?$(W.current):"function"===typeof W&&$(W()))}),[m,W]);var se=function(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];e&&t&&t.addEventListener(i,e,{capture:r})},ae=function(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];e&&t&&t.removeEventListener(i,e,{capture:r})};c.useEffect((function(){se(S,re,"mouseenter"),se(w,re,"mouseleave"),se(k,re,"focus"),se(x,re,"blur"),se(E,re,"click"),se(R,re,"keydown"),se(M,J,"click"),se(A,J,"mouseenter"),se(D,J,"mouseleave"),L&&se(ne,document,"click",!0),se(O,document,"keydown",!0);var e=new MutationObserver((function(){_e&&_e()}));return J&&e.observe(J,{attributes:!0,childList:!0,subtree:!0}),function(){ae(S,re,"mouseenter"),ae(w,re,"mouseleave"),ae(k,re,"focus"),ae(x,re,"blur"),ae(E,re,"click"),ae(R,re,"keydown"),ae(M,J,"click"),ae(A,J,"mouseenter"),ae(D,J,"mouseleave"),L&&ae(ne,document,"click",!0),ae(O,document,"keydown",!0),e.disconnect()}}),[z,J,S,w,k,x,E,R,M,A,D,L,O,Z]);var ce=function(){if(h)return h;var e="up"===o?"top":"bottom";return"center"!==u&&(e="".concat(e,"-").concat("right"===u?"end":"start")),e},le=c.useMemo(ce,[o,u,h]),ue=c.useMemo((function(){return function(e){return e.replace(/left|right|bottom|top|top-start|top-end|bottom-start|bottom-end|right-start|right-end|left-start|left-end/g,(function(e){return It[e]}))}(ce())}),[o,u,h]),he=c.useMemo((function(){return{name:"sameWidth",enabled:n,phase:"beforeWrite",requires:["computeStyles"],fn:function(e){var t=e.state;t.styles.popper.width="".concat(t.rects.reference.width,"px")},effect:function(e){var t=e.state;return t.elements.popper.style.width="".concat(t.elements.reference.offsetWidth,"px"),function(){}}}}),[n]),fe=Ot(re,J,{placement:le,modifiers:[{name:"offset",options:{offset:[0,C]}},{name:"preventOverflow",enabled:!1},{name:"hide",enabled:!0},{name:"flip",enabled:le.startsWith("auto")||B,options:{fallbackPlacements:"flip"===P?[ue]:P}},he]}),de=fe.styles,ve=fe.attributes,_e=fe.update,pe=fe.forceUpdate;c.useEffect((function(){pe&&pe()}),[i]);var ge,me=Object.assign({className:(0,f.i)(i.props&&i.props.className,y&&function(){if(ve&&ve.popper&&ve.popper["data-popper-placement"]){var e=ve.popper["data-popper-placement"];return y[e]}return y.top}()),style:Object.assign(Object.assign(Object.assign({},i.props&&i.props.style||{}),de.popper),{zIndex:p})},ve.popper),ye=c.cloneElement(i,me);return ge=N?c.createElement("div",{style:{display:"contents"},ref:function(e){return $(null===e||void 0===e?void 0:e.firstElementChild)}},ye):W?ye:c.createElement(Tt,{onFoundRef:function(e){return $(e)}},ye),c.createElement(c.Fragment,null,!F&&t&&c.isValidElement(t)&&!N&&c.createElement(Tt,{onFoundRef:function(e){return q(e)}},t),!F&&t&&c.isValidElement(t)&&N&&c.createElement("div",{style:{display:"contents"},ref:function(e){return q(null===e||void 0===e?void 0:e.firstElementChild)}},t),te&&m&&l.createPortal(ge,"function"===typeof v?v():v))};Ft.displayName="Popper",function(e){e.auto="auto",e.top="top",e.bottom="bottom",e.left="left",e.right="right",e.topStart="top-start",e.topEnd="top-end",e.bottomStart="bottom-start",e.bottomEnd="bottom-end",e.leftStart="left-start",e.leftEnd="left-end",e.rightStart="right-start",e.rightEnd="right-end"}(Bt||(Bt={}));var Ht=1,Nt=function(e){var t=e.content,i=e.position,r=void 0===i?"top":i,n=e.trigger,s=void 0===n?"mouseenter focus":n,o=e.isVisible,l=void 0!==o&&o,h=e.isContentLeftAligned,d=void 0!==h&&h,v=e.enableFlip,_=void 0===v||v,p=e.className,g=void 0===p?"":p,m=e.entryDelay,y=void 0===m?300:m,b=e.exitDelay,C=void 0===b?300:b,S=e.appendTo,w=void 0===S?function(){return document.body}:S,k=e.zIndex,x=void 0===k?9999:k,L=e.maxWidth,E=void 0===L?ve.value:L,R=e.distance,M=void 0===R?15:R,A=e.aria,D=void 0===A?"describedby":A,O=e.flipBehavior,T=void 0===O?["top","right","bottom","left","top","right","bottom"]:O,B=e.id,I=void 0===B?"pf-tooltip-".concat(Ht++):B,P=e.children,F=e.animationDuration,H=void 0===F?300:F,N=e.reference,W=e["aria-live"],U=void 0===W?N?"polite":"off":W,j=(e.boundary,e.isAppLauncher,e.tippyProps,e.removeFindDomNode),z=void 0!==j&&j,q=e.onTooltipHidden,G=void 0===q?function(){}:q,K=(0,a._T)(e,["content","position","trigger","isVisible","isContentLeftAligned","enableFlip","className","entryDelay","exitDelay","appendTo","zIndex","maxWidth","distance","aria","flipBehavior","id","children","animationDuration","reference","aria-live","boundary","isAppLauncher","tippyProps","removeFindDomNode","onTooltipHidden"]);var Z=s.includes("mouseenter"),V=s.includes("focus"),X=s.includes("click"),Y="manual"===s,J=c.useState(!1),$=(0,oe.Z)(J,2),Q=$[0],ee=$[1],te=c.useState(0),ie=(0,oe.Z)(te,2),re=ie[0],ne=ie[1],se=c.useRef(null),ae=c.useRef(null),ue=c.useRef(null),he=c.useRef(),_e=function(e){e.forEach((function(e){e.current&&clearTimeout(e.current)}))};c.useEffect((function(){return function(){_e([se,ue,ae])}}),[]);c.useEffect((function(){l?pe():ge()}),[l]),c.useEffect((function(){he.current<C&&(_e([se,ue]),ue.current=setTimeout((function(){ne(0),se.current=setTimeout((function(){ee(!1),G()}),H)}),C)),he.current=C}),[C]);var pe=function(){_e([se,ue]),ae.current=setTimeout((function(){ee(!0),ne(1)}),y)},ge=function(){_e([ae]),ue.current=setTimeout((function(){ne(0),se.current=setTimeout((function(){ee(!1),G()}),H)}),C)},me={top:ce.top,bottom:ce.bottom,left:ce.left,right:ce.right,"top-start":ce.topLeft,"top-end":ce.topRight,"bottom-start":ce.bottomLeft,"bottom-end":ce.bottomRight,"left-start":ce.leftTop,"left-end":ce.leftBottom,"right-start":ce.rightTop,"right-end":ce.rightBottom},ye=E!==ve.value,be=c.createElement("div",Object.assign({"aria-live":U,className:(0,f.i)(le,g),role:"tooltip",id:I,style:{maxWidth:ye?E:null,opacity:re,transition:Pt(H)}},K),c.createElement(de,null),c.createElement(fe,{isLeftAligned:d},t));return c.createElement(Ft,{trigger:"none"!==D&&Q?"describedby"===D&&P&&P.props&&!P.props["aria-describedby"]?c.cloneElement(P,{"aria-describedby":I}):"labelledby"===D&&P.props&&!P.props["aria-labelledby"]?c.cloneElement(P,{"aria-labelledby":I}):P:P,reference:N,popper:be,popperMatchesTriggerWidth:!1,appendTo:w,isVisible:Q,positionModifiers:me,distance:M,placement:r,onMouseEnter:Z&&pe,onMouseLeave:Z&&ge,onPopperMouseEnter:Z&&pe,onPopperMouseLeave:Z&&ge,onFocus:V&&pe,onBlur:V&&ge,onDocumentClick:X&&function(e,t){Q?ge():e.target===t&&pe()},onDocumentKeyDown:Y?null:function(e){Y||e.key===u.yu.Escape&&Q&&ge()},onTriggerEnter:Y?null:function(e){e.key===u.yu.Enter&&(Q?ge():pe())},enableFlip:_,zIndex:x,flipBehavior:T,removeFindDomNode:z})};Nt.displayName="Tooltip";var Wt=(0,$.IU)({name:"CheckCircleIcon",height:512,width:512,svgPath:"M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z",yOffset:0,xOffset:0}),Ut=(0,$.IU)({name:"ExclamationCircleIcon",height:512,width:512,svgPath:"M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z",yOffset:0,xOffset:0}),jt=(0,$.IU)({name:"ExclamationTriangleIcon",height:512,width:576,svgPath:"M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z",yOffset:0,xOffset:0}),zt=(0,$.IU)({name:"InfoCircleIcon",height:512,width:512,svgPath:"M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z",yOffset:0,xOffset:0}),qt=(0,$.IU)({name:"BellIcon",height:1024,width:896,svgPath:"M448,0 C465.333333,0 480.333333,6.33333333 493,19 C505.666667,31.6666667 512,46.6666667 512,64 L512,106 L514.23,106.45 C587.89,121.39 648.48,157.24 696,214 C744,271.333333 768,338.666667 768,416 C768,500 780,568.666667 804,622 C818.666667,652.666667 841.333333,684 872,716 C873.773676,718.829136 875.780658,721.505113 878,724 C890,737.333333 896,752.333333 896,769 C896,785.666667 890,800.333333 878,813 C866,825.666667 850.666667,832 832,832 L63.3,832 C44.9533333,831.84 29.8533333,825.506667 18,813 C6,800.333333 0,785.666667 0,769 C0,752.333333 6,737.333333 18,724 L24,716 L25.06,714.9 C55.1933333,683.28 77.5066667,652.313333 92,622 C116,568.666667 128,500 128,416 C128,338.666667 152,271.333333 200,214 C248,156.666667 309.333333,120.666667 384,106 L384,63.31 C384.166667,46.27 390.5,31.5 403,19 C415.666667,6.33333333 430.666667,0 448,0 Z M576,896 L576,897.08 C575.74,932.6 563.073333,962.573333 538,987 C512.666667,1011.66667 482.666667,1024 448,1024 C413.333333,1024 383.333333,1011.66667 358,987 C332.666667,962.333333 320,932 320,896 L576,896 Z",yOffset:0,xOffset:0}),Gt=function(e){return["success","danger","warning","info","default"].includes(e)},Kt=function(e){var t=e.className,i=void 0===t?"":t,r=e.id,n=e.title,s=e.titleIconVariant,o=e.titleLabel,l=void 0===o?"":o,u=(0,a._T)(e,["className","id","title","titleIconVariant","titleLabel"]),d=c.useState(!1),v=(0,oe.Z)(d,2),_=v[0],p=v[1],g=c.useRef(null),m=l||(Gt(s)?"".concat((0,h.kC)(s)," alert:"):l),y={success:c.createElement(Wt,null),danger:c.createElement(Ut,null),warning:c.createElement(jt,null),info:c.createElement(zt,null),default:c.createElement(qt,null)},b=!Gt(s)&&s;Mt((function(){p(g.current&&g.current.offsetWidth<g.current.scrollWidth)}),[]);var C=c.createElement("h1",Object.assign({id:r,ref:g,className:(0,f.i)(K.modalBoxTitle,s&&K.modifiers.icon,i)},u),s&&c.createElement("span",{className:(0,f.i)(K.modalBoxTitleIcon)},Gt(s)?y[s]:c.createElement(b,null)),m&&c.createElement("span",{className:(0,f.i)(ae)},m),c.createElement("span",{className:(0,f.i)(K.modalBoxTitleText)},n));return _?c.createElement(Nt,{content:n},C):C};Kt.displayName="ModalBoxTitle";var Zt,Vt=function e(t){var i=t.children,r=t.className,n=void 0===r?"":r,s=t.isOpen,o=void 0!==s&&s,l=t.header,u=void 0===l?null:l,h=t.help,d=void 0===h?null:h,v=t.description,_=void 0===v?null:v,p=t.title,g=void 0===p?"":p,m=t.titleIconVariant,y=void 0===m?null:m,b=t.titleLabel,C=void 0===b?"":b,S=t["aria-label"],w=void 0===S?"":S,k=t["aria-describedby"],x=t["aria-labelledby"],L=t.bodyAriaLabel,E=t.bodyAriaRole,R=t.showClose,M=void 0===R||R,A=t.footer,D=void 0===A?null:A,O=t.actions,T=void 0===O?[]:O,B=t.onClose,I=void 0===B?function(){}:B,P=t.variant,F=void 0===P?"default":P,H=t.position,N=t.positionOffset,W=t.width,U=void 0===W?-1:W,j=t.boxId,z=t.labelId,q=t.descriptorId,J=t.disableFocusTrap,$=void 0!==J&&J,Q=t.hasNoBodyWrapper,te=void 0!==Q&&Q,oe=t.ouiaId,ae=t.ouiaSafe,ce=void 0===ae||ae,le=(0,a._T)(t,["children","className","isOpen","header","help","description","title","titleIconVariant","titleLabel","aria-label","aria-describedby","aria-labelledby","bodyAriaLabel","bodyAriaRole","showClose","footer","actions","onClose","variant","position","positionOffset","width","boxId","labelId","descriptorId","disableFocusTrap","hasNoBodyWrapper","ouiaId","ouiaSafe"]);if(!o)return null;var ue=u?c.createElement(se,{help:d},u):g&&c.createElement(se,{help:d},c.createElement(Kt,{title:g,titleIconVariant:y,titleLabel:C,id:z}),_&&c.createElement(ne,{id:q},_)),he=D?c.createElement(re,null,D):T.length>0&&c.createElement(re,null,T),fe=L?"region":void 0,de=te?i:c.createElement(Y,Object.assign({"aria-label":L,role:E||fe},le,!_&&!k&&{id:q}),i),ve=-1===U?{}:{width:U},_e=c.createElement(ie,Object.assign({id:j,style:ve,className:(0,f.i)(n,Gt(y)&&K.modifiers[y]),variant:F,position:H,positionOffset:N,"aria-label":w,"aria-labelledby":function(){if(null===x)return null;var e=[];return""!==(w&&j)&&e.push(w&&j),x&&e.push(x),g&&e.push(z),e.join(" ")}(),"aria-describedby":k||(te?null:q)},(0,V.dp)(e.displayName,oe,ce)),M&&c.createElement(ee,{onClose:I,ouiaId:oe}),ue,de,he);return c.createElement(X,null,c.createElement(G,{active:!$,focusTrapOptions:{clickOutsideDeactivates:!0,tabbableOptions:{displayCheck:"none"}},className:(0,f.i)(Z)},_e))};Vt.displayName="ModalContent",function(e){e.small="small",e.medium="medium",e.large="large",e.default="default"}(Zt||(Zt={}));var Xt=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(e){var n;(0,r.Z)(this,i),(n=t.call(this,e)).boxId="",n.labelId="",n.descriptorId="",n.handleEscKeyClick=function(e){var t,i,r=n.props.onEscapePress;e.key===u.yu.Escape&&n.props.isOpen&&(r?r(e):null===(i=(t=n.props).onClose)||void 0===i||i.call(t))},n.getElement=function(e){return"function"===typeof e?e():e||document.body},n.toggleSiblingsFromScreenReaders=function(e){for(var t=n.props.appendTo,i=n.getElement(t).children,r=0,s=Array.from(i);r<s.length;r++){var o=s[r];o!==n.state.container&&(e?o.setAttribute("aria-hidden",""+e):o.removeAttribute("aria-hidden"))}},n.isEmpty=function(e){return null===e||void 0===e||""===e};var s=i.currentId++,o=s+1,a=s+2;return n.boxId=e.id||"pf-modal-part-".concat(s),n.labelId="pf-modal-part-".concat(o),n.descriptorId="pf-modal-part-".concat(a),n.state={container:void 0,ouiaStateId:(0,V.ql)(i.displayName,e.variant)},n}return(0,n.Z)(i,[{key:"componentDidMount",value:function(){var e=this.props,t=e.appendTo,i=e.title,r=e["aria-label"],n=e["aria-labelledby"],s=e.hasNoBodyWrapper,o=e.header,a=this.getElement(t),c=document.createElement("div");this.setState({container:c}),a.appendChild(c),a.addEventListener("keydown",this.handleEscKeyClick,!1),this.props.isOpen?a.classList.add((0,f.i)(v)):a.classList.remove((0,f.i)(v)),this.isEmpty(i)&&this.isEmpty(r)&&this.isEmpty(n)&&console.error("Modal: Specify at least one of: title, aria-label, aria-labelledby."),this.isEmpty(r)&&this.isEmpty(n)&&(s||o)&&console.error("Modal: When using hasNoBodyWrapper or setting a custom header, ensure you assign an accessible name to the the modal container with aria-label or aria-labelledby.")}},{key:"componentDidUpdate",value:function(){var e=this.props.appendTo,t=this.getElement(e);this.props.isOpen?(t.classList.add((0,f.i)(v)),this.toggleSiblingsFromScreenReaders(!0)):(t.classList.remove((0,f.i)(v)),this.toggleSiblingsFromScreenReaders(!1))}},{key:"componentWillUnmount",value:function(){var e=this.props.appendTo,t=this.getElement(e);this.state.container&&t.removeChild(this.state.container),t.removeEventListener("keydown",this.handleEscKeyClick,!1),t.classList.remove((0,f.i)(v))}},{key:"render",value:function(){var e=this.props,t=(e.appendTo,e.onEscapePress,e["aria-labelledby"]),i=e["aria-label"],r=e["aria-describedby"],n=e.bodyAriaLabel,s=e.bodyAriaRole,o=e.title,u=e.titleIconVariant,f=e.titleLabel,d=e.ouiaId,v=e.ouiaSafe,_=(0,a._T)(e,["appendTo","onEscapePress","aria-labelledby","aria-label","aria-describedby","bodyAriaLabel","bodyAriaRole","title","titleIconVariant","titleLabel","ouiaId","ouiaSafe"]),p=this.state.container;return h.Nq&&p?l.createPortal(c.createElement(Vt,Object.assign({},_,{boxId:this.boxId,labelId:this.labelId,descriptorId:this.descriptorId,title:o,titleIconVariant:u,titleLabel:f,"aria-label":i,"aria-describedby":r,"aria-labelledby":t,bodyAriaLabel:n,bodyAriaRole:s,ouiaId:void 0!==d?d:this.state.ouiaStateId,ouiaSafe:v})),p):null}}]),i}(c.Component);Xt.displayName="Modal",Xt.currentId=0,Xt.defaultProps={className:"",isOpen:!1,title:"",titleIconVariant:null,titleLabel:"","aria-label":"",showClose:!0,"aria-describedby":"","aria-labelledby":"",id:void 0,actions:[],onClose:function(){},variant:"default",hasNoBodyWrapper:!1,appendTo:function(){return document.body},ouiaSafe:!0}},146:function(e,t,i){"use strict";i.d(t,{Y:function(){return B}});var r,n,s=i(9388),o=i(2791),a={status:"pf-m-status"},c="pf-c-number-input",l="pf-c-number-input__icon",u="pf-c-number-input__unit",h=i(1994),f=i(9720),d=(0,f.IU)({name:"MinusIcon",height:512,width:448,svgPath:"M416 208H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z",yOffset:0,xOffset:0}),v=(0,f.IU)({name:"PlusIcon",height:512,width:448,svgPath:"M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z",yOffset:0,xOffset:0}),_="pf-c-input-group",p=i(9061),g=i(5671),m=i(3144),y=i(136),b=i(7277),C=i(4226),S={name:"--pf-c-form-control--textarea--Height",value:"auto",var:"var(--pf-c-form-control--textarea--Height)"},w=i(1677),k=i(8132);!function(e){e.horizontal="horizontal",e.vertical="vertical",e.both="both"}(r||(r={})),function(e){e.default="default",e.plain="plain"}(n||(n={}));var x=function(e){(0,y.Z)(i,e);var t=(0,b.Z)(i);function i(e){var r;return(0,g.Z)(this,i),(r=t.call(this,e)).inputRef=o.createRef(),r.setAutoHeight=function(e){e.style.setProperty(S.name,"inherit");var t=window.getComputedStyle(e),i=parseInt(t.getPropertyValue("border-top-width"))+parseInt(t.getPropertyValue("padding-top"))+e.scrollHeight+parseInt(t.getPropertyValue("padding-bottom"))+parseInt(t.getPropertyValue("border-bottom-width"));e.style.setProperty(S.name,"".concat(i,"px"))},r.handleChange=function(e){var t=e.currentTarget;r.props.autoResize&&w.Nq&&r.setAutoHeight(t),r.props.onChange&&r.props.onChange(t.value,e)},e.id||e["aria-label"]||console.error("TextArea: TextArea requires either an id or aria-label to be specified"),r}return(0,m.Z)(i,[{key:"componentDidMount",value:function(){var e=this.props.innerRef||this.inputRef;if(this.props.autoResize&&w.Nq){var t=e.current;this.setAutoHeight(t)}}},{key:"render",value:function(){var e=this.props,t=e.className,i=e.value,n=e.validated,a=e.isRequired,c=e.isDisabled,l=e.isIconSprite,u=e.isReadOnly,f=e.readOnlyVariant,d=e.resizeOrientation,v=e.innerRef,_=e.disabled,p=(e.autoResize,e.onChange,(0,s._T)(e,["className","value","validated","isRequired","isDisabled","isIconSprite","isReadOnly","readOnlyVariant","resizeOrientation","innerRef","disabled","autoResize","onChange"])),g="resize".concat((0,w.kC)(d));return o.createElement("textarea",Object.assign({className:(0,h.i)(C.Z.formControl,l&&C.Z.modifiers.iconSprite,"plain"===f&&C.Z.modifiers.plain,t,d!==r.both&&C.Z.modifiers[g],n===k.LD.success&&C.Z.modifiers.success,n===k.LD.warning&&C.Z.modifiers.warning),onChange:this.handleChange},"string"!==typeof this.props.defaultValue&&{value:i},{"aria-invalid":n===k.LD.error,required:a,disabled:c||_,readOnly:!!f||u,ref:v||this.inputRef},p))}}]),i}(o.Component);x.displayName="TextArea",x.defaultProps={innerRef:o.createRef(),className:"",isRequired:!1,isDisabled:!1,isIconSprite:!1,validated:"default",resizeOrientation:"both","aria-label":null};var L=o.forwardRef((function(e,t){return o.createElement(x,Object.assign({},e,{innerRef:t}))}));L.displayName="TextArea";var E,R,M=i(4134);!function(e){e.text="text",e.date="date",e.datetimeLocal="datetime-local",e.email="email",e.month="month",e.number="number",e.password="password",e.search="search",e.tel="tel",e.time="time",e.url="url"}(E||(E={})),function(e){e.default="default",e.plain="plain"}(R||(R={}));var A=function(e){(0,y.Z)(i,e);var t=(0,b.Z)(i);function i(e){var r;return(0,g.Z)(this,i),(r=t.call(this,e)).inputRef=o.createRef(),r.observer=function(){},r.handleChange=function(e){r.props.onChange&&r.props.onChange(e.currentTarget.value,e)},r.handleResize=function(){var e=r.props.innerRef||r.inputRef;e&&e.current&&(0,w.fi)(e.current,String(r.props.value))},r.restoreText=function(){var e=r.props.innerRef||r.inputRef;e.current.value=String(r.props.value),e.current.scrollLeft=e.current.scrollWidth},r.onFocus=function(e){var t=r.props,i=t.isLeftTruncated,n=t.onFocus;i&&r.restoreText(),n&&n(e)},r.onBlur=function(e){var t=r.props,i=t.isLeftTruncated,n=t.onBlur;i&&r.handleResize(),n&&n(e)},r.sanitizeInputValue=function(e){return"string"===typeof e?e.replace(/\n/g," "):e},e.id||e["aria-label"]||e["aria-labelledby"]||console.error("Text input:","Text input requires either an id or aria-label to be specified"),r.state={ouiaStateId:(0,M.ql)(i.displayName)},r}return(0,m.Z)(i,[{key:"componentDidMount",value:function(){if(this.props.isLeftTruncated){var e=this.props.innerRef||this.inputRef;this.observer=function(e,t){var i,r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(w.Nq){var n=window.ResizeObserver;if(e&&n){var s=new n((function(e){r?window.requestAnimationFrame((function(){Array.isArray(e)&&e.length>0&&t()})):Array.isArray(e)&&e.length>0&&t()}));s.observe(e),i=function(){return s.unobserve(e)}}else window.addEventListener("resize",t),i=function(){return window.removeEventListener("resize",t)}}return function(){i&&i()}}(e.current,this.handleResize),this.handleResize()}}},{key:"componentWillUnmount",value:function(){this.props.isLeftTruncated&&this.observer()}},{key:"render",value:function(){var e=this.props,t=e.innerRef,i=e.className,r=e.type,n=e.value,a=e.validated,c=(e.onChange,e.onFocus,e.onBlur,e.isLeftTruncated,e.isReadOnly),l=e.readOnly,u=e.readOnlyVariant,f=e.isRequired,d=e.isDisabled,v=e.isIconSprite,_=e.iconVariant,p=e.customIconUrl,g=e.customIconDimensions,m=e.ouiaId,y=e.ouiaSafe,b=(0,s._T)(e,["innerRef","className","type","value","validated","onChange","onFocus","onBlur","isLeftTruncated","isReadOnly","readOnly","readOnlyVariant","isRequired","isDisabled","isIconSprite","iconVariant","customIconUrl","customIconDimensions","ouiaId","ouiaSafe"]),S={};return p&&(S.backgroundImage="url('".concat(p,"')")),g&&(S.backgroundSize=g),o.createElement("input",Object.assign({},b,{onFocus:this.onFocus,onBlur:this.onBlur,className:(0,h.i)(C.Z.formControl,v&&C.Z.modifiers.iconSprite,"plain"===u&&C.Z.modifiers.plain,a===k.LD.success&&C.Z.modifiers.success,a===k.LD.warning&&C.Z.modifiers.warning,(_&&"search"!==_||p)&&C.Z.modifiers.icon,_&&C.Z.modifiers[_],i),onChange:this.handleChange,type:r,value:this.sanitizeInputValue(n),"aria-invalid":b["aria-invalid"]?b["aria-invalid"]:a===k.LD.error,required:f,disabled:d,readOnly:!!u||c||l,ref:t||this.inputRef},(p||g)&&{style:S},(0,M.dp)(D.displayName,void 0!==m?m:this.state.ouiaStateId,y)))}}]),i}(o.Component);A.displayName="TextInputBase",A.defaultProps={"aria-label":null,className:"",isRequired:!1,validated:"default",isDisabled:!1,isReadOnly:!1,isIconSprite:!1,type:E.text,isLeftTruncated:!1,onChange:function(){},ouiaSafe:!0};var D=o.forwardRef((function(e,t){return o.createElement(A,Object.assign({},e,{innerRef:t}))}));D.displayName="TextInput";var O=function(e){var t=e.className,i=void 0===t?"":t,r=e.children,n=e.innerRef,a=(0,s._T)(e,["className","children","innerRef"]),c=[p.i,L,D].map((function(e){return e.displayName})),l=o.Children.toArray(r).find((function(e){return!c.includes(e.type.displayName)&&e.props.id})),u=o.useRef(null),f=n||u;return o.createElement("div",Object.assign({ref:f,className:(0,h.i)(_,i)},a),l?o.Children.map(r,(function(e){return!c.includes(e.type.displayName)||e.props["aria-describedby"]?e:o.cloneElement(e,{"aria-describedby":""===e.props["aria-describedby"]?void 0:l.props.id})})):r)};O.displayName="InputGroup";var T=i(6396),B=function(e){var t=e.value,i=void 0===t?0:t,r=e.className,n=e.widthChars,f=e.isDisabled,_=void 0!==f&&f,p=e.validated,g=void 0===p?k.LD.default:p,m=e.onMinus,y=void 0===m?function(){}:m,b=e.onChange,C=e.onBlur,S=e.onPlus,w=void 0===S?function(){}:S,x=e.unit,L=e.unitPosition,E=void 0===L?"after":L,R=e.min,M=e.max,A=e.inputName,B=e.inputAriaLabel,I=void 0===B?"Input":B,P=e.minusBtnAriaLabel,F=void 0===P?"Minus":P,H=e.plusBtnAriaLabel,N=void 0===H?"Plus":H,W=e.inputProps,U=e.minusBtnProps,j=e.plusBtnProps,z=e.allowEmptyInput,q=void 0!==z&&z,G=(0,s._T)(e,["value","className","widthChars","isDisabled","validated","onMinus","onChange","onBlur","onPlus","unit","unitPosition","min","max","inputName","inputAriaLabel","minusBtnAriaLabel","plusBtnAriaLabel","inputProps","minusBtnProps","plusBtnProps","allowEmptyInput"]);q||(i=i||0);var K,Z=o.createElement("div",{className:(0,h.i)(u)},x),V=W&&W.onKeyDown?W.onKeyDown:(K={inputName:A,onMinus:y,onPlus:w},function(e){k.yu.ArrowUp===e.key&&K.onPlus&&(e.preventDefault(),K.onPlus(null,K.inputName)),k.yu.ArrowDown===e.key&&K.onMinus&&(e.preventDefault(),K.onMinus(null,K.inputName))});return o.createElement("div",Object.assign({className:(0,h.i)(c,"default"!==g&&a.status,r)},n&&{style:Object.assign({"--pf-c-number-input--c-form-control--width-chars":n},G.style)},G),x&&"before"===E&&Z,o.createElement(O,null,o.createElement(T.zx,Object.assign({variant:"control","aria-label":F,isDisabled:_||i<=R,onClick:function(e){return y(e,A)}},U),o.createElement("span",{className:(0,h.i)(l)},o.createElement(d,{"aria-hidden":"true"}))),o.createElement(D,Object.assign({},W,{type:"number",value:i,name:A,"aria-label":I},_&&{isDisabled:_},b&&{onChange:function(e,t){return b(t)}},{onBlur:function(e){e.target.value=Number(e.target.value).toString(),b&&b(e),C&&C(e)}},!b&&{isReadOnly:!0},{onKeyDown:V,validated:g})),o.createElement(T.zx,Object.assign({variant:"control","aria-label":N,isDisabled:_||i>=M,onClick:function(e){return w(e,A)}},j),o.createElement("span",{className:(0,h.i)(l)},o.createElement(v,{"aria-hidden":"true"})))),x&&"after"===E&&Z)};B.displayName="NumberInput"},7149:function(e,t,i){"use strict";i.d(t,{z1:function(){return o}});var r=i(2791),n=i(1677),s={isManagedSidebar:!1,isNavOpen:!1,onNavToggle:function(){return null},width:null,height:null,getBreakpoint:n.iu,getVerticalBreakpoint:n.xb},o=r.createContext(s);o.Provider,o.Consumer},2136:function(e,t,i){"use strict";i.d(t,{o:function(){return C}});var r=i(5671),n=i(3144),s=i(136),o=i(7277),a=i(9388),c=i(2791),l=i(3634),u=0,h=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(){var e;return(0,r.Z)(this,i),(e=t.apply(this,arguments)).id="".concat(e.props.prefix).concat(u++),e}return(0,n.Z)(i,[{key:"render",value:function(){return this.props.children(this.id)}}]),i}(c.Component);h.displayName="GenerateId",h.defaultProps={prefix:"pf-random-id-"};var f=i(1994),d=i(7780),v=i(1677),_=i(7695),p=i(6396),g=i(8955),m=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(){return(0,r.Z)(this,i),t.apply(this,arguments)}return(0,n.Z)(i,[{key:"render",value:function(){var e=this.props,t=e.className,i=e.isExpanded,r=e.chipGroupContentRef,n=e.clearAllFilters,s=e.showClearFiltersButton,o=e.clearFiltersButtonText,u=e.collapseListedFiltersBreakpoint,h=e.numberOfFilters,m=e.numberOfFiltersText,y=e.customChipGroupContent,b=(0,a._T)(e,["className","isExpanded","chipGroupContentRef","clearAllFilters","showClearFiltersButton","clearFiltersButtonText","collapseListedFiltersBreakpoint","numberOfFilters","numberOfFiltersText","customChipGroupContent"]),C=!1;return"all"===u?C=!0:v.Nq&&(C=(v.Nq?window.innerWidth:1200)<d.Oc[u]),c.createElement("div",Object.assign({className:(0,f.i)(l.Z.toolbarContent,(0===h||i)&&l.Z.modifiers.hidden,t)},(0===h||i)&&{hidden:!0},{ref:r},b),c.createElement(g.k,Object.assign({className:(0,f.i)(C&&l.Z.modifiers.hidden)},C&&{hidden:!0},C&&{"aria-hidden":!0})),C&&h>0&&!i&&c.createElement(g.k,null,c.createElement(_.E,null,m(h))),s&&!i&&!y&&c.createElement(_.E,null,c.createElement(p.zx,{variant:"link",onClick:function(){n()},isInline:!0},o)),y&&y)}}]),i}(c.Component);m.displayName="ToolbarChipGroupContent",m.defaultProps={clearFiltersButtonText:"Clear all filters",collapseListedFiltersBreakpoint:"lg",numberOfFiltersText:function(e){return"".concat(e," filters applied")}};var y=i(4134),b=i(7149),C=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(){var e;return(0,r.Z)(this,i),(e=t.apply(this,arguments)).chipGroupContentRef=c.createRef(),e.staticFilterInfo={},e.state={isManagedToggleExpanded:!1,filterInfo:{},windowWidth:v.Nq?window.innerWidth:1200,ouiaStateId:(0,y.ql)(i.displayName)},e.isToggleManaged=function(){return!(e.props.isExpanded||e.props.toggleIsExpanded)},e.toggleIsExpanded=function(){e.setState((function(e){return{isManagedToggleExpanded:!e.isManagedToggleExpanded}}))},e.closeExpandableContent=function(t){t.target.innerWidth!==e.state.windowWidth&&e.setState((function(){return{isManagedToggleExpanded:!1,windowWidth:t.target.innerWidth}}))},e.updateNumberFilters=function(t,i){var r=Object.assign({},e.staticFilterInfo);r.hasOwnProperty(t)&&r[t]===i||(r[t]=i,e.staticFilterInfo=r,e.setState({filterInfo:r}))},e.getNumberOfFilters=function(){return Object.values(e.state.filterInfo).reduce((function(e,t){return e+t}),0)},e.renderToolbar=function(t){var r=e.props,n=r.clearAllFilters,s=r.clearFiltersButtonText,o=r.collapseListedFiltersBreakpoint,u=r.isExpanded,h=r.toggleIsExpanded,_=r.className,p=r.children,g=r.isFullHeight,C=r.isStatic,S=r.inset,w=r.usePageInsets,k=r.isSticky,x=r.ouiaId,L=r.numberOfFiltersText,E=r.customChipGroupContent,R=(0,a._T)(r,["clearAllFilters","clearFiltersButtonText","collapseListedFiltersBreakpoint","isExpanded","toggleIsExpanded","className","children","isFullHeight","isStatic","inset","usePageInsets","isSticky","ouiaId","numberOfFiltersText","customChipGroupContent"]),M=e.state.isManagedToggleExpanded,A=e.isToggleManaged(),D=A?M:u,O=e.getNumberOfFilters(),T=O>0;return c.createElement(b.z1.Consumer,null,(function(r){var a=r.width,u=r.getBreakpoint;return c.createElement("div",Object.assign({className:(0,f.i)(l.Z.toolbar,g&&l.Z.modifiers.fullHeight,C&&l.Z.modifiers.static,w&&l.Z.modifiers.pageInsets,k&&l.Z.modifiers.sticky,(0,v.wt)(S,l.Z,"",u(a)),_),id:t},(0,y.dp)(i.displayName,void 0!==x?x:e.state.ouiaStateId),R),c.createElement(d.hP.Provider,{value:{isExpanded:D,toggleIsExpanded:A?e.toggleIsExpanded:h,chipGroupContentRef:e.chipGroupContentRef,updateNumberFilters:e.updateNumberFilters,numberOfFilters:O,clearAllFilters:n,clearFiltersButtonText:s,showClearFiltersButton:T,toolbarId:t,customChipGroupContent:E}},p,c.createElement(m,{isExpanded:D,chipGroupContentRef:e.chipGroupContentRef,clearAllFilters:n,showClearFiltersButton:T,clearFiltersButtonText:s,numberOfFilters:O,numberOfFiltersText:L,collapseListedFiltersBreakpoint:o,customChipGroupContent:E})))}))},e}return(0,n.Z)(i,[{key:"componentDidMount",value:function(){this.isToggleManaged()&&v.Nq&&window.addEventListener("resize",this.closeExpandableContent)}},{key:"componentWillUnmount",value:function(){this.isToggleManaged()&&v.Nq&&window.removeEventListener("resize",this.closeExpandableContent)}},{key:"render",value:function(){var e=this;return this.props.id?this.renderToolbar(this.props.id):c.createElement(h,null,(function(t){return e.renderToolbar(t)}))}}]),i}(c.Component);C.displayName="Toolbar"},2968:function(e,t,i){"use strict";i.d(t,{c:function(){return m}});var r=i(5671),n=i(3144),s=i(136),o=i(7277),a=i(9388),c=i(2791),l=i(3634),u=i(1994),h=i(7780),f=i(1677),d=i(8955),v=i(7695),_=i(6396),p=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(){return(0,r.Z)(this,i),t.apply(this,arguments)}return(0,n.Z)(i,[{key:"render",value:function(){var e=this.props,t=e.className,i=e.expandableContentRef,r=e.chipContainerRef,n=(e.isExpanded,e.clearAllFilters),s=e.clearFiltersButtonText,o=e.showClearFiltersButton,h=(0,a._T)(e,["className","expandableContentRef","chipContainerRef","isExpanded","clearAllFilters","clearFiltersButtonText","showClearFiltersButton"]),f=this.context,p=f.numberOfFilters,g=f.customChipGroupContent;return c.createElement("div",Object.assign({className:(0,u.i)(l.Z.toolbarExpandableContent,t),ref:i},h),c.createElement(d.k,null),p>0&&c.createElement(d.k,{className:l.Z.modifiers.chipContainer},c.createElement(d.k,{ref:r}),o&&!g&&c.createElement(v.E,null,c.createElement(_.zx,{variant:"link",onClick:function(){n()},isInline:!0},s)),g&&g))}}]),i}(c.Component);p.displayName="ToolbarExpandableContent",p.contextType=h.hP,p.defaultProps={isExpanded:!1,clearFiltersButtonText:"Clear all filters"};var g=i(7149),m=function(e){(0,s.Z)(i,e);var t=(0,o.Z)(i);function i(){var e;return(0,r.Z)(this,i),(e=t.apply(this,arguments)).expandableContentRef=c.createRef(),e.chipContainerRef=c.createRef(),e}return(0,n.Z)(i,[{key:"render",value:function(){var e=this,t=this.props,r=t.className,n=t.children,s=t.isExpanded,o=t.toolbarId,d=t.visibility,v=t.visiblity,_=t.alignment,m=t.clearAllFilters,y=t.showClearFiltersButton,b=t.clearFiltersButtonText,C=(0,a._T)(t,["className","children","isExpanded","toolbarId","visibility","visiblity","alignment","clearAllFilters","showClearFiltersButton","clearFiltersButtonText"]);return void 0!==v&&console.warn("The ToolbarContent visiblity prop has been deprecated. Please use the correctly spelled visibility prop instead."),c.createElement(g.z1.Consumer,null,(function(t){var a=t.width,g=t.getBreakpoint;return c.createElement("div",Object.assign({className:(0,u.i)(l.Z.toolbarContent,(0,f.wt)(d||v,l.Z,"",g(a)),(0,f.wt)(_,l.Z,"",g(a)),r)},C),c.createElement(h.hP.Consumer,null,(function(t){var r=t.clearAllFilters,a=t.clearFiltersButtonText,f=t.showClearFiltersButton,d=t.toolbarId,v="".concat(o||d,"-expandable-content-").concat(i.currentId++);return c.createElement(h.sK.Provider,{value:{expandableContentRef:e.expandableContentRef,expandableContentId:v,chipContainerRef:e.chipContainerRef}},c.createElement("div",{className:(0,u.i)(l.Z.toolbarContentSection)},n),c.createElement(p,{id:v,isExpanded:s,expandableContentRef:e.expandableContentRef,chipContainerRef:e.chipContainerRef,clearAllFilters:m||r,showClearFiltersButton:y||f,clearFiltersButtonText:b||a}))})))}))}}]),i}(c.Component);m.displayName="ToolbarContent",m.currentId=0,m.defaultProps={isExpanded:!1,showClearFiltersButton:!1}},8955:function(e,t,i){"use strict";i.d(t,{k:function(){return _}});var r,n=i(5671),s=i(3144),o=i(136),a=i(7277),c=i(9388),l=i(2791),u=i(3634),h=i(1994),f=i(1677),d=i(7149);!function(e){e["filter-group"]="filter-group",e["icon-button-group"]="icon-button-group",e["button-group"]="button-group"}(r||(r={}));var v=function(e){(0,o.Z)(i,e);var t=(0,a.Z)(i);function i(){return(0,n.Z)(this,i),t.apply(this,arguments)}return(0,s.Z)(i,[{key:"render",value:function(){var e=this.props,t=e.visibility,i=e.visiblity,r=e.alignment,n=e.spacer,s=e.spaceItems,o=e.className,a=e.variant,v=e.children,_=e.innerRef,p=(0,c._T)(e,["visibility","visiblity","alignment","spacer","spaceItems","className","variant","children","innerRef"]);return void 0!==i&&console.warn("The ToolbarGroup visiblity prop has been deprecated. Please use the correctly spelled visibility prop instead."),l.createElement(d.z1.Consumer,null,(function(e){var c=e.width,d=e.getBreakpoint;return l.createElement("div",Object.assign({className:(0,h.i)(u.Z.toolbarGroup,a&&u.Z.modifiers[(0,f.fZ)(a)],(0,f.wt)(t||i,u.Z,"",d(c)),(0,f.wt)(r,u.Z,"",d(c)),(0,f.wt)(n,u.Z,"",d(c)),(0,f.wt)(s,u.Z,"",d(c)),o)},p,{ref:_}),v)}))}}]),i}(l.Component),_=l.forwardRef((function(e,t){return l.createElement(v,Object.assign({},e,{innerRef:t}))}))},7695:function(e,t,i){"use strict";i.d(t,{E:function(){return v}});var r,n=i(9439),s=i(9388),o=i(2791),a=i(3634),c=i(1994),l=i(1677),u={divider:"pf-c-divider",modifiers:{hidden:"pf-m-hidden",hiddenOnSm:"pf-m-hidden-on-sm",visibleOnSm:"pf-m-visible-on-sm",hiddenOnMd:"pf-m-hidden-on-md",visibleOnMd:"pf-m-visible-on-md",hiddenOnLg:"pf-m-hidden-on-lg",visibleOnLg:"pf-m-visible-on-lg",hiddenOnXl:"pf-m-hidden-on-xl",visibleOnXl:"pf-m-visible-on-xl",hiddenOn_2xl:"pf-m-hidden-on-2xl",visibleOn_2xl:"pf-m-visible-on-2xl",vertical:"pf-m-vertical",insetNone:"pf-m-inset-none",insetXs:"pf-m-inset-xs",insetSm:"pf-m-inset-sm",insetMd:"pf-m-inset-md",insetLg:"pf-m-inset-lg",insetXl:"pf-m-inset-xl",inset_2xl:"pf-m-inset-2xl",inset_3xl:"pf-m-inset-3xl",horizontalOnSm:"pf-m-horizontal-on-sm",verticalOnSm:"pf-m-vertical-on-sm",insetNoneOnSm:"pf-m-inset-none-on-sm",insetXsOnSm:"pf-m-inset-xs-on-sm",insetSmOnSm:"pf-m-inset-sm-on-sm",insetMdOnSm:"pf-m-inset-md-on-sm",insetLgOnSm:"pf-m-inset-lg-on-sm",insetXlOnSm:"pf-m-inset-xl-on-sm",inset_2xlOnSm:"pf-m-inset-2xl-on-sm",inset_3xlOnSm:"pf-m-inset-3xl-on-sm",horizontalOnMd:"pf-m-horizontal-on-md",verticalOnMd:"pf-m-vertical-on-md",insetNoneOnMd:"pf-m-inset-none-on-md",insetXsOnMd:"pf-m-inset-xs-on-md",insetSmOnMd:"pf-m-inset-sm-on-md",insetMdOnMd:"pf-m-inset-md-on-md",insetLgOnMd:"pf-m-inset-lg-on-md",insetXlOnMd:"pf-m-inset-xl-on-md",inset_2xlOnMd:"pf-m-inset-2xl-on-md",inset_3xlOnMd:"pf-m-inset-3xl-on-md",horizontalOnLg:"pf-m-horizontal-on-lg",verticalOnLg:"pf-m-vertical-on-lg",insetNoneOnLg:"pf-m-inset-none-on-lg",insetXsOnLg:"pf-m-inset-xs-on-lg",insetSmOnLg:"pf-m-inset-sm-on-lg",insetMdOnLg:"pf-m-inset-md-on-lg",insetLgOnLg:"pf-m-inset-lg-on-lg",insetXlOnLg:"pf-m-inset-xl-on-lg",inset_2xlOnLg:"pf-m-inset-2xl-on-lg",inset_3xlOnLg:"pf-m-inset-3xl-on-lg",horizontalOnXl:"pf-m-horizontal-on-xl",verticalOnXl:"pf-m-vertical-on-xl",insetNoneOnXl:"pf-m-inset-none-on-xl",insetXsOnXl:"pf-m-inset-xs-on-xl",insetSmOnXl:"pf-m-inset-sm-on-xl",insetMdOnXl:"pf-m-inset-md-on-xl",insetLgOnXl:"pf-m-inset-lg-on-xl",insetXlOnXl:"pf-m-inset-xl-on-xl",inset_2xlOnXl:"pf-m-inset-2xl-on-xl",inset_3xlOnXl:"pf-m-inset-3xl-on-xl",horizontalOn_2xl:"pf-m-horizontal-on-2xl",verticalOn_2xl:"pf-m-vertical-on-2xl",insetNoneOn_2xl:"pf-m-inset-none-on-2xl",insetXsOn_2xl:"pf-m-inset-xs-on-2xl",insetSmOn_2xl:"pf-m-inset-sm-on-2xl",insetMdOn_2xl:"pf-m-inset-md-on-2xl",insetLgOn_2xl:"pf-m-inset-lg-on-2xl",insetXlOn_2xl:"pf-m-inset-xl-on-2xl",inset_2xlOn_2xl:"pf-m-inset-2xl-on-2xl",inset_3xlOn_2xl:"pf-m-inset-3xl-on-2xl"}};!function(e){e.hr="hr",e.li="li",e.div="div"}(r||(r={}));var h=function(e){var t=e.className,i=e.component,n=void 0===i?r.hr:i,a=e.isVertical,h=void 0!==a&&a,f=e.inset,d=e.orientation,v=(0,s._T)(e,["className","component","isVertical","inset","orientation"]),_=n;return o.createElement(_,Object.assign({className:(0,c.i)(u.divider,h&&u.modifiers.vertical,(0,l.wt)(f,u),(0,l.wt)(d,u),t)},"hr"!==n&&{role:"separator"},v))};h.displayName="Divider";var f,d=i(7149);!function(e){e.separator="separator",e["bulk-select"]="bulk-select",e["overflow-menu"]="overflow-menu",e.pagination="pagination",e["search-filter"]="search-filter",e.label="label",e["chip-group"]="chip-group",e["expand-all"]="expand-all"}(f||(f={}));var v=function(e){var t=e.className,i=e.variant,r=e.visibility,u=e.visiblity,v=e.alignment,_=e.spacer,p=e.widths,g=e.id,m=e.children,y=e.isAllExpanded,b=(0,s._T)(e,["className","variant","visibility","visiblity","alignment","spacer","widths","id","children","isAllExpanded"]);if(i===f.separator)return o.createElement(h,Object.assign({className:(0,c.i)(a.Z.modifiers.vertical,t)},b));void 0!==u&&console.warn("The ToolbarItem visiblity prop has been deprecated. Please use the correctly spelled visibility prop instead.");var C={};return p&&Object.entries(p||{}).map((function(e){var t=(0,n.Z)(e,2),i=t[0],r=t[1];return C["--pf-c-toolbar__item--Width".concat("default"!==i?"-on-".concat(i):"")]=r})),o.createElement(d.z1.Consumer,null,(function(e){var n=e.width,s=e.getBreakpoint;return o.createElement("div",Object.assign({className:(0,c.i)(a.Z.toolbarItem,i&&a.Z.modifiers[(0,l.fZ)(i)],y&&a.Z.modifiers.expanded,(0,l.wt)(r||u,a.Z,"",s(n)),(0,l.wt)(v,a.Z,"",s(n)),(0,l.wt)(_,a.Z,"",s(n)),t)},"label"===i&&{"aria-hidden":!0},{id:g},b,p&&{style:Object.assign(Object.assign({},C),b.style)}),m)}))};v.displayName="ToolbarItem"},7780:function(e,t,i){"use strict";i.d(t,{Oc:function(){return u},hP:function(){return c},sK:function(){return l}});var r=i(2791),n=i(4489),s=i(652),o=i(6613),a=i(2224),c=r.createContext({isExpanded:!1,toggleIsExpanded:function(){},chipGroupContentRef:null,updateNumberFilters:function(){},numberOfFilters:0,clearAllFilters:function(){}}),l=r.createContext({expandableContentRef:null,expandableContentId:"",chipContainerRef:null}),u={md:parseInt(n.Z.value),lg:parseInt(s.Z.value),xl:parseInt(o.Z.value),"2xl":parseInt(a.Z.value)}},4134:function(e,t,i){"use strict";i.d(t,{S$:function(){return c},dp:function(){return a},ql:function(){return u}});var r=i(2791),n=0,s="OUIA-Generated-",o={};function a(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return{"data-ouia-component-type":"PF4/".concat(e),"data-ouia-safe":i,"data-ouia-component-id":t}}var c=function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=arguments.length>3?arguments[3]:void 0;return{"data-ouia-component-type":"PF4/".concat(e),"data-ouia-safe":i,"data-ouia-component-id":l(e,t,r)}},l=function(e,t,i){var n=(0,r.useMemo)((function(){return u(e,i)}),[e,i]);return null!==t&&void 0!==t?t:n};function u(e,t){try{var i;return i="undefined"!==typeof window?"".concat(window.location.href,"-").concat(e,"-").concat(t||""):"".concat(e,"-").concat(t||""),o[i]||(o[i]=0),"".concat(s).concat(e,"-").concat(t?"".concat(t,"-"):"").concat(++o[i])}catch(r){return"".concat(s).concat(e,"-").concat(t?"".concat(t,"-"):"").concat(++n)}}},8132:function(e,t,i){"use strict";i.d(t,{yu:function(){return v},LD:function(){return r},pr:function(){return p},H_:function(){return _}});var r,n={name:"--pf-global--breakpoint--sm",value:"576px",var:"var(--pf-global--breakpoint--sm)"},s=i(4489),o=i(652),a=i(6613),c=i(2224),l={name:"--pf-global--height-breakpoint--sm",value:"0",var:"var(--pf-global--height-breakpoint--sm)"},u={name:"--pf-global--height-breakpoint--md",value:"40rem",var:"var(--pf-global--height-breakpoint--md)"},h={name:"--pf-global--height-breakpoint--lg",value:"48rem",var:"var(--pf-global--height-breakpoint--lg)"},f={name:"--pf-global--height-breakpoint--xl",value:"60rem",var:"var(--pf-global--height-breakpoint--xl)"},d={name:"--pf-global--height-breakpoint--2xl",value:"80rem",var:"var(--pf-global--height-breakpoint--2xl)"};!function(e){e.success="success",e.error="error",e.warning="warning",e.default="default"}(r||(r={}));var v={Tab:"Tab",Space:" ",Escape:"Escape",Enter:"Enter",ArrowUp:"ArrowUp",ArrowDown:"ArrowDown",ArrowLeft:"ArrowLeft",ArrowRight:"ArrowRight"},_={sm:parseInt(n.value),md:parseInt(s.Z.value),lg:parseInt(o.Z.value),xl:parseInt(a.Z.value),"2xl":parseInt(c.Z.value)},p={sm:parseInt(l.value),md:parseInt(u.value),lg:parseInt(h.value),xl:parseInt(f.value),"2xl":parseInt(d.value)}},1677:function(e,t,i){"use strict";i.d(t,{Nq:function(){return h},fZ:function(){return u},fi:function(){return d},iu:function(){return c},kC:function(){return s},wt:function(){return o},xb:function(){return a}});var r=i(9439),n=(i(4164),i(8132));function s(e){return e[0].toUpperCase()+e.substring(1)}var o=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3?arguments[3]:void 0,s=arguments.length>4?arguments[4]:void 0;if(!e)return"";if(n&&!s){if(n in e)return t.modifiers[u("".concat(i).concat(e[n]))];for(var o=["2xl","xl","lg","md","sm","default"],a=o.indexOf(n);a<o.length;a++)if(o[a]in e)return t.modifiers[u("".concat(i).concat(e[o[a]]))];return""}return Object.entries(e||{}).map((function(e){var t=(0,r.Z)(e,2),n=t[0],o=t[1];return"".concat(i).concat(o).concat("default"!==n?"-on-".concat(n):"").concat(s&&"default"!==n?"-height":"")})).map(u).map((function(e){return e.replace(/-?(\dxl)/gi,(function(e,t){return"_".concat(t)}))})).map((function(e){return t.modifiers[e]})).filter(Boolean).join(" ")},a=function(e){return null===e?null:e>=n.pr["2xl"]?"2xl":e>=n.pr.xl?"xl":e>=n.pr.lg?"lg":e>=n.pr.md?"md":e>=n.pr.sm?"sm":"default"},c=function(e){return null===e?null:e>=n.H_["2xl"]?"2xl":e>=n.H_.xl?"xl":e>=n.H_.lg?"lg":e>=n.H_.md?"md":e>=n.H_.sm?"sm":"default"},l=function(e){return e.toUpperCase().replace("-","").replace("_","")},u=function(e){return e.replace(/([-_][a-z])/gi,l)},h=!("undefined"===typeof window||!window.document||!window.document.createElement),f=function(e,t){var i=getComputedStyle(t),r=document.createElement("canvas").getContext("2d");return r.font=i.font||function(){var e,t={"50%":"ultra-condensed","62.5%":"extra-condensed","75%":"condensed","87.5%":"semi-condensed","100%":"normal","112.5%":"semi-expanded","125%":"expanded","150%":"extra-expanded","200%":"ultra-expanded"};return e=i.fontStretch in t?t[i.fontStretch]:"normal",i.fontStyle+" "+i.fontVariant+" "+i.fontWeight+" "+e+" "+i.fontSize+"/"+i.lineHeight+" "+i.fontFamily}(),r.measureText(e).width},d=function(e,t){var i=function(e){var t=getComputedStyle(e),i=e.clientWidth,r=e.clientHeight;return{height:r-=parseFloat(t.paddingTop)+parseFloat(t.paddingBottom),width:i-=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight)}}(e).width,r=t;if(f(t,e)>i){for(;f("...".concat(r),e)>i;)r=r.substring(1);e.value?e.value="...".concat(r):e.innerText="...".concat(r)}else e.value?e.value=t:e.innerText=t}},9720:function(e,t,i){"use strict";i.d(t,{IU:function(){return f}});var r,n=i(5671),s=i(3144),o=i(136),a=i(7277),c=i(9388),l=i(2791);!function(e){e.sm="sm",e.md="md",e.lg="lg",e.xl="xl"}(r||(r={}));var u=function(e){switch(e){case r.sm:return"1em";case r.md:return"1.5em";case r.lg:return"2em";case r.xl:return"3em";default:return"1em"}},h=0;function f(e){var t,i=e.name,f=e.xOffset,d=void 0===f?0:f,v=e.yOffset,_=void 0===v?0:v,p=e.width,g=e.height,m=e.svgPath;return t=function(e){(0,o.Z)(i,e);var t=(0,a.Z)(i);function i(){var e;return(0,n.Z)(this,i),(e=t.apply(this,arguments)).id="icon-title-".concat(h++),e}return(0,s.Z)(i,[{key:"render",value:function(){var e=this.props,t=e.size,i=e.color,r=e.title,n=e.noVerticalAlign,s=(0,c._T)(e,["size","color","title","noVerticalAlign"]),o=Boolean(r),a=u(t),h=-.125*Number.parseFloat(a),f=n?null:{verticalAlign:"".concat(h,"em")},v=[d,_,p,g].join(" ");return l.createElement("svg",Object.assign({style:f,fill:i,height:a,width:a,viewBox:v,"aria-labelledby":o?this.id:null,"aria-hidden":!o||null,role:"img"},s),o&&l.createElement("title",{id:this.id},r),l.createElement("path",{d:m}))}}]),i}(l.Component),t.displayName=i,t.defaultProps={color:"currentColor",size:r.sm,noVerticalAlign:!1},t}},1994:function(e,t,i){"use strict";i.d(t,{i:function(){return n}});var r=i(3433);function n(){for(var e=[],t={}.hasOwnProperty,i=arguments.length,s=new Array(i),o=0;o<i;o++)s[o]=arguments[o];return s.filter(Boolean).forEach((function(i){var s=typeof i;if("string"===s||"number"===s)e.push(i);else if(Array.isArray(i)&&i.length){var o=n.apply(void 0,(0,r.Z)(i));o&&e.push(o)}else if("object"===s)for(var a in i)t.call(i,a)&&i[a]&&e.push(a)})),e.join(" ")}},2224:function(e,t,i){"use strict";t.Z={name:"--pf-global--breakpoint--2xl",value:"1450px",var:"var(--pf-global--breakpoint--2xl)"}},652:function(e,t,i){"use strict";t.Z={name:"--pf-global--breakpoint--lg",value:"992px",var:"var(--pf-global--breakpoint--lg)"}},4489:function(e,t,i){"use strict";t.Z={name:"--pf-global--breakpoint--md",value:"768px",var:"var(--pf-global--breakpoint--md)"}},6613:function(e,t,i){"use strict";t.Z={name:"--pf-global--breakpoint--xl",value:"1200px",var:"var(--pf-global--breakpoint--xl)"}},5249:function(e,t,i){var r=i(861).default,n=i(7424).default,s=i(6115).default,o=i(1588).default,a=i(4968).default,c=i(4704).default,l=i(6690).default,u=i(9728).default,h=i(1655).default,f=i(6389).default;self,e.exports=function(){"use strict";var e={903:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BaseRenderLayer=void 0;var r=i(503),n=i(627),s=i(237),o=i(860),a=i(374),c=i(296),d=i(855),v=i(274),_=i(859),p=i(399),g=i(345),m=function(e){h(i,e);var t=f(i);function i(e,n,s,o,a,u,h,f,d,p){var m;return l(this,i),(m=t.call(this))._terminal=e,m._container=n,m._alpha=a,m._themeService=u,m._bufferService=h,m._optionsService=f,m._decorationService=d,m._coreBrowserService=p,m._deviceCharWidth=0,m._deviceCharHeight=0,m._deviceCellWidth=0,m._deviceCellHeight=0,m._deviceCharLeft=0,m._deviceCharTop=0,m._selectionModel=(0,c.createSelectionRenderModel)(),m._bitmapGenerator=[],m._onAddTextureAtlasCanvas=m.register(new g.EventEmitter),m.onAddTextureAtlasCanvas=m._onAddTextureAtlasCanvas.event,m._cellColorResolver=new v.CellColorResolver(m._terminal,m._selectionModel,m._decorationService,m._coreBrowserService,m._themeService),m._canvas=document.createElement("canvas"),m._canvas.classList.add("xterm-".concat(s,"-layer")),m._canvas.style.zIndex=o.toString(),m._initCanvas(),m._container.appendChild(m._canvas),m._refreshCharAtlas(m._themeService.colors),m.register(m._themeService.onChangeColors((function(e){m._refreshCharAtlas(e),m.reset()}))),m.register((0,_.toDisposable)((function(){var e;(0,r.removeElementFromParent)(m._canvas),null===(e=m._charAtlas)||void 0===e||e.dispose()}))),m}return u(i,[{key:"canvas",get:function(){return this._canvas}},{key:"cacheCanvas",get:function(){var e;return null===(e=this._charAtlas)||void 0===e?void 0:e.pages[0].canvas}},{key:"_initCanvas",value:function(){this._ctx=(0,a.throwIfFalsy)(this._canvas.getContext("2d",{alpha:this._alpha})),this._alpha||this._clearAll()}},{key:"handleBlur",value:function(){}},{key:"handleFocus",value:function(){}},{key:"handleCursorMove",value:function(){}},{key:"handleGridChanged",value:function(e,t){}},{key:"handleSelectionChanged",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this._selectionModel.update(this._terminal,e,t,i)}},{key:"_setTransparency",value:function(e){if(e!==this._alpha){var t=this._canvas;this._alpha=e,this._canvas=this._canvas.cloneNode(),this._initCanvas(),this._container.replaceChild(this._canvas,t),this._refreshCharAtlas(this._themeService.colors),this.handleGridChanged(0,this._bufferService.rows-1)}}},{key:"_refreshCharAtlas",value:function(e){var t;if(!(this._deviceCharWidth<=0&&this._deviceCharHeight<=0)){null===(t=this._charAtlasDisposable)||void 0===t||t.dispose(),this._charAtlas=(0,n.acquireTextureAtlas)(this._terminal,this._optionsService.rawOptions,e,this._deviceCellWidth,this._deviceCellHeight,this._deviceCharWidth,this._deviceCharHeight,this._coreBrowserService.dpr),this._charAtlasDisposable=(0,g.forwardEvent)(this._charAtlas.onAddTextureAtlasCanvas,this._onAddTextureAtlasCanvas),this._charAtlas.warmUp();for(var i=0;i<this._charAtlas.pages.length;i++)this._bitmapGenerator[i]=new y(this._charAtlas.pages[i].canvas)}}},{key:"resize",value:function(e){this._deviceCellWidth=e.device.cell.width,this._deviceCellHeight=e.device.cell.height,this._deviceCharWidth=e.device.char.width,this._deviceCharHeight=e.device.char.height,this._deviceCharLeft=e.device.char.left,this._deviceCharTop=e.device.char.top,this._canvas.width=e.device.canvas.width,this._canvas.height=e.device.canvas.height,this._canvas.style.width="".concat(e.css.canvas.width,"px"),this._canvas.style.height="".concat(e.css.canvas.height,"px"),this._alpha||this._clearAll(),this._refreshCharAtlas(this._themeService.colors)}},{key:"clearTextureAtlas",value:function(){var e;null===(e=this._charAtlas)||void 0===e||e.clearTexture()}},{key:"_fillCells",value:function(e,t,i,r){this._ctx.fillRect(e*this._deviceCellWidth,t*this._deviceCellHeight,i*this._deviceCellWidth,r*this._deviceCellHeight)}},{key:"_fillMiddleLineAtCells",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=Math.ceil(.5*this._deviceCellHeight);this._ctx.fillRect(e*this._deviceCellWidth,(t+1)*this._deviceCellHeight-r-this._coreBrowserService.dpr,i*this._deviceCellWidth,this._coreBrowserService.dpr)}},{key:"_fillBottomLineAtCells",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;this._ctx.fillRect(e*this._deviceCellWidth,(t+1)*this._deviceCellHeight+r-this._coreBrowserService.dpr-1,i*this._deviceCellWidth,this._coreBrowserService.dpr)}},{key:"_curlyUnderlineAtCell",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;this._ctx.save(),this._ctx.beginPath(),this._ctx.strokeStyle=this._ctx.fillStyle;var r=this._coreBrowserService.dpr;this._ctx.lineWidth=r;for(var n=0;n<i;n++){var s=(e+n)*this._deviceCellWidth,o=(e+n+.5)*this._deviceCellWidth,a=(e+n+1)*this._deviceCellWidth,c=(t+1)*this._deviceCellHeight-r-1,l=c-r,u=c+r;this._ctx.moveTo(s,c),this._ctx.bezierCurveTo(s,l,o,l,o,c),this._ctx.bezierCurveTo(o,u,a,u,a,c)}this._ctx.stroke(),this._ctx.restore()}},{key:"_dottedUnderlineAtCell",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;this._ctx.save(),this._ctx.beginPath(),this._ctx.strokeStyle=this._ctx.fillStyle;var r=this._coreBrowserService.dpr;this._ctx.lineWidth=r,this._ctx.setLineDash([2*r,r]);var n=e*this._deviceCellWidth,s=(t+1)*this._deviceCellHeight-r-1;this._ctx.moveTo(n,s);for(var o=0;o<i;o++){var a=(e+i+o)*this._deviceCellWidth;this._ctx.lineTo(a,s)}this._ctx.stroke(),this._ctx.closePath(),this._ctx.restore()}},{key:"_dashedUnderlineAtCell",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;this._ctx.save(),this._ctx.beginPath(),this._ctx.strokeStyle=this._ctx.fillStyle;var r=this._coreBrowserService.dpr;this._ctx.lineWidth=r,this._ctx.setLineDash([4*r,3*r]);var n=e*this._deviceCellWidth,s=(e+i)*this._deviceCellWidth,o=(t+1)*this._deviceCellHeight-r-1;this._ctx.moveTo(n,o),this._ctx.lineTo(s,o),this._ctx.stroke(),this._ctx.closePath(),this._ctx.restore()}},{key:"_fillLeftLineAtCell",value:function(e,t,i){this._ctx.fillRect(e*this._deviceCellWidth,t*this._deviceCellHeight,this._coreBrowserService.dpr*i,this._deviceCellHeight)}},{key:"_strokeRectAtCell",value:function(e,t,i,r){var n=this._coreBrowserService.dpr;this._ctx.lineWidth=n,this._ctx.strokeRect(e*this._deviceCellWidth+n/2,t*this._deviceCellHeight+n/2,i*this._deviceCellWidth-n,r*this._deviceCellHeight-n)}},{key:"_clearAll",value:function(){this._alpha?this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height):(this._ctx.fillStyle=this._themeService.colors.background.css,this._ctx.fillRect(0,0,this._canvas.width,this._canvas.height))}},{key:"_clearCells",value:function(e,t,i,r){this._alpha?this._ctx.clearRect(e*this._deviceCellWidth,t*this._deviceCellHeight,i*this._deviceCellWidth,r*this._deviceCellHeight):(this._ctx.fillStyle=this._themeService.colors.background.css,this._ctx.fillRect(e*this._deviceCellWidth,t*this._deviceCellHeight,i*this._deviceCellWidth,r*this._deviceCellHeight))}},{key:"_fillCharTrueColor",value:function(e,t,i){this._ctx.font=this._getFont(!1,!1),this._ctx.textBaseline=s.TEXT_BASELINE,this._clipRow(i);var r=!1;!1!==this._optionsService.rawOptions.customGlyphs&&(r=(0,o.tryDrawCustomChar)(this._ctx,e.getChars(),t*this._deviceCellWidth,i*this._deviceCellHeight,this._deviceCellWidth,this._deviceCellHeight,this._optionsService.rawOptions.fontSize,this._coreBrowserService.dpr)),r||this._ctx.fillText(e.getChars(),t*this._deviceCellWidth+this._deviceCharLeft,i*this._deviceCellHeight+this._deviceCharTop+this._deviceCharHeight)}},{key:"_drawChars",value:function(e,t,i){var r,n,s,o=e.getChars();this._cellColorResolver.resolve(e,t,this._bufferService.buffer.ydisp+i),(s=o&&o.length>1?this._charAtlas.getRasterizedGlyphCombinedChar(o,this._cellColorResolver.result.bg,this._cellColorResolver.result.fg,this._cellColorResolver.result.ext):this._charAtlas.getRasterizedGlyph(e.getCode()||d.WHITESPACE_CELL_CODE,this._cellColorResolver.result.bg,this._cellColorResolver.result.fg,this._cellColorResolver.result.ext)).size.x&&s.size.y&&(this._ctx.save(),this._clipRow(i),this._charAtlas.pages[s.texturePage].version!==(null===(r=this._bitmapGenerator[s.texturePage])||void 0===r?void 0:r.version)&&(this._bitmapGenerator[s.texturePage]||(this._bitmapGenerator[s.texturePage]=new y(this._charAtlas.pages[s.texturePage].canvas)),this._bitmapGenerator[s.texturePage].refresh(),this._bitmapGenerator[s.texturePage].version=this._charAtlas.pages[s.texturePage].version),this._ctx.drawImage((null===(n=this._bitmapGenerator[s.texturePage])||void 0===n?void 0:n.bitmap)||this._charAtlas.pages[s.texturePage].canvas,s.texturePosition.x,s.texturePosition.y,s.size.x,s.size.y,t*this._deviceCellWidth+this._deviceCharLeft-s.offset.x,i*this._deviceCellHeight+this._deviceCharTop-s.offset.y,s.size.x,s.size.y),this._ctx.restore())}},{key:"_clipRow",value:function(e){this._ctx.beginPath(),this._ctx.rect(0,e*this._deviceCellHeight,this._bufferService.cols*this._deviceCellWidth,this._deviceCellHeight),this._ctx.clip()}},{key:"_getFont",value:function(e,t){return"".concat(t?"italic":""," ").concat(e?this._optionsService.rawOptions.fontWeightBold:this._optionsService.rawOptions.fontWeight," ").concat(this._optionsService.rawOptions.fontSize*this._coreBrowserService.dpr,"px ").concat(this._optionsService.rawOptions.fontFamily)}}]),i}(_.Disposable);t.BaseRenderLayer=m;var y=function(){function e(t){l(this,e),this._canvas=t,this._state=0,this._commitTimeout=void 0,this._bitmap=void 0,this.version=-1}return u(e,[{key:"bitmap",get:function(){return this._bitmap}},{key:"refresh",value:function(){var e=this;this._bitmap=void 0,p.isSafari||(void 0===this._commitTimeout&&(this._commitTimeout=window.setTimeout((function(){return e._generate()}),100)),1===this._state&&(this._state=2))}},{key:"_generate",value:function(){var e=this;0===this._state&&(this._bitmap=void 0,this._state=1,window.createImageBitmap(this._canvas).then((function(t){2===e._state?e.refresh():e._bitmap=t,e._state=0})),this._commitTimeout&&(this._commitTimeout=void 0))}}]),e}()},949:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.CanvasRenderer=void 0;var r=i(627),n=i(56),s=i(374),o=i(345),a=i(859),d=i(873),v=i(43),_=i(630),p=i(744),g=function(e){h(i,e);var t=f(i);function i(e,u,h,f,g,m,y,b,C,S,w){var k;l(this,i),(k=t.call(this))._terminal=e,k._screenElement=u,k._bufferService=f,k._charSizeService=g,k._optionsService=m,k._coreBrowserService=C,k._themeService=w,k._onRequestRedraw=k.register(new o.EventEmitter),k.onRequestRedraw=k._onRequestRedraw.event,k._onChangeTextureAtlas=k.register(new o.EventEmitter),k.onChangeTextureAtlas=k._onChangeTextureAtlas.event,k._onAddTextureAtlasCanvas=k.register(new o.EventEmitter),k.onAddTextureAtlasCanvas=k._onAddTextureAtlasCanvas.event;var x=k._optionsService.rawOptions.allowTransparency;k._renderLayers=[new p.TextRenderLayer(k._terminal,k._screenElement,0,x,k._bufferService,k._optionsService,y,S,k._coreBrowserService,w),new _.SelectionRenderLayer(k._terminal,k._screenElement,1,k._bufferService,k._coreBrowserService,S,k._optionsService,w),new v.LinkRenderLayer(k._terminal,k._screenElement,2,h,k._bufferService,k._optionsService,S,k._coreBrowserService,w),new d.CursorRenderLayer(k._terminal,k._screenElement,3,k._onRequestRedraw,k._bufferService,k._optionsService,b,k._coreBrowserService,S,w)];var L,E=c(k._renderLayers);try{for(E.s();!(L=E.n()).done;){var R=L.value;(0,o.forwardEvent)(R.onAddTextureAtlasCanvas,k._onAddTextureAtlasCanvas)}}catch(M){E.e(M)}finally{E.f()}return k.dimensions=(0,s.createRenderDimensions)(),k._devicePixelRatio=k._coreBrowserService.dpr,k._updateDimensions(),k.register((0,n.observeDevicePixelDimensions)(k._renderLayers[0].canvas,k._coreBrowserService.window,(function(e,t){return k._setCanvasDevicePixelDimensions(e,t)}))),k.register((0,a.toDisposable)((function(){var e,t=c(k._renderLayers);try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(M){t.e(M)}finally{t.f()}(0,r.removeTerminalFromCache)(k._terminal)}))),k}return u(i,[{key:"textureAtlas",get:function(){return this._renderLayers[0].cacheCanvas}},{key:"handleDevicePixelRatioChange",value:function(){this._devicePixelRatio!==this._coreBrowserService.dpr&&(this._devicePixelRatio=this._coreBrowserService.dpr,this.handleResize(this._bufferService.cols,this._bufferService.rows))}},{key:"handleResize",value:function(e,t){this._updateDimensions();var i,r=c(this._renderLayers);try{for(r.s();!(i=r.n()).done;)i.value.resize(this.dimensions)}catch(n){r.e(n)}finally{r.f()}this._screenElement.style.width="".concat(this.dimensions.css.canvas.width,"px"),this._screenElement.style.height="".concat(this.dimensions.css.canvas.height,"px")}},{key:"handleCharSizeChanged",value:function(){this.handleResize(this._bufferService.cols,this._bufferService.rows)}},{key:"handleBlur",value:function(){this._runOperation((function(e){return e.handleBlur()}))}},{key:"handleFocus",value:function(){this._runOperation((function(e){return e.handleFocus()}))}},{key:"handleSelectionChanged",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this._runOperation((function(r){return r.handleSelectionChanged(e,t,i)})),this._themeService.colors.selectionForeground&&this._onRequestRedraw.fire({start:0,end:this._bufferService.rows-1})}},{key:"handleCursorMove",value:function(){this._runOperation((function(e){return e.handleCursorMove()}))}},{key:"clear",value:function(){this._runOperation((function(e){return e.reset()}))}},{key:"_runOperation",value:function(e){var t,i=c(this._renderLayers);try{for(i.s();!(t=i.n()).done;)e(t.value)}catch(r){i.e(r)}finally{i.f()}}},{key:"renderRows",value:function(e,t){var i,r=c(this._renderLayers);try{for(r.s();!(i=r.n()).done;)i.value.handleGridChanged(e,t)}catch(n){r.e(n)}finally{r.f()}}},{key:"clearTextureAtlas",value:function(){var e,t=c(this._renderLayers);try{for(t.s();!(e=t.n()).done;)e.value.clearTextureAtlas()}catch(i){t.e(i)}finally{t.f()}}},{key:"_updateDimensions",value:function(){if(this._charSizeService.hasValidSize){var e=this._coreBrowserService.dpr;this.dimensions.device.char.width=Math.floor(this._charSizeService.width*e),this.dimensions.device.char.height=Math.ceil(this._charSizeService.height*e),this.dimensions.device.cell.height=Math.floor(this.dimensions.device.char.height*this._optionsService.rawOptions.lineHeight),this.dimensions.device.char.top=1===this._optionsService.rawOptions.lineHeight?0:Math.round((this.dimensions.device.cell.height-this.dimensions.device.char.height)/2),this.dimensions.device.cell.width=this.dimensions.device.char.width+Math.round(this._optionsService.rawOptions.letterSpacing),this.dimensions.device.char.left=Math.floor(this._optionsService.rawOptions.letterSpacing/2),this.dimensions.device.canvas.height=this._bufferService.rows*this.dimensions.device.cell.height,this.dimensions.device.canvas.width=this._bufferService.cols*this.dimensions.device.cell.width,this.dimensions.css.canvas.height=Math.round(this.dimensions.device.canvas.height/e),this.dimensions.css.canvas.width=Math.round(this.dimensions.device.canvas.width/e),this.dimensions.css.cell.height=this.dimensions.css.canvas.height/this._bufferService.rows,this.dimensions.css.cell.width=this.dimensions.css.canvas.width/this._bufferService.cols}}},{key:"_setCanvasDevicePixelDimensions",value:function(e,t){this.dimensions.device.canvas.height=t,this.dimensions.device.canvas.width=e;var i,r=c(this._renderLayers);try{for(r.s();!(i=r.n()).done;)i.value.resize(this.dimensions)}catch(n){r.e(n)}finally{r.f()}this._requestRedrawViewport()}},{key:"_requestRedrawViewport",value:function(){this._onRequestRedraw.fire({start:0,end:this._bufferService.rows-1})}}]),i}(a.Disposable);t.CanvasRenderer=g},873:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.CursorRenderLayer=void 0;var r=i(903),n=i(782),c=i(859),d=function(e){h(i,e);var t=f(i);function i(e,r,o,a,u,h,f,d,v,_){var p;return l(this,i),(p=t.call(this,e,r,"cursor",o,!0,_,u,h,v,d))._onRequestRedraw=a,p._coreService=f,p._cell=new n.CellData,p._state={x:0,y:0,isFocused:!1,style:"",width:0},p._cursorRenderers={bar:p._renderBarCursor.bind(s(p)),block:p._renderBlockCursor.bind(s(p)),underline:p._renderUnderlineCursor.bind(s(p))},p.register(h.onOptionChange((function(){return p._handleOptionsChanged()}))),p.register((0,c.toDisposable)((function(){var e;null===(e=p._cursorBlinkStateManager)||void 0===e||e.dispose(),p._cursorBlinkStateManager=void 0}))),p}return u(i,[{key:"resize",value:function(e){o(a(i.prototype),"resize",this).call(this,e),this._state={x:0,y:0,isFocused:!1,style:"",width:0}}},{key:"reset",value:function(){var e;this._clearCursor(),null===(e=this._cursorBlinkStateManager)||void 0===e||e.restartBlinkAnimation(),this._handleOptionsChanged()}},{key:"handleBlur",value:function(){var e;null===(e=this._cursorBlinkStateManager)||void 0===e||e.pause(),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})}},{key:"handleFocus",value:function(){var e;null===(e=this._cursorBlinkStateManager)||void 0===e||e.resume(),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})}},{key:"_handleOptionsChanged",value:function(){var e,t=this;this._optionsService.rawOptions.cursorBlink?this._cursorBlinkStateManager||(this._cursorBlinkStateManager=new v(this._coreBrowserService.isFocused,(function(){t._render(!0)}),this._coreBrowserService)):(null===(e=this._cursorBlinkStateManager)||void 0===e||e.dispose(),this._cursorBlinkStateManager=void 0),this._onRequestRedraw.fire({start:this._bufferService.buffer.y,end:this._bufferService.buffer.y})}},{key:"handleCursorMove",value:function(){var e;null===(e=this._cursorBlinkStateManager)||void 0===e||e.restartBlinkAnimation()}},{key:"handleGridChanged",value:function(e,t){!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isPaused?this._render(!1):this._cursorBlinkStateManager.restartBlinkAnimation()}},{key:"_render",value:function(e){if(this._coreService.isCursorInitialized&&!this._coreService.isCursorHidden){var t=this._bufferService.buffer.ybase+this._bufferService.buffer.y,i=t-this._bufferService.buffer.ydisp;if(i<0||i>=this._bufferService.rows)this._clearCursor();else{var r=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1);if(this._bufferService.buffer.lines.get(t).loadCell(r,this._cell),void 0!==this._cell.content){if(!this._coreBrowserService.isFocused){this._clearCursor(),this._ctx.save(),this._ctx.fillStyle=this._themeService.colors.cursor.css;var n=this._optionsService.rawOptions.cursorStyle;return n&&"block"!==n?this._cursorRenderers[n](r,i,this._cell):this._renderBlurCursor(r,i,this._cell),this._ctx.restore(),this._state.x=r,this._state.y=i,this._state.isFocused=!1,this._state.style=n,void(this._state.width=this._cell.getWidth())}if(!this._cursorBlinkStateManager||this._cursorBlinkStateManager.isCursorVisible){if(this._state){if(this._state.x===r&&this._state.y===i&&this._state.isFocused===this._coreBrowserService.isFocused&&this._state.style===this._optionsService.rawOptions.cursorStyle&&this._state.width===this._cell.getWidth())return;this._clearCursor()}this._ctx.save(),this._cursorRenderers[this._optionsService.rawOptions.cursorStyle||"block"](r,i,this._cell),this._ctx.restore(),this._state.x=r,this._state.y=i,this._state.isFocused=!1,this._state.style=this._optionsService.rawOptions.cursorStyle,this._state.width=this._cell.getWidth()}else this._clearCursor()}}}else this._clearCursor()}},{key:"_clearCursor",value:function(){this._state&&(this._coreBrowserService.dpr<1?this._clearAll():this._clearCells(this._state.x,this._state.y,this._state.width,1),this._state={x:0,y:0,isFocused:!1,style:"",width:0})}},{key:"_renderBarCursor",value:function(e,t,i){this._ctx.save(),this._ctx.fillStyle=this._themeService.colors.cursor.css,this._fillLeftLineAtCell(e,t,this._optionsService.rawOptions.cursorWidth),this._ctx.restore()}},{key:"_renderBlockCursor",value:function(e,t,i){this._ctx.save(),this._ctx.fillStyle=this._themeService.colors.cursor.css,this._fillCells(e,t,i.getWidth(),1),this._ctx.fillStyle=this._themeService.colors.cursorAccent.css,this._fillCharTrueColor(i,e,t),this._ctx.restore()}},{key:"_renderUnderlineCursor",value:function(e,t,i){this._ctx.save(),this._ctx.fillStyle=this._themeService.colors.cursor.css,this._fillBottomLineAtCells(e,t),this._ctx.restore()}},{key:"_renderBlurCursor",value:function(e,t,i){this._ctx.save(),this._ctx.strokeStyle=this._themeService.colors.cursor.css,this._strokeRectAtCell(e,t,i.getWidth(),1),this._ctx.restore()}}]),i}(r.BaseRenderLayer);t.CursorRenderLayer=d;var v=function(){function e(t,i,r){l(this,e),this._renderCallback=i,this._coreBrowserService=r,this.isCursorVisible=!0,t&&this._restartInterval()}return u(e,[{key:"isPaused",get:function(){return!(this._blinkStartTimeout||this._blinkInterval)}},{key:"dispose",value:function(){this._blinkInterval&&(this._coreBrowserService.window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(this._coreBrowserService.window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(this._coreBrowserService.window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}},{key:"restartBlinkAnimation",value:function(){var e=this;this.isPaused||(this._animationTimeRestarted=Date.now(),this.isCursorVisible=!0,this._animationFrame||(this._animationFrame=this._coreBrowserService.window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=void 0}))))}},{key:"_restartInterval",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:600;this._blinkInterval&&(this._coreBrowserService.window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout=this._coreBrowserService.window.setTimeout((function(){if(e._animationTimeRestarted){var t=600-(Date.now()-e._animationTimeRestarted);if(e._animationTimeRestarted=void 0,t>0)return void e._restartInterval(t)}e.isCursorVisible=!1,e._animationFrame=e._coreBrowserService.window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=void 0})),e._blinkInterval=e._coreBrowserService.window.setInterval((function(){if(e._animationTimeRestarted){var t=600-(Date.now()-e._animationTimeRestarted);return e._animationTimeRestarted=void 0,void e._restartInterval(t)}e.isCursorVisible=!e.isCursorVisible,e._animationFrame=e._coreBrowserService.window.requestAnimationFrame((function(){e._renderCallback(),e._animationFrame=void 0}))}),600)}),t)}},{key:"pause",value:function(){this.isCursorVisible=!0,this._blinkInterval&&(this._coreBrowserService.window.clearInterval(this._blinkInterval),this._blinkInterval=void 0),this._blinkStartTimeout&&(this._coreBrowserService.window.clearTimeout(this._blinkStartTimeout),this._blinkStartTimeout=void 0),this._animationFrame&&(this._coreBrowserService.window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}},{key:"resume",value:function(){this.pause(),this._animationTimeRestarted=void 0,this._restartInterval(),this.restartBlinkAnimation()}}]),e}()},574:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.GridCache=void 0,t.GridCache=function(){function e(){l(this,e),this.cache=[]}return u(e,[{key:"resize",value:function(e,t){for(var i=0;i<e;i++){this.cache.length<=i&&this.cache.push([]);for(var r=this.cache[i].length;r<t;r++)this.cache[i].push(void 0);this.cache[i].length=t}this.cache.length=e}},{key:"clear",value:function(){for(var e=0;e<this.cache.length;e++)for(var t=0;t<this.cache[e].length;t++)this.cache[e][t]=void 0}}]),e}()},43:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.LinkRenderLayer=void 0;var r=i(903),n=i(237),s=i(197),c=function(e){h(i,e);var t=f(i);function i(e,r,n,s,o,a,c,u,h){var f;return l(this,i),(f=t.call(this,e,r,"link",n,!0,h,o,a,c,u)).register(s.onShowLinkUnderline((function(e){return f._handleShowLinkUnderline(e)}))),f.register(s.onHideLinkUnderline((function(e){return f._handleHideLinkUnderline(e)}))),f}return u(i,[{key:"resize",value:function(e){o(a(i.prototype),"resize",this).call(this,e),this._state=void 0}},{key:"reset",value:function(){this._clearCurrentLink()}},{key:"_clearCurrentLink",value:function(){if(this._state){this._clearCells(this._state.x1,this._state.y1,this._state.cols-this._state.x1,1);var e=this._state.y2-this._state.y1-1;e>0&&this._clearCells(0,this._state.y1+1,this._state.cols,e),this._clearCells(0,this._state.y2,this._state.x2,1),this._state=void 0}}},{key:"_handleShowLinkUnderline",value:function(e){if(e.fg===n.INVERTED_DEFAULT_COLOR?this._ctx.fillStyle=this._themeService.colors.background.css:e.fg&&(0,s.is256Color)(e.fg)?this._ctx.fillStyle=this._themeService.colors.ansi[e.fg].css:this._ctx.fillStyle=this._themeService.colors.foreground.css,e.y1===e.y2)this._fillBottomLineAtCells(e.x1,e.y1,e.x2-e.x1);else{this._fillBottomLineAtCells(e.x1,e.y1,e.cols-e.x1);for(var t=e.y1+1;t<e.y2;t++)this._fillBottomLineAtCells(0,t,e.cols);this._fillBottomLineAtCells(0,e.y2,e.x2)}this._state=e}},{key:"_handleHideLinkUnderline",value:function(e){this._clearCurrentLink()}}]),i}(r.BaseRenderLayer);t.LinkRenderLayer=c},630:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionRenderLayer=void 0;var r=function(e){h(i,e);var t=f(i);function i(e,r,n,s,o,a,c,u){var h;return l(this,i),(h=t.call(this,e,r,"selection",n,!0,u,s,c,a,o))._clearState(),h}return u(i,[{key:"_clearState",value:function(){this._state={start:void 0,end:void 0,columnSelectMode:void 0,ydisp:void 0}}},{key:"resize",value:function(e){o(a(i.prototype),"resize",this).call(this,e),this._selectionModel.selectionStart&&this._selectionModel.selectionEnd&&this._redrawSelection(this._selectionModel.selectionStart,this._selectionModel.selectionEnd,this._selectionModel.columnSelectMode)}},{key:"reset",value:function(){this._state.start&&this._state.end&&(this._clearState(),this._clearAll())}},{key:"handleBlur",value:function(){this.reset(),this._redrawSelection(this._selectionModel.selectionStart,this._selectionModel.selectionEnd,this._selectionModel.columnSelectMode)}},{key:"handleFocus",value:function(){this.reset(),this._redrawSelection(this._selectionModel.selectionStart,this._selectionModel.selectionEnd,this._selectionModel.columnSelectMode)}},{key:"handleSelectionChanged",value:function(e,t,r){o(a(i.prototype),"handleSelectionChanged",this).call(this,e,t,r),this._redrawSelection(e,t,r)}},{key:"_redrawSelection",value:function(e,t,i){if(this._didStateChange(e,t,i,this._bufferService.buffer.ydisp))if(this._clearAll(),e&&t){var r=e[1]-this._bufferService.buffer.ydisp,n=t[1]-this._bufferService.buffer.ydisp,s=Math.max(r,0),o=Math.min(n,this._bufferService.rows-1);if(s>=this._bufferService.rows||o<0)this._state.ydisp=this._bufferService.buffer.ydisp;else{if(this._ctx.fillStyle=(this._coreBrowserService.isFocused?this._themeService.colors.selectionBackgroundTransparent:this._themeService.colors.selectionInactiveBackgroundTransparent).css,i){var a=e[0],c=t[0]-a,l=o-s+1;this._fillCells(a,s,c,l)}else{var u=r===s?e[0]:0,h=s===n?t[0]:this._bufferService.cols;this._fillCells(u,s,h-u,1);var f=Math.max(o-s-1,0);if(this._fillCells(0,s+1,this._bufferService.cols,f),s!==o){var d=n===o?t[0]:this._bufferService.cols;this._fillCells(0,o,d,1)}}this._state.start=[e[0],e[1]],this._state.end=[t[0],t[1]],this._state.columnSelectMode=i,this._state.ydisp=this._bufferService.buffer.ydisp}}else this._clearState()}},{key:"_didStateChange",value:function(e,t,i,r){return!this._areCoordinatesEqual(e,this._state.start)||!this._areCoordinatesEqual(t,this._state.end)||i!==this._state.columnSelectMode||r!==this._state.ydisp}},{key:"_areCoordinatesEqual",value:function(e,t){return!(!e||!t)&&e[0]===t[0]&&e[1]===t[1]}}]),i}(i(903).BaseRenderLayer);t.SelectionRenderLayer=r},744:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.TextRenderLayer=void 0;var r=i(574),n=i(903),s=i(147),c=i(855),d=i(782),v=i(577),_=i(160),p=function(e){h(i,e);var t=f(i);function i(e,n,s,o,a,c,u,h,f,v){var _;return l(this,i),(_=t.call(this,e,n,"text",s,o,v,a,c,h,f))._characterJoinerService=u,_._characterWidth=0,_._characterFont="",_._characterOverlapCache={},_._workCell=new d.CellData,_._state=new r.GridCache,_.register(c.onSpecificOptionChange("allowTransparency",(function(e){return _._setTransparency(e)}))),_}return u(i,[{key:"resize",value:function(e){o(a(i.prototype),"resize",this).call(this,e);var t=this._getFont(!1,!1);this._characterWidth===e.device.char.width&&this._characterFont===t||(this._characterWidth=e.device.char.width,this._characterFont=t,this._characterOverlapCache={}),this._state.clear(),this._state.resize(this._bufferService.cols,this._bufferService.rows)}},{key:"reset",value:function(){this._state.clear(),this._clearAll()}},{key:"_forEachCell",value:function(e,t,i){for(var r=e;r<=t;r++)for(var n=r+this._bufferService.buffer.ydisp,s=this._bufferService.buffer.lines.get(n),o=this._characterJoinerService.getJoinedCharacters(n),a=0;a<this._bufferService.cols;a++){s.loadCell(a,this._workCell);var l=this._workCell,u=!1,h=a;if(0!==l.getWidth()){var f=l.getCode();if(0!==f&&32!==f){if(o.length>0&&a===o[0][0]){u=!0;var d=o.shift();l=new v.JoinedCellData(this._workCell,s.translateToString(!0,d[0],d[1]),d[1]-d[0]),h=d[1]-1}!u&&this._isOverlapping(l)&&h<s.length-1&&s.getCodePoint(h+1)===c.NULL_CELL_CODE&&(l.content&=-12582913,l.content|=2<<22),i(l,a,r),a=h}}}}},{key:"_drawBackground",value:function(e,t){var i=this,r=this._ctx,n=this._bufferService.cols,o=0,a=0,c=null;r.save(),this._forEachCell(e,t,(function(e,t,l){var u=null;e.isInverse()?u=e.isFgDefault()?i._themeService.colors.foreground.css:e.isFgRGB()?"rgb(".concat(s.AttributeData.toColorRGB(e.getFgColor()).join(","),")"):i._themeService.colors.ansi[e.getFgColor()].css:e.isBgRGB()?u="rgb(".concat(s.AttributeData.toColorRGB(e.getBgColor()).join(","),")"):e.isBgPalette()&&(u=i._themeService.colors.ansi[e.getBgColor()].css),u&&e.isDim()&&(u=_.color.multiplyOpacity(_.css.toColor(u),.5).css);var h=!1;i._decorationService.forEachDecorationAtCell(t,i._bufferService.buffer.ydisp+l,void 0,(function(e){"top"!==e.options.layer&&h||(e.backgroundColorRGB&&(u=e.backgroundColorRGB.css),h="top"===e.options.layer)})),null===c&&(o=t,a=l),l!==a?(r.fillStyle=c||"",i._fillCells(o,a,n-o,1),o=t,a=l):c!==u&&(r.fillStyle=c||"",i._fillCells(o,a,t-o,1),o=t,a=l),c=u})),null!==c&&(r.fillStyle=c,this._fillCells(o,a,n-o,1)),r.restore()}},{key:"_drawForeground",value:function(e,t){var i=this;this._forEachCell(e,t,(function(e,t,r){return i._drawChars(e,t,r)}))}},{key:"handleGridChanged",value:function(e,t){0!==this._state.cache.length&&(this._charAtlas&&this._charAtlas.beginFrame(),this._clearCells(0,e,this._bufferService.cols,t-e+1),this._drawBackground(e,t),this._drawForeground(e,t))}},{key:"_isOverlapping",value:function(e){if(1!==e.getWidth())return!1;if(e.getCode()<256)return!1;var t=e.getChars();if(this._characterOverlapCache.hasOwnProperty(t))return this._characterOverlapCache[t];this._ctx.save(),this._ctx.font=this._characterFont;var i=Math.floor(this._ctx.measureText(t).width)>this._characterWidth;return this._ctx.restore(),this._characterOverlapCache[t]=i,i}}]),i}(n.BaseRenderLayer);t.TextRenderLayer=p},503:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.removeElementFromParent=void 0,t.removeElementFromParent=function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];for(var n=0,s=i;n<s.length;n++){var o=s[n];null===(e=null==o?void 0:o.parentElement)||void 0===e||e.removeChild(o)}}},274:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.CellColorResolver=void 0;var i,r=0,n=0,s=!1,o=!1,a=!1;t.CellColorResolver=function(){function e(t,i,r,n,s){l(this,e),this._terminal=t,this._selectionRenderModel=i,this._decorationService=r,this._coreBrowserService=n,this._themeService=s,this.result={fg:0,bg:0,ext:0}}return u(e,[{key:"resolve",value:function(e,t,c){this.result.bg=e.bg,this.result.fg=e.fg,this.result.ext=268435456&e.bg?e.extended.ext:0,n=0,r=0,o=!1,s=!1,a=!1,i=this._themeService.colors,this._decorationService.forEachDecorationAtCell(t,c,"bottom",(function(e){e.backgroundColorRGB&&(n=e.backgroundColorRGB.rgba>>8&16777215,o=!0),e.foregroundColorRGB&&(r=e.foregroundColorRGB.rgba>>8&16777215,s=!0)})),(a=this._selectionRenderModel.isCellSelected(this._terminal,t,c))&&(n=(this._coreBrowserService.isFocused?i.selectionBackgroundOpaque:i.selectionInactiveBackgroundOpaque).rgba>>8&16777215,o=!0,i.selectionForeground&&(r=i.selectionForeground.rgba>>8&16777215,s=!0)),this._decorationService.forEachDecorationAtCell(t,c,"top",(function(e){e.backgroundColorRGB&&(n=e.backgroundColorRGB.rgba>>8&16777215,o=!0),e.foregroundColorRGB&&(r=e.foregroundColorRGB.rgba>>8&16777215,s=!0)})),o&&(n=a?-16777216&e.bg&-134217729|n|50331648:-16777216&e.bg|n|50331648),s&&(r=-16777216&e.fg&-67108865|r|50331648),67108864&this.result.fg&&(o&&!s&&(r=0==(50331648&this.result.bg)?-134217728&this.result.fg|16777215&i.background.rgba>>8|50331648:-134217728&this.result.fg|67108863&this.result.bg,s=!0),!o&&s&&(n=0==(50331648&this.result.fg)?-67108864&this.result.bg|16777215&i.foreground.rgba>>8|50331648:-67108864&this.result.bg|67108863&this.result.fg,o=!0)),i=void 0,this.result.bg=o?n:this.result.bg,this.result.fg=s?r:this.result.fg}}]),e}()},627:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.removeTerminalFromCache=t.acquireTextureAtlas=void 0;var r=i(509),n=i(197),s=[];t.acquireTextureAtlas=function(e,t,i,o,a,c,l,u){for(var h=(0,n.generateConfig)(o,a,c,l,t,i,u),f=0;f<s.length;f++){var d=s[f],v=d.ownedBy.indexOf(e);if(v>=0){if((0,n.configEquals)(d.config,h))return d.atlas;1===d.ownedBy.length?(d.atlas.dispose(),s.splice(f,1)):d.ownedBy.splice(v,1);break}}for(var _=0;_<s.length;_++){var p=s[_];if((0,n.configEquals)(p.config,h))return p.ownedBy.push(e),p.atlas}var g=e._core,m={atlas:new r.TextureAtlas(document,h,g.unicodeService),config:h,ownedBy:[e]};return s.push(m),m.atlas},t.removeTerminalFromCache=function(e){for(var t=0;t<s.length;t++){var i=s[t].ownedBy.indexOf(e);if(-1!==i){1===s[t].ownedBy.length?(s[t].atlas.dispose(),s.splice(t,1)):s[t].ownedBy.splice(i,1);break}}}},197:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.is256Color=t.configEquals=t.generateConfig=void 0;var r=i(160);t.generateConfig=function(e,t,i,n,s,o,a){var c={foreground:o.foreground,background:o.background,cursor:r.NULL_COLOR,cursorAccent:r.NULL_COLOR,selectionForeground:r.NULL_COLOR,selectionBackgroundTransparent:r.NULL_COLOR,selectionBackgroundOpaque:r.NULL_COLOR,selectionInactiveBackgroundTransparent:r.NULL_COLOR,selectionInactiveBackgroundOpaque:r.NULL_COLOR,ansi:o.ansi.slice(),contrastCache:o.contrastCache};return{customGlyphs:s.customGlyphs,devicePixelRatio:a,letterSpacing:s.letterSpacing,lineHeight:s.lineHeight,deviceCellWidth:e,deviceCellHeight:t,deviceCharWidth:i,deviceCharHeight:n,fontFamily:s.fontFamily,fontSize:s.fontSize,fontWeight:s.fontWeight,fontWeightBold:s.fontWeightBold,allowTransparency:s.allowTransparency,drawBoldTextInBrightColors:s.drawBoldTextInBrightColors,minimumContrastRatio:s.minimumContrastRatio,colors:c}},t.configEquals=function(e,t){for(var i=0;i<e.colors.ansi.length;i++)if(e.colors.ansi[i].rgba!==t.colors.ansi[i].rgba)return!1;return e.devicePixelRatio===t.devicePixelRatio&&e.customGlyphs===t.customGlyphs&&e.lineHeight===t.lineHeight&&e.letterSpacing===t.letterSpacing&&e.fontFamily===t.fontFamily&&e.fontSize===t.fontSize&&e.fontWeight===t.fontWeight&&e.fontWeightBold===t.fontWeightBold&&e.allowTransparency===t.allowTransparency&&e.deviceCharWidth===t.deviceCharWidth&&e.deviceCharHeight===t.deviceCharHeight&&e.drawBoldTextInBrightColors===t.drawBoldTextInBrightColors&&e.minimumContrastRatio===t.minimumContrastRatio&&e.colors.foreground.rgba===t.colors.foreground.rgba&&e.colors.background.rgba===t.colors.background.rgba},t.is256Color=function(e){return 16777216==(50331648&e)||33554432==(50331648&e)}},237:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.TEXT_BASELINE=t.DIM_OPACITY=t.INVERTED_DEFAULT_COLOR=void 0;var r=i(399);t.INVERTED_DEFAULT_COLOR=257,t.DIM_OPACITY=.5,t.TEXT_BASELINE=r.isFirefox||r.isLegacyEdge?"bottom":"ideographic"},860:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.tryDrawCustomChar=t.powerlineDefinitions=t.boxDrawingDefinitions=t.blockElementDefinitions=void 0;var r=i(374);t.blockElementDefinitions={"\u2580":[{x:0,y:0,w:8,h:4}],"\u2581":[{x:0,y:7,w:8,h:1}],"\u2582":[{x:0,y:6,w:8,h:2}],"\u2583":[{x:0,y:5,w:8,h:3}],"\u2584":[{x:0,y:4,w:8,h:4}],"\u2585":[{x:0,y:3,w:8,h:5}],"\u2586":[{x:0,y:2,w:8,h:6}],"\u2587":[{x:0,y:1,w:8,h:7}],"\u2588":[{x:0,y:0,w:8,h:8}],"\u2589":[{x:0,y:0,w:7,h:8}],"\u258a":[{x:0,y:0,w:6,h:8}],"\u258b":[{x:0,y:0,w:5,h:8}],"\u258c":[{x:0,y:0,w:4,h:8}],"\u258d":[{x:0,y:0,w:3,h:8}],"\u258e":[{x:0,y:0,w:2,h:8}],"\u258f":[{x:0,y:0,w:1,h:8}],"\u2590":[{x:4,y:0,w:4,h:8}],"\u2594":[{x:0,y:0,w:8,h:1}],"\u2595":[{x:7,y:0,w:1,h:8}],"\u2596":[{x:0,y:4,w:4,h:4}],"\u2597":[{x:4,y:4,w:4,h:4}],"\u2598":[{x:0,y:0,w:4,h:4}],"\u2599":[{x:0,y:0,w:4,h:8},{x:0,y:4,w:8,h:4}],"\u259a":[{x:0,y:0,w:4,h:4},{x:4,y:4,w:4,h:4}],"\u259b":[{x:0,y:0,w:4,h:8},{x:4,y:0,w:4,h:4}],"\u259c":[{x:0,y:0,w:8,h:4},{x:4,y:0,w:4,h:8}],"\u259d":[{x:4,y:0,w:4,h:4}],"\u259e":[{x:4,y:0,w:4,h:4},{x:0,y:4,w:4,h:4}],"\u259f":[{x:4,y:0,w:4,h:8},{x:0,y:4,w:8,h:4}],"\ud83e\udf70":[{x:1,y:0,w:1,h:8}],"\ud83e\udf71":[{x:2,y:0,w:1,h:8}],"\ud83e\udf72":[{x:3,y:0,w:1,h:8}],"\ud83e\udf73":[{x:4,y:0,w:1,h:8}],"\ud83e\udf74":[{x:5,y:0,w:1,h:8}],"\ud83e\udf75":[{x:6,y:0,w:1,h:8}],"\ud83e\udf76":[{x:0,y:1,w:8,h:1}],"\ud83e\udf77":[{x:0,y:2,w:8,h:1}],"\ud83e\udf78":[{x:0,y:3,w:8,h:1}],"\ud83e\udf79":[{x:0,y:4,w:8,h:1}],"\ud83e\udf7a":[{x:0,y:5,w:8,h:1}],"\ud83e\udf7b":[{x:0,y:6,w:8,h:1}],"\ud83e\udf7c":[{x:0,y:0,w:1,h:8},{x:0,y:7,w:8,h:1}],"\ud83e\udf7d":[{x:0,y:0,w:1,h:8},{x:0,y:0,w:8,h:1}],"\ud83e\udf7e":[{x:7,y:0,w:1,h:8},{x:0,y:0,w:8,h:1}],"\ud83e\udf7f":[{x:7,y:0,w:1,h:8},{x:0,y:7,w:8,h:1}],"\ud83e\udf80":[{x:0,y:0,w:8,h:1},{x:0,y:7,w:8,h:1}],"\ud83e\udf81":[{x:0,y:0,w:8,h:1},{x:0,y:2,w:8,h:1},{x:0,y:4,w:8,h:1},{x:0,y:7,w:8,h:1}],"\ud83e\udf82":[{x:0,y:0,w:8,h:2}],"\ud83e\udf83":[{x:0,y:0,w:8,h:3}],"\ud83e\udf84":[{x:0,y:0,w:8,h:5}],"\ud83e\udf85":[{x:0,y:0,w:8,h:6}],"\ud83e\udf86":[{x:0,y:0,w:8,h:7}],"\ud83e\udf87":[{x:6,y:0,w:2,h:8}],"\ud83e\udf88":[{x:5,y:0,w:3,h:8}],"\ud83e\udf89":[{x:3,y:0,w:5,h:8}],"\ud83e\udf8a":[{x:2,y:0,w:6,h:8}],"\ud83e\udf8b":[{x:1,y:0,w:7,h:8}],"\ud83e\udf95":[{x:0,y:0,w:2,h:2},{x:4,y:0,w:2,h:2},{x:2,y:2,w:2,h:2},{x:6,y:2,w:2,h:2},{x:0,y:4,w:2,h:2},{x:4,y:4,w:2,h:2},{x:2,y:6,w:2,h:2},{x:6,y:6,w:2,h:2}],"\ud83e\udf96":[{x:2,y:0,w:2,h:2},{x:6,y:0,w:2,h:2},{x:0,y:2,w:2,h:2},{x:4,y:2,w:2,h:2},{x:2,y:4,w:2,h:2},{x:6,y:4,w:2,h:2},{x:0,y:6,w:2,h:2},{x:4,y:6,w:2,h:2}],"\ud83e\udf97":[{x:0,y:2,w:8,h:2},{x:0,y:6,w:8,h:2}]};var s={"\u2591":[[1,0,0,0],[0,0,0,0],[0,0,1,0],[0,0,0,0]],"\u2592":[[1,0],[0,0],[0,1],[0,0]],"\u2593":[[0,1],[1,1],[1,0],[1,1]]};t.boxDrawingDefinitions={"\u2500":{1:"M0,.5 L1,.5"},"\u2501":{3:"M0,.5 L1,.5"},"\u2502":{1:"M.5,0 L.5,1"},"\u2503":{3:"M.5,0 L.5,1"},"\u250c":{1:"M0.5,1 L.5,.5 L1,.5"},"\u250f":{3:"M0.5,1 L.5,.5 L1,.5"},"\u2510":{1:"M0,.5 L.5,.5 L.5,1"},"\u2513":{3:"M0,.5 L.5,.5 L.5,1"},"\u2514":{1:"M.5,0 L.5,.5 L1,.5"},"\u2517":{3:"M.5,0 L.5,.5 L1,.5"},"\u2518":{1:"M.5,0 L.5,.5 L0,.5"},"\u251b":{3:"M.5,0 L.5,.5 L0,.5"},"\u251c":{1:"M.5,0 L.5,1 M.5,.5 L1,.5"},"\u2523":{3:"M.5,0 L.5,1 M.5,.5 L1,.5"},"\u2524":{1:"M.5,0 L.5,1 M.5,.5 L0,.5"},"\u252b":{3:"M.5,0 L.5,1 M.5,.5 L0,.5"},"\u252c":{1:"M0,.5 L1,.5 M.5,.5 L.5,1"},"\u2533":{3:"M0,.5 L1,.5 M.5,.5 L.5,1"},"\u2534":{1:"M0,.5 L1,.5 M.5,.5 L.5,0"},"\u253b":{3:"M0,.5 L1,.5 M.5,.5 L.5,0"},"\u253c":{1:"M0,.5 L1,.5 M.5,0 L.5,1"},"\u254b":{3:"M0,.5 L1,.5 M.5,0 L.5,1"},"\u2574":{1:"M.5,.5 L0,.5"},"\u2578":{3:"M.5,.5 L0,.5"},"\u2575":{1:"M.5,.5 L.5,0"},"\u2579":{3:"M.5,.5 L.5,0"},"\u2576":{1:"M.5,.5 L1,.5"},"\u257a":{3:"M.5,.5 L1,.5"},"\u2577":{1:"M.5,.5 L.5,1"},"\u257b":{3:"M.5,.5 L.5,1"},"\u2550":{1:function(e,t){return"M0,".concat(.5-t," L1,").concat(.5-t," M0,").concat(.5+t," L1,").concat(.5+t)}},"\u2551":{1:function(e,t){return"M".concat(.5-e,",0 L").concat(.5-e,",1 M").concat(.5+e,",0 L").concat(.5+e,",1")}},"\u2552":{1:function(e,t){return"M.5,1 L.5,".concat(.5-t," L1,").concat(.5-t," M.5,").concat(.5+t," L1,").concat(.5+t)}},"\u2553":{1:function(e,t){return"M".concat(.5-e,",1 L").concat(.5-e,",.5 L1,.5 M").concat(.5+e,",.5 L").concat(.5+e,",1")}},"\u2554":{1:function(e,t){return"M1,".concat(.5-t," L").concat(.5-e,",").concat(.5-t," L").concat(.5-e,",1 M1,").concat(.5+t," L").concat(.5+e,",").concat(.5+t," L").concat(.5+e,",1")}},"\u2555":{1:function(e,t){return"M0,".concat(.5-t," L.5,").concat(.5-t," L.5,1 M0,").concat(.5+t," L.5,").concat(.5+t)}},"\u2556":{1:function(e,t){return"M".concat(.5+e,",1 L").concat(.5+e,",.5 L0,.5 M").concat(.5-e,",.5 L").concat(.5-e,",1")}},"\u2557":{1:function(e,t){return"M0,".concat(.5+t," L").concat(.5-e,",").concat(.5+t," L").concat(.5-e,",1 M0,").concat(.5-t," L").concat(.5+e,",").concat(.5-t," L").concat(.5+e,",1")}},"\u2558":{1:function(e,t){return"M.5,0 L.5,".concat(.5+t," L1,").concat(.5+t," M.5,").concat(.5-t," L1,").concat(.5-t)}},"\u2559":{1:function(e,t){return"M1,.5 L".concat(.5-e,",.5 L").concat(.5-e,",0 M").concat(.5+e,",.5 L").concat(.5+e,",0")}},"\u255a":{1:function(e,t){return"M1,".concat(.5-t," L").concat(.5+e,",").concat(.5-t," L").concat(.5+e,",0 M1,").concat(.5+t," L").concat(.5-e,",").concat(.5+t," L").concat(.5-e,",0")}},"\u255b":{1:function(e,t){return"M0,".concat(.5+t," L.5,").concat(.5+t," L.5,0 M0,").concat(.5-t," L.5,").concat(.5-t)}},"\u255c":{1:function(e,t){return"M0,.5 L".concat(.5+e,",.5 L").concat(.5+e,",0 M").concat(.5-e,",.5 L").concat(.5-e,",0")}},"\u255d":{1:function(e,t){return"M0,".concat(.5-t," L").concat(.5-e,",").concat(.5-t," L").concat(.5-e,",0 M0,").concat(.5+t," L").concat(.5+e,",").concat(.5+t," L").concat(.5+e,",0")}},"\u255e":{1:function(e,t){return"M.5,0 L.5,1 M.5,".concat(.5-t," L1,").concat(.5-t," M.5,").concat(.5+t," L1,").concat(.5+t)}},"\u255f":{1:function(e,t){return"M".concat(.5-e,",0 L").concat(.5-e,",1 M").concat(.5+e,",0 L").concat(.5+e,",1 M").concat(.5+e,",.5 L1,.5")}},"\u2560":{1:function(e,t){return"M".concat(.5-e,",0 L").concat(.5-e,",1 M1,").concat(.5+t," L").concat(.5+e,",").concat(.5+t," L").concat(.5+e,",1 M1,").concat(.5-t," L").concat(.5+e,",").concat(.5-t," L").concat(.5+e,",0")}},"\u2561":{1:function(e,t){return"M.5,0 L.5,1 M0,".concat(.5-t," L.5,").concat(.5-t," M0,").concat(.5+t," L.5,").concat(.5+t)}},"\u2562":{1:function(e,t){return"M0,.5 L".concat(.5-e,",.5 M").concat(.5-e,",0 L").concat(.5-e,",1 M").concat(.5+e,",0 L").concat(.5+e,",1")}},"\u2563":{1:function(e,t){return"M".concat(.5+e,",0 L").concat(.5+e,",1 M0,").concat(.5+t," L").concat(.5-e,",").concat(.5+t," L").concat(.5-e,",1 M0,").concat(.5-t," L").concat(.5-e,",").concat(.5-t," L").concat(.5-e,",0")}},"\u2564":{1:function(e,t){return"M0,".concat(.5-t," L1,").concat(.5-t," M0,").concat(.5+t," L1,").concat(.5+t," M.5,").concat(.5+t," L.5,1")}},"\u2565":{1:function(e,t){return"M0,.5 L1,.5 M".concat(.5-e,",.5 L").concat(.5-e,",1 M").concat(.5+e,",.5 L").concat(.5+e,",1")}},"\u2566":{1:function(e,t){return"M0,".concat(.5-t," L1,").concat(.5-t," M0,").concat(.5+t," L").concat(.5-e,",").concat(.5+t," L").concat(.5-e,",1 M1,").concat(.5+t," L").concat(.5+e,",").concat(.5+t," L").concat(.5+e,",1")}},"\u2567":{1:function(e,t){return"M.5,0 L.5,".concat(.5-t," M0,").concat(.5-t," L1,").concat(.5-t," M0,").concat(.5+t," L1,").concat(.5+t)}},"\u2568":{1:function(e,t){return"M0,.5 L1,.5 M".concat(.5-e,",.5 L").concat(.5-e,",0 M").concat(.5+e,",.5 L").concat(.5+e,",0")}},"\u2569":{1:function(e,t){return"M0,".concat(.5+t," L1,").concat(.5+t," M0,").concat(.5-t," L").concat(.5-e,",").concat(.5-t," L").concat(.5-e,",0 M1,").concat(.5-t," L").concat(.5+e,",").concat(.5-t," L").concat(.5+e,",0")}},"\u256a":{1:function(e,t){return"M.5,0 L.5,1 M0,".concat(.5-t," L1,").concat(.5-t," M0,").concat(.5+t," L1,").concat(.5+t)}},"\u256b":{1:function(e,t){return"M0,.5 L1,.5 M".concat(.5-e,",0 L").concat(.5-e,",1 M").concat(.5+e,",0 L").concat(.5+e,",1")}},"\u256c":{1:function(e,t){return"M0,".concat(.5+t," L").concat(.5-e,",").concat(.5+t," L").concat(.5-e,",1 M1,").concat(.5+t," L").concat(.5+e,",").concat(.5+t," L").concat(.5+e,",1 M0,").concat(.5-t," L").concat(.5-e,",").concat(.5-t," L").concat(.5-e,",0 M1,").concat(.5-t," L").concat(.5+e,",").concat(.5-t," L").concat(.5+e,",0")}},"\u2571":{1:"M1,0 L0,1"},"\u2572":{1:"M0,0 L1,1"},"\u2573":{1:"M1,0 L0,1 M0,0 L1,1"},"\u257c":{1:"M.5,.5 L0,.5",3:"M.5,.5 L1,.5"},"\u257d":{1:"M.5,.5 L.5,0",3:"M.5,.5 L.5,1"},"\u257e":{1:"M.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"\u257f":{1:"M.5,.5 L.5,1",3:"M.5,.5 L.5,0"},"\u250d":{1:"M.5,.5 L.5,1",3:"M.5,.5 L1,.5"},"\u250e":{1:"M.5,.5 L1,.5",3:"M.5,.5 L.5,1"},"\u2511":{1:"M.5,.5 L.5,1",3:"M.5,.5 L0,.5"},"\u2512":{1:"M.5,.5 L0,.5",3:"M.5,.5 L.5,1"},"\u2515":{1:"M.5,.5 L.5,0",3:"M.5,.5 L1,.5"},"\u2516":{1:"M.5,.5 L1,.5",3:"M.5,.5 L.5,0"},"\u2519":{1:"M.5,.5 L.5,0",3:"M.5,.5 L0,.5"},"\u251a":{1:"M.5,.5 L0,.5",3:"M.5,.5 L.5,0"},"\u251d":{1:"M.5,0 L.5,1",3:"M.5,.5 L1,.5"},"\u251e":{1:"M0.5,1 L.5,.5 L1,.5",3:"M.5,.5 L.5,0"},"\u251f":{1:"M.5,0 L.5,.5 L1,.5",3:"M.5,.5 L.5,1"},"\u2520":{1:"M.5,.5 L1,.5",3:"M.5,0 L.5,1"},"\u2521":{1:"M.5,.5 L.5,1",3:"M.5,0 L.5,.5 L1,.5"},"\u2522":{1:"M.5,.5 L.5,0",3:"M0.5,1 L.5,.5 L1,.5"},"\u2525":{1:"M.5,0 L.5,1",3:"M.5,.5 L0,.5"},"\u2526":{1:"M0,.5 L.5,.5 L.5,1",3:"M.5,.5 L.5,0"},"\u2527":{1:"M.5,0 L.5,.5 L0,.5",3:"M.5,.5 L.5,1"},"\u2528":{1:"M.5,.5 L0,.5",3:"M.5,0 L.5,1"},"\u2529":{1:"M.5,.5 L.5,1",3:"M.5,0 L.5,.5 L0,.5"},"\u252a":{1:"M.5,.5 L.5,0",3:"M0,.5 L.5,.5 L.5,1"},"\u252d":{1:"M0.5,1 L.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"\u252e":{1:"M0,.5 L.5,.5 L.5,1",3:"M.5,.5 L1,.5"},"\u252f":{1:"M.5,.5 L.5,1",3:"M0,.5 L1,.5"},"\u2530":{1:"M0,.5 L1,.5",3:"M.5,.5 L.5,1"},"\u2531":{1:"M.5,.5 L1,.5",3:"M0,.5 L.5,.5 L.5,1"},"\u2532":{1:"M.5,.5 L0,.5",3:"M0.5,1 L.5,.5 L1,.5"},"\u2535":{1:"M.5,0 L.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"\u2536":{1:"M.5,0 L.5,.5 L0,.5",3:"M.5,.5 L1,.5"},"\u2537":{1:"M.5,.5 L.5,0",3:"M0,.5 L1,.5"},"\u2538":{1:"M0,.5 L1,.5",3:"M.5,.5 L.5,0"},"\u2539":{1:"M.5,.5 L1,.5",3:"M.5,0 L.5,.5 L0,.5"},"\u253a":{1:"M.5,.5 L0,.5",3:"M.5,0 L.5,.5 L1,.5"},"\u253d":{1:"M.5,0 L.5,1 M.5,.5 L1,.5",3:"M.5,.5 L0,.5"},"\u253e":{1:"M.5,0 L.5,1 M.5,.5 L0,.5",3:"M.5,.5 L1,.5"},"\u253f":{1:"M.5,0 L.5,1",3:"M0,.5 L1,.5"},"\u2540":{1:"M0,.5 L1,.5 M.5,.5 L.5,1",3:"M.5,.5 L.5,0"},"\u2541":{1:"M.5,.5 L.5,0 M0,.5 L1,.5",3:"M.5,.5 L.5,1"},"\u2542":{1:"M0,.5 L1,.5",3:"M.5,0 L.5,1"},"\u2543":{1:"M0.5,1 L.5,.5 L1,.5",3:"M.5,0 L.5,.5 L0,.5"},"\u2544":{1:"M0,.5 L.5,.5 L.5,1",3:"M.5,0 L.5,.5 L1,.5"},"\u2545":{1:"M.5,0 L.5,.5 L1,.5",3:"M0,.5 L.5,.5 L.5,1"},"\u2546":{1:"M.5,0 L.5,.5 L0,.5",3:"M0.5,1 L.5,.5 L1,.5"},"\u2547":{1:"M.5,.5 L.5,1",3:"M.5,.5 L.5,0 M0,.5 L1,.5"},"\u2548":{1:"M.5,.5 L.5,0",3:"M0,.5 L1,.5 M.5,.5 L.5,1"},"\u2549":{1:"M.5,.5 L1,.5",3:"M.5,0 L.5,1 M.5,.5 L0,.5"},"\u254a":{1:"M.5,.5 L0,.5",3:"M.5,0 L.5,1 M.5,.5 L1,.5"},"\u254c":{1:"M.1,.5 L.4,.5 M.6,.5 L.9,.5"},"\u254d":{3:"M.1,.5 L.4,.5 M.6,.5 L.9,.5"},"\u2504":{1:"M.0667,.5 L.2667,.5 M.4,.5 L.6,.5 M.7333,.5 L.9333,.5"},"\u2505":{3:"M.0667,.5 L.2667,.5 M.4,.5 L.6,.5 M.7333,.5 L.9333,.5"},"\u2508":{1:"M.05,.5 L.2,.5 M.3,.5 L.45,.5 M.55,.5 L.7,.5 M.8,.5 L.95,.5"},"\u2509":{3:"M.05,.5 L.2,.5 M.3,.5 L.45,.5 M.55,.5 L.7,.5 M.8,.5 L.95,.5"},"\u254e":{1:"M.5,.1 L.5,.4 M.5,.6 L.5,.9"},"\u254f":{3:"M.5,.1 L.5,.4 M.5,.6 L.5,.9"},"\u2506":{1:"M.5,.0667 L.5,.2667 M.5,.4 L.5,.6 M.5,.7333 L.5,.9333"},"\u2507":{3:"M.5,.0667 L.5,.2667 M.5,.4 L.5,.6 M.5,.7333 L.5,.9333"},"\u250a":{1:"M.5,.05 L.5,.2 M.5,.3 L.5,.45 L.5,.55 M.5,.7 L.5,.95"},"\u250b":{3:"M.5,.05 L.5,.2 M.5,.3 L.5,.45 L.5,.55 M.5,.7 L.5,.95"},"\u256d":{1:function(e,t){return"M.5,1 L.5,".concat(.5+t/.15*.5," C.5,").concat(.5+t/.15*.5,",.5,.5,1,.5")}},"\u256e":{1:function(e,t){return"M.5,1 L.5,".concat(.5+t/.15*.5," C.5,").concat(.5+t/.15*.5,",.5,.5,0,.5")}},"\u256f":{1:function(e,t){return"M.5,0 L.5,".concat(.5-t/.15*.5," C.5,").concat(.5-t/.15*.5,",.5,.5,0,.5")}},"\u2570":{1:function(e,t){return"M.5,0 L.5,".concat(.5-t/.15*.5," C.5,").concat(.5-t/.15*.5,",.5,.5,1,.5")}}},t.powerlineDefinitions={"\ue0b0":{d:"M0,0 L1,.5 L0,1",type:0,rightPadding:2},"\ue0b1":{d:"M-1,-.5 L1,.5 L-1,1.5",type:1,leftPadding:1,rightPadding:1},"\ue0b2":{d:"M1,0 L0,.5 L1,1",type:0,leftPadding:2},"\ue0b3":{d:"M2,-.5 L0,.5 L2,1.5",type:1,leftPadding:1,rightPadding:1},"\ue0b4":{d:"M0,0 L0,1 C0.552,1,1,0.776,1,.5 C1,0.224,0.552,0,0,0",type:0,rightPadding:1},"\ue0b5":{d:"M0,1 C0.552,1,1,0.776,1,.5 C1,0.224,0.552,0,0,0",type:1,rightPadding:1},"\ue0b6":{d:"M1,0 L1,1 C0.448,1,0,0.776,0,.5 C0,0.224,0.448,0,1,0",type:0,leftPadding:1},"\ue0b7":{d:"M1,1 C0.448,1,0,0.776,0,.5 C0,0.224,0.448,0,1,0",type:1,leftPadding:1},"\ue0b8":{d:"M-.5,-.5 L1.5,1.5 L-.5,1.5",type:0},"\ue0b9":{d:"M-.5,-.5 L1.5,1.5",type:1,leftPadding:1,rightPadding:1},"\ue0ba":{d:"M1.5,-.5 L-.5,1.5 L1.5,1.5",type:0},"\ue0bc":{d:"M1.5,-.5 L-.5,1.5 L-.5,-.5",type:0},"\ue0bd":{d:"M1.5,-.5 L-.5,1.5",type:1,leftPadding:1,rightPadding:1},"\ue0be":{d:"M-.5,-.5 L1.5,1.5 L1.5,-.5",type:0}},t.powerlineDefinitions["\ue0bb"]=t.powerlineDefinitions["\ue0b9"],t.powerlineDefinitions["\ue0bf"]=t.powerlineDefinitions["\ue0bd"],t.tryDrawCustomChar=function(e,i,a,h,f,d,v,_){var p=t.blockElementDefinitions[i];if(p)return function(e,t,i,r,n,s){for(var o=0;o<t.length;o++){var a=t[o],c=n/8,l=s/8;e.fillRect(i+a.x*c,r+a.y*l,a.w*c,a.h*l)}}(e,p,a,h,f,d),!0;var g=s[i];if(g)return function(e,t,i,s,a,c){var l=o.get(t);l||(l=new Map,o.set(t,l));var u=e.fillStyle;if("string"!=typeof u)throw new Error('Unexpected fillStyle type "'.concat(u,'"'));var h=l.get(u);if(!h){var f=t[0].length,d=t.length,v=document.createElement("canvas");v.width=f,v.height=d;var _,p,g,m,y=(0,r.throwIfFalsy)(v.getContext("2d")),b=new ImageData(f,d);if(u.startsWith("#"))_=parseInt(u.slice(1,3),16),p=parseInt(u.slice(3,5),16),g=parseInt(u.slice(5,7),16),m=u.length>7&&parseInt(u.slice(7,9),16)||1;else{if(!u.startsWith("rgba"))throw new Error('Unexpected fillStyle color format "'.concat(u,'" when drawing pattern glyph'));var C=u.substring(5,u.length-1).split(",").map((function(e){return parseFloat(e)})),S=n(C,4);_=S[0],p=S[1],g=S[2],m=S[3]}for(var w=0;w<d;w++)for(var k=0;k<f;k++)b.data[4*(w*f+k)]=_,b.data[4*(w*f+k)+1]=p,b.data[4*(w*f+k)+2]=g,b.data[4*(w*f+k)+3]=t[w][k]*(255*m);y.putImageData(b,0,0),h=(0,r.throwIfFalsy)(e.createPattern(v,null)),l.set(u,h)}e.fillStyle=h,e.fillRect(i,s,a,c)}(e,g,a,h,f,d),!0;var m=t.boxDrawingDefinitions[i];if(m)return function(e,t,i,r,s,o,a){e.strokeStyle=e.fillStyle;for(var h=0,f=Object.entries(t);h<f.length;h++){var d=n(f[h],2),v=d[0],_=d[1],p=void 0;e.beginPath(),e.lineWidth=a*Number.parseInt(v),p="function"==typeof _?_(.15,.15/o*s):_;var g,m=c(p.split(" "));try{for(m.s();!(g=m.n()).done;){var y=g.value,b=y[0],C=l[b];if(C){var S=y.substring(1).split(",");S[0]&&S[1]&&C(e,u(S,s,o,i,r,!0,a))}else console.error('Could not find drawing instructions for "'.concat(b,'"'))}}catch(w){m.e(w)}finally{m.f()}e.stroke(),e.closePath()}}(e,m,a,h,f,d,_),!0;var y=t.powerlineDefinitions[i];return!!y&&(function(e,t,i,r,n,s,o,a){var h,f,d=new Path2D;d.rect(i,r,n,s),e.clip(d),e.beginPath();var v=o/12;e.lineWidth=a*v;var _,p=c(t.d.split(" "));try{for(p.s();!(_=p.n()).done;){var g=_.value,m=g[0],y=l[m];if(y){var b=g.substring(1).split(",");b[0]&&b[1]&&y(e,u(b,n,s,i,r,!1,a,(null!==(h=t.leftPadding)&&void 0!==h?h:0)*(v/2),(null!==(f=t.rightPadding)&&void 0!==f?f:0)*(v/2)))}else console.error('Could not find drawing instructions for "'.concat(m,'"'))}}catch(C){p.e(C)}finally{p.f()}1===t.type?(e.strokeStyle=e.fillStyle,e.stroke()):e.fill(),e.closePath()}(e,y,a,h,f,d,v,_),!0)};var o=new Map;function a(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return Math.max(Math.min(e,t),i)}var l={C:function(e,t){return e.bezierCurveTo(t[0],t[1],t[2],t[3],t[4],t[5])},L:function(e,t){return e.lineTo(t[0],t[1])},M:function(e,t){return e.moveTo(t[0],t[1])}};function u(e,t,i,r,n,s,o){var c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:0,l=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0,u=e.map((function(e){return parseFloat(e)||parseInt(e)}));if(u.length<2)throw new Error("Too few arguments for instruction");for(var h=0;h<u.length;h+=2)u[h]*=t-c*o-l*o,s&&0!==u[h]&&(u[h]=a(Math.round(u[h]+.5)-.5,t,0)),u[h]+=r+c*o;for(var f=1;f<u.length;f+=2)u[f]*=i,s&&0!==u[f]&&(u[f]=a(Math.round(u[f]+.5)-.5,i,0)),u[f]+=n;return u}},56:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.observeDevicePixelDimensions=void 0;var r=i(859);t.observeDevicePixelDimensions=function(e,t,i){var n=new t.ResizeObserver((function(t){var r=t.find((function(t){return t.target===e}));if(r){if(!("devicePixelContentBoxSize"in r))return null==n||n.disconnect(),void(n=void 0);var s=r.devicePixelContentBoxSize[0].inlineSize,o=r.devicePixelContentBoxSize[0].blockSize;s>0&&o>0&&i(s,o)}}));try{n.observe(e,{box:["device-pixel-content-box"]})}catch(e){n.disconnect(),n=void 0}return(0,r.toDisposable)((function(){return null==n?void 0:n.disconnect()}))}},374:function(e,t){function i(e){return 57508<=e&&e<=57558}Object.defineProperty(t,"__esModule",{value:!0}),t.createRenderDimensions=t.excludeFromContrastRatioDemands=t.isRestrictedPowerlineGlyph=t.isPowerlineGlyph=t.throwIfFalsy=void 0,t.throwIfFalsy=function(e){if(!e)throw new Error("value must not be falsy");return e},t.isPowerlineGlyph=i,t.isRestrictedPowerlineGlyph=function(e){return 57520<=e&&e<=57527},t.excludeFromContrastRatioDemands=function(e){return i(e)||function(e){return 9472<=e&&e<=9631}(e)},t.createRenderDimensions=function(){return{css:{canvas:{width:0,height:0},cell:{width:0,height:0}},device:{canvas:{width:0,height:0},cell:{width:0,height:0},char:{width:0,height:0,left:0,top:0}}}}},296:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.createSelectionRenderModel=void 0;var i=function(){function e(){l(this,e),this.clear()}return u(e,[{key:"clear",value:function(){this.hasSelection=!1,this.columnSelectMode=!1,this.viewportStartRow=0,this.viewportEndRow=0,this.viewportCappedStartRow=0,this.viewportCappedEndRow=0,this.startCol=0,this.endCol=0,this.selectionStart=void 0,this.selectionEnd=void 0}},{key:"update",value:function(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(this.selectionStart=t,this.selectionEnd=i,t&&i&&(t[0]!==i[0]||t[1]!==i[1])){var n=t[1]-e.buffer.active.viewportY,s=i[1]-e.buffer.active.viewportY,o=Math.max(n,0),a=Math.min(s,e.rows-1);o>=e.rows||a<0?this.clear():(this.hasSelection=!0,this.columnSelectMode=r,this.viewportStartRow=n,this.viewportEndRow=s,this.viewportCappedStartRow=o,this.viewportCappedEndRow=a,this.startCol=t[0],this.endCol=i[0])}else this.clear()}},{key:"isCellSelected",value:function(e,t,i){return!!this.hasSelection&&(i-=e.buffer.active.viewportY,this.columnSelectMode?this.startCol<=this.endCol?t>=this.startCol&&i>=this.viewportCappedStartRow&&t<this.endCol&&i<=this.viewportCappedEndRow:t<this.startCol&&i>=this.viewportCappedStartRow&&t>=this.endCol&&i<=this.viewportCappedEndRow:i>this.viewportStartRow&&i<this.viewportEndRow||this.viewportStartRow===this.viewportEndRow&&i===this.viewportStartRow&&t>=this.startCol&&t<this.endCol||this.viewportStartRow<this.viewportEndRow&&i===this.viewportEndRow&&t<this.endCol||this.viewportStartRow<this.viewportEndRow&&i===this.viewportStartRow&&t>=this.startCol)}}]),e}();t.createSelectionRenderModel=function(){return new i}},509:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.TextureAtlas=void 0;var s,o=i(237),a=i(855),h=i(147),f=i(160),d=i(860),v=i(374),_=i(485),p=i(385),g=i(345),m={texturePage:0,texturePosition:{x:0,y:0},texturePositionClipSpace:{x:0,y:0},offset:{x:0,y:0},size:{x:0,y:0},sizeClipSpace:{x:0,y:0}},y=function(){function e(t,i,r){l(this,e),this._document=t,this._config=i,this._unicodeService=r,this._didWarmUp=!1,this._cacheMap=new _.FourKeyMap,this._cacheMapCombined=new _.FourKeyMap,this._pages=[],this._activePages=[],this._workBoundingBox={top:0,left:0,bottom:0,right:0},this._workAttributeData=new h.AttributeData,this._textureSize=512,this._onAddTextureAtlasCanvas=new g.EventEmitter,this.onAddTextureAtlasCanvas=this._onAddTextureAtlasCanvas.event,this._onRemoveTextureAtlasCanvas=new g.EventEmitter,this.onRemoveTextureAtlasCanvas=this._onRemoveTextureAtlasCanvas.event,this._requestClearModel=!1,this._createNewPage(),this._tmpCanvas=S(t,4*this._config.deviceCellWidth+4,this._config.deviceCellHeight+4),this._tmpCtx=(0,v.throwIfFalsy)(this._tmpCanvas.getContext("2d",{alpha:this._config.allowTransparency,willReadFrequently:!0}))}return u(e,[{key:"pages",get:function(){return this._pages}},{key:"dispose",value:function(){var e,t=c(this.pages);try{for(t.s();!(e=t.n()).done;)e.value.canvas.remove()}catch(i){t.e(i)}finally{t.f()}this._onAddTextureAtlasCanvas.dispose()}},{key:"warmUp",value:function(){this._didWarmUp||(this._doWarmUp(),this._didWarmUp=!0)}},{key:"_doWarmUp",value:function(){for(var e=this,t=new p.IdleTaskQueue,i=function(i){t.enqueue((function(){if(!e._cacheMap.get(i,a.DEFAULT_COLOR,a.DEFAULT_COLOR,a.DEFAULT_EXT)){var t=e._drawToCache(i,a.DEFAULT_COLOR,a.DEFAULT_COLOR,a.DEFAULT_EXT);e._cacheMap.set(i,a.DEFAULT_COLOR,a.DEFAULT_COLOR,a.DEFAULT_EXT,t)}}))},r=33;r<126;r++)i(r)}},{key:"beginFrame",value:function(){return this._requestClearModel}},{key:"clearTexture",value:function(){if(0!==this._pages[0].currentRow.x||0!==this._pages[0].currentRow.y){var e,t=c(this._pages);try{for(t.s();!(e=t.n()).done;)e.value.clear()}catch(i){t.e(i)}finally{t.f()}this._cacheMap.clear(),this._cacheMapCombined.clear(),this._didWarmUp=!1}}},{key:"_createNewPage",value:function(){var t=this;e.maxAtlasPages&&this._pages.length>=Math.max(4,e.maxAtlasPages/2)&&queueMicrotask((function(){for(var i=t._pages.filter((function(t){return 2*t.canvas.width<=(e.maxTextureSize||4096)})).sort((function(e,t){return t.canvas.width!==e.canvas.width?t.canvas.width-e.canvas.width:t.percentageUsed-e.percentageUsed})),r=-1,n=0,s=0;s<i.length;s++)if(i[s].canvas.width!==n)r=s,n=i[s].canvas.width;else if(s-r==3)break;var o=i.slice(r,r+4),a=o.map((function(e){return e.glyphs[0].texturePage})).sort((function(e,t){return e>t?1:-1})),c=a[0],l=t._mergePages(o,c);l.version++,t._pages[c]=l;for(var u=a.length-1;u>=1;u--)t._deletePage(a[u]);t._requestClearModel=!0,t._onAddTextureAtlasCanvas.fire(l.canvas)}));var i=new b(this._document,this._textureSize);return this._pages.push(i),this._activePages.push(i),this._onAddTextureAtlasCanvas.fire(i.canvas),i}},{key:"_mergePages",value:function(e,t){var i,r=2*e[0].canvas.width,s=new b(this._document,r,e),o=c(e.entries());try{for(o.s();!(i=o.n()).done;){var a=n(i.value,2),l=a[0],u=a[1],h=l*u.canvas.width%r,f=Math.floor(l/2)*u.canvas.height;s.ctx.drawImage(u.canvas,h,f);var d,v=c(u.glyphs);try{for(v.s();!(d=v.n()).done;){var _=d.value;_.texturePage=t,_.sizeClipSpace.x=_.size.x/r,_.sizeClipSpace.y=_.size.y/r,_.texturePosition.x+=h,_.texturePosition.y+=f,_.texturePositionClipSpace.x=_.texturePosition.x/r,_.texturePositionClipSpace.y=_.texturePosition.y/r}}catch(g){v.e(g)}finally{v.f()}this._onRemoveTextureAtlasCanvas.fire(u.canvas);var p=this._activePages.indexOf(u);-1!==p&&this._activePages.splice(p,1)}}catch(g){o.e(g)}finally{o.f()}return s}},{key:"_deletePage",value:function(e){this._pages.splice(e,1);for(var t=e;t<this._pages.length;t++){var i,r=this._pages[t],n=c(r.glyphs);try{for(n.s();!(i=n.n()).done;)i.value.texturePage--}catch(s){n.e(s)}finally{n.f()}r.version++}}},{key:"getRasterizedGlyphCombinedChar",value:function(e,t,i,r){return this._getFromCacheMap(this._cacheMapCombined,e,t,i,r)}},{key:"getRasterizedGlyph",value:function(e,t,i,r){return this._getFromCacheMap(this._cacheMap,e,t,i,r)}},{key:"_getFromCacheMap",value:function(e,t,i,r,n){return(s=e.get(t,i,r,n))||(s=this._drawToCache(t,i,r,n),e.set(t,i,r,n,s)),s}},{key:"_getColorFromAnsiIndex",value:function(e){if(e>=this._config.colors.ansi.length)throw new Error("No color found for idx "+e);return this._config.colors.ansi[e]}},{key:"_getBackgroundColor",value:function(e,t,i,r){if(this._config.allowTransparency)return f.NULL_COLOR;var n;switch(e){case 16777216:case 33554432:n=this._getColorFromAnsiIndex(t);break;case 50331648:var s=h.AttributeData.toColorRGB(t);n=f.rgba.toColor(s[0],s[1],s[2]);break;default:n=i?this._config.colors.foreground:this._config.colors.background}return r&&(n=f.color.blend(this._config.colors.background,f.color.multiplyOpacity(n,o.DIM_OPACITY))),n}},{key:"_getForegroundColor",value:function(e,t,i,r,n,s,a,c,l,u){var d,v=this._getMinimumContrastColor(e,t,i,r,n,s,!1,l,u);if(v)return v;switch(n){case 16777216:case 33554432:this._config.drawBoldTextInBrightColors&&l&&s<8&&(s+=8),d=this._getColorFromAnsiIndex(s);break;case 50331648:var _=h.AttributeData.toColorRGB(s);d=f.rgba.toColor(_[0],_[1],_[2]);break;default:d=a?this._config.colors.background:this._config.colors.foreground}return this._config.allowTransparency&&(d=f.color.opaque(d)),c&&(d=f.color.multiplyOpacity(d,o.DIM_OPACITY)),d}},{key:"_resolveBackgroundRgba",value:function(e,t,i){switch(e){case 16777216:case 33554432:return this._getColorFromAnsiIndex(t).rgba;case 50331648:return t<<8;default:return i?this._config.colors.foreground.rgba:this._config.colors.background.rgba}}},{key:"_resolveForegroundRgba",value:function(e,t,i,r){switch(e){case 16777216:case 33554432:return this._config.drawBoldTextInBrightColors&&r&&t<8&&(t+=8),this._getColorFromAnsiIndex(t).rgba;case 50331648:return t<<8;default:return i?this._config.colors.background.rgba:this._config.colors.foreground.rgba}}},{key:"_getMinimumContrastColor",value:function(e,t,i,r,n,s,o,a,c){if(1!==this._config.minimumContrastRatio&&!c){var l=this._config.colors.contrastCache.getColor(e,r);if(void 0!==l)return l||void 0;var u=this._resolveBackgroundRgba(t,i,o),h=this._resolveForegroundRgba(n,s,o,a),d=f.rgba.ensureContrastRatio(u,h,this._config.minimumContrastRatio);if(d){var v=f.rgba.toColor(d>>24&255,d>>16&255,d>>8&255);return this._config.colors.contrastCache.setColor(e,r,v),v}this._config.colors.contrastCache.setColor(e,r,null)}}},{key:"_drawToCache",value:function(e,t,i,r){var n="number"==typeof e?String.fromCharCode(e):e,s=this._config.deviceCellWidth*Math.max(n.length,2)+4;this._tmpCanvas.width<s&&(this._tmpCanvas.width=s);var a=this._config.deviceCellHeight+8;if(this._tmpCanvas.height<a&&(this._tmpCanvas.height=a),this._tmpCtx.save(),this._workAttributeData.fg=i,this._workAttributeData.bg=t,this._workAttributeData.extended.ext=r,this._workAttributeData.isInvisible())return m;var l=!!this._workAttributeData.isBold(),u=!!this._workAttributeData.isInverse(),f=!!this._workAttributeData.isDim(),_=!!this._workAttributeData.isItalic(),p=!!this._workAttributeData.isUnderline(),g=!!this._workAttributeData.isStrikethrough(),y=this._workAttributeData.getFgColor(),b=this._workAttributeData.getFgColorMode(),S=this._workAttributeData.getBgColor(),w=this._workAttributeData.getBgColorMode();if(u){var k=y;y=S,S=k;var x=b;b=w,w=x}var L=this._getBackgroundColor(w,S,u,f);this._tmpCtx.globalCompositeOperation="copy",this._tmpCtx.fillStyle=L.css,this._tmpCtx.fillRect(0,0,this._tmpCanvas.width,this._tmpCanvas.height),this._tmpCtx.globalCompositeOperation="source-over";var E=l?this._config.fontWeightBold:this._config.fontWeight,R=_?"italic":"";this._tmpCtx.font="".concat(R," ").concat(E," ").concat(this._config.fontSize*this._config.devicePixelRatio,"px ").concat(this._config.fontFamily),this._tmpCtx.textBaseline=o.TEXT_BASELINE;var M=1===n.length&&(0,v.isPowerlineGlyph)(n.charCodeAt(0)),A=1===n.length&&(0,v.isRestrictedPowerlineGlyph)(n.charCodeAt(0)),D=this._getForegroundColor(t,w,S,i,b,y,u,f,l,(0,v.excludeFromContrastRatioDemands)(n.charCodeAt(0)));this._tmpCtx.fillStyle=D.css;var O=A?0:4,T=!1;!1!==this._config.customGlyphs&&(T=(0,d.tryDrawCustomChar)(this._tmpCtx,n,O,O,this._config.deviceCellWidth,this._config.deviceCellHeight,this._config.fontSize,this._config.devicePixelRatio));var B,I=!M;if(B="number"==typeof e?this._unicodeService.wcwidth(e):this._unicodeService.getStringCellWidth(e),p){this._tmpCtx.save();var P=Math.max(1,Math.floor(this._config.fontSize*this._config.devicePixelRatio/15)),F=P%2==1?.5:0;if(this._tmpCtx.lineWidth=P,this._workAttributeData.isUnderlineColorDefault())this._tmpCtx.strokeStyle=this._tmpCtx.fillStyle;else if(this._workAttributeData.isUnderlineColorRGB())I=!1,this._tmpCtx.strokeStyle="rgb(".concat(h.AttributeData.toColorRGB(this._workAttributeData.getUnderlineColor()).join(","),")");else{I=!1;var H=this._workAttributeData.getUnderlineColor();this._config.drawBoldTextInBrightColors&&this._workAttributeData.isBold()&&H<8&&(H+=8),this._tmpCtx.strokeStyle=this._getColorFromAnsiIndex(H).css}this._tmpCtx.beginPath();for(var N=O,W=Math.ceil(O+this._config.deviceCharHeight)-F,U=O+this._config.deviceCharHeight+P-F,j=Math.ceil(O+this._config.deviceCharHeight+2*P)-F,z=0;z<B;z++){this._tmpCtx.save();var q=N+z*this._config.deviceCellWidth,G=N+(z+1)*this._config.deviceCellWidth,K=q+this._config.deviceCellWidth/2;switch(this._workAttributeData.extended.underlineStyle){case 2:this._tmpCtx.moveTo(q,W),this._tmpCtx.lineTo(G,W),this._tmpCtx.moveTo(q,j),this._tmpCtx.lineTo(G,j);break;case 3:var Z=P<=1?j:Math.ceil(O+this._config.deviceCharHeight-P/2)-F,V=P<=1?W:Math.ceil(O+this._config.deviceCharHeight+P/2)-F,X=new Path2D;X.rect(q,W,this._config.deviceCellWidth,j-W),this._tmpCtx.clip(X),this._tmpCtx.moveTo(q-this._config.deviceCellWidth/2,U),this._tmpCtx.bezierCurveTo(q-this._config.deviceCellWidth/2,V,q,V,q,U),this._tmpCtx.bezierCurveTo(q,Z,K,Z,K,U),this._tmpCtx.bezierCurveTo(K,V,G,V,G,U),this._tmpCtx.bezierCurveTo(G,Z,G+this._config.deviceCellWidth/2,Z,G+this._config.deviceCellWidth/2,U);break;case 4:this._tmpCtx.setLineDash([2*this._config.devicePixelRatio,this._config.devicePixelRatio]),this._tmpCtx.moveTo(q,W),this._tmpCtx.lineTo(G,W);break;case 5:this._tmpCtx.setLineDash([4*this._config.devicePixelRatio,3*this._config.devicePixelRatio]),this._tmpCtx.moveTo(q,W),this._tmpCtx.lineTo(G,W);break;default:this._tmpCtx.moveTo(q,W),this._tmpCtx.lineTo(G,W)}this._tmpCtx.stroke(),this._tmpCtx.restore()}if(this._tmpCtx.restore(),!T&&this._config.fontSize>=12&&!this._config.allowTransparency&&" "!==n){this._tmpCtx.save(),this._tmpCtx.textBaseline="alphabetic";var Y=this._tmpCtx.measureText(n);if(this._tmpCtx.restore(),"actualBoundingBoxDescent"in Y&&Y.actualBoundingBoxDescent>0){this._tmpCtx.save();var J=new Path2D;J.rect(N,W-Math.ceil(P/2),this._config.deviceCellWidth,j-W+Math.ceil(P/2)),this._tmpCtx.clip(J),this._tmpCtx.lineWidth=3*this._config.devicePixelRatio,this._tmpCtx.strokeStyle=L.css,this._tmpCtx.strokeText(n,O,O+this._config.deviceCharHeight),this._tmpCtx.restore()}}}if(T||this._tmpCtx.fillText(n,O,O+this._config.deviceCharHeight),"_"===n&&!this._config.allowTransparency){var $=C(this._tmpCtx.getImageData(O,O,this._config.deviceCellWidth,this._config.deviceCellHeight),L,D,I);if($)for(var Q=1;Q<=5&&(this._tmpCtx.save(),this._tmpCtx.fillStyle=L.css,this._tmpCtx.fillRect(0,0,this._tmpCanvas.width,this._tmpCanvas.height),this._tmpCtx.restore(),this._tmpCtx.fillText(n,O,O+this._config.deviceCharHeight-Q),$=C(this._tmpCtx.getImageData(O,O,this._config.deviceCellWidth,this._config.deviceCellHeight),L,D,I));Q++);}if(g){var ee=Math.max(1,Math.floor(this._config.fontSize*this._config.devicePixelRatio/10)),te=this._tmpCtx.lineWidth%2==1?.5:0;this._tmpCtx.lineWidth=ee,this._tmpCtx.strokeStyle=this._tmpCtx.fillStyle,this._tmpCtx.beginPath(),this._tmpCtx.moveTo(O,O+Math.floor(this._config.deviceCharHeight/2)-te),this._tmpCtx.lineTo(O+this._config.deviceCharWidth*B,O+Math.floor(this._config.deviceCharHeight/2)-te),this._tmpCtx.stroke()}this._tmpCtx.restore();var ie,re=this._tmpCtx.getImageData(0,0,this._tmpCanvas.width,this._tmpCanvas.height);if(ie=this._config.allowTransparency?function(e){for(var t=0;t<e.data.length;t+=4)if(e.data[t+3]>0)return!1;return!0}(re):C(re,L,D,I),ie)return m;for(var ne,se,oe=this._findGlyphBoundingBox(re,this._workBoundingBox,s,A,T,O);;){if(0===this._activePages.length){var ae=this._createNewPage();ne=ae,(se=ae.currentRow).height=oe.size.y;break}se=(ne=this._activePages[this._activePages.length-1]).currentRow;var ce,le=c(this._activePages);try{for(le.s();!(ce=le.n()).done;){var ue=ce.value;oe.size.y<=ue.currentRow.height&&(ne=ue,se=ue.currentRow)}}catch(Ce){le.e(Ce)}finally{le.f()}for(var he=this._activePages.length-1;he>=0;he--){var fe,de=c(this._activePages[he].fixedRows);try{for(de.s();!(fe=de.n()).done;){var ve=fe.value;ve.height<=se.height&&oe.size.y<=ve.height&&(ne=this._activePages[he],se=ve)}}catch(Ce){de.e(Ce)}finally{de.f()}}if(se.y+oe.size.y>=ne.canvas.height||se.height>oe.size.y+2){var _e=!1;if(ne.currentRow.y+ne.currentRow.height+oe.size.y>=ne.canvas.height){var pe,ge=void 0,me=c(this._activePages);try{for(me.s();!(pe=me.n()).done;){var ye=pe.value;if(ye.currentRow.y+ye.currentRow.height+oe.size.y<ye.canvas.height){ge=ye;break}}}catch(Ce){me.e(Ce)}finally{me.f()}if(ge)ne=ge;else{var be=this._createNewPage();ne=be,(se=be.currentRow).height=oe.size.y,_e=!0}}_e||(ne.currentRow.height>0&&ne.fixedRows.push(ne.currentRow),se={x:0,y:ne.currentRow.y+ne.currentRow.height,height:oe.size.y},ne.fixedRows.push(se),ne.currentRow={x:0,y:se.y+se.height,height:0})}if(se.x+oe.size.x<=ne.canvas.width)break;se===ne.currentRow?(se.x=0,se.y+=se.height,se.height=0):ne.fixedRows.splice(ne.fixedRows.indexOf(se),1)}return oe.texturePage=this._pages.indexOf(ne),oe.texturePosition.x=se.x,oe.texturePosition.y=se.y,oe.texturePositionClipSpace.x=se.x/ne.canvas.width,oe.texturePositionClipSpace.y=se.y/ne.canvas.height,oe.sizeClipSpace.x/=ne.canvas.width,oe.sizeClipSpace.y/=ne.canvas.height,se.height=Math.max(se.height,oe.size.y),se.x+=oe.size.x,ne.ctx.putImageData(re,oe.texturePosition.x-this._workBoundingBox.left,oe.texturePosition.y-this._workBoundingBox.top,this._workBoundingBox.left,this._workBoundingBox.top,oe.size.x,oe.size.y),ne.addGlyph(oe),ne.version++,oe}},{key:"_findGlyphBoundingBox",value:function(e,t,i,r,n,s){t.top=0;for(var o=r?this._config.deviceCellHeight:this._tmpCanvas.height,a=r?this._config.deviceCellWidth:i,c=!1,l=0;l<o;l++){for(var u=0;u<a;u++){var h=l*this._tmpCanvas.width*4+4*u+3;if(0!==e.data[h]){t.top=l,c=!0;break}}if(c)break}t.left=0,c=!1;for(var f=0;f<s+a;f++){for(var d=0;d<o;d++){var v=d*this._tmpCanvas.width*4+4*f+3;if(0!==e.data[v]){t.left=f,c=!0;break}}if(c)break}t.right=a,c=!1;for(var _=s+a-1;_>=s;_--){for(var p=0;p<o;p++){var g=p*this._tmpCanvas.width*4+4*_+3;if(0!==e.data[g]){t.right=_,c=!0;break}}if(c)break}t.bottom=o,c=!1;for(var m=o-1;m>=0;m--){for(var y=0;y<a;y++){var b=m*this._tmpCanvas.width*4+4*y+3;if(0!==e.data[b]){t.bottom=m,c=!0;break}}if(c)break}return{texturePage:0,texturePosition:{x:0,y:0},texturePositionClipSpace:{x:0,y:0},size:{x:t.right-t.left+1,y:t.bottom-t.top+1},sizeClipSpace:{x:t.right-t.left+1,y:t.bottom-t.top+1},offset:{x:-t.left+s+(r||n?Math.floor((this._config.deviceCellWidth-this._config.deviceCharWidth)/2):0),y:-t.top+s+(r||n?1===this._config.lineHeight?0:Math.round((this._config.deviceCellHeight-this._config.deviceCharHeight)/2):0)}}}}]),e}();t.TextureAtlas=y;var b=function(){function e(t,i,n){if(l(this,e),this._usedPixels=0,this._glyphs=[],this.version=0,this.currentRow={x:0,y:0,height:0},this.fixedRows=[],n){var s,o=c(n);try{for(o.s();!(s=o.n()).done;){var a,u=s.value;(a=this._glyphs).push.apply(a,r(u.glyphs)),this._usedPixels+=u._usedPixels}}catch(h){o.e(h)}finally{o.f()}}this.canvas=S(t,i,i),this.ctx=(0,v.throwIfFalsy)(this.canvas.getContext("2d",{alpha:!0}))}return u(e,[{key:"percentageUsed",get:function(){return this._usedPixels/(this.canvas.width*this.canvas.height)}},{key:"glyphs",get:function(){return this._glyphs}},{key:"addGlyph",value:function(e){this._glyphs.push(e),this._usedPixels+=e.size.x*e.size.y}},{key:"clear",value:function(){this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.currentRow.x=0,this.currentRow.y=0,this.currentRow.height=0,this.fixedRows.length=0,this.version++}}]),e}();function C(e,t,i,r){for(var n=t.rgba>>>24,s=t.rgba>>>16&255,o=t.rgba>>>8&255,a=i.rgba>>>24,c=i.rgba>>>16&255,l=i.rgba>>>8&255,u=Math.floor((Math.abs(n-a)+Math.abs(s-c)+Math.abs(o-l))/12),h=!0,f=0;f<e.data.length;f+=4)e.data[f]===n&&e.data[f+1]===s&&e.data[f+2]===o||r&&Math.abs(e.data[f]-n)+Math.abs(e.data[f+1]-s)+Math.abs(e.data[f+2]-o)<u?e.data[f+3]=0:h=!1;return h}function S(e,t,i){var r=e.createElement("canvas");return r.width=t,r.height=i,r}},577:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CharacterJoinerService=t.JoinedCellData=void 0;var s=i(147),o=i(855),a=i(782),c=i(97),d=function(e){h(i,e);var t=f(i);function i(e,r,n){var s;return l(this,i),(s=t.call(this)).content=0,s.combinedData="",s.fg=e.fg,s.bg=e.bg,s.combinedData=r,s._width=n,s}return u(i,[{key:"isCombined",value:function(){return 2097152}},{key:"getWidth",value:function(){return this._width}},{key:"getChars",value:function(){return this.combinedData}},{key:"getCode",value:function(){return 2097151}},{key:"setFromCharData",value:function(e){throw new Error("not implemented")}},{key:"getAsCharData",value:function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}]),i}(s.AttributeData);t.JoinedCellData=d;var v=function(){function e(t){l(this,e),this._bufferService=t,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new a.CellData}return u(e,[{key:"register",value:function(e){var t={id:this._nextCharacterJoinerId++,handler:e};return this._characterJoiners.push(t),t.id}},{key:"deregister",value:function(e){for(var t=0;t<this._characterJoiners.length;t++)if(this._characterJoiners[t].id===e)return this._characterJoiners.splice(t,1),!0;return!1}},{key:"getJoinedCharacters",value:function(e){if(0===this._characterJoiners.length)return[];var t=this._bufferService.buffer.lines.get(e);if(!t||0===t.length)return[];for(var i=[],r=t.translateToString(!0),n=0,s=0,a=0,c=t.getFg(0),l=t.getBg(0),u=0;u<t.getTrimmedLength();u++)if(t.loadCell(u,this._workCell),0!==this._workCell.getWidth()){if(this._workCell.fg!==c||this._workCell.bg!==l){if(u-n>1)for(var h=this._getJoinedRanges(r,a,s,t,n),f=0;f<h.length;f++)i.push(h[f]);n=u,a=s,c=this._workCell.fg,l=this._workCell.bg}s+=this._workCell.getChars().length||o.WHITESPACE_CELL_CHAR.length}if(this._bufferService.cols-n>1)for(var d=this._getJoinedRanges(r,a,s,t,n),v=0;v<d.length;v++)i.push(d[v]);return i}},{key:"_getJoinedRanges",value:function(t,i,r,n,s){var o=t.substring(i,r),a=[];try{a=this._characterJoiners[0].handler(o)}catch(h){console.error(h)}for(var c=1;c<this._characterJoiners.length;c++)try{for(var l=this._characterJoiners[c].handler(o),u=0;u<l.length;u++)e._mergeRanges(a,l[u])}catch(f){console.error(f)}return this._stringRangesToCellRanges(a,n,s),a}},{key:"_stringRangesToCellRanges",value:function(e,t,i){var r=0,n=!1,s=0,a=e[r];if(a){for(var c=i;c<this._bufferService.cols;c++){var l=t.getWidth(c),u=t.getString(c).length||o.WHITESPACE_CELL_CHAR.length;if(0!==l){if(!n&&a[0]<=s&&(a[0]=c,n=!0),a[1]<=s){if(a[1]=c,!(a=e[++r]))break;a[0]<=s?(a[0]=c,n=!0):n=!1}s+=u}}a&&(a[1]=this._bufferService.cols)}}}],[{key:"_mergeRanges",value:function(e,t){for(var i=!1,r=0;r<e.length;r++){var n=e[r];if(i){if(t[1]<=n[0])return e[r-1][1]=t[1],e;if(t[1]<=n[1])return e[r-1][1]=Math.max(t[1],n[1]),e.splice(r,1),e;e.splice(r,1),r--}else{if(t[1]<=n[0])return e.splice(r,0,t),e;if(t[1]<=n[1])return n[0]=Math.min(t[0],n[0]),e;t[0]<n[1]&&(n[0]=Math.min(t[0],n[0]),i=!0)}}return i?e[e.length-1][1]=t[1]:e.push(t),e}}]),e}();v=r([n(0,c.IBufferService)],v),t.CharacterJoinerService=v},160:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.contrastRatio=t.toPaddedHex=t.rgba=t.rgb=t.css=t.color=t.channels=t.NULL_COLOR=void 0;var r,s,o,a=i(399),c=0,l=0,u=0,h=0;function f(e){var t=e.toString(16);return t.length<2?"0"+t:t}function d(e,t){return e<t?(t+.05)/(e+.05):(e+.05)/(t+.05)}t.NULL_COLOR={css:"#00000000",rgba:0},function(e){e.toCss=function(e,t,i,r){return void 0!==r?"#".concat(f(e)).concat(f(t)).concat(f(i)).concat(f(r)):"#".concat(f(e)).concat(f(t)).concat(f(i))},e.toRgba=function(e,t,i){return(e<<24|t<<16|i<<8|(arguments.length>3&&void 0!==arguments[3]?arguments[3]:255))>>>0}}(r=t.channels||(t.channels={})),function(e){function t(e,t){var i,s;return h=Math.round(255*t),i=o.toChannels(e.rgba),s=n(i,3),c=s[0],l=s[1],u=s[2],{css:r.toCss(c,l,u,h),rgba:r.toRgba(c,l,u,h)}}e.blend=function(e,t){if(1===(h=(255&t.rgba)/255))return{css:t.css,rgba:t.rgba};var i=t.rgba>>24&255,n=t.rgba>>16&255,s=t.rgba>>8&255,o=e.rgba>>24&255,a=e.rgba>>16&255,f=e.rgba>>8&255;return c=o+Math.round((i-o)*h),l=a+Math.round((n-a)*h),u=f+Math.round((s-f)*h),{css:r.toCss(c,l,u),rgba:r.toRgba(c,l,u)}},e.isOpaque=function(e){return 255==(255&e.rgba)},e.ensureContrastRatio=function(e,t,i){var r=o.ensureContrastRatio(e.rgba,t.rgba,i);if(r)return o.toColor(r>>24&255,r>>16&255,r>>8&255)},e.opaque=function(e){var t,i,s=(255|e.rgba)>>>0;return t=o.toChannels(s),i=n(t,3),c=i[0],l=i[1],u=i[2],{css:r.toCss(c,l,u),rgba:s}},e.opacity=t,e.multiplyOpacity=function(e,i){return t(e,(h=255&e.rgba)*i/255)},e.toColorRGB=function(e){return[e.rgba>>24&255,e.rgba>>16&255,e.rgba>>8&255]}}(t.color||(t.color={})),function(e){var t,i;if(!a.isNode){var s=document.createElement("canvas");s.width=1,s.height=1;var f=s.getContext("2d",{willReadFrequently:!0});f&&((t=f).globalCompositeOperation="copy",i=t.createLinearGradient(0,0,1,1))}e.toColor=function(e){var s;if(e.match(/#[\da-f]{3,8}/i))switch(e.length){case 4:return c=parseInt(e.slice(1,2).repeat(2),16),l=parseInt(e.slice(2,3).repeat(2),16),u=parseInt(e.slice(3,4).repeat(2),16),o.toColor(c,l,u);case 5:return c=parseInt(e.slice(1,2).repeat(2),16),l=parseInt(e.slice(2,3).repeat(2),16),u=parseInt(e.slice(3,4).repeat(2),16),h=parseInt(e.slice(4,5).repeat(2),16),o.toColor(c,l,u,h);case 7:return{css:e,rgba:(parseInt(e.slice(1),16)<<8|255)>>>0};case 9:return{css:e,rgba:parseInt(e.slice(1),16)>>>0}}var a=e.match(/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(,\s*(0|1|\d?\.(\d+))\s*)?\)/);if(a)return c=parseInt(a[1]),l=parseInt(a[2]),u=parseInt(a[3]),h=Math.round(255*(void 0===a[5]?1:parseFloat(a[5]))),o.toColor(c,l,u,h);if(!t||!i)throw new Error("css.toColor: Unsupported css format");if(t.fillStyle=i,t.fillStyle=e,"string"!=typeof t.fillStyle)throw new Error("css.toColor: Unsupported css format");if(t.fillRect(0,0,1,1),s=n(t.getImageData(0,0,1,1).data,4),c=s[0],l=s[1],u=s[2],255!==(h=s[3]))throw new Error("css.toColor: Unsupported css format");return{rgba:r.toRgba(c,l,u,h),css:e}}}(t.css||(t.css={})),function(e){function t(e,t,i){var r=e/255,n=t/255,s=i/255;return.2126*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))+.7152*(n<=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4))+.0722*(s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4))}e.relativeLuminance=function(e){return t(e>>16&255,e>>8&255,255&e)},e.relativeLuminance2=t}(s=t.rgb||(t.rgb={})),function(e){function t(e,t,i){for(var r=e>>24&255,n=e>>16&255,o=e>>8&255,a=t>>24&255,c=t>>16&255,l=t>>8&255,u=d(s.relativeLuminance2(a,c,l),s.relativeLuminance2(r,n,o));u<i&&(a>0||c>0||l>0);)a-=Math.max(0,Math.ceil(.1*a)),c-=Math.max(0,Math.ceil(.1*c)),l-=Math.max(0,Math.ceil(.1*l)),u=d(s.relativeLuminance2(a,c,l),s.relativeLuminance2(r,n,o));return(a<<24|c<<16|l<<8|255)>>>0}function i(e,t,i){for(var r=e>>24&255,n=e>>16&255,o=e>>8&255,a=t>>24&255,c=t>>16&255,l=t>>8&255,u=d(s.relativeLuminance2(a,c,l),s.relativeLuminance2(r,n,o));u<i&&(a<255||c<255||l<255);)a=Math.min(255,a+Math.ceil(.1*(255-a))),c=Math.min(255,c+Math.ceil(.1*(255-c))),l=Math.min(255,l+Math.ceil(.1*(255-l))),u=d(s.relativeLuminance2(a,c,l),s.relativeLuminance2(r,n,o));return(a<<24|c<<16|l<<8|255)>>>0}e.ensureContrastRatio=function(e,r,n){var o=s.relativeLuminance(e>>8),a=s.relativeLuminance(r>>8);if(d(o,a)<n){if(a<o){var c=t(e,r,n),l=d(o,s.relativeLuminance(c>>8));if(l<n){var u=i(e,r,n);return l>d(o,s.relativeLuminance(u>>8))?c:u}return c}var h=i(e,r,n),f=d(o,s.relativeLuminance(h>>8));if(f<n){var v=t(e,r,n);return f>d(o,s.relativeLuminance(v>>8))?h:v}return h}},e.reduceLuminance=t,e.increaseLuminance=i,e.toChannels=function(e){return[e>>24&255,e>>16&255,e>>8&255,255&e]},e.toColor=function(e,t,i,n){return{css:r.toCss(e,t,i,n),rgba:r.toRgba(e,t,i,n)}}}(o=t.rgba||(t.rgba={})),t.toPaddedHex=f,t.contrastRatio=d},345:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.forwardEvent=t.EventEmitter=void 0,t.EventEmitter=function(){function e(){l(this,e),this._listeners=[],this._disposed=!1}return u(e,[{key:"event",get:function(){var e=this;return this._event||(this._event=function(t){return e._listeners.push(t),{dispose:function(){if(!e._disposed)for(var i=0;i<e._listeners.length;i++)if(e._listeners[i]===t)return void e._listeners.splice(i,1)}}}),this._event}},{key:"fire",value:function(e,t){for(var i=[],r=0;r<this._listeners.length;r++)i.push(this._listeners[r]);for(var n=0;n<i.length;n++)i[n].call(void 0,e,t)}},{key:"dispose",value:function(){this._listeners&&(this._listeners.length=0),this._disposed=!0}}]),e}(),t.forwardEvent=function(e,t){return e((function(e){return t.fire(e)}))}},859:function(e,t){function i(e){var t,i=c(e);try{for(i.s();!(t=i.n()).done;)t.value.dispose()}catch(r){i.e(r)}finally{i.f()}e.length=0}Object.defineProperty(t,"__esModule",{value:!0}),t.getDisposeArrayDisposable=t.disposeArray=t.toDisposable=t.Disposable=void 0,t.Disposable=function(){function e(){l(this,e),this._disposables=[],this._isDisposed=!1}return u(e,[{key:"dispose",value:function(){this._isDisposed=!0;var e,t=c(this._disposables);try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(i){t.e(i)}finally{t.f()}this._disposables.length=0}},{key:"register",value:function(e){return this._disposables.push(e),e}},{key:"unregister",value:function(e){var t=this._disposables.indexOf(e);-1!==t&&this._disposables.splice(t,1)}}]),e}(),t.toDisposable=function(e){return{dispose:e}},t.disposeArray=i,t.getDisposeArrayDisposable=function(e){return{dispose:function(){return i(e)}}}},485:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.FourKeyMap=t.TwoKeyMap=void 0;var i=function(){function e(){l(this,e),this._data={}}return u(e,[{key:"set",value:function(e,t,i){this._data[e]||(this._data[e]={}),this._data[e][t]=i}},{key:"get",value:function(e,t){return this._data[e]?this._data[e][t]:void 0}},{key:"clear",value:function(){this._data={}}}]),e}();t.TwoKeyMap=i,t.FourKeyMap=function(){function e(){l(this,e),this._data=new i}return u(e,[{key:"set",value:function(e,t,r,n,s){this._data.get(e,t)||this._data.set(e,t,new i),this._data.get(e,t).set(r,n,s)}},{key:"get",value:function(e,t,i,r){var n;return null===(n=this._data.get(e,t))||void 0===n?void 0:n.get(i,r)}},{key:"clear",value:function(){this._data.clear()}}]),e}()},399:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.isChromeOS=t.isLinux=t.isWindows=t.isIphone=t.isIpad=t.isMac=t.getSafariVersion=t.isSafari=t.isLegacyEdge=t.isFirefox=t.isNode=void 0,t.isNode="undefined"==typeof navigator;var i=t.isNode?"node":navigator.userAgent,r=t.isNode?"node":navigator.platform;t.isFirefox=i.includes("Firefox"),t.isLegacyEdge=i.includes("Edge"),t.isSafari=/^((?!chrome|android).)*safari/i.test(i),t.getSafariVersion=function(){if(!t.isSafari)return 0;var e=i.match(/Version\/(\d+)/);return null===e||e.length<2?0:parseInt(e[1])},t.isMac=["Macintosh","MacIntel","MacPPC","Mac68K"].includes(r),t.isIpad="iPad"===r,t.isIphone="iPhone"===r,t.isWindows=["Windows","Win16","Win32","WinCE"].includes(r),t.isLinux=r.indexOf("Linux")>=0,t.isChromeOS=/\bCrOS\b/.test(i)},385:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.DebouncedIdleTask=t.IdleTaskQueue=t.PriorityTaskQueue=void 0;var r=i(399),n=function(){function e(){l(this,e),this._tasks=[],this._i=0}return u(e,[{key:"enqueue",value:function(e){this._tasks.push(e),this._start()}},{key:"flush",value:function(){for(;this._i<this._tasks.length;)this._tasks[this._i]()||this._i++;this.clear()}},{key:"clear",value:function(){this._idleCallback&&(this._cancelCallback(this._idleCallback),this._idleCallback=void 0),this._i=0,this._tasks.length=0}},{key:"_start",value:function(){this._idleCallback||(this._idleCallback=this._requestCallback(this._process.bind(this)))}},{key:"_process",value:function(e){this._idleCallback=void 0;for(var t=0,i=0,r=e.timeRemaining(),n=0;this._i<this._tasks.length;){if(t=Date.now(),this._tasks[this._i]()||this._i++,t=Math.max(1,Date.now()-t),1.5*(i=Math.max(t,i))>(n=e.timeRemaining()))return r-t<-20&&console.warn("task queue exceeded allotted deadline by ".concat(Math.abs(Math.round(r-t)),"ms")),void this._start();r=n}this.clear()}}]),e}(),s=function(e){h(i,e);var t=f(i);function i(){return l(this,i),t.apply(this,arguments)}return u(i,[{key:"_requestCallback",value:function(e){var t=this;return setTimeout((function(){return e(t._createDeadline(16))}))}},{key:"_cancelCallback",value:function(e){clearTimeout(e)}},{key:"_createDeadline",value:function(e){var t=Date.now()+e;return{timeRemaining:function(){return Math.max(0,t-Date.now())}}}}]),i}(n);t.PriorityTaskQueue=s,t.IdleTaskQueue=!r.isNode&&"requestIdleCallback"in window?function(e){h(i,e);var t=f(i);function i(){return l(this,i),t.apply(this,arguments)}return u(i,[{key:"_requestCallback",value:function(e){return requestIdleCallback(e)}},{key:"_cancelCallback",value:function(e){cancelIdleCallback(e)}}]),i}(n):s,t.DebouncedIdleTask=function(){function e(){l(this,e),this._queue=new t.IdleTaskQueue}return u(e,[{key:"set",value:function(e){this._queue.clear(),this._queue.enqueue(e)}},{key:"flush",value:function(){this._queue.flush()}}]),e}()},147:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.ExtendedAttrs=t.AttributeData=void 0;var i=function(){function e(){l(this,e),this.fg=0,this.bg=0,this.extended=new r}return u(e,[{key:"clone",value:function(){var t=new e;return t.fg=this.fg,t.bg=this.bg,t.extended=this.extended.clone(),t}},{key:"isInverse",value:function(){return 67108864&this.fg}},{key:"isBold",value:function(){return 134217728&this.fg}},{key:"isUnderline",value:function(){return this.hasExtendedAttrs()&&0!==this.extended.underlineStyle?1:268435456&this.fg}},{key:"isBlink",value:function(){return 536870912&this.fg}},{key:"isInvisible",value:function(){return 1073741824&this.fg}},{key:"isItalic",value:function(){return 67108864&this.bg}},{key:"isDim",value:function(){return 134217728&this.bg}},{key:"isStrikethrough",value:function(){return 2147483648&this.fg}},{key:"isProtected",value:function(){return 536870912&this.bg}},{key:"getFgColorMode",value:function(){return 50331648&this.fg}},{key:"getBgColorMode",value:function(){return 50331648&this.bg}},{key:"isFgRGB",value:function(){return 50331648==(50331648&this.fg)}},{key:"isBgRGB",value:function(){return 50331648==(50331648&this.bg)}},{key:"isFgPalette",value:function(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)}},{key:"isBgPalette",value:function(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)}},{key:"isFgDefault",value:function(){return 0==(50331648&this.fg)}},{key:"isBgDefault",value:function(){return 0==(50331648&this.bg)}},{key:"isAttributeDefault",value:function(){return 0===this.fg&&0===this.bg}},{key:"getFgColor",value:function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}}},{key:"getBgColor",value:function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}}},{key:"hasExtendedAttrs",value:function(){return 268435456&this.bg}},{key:"updateExtended",value:function(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456}},{key:"getUnderlineColor",value:function(){if(268435456&this.bg&&~this.extended.underlineColor)switch(50331648&this.extended.underlineColor){case 16777216:case 33554432:return 255&this.extended.underlineColor;case 50331648:return 16777215&this.extended.underlineColor;default:return this.getFgColor()}return this.getFgColor()}},{key:"getUnderlineColorMode",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648&this.extended.underlineColor:this.getFgColorMode()}},{key:"isUnderlineColorRGB",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648==(50331648&this.extended.underlineColor):this.isFgRGB()}},{key:"isUnderlineColorPalette",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?16777216==(50331648&this.extended.underlineColor)||33554432==(50331648&this.extended.underlineColor):this.isFgPalette()}},{key:"isUnderlineColorDefault",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?0==(50331648&this.extended.underlineColor):this.isFgDefault()}},{key:"getUnderlineStyle",value:function(){return 268435456&this.fg?268435456&this.bg?this.extended.underlineStyle:1:0}}],[{key:"toColorRGB",value:function(e){return[e>>>16&255,e>>>8&255,255&e]}},{key:"fromColorRGB",value:function(e){return(255&e[0])<<16|(255&e[1])<<8|255&e[2]}}]),e}();t.AttributeData=i;var r=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;l(this,e),this._ext=0,this._urlId=0,this._ext=t,this._urlId=i}return u(e,[{key:"ext",get:function(){return this._urlId?-469762049&this._ext|this.underlineStyle<<26:this._ext},set:function(e){this._ext=e}},{key:"underlineStyle",get:function(){return this._urlId?5:(469762048&this._ext)>>26},set:function(e){this._ext&=-469762049,this._ext|=e<<26&469762048}},{key:"underlineColor",get:function(){return 67108863&this._ext},set:function(e){this._ext&=-67108864,this._ext|=67108863&e}},{key:"urlId",get:function(){return this._urlId},set:function(e){this._urlId=e}},{key:"clone",value:function(){return new e(this._ext,this._urlId)}},{key:"isEmpty",value:function(){return 0===this.underlineStyle&&0===this._urlId}}]),e}();t.ExtendedAttrs=r},782:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.CellData=void 0;var r=i(133),n=i(855),s=i(147),o=function(e){h(i,e);var t=f(i);function i(){var e;return l(this,i),(e=t.apply(this,arguments)).content=0,e.fg=0,e.bg=0,e.extended=new s.ExtendedAttrs,e.combinedData="",e}return u(i,[{key:"isCombined",value:function(){return 2097152&this.content}},{key:"getWidth",value:function(){return this.content>>22}},{key:"getChars",value:function(){return 2097152&this.content?this.combinedData:2097151&this.content?(0,r.stringFromCodePoint)(2097151&this.content):""}},{key:"getCode",value:function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content}},{key:"setFromCharData",value:function(e){this.fg=e[n.CHAR_DATA_ATTR_INDEX],this.bg=0;var t=!1;if(e[n.CHAR_DATA_CHAR_INDEX].length>2)t=!0;else if(2===e[n.CHAR_DATA_CHAR_INDEX].length){var i=e[n.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=i&&i<=56319){var r=e[n.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=r&&r<=57343?this.content=1024*(i-55296)+r-56320+65536|e[n.CHAR_DATA_WIDTH_INDEX]<<22:t=!0}else t=!0}else this.content=e[n.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|e[n.CHAR_DATA_WIDTH_INDEX]<<22;t&&(this.combinedData=e[n.CHAR_DATA_CHAR_INDEX],this.content=2097152|e[n.CHAR_DATA_WIDTH_INDEX]<<22)}},{key:"getAsCharData",value:function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}],[{key:"fromCharData",value:function(e){var t=new i;return t.setFromCharData(e),t}}]),i}(s.AttributeData);t.CellData=o},855:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.WHITESPACE_CELL_CODE=t.WHITESPACE_CELL_WIDTH=t.WHITESPACE_CELL_CHAR=t.NULL_CELL_CODE=t.NULL_CELL_WIDTH=t.NULL_CELL_CHAR=t.CHAR_DATA_CODE_INDEX=t.CHAR_DATA_WIDTH_INDEX=t.CHAR_DATA_CHAR_INDEX=t.CHAR_DATA_ATTR_INDEX=t.DEFAULT_EXT=t.DEFAULT_ATTR=t.DEFAULT_COLOR=void 0,t.DEFAULT_COLOR=0,t.DEFAULT_ATTR=256|t.DEFAULT_COLOR<<9,t.DEFAULT_EXT=0,t.CHAR_DATA_ATTR_INDEX=0,t.CHAR_DATA_CHAR_INDEX=1,t.CHAR_DATA_WIDTH_INDEX=2,t.CHAR_DATA_CODE_INDEX=3,t.NULL_CELL_CHAR="",t.NULL_CELL_WIDTH=1,t.NULL_CELL_CODE=0,t.WHITESPACE_CELL_CHAR=" ",t.WHITESPACE_CELL_WIDTH=1,t.WHITESPACE_CELL_CODE=32},133:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ToUtf32=t.StringToUtf32=t.utf32ToString=t.stringFromCodePoint=void 0,t.stringFromCodePoint=function(e){return e>65535?(e-=65536,String.fromCharCode(55296+(e>>10))+String.fromCharCode(e%1024+56320)):String.fromCharCode(e)},t.utf32ToString=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,r="",n=t;n<i;++n){var s=e[n];s>65535?(s-=65536,r+=String.fromCharCode(55296+(s>>10))+String.fromCharCode(s%1024+56320)):r+=String.fromCharCode(s)}return r},t.StringToUtf32=function(){function e(){l(this,e),this._interim=0}return u(e,[{key:"clear",value:function(){this._interim=0}},{key:"decode",value:function(e,t){var i=e.length;if(!i)return 0;var r=0,n=0;if(this._interim){var s=e.charCodeAt(n++);56320<=s&&s<=57343?t[r++]=1024*(this._interim-55296)+s-56320+65536:(t[r++]=this._interim,t[r++]=s),this._interim=0}for(var o=n;o<i;++o){var a=e.charCodeAt(o);if(55296<=a&&a<=56319){if(++o>=i)return this._interim=a,r;var c=e.charCodeAt(o);56320<=c&&c<=57343?t[r++]=1024*(a-55296)+c-56320+65536:(t[r++]=a,t[r++]=c)}else 65279!==a&&(t[r++]=a)}return r}}]),e}(),t.Utf8ToUtf32=function(){function e(){l(this,e),this.interim=new Uint8Array(3)}return u(e,[{key:"clear",value:function(){this.interim.fill(0)}},{key:"decode",value:function(e,t){var i=e.length;if(!i)return 0;var r,n,s,o,a=0,c=0,l=0;if(this.interim[0]){var u=!1,h=this.interim[0];h&=192==(224&h)?31:224==(240&h)?15:7;for(var f,d=0;(f=63&this.interim[++d])&&d<4;)h<<=6,h|=f;for(var v=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,_=v-d;l<_;){if(l>=i)return 0;if(128!=(192&(f=e[l++]))){l--,u=!0;break}this.interim[d++]=f,h<<=6,h|=63&f}u||(2===v?h<128?l--:t[a++]=h:3===v?h<2048||h>=55296&&h<=57343||65279===h||(t[a++]=h):h<65536||h>1114111||(t[a++]=h)),this.interim.fill(0)}for(var p=i-4,g=l;g<i;){for(;!(!(g<p)||128&(r=e[g])||128&(n=e[g+1])||128&(s=e[g+2])||128&(o=e[g+3]));)t[a++]=r,t[a++]=n,t[a++]=s,t[a++]=o,g+=4;if((r=e[g++])<128)t[a++]=r;else if(192==(224&r)){if(g>=i)return this.interim[0]=r,a;if(128!=(192&(n=e[g++]))){g--;continue}if((c=(31&r)<<6|63&n)<128){g--;continue}t[a++]=c}else if(224==(240&r)){if(g>=i)return this.interim[0]=r,a;if(128!=(192&(n=e[g++]))){g--;continue}if(g>=i)return this.interim[0]=r,this.interim[1]=n,a;if(128!=(192&(s=e[g++]))){g--;continue}if((c=(15&r)<<12|(63&n)<<6|63&s)<2048||c>=55296&&c<=57343||65279===c)continue;t[a++]=c}else if(240==(248&r)){if(g>=i)return this.interim[0]=r,a;if(128!=(192&(n=e[g++]))){g--;continue}if(g>=i)return this.interim[0]=r,this.interim[1]=n,a;if(128!=(192&(s=e[g++]))){g--;continue}if(g>=i)return this.interim[0]=r,this.interim[1]=n,this.interim[2]=s,a;if(128!=(192&(o=e[g++]))){g--;continue}if((c=(7&r)<<18|(63&n)<<12|(63&s)<<6|63&o)<65536||c>1114111)continue;t[a++]=c}}return a}}]),e}()},726:function(e,t){function i(e,t,i){t.di$target===t?t.di$dependencies.push({id:e,index:i}):(t.di$dependencies=[{id:e,index:i}],t.di$target=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.createDecorator=t.getServiceDependencies=t.serviceRegistry=void 0,t.serviceRegistry=new Map,t.getServiceDependencies=function(e){return e.di$dependencies||[]},t.createDecorator=function(e){if(t.serviceRegistry.has(e))return t.serviceRegistry.get(e);var r=function e(t,r,n){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");i(e,t,n)};return r.toString=function(){return e},t.serviceRegistry.set(e,r),r}},97:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.IDecorationService=t.IUnicodeService=t.IOscLinkService=t.IOptionsService=t.ILogService=t.LogLevelEnum=t.IInstantiationService=t.ICharsetService=t.ICoreService=t.ICoreMouseService=t.IBufferService=void 0;var r,n=i(726);t.IBufferService=(0,n.createDecorator)("BufferService"),t.ICoreMouseService=(0,n.createDecorator)("CoreMouseService"),t.ICoreService=(0,n.createDecorator)("CoreService"),t.ICharsetService=(0,n.createDecorator)("CharsetService"),t.IInstantiationService=(0,n.createDecorator)("InstantiationService"),(r=t.LogLevelEnum||(t.LogLevelEnum={}))[r.DEBUG=0]="DEBUG",r[r.INFO=1]="INFO",r[r.WARN=2]="WARN",r[r.ERROR=3]="ERROR",r[r.OFF=4]="OFF",t.ILogService=(0,n.createDecorator)("LogService"),t.IOptionsService=(0,n.createDecorator)("OptionsService"),t.IOscLinkService=(0,n.createDecorator)("OscLinkService"),t.IUnicodeService=(0,n.createDecorator)("UnicodeService"),t.IDecorationService=(0,n.createDecorator)("DecorationService")}},t={};function i(r){var n=t[r];if(void 0!==n)return n.exports;var s=t[r]={exports:{}};return e[r].call(s.exports,s,s.exports,i),s.exports}var d={};return function(){var e=d;Object.defineProperty(e,"__esModule",{value:!0}),e.CanvasAddon=void 0;var t=i(949),r=i(345),n=i(859),s=function(e){h(s,e);var i=f(s);function s(){var e;return l(this,s),(e=i.apply(this,arguments))._onChangeTextureAtlas=e.register(new r.EventEmitter),e.onChangeTextureAtlas=e._onChangeTextureAtlas.event,e._onAddTextureAtlasCanvas=e.register(new r.EventEmitter),e.onAddTextureAtlasCanvas=e._onAddTextureAtlasCanvas.event,e}return u(s,[{key:"textureAtlas",get:function(){var e;return null===(e=this._renderer)||void 0===e?void 0:e.textureAtlas}},{key:"activate",value:function(e){var i=this,s=e._core;if(e.element){this._terminal=e;var o=s.coreService,a=s.optionsService,c=s.screenElement,l=s.linkifier2,u=s,h=u._bufferService,f=u._renderService,d=u._characterJoinerService,v=u._charSizeService,_=u._coreBrowserService,p=u._decorationService,g=u._themeService;this._renderer=new t.CanvasRenderer(e,c,l,h,v,a,d,o,_,p,g),this.register((0,r.forwardEvent)(this._renderer.onChangeTextureAtlas,this._onChangeTextureAtlas)),this.register((0,r.forwardEvent)(this._renderer.onAddTextureAtlasCanvas,this._onAddTextureAtlasCanvas)),f.setRenderer(this._renderer),f.handleResize(h.cols,h.rows),this.register((0,n.toDisposable)((function(){var t;f.setRenderer(i._terminal._core._createRenderer()),f.handleResize(e.cols,e.rows),null===(t=i._renderer)||void 0===t||t.dispose(),i._renderer=void 0})))}else this.register(s.onWillOpen((function(){return i.activate(e)})))}}]),s}(n.Disposable);e.CanvasAddon=s}(),d}()},2699:function(e,t,i){var r=i(3515).default,n=i(7061).default,s=i(4993).default,o=i(861).default,a=i(1588).default,c=i(4968).default,l=i(7424).default,u=i(4704).default,h=i(6690).default,f=i(9728).default,d=i(6115).default,v=i(1655).default,_=i(6389).default;self,e.exports=function(){"use strict";var e={4567:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.AccessibilityManager=void 0;var r=i(9042),n=i(6114),s=i(9924),o=i(3656),a=i(844),c=i(5596),l=i(9631),u=function(e){v(i,e);var t=_(i);function i(e,r){var n;h(this,i),(n=t.call(this))._terminal=e,n._renderService=r,n._liveRegionLineCount=0,n._charsToConsume=[],n._charsToAnnounce="",n._accessibilityTreeRoot=document.createElement("div"),n._accessibilityTreeRoot.classList.add("xterm-accessibility"),n._accessibilityTreeRoot.tabIndex=0,n._rowContainer=document.createElement("div"),n._rowContainer.setAttribute("role","list"),n._rowContainer.classList.add("xterm-accessibility-tree"),n._rowElements=[];for(var u=0;u<n._terminal.rows;u++)n._rowElements[u]=n._createAccessibilityTreeNode(),n._rowContainer.appendChild(n._rowElements[u]);if(n._topBoundaryFocusListener=function(e){return n._handleBoundaryFocus(e,0)},n._bottomBoundaryFocusListener=function(e){return n._handleBoundaryFocus(e,1)},n._rowElements[0].addEventListener("focus",n._topBoundaryFocusListener),n._rowElements[n._rowElements.length-1].addEventListener("focus",n._bottomBoundaryFocusListener),n._refreshRowsDimensions(),n._accessibilityTreeRoot.appendChild(n._rowContainer),n._renderRowsDebouncer=new s.TimeBasedDebouncer(n._renderRows.bind(d(n))),n._refreshRows(),n._liveRegion=document.createElement("div"),n._liveRegion.classList.add("live-region"),n._liveRegion.setAttribute("aria-live","assertive"),n._accessibilityTreeRoot.appendChild(n._liveRegion),!n._terminal.element)throw new Error("Cannot enable accessibility before Terminal.open");return n._terminal.element.insertAdjacentElement("afterbegin",n._accessibilityTreeRoot),n.register(n._renderRowsDebouncer),n.register(n._terminal.onResize((function(e){return n._handleResize(e.rows)}))),n.register(n._terminal.onRender((function(e){return n._refreshRows(e.start,e.end)}))),n.register(n._terminal.onScroll((function(){return n._refreshRows()}))),n.register(n._terminal.onA11yChar((function(e){return n._handleChar(e)}))),n.register(n._terminal.onLineFeed((function(){return n._handleChar("\n")}))),n.register(n._terminal.onA11yTab((function(e){return n._handleTab(e)}))),n.register(n._terminal.onKey((function(e){return n._handleKey(e.key)}))),n.register(n._terminal.onBlur((function(){return n._clearLiveRegion()}))),n.register(n._renderService.onDimensionsChange((function(){return n._refreshRowsDimensions()}))),n._screenDprMonitor=new c.ScreenDprMonitor(window),n.register(n._screenDprMonitor),n._screenDprMonitor.setListener((function(){return n._refreshRowsDimensions()})),n.register((0,o.addDisposableDomListener)(window,"resize",(function(){return n._refreshRowsDimensions()}))),n.register((0,a.toDisposable)((function(){(0,l.removeElementFromParent)(n._accessibilityTreeRoot),n._rowElements.length=0}))),n}return f(i,[{key:"_handleBoundaryFocus",value:function(e,t){var i=e.target,r=this._rowElements[0===t?1:this._rowElements.length-2];if(i.getAttribute("aria-posinset")!==(0===t?"1":"".concat(this._terminal.buffer.lines.length))&&e.relatedTarget===r){var n,s;if(0===t?(n=i,s=this._rowElements.pop(),this._rowContainer.removeChild(s)):(n=this._rowElements.shift(),s=i,this._rowContainer.removeChild(n)),n.removeEventListener("focus",this._topBoundaryFocusListener),s.removeEventListener("focus",this._bottomBoundaryFocusListener),0===t){var o=this._createAccessibilityTreeNode();this._rowElements.unshift(o),this._rowContainer.insertAdjacentElement("afterbegin",o)}else{var a=this._createAccessibilityTreeNode();this._rowElements.push(a),this._rowContainer.appendChild(a)}this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._terminal.scrollLines(0===t?-1:1),this._rowElements[0===t?1:this._rowElements.length-2].focus(),e.preventDefault(),e.stopImmediatePropagation()}}},{key:"_handleResize",value:function(e){this._rowElements[this._rowElements.length-1].removeEventListener("focus",this._bottomBoundaryFocusListener);for(var t=this._rowContainer.children.length;t<this._terminal.rows;t++)this._rowElements[t]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[t]);for(;this._rowElements.length>e;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()}},{key:"_createAccessibilityTreeNode",value:function(){var e=document.createElement("div");return e.setAttribute("role","listitem"),e.tabIndex=-1,this._refreshRowDimensions(e),e}},{key:"_handleTab",value:function(e){for(var t=0;t<e;t++)this._handleChar(" ")}},{key:"_handleChar",value:function(e){var t=this;this._liveRegionLineCount<21&&(this._charsToConsume.length>0?this._charsToConsume.shift()!==e&&(this._charsToAnnounce+=e):this._charsToAnnounce+=e,"\n"===e&&(this._liveRegionLineCount++,21===this._liveRegionLineCount&&(this._liveRegion.textContent+=r.tooMuchOutput)),n.isMac&&this._liveRegion.textContent&&this._liveRegion.textContent.length>0&&!this._liveRegion.parentNode&&setTimeout((function(){t._accessibilityTreeRoot.appendChild(t._liveRegion)}),0))}},{key:"_clearLiveRegion",value:function(){this._liveRegion.textContent="",this._liveRegionLineCount=0,n.isMac&&(0,l.removeElementFromParent)(this._liveRegion)}},{key:"_handleKey",value:function(e){this._clearLiveRegion(),/[\0-\x1F\x7F-\x9F]/.test(e)||this._charsToConsume.push(e)}},{key:"_refreshRows",value:function(e,t){this._renderRowsDebouncer.refresh(e,t,this._terminal.rows)}},{key:"_renderRows",value:function(e,t){for(var i=this._terminal.buffer,r=i.lines.length.toString(),n=e;n<=t;n++){var s=i.translateBufferLineToString(i.ydisp+n,!0),o=(i.ydisp+n+1).toString(),a=this._rowElements[n];a&&(0===s.length?a.innerText="\xa0":a.textContent=s,a.setAttribute("aria-posinset",o),a.setAttribute("aria-setsize",r))}this._announceCharacters()}},{key:"_refreshRowsDimensions",value:function(){if(this._renderService.dimensions.css.cell.height){this._accessibilityTreeRoot.style.width="".concat(this._renderService.dimensions.css.canvas.width,"px"),this._rowElements.length!==this._terminal.rows&&this._handleResize(this._terminal.rows);for(var e=0;e<this._terminal.rows;e++)this._refreshRowDimensions(this._rowElements[e])}}},{key:"_refreshRowDimensions",value:function(e){e.style.height="".concat(this._renderService.dimensions.css.cell.height,"px")}},{key:"_announceCharacters",value:function(){0!==this._charsToAnnounce.length&&(this._liveRegion.textContent+=this._charsToAnnounce,this._charsToAnnounce="")}}]),i}(a.Disposable);t.AccessibilityManager=u},3614:function(e,t){function i(e){return e.replace(/\r?\n/g,"\r")}function r(e,t){return t?"\x1b[200~"+e+"\x1b[201~":e}function n(e,t,n){e=r(e=i(e),n.decPrivateModes.bracketedPasteMode),n.triggerDataEvent(e,!0),t.value=""}function s(e,t,i){var r=i.getBoundingClientRect(),n=e.clientX-r.left-10,s=e.clientY-r.top-10;t.style.width="20px",t.style.height="20px",t.style.left="".concat(n,"px"),t.style.top="".concat(s,"px"),t.style.zIndex="1000",t.focus()}Object.defineProperty(t,"__esModule",{value:!0}),t.rightClickHandler=t.moveTextAreaUnderMouseCursor=t.paste=t.handlePasteEvent=t.copyHandler=t.bracketTextForPaste=t.prepareTextForTerminal=void 0,t.prepareTextForTerminal=i,t.bracketTextForPaste=r,t.copyHandler=function(e,t){e.clipboardData&&e.clipboardData.setData("text/plain",t.selectionText),e.preventDefault()},t.handlePasteEvent=function(e,t,i){e.stopPropagation(),e.clipboardData&&n(e.clipboardData.getData("text/plain"),t,i)},t.paste=n,t.moveTextAreaUnderMouseCursor=s,t.rightClickHandler=function(e,t,i,r,n){s(e,t,i),n&&r.rightClickSelect(e),t.value=r.selectionText,t.select()}},7239:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.ColorContrastCache=void 0;var r=i(1505);t.ColorContrastCache=function(){function e(){h(this,e),this._color=new r.TwoKeyMap,this._css=new r.TwoKeyMap}return f(e,[{key:"setCss",value:function(e,t,i){this._css.set(e,t,i)}},{key:"getCss",value:function(e,t){return this._css.get(e,t)}},{key:"setColor",value:function(e,t,i){this._color.set(e,t,i)}},{key:"getColor",value:function(e,t){return this._color.get(e,t)}},{key:"clear",value:function(){this._color.clear(),this._css.clear()}}]),e}()},9631:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.removeElementFromParent=void 0,t.removeElementFromParent=function(){for(var e,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];for(var n=0,s=i;n<s.length;n++){var o=s[n];null===(e=null==o?void 0:o.parentElement)||void 0===e||e.removeChild(o)}}},3656:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.addDisposableDomListener=void 0,t.addDisposableDomListener=function(e,t,i,r){e.addEventListener(t,i,r);var n=!1;return{dispose:function(){n||(n=!0,e.removeEventListener(t,i,r))}}}},6465:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Linkifier2=void 0;var s=i(2585),o=i(8460),a=i(844),c=i(3656),d=function(e){v(i,e);var t=_(i);function i(e){var r;return h(this,i),(r=t.call(this))._bufferService=e,r._linkProviders=[],r._linkCacheDisposables=[],r._isMouseOut=!0,r._activeLine=-1,r._onShowLinkUnderline=r.register(new o.EventEmitter),r.onShowLinkUnderline=r._onShowLinkUnderline.event,r._onHideLinkUnderline=r.register(new o.EventEmitter),r.onHideLinkUnderline=r._onHideLinkUnderline.event,r.register((0,a.getDisposeArrayDisposable)(r._linkCacheDisposables)),r.register((0,a.toDisposable)((function(){r._lastMouseEvent=void 0}))),r}return f(i,[{key:"currentLink",get:function(){return this._currentLink}},{key:"registerLinkProvider",value:function(e){var t=this;return this._linkProviders.push(e),{dispose:function(){var i=t._linkProviders.indexOf(e);-1!==i&&t._linkProviders.splice(i,1)}}}},{key:"attachToDom",value:function(e,t,i){var r=this;this._element=e,this._mouseService=t,this._renderService=i,this.register((0,c.addDisposableDomListener)(this._element,"mouseleave",(function(){r._isMouseOut=!0,r._clearCurrentLink()}))),this.register((0,c.addDisposableDomListener)(this._element,"mousemove",this._handleMouseMove.bind(this))),this.register((0,c.addDisposableDomListener)(this._element,"mousedown",this._handleMouseDown.bind(this))),this.register((0,c.addDisposableDomListener)(this._element,"mouseup",this._handleMouseUp.bind(this)))}},{key:"_handleMouseMove",value:function(e){if(this._lastMouseEvent=e,this._element&&this._mouseService){var t=this._positionFromMouseEvent(e,this._element,this._mouseService);if(t){this._isMouseOut=!1;for(var i=e.composedPath(),r=0;r<i.length;r++){var n=i[r];if(n.classList.contains("xterm"))break;if(n.classList.contains("xterm-hover"))return}this._lastBufferCell&&t.x===this._lastBufferCell.x&&t.y===this._lastBufferCell.y||(this._handleHover(t),this._lastBufferCell=t)}}}},{key:"_handleHover",value:function(e){if(this._activeLine!==e.y)return this._clearCurrentLink(),void this._askForLink(e,!1);this._currentLink&&this._linkAtPosition(this._currentLink.link,e)||(this._clearCurrentLink(),this._askForLink(e,!0))}},{key:"_askForLink",value:function(e,t){var i,r,n=this;this._activeProviderReplies&&t||(null===(i=this._activeProviderReplies)||void 0===i||i.forEach((function(e){null==e||e.forEach((function(e){e.link.dispose&&e.link.dispose()}))})),this._activeProviderReplies=new Map,this._activeLine=e.y);var s,o=!1,a=u(this._linkProviders.entries());try{var c=function(){var i=l(s.value,2),a=i[0],c=i[1];t?(null===(r=n._activeProviderReplies)||void 0===r?void 0:r.get(a))&&(o=n._checkLinkProviderResult(a,e,o)):c.provideLinks(e.y,(function(t){var i,r;if(!n._isMouseOut){var s=null==t?void 0:t.map((function(e){return{link:e}}));null===(i=n._activeProviderReplies)||void 0===i||i.set(a,s),o=n._checkLinkProviderResult(a,e,o),(null===(r=n._activeProviderReplies)||void 0===r?void 0:r.size)===n._linkProviders.length&&n._removeIntersectingLinks(e.y,n._activeProviderReplies)}}))};for(a.s();!(s=a.n()).done;)c()}catch(h){a.e(h)}finally{a.f()}}},{key:"_removeIntersectingLinks",value:function(e,t){for(var i=new Set,r=0;r<t.size;r++){var n=t.get(r);if(n)for(var s=0;s<n.length;s++)for(var o=n[s],a=o.link.range.start.y<e?0:o.link.range.start.x,c=o.link.range.end.y>e?this._bufferService.cols:o.link.range.end.x,l=a;l<=c;l++){if(i.has(l)){n.splice(s--,1);break}i.add(l)}}}},{key:"_checkLinkProviderResult",value:function(e,t,i){var r,n=this;if(!this._activeProviderReplies)return i;for(var s=this._activeProviderReplies.get(e),o=!1,a=0;a<e;a++)this._activeProviderReplies.has(a)&&!this._activeProviderReplies.get(a)||(o=!0);if(!o&&s){var c=s.find((function(e){return n._linkAtPosition(e.link,t)}));c&&(i=!0,this._handleNewLink(c))}if(this._activeProviderReplies.size===this._linkProviders.length&&!i)for(var l=0;l<this._activeProviderReplies.size;l++){var u=null===(r=this._activeProviderReplies.get(l))||void 0===r?void 0:r.find((function(e){return n._linkAtPosition(e.link,t)}));if(u){i=!0,this._handleNewLink(u);break}}return i}},{key:"_handleMouseDown",value:function(){this._mouseDownLink=this._currentLink}},{key:"_handleMouseUp",value:function(e){if(this._element&&this._mouseService&&this._currentLink){var t=this._positionFromMouseEvent(e,this._element,this._mouseService);t&&this._mouseDownLink===this._currentLink&&this._linkAtPosition(this._currentLink.link,t)&&this._currentLink.link.activate(e,this._currentLink.link.text)}}},{key:"_clearCurrentLink",value:function(e,t){this._element&&this._currentLink&&this._lastMouseEvent&&(!e||!t||this._currentLink.link.range.start.y>=e&&this._currentLink.link.range.end.y<=t)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,(0,a.disposeArray)(this._linkCacheDisposables))}},{key:"_handleNewLink",value:function(e){var t=this;if(this._element&&this._lastMouseEvent&&this._mouseService){var i=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);i&&this._linkAtPosition(e.link,i)&&(this._currentLink=e,this._currentLink.state={decorations:{underline:void 0===e.link.decorations||e.link.decorations.underline,pointerCursor:void 0===e.link.decorations||e.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,e.link,this._lastMouseEvent),e.link.decorations={},Object.defineProperties(e.link.decorations,{pointerCursor:{get:function(){var e,i;return null===(i=null===(e=t._currentLink)||void 0===e?void 0:e.state)||void 0===i?void 0:i.decorations.pointerCursor},set:function(e){var i,r;(null===(i=t._currentLink)||void 0===i?void 0:i.state)&&t._currentLink.state.decorations.pointerCursor!==e&&(t._currentLink.state.decorations.pointerCursor=e,t._currentLink.state.isHovered&&(null===(r=t._element)||void 0===r||r.classList.toggle("xterm-cursor-pointer",e)))}},underline:{get:function(){var e,i;return null===(i=null===(e=t._currentLink)||void 0===e?void 0:e.state)||void 0===i?void 0:i.decorations.underline},set:function(i){var r,n,s;(null===(r=t._currentLink)||void 0===r?void 0:r.state)&&(null===(s=null===(n=t._currentLink)||void 0===n?void 0:n.state)||void 0===s?void 0:s.decorations.underline)!==i&&(t._currentLink.state.decorations.underline=i,t._currentLink.state.isHovered&&t._fireUnderlineEvent(e.link,i))}}}),this._renderService&&this._linkCacheDisposables.push(this._renderService.onRenderedViewportChange((function(e){var i=0===e.start?0:e.start+1+t._bufferService.buffer.ydisp,r=t._currentLink?t._lastMouseEvent:void 0;if(t._clearCurrentLink(i,e.end+1+t._bufferService.buffer.ydisp),r&&t._element){var n=t._positionFromMouseEvent(r,t._element,t._mouseService);n&&t._askForLink(n,!1)}}))))}}},{key:"_linkHover",value:function(e,t,i){var r;(null===(r=this._currentLink)||void 0===r?void 0:r.state)&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!0),this._currentLink.state.decorations.pointerCursor&&e.classList.add("xterm-cursor-pointer")),t.hover&&t.hover(i,t.text)}},{key:"_fireUnderlineEvent",value:function(e,t){var i=e.range,r=this._bufferService.buffer.ydisp,n=this._createLinkUnderlineEvent(i.start.x-1,i.start.y-r-1,i.end.x,i.end.y-r-1,void 0);(t?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(n)}},{key:"_linkLeave",value:function(e,t,i){var r;(null===(r=this._currentLink)||void 0===r?void 0:r.state)&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!1),this._currentLink.state.decorations.pointerCursor&&e.classList.remove("xterm-cursor-pointer")),t.leave&&t.leave(i,t.text)}},{key:"_linkAtPosition",value:function(e,t){var i=e.range.start.y*this._bufferService.cols+e.range.start.x,r=e.range.end.y*this._bufferService.cols+e.range.end.x,n=t.y*this._bufferService.cols+t.x;return i<=n&&n<=r}},{key:"_positionFromMouseEvent",value:function(e,t,i){var r=i.getCoords(e,t,this._bufferService.cols,this._bufferService.rows);if(r)return{x:r[0],y:r[1]+this._bufferService.buffer.ydisp}}},{key:"_createLinkUnderlineEvent",value:function(e,t,i,r,n){return{x1:e,y1:t,x2:i,y2:r,cols:this._bufferService.cols,fg:n}}}]),i}(a.Disposable);d=r([n(0,s.IBufferService)],d),t.Linkifier2=d},9042:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.tooMuchOutput=t.promptLabel=void 0,t.promptLabel="Terminal input",t.tooMuchOutput="Too much output to announce, navigate to rows manually to read"},3730:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.OscLinkProvider=void 0;var s=i(511),o=i(2585),a=function(){function e(t,i,r){h(this,e),this._bufferService=t,this._optionsService=i,this._oscLinkService=r}return f(e,[{key:"provideLinks",value:function(e,t){var i,r=this._bufferService.buffer.lines.get(e-1);if(r){for(var n=[],o=this._optionsService.rawOptions.linkHandler,a=new s.CellData,l=r.getTrimmedLength(),u=-1,h=-1,f=!1,d=0;d<l;d++)if(-1!==h||r.hasContent(d)){if(r.loadCell(d,a),a.hasExtendedAttrs()&&a.extended.urlId){if(-1===h){h=d,u=a.extended.urlId;continue}f=a.extended.urlId!==u}else-1!==h&&(f=!0);if(f||-1!==h&&d===l-1){var v=null===(i=this._oscLinkService.getLinkData(u))||void 0===i?void 0:i.uri;if(v){var _={start:{x:h+1,y:e},end:{x:d+(f||d!==l-1?0:1),y:e}},p=!1;if(!(null==o?void 0:o.allowNonHttpProtocols))try{var g=new URL(v);["http:","https:"].includes(g.protocol)||(p=!0)}catch(e){p=!0}p||n.push({text:v,range:_,activate:function(e,t){return o?o.activate(e,t,_):c(0,t)},hover:function(e,t){var i;return null===(i=null==o?void 0:o.hover)||void 0===i?void 0:i.call(o,e,t,_)},leave:function(e,t){var i;return null===(i=null==o?void 0:o.leave)||void 0===i?void 0:i.call(o,e,t,_)}})}f=!1,a.hasExtendedAttrs()&&a.extended.urlId?(h=d,u=a.extended.urlId):(h=-1,u=-1)}}t(n)}else t(void 0)}}]),e}();function c(e,t){if(confirm("Do you want to navigate to ".concat(t,"?\n\nWARNING: This link could potentially be dangerous"))){var i=window.open();if(i){try{i.opener=null}catch(e){}i.location.href=t}else console.warn("Opening link blocked as opener could not be cleared")}}a=r([n(0,o.IBufferService),n(1,o.IOptionsService),n(2,o.IOscLinkService)],a),t.OscLinkProvider=a},6193:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.RenderDebouncer=void 0,t.RenderDebouncer=function(){function e(t,i){h(this,e),this._parentWindow=t,this._renderCallback=i,this._refreshCallbacks=[]}return f(e,[{key:"dispose",value:function(){this._animationFrame&&(this._parentWindow.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}},{key:"addRefreshCallback",value:function(e){var t=this;return this._refreshCallbacks.push(e),this._animationFrame||(this._animationFrame=this._parentWindow.requestAnimationFrame((function(){return t._innerRefresh()}))),this._animationFrame}},{key:"refresh",value:function(e,t,i){var r=this;this._rowCount=i,e=void 0!==e?e:0,t=void 0!==t?t:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,e):e,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,t):t,this._animationFrame||(this._animationFrame=this._parentWindow.requestAnimationFrame((function(){return r._innerRefresh()})))}},{key:"_innerRefresh",value:function(){if(this._animationFrame=void 0,void 0!==this._rowStart&&void 0!==this._rowEnd&&void 0!==this._rowCount){var e=Math.max(this._rowStart,0),t=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._renderCallback(e,t),this._runRefreshCallbacks()}else this._runRefreshCallbacks()}},{key:"_runRefreshCallbacks",value:function(){var e,t=u(this._refreshCallbacks);try{for(t.s();!(e=t.n()).done;)(0,e.value)(0)}catch(i){t.e(i)}finally{t.f()}this._refreshCallbacks=[]}}]),e}()},5596:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.ScreenDprMonitor=void 0;var r=i(844),n=function(e){v(i,e);var t=_(i);function i(e){var n;return h(this,i),(n=t.call(this))._parentWindow=e,n._currentDevicePixelRatio=n._parentWindow.devicePixelRatio,n.register((0,r.toDisposable)((function(){n.clearListener()}))),n}return f(i,[{key:"setListener",value:function(e){var t=this;this._listener&&this.clearListener(),this._listener=e,this._outerListener=function(){t._listener&&(t._listener(t._parentWindow.devicePixelRatio,t._currentDevicePixelRatio),t._updateDpr())},this._updateDpr()}},{key:"_updateDpr",value:function(){var e;this._outerListener&&(null===(e=this._resolutionMediaMatchList)||void 0===e||e.removeListener(this._outerListener),this._currentDevicePixelRatio=this._parentWindow.devicePixelRatio,this._resolutionMediaMatchList=this._parentWindow.matchMedia("screen and (resolution: ".concat(this._parentWindow.devicePixelRatio,"dppx)")),this._resolutionMediaMatchList.addListener(this._outerListener))}},{key:"clearListener",value: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}(r.Disposable);t.ScreenDprMonitor=n},3236:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.Terminal=void 0;var r=i(2950),n=i(1680),s=i(3614),l=i(2584),d=i(5435),p=i(9312),g=i(6114),m=i(3656),y=i(9042),b=i(4567),C=i(1296),S=i(7399),w=i(8460),k=i(8437),x=i(3230),L=i(4725),E=i(428),R=i(8934),M=i(6465),A=i(5114),D=i(8969),O=i(8055),T=i(4269),B=i(5941),I=i(3107),P=i(5744),F=i(9074),H=i(2585),N=i(3730),W=i(844),U=i(6731),j="undefined"!=typeof window?window.document:null,z=function(e){v(i,e);var t=_(i);function i(){var e,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return h(this,i),(e=t.call(this,r)).browser=g,e._keyDownHandled=!1,e._keyDownSeen=!1,e._keyPressHandled=!1,e._unprocessedDeadKey=!1,e._onCursorMove=e.register(new w.EventEmitter),e.onCursorMove=e._onCursorMove.event,e._onKey=e.register(new w.EventEmitter),e.onKey=e._onKey.event,e._onRender=e.register(new w.EventEmitter),e.onRender=e._onRender.event,e._onSelectionChange=e.register(new w.EventEmitter),e.onSelectionChange=e._onSelectionChange.event,e._onTitleChange=e.register(new w.EventEmitter),e.onTitleChange=e._onTitleChange.event,e._onBell=e.register(new w.EventEmitter),e.onBell=e._onBell.event,e._onFocus=e.register(new w.EventEmitter),e._onBlur=e.register(new w.EventEmitter),e._onA11yCharEmitter=e.register(new w.EventEmitter),e._onA11yTabEmitter=e.register(new w.EventEmitter),e._onWillOpen=e.register(new w.EventEmitter),e._setup(),e.linkifier2=e.register(e._instantiationService.createInstance(M.Linkifier2)),e.linkifier2.registerLinkProvider(e._instantiationService.createInstance(N.OscLinkProvider)),e._decorationService=e._instantiationService.createInstance(F.DecorationService),e._instantiationService.setService(H.IDecorationService,e._decorationService),e.register(e._inputHandler.onRequestBell((function(){return e._onBell.fire()}))),e.register(e._inputHandler.onRequestRefreshRows((function(t,i){return e.refresh(t,i)}))),e.register(e._inputHandler.onRequestSendFocus((function(){return e._reportFocus()}))),e.register(e._inputHandler.onRequestReset((function(){return e.reset()}))),e.register(e._inputHandler.onRequestWindowsOptionsReport((function(t){return e._reportWindowsOptions(t)}))),e.register(e._inputHandler.onColor((function(t){return e._handleColorEvent(t)}))),e.register((0,w.forwardEvent)(e._inputHandler.onCursorMove,e._onCursorMove)),e.register((0,w.forwardEvent)(e._inputHandler.onTitleChange,e._onTitleChange)),e.register((0,w.forwardEvent)(e._inputHandler.onA11yChar,e._onA11yCharEmitter)),e.register((0,w.forwardEvent)(e._inputHandler.onA11yTab,e._onA11yTabEmitter)),e.register(e._bufferService.onResize((function(t){return e._afterResize(t.cols,t.rows)}))),e.register((0,W.toDisposable)((function(){var t,i;e._customKeyEventHandler=void 0,null===(i=null===(t=e.element)||void 0===t?void 0:t.parentNode)||void 0===i||i.removeChild(e.element)}))),e}return f(i,[{key:"onFocus",get:function(){return this._onFocus.event}},{key:"onBlur",get:function(){return this._onBlur.event}},{key:"onA11yChar",get:function(){return this._onA11yCharEmitter.event}},{key:"onA11yTab",get:function(){return this._onA11yTabEmitter.event}},{key:"onWillOpen",get:function(){return this._onWillOpen.event}},{key:"_handleColorEvent",value:function(e){var t=this;if(this._themeService){var i,r=u(e);try{var n=function(){var e,r=i.value,n="";switch(r.index){case 256:e="foreground",n="10";break;case 257:e="background",n="11";break;case 258:e="cursor",n="12";break;default:e="ansi",n="4;"+r.index}switch(r.type){case 0:var s=O.color.toColorRGB("ansi"===e?t._themeService.colors.ansi[r.index]:t._themeService.colors[e]);t.coreService.triggerDataEvent("".concat(l.C0.ESC,"]").concat(n,";").concat((0,B.toRgbString)(s)).concat(l.C1_ESCAPED.ST));break;case 1:if("ansi"===e)t._themeService.modifyColors((function(e){var t;return e.ansi[r.index]=(t=O.rgba).toColor.apply(t,o(r.color))}));else{var a=e;t._themeService.modifyColors((function(e){var t;return e[a]=(t=O.rgba).toColor.apply(t,o(r.color))}))}break;case 2:t._themeService.restoreColor(r.index)}};for(r.s();!(i=r.n()).done;)n()}catch(s){r.e(s)}finally{r.f()}}}},{key:"_setup",value:function(){a(c(i.prototype),"_setup",this).call(this),this._customKeyEventHandler=void 0}},{key:"buffer",get:function(){return this.buffers.active}},{key:"focus",value:function(){this.textarea&&this.textarea.focus({preventScroll:!0})}},{key:"_handleScreenReaderModeOptionChange",value:function(e){var t;e?!this._accessibilityManager&&this._renderService&&(this._accessibilityManager=new b.AccessibilityManager(this,this._renderService)):(null===(t=this._accessibilityManager)||void 0===t||t.dispose(),this._accessibilityManager=void 0)}},{key:"_handleTextAreaFocus",value:function(e){this.coreService.decPrivateModes.sendFocus&&this.coreService.triggerDataEvent(l.C0.ESC+"[I"),this.updateCursorStyle(e),this.element.classList.add("focus"),this._showCursor(),this._onFocus.fire()}},{key:"blur",value:function(){var e;return null===(e=this.textarea)||void 0===e?void 0:e.blur()}},{key:"_handleTextAreaBlur",value:function(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this.coreService.decPrivateModes.sendFocus&&this.coreService.triggerDataEvent(l.C0.ESC+"[O"),this.element.classList.remove("focus"),this._onBlur.fire()}},{key:"_syncTextArea",value:function(){if(this.textarea&&this.buffer.isCursorInViewport&&!this._compositionHelper.isComposing&&this._renderService){var e=this.buffer.ybase+this.buffer.y,t=this.buffer.lines.get(e);if(t){var i=Math.min(this.buffer.x,this.cols-1),r=this._renderService.dimensions.css.cell.height,n=t.getWidth(i),s=this._renderService.dimensions.css.cell.width*n,o=this.buffer.y*this._renderService.dimensions.css.cell.height,a=i*this._renderService.dimensions.css.cell.width;this.textarea.style.left=a+"px",this.textarea.style.top=o+"px",this.textarea.style.width=s+"px",this.textarea.style.height=r+"px",this.textarea.style.lineHeight=r+"px",this.textarea.style.zIndex="-5"}}}},{key:"_initGlobal",value:function(){var e=this;this._bindKeys(),this.register((0,m.addDisposableDomListener)(this.element,"copy",(function(t){e.hasSelection()&&(0,s.copyHandler)(t,e._selectionService)})));var t=function(t){return(0,s.handlePasteEvent)(t,e.textarea,e.coreService)};this.register((0,m.addDisposableDomListener)(this.textarea,"paste",t)),this.register((0,m.addDisposableDomListener)(this.element,"paste",t)),g.isFirefox?this.register((0,m.addDisposableDomListener)(this.element,"mousedown",(function(t){2===t.button&&(0,s.rightClickHandler)(t,e.textarea,e.screenElement,e._selectionService,e.options.rightClickSelectsWord)}))):this.register((0,m.addDisposableDomListener)(this.element,"contextmenu",(function(t){(0,s.rightClickHandler)(t,e.textarea,e.screenElement,e._selectionService,e.options.rightClickSelectsWord)}))),g.isLinux&&this.register((0,m.addDisposableDomListener)(this.element,"auxclick",(function(t){1===t.button&&(0,s.moveTextAreaUnderMouseCursor)(t,e.textarea,e.screenElement)})))}},{key:"_bindKeys",value:function(){var e=this;this.register((0,m.addDisposableDomListener)(this.textarea,"keyup",(function(t){return e._keyUp(t)}),!0)),this.register((0,m.addDisposableDomListener)(this.textarea,"keydown",(function(t){return e._keyDown(t)}),!0)),this.register((0,m.addDisposableDomListener)(this.textarea,"keypress",(function(t){return e._keyPress(t)}),!0)),this.register((0,m.addDisposableDomListener)(this.textarea,"compositionstart",(function(){return e._compositionHelper.compositionstart()}))),this.register((0,m.addDisposableDomListener)(this.textarea,"compositionupdate",(function(t){return e._compositionHelper.compositionupdate(t)}))),this.register((0,m.addDisposableDomListener)(this.textarea,"compositionend",(function(){return e._compositionHelper.compositionend()}))),this.register((0,m.addDisposableDomListener)(this.textarea,"input",(function(t){return e._inputEvent(t)}),!0)),this.register(this.onRender((function(){return e._compositionHelper.updateCompositionElements()})))}},{key:"open",value:function(e){var t,i=this;if(!e)throw new Error("Terminal requires a parent element.");e.isConnected||this._logService.debug("Terminal.open was called on an element that was not attached to the DOM"),this._document=e.ownerDocument,this.element=this._document.createElement("div"),this.element.dir="ltr",this.element.classList.add("terminal"),this.element.classList.add("xterm"),this.element.setAttribute("tabindex","0"),e.appendChild(this.element);var s=j.createDocumentFragment();this._viewportElement=j.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),s.appendChild(this._viewportElement),this._viewportScrollArea=j.createElement("div"),this._viewportScrollArea.classList.add("xterm-scroll-area"),this._viewportElement.appendChild(this._viewportScrollArea),this.screenElement=j.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._helperContainer=j.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),s.appendChild(this.screenElement),this.textarea=j.createElement("textarea"),this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",y.promptLabel),g.isChromeOS||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._coreBrowserService=this._instantiationService.createInstance(A.CoreBrowserService,this.textarea,null!==(t=this._document.defaultView)&&void 0!==t?t:window),this._instantiationService.setService(L.ICoreBrowserService,this._coreBrowserService),this.register((0,m.addDisposableDomListener)(this.textarea,"focus",(function(e){return i._handleTextAreaFocus(e)}))),this.register((0,m.addDisposableDomListener)(this.textarea,"blur",(function(){return i._handleTextAreaBlur()}))),this._helperContainer.appendChild(this.textarea),this._charSizeService=this._instantiationService.createInstance(E.CharSizeService,this._document,this._helperContainer),this._instantiationService.setService(L.ICharSizeService,this._charSizeService),this._themeService=this._instantiationService.createInstance(U.ThemeService),this._instantiationService.setService(L.IThemeService,this._themeService),this._characterJoinerService=this._instantiationService.createInstance(T.CharacterJoinerService),this._instantiationService.setService(L.ICharacterJoinerService,this._characterJoinerService),this._renderService=this.register(this._instantiationService.createInstance(x.RenderService,this.rows,this.screenElement)),this._instantiationService.setService(L.IRenderService,this._renderService),this.register(this._renderService.onRenderedViewportChange((function(e){return i._onRender.fire(e)}))),this.onResize((function(e){return i._renderService.resize(e.cols,e.rows)})),this._compositionView=j.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=this._instantiationService.createInstance(r.CompositionHelper,this.textarea,this._compositionView),this._helperContainer.appendChild(this._compositionView),this.element.appendChild(s);try{this._onWillOpen.fire(this.element)}catch(e){}this._renderService.hasRenderer()||this._renderService.setRenderer(this._createRenderer()),this._mouseService=this._instantiationService.createInstance(R.MouseService),this._instantiationService.setService(L.IMouseService,this._mouseService),this.viewport=this._instantiationService.createInstance(n.Viewport,(function(e){return i.scrollLines(e,!0,1)}),this._viewportElement,this._viewportScrollArea),this.register(this._inputHandler.onRequestSyncScrollBar((function(){return i.viewport.syncScrollArea()}))),this.register(this.viewport),this.register(this.onCursorMove((function(){i._renderService.handleCursorMove(),i._syncTextArea()}))),this.register(this.onResize((function(){return i._renderService.handleResize(i.cols,i.rows)}))),this.register(this.onBlur((function(){return i._renderService.handleBlur()}))),this.register(this.onFocus((function(){return i._renderService.handleFocus()}))),this.register(this._renderService.onDimensionsChange((function(){return i.viewport.syncScrollArea()}))),this._selectionService=this.register(this._instantiationService.createInstance(p.SelectionService,this.element,this.screenElement,this.linkifier2)),this._instantiationService.setService(L.ISelectionService,this._selectionService),this.register(this._selectionService.onRequestScrollLines((function(e){return i.scrollLines(e.amount,e.suppressScrollEvent)}))),this.register(this._selectionService.onSelectionChange((function(){return i._onSelectionChange.fire()}))),this.register(this._selectionService.onRequestRedraw((function(e){return i._renderService.handleSelectionChanged(e.start,e.end,e.columnSelectMode)}))),this.register(this._selectionService.onLinuxMouseSelection((function(e){i.textarea.value=e,i.textarea.focus(),i.textarea.select()}))),this.register(this._onScroll.event((function(e){i.viewport.syncScrollArea(),i._selectionService.refresh()}))),this.register((0,m.addDisposableDomListener)(this._viewportElement,"scroll",(function(){return i._selectionService.refresh()}))),this.linkifier2.attachToDom(this.screenElement,this._mouseService,this._renderService),this.register(this._instantiationService.createInstance(I.BufferDecorationRenderer,this.screenElement)),this.register((0,m.addDisposableDomListener)(this.element,"mousedown",(function(e){return i._selectionService.handleMouseDown(e)}))),this.coreMouseService.areMouseEventsActive?(this._selectionService.disable(),this.element.classList.add("enable-mouse-events")):this._selectionService.enable(),this.options.screenReaderMode&&(this._accessibilityManager=new b.AccessibilityManager(this,this._renderService)),this.register(this.optionsService.onSpecificOptionChange("screenReaderMode",(function(e){return i._handleScreenReaderModeOptionChange(e)}))),this.options.overviewRulerWidth&&(this._overviewRulerRenderer=this.register(this._instantiationService.createInstance(P.OverviewRulerRenderer,this._viewportElement,this.screenElement))),this.optionsService.onSpecificOptionChange("overviewRulerWidth",(function(e){!i._overviewRulerRenderer&&e&&i._viewportElement&&i.screenElement&&(i._overviewRulerRenderer=i.register(i._instantiationService.createInstance(P.OverviewRulerRenderer,i._viewportElement,i.screenElement)))})),this._charSizeService.measure(),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()}},{key:"_createRenderer",value:function(){return this._instantiationService.createInstance(C.DomRenderer,this.element,this.screenElement,this._viewportElement,this.linkifier2)}},{key:"bindMouse",value:function(){var e=this,t=this,i=this.element;function r(e){var i,r,n=t._mouseService.getMouseReportCoords(e,t.screenElement);if(!n)return!1;switch(e.overrideType||e.type){case"mousemove":r=32,void 0===e.buttons?(i=3,void 0!==e.button&&(i=e.button<3?e.button:3)):i=1&e.buttons?0:4&e.buttons?1:2&e.buttons?2:3;break;case"mouseup":r=0,i=e.button<3?e.button:3;break;case"mousedown":r=1,i=e.button<3?e.button:3;break;case"wheel":if(0===t.viewport.getLinesScrolled(e))return!1;r=e.deltaY<0?0:1,i=4;break;default:return!1}return!(void 0===r||void 0===i||i>4)&&t.coreMouseService.triggerMouseEvent({col:n.col,row:n.row,x:n.x,y:n.y,button:i,action:r,ctrl:e.ctrlKey,alt:e.altKey,shift:e.shiftKey})}var n={mouseup:null,wheel:null,mousedrag:null,mousemove:null},s={mouseup:function(t){return r(t),t.buttons||(e._document.removeEventListener("mouseup",n.mouseup),n.mousedrag&&e._document.removeEventListener("mousemove",n.mousedrag)),e.cancel(t)},wheel:function(t){return r(t),e.cancel(t,!0)},mousedrag:function(e){e.buttons&&r(e)},mousemove:function(e){e.buttons||r(e)}};this.register(this.coreMouseService.onProtocolChange((function(t){t?("debug"===e.optionsService.rawOptions.logLevel&&e._logService.debug("Binding to mouse events:",e.coreMouseService.explainEvents(t)),e.element.classList.add("enable-mouse-events"),e._selectionService.disable()):(e._logService.debug("Unbinding from mouse events."),e.element.classList.remove("enable-mouse-events"),e._selectionService.enable()),8&t?n.mousemove||(i.addEventListener("mousemove",s.mousemove),n.mousemove=s.mousemove):(i.removeEventListener("mousemove",n.mousemove),n.mousemove=null),16&t?n.wheel||(i.addEventListener("wheel",s.wheel,{passive:!1}),n.wheel=s.wheel):(i.removeEventListener("wheel",n.wheel),n.wheel=null),2&t?n.mouseup||(n.mouseup=s.mouseup):(e._document.removeEventListener("mouseup",n.mouseup),n.mouseup=null),4&t?n.mousedrag||(n.mousedrag=s.mousedrag):(e._document.removeEventListener("mousemove",n.mousedrag),n.mousedrag=null)}))),this.coreMouseService.activeProtocol=this.coreMouseService.activeProtocol,this.register((0,m.addDisposableDomListener)(i,"mousedown",(function(t){if(t.preventDefault(),e.focus(),e.coreMouseService.areMouseEventsActive&&!e._selectionService.shouldForceSelection(t))return r(t),n.mouseup&&e._document.addEventListener("mouseup",n.mouseup),n.mousedrag&&e._document.addEventListener("mousemove",n.mousedrag),e.cancel(t)}))),this.register((0,m.addDisposableDomListener)(i,"wheel",(function(t){if(!n.wheel){if(!e.buffer.hasScrollback){var i=e.viewport.getLinesScrolled(t);if(0===i)return;for(var r=l.C0.ESC+(e.coreService.decPrivateModes.applicationCursorKeys?"O":"[")+(t.deltaY<0?"A":"B"),s="",o=0;o<Math.abs(i);o++)s+=r;return e.coreService.triggerDataEvent(s,!0),e.cancel(t,!0)}return e.viewport.handleWheel(t)?e.cancel(t):void 0}}),{passive:!1})),this.register((0,m.addDisposableDomListener)(i,"touchstart",(function(t){if(!e.coreMouseService.areMouseEventsActive)return e.viewport.handleTouchStart(t),e.cancel(t)}),{passive:!0})),this.register((0,m.addDisposableDomListener)(i,"touchmove",(function(t){if(!e.coreMouseService.areMouseEventsActive)return e.viewport.handleTouchMove(t)?void 0:e.cancel(t)}),{passive:!1}))}},{key:"refresh",value:function(e,t){var i;null===(i=this._renderService)||void 0===i||i.refreshRows(e,t)}},{key:"updateCursorStyle",value:function(e){var t;(null===(t=this._selectionService)||void 0===t?void 0:t.shouldColumnSelect(e))?this.element.classList.add("column-select"):this.element.classList.remove("column-select")}},{key:"_showCursor",value:function(){this.coreService.isCursorInitialized||(this.coreService.isCursorInitialized=!0,this.refresh(this.buffer.y,this.buffer.y))}},{key:"scrollLines",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;a(c(i.prototype),"scrollLines",this).call(this,e,t,r),this.refresh(0,this.rows-1)}},{key:"paste",value:function(e){(0,s.paste)(e,this.textarea,this.coreService)}},{key:"attachCustomKeyEventHandler",value:function(e){this._customKeyEventHandler=e}},{key:"registerLinkProvider",value:function(e){return this.linkifier2.registerLinkProvider(e)}},{key:"registerCharacterJoiner",value:function(e){if(!this._characterJoinerService)throw new Error("Terminal must be opened first");var t=this._characterJoinerService.register(e);return this.refresh(0,this.rows-1),t}},{key:"deregisterCharacterJoiner",value:function(e){if(!this._characterJoinerService)throw new Error("Terminal must be opened first");this._characterJoinerService.deregister(e)&&this.refresh(0,this.rows-1)}},{key:"markers",get:function(){return this.buffer.markers}},{key:"addMarker",value:function(e){return this.buffer.addMarker(this.buffer.ybase+this.buffer.y+e)}},{key:"registerDecoration",value:function(e){return this._decorationService.registerDecoration(e)}},{key:"hasSelection",value:function(){return!!this._selectionService&&this._selectionService.hasSelection}},{key:"select",value:function(e,t,i){this._selectionService.setSelection(e,t,i)}},{key:"getSelection",value:function(){return this._selectionService?this._selectionService.selectionText:""}},{key:"getSelectionPosition",value:function(){if(this._selectionService&&this._selectionService.hasSelection)return{start:{x:this._selectionService.selectionStart[0],y:this._selectionService.selectionStart[1]},end:{x:this._selectionService.selectionEnd[0],y:this._selectionService.selectionEnd[1]}}}},{key:"clearSelection",value:function(){var e;null===(e=this._selectionService)||void 0===e||e.clearSelection()}},{key:"selectAll",value:function(){var e;null===(e=this._selectionService)||void 0===e||e.selectAll()}},{key:"selectLines",value:function(e,t){var i;null===(i=this._selectionService)||void 0===i||i.selectLines(e,t)}},{key:"_keyDown",value:function(e){if(this._keyDownHandled=!1,this._keyDownSeen=!0,this._customKeyEventHandler&&!1===this._customKeyEventHandler(e))return!1;var t=this.browser.isMac&&this.options.macOptionIsMeta&&e.altKey;if(!t&&!this._compositionHelper.keydown(e))return this.options.scrollOnUserInput&&this.buffer.ybase!==this.buffer.ydisp&&this._bufferService.scrollToBottom(),!1;t||"Dead"!==e.key&&"AltGraph"!==e.key||(this._unprocessedDeadKey=!0);var i=(0,S.evaluateKeyboardEvent)(e,this.coreService.decPrivateModes.applicationCursorKeys,this.browser.isMac,this.options.macOptionIsMeta);if(this.updateCursorStyle(e),3===i.type||2===i.type){var r=this.rows-1;return this.scrollLines(2===i.type?-r:r),this.cancel(e,!0)}return 1===i.type&&this.selectAll(),!!this._isThirdLevelShift(this.browser,e)||(i.cancel&&this.cancel(e,!0),!i.key||!!(e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&1===e.key.length&&e.key.charCodeAt(0)>=65&&e.key.charCodeAt(0)<=90)||(this._unprocessedDeadKey?(this._unprocessedDeadKey=!1,!0):(i.key!==l.C0.ETX&&i.key!==l.C0.CR||(this.textarea.value=""),this._onKey.fire({key:i.key,domEvent:e}),this._showCursor(),this.coreService.triggerDataEvent(i.key,!0),!this.optionsService.rawOptions.screenReaderMode||e.altKey||e.ctrlKey?this.cancel(e,!0):void(this._keyDownHandled=!0))))}},{key:"_isThirdLevelShift",value:function(e,t){var i=e.isMac&&!this.options.macOptionIsMeta&&t.altKey&&!t.ctrlKey&&!t.metaKey||e.isWindows&&t.altKey&&t.ctrlKey&&!t.metaKey||e.isWindows&&t.getModifierState("AltGraph");return"keypress"===t.type?i:i&&(!t.keyCode||t.keyCode>47)}},{key:"_keyUp",value:function(e){this._keyDownSeen=!1,this._customKeyEventHandler&&!1===this._customKeyEventHandler(e)||(function(e){return 16===e.keyCode||17===e.keyCode||18===e.keyCode}(e)||this.focus(),this.updateCursorStyle(e),this._keyPressHandled=!1)}},{key:"_keyPress",value:function(e){var t;if(this._keyPressHandled=!1,this._keyDownHandled)return!1;if(this._customKeyEventHandler&&!1===this._customKeyEventHandler(e))return!1;if(this.cancel(e),e.charCode)t=e.charCode;else if(null===e.which||void 0===e.which)t=e.keyCode;else{if(0===e.which||0===e.charCode)return!1;t=e.which}return!(!t||(e.altKey||e.ctrlKey||e.metaKey)&&!this._isThirdLevelShift(this.browser,e)||(t=String.fromCharCode(t),this._onKey.fire({key:t,domEvent:e}),this._showCursor(),this.coreService.triggerDataEvent(t,!0),this._keyPressHandled=!0,this._unprocessedDeadKey=!1,0))}},{key:"_inputEvent",value:function(e){if(e.data&&"insertText"===e.inputType&&(!e.composed||!this._keyDownSeen)&&!this.optionsService.rawOptions.screenReaderMode){if(this._keyPressHandled)return!1;this._unprocessedDeadKey=!1;var t=e.data;return this.coreService.triggerDataEvent(t,!0),this.cancel(e),!0}return!1}},{key:"resize",value:function(e,t){e!==this.cols||t!==this.rows?a(c(i.prototype),"resize",this).call(this,e,t):this._charSizeService&&!this._charSizeService.hasValidSize&&this._charSizeService.measure()}},{key:"_afterResize",value:function(e,t){var i,r;null===(i=this._charSizeService)||void 0===i||i.measure(),null===(r=this.viewport)||void 0===r||r.syncScrollArea(!0)}},{key:"clear",value:function(){if(0!==this.buffer.ybase||0!==this.buffer.y){this.buffer.clearAllMarkers(),this.buffer.lines.set(0,this.buffer.lines.get(this.buffer.ybase+this.buffer.y)),this.buffer.lines.length=1,this.buffer.ydisp=0,this.buffer.ybase=0,this.buffer.y=0;for(var e=1;e<this.rows;e++)this.buffer.lines.push(this.buffer.getBlankLine(k.DEFAULT_ATTR_DATA));this.refresh(0,this.rows-1),this._onScroll.fire({position:this.buffer.ydisp,source:0})}}},{key:"reset",value:function(){var e,t;this.options.rows=this.rows,this.options.cols=this.cols;var r=this._customKeyEventHandler;this._setup(),a(c(i.prototype),"reset",this).call(this),null===(e=this._selectionService)||void 0===e||e.reset(),this._decorationService.reset(),this._customKeyEventHandler=r,this.refresh(0,this.rows-1),null===(t=this.viewport)||void 0===t||t.syncScrollArea()}},{key:"clearTextureAtlas",value:function(){var e;null===(e=this._renderService)||void 0===e||e.clearTextureAtlas()}},{key:"_reportFocus",value:function(){var e;(null===(e=this.element)||void 0===e?void 0:e.classList.contains("focus"))?this.coreService.triggerDataEvent(l.C0.ESC+"[I"):this.coreService.triggerDataEvent(l.C0.ESC+"[O")}},{key:"_reportWindowsOptions",value:function(e){if(this._renderService)switch(e){case d.WindowsOptionsReportType.GET_WIN_SIZE_PIXELS:var t=this._renderService.dimensions.css.canvas.width.toFixed(0),i=this._renderService.dimensions.css.canvas.height.toFixed(0);this.coreService.triggerDataEvent("".concat(l.C0.ESC,"[4;").concat(i,";").concat(t,"t"));break;case d.WindowsOptionsReportType.GET_CELL_SIZE_PIXELS:var r=this._renderService.dimensions.css.cell.width.toFixed(0),n=this._renderService.dimensions.css.cell.height.toFixed(0);this.coreService.triggerDataEvent("".concat(l.C0.ESC,"[6;").concat(n,";").concat(r,"t"))}}},{key:"cancel",value:function(e,t){if(this.options.cancelEvents||t)return e.preventDefault(),e.stopPropagation(),!1}}]),i}(D.CoreTerminal);t.Terminal=z},9924:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.TimeBasedDebouncer=void 0,t.TimeBasedDebouncer=function(){function e(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1e3;h(this,e),this._renderCallback=t,this._debounceThresholdMS=i,this._lastRefreshMs=0,this._additionalRefreshRequested=!1}return f(e,[{key:"dispose",value:function(){this._refreshTimeoutID&&clearTimeout(this._refreshTimeoutID)}},{key:"refresh",value:function(e,t,i){var r=this;this._rowCount=i,e=void 0!==e?e:0,t=void 0!==t?t:this._rowCount-1,this._rowStart=void 0!==this._rowStart?Math.min(this._rowStart,e):e,this._rowEnd=void 0!==this._rowEnd?Math.max(this._rowEnd,t):t;var n=Date.now();if(n-this._lastRefreshMs>=this._debounceThresholdMS)this._lastRefreshMs=n,this._innerRefresh();else if(!this._additionalRefreshRequested){var s=n-this._lastRefreshMs,o=this._debounceThresholdMS-s;this._additionalRefreshRequested=!0,this._refreshTimeoutID=window.setTimeout((function(){r._lastRefreshMs=Date.now(),r._innerRefresh(),r._additionalRefreshRequested=!1,r._refreshTimeoutID=void 0}),o)}}},{key:"_innerRefresh",value:function(){if(void 0!==this._rowStart&&void 0!==this._rowEnd&&void 0!==this._rowCount){var e=Math.max(this._rowStart,0),t=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._renderCallback(e,t)}}}]),e}()},1680:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.Viewport=void 0;var s=i(844),o=i(3656),a=i(4725),c=i(2585),l=function(e){v(i,e);var t=_(i);function i(e,r,n,s,a,c,l,u,f){var v;return h(this,i),(v=t.call(this))._scrollLines=e,v._viewportElement=r,v._scrollArea=n,v._bufferService=s,v._optionsService=a,v._charSizeService=c,v._renderService=l,v._coreBrowserService=u,v.scrollBarWidth=0,v._currentRowHeight=0,v._currentDeviceCellHeight=0,v._lastRecordedBufferLength=0,v._lastRecordedViewportHeight=0,v._lastRecordedBufferHeight=0,v._lastTouchY=0,v._lastScrollTop=0,v._wheelPartialScroll=0,v._refreshAnimationFrame=null,v._ignoreNextScrollEvent=!1,v._smoothScrollState={startTime:0,origin:-1,target:-1},v.scrollBarWidth=v._viewportElement.offsetWidth-v._scrollArea.offsetWidth||15,v.register((0,o.addDisposableDomListener)(v._viewportElement,"scroll",v._handleScroll.bind(d(v)))),v._activeBuffer=v._bufferService.buffer,v.register(v._bufferService.buffers.onBufferActivate((function(e){return v._activeBuffer=e.activeBuffer}))),v._renderDimensions=v._renderService.dimensions,v.register(v._renderService.onDimensionsChange((function(e){return v._renderDimensions=e}))),v._handleThemeChange(f.colors),v.register(f.onChangeColors((function(e){return v._handleThemeChange(e)}))),v.register(v._optionsService.onSpecificOptionChange("scrollback",(function(){return v.syncScrollArea()}))),setTimeout((function(){return v.syncScrollArea()}),0),v}return f(i,[{key:"_handleThemeChange",value:function(e){this._viewportElement.style.backgroundColor=e.background.css}},{key:"_refresh",value:function(e){var t=this;if(e)return this._innerRefresh(),void(null!==this._refreshAnimationFrame&&this._coreBrowserService.window.cancelAnimationFrame(this._refreshAnimationFrame));null===this._refreshAnimationFrame&&(this._refreshAnimationFrame=this._coreBrowserService.window.requestAnimationFrame((function(){return t._innerRefresh()})))}},{key:"_innerRefresh",value:function(){if(this._charSizeService.height>0){this._currentRowHeight=this._renderService.dimensions.device.cell.height/this._coreBrowserService.dpr,this._currentDeviceCellHeight=this._renderService.dimensions.device.cell.height,this._lastRecordedViewportHeight=this._viewportElement.offsetHeight;var e=Math.round(this._currentRowHeight*this._lastRecordedBufferLength)+(this._lastRecordedViewportHeight-this._renderService.dimensions.css.canvas.height);this._lastRecordedBufferHeight!==e&&(this._lastRecordedBufferHeight=e,this._scrollArea.style.height=this._lastRecordedBufferHeight+"px")}var t=this._bufferService.buffer.ydisp*this._currentRowHeight;this._viewportElement.scrollTop!==t&&(this._ignoreNextScrollEvent=!0,this._viewportElement.scrollTop=t),this._refreshAnimationFrame=null}},{key:"syncScrollArea",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this._lastRecordedBufferLength!==this._bufferService.buffer.lines.length)return this._lastRecordedBufferLength=this._bufferService.buffer.lines.length,void this._refresh(e);this._lastRecordedViewportHeight===this._renderService.dimensions.css.canvas.height&&this._lastScrollTop===this._activeBuffer.ydisp*this._currentRowHeight&&this._renderDimensions.device.cell.height===this._currentDeviceCellHeight||this._refresh(e)}},{key:"_handleScroll",value:function(e){if(this._lastScrollTop=this._viewportElement.scrollTop,this._viewportElement.offsetParent){if(this._ignoreNextScrollEvent)return this._ignoreNextScrollEvent=!1,void this._scrollLines(0);var t=Math.round(this._lastScrollTop/this._currentRowHeight)-this._bufferService.buffer.ydisp;this._scrollLines(t)}}},{key:"_smoothScroll",value:function(){var e=this;if(!this._isDisposed&&-1!==this._smoothScrollState.origin&&-1!==this._smoothScrollState.target){var t=this._smoothScrollPercent();this._viewportElement.scrollTop=this._smoothScrollState.origin+Math.round(t*(this._smoothScrollState.target-this._smoothScrollState.origin)),t<1?this._coreBrowserService.window.requestAnimationFrame((function(){return e._smoothScroll()})):this._clearSmoothScrollState()}}},{key:"_smoothScrollPercent",value:function(){return this._optionsService.rawOptions.smoothScrollDuration&&this._smoothScrollState.startTime?Math.max(Math.min((Date.now()-this._smoothScrollState.startTime)/this._optionsService.rawOptions.smoothScrollDuration,1),0):1}},{key:"_clearSmoothScrollState",value:function(){this._smoothScrollState.startTime=0,this._smoothScrollState.origin=-1,this._smoothScrollState.target=-1}},{key:"_bubbleScroll",value:function(e,t){var i=this._viewportElement.scrollTop+this._lastRecordedViewportHeight;return!(t<0&&0!==this._viewportElement.scrollTop||t>0&&i<this._lastRecordedBufferHeight)||(e.cancelable&&e.preventDefault(),!1)}},{key:"handleWheel",value:function(e){var t=this._getPixelsScrolled(e);return 0!==t&&(this._optionsService.rawOptions.smoothScrollDuration?(this._smoothScrollState.startTime=Date.now(),this._smoothScrollPercent()<1?(this._smoothScrollState.origin=this._viewportElement.scrollTop,-1===this._smoothScrollState.target?this._smoothScrollState.target=this._viewportElement.scrollTop+t:this._smoothScrollState.target+=t,this._smoothScrollState.target=Math.max(Math.min(this._smoothScrollState.target,this._viewportElement.scrollHeight),0),this._smoothScroll()):this._clearSmoothScrollState()):this._viewportElement.scrollTop+=t,this._bubbleScroll(e,t))}},{key:"_getPixelsScrolled",value:function(e){if(0===e.deltaY||e.shiftKey)return 0;var t=this._applyScrollModifier(e.deltaY,e);return e.deltaMode===WheelEvent.DOM_DELTA_LINE?t*=this._currentRowHeight:e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(t*=this._currentRowHeight*this._bufferService.rows),t}},{key:"getLinesScrolled",value:function(e){if(0===e.deltaY||e.shiftKey)return 0;var t=this._applyScrollModifier(e.deltaY,e);return e.deltaMode===WheelEvent.DOM_DELTA_PIXEL?(t/=this._currentRowHeight+0,this._wheelPartialScroll+=t,t=Math.floor(Math.abs(this._wheelPartialScroll))*(this._wheelPartialScroll>0?1:-1),this._wheelPartialScroll%=1):e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(t*=this._bufferService.rows),t}},{key:"_applyScrollModifier",value:function(e,t){var i=this._optionsService.rawOptions.fastScrollModifier;return"alt"===i&&t.altKey||"ctrl"===i&&t.ctrlKey||"shift"===i&&t.shiftKey?e*this._optionsService.rawOptions.fastScrollSensitivity*this._optionsService.rawOptions.scrollSensitivity:e*this._optionsService.rawOptions.scrollSensitivity}},{key:"handleTouchStart",value:function(e){this._lastTouchY=e.touches[0].pageY}},{key:"handleTouchMove",value:function(e){var t=this._lastTouchY-e.touches[0].pageY;return this._lastTouchY=e.touches[0].pageY,0!==t&&(this._viewportElement.scrollTop+=t,this._bubbleScroll(e,t))}}]),i}(s.Disposable);l=r([n(3,c.IBufferService),n(4,c.IOptionsService),n(5,a.ICharSizeService),n(6,a.IRenderService),n(7,a.ICoreBrowserService),n(8,a.IThemeService)],l),t.Viewport=l},3107:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.BufferDecorationRenderer=void 0;var s=i(3656),o=i(4725),a=i(844),c=i(2585),l=function(e){v(i,e);var t=_(i);function i(e,r,n,o){var c;return h(this,i),(c=t.call(this))._screenElement=e,c._bufferService=r,c._decorationService=n,c._renderService=o,c._decorationElements=new Map,c._altBufferIsActive=!1,c._dimensionsChanged=!1,c._container=document.createElement("div"),c._container.classList.add("xterm-decoration-container"),c._screenElement.appendChild(c._container),c.register(c._renderService.onRenderedViewportChange((function(){return c._doRefreshDecorations()}))),c.register(c._renderService.onDimensionsChange((function(){c._dimensionsChanged=!0,c._queueRefresh()}))),c.register((0,s.addDisposableDomListener)(window,"resize",(function(){return c._queueRefresh()}))),c.register(c._bufferService.buffers.onBufferActivate((function(){c._altBufferIsActive=c._bufferService.buffer===c._bufferService.buffers.alt}))),c.register(c._decorationService.onDecorationRegistered((function(){return c._queueRefresh()}))),c.register(c._decorationService.onDecorationRemoved((function(e){return c._removeDecoration(e)}))),c.register((0,a.toDisposable)((function(){c._container.remove(),c._decorationElements.clear()}))),c}return f(i,[{key:"_queueRefresh",value:function(){var e=this;void 0===this._animationFrame&&(this._animationFrame=this._renderService.addRefreshCallback((function(){e._doRefreshDecorations(),e._animationFrame=void 0})))}},{key:"_doRefreshDecorations",value:function(){var e,t=u(this._decorationService.decorations);try{for(t.s();!(e=t.n()).done;){var i=e.value;this._renderDecoration(i)}}catch(r){t.e(r)}finally{t.f()}this._dimensionsChanged=!1}},{key:"_renderDecoration",value:function(e){this._refreshStyle(e),this._dimensionsChanged&&this._refreshXPosition(e)}},{key:"_createElement",value:function(e){var t,i=document.createElement("div");i.classList.add("xterm-decoration"),i.style.width="".concat(Math.round((e.options.width||1)*this._renderService.dimensions.css.cell.width),"px"),i.style.height=(e.options.height||1)*this._renderService.dimensions.css.cell.height+"px",i.style.top=(e.marker.line-this._bufferService.buffers.active.ydisp)*this._renderService.dimensions.css.cell.height+"px",i.style.lineHeight="".concat(this._renderService.dimensions.css.cell.height,"px");var r=null!==(t=e.options.x)&&void 0!==t?t:0;return r&&r>this._bufferService.cols&&(i.style.display="none"),this._refreshXPosition(e,i),i}},{key:"_refreshStyle",value:function(e){var t=e.marker.line-this._bufferService.buffers.active.ydisp;if(t<0||t>=this._bufferService.rows)e.element&&(e.element.style.display="none",e.onRenderEmitter.fire(e.element));else{var i=this._decorationElements.get(e);i||(i=this._createElement(e),e.element=i,this._decorationElements.set(e,i),this._container.appendChild(i)),i.style.top=t*this._renderService.dimensions.css.cell.height+"px",i.style.display=this._altBufferIsActive?"none":"block",e.onRenderEmitter.fire(i)}}},{key:"_refreshXPosition",value:function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.element;if(i){var r=null!==(t=e.options.x)&&void 0!==t?t:0;"right"===(e.options.anchor||"left")?i.style.right=r?r*this._renderService.dimensions.css.cell.width+"px":"":i.style.left=r?r*this._renderService.dimensions.css.cell.width+"px":""}}},{key:"_removeDecoration",value:function(e){var t;null===(t=this._decorationElements.get(e))||void 0===t||t.remove(),this._decorationElements.delete(e),e.dispose()}}]),i}(a.Disposable);l=r([n(1,c.IBufferService),n(2,c.IDecorationService),n(3,o.IRenderService)],l),t.BufferDecorationRenderer=l},5871:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.ColorZoneStore=void 0,t.ColorZoneStore=function(){function e(){h(this,e),this._zones=[],this._zonePool=[],this._zonePoolIndex=0,this._linePadding={full:0,left:0,center:0,right:0}}return f(e,[{key:"zones",get:function(){return this._zonePool.length=Math.min(this._zonePool.length,this._zones.length),this._zones}},{key:"clear",value:function(){this._zones.length=0,this._zonePoolIndex=0}},{key:"addDecoration",value:function(e){if(e.options.overviewRulerOptions){var t,i=u(this._zones);try{for(i.s();!(t=i.n()).done;){var r=t.value;if(r.color===e.options.overviewRulerOptions.color&&r.position===e.options.overviewRulerOptions.position){if(this._lineIntersectsZone(r,e.marker.line))return;if(this._lineAdjacentToZone(r,e.marker.line,e.options.overviewRulerOptions.position))return void this._addLineToZone(r,e.marker.line)}}}catch(n){i.e(n)}finally{i.f()}if(this._zonePoolIndex<this._zonePool.length)return this._zonePool[this._zonePoolIndex].color=e.options.overviewRulerOptions.color,this._zonePool[this._zonePoolIndex].position=e.options.overviewRulerOptions.position,this._zonePool[this._zonePoolIndex].startBufferLine=e.marker.line,this._zonePool[this._zonePoolIndex].endBufferLine=e.marker.line,void this._zones.push(this._zonePool[this._zonePoolIndex++]);this._zones.push({color:e.options.overviewRulerOptions.color,position:e.options.overviewRulerOptions.position,startBufferLine:e.marker.line,endBufferLine:e.marker.line}),this._zonePool.push(this._zones[this._zones.length-1]),this._zonePoolIndex++}}},{key:"setPadding",value:function(e){this._linePadding=e}},{key:"_lineIntersectsZone",value:function(e,t){return t>=e.startBufferLine&&t<=e.endBufferLine}},{key:"_lineAdjacentToZone",value:function(e,t,i){return t>=e.startBufferLine-this._linePadding[i||"full"]&&t<=e.endBufferLine+this._linePadding[i||"full"]}},{key:"_addLineToZone",value:function(e,t){e.startBufferLine=Math.min(e.startBufferLine,t),e.endBufferLine=Math.max(e.endBufferLine,t)}}]),e}()},5744:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.OverviewRulerRenderer=void 0;var s=i(5871),o=i(3656),a=i(4725),c=i(844),l=i(2585),d={full:0,left:0,center:0,right:0},p={full:0,left:0,center:0,right:0},g={full:0,left:0,center:0,right:0},m=function(e){v(i,e);var t=_(i);function i(e,r,n,o,a,l,u){var f,d;h(this,i),(f=t.call(this))._viewportElement=e,f._screenElement=r,f._bufferService=n,f._decorationService=o,f._renderService=a,f._optionsService=l,f._coreBrowseService=u,f._colorZoneStore=new s.ColorZoneStore,f._shouldUpdateDimensions=!0,f._shouldUpdateAnchor=!0,f._lastKnownBufferLength=0,f._canvas=document.createElement("canvas"),f._canvas.classList.add("xterm-decoration-overview-ruler"),f._refreshCanvasDimensions(),null===(d=f._viewportElement.parentElement)||void 0===d||d.insertBefore(f._canvas,f._viewportElement);var v=f._canvas.getContext("2d");if(!v)throw new Error("Ctx cannot be null");return f._ctx=v,f._registerDecorationListeners(),f._registerBufferChangeListeners(),f._registerDimensionChangeListeners(),f.register((0,c.toDisposable)((function(){var e;null===(e=f._canvas)||void 0===e||e.remove()}))),f}return f(i,[{key:"_width",get:function(){return this._optionsService.options.overviewRulerWidth||0}},{key:"_registerDecorationListeners",value:function(){var e=this;this.register(this._decorationService.onDecorationRegistered((function(){return e._queueRefresh(void 0,!0)}))),this.register(this._decorationService.onDecorationRemoved((function(){return e._queueRefresh(void 0,!0)})))}},{key:"_registerBufferChangeListeners",value:function(){var e=this;this.register(this._renderService.onRenderedViewportChange((function(){return e._queueRefresh()}))),this.register(this._bufferService.buffers.onBufferActivate((function(){e._canvas.style.display=e._bufferService.buffer===e._bufferService.buffers.alt?"none":"block"}))),this.register(this._bufferService.onScroll((function(){e._lastKnownBufferLength!==e._bufferService.buffers.normal.lines.length&&(e._refreshDrawHeightConstants(),e._refreshColorZonePadding())})))}},{key:"_registerDimensionChangeListeners",value:function(){var e=this;this.register(this._renderService.onRender((function(){e._containerHeight&&e._containerHeight===e._screenElement.clientHeight||(e._queueRefresh(!0),e._containerHeight=e._screenElement.clientHeight)}))),this.register(this._optionsService.onSpecificOptionChange("overviewRulerWidth",(function(){return e._queueRefresh(!0)}))),this.register((0,o.addDisposableDomListener)(this._coreBrowseService.window,"resize",(function(){return e._queueRefresh(!0)}))),this._queueRefresh(!0)}},{key:"_refreshDrawConstants",value:function(){var e=Math.floor(this._canvas.width/3),t=Math.ceil(this._canvas.width/3);p.full=this._canvas.width,p.left=e,p.center=t,p.right=e,this._refreshDrawHeightConstants(),g.full=0,g.left=0,g.center=p.left,g.right=p.left+p.center}},{key:"_refreshDrawHeightConstants",value:function(){d.full=Math.round(2*this._coreBrowseService.dpr);var e=this._canvas.height/this._bufferService.buffer.lines.length,t=Math.round(Math.max(Math.min(e,12),6)*this._coreBrowseService.dpr);d.left=t,d.center=t,d.right=t}},{key:"_refreshColorZonePadding",value:function(){this._colorZoneStore.setPadding({full:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*d.full),left:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*d.left),center:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*d.center),right:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*d.right)}),this._lastKnownBufferLength=this._bufferService.buffers.normal.lines.length}},{key:"_refreshCanvasDimensions",value:function(){this._canvas.style.width="".concat(this._width,"px"),this._canvas.width=Math.round(this._width*this._coreBrowseService.dpr),this._canvas.style.height="".concat(this._screenElement.clientHeight,"px"),this._canvas.height=Math.round(this._screenElement.clientHeight*this._coreBrowseService.dpr),this._refreshDrawConstants(),this._refreshColorZonePadding()}},{key:"_refreshDecorations",value:function(){this._shouldUpdateDimensions&&this._refreshCanvasDimensions(),this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height),this._colorZoneStore.clear();var e,t=u(this._decorationService.decorations);try{for(t.s();!(e=t.n()).done;){var i=e.value;this._colorZoneStore.addDecoration(i)}}catch(h){t.e(h)}finally{t.f()}this._ctx.lineWidth=1;var r,n=this._colorZoneStore.zones,s=u(n);try{for(s.s();!(r=s.n()).done;){var o=r.value;"full"!==o.position&&this._renderColorZone(o)}}catch(h){s.e(h)}finally{s.f()}var a,c=u(n);try{for(c.s();!(a=c.n()).done;){var l=a.value;"full"===l.position&&this._renderColorZone(l)}}catch(h){c.e(h)}finally{c.f()}this._shouldUpdateDimensions=!1,this._shouldUpdateAnchor=!1}},{key:"_renderColorZone",value:function(e){this._ctx.fillStyle=e.color,this._ctx.fillRect(g[e.position||"full"],Math.round((this._canvas.height-1)*(e.startBufferLine/this._bufferService.buffers.active.lines.length)-d[e.position||"full"]/2),p[e.position||"full"],Math.round((this._canvas.height-1)*((e.endBufferLine-e.startBufferLine)/this._bufferService.buffers.active.lines.length)+d[e.position||"full"]))}},{key:"_queueRefresh",value:function(e,t){var i=this;this._shouldUpdateDimensions=e||this._shouldUpdateDimensions,this._shouldUpdateAnchor=t||this._shouldUpdateAnchor,void 0===this._animationFrame&&(this._animationFrame=this._coreBrowseService.window.requestAnimationFrame((function(){i._refreshDecorations(),i._animationFrame=void 0})))}}]),i}(c.Disposable);m=r([n(2,l.IBufferService),n(3,l.IDecorationService),n(4,a.IRenderService),n(5,l.IOptionsService),n(6,a.ICoreBrowserService)],m),t.OverviewRulerRenderer=m},2950:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CompositionHelper=void 0;var s=i(4725),o=i(2585),a=i(2584),c=function(){function e(t,i,r,n,s,o){h(this,e),this._textarea=t,this._compositionView=i,this._bufferService=r,this._optionsService=n,this._coreService=s,this._renderService=o,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:0,end:0},this._dataAlreadySent=""}return f(e,[{key:"isComposing",get:function(){return this._isComposing}},{key:"compositionstart",value:function(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._dataAlreadySent="",this._compositionView.classList.add("active")}},{key:"compositionupdate",value:function(e){var t=this;this._compositionView.textContent=e.data,this.updateCompositionElements(),setTimeout((function(){t._compositionPosition.end=t._textarea.value.length}),0)}},{key:"compositionend",value:function(){this._finalizeComposition(!0)}},{key:"keydown",value:function(e){if(this._isComposing||this._isSendingComposition){if(229===e.keyCode)return!1;if(16===e.keyCode||17===e.keyCode||18===e.keyCode)return!1;this._finalizeComposition(!1)}return 229!==e.keyCode||(this._handleAnyTextareaChanges(),!1)}},{key:"_finalizeComposition",value:function(e){var t=this;if(this._compositionView.classList.remove("active"),this._isComposing=!1,e){var i={start:this._compositionPosition.start,end:this._compositionPosition.end};this._isSendingComposition=!0,setTimeout((function(){var e;t._isSendingComposition&&(t._isSendingComposition=!1,i.start+=t._dataAlreadySent.length,(e=t._isComposing?t._textarea.value.substring(i.start,i.end):t._textarea.value.substring(i.start)).length>0&&t._coreService.triggerDataEvent(e,!0))}),0)}else{this._isSendingComposition=!1;var r=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end);this._coreService.triggerDataEvent(r,!0)}}},{key:"_handleAnyTextareaChanges",value:function(){var e=this,t=this._textarea.value;setTimeout((function(){if(!e._isComposing){var i=e._textarea.value,r=i.replace(t,"");e._dataAlreadySent=r,i.length>t.length?e._coreService.triggerDataEvent(r,!0):i.length<t.length?e._coreService.triggerDataEvent("".concat(a.C0.DEL),!0):i.length===t.length&&i!==t&&e._coreService.triggerDataEvent(i,!0)}}),0)}},{key:"updateCompositionElements",value:function(e){var t=this;if(this._isComposing){if(this._bufferService.buffer.isCursorInViewport){var i=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1),r=this._renderService.dimensions.css.cell.height,n=this._bufferService.buffer.y*this._renderService.dimensions.css.cell.height,s=i*this._renderService.dimensions.css.cell.width;this._compositionView.style.left=s+"px",this._compositionView.style.top=n+"px",this._compositionView.style.height=r+"px",this._compositionView.style.lineHeight=r+"px",this._compositionView.style.fontFamily=this._optionsService.rawOptions.fontFamily,this._compositionView.style.fontSize=this._optionsService.rawOptions.fontSize+"px";var o=this._compositionView.getBoundingClientRect();this._textarea.style.left=s+"px",this._textarea.style.top=n+"px",this._textarea.style.width=Math.max(o.width,1)+"px",this._textarea.style.height=Math.max(o.height,1)+"px",this._textarea.style.lineHeight=o.height+"px"}e||setTimeout((function(){return t.updateCompositionElements(!0)}),0)}}}]),e}();c=r([n(2,o.IBufferService),n(3,o.IOptionsService),n(4,o.ICoreService),n(5,s.IRenderService)],c),t.CompositionHelper=c},9806:function(e,t){function i(e,t,i){var r=i.getBoundingClientRect(),n=e.getComputedStyle(i),s=parseInt(n.getPropertyValue("padding-left")),o=parseInt(n.getPropertyValue("padding-top"));return[t.clientX-r.left-s,t.clientY-r.top-o]}Object.defineProperty(t,"__esModule",{value:!0}),t.getCoords=t.getCoordsRelativeToElement=void 0,t.getCoordsRelativeToElement=i,t.getCoords=function(e,t,r,n,s,o,a,c,l){if(o){var u=i(e,t,r);return u?(u[0]=Math.ceil((u[0]+(l?a/2:0))/a),u[1]=Math.ceil(u[1]/c),u[0]=Math.min(Math.max(u[0],1),n+(l?1:0)),u[1]=Math.min(Math.max(u[1],1),s),u):void 0}}},9504:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.moveToCellSequence=void 0;var r=i(2584);function n(e,t,i,r){var n=e-s(e,i),a=t-s(t,i),u=Math.abs(n-a)-function(e,t,i){for(var r=0,n=e-s(e,i),a=t-s(t,i),c=0;c<Math.abs(n-a);c++){var l="A"===o(e,t)?-1:1,u=i.buffer.lines.get(n+l*c);(null==u?void 0:u.isWrapped)&&r++}return r}(e,t,i);return l(u,c(o(e,t),r))}function s(e,t){for(var i=0,r=t.buffer.lines.get(e),n=null==r?void 0:r.isWrapped;n&&e>=0&&e<t.rows;)i++,n=null==(r=t.buffer.lines.get(--e))?void 0:r.isWrapped;return i}function o(e,t){return e>t?"A":"B"}function a(e,t,i,r,n,s){for(var o=e,a=t,c="";o!==i||a!==r;)o+=n?1:-1,n&&o>s.cols-1?(c+=s.buffer.translateBufferLineToString(a,!1,e,o),o=0,e=0,a++):!n&&o<0&&(c+=s.buffer.translateBufferLineToString(a,!1,0,e+1),e=o=s.cols-1,a--);return c+s.buffer.translateBufferLineToString(a,!1,e,o)}function c(e,t){var i=t?"O":"[";return r.C0.ESC+i+e}function l(e,t){e=Math.floor(e);for(var i="",r=0;r<e;r++)i+=t;return i}t.moveToCellSequence=function(e,t,i,r){var o,u=i.buffer.x,h=i.buffer.y;if(!i.buffer.hasScrollback)return function(e,t,i,r,o,u){return 0===n(t,r,o,u).length?"":l(a(e,t,e,t-s(t,o),!1,o).length,c("D",u))}(u,h,0,t,i,r)+n(h,t,i,r)+function(e,t,i,r,o,u){var h;h=n(t,r,o,u).length>0?r-s(r,o):t;var f=r,d=function(e,t,i,r,o,a){var c;return c=n(i,r,o,a).length>0?r-s(r,o):t,e<i&&c<=r||e>=i&&c<r?"C":"D"}(e,t,i,r,o,u);return l(a(e,h,i,f,"C"===d,o).length,c(d,u))}(u,h,e,t,i,r);if(h===t)return o=u>e?"D":"C",l(Math.abs(u-e),c(o,r));o=h>t?"D":"C";var f=Math.abs(h-t);return l(function(e,t){return t.cols-e}(h>t?e:u,i)+(f-1)*i.cols+1+((h>t?u:e)-1),c(o,r))}},1296:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.DomRenderer=void 0;var s=i(9631),o=i(3787),a=i(2223),c=i(6171),d=i(4725),p=i(8055),g=i(8460),m=i(844),y=i(2585),b="xterm-dom-renderer-owner-",C="xterm-focus",S=1,w=function(e){v(i,e);var t=_(i);function i(e,r,n,a,l,u,f,d,v,_){var p;return h(this,i),(p=t.call(this))._element=e,p._screenElement=r,p._viewportElement=n,p._linkifier2=a,p._charSizeService=u,p._optionsService=f,p._bufferService=d,p._coreBrowserService=v,p._terminalClass=S++,p._rowElements=[],p._cellToRowElements=[],p.onRequestRedraw=p.register(new g.EventEmitter).event,p._rowContainer=document.createElement("div"),p._rowContainer.classList.add("xterm-rows"),p._rowContainer.style.lineHeight="normal",p._rowContainer.setAttribute("aria-hidden","true"),p._refreshRowElements(p._bufferService.cols,p._bufferService.rows),p._selectionContainer=document.createElement("div"),p._selectionContainer.classList.add("xterm-selection"),p._selectionContainer.setAttribute("aria-hidden","true"),p.dimensions=(0,c.createRenderDimensions)(),p._updateDimensions(),p.register(p._optionsService.onOptionChange((function(){return p._handleOptionsChanged()}))),p.register(_.onChangeColors((function(e){return p._injectCss(e)}))),p._injectCss(_.colors),p._rowFactory=l.createInstance(o.DomRendererRowFactory,document),p._element.classList.add(b+p._terminalClass),p._screenElement.appendChild(p._rowContainer),p._screenElement.appendChild(p._selectionContainer),p.register(p._linkifier2.onShowLinkUnderline((function(e){return p._handleLinkHover(e)}))),p.register(p._linkifier2.onHideLinkUnderline((function(e){return p._handleLinkLeave(e)}))),p.register((0,m.toDisposable)((function(){p._element.classList.remove(b+p._terminalClass),(0,s.removeElementFromParent)(p._rowContainer,p._selectionContainer,p._themeStyleElement,p._dimensionsStyleElement)}))),p}return f(i,[{key:"_updateDimensions",value:function(){var e=this._coreBrowserService.dpr;this.dimensions.device.char.width=this._charSizeService.width*e,this.dimensions.device.char.height=Math.ceil(this._charSizeService.height*e),this.dimensions.device.cell.width=this.dimensions.device.char.width+Math.round(this._optionsService.rawOptions.letterSpacing),this.dimensions.device.cell.height=Math.floor(this.dimensions.device.char.height*this._optionsService.rawOptions.lineHeight),this.dimensions.device.char.left=0,this.dimensions.device.char.top=0,this.dimensions.device.canvas.width=this.dimensions.device.cell.width*this._bufferService.cols,this.dimensions.device.canvas.height=this.dimensions.device.cell.height*this._bufferService.rows,this.dimensions.css.canvas.width=Math.round(this.dimensions.device.canvas.width/e),this.dimensions.css.canvas.height=Math.round(this.dimensions.device.canvas.height/e),this.dimensions.css.cell.width=this.dimensions.css.canvas.width/this._bufferService.cols,this.dimensions.css.cell.height=this.dimensions.css.canvas.height/this._bufferService.rows;var t,i=u(this._rowElements);try{for(i.s();!(t=i.n()).done;){var r=t.value;r.style.width="".concat(this.dimensions.css.canvas.width,"px"),r.style.height="".concat(this.dimensions.css.cell.height,"px"),r.style.lineHeight="".concat(this.dimensions.css.cell.height,"px"),r.style.overflow="hidden"}}catch(s){i.e(s)}finally{i.f()}this._dimensionsStyleElement||(this._dimensionsStyleElement=document.createElement("style"),this._screenElement.appendChild(this._dimensionsStyleElement));var n="".concat(this._terminalSelector," .xterm-rows span { display: inline-block; height: 100%; vertical-align: top; width: ").concat(this.dimensions.css.cell.width,"px}");this._dimensionsStyleElement.textContent=n,this._selectionContainer.style.height=this._viewportElement.style.height,this._screenElement.style.width="".concat(this.dimensions.css.canvas.width,"px"),this._screenElement.style.height="".concat(this.dimensions.css.canvas.height,"px")}},{key:"_injectCss",value:function(e){this._themeStyleElement||(this._themeStyleElement=document.createElement("style"),this._screenElement.appendChild(this._themeStyleElement));var t="".concat(this._terminalSelector," .xterm-rows { color: ").concat(e.foreground.css,"; font-family: ").concat(this._optionsService.rawOptions.fontFamily,"; font-size: ").concat(this._optionsService.rawOptions.fontSize,"px;}");t+="".concat(this._terminalSelector," span:not(.").concat(o.BOLD_CLASS,") { font-weight: ").concat(this._optionsService.rawOptions.fontWeight,";}").concat(this._terminalSelector," span.").concat(o.BOLD_CLASS," { font-weight: ").concat(this._optionsService.rawOptions.fontWeightBold,";}").concat(this._terminalSelector," span.").concat(o.ITALIC_CLASS," { font-style: italic;}"),t+="@keyframes blink_box_shadow_"+this._terminalClass+" { 50% { box-shadow: none; }}",t+="@keyframes blink_block_"+this._terminalClass+" { 0% {"+" background-color: ".concat(e.cursor.css,";")+" color: ".concat(e.cursorAccent.css,"; } 50% {")+" background-color: ".concat(e.cursorAccent.css,";")+" color: ".concat(e.cursor.css,"; }}"),t+="".concat(this._terminalSelector," .xterm-rows:not(.xterm-focus) .").concat(o.CURSOR_CLASS,".").concat(o.CURSOR_STYLE_BLOCK_CLASS," { outline: 1px solid ").concat(e.cursor.css,"; outline-offset: -1px;}").concat(this._terminalSelector," .xterm-rows.xterm-focus .").concat(o.CURSOR_CLASS,".").concat(o.CURSOR_BLINK_CLASS,":not(.").concat(o.CURSOR_STYLE_BLOCK_CLASS,") { animation: blink_box_shadow_")+this._terminalClass+" 1s step-end infinite;}"+"".concat(this._terminalSelector," .xterm-rows.xterm-focus .").concat(o.CURSOR_CLASS,".").concat(o.CURSOR_BLINK_CLASS,".").concat(o.CURSOR_STYLE_BLOCK_CLASS," { animation: blink_block_")+this._terminalClass+" 1s step-end infinite;}"+"".concat(this._terminalSelector," .xterm-rows.xterm-focus .").concat(o.CURSOR_CLASS,".").concat(o.CURSOR_STYLE_BLOCK_CLASS," {")+" background-color: ".concat(e.cursor.css,";")+" color: ".concat(e.cursorAccent.css,";}")+"".concat(this._terminalSelector," .xterm-rows .").concat(o.CURSOR_CLASS,".").concat(o.CURSOR_STYLE_BAR_CLASS," {")+" box-shadow: ".concat(this._optionsService.rawOptions.cursorWidth,"px 0 0 ").concat(e.cursor.css," inset;}")+"".concat(this._terminalSelector," .xterm-rows .").concat(o.CURSOR_CLASS,".").concat(o.CURSOR_STYLE_UNDERLINE_CLASS," {")+" box-shadow: 0 -1px 0 ".concat(e.cursor.css," inset;}"),t+="".concat(this._terminalSelector," .xterm-selection { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}").concat(this._terminalSelector,".focus .xterm-selection div { position: absolute; background-color: ").concat(e.selectionBackgroundOpaque.css,";}").concat(this._terminalSelector," .xterm-selection div { position: absolute; background-color: ").concat(e.selectionInactiveBackgroundOpaque.css,";}");var i,r=u(e.ansi.entries());try{for(r.s();!(i=r.n()).done;){var n=l(i.value,2),s=n[0],c=n[1];t+="".concat(this._terminalSelector," .xterm-fg-").concat(s," { color: ").concat(c.css,"; }").concat(this._terminalSelector," .xterm-bg-").concat(s," { background-color: ").concat(c.css,"; }")}}catch(h){r.e(h)}finally{r.f()}t+="".concat(this._terminalSelector," .xterm-fg-").concat(a.INVERTED_DEFAULT_COLOR," { color: ").concat(p.color.opaque(e.background).css,"; }").concat(this._terminalSelector," .xterm-bg-").concat(a.INVERTED_DEFAULT_COLOR," { background-color: ").concat(e.foreground.css,"; }"),this._themeStyleElement.textContent=t}},{key:"handleDevicePixelRatioChange",value:function(){this._updateDimensions()}},{key:"_refreshRowElements",value:function(e,t){for(var i=this._rowElements.length;i<=t;i++){var r=document.createElement("div");this._rowContainer.appendChild(r),this._rowElements.push(r)}for(;this._rowElements.length>t;)this._rowContainer.removeChild(this._rowElements.pop())}},{key:"handleResize",value:function(e,t){this._refreshRowElements(e,t),this._updateDimensions()}},{key:"handleCharSizeChanged",value:function(){this._updateDimensions()}},{key:"handleBlur",value:function(){this._rowContainer.classList.remove(C)}},{key:"handleFocus",value:function(){this._rowContainer.classList.add(C)}},{key:"handleSelectionChanged",value:function(e,t,i){for(;this._selectionContainer.children.length;)this._selectionContainer.removeChild(this._selectionContainer.children[0]);if(this._rowFactory.handleSelectionChanged(e,t,i),this.renderRows(0,this._bufferService.rows-1),e&&t){var r=e[1]-this._bufferService.buffer.ydisp,n=t[1]-this._bufferService.buffer.ydisp,s=Math.max(r,0),o=Math.min(n,this._bufferService.rows-1);if(!(s>=this._bufferService.rows||o<0)){var a=document.createDocumentFragment();if(i){var c=e[0]>t[0];a.appendChild(this._createSelectionElement(s,c?t[0]:e[0],c?e[0]:t[0],o-s+1))}else{var l=r===s?e[0]:0,u=s===n?t[0]:this._bufferService.cols;a.appendChild(this._createSelectionElement(s,l,u));var h=o-s-1;if(a.appendChild(this._createSelectionElement(s+1,0,this._bufferService.cols,h)),s!==o){var f=n===o?t[0]:this._bufferService.cols;a.appendChild(this._createSelectionElement(o,0,f))}}this._selectionContainer.appendChild(a)}}}},{key:"_createSelectionElement",value:function(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,n=document.createElement("div");return n.style.height=r*this.dimensions.css.cell.height+"px",n.style.top=e*this.dimensions.css.cell.height+"px",n.style.left=t*this.dimensions.css.cell.width+"px",n.style.width=this.dimensions.css.cell.width*(i-t)+"px",n}},{key:"handleCursorMove",value:function(){}},{key:"_handleOptionsChanged",value:function(){this._updateDimensions()}},{key:"clear",value:function(){var e,t=u(this._rowElements);try{for(t.s();!(e=t.n()).done;)e.value.replaceChildren()}catch(i){t.e(i)}finally{t.f()}}},{key:"renderRows",value:function(e,t){for(var i=this._bufferService.buffer.ybase+this._bufferService.buffer.y,r=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1),n=this._optionsService.rawOptions.cursorBlink,s=e;s<=t;s++){var o=this._rowElements[s],a=s+this._bufferService.buffer.ydisp,c=this._bufferService.buffer.lines.get(a),l=this._optionsService.rawOptions.cursorStyle;this._cellToRowElements[s]&&this._cellToRowElements[s].length===this._bufferService.cols||(this._cellToRowElements[s]=new Int16Array(this._bufferService.cols)),o.replaceChildren(this._rowFactory.createRow(c,a,a===i,l,r,n,this.dimensions.css.cell.width,this._bufferService.cols,this._cellToRowElements[s]))}}},{key:"_terminalSelector",get:function(){return".".concat(b).concat(this._terminalClass)}},{key:"_handleLinkHover",value:function(e){this._setCellUnderline(e.x1,e.x2,e.y1,e.y2,e.cols,!0)}},{key:"_handleLinkLeave",value:function(e){this._setCellUnderline(e.x1,e.x2,e.y1,e.y2,e.cols,!1)}},{key:"_setCellUnderline",value:function(e,t,i,r,n,s){if(e=this._cellToRowElements[i][e],t=this._cellToRowElements[r][t],-1!==e&&-1!==t)for(;e!==t||i!==r;){var o=this._rowElements[i];if(!o)return;var a=o.children[e];a&&(a.style.textDecoration=s?"underline":"none"),++e>=n&&(e=0,i++)}}}]),i}(m.Disposable);w=r([n(4,y.IInstantiationService),n(5,d.ICharSizeService),n(6,y.IOptionsService),n(7,y.IBufferService),n(8,d.ICoreBrowserService),n(9,d.IThemeService)],w),t.DomRenderer=w},3787:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.DomRendererRowFactory=t.CURSOR_STYLE_UNDERLINE_CLASS=t.CURSOR_STYLE_BAR_CLASS=t.CURSOR_STYLE_BLOCK_CLASS=t.CURSOR_BLINK_CLASS=t.CURSOR_CLASS=t.STRIKETHROUGH_CLASS=t.UNDERLINE_CLASS=t.ITALIC_CLASS=t.DIM_CLASS=t.BOLD_CLASS=void 0;var s=i(2223),o=i(643),a=i(511),c=i(2585),l=i(8055),u=i(4725),d=i(4269),v=i(6171),_=i(3734);t.BOLD_CLASS="xterm-bold",t.DIM_CLASS="xterm-dim",t.ITALIC_CLASS="xterm-italic",t.UNDERLINE_CLASS="xterm-underline",t.STRIKETHROUGH_CLASS="xterm-strikethrough",t.CURSOR_CLASS="xterm-cursor",t.CURSOR_BLINK_CLASS="xterm-cursor-blink",t.CURSOR_STYLE_BLOCK_CLASS="xterm-cursor-block",t.CURSOR_STYLE_BAR_CLASS="xterm-cursor-bar",t.CURSOR_STYLE_UNDERLINE_CLASS="xterm-cursor-underline";var p=function(){function e(t,i,r,n,s,o,c){h(this,e),this._document=t,this._characterJoinerService=i,this._optionsService=r,this._coreBrowserService=n,this._coreService=s,this._decorationService=o,this._themeService=c,this._workCell=new a.CellData,this._columnSelectMode=!1}return f(e,[{key:"handleSelectionChanged",value:function(e,t,i){this._selectionStart=e,this._selectionEnd=t,this._columnSelectMode=i}},{key:"createRow",value:function(e,i,r,n,a,c,u,h,f){for(var v=this,p=this._document.createDocumentFragment(),m=this._characterJoinerService.getJoinedCharacters(i),y=0,b=Math.min(e.length,h)-1;b>=0;b--)if(e.loadCell(b,this._workCell).getCode()!==o.NULL_CELL_CODE||r&&b===a){y=b+1;break}for(var C=this._themeService.colors,S=-1,w=0,k=function(){e.loadCell(w,v._workCell);var h=v._workCell.getWidth();if(0===h)return f[w]=S,"continue";var y=!1,b=w,k=v._workCell;if(m.length>0&&w===m[0][0]){y=!0;var x=m.shift();k=new d.JoinedCellData(v._workCell,e.translateToString(!0,x[0],x[1]),x[1]-x[0]),b=x[1]-1,h=k.getWidth()}var L=v._document.createElement("span");if(h>1&&(L.style.width=u*h+"px"),y&&(L.style.display="inline",a>=w&&a<=b&&(a=w)),!v._coreService.isCursorHidden&&r&&w===a)switch(L.classList.add(t.CURSOR_CLASS),c&&L.classList.add(t.CURSOR_BLINK_CLASS),n){case"bar":L.classList.add(t.CURSOR_STYLE_BAR_CLASS);break;case"underline":L.classList.add(t.CURSOR_STYLE_UNDERLINE_CLASS);break;default:L.classList.add(t.CURSOR_STYLE_BLOCK_CLASS)}if(k.isBold()&&L.classList.add(t.BOLD_CLASS),k.isItalic()&&L.classList.add(t.ITALIC_CLASS),k.isDim()&&L.classList.add(t.DIM_CLASS),k.isInvisible()?L.textContent=o.WHITESPACE_CELL_CHAR:L.textContent=k.getChars()||o.WHITESPACE_CELL_CHAR,k.isUnderline()&&(L.classList.add("".concat(t.UNDERLINE_CLASS,"-").concat(k.extended.underlineStyle))," "===L.textContent&&(L.textContent="\xa0"),!k.isUnderlineColorDefault()))if(k.isUnderlineColorRGB())L.style.textDecorationColor="rgb(".concat(_.AttributeData.toColorRGB(k.getUnderlineColor()).join(","),")");else{var E=k.getUnderlineColor();v._optionsService.rawOptions.drawBoldTextInBrightColors&&k.isBold()&&E<8&&(E+=8),L.style.textDecorationColor=C.ansi[E].css}k.isStrikethrough()&&L.classList.add(t.STRIKETHROUGH_CLASS);var R=k.getFgColor(),M=k.getFgColorMode(),A=k.getBgColor(),D=k.getBgColorMode(),O=!!k.isInverse();if(O){var T=R;R=A,A=T;var B=M;M=D,D=B}var I,P,F=!1;v._decorationService.forEachDecorationAtCell(w,i,void 0,(function(e){"top"!==e.options.layer&&F||(e.backgroundColorRGB&&(D=50331648,A=e.backgroundColorRGB.rgba>>8&16777215,I=e.backgroundColorRGB),e.foregroundColorRGB&&(M=50331648,R=e.foregroundColorRGB.rgba>>8&16777215,P=e.foregroundColorRGB),F="top"===e.options.layer)}));var H,N=v._isCellInSelection(w,i);switch(F||C.selectionForeground&&N&&(M=50331648,R=C.selectionForeground.rgba>>8&16777215,P=C.selectionForeground),N&&(I=v._coreBrowserService.isFocused?C.selectionBackgroundOpaque:C.selectionInactiveBackgroundOpaque,F=!0),F&&L.classList.add("xterm-decoration-top"),D){case 16777216:case 33554432:H=C.ansi[A],L.classList.add("xterm-bg-".concat(A));break;case 50331648:H=l.rgba.toColor(A>>16,A>>8&255,255&A),v._addStyle(L,"background-color:#".concat(g((A>>>0).toString(16),"0",6)));break;default:O?(H=C.foreground,L.classList.add("xterm-bg-".concat(s.INVERTED_DEFAULT_COLOR))):H=C.background}switch(I||k.isDim()&&(I=l.color.multiplyOpacity(H,.5)),M){case 16777216:case 33554432:k.isBold()&&R<8&&v._optionsService.rawOptions.drawBoldTextInBrightColors&&(R+=8),v._applyMinimumContrast(L,H,C.ansi[R],k,I,void 0)||L.classList.add("xterm-fg-".concat(R));break;case 50331648:var W=l.rgba.toColor(R>>16&255,R>>8&255,255&R);v._applyMinimumContrast(L,H,W,k,I,P)||v._addStyle(L,"color:#".concat(g(R.toString(16),"0",6)));break;default:v._applyMinimumContrast(L,H,C.foreground,k,I,void 0)||O&&L.classList.add("xterm-fg-".concat(s.INVERTED_DEFAULT_COLOR))}p.appendChild(L),f[w]=++S,w=b};w<y;w++)k();return w<h-1&&f.subarray(w).fill(++S),p}},{key:"_applyMinimumContrast",value:function(e,t,i,r,n,s){return 1!==this._optionsService.rawOptions.minimumContrastRatio&&!(0,v.excludeFromContrastRatioDemands)(r.getCode())&&(n||s||(o=this._themeService.colors.contrastCache.getColor(t.rgba,i.rgba)),void 0===o&&(o=l.color.ensureContrastRatio(n||t,s||i,this._optionsService.rawOptions.minimumContrastRatio),this._themeService.colors.contrastCache.setColor((n||t).rgba,(s||i).rgba,null!=o?o:null)),!!o&&(this._addStyle(e,"color:".concat(o.css)),!0));var o}},{key:"_addStyle",value:function(e,t){e.setAttribute("style","".concat(e.getAttribute("style")||"").concat(t,";"))}},{key:"_isCellInSelection",value:function(e,t){var i=this._selectionStart,r=this._selectionEnd;return!(!i||!r)&&(this._columnSelectMode?i[0]<=r[0]?e>=i[0]&&t>=i[1]&&e<r[0]&&t<=r[1]:e<i[0]&&t>=i[1]&&e>=r[0]&&t<=r[1]:t>i[1]&&t<r[1]||i[1]===r[1]&&t===i[1]&&e>=i[0]&&e<r[0]||i[1]<r[1]&&t===r[1]&&e<r[0]||i[1]<r[1]&&t===i[1]&&e>=i[0])}}]),e}();function g(e,t,i){for(;e.length<i;)e=t+e;return e}p=r([n(1,u.ICharacterJoinerService),n(2,c.IOptionsService),n(3,u.ICoreBrowserService),n(4,c.ICoreService),n(5,c.IDecorationService),n(6,u.IThemeService)],p),t.DomRendererRowFactory=p},2223:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.TEXT_BASELINE=t.DIM_OPACITY=t.INVERTED_DEFAULT_COLOR=void 0;var r=i(6114);t.INVERTED_DEFAULT_COLOR=257,t.DIM_OPACITY=.5,t.TEXT_BASELINE=r.isFirefox||r.isLegacyEdge?"bottom":"ideographic"},6171:function(e,t){function i(e){return 57508<=e&&e<=57558}Object.defineProperty(t,"__esModule",{value:!0}),t.createRenderDimensions=t.excludeFromContrastRatioDemands=t.isRestrictedPowerlineGlyph=t.isPowerlineGlyph=t.throwIfFalsy=void 0,t.throwIfFalsy=function(e){if(!e)throw new Error("value must not be falsy");return e},t.isPowerlineGlyph=i,t.isRestrictedPowerlineGlyph=function(e){return 57520<=e&&e<=57527},t.excludeFromContrastRatioDemands=function(e){return i(e)||function(e){return 9472<=e&&e<=9631}(e)},t.createRenderDimensions=function(){return{css:{canvas:{width:0,height:0},cell:{width:0,height:0}},device:{canvas:{width:0,height:0},cell:{width:0,height:0},char:{width:0,height:0,left:0,top:0}}}}},456:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionModel=void 0,t.SelectionModel=function(){function e(t){h(this,e),this._bufferService=t,this.isSelectAllActive=!1,this.selectionStartLength=0}return f(e,[{key:"clearSelection",value:function(){this.selectionStart=void 0,this.selectionEnd=void 0,this.isSelectAllActive=!1,this.selectionStartLength=0}},{key:"finalSelectionStart",get:function(){return this.isSelectAllActive?[0,0]:this.selectionEnd&&this.selectionStart&&this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart}},{key:"finalSelectionEnd",get:function(){if(this.isSelectAllActive)return[this._bufferService.cols,this._bufferService.buffer.ybase+this._bufferService.rows-1];if(this.selectionStart){if(!this.selectionEnd||this.areSelectionValuesReversed()){var e=this.selectionStart[0]+this.selectionStartLength;return e>this._bufferService.cols?e%this._bufferService.cols==0?[this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)-1]:[e%this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)]:[e,this.selectionStart[1]]}if(this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]){var t=this.selectionStart[0]+this.selectionStartLength;return t>this._bufferService.cols?[t%this._bufferService.cols,this.selectionStart[1]+Math.floor(t/this._bufferService.cols)]:[Math.max(t,this.selectionEnd[0]),this.selectionEnd[1]]}return this.selectionEnd}}},{key:"areSelectionValuesReversed",value:function(){var e=this.selectionStart,t=this.selectionEnd;return!(!e||!t)&&(e[1]>t[1]||e[1]===t[1]&&e[0]>t[0])}},{key:"handleTrim",value:function(e){return this.selectionStart&&(this.selectionStart[1]-=e),this.selectionEnd&&(this.selectionEnd[1]-=e),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)}}]),e}()},428:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CharSizeService=void 0;var s=i(2585),o=i(8460),a=function(e){v(i,e);var t=_(i);function i(e,r,n){var s;return h(this,i),(s=t.call(this))._optionsService=n,s.width=0,s.height=0,s._onCharSizeChange=s.register(new o.EventEmitter),s.onCharSizeChange=s._onCharSizeChange.event,s._measureStrategy=new c(e,r,s._optionsService),s.register(s._optionsService.onMultipleOptionChange(["fontFamily","fontSize"],(function(){return s.measure()}))),s}return f(i,[{key:"hasValidSize",get:function(){return this.width>0&&this.height>0}},{key:"measure",value:function(){var e=this._measureStrategy.measure();e.width===this.width&&e.height===this.height||(this.width=e.width,this.height=e.height,this._onCharSizeChange.fire())}}]),i}(i(844).Disposable);a=r([n(2,s.IOptionsService)],a),t.CharSizeService=a;var c=function(){function e(t,i,r){h(this,e),this._document=t,this._parentElement=i,this._optionsService=r,this._result={width:0,height:0},this._measureElement=this._document.createElement("span"),this._measureElement.classList.add("xterm-char-measure-element"),this._measureElement.textContent="W",this._measureElement.setAttribute("aria-hidden","true"),this._parentElement.appendChild(this._measureElement)}return f(e,[{key:"measure",value:function(){this._measureElement.style.fontFamily=this._optionsService.rawOptions.fontFamily,this._measureElement.style.fontSize="".concat(this._optionsService.rawOptions.fontSize,"px");var e=this._measureElement.getBoundingClientRect();return 0!==e.width&&0!==e.height&&(this._result.width=e.width,this._result.height=Math.ceil(e.height)),this._result}}]),e}()},4269:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CharacterJoinerService=t.JoinedCellData=void 0;var s=i(3734),o=i(643),a=i(511),c=i(2585),l=function(e){v(i,e);var t=_(i);function i(e,r,n){var s;return h(this,i),(s=t.call(this)).content=0,s.combinedData="",s.fg=e.fg,s.bg=e.bg,s.combinedData=r,s._width=n,s}return f(i,[{key:"isCombined",value:function(){return 2097152}},{key:"getWidth",value:function(){return this._width}},{key:"getChars",value:function(){return this.combinedData}},{key:"getCode",value:function(){return 2097151}},{key:"setFromCharData",value:function(e){throw new Error("not implemented")}},{key:"getAsCharData",value:function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}]),i}(s.AttributeData);t.JoinedCellData=l;var u=function(){function e(t){h(this,e),this._bufferService=t,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new a.CellData}return f(e,[{key:"register",value:function(e){var t={id:this._nextCharacterJoinerId++,handler:e};return this._characterJoiners.push(t),t.id}},{key:"deregister",value:function(e){for(var t=0;t<this._characterJoiners.length;t++)if(this._characterJoiners[t].id===e)return this._characterJoiners.splice(t,1),!0;return!1}},{key:"getJoinedCharacters",value:function(e){if(0===this._characterJoiners.length)return[];var t=this._bufferService.buffer.lines.get(e);if(!t||0===t.length)return[];for(var i=[],r=t.translateToString(!0),n=0,s=0,a=0,c=t.getFg(0),l=t.getBg(0),u=0;u<t.getTrimmedLength();u++)if(t.loadCell(u,this._workCell),0!==this._workCell.getWidth()){if(this._workCell.fg!==c||this._workCell.bg!==l){if(u-n>1)for(var h=this._getJoinedRanges(r,a,s,t,n),f=0;f<h.length;f++)i.push(h[f]);n=u,a=s,c=this._workCell.fg,l=this._workCell.bg}s+=this._workCell.getChars().length||o.WHITESPACE_CELL_CHAR.length}if(this._bufferService.cols-n>1)for(var d=this._getJoinedRanges(r,a,s,t,n),v=0;v<d.length;v++)i.push(d[v]);return i}},{key:"_getJoinedRanges",value:function(t,i,r,n,s){var o=t.substring(i,r),a=[];try{a=this._characterJoiners[0].handler(o)}catch(h){console.error(h)}for(var c=1;c<this._characterJoiners.length;c++)try{for(var l=this._characterJoiners[c].handler(o),u=0;u<l.length;u++)e._mergeRanges(a,l[u])}catch(f){console.error(f)}return this._stringRangesToCellRanges(a,n,s),a}},{key:"_stringRangesToCellRanges",value:function(e,t,i){var r=0,n=!1,s=0,a=e[r];if(a){for(var c=i;c<this._bufferService.cols;c++){var l=t.getWidth(c),u=t.getString(c).length||o.WHITESPACE_CELL_CHAR.length;if(0!==l){if(!n&&a[0]<=s&&(a[0]=c,n=!0),a[1]<=s){if(a[1]=c,!(a=e[++r]))break;a[0]<=s?(a[0]=c,n=!0):n=!1}s+=u}}a&&(a[1]=this._bufferService.cols)}}}],[{key:"_mergeRanges",value:function(e,t){for(var i=!1,r=0;r<e.length;r++){var n=e[r];if(i){if(t[1]<=n[0])return e[r-1][1]=t[1],e;if(t[1]<=n[1])return e[r-1][1]=Math.max(t[1],n[1]),e.splice(r,1),e;e.splice(r,1),r--}else{if(t[1]<=n[0])return e.splice(r,0,t),e;if(t[1]<=n[1])return n[0]=Math.min(t[0],n[0]),e;t[0]<n[1]&&(n[0]=Math.min(t[0],n[0]),i=!0)}}return i?e[e.length-1][1]=t[1]:e.push(t),e}}]),e}();u=r([n(0,c.IBufferService)],u),t.CharacterJoinerService=u},5114:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.CoreBrowserService=void 0,t.CoreBrowserService=function(){function e(t,i){var r=this;h(this,e),this._textarea=t,this.window=i,this._isFocused=!1,this._cachedIsFocused=void 0,this._textarea.addEventListener("focus",(function(){return r._isFocused=!0})),this._textarea.addEventListener("blur",(function(){return r._isFocused=!1}))}return f(e,[{key:"dpr",get:function(){return this.window.devicePixelRatio}},{key:"isFocused",get:function(){var e=this;return void 0===this._cachedIsFocused&&(this._cachedIsFocused=this._isFocused&&this._textarea.ownerDocument.hasFocus(),queueMicrotask((function(){return e._cachedIsFocused=void 0}))),this._cachedIsFocused}}]),e}()},8934:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.MouseService=void 0;var s=i(4725),o=i(9806),a=function(){function e(t,i){h(this,e),this._renderService=t,this._charSizeService=i}return f(e,[{key:"getCoords",value:function(e,t,i,r,n){return(0,o.getCoords)(window,e,t,i,r,this._charSizeService.hasValidSize,this._renderService.dimensions.css.cell.width,this._renderService.dimensions.css.cell.height,n)}},{key:"getMouseReportCoords",value:function(e,t){var i=(0,o.getCoordsRelativeToElement)(window,e,t);if(!(!this._charSizeService.hasValidSize||i[0]<0||i[1]<0||i[0]>=this._renderService.dimensions.css.canvas.width||i[1]>=this._renderService.dimensions.css.canvas.height))return{col:Math.floor(i[0]/this._renderService.dimensions.css.cell.width),row:Math.floor(i[1]/this._renderService.dimensions.css.cell.height),x:Math.floor(i[0]),y:Math.floor(i[1])}}}]),e}();a=r([n(0,s.IRenderService),n(1,s.ICharSizeService)],a),t.MouseService=a},3230:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.RenderService=void 0;var o=i(6193),a=i(8460),c=i(844),l=i(5596),u=i(3656),d=i(2585),p=i(4725),g=i(7226),m=function(e){v(i,e);var t=_(i);function i(e,r,n,c,f,d,v,_){var p;if(h(this,i),(p=t.call(this))._rowCount=e,p._charSizeService=c,p._pausedResizeTask=new g.DebouncedIdleTask,p._isPaused=!1,p._needsFullRefresh=!1,p._isNextRenderRedrawOnly=!0,p._needsSelectionRefresh=!1,p._canvasWidth=0,p._canvasHeight=0,p._selectionState={start:void 0,end:void 0,columnSelectMode:!1},p._onDimensionsChange=p.register(new a.EventEmitter),p.onDimensionsChange=p._onDimensionsChange.event,p._onRenderedViewportChange=p.register(new a.EventEmitter),p.onRenderedViewportChange=p._onRenderedViewportChange.event,p._onRender=p.register(new a.EventEmitter),p.onRender=p._onRender.event,p._onRefreshRequest=p.register(new a.EventEmitter),p.onRefreshRequest=p._onRefreshRequest.event,p.register({dispose:function(){var e;return null===(e=p._renderer)||void 0===e?void 0:e.dispose()}}),p._renderDebouncer=new o.RenderDebouncer(v.window,(function(e,t){return p._renderRows(e,t)})),p.register(p._renderDebouncer),p._screenDprMonitor=new l.ScreenDprMonitor(v.window),p._screenDprMonitor.setListener((function(){return p.handleDevicePixelRatioChange()})),p.register(p._screenDprMonitor),p.register(d.onResize((function(){return p._fullRefresh()}))),p.register(d.buffers.onBufferActivate((function(){var e;return null===(e=p._renderer)||void 0===e?void 0:e.clear()}))),p.register(n.onOptionChange((function(){return p._handleOptionsChanged()}))),p.register(p._charSizeService.onCharSizeChange((function(){return p.handleCharSizeChanged()}))),p.register(f.onDecorationRegistered((function(){return p._fullRefresh()}))),p.register(f.onDecorationRemoved((function(){return p._fullRefresh()}))),p.register(n.onMultipleOptionChange(["customGlyphs","drawBoldTextInBrightColors","letterSpacing","lineHeight","fontFamily","fontSize","fontWeight","fontWeightBold","minimumContrastRatio"],(function(){p.clear(),p.handleResize(d.cols,d.rows),p._fullRefresh()}))),p.register(n.onMultipleOptionChange(["cursorBlink","cursorStyle"],(function(){return p.refreshRows(d.buffer.y,d.buffer.y,!0)}))),p.register((0,u.addDisposableDomListener)(v.window,"resize",(function(){return p.handleDevicePixelRatioChange()}))),p.register(_.onChangeColors((function(){return p._fullRefresh()}))),"IntersectionObserver"in v.window){var m=new v.window.IntersectionObserver((function(e){return p._handleIntersectionChange(e[e.length-1])}),{threshold:0});m.observe(r),p.register({dispose:function(){return m.disconnect()}})}return s(p)}return f(i,[{key:"dimensions",get:function(){return this._renderer.dimensions}},{key:"_handleIntersectionChange",value:function(e){this._isPaused=void 0===e.isIntersecting?0===e.intersectionRatio:!e.isIntersecting,this._isPaused||this._charSizeService.hasValidSize||this._charSizeService.measure(),!this._isPaused&&this._needsFullRefresh&&(this._pausedResizeTask.flush(),this.refreshRows(0,this._rowCount-1),this._needsFullRefresh=!1)}},{key:"refreshRows",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this._isPaused?this._needsFullRefresh=!0:(i||(this._isNextRenderRedrawOnly=!1),this._renderDebouncer.refresh(e,t,this._rowCount))}},{key:"_renderRows",value:function(e,t){this._renderer&&(this._renderer.renderRows(e,t),this._needsSelectionRefresh&&(this._renderer.handleSelectionChanged(this._selectionState.start,this._selectionState.end,this._selectionState.columnSelectMode),this._needsSelectionRefresh=!1),this._isNextRenderRedrawOnly||this._onRenderedViewportChange.fire({start:e,end:t}),this._onRender.fire({start:e,end:t}),this._isNextRenderRedrawOnly=!0)}},{key:"resize",value:function(e,t){this._rowCount=t,this._fireOnCanvasResize()}},{key:"_handleOptionsChanged",value:function(){this._renderer&&(this.refreshRows(0,this._rowCount-1),this._fireOnCanvasResize())}},{key:"_fireOnCanvasResize",value:function(){this._renderer&&(this._renderer.dimensions.css.canvas.width===this._canvasWidth&&this._renderer.dimensions.css.canvas.height===this._canvasHeight||this._onDimensionsChange.fire(this._renderer.dimensions))}},{key:"hasRenderer",value:function(){return!!this._renderer}},{key:"setRenderer",value:function(e){var t,i=this;null===(t=this._renderer)||void 0===t||t.dispose(),this._renderer=e,this._renderer.onRequestRedraw((function(e){return i.refreshRows(e.start,e.end,!0)})),this._needsSelectionRefresh=!0,this._fullRefresh()}},{key:"addRefreshCallback",value:function(e){return this._renderDebouncer.addRefreshCallback(e)}},{key:"_fullRefresh",value:function(){this._isPaused?this._needsFullRefresh=!0:this.refreshRows(0,this._rowCount-1)}},{key:"clearTextureAtlas",value:function(){var e,t;this._renderer&&(null===(t=(e=this._renderer).clearTextureAtlas)||void 0===t||t.call(e),this._fullRefresh())}},{key:"handleDevicePixelRatioChange",value:function(){this._charSizeService.measure(),this._renderer&&(this._renderer.handleDevicePixelRatioChange(),this.refreshRows(0,this._rowCount-1))}},{key:"handleResize",value:function(e,t){var i=this;this._renderer&&(this._isPaused?this._pausedResizeTask.set((function(){return i._renderer.handleResize(e,t)})):this._renderer.handleResize(e,t),this._fullRefresh())}},{key:"handleCharSizeChanged",value:function(){var e;null===(e=this._renderer)||void 0===e||e.handleCharSizeChanged()}},{key:"handleBlur",value:function(){var e;null===(e=this._renderer)||void 0===e||e.handleBlur()}},{key:"handleFocus",value:function(){var e;null===(e=this._renderer)||void 0===e||e.handleFocus()}},{key:"handleSelectionChanged",value:function(e,t,i){var r;this._selectionState.start=e,this._selectionState.end=t,this._selectionState.columnSelectMode=i,null===(r=this._renderer)||void 0===r||r.handleSelectionChanged(e,t,i)}},{key:"handleCursorMove",value:function(){var e;null===(e=this._renderer)||void 0===e||e.handleCursorMove()}},{key:"clear",value:function(){var e;null===(e=this._renderer)||void 0===e||e.clear()}}]),i}(c.Disposable);m=r([n(2,d.IOptionsService),n(3,p.ICharSizeService),n(4,d.IDecorationService),n(5,d.IBufferService),n(6,p.ICoreBrowserService),n(7,p.IThemeService)],m),t.RenderService=m},9312:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionService=void 0;var s=i(6114),o=i(456),a=i(511),c=i(8460),l=i(4725),u=i(2585),d=i(9806),p=i(9504),g=i(844),m=i(4841),y=String.fromCharCode(160),b=new RegExp(y,"g"),C=function(e){v(i,e);var t=_(i);function i(e,r,n,s,l,u,f,d,v){var _;return h(this,i),(_=t.call(this))._element=e,_._screenElement=r,_._linkifier=n,_._bufferService=s,_._coreService=l,_._mouseService=u,_._optionsService=f,_._renderService=d,_._coreBrowserService=v,_._dragScrollAmount=0,_._enabled=!0,_._workCell=new a.CellData,_._mouseDownTimeStamp=0,_._oldHasSelection=!1,_._oldSelectionStart=void 0,_._oldSelectionEnd=void 0,_._onLinuxMouseSelection=_.register(new c.EventEmitter),_.onLinuxMouseSelection=_._onLinuxMouseSelection.event,_._onRedrawRequest=_.register(new c.EventEmitter),_.onRequestRedraw=_._onRedrawRequest.event,_._onSelectionChange=_.register(new c.EventEmitter),_.onSelectionChange=_._onSelectionChange.event,_._onRequestScrollLines=_.register(new c.EventEmitter),_.onRequestScrollLines=_._onRequestScrollLines.event,_._mouseMoveListener=function(e){return _._handleMouseMove(e)},_._mouseUpListener=function(e){return _._handleMouseUp(e)},_._coreService.onUserInput((function(){_.hasSelection&&_.clearSelection()})),_._trimListener=_._bufferService.buffer.lines.onTrim((function(e){return _._handleTrim(e)})),_.register(_._bufferService.buffers.onBufferActivate((function(e){return _._handleBufferActivate(e)}))),_.enable(),_._model=new o.SelectionModel(_._bufferService),_._activeSelectionMode=0,_.register((0,g.toDisposable)((function(){_._removeMouseDownListeners()}))),_}return f(i,[{key:"reset",value:function(){this.clearSelection()}},{key:"disable",value:function(){this.clearSelection(),this._enabled=!1}},{key:"enable",value:function(){this._enabled=!0}},{key:"selectionStart",get:function(){return this._model.finalSelectionStart}},{key:"selectionEnd",get:function(){return this._model.finalSelectionEnd}},{key:"hasSelection",get:function(){var e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;return!(!e||!t||e[0]===t[0]&&e[1]===t[1])}},{key:"selectionText",get:function(){var e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;if(!e||!t)return"";var i=this._bufferService.buffer,r=[];if(3===this._activeSelectionMode){if(e[0]===t[0])return"";for(var n=e[0]<t[0]?e[0]:t[0],o=e[0]<t[0]?t[0]:e[0],a=e[1];a<=t[1];a++){var c=i.translateBufferLineToString(a,!0,n,o);r.push(c)}}else{var l=e[1]===t[1]?t[0]:void 0;r.push(i.translateBufferLineToString(e[1],!0,e[0],l));for(var u=e[1]+1;u<=t[1]-1;u++){var h=i.lines.get(u),f=i.translateBufferLineToString(u,!0);(null==h?void 0:h.isWrapped)?r[r.length-1]+=f:r.push(f)}if(e[1]!==t[1]){var d=i.lines.get(t[1]),v=i.translateBufferLineToString(t[1],!0,0,t[0]);d&&d.isWrapped?r[r.length-1]+=v:r.push(v)}}return r.map((function(e){return e.replace(b," ")})).join(s.isWindows?"\r\n":"\n")}},{key:"clearSelection",value:function(){this._model.clearSelection(),this._removeMouseDownListeners(),this.refresh(),this._onSelectionChange.fire()}},{key:"refresh",value:function(e){var t=this;this._refreshAnimationFrame||(this._refreshAnimationFrame=this._coreBrowserService.window.requestAnimationFrame((function(){return t._refresh()}))),s.isLinux&&e&&this.selectionText.length&&this._onLinuxMouseSelection.fire(this.selectionText)}},{key:"_refresh",value:function(){this._refreshAnimationFrame=void 0,this._onRedrawRequest.fire({start:this._model.finalSelectionStart,end:this._model.finalSelectionEnd,columnSelectMode:3===this._activeSelectionMode})}},{key:"_isClickInSelection",value:function(e){var t=this._getMouseBufferCoords(e),i=this._model.finalSelectionStart,r=this._model.finalSelectionEnd;return!!(i&&r&&t)&&this._areCoordsInSelection(t,i,r)}},{key:"isCellInSelection",value:function(e,t){var i=this._model.finalSelectionStart,r=this._model.finalSelectionEnd;return!(!i||!r)&&this._areCoordsInSelection([e,t],i,r)}},{key:"_areCoordsInSelection",value:function(e,t,i){return e[1]>t[1]&&e[1]<i[1]||t[1]===i[1]&&e[1]===t[1]&&e[0]>=t[0]&&e[0]<i[0]||t[1]<i[1]&&e[1]===i[1]&&e[0]<i[0]||t[1]<i[1]&&e[1]===t[1]&&e[0]>=t[0]}},{key:"_selectWordAtCursor",value:function(e,t){var i,r,n=null===(r=null===(i=this._linkifier.currentLink)||void 0===i?void 0:i.link)||void 0===r?void 0:r.range;if(n)return this._model.selectionStart=[n.start.x-1,n.start.y-1],this._model.selectionStartLength=(0,m.getRangeLength)(n,this._bufferService.cols),this._model.selectionEnd=void 0,!0;var s=this._getMouseBufferCoords(e);return!!s&&(this._selectWordAt(s,t),this._model.selectionEnd=void 0,!0)}},{key:"selectAll",value:function(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()}},{key:"selectLines",value:function(e,t){this._model.clearSelection(),e=Math.max(e,0),t=Math.min(t,this._bufferService.buffer.lines.length-1),this._model.selectionStart=[0,e],this._model.selectionEnd=[this._bufferService.cols,t],this.refresh(),this._onSelectionChange.fire()}},{key:"_handleTrim",value:function(e){this._model.handleTrim(e)&&this.refresh()}},{key:"_getMouseBufferCoords",value:function(e){var t=this._mouseService.getCoords(e,this._screenElement,this._bufferService.cols,this._bufferService.rows,!0);if(t)return t[0]--,t[1]--,t[1]+=this._bufferService.buffer.ydisp,t}},{key:"_getMouseEventScrollAmount",value:function(e){var t=(0,d.getCoordsRelativeToElement)(this._coreBrowserService.window,e,this._screenElement)[1],i=this._renderService.dimensions.css.canvas.height;return t>=0&&t<=i?0:(t>i&&(t-=i),t=Math.min(Math.max(t,-50),50),(t/=50)/Math.abs(t)+Math.round(14*t))}},{key:"shouldForceSelection",value:function(e){return s.isMac?e.altKey&&this._optionsService.rawOptions.macOptionClickForcesSelection:e.shiftKey}},{key:"handleMouseDown",value:function(e){if(this._mouseDownTimeStamp=e.timeStamp,(2!==e.button||!this.hasSelection)&&0===e.button){if(!this._enabled){if(!this.shouldForceSelection(e))return;e.stopPropagation()}e.preventDefault(),this._dragScrollAmount=0,this._enabled&&e.shiftKey?this._handleIncrementalClick(e):1===e.detail?this._handleSingleClick(e):2===e.detail?this._handleDoubleClick(e):3===e.detail&&this._handleTripleClick(e),this._addMouseDownListeners(),this.refresh(!0)}}},{key:"_addMouseDownListeners",value:function(){var e=this;this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.addEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.addEventListener("mouseup",this._mouseUpListener)),this._dragScrollIntervalTimer=this._coreBrowserService.window.setInterval((function(){return e._dragScroll()}),50)}},{key:"_removeMouseDownListeners",value:function(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.removeEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.removeEventListener("mouseup",this._mouseUpListener)),this._coreBrowserService.window.clearInterval(this._dragScrollIntervalTimer),this._dragScrollIntervalTimer=void 0}},{key:"_handleIncrementalClick",value:function(e){this._model.selectionStart&&(this._model.selectionEnd=this._getMouseBufferCoords(e))}},{key:"_handleSingleClick",value:function(e){if(this._model.selectionStartLength=0,this._model.isSelectAllActive=!1,this._activeSelectionMode=this.shouldColumnSelect(e)?3:0,this._model.selectionStart=this._getMouseBufferCoords(e),this._model.selectionStart){this._model.selectionEnd=void 0;var t=this._bufferService.buffer.lines.get(this._model.selectionStart[1]);t&&t.length!==this._model.selectionStart[0]&&0===t.hasWidth(this._model.selectionStart[0])&&this._model.selectionStart[0]++}}},{key:"_handleDoubleClick",value:function(e){this._selectWordAtCursor(e,!0)&&(this._activeSelectionMode=1)}},{key:"_handleTripleClick",value:function(e){var t=this._getMouseBufferCoords(e);t&&(this._activeSelectionMode=2,this._selectLineAt(t[1]))}},{key:"shouldColumnSelect",value:function(e){return e.altKey&&!(s.isMac&&this._optionsService.rawOptions.macOptionClickForcesSelection)}},{key:"_handleMouseMove",value:function(e){if(e.stopImmediatePropagation(),this._model.selectionStart){var t=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;if(this._model.selectionEnd=this._getMouseBufferCoords(e),this._model.selectionEnd){2===this._activeSelectionMode?this._model.selectionEnd[1]<this._model.selectionStart[1]?this._model.selectionEnd[0]=0:this._model.selectionEnd[0]=this._bufferService.cols:1===this._activeSelectionMode&&this._selectToWordAt(this._model.selectionEnd),this._dragScrollAmount=this._getMouseEventScrollAmount(e),3!==this._activeSelectionMode&&(this._dragScrollAmount>0?this._model.selectionEnd[0]=this._bufferService.cols:this._dragScrollAmount<0&&(this._model.selectionEnd[0]=0));var i=this._bufferService.buffer;if(this._model.selectionEnd[1]<i.lines.length){var r=i.lines.get(this._model.selectionEnd[1]);r&&0===r.hasWidth(this._model.selectionEnd[0])&&this._model.selectionEnd[0]++}t&&t[0]===this._model.selectionEnd[0]&&t[1]===this._model.selectionEnd[1]||this.refresh(!0)}else this.refresh(!0)}}},{key:"_dragScroll",value:function(){if(this._model.selectionEnd&&this._model.selectionStart&&this._dragScrollAmount){this._onRequestScrollLines.fire({amount:this._dragScrollAmount,suppressScrollEvent:!1});var e=this._bufferService.buffer;this._dragScrollAmount>0?(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=this._bufferService.cols),this._model.selectionEnd[1]=Math.min(e.ydisp+this._bufferService.rows,e.lines.length-1)):(3!==this._activeSelectionMode&&(this._model.selectionEnd[0]=0),this._model.selectionEnd[1]=e.ydisp),this.refresh()}}},{key:"_handleMouseUp",value:function(e){var t=e.timeStamp-this._mouseDownTimeStamp;if(this._removeMouseDownListeners(),this.selectionText.length<=1&&t<500&&e.altKey&&this._optionsService.rawOptions.altClickMovesCursor){if(this._bufferService.buffer.ybase===this._bufferService.buffer.ydisp){var i=this._mouseService.getCoords(e,this._element,this._bufferService.cols,this._bufferService.rows,!1);if(i&&void 0!==i[0]&&void 0!==i[1]){var r=(0,p.moveToCellSequence)(i[0]-1,i[1]-1,this._bufferService,this._coreService.decPrivateModes.applicationCursorKeys);this._coreService.triggerDataEvent(r,!0)}}}else this._fireEventIfSelectionChanged()}},{key:"_fireEventIfSelectionChanged",value:function(){var e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd,i=!(!e||!t||e[0]===t[0]&&e[1]===t[1]);i?e&&t&&(this._oldSelectionStart&&this._oldSelectionEnd&&e[0]===this._oldSelectionStart[0]&&e[1]===this._oldSelectionStart[1]&&t[0]===this._oldSelectionEnd[0]&&t[1]===this._oldSelectionEnd[1]||this._fireOnSelectionChange(e,t,i)):this._oldHasSelection&&this._fireOnSelectionChange(e,t,i)}},{key:"_fireOnSelectionChange",value:function(e,t,i){this._oldSelectionStart=e,this._oldSelectionEnd=t,this._oldHasSelection=i,this._onSelectionChange.fire()}},{key:"_handleBufferActivate",value:function(e){var t=this;this.clearSelection(),this._trimListener.dispose(),this._trimListener=e.activeBuffer.lines.onTrim((function(e){return t._handleTrim(e)}))}},{key:"_convertViewportColToCharacterIndex",value:function(e,t){for(var i=t,r=0;t>=r;r++){var n=e.loadCell(r,this._workCell).getChars().length;0===this._workCell.getWidth()?i--:n>1&&t!==r&&(i+=n-1)}return i}},{key:"setSelection",value:function(e,t,i){this._model.clearSelection(),this._removeMouseDownListeners(),this._model.selectionStart=[e,t],this._model.selectionStartLength=i,this.refresh(),this._fireEventIfSelectionChanged()}},{key:"rightClickSelect",value:function(e){this._isClickInSelection(e)||(this._selectWordAtCursor(e,!1)&&this.refresh(!0),this._fireEventIfSelectionChanged())}},{key:"_getWordAt",value:function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];if(!(e[0]>=this._bufferService.cols)){var n=this._bufferService.buffer,s=n.lines.get(e[1]);if(s){var o=n.translateBufferLineToString(e[1],!1),a=this._convertViewportColToCharacterIndex(s,e[0]),c=a,l=e[0]-a,u=0,h=0,f=0,d=0;if(" "===o.charAt(a)){for(;a>0&&" "===o.charAt(a-1);)a--;for(;c<o.length&&" "===o.charAt(c+1);)c++}else{var v=e[0],_=e[0];0===s.getWidth(v)&&(u++,v--),2===s.getWidth(_)&&(h++,_++);var p=s.getString(_).length;for(p>1&&(d+=p-1,c+=p-1);v>0&&a>0&&!this._isCharWordSeparator(s.loadCell(v-1,this._workCell));){s.loadCell(v-1,this._workCell);var g=this._workCell.getChars().length;0===this._workCell.getWidth()?(u++,v--):g>1&&(f+=g-1,a-=g-1),a--,v--}for(;_<s.length&&c+1<o.length&&!this._isCharWordSeparator(s.loadCell(_+1,this._workCell));){s.loadCell(_+1,this._workCell);var m=this._workCell.getChars().length;2===this._workCell.getWidth()?(h++,_++):m>1&&(d+=m-1,c+=m-1),c++,_++}}c++;var y=a+l-u+f,b=Math.min(this._bufferService.cols,c-a+u+h-f-d);if(t||""!==o.slice(a,c).trim()){if(i&&0===y&&32!==s.getCodePoint(0)){var C=n.lines.get(e[1]-1);if(C&&s.isWrapped&&32!==C.getCodePoint(this._bufferService.cols-1)){var S=this._getWordAt([this._bufferService.cols-1,e[1]-1],!1,!0,!1);if(S){var w=this._bufferService.cols-S.start;y-=w,b+=w}}}if(r&&y+b===this._bufferService.cols&&32!==s.getCodePoint(this._bufferService.cols-1)){var k=n.lines.get(e[1]+1);if((null==k?void 0:k.isWrapped)&&32!==k.getCodePoint(0)){var x=this._getWordAt([0,e[1]+1],!1,!1,!0);x&&(b+=x.length)}}return{start:y,length:b}}}}}},{key:"_selectWordAt",value:function(e,t){var i=this._getWordAt(e,t);if(i){for(;i.start<0;)i.start+=this._bufferService.cols,e[1]--;this._model.selectionStart=[i.start,e[1]],this._model.selectionStartLength=i.length}}},{key:"_selectToWordAt",value:function(e){var t=this._getWordAt(e,!0);if(t){for(var i=e[1];t.start<0;)t.start+=this._bufferService.cols,i--;if(!this._model.areSelectionValuesReversed())for(;t.start+t.length>this._bufferService.cols;)t.length-=this._bufferService.cols,i++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?t.start:t.start+t.length,i]}}},{key:"_isCharWordSeparator",value:function(e){return 0!==e.getWidth()&&this._optionsService.rawOptions.wordSeparator.indexOf(e.getChars())>=0}},{key:"_selectLineAt",value:function(e){var t=this._bufferService.buffer.getWrappedRangeForLine(e),i={start:{x:0,y:t.first},end:{x:this._bufferService.cols-1,y:t.last}};this._model.selectionStart=[0,t.first],this._model.selectionEnd=void 0,this._model.selectionStartLength=(0,m.getRangeLength)(i,this._bufferService.cols)}}]),i}(g.Disposable);C=r([n(3,u.IBufferService),n(4,u.ICoreService),n(5,l.IMouseService),n(6,u.IOptionsService),n(7,l.IRenderService),n(8,l.ICoreBrowserService)],C),t.SelectionService=C},4725:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.IThemeService=t.ICharacterJoinerService=t.ISelectionService=t.IRenderService=t.IMouseService=t.ICoreBrowserService=t.ICharSizeService=void 0;var r=i(8343);t.ICharSizeService=(0,r.createDecorator)("CharSizeService"),t.ICoreBrowserService=(0,r.createDecorator)("CoreBrowserService"),t.IMouseService=(0,r.createDecorator)("MouseService"),t.IRenderService=(0,r.createDecorator)("RenderService"),t.ISelectionService=(0,r.createDecorator)("SelectionService"),t.ICharacterJoinerService=(0,r.createDecorator)("CharacterJoinerService"),t.IThemeService=(0,r.createDecorator)("ThemeService")},6731:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.ThemeService=t.DEFAULT_ANSI_COLORS=void 0;var s=i(7239),o=i(8055),a=i(8460),c=i(844),l=i(2585),u=o.css.toColor("#ffffff"),d=o.css.toColor("#000000"),p=o.css.toColor("#ffffff"),g=o.css.toColor("#000000"),m={css:"rgba(255, 255, 255, 0.3)",rgba:4294967117};t.DEFAULT_ANSI_COLORS=Object.freeze(function(){for(var e=[o.css.toColor("#2e3436"),o.css.toColor("#cc0000"),o.css.toColor("#4e9a06"),o.css.toColor("#c4a000"),o.css.toColor("#3465a4"),o.css.toColor("#75507b"),o.css.toColor("#06989a"),o.css.toColor("#d3d7cf"),o.css.toColor("#555753"),o.css.toColor("#ef2929"),o.css.toColor("#8ae234"),o.css.toColor("#fce94f"),o.css.toColor("#729fcf"),o.css.toColor("#ad7fa8"),o.css.toColor("#34e2e2"),o.css.toColor("#eeeeec")],t=[0,95,135,175,215,255],i=0;i<216;i++){var r=t[i/36%6|0],n=t[i/6%6|0],s=t[i%6];e.push({css:o.channels.toCss(r,n,s),rgba:o.channels.toRgba(r,n,s)})}for(var a=0;a<24;a++){var c=8+10*a;e.push({css:o.channels.toCss(c,c,c),rgba:o.channels.toRgba(c,c,c)})}return e}());var y=function(e){v(r,e);var i=_(r);function r(e){var n;return h(this,r),(n=i.call(this))._optionsService=e,n._onChangeColors=n.register(new a.EventEmitter),n.onChangeColors=n._onChangeColors.event,n._contrastCache=new s.ColorContrastCache,n._colors={foreground:u,background:d,cursor:p,cursorAccent:g,selectionForeground:void 0,selectionBackgroundTransparent:m,selectionBackgroundOpaque:o.color.blend(d,m),selectionInactiveBackgroundTransparent:m,selectionInactiveBackgroundOpaque:o.color.blend(d,m),ansi:t.DEFAULT_ANSI_COLORS.slice(),contrastCache:n._contrastCache},n._updateRestoreColors(),n._setTheme(n._optionsService.rawOptions.theme),n.register(n._optionsService.onSpecificOptionChange("minimumContrastRatio",(function(){return n._contrastCache.clear()}))),n.register(n._optionsService.onSpecificOptionChange("theme",(function(){return n._setTheme(n._optionsService.rawOptions.theme)}))),n}return f(r,[{key:"colors",get:function(){return this._colors}},{key:"_setTheme",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=this._colors;if(i.foreground=b(e.foreground,u),i.background=b(e.background,d),i.cursor=b(e.cursor,p),i.cursorAccent=b(e.cursorAccent,g),i.selectionBackgroundTransparent=b(e.selectionBackground,m),i.selectionBackgroundOpaque=o.color.blend(i.background,i.selectionBackgroundTransparent),i.selectionInactiveBackgroundTransparent=b(e.selectionInactiveBackground,i.selectionBackgroundTransparent),i.selectionInactiveBackgroundOpaque=o.color.blend(i.background,i.selectionInactiveBackgroundTransparent),i.selectionForeground=e.selectionForeground?b(e.selectionForeground,o.NULL_COLOR):void 0,i.selectionForeground===o.NULL_COLOR&&(i.selectionForeground=void 0),o.color.isOpaque(i.selectionBackgroundTransparent)){var r=.3;i.selectionBackgroundTransparent=o.color.opacity(i.selectionBackgroundTransparent,r)}if(o.color.isOpaque(i.selectionInactiveBackgroundTransparent)){var n=.3;i.selectionInactiveBackgroundTransparent=o.color.opacity(i.selectionInactiveBackgroundTransparent,n)}if(i.ansi=t.DEFAULT_ANSI_COLORS.slice(),i.ansi[0]=b(e.black,t.DEFAULT_ANSI_COLORS[0]),i.ansi[1]=b(e.red,t.DEFAULT_ANSI_COLORS[1]),i.ansi[2]=b(e.green,t.DEFAULT_ANSI_COLORS[2]),i.ansi[3]=b(e.yellow,t.DEFAULT_ANSI_COLORS[3]),i.ansi[4]=b(e.blue,t.DEFAULT_ANSI_COLORS[4]),i.ansi[5]=b(e.magenta,t.DEFAULT_ANSI_COLORS[5]),i.ansi[6]=b(e.cyan,t.DEFAULT_ANSI_COLORS[6]),i.ansi[7]=b(e.white,t.DEFAULT_ANSI_COLORS[7]),i.ansi[8]=b(e.brightBlack,t.DEFAULT_ANSI_COLORS[8]),i.ansi[9]=b(e.brightRed,t.DEFAULT_ANSI_COLORS[9]),i.ansi[10]=b(e.brightGreen,t.DEFAULT_ANSI_COLORS[10]),i.ansi[11]=b(e.brightYellow,t.DEFAULT_ANSI_COLORS[11]),i.ansi[12]=b(e.brightBlue,t.DEFAULT_ANSI_COLORS[12]),i.ansi[13]=b(e.brightMagenta,t.DEFAULT_ANSI_COLORS[13]),i.ansi[14]=b(e.brightCyan,t.DEFAULT_ANSI_COLORS[14]),i.ansi[15]=b(e.brightWhite,t.DEFAULT_ANSI_COLORS[15]),e.extendedAnsi)for(var s=Math.min(i.ansi.length-16,e.extendedAnsi.length),a=0;a<s;a++)i.ansi[a+16]=b(e.extendedAnsi[a],t.DEFAULT_ANSI_COLORS[a+16]);this._contrastCache.clear(),this._updateRestoreColors(),this._onChangeColors.fire(this.colors)}},{key:"restoreColor",value:function(e){this._restoreColor(e),this._onChangeColors.fire(this.colors)}},{key:"_restoreColor",value:function(e){if(void 0!==e)switch(e){case 256:this._colors.foreground=this._restoreColors.foreground;break;case 257:this._colors.background=this._restoreColors.background;break;case 258:this._colors.cursor=this._restoreColors.cursor;break;default:this._colors.ansi[e]=this._restoreColors.ansi[e]}else for(var t=0;t<this._restoreColors.ansi.length;++t)this._colors.ansi[t]=this._restoreColors.ansi[t]}},{key:"modifyColors",value:function(e){e(this._colors),this._onChangeColors.fire(this.colors)}},{key:"_updateRestoreColors",value:function(){this._restoreColors={foreground:this._colors.foreground,background:this._colors.background,cursor:this._colors.cursor,ansi:this._colors.ansi.slice()}}}]),r}(c.Disposable);function b(e,t){if(void 0!==e)try{return o.css.toColor(e)}catch(e){}return t}y=r([n(0,l.IOptionsService)],y),t.ThemeService=y},6349:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.CircularList=void 0;var r=i(8460),n=function(e){v(i,e);var t=_(i);function i(e){var n;return h(this,i),(n=t.call(this))._maxLength=e,n.onDeleteEmitter=n.register(new r.EventEmitter),n.onDelete=n.onDeleteEmitter.event,n.onInsertEmitter=n.register(new r.EventEmitter),n.onInsert=n.onInsertEmitter.event,n.onTrimEmitter=n.register(new r.EventEmitter),n.onTrim=n.onTrimEmitter.event,n._array=new Array(n._maxLength),n._startIndex=0,n._length=0,n}return f(i,[{key:"maxLength",get:function(){return this._maxLength},set:function(e){if(this._maxLength!==e){for(var t=new Array(e),i=0;i<Math.min(e,this.length);i++)t[i]=this._array[this._getCyclicIndex(i)];this._array=t,this._maxLength=e,this._startIndex=0}}},{key:"length",get:function(){return this._length},set:function(e){if(e>this._length)for(var t=this._length;t<e;t++)this._array[t]=void 0;this._length=e}},{key:"get",value:function(e){return this._array[this._getCyclicIndex(e)]}},{key:"set",value:function(e,t){this._array[this._getCyclicIndex(e)]=t}},{key:"push",value:function(e){this._array[this._getCyclicIndex(this._length)]=e,this._length===this._maxLength?(this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1)):this._length++}},{key:"recycle",value:function(){if(this._length!==this._maxLength)throw new Error("Can only recycle when the buffer is full");return this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1),this._array[this._getCyclicIndex(this._length-1)]}},{key:"isFull",get:function(){return this._length===this._maxLength}},{key:"pop",value:function(){return this._array[this._getCyclicIndex(this._length---1)]}},{key:"splice",value:function(e,t){if(t){for(var i=e;i<this._length-t;i++)this._array[this._getCyclicIndex(i)]=this._array[this._getCyclicIndex(i+t)];this._length-=t,this.onDeleteEmitter.fire({index:e,amount:t})}for(var r=this._length-1;r>=e;r--)this._array[this._getCyclicIndex(r+(arguments.length<=2?0:arguments.length-2))]=this._array[this._getCyclicIndex(r)];for(var n=0;n<(arguments.length<=2?0:arguments.length-2);n++)this._array[this._getCyclicIndex(e+n)]=n+2<2||arguments.length<=n+2?void 0:arguments[n+2];if((arguments.length<=2?0:arguments.length-2)&&this.onInsertEmitter.fire({index:e,amount:arguments.length<=2?0:arguments.length-2}),this._length+(arguments.length<=2?0:arguments.length-2)>this._maxLength){var s=this._length+(arguments.length<=2?0:arguments.length-2)-this._maxLength;this._startIndex+=s,this._length=this._maxLength,this.onTrimEmitter.fire(s)}else this._length+=arguments.length<=2?0:arguments.length-2}},{key:"trimStart",value:function(e){e>this._length&&(e=this._length),this._startIndex+=e,this._length-=e,this.onTrimEmitter.fire(e)}},{key:"shiftElements",value:function(e,t,i){if(!(t<=0)){if(e<0||e>=this._length)throw new Error("start argument out of range");if(e+i<0)throw new Error("Cannot shift elements in list beyond index 0");if(i>0){for(var r=t-1;r>=0;r--)this.set(e+r+i,this.get(e+r));var n=e+t+i-this._length;if(n>0)for(this._length+=n;this._length>this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(var s=0;s<t;s++)this.set(e+s+i,this.get(e+s))}}},{key:"_getCyclicIndex",value:function(e){return(this._startIndex+e)%this._maxLength}}]),i}(i(844).Disposable);t.CircularList=n},1439:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.clone=void 0,t.clone=function e(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:5;if("object"!=typeof t)return t;var r=Array.isArray(t)?[]:{};for(var n in t)r[n]=i<=1?t[n]:t[n]&&e(t[n],i-1);return r}},8055:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.contrastRatio=t.toPaddedHex=t.rgba=t.rgb=t.css=t.color=t.channels=t.NULL_COLOR=void 0;var r,n,s,o=i(6114),a=0,c=0,u=0,h=0;function f(e){var t=e.toString(16);return t.length<2?"0"+t:t}function d(e,t){return e<t?(t+.05)/(e+.05):(e+.05)/(t+.05)}t.NULL_COLOR={css:"#00000000",rgba:0},function(e){e.toCss=function(e,t,i,r){return void 0!==r?"#".concat(f(e)).concat(f(t)).concat(f(i)).concat(f(r)):"#".concat(f(e)).concat(f(t)).concat(f(i))},e.toRgba=function(e,t,i){return(e<<24|t<<16|i<<8|(arguments.length>3&&void 0!==arguments[3]?arguments[3]:255))>>>0}}(r=t.channels||(t.channels={})),function(e){function t(e,t){var i,n;return h=Math.round(255*t),i=s.toChannels(e.rgba),n=l(i,3),a=n[0],c=n[1],u=n[2],{css:r.toCss(a,c,u,h),rgba:r.toRgba(a,c,u,h)}}e.blend=function(e,t){if(1===(h=(255&t.rgba)/255))return{css:t.css,rgba:t.rgba};var i=t.rgba>>24&255,n=t.rgba>>16&255,s=t.rgba>>8&255,o=e.rgba>>24&255,l=e.rgba>>16&255,f=e.rgba>>8&255;return a=o+Math.round((i-o)*h),c=l+Math.round((n-l)*h),u=f+Math.round((s-f)*h),{css:r.toCss(a,c,u),rgba:r.toRgba(a,c,u)}},e.isOpaque=function(e){return 255==(255&e.rgba)},e.ensureContrastRatio=function(e,t,i){var r=s.ensureContrastRatio(e.rgba,t.rgba,i);if(r)return s.toColor(r>>24&255,r>>16&255,r>>8&255)},e.opaque=function(e){var t,i,n=(255|e.rgba)>>>0;return t=s.toChannels(n),i=l(t,3),a=i[0],c=i[1],u=i[2],{css:r.toCss(a,c,u),rgba:n}},e.opacity=t,e.multiplyOpacity=function(e,i){return t(e,(h=255&e.rgba)*i/255)},e.toColorRGB=function(e){return[e.rgba>>24&255,e.rgba>>16&255,e.rgba>>8&255]}}(t.color||(t.color={})),function(e){var t,i;if(!o.isNode){var n=document.createElement("canvas");n.width=1,n.height=1;var f=n.getContext("2d",{willReadFrequently:!0});f&&((t=f).globalCompositeOperation="copy",i=t.createLinearGradient(0,0,1,1))}e.toColor=function(e){var n;if(e.match(/#[\da-f]{3,8}/i))switch(e.length){case 4:return a=parseInt(e.slice(1,2).repeat(2),16),c=parseInt(e.slice(2,3).repeat(2),16),u=parseInt(e.slice(3,4).repeat(2),16),s.toColor(a,c,u);case 5:return a=parseInt(e.slice(1,2).repeat(2),16),c=parseInt(e.slice(2,3).repeat(2),16),u=parseInt(e.slice(3,4).repeat(2),16),h=parseInt(e.slice(4,5).repeat(2),16),s.toColor(a,c,u,h);case 7:return{css:e,rgba:(parseInt(e.slice(1),16)<<8|255)>>>0};case 9:return{css:e,rgba:parseInt(e.slice(1),16)>>>0}}var o=e.match(/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(,\s*(0|1|\d?\.(\d+))\s*)?\)/);if(o)return a=parseInt(o[1]),c=parseInt(o[2]),u=parseInt(o[3]),h=Math.round(255*(void 0===o[5]?1:parseFloat(o[5]))),s.toColor(a,c,u,h);if(!t||!i)throw new Error("css.toColor: Unsupported css format");if(t.fillStyle=i,t.fillStyle=e,"string"!=typeof t.fillStyle)throw new Error("css.toColor: Unsupported css format");if(t.fillRect(0,0,1,1),n=l(t.getImageData(0,0,1,1).data,4),a=n[0],c=n[1],u=n[2],255!==(h=n[3]))throw new Error("css.toColor: Unsupported css format");return{rgba:r.toRgba(a,c,u,h),css:e}}}(t.css||(t.css={})),function(e){function t(e,t,i){var r=e/255,n=t/255,s=i/255;return.2126*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))+.7152*(n<=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4))+.0722*(s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4))}e.relativeLuminance=function(e){return t(e>>16&255,e>>8&255,255&e)},e.relativeLuminance2=t}(n=t.rgb||(t.rgb={})),function(e){function t(e,t,i){for(var r=e>>24&255,s=e>>16&255,o=e>>8&255,a=t>>24&255,c=t>>16&255,l=t>>8&255,u=d(n.relativeLuminance2(a,c,l),n.relativeLuminance2(r,s,o));u<i&&(a>0||c>0||l>0);)a-=Math.max(0,Math.ceil(.1*a)),c-=Math.max(0,Math.ceil(.1*c)),l-=Math.max(0,Math.ceil(.1*l)),u=d(n.relativeLuminance2(a,c,l),n.relativeLuminance2(r,s,o));return(a<<24|c<<16|l<<8|255)>>>0}function i(e,t,i){for(var r=e>>24&255,s=e>>16&255,o=e>>8&255,a=t>>24&255,c=t>>16&255,l=t>>8&255,u=d(n.relativeLuminance2(a,c,l),n.relativeLuminance2(r,s,o));u<i&&(a<255||c<255||l<255);)a=Math.min(255,a+Math.ceil(.1*(255-a))),c=Math.min(255,c+Math.ceil(.1*(255-c))),l=Math.min(255,l+Math.ceil(.1*(255-l))),u=d(n.relativeLuminance2(a,c,l),n.relativeLuminance2(r,s,o));return(a<<24|c<<16|l<<8|255)>>>0}e.ensureContrastRatio=function(e,r,s){var o=n.relativeLuminance(e>>8),a=n.relativeLuminance(r>>8);if(d(o,a)<s){if(a<o){var c=t(e,r,s),l=d(o,n.relativeLuminance(c>>8));if(l<s){var u=i(e,r,s);return l>d(o,n.relativeLuminance(u>>8))?c:u}return c}var h=i(e,r,s),f=d(o,n.relativeLuminance(h>>8));if(f<s){var v=t(e,r,s);return f>d(o,n.relativeLuminance(v>>8))?h:v}return h}},e.reduceLuminance=t,e.increaseLuminance=i,e.toChannels=function(e){return[e>>24&255,e>>16&255,e>>8&255,255&e]},e.toColor=function(e,t,i,n){return{css:r.toCss(e,t,i,n),rgba:r.toRgba(e,t,i,n)}}}(s=t.rgba||(t.rgba={})),t.toPaddedHex=f,t.contrastRatio=d},8969:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.CoreTerminal=void 0;var r=i(844),n=i(2585),s=i(4348),o=i(7866),a=i(744),c=i(7302),l=i(6975),u=i(8460),d=i(1753),p=i(1480),g=i(7994),m=i(9282),y=i(5435),b=i(5981),C=i(2660),S=!1,w=function(e){v(i,e);var t=_(i);function i(e){var f;return h(this,i),(f=t.call(this))._onBinary=f.register(new u.EventEmitter),f.onBinary=f._onBinary.event,f._onData=f.register(new u.EventEmitter),f.onData=f._onData.event,f._onLineFeed=f.register(new u.EventEmitter),f.onLineFeed=f._onLineFeed.event,f._onResize=f.register(new u.EventEmitter),f.onResize=f._onResize.event,f._onWriteParsed=f.register(new u.EventEmitter),f.onWriteParsed=f._onWriteParsed.event,f._onScroll=f.register(new u.EventEmitter),f._instantiationService=new s.InstantiationService,f.optionsService=f.register(new c.OptionsService(e)),f._instantiationService.setService(n.IOptionsService,f.optionsService),f._bufferService=f.register(f._instantiationService.createInstance(a.BufferService)),f._instantiationService.setService(n.IBufferService,f._bufferService),f._logService=f.register(f._instantiationService.createInstance(o.LogService)),f._instantiationService.setService(n.ILogService,f._logService),f.coreService=f.register(f._instantiationService.createInstance(l.CoreService)),f._instantiationService.setService(n.ICoreService,f.coreService),f.coreMouseService=f.register(f._instantiationService.createInstance(d.CoreMouseService)),f._instantiationService.setService(n.ICoreMouseService,f.coreMouseService),f.unicodeService=f.register(f._instantiationService.createInstance(p.UnicodeService)),f._instantiationService.setService(n.IUnicodeService,f.unicodeService),f._charsetService=f._instantiationService.createInstance(g.CharsetService),f._instantiationService.setService(n.ICharsetService,f._charsetService),f._oscLinkService=f._instantiationService.createInstance(C.OscLinkService),f._instantiationService.setService(n.IOscLinkService,f._oscLinkService),f._inputHandler=f.register(new y.InputHandler(f._bufferService,f._charsetService,f.coreService,f._logService,f.optionsService,f._oscLinkService,f.coreMouseService,f.unicodeService)),f.register((0,u.forwardEvent)(f._inputHandler.onLineFeed,f._onLineFeed)),f.register(f._inputHandler),f.register((0,u.forwardEvent)(f._bufferService.onResize,f._onResize)),f.register((0,u.forwardEvent)(f.coreService.onData,f._onData)),f.register((0,u.forwardEvent)(f.coreService.onBinary,f._onBinary)),f.register(f.coreService.onRequestScrollToBottom((function(){return f.scrollToBottom()}))),f.register(f.coreService.onUserInput((function(){return f._writeBuffer.handleUserInput()}))),f.register(f.optionsService.onSpecificOptionChange("windowsMode",(function(e){return f._handleWindowsModeOptionChange(e)}))),f.register(f._bufferService.onScroll((function(e){f._onScroll.fire({position:f._bufferService.buffer.ydisp,source:0}),f._inputHandler.markRangeDirty(f._bufferService.buffer.scrollTop,f._bufferService.buffer.scrollBottom)}))),f.register(f._inputHandler.onScroll((function(e){f._onScroll.fire({position:f._bufferService.buffer.ydisp,source:0}),f._inputHandler.markRangeDirty(f._bufferService.buffer.scrollTop,f._bufferService.buffer.scrollBottom)}))),f._writeBuffer=f.register(new b.WriteBuffer((function(e,t){return f._inputHandler.parse(e,t)}))),f.register((0,u.forwardEvent)(f._writeBuffer.onWriteParsed,f._onWriteParsed)),f.register((0,r.toDisposable)((function(){var e;null===(e=f._windowsMode)||void 0===e||e.dispose(),f._windowsMode=void 0}))),f}return f(i,[{key:"onScroll",get:function(){var e=this;return this._onScrollApi||(this._onScrollApi=this.register(new u.EventEmitter),this._onScroll.event((function(t){var i;null===(i=e._onScrollApi)||void 0===i||i.fire(t.position)}))),this._onScrollApi.event}},{key:"cols",get:function(){return this._bufferService.cols}},{key:"rows",get:function(){return this._bufferService.rows}},{key:"buffers",get:function(){return this._bufferService.buffers}},{key:"options",get:function(){return this.optionsService.options},set:function(e){for(var t in e)this.optionsService.options[t]=e[t]}},{key:"write",value:function(e,t){this._writeBuffer.write(e,t)}},{key:"writeSync",value:function(e,t){this._logService.logLevel<=n.LogLevelEnum.WARN&&!S&&(this._logService.warn("writeSync is unreliable and will be removed soon."),S=!0),this._writeBuffer.writeSync(e,t)}},{key:"resize",value:function(e,t){isNaN(e)||isNaN(t)||(e=Math.max(e,a.MINIMUM_COLS),t=Math.max(t,a.MINIMUM_ROWS),this._bufferService.resize(e,t))}},{key:"scroll",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this._bufferService.scroll(e,t)}},{key:"scrollLines",value:function(e,t,i){this._bufferService.scrollLines(e,t,i)}},{key:"scrollPages",value:function(e){this._bufferService.scrollPages(e)}},{key:"scrollToTop",value:function(){this._bufferService.scrollToTop()}},{key:"scrollToBottom",value:function(){this._bufferService.scrollToBottom()}},{key:"scrollToLine",value:function(e){this._bufferService.scrollToLine(e)}},{key:"registerEscHandler",value:function(e,t){return this._inputHandler.registerEscHandler(e,t)}},{key:"registerDcsHandler",value:function(e,t){return this._inputHandler.registerDcsHandler(e,t)}},{key:"registerCsiHandler",value:function(e,t){return this._inputHandler.registerCsiHandler(e,t)}},{key:"registerOscHandler",value:function(e,t){return this._inputHandler.registerOscHandler(e,t)}},{key:"_setup",value:function(){this.optionsService.rawOptions.windowsMode&&this._enableWindowsMode()}},{key:"reset",value:function(){this._inputHandler.reset(),this._bufferService.reset(),this._charsetService.reset(),this.coreService.reset(),this.coreMouseService.reset()}},{key:"_handleWindowsModeOptionChange",value:function(e){var t;e?this._enableWindowsMode():(null===(t=this._windowsMode)||void 0===t||t.dispose(),this._windowsMode=void 0)}},{key:"_enableWindowsMode",value:function(){var e=this;if(!this._windowsMode){var t=[];t.push(this.onLineFeed(m.updateWindowsModeWrappedState.bind(null,this._bufferService))),t.push(this.registerCsiHandler({final:"H"},(function(){return(0,m.updateWindowsModeWrappedState)(e._bufferService),!1}))),this._windowsMode={dispose:function(){for(var e=0,i=t;e<i.length;e++)i[e].dispose()}}}}}]),i}(r.Disposable);t.CoreTerminal=w},8460:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.forwardEvent=t.EventEmitter=void 0,t.EventEmitter=function(){function e(){h(this,e),this._listeners=[],this._disposed=!1}return f(e,[{key:"event",get:function(){var e=this;return this._event||(this._event=function(t){return e._listeners.push(t),{dispose:function(){if(!e._disposed)for(var i=0;i<e._listeners.length;i++)if(e._listeners[i]===t)return void e._listeners.splice(i,1)}}}),this._event}},{key:"fire",value:function(e,t){for(var i=[],r=0;r<this._listeners.length;r++)i.push(this._listeners[r]);for(var n=0;n<i.length;n++)i[n].call(void 0,e,t)}},{key:"dispose",value:function(){this._listeners&&(this._listeners.length=0),this._disposed=!0}}]),e}(),t.forwardEvent=function(e,t){return e((function(e){return t.fire(e)}))}},5435:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.InputHandler=t.WindowsOptionsReportType=void 0;var s,o=i(2584),a=i(7116),c=i(2015),l=i(844),u=i(482),d=i(8437),p=i(8460),g=i(643),m=i(511),y=i(3734),b=i(2585),C=i(6242),S=i(6351),w=i(5941),k={"(":0,")":1,"*":2,"+":3,"-":1,".":2},x=131072;function L(e,t){if(e>24)return t.setWinLines||!1;switch(e){case 1:return!!t.restoreWin;case 2:return!!t.minimizeWin;case 3:return!!t.setWinPosition;case 4:return!!t.setWinSizePixels;case 5:return!!t.raiseWin;case 6:return!!t.lowerWin;case 7:return!!t.refreshWin;case 8:return!!t.setWinSizeChars;case 9:return!!t.maximizeWin;case 10:return!!t.fullscreenWin;case 11:return!!t.getWinState;case 13:return!!t.getWinPosition;case 14:return!!t.getWinSizePixels;case 15:return!!t.getScreenSizePixels;case 16:return!!t.getCellSizePixels;case 18:return!!t.getWinSizeChars;case 19:return!!t.getScreenSizeChars;case 20:return!!t.getIconTitle;case 21:return!!t.getWinTitle;case 22:return!!t.pushTitle;case 23:return!!t.popTitle;case 24:return!!t.setWinLines}return!1}!function(e){e[e.GET_WIN_SIZE_PIXELS=0]="GET_WIN_SIZE_PIXELS",e[e.GET_CELL_SIZE_PIXELS=1]="GET_CELL_SIZE_PIXELS"}(s=t.WindowsOptionsReportType||(t.WindowsOptionsReportType={}));var E=0,R=function(e){v(i,e);var t=_(i);function i(e,r,n,s,l,f,v,_){var g,y=arguments.length>8&&void 0!==arguments[8]?arguments[8]:new c.EscapeSequenceParser;h(this,i),(g=t.call(this))._bufferService=e,g._charsetService=r,g._coreService=n,g._logService=s,g._optionsService=l,g._oscLinkService=f,g._coreMouseService=v,g._unicodeService=_,g._parser=y,g._parseBuffer=new Uint32Array(4096),g._stringDecoder=new u.StringToUtf32,g._utf8Decoder=new u.Utf8ToUtf32,g._workCell=new m.CellData,g._windowTitle="",g._iconName="",g._windowTitleStack=[],g._iconNameStack=[],g._curAttrData=d.DEFAULT_ATTR_DATA.clone(),g._eraseAttrDataInternal=d.DEFAULT_ATTR_DATA.clone(),g._onRequestBell=g.register(new p.EventEmitter),g.onRequestBell=g._onRequestBell.event,g._onRequestRefreshRows=g.register(new p.EventEmitter),g.onRequestRefreshRows=g._onRequestRefreshRows.event,g._onRequestReset=g.register(new p.EventEmitter),g.onRequestReset=g._onRequestReset.event,g._onRequestSendFocus=g.register(new p.EventEmitter),g.onRequestSendFocus=g._onRequestSendFocus.event,g._onRequestSyncScrollBar=g.register(new p.EventEmitter),g.onRequestSyncScrollBar=g._onRequestSyncScrollBar.event,g._onRequestWindowsOptionsReport=g.register(new p.EventEmitter),g.onRequestWindowsOptionsReport=g._onRequestWindowsOptionsReport.event,g._onA11yChar=g.register(new p.EventEmitter),g.onA11yChar=g._onA11yChar.event,g._onA11yTab=g.register(new p.EventEmitter),g.onA11yTab=g._onA11yTab.event,g._onCursorMove=g.register(new p.EventEmitter),g.onCursorMove=g._onCursorMove.event,g._onLineFeed=g.register(new p.EventEmitter),g.onLineFeed=g._onLineFeed.event,g._onScroll=g.register(new p.EventEmitter),g.onScroll=g._onScroll.event,g._onTitleChange=g.register(new p.EventEmitter),g.onTitleChange=g._onTitleChange.event,g._onColor=g.register(new p.EventEmitter),g.onColor=g._onColor.event,g._parseStack={paused:!1,cursorStartX:0,cursorStartY:0,decodedLength:0,position:0},g._specialColors=[256,257,258],g.register(g._parser),g._dirtyRowTracker=new M(g._bufferService),g._activeBuffer=g._bufferService.buffer,g.register(g._bufferService.buffers.onBufferActivate((function(e){return g._activeBuffer=e.activeBuffer}))),g._parser.setCsiHandlerFallback((function(e,t){g._logService.debug("Unknown CSI code: ",{identifier:g._parser.identToString(e),params:t.toArray()})})),g._parser.setEscHandlerFallback((function(e){g._logService.debug("Unknown ESC code: ",{identifier:g._parser.identToString(e)})})),g._parser.setExecuteHandlerFallback((function(e){g._logService.debug("Unknown EXECUTE code: ",{code:e})})),g._parser.setOscHandlerFallback((function(e,t,i){g._logService.debug("Unknown OSC code: ",{identifier:e,action:t,data:i})})),g._parser.setDcsHandlerFallback((function(e,t,i){"HOOK"===t&&(i=i.toArray()),g._logService.debug("Unknown DCS code: ",{identifier:g._parser.identToString(e),action:t,payload:i})})),g._parser.setPrintHandler((function(e,t,i){return g.print(e,t,i)})),g._parser.registerCsiHandler({final:"@"},(function(e){return g.insertChars(e)})),g._parser.registerCsiHandler({intermediates:" ",final:"@"},(function(e){return g.scrollLeft(e)})),g._parser.registerCsiHandler({final:"A"},(function(e){return g.cursorUp(e)})),g._parser.registerCsiHandler({intermediates:" ",final:"A"},(function(e){return g.scrollRight(e)})),g._parser.registerCsiHandler({final:"B"},(function(e){return g.cursorDown(e)})),g._parser.registerCsiHandler({final:"C"},(function(e){return g.cursorForward(e)})),g._parser.registerCsiHandler({final:"D"},(function(e){return g.cursorBackward(e)})),g._parser.registerCsiHandler({final:"E"},(function(e){return g.cursorNextLine(e)})),g._parser.registerCsiHandler({final:"F"},(function(e){return g.cursorPrecedingLine(e)})),g._parser.registerCsiHandler({final:"G"},(function(e){return g.cursorCharAbsolute(e)})),g._parser.registerCsiHandler({final:"H"},(function(e){return g.cursorPosition(e)})),g._parser.registerCsiHandler({final:"I"},(function(e){return g.cursorForwardTab(e)})),g._parser.registerCsiHandler({final:"J"},(function(e){return g.eraseInDisplay(e,!1)})),g._parser.registerCsiHandler({prefix:"?",final:"J"},(function(e){return g.eraseInDisplay(e,!0)})),g._parser.registerCsiHandler({final:"K"},(function(e){return g.eraseInLine(e,!1)})),g._parser.registerCsiHandler({prefix:"?",final:"K"},(function(e){return g.eraseInLine(e,!0)})),g._parser.registerCsiHandler({final:"L"},(function(e){return g.insertLines(e)})),g._parser.registerCsiHandler({final:"M"},(function(e){return g.deleteLines(e)})),g._parser.registerCsiHandler({final:"P"},(function(e){return g.deleteChars(e)})),g._parser.registerCsiHandler({final:"S"},(function(e){return g.scrollUp(e)})),g._parser.registerCsiHandler({final:"T"},(function(e){return g.scrollDown(e)})),g._parser.registerCsiHandler({final:"X"},(function(e){return g.eraseChars(e)})),g._parser.registerCsiHandler({final:"Z"},(function(e){return g.cursorBackwardTab(e)})),g._parser.registerCsiHandler({final:"`"},(function(e){return g.charPosAbsolute(e)})),g._parser.registerCsiHandler({final:"a"},(function(e){return g.hPositionRelative(e)})),g._parser.registerCsiHandler({final:"b"},(function(e){return g.repeatPrecedingCharacter(e)})),g._parser.registerCsiHandler({final:"c"},(function(e){return g.sendDeviceAttributesPrimary(e)})),g._parser.registerCsiHandler({prefix:">",final:"c"},(function(e){return g.sendDeviceAttributesSecondary(e)})),g._parser.registerCsiHandler({final:"d"},(function(e){return g.linePosAbsolute(e)})),g._parser.registerCsiHandler({final:"e"},(function(e){return g.vPositionRelative(e)})),g._parser.registerCsiHandler({final:"f"},(function(e){return g.hVPosition(e)})),g._parser.registerCsiHandler({final:"g"},(function(e){return g.tabClear(e)})),g._parser.registerCsiHandler({final:"h"},(function(e){return g.setMode(e)})),g._parser.registerCsiHandler({prefix:"?",final:"h"},(function(e){return g.setModePrivate(e)})),g._parser.registerCsiHandler({final:"l"},(function(e){return g.resetMode(e)})),g._parser.registerCsiHandler({prefix:"?",final:"l"},(function(e){return g.resetModePrivate(e)})),g._parser.registerCsiHandler({final:"m"},(function(e){return g.charAttributes(e)})),g._parser.registerCsiHandler({final:"n"},(function(e){return g.deviceStatus(e)})),g._parser.registerCsiHandler({prefix:"?",final:"n"},(function(e){return g.deviceStatusPrivate(e)})),g._parser.registerCsiHandler({intermediates:"!",final:"p"},(function(e){return g.softReset(e)})),g._parser.registerCsiHandler({intermediates:" ",final:"q"},(function(e){return g.setCursorStyle(e)})),g._parser.registerCsiHandler({final:"r"},(function(e){return g.setScrollRegion(e)})),g._parser.registerCsiHandler({final:"s"},(function(e){return g.saveCursor(e)})),g._parser.registerCsiHandler({final:"t"},(function(e){return g.windowOptions(e)})),g._parser.registerCsiHandler({final:"u"},(function(e){return g.restoreCursor(e)})),g._parser.registerCsiHandler({intermediates:"'",final:"}"},(function(e){return g.insertColumns(e)})),g._parser.registerCsiHandler({intermediates:"'",final:"~"},(function(e){return g.deleteColumns(e)})),g._parser.registerCsiHandler({intermediates:'"',final:"q"},(function(e){return g.selectProtected(e)})),g._parser.registerCsiHandler({intermediates:"$",final:"p"},(function(e){return g.requestMode(e,!0)})),g._parser.registerCsiHandler({prefix:"?",intermediates:"$",final:"p"},(function(e){return g.requestMode(e,!1)})),g._parser.setExecuteHandler(o.C0.BEL,(function(){return g.bell()})),g._parser.setExecuteHandler(o.C0.LF,(function(){return g.lineFeed()})),g._parser.setExecuteHandler(o.C0.VT,(function(){return g.lineFeed()})),g._parser.setExecuteHandler(o.C0.FF,(function(){return g.lineFeed()})),g._parser.setExecuteHandler(o.C0.CR,(function(){return g.carriageReturn()})),g._parser.setExecuteHandler(o.C0.BS,(function(){return g.backspace()})),g._parser.setExecuteHandler(o.C0.HT,(function(){return g.tab()})),g._parser.setExecuteHandler(o.C0.SO,(function(){return g.shiftOut()})),g._parser.setExecuteHandler(o.C0.SI,(function(){return g.shiftIn()})),g._parser.setExecuteHandler(o.C1.IND,(function(){return g.index()})),g._parser.setExecuteHandler(o.C1.NEL,(function(){return g.nextLine()})),g._parser.setExecuteHandler(o.C1.HTS,(function(){return g.tabSet()})),g._parser.registerOscHandler(0,new C.OscHandler((function(e){return g.setTitle(e),g.setIconName(e),!0}))),g._parser.registerOscHandler(1,new C.OscHandler((function(e){return g.setIconName(e)}))),g._parser.registerOscHandler(2,new C.OscHandler((function(e){return g.setTitle(e)}))),g._parser.registerOscHandler(4,new C.OscHandler((function(e){return g.setOrReportIndexedColor(e)}))),g._parser.registerOscHandler(8,new C.OscHandler((function(e){return g.setHyperlink(e)}))),g._parser.registerOscHandler(10,new C.OscHandler((function(e){return g.setOrReportFgColor(e)}))),g._parser.registerOscHandler(11,new C.OscHandler((function(e){return g.setOrReportBgColor(e)}))),g._parser.registerOscHandler(12,new C.OscHandler((function(e){return g.setOrReportCursorColor(e)}))),g._parser.registerOscHandler(104,new C.OscHandler((function(e){return g.restoreIndexedColor(e)}))),g._parser.registerOscHandler(110,new C.OscHandler((function(e){return g.restoreFgColor(e)}))),g._parser.registerOscHandler(111,new C.OscHandler((function(e){return g.restoreBgColor(e)}))),g._parser.registerOscHandler(112,new C.OscHandler((function(e){return g.restoreCursorColor(e)}))),g._parser.registerEscHandler({final:"7"},(function(){return g.saveCursor()})),g._parser.registerEscHandler({final:"8"},(function(){return g.restoreCursor()})),g._parser.registerEscHandler({final:"D"},(function(){return g.index()})),g._parser.registerEscHandler({final:"E"},(function(){return g.nextLine()})),g._parser.registerEscHandler({final:"H"},(function(){return g.tabSet()})),g._parser.registerEscHandler({final:"M"},(function(){return g.reverseIndex()})),g._parser.registerEscHandler({final:"="},(function(){return g.keypadApplicationMode()})),g._parser.registerEscHandler({final:">"},(function(){return g.keypadNumericMode()})),g._parser.registerEscHandler({final:"c"},(function(){return g.fullReset()})),g._parser.registerEscHandler({final:"n"},(function(){return g.setgLevel(2)})),g._parser.registerEscHandler({final:"o"},(function(){return g.setgLevel(3)})),g._parser.registerEscHandler({final:"|"},(function(){return g.setgLevel(3)})),g._parser.registerEscHandler({final:"}"},(function(){return g.setgLevel(2)})),g._parser.registerEscHandler({final:"~"},(function(){return g.setgLevel(1)})),g._parser.registerEscHandler({intermediates:"%",final:"@"},(function(){return g.selectDefaultCharset()})),g._parser.registerEscHandler({intermediates:"%",final:"G"},(function(){return g.selectDefaultCharset()}));var b=function(e){g._parser.registerEscHandler({intermediates:"(",final:e},(function(){return g.selectCharset("("+e)})),g._parser.registerEscHandler({intermediates:")",final:e},(function(){return g.selectCharset(")"+e)})),g._parser.registerEscHandler({intermediates:"*",final:e},(function(){return g.selectCharset("*"+e)})),g._parser.registerEscHandler({intermediates:"+",final:e},(function(){return g.selectCharset("+"+e)})),g._parser.registerEscHandler({intermediates:"-",final:e},(function(){return g.selectCharset("-"+e)})),g._parser.registerEscHandler({intermediates:".",final:e},(function(){return g.selectCharset("."+e)})),g._parser.registerEscHandler({intermediates:"/",final:e},(function(){return g.selectCharset("/"+e)}))};for(var w in a.CHARSETS)b(w);return g._parser.registerEscHandler({intermediates:"#",final:"8"},(function(){return g.screenAlignmentPattern()})),g._parser.setErrorHandler((function(e){return g._logService.error("Parsing error: ",e),e})),g._parser.registerDcsHandler({intermediates:"$",final:"q"},new S.DcsHandler((function(e,t){return g.requestStatusString(e,t)}))),g}return f(i,[{key:"getAttrData",value:function(){return this._curAttrData}},{key:"_preserveStack",value:function(e,t,i,r){this._parseStack.paused=!0,this._parseStack.cursorStartX=e,this._parseStack.cursorStartY=t,this._parseStack.decodedLength=i,this._parseStack.position=r}},{key:"_logSlowResolvingAsync",value:function(e){this._logService.logLevel<=b.LogLevelEnum.WARN&&Promise.race([e,new Promise((function(e,t){return setTimeout((function(){return t("#SLOW_TIMEOUT")}),5e3)}))]).catch((function(e){if("#SLOW_TIMEOUT"!==e)throw e;console.warn("async parser handler taking longer than 5000 ms")}))}},{key:"_getCurrentLinkId",value:function(){return this._curAttrData.extended.urlId}},{key:"parse",value:function(e,t){var i,r=this._activeBuffer.x,n=this._activeBuffer.y,s=0,o=this._parseStack.paused;if(o){if(i=this._parser.parse(this._parseBuffer,this._parseStack.decodedLength,t))return this._logSlowResolvingAsync(i),i;r=this._parseStack.cursorStartX,n=this._parseStack.cursorStartY,this._parseStack.paused=!1,e.length>x&&(s=this._parseStack.position+x)}if(this._logService.logLevel<=b.LogLevelEnum.DEBUG&&this._logService.debug("parsing data"+' "'.concat("string"==typeof e?e:Array.prototype.map.call(e,(function(e){return String.fromCharCode(e)})).join(""),'"'),"string"==typeof e?e.split("").map((function(e){return e.charCodeAt(0)})):e),this._parseBuffer.length<e.length&&this._parseBuffer.length<x&&(this._parseBuffer=new Uint32Array(Math.min(e.length,x))),o||this._dirtyRowTracker.clearRange(),e.length>x)for(var a=s;a<e.length;a+=x){var c=a+x<e.length?a+x:e.length,l="string"==typeof e?this._stringDecoder.decode(e.substring(a,c),this._parseBuffer):this._utf8Decoder.decode(e.subarray(a,c),this._parseBuffer);if(i=this._parser.parse(this._parseBuffer,l))return this._preserveStack(r,n,l,a),this._logSlowResolvingAsync(i),i}else if(!o){var u="string"==typeof e?this._stringDecoder.decode(e,this._parseBuffer):this._utf8Decoder.decode(e,this._parseBuffer);if(i=this._parser.parse(this._parseBuffer,u))return this._preserveStack(r,n,u,0),this._logSlowResolvingAsync(i),i}this._activeBuffer.x===r&&this._activeBuffer.y===n||this._onCursorMove.fire(),this._onRequestRefreshRows.fire(this._dirtyRowTracker.start,this._dirtyRowTracker.end)}},{key:"print",value:function(e,t,i){var r,n,s=this._charsetService.charset,o=this._optionsService.rawOptions.screenReaderMode,a=this._bufferService.cols,c=this._coreService.decPrivateModes.wraparound,l=this._coreService.modes.insertMode,h=this._curAttrData,f=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._activeBuffer.x&&i-t>0&&2===f.getWidth(this._activeBuffer.x-1)&&f.setCellFromCodePoint(this._activeBuffer.x-1,0,1,h.fg,h.bg,h.extended);for(var d=t;d<i;++d){if(r=e[d],n=this._unicodeService.wcwidth(r),r<127&&s){var v=s[String.fromCharCode(r)];v&&(r=v.charCodeAt(0))}if(o&&this._onA11yChar.fire((0,u.stringFromCodePoint)(r)),this._getCurrentLinkId()&&this._oscLinkService.addLineToLink(this._getCurrentLinkId(),this._activeBuffer.ybase+this._activeBuffer.y),n||!this._activeBuffer.x){if(this._activeBuffer.x+n-1>=a)if(c){for(;this._activeBuffer.x<a;)f.setCellFromCodePoint(this._activeBuffer.x++,0,1,h.fg,h.bg,h.extended);this._activeBuffer.x=0,this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData(),!0)):(this._activeBuffer.y>=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!0),f=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y)}else if(this._activeBuffer.x=a-1,2===n)continue;if(l&&(f.insertCells(this._activeBuffer.x,n,this._activeBuffer.getNullCell(h),h),2===f.getWidth(a-1)&&f.setCellFromCodePoint(a-1,g.NULL_CELL_CODE,g.NULL_CELL_WIDTH,h.fg,h.bg,h.extended)),f.setCellFromCodePoint(this._activeBuffer.x++,r,n,h.fg,h.bg,h.extended),n>0)for(;--n;)f.setCellFromCodePoint(this._activeBuffer.x++,0,0,h.fg,h.bg,h.extended)}else f.getWidth(this._activeBuffer.x-1)?f.addCodepointToCell(this._activeBuffer.x-1,r):f.addCodepointToCell(this._activeBuffer.x-2,r)}i-t>0&&(f.loadCell(this._activeBuffer.x-1,this._workCell),2===this._workCell.getWidth()||this._workCell.getCode()>65535?this._parser.precedingCodepoint=0:this._workCell.isCombined()?this._parser.precedingCodepoint=this._workCell.getChars().charCodeAt(0):this._parser.precedingCodepoint=this._workCell.content),this._activeBuffer.x<a&&i-t>0&&0===f.getWidth(this._activeBuffer.x)&&!f.hasContent(this._activeBuffer.x)&&f.setCellFromCodePoint(this._activeBuffer.x,0,1,h.fg,h.bg,h.extended),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}},{key:"registerCsiHandler",value:function(e,t){var i=this;return"t"!==e.final||e.prefix||e.intermediates?this._parser.registerCsiHandler(e,t):this._parser.registerCsiHandler(e,(function(e){return!L(e.params[0],i._optionsService.rawOptions.windowOptions)||t(e)}))}},{key:"registerDcsHandler",value:function(e,t){return this._parser.registerDcsHandler(e,new S.DcsHandler(t))}},{key:"registerEscHandler",value:function(e,t){return this._parser.registerEscHandler(e,t)}},{key:"registerOscHandler",value:function(e,t){return this._parser.registerOscHandler(e,new C.OscHandler(t))}},{key:"bell",value:function(){return this._onRequestBell.fire(),!0}},{key:"lineFeed",value:function(){return this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._optionsService.rawOptions.convertEol&&(this._activeBuffer.x=0),this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData())):this._activeBuffer.y>=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._activeBuffer.x>=this._bufferService.cols&&this._activeBuffer.x--,this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._onLineFeed.fire(),!0}},{key:"carriageReturn",value:function(){return this._activeBuffer.x=0,!0}},{key:"backspace",value:function(){var e;if(!this._coreService.decPrivateModes.reverseWraparound)return this._restrictCursor(),this._activeBuffer.x>0&&this._activeBuffer.x--,!0;if(this._restrictCursor(this._bufferService.cols),this._activeBuffer.x>0)this._activeBuffer.x--;else if(0===this._activeBuffer.x&&this._activeBuffer.y>this._activeBuffer.scrollTop&&this._activeBuffer.y<=this._activeBuffer.scrollBottom&&(null===(e=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y))||void 0===e?void 0:e.isWrapped)){this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!1,this._activeBuffer.y--,this._activeBuffer.x=this._bufferService.cols-1;var t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);t.hasWidth(this._activeBuffer.x)&&!t.hasContent(this._activeBuffer.x)&&this._activeBuffer.x--}return this._restrictCursor(),!0}},{key:"tab",value:function(){if(this._activeBuffer.x>=this._bufferService.cols)return!0;var e=this._activeBuffer.x;return this._activeBuffer.x=this._activeBuffer.nextStop(),this._optionsService.rawOptions.screenReaderMode&&this._onA11yTab.fire(this._activeBuffer.x-e),!0}},{key:"shiftOut",value:function(){return this._charsetService.setgLevel(1),!0}},{key:"shiftIn",value:function(){return this._charsetService.setgLevel(0),!0}},{key:"_restrictCursor",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._bufferService.cols-1;this._activeBuffer.x=Math.min(e,Math.max(0,this._activeBuffer.x)),this._activeBuffer.y=this._coreService.decPrivateModes.origin?Math.min(this._activeBuffer.scrollBottom,Math.max(this._activeBuffer.scrollTop,this._activeBuffer.y)):Math.min(this._bufferService.rows-1,Math.max(0,this._activeBuffer.y)),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}},{key:"_setCursor",value:function(e,t){this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._coreService.decPrivateModes.origin?(this._activeBuffer.x=e,this._activeBuffer.y=this._activeBuffer.scrollTop+t):(this._activeBuffer.x=e,this._activeBuffer.y=t),this._restrictCursor(),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}},{key:"_moveCursor",value:function(e,t){this._restrictCursor(),this._setCursor(this._activeBuffer.x+e,this._activeBuffer.y+t)}},{key:"cursorUp",value:function(e){var t=this._activeBuffer.y-this._activeBuffer.scrollTop;return t>=0?this._moveCursor(0,-Math.min(t,e.params[0]||1)):this._moveCursor(0,-(e.params[0]||1)),!0}},{key:"cursorDown",value:function(e){var t=this._activeBuffer.scrollBottom-this._activeBuffer.y;return t>=0?this._moveCursor(0,Math.min(t,e.params[0]||1)):this._moveCursor(0,e.params[0]||1),!0}},{key:"cursorForward",value:function(e){return this._moveCursor(e.params[0]||1,0),!0}},{key:"cursorBackward",value:function(e){return this._moveCursor(-(e.params[0]||1),0),!0}},{key:"cursorNextLine",value:function(e){return this.cursorDown(e),this._activeBuffer.x=0,!0}},{key:"cursorPrecedingLine",value:function(e){return this.cursorUp(e),this._activeBuffer.x=0,!0}},{key:"cursorCharAbsolute",value:function(e){return this._setCursor((e.params[0]||1)-1,this._activeBuffer.y),!0}},{key:"cursorPosition",value:function(e){return this._setCursor(e.length>=2?(e.params[1]||1)-1:0,(e.params[0]||1)-1),!0}},{key:"charPosAbsolute",value:function(e){return this._setCursor((e.params[0]||1)-1,this._activeBuffer.y),!0}},{key:"hPositionRelative",value:function(e){return this._moveCursor(e.params[0]||1,0),!0}},{key:"linePosAbsolute",value:function(e){return this._setCursor(this._activeBuffer.x,(e.params[0]||1)-1),!0}},{key:"vPositionRelative",value:function(e){return this._moveCursor(0,e.params[0]||1),!0}},{key:"hVPosition",value:function(e){return this.cursorPosition(e),!0}},{key:"tabClear",value:function(e){var t=e.params[0];return 0===t?delete this._activeBuffer.tabs[this._activeBuffer.x]:3===t&&(this._activeBuffer.tabs={}),!0}},{key:"cursorForwardTab",value:function(e){if(this._activeBuffer.x>=this._bufferService.cols)return!0;for(var t=e.params[0]||1;t--;)this._activeBuffer.x=this._activeBuffer.nextStop();return!0}},{key:"cursorBackwardTab",value:function(e){if(this._activeBuffer.x>=this._bufferService.cols)return!0;for(var t=e.params[0]||1;t--;)this._activeBuffer.x=this._activeBuffer.prevStop();return!0}},{key:"selectProtected",value:function(e){var t=e.params[0];return 1===t&&(this._curAttrData.bg|=536870912),2!==t&&0!==t||(this._curAttrData.bg&=-536870913),!0}},{key:"_eraseInBufferLine",value:function(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],n=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s=this._activeBuffer.lines.get(this._activeBuffer.ybase+e);s.replaceCells(t,i,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData(),n),r&&(s.isWrapped=!1)}},{key:"_resetBufferLine",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=this._activeBuffer.lines.get(this._activeBuffer.ybase+e);i.fill(this._activeBuffer.getNullCell(this._eraseAttrData()),t),this._bufferService.buffer.clearMarkers(this._activeBuffer.ybase+e),i.isWrapped=!1}},{key:"eraseInDisplay",value:function(e){var t,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1];switch(this._restrictCursor(this._bufferService.cols),e.params[0]){case 0:for(t=this._activeBuffer.y,this._dirtyRowTracker.markDirty(t),this._eraseInBufferLine(t++,this._activeBuffer.x,this._bufferService.cols,0===this._activeBuffer.x,i);t<this._bufferService.rows;t++)this._resetBufferLine(t,i);this._dirtyRowTracker.markDirty(t);break;case 1:for(t=this._activeBuffer.y,this._dirtyRowTracker.markDirty(t),this._eraseInBufferLine(t,0,this._activeBuffer.x+1,!0,i),this._activeBuffer.x+1>=this._bufferService.cols&&(this._activeBuffer.lines.get(t+1).isWrapped=!1);t--;)this._resetBufferLine(t,i);this._dirtyRowTracker.markDirty(0);break;case 2:for(t=this._bufferService.rows,this._dirtyRowTracker.markDirty(t-1);t--;)this._resetBufferLine(t,i);this._dirtyRowTracker.markDirty(0);break;case 3:var r=this._activeBuffer.lines.length-this._bufferService.rows;r>0&&(this._activeBuffer.lines.trimStart(r),this._activeBuffer.ybase=Math.max(this._activeBuffer.ybase-r,0),this._activeBuffer.ydisp=Math.max(this._activeBuffer.ydisp-r,0),this._onScroll.fire(0))}return!0}},{key:"eraseInLine",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];switch(this._restrictCursor(this._bufferService.cols),e.params[0]){case 0:this._eraseInBufferLine(this._activeBuffer.y,this._activeBuffer.x,this._bufferService.cols,0===this._activeBuffer.x,t);break;case 1:this._eraseInBufferLine(this._activeBuffer.y,0,this._activeBuffer.x+1,!1,t);break;case 2:this._eraseInBufferLine(this._activeBuffer.y,0,this._bufferService.cols,!0,t)}return this._dirtyRowTracker.markDirty(this._activeBuffer.y),!0}},{key:"insertLines",value:function(e){this._restrictCursor();var t=e.params[0]||1;if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;for(var i=this._activeBuffer.ybase+this._activeBuffer.y,r=this._bufferService.rows-1-this._activeBuffer.scrollBottom,n=this._bufferService.rows-1+this._activeBuffer.ybase-r+1;t--;)this._activeBuffer.lines.splice(n-1,1),this._activeBuffer.lines.splice(i,0,this._activeBuffer.getBlankLine(this._eraseAttrData()));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.y,this._activeBuffer.scrollBottom),this._activeBuffer.x=0,!0}},{key:"deleteLines",value:function(e){this._restrictCursor();var t=e.params[0]||1;if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;var i,r=this._activeBuffer.ybase+this._activeBuffer.y;for(i=this._bufferService.rows-1-this._activeBuffer.scrollBottom,i=this._bufferService.rows-1+this._activeBuffer.ybase-i;t--;)this._activeBuffer.lines.splice(r,1),this._activeBuffer.lines.splice(i,0,this._activeBuffer.getBlankLine(this._eraseAttrData()));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.y,this._activeBuffer.scrollBottom),this._activeBuffer.x=0,!0}},{key:"insertChars",value:function(e){this._restrictCursor();var t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);return t&&(t.insertCells(this._activeBuffer.x,e.params[0]||1,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowTracker.markDirty(this._activeBuffer.y)),!0}},{key:"deleteChars",value:function(e){this._restrictCursor();var t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);return t&&(t.deleteCells(this._activeBuffer.x,e.params[0]||1,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowTracker.markDirty(this._activeBuffer.y)),!0}},{key:"scrollUp",value:function(e){for(var t=e.params[0]||1;t--;)this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollTop,1),this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollBottom,0,this._activeBuffer.getBlankLine(this._eraseAttrData()));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}},{key:"scrollDown",value:function(e){for(var t=e.params[0]||1;t--;)this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollBottom,1),this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollTop,0,this._activeBuffer.getBlankLine(d.DEFAULT_ATTR_DATA));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}},{key:"scrollLeft",value:function(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;for(var t=e.params[0]||1,i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){var r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.deleteCells(0,t,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}},{key:"scrollRight",value:function(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;for(var t=e.params[0]||1,i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){var r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.insertCells(0,t,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}},{key:"insertColumns",value:function(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;for(var t=e.params[0]||1,i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){var r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.insertCells(this._activeBuffer.x,t,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}},{key:"deleteColumns",value:function(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;for(var t=e.params[0]||1,i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){var r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.deleteCells(this._activeBuffer.x,t,this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}},{key:"eraseChars",value:function(e){this._restrictCursor();var t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);return t&&(t.replaceCells(this._activeBuffer.x,this._activeBuffer.x+(e.params[0]||1),this._activeBuffer.getNullCell(this._eraseAttrData()),this._eraseAttrData()),this._dirtyRowTracker.markDirty(this._activeBuffer.y)),!0}},{key:"repeatPrecedingCharacter",value:function(e){if(!this._parser.precedingCodepoint)return!0;for(var t=e.params[0]||1,i=new Uint32Array(t),r=0;r<t;++r)i[r]=this._parser.precedingCodepoint;return this.print(i,0,i.length),!0}},{key:"sendDeviceAttributesPrimary",value:function(e){return e.params[0]>0||(this._is("xterm")||this._is("rxvt-unicode")||this._is("screen")?this._coreService.triggerDataEvent(o.C0.ESC+"[?1;2c"):this._is("linux")&&this._coreService.triggerDataEvent(o.C0.ESC+"[?6c")),!0}},{key:"sendDeviceAttributesSecondary",value:function(e){return e.params[0]>0||(this._is("xterm")?this._coreService.triggerDataEvent(o.C0.ESC+"[>0;276;0c"):this._is("rxvt-unicode")?this._coreService.triggerDataEvent(o.C0.ESC+"[>85;95;0c"):this._is("linux")?this._coreService.triggerDataEvent(e.params[0]+"c"):this._is("screen")&&this._coreService.triggerDataEvent(o.C0.ESC+"[>83;40003;0c")),!0}},{key:"_is",value:function(e){return 0===(this._optionsService.rawOptions.termName+"").indexOf(e)}},{key:"setMode",value:function(e){for(var t=0;t<e.length;t++)switch(e.params[t]){case 4:this._coreService.modes.insertMode=!0;break;case 20:this._optionsService.options.convertEol=!0}return!0}},{key:"setModePrivate",value:function(e){for(var t=0;t<e.length;t++)switch(e.params[t]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!0;break;case 2:this._charsetService.setgCharset(0,a.DEFAULT_CHARSET),this._charsetService.setgCharset(1,a.DEFAULT_CHARSET),this._charsetService.setgCharset(2,a.DEFAULT_CHARSET),this._charsetService.setgCharset(3,a.DEFAULT_CHARSET);break;case 3:this._optionsService.rawOptions.windowOptions.setWinLines&&(this._bufferService.resize(132,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!0,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!0;break;case 12:this._optionsService.options.cursorBlink=!0;break;case 45:this._coreService.decPrivateModes.reverseWraparound=!0;break;case 66:this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire();break;case 9:this._coreMouseService.activeProtocol="X10";break;case 1e3:this._coreMouseService.activeProtocol="VT200";break;case 1002:this._coreMouseService.activeProtocol="DRAG";break;case 1003:this._coreMouseService.activeProtocol="ANY";break;case 1004:this._coreService.decPrivateModes.sendFocus=!0,this._onRequestSendFocus.fire();break;case 1005:this._logService.debug("DECSET 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="SGR";break;case 1015:this._logService.debug("DECSET 1015 not supported (see #2507)");break;case 1016:this._coreMouseService.activeEncoding="SGR_PIXELS";break;case 25:this._coreService.isCursorHidden=!1;break;case 1048:this.saveCursor();break;case 1049:this.saveCursor();case 47:case 1047:this._bufferService.buffers.activateAltBuffer(this._eraseAttrData()),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(0,this._bufferService.rows-1),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!0}return!0}},{key:"resetMode",value:function(e){for(var t=0;t<e.length;t++)switch(e.params[t]){case 4:this._coreService.modes.insertMode=!1;break;case 20:this._optionsService.options.convertEol=!1}return!0}},{key:"resetModePrivate",value:function(e){for(var t=0;t<e.length;t++)switch(e.params[t]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!1;break;case 3:this._optionsService.rawOptions.windowOptions.setWinLines&&(this._bufferService.resize(80,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!1,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!1;break;case 12:this._optionsService.options.cursorBlink=!1;break;case 45:this._coreService.decPrivateModes.reverseWraparound=!1;break;case 66:this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire();break;case 9:case 1e3:case 1002:case 1003:this._coreMouseService.activeProtocol="NONE";break;case 1004:this._coreService.decPrivateModes.sendFocus=!1;break;case 1005:this._logService.debug("DECRST 1005 not supported (see #2507)");break;case 1006:case 1016:this._coreMouseService.activeEncoding="DEFAULT";break;case 1015:this._logService.debug("DECRST 1015 not supported (see #2507)");break;case 25:this._coreService.isCursorHidden=!0;break;case 1048:this.restoreCursor();break;case 1049:case 47:case 1047:this._bufferService.buffers.activateNormalBuffer(),1049===e.params[t]&&this.restoreCursor(),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(0,this._bufferService.rows-1),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!1}return!0}},{key:"requestMode",value:function(e,t){var i,r,n=this._coreService.decPrivateModes,s=this._coreMouseService,a=s.activeProtocol,c=s.activeEncoding,l=this._coreService,u=this._bufferService,h=u.buffers,f=u.cols,d=h.active,v=h.alt,_=this._optionsService.rawOptions,p=function(e){return e?1:2},g=e.params[0];return i=g,r=t?2===g?3:4===g?p(l.modes.insertMode):12===g?4:20===g?p(_.convertEol):0:1===g?p(n.applicationCursorKeys):3===g?_.windowOptions.setWinLines?80===f?2:132===f?1:0:0:6===g?p(n.origin):7===g?p(n.wraparound):8===g?3:9===g?p("X10"===a):12===g?p(_.cursorBlink):25===g?p(!l.isCursorHidden):45===g?p(n.reverseWraparound):66===g?p(n.applicationKeypad):1e3===g?p("VT200"===a):1002===g?p("DRAG"===a):1003===g?p("ANY"===a):1004===g?p(n.sendFocus):1005===g?4:1006===g?p("SGR"===c):1015===g?4:1016===g?p("SGR_PIXELS"===c):1048===g?1:47===g||1047===g||1049===g?p(d===v):2004===g?p(n.bracketedPasteMode):0,l.triggerDataEvent("".concat(o.C0.ESC,"[").concat(t?"":"?").concat(i,";").concat(r,"$y")),!0}},{key:"_updateAttrColor",value:function(e,t,i,r,n){return 2===t?(e|=50331648,e&=-16777216,e|=y.AttributeData.fromColorRGB([i,r,n])):5===t&&(e&=-50331904,e|=33554432|255&i),e}},{key:"_extractColor",value:function(e,t,i){var r=[0,0,-1,0,0,0],n=0,s=0;do{if(r[s+n]=e.params[t+s],e.hasSubParams(t+s)){var o=e.getSubParams(t+s),a=0;do{5===r[1]&&(n=1),r[s+a+1+n]=o[a]}while(++a<o.length&&a+s+1+n<r.length);break}if(5===r[1]&&s+n>=2||2===r[1]&&s+n>=5)break;r[1]&&(n=1)}while(++s+t<e.length&&s+n<r.length);for(var c=2;c<r.length;++c)-1===r[c]&&(r[c]=0);switch(r[0]){case 38:i.fg=this._updateAttrColor(i.fg,r[1],r[3],r[4],r[5]);break;case 48:i.bg=this._updateAttrColor(i.bg,r[1],r[3],r[4],r[5]);break;case 58:i.extended=i.extended.clone(),i.extended.underlineColor=this._updateAttrColor(i.extended.underlineColor,r[1],r[3],r[4],r[5])}return s}},{key:"_processUnderline",value:function(e,t){t.extended=t.extended.clone(),(!~e||e>5)&&(e=1),t.extended.underlineStyle=e,t.fg|=268435456,0===e&&(t.fg&=-268435457),t.updateExtended()}},{key:"_processSGR0",value:function(e){e.fg=d.DEFAULT_ATTR_DATA.fg,e.bg=d.DEFAULT_ATTR_DATA.bg,e.extended=e.extended.clone(),e.extended.underlineStyle=0,e.extended.underlineColor&=-67108864,e.updateExtended()}},{key:"charAttributes",value:function(e){if(1===e.length&&0===e.params[0])return this._processSGR0(this._curAttrData),!0;for(var t,i=e.length,r=this._curAttrData,n=0;n<i;n++)(t=e.params[n])>=30&&t<=37?(r.fg&=-50331904,r.fg|=16777216|t-30):t>=40&&t<=47?(r.bg&=-50331904,r.bg|=16777216|t-40):t>=90&&t<=97?(r.fg&=-50331904,r.fg|=16777224|t-90):t>=100&&t<=107?(r.bg&=-50331904,r.bg|=16777224|t-100):0===t?this._processSGR0(r):1===t?r.fg|=134217728:3===t?r.bg|=67108864:4===t?(r.fg|=268435456,this._processUnderline(e.hasSubParams(n)?e.getSubParams(n)[0]:1,r)):5===t?r.fg|=536870912:7===t?r.fg|=67108864:8===t?r.fg|=1073741824:9===t?r.fg|=2147483648:2===t?r.bg|=134217728:21===t?this._processUnderline(2,r):22===t?(r.fg&=-134217729,r.bg&=-134217729):23===t?r.bg&=-67108865:24===t?(r.fg&=-268435457,this._processUnderline(0,r)):25===t?r.fg&=-536870913:27===t?r.fg&=-67108865:28===t?r.fg&=-1073741825:29===t?r.fg&=2147483647:39===t?(r.fg&=-67108864,r.fg|=16777215&d.DEFAULT_ATTR_DATA.fg):49===t?(r.bg&=-67108864,r.bg|=16777215&d.DEFAULT_ATTR_DATA.bg):38===t||48===t||58===t?n+=this._extractColor(e,n,r):59===t?(r.extended=r.extended.clone(),r.extended.underlineColor=-1,r.updateExtended()):100===t?(r.fg&=-67108864,r.fg|=16777215&d.DEFAULT_ATTR_DATA.fg,r.bg&=-67108864,r.bg|=16777215&d.DEFAULT_ATTR_DATA.bg):this._logService.debug("Unknown SGR attribute: %d.",t);return!0}},{key:"deviceStatus",value:function(e){switch(e.params[0]){case 5:this._coreService.triggerDataEvent("".concat(o.C0.ESC,"[0n"));break;case 6:var t=this._activeBuffer.y+1,i=this._activeBuffer.x+1;this._coreService.triggerDataEvent("".concat(o.C0.ESC,"[").concat(t,";").concat(i,"R"))}return!0}},{key:"deviceStatusPrivate",value:function(e){if(6===e.params[0]){var t=this._activeBuffer.y+1,i=this._activeBuffer.x+1;this._coreService.triggerDataEvent("".concat(o.C0.ESC,"[?").concat(t,";").concat(i,"R"))}return!0}},{key:"softReset",value:function(e){return this._coreService.isCursorHidden=!1,this._onRequestSyncScrollBar.fire(),this._activeBuffer.scrollTop=0,this._activeBuffer.scrollBottom=this._bufferService.rows-1,this._curAttrData=d.DEFAULT_ATTR_DATA.clone(),this._coreService.reset(),this._charsetService.reset(),this._activeBuffer.savedX=0,this._activeBuffer.savedY=this._activeBuffer.ybase,this._activeBuffer.savedCurAttrData.fg=this._curAttrData.fg,this._activeBuffer.savedCurAttrData.bg=this._curAttrData.bg,this._activeBuffer.savedCharset=this._charsetService.charset,this._coreService.decPrivateModes.origin=!1,!0}},{key:"setCursorStyle",value:function(e){var t=e.params[0]||1;switch(t){case 1:case 2:this._optionsService.options.cursorStyle="block";break;case 3:case 4:this._optionsService.options.cursorStyle="underline";break;case 5:case 6:this._optionsService.options.cursorStyle="bar"}var i=t%2==1;return this._optionsService.options.cursorBlink=i,!0}},{key:"setScrollRegion",value:function(e){var t,i=e.params[0]||1;return(e.length<2||(t=e.params[1])>this._bufferService.rows||0===t)&&(t=this._bufferService.rows),t>i&&(this._activeBuffer.scrollTop=i-1,this._activeBuffer.scrollBottom=t-1,this._setCursor(0,0)),!0}},{key:"windowOptions",value:function(e){if(!L(e.params[0],this._optionsService.rawOptions.windowOptions))return!0;var t=e.length>1?e.params[1]:0;switch(e.params[0]){case 14:2!==t&&this._onRequestWindowsOptionsReport.fire(s.GET_WIN_SIZE_PIXELS);break;case 16:this._onRequestWindowsOptionsReport.fire(s.GET_CELL_SIZE_PIXELS);break;case 18:this._bufferService&&this._coreService.triggerDataEvent("".concat(o.C0.ESC,"[8;").concat(this._bufferService.rows,";").concat(this._bufferService.cols,"t"));break;case 22:0!==t&&2!==t||(this._windowTitleStack.push(this._windowTitle),this._windowTitleStack.length>10&&this._windowTitleStack.shift()),0!==t&&1!==t||(this._iconNameStack.push(this._iconName),this._iconNameStack.length>10&&this._iconNameStack.shift());break;case 23:0!==t&&2!==t||this._windowTitleStack.length&&this.setTitle(this._windowTitleStack.pop()),0!==t&&1!==t||this._iconNameStack.length&&this.setIconName(this._iconNameStack.pop())}return!0}},{key:"saveCursor",value:function(e){return this._activeBuffer.savedX=this._activeBuffer.x,this._activeBuffer.savedY=this._activeBuffer.ybase+this._activeBuffer.y,this._activeBuffer.savedCurAttrData.fg=this._curAttrData.fg,this._activeBuffer.savedCurAttrData.bg=this._curAttrData.bg,this._activeBuffer.savedCharset=this._charsetService.charset,!0}},{key:"restoreCursor",value:function(e){return this._activeBuffer.x=this._activeBuffer.savedX||0,this._activeBuffer.y=Math.max(this._activeBuffer.savedY-this._activeBuffer.ybase,0),this._curAttrData.fg=this._activeBuffer.savedCurAttrData.fg,this._curAttrData.bg=this._activeBuffer.savedCurAttrData.bg,this._charsetService.charset=this._savedCharset,this._activeBuffer.savedCharset&&(this._charsetService.charset=this._activeBuffer.savedCharset),this._restrictCursor(),!0}},{key:"setTitle",value:function(e){return this._windowTitle=e,this._onTitleChange.fire(e),!0}},{key:"setIconName",value:function(e){return this._iconName=e,!0}},{key:"setOrReportIndexedColor",value:function(e){for(var t=[],i=e.split(";");i.length>1;){var r=i.shift(),n=i.shift();if(/^\d+$/.exec(r)){var s=parseInt(r);if(0<=s&&s<256)if("?"===n)t.push({type:0,index:s});else{var o=(0,w.parseColor)(n);o&&t.push({type:1,index:s,color:o})}}}return t.length&&this._onColor.fire(t),!0}},{key:"setHyperlink",value:function(e){var t=e.split(";");return!(t.length<2)&&(t[1]?this._createHyperlink(t[0],t[1]):!t[0]&&this._finishHyperlink())}},{key:"_createHyperlink",value:function(e,t){this._getCurrentLinkId()&&this._finishHyperlink();var i,r=e.split(":"),n=r.findIndex((function(e){return e.startsWith("id=")}));return-1!==n&&(i=r[n].slice(3)||void 0),this._curAttrData.extended=this._curAttrData.extended.clone(),this._curAttrData.extended.urlId=this._oscLinkService.registerLink({id:i,uri:t}),this._curAttrData.updateExtended(),!0}},{key:"_finishHyperlink",value:function(){return this._curAttrData.extended=this._curAttrData.extended.clone(),this._curAttrData.extended.urlId=0,this._curAttrData.updateExtended(),!0}},{key:"_setOrReportSpecialColor",value:function(e,t){for(var i=e.split(";"),r=0;r<i.length&&!(t>=this._specialColors.length);++r,++t)if("?"===i[r])this._onColor.fire([{type:0,index:this._specialColors[t]}]);else{var n=(0,w.parseColor)(i[r]);n&&this._onColor.fire([{type:1,index:this._specialColors[t],color:n}])}return!0}},{key:"setOrReportFgColor",value:function(e){return this._setOrReportSpecialColor(e,0)}},{key:"setOrReportBgColor",value:function(e){return this._setOrReportSpecialColor(e,1)}},{key:"setOrReportCursorColor",value:function(e){return this._setOrReportSpecialColor(e,2)}},{key:"restoreIndexedColor",value:function(e){if(!e)return this._onColor.fire([{type:2}]),!0;for(var t=[],i=e.split(";"),r=0;r<i.length;++r)if(/^\d+$/.exec(i[r])){var n=parseInt(i[r]);0<=n&&n<256&&t.push({type:2,index:n})}return t.length&&this._onColor.fire(t),!0}},{key:"restoreFgColor",value:function(e){return this._onColor.fire([{type:2,index:256}]),!0}},{key:"restoreBgColor",value:function(e){return this._onColor.fire([{type:2,index:257}]),!0}},{key:"restoreCursorColor",value:function(e){return this._onColor.fire([{type:2,index:258}]),!0}},{key:"nextLine",value:function(){return this._activeBuffer.x=0,this.index(),!0}},{key:"keypadApplicationMode",value:function(){return this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire(),!0}},{key:"keypadNumericMode",value:function(){return this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire(),!0}},{key:"selectDefaultCharset",value:function(){return this._charsetService.setgLevel(0),this._charsetService.setgCharset(0,a.DEFAULT_CHARSET),!0}},{key:"selectCharset",value:function(e){return 2!==e.length?(this.selectDefaultCharset(),!0):("/"===e[0]||this._charsetService.setgCharset(k[e[0]],a.CHARSETS[e[1]]||a.DEFAULT_CHARSET),!0)}},{key:"index",value:function(){return this._restrictCursor(),this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData())):this._activeBuffer.y>=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._restrictCursor(),!0}},{key:"tabSet",value:function(){return this._activeBuffer.tabs[this._activeBuffer.x]=!0,!0}},{key:"reverseIndex",value:function(){if(this._restrictCursor(),this._activeBuffer.y===this._activeBuffer.scrollTop){var e=this._activeBuffer.scrollBottom-this._activeBuffer.scrollTop;this._activeBuffer.lines.shiftElements(this._activeBuffer.ybase+this._activeBuffer.y,e,1),this._activeBuffer.lines.set(this._activeBuffer.ybase+this._activeBuffer.y,this._activeBuffer.getBlankLine(this._eraseAttrData())),this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom)}else this._activeBuffer.y--,this._restrictCursor();return!0}},{key:"fullReset",value:function(){return this._parser.reset(),this._onRequestReset.fire(),!0}},{key:"reset",value:function(){this._curAttrData=d.DEFAULT_ATTR_DATA.clone(),this._eraseAttrDataInternal=d.DEFAULT_ATTR_DATA.clone()}},{key:"_eraseAttrData",value:function(){return this._eraseAttrDataInternal.bg&=-67108864,this._eraseAttrDataInternal.bg|=67108863&this._curAttrData.bg,this._eraseAttrDataInternal}},{key:"setgLevel",value:function(e){return this._charsetService.setgLevel(e),!0}},{key:"screenAlignmentPattern",value:function(){var e=new m.CellData;e.content=1<<22|"E".charCodeAt(0),e.fg=this._curAttrData.fg,e.bg=this._curAttrData.bg,this._setCursor(0,0);for(var t=0;t<this._bufferService.rows;++t){var i=this._activeBuffer.ybase+this._activeBuffer.y+t,r=this._activeBuffer.lines.get(i);r&&(r.fill(e),r.isWrapped=!1)}return this._dirtyRowTracker.markAllDirty(),this._setCursor(0,0),!0}},{key:"requestStatusString",value:function(e,t){var i=this,r=this._bufferService.buffer,n=this._optionsService.rawOptions;return function(e){return i._coreService.triggerDataEvent("".concat(o.C0.ESC).concat(e).concat(o.C0.ESC,"\\")),!0}('"q'===e?"P1$r".concat(this._curAttrData.isProtected()?1:0,'"q'):'"p'===e?'P1$r61;1"p':"r"===e?"P1$r".concat(r.scrollTop+1,";").concat(r.scrollBottom+1,"r"):"m"===e?"P1$r0m":" q"===e?"P1$r".concat({block:2,underline:4,bar:6}[n.cursorStyle]-(n.cursorBlink?1:0)," q"):"P0$r")}},{key:"markRangeDirty",value:function(e,t){this._dirtyRowTracker.markRangeDirty(e,t)}}]),i}(l.Disposable);t.InputHandler=R;var M=function(){function e(t){h(this,e),this._bufferService=t,this.clearRange()}return f(e,[{key:"clearRange",value:function(){this.start=this._bufferService.buffer.y,this.end=this._bufferService.buffer.y}},{key:"markDirty",value:function(e){e<this.start?this.start=e:e>this.end&&(this.end=e)}},{key:"markRangeDirty",value:function(e,t){e>t&&(E=e,e=t,t=E),e<this.start&&(this.start=e),t>this.end&&(this.end=t)}},{key:"markAllDirty",value:function(){this.markRangeDirty(0,this._bufferService.rows-1)}}]),e}();M=r([n(0,b.IBufferService)],M)},844:function(e,t){function i(e){var t,i=u(e);try{for(i.s();!(t=i.n()).done;)t.value.dispose()}catch(r){i.e(r)}finally{i.f()}e.length=0}Object.defineProperty(t,"__esModule",{value:!0}),t.getDisposeArrayDisposable=t.disposeArray=t.toDisposable=t.Disposable=void 0,t.Disposable=function(){function e(){h(this,e),this._disposables=[],this._isDisposed=!1}return f(e,[{key:"dispose",value:function(){this._isDisposed=!0;var e,t=u(this._disposables);try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(i){t.e(i)}finally{t.f()}this._disposables.length=0}},{key:"register",value:function(e){return this._disposables.push(e),e}},{key:"unregister",value:function(e){var t=this._disposables.indexOf(e);-1!==t&&this._disposables.splice(t,1)}}]),e}(),t.toDisposable=function(e){return{dispose:e}},t.disposeArray=i,t.getDisposeArrayDisposable=function(e){return{dispose:function(){return i(e)}}}},1505:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.FourKeyMap=t.TwoKeyMap=void 0;var i=function(){function e(){h(this,e),this._data={}}return f(e,[{key:"set",value:function(e,t,i){this._data[e]||(this._data[e]={}),this._data[e][t]=i}},{key:"get",value:function(e,t){return this._data[e]?this._data[e][t]:void 0}},{key:"clear",value:function(){this._data={}}}]),e}();t.TwoKeyMap=i,t.FourKeyMap=function(){function e(){h(this,e),this._data=new i}return f(e,[{key:"set",value:function(e,t,r,n,s){this._data.get(e,t)||this._data.set(e,t,new i),this._data.get(e,t).set(r,n,s)}},{key:"get",value:function(e,t,i,r){var n;return null===(n=this._data.get(e,t))||void 0===n?void 0:n.get(i,r)}},{key:"clear",value:function(){this._data.clear()}}]),e}()},6114:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.isChromeOS=t.isLinux=t.isWindows=t.isIphone=t.isIpad=t.isMac=t.getSafariVersion=t.isSafari=t.isLegacyEdge=t.isFirefox=t.isNode=void 0,t.isNode="undefined"==typeof navigator;var i=t.isNode?"node":navigator.userAgent,r=t.isNode?"node":navigator.platform;t.isFirefox=i.includes("Firefox"),t.isLegacyEdge=i.includes("Edge"),t.isSafari=/^((?!chrome|android).)*safari/i.test(i),t.getSafariVersion=function(){if(!t.isSafari)return 0;var e=i.match(/Version\/(\d+)/);return null===e||e.length<2?0:parseInt(e[1])},t.isMac=["Macintosh","MacIntel","MacPPC","Mac68K"].includes(r),t.isIpad="iPad"===r,t.isIphone="iPhone"===r,t.isWindows=["Windows","Win16","Win32","WinCE"].includes(r),t.isLinux=r.indexOf("Linux")>=0,t.isChromeOS=/\bCrOS\b/.test(i)},6106:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.SortedList=void 0;var i=0;t.SortedList=function(){function e(t){h(this,e),this._getKey=t,this._array=[]}return f(e,[{key:"clear",value:function(){this._array.length=0}},{key:"insert",value:function(e){0!==this._array.length?(i=this._search(this._getKey(e),0,this._array.length-1),this._array.splice(i,0,e)):this._array.push(e)}},{key:"delete",value:function(e){if(0===this._array.length)return!1;var t=this._getKey(e);if(void 0===t)return!1;if(-1===(i=this._search(t,0,this._array.length-1)))return!1;if(this._getKey(this._array[i])!==t)return!1;do{if(this._array[i]===e)return this._array.splice(i,1),!0}while(++i<this._array.length&&this._getKey(this._array[i])===t);return!1}},{key:"getKeyIterator",value:n().mark((function e(t){return n().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(0===this._array.length||(i=this._search(t,0,this._array.length-1))<0||i>=this._array.length||this._getKey(this._array[i])!==t){e.next=4;break}case 1:return e.next=3,this._array[i];case 3:if(++i<this._array.length&&this._getKey(this._array[i])===t){e.next=1;break}case 4:case"end":return e.stop()}}),e,this)}))},{key:"forEachByKey",value:function(e,t){if(0!==this._array.length&&!((i=this._search(e,0,this._array.length-1))<0||i>=this._array.length)&&this._getKey(this._array[i])===e)do{t(this._array[i])}while(++i<this._array.length&&this._getKey(this._array[i])===e)}},{key:"values",value:function(){return this._array.values()}},{key:"_search",value:function(e,t,i){if(i<t)return t;var r=Math.floor((t+i)/2),n=this._getKey(this._array[r]);if(n>e)return this._search(e,t,r-1);if(n<e)return this._search(e,r+1,i);for(;r>0&&this._getKey(this._array[r-1])===e;)r--;return r}}]),e}()},7226:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.DebouncedIdleTask=t.IdleTaskQueue=t.PriorityTaskQueue=void 0;var r=i(6114),n=function(){function e(){h(this,e),this._tasks=[],this._i=0}return f(e,[{key:"enqueue",value:function(e){this._tasks.push(e),this._start()}},{key:"flush",value:function(){for(;this._i<this._tasks.length;)this._tasks[this._i]()||this._i++;this.clear()}},{key:"clear",value:function(){this._idleCallback&&(this._cancelCallback(this._idleCallback),this._idleCallback=void 0),this._i=0,this._tasks.length=0}},{key:"_start",value:function(){this._idleCallback||(this._idleCallback=this._requestCallback(this._process.bind(this)))}},{key:"_process",value:function(e){this._idleCallback=void 0;for(var t=0,i=0,r=e.timeRemaining(),n=0;this._i<this._tasks.length;){if(t=Date.now(),this._tasks[this._i]()||this._i++,t=Math.max(1,Date.now()-t),1.5*(i=Math.max(t,i))>(n=e.timeRemaining()))return r-t<-20&&console.warn("task queue exceeded allotted deadline by ".concat(Math.abs(Math.round(r-t)),"ms")),void this._start();r=n}this.clear()}}]),e}(),s=function(e){v(i,e);var t=_(i);function i(){return h(this,i),t.apply(this,arguments)}return f(i,[{key:"_requestCallback",value:function(e){var t=this;return setTimeout((function(){return e(t._createDeadline(16))}))}},{key:"_cancelCallback",value:function(e){clearTimeout(e)}},{key:"_createDeadline",value:function(e){var t=Date.now()+e;return{timeRemaining:function(){return Math.max(0,t-Date.now())}}}}]),i}(n);t.PriorityTaskQueue=s,t.IdleTaskQueue=!r.isNode&&"requestIdleCallback"in window?function(e){v(i,e);var t=_(i);function i(){return h(this,i),t.apply(this,arguments)}return f(i,[{key:"_requestCallback",value:function(e){return requestIdleCallback(e)}},{key:"_cancelCallback",value:function(e){cancelIdleCallback(e)}}]),i}(n):s,t.DebouncedIdleTask=function(){function e(){h(this,e),this._queue=new t.IdleTaskQueue}return f(e,[{key:"set",value:function(e){this._queue.clear(),this._queue.enqueue(e)}},{key:"flush",value:function(){this._queue.flush()}}]),e}()},9282:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.updateWindowsModeWrappedState=void 0;var r=i(643);t.updateWindowsModeWrappedState=function(e){var t=e.buffer.lines.get(e.buffer.ybase+e.buffer.y-1),i=null==t?void 0:t.get(e.cols-1),n=e.buffer.lines.get(e.buffer.ybase+e.buffer.y);n&&i&&(n.isWrapped=i[r.CHAR_DATA_CODE_INDEX]!==r.NULL_CELL_CODE&&i[r.CHAR_DATA_CODE_INDEX]!==r.WHITESPACE_CELL_CODE)}},3734:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.ExtendedAttrs=t.AttributeData=void 0;var i=function(){function e(){h(this,e),this.fg=0,this.bg=0,this.extended=new r}return f(e,[{key:"clone",value:function(){var t=new e;return t.fg=this.fg,t.bg=this.bg,t.extended=this.extended.clone(),t}},{key:"isInverse",value:function(){return 67108864&this.fg}},{key:"isBold",value:function(){return 134217728&this.fg}},{key:"isUnderline",value:function(){return this.hasExtendedAttrs()&&0!==this.extended.underlineStyle?1:268435456&this.fg}},{key:"isBlink",value:function(){return 536870912&this.fg}},{key:"isInvisible",value:function(){return 1073741824&this.fg}},{key:"isItalic",value:function(){return 67108864&this.bg}},{key:"isDim",value:function(){return 134217728&this.bg}},{key:"isStrikethrough",value:function(){return 2147483648&this.fg}},{key:"isProtected",value:function(){return 536870912&this.bg}},{key:"getFgColorMode",value:function(){return 50331648&this.fg}},{key:"getBgColorMode",value:function(){return 50331648&this.bg}},{key:"isFgRGB",value:function(){return 50331648==(50331648&this.fg)}},{key:"isBgRGB",value:function(){return 50331648==(50331648&this.bg)}},{key:"isFgPalette",value:function(){return 16777216==(50331648&this.fg)||33554432==(50331648&this.fg)}},{key:"isBgPalette",value:function(){return 16777216==(50331648&this.bg)||33554432==(50331648&this.bg)}},{key:"isFgDefault",value:function(){return 0==(50331648&this.fg)}},{key:"isBgDefault",value:function(){return 0==(50331648&this.bg)}},{key:"isAttributeDefault",value:function(){return 0===this.fg&&0===this.bg}},{key:"getFgColor",value:function(){switch(50331648&this.fg){case 16777216:case 33554432:return 255&this.fg;case 50331648:return 16777215&this.fg;default:return-1}}},{key:"getBgColor",value:function(){switch(50331648&this.bg){case 16777216:case 33554432:return 255&this.bg;case 50331648:return 16777215&this.bg;default:return-1}}},{key:"hasExtendedAttrs",value:function(){return 268435456&this.bg}},{key:"updateExtended",value:function(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456}},{key:"getUnderlineColor",value:function(){if(268435456&this.bg&&~this.extended.underlineColor)switch(50331648&this.extended.underlineColor){case 16777216:case 33554432:return 255&this.extended.underlineColor;case 50331648:return 16777215&this.extended.underlineColor;default:return this.getFgColor()}return this.getFgColor()}},{key:"getUnderlineColorMode",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648&this.extended.underlineColor:this.getFgColorMode()}},{key:"isUnderlineColorRGB",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?50331648==(50331648&this.extended.underlineColor):this.isFgRGB()}},{key:"isUnderlineColorPalette",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?16777216==(50331648&this.extended.underlineColor)||33554432==(50331648&this.extended.underlineColor):this.isFgPalette()}},{key:"isUnderlineColorDefault",value:function(){return 268435456&this.bg&&~this.extended.underlineColor?0==(50331648&this.extended.underlineColor):this.isFgDefault()}},{key:"getUnderlineStyle",value:function(){return 268435456&this.fg?268435456&this.bg?this.extended.underlineStyle:1:0}}],[{key:"toColorRGB",value:function(e){return[e>>>16&255,e>>>8&255,255&e]}},{key:"fromColorRGB",value:function(e){return(255&e[0])<<16|(255&e[1])<<8|255&e[2]}}]),e}();t.AttributeData=i;var r=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;h(this,e),this._ext=0,this._urlId=0,this._ext=t,this._urlId=i}return f(e,[{key:"ext",get:function(){return this._urlId?-469762049&this._ext|this.underlineStyle<<26:this._ext},set:function(e){this._ext=e}},{key:"underlineStyle",get:function(){return this._urlId?5:(469762048&this._ext)>>26},set:function(e){this._ext&=-469762049,this._ext|=e<<26&469762048}},{key:"underlineColor",get:function(){return 67108863&this._ext},set:function(e){this._ext&=-67108864,this._ext|=67108863&e}},{key:"urlId",get:function(){return this._urlId},set:function(e){this._urlId=e}},{key:"clone",value:function(){return new e(this._ext,this._urlId)}},{key:"isEmpty",value:function(){return 0===this.underlineStyle&&0===this._urlId}}]),e}();t.ExtendedAttrs=r},9092:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BufferStringIterator=t.Buffer=t.MAX_BUFFER_SIZE=void 0;var r=i(6349),n=i(8437),s=i(511),o=i(643),a=i(4634),c=i(4863),l=i(7116),u=i(3734),d=i(7226);t.MAX_BUFFER_SIZE=4294967295,t.Buffer=function(){function e(t,i,a){h(this,e),this._hasScrollback=t,this._optionsService=i,this._bufferService=a,this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.tabs={},this.savedY=0,this.savedX=0,this.savedCurAttrData=n.DEFAULT_ATTR_DATA.clone(),this.savedCharset=l.DEFAULT_CHARSET,this.markers=[],this._nullCell=s.CellData.fromCharData([0,o.NULL_CELL_CHAR,o.NULL_CELL_WIDTH,o.NULL_CELL_CODE]),this._whitespaceCell=s.CellData.fromCharData([0,o.WHITESPACE_CELL_CHAR,o.WHITESPACE_CELL_WIDTH,o.WHITESPACE_CELL_CODE]),this._isClearing=!1,this._memoryCleanupQueue=new d.IdleTaskQueue,this._memoryCleanupPosition=0,this._cols=this._bufferService.cols,this._rows=this._bufferService.rows,this.lines=new r.CircularList(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}return f(e,[{key:"getNullCell",value:function(e){return e?(this._nullCell.fg=e.fg,this._nullCell.bg=e.bg,this._nullCell.extended=e.extended):(this._nullCell.fg=0,this._nullCell.bg=0,this._nullCell.extended=new u.ExtendedAttrs),this._nullCell}},{key:"getWhitespaceCell",value:function(e){return e?(this._whitespaceCell.fg=e.fg,this._whitespaceCell.bg=e.bg,this._whitespaceCell.extended=e.extended):(this._whitespaceCell.fg=0,this._whitespaceCell.bg=0,this._whitespaceCell.extended=new u.ExtendedAttrs),this._whitespaceCell}},{key:"getBlankLine",value:function(e,t){return new n.BufferLine(this._bufferService.cols,this.getNullCell(e),t)}},{key:"hasScrollback",get:function(){return this._hasScrollback&&this.lines.maxLength>this._rows}},{key:"isCursorInViewport",get:function(){var e=this.ybase+this.y-this.ydisp;return e>=0&&e<this._rows}},{key:"_getCorrectBufferLength",value:function(e){if(!this._hasScrollback)return e;var i=e+this._optionsService.rawOptions.scrollback;return i>t.MAX_BUFFER_SIZE?t.MAX_BUFFER_SIZE:i}},{key:"fillViewportRows",value:function(e){if(0===this.lines.length){void 0===e&&(e=n.DEFAULT_ATTR_DATA);for(var t=this._rows;t--;)this.lines.push(this.getBlankLine(e))}}},{key:"clear",value: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()}},{key:"resize",value:function(e,t){var i=this,r=this.getNullCell(n.DEFAULT_ATTR_DATA),s=0,o=this._getCorrectBufferLength(t);if(o>this.lines.maxLength&&(this.lines.maxLength=o),this.lines.length>0){if(this._cols<e)for(var a=0;a<this.lines.length;a++)s+=+this.lines.get(a).resize(e,r);var c=0;if(this._rows<t)for(var l=this._rows;l<t;l++)this.lines.length<t+this.ybase&&(this._optionsService.rawOptions.windowsMode?this.lines.push(new n.BufferLine(e,r)):this.ybase>0&&this.lines.length<=this.ybase+this.y+c+1?(this.ybase--,c++,this.ydisp>0&&this.ydisp--):this.lines.push(new n.BufferLine(e,r)));else for(var u=this._rows;u>t;u--)this.lines.length>t+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));if(o<this.lines.maxLength){var h=this.lines.length-o;h>0&&(this.lines.trimStart(h),this.ybase=Math.max(this.ybase-h,0),this.ydisp=Math.max(this.ydisp-h,0),this.savedY=Math.max(this.savedY-h,0)),this.lines.maxLength=o}this.x=Math.min(this.x,e-1),this.y=Math.min(this.y,t-1),c&&(this.y+=c),this.savedX=Math.min(this.savedX,e-1),this.scrollTop=0}if(this.scrollBottom=t-1,this._isReflowEnabled&&(this._reflow(e,t),this._cols>e))for(var f=0;f<this.lines.length;f++)s+=+this.lines.get(f).resize(e,r);this._cols=e,this._rows=t,this._memoryCleanupQueue.clear(),s>.1*this.lines.length&&(this._memoryCleanupPosition=0,this._memoryCleanupQueue.enqueue((function(){return i._batchedMemoryCleanup()})))}},{key:"_batchedMemoryCleanup",value:function(){var e=!0;this._memoryCleanupPosition>=this.lines.length&&(this._memoryCleanupPosition=0,e=!1);for(var t=0;this._memoryCleanupPosition<this.lines.length;)if((t+=this.lines.get(this._memoryCleanupPosition++).cleanupMemory())>100)return!0;return e}},{key:"_isReflowEnabled",get:function(){return this._hasScrollback&&!this._optionsService.rawOptions.windowsMode}},{key:"_reflow",value:function(e,t){this._cols!==e&&(e>this._cols?this._reflowLarger(e,t):this._reflowSmaller(e,t))}},{key:"_reflowLarger",value:function(e,t){var i=(0,a.reflowLargerGetLinesToRemove)(this.lines,this._cols,e,this.ybase+this.y,this.getNullCell(n.DEFAULT_ATTR_DATA));if(i.length>0){var r=(0,a.reflowLargerCreateNewLayout)(this.lines,i);(0,a.reflowLargerApplyNewLayout)(this.lines,r.layout),this._reflowLargerAdjustViewport(e,t,r.countRemoved)}}},{key:"_reflowLargerAdjustViewport",value:function(e,t,i){for(var r=this.getNullCell(n.DEFAULT_ATTR_DATA),s=i;s-- >0;)0===this.ybase?(this.y>0&&this.y--,this.lines.length<t&&this.lines.push(new n.BufferLine(e,r))):(this.ydisp===this.ybase&&this.ydisp--,this.ybase--);this.savedY=Math.max(this.savedY-i,0)}},{key:"_reflowSmaller",value:function(e,t){for(var i=this.getNullCell(n.DEFAULT_ATTR_DATA),r=[],s=0,o=this.lines.length-1;o>=0;o--){var c=this.lines.get(o);if(!(!c||!c.isWrapped&&c.getTrimmedLength()<=e)){for(var l=[c];c.isWrapped&&o>0;)c=this.lines.get(--o),l.unshift(c);var u=this.ybase+this.y;if(!(u>=o&&u<o+l.length)){var h=l[l.length-1].getTrimmedLength(),f=(0,a.reflowSmallerGetNewLineLengths)(l,this._cols,e),d=f.length-l.length,v=void 0;v=0===this.ybase&&this.y!==this.lines.length-1?Math.max(0,this.y-this.lines.maxLength+d):Math.max(0,this.lines.length-this.lines.maxLength+d);for(var _=[],p=0;p<d;p++){var g=this.getBlankLine(n.DEFAULT_ATTR_DATA,!0);_.push(g)}_.length>0&&(r.push({start:o+l.length+s,newLines:_}),s+=_.length),l.push.apply(l,_);var m=f.length-1,y=f[m];0===y&&(y=f[--m]);for(var b=l.length-d-1,C=h;b>=0;){var S=Math.min(C,y);if(void 0===l[m])break;if(l[m].copyCellsFrom(l[b],C-S,y-S,S,!0),0===(y-=S)&&(y=f[--m]),0===(C-=S)){b--;var w=Math.max(b,0);C=(0,a.getWrappedLineTrimmedLength)(l,w,this._cols)}}for(var k=0;k<l.length;k++)f[k]<e&&l[k].setCell(f[k],i);for(var x=d-v;x-- >0;)0===this.ybase?this.y<t-1?(this.y++,this.lines.pop()):(this.ybase++,this.ydisp++):this.ybase<Math.min(this.lines.maxLength,this.lines.length+s)-t&&(this.ybase===this.ydisp&&this.ydisp++,this.ybase++);this.savedY=Math.min(this.savedY+d,this.ybase+t-1)}}}if(r.length>0){for(var L=[],E=[],R=0;R<this.lines.length;R++)E.push(this.lines.get(R));var M=this.lines.length,A=M-1,D=0,O=r[D];this.lines.length=Math.min(this.lines.maxLength,this.lines.length+s);for(var T=0,B=Math.min(this.lines.maxLength-1,M+s-1);B>=0;B--)if(O&&O.start>A+T){for(var I=O.newLines.length-1;I>=0;I--)this.lines.set(B--,O.newLines[I]);B++,L.push({index:A+1,amount:O.newLines.length}),T+=O.newLines.length,O=r[++D]}else this.lines.set(B,E[A--]);for(var P=0,F=L.length-1;F>=0;F--)L[F].index+=P,this.lines.onInsertEmitter.fire(L[F]),P+=L[F].amount;var H=Math.max(0,M+s-this.lines.maxLength);H>0&&this.lines.onTrimEmitter.fire(H)}}},{key:"stringIndexToBufferIndex",value:function(e,t){for(var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];t;){var r=this.lines.get(e);if(!r)return[-1,-1];for(var n=i?r.getTrimmedLength():r.length,s=0;s<n;++s)if(r.get(s)[o.CHAR_DATA_WIDTH_INDEX]&&(t-=r.get(s)[o.CHAR_DATA_CHAR_INDEX].length||1),t<0)return[e,s];e++}return[e,0]}},{key:"translateBufferLineToString",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=arguments.length>3?arguments[3]:void 0,n=this.lines.get(e);return n?n.translateToString(t,i,r):""}},{key:"getWrappedRangeForLine",value:function(e){for(var t=e,i=e;t>0&&this.lines.get(t).isWrapped;)t--;for(;i+1<this.lines.length&&this.lines.get(i+1).isWrapped;)i++;return{first:t,last:i}}},{key:"setupTabStops",value:function(e){for(null!=e?this.tabs[e]||(e=this.prevStop(e)):(this.tabs={},e=0);e<this._cols;e+=this._optionsService.rawOptions.tabStopWidth)this.tabs[e]=!0}},{key:"prevStop",value:function(e){for(null==e&&(e=this.x);!this.tabs[--e]&&e>0;);return e>=this._cols?this._cols-1:e<0?0:e}},{key:"nextStop",value:function(e){for(null==e&&(e=this.x);!this.tabs[++e]&&e<this._cols;);return e>=this._cols?this._cols-1:e<0?0:e}},{key:"clearMarkers",value:function(e){this._isClearing=!0;for(var t=0;t<this.markers.length;t++)this.markers[t].line===e&&(this.markers[t].dispose(),this.markers.splice(t--,1));this._isClearing=!1}},{key:"clearAllMarkers",value:function(){this._isClearing=!0;for(var e=0;e<this.markers.length;e++)this.markers[e].dispose(),this.markers.splice(e--,1);this._isClearing=!1}},{key:"addMarker",value:function(e){var t=this,i=new c.Marker(e);return this.markers.push(i),i.register(this.lines.onTrim((function(e){i.line-=e,i.line<0&&i.dispose()}))),i.register(this.lines.onInsert((function(e){i.line>=e.index&&(i.line+=e.amount)}))),i.register(this.lines.onDelete((function(e){i.line>=e.index&&i.line<e.index+e.amount&&i.dispose(),i.line>e.index&&(i.line-=e.amount)}))),i.register(i.onDispose((function(){return t._removeMarker(i)}))),i}},{key:"_removeMarker",value:function(e){this._isClearing||this.markers.splice(this.markers.indexOf(e),1)}},{key:"iterator",value:function(e,t,i,r,n){return new v(this,e,t,i,r,n)}}]),e}();var v=function(){function e(t,i){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t.lines.length,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;h(this,e),this._buffer=t,this._trimRight=i,this._startIndex=r,this._endIndex=n,this._startOverscan=s,this._endOverscan=o,this._startIndex<0&&(this._startIndex=0),this._endIndex>this._buffer.lines.length&&(this._endIndex=this._buffer.lines.length),this._current=this._startIndex}return f(e,[{key:"hasNext",value:function(){return this._current<this._endIndex}},{key:"next",value:function(){var e=this._buffer.getWrappedRangeForLine(this._current);e.first<this._startIndex-this._startOverscan&&(e.first=this._startIndex-this._startOverscan),e.last>this._endIndex+this._endOverscan&&(e.last=this._endIndex+this._endOverscan),e.first=Math.max(e.first,0),e.last=Math.min(e.last,this._buffer.lines.length);for(var t="",i=e.first;i<=e.last;++i)t+=this._buffer.translateBufferLineToString(i,this._trimRight);return this._current=e.last+1,{range:e,content:t}}}]),e}();t.BufferStringIterator=v},8437:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BufferLine=t.DEFAULT_ATTR_DATA=void 0;var r=i(482),n=i(643),s=i(511),o=i(3734);t.DEFAULT_ATTR_DATA=Object.freeze(new o.AttributeData);var a=0,c=function(){function e(t,i){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];h(this,e),this.isWrapped=r,this._combined={},this._extendedAttrs={},this._data=new Uint32Array(3*t);for(var o=i||s.CellData.fromCharData([0,n.NULL_CELL_CHAR,n.NULL_CELL_WIDTH,n.NULL_CELL_CODE]),a=0;a<t;++a)this.setCell(a,o);this.length=t}return f(e,[{key:"get",value:function(e){var t=this._data[3*e+0],i=2097151&t;return[this._data[3*e+1],2097152&t?this._combined[e]:i?(0,r.stringFromCodePoint)(i):"",t>>22,2097152&t?this._combined[e].charCodeAt(this._combined[e].length-1):i]}},{key:"set",value:function(e,t){this._data[3*e+1]=t[n.CHAR_DATA_ATTR_INDEX],t[n.CHAR_DATA_CHAR_INDEX].length>1?(this._combined[e]=t[1],this._data[3*e+0]=2097152|e|t[n.CHAR_DATA_WIDTH_INDEX]<<22):this._data[3*e+0]=t[n.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|t[n.CHAR_DATA_WIDTH_INDEX]<<22}},{key:"getWidth",value:function(e){return this._data[3*e+0]>>22}},{key:"hasWidth",value:function(e){return 12582912&this._data[3*e+0]}},{key:"getFg",value:function(e){return this._data[3*e+1]}},{key:"getBg",value:function(e){return this._data[3*e+2]}},{key:"hasContent",value:function(e){return 4194303&this._data[3*e+0]}},{key:"getCodePoint",value:function(e){var t=this._data[3*e+0];return 2097152&t?this._combined[e].charCodeAt(this._combined[e].length-1):2097151&t}},{key:"isCombined",value:function(e){return 2097152&this._data[3*e+0]}},{key:"getString",value:function(e){var t=this._data[3*e+0];return 2097152&t?this._combined[e]:2097151&t?(0,r.stringFromCodePoint)(2097151&t):""}},{key:"isProtected",value:function(e){return 536870912&this._data[3*e+2]}},{key:"loadCell",value:function(e,t){return a=3*e,t.content=this._data[a+0],t.fg=this._data[a+1],t.bg=this._data[a+2],2097152&t.content&&(t.combinedData=this._combined[e]),268435456&t.bg&&(t.extended=this._extendedAttrs[e]),t}},{key:"setCell",value:function(e,t){2097152&t.content&&(this._combined[e]=t.combinedData),268435456&t.bg&&(this._extendedAttrs[e]=t.extended),this._data[3*e+0]=t.content,this._data[3*e+1]=t.fg,this._data[3*e+2]=t.bg}},{key:"setCellFromCodePoint",value:function(e,t,i,r,n,s){268435456&n&&(this._extendedAttrs[e]=s),this._data[3*e+0]=t|i<<22,this._data[3*e+1]=r,this._data[3*e+2]=n}},{key:"addCodepointToCell",value:function(e,t){var i=this._data[3*e+0];2097152&i?this._combined[e]+=(0,r.stringFromCodePoint)(t):(2097151&i?(this._combined[e]=(0,r.stringFromCodePoint)(2097151&i)+(0,r.stringFromCodePoint)(t),i&=-2097152,i|=2097152):i=t|1<<22,this._data[3*e+0]=i)}},{key:"insertCells",value:function(e,t,i,r){if((e%=this.length)&&2===this.getWidth(e-1)&&this.setCellFromCodePoint(e-1,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs),t<this.length-e){for(var n=new s.CellData,a=this.length-e-t-1;a>=0;--a)this.setCell(e+t+a,this.loadCell(e+a,n));for(var c=0;c<t;++c)this.setCell(e+c,i)}else for(var l=e;l<this.length;++l)this.setCell(l,i);2===this.getWidth(this.length-1)&&this.setCellFromCodePoint(this.length-1,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs)}},{key:"deleteCells",value:function(e,t,i,r){if(e%=this.length,t<this.length-e){for(var n=new s.CellData,a=0;a<this.length-e-t;++a)this.setCell(e+a,this.loadCell(e+t+a,n));for(var c=this.length-t;c<this.length;++c)this.setCell(c,i)}else for(var l=e;l<this.length;++l)this.setCell(l,i);e&&2===this.getWidth(e-1)&&this.setCellFromCodePoint(e-1,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs),0!==this.getWidth(e)||this.hasContent(e)||this.setCellFromCodePoint(e,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs)}},{key:"replaceCells",value:function(e,t,i,r){if(arguments.length>4&&void 0!==arguments[4]&&arguments[4])for(e&&2===this.getWidth(e-1)&&!this.isProtected(e-1)&&this.setCellFromCodePoint(e-1,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs),t<this.length&&2===this.getWidth(t-1)&&!this.isProtected(t)&&this.setCellFromCodePoint(t,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs);e<t&&e<this.length;)this.isProtected(e)||this.setCell(e,i),e++;else for(e&&2===this.getWidth(e-1)&&this.setCellFromCodePoint(e-1,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs),t<this.length&&2===this.getWidth(t-1)&&this.setCellFromCodePoint(t,0,1,(null==r?void 0:r.fg)||0,(null==r?void 0:r.bg)||0,(null==r?void 0:r.extended)||new o.ExtendedAttrs);e<t&&e<this.length;)this.setCell(e++,i)}},{key:"resize",value:function(e,t){if(e===this.length)return 4*this._data.length*2<this._data.buffer.byteLength;var i=3*e;if(e>this.length){if(this._data.buffer.byteLength>=4*i)this._data=new Uint32Array(this._data.buffer,0,i);else{var r=new Uint32Array(i);r.set(this._data),this._data=r}for(var n=this.length;n<e;++n)this.setCell(n,t)}else{this._data=this._data.subarray(0,i);for(var s=Object.keys(this._combined),o=0;o<s.length;o++){var a=parseInt(s[o],10);a>=e&&delete this._combined[a]}for(var c=Object.keys(this._extendedAttrs),l=0;l<c.length;l++){var u=parseInt(c[l],10);u>=e&&delete this._extendedAttrs[u]}}return this.length=e,4*i*2<this._data.buffer.byteLength}},{key:"cleanupMemory",value:function(){if(4*this._data.length*2<this._data.buffer.byteLength){var e=new Uint32Array(this._data.length);return e.set(this._data),this._data=e,1}return 0}},{key:"fill",value:function(e){if(arguments.length>1&&void 0!==arguments[1]&&arguments[1])for(var t=0;t<this.length;++t)this.isProtected(t)||this.setCell(t,e);else{this._combined={},this._extendedAttrs={};for(var i=0;i<this.length;++i)this.setCell(i,e)}}},{key:"copyFrom",value:function(e){for(var t in this.length!==e.length?this._data=new Uint32Array(e._data):this._data.set(e._data),this.length=e.length,this._combined={},e._combined)this._combined[t]=e._combined[t];for(var i in this._extendedAttrs={},e._extendedAttrs)this._extendedAttrs[i]=e._extendedAttrs[i];this.isWrapped=e.isWrapped}},{key:"clone",value:function(){var t=new e(0);for(var i in t._data=new Uint32Array(this._data),t.length=this.length,this._combined)t._combined[i]=this._combined[i];for(var r in this._extendedAttrs)t._extendedAttrs[r]=this._extendedAttrs[r];return t.isWrapped=this.isWrapped,t}},{key:"getTrimmedLength",value:function(){for(var e=this.length-1;e>=0;--e)if(4194303&this._data[3*e+0])return e+(this._data[3*e+0]>>22);return 0}},{key:"copyCellsFrom",value:function(e,t,i,r,n){var s=e._data;if(n)for(var o=r-1;o>=0;o--){for(var a=0;a<3;a++)this._data[3*(i+o)+a]=s[3*(t+o)+a];268435456&s[3*(t+o)+2]&&(this._extendedAttrs[i+o]=e._extendedAttrs[t+o])}else for(var c=0;c<r;c++){for(var l=0;l<3;l++)this._data[3*(i+c)+l]=s[3*(t+c)+l];268435456&s[3*(t+c)+2]&&(this._extendedAttrs[i+c]=e._extendedAttrs[t+c])}for(var u=Object.keys(e._combined),h=0;h<u.length;h++){var f=parseInt(u[h],10);f>=t&&(this._combined[f-t+i]=e._combined[f])}}},{key:"translateToString",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.length;e&&(i=Math.min(i,this.getTrimmedLength()));for(var s="";t<i;){var o=this._data[3*t+0],a=2097151&o;s+=2097152&o?this._combined[t]:a?(0,r.stringFromCodePoint)(a):n.WHITESPACE_CELL_CHAR,t+=o>>22||1}return s}}]),e}();t.BufferLine=c},4841:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.getRangeLength=void 0,t.getRangeLength=function(e,t){if(e.start.y>e.end.y)throw new Error("Buffer range end (".concat(e.end.x,", ").concat(e.end.y,") cannot be before start (").concat(e.start.x,", ").concat(e.start.y,")"));return t*(e.end.y-e.start.y)+(e.end.x-e.start.x+1)}},4634:function(e,t){function i(e,t,i){if(t===e.length-1)return e[t].getTrimmedLength();var r=!e[t].hasContent(i-1)&&1===e[t].getWidth(i-1),n=2===e[t+1].getWidth(0);return r&&n?i-1:i}Object.defineProperty(t,"__esModule",{value:!0}),t.getWrappedLineTrimmedLength=t.reflowSmallerGetNewLineLengths=t.reflowLargerApplyNewLayout=t.reflowLargerCreateNewLayout=t.reflowLargerGetLinesToRemove=void 0,t.reflowLargerGetLinesToRemove=function(e,t,r,n,s){for(var o=[],a=0;a<e.length-1;a++){var c=a,l=e.get(++c);if(l.isWrapped){for(var u=[e.get(a)];c<e.length&&l.isWrapped;)u.push(l),l=e.get(++c);if(n>=a&&n<c)a+=u.length-1;else{for(var h=0,f=i(u,h,t),d=1,v=0;d<u.length;){var _=i(u,d,t),p=_-v,g=r-f,m=Math.min(p,g);u[h].copyCellsFrom(u[d],v,f,m,!1),(f+=m)===r&&(h++,f=0),(v+=m)===_&&(d++,v=0),0===f&&0!==h&&2===u[h-1].getWidth(r-1)&&(u[h].copyCellsFrom(u[h-1],r-1,f++,1,!1),u[h-1].setCell(r-1,s))}u[h].replaceCells(f,r,s);for(var y=0,b=u.length-1;b>0&&(b>h||0===u[b].getTrimmedLength());b--)y++;y>0&&(o.push(a+u.length-y),o.push(y)),a+=u.length-1}}}return o},t.reflowLargerCreateNewLayout=function(e,t){for(var i=[],r=0,n=t[r],s=0,o=0;o<e.length;o++)if(n===o){var a=t[++r];e.onDeleteEmitter.fire({index:o-s,amount:a}),o+=a-1,s+=a,n=t[++r]}else i.push(o);return{layout:i,countRemoved:s}},t.reflowLargerApplyNewLayout=function(e,t){for(var i=[],r=0;r<t.length;r++)i.push(e.get(t[r]));for(var n=0;n<i.length;n++)e.set(n,i[n]);e.length=t.length},t.reflowSmallerGetNewLineLengths=function(e,t,r){for(var n=[],s=e.map((function(r,n){return i(e,n,t)})).reduce((function(e,t){return e+t})),o=0,a=0,c=0;c<s;){if(s-c<r){n.push(s-c);break}o+=r;var l=i(e,a,t);o>l&&(o-=l,a++);var u=2===e[a].getWidth(o-1);u&&o--;var h=u?r-1:r;n.push(h),c+=h}return n},t.getWrappedLineTrimmedLength=i},5295:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BufferSet=void 0;var r=i(9092),n=i(8460),s=function(e){v(i,e);var t=_(i);function i(e,r){var s;return h(this,i),(s=t.call(this))._optionsService=e,s._bufferService=r,s._onBufferActivate=s.register(new n.EventEmitter),s.onBufferActivate=s._onBufferActivate.event,s.reset(),s.register(s._optionsService.onSpecificOptionChange("scrollback",(function(){return s.resize(s._bufferService.cols,s._bufferService.rows)}))),s.register(s._optionsService.onSpecificOptionChange("tabStopWidth",(function(){return s.setupTabStops()}))),s}return f(i,[{key:"reset",value:function(){this._normal=new r.Buffer(!0,this._optionsService,this._bufferService),this._normal.fillViewportRows(),this._alt=new r.Buffer(!1,this._optionsService,this._bufferService),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}),this.setupTabStops()}},{key:"alt",get:function(){return this._alt}},{key:"active",get:function(){return this._activeBuffer}},{key:"normal",get:function(){return this._normal}},{key:"activateNormalBuffer",value:function(){this._activeBuffer!==this._normal&&(this._normal.x=this._alt.x,this._normal.y=this._alt.y,this._alt.clearAllMarkers(),this._alt.clear(),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}))}},{key:"activateAltBuffer",value:function(e){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(e),this._alt.x=this._normal.x,this._alt.y=this._normal.y,this._activeBuffer=this._alt,this._onBufferActivate.fire({activeBuffer:this._alt,inactiveBuffer:this._normal}))}},{key:"resize",value:function(e,t){this._normal.resize(e,t),this._alt.resize(e,t),this.setupTabStops(e)}},{key:"setupTabStops",value:function(e){this._normal.setupTabStops(e),this._alt.setupTabStops(e)}}]),i}(i(844).Disposable);t.BufferSet=s},511:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.CellData=void 0;var r=i(482),n=i(643),s=i(3734),o=function(e){v(i,e);var t=_(i);function i(){var e;return h(this,i),(e=t.apply(this,arguments)).content=0,e.fg=0,e.bg=0,e.extended=new s.ExtendedAttrs,e.combinedData="",e}return f(i,[{key:"isCombined",value:function(){return 2097152&this.content}},{key:"getWidth",value:function(){return this.content>>22}},{key:"getChars",value:function(){return 2097152&this.content?this.combinedData:2097151&this.content?(0,r.stringFromCodePoint)(2097151&this.content):""}},{key:"getCode",value:function(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):2097151&this.content}},{key:"setFromCharData",value:function(e){this.fg=e[n.CHAR_DATA_ATTR_INDEX],this.bg=0;var t=!1;if(e[n.CHAR_DATA_CHAR_INDEX].length>2)t=!0;else if(2===e[n.CHAR_DATA_CHAR_INDEX].length){var i=e[n.CHAR_DATA_CHAR_INDEX].charCodeAt(0);if(55296<=i&&i<=56319){var r=e[n.CHAR_DATA_CHAR_INDEX].charCodeAt(1);56320<=r&&r<=57343?this.content=1024*(i-55296)+r-56320+65536|e[n.CHAR_DATA_WIDTH_INDEX]<<22:t=!0}else t=!0}else this.content=e[n.CHAR_DATA_CHAR_INDEX].charCodeAt(0)|e[n.CHAR_DATA_WIDTH_INDEX]<<22;t&&(this.combinedData=e[n.CHAR_DATA_CHAR_INDEX],this.content=2097152|e[n.CHAR_DATA_WIDTH_INDEX]<<22)}},{key:"getAsCharData",value:function(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}}],[{key:"fromCharData",value:function(e){var t=new i;return t.setFromCharData(e),t}}]),i}(s.AttributeData);t.CellData=o},643:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.WHITESPACE_CELL_CODE=t.WHITESPACE_CELL_WIDTH=t.WHITESPACE_CELL_CHAR=t.NULL_CELL_CODE=t.NULL_CELL_WIDTH=t.NULL_CELL_CHAR=t.CHAR_DATA_CODE_INDEX=t.CHAR_DATA_WIDTH_INDEX=t.CHAR_DATA_CHAR_INDEX=t.CHAR_DATA_ATTR_INDEX=t.DEFAULT_EXT=t.DEFAULT_ATTR=t.DEFAULT_COLOR=void 0,t.DEFAULT_COLOR=0,t.DEFAULT_ATTR=256|t.DEFAULT_COLOR<<9,t.DEFAULT_EXT=0,t.CHAR_DATA_ATTR_INDEX=0,t.CHAR_DATA_CHAR_INDEX=1,t.CHAR_DATA_WIDTH_INDEX=2,t.CHAR_DATA_CODE_INDEX=3,t.NULL_CELL_CHAR="",t.NULL_CELL_WIDTH=1,t.NULL_CELL_CODE=0,t.WHITESPACE_CELL_CHAR=" ",t.WHITESPACE_CELL_WIDTH=1,t.WHITESPACE_CELL_CODE=32},4863:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.Marker=void 0;var r=i(8460),n=i(844),s=function(){function e(t){h(this,e),this.line=t,this.isDisposed=!1,this._disposables=[],this._id=e._nextId++,this._onDispose=this.register(new r.EventEmitter),this.onDispose=this._onDispose.event}return f(e,[{key:"id",get:function(){return this._id}},{key:"dispose",value:function(){this.isDisposed||(this.isDisposed=!0,this.line=-1,this._onDispose.fire(),(0,n.disposeArray)(this._disposables),this._disposables.length=0)}},{key:"register",value:function(e){return this._disposables.push(e),e}}]),e}();t.Marker=s,s._nextId=1},7116:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_CHARSET=t.CHARSETS=void 0,t.CHARSETS={},t.DEFAULT_CHARSET=t.CHARSETS.B,t.CHARSETS[0]={"`":"\u25c6",a:"\u2592",b:"\u2409",c:"\u240c",d:"\u240d",e:"\u240a",f:"\xb0",g:"\xb1",h:"\u2424",i:"\u240b",j:"\u2518",k:"\u2510",l:"\u250c",m:"\u2514",n:"\u253c",o:"\u23ba",p:"\u23bb",q:"\u2500",r:"\u23bc",s:"\u23bd",t:"\u251c",u:"\u2524",v:"\u2534",w:"\u252c",x:"\u2502",y:"\u2264",z:"\u2265","{":"\u03c0","|":"\u2260","}":"\xa3","~":"\xb7"},t.CHARSETS.A={"#":"\xa3"},t.CHARSETS.B=void 0,t.CHARSETS[4]={"#":"\xa3","@":"\xbe","[":"ij","\\":"\xbd","]":"|","{":"\xa8","|":"f","}":"\xbc","~":"\xb4"},t.CHARSETS.C=t.CHARSETS[5]={"[":"\xc4","\\":"\xd6","]":"\xc5","^":"\xdc","`":"\xe9","{":"\xe4","|":"\xf6","}":"\xe5","~":"\xfc"},t.CHARSETS.R={"#":"\xa3","@":"\xe0","[":"\xb0","\\":"\xe7","]":"\xa7","{":"\xe9","|":"\xf9","}":"\xe8","~":"\xa8"},t.CHARSETS.Q={"@":"\xe0","[":"\xe2","\\":"\xe7","]":"\xea","^":"\xee","`":"\xf4","{":"\xe9","|":"\xf9","}":"\xe8","~":"\xfb"},t.CHARSETS.K={"@":"\xa7","[":"\xc4","\\":"\xd6","]":"\xdc","{":"\xe4","|":"\xf6","}":"\xfc","~":"\xdf"},t.CHARSETS.Y={"#":"\xa3","@":"\xa7","[":"\xb0","\\":"\xe7","]":"\xe9","`":"\xf9","{":"\xe0","|":"\xf2","}":"\xe8","~":"\xec"},t.CHARSETS.E=t.CHARSETS[6]={"@":"\xc4","[":"\xc6","\\":"\xd8","]":"\xc5","^":"\xdc","`":"\xe4","{":"\xe6","|":"\xf8","}":"\xe5","~":"\xfc"},t.CHARSETS.Z={"#":"\xa3","@":"\xa7","[":"\xa1","\\":"\xd1","]":"\xbf","{":"\xb0","|":"\xf1","}":"\xe7"},t.CHARSETS.H=t.CHARSETS[7]={"@":"\xc9","[":"\xc4","\\":"\xd6","]":"\xc5","^":"\xdc","`":"\xe9","{":"\xe4","|":"\xf6","}":"\xe5","~":"\xfc"},t.CHARSETS["="]={"#":"\xf9","@":"\xe0","[":"\xe9","\\":"\xe7","]":"\xea","^":"\xee",_:"\xe8","`":"\xf4","{":"\xe4","|":"\xf6","}":"\xfc","~":"\xfb"}},2584:function(e,t){var i,r;Object.defineProperty(t,"__esModule",{value:!0}),t.C1_ESCAPED=t.C1=t.C0=void 0,function(e){e.NUL="\0",e.SOH="\x01",e.STX="\x02",e.ETX="\x03",e.EOT="\x04",e.ENQ="\x05",e.ACK="\x06",e.BEL="\x07",e.BS="\b",e.HT="\t",e.LF="\n",e.VT="\v",e.FF="\f",e.CR="\r",e.SO="\x0e",e.SI="\x0f",e.DLE="\x10",e.DC1="\x11",e.DC2="\x12",e.DC3="\x13",e.DC4="\x14",e.NAK="\x15",e.SYN="\x16",e.ETB="\x17",e.CAN="\x18",e.EM="\x19",e.SUB="\x1a",e.ESC="\x1b",e.FS="\x1c",e.GS="\x1d",e.RS="\x1e",e.US="\x1f",e.SP=" ",e.DEL="\x7f"}(i=t.C0||(t.C0={})),(r=t.C1||(t.C1={})).PAD="\x80",r.HOP="\x81",r.BPH="\x82",r.NBH="\x83",r.IND="\x84",r.NEL="\x85",r.SSA="\x86",r.ESA="\x87",r.HTS="\x88",r.HTJ="\x89",r.VTS="\x8a",r.PLD="\x8b",r.PLU="\x8c",r.RI="\x8d",r.SS2="\x8e",r.SS3="\x8f",r.DCS="\x90",r.PU1="\x91",r.PU2="\x92",r.STS="\x93",r.CCH="\x94",r.MW="\x95",r.SPA="\x96",r.EPA="\x97",r.SOS="\x98",r.SGCI="\x99",r.SCI="\x9a",r.CSI="\x9b",r.ST="\x9c",r.OSC="\x9d",r.PM="\x9e",r.APC="\x9f",(t.C1_ESCAPED||(t.C1_ESCAPED={})).ST="".concat(i.ESC,"\\")},7399:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.evaluateKeyboardEvent=void 0;var r=i(2584),n={48:["0",")"],49:["1","!"],50:["2","@"],51:["3","#"],52:["4","$"],53:["5","%"],54:["6","^"],55:["7","&"],56:["8","*"],57:["9","("],186:[";",":"],187:["=","+"],188:[",","<"],189:["-","_"],190:[".",">"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};t.evaluateKeyboardEvent=function(e,t,i,s){var o={type:0,cancel:!1,key:void 0},a=(e.shiftKey?1:0)|(e.altKey?2:0)|(e.ctrlKey?4:0)|(e.metaKey?8:0);switch(e.keyCode){case 0:"UIKeyInputUpArrow"===e.key?o.key=t?r.C0.ESC+"OA":r.C0.ESC+"[A":"UIKeyInputLeftArrow"===e.key?o.key=t?r.C0.ESC+"OD":r.C0.ESC+"[D":"UIKeyInputRightArrow"===e.key?o.key=t?r.C0.ESC+"OC":r.C0.ESC+"[C":"UIKeyInputDownArrow"===e.key&&(o.key=t?r.C0.ESC+"OB":r.C0.ESC+"[B");break;case 8:if(e.altKey){o.key=r.C0.ESC+r.C0.DEL;break}o.key=r.C0.DEL;break;case 9:if(e.shiftKey){o.key=r.C0.ESC+"[Z";break}o.key=r.C0.HT,o.cancel=!0;break;case 13:o.key=e.altKey?r.C0.ESC+r.C0.CR:r.C0.CR,o.cancel=!0;break;case 27:o.key=r.C0.ESC,e.altKey&&(o.key=r.C0.ESC+r.C0.ESC),o.cancel=!0;break;case 37:if(e.metaKey)break;a?(o.key=r.C0.ESC+"[1;"+(a+1)+"D",o.key===r.C0.ESC+"[1;3D"&&(o.key=r.C0.ESC+(i?"b":"[1;5D"))):o.key=t?r.C0.ESC+"OD":r.C0.ESC+"[D";break;case 39:if(e.metaKey)break;a?(o.key=r.C0.ESC+"[1;"+(a+1)+"C",o.key===r.C0.ESC+"[1;3C"&&(o.key=r.C0.ESC+(i?"f":"[1;5C"))):o.key=t?r.C0.ESC+"OC":r.C0.ESC+"[C";break;case 38:if(e.metaKey)break;a?(o.key=r.C0.ESC+"[1;"+(a+1)+"A",i||o.key!==r.C0.ESC+"[1;3A"||(o.key=r.C0.ESC+"[1;5A")):o.key=t?r.C0.ESC+"OA":r.C0.ESC+"[A";break;case 40:if(e.metaKey)break;a?(o.key=r.C0.ESC+"[1;"+(a+1)+"B",i||o.key!==r.C0.ESC+"[1;3B"||(o.key=r.C0.ESC+"[1;5B")):o.key=t?r.C0.ESC+"OB":r.C0.ESC+"[B";break;case 45:e.shiftKey||e.ctrlKey||(o.key=r.C0.ESC+"[2~");break;case 46:o.key=a?r.C0.ESC+"[3;"+(a+1)+"~":r.C0.ESC+"[3~";break;case 36:o.key=a?r.C0.ESC+"[1;"+(a+1)+"H":t?r.C0.ESC+"OH":r.C0.ESC+"[H";break;case 35:o.key=a?r.C0.ESC+"[1;"+(a+1)+"F":t?r.C0.ESC+"OF":r.C0.ESC+"[F";break;case 33:e.shiftKey?o.type=2:e.ctrlKey?o.key=r.C0.ESC+"[5;"+(a+1)+"~":o.key=r.C0.ESC+"[5~";break;case 34:e.shiftKey?o.type=3:e.ctrlKey?o.key=r.C0.ESC+"[6;"+(a+1)+"~":o.key=r.C0.ESC+"[6~";break;case 112:o.key=a?r.C0.ESC+"[1;"+(a+1)+"P":r.C0.ESC+"OP";break;case 113:o.key=a?r.C0.ESC+"[1;"+(a+1)+"Q":r.C0.ESC+"OQ";break;case 114:o.key=a?r.C0.ESC+"[1;"+(a+1)+"R":r.C0.ESC+"OR";break;case 115:o.key=a?r.C0.ESC+"[1;"+(a+1)+"S":r.C0.ESC+"OS";break;case 116:o.key=a?r.C0.ESC+"[15;"+(a+1)+"~":r.C0.ESC+"[15~";break;case 117:o.key=a?r.C0.ESC+"[17;"+(a+1)+"~":r.C0.ESC+"[17~";break;case 118:o.key=a?r.C0.ESC+"[18;"+(a+1)+"~":r.C0.ESC+"[18~";break;case 119:o.key=a?r.C0.ESC+"[19;"+(a+1)+"~":r.C0.ESC+"[19~";break;case 120:o.key=a?r.C0.ESC+"[20;"+(a+1)+"~":r.C0.ESC+"[20~";break;case 121:o.key=a?r.C0.ESC+"[21;"+(a+1)+"~":r.C0.ESC+"[21~";break;case 122:o.key=a?r.C0.ESC+"[23;"+(a+1)+"~":r.C0.ESC+"[23~";break;case 123:o.key=a?r.C0.ESC+"[24;"+(a+1)+"~":r.C0.ESC+"[24~";break;default:if(!e.ctrlKey||e.shiftKey||e.altKey||e.metaKey)if(i&&!s||!e.altKey||e.metaKey)!i||e.altKey||e.ctrlKey||e.shiftKey||!e.metaKey?e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&e.keyCode>=48&&1===e.key.length?o.key=e.key:e.key&&e.ctrlKey&&("_"===e.key&&(o.key=r.C0.US),"@"===e.key&&(o.key=r.C0.NUL)):65===e.keyCode&&(o.type=1);else{var c=n[e.keyCode],l=null==c?void 0:c[e.shiftKey?1:0];if(l)o.key=r.C0.ESC+l;else if(e.keyCode>=65&&e.keyCode<=90){var u=e.ctrlKey?e.keyCode-64:e.keyCode+32,h=String.fromCharCode(u);e.shiftKey&&(h=h.toUpperCase()),o.key=r.C0.ESC+h}else if(32===e.keyCode)o.key=r.C0.ESC+(e.ctrlKey?r.C0.NUL:" ");else if("Dead"===e.key&&e.code.startsWith("Key")){var f=e.code.slice(3,4);e.shiftKey||(f=f.toLowerCase()),o.key=r.C0.ESC+f,o.cancel=!0}}else e.keyCode>=65&&e.keyCode<=90?o.key=String.fromCharCode(e.keyCode-64):32===e.keyCode?o.key=r.C0.NUL:e.keyCode>=51&&e.keyCode<=55?o.key=String.fromCharCode(e.keyCode-51+27):56===e.keyCode?o.key=r.C0.DEL:219===e.keyCode?o.key=r.C0.ESC:220===e.keyCode?o.key=r.C0.FS:221===e.keyCode&&(o.key=r.C0.GS)}return o}},482:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Utf8ToUtf32=t.StringToUtf32=t.utf32ToString=t.stringFromCodePoint=void 0,t.stringFromCodePoint=function(e){return e>65535?(e-=65536,String.fromCharCode(55296+(e>>10))+String.fromCharCode(e%1024+56320)):String.fromCharCode(e)},t.utf32ToString=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.length,r="",n=t;n<i;++n){var s=e[n];s>65535?(s-=65536,r+=String.fromCharCode(55296+(s>>10))+String.fromCharCode(s%1024+56320)):r+=String.fromCharCode(s)}return r},t.StringToUtf32=function(){function e(){h(this,e),this._interim=0}return f(e,[{key:"clear",value:function(){this._interim=0}},{key:"decode",value:function(e,t){var i=e.length;if(!i)return 0;var r=0,n=0;if(this._interim){var s=e.charCodeAt(n++);56320<=s&&s<=57343?t[r++]=1024*(this._interim-55296)+s-56320+65536:(t[r++]=this._interim,t[r++]=s),this._interim=0}for(var o=n;o<i;++o){var a=e.charCodeAt(o);if(55296<=a&&a<=56319){if(++o>=i)return this._interim=a,r;var c=e.charCodeAt(o);56320<=c&&c<=57343?t[r++]=1024*(a-55296)+c-56320+65536:(t[r++]=a,t[r++]=c)}else 65279!==a&&(t[r++]=a)}return r}}]),e}(),t.Utf8ToUtf32=function(){function e(){h(this,e),this.interim=new Uint8Array(3)}return f(e,[{key:"clear",value:function(){this.interim.fill(0)}},{key:"decode",value:function(e,t){var i=e.length;if(!i)return 0;var r,n,s,o,a=0,c=0,l=0;if(this.interim[0]){var u=!1,h=this.interim[0];h&=192==(224&h)?31:224==(240&h)?15:7;for(var f,d=0;(f=63&this.interim[++d])&&d<4;)h<<=6,h|=f;for(var v=192==(224&this.interim[0])?2:224==(240&this.interim[0])?3:4,_=v-d;l<_;){if(l>=i)return 0;if(128!=(192&(f=e[l++]))){l--,u=!0;break}this.interim[d++]=f,h<<=6,h|=63&f}u||(2===v?h<128?l--:t[a++]=h:3===v?h<2048||h>=55296&&h<=57343||65279===h||(t[a++]=h):h<65536||h>1114111||(t[a++]=h)),this.interim.fill(0)}for(var p=i-4,g=l;g<i;){for(;!(!(g<p)||128&(r=e[g])||128&(n=e[g+1])||128&(s=e[g+2])||128&(o=e[g+3]));)t[a++]=r,t[a++]=n,t[a++]=s,t[a++]=o,g+=4;if((r=e[g++])<128)t[a++]=r;else if(192==(224&r)){if(g>=i)return this.interim[0]=r,a;if(128!=(192&(n=e[g++]))){g--;continue}if((c=(31&r)<<6|63&n)<128){g--;continue}t[a++]=c}else if(224==(240&r)){if(g>=i)return this.interim[0]=r,a;if(128!=(192&(n=e[g++]))){g--;continue}if(g>=i)return this.interim[0]=r,this.interim[1]=n,a;if(128!=(192&(s=e[g++]))){g--;continue}if((c=(15&r)<<12|(63&n)<<6|63&s)<2048||c>=55296&&c<=57343||65279===c)continue;t[a++]=c}else if(240==(248&r)){if(g>=i)return this.interim[0]=r,a;if(128!=(192&(n=e[g++]))){g--;continue}if(g>=i)return this.interim[0]=r,this.interim[1]=n,a;if(128!=(192&(s=e[g++]))){g--;continue}if(g>=i)return this.interim[0]=r,this.interim[1]=n,this.interim[2]=s,a;if(128!=(192&(o=e[g++]))){g--;continue}if((c=(7&r)<<18|(63&n)<<12|(63&s)<<6|63&o)<65536||c>1114111)continue;t[a++]=c}}return a}}]),e}()},225:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeV6=void 0;var i,r=[[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]];t.UnicodeV6=function(){function e(){if(h(this,e),this.version="6",!i){(i=new Uint8Array(65536)).fill(1),i[0]=0,i.fill(0,1,32),i.fill(0,127,160),i.fill(2,4352,4448),i[9001]=2,i[9002]=2,i.fill(2,11904,42192),i[12351]=1,i.fill(2,44032,55204),i.fill(2,63744,64256),i.fill(2,65040,65050),i.fill(2,65072,65136),i.fill(2,65280,65377),i.fill(2,65504,65511);for(var t=0;t<r.length;++t)i.fill(0,r[t][0],r[t][1]+1)}}return f(e,[{key:"wcwidth",value:function(e){return e<32?0:e<127?1:e<65536?i[e]:function(e,t){var i,r=0,n=t.length-1;if(e<t[0][0]||e>t[n][1])return!1;for(;n>=r;)if(e>t[i=r+n>>1][1])r=i+1;else{if(!(e<t[i][0]))return!0;n=i-1}return!1}(e,n)?0:e>=131072&&e<=196605||e>=196608&&e<=262141?2:1}}]),e}()},5981:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.WriteBuffer=void 0;var r=i(8460),n=function(e){v(i,e);var t=_(i);function i(e){var n;return h(this,i),(n=t.call(this))._action=e,n._writeBuffer=[],n._callbacks=[],n._pendingData=0,n._bufferOffset=0,n._isSyncWriting=!1,n._syncCalls=0,n._didUserInput=!1,n._onWriteParsed=n.register(new r.EventEmitter),n.onWriteParsed=n._onWriteParsed.event,n}return f(i,[{key:"handleUserInput",value:function(){this._didUserInput=!0}},{key:"writeSync",value:function(e,t){if(void 0!==t&&this._syncCalls>t)this._syncCalls=0;else if(this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(void 0),this._syncCalls++,!this._isSyncWriting){var i;for(this._isSyncWriting=!0;i=this._writeBuffer.shift();){this._action(i);var r=this._callbacks.shift();r&&r()}this._pendingData=0,this._bufferOffset=2147483647,this._isSyncWriting=!1,this._syncCalls=0}}},{key:"write",value:function(e,t){var i=this;if(this._pendingData>5e7)throw new Error("write data discarded, use flow control to avoid losing data");if(!this._writeBuffer.length){if(this._bufferOffset=0,this._didUserInput)return this._didUserInput=!1,this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t),void this._innerWrite();setTimeout((function(){return i._innerWrite()}))}this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t)}},{key:"_innerWrite",value:function(){for(var e=this,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:0)||Date.now();this._writeBuffer.length>this._bufferOffset;){var r=this._writeBuffer[this._bufferOffset],n=this._action(r,t);if(n){var s=function(t){return Date.now()-i>=12?setTimeout((function(){return e._innerWrite(0,t)})):e._innerWrite(i,t)};return void n.catch((function(e){return queueMicrotask((function(){throw e})),Promise.resolve(!1)})).then(s)}var o=this._callbacks[this._bufferOffset];if(o&&o(),this._bufferOffset++,this._pendingData-=r.length,Date.now()-i>=12)break}this._writeBuffer.length>this._bufferOffset?(this._bufferOffset>50&&(this._writeBuffer=this._writeBuffer.slice(this._bufferOffset),this._callbacks=this._callbacks.slice(this._bufferOffset),this._bufferOffset=0),setTimeout((function(){return e._innerWrite()}))):(this._writeBuffer.length=0,this._callbacks.length=0,this._pendingData=0,this._bufferOffset=0),this._onWriteParsed.fire()}}]),i}(i(844).Disposable);t.WriteBuffer=n},5941:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.toRgbString=t.parseColor=void 0;var i=/^([\da-f])\/([\da-f])\/([\da-f])$|^([\da-f]{2})\/([\da-f]{2})\/([\da-f]{2})$|^([\da-f]{3})\/([\da-f]{3})\/([\da-f]{3})$|^([\da-f]{4})\/([\da-f]{4})\/([\da-f]{4})$/,r=/^[\da-f]+$/;function n(e,t){var i=e.toString(16),r=i.length<2?"0"+i:i;switch(t){case 4:return i[0];case 8:return r;case 12:return(r+r).slice(0,3);default:return r+r}}t.parseColor=function(e){if(e){var t=e.toLowerCase();if(0===t.indexOf("rgb:")){t=t.slice(4);var n=i.exec(t);if(n){var s=n[1]?15:n[4]?255:n[7]?4095:65535;return[Math.round(parseInt(n[1]||n[4]||n[7]||n[10],16)/s*255),Math.round(parseInt(n[2]||n[5]||n[8]||n[11],16)/s*255),Math.round(parseInt(n[3]||n[6]||n[9]||n[12],16)/s*255)]}}else if(0===t.indexOf("#")&&(t=t.slice(1),r.exec(t)&&[3,6,9,12].includes(t.length))){for(var o=t.length/3,a=[0,0,0],c=0;c<3;++c){var l=parseInt(t.slice(o*c,o*c+o),16);a[c]=1===o?l<<4:2===o?l:3===o?l>>4:l>>8}return a}}},t.toRgbString=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:16,i=l(e,3),r=i[0],s=i[1],o=i[2];return"rgb:".concat(n(r,t),"/").concat(n(s,t),"/").concat(n(o,t))}},5770:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.PAYLOAD_LIMIT=void 0,t.PAYLOAD_LIMIT=1e7},6351:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.DcsHandler=t.DcsParser=void 0;var r=i(482),n=i(8742),s=i(5770),o=[];t.DcsParser=function(){function e(){h(this,e),this._handlers=Object.create(null),this._active=o,this._ident=0,this._handlerFb=function(){},this._stack={paused:!1,loopPosition:0,fallThrough:!1}}return f(e,[{key:"dispose",value:function(){this._handlers=Object.create(null),this._handlerFb=function(){},this._active=o}},{key:"registerHandler",value:function(e,t){void 0===this._handlers[e]&&(this._handlers[e]=[]);var i=this._handlers[e];return i.push(t),{dispose:function(){var e=i.indexOf(t);-1!==e&&i.splice(e,1)}}}},{key:"clearHandler",value:function(e){this._handlers[e]&&delete this._handlers[e]}},{key:"setHandlerFallback",value:function(e){this._handlerFb=e}},{key:"reset",value:function(){if(this._active.length)for(var e=this._stack.paused?this._stack.loopPosition-1:this._active.length-1;e>=0;--e)this._active[e].unhook(!1);this._stack.paused=!1,this._active=o,this._ident=0}},{key:"hook",value:function(e,t){if(this.reset(),this._ident=e,this._active=this._handlers[e]||o,this._active.length)for(var i=this._active.length-1;i>=0;i--)this._active[i].hook(t);else this._handlerFb(this._ident,"HOOK",t)}},{key:"put",value:function(e,t,i){if(this._active.length)for(var n=this._active.length-1;n>=0;n--)this._active[n].put(e,t,i);else this._handlerFb(this._ident,"PUT",(0,r.utf32ToString)(e,t,i))}},{key:"unhook",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(this._active.length){var i=!1,r=this._active.length-1,n=!1;if(this._stack.paused&&(r=this._stack.loopPosition-1,i=t,n=this._stack.fallThrough,this._stack.paused=!1),!n&&!1===i){for(;r>=0&&!0!==(i=this._active[r].unhook(e));r--)if(i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!1,i;r--}for(;r>=0;r--)if((i=this._active[r].unhook(!1))instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!0,i}else this._handlerFb(this._ident,"UNHOOK",e);this._active=o,this._ident=0}}]),e}();var a=new n.Params;a.addParam(0),t.DcsHandler=function(){function e(t){h(this,e),this._handler=t,this._data="",this._params=a,this._hitLimit=!1}return f(e,[{key:"hook",value:function(e){this._params=e.length>1||e.params[0]?e.clone():a,this._data="",this._hitLimit=!1}},{key:"put",value:function(e,t,i){this._hitLimit||(this._data+=(0,r.utf32ToString)(e,t,i),this._data.length>s.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))}},{key:"unhook",value:function(e){var t=this,i=!1;if(this._hitLimit)i=!1;else if(e&&(i=this._handler(this._data,this._params))instanceof Promise)return i.then((function(e){return t._params=a,t._data="",t._hitLimit=!1,e}));return this._params=a,this._data="",this._hitLimit=!1,i}}]),e}()},2015:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.EscapeSequenceParser=t.VT500_TRANSITION_TABLE=t.TransitionTable=void 0;var r=i(844),n=i(8742),s=i(6242),o=i(6351),a=function(){function e(t){h(this,e),this.table=new Uint8Array(t)}return f(e,[{key:"setDefault",value:function(e,t){this.table.fill(e<<4|t)}},{key:"add",value:function(e,t,i,r){this.table[t<<8|e]=i<<4|r}},{key:"addMany",value:function(e,t,i,r){for(var n=0;n<e.length;n++)this.table[t<<8|e[n]]=i<<4|r}}]),e}();t.TransitionTable=a;var c=160;t.VT500_TRANSITION_TABLE=function(){var e=new a(4095),t=Array.apply(null,Array(256)).map((function(e,t){return t})),i=function(e,i){return t.slice(e,i)},r=i(32,127),n=i(0,24);n.push(25),n.push.apply(n,i(28,32));var s,o=i(0,14);for(s in e.setDefault(1,0),e.addMany(r,0,2,0),o)e.addMany([24,26,153,154],s,3,0),e.addMany(i(128,144),s,3,0),e.addMany(i(144,152),s,3,0),e.add(156,s,0,0),e.add(27,s,11,1),e.add(157,s,4,8),e.addMany([152,158,159],s,0,7),e.add(155,s,11,3),e.add(144,s,11,9);return e.addMany(n,0,3,0),e.addMany(n,1,3,1),e.add(127,1,0,1),e.addMany(n,8,0,8),e.addMany(n,3,3,3),e.add(127,3,0,3),e.addMany(n,4,3,4),e.add(127,4,0,4),e.addMany(n,6,3,6),e.addMany(n,5,3,5),e.add(127,5,0,5),e.addMany(n,2,3,2),e.add(127,2,0,2),e.add(93,1,4,8),e.addMany(r,8,5,8),e.add(127,8,5,8),e.addMany([156,27,24,26,7],8,6,0),e.addMany(i(28,32),8,0,8),e.addMany([88,94,95],1,0,7),e.addMany(r,7,0,7),e.addMany(n,7,0,7),e.add(156,7,0,0),e.add(127,7,0,7),e.add(91,1,11,3),e.addMany(i(64,127),3,7,0),e.addMany(i(48,60),3,8,4),e.addMany([60,61,62,63],3,9,4),e.addMany(i(48,60),4,8,4),e.addMany(i(64,127),4,7,0),e.addMany([60,61,62,63],4,0,6),e.addMany(i(32,64),6,0,6),e.add(127,6,0,6),e.addMany(i(64,127),6,0,0),e.addMany(i(32,48),3,9,5),e.addMany(i(32,48),5,9,5),e.addMany(i(48,64),5,0,6),e.addMany(i(64,127),5,7,0),e.addMany(i(32,48),4,9,5),e.addMany(i(32,48),1,9,2),e.addMany(i(32,48),2,9,2),e.addMany(i(48,127),2,10,0),e.addMany(i(48,80),1,10,0),e.addMany(i(81,88),1,10,0),e.addMany([89,90,92],1,10,0),e.addMany(i(96,127),1,10,0),e.add(80,1,11,9),e.addMany(n,9,0,9),e.add(127,9,0,9),e.addMany(i(28,32),9,0,9),e.addMany(i(32,48),9,9,12),e.addMany(i(48,60),9,8,10),e.addMany([60,61,62,63],9,9,10),e.addMany(n,11,0,11),e.addMany(i(32,128),11,0,11),e.addMany(i(28,32),11,0,11),e.addMany(n,10,0,10),e.add(127,10,0,10),e.addMany(i(28,32),10,0,10),e.addMany(i(48,60),10,8,10),e.addMany([60,61,62,63],10,0,11),e.addMany(i(32,48),10,9,12),e.addMany(n,12,0,12),e.add(127,12,0,12),e.addMany(i(28,32),12,0,12),e.addMany(i(32,48),12,9,12),e.addMany(i(48,64),12,0,11),e.addMany(i(64,127),12,12,13),e.addMany(i(64,127),10,12,13),e.addMany(i(64,127),9,12,13),e.addMany(n,13,13,13),e.addMany(r,13,13,13),e.add(127,13,0,13),e.addMany([27,156,24,26],13,14,0),e.add(c,0,2,0),e.add(c,8,5,8),e.add(c,6,0,6),e.add(c,11,0,11),e.add(c,13,13,13),e}();var l=function(e){v(a,e);var i=_(a);function a(){var e,c=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t.VT500_TRANSITION_TABLE;return h(this,a),(e=i.call(this))._transitions=c,e._parseStack={state:0,handlers:[],handlerPos:0,transition:0,chunkPos:0},e.initialState=0,e.currentState=e.initialState,e._params=new n.Params,e._params.addParam(0),e._collect=0,e.precedingCodepoint=0,e._printHandlerFb=function(e,t,i){},e._executeHandlerFb=function(e){},e._csiHandlerFb=function(e,t){},e._escHandlerFb=function(e){},e._errorHandlerFb=function(e){return e},e._printHandler=e._printHandlerFb,e._executeHandlers=Object.create(null),e._csiHandlers=Object.create(null),e._escHandlers=Object.create(null),e.register((0,r.toDisposable)((function(){e._csiHandlers=Object.create(null),e._executeHandlers=Object.create(null),e._escHandlers=Object.create(null)}))),e._oscParser=e.register(new s.OscParser),e._dcsParser=e.register(new o.DcsParser),e._errorHandler=e._errorHandlerFb,e.registerEscHandler({final:"\\"},(function(){return!0})),e}return f(a,[{key:"_identifier",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[64,126],i=0;if(e.prefix){if(e.prefix.length>1)throw new Error("only one byte as prefix supported");if((i=e.prefix.charCodeAt(0))&&60>i||i>63)throw new Error("prefix must be in range 0x3c .. 0x3f")}if(e.intermediates){if(e.intermediates.length>2)throw new Error("only two bytes as intermediates are supported");for(var r=0;r<e.intermediates.length;++r){var n=e.intermediates.charCodeAt(r);if(32>n||n>47)throw new Error("intermediate must be in range 0x20 .. 0x2f");i<<=8,i|=n}}if(1!==e.final.length)throw new Error("final must be a single byte");var s=e.final.charCodeAt(0);if(t[0]>s||s>t[1])throw new Error("final must be in range ".concat(t[0]," .. ").concat(t[1]));return i<<=8,i|=s}},{key:"identToString",value:function(e){for(var t=[];e;)t.push(String.fromCharCode(255&e)),e>>=8;return t.reverse().join("")}},{key:"setPrintHandler",value:function(e){this._printHandler=e}},{key:"clearPrintHandler",value:function(){this._printHandler=this._printHandlerFb}},{key:"registerEscHandler",value:function(e,t){var i=this._identifier(e,[48,126]);void 0===this._escHandlers[i]&&(this._escHandlers[i]=[]);var r=this._escHandlers[i];return r.push(t),{dispose:function(){var e=r.indexOf(t);-1!==e&&r.splice(e,1)}}}},{key:"clearEscHandler",value:function(e){this._escHandlers[this._identifier(e,[48,126])]&&delete this._escHandlers[this._identifier(e,[48,126])]}},{key:"setEscHandlerFallback",value:function(e){this._escHandlerFb=e}},{key:"setExecuteHandler",value:function(e,t){this._executeHandlers[e.charCodeAt(0)]=t}},{key:"clearExecuteHandler",value:function(e){this._executeHandlers[e.charCodeAt(0)]&&delete this._executeHandlers[e.charCodeAt(0)]}},{key:"setExecuteHandlerFallback",value:function(e){this._executeHandlerFb=e}},{key:"registerCsiHandler",value:function(e,t){var i=this._identifier(e);void 0===this._csiHandlers[i]&&(this._csiHandlers[i]=[]);var r=this._csiHandlers[i];return r.push(t),{dispose:function(){var e=r.indexOf(t);-1!==e&&r.splice(e,1)}}}},{key:"clearCsiHandler",value:function(e){this._csiHandlers[this._identifier(e)]&&delete this._csiHandlers[this._identifier(e)]}},{key:"setCsiHandlerFallback",value:function(e){this._csiHandlerFb=e}},{key:"registerDcsHandler",value:function(e,t){return this._dcsParser.registerHandler(this._identifier(e),t)}},{key:"clearDcsHandler",value:function(e){this._dcsParser.clearHandler(this._identifier(e))}},{key:"setDcsHandlerFallback",value:function(e){this._dcsParser.setHandlerFallback(e)}},{key:"registerOscHandler",value:function(e,t){return this._oscParser.registerHandler(e,t)}},{key:"clearOscHandler",value:function(e){this._oscParser.clearHandler(e)}},{key:"setOscHandlerFallback",value:function(e){this._oscParser.setHandlerFallback(e)}},{key:"setErrorHandler",value:function(e){this._errorHandler=e}},{key:"clearErrorHandler",value:function(){this._errorHandler=this._errorHandlerFb}},{key:"reset",value:function(){this.currentState=this.initialState,this._oscParser.reset(),this._dcsParser.reset(),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingCodepoint=0,0!==this._parseStack.state&&(this._parseStack.state=2,this._parseStack.handlers=[])}},{key:"_preserveStack",value:function(e,t,i,r,n){this._parseStack.state=e,this._parseStack.handlers=t,this._parseStack.handlerPos=i,this._parseStack.transition=r,this._parseStack.chunkPos=n}},{key:"parse",value:function(e,t,i){var r,n=0,s=0,o=0;if(this._parseStack.state)if(2===this._parseStack.state)this._parseStack.state=0,o=this._parseStack.chunkPos+1;else{if(void 0===i||1===this._parseStack.state)throw this._parseStack.state=1,new Error("improper continuation due to previous async handler, giving up parsing");var a=this._parseStack.handlers,l=this._parseStack.handlerPos-1;switch(this._parseStack.state){case 3:if(!1===i&&l>-1)for(;l>=0&&!0!==(r=a[l](this._params));l--)if(r instanceof Promise)return this._parseStack.handlerPos=l,r;this._parseStack.handlers=[];break;case 4:if(!1===i&&l>-1)for(;l>=0&&!0!==(r=a[l]());l--)if(r instanceof Promise)return this._parseStack.handlerPos=l,r;this._parseStack.handlers=[];break;case 6:if(n=e[this._parseStack.chunkPos],r=this._dcsParser.unhook(24!==n&&26!==n,i))return r;27===n&&(this._parseStack.transition|=1),this._params.reset(),this._params.addParam(0),this._collect=0;break;case 5:if(n=e[this._parseStack.chunkPos],r=this._oscParser.end(24!==n&&26!==n,i))return r;27===n&&(this._parseStack.transition|=1),this._params.reset(),this._params.addParam(0),this._collect=0}this._parseStack.state=0,o=this._parseStack.chunkPos+1,this.precedingCodepoint=0,this.currentState=15&this._parseStack.transition}for(var u=o;u<t;++u){switch(n=e[u],(s=this._transitions.table[this.currentState<<8|(n<160?n:c)])>>4){case 2:for(var h=u+1;;++h){if(h>=t||(n=e[h])<32||n>126&&n<c){this._printHandler(e,u,h),u=h-1;break}if(++h>=t||(n=e[h])<32||n>126&&n<c){this._printHandler(e,u,h),u=h-1;break}if(++h>=t||(n=e[h])<32||n>126&&n<c){this._printHandler(e,u,h),u=h-1;break}if(++h>=t||(n=e[h])<32||n>126&&n<c){this._printHandler(e,u,h),u=h-1;break}}break;case 3:this._executeHandlers[n]?this._executeHandlers[n]():this._executeHandlerFb(n),this.precedingCodepoint=0;break;case 0:break;case 1:if(this._errorHandler({position:u,code:n,currentState:this.currentState,collect:this._collect,params:this._params,abort:!1}).abort)return;break;case 7:for(var f=this._csiHandlers[this._collect<<8|n],d=f?f.length-1:-1;d>=0&&!0!==(r=f[d](this._params));d--)if(r instanceof Promise)return this._preserveStack(3,f,d,s,u),r;d<0&&this._csiHandlerFb(this._collect<<8|n,this._params),this.precedingCodepoint=0;break;case 8:do{switch(n){case 59:this._params.addParam(0);break;case 58:this._params.addSubParam(-1);break;default:this._params.addDigit(n-48)}}while(++u<t&&(n=e[u])>47&&n<60);u--;break;case 9:this._collect<<=8,this._collect|=n;break;case 10:for(var v=this._escHandlers[this._collect<<8|n],_=v?v.length-1:-1;_>=0&&!0!==(r=v[_]());_--)if(r instanceof Promise)return this._preserveStack(4,v,_,s,u),r;_<0&&this._escHandlerFb(this._collect<<8|n),this.precedingCodepoint=0;break;case 11:this._params.reset(),this._params.addParam(0),this._collect=0;break;case 12:this._dcsParser.hook(this._collect<<8|n,this._params);break;case 13:for(var p=u+1;;++p)if(p>=t||24===(n=e[p])||26===n||27===n||n>127&&n<c){this._dcsParser.put(e,u,p),u=p-1;break}break;case 14:if(r=this._dcsParser.unhook(24!==n&&26!==n))return this._preserveStack(6,[],0,s,u),r;27===n&&(s|=1),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingCodepoint=0;break;case 4:this._oscParser.start();break;case 5:for(var g=u+1;;g++)if(g>=t||(n=e[g])<32||n>127&&n<c){this._oscParser.put(e,u,g),u=g-1;break}break;case 6:if(r=this._oscParser.end(24!==n&&26!==n))return this._preserveStack(5,[],0,s,u),r;27===n&&(s|=1),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingCodepoint=0}this.currentState=15&s}}}]),a}(r.Disposable);t.EscapeSequenceParser=l},6242:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.OscHandler=t.OscParser=void 0;var r=i(5770),n=i(482),s=[];t.OscParser=function(){function e(){h(this,e),this._state=0,this._active=s,this._id=-1,this._handlers=Object.create(null),this._handlerFb=function(){},this._stack={paused:!1,loopPosition:0,fallThrough:!1}}return f(e,[{key:"registerHandler",value:function(e,t){void 0===this._handlers[e]&&(this._handlers[e]=[]);var i=this._handlers[e];return i.push(t),{dispose:function(){var e=i.indexOf(t);-1!==e&&i.splice(e,1)}}}},{key:"clearHandler",value:function(e){this._handlers[e]&&delete this._handlers[e]}},{key:"setHandlerFallback",value:function(e){this._handlerFb=e}},{key:"dispose",value:function(){this._handlers=Object.create(null),this._handlerFb=function(){},this._active=s}},{key:"reset",value:function(){if(2===this._state)for(var e=this._stack.paused?this._stack.loopPosition-1:this._active.length-1;e>=0;--e)this._active[e].end(!1);this._stack.paused=!1,this._active=s,this._id=-1,this._state=0}},{key:"_start",value:function(){if(this._active=this._handlers[this._id]||s,this._active.length)for(var e=this._active.length-1;e>=0;e--)this._active[e].start();else this._handlerFb(this._id,"START")}},{key:"_put",value:function(e,t,i){if(this._active.length)for(var r=this._active.length-1;r>=0;r--)this._active[r].put(e,t,i);else this._handlerFb(this._id,"PUT",(0,n.utf32ToString)(e,t,i))}},{key:"start",value:function(){this.reset(),this._state=1}},{key:"put",value:function(e,t,i){if(3!==this._state){if(1===this._state)for(;t<i;){var r=e[t++];if(59===r){this._state=2,this._start();break}if(r<48||57<r)return void(this._state=3);-1===this._id&&(this._id=0),this._id=10*this._id+r-48}2===this._state&&i-t>0&&this._put(e,t,i)}}},{key:"end",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(0!==this._state){if(3!==this._state)if(1===this._state&&this._start(),this._active.length){var i=!1,r=this._active.length-1,n=!1;if(this._stack.paused&&(r=this._stack.loopPosition-1,i=t,n=this._stack.fallThrough,this._stack.paused=!1),!n&&!1===i){for(;r>=0&&!0!==(i=this._active[r].end(e));r--)if(i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!1,i;r--}for(;r>=0;r--)if((i=this._active[r].end(!1))instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!0,i}else this._handlerFb(this._id,"END",e);this._active=s,this._id=-1,this._state=0}}}]),e}(),t.OscHandler=function(){function e(t){h(this,e),this._handler=t,this._data="",this._hitLimit=!1}return f(e,[{key:"start",value:function(){this._data="",this._hitLimit=!1}},{key:"put",value:function(e,t,i){this._hitLimit||(this._data+=(0,n.utf32ToString)(e,t,i),this._data.length>r.PAYLOAD_LIMIT&&(this._data="",this._hitLimit=!0))}},{key:"end",value:function(e){var t=this,i=!1;if(this._hitLimit)i=!1;else if(e&&(i=this._handler(this._data))instanceof Promise)return i.then((function(e){return t._data="",t._hitLimit=!1,e}));return this._data="",this._hitLimit=!1,i}}]),e}()},8742:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Params=void 0;var i=2147483647,r=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:32,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:32;if(h(this,e),this.maxLength=t,this.maxSubParamsLength=i,i>256)throw new Error("maxSubParamsLength must not be greater than 256");this.params=new Int32Array(t),this.length=0,this._subParams=new Int32Array(i),this._subParamsLength=0,this._subParamsIdx=new Uint16Array(t),this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}return f(e,[{key:"clone",value:function(){var t=new e(this.maxLength,this.maxSubParamsLength);return t.params.set(this.params),t.length=this.length,t._subParams.set(this._subParams),t._subParamsLength=this._subParamsLength,t._subParamsIdx.set(this._subParamsIdx),t._rejectDigits=this._rejectDigits,t._rejectSubDigits=this._rejectSubDigits,t._digitIsSub=this._digitIsSub,t}},{key:"toArray",value:function(){for(var e=[],t=0;t<this.length;++t){e.push(this.params[t]);var i=this._subParamsIdx[t]>>8,r=255&this._subParamsIdx[t];r-i>0&&e.push(Array.prototype.slice.call(this._subParams,i,r))}return e}},{key:"reset",value:function(){this.length=0,this._subParamsLength=0,this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}},{key:"addParam",value:function(e){if(this._digitIsSub=!1,this.length>=this.maxLength)this._rejectDigits=!0;else{if(e<-1)throw new Error("values lesser than -1 are not allowed");this._subParamsIdx[this.length]=this._subParamsLength<<8|this._subParamsLength,this.params[this.length++]=e>i?i:e}}},{key:"addSubParam",value:function(e){if(this._digitIsSub=!0,this.length)if(this._rejectDigits||this._subParamsLength>=this.maxSubParamsLength)this._rejectSubDigits=!0;else{if(e<-1)throw new Error("values lesser than -1 are not allowed");this._subParams[this._subParamsLength++]=e>i?i:e,this._subParamsIdx[this.length-1]++}}},{key:"hasSubParams",value:function(e){return(255&this._subParamsIdx[e])-(this._subParamsIdx[e]>>8)>0}},{key:"getSubParams",value:function(e){var t=this._subParamsIdx[e]>>8,i=255&this._subParamsIdx[e];return i-t>0?this._subParams.subarray(t,i):null}},{key:"getSubParamsAll",value:function(){for(var e={},t=0;t<this.length;++t){var i=this._subParamsIdx[t]>>8,r=255&this._subParamsIdx[t];r-i>0&&(e[t]=this._subParams.slice(i,r))}return e}},{key:"addDigit",value:function(e){var t;if(!(this._rejectDigits||!(t=this._digitIsSub?this._subParamsLength:this.length)||this._digitIsSub&&this._rejectSubDigits)){var r=this._digitIsSub?this._subParams:this.params,n=r[t-1];r[t-1]=~n?Math.min(10*n+e,i):e}}}],[{key:"fromArray",value:function(t){var i=new e;if(!t.length)return i;for(var r=Array.isArray(t[0])?1:0;r<t.length;++r){var n=t[r];if(Array.isArray(n))for(var s=0;s<n.length;++s)i.addSubParam(n[s]);else i.addParam(n)}return i}}]),e}();t.Params=r},5741:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.AddonManager=void 0,t.AddonManager=function(){function e(){h(this,e),this._addons=[]}return f(e,[{key:"dispose",value:function(){for(var e=this._addons.length-1;e>=0;e--)this._addons[e].instance.dispose()}},{key:"loadAddon",value:function(e,t){var i=this,r={instance:t,dispose:t.dispose,isDisposed:!1};this._addons.push(r),t.dispose=function(){return i._wrappedAddonDispose(r)},t.activate(e)}},{key:"_wrappedAddonDispose",value:function(e){if(!e.isDisposed){for(var t=-1,i=0;i<this._addons.length;i++)if(this._addons[i]===e){t=i;break}if(-1===t)throw new Error("Could not dispose an addon that has not been loaded");e.isDisposed=!0,e.dispose.apply(e.instance),this._addons.splice(t,1)}}}]),e}()},8771:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BufferApiView=void 0;var r=i(3785),n=i(511);t.BufferApiView=function(){function e(t,i){h(this,e),this._buffer=t,this.type=i}return f(e,[{key:"init",value:function(e){return this._buffer=e,this}},{key:"cursorY",get:function(){return this._buffer.y}},{key:"cursorX",get:function(){return this._buffer.x}},{key:"viewportY",get:function(){return this._buffer.ydisp}},{key:"baseY",get:function(){return this._buffer.ybase}},{key:"length",get:function(){return this._buffer.lines.length}},{key:"getLine",value:function(e){var t=this._buffer.lines.get(e);if(t)return new r.BufferLineApiView(t)}},{key:"getNullCell",value:function(){return new n.CellData}}]),e}()},3785:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BufferLineApiView=void 0;var r=i(511);t.BufferLineApiView=function(){function e(t){h(this,e),this._line=t}return f(e,[{key:"isWrapped",get:function(){return this._line.isWrapped}},{key:"length",get:function(){return this._line.length}},{key:"getCell",value:function(e,t){if(!(e<0||e>=this._line.length))return t?(this._line.loadCell(e,t),t):this._line.loadCell(e,new r.CellData)}},{key:"translateToString",value:function(e,t,i){return this._line.translateToString(e,t,i)}}]),e}()},8285:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.BufferNamespaceApi=void 0;var r=i(8771),n=i(8460);t.BufferNamespaceApi=function(){function e(t){var i=this;h(this,e),this._core=t,this._onBufferChange=new n.EventEmitter,this.onBufferChange=this._onBufferChange.event,this._normal=new r.BufferApiView(this._core.buffers.normal,"normal"),this._alternate=new r.BufferApiView(this._core.buffers.alt,"alternate"),this._core.buffers.onBufferActivate((function(){return i._onBufferChange.fire(i.active)}))}return f(e,[{key:"active",get:function(){if(this._core.buffers.active===this._core.buffers.normal)return this.normal;if(this._core.buffers.active===this._core.buffers.alt)return this.alternate;throw new Error("Active buffer is neither normal nor alternate")}},{key:"normal",get:function(){return this._normal.init(this._core.buffers.normal)}},{key:"alternate",get:function(){return this._alternate.init(this._core.buffers.alt)}}]),e}()},7975:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.ParserApi=void 0,t.ParserApi=function(){function e(t){h(this,e),this._core=t}return f(e,[{key:"registerCsiHandler",value:function(e,t){return this._core.registerCsiHandler(e,(function(e){return t(e.toArray())}))}},{key:"addCsiHandler",value:function(e,t){return this.registerCsiHandler(e,t)}},{key:"registerDcsHandler",value:function(e,t){return this._core.registerDcsHandler(e,(function(e,i){return t(e,i.toArray())}))}},{key:"addDcsHandler",value:function(e,t){return this.registerDcsHandler(e,t)}},{key:"registerEscHandler",value:function(e,t){return this._core.registerEscHandler(e,t)}},{key:"addEscHandler",value:function(e,t){return this.registerEscHandler(e,t)}},{key:"registerOscHandler",value:function(e,t){return this._core.registerOscHandler(e,t)}},{key:"addOscHandler",value:function(e,t){return this.registerOscHandler(e,t)}}]),e}()},7090:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeApi=void 0,t.UnicodeApi=function(){function e(t){h(this,e),this._core=t}return f(e,[{key:"register",value:function(e){this._core.unicodeService.register(e)}},{key:"versions",get:function(){return this._core.unicodeService.versions}},{key:"activeVersion",get:function(){return this._core.unicodeService.activeVersion},set:function(e){this._core.unicodeService.activeVersion=e}}]),e}()},744:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.BufferService=t.MINIMUM_ROWS=t.MINIMUM_COLS=void 0;var s=i(2585),o=i(5295),a=i(8460),c=i(844);t.MINIMUM_COLS=2,t.MINIMUM_ROWS=1;var l=function(e){v(r,e);var i=_(r);function r(e){var n;return h(this,r),(n=i.call(this)).isUserScrolling=!1,n._onResize=n.register(new a.EventEmitter),n.onResize=n._onResize.event,n._onScroll=n.register(new a.EventEmitter),n.onScroll=n._onScroll.event,n.cols=Math.max(e.rawOptions.cols||0,t.MINIMUM_COLS),n.rows=Math.max(e.rawOptions.rows||0,t.MINIMUM_ROWS),n.buffers=n.register(new o.BufferSet(e,d(n))),n}return f(r,[{key:"buffer",get:function(){return this.buffers.active}},{key:"resize",value:function(e,t){this.cols=e,this.rows=t,this.buffers.resize(e,t),this._onResize.fire({cols:e,rows:t})}},{key:"reset",value:function(){this.buffers.reset(),this.isUserScrolling=!1}},{key:"scroll",value:function(e){var t,i=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=this.buffer;(t=this._cachedBlankLine)&&t.length===this.cols&&t.getFg(0)===e.fg&&t.getBg(0)===e.bg||(t=r.getBlankLine(e,i),this._cachedBlankLine=t),t.isWrapped=i;var n=r.ybase+r.scrollTop,s=r.ybase+r.scrollBottom;if(0===r.scrollTop){var o=r.lines.isFull;s===r.lines.length-1?o?r.lines.recycle().copyFrom(t):r.lines.push(t.clone()):r.lines.splice(s+1,0,t.clone()),o?this.isUserScrolling&&(r.ydisp=Math.max(r.ydisp-1,0)):(r.ybase++,this.isUserScrolling||r.ydisp++)}else{var a=s-n+1;r.lines.shiftElements(n+1,a-1,-1),r.lines.set(s,t.clone())}this.isUserScrolling||(r.ydisp=r.ybase),this._onScroll.fire(r.ydisp)}},{key:"scrollLines",value:function(e,t,i){var r=this.buffer;if(e<0){if(0===r.ydisp)return;this.isUserScrolling=!0}else e+r.ydisp>=r.ybase&&(this.isUserScrolling=!1);var n=r.ydisp;r.ydisp=Math.max(Math.min(r.ydisp+e,r.ybase),0),n!==r.ydisp&&(t||this._onScroll.fire(r.ydisp))}},{key:"scrollPages",value:function(e){this.scrollLines(e*(this.rows-1))}},{key:"scrollToTop",value:function(){this.scrollLines(-this.buffer.ydisp)}},{key:"scrollToBottom",value:function(){this.scrollLines(this.buffer.ybase-this.buffer.ydisp)}},{key:"scrollToLine",value:function(e){var t=e-this.buffer.ydisp;0!==t&&this.scrollLines(t)}}]),r}(c.Disposable);l=r([n(0,s.IOptionsService)],l),t.BufferService=l},7994:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.CharsetService=void 0,t.CharsetService=function(){function e(){h(this,e),this.glevel=0,this._charsets=[]}return f(e,[{key:"reset",value:function(){this.charset=void 0,this._charsets=[],this.glevel=0}},{key:"setgLevel",value:function(e){this.glevel=e,this.charset=this._charsets[e]}},{key:"setgCharset",value:function(e,t){this._charsets[e]=t,this.glevel===e&&(this.charset=t)}}]),e}()},1753:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CoreMouseService=void 0;var s=i(2585),o=i(8460),a=i(844),c={NONE:{events:0,restrict:function(){return!1}},X10:{events:1,restrict:function(e){return 4!==e.button&&1===e.action&&(e.ctrl=!1,e.alt=!1,e.shift=!1,!0)}},VT200:{events:19,restrict:function(e){return 32!==e.action}},DRAG:{events:23,restrict:function(e){return 32!==e.action||3!==e.button}},ANY:{events:31,restrict:function(e){return!0}}};function l(e,t){var i=(e.ctrl?16:0)|(e.shift?4:0)|(e.alt?8:0);return 4===e.button?(i|=64,i|=e.action):(i|=3&e.button,4&e.button&&(i|=64),8&e.button&&(i|=128),32===e.action?i|=32:0!==e.action||t||(i|=3)),i}var u=String.fromCharCode,d={DEFAULT:function(e){var t=[l(e,!1)+32,e.col+32,e.row+32];return t[0]>255||t[1]>255||t[2]>255?"":"\x1b[M".concat(u(t[0])).concat(u(t[1])).concat(u(t[2]))},SGR:function(e){var t=0===e.action&&4!==e.button?"m":"M";return"\x1b[<".concat(l(e,!0),";").concat(e.col,";").concat(e.row).concat(t)},SGR_PIXELS:function(e){var t=0===e.action&&4!==e.button?"m":"M";return"\x1b[<".concat(l(e,!0),";").concat(e.x,";").concat(e.y).concat(t)}},p=function(e){v(i,e);var t=_(i);function i(e,r){var n;h(this,i),(n=t.call(this))._bufferService=e,n._coreService=r,n._protocols={},n._encodings={},n._activeProtocol="",n._activeEncoding="",n._lastEvent=null,n._onProtocolChange=n.register(new o.EventEmitter),n.onProtocolChange=n._onProtocolChange.event;for(var s=0,a=Object.keys(c);s<a.length;s++){var l=a[s];n.addProtocol(l,c[l])}for(var u=0,f=Object.keys(d);u<f.length;u++){var v=f[u];n.addEncoding(v,d[v])}return n.reset(),n}return f(i,[{key:"addProtocol",value:function(e,t){this._protocols[e]=t}},{key:"addEncoding",value:function(e,t){this._encodings[e]=t}},{key:"activeProtocol",get:function(){return this._activeProtocol},set:function(e){if(!this._protocols[e])throw new Error('unknown protocol "'.concat(e,'"'));this._activeProtocol=e,this._onProtocolChange.fire(this._protocols[e].events)}},{key:"areMouseEventsActive",get:function(){return 0!==this._protocols[this._activeProtocol].events}},{key:"activeEncoding",get:function(){return this._activeEncoding},set:function(e){if(!this._encodings[e])throw new Error('unknown encoding "'.concat(e,'"'));this._activeEncoding=e}},{key:"reset",value:function(){this.activeProtocol="NONE",this.activeEncoding="DEFAULT",this._lastEvent=null}},{key:"triggerMouseEvent",value:function(e){if(e.col<0||e.col>=this._bufferService.cols||e.row<0||e.row>=this._bufferService.rows)return!1;if(4===e.button&&32===e.action)return!1;if(3===e.button&&32!==e.action)return!1;if(4!==e.button&&(2===e.action||3===e.action))return!1;if(e.col++,e.row++,32===e.action&&this._lastEvent&&this._equalEvents(this._lastEvent,e,"SGR_PIXELS"===this._activeEncoding))return!1;if(!this._protocols[this._activeProtocol].restrict(e))return!1;var t=this._encodings[this._activeEncoding](e);return t&&("DEFAULT"===this._activeEncoding?this._coreService.triggerBinaryEvent(t):this._coreService.triggerDataEvent(t,!0)),this._lastEvent=e,!0}},{key:"explainEvents",value:function(e){return{down:!!(1&e),up:!!(2&e),drag:!!(4&e),move:!!(8&e),wheel:!!(16&e)}}},{key:"_equalEvents",value:function(e,t,i){if(i){if(e.x!==t.x)return!1;if(e.y!==t.y)return!1}else{if(e.col!==t.col)return!1;if(e.row!==t.row)return!1}return e.button===t.button&&e.action===t.action&&e.ctrl===t.ctrl&&e.alt===t.alt&&e.shift===t.shift}}]),i}(a.Disposable);p=r([n(0,s.IBufferService),n(1,s.ICoreService)],p),t.CoreMouseService=p},6975:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.CoreService=void 0;var s=i(2585),o=i(8460),a=i(1439),c=i(844),l=Object.freeze({insertMode:!1}),u=Object.freeze({applicationCursorKeys:!1,applicationKeypad:!1,bracketedPasteMode:!1,origin:!1,reverseWraparound:!1,sendFocus:!1,wraparound:!0}),d=function(e){v(i,e);var t=_(i);function i(e,r,n){var s;return h(this,i),(s=t.call(this))._bufferService=e,s._logService=r,s._optionsService=n,s.isCursorInitialized=!1,s.isCursorHidden=!1,s._onData=s.register(new o.EventEmitter),s.onData=s._onData.event,s._onUserInput=s.register(new o.EventEmitter),s.onUserInput=s._onUserInput.event,s._onBinary=s.register(new o.EventEmitter),s.onBinary=s._onBinary.event,s._onRequestScrollToBottom=s.register(new o.EventEmitter),s.onRequestScrollToBottom=s._onRequestScrollToBottom.event,s.modes=(0,a.clone)(l),s.decPrivateModes=(0,a.clone)(u),s}return f(i,[{key:"reset",value:function(){this.modes=(0,a.clone)(l),this.decPrivateModes=(0,a.clone)(u)}},{key:"triggerDataEvent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!this._optionsService.rawOptions.disableStdin){var i=this._bufferService.buffer;t&&this._optionsService.rawOptions.scrollOnUserInput&&i.ybase!==i.ydisp&&this._onRequestScrollToBottom.fire(),t&&this._onUserInput.fire(),this._logService.debug('sending data "'.concat(e,'"'),(function(){return e.split("").map((function(e){return e.charCodeAt(0)}))})),this._onData.fire(e)}}},{key:"triggerBinaryEvent",value:function(e){this._optionsService.rawOptions.disableStdin||(this._logService.debug('sending binary "'.concat(e,'"'),(function(){return e.split("").map((function(e){return e.charCodeAt(0)}))})),this._onBinary.fire(e))}}]),i}(c.Disposable);d=r([n(0,s.IBufferService),n(1,s.ILogService),n(2,s.IOptionsService)],d),t.CoreService=d},9074:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.DecorationService=void 0;var r=i(8055),s=i(8460),o=i(844),l=i(6106),d=0,p=0,g=function(e){v(i,e);var t=_(i);function i(){var e;return h(this,i),(e=t.call(this))._decorations=new l.SortedList((function(e){return null==e?void 0:e.marker.line})),e._onDecorationRegistered=e.register(new s.EventEmitter),e.onDecorationRegistered=e._onDecorationRegistered.event,e._onDecorationRemoved=e.register(new s.EventEmitter),e.onDecorationRemoved=e._onDecorationRemoved.event,e.register((0,o.toDisposable)((function(){var t,i=u(e._decorations.values());try{for(i.s();!(t=i.n()).done;){var r=t.value;e._onDecorationRemoved.fire(r)}}catch(n){i.e(n)}finally{i.f()}e.reset()}))),e}return f(i,[{key:"decorations",get:function(){return this._decorations.values()}},{key:"registerDecoration",value:function(e){var t=this;if(!e.marker.isDisposed){var i=new m(e);if(i){var r=i.marker.onDispose((function(){return i.dispose()}));i.onDispose((function(){i&&(t._decorations.delete(i)&&t._onDecorationRemoved.fire(i),r.dispose())})),this._decorations.insert(i),this._onDecorationRegistered.fire(i)}return i}}},{key:"reset",value:function(){var e,t=u(this._decorations.values());try{for(t.s();!(e=t.n()).done;)e.value.dispose()}catch(i){t.e(i)}finally{t.f()}this._decorations.clear()}},{key:"getDecorationsAtCell",value:n().mark((function e(t,i,r){var s,o,a,c,l,h,f,d;return n().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:c=0,l=0,h=u(this._decorations.getKeyIterator(i)),e.prev=2,h.s();case 4:if((f=h.n()).done){e.next=14;break}if(d=f.value,c=null!==(s=d.options.x)&&void 0!==s?s:0,l=c+(null!==(o=d.options.width)&&void 0!==o?o:1),e.t0=t>=c&&t<l&&(!r||(null!==(a=d.options.layer)&&void 0!==a?a:"bottom")===r),!e.t0){e.next=12;break}return e.next=12,d;case 12:e.next=4;break;case 14:e.next=19;break;case 16:e.prev=16,e.t1=e.catch(2),h.e(e.t1);case 19:return e.prev=19,h.f(),e.finish(19);case 22:case"end":return e.stop()}}),e,this,[[2,16,19,22]])}))},{key:"forEachDecorationAtCell",value:function(e,t,i,r){this._decorations.forEachByKey(t,(function(t){var n,s,o;d=null!==(n=t.options.x)&&void 0!==n?n:0,p=d+(null!==(s=t.options.width)&&void 0!==s?s:1),e>=d&&e<p&&(!i||(null!==(o=t.options.layer)&&void 0!==o?o:"bottom")===i)&&r(t)}))}},{key:"dispose",value:function(){var e,t=u(this._decorations.values());try{for(t.s();!(e=t.n()).done;){var i=e.value;this._onDecorationRemoved.fire(i)}}catch(r){t.e(r)}finally{t.f()}this.reset()}}]),i}(o.Disposable);t.DecorationService=g;var m=function(e){v(i,e);var t=_(i);function i(e){var r;return h(this,i),(r=t.call(this)).options=e,r.isDisposed=!1,r.onRenderEmitter=r.register(new s.EventEmitter),r.onRender=r.onRenderEmitter.event,r._onDispose=r.register(new s.EventEmitter),r.onDispose=r._onDispose.event,r._cachedBg=null,r._cachedFg=null,r.marker=e.marker,r.options.overviewRulerOptions&&!r.options.overviewRulerOptions.position&&(r.options.overviewRulerOptions.position="full"),r}return f(i,[{key:"backgroundColorRGB",get:function(){return null===this._cachedBg&&(this.options.backgroundColor?this._cachedBg=r.css.toColor(this.options.backgroundColor):this._cachedBg=void 0),this._cachedBg}},{key:"foregroundColorRGB",get:function(){return null===this._cachedFg&&(this.options.foregroundColor?this._cachedFg=r.css.toColor(this.options.foregroundColor):this._cachedFg=void 0),this._cachedFg}},{key:"dispose",value:function(){this._onDispose.fire(),a(c(i.prototype),"dispose",this).call(this)}}]),i}(o.Disposable)},4348:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.InstantiationService=t.ServiceCollection=void 0;var n=i(2585),s=i(8343),o=function(){function e(){h(this,e),this._entries=new Map;for(var t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];for(var n=0,s=i;n<s.length;n++){var o=l(s[n],2),a=o[0],c=o[1];this.set(a,c)}}return f(e,[{key:"set",value:function(e,t){var i=this._entries.get(e);return this._entries.set(e,t),i}},{key:"forEach",value:function(e){var t,i=u(this._entries.entries());try{for(i.s();!(t=i.n()).done;){var r=l(t.value,2);e(r[0],r[1])}}catch(n){i.e(n)}finally{i.f()}}},{key:"has",value:function(e){return this._entries.has(e)}},{key:"get",value:function(e){return this._entries.get(e)}}]),e}();t.ServiceCollection=o,t.InstantiationService=function(){function e(){h(this,e),this._services=new o,this._services.set(n.IInstantiationService,this)}return f(e,[{key:"setService",value:function(e,t){this._services.set(e,t)}},{key:"getService",value:function(e){return this._services.get(e)}},{key:"createInstance",value:function(e){var t,i=(0,s.getServiceDependencies)(e).sort((function(e,t){return e.index-t.index})),n=[],o=u(i);try{for(o.s();!(t=o.n()).done;){var a=t.value,c=this._services.get(a.id);if(!c)throw new Error("[createInstance] ".concat(e.name," depends on UNKNOWN service ").concat(a.id,"."));n.push(c)}}catch(v){o.e(v)}finally{o.f()}for(var l=arguments.length,h=new Array(l>1?l-1:0),f=1;f<l;f++)h[f-1]=arguments[f];var d=i.length>0?i[0].index:h.length;if(h.length!==d)throw new Error("[createInstance] First service dependency of ".concat(e.name," at position ").concat(d+1," conflicts with ").concat(h.length," static arguments"));return r(e,[].concat(h,n))}}]),e}()},7866:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.LogService=void 0;var s=i(844),a=i(2585),c={debug:a.LogLevelEnum.DEBUG,info:a.LogLevelEnum.INFO,warn:a.LogLevelEnum.WARN,error:a.LogLevelEnum.ERROR,off:a.LogLevelEnum.OFF},l=function(e){v(i,e);var t=_(i);function i(e){var r;return h(this,i),(r=t.call(this))._optionsService=e,r.logLevel=a.LogLevelEnum.OFF,r._updateLogLevel(),r.register(r._optionsService.onSpecificOptionChange("logLevel",(function(){return r._updateLogLevel()}))),r}return f(i,[{key:"_updateLogLevel",value:function(){this.logLevel=c[this._optionsService.rawOptions.logLevel]}},{key:"_evalLazyOptionalParams",value:function(e){for(var t=0;t<e.length;t++)"function"==typeof e[t]&&(e[t]=e[t]())}},{key:"_log",value:function(e,t,i){this._evalLazyOptionalParams(i),e.call.apply(e,[console,"xterm.js: "+t].concat(o(i)))}},{key:"debug",value:function(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),r=1;r<t;r++)i[r-1]=arguments[r];this.logLevel<=a.LogLevelEnum.DEBUG&&this._log(console.log,e,i)}},{key:"info",value:function(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),r=1;r<t;r++)i[r-1]=arguments[r];this.logLevel<=a.LogLevelEnum.INFO&&this._log(console.info,e,i)}},{key:"warn",value:function(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),r=1;r<t;r++)i[r-1]=arguments[r];this.logLevel<=a.LogLevelEnum.WARN&&this._log(console.warn,e,i)}},{key:"error",value:function(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),r=1;r<t;r++)i[r-1]=arguments[r];this.logLevel<=a.LogLevelEnum.ERROR&&this._log(console.error,e,i)}}]),i}(s.Disposable);l=r([n(0,a.IOptionsService)],l),t.LogService=l},7302:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.OptionsService=t.DEFAULT_OPTIONS=void 0;var r=i(8460),n=i(6114),s=i(844);t.DEFAULT_OPTIONS={cols:80,rows:24,cursorBlink:!1,cursorStyle:"block",cursorWidth:1,customGlyphs:!0,drawBoldTextInBrightColors:!0,fastScrollModifier:"alt",fastScrollSensitivity:5,fontFamily:"courier-new, courier, monospace",fontSize:15,fontWeight:"normal",fontWeightBold:"bold",lineHeight:1,letterSpacing:0,linkHandler:null,logLevel:"info",scrollback:1e3,scrollOnUserInput:!0,scrollSensitivity:1,screenReaderMode:!1,smoothScrollDuration:0,macOptionIsMeta:!1,macOptionClickForcesSelection:!1,minimumContrastRatio:1,disableStdin:!1,allowProposedApi:!1,allowTransparency:!1,tabStopWidth:8,theme:{},rightClickSelectsWord:n.isMac,windowOptions:{},windowsMode:!1,wordSeparator:" ()[]{}',\"`",altClickMovesCursor:!0,convertEol:!1,termName:"xterm",cancelEvents:!1,overviewRulerWidth:0};var o=["normal","bold","100","200","300","400","500","600","700","800","900"],a=function(e){v(n,e);var i=_(n);function n(e){var s;h(this,n),(s=i.call(this))._onOptionChange=s.register(new r.EventEmitter),s.onOptionChange=s._onOptionChange.event;var o=Object.assign({},t.DEFAULT_OPTIONS);for(var a in e)if(a in o)try{var c=e[a];o[a]=s._sanitizeAndValidateOption(a,c)}catch(e){console.error(e)}return s.rawOptions=o,s.options=Object.assign({},o),s._setupOptions(),s}return f(n,[{key:"onSpecificOptionChange",value:function(e,t){var i=this;return this.onOptionChange((function(r){r===e&&t(i.rawOptions[e])}))}},{key:"onMultipleOptionChange",value:function(e,t){return this.onOptionChange((function(i){-1!==e.indexOf(i)&&t()}))}},{key:"_setupOptions",value:function(){var e=this,i=function(i){if(!(i in t.DEFAULT_OPTIONS))throw new Error('No option with key "'.concat(i,'"'));return e.rawOptions[i]},r=function(i,r){if(!(i in t.DEFAULT_OPTIONS))throw new Error('No option with key "'.concat(i,'"'));r=e._sanitizeAndValidateOption(i,r),e.rawOptions[i]!==r&&(e.rawOptions[i]=r,e._onOptionChange.fire(i))};for(var n in this.rawOptions){var s={get:i.bind(this,n),set:r.bind(this,n)};Object.defineProperty(this.options,n,s)}}},{key:"_sanitizeAndValidateOption",value:function(e,i){switch(e){case"cursorStyle":if(i||(i=t.DEFAULT_OPTIONS[e]),!function(e){return"block"===e||"underline"===e||"bar"===e}(i))throw new Error('"'.concat(i,'" is not a valid value for ').concat(e));break;case"wordSeparator":i||(i=t.DEFAULT_OPTIONS[e]);break;case"fontWeight":case"fontWeightBold":if("number"==typeof i&&1<=i&&i<=1e3)break;i=o.includes(i)?i:t.DEFAULT_OPTIONS[e];break;case"cursorWidth":i=Math.floor(i);case"lineHeight":case"tabStopWidth":if(i<1)throw new Error("".concat(e," cannot be less than 1, value: ").concat(i));break;case"minimumContrastRatio":i=Math.max(1,Math.min(21,Math.round(10*i)/10));break;case"scrollback":if((i=Math.min(i,4294967295))<0)throw new Error("".concat(e," cannot be less than 0, value: ").concat(i));break;case"fastScrollSensitivity":case"scrollSensitivity":if(i<=0)throw new Error("".concat(e," cannot be less than or equal to 0, value: ").concat(i));case"rows":case"cols":if(!i&&0!==i)throw new Error("".concat(e," must be numeric, value: ").concat(i))}return i}}]),n}(s.Disposable);t.OptionsService=a},2660:function(e,t,i){var r=this&&this.__decorate||function(e,t,i,r){var n,s=arguments.length,o=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(e,t,i,r);else for(var a=e.length-1;a>=0;a--)(n=e[a])&&(o=(s<3?n(o):s>3?n(t,i,o):n(t,i))||o);return s>3&&o&&Object.defineProperty(t,i,o),o},n=this&&this.__param||function(e,t){return function(i,r){t(i,r,e)}};Object.defineProperty(t,"__esModule",{value:!0}),t.OscLinkService=void 0;var s=i(2585),o=function(){function e(t){h(this,e),this._bufferService=t,this._nextId=1,this._entriesWithId=new Map,this._dataByLinkId=new Map}return f(e,[{key:"registerLink",value:function(e){var t=this,i=this._bufferService.buffer;if(void 0===e.id){var r=i.addMarker(i.ybase+i.y),n={data:e,id:this._nextId++,lines:[r]};return r.onDispose((function(){return t._removeMarkerFromLink(n,r)})),this._dataByLinkId.set(n.id,n),n.id}var s=e,o=this._getEntryIdKey(s),a=this._entriesWithId.get(o);if(a)return this.addLineToLink(a.id,i.ybase+i.y),a.id;var c=i.addMarker(i.ybase+i.y),l={id:this._nextId++,key:this._getEntryIdKey(s),data:s,lines:[c]};return c.onDispose((function(){return t._removeMarkerFromLink(l,c)})),this._entriesWithId.set(l.key,l),this._dataByLinkId.set(l.id,l),l.id}},{key:"addLineToLink",value:function(e,t){var i=this,r=this._dataByLinkId.get(e);if(r&&r.lines.every((function(e){return e.line!==t}))){var n=this._bufferService.buffer.addMarker(t);r.lines.push(n),n.onDispose((function(){return i._removeMarkerFromLink(r,n)}))}}},{key:"getLinkData",value:function(e){var t;return null===(t=this._dataByLinkId.get(e))||void 0===t?void 0:t.data}},{key:"_getEntryIdKey",value:function(e){return"".concat(e.id,";;").concat(e.uri)}},{key:"_removeMarkerFromLink",value:function(e,t){var i=e.lines.indexOf(t);-1!==i&&(e.lines.splice(i,1),0===e.lines.length&&(void 0!==e.data.id&&this._entriesWithId.delete(e.key),this._dataByLinkId.delete(e.id)))}}]),e}();o=r([n(0,s.IBufferService)],o),t.OscLinkService=o},8343:function(e,t){function i(e,t,i){t.di$target===t?t.di$dependencies.push({id:e,index:i}):(t.di$dependencies=[{id:e,index:i}],t.di$target=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.createDecorator=t.getServiceDependencies=t.serviceRegistry=void 0,t.serviceRegistry=new Map,t.getServiceDependencies=function(e){return e.di$dependencies||[]},t.createDecorator=function(e){if(t.serviceRegistry.has(e))return t.serviceRegistry.get(e);var r=function e(t,r,n){if(3!==arguments.length)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");i(e,t,n)};return r.toString=function(){return e},t.serviceRegistry.set(e,r),r}},2585:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.IDecorationService=t.IUnicodeService=t.IOscLinkService=t.IOptionsService=t.ILogService=t.LogLevelEnum=t.IInstantiationService=t.ICharsetService=t.ICoreService=t.ICoreMouseService=t.IBufferService=void 0;var r,n=i(8343);t.IBufferService=(0,n.createDecorator)("BufferService"),t.ICoreMouseService=(0,n.createDecorator)("CoreMouseService"),t.ICoreService=(0,n.createDecorator)("CoreService"),t.ICharsetService=(0,n.createDecorator)("CharsetService"),t.IInstantiationService=(0,n.createDecorator)("InstantiationService"),(r=t.LogLevelEnum||(t.LogLevelEnum={}))[r.DEBUG=0]="DEBUG",r[r.INFO=1]="INFO",r[r.WARN=2]="WARN",r[r.ERROR=3]="ERROR",r[r.OFF=4]="OFF",t.ILogService=(0,n.createDecorator)("LogService"),t.IOptionsService=(0,n.createDecorator)("OptionsService"),t.IOscLinkService=(0,n.createDecorator)("OscLinkService"),t.IUnicodeService=(0,n.createDecorator)("UnicodeService"),t.IDecorationService=(0,n.createDecorator)("DecorationService")},1480:function(e,t,i){Object.defineProperty(t,"__esModule",{value:!0}),t.UnicodeService=void 0;var r=i(8460),n=i(225);t.UnicodeService=function(){function e(){h(this,e),this._providers=Object.create(null),this._active="",this._onChange=new r.EventEmitter,this.onChange=this._onChange.event;var t=new n.UnicodeV6;this.register(t),this._active=t.version,this._activeProvider=t}return f(e,[{key:"dispose",value:function(){this._onChange.dispose()}},{key:"versions",get:function(){return Object.keys(this._providers)}},{key:"activeVersion",get:function(){return this._active},set:function(e){if(!this._providers[e])throw new Error('unknown Unicode version "'.concat(e,'"'));this._active=e,this._activeProvider=this._providers[e],this._onChange.fire(e)}},{key:"register",value:function(e){this._providers[e.version]=e}},{key:"wcwidth",value:function(e){return this._activeProvider.wcwidth(e)}},{key:"getStringCellWidth",value:function(e){for(var t=0,i=e.length,r=0;r<i;++r){var n=e.charCodeAt(r);if(55296<=n&&n<=56319){if(++r>=i)return t+this.wcwidth(n);var s=e.charCodeAt(r);56320<=s&&s<=57343?n=1024*(n-55296)+s-56320+65536:t+=this.wcwidth(s)}t+=this.wcwidth(n)}return t}}]),e}()}},t={};function i(r){var n=t[r];if(void 0!==n)return n.exports;var s=t[r]={exports:{}};return e[r].call(s.exports,s,s.exports,i),s.exports}var p={};return function(){var e=p;Object.defineProperty(e,"__esModule",{value:!0}),e.Terminal=void 0;var t=i(3236),r=i(9042),n=i(7975),s=i(7090),o=i(5741),a=i(8285),c=["cols","rows"];e.Terminal=function(){function e(i){var r=this;h(this,e),this._core=new t.Terminal(i),this._addonManager=new o.AddonManager,this._publicOptions=Object.assign({},this._core.options);var n=function(e){return r._core.options[e]},s=function(e,t){r._checkReadonlyOptions(e),r._core.options[e]=t};for(var a in this._core.options){var c={get:n.bind(this,a),set:s.bind(this,a)};Object.defineProperty(this._publicOptions,a,c)}}return f(e,[{key:"_checkReadonlyOptions",value:function(e){if(c.includes(e))throw new Error('Option "'.concat(e,'" can only be set in the constructor'))}},{key:"_checkProposedApi",value:function(){if(!this._core.optionsService.rawOptions.allowProposedApi)throw new Error("You must set the allowProposedApi option to true to use proposed API")}},{key:"onBell",get:function(){return this._core.onBell}},{key:"onBinary",get:function(){return this._core.onBinary}},{key:"onCursorMove",get:function(){return this._core.onCursorMove}},{key:"onData",get:function(){return this._core.onData}},{key:"onKey",get:function(){return this._core.onKey}},{key:"onLineFeed",get:function(){return this._core.onLineFeed}},{key:"onRender",get:function(){return this._core.onRender}},{key:"onResize",get:function(){return this._core.onResize}},{key:"onScroll",get:function(){return this._core.onScroll}},{key:"onSelectionChange",get:function(){return this._core.onSelectionChange}},{key:"onTitleChange",get:function(){return this._core.onTitleChange}},{key:"onWriteParsed",get:function(){return this._core.onWriteParsed}},{key:"element",get:function(){return this._core.element}},{key:"parser",get:function(){return this._parser||(this._parser=new n.ParserApi(this._core)),this._parser}},{key:"unicode",get:function(){return this._checkProposedApi(),new s.UnicodeApi(this._core)}},{key:"textarea",get:function(){return this._core.textarea}},{key:"rows",get:function(){return this._core.rows}},{key:"cols",get:function(){return this._core.cols}},{key:"buffer",get:function(){return this._buffer||(this._buffer=new a.BufferNamespaceApi(this._core)),this._buffer}},{key:"markers",get:function(){return this._checkProposedApi(),this._core.markers}},{key:"modes",get:function(){var e=this._core.coreService.decPrivateModes,t="none";switch(this._core.coreMouseService.activeProtocol){case"X10":t="x10";break;case"VT200":t="vt200";break;case"DRAG":t="drag";break;case"ANY":t="any"}return{applicationCursorKeysMode:e.applicationCursorKeys,applicationKeypadMode:e.applicationKeypad,bracketedPasteMode:e.bracketedPasteMode,insertMode:this._core.coreService.modes.insertMode,mouseTrackingMode:t,originMode:e.origin,reverseWraparoundMode:e.reverseWraparound,sendFocusMode:e.sendFocus,wraparoundMode:e.wraparound}}},{key:"options",get:function(){return this._publicOptions},set:function(e){for(var t in e)this._publicOptions[t]=e[t]}},{key:"blur",value:function(){this._core.blur()}},{key:"focus",value:function(){this._core.focus()}},{key:"resize",value:function(e,t){this._verifyIntegers(e,t),this._core.resize(e,t)}},{key:"open",value:function(e){this._core.open(e)}},{key:"attachCustomKeyEventHandler",value:function(e){this._core.attachCustomKeyEventHandler(e)}},{key:"registerLinkProvider",value:function(e){return this._core.registerLinkProvider(e)}},{key:"registerCharacterJoiner",value:function(e){return this._checkProposedApi(),this._core.registerCharacterJoiner(e)}},{key:"deregisterCharacterJoiner",value:function(e){this._checkProposedApi(),this._core.deregisterCharacterJoiner(e)}},{key:"registerMarker",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return this._verifyIntegers(e),this._core.addMarker(e)}},{key:"registerDecoration",value:function(e){var t,i,r;return this._checkProposedApi(),this._verifyPositiveIntegers(null!==(t=e.x)&&void 0!==t?t:0,null!==(i=e.width)&&void 0!==i?i:0,null!==(r=e.height)&&void 0!==r?r:0),this._core.registerDecoration(e)}},{key:"hasSelection",value:function(){return this._core.hasSelection()}},{key:"select",value:function(e,t,i){this._verifyIntegers(e,t,i),this._core.select(e,t,i)}},{key:"getSelection",value:function(){return this._core.getSelection()}},{key:"getSelectionPosition",value:function(){return this._core.getSelectionPosition()}},{key:"clearSelection",value:function(){this._core.clearSelection()}},{key:"selectAll",value:function(){this._core.selectAll()}},{key:"selectLines",value:function(e,t){this._verifyIntegers(e,t),this._core.selectLines(e,t)}},{key:"dispose",value:function(){this._addonManager.dispose(),this._core.dispose()}},{key:"scrollLines",value:function(e){this._verifyIntegers(e),this._core.scrollLines(e)}},{key:"scrollPages",value:function(e){this._verifyIntegers(e),this._core.scrollPages(e)}},{key:"scrollToTop",value:function(){this._core.scrollToTop()}},{key:"scrollToBottom",value:function(){this._core.scrollToBottom()}},{key:"scrollToLine",value:function(e){this._verifyIntegers(e),this._core.scrollToLine(e)}},{key:"clear",value:function(){this._core.clear()}},{key:"write",value:function(e,t){this._core.write(e,t)}},{key:"writeln",value:function(e,t){this._core.write(e),this._core.write("\r\n",t)}},{key:"paste",value:function(e){this._core.paste(e)}},{key:"refresh",value:function(e,t){this._verifyIntegers(e,t),this._core.refresh(e,t)}},{key:"reset",value:function(){this._core.reset()}},{key:"clearTextureAtlas",value:function(){this._core.clearTextureAtlas()}},{key:"loadAddon",value:function(e){return this._addonManager.loadAddon(this,e)}},{key:"_verifyIntegers",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++){var s=n[r];if(s===1/0||isNaN(s)||s%1!=0)throw new Error("This API only accepts integers")}}},{key:"_verifyPositiveIntegers",value:function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];for(var r=0,n=t;r<n.length;r++){var s=n[r];if(s&&(s===1/0||isNaN(s)||s%1!=0||s<0))throw new Error("This API only accepts positive integers")}}}],[{key:"strings",get:function(){return r}}]),e}()}(),p}()},3897:function(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,r=new Array(t);i<t;i++)r[i]=e[i];return r},e.exports.__esModule=!0,e.exports.default=e.exports},5372:function(e){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},3405:function(e,t,i){var r=i(3897);e.exports=function(e){if(Array.isArray(e))return r(e)},e.exports.__esModule=!0,e.exports.default=e.exports},6115:function(e){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},6690:function(e){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},3515:function(e,t,i){var r=i(6015),n=i(9617);function s(t,i,o){return n()?(e.exports=s=Reflect.construct.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=s=function(e,t,i){var n=[null];n.push.apply(n,t);var s=new(Function.bind.apply(e,n));return i&&r(s,i.prototype),s},e.exports.__esModule=!0,e.exports.default=e.exports),s.apply(null,arguments)}e.exports=s,e.exports.__esModule=!0,e.exports.default=e.exports},9728:function(e,t,i){var r=i(4062);function n(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,r(n.key),n)}}e.exports=function(e,t,i){return t&&n(e.prototype,t),i&&n(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports.default=e.exports},4704:function(e,t,i){var r=i(6116);e.exports=function(e,t){var i="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!i){if(Array.isArray(e)||(i=r(e))||t&&e&&"number"===typeof e.length){i&&(e=i);var n=0,s=function(){};return{s:s,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,c=!1;return{s:function(){i=i.call(e)},n:function(){var e=i.next();return a=e.done,e},e:function(e){c=!0,o=e},f:function(){try{a||null==i.return||i.return()}finally{if(c)throw o}}}},e.exports.__esModule=!0,e.exports.default=e.exports},6389:function(e,t,i){var r=i(4968),n=i(9617),s=i(4993);e.exports=function(e){var t=n();return function(){var i,n=r(e);if(t){var o=r(this).constructor;i=Reflect.construct(n,arguments,o)}else i=n.apply(this,arguments);return s(this,i)}},e.exports.__esModule=!0,e.exports.default=e.exports},1588:function(e,t,i){var r=i(1753);function n(){return"undefined"!==typeof Reflect&&Reflect.get?(e.exports=n=Reflect.get.bind(),e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=n=function(e,t,i){var n=r(e,t);if(n){var s=Object.getOwnPropertyDescriptor(n,t);return s.get?s.get.call(arguments.length<3?e:i):s.value}},e.exports.__esModule=!0,e.exports.default=e.exports),n.apply(this,arguments)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},4968:function(e){function t(i){return e.exports=t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,t(i)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},1655:function(e,t,i){var r=i(6015);e.exports=function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},9617:function(e){e.exports=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.__esModule=!0,e.exports.default=e.exports},9498:function(e){e.exports=function(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports},8872:function(e){e.exports=function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var r,n,s,o,a=[],c=!0,l=!1;try{if(s=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;c=!1}else for(;!(c=(r=s.call(i)).done)&&(a.push(r.value),a.length!==t);c=!0);}catch(u){l=!0,n=u}finally{try{if(!c&&null!=i.return&&(o=i.return(),Object(o)!==o))return}finally{if(l)throw n}}return a}},e.exports.__esModule=!0,e.exports.default=e.exports},2218:function(e){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},2281:function(e){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},4993:function(e,t,i){var r=i(8698).default,n=i(6115);e.exports=function(e,t){if(t&&("object"===r(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return n(e)},e.exports.__esModule=!0,e.exports.default=e.exports},7061:function(e,t,i){var r=i(8698).default;function n(){"use strict";e.exports=n=function(){return t},e.exports.__esModule=!0,e.exports.default=e.exports;var t={},i=Object.prototype,s=i.hasOwnProperty,o=Object.defineProperty||function(e,t,i){e[t]=i.value},a="function"==typeof Symbol?Symbol:{},c=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function h(e,t,i){return Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{h({},"")}catch(D){h=function(e,t,i){return e[t]=i}}function f(e,t,i,r){var n=t&&t.prototype instanceof _?t:_,s=Object.create(n.prototype),a=new R(r||[]);return o(s,"_invoke",{value:k(e,i,a)}),s}function d(e,t,i){try{return{type:"normal",arg:e.call(t,i)}}catch(D){return{type:"throw",arg:D}}}t.wrap=f;var v={};function _(){}function p(){}function g(){}var m={};h(m,c,(function(){return this}));var y=Object.getPrototypeOf,b=y&&y(y(M([])));b&&b!==i&&s.call(b,c)&&(m=b);var C=g.prototype=_.prototype=Object.create(m);function S(e){["next","throw","return"].forEach((function(t){h(e,t,(function(e){return this._invoke(t,e)}))}))}function w(e,t){function i(n,o,a,c){var l=d(e[n],e,o);if("throw"!==l.type){var u=l.arg,h=u.value;return h&&"object"==r(h)&&s.call(h,"__await")?t.resolve(h.__await).then((function(e){i("next",e,a,c)}),(function(e){i("throw",e,a,c)})):t.resolve(h).then((function(e){u.value=e,a(u)}),(function(e){return i("throw",e,a,c)}))}c(l.arg)}var n;o(this,"_invoke",{value:function(e,r){function s(){return new t((function(t,n){i(e,r,t,n)}))}return n=n?n.then(s,s):s()}})}function k(e,t,i){var r="suspendedStart";return function(n,s){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===n)throw s;return A()}for(i.method=n,i.arg=s;;){var o=i.delegate;if(o){var a=x(o,i);if(a){if(a===v)continue;return a}}if("next"===i.method)i.sent=i._sent=i.arg;else if("throw"===i.method){if("suspendedStart"===r)throw r="completed",i.arg;i.dispatchException(i.arg)}else"return"===i.method&&i.abrupt("return",i.arg);r="executing";var c=d(e,t,i);if("normal"===c.type){if(r=i.done?"completed":"suspendedYield",c.arg===v)continue;return{value:c.arg,done:i.done}}"throw"===c.type&&(r="completed",i.method="throw",i.arg=c.arg)}}}function x(e,t){var i=t.method,r=e.iterator[i];if(void 0===r)return t.delegate=null,"throw"===i&&e.iterator.return&&(t.method="return",t.arg=void 0,x(e,t),"throw"===t.method)||"return"!==i&&(t.method="throw",t.arg=new TypeError("The iterator does not provide a '"+i+"' method")),v;var n=d(r,e.iterator,t.arg);if("throw"===n.type)return t.method="throw",t.arg=n.arg,t.delegate=null,v;var s=n.arg;return s?s.done?(t[e.resultName]=s.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,v):s:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,v)}function L(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function E(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function R(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(L,this),this.reset(!0)}function M(e){if(e){var t=e[c];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var i=-1,r=function t(){for(;++i<e.length;)if(s.call(e,i))return t.value=e[i],t.done=!1,t;return t.value=void 0,t.done=!0,t};return r.next=r}}return{next:A}}function A(){return{value:void 0,done:!0}}return p.prototype=g,o(C,"constructor",{value:g,configurable:!0}),o(g,"constructor",{value:p,configurable:!0}),p.displayName=h(g,u,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===p||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,g):(e.__proto__=g,h(e,u,"GeneratorFunction")),e.prototype=Object.create(C),e},t.awrap=function(e){return{__await:e}},S(w.prototype),h(w.prototype,l,(function(){return this})),t.AsyncIterator=w,t.async=function(e,i,r,n,s){void 0===s&&(s=Promise);var o=new w(f(e,i,r,n),s);return t.isGeneratorFunction(i)?o:o.next().then((function(e){return e.done?e.value:o.next()}))},S(C),h(C,u,"Generator"),h(C,c,(function(){return this})),h(C,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),i=[];for(var r in t)i.push(r);return i.reverse(),function e(){for(;i.length;){var r=i.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=M,R.prototype={constructor:R,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!e)for(var t in this)"t"===t.charAt(0)&&s.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function i(i,r){return o.type="throw",o.arg=e,t.next=i,r&&(t.method="next",t.arg=void 0),!!r}for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r],o=n.completion;if("root"===n.tryLoc)return i("end");if(n.tryLoc<=this.prev){var a=s.call(n,"catchLoc"),c=s.call(n,"finallyLoc");if(a&&c){if(this.prev<n.catchLoc)return i(n.catchLoc,!0);if(this.prev<n.finallyLoc)return i(n.finallyLoc)}else if(a){if(this.prev<n.catchLoc)return i(n.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<n.finallyLoc)return i(n.finallyLoc)}}}},abrupt:function(e,t){for(var i=this.tryEntries.length-1;i>=0;--i){var r=this.tryEntries[i];if(r.tryLoc<=this.prev&&s.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var n=r;break}}n&&("break"===e||"continue"===e)&&n.tryLoc<=t&&t<=n.finallyLoc&&(n=null);var o=n?n.completion:{};return o.type=e,o.arg=t,n?(this.method="next",this.next=n.finallyLoc,v):this.complete(o)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),v},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var i=this.tryEntries[t];if(i.finallyLoc===e)return this.complete(i.completion,i.afterLoc),E(i),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var i=this.tryEntries[t];if(i.tryLoc===e){var r=i.completion;if("throw"===r.type){var n=r.arg;E(i)}return n}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,i){return this.delegate={iterator:M(e),resultName:t,nextLoc:i},"next"===this.method&&(this.arg=void 0),v}},t}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},6015:function(e){function t(i,r){return e.exports=t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,t(i,r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},7424:function(e,t,i){var r=i(5372),n=i(8872),s=i(6116),o=i(2218);e.exports=function(e,t){return r(e)||n(e,t)||s(e,t)||o()},e.exports.__esModule=!0,e.exports.default=e.exports},1753:function(e,t,i){var r=i(4968);e.exports=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=r(e)););return e},e.exports.__esModule=!0,e.exports.default=e.exports},861:function(e,t,i){var r=i(3405),n=i(9498),s=i(6116),o=i(2281);e.exports=function(e){return r(e)||n(e)||s(e)||o()},e.exports.__esModule=!0,e.exports.default=e.exports},5036:function(e,t,i){var r=i(8698).default;e.exports=function(e,t){if("object"!==r(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,t||"default");if("object"!==r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},4062:function(e,t,i){var r=i(8698).default,n=i(5036);e.exports=function(e){var t=n(e,"string");return"symbol"===r(t)?t:String(t)},e.exports.__esModule=!0,e.exports.default=e.exports},8698:function(e){function t(i){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(i)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},6116:function(e,t,i){var r=i(3897);e.exports=function(e,t){if(e){if("string"===typeof e)return r(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?r(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},4226:function(e,t,i){"use strict";i.d(t,{Z:function(){return r}});var r={formControl:"pf-c-form-control",modifiers:{success:"pf-m-success",plain:"pf-m-plain",expanded:"pf-m-expanded",icon:"pf-m-icon",warning:"pf-m-warning",search:"pf-m-search",calendar:"pf-m-calendar",clock:"pf-m-clock",iconSprite:"pf-m-icon-sprite",placeholder:"pf-m-placeholder",resizeVertical:"pf-m-resize-vertical",resizeHorizontal:"pf-m-resize-horizontal"},themeDark:"pf-theme-dark"}},3634:function(e,t,i){"use strict";i.d(t,{Z:function(){return r}});var r={button:"pf-c-button",chipGroup:"pf-c-chip-group",divider:"pf-c-divider",modifiers:{hidden:"pf-m-hidden",hiddenOnSm:"pf-m-hidden-on-sm",visibleOnSm:"pf-m-visible-on-sm",hiddenOnMd:"pf-m-hidden-on-md",visibleOnMd:"pf-m-visible-on-md",hiddenOnLg:"pf-m-hidden-on-lg",visibleOnLg:"pf-m-visible-on-lg",hiddenOnXl:"pf-m-hidden-on-xl",visibleOnXl:"pf-m-visible-on-xl",hiddenOn_2xl:"pf-m-hidden-on-2xl",visibleOn_2xl:"pf-m-visible-on-2xl",pageInsets:"pf-m-page-insets",sticky:"pf-m-sticky",fullHeight:"pf-m-full-height",static:"pf-m-static",vertical:"pf-m-vertical",buttonGroup:"pf-m-button-group",iconButtonGroup:"pf-m-icon-button-group",filterGroup:"pf-m-filter-group",toggleGroup:"pf-m-toggle-group",overflowMenu:"pf-m-overflow-menu",bulkSelect:"pf-m-bulk-select",expandAll:"pf-m-expand-all",expanded:"pf-m-expanded",searchFilter:"pf-m-search-filter",chipGroup:"pf-m-chip-group",label:"pf-m-label",pagination:"pf-m-pagination",overflowContainer:"pf-m-overflow-container",chipContainer:"pf-m-chip-container",plain:"pf-m-plain",show:"pf-m-show",showOnSm:"pf-m-show-on-sm",showOnMd:"pf-m-show-on-md",showOnLg:"pf-m-show-on-lg",showOnXl:"pf-m-show-on-xl",showOn_2xl:"pf-m-show-on-2xl",alignRight:"pf-m-align-right",alignLeft:"pf-m-align-left",nowrap:"pf-m-nowrap",wrap:"pf-m-wrap",alignRightOnSm:"pf-m-align-right-on-sm",alignLeftOnSm:"pf-m-align-left-on-sm",nowrapOnSm:"pf-m-nowrap-on-sm",wrapOnSm:"pf-m-wrap-on-sm",alignRightOnMd:"pf-m-align-right-on-md",alignLeftOnMd:"pf-m-align-left-on-md",nowrapOnMd:"pf-m-nowrap-on-md",wrapOnMd:"pf-m-wrap-on-md",alignRightOnLg:"pf-m-align-right-on-lg",alignLeftOnLg:"pf-m-align-left-on-lg",nowrapOnLg:"pf-m-nowrap-on-lg",wrapOnLg:"pf-m-wrap-on-lg",alignRightOnXl:"pf-m-align-right-on-xl",alignLeftOnXl:"pf-m-align-left-on-xl",nowrapOnXl:"pf-m-nowrap-on-xl",wrapOnXl:"pf-m-wrap-on-xl",alignRightOn_2xl:"pf-m-align-right-on-2xl",alignLeftOn_2xl:"pf-m-align-left-on-2xl",nowrapOn_2xl:"pf-m-nowrap-on-2xl",wrapOn_2xl:"pf-m-wrap-on-2xl",spaceItemsNone:"pf-m-space-items-none",spaceItemsSm:"pf-m-space-items-sm",spaceItemsMd:"pf-m-space-items-md",spaceItemsLg:"pf-m-space-items-lg",spaceItemsNoneOnSm:"pf-m-space-items-none-on-sm",spaceItemsSmOnSm:"pf-m-space-items-sm-on-sm",spaceItemsMdOnSm:"pf-m-space-items-md-on-sm",spaceItemsLgOnSm:"pf-m-space-items-lg-on-sm",spaceItemsNoneOnMd:"pf-m-space-items-none-on-md",spaceItemsSmOnMd:"pf-m-space-items-sm-on-md",spaceItemsMdOnMd:"pf-m-space-items-md-on-md",spaceItemsLgOnMd:"pf-m-space-items-lg-on-md",spaceItemsNoneOnLg:"pf-m-space-items-none-on-lg",spaceItemsSmOnLg:"pf-m-space-items-sm-on-lg",spaceItemsMdOnLg:"pf-m-space-items-md-on-lg",spaceItemsLgOnLg:"pf-m-space-items-lg-on-lg",spaceItemsNoneOnXl:"pf-m-space-items-none-on-xl",spaceItemsSmOnXl:"pf-m-space-items-sm-on-xl",spaceItemsMdOnXl:"pf-m-space-items-md-on-xl",spaceItemsLgOnXl:"pf-m-space-items-lg-on-xl",spaceItemsNoneOn_2xl:"pf-m-space-items-none-on-2xl",spaceItemsSmOn_2xl:"pf-m-space-items-sm-on-2xl",spaceItemsMdOn_2xl:"pf-m-space-items-md-on-2xl",spaceItemsLgOn_2xl:"pf-m-space-items-lg-on-2xl",spacerNone:"pf-m-spacer-none",spacerSm:"pf-m-spacer-sm",spacerMd:"pf-m-spacer-md",spacerLg:"pf-m-spacer-lg",spacerNoneOnSm:"pf-m-spacer-none-on-sm",spacerSmOnSm:"pf-m-spacer-sm-on-sm",spacerMdOnSm:"pf-m-spacer-md-on-sm",spacerLgOnSm:"pf-m-spacer-lg-on-sm",spacerNoneOnMd:"pf-m-spacer-none-on-md",spacerSmOnMd:"pf-m-spacer-sm-on-md",spacerMdOnMd:"pf-m-spacer-md-on-md",spacerLgOnMd:"pf-m-spacer-lg-on-md",spacerNoneOnLg:"pf-m-spacer-none-on-lg",spacerSmOnLg:"pf-m-spacer-sm-on-lg",spacerMdOnLg:"pf-m-spacer-md-on-lg",spacerLgOnLg:"pf-m-spacer-lg-on-lg",spacerNoneOnXl:"pf-m-spacer-none-on-xl",spacerSmOnXl:"pf-m-spacer-sm-on-xl",spacerMdOnXl:"pf-m-spacer-md-on-xl",spacerLgOnXl:"pf-m-spacer-lg-on-xl",spacerNoneOn_2xl:"pf-m-spacer-none-on-2xl",spacerSmOn_2xl:"pf-m-spacer-sm-on-2xl",spacerMdOn_2xl:"pf-m-spacer-md-on-2xl",spacerLgOn_2xl:"pf-m-spacer-lg-on-2xl",insetNone:"pf-m-inset-none",insetSm:"pf-m-inset-sm",insetMd:"pf-m-inset-md",insetLg:"pf-m-inset-lg",insetXl:"pf-m-inset-xl",inset_2xl:"pf-m-inset-2xl",insetNoneOnSm:"pf-m-inset-none-on-sm",insetSmOnSm:"pf-m-inset-sm-on-sm",insetMdOnSm:"pf-m-inset-md-on-sm",insetLgOnSm:"pf-m-inset-lg-on-sm",insetXlOnSm:"pf-m-inset-xl-on-sm",inset_2xlOnSm:"pf-m-inset-2xl-on-sm",insetNoneOnMd:"pf-m-inset-none-on-md",insetSmOnMd:"pf-m-inset-sm-on-md",insetMdOnMd:"pf-m-inset-md-on-md",insetLgOnMd:"pf-m-inset-lg-on-md",insetXlOnMd:"pf-m-inset-xl-on-md",inset_2xlOnMd:"pf-m-inset-2xl-on-md",insetNoneOnLg:"pf-m-inset-none-on-lg",insetSmOnLg:"pf-m-inset-sm-on-lg",insetMdOnLg:"pf-m-inset-md-on-lg",insetLgOnLg:"pf-m-inset-lg-on-lg",insetXlOnLg:"pf-m-inset-xl-on-lg",inset_2xlOnLg:"pf-m-inset-2xl-on-lg",insetNoneOnXl:"pf-m-inset-none-on-xl",insetSmOnXl:"pf-m-inset-sm-on-xl",insetMdOnXl:"pf-m-inset-md-on-xl",insetLgOnXl:"pf-m-inset-lg-on-xl",insetXlOnXl:"pf-m-inset-xl-on-xl",inset_2xlOnXl:"pf-m-inset-2xl-on-xl",insetNoneOn_2xl:"pf-m-inset-none-on-2xl",insetSmOn_2xl:"pf-m-inset-sm-on-2xl",insetMdOn_2xl:"pf-m-inset-md-on-2xl",insetLgOn_2xl:"pf-m-inset-lg-on-2xl",insetXlOn_2xl:"pf-m-inset-xl-on-2xl",inset_2xlOn_2xl:"pf-m-inset-2xl-on-2xl"},pagination:"pf-c-pagination",toolbar:"pf-c-toolbar",toolbarContent:"pf-c-toolbar__content",toolbarContentSection:"pf-c-toolbar__content-section",toolbarExpandAllIcon:"pf-c-toolbar__expand-all-icon",toolbarExpandableContent:"pf-c-toolbar__expandable-content",toolbarGroup:"pf-c-toolbar__group",toolbarItem:"pf-c-toolbar__item",toolbarToggle:"pf-c-toolbar__toggle"}}}]);
|
|
//# sourceMappingURL=769.3b95354d.chunk.js.map
|